@treegress.com/treegress-browser-core 1.59.0-treegress.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +60 -0
- package/ThirdPartyNotices.txt +3759 -0
- package/bin/install_media_pack.ps1 +5 -0
- package/bin/install_webkit_wsl.ps1 +33 -0
- package/bin/reinstall_chrome_beta_linux.sh +42 -0
- package/bin/reinstall_chrome_beta_mac.sh +13 -0
- package/bin/reinstall_chrome_beta_win.ps1 +24 -0
- package/bin/reinstall_chrome_stable_linux.sh +42 -0
- package/bin/reinstall_chrome_stable_mac.sh +12 -0
- package/bin/reinstall_chrome_stable_win.ps1 +24 -0
- package/bin/reinstall_msedge_beta_linux.sh +48 -0
- package/bin/reinstall_msedge_beta_mac.sh +11 -0
- package/bin/reinstall_msedge_beta_win.ps1 +23 -0
- package/bin/reinstall_msedge_dev_linux.sh +48 -0
- package/bin/reinstall_msedge_dev_mac.sh +11 -0
- package/bin/reinstall_msedge_dev_win.ps1 +23 -0
- package/bin/reinstall_msedge_stable_linux.sh +48 -0
- package/bin/reinstall_msedge_stable_mac.sh +11 -0
- package/bin/reinstall_msedge_stable_win.ps1 +24 -0
- package/browsers.json +81 -0
- package/cli.js +18 -0
- package/index.d.ts +17 -0
- package/index.js +32 -0
- package/index.mjs +28 -0
- package/lib/androidServerImpl.js +65 -0
- package/lib/browserServerImpl.js +120 -0
- package/lib/cli/client/cli.js +6 -0
- package/lib/cli/client/program.js +375 -0
- package/lib/cli/client/registry.js +171 -0
- package/lib/cli/client/session.js +282 -0
- package/lib/cli/client/socketConnection.js +108 -0
- package/lib/cli/daemon/command.js +73 -0
- package/lib/cli/daemon/commands.js +879 -0
- package/lib/cli/daemon/daemon.js +179 -0
- package/lib/cli/daemon/helpGenerator.js +173 -0
- package/lib/cli/daemon/program.js +123 -0
- package/lib/cli/driver.js +98 -0
- package/lib/cli/program.js +598 -0
- package/lib/cli/programWithTestStub.js +74 -0
- package/lib/client/android.js +361 -0
- package/lib/client/api.js +137 -0
- package/lib/client/artifact.js +79 -0
- package/lib/client/browser.js +169 -0
- package/lib/client/browserContext.js +590 -0
- package/lib/client/browserType.js +153 -0
- package/lib/client/cdpSession.js +55 -0
- package/lib/client/channelOwner.js +194 -0
- package/lib/client/clientHelper.js +64 -0
- package/lib/client/clientInstrumentation.js +55 -0
- package/lib/client/clientStackTrace.js +69 -0
- package/lib/client/clock.js +68 -0
- package/lib/client/connect.js +152 -0
- package/lib/client/connection.js +322 -0
- package/lib/client/consoleMessage.js +61 -0
- package/lib/client/coverage.js +44 -0
- package/lib/client/dialog.js +56 -0
- package/lib/client/disposable.js +76 -0
- package/lib/client/download.js +62 -0
- package/lib/client/electron.js +138 -0
- package/lib/client/elementHandle.js +284 -0
- package/lib/client/errors.js +77 -0
- package/lib/client/eventEmitter.js +327 -0
- package/lib/client/events.js +103 -0
- package/lib/client/fetch.js +368 -0
- package/lib/client/fileChooser.js +46 -0
- package/lib/client/fileUtils.js +34 -0
- package/lib/client/frame.js +409 -0
- package/lib/client/harRouter.js +99 -0
- package/lib/client/input.js +84 -0
- package/lib/client/inspector.js +48 -0
- package/lib/client/jsHandle.js +109 -0
- package/lib/client/jsonPipe.js +39 -0
- package/lib/client/localUtils.js +60 -0
- package/lib/client/locator.js +373 -0
- package/lib/client/network.js +750 -0
- package/lib/client/page.js +750 -0
- package/lib/client/pageAgent.js +64 -0
- package/lib/client/platform.js +77 -0
- package/lib/client/playwright.js +71 -0
- package/lib/client/selectors.js +55 -0
- package/lib/client/stream.js +39 -0
- package/lib/client/timeoutSettings.js +79 -0
- package/lib/client/tracing.js +124 -0
- package/lib/client/types.js +28 -0
- package/lib/client/video.js +65 -0
- package/lib/client/waiter.js +142 -0
- package/lib/client/webError.js +39 -0
- package/lib/client/worker.js +85 -0
- package/lib/client/writableStream.js +39 -0
- package/lib/devtools/appIcon.png +0 -0
- package/lib/devtools/devtoolsApp.js +275 -0
- package/lib/devtools/devtoolsController.js +289 -0
- package/lib/generated/bindingsControllerSource.js +28 -0
- package/lib/generated/clockSource.js +28 -0
- package/lib/generated/injectedScriptSource.js +28 -0
- package/lib/generated/pollingRecorderSource.js +28 -0
- package/lib/generated/storageScriptSource.js +28 -0
- package/lib/generated/utilityScriptSource.js +28 -0
- package/lib/generated/webSocketMockSource.js +336 -0
- package/lib/inProcessFactory.js +60 -0
- package/lib/inprocess.js +3 -0
- package/lib/mcp/browserFactory.js +196 -0
- package/lib/mcp/cdpRelay.js +353 -0
- package/lib/mcp/config.d.js +16 -0
- package/lib/mcp/config.js +399 -0
- package/lib/mcp/configIni.js +190 -0
- package/lib/mcp/exports.js +42 -0
- package/lib/mcp/extensionContextFactory.js +59 -0
- package/lib/mcp/index.js +62 -0
- package/lib/mcp/log.js +35 -0
- package/lib/mcp/program.js +111 -0
- package/lib/mcp/protocol.js +28 -0
- package/lib/mcp/sdk/http.js +152 -0
- package/lib/mcp/sdk/server.js +230 -0
- package/lib/mcp/sdk/tool.js +47 -0
- package/lib/mcp/watchdog.js +44 -0
- package/lib/mcpBundle.js +84 -0
- package/lib/mcpBundleImpl/index.js +147 -0
- package/lib/outofprocess.js +76 -0
- package/lib/protocol/serializers.js +197 -0
- package/lib/protocol/validator.js +3064 -0
- package/lib/protocol/validatorPrimitives.js +193 -0
- package/lib/remote/playwrightConnection.js +129 -0
- package/lib/remote/playwrightPipeServer.js +100 -0
- package/lib/remote/playwrightServer.js +339 -0
- package/lib/remote/playwrightWebSocketServer.js +73 -0
- package/lib/remote/serverTransport.js +96 -0
- package/lib/server/agent/actionRunner.js +341 -0
- package/lib/server/agent/actions.js +128 -0
- package/lib/server/agent/codegen.js +111 -0
- package/lib/server/agent/context.js +161 -0
- package/lib/server/agent/expectTools.js +156 -0
- package/lib/server/agent/pageAgent.js +204 -0
- package/lib/server/agent/performTools.js +262 -0
- package/lib/server/agent/tool.js +109 -0
- package/lib/server/android/android.js +465 -0
- package/lib/server/android/backendAdb.js +177 -0
- package/lib/server/artifact.js +127 -0
- package/lib/server/bidi/bidiBrowser.js +560 -0
- package/lib/server/bidi/bidiChromium.js +162 -0
- package/lib/server/bidi/bidiConnection.js +213 -0
- package/lib/server/bidi/bidiDeserializer.js +116 -0
- package/lib/server/bidi/bidiExecutionContext.js +267 -0
- package/lib/server/bidi/bidiFirefox.js +128 -0
- package/lib/server/bidi/bidiInput.js +146 -0
- package/lib/server/bidi/bidiNetworkManager.js +411 -0
- package/lib/server/bidi/bidiOverCdp.js +102 -0
- package/lib/server/bidi/bidiPage.js +598 -0
- package/lib/server/bidi/bidiPdf.js +106 -0
- package/lib/server/bidi/third_party/bidiCommands.d.js +22 -0
- package/lib/server/bidi/third_party/bidiKeyboard.js +256 -0
- package/lib/server/bidi/third_party/bidiProtocol.js +24 -0
- package/lib/server/bidi/third_party/bidiProtocolCore.js +180 -0
- package/lib/server/bidi/third_party/bidiProtocolPermissions.js +42 -0
- package/lib/server/bidi/third_party/bidiSerializer.js +148 -0
- package/lib/server/bidi/third_party/firefoxPrefs.js +261 -0
- package/lib/server/browser.js +217 -0
- package/lib/server/browserContext.js +699 -0
- package/lib/server/browserType.js +337 -0
- package/lib/server/callLog.js +82 -0
- package/lib/server/chromium/appIcon.png +0 -0
- package/lib/server/chromium/chromium.js +399 -0
- package/lib/server/chromium/chromiumSwitches.js +104 -0
- package/lib/server/chromium/crBrowser.js +532 -0
- package/lib/server/chromium/crConnection.js +197 -0
- package/lib/server/chromium/crCoverage.js +235 -0
- package/lib/server/chromium/crDevTools.js +111 -0
- package/lib/server/chromium/crDragDrop.js +131 -0
- package/lib/server/chromium/crExecutionContext.js +146 -0
- package/lib/server/chromium/crInput.js +187 -0
- package/lib/server/chromium/crNetworkManager.js +708 -0
- package/lib/server/chromium/crPage.js +1004 -0
- package/lib/server/chromium/crPdf.js +121 -0
- package/lib/server/chromium/crProtocolHelper.js +145 -0
- package/lib/server/chromium/crServiceWorker.js +136 -0
- package/lib/server/chromium/defaultFontFamilies.js +162 -0
- package/lib/server/chromium/protocol.d.js +16 -0
- package/lib/server/clock.js +149 -0
- package/lib/server/codegen/csharp.js +327 -0
- package/lib/server/codegen/java.js +274 -0
- package/lib/server/codegen/javascript.js +247 -0
- package/lib/server/codegen/jsonl.js +52 -0
- package/lib/server/codegen/language.js +132 -0
- package/lib/server/codegen/languages.js +68 -0
- package/lib/server/codegen/python.js +279 -0
- package/lib/server/codegen/types.js +16 -0
- package/lib/server/console.js +61 -0
- package/lib/server/cookieStore.js +206 -0
- package/lib/server/debugController.js +197 -0
- package/lib/server/debugger.js +119 -0
- package/lib/server/deviceDescriptors.js +39 -0
- package/lib/server/deviceDescriptorsSource.json +1779 -0
- package/lib/server/dialog.js +116 -0
- package/lib/server/dispatchers/androidDispatcher.js +325 -0
- package/lib/server/dispatchers/artifactDispatcher.js +118 -0
- package/lib/server/dispatchers/browserContextDispatcher.js +377 -0
- package/lib/server/dispatchers/browserDispatcher.js +124 -0
- package/lib/server/dispatchers/browserTypeDispatcher.js +71 -0
- package/lib/server/dispatchers/cdpSessionDispatcher.js +47 -0
- package/lib/server/dispatchers/debugControllerDispatcher.js +78 -0
- package/lib/server/dispatchers/dialogDispatcher.js +47 -0
- package/lib/server/dispatchers/dispatcher.js +364 -0
- package/lib/server/dispatchers/disposableDispatcher.js +39 -0
- package/lib/server/dispatchers/electronDispatcher.js +90 -0
- package/lib/server/dispatchers/elementHandlerDispatcher.js +181 -0
- package/lib/server/dispatchers/frameDispatcher.js +227 -0
- package/lib/server/dispatchers/jsHandleDispatcher.js +85 -0
- package/lib/server/dispatchers/jsonPipeDispatcher.js +58 -0
- package/lib/server/dispatchers/localUtilsDispatcher.js +185 -0
- package/lib/server/dispatchers/networkDispatchers.js +214 -0
- package/lib/server/dispatchers/pageAgentDispatcher.js +106 -0
- package/lib/server/dispatchers/pageDispatcher.js +441 -0
- package/lib/server/dispatchers/playwrightDispatcher.js +108 -0
- package/lib/server/dispatchers/streamDispatcher.js +67 -0
- package/lib/server/dispatchers/tracingDispatcher.js +68 -0
- package/lib/server/dispatchers/webSocketRouteDispatcher.js +164 -0
- package/lib/server/dispatchers/writableStreamDispatcher.js +79 -0
- package/lib/server/disposable.js +41 -0
- package/lib/server/dom.js +815 -0
- package/lib/server/download.js +71 -0
- package/lib/server/electron/electron.js +272 -0
- package/lib/server/electron/loader.js +30 -0
- package/lib/server/errors.js +69 -0
- package/lib/server/fetch.js +621 -0
- package/lib/server/fileChooser.js +43 -0
- package/lib/server/fileUploadUtils.js +84 -0
- package/lib/server/firefox/ffBrowser.js +415 -0
- package/lib/server/firefox/ffConnection.js +142 -0
- package/lib/server/firefox/ffExecutionContext.js +150 -0
- package/lib/server/firefox/ffInput.js +159 -0
- package/lib/server/firefox/ffNetworkManager.js +256 -0
- package/lib/server/firefox/ffPage.js +495 -0
- package/lib/server/firefox/firefox.js +114 -0
- package/lib/server/firefox/protocol.d.js +16 -0
- package/lib/server/formData.js +147 -0
- package/lib/server/frameSelectors.js +160 -0
- package/lib/server/frames.js +1476 -0
- package/lib/server/har/harRecorder.js +147 -0
- package/lib/server/har/harTracer.js +608 -0
- package/lib/server/harBackend.js +157 -0
- package/lib/server/helper.js +96 -0
- package/lib/server/index.js +58 -0
- package/lib/server/input.js +277 -0
- package/lib/server/instrumentation.js +72 -0
- package/lib/server/javascript.js +291 -0
- package/lib/server/launchApp.js +127 -0
- package/lib/server/localUtils.js +214 -0
- package/lib/server/macEditingCommands.js +143 -0
- package/lib/server/network.js +668 -0
- package/lib/server/page.js +915 -0
- package/lib/server/pipeTransport.js +89 -0
- package/lib/server/playwright.js +69 -0
- package/lib/server/progress.js +136 -0
- package/lib/server/protocolError.js +52 -0
- package/lib/server/recorder/chat.js +161 -0
- package/lib/server/recorder/recorderApp.js +367 -0
- package/lib/server/recorder/recorderRunner.js +138 -0
- package/lib/server/recorder/recorderSignalProcessor.js +83 -0
- package/lib/server/recorder/recorderUtils.js +157 -0
- package/lib/server/recorder/throttledFile.js +57 -0
- package/lib/server/recorder.js +533 -0
- package/lib/server/registry/browserFetcher.js +177 -0
- package/lib/server/registry/dependencies.js +371 -0
- package/lib/server/registry/index.js +1395 -0
- package/lib/server/registry/nativeDeps.js +1281 -0
- package/lib/server/registry/oopDownloadBrowserMain.js +127 -0
- package/lib/server/screencast.js +214 -0
- package/lib/server/screenshotter.js +333 -0
- package/lib/server/selectors.js +112 -0
- package/lib/server/socksClientCertificatesInterceptor.js +383 -0
- package/lib/server/socksInterceptor.js +95 -0
- package/lib/server/trace/recorder/snapshotter.js +147 -0
- package/lib/server/trace/recorder/snapshotterInjected.js +561 -0
- package/lib/server/trace/recorder/tracing.js +607 -0
- package/lib/server/trace/viewer/traceParser.js +72 -0
- package/lib/server/trace/viewer/traceViewer.js +244 -0
- package/lib/server/transport.js +181 -0
- package/lib/server/types.js +28 -0
- package/lib/server/usKeyboardLayout.js +145 -0
- package/lib/server/utils/ascii.js +44 -0
- package/lib/server/utils/comparators.js +139 -0
- package/lib/server/utils/crypto.js +216 -0
- package/lib/server/utils/debug.js +42 -0
- package/lib/server/utils/debugLogger.js +122 -0
- package/lib/server/utils/env.js +73 -0
- package/lib/server/utils/eventsHelper.js +39 -0
- package/lib/server/utils/expectUtils.js +123 -0
- package/lib/server/utils/fileUtils.js +191 -0
- package/lib/server/utils/happyEyeballs.js +207 -0
- package/lib/server/utils/hostPlatform.js +123 -0
- package/lib/server/utils/httpServer.js +205 -0
- package/lib/server/utils/image_tools/colorUtils.js +89 -0
- package/lib/server/utils/image_tools/compare.js +109 -0
- package/lib/server/utils/image_tools/imageChannel.js +78 -0
- package/lib/server/utils/image_tools/stats.js +102 -0
- package/lib/server/utils/linuxUtils.js +71 -0
- package/lib/server/utils/network.js +244 -0
- package/lib/server/utils/nodePlatform.js +154 -0
- package/lib/server/utils/pipeTransport.js +84 -0
- package/lib/server/utils/processLauncher.js +243 -0
- package/lib/server/utils/profiler.js +65 -0
- package/lib/server/utils/socksProxy.js +511 -0
- package/lib/server/utils/spawnAsync.js +41 -0
- package/lib/server/utils/task.js +51 -0
- package/lib/server/utils/userAgent.js +98 -0
- package/lib/server/utils/wsServer.js +121 -0
- package/lib/server/utils/zipFile.js +74 -0
- package/lib/server/utils/zones.js +57 -0
- package/lib/server/videoRecorder.js +133 -0
- package/lib/server/webkit/protocol.d.js +16 -0
- package/lib/server/webkit/webkit.js +108 -0
- package/lib/server/webkit/wkBrowser.js +331 -0
- package/lib/server/webkit/wkConnection.js +144 -0
- package/lib/server/webkit/wkExecutionContext.js +154 -0
- package/lib/server/webkit/wkInput.js +181 -0
- package/lib/server/webkit/wkInterceptableRequest.js +197 -0
- package/lib/server/webkit/wkPage.js +1164 -0
- package/lib/server/webkit/wkProvisionalPage.js +83 -0
- package/lib/server/webkit/wkWorkers.js +106 -0
- package/lib/serverRegistry.js +136 -0
- package/lib/third_party/pixelmatch.js +255 -0
- package/lib/tools/browserServerBackend.js +79 -0
- package/lib/tools/common.js +63 -0
- package/lib/tools/config.js +41 -0
- package/lib/tools/console.js +65 -0
- package/lib/tools/context.js +282 -0
- package/lib/tools/cookies.js +152 -0
- package/lib/tools/customDomLocatorCompiler.js +239 -0
- package/lib/tools/customDomResolverDiagnostics.js +100 -0
- package/lib/tools/customDomSnapshotFormatter.js +658 -0
- package/lib/tools/devtools.js +42 -0
- package/lib/tools/dialogs.js +59 -0
- package/lib/tools/evaluate.js +61 -0
- package/lib/tools/exports.js +57 -0
- package/lib/tools/files.js +58 -0
- package/lib/tools/form.js +63 -0
- package/lib/tools/keyboard.js +151 -0
- package/lib/tools/logFile.js +95 -0
- package/lib/tools/mouse.js +170 -0
- package/lib/tools/navigate.js +105 -0
- package/lib/tools/network.js +112 -0
- package/lib/tools/pdf.js +48 -0
- package/lib/tools/response.js +278 -0
- package/lib/tools/route.js +140 -0
- package/lib/tools/runCode.js +76 -0
- package/lib/tools/screenshot.js +87 -0
- package/lib/tools/sessionLog.js +75 -0
- package/lib/tools/snapshot.js +209 -0
- package/lib/tools/storage.js +67 -0
- package/lib/tools/tab.js +596 -0
- package/lib/tools/tabs.js +67 -0
- package/lib/tools/tool.js +47 -0
- package/lib/tools/tools.js +94 -0
- package/lib/tools/tracing.js +75 -0
- package/lib/tools/utils.js +88 -0
- package/lib/tools/verify.js +149 -0
- package/lib/tools/video.js +89 -0
- package/lib/tools/wait.js +63 -0
- package/lib/tools/webstorage.js +223 -0
- package/lib/utils/isomorphic/aiSnapshotTypes.js +16 -0
- package/lib/utils/isomorphic/ariaSnapshot.js +455 -0
- package/lib/utils/isomorphic/assert.js +31 -0
- package/lib/utils/isomorphic/colors.js +72 -0
- package/lib/utils/isomorphic/cssParser.js +245 -0
- package/lib/utils/isomorphic/cssTokenizer.js +1051 -0
- package/lib/utils/isomorphic/headers.js +53 -0
- package/lib/utils/isomorphic/imageUtils.js +141 -0
- package/lib/utils/isomorphic/locatorGenerators.js +689 -0
- package/lib/utils/isomorphic/locatorParser.js +176 -0
- package/lib/utils/isomorphic/locatorUtils.js +81 -0
- package/lib/utils/isomorphic/lruCache.js +51 -0
- package/lib/utils/isomorphic/manualPromise.js +114 -0
- package/lib/utils/isomorphic/mimeType.js +464 -0
- package/lib/utils/isomorphic/multimap.js +80 -0
- package/lib/utils/isomorphic/protocolFormatter.js +81 -0
- package/lib/utils/isomorphic/protocolMetainfo.js +345 -0
- package/lib/utils/isomorphic/rtti.js +43 -0
- package/lib/utils/isomorphic/selectorParser.js +386 -0
- package/lib/utils/isomorphic/semaphore.js +54 -0
- package/lib/utils/isomorphic/stackTrace.js +158 -0
- package/lib/utils/isomorphic/stringUtils.js +204 -0
- package/lib/utils/isomorphic/time.js +49 -0
- package/lib/utils/isomorphic/timeoutRunner.js +66 -0
- package/lib/utils/isomorphic/trace/entries.js +16 -0
- package/lib/utils/isomorphic/trace/snapshotRenderer.js +502 -0
- package/lib/utils/isomorphic/trace/snapshotServer.js +120 -0
- package/lib/utils/isomorphic/trace/snapshotStorage.js +89 -0
- package/lib/utils/isomorphic/trace/traceLoader.js +131 -0
- package/lib/utils/isomorphic/trace/traceModel.js +366 -0
- package/lib/utils/isomorphic/trace/traceModernizer.js +401 -0
- package/lib/utils/isomorphic/trace/versions/traceV3.js +16 -0
- package/lib/utils/isomorphic/trace/versions/traceV4.js +16 -0
- package/lib/utils/isomorphic/trace/versions/traceV5.js +16 -0
- package/lib/utils/isomorphic/trace/versions/traceV6.js +16 -0
- package/lib/utils/isomorphic/trace/versions/traceV7.js +16 -0
- package/lib/utils/isomorphic/trace/versions/traceV8.js +16 -0
- package/lib/utils/isomorphic/traceUtils.js +58 -0
- package/lib/utils/isomorphic/types.js +16 -0
- package/lib/utils/isomorphic/urlMatch.js +243 -0
- package/lib/utils/isomorphic/utilityScriptSerializers.js +262 -0
- package/lib/utils/isomorphic/yaml.js +84 -0
- package/lib/utils.js +111 -0
- package/lib/utilsBundle.js +112 -0
- package/lib/utilsBundleImpl/index.js +218 -0
- package/lib/utilsBundleImpl/xdg-open +1066 -0
- package/lib/vite/devtools/assets/index-D3CVnoLM.css +1 -0
- package/lib/vite/devtools/assets/index-wqccfruE.js +50 -0
- package/lib/vite/devtools/index.html +28 -0
- package/lib/vite/htmlReport/index.html +84 -0
- package/lib/vite/recorder/assets/codeMirrorModule-4NapTJOb.js +32 -0
- package/lib/vite/recorder/assets/codeMirrorModule-DYBRYzYX.css +1 -0
- package/lib/vite/recorder/assets/codicon-DCmgc-ay.ttf +0 -0
- package/lib/vite/recorder/assets/index-BSjZa4pk.css +1 -0
- package/lib/vite/recorder/assets/index-CD9lKVjM.js +193 -0
- package/lib/vite/recorder/index.html +29 -0
- package/lib/vite/recorder/playwright-logo.svg +9 -0
- package/lib/vite/traceViewer/assets/codeMirrorModule-RgXeHFoQ.js +32 -0
- package/lib/vite/traceViewer/assets/defaultSettingsView-DP6vvJEM.js +269 -0
- package/lib/vite/traceViewer/assets/xtermModule-CsJ4vdCR.js +9 -0
- package/lib/vite/traceViewer/codeMirrorModule.DYBRYzYX.css +1 -0
- package/lib/vite/traceViewer/codicon.DCmgc-ay.ttf +0 -0
- package/lib/vite/traceViewer/defaultSettingsView.DQ9U-ctL.css +1 -0
- package/lib/vite/traceViewer/index.BVu7tZDe.css +1 -0
- package/lib/vite/traceViewer/index.D8YUXFVt.js +2 -0
- package/lib/vite/traceViewer/index.html +43 -0
- package/lib/vite/traceViewer/manifest.webmanifest +16 -0
- package/lib/vite/traceViewer/playwright-logo.svg +9 -0
- package/lib/vite/traceViewer/snapshot.html +21 -0
- package/lib/vite/traceViewer/sw.bundle.js +5 -0
- package/lib/vite/traceViewer/uiMode.BIQFTUME.js +6 -0
- package/lib/vite/traceViewer/uiMode.Btcz36p_.css +1 -0
- package/lib/vite/traceViewer/uiMode.html +17 -0
- package/lib/vite/traceViewer/xtermModule.DYP7pi_n.css +32 -0
- package/lib/zipBundle.js +34 -0
- package/lib/zipBundleImpl.js +5 -0
- package/package.json +52 -0
- package/types/protocol.d.ts +24365 -0
- package/types/structs.d.ts +45 -0
- package/types/types.d.ts +23724 -0
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./codeMirrorModule-RgXeHFoQ.js","../codeMirrorModule.DYBRYzYX.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const a of document.querySelectorAll('link[rel="modulepreload"]'))s(a);new MutationObserver(a=>{for(const o of a)if(o.type==="childList")for(const c of o.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&s(c)}).observe(document,{childList:!0,subtree:!0});function i(a){const o={};return a.integrity&&(o.integrity=a.integrity),a.referrerPolicy&&(o.referrerPolicy=a.referrerPolicy),a.crossOrigin==="use-credentials"?o.credentials="include":a.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function s(a){if(a.ep)return;a.ep=!0;const o=i(a);fetch(a.href,o)}})();function kx(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var dh={exports:{}},Ba={};/**
|
|
3
|
+
* @license React
|
|
4
|
+
* react-jsx-runtime.production.js
|
|
5
|
+
*
|
|
6
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
7
|
+
*
|
|
8
|
+
* This source code is licensed under the MIT license found in the
|
|
9
|
+
* LICENSE file in the root directory of this source tree.
|
|
10
|
+
*/var ab;function Mx(){if(ab)return Ba;ab=1;var n=Symbol.for("react.transitional.element"),e=Symbol.for("react.fragment");function i(s,a,o){var c=null;if(o!==void 0&&(c=""+o),a.key!==void 0&&(c=""+a.key),"key"in a){o={};for(var f in a)f!=="key"&&(o[f]=a[f])}else o=a;return a=o.ref,{$$typeof:n,type:s,key:c,ref:a!==void 0?a:null,props:o}}return Ba.Fragment=e,Ba.jsx=i,Ba.jsxs=i,Ba}var lb;function Ox(){return lb||(lb=1,dh.exports=Mx()),dh.exports}var w=Ox(),ph={exports:{}},ue={};/**
|
|
11
|
+
* @license React
|
|
12
|
+
* react.production.js
|
|
13
|
+
*
|
|
14
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
15
|
+
*
|
|
16
|
+
* This source code is licensed under the MIT license found in the
|
|
17
|
+
* LICENSE file in the root directory of this source tree.
|
|
18
|
+
*/var ob;function Lx(){if(ob)return ue;ob=1;var n=Symbol.for("react.transitional.element"),e=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),s=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),c=Symbol.for("react.context"),f=Symbol.for("react.forward_ref"),h=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),m=Symbol.for("react.activity"),v=Symbol.iterator;function S(k){return k===null||typeof k!="object"?null:(k=v&&k[v]||k["@@iterator"],typeof k=="function"?k:null)}var T={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},x=Object.assign,E={};function A(k,X,Z){this.props=k,this.context=X,this.refs=E,this.updater=Z||T}A.prototype.isReactComponent={},A.prototype.setState=function(k,X){if(typeof k!="object"&&typeof k!="function"&&k!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,k,X,"setState")},A.prototype.forceUpdate=function(k){this.updater.enqueueForceUpdate(this,k,"forceUpdate")};function N(){}N.prototype=A.prototype;function B(k,X,Z){this.props=k,this.context=X,this.refs=E,this.updater=Z||T}var V=B.prototype=new N;V.constructor=B,x(V,A.prototype),V.isPureReactComponent=!0;var $=Array.isArray;function z(){}var Q={H:null,A:null,T:null,S:null},H=Object.prototype.hasOwnProperty;function L(k,X,Z){var ee=Z.ref;return{$$typeof:n,type:k,key:X,ref:ee!==void 0?ee:null,props:Z}}function ne(k,X){return L(k.type,X,k.props)}function ae(k){return typeof k=="object"&&k!==null&&k.$$typeof===n}function G(k){var X={"=":"=0",":":"=2"};return"$"+k.replace(/[=:]/g,function(Z){return X[Z]})}var P=/\/+/g;function W(k,X){return typeof k=="object"&&k!==null&&k.key!=null?G(""+k.key):X.toString(36)}function Ce(k){switch(k.status){case"fulfilled":return k.value;case"rejected":throw k.reason;default:switch(typeof k.status=="string"?k.then(z,z):(k.status="pending",k.then(function(X){k.status==="pending"&&(k.status="fulfilled",k.value=X)},function(X){k.status==="pending"&&(k.status="rejected",k.reason=X)})),k.status){case"fulfilled":return k.value;case"rejected":throw k.reason}}throw k}function q(k,X,Z,ee,ce){var de=typeof k;(de==="undefined"||de==="boolean")&&(k=null);var Ee=!1;if(k===null)Ee=!0;else switch(de){case"bigint":case"string":case"number":Ee=!0;break;case"object":switch(k.$$typeof){case n:case e:Ee=!0;break;case y:return Ee=k._init,q(Ee(k._payload),X,Z,ee,ce)}}if(Ee)return ce=ce(k),Ee=ee===""?"."+W(k,0):ee,$(ce)?(Z="",Ee!=null&&(Z=Ee.replace(P,"$&/")+"/"),q(ce,X,Z,"",function(Ln){return Ln})):ce!=null&&(ae(ce)&&(ce=ne(ce,Z+(ce.key==null||k&&k.key===ce.key?"":(""+ce.key).replace(P,"$&/")+"/")+Ee)),X.push(ce)),1;Ee=0;var ve=ee===""?".":ee+":";if($(k))for(var qe=0;qe<k.length;qe++)ee=k[qe],de=ve+W(ee,qe),Ee+=q(ee,X,Z,de,ce);else if(qe=S(k),typeof qe=="function")for(k=qe.call(k),qe=0;!(ee=k.next()).done;)ee=ee.value,de=ve+W(ee,qe++),Ee+=q(ee,X,Z,de,ce);else if(de==="object"){if(typeof k.then=="function")return q(Ce(k),X,Z,ee,ce);throw X=String(k),Error("Objects are not valid as a React child (found: "+(X==="[object Object]"?"object with keys {"+Object.keys(k).join(", ")+"}":X)+"). If you meant to render a collection of children, use an array instead.")}return Ee}function J(k,X,Z){if(k==null)return k;var ee=[],ce=0;return q(k,ee,"","",function(de){return X.call(Z,de,ce++)}),ee}function se(k){if(k._status===-1){var X=k._result;X=X(),X.then(function(Z){(k._status===0||k._status===-1)&&(k._status=1,k._result=Z)},function(Z){(k._status===0||k._status===-1)&&(k._status=2,k._result=Z)}),k._status===-1&&(k._status=0,k._result=X)}if(k._status===1)return k._result.default;throw k._result}var we=typeof reportError=="function"?reportError:function(k){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var X=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof k=="object"&&k!==null&&typeof k.message=="string"?String(k.message):String(k),error:k});if(!window.dispatchEvent(X))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",k);return}console.error(k)},xe={map:J,forEach:function(k,X,Z){J(k,function(){X.apply(this,arguments)},Z)},count:function(k){var X=0;return J(k,function(){X++}),X},toArray:function(k){return J(k,function(X){return X})||[]},only:function(k){if(!ae(k))throw Error("React.Children.only expected to receive a single React element child.");return k}};return ue.Activity=m,ue.Children=xe,ue.Component=A,ue.Fragment=i,ue.Profiler=a,ue.PureComponent=B,ue.StrictMode=s,ue.Suspense=h,ue.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=Q,ue.__COMPILER_RUNTIME={__proto__:null,c:function(k){return Q.H.useMemoCache(k)}},ue.cache=function(k){return function(){return k.apply(null,arguments)}},ue.cacheSignal=function(){return null},ue.cloneElement=function(k,X,Z){if(k==null)throw Error("The argument must be a React element, but you passed "+k+".");var ee=x({},k.props),ce=k.key;if(X!=null)for(de in X.key!==void 0&&(ce=""+X.key),X)!H.call(X,de)||de==="key"||de==="__self"||de==="__source"||de==="ref"&&X.ref===void 0||(ee[de]=X[de]);var de=arguments.length-2;if(de===1)ee.children=Z;else if(1<de){for(var Ee=Array(de),ve=0;ve<de;ve++)Ee[ve]=arguments[ve+2];ee.children=Ee}return L(k.type,ce,ee)},ue.createContext=function(k){return k={$$typeof:c,_currentValue:k,_currentValue2:k,_threadCount:0,Provider:null,Consumer:null},k.Provider=k,k.Consumer={$$typeof:o,_context:k},k},ue.createElement=function(k,X,Z){var ee,ce={},de=null;if(X!=null)for(ee in X.key!==void 0&&(de=""+X.key),X)H.call(X,ee)&&ee!=="key"&&ee!=="__self"&&ee!=="__source"&&(ce[ee]=X[ee]);var Ee=arguments.length-2;if(Ee===1)ce.children=Z;else if(1<Ee){for(var ve=Array(Ee),qe=0;qe<Ee;qe++)ve[qe]=arguments[qe+2];ce.children=ve}if(k&&k.defaultProps)for(ee in Ee=k.defaultProps,Ee)ce[ee]===void 0&&(ce[ee]=Ee[ee]);return L(k,de,ce)},ue.createRef=function(){return{current:null}},ue.forwardRef=function(k){return{$$typeof:f,render:k}},ue.isValidElement=ae,ue.lazy=function(k){return{$$typeof:y,_payload:{_status:-1,_result:k},_init:se}},ue.memo=function(k,X){return{$$typeof:p,type:k,compare:X===void 0?null:X}},ue.startTransition=function(k){var X=Q.T,Z={};Q.T=Z;try{var ee=k(),ce=Q.S;ce!==null&&ce(Z,ee),typeof ee=="object"&&ee!==null&&typeof ee.then=="function"&&ee.then(z,we)}catch(de){we(de)}finally{X!==null&&Z.types!==null&&(X.types=Z.types),Q.T=X}},ue.unstable_useCacheRefresh=function(){return Q.H.useCacheRefresh()},ue.use=function(k){return Q.H.use(k)},ue.useActionState=function(k,X,Z){return Q.H.useActionState(k,X,Z)},ue.useCallback=function(k,X){return Q.H.useCallback(k,X)},ue.useContext=function(k){return Q.H.useContext(k)},ue.useDebugValue=function(){},ue.useDeferredValue=function(k,X){return Q.H.useDeferredValue(k,X)},ue.useEffect=function(k,X){return Q.H.useEffect(k,X)},ue.useEffectEvent=function(k){return Q.H.useEffectEvent(k)},ue.useId=function(){return Q.H.useId()},ue.useImperativeHandle=function(k,X,Z){return Q.H.useImperativeHandle(k,X,Z)},ue.useInsertionEffect=function(k,X){return Q.H.useInsertionEffect(k,X)},ue.useLayoutEffect=function(k,X){return Q.H.useLayoutEffect(k,X)},ue.useMemo=function(k,X){return Q.H.useMemo(k,X)},ue.useOptimistic=function(k,X){return Q.H.useOptimistic(k,X)},ue.useReducer=function(k,X,Z){return Q.H.useReducer(k,X,Z)},ue.useRef=function(k){return Q.H.useRef(k)},ue.useState=function(k){return Q.H.useState(k)},ue.useSyncExternalStore=function(k,X,Z){return Q.H.useSyncExternalStore(k,X,Z)},ue.useTransition=function(){return Q.H.useTransition()},ue.version="19.2.1",ue}var cb;function hd(){return cb||(cb=1,ph.exports=Lx()),ph.exports}var U=hd();const yt=kx(U);function cc(n,e,i,s){const[a,o]=yt.useState(i);return yt.useEffect(()=>{let c=!1;return n().then(f=>{c||o(f)}),()=>{c=!0}},e),a}function bs(){const n=yt.useRef(null),[e]=Uh(n);return[e,n]}function Uh(n){const[e,i]=yt.useState(new DOMRect(0,0,10,10)),s=yt.useCallback(()=>{const a=n==null?void 0:n.current;a&&i(a.getBoundingClientRect())},[n]);return yt.useLayoutEffect(()=>{const a=n==null?void 0:n.current;if(!a)return;s();const o=new ResizeObserver(s);return o.observe(a),window.addEventListener("resize",s),()=>{o.disconnect(),window.removeEventListener("resize",s)}},[s,n]),[e,s]}function mt(n){if(n<0||!isFinite(n))return"-";if(n===0)return"0";if(n<1e3)return n.toFixed(0)+"ms";const e=n/1e3;if(e<60)return e.toFixed(1)+"s";const i=e/60;if(i<60)return i.toFixed(1)+"m";const s=i/60;return s<24?s.toFixed(1)+"h":(s/24).toFixed(1)+"d"}function jx(n){if(n<0||!isFinite(n))return"-";if(n===0)return"0";if(n<1e3)return n.toFixed(0);const e=n/1024;if(e<1e3)return e.toFixed(1)+"K";const i=e/1024;return i<1e3?i.toFixed(1)+"M":(i/1024).toFixed(1)+"G"}function v0(n,e,i,s,a){let o=0,c=n.length;for(;o<c;){const f=o+c>>1;i(e,n[f])>=0?o=f+1:c=f}return c}function ub(n){const e=document.createElement("textarea");e.style.position="absolute",e.style.zIndex="-1000",e.value=n,document.body.appendChild(e),e.select(),document.execCommand("copy"),e.remove()}function fn(n,e){n&&(e=cs.getObject(n,e));const[i,s]=yt.useState(e),a=yt.useCallback(o=>{n?cs.setObject(n,o):s(o)},[n,s]);return yt.useEffect(()=>{if(n){const o=()=>s(cs.getObject(n,e));return cs.onChangeEmitter.addEventListener(n,o),()=>cs.onChangeEmitter.removeEventListener(n,o)}},[e,n]),[i,a]}const Hh=new Map,S0=new Map;let uc;function Mi(n,e){const[i,s]=yt.useState();S0.set(n,{setter:s,defaultValue:e});const a=yt.useCallback(o=>{const c=Hh.get(uc||"default")||{};c[n]=o,Hh.set(uc||"default",c),s(o)},[n]);return[i,a]}function Rx(n){if(uc===n)return;uc=n;const e=Hh.get(n)||{};for(const[i,s]of S0.entries())s.setter(e[i]||s.defaultValue)}class Dx{constructor(){this.onChangeEmitter=new EventTarget}getString(e,i){return localStorage[e]||i}setString(e,i){var s;localStorage[e]=i,this.onChangeEmitter.dispatchEvent(new Event(e)),(s=window.saveSettings)==null||s.call(window)}getObject(e,i){if(!localStorage[e])return i;try{return JSON.parse(localStorage[e])}catch{return i}}setObject(e,i){var s;localStorage[e]=JSON.stringify(i),this.onChangeEmitter.dispatchEvent(new Event(e)),(s=window.saveSettings)==null||s.call(window)}}const cs=new Dx;function Qe(...n){return n.filter(Boolean).join(" ")}function w0(n){n&&(n!=null&&n.scrollIntoViewIfNeeded?n.scrollIntoViewIfNeeded(!1):n==null||n.scrollIntoView())}const fb="\\u0000-\\u0020\\u007f-\\u009f",x0=new RegExp("(?:[a-zA-Z][a-zA-Z0-9+.-]{2,}:\\/\\/|www\\.)[^\\s"+fb+'"]{2,}[^\\s'+fb+`"')}\\],:;.!?]`,"ug");function Bx(){const[n,e]=yt.useState(!1),i=yt.useCallback(()=>{const s=[];return e(a=>(s.push(setTimeout(()=>e(!1),1e3)),a?(s.push(setTimeout(()=>e(!0),50)),!1):!0)),()=>s.forEach(clearTimeout)},[e]);return[n,i]}const zx="system",E0="theme",Ux=[{label:"Dark mode",value:"dark-mode"},{label:"Light mode",value:"light-mode"},{label:"System",value:"system"}],T0=window.matchMedia("(prefers-color-scheme: dark)");function x2(){document.playwrightThemeInitialized||(document.playwrightThemeInitialized=!0,document.defaultView.addEventListener("focus",n=>{n.target.document.nodeType===Node.DOCUMENT_NODE&&document.body.classList.remove("inactive")},!1),document.defaultView.addEventListener("blur",n=>{document.body.classList.add("inactive")},!1),qh(Ih()),T0.addEventListener("change",()=>{qh(Ih())}))}const dd=new Set;function qh(n){const e=Hx(),i=n==="system"?T0.matches?"dark-mode":"light-mode":n;if(e!==i){e&&document.documentElement.classList.remove(e),document.documentElement.classList.add(i);for(const s of dd)s(i)}}function E2(n){dd.add(n)}function T2(n){dd.delete(n)}function Ih(){return cs.getString(E0,zx)}function Hx(){return document.documentElement.classList.contains("dark-mode")?"dark-mode":document.documentElement.classList.contains("light-mode")?"light-mode":null}function qx(){const[n,e]=yt.useState(Ih());return yt.useEffect(()=>{cs.setString(E0,n),qh(n)},[n]),[n,e]}var gh={exports:{}},za={},mh={exports:{}},yh={};/**
|
|
19
|
+
* @license React
|
|
20
|
+
* scheduler.production.js
|
|
21
|
+
*
|
|
22
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
23
|
+
*
|
|
24
|
+
* This source code is licensed under the MIT license found in the
|
|
25
|
+
* LICENSE file in the root directory of this source tree.
|
|
26
|
+
*/var hb;function Ix(){return hb||(hb=1,(function(n){function e(q,J){var se=q.length;q.push(J);e:for(;0<se;){var we=se-1>>>1,xe=q[we];if(0<a(xe,J))q[we]=J,q[se]=xe,se=we;else break e}}function i(q){return q.length===0?null:q[0]}function s(q){if(q.length===0)return null;var J=q[0],se=q.pop();if(se!==J){q[0]=se;e:for(var we=0,xe=q.length,k=xe>>>1;we<k;){var X=2*(we+1)-1,Z=q[X],ee=X+1,ce=q[ee];if(0>a(Z,se))ee<xe&&0>a(ce,Z)?(q[we]=ce,q[ee]=se,we=ee):(q[we]=Z,q[X]=se,we=X);else if(ee<xe&&0>a(ce,se))q[we]=ce,q[ee]=se,we=ee;else break e}}return J}function a(q,J){var se=q.sortIndex-J.sortIndex;return se!==0?se:q.id-J.id}if(n.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var o=performance;n.unstable_now=function(){return o.now()}}else{var c=Date,f=c.now();n.unstable_now=function(){return c.now()-f}}var h=[],p=[],y=1,m=null,v=3,S=!1,T=!1,x=!1,E=!1,A=typeof setTimeout=="function"?setTimeout:null,N=typeof clearTimeout=="function"?clearTimeout:null,B=typeof setImmediate<"u"?setImmediate:null;function V(q){for(var J=i(p);J!==null;){if(J.callback===null)s(p);else if(J.startTime<=q)s(p),J.sortIndex=J.expirationTime,e(h,J);else break;J=i(p)}}function $(q){if(x=!1,V(q),!T)if(i(h)!==null)T=!0,z||(z=!0,G());else{var J=i(p);J!==null&&Ce($,J.startTime-q)}}var z=!1,Q=-1,H=5,L=-1;function ne(){return E?!0:!(n.unstable_now()-L<H)}function ae(){if(E=!1,z){var q=n.unstable_now();L=q;var J=!0;try{e:{T=!1,x&&(x=!1,N(Q),Q=-1),S=!0;var se=v;try{t:{for(V(q),m=i(h);m!==null&&!(m.expirationTime>q&&ne());){var we=m.callback;if(typeof we=="function"){m.callback=null,v=m.priorityLevel;var xe=we(m.expirationTime<=q);if(q=n.unstable_now(),typeof xe=="function"){m.callback=xe,V(q),J=!0;break t}m===i(h)&&s(h),V(q)}else s(h);m=i(h)}if(m!==null)J=!0;else{var k=i(p);k!==null&&Ce($,k.startTime-q),J=!1}}break e}finally{m=null,v=se,S=!1}J=void 0}}finally{J?G():z=!1}}}var G;if(typeof B=="function")G=function(){B(ae)};else if(typeof MessageChannel<"u"){var P=new MessageChannel,W=P.port2;P.port1.onmessage=ae,G=function(){W.postMessage(null)}}else G=function(){A(ae,0)};function Ce(q,J){Q=A(function(){q(n.unstable_now())},J)}n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(q){q.callback=null},n.unstable_forceFrameRate=function(q){0>q||125<q?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):H=0<q?Math.floor(1e3/q):5},n.unstable_getCurrentPriorityLevel=function(){return v},n.unstable_next=function(q){switch(v){case 1:case 2:case 3:var J=3;break;default:J=v}var se=v;v=J;try{return q()}finally{v=se}},n.unstable_requestPaint=function(){E=!0},n.unstable_runWithPriority=function(q,J){switch(q){case 1:case 2:case 3:case 4:case 5:break;default:q=3}var se=v;v=q;try{return J()}finally{v=se}},n.unstable_scheduleCallback=function(q,J,se){var we=n.unstable_now();switch(typeof se=="object"&&se!==null?(se=se.delay,se=typeof se=="number"&&0<se?we+se:we):se=we,q){case 1:var xe=-1;break;case 2:xe=250;break;case 5:xe=1073741823;break;case 4:xe=1e4;break;default:xe=5e3}return xe=se+xe,q={id:y++,callback:J,priorityLevel:q,startTime:se,expirationTime:xe,sortIndex:-1},se>we?(q.sortIndex=se,e(p,q),i(h)===null&&q===i(p)&&(x?(N(Q),Q=-1):x=!0,Ce($,se-we))):(q.sortIndex=xe,e(h,q),T||S||(T=!0,z||(z=!0,G()))),q},n.unstable_shouldYield=ne,n.unstable_wrapCallback=function(q){var J=v;return function(){var se=v;v=J;try{return q.apply(this,arguments)}finally{v=se}}}})(yh)),yh}var db;function $x(){return db||(db=1,mh.exports=Ix()),mh.exports}var bh={exports:{}},vt={};/**
|
|
27
|
+
* @license React
|
|
28
|
+
* react-dom.production.js
|
|
29
|
+
*
|
|
30
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
31
|
+
*
|
|
32
|
+
* This source code is licensed under the MIT license found in the
|
|
33
|
+
* LICENSE file in the root directory of this source tree.
|
|
34
|
+
*/var pb;function Vx(){if(pb)return vt;pb=1;var n=hd();function e(h){var p="https://react.dev/errors/"+h;if(1<arguments.length){p+="?args[]="+encodeURIComponent(arguments[1]);for(var y=2;y<arguments.length;y++)p+="&args[]="+encodeURIComponent(arguments[y])}return"Minified React error #"+h+"; visit "+p+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(){}var s={d:{f:i,r:function(){throw Error(e(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},a=Symbol.for("react.portal");function o(h,p,y){var m=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:m==null?null:""+m,children:h,containerInfo:p,implementation:y}}var c=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function f(h,p){if(h==="font")return"";if(typeof p=="string")return p==="use-credentials"?p:""}return vt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=s,vt.createPortal=function(h,p){var y=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!p||p.nodeType!==1&&p.nodeType!==9&&p.nodeType!==11)throw Error(e(299));return o(h,p,null,y)},vt.flushSync=function(h){var p=c.T,y=s.p;try{if(c.T=null,s.p=2,h)return h()}finally{c.T=p,s.p=y,s.d.f()}},vt.preconnect=function(h,p){typeof h=="string"&&(p?(p=p.crossOrigin,p=typeof p=="string"?p==="use-credentials"?p:"":void 0):p=null,s.d.C(h,p))},vt.prefetchDNS=function(h){typeof h=="string"&&s.d.D(h)},vt.preinit=function(h,p){if(typeof h=="string"&&p&&typeof p.as=="string"){var y=p.as,m=f(y,p.crossOrigin),v=typeof p.integrity=="string"?p.integrity:void 0,S=typeof p.fetchPriority=="string"?p.fetchPriority:void 0;y==="style"?s.d.S(h,typeof p.precedence=="string"?p.precedence:void 0,{crossOrigin:m,integrity:v,fetchPriority:S}):y==="script"&&s.d.X(h,{crossOrigin:m,integrity:v,fetchPriority:S,nonce:typeof p.nonce=="string"?p.nonce:void 0})}},vt.preinitModule=function(h,p){if(typeof h=="string")if(typeof p=="object"&&p!==null){if(p.as==null||p.as==="script"){var y=f(p.as,p.crossOrigin);s.d.M(h,{crossOrigin:y,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0})}}else p==null&&s.d.M(h)},vt.preload=function(h,p){if(typeof h=="string"&&typeof p=="object"&&p!==null&&typeof p.as=="string"){var y=p.as,m=f(y,p.crossOrigin);s.d.L(h,y,{crossOrigin:m,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0,type:typeof p.type=="string"?p.type:void 0,fetchPriority:typeof p.fetchPriority=="string"?p.fetchPriority:void 0,referrerPolicy:typeof p.referrerPolicy=="string"?p.referrerPolicy:void 0,imageSrcSet:typeof p.imageSrcSet=="string"?p.imageSrcSet:void 0,imageSizes:typeof p.imageSizes=="string"?p.imageSizes:void 0,media:typeof p.media=="string"?p.media:void 0})}},vt.preloadModule=function(h,p){if(typeof h=="string")if(p){var y=f(p.as,p.crossOrigin);s.d.m(h,{as:typeof p.as=="string"&&p.as!=="script"?p.as:void 0,crossOrigin:y,integrity:typeof p.integrity=="string"?p.integrity:void 0})}else s.d.m(h)},vt.requestFormReset=function(h){s.d.r(h)},vt.unstable_batchedUpdates=function(h,p){return h(p)},vt.useFormState=function(h,p,y){return c.H.useFormState(h,p,y)},vt.useFormStatus=function(){return c.H.useHostTransitionStatus()},vt.version="19.2.1",vt}var gb;function Gx(){if(gb)return bh.exports;gb=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}return n(),bh.exports=Vx(),bh.exports}/**
|
|
35
|
+
* @license React
|
|
36
|
+
* react-dom-client.production.js
|
|
37
|
+
*
|
|
38
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
39
|
+
*
|
|
40
|
+
* This source code is licensed under the MIT license found in the
|
|
41
|
+
* LICENSE file in the root directory of this source tree.
|
|
42
|
+
*/var mb;function Kx(){if(mb)return za;mb=1;var n=$x(),e=hd(),i=Gx();function s(t){var r="https://react.dev/errors/"+t;if(1<arguments.length){r+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)r+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+t+"; visit "+r+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function a(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function o(t){var r=t,l=t;if(t.alternate)for(;r.return;)r=r.return;else{t=r;do r=t,(r.flags&4098)!==0&&(l=r.return),t=r.return;while(t)}return r.tag===3?l:null}function c(t){if(t.tag===13){var r=t.memoizedState;if(r===null&&(t=t.alternate,t!==null&&(r=t.memoizedState)),r!==null)return r.dehydrated}return null}function f(t){if(t.tag===31){var r=t.memoizedState;if(r===null&&(t=t.alternate,t!==null&&(r=t.memoizedState)),r!==null)return r.dehydrated}return null}function h(t){if(o(t)!==t)throw Error(s(188))}function p(t){var r=t.alternate;if(!r){if(r=o(t),r===null)throw Error(s(188));return r!==t?null:t}for(var l=t,u=r;;){var d=l.return;if(d===null)break;var g=d.alternate;if(g===null){if(u=d.return,u!==null){l=u;continue}break}if(d.child===g.child){for(g=d.child;g;){if(g===l)return h(d),t;if(g===u)return h(d),r;g=g.sibling}throw Error(s(188))}if(l.return!==u.return)l=d,u=g;else{for(var b=!1,_=d.child;_;){if(_===l){b=!0,l=d,u=g;break}if(_===u){b=!0,u=d,l=g;break}_=_.sibling}if(!b){for(_=g.child;_;){if(_===l){b=!0,l=g,u=d;break}if(_===u){b=!0,u=g,l=d;break}_=_.sibling}if(!b)throw Error(s(189))}}if(l.alternate!==u)throw Error(s(190))}if(l.tag!==3)throw Error(s(188));return l.stateNode.current===l?t:r}function y(t){var r=t.tag;if(r===5||r===26||r===27||r===6)return t;for(t=t.child;t!==null;){if(r=y(t),r!==null)return r;t=t.sibling}return null}var m=Object.assign,v=Symbol.for("react.element"),S=Symbol.for("react.transitional.element"),T=Symbol.for("react.portal"),x=Symbol.for("react.fragment"),E=Symbol.for("react.strict_mode"),A=Symbol.for("react.profiler"),N=Symbol.for("react.consumer"),B=Symbol.for("react.context"),V=Symbol.for("react.forward_ref"),$=Symbol.for("react.suspense"),z=Symbol.for("react.suspense_list"),Q=Symbol.for("react.memo"),H=Symbol.for("react.lazy"),L=Symbol.for("react.activity"),ne=Symbol.for("react.memo_cache_sentinel"),ae=Symbol.iterator;function G(t){return t===null||typeof t!="object"?null:(t=ae&&t[ae]||t["@@iterator"],typeof t=="function"?t:null)}var P=Symbol.for("react.client.reference");function W(t){if(t==null)return null;if(typeof t=="function")return t.$$typeof===P?null:t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case x:return"Fragment";case A:return"Profiler";case E:return"StrictMode";case $:return"Suspense";case z:return"SuspenseList";case L:return"Activity"}if(typeof t=="object")switch(t.$$typeof){case T:return"Portal";case B:return t.displayName||"Context";case N:return(t._context.displayName||"Context")+".Consumer";case V:var r=t.render;return t=t.displayName,t||(t=r.displayName||r.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case Q:return r=t.displayName||null,r!==null?r:W(t.type)||"Memo";case H:r=t._payload,t=t._init;try{return W(t(r))}catch{}}return null}var Ce=Array.isArray,q=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,J=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,se={pending:!1,data:null,method:null,action:null},we=[],xe=-1;function k(t){return{current:t}}function X(t){0>xe||(t.current=we[xe],we[xe]=null,xe--)}function Z(t,r){xe++,we[xe]=t.current,t.current=r}var ee=k(null),ce=k(null),de=k(null),Ee=k(null);function ve(t,r){switch(Z(de,r),Z(ce,t),Z(ee,null),r.nodeType){case 9:case 11:t=(t=r.documentElement)&&(t=t.namespaceURI)?ky(t):0;break;default:if(t=r.tagName,r=r.namespaceURI)r=ky(r),t=My(r,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}X(ee),Z(ee,t)}function qe(){X(ee),X(ce),X(de)}function Ln(t){t.memoizedState!==null&&Z(Ee,t);var r=ee.current,l=My(r,t.type);r!==l&&(Z(ce,t),Z(ee,l))}function ri(t){ce.current===t&&(X(ee),X(ce)),Ee.current===t&&(X(Ee),La._currentValue=se)}var Vr,Ui;function xt(t){if(Vr===void 0)try{throw Error()}catch(l){var r=l.stack.trim().match(/\n( *(at )?)/);Vr=r&&r[1]||"",Ui=-1<l.stack.indexOf(`
|
|
43
|
+
at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
44
|
+
`+Vr+t+Ui}var xs=!1;function Et(t,r){if(!t||xs)return"";xs=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var u={DetermineComponentFrameRoot:function(){try{if(r){var Y=function(){throw Error()};if(Object.defineProperty(Y.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Y,[])}catch(I){var D=I}Reflect.construct(t,[],Y)}else{try{Y.call()}catch(I){D=I}t.call(Y.prototype)}}else{try{throw Error()}catch(I){D=I}(Y=t())&&typeof Y.catch=="function"&&Y.catch(function(){})}}catch(I){if(I&&D&&typeof I.stack=="string")return[I.stack,D.stack]}return[null,null]}};u.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var d=Object.getOwnPropertyDescriptor(u.DetermineComponentFrameRoot,"name");d&&d.configurable&&Object.defineProperty(u.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var g=u.DetermineComponentFrameRoot(),b=g[0],_=g[1];if(b&&_){var C=b.split(`
|
|
45
|
+
`),R=_.split(`
|
|
46
|
+
`);for(d=u=0;u<C.length&&!C[u].includes("DetermineComponentFrameRoot");)u++;for(;d<R.length&&!R[d].includes("DetermineComponentFrameRoot");)d++;if(u===C.length||d===R.length)for(u=C.length-1,d=R.length-1;1<=u&&0<=d&&C[u]!==R[d];)d--;for(;1<=u&&0<=d;u--,d--)if(C[u]!==R[d]){if(u!==1||d!==1)do if(u--,d--,0>d||C[u]!==R[d]){var K=`
|
|
47
|
+
`+C[u].replace(" at new "," at ");return t.displayName&&K.includes("<anonymous>")&&(K=K.replace("<anonymous>",t.displayName)),K}while(1<=u&&0<=d);break}}}finally{xs=!1,Error.prepareStackTrace=l}return(l=t?t.displayName||t.name:"")?xt(l):""}function Sl(t,r){switch(t.tag){case 26:case 27:case 5:return xt(t.type);case 16:return xt("Lazy");case 13:return t.child!==r&&r!==null?xt("Suspense Fallback"):xt("Suspense");case 19:return xt("SuspenseList");case 0:case 15:return Et(t.type,!1);case 11:return Et(t.type.render,!1);case 1:return Et(t.type,!0);case 31:return xt("Activity");default:return""}}function wl(t){try{var r="",l=null;do r+=Sl(t,l),l=t,t=t.return;while(t);return r}catch(u){return`
|
|
48
|
+
Error generating stack: `+u.message+`
|
|
49
|
+
`+u.stack}}var Gr=Object.prototype.hasOwnProperty,Hi=n.unstable_scheduleCallback,qi=n.unstable_cancelCallback,Es=n.unstable_shouldYield,Fc=n.unstable_requestPaint,Je=n.unstable_now,Yc=n.unstable_getCurrentPriorityLevel,xl=n.unstable_ImmediatePriority,El=n.unstable_UserBlockingPriority,Ts=n.unstable_NormalPriority,Tl=n.unstable_LowPriority,_s=n.unstable_IdlePriority,Qc=n.log,Pc=n.unstable_setDisableYieldValue,Ii=null,it=null;function Jt(t){if(typeof Qc=="function"&&Pc(t),it&&typeof it.setStrictMode=="function")try{it.setStrictMode(Ii,t)}catch{}}var at=Math.clz32?Math.clz32:Wc,Jc=Math.log,Zc=Math.LN2;function Wc(t){return t>>>=0,t===0?32:31-(Jc(t)/Zc|0)|0}var $i=256,le=262144,xn=4194304;function Tt(t){var r=t&42;if(r!==0)return r;switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function _l(t,r,l){var u=t.pendingLanes;if(u===0)return 0;var d=0,g=t.suspendedLanes,b=t.pingedLanes;t=t.warmLanes;var _=u&134217727;return _!==0?(u=_&~g,u!==0?d=Tt(u):(b&=_,b!==0?d=Tt(b):l||(l=_&~t,l!==0&&(d=Tt(l))))):(_=u&~g,_!==0?d=Tt(_):b!==0?d=Tt(b):l||(l=u&~t,l!==0&&(d=Tt(l)))),d===0?0:r!==0&&r!==d&&(r&g)===0&&(g=d&-d,l=r&-r,g>=l||g===32&&(l&4194048)!==0)?r:d}function Kr(t,r){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&r)===0}function mw(t,r){switch(t){case 1:case 2:case 4:case 8:case 64:return r+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return r+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function up(){var t=xn;return xn<<=1,(xn&62914560)===0&&(xn=4194304),t}function eu(t){for(var r=[],l=0;31>l;l++)r.push(t);return r}function Xr(t,r){t.pendingLanes|=r,r!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function yw(t,r,l,u,d,g){var b=t.pendingLanes;t.pendingLanes=l,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=l,t.entangledLanes&=l,t.errorRecoveryDisabledLanes&=l,t.shellSuspendCounter=0;var _=t.entanglements,C=t.expirationTimes,R=t.hiddenUpdates;for(l=b&~l;0<l;){var K=31-at(l),Y=1<<K;_[K]=0,C[K]=-1;var D=R[K];if(D!==null)for(R[K]=null,K=0;K<D.length;K++){var I=D[K];I!==null&&(I.lane&=-536870913)}l&=~Y}u!==0&&fp(t,u,0),g!==0&&d===0&&t.tag!==0&&(t.suspendedLanes|=g&~(b&~r))}function fp(t,r,l){t.pendingLanes|=r,t.suspendedLanes&=~r;var u=31-at(r);t.entangledLanes|=r,t.entanglements[u]=t.entanglements[u]|1073741824|l&261930}function hp(t,r){var l=t.entangledLanes|=r;for(t=t.entanglements;l;){var u=31-at(l),d=1<<u;d&r|t[u]&r&&(t[u]|=r),l&=~d}}function dp(t,r){var l=r&-r;return l=(l&42)!==0?1:tu(l),(l&(t.suspendedLanes|r))!==0?0:l}function tu(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function nu(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function pp(){var t=J.p;return t!==0?t:(t=window.event,t===void 0?32:Wy(t.type))}function gp(t,r){var l=J.p;try{return J.p=t,r()}finally{J.p=l}}var ai=Math.random().toString(36).slice(2),ct="__reactFiber$"+ai,kt="__reactProps$"+ai,As="__reactContainer$"+ai,iu="__reactEvents$"+ai,bw="__reactListeners$"+ai,vw="__reactHandles$"+ai,mp="__reactResources$"+ai,Fr="__reactMarker$"+ai;function su(t){delete t[ct],delete t[kt],delete t[iu],delete t[bw],delete t[vw]}function Cs(t){var r=t[ct];if(r)return r;for(var l=t.parentNode;l;){if(r=l[As]||l[ct]){if(l=r.alternate,r.child!==null||l!==null&&l.child!==null)for(t=zy(t);t!==null;){if(l=t[ct])return l;t=zy(t)}return r}t=l,l=t.parentNode}return null}function Ns(t){if(t=t[ct]||t[As]){var r=t.tag;if(r===5||r===6||r===13||r===31||r===26||r===27||r===3)return t}return null}function Yr(t){var r=t.tag;if(r===5||r===26||r===27||r===6)return t.stateNode;throw Error(s(33))}function ks(t){var r=t[mp];return r||(r=t[mp]={hoistableStyles:new Map,hoistableScripts:new Map}),r}function lt(t){t[Fr]=!0}var yp=new Set,bp={};function Vi(t,r){Ms(t,r),Ms(t+"Capture",r)}function Ms(t,r){for(bp[t]=r,t=0;t<r.length;t++)yp.add(r[t])}var Sw=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),vp={},Sp={};function ww(t){return Gr.call(Sp,t)?!0:Gr.call(vp,t)?!1:Sw.test(t)?Sp[t]=!0:(vp[t]=!0,!1)}function Al(t,r,l){if(ww(r))if(l===null)t.removeAttribute(r);else{switch(typeof l){case"undefined":case"function":case"symbol":t.removeAttribute(r);return;case"boolean":var u=r.toLowerCase().slice(0,5);if(u!=="data-"&&u!=="aria-"){t.removeAttribute(r);return}}t.setAttribute(r,""+l)}}function Cl(t,r,l){if(l===null)t.removeAttribute(r);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(r);return}t.setAttribute(r,""+l)}}function jn(t,r,l,u){if(u===null)t.removeAttribute(l);else{switch(typeof u){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(l);return}t.setAttributeNS(r,l,""+u)}}function Zt(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function wp(t){var r=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(r==="checkbox"||r==="radio")}function xw(t,r,l){var u=Object.getOwnPropertyDescriptor(t.constructor.prototype,r);if(!t.hasOwnProperty(r)&&typeof u<"u"&&typeof u.get=="function"&&typeof u.set=="function"){var d=u.get,g=u.set;return Object.defineProperty(t,r,{configurable:!0,get:function(){return d.call(this)},set:function(b){l=""+b,g.call(this,b)}}),Object.defineProperty(t,r,{enumerable:u.enumerable}),{getValue:function(){return l},setValue:function(b){l=""+b},stopTracking:function(){t._valueTracker=null,delete t[r]}}}}function ru(t){if(!t._valueTracker){var r=wp(t)?"checked":"value";t._valueTracker=xw(t,r,""+t[r])}}function xp(t){if(!t)return!1;var r=t._valueTracker;if(!r)return!0;var l=r.getValue(),u="";return t&&(u=wp(t)?t.checked?"true":"false":t.value),t=u,t!==l?(r.setValue(t),!0):!1}function Nl(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}var Ew=/[\n"\\]/g;function Wt(t){return t.replace(Ew,function(r){return"\\"+r.charCodeAt(0).toString(16)+" "})}function au(t,r,l,u,d,g,b,_){t.name="",b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?t.type=b:t.removeAttribute("type"),r!=null?b==="number"?(r===0&&t.value===""||t.value!=r)&&(t.value=""+Zt(r)):t.value!==""+Zt(r)&&(t.value=""+Zt(r)):b!=="submit"&&b!=="reset"||t.removeAttribute("value"),r!=null?lu(t,b,Zt(r)):l!=null?lu(t,b,Zt(l)):u!=null&&t.removeAttribute("value"),d==null&&g!=null&&(t.defaultChecked=!!g),d!=null&&(t.checked=d&&typeof d!="function"&&typeof d!="symbol"),_!=null&&typeof _!="function"&&typeof _!="symbol"&&typeof _!="boolean"?t.name=""+Zt(_):t.removeAttribute("name")}function Ep(t,r,l,u,d,g,b,_){if(g!=null&&typeof g!="function"&&typeof g!="symbol"&&typeof g!="boolean"&&(t.type=g),r!=null||l!=null){if(!(g!=="submit"&&g!=="reset"||r!=null)){ru(t);return}l=l!=null?""+Zt(l):"",r=r!=null?""+Zt(r):l,_||r===t.value||(t.value=r),t.defaultValue=r}u=u??d,u=typeof u!="function"&&typeof u!="symbol"&&!!u,t.checked=_?t.checked:!!u,t.defaultChecked=!!u,b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"&&(t.name=b),ru(t)}function lu(t,r,l){r==="number"&&Nl(t.ownerDocument)===t||t.defaultValue===""+l||(t.defaultValue=""+l)}function Os(t,r,l,u){if(t=t.options,r){r={};for(var d=0;d<l.length;d++)r["$"+l[d]]=!0;for(l=0;l<t.length;l++)d=r.hasOwnProperty("$"+t[l].value),t[l].selected!==d&&(t[l].selected=d),d&&u&&(t[l].defaultSelected=!0)}else{for(l=""+Zt(l),r=null,d=0;d<t.length;d++){if(t[d].value===l){t[d].selected=!0,u&&(t[d].defaultSelected=!0);return}r!==null||t[d].disabled||(r=t[d])}r!==null&&(r.selected=!0)}}function Tp(t,r,l){if(r!=null&&(r=""+Zt(r),r!==t.value&&(t.value=r),l==null)){t.defaultValue!==r&&(t.defaultValue=r);return}t.defaultValue=l!=null?""+Zt(l):""}function _p(t,r,l,u){if(r==null){if(u!=null){if(l!=null)throw Error(s(92));if(Ce(u)){if(1<u.length)throw Error(s(93));u=u[0]}l=u}l==null&&(l=""),r=l}l=Zt(r),t.defaultValue=l,u=t.textContent,u===l&&u!==""&&u!==null&&(t.value=u),ru(t)}function Ls(t,r){if(r){var l=t.firstChild;if(l&&l===t.lastChild&&l.nodeType===3){l.nodeValue=r;return}}t.textContent=r}var Tw=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function Ap(t,r,l){var u=r.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?u?t.setProperty(r,""):r==="float"?t.cssFloat="":t[r]="":u?t.setProperty(r,l):typeof l!="number"||l===0||Tw.has(r)?r==="float"?t.cssFloat=l:t[r]=(""+l).trim():t[r]=l+"px"}function Cp(t,r,l){if(r!=null&&typeof r!="object")throw Error(s(62));if(t=t.style,l!=null){for(var u in l)!l.hasOwnProperty(u)||r!=null&&r.hasOwnProperty(u)||(u.indexOf("--")===0?t.setProperty(u,""):u==="float"?t.cssFloat="":t[u]="");for(var d in r)u=r[d],r.hasOwnProperty(d)&&l[d]!==u&&Ap(t,d,u)}else for(var g in r)r.hasOwnProperty(g)&&Ap(t,g,r[g])}function ou(t){if(t.indexOf("-")===-1)return!1;switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var _w=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Aw=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function kl(t){return Aw.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function Rn(){}var cu=null;function uu(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var js=null,Rs=null;function Np(t){var r=Ns(t);if(r&&(t=r.stateNode)){var l=t[kt]||null;e:switch(t=r.stateNode,r.type){case"input":if(au(t,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),r=l.name,l.type==="radio"&&r!=null){for(l=t;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Wt(""+r)+'"][type="radio"]'),r=0;r<l.length;r++){var u=l[r];if(u!==t&&u.form===t.form){var d=u[kt]||null;if(!d)throw Error(s(90));au(u,d.value,d.defaultValue,d.defaultValue,d.checked,d.defaultChecked,d.type,d.name)}}for(r=0;r<l.length;r++)u=l[r],u.form===t.form&&xp(u)}break e;case"textarea":Tp(t,l.value,l.defaultValue);break e;case"select":r=l.value,r!=null&&Os(t,!!l.multiple,r,!1)}}}var fu=!1;function kp(t,r,l){if(fu)return t(r,l);fu=!0;try{var u=t(r);return u}finally{if(fu=!1,(js!==null||Rs!==null)&&(yo(),js&&(r=js,t=Rs,Rs=js=null,Np(r),t)))for(r=0;r<t.length;r++)Np(t[r])}}function Qr(t,r){var l=t.stateNode;if(l===null)return null;var u=l[kt]||null;if(u===null)return null;l=u[r];e:switch(r){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(u=!u.disabled)||(t=t.type,u=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!u;break e;default:t=!1}if(t)return null;if(l&&typeof l!="function")throw Error(s(231,r,typeof l));return l}var Dn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),hu=!1;if(Dn)try{var Pr={};Object.defineProperty(Pr,"passive",{get:function(){hu=!0}}),window.addEventListener("test",Pr,Pr),window.removeEventListener("test",Pr,Pr)}catch{hu=!1}var li=null,du=null,Ml=null;function Mp(){if(Ml)return Ml;var t,r=du,l=r.length,u,d="value"in li?li.value:li.textContent,g=d.length;for(t=0;t<l&&r[t]===d[t];t++);var b=l-t;for(u=1;u<=b&&r[l-u]===d[g-u];u++);return Ml=d.slice(t,1<u?1-u:void 0)}function Ol(t){var r=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&r===13&&(t=13)):t=r,t===10&&(t=13),32<=t||t===13?t:0}function Ll(){return!0}function Op(){return!1}function Mt(t){function r(l,u,d,g,b){this._reactName=l,this._targetInst=d,this.type=u,this.nativeEvent=g,this.target=b,this.currentTarget=null;for(var _ in t)t.hasOwnProperty(_)&&(l=t[_],this[_]=l?l(g):g[_]);return this.isDefaultPrevented=(g.defaultPrevented!=null?g.defaultPrevented:g.returnValue===!1)?Ll:Op,this.isPropagationStopped=Op,this}return m(r.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=Ll)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Ll)},persist:function(){},isPersistent:Ll}),r}var Gi={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},jl=Mt(Gi),Jr=m({},Gi,{view:0,detail:0}),Cw=Mt(Jr),pu,gu,Zr,Rl=m({},Jr,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:yu,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Zr&&(Zr&&t.type==="mousemove"?(pu=t.screenX-Zr.screenX,gu=t.screenY-Zr.screenY):gu=pu=0,Zr=t),pu)},movementY:function(t){return"movementY"in t?t.movementY:gu}}),Lp=Mt(Rl),Nw=m({},Rl,{dataTransfer:0}),kw=Mt(Nw),Mw=m({},Jr,{relatedTarget:0}),mu=Mt(Mw),Ow=m({},Gi,{animationName:0,elapsedTime:0,pseudoElement:0}),Lw=Mt(Ow),jw=m({},Gi,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),Rw=Mt(jw),Dw=m({},Gi,{data:0}),jp=Mt(Dw),Bw={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},zw={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Uw={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Hw(t){var r=this.nativeEvent;return r.getModifierState?r.getModifierState(t):(t=Uw[t])?!!r[t]:!1}function yu(){return Hw}var qw=m({},Jr,{key:function(t){if(t.key){var r=Bw[t.key]||t.key;if(r!=="Unidentified")return r}return t.type==="keypress"?(t=Ol(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?zw[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:yu,charCode:function(t){return t.type==="keypress"?Ol(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Ol(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),Iw=Mt(qw),$w=m({},Rl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Rp=Mt($w),Vw=m({},Jr,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:yu}),Gw=Mt(Vw),Kw=m({},Gi,{propertyName:0,elapsedTime:0,pseudoElement:0}),Xw=Mt(Kw),Fw=m({},Rl,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),Yw=Mt(Fw),Qw=m({},Gi,{newState:0,oldState:0}),Pw=Mt(Qw),Jw=[9,13,27,32],bu=Dn&&"CompositionEvent"in window,Wr=null;Dn&&"documentMode"in document&&(Wr=document.documentMode);var Zw=Dn&&"TextEvent"in window&&!Wr,Dp=Dn&&(!bu||Wr&&8<Wr&&11>=Wr),Bp=" ",zp=!1;function Up(t,r){switch(t){case"keyup":return Jw.indexOf(r.keyCode)!==-1;case"keydown":return r.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Hp(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Ds=!1;function Ww(t,r){switch(t){case"compositionend":return Hp(r);case"keypress":return r.which!==32?null:(zp=!0,Bp);case"textInput":return t=r.data,t===Bp&&zp?null:t;default:return null}}function e1(t,r){if(Ds)return t==="compositionend"||!bu&&Up(t,r)?(t=Mp(),Ml=du=li=null,Ds=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(r.ctrlKey||r.altKey||r.metaKey)||r.ctrlKey&&r.altKey){if(r.char&&1<r.char.length)return r.char;if(r.which)return String.fromCharCode(r.which)}return null;case"compositionend":return Dp&&r.locale!=="ko"?null:r.data;default:return null}}var t1={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function qp(t){var r=t&&t.nodeName&&t.nodeName.toLowerCase();return r==="input"?!!t1[t.type]:r==="textarea"}function Ip(t,r,l,u){js?Rs?Rs.push(u):Rs=[u]:js=u,r=To(r,"onChange"),0<r.length&&(l=new jl("onChange","change",null,l,u),t.push({event:l,listeners:r}))}var ea=null,ta=null;function n1(t){Ey(t,0)}function Dl(t){var r=Yr(t);if(xp(r))return t}function $p(t,r){if(t==="change")return r}var Vp=!1;if(Dn){var vu;if(Dn){var Su="oninput"in document;if(!Su){var Gp=document.createElement("div");Gp.setAttribute("oninput","return;"),Su=typeof Gp.oninput=="function"}vu=Su}else vu=!1;Vp=vu&&(!document.documentMode||9<document.documentMode)}function Kp(){ea&&(ea.detachEvent("onpropertychange",Xp),ta=ea=null)}function Xp(t){if(t.propertyName==="value"&&Dl(ta)){var r=[];Ip(r,ta,t,uu(t)),kp(n1,r)}}function i1(t,r,l){t==="focusin"?(Kp(),ea=r,ta=l,ea.attachEvent("onpropertychange",Xp)):t==="focusout"&&Kp()}function s1(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return Dl(ta)}function r1(t,r){if(t==="click")return Dl(r)}function a1(t,r){if(t==="input"||t==="change")return Dl(r)}function l1(t,r){return t===r&&(t!==0||1/t===1/r)||t!==t&&r!==r}var Vt=typeof Object.is=="function"?Object.is:l1;function na(t,r){if(Vt(t,r))return!0;if(typeof t!="object"||t===null||typeof r!="object"||r===null)return!1;var l=Object.keys(t),u=Object.keys(r);if(l.length!==u.length)return!1;for(u=0;u<l.length;u++){var d=l[u];if(!Gr.call(r,d)||!Vt(t[d],r[d]))return!1}return!0}function Fp(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Yp(t,r){var l=Fp(t);t=0;for(var u;l;){if(l.nodeType===3){if(u=t+l.textContent.length,t<=r&&u>=r)return{node:l,offset:r-t};t=u}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=Fp(l)}}function Qp(t,r){return t&&r?t===r?!0:t&&t.nodeType===3?!1:r&&r.nodeType===3?Qp(t,r.parentNode):"contains"in t?t.contains(r):t.compareDocumentPosition?!!(t.compareDocumentPosition(r)&16):!1:!1}function Pp(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var r=Nl(t.document);r instanceof t.HTMLIFrameElement;){try{var l=typeof r.contentWindow.location.href=="string"}catch{l=!1}if(l)t=r.contentWindow;else break;r=Nl(t.document)}return r}function wu(t){var r=t&&t.nodeName&&t.nodeName.toLowerCase();return r&&(r==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||r==="textarea"||t.contentEditable==="true")}var o1=Dn&&"documentMode"in document&&11>=document.documentMode,Bs=null,xu=null,ia=null,Eu=!1;function Jp(t,r,l){var u=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Eu||Bs==null||Bs!==Nl(u)||(u=Bs,"selectionStart"in u&&wu(u)?u={start:u.selectionStart,end:u.selectionEnd}:(u=(u.ownerDocument&&u.ownerDocument.defaultView||window).getSelection(),u={anchorNode:u.anchorNode,anchorOffset:u.anchorOffset,focusNode:u.focusNode,focusOffset:u.focusOffset}),ia&&na(ia,u)||(ia=u,u=To(xu,"onSelect"),0<u.length&&(r=new jl("onSelect","select",null,r,l),t.push({event:r,listeners:u}),r.target=Bs)))}function Ki(t,r){var l={};return l[t.toLowerCase()]=r.toLowerCase(),l["Webkit"+t]="webkit"+r,l["Moz"+t]="moz"+r,l}var zs={animationend:Ki("Animation","AnimationEnd"),animationiteration:Ki("Animation","AnimationIteration"),animationstart:Ki("Animation","AnimationStart"),transitionrun:Ki("Transition","TransitionRun"),transitionstart:Ki("Transition","TransitionStart"),transitioncancel:Ki("Transition","TransitionCancel"),transitionend:Ki("Transition","TransitionEnd")},Tu={},Zp={};Dn&&(Zp=document.createElement("div").style,"AnimationEvent"in window||(delete zs.animationend.animation,delete zs.animationiteration.animation,delete zs.animationstart.animation),"TransitionEvent"in window||delete zs.transitionend.transition);function Xi(t){if(Tu[t])return Tu[t];if(!zs[t])return t;var r=zs[t],l;for(l in r)if(r.hasOwnProperty(l)&&l in Zp)return Tu[t]=r[l];return t}var Wp=Xi("animationend"),eg=Xi("animationiteration"),tg=Xi("animationstart"),c1=Xi("transitionrun"),u1=Xi("transitionstart"),f1=Xi("transitioncancel"),ng=Xi("transitionend"),ig=new Map,_u="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");_u.push("scrollEnd");function mn(t,r){ig.set(t,r),Vi(r,[t])}var Bl=typeof reportError=="function"?reportError:function(t){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var r=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t=="object"&&t!==null&&typeof t.message=="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(r))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",t);return}console.error(t)},en=[],Us=0,Au=0;function zl(){for(var t=Us,r=Au=Us=0;r<t;){var l=en[r];en[r++]=null;var u=en[r];en[r++]=null;var d=en[r];en[r++]=null;var g=en[r];if(en[r++]=null,u!==null&&d!==null){var b=u.pending;b===null?d.next=d:(d.next=b.next,b.next=d),u.pending=d}g!==0&&sg(l,d,g)}}function Ul(t,r,l,u){en[Us++]=t,en[Us++]=r,en[Us++]=l,en[Us++]=u,Au|=u,t.lanes|=u,t=t.alternate,t!==null&&(t.lanes|=u)}function Cu(t,r,l,u){return Ul(t,r,l,u),Hl(t)}function Fi(t,r){return Ul(t,null,null,r),Hl(t)}function sg(t,r,l){t.lanes|=l;var u=t.alternate;u!==null&&(u.lanes|=l);for(var d=!1,g=t.return;g!==null;)g.childLanes|=l,u=g.alternate,u!==null&&(u.childLanes|=l),g.tag===22&&(t=g.stateNode,t===null||t._visibility&1||(d=!0)),t=g,g=g.return;return t.tag===3?(g=t.stateNode,d&&r!==null&&(d=31-at(l),t=g.hiddenUpdates,u=t[d],u===null?t[d]=[r]:u.push(r),r.lane=l|536870912),g):null}function Hl(t){if(50<_a)throw _a=0,zf=null,Error(s(185));for(var r=t.return;r!==null;)t=r,r=t.return;return t.tag===3?t.stateNode:null}var Hs={};function h1(t,r,l,u){this.tag=t,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=r,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=u,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Gt(t,r,l,u){return new h1(t,r,l,u)}function Nu(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Bn(t,r){var l=t.alternate;return l===null?(l=Gt(t.tag,r,t.key,t.mode),l.elementType=t.elementType,l.type=t.type,l.stateNode=t.stateNode,l.alternate=t,t.alternate=l):(l.pendingProps=r,l.type=t.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=t.flags&65011712,l.childLanes=t.childLanes,l.lanes=t.lanes,l.child=t.child,l.memoizedProps=t.memoizedProps,l.memoizedState=t.memoizedState,l.updateQueue=t.updateQueue,r=t.dependencies,l.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext},l.sibling=t.sibling,l.index=t.index,l.ref=t.ref,l.refCleanup=t.refCleanup,l}function rg(t,r){t.flags&=65011714;var l=t.alternate;return l===null?(t.childLanes=0,t.lanes=r,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=l.childLanes,t.lanes=l.lanes,t.child=l.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=l.memoizedProps,t.memoizedState=l.memoizedState,t.updateQueue=l.updateQueue,t.type=l.type,r=l.dependencies,t.dependencies=r===null?null:{lanes:r.lanes,firstContext:r.firstContext}),t}function ql(t,r,l,u,d,g){var b=0;if(u=t,typeof t=="function")Nu(t)&&(b=1);else if(typeof t=="string")b=yx(t,l,ee.current)?26:t==="html"||t==="head"||t==="body"?27:5;else e:switch(t){case L:return t=Gt(31,l,r,d),t.elementType=L,t.lanes=g,t;case x:return Yi(l.children,d,g,r);case E:b=8,d|=24;break;case A:return t=Gt(12,l,r,d|2),t.elementType=A,t.lanes=g,t;case $:return t=Gt(13,l,r,d),t.elementType=$,t.lanes=g,t;case z:return t=Gt(19,l,r,d),t.elementType=z,t.lanes=g,t;default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case B:b=10;break e;case N:b=9;break e;case V:b=11;break e;case Q:b=14;break e;case H:b=16,u=null;break e}b=29,l=Error(s(130,t===null?"null":typeof t,"")),u=null}return r=Gt(b,l,r,d),r.elementType=t,r.type=u,r.lanes=g,r}function Yi(t,r,l,u){return t=Gt(7,t,u,r),t.lanes=l,t}function ku(t,r,l){return t=Gt(6,t,null,r),t.lanes=l,t}function ag(t){var r=Gt(18,null,null,0);return r.stateNode=t,r}function Mu(t,r,l){return r=Gt(4,t.children!==null?t.children:[],t.key,r),r.lanes=l,r.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},r}var lg=new WeakMap;function tn(t,r){if(typeof t=="object"&&t!==null){var l=lg.get(t);return l!==void 0?l:(r={value:t,source:r,stack:wl(r)},lg.set(t,r),r)}return{value:t,source:r,stack:wl(r)}}var qs=[],Is=0,Il=null,sa=0,nn=[],sn=0,oi=null,En=1,Tn="";function zn(t,r){qs[Is++]=sa,qs[Is++]=Il,Il=t,sa=r}function og(t,r,l){nn[sn++]=En,nn[sn++]=Tn,nn[sn++]=oi,oi=t;var u=En;t=Tn;var d=32-at(u)-1;u&=~(1<<d),l+=1;var g=32-at(r)+d;if(30<g){var b=d-d%5;g=(u&(1<<b)-1).toString(32),u>>=b,d-=b,En=1<<32-at(r)+d|l<<d|u,Tn=g+t}else En=1<<g|l<<d|u,Tn=t}function Ou(t){t.return!==null&&(zn(t,1),og(t,1,0))}function Lu(t){for(;t===Il;)Il=qs[--Is],qs[Is]=null,sa=qs[--Is],qs[Is]=null;for(;t===oi;)oi=nn[--sn],nn[sn]=null,Tn=nn[--sn],nn[sn]=null,En=nn[--sn],nn[sn]=null}function cg(t,r){nn[sn++]=En,nn[sn++]=Tn,nn[sn++]=oi,En=r.id,Tn=r.overflow,oi=t}var ut=null,De=null,Se=!1,ci=null,rn=!1,ju=Error(s(519));function ui(t){var r=Error(s(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw ra(tn(r,t)),ju}function ug(t){var r=t.stateNode,l=t.type,u=t.memoizedProps;switch(r[ct]=t,r[kt]=u,l){case"dialog":me("cancel",r),me("close",r);break;case"iframe":case"object":case"embed":me("load",r);break;case"video":case"audio":for(l=0;l<Ca.length;l++)me(Ca[l],r);break;case"source":me("error",r);break;case"img":case"image":case"link":me("error",r),me("load",r);break;case"details":me("toggle",r);break;case"input":me("invalid",r),Ep(r,u.value,u.defaultValue,u.checked,u.defaultChecked,u.type,u.name,!0);break;case"select":me("invalid",r);break;case"textarea":me("invalid",r),_p(r,u.value,u.defaultValue,u.children)}l=u.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||r.textContent===""+l||u.suppressHydrationWarning===!0||Cy(r.textContent,l)?(u.popover!=null&&(me("beforetoggle",r),me("toggle",r)),u.onScroll!=null&&me("scroll",r),u.onScrollEnd!=null&&me("scrollend",r),u.onClick!=null&&(r.onclick=Rn),r=!0):r=!1,r||ui(t,!0)}function fg(t){for(ut=t.return;ut;)switch(ut.tag){case 5:case 31:case 13:rn=!1;return;case 27:case 3:rn=!0;return;default:ut=ut.return}}function $s(t){if(t!==ut)return!1;if(!Se)return fg(t),Se=!0,!1;var r=t.tag,l;if((l=r!==3&&r!==27)&&((l=r===5)&&(l=t.type,l=!(l!=="form"&&l!=="button")||Zf(t.type,t.memoizedProps)),l=!l),l&&De&&ui(t),fg(t),r===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(s(317));De=By(t)}else if(r===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(s(317));De=By(t)}else r===27?(r=De,Ti(t.type)?(t=ih,ih=null,De=t):De=r):De=ut?ln(t.stateNode.nextSibling):null;return!0}function Qi(){De=ut=null,Se=!1}function Ru(){var t=ci;return t!==null&&(Rt===null?Rt=t:Rt.push.apply(Rt,t),ci=null),t}function ra(t){ci===null?ci=[t]:ci.push(t)}var Du=k(null),Pi=null,Un=null;function fi(t,r,l){Z(Du,r._currentValue),r._currentValue=l}function Hn(t){t._currentValue=Du.current,X(Du)}function Bu(t,r,l){for(;t!==null;){var u=t.alternate;if((t.childLanes&r)!==r?(t.childLanes|=r,u!==null&&(u.childLanes|=r)):u!==null&&(u.childLanes&r)!==r&&(u.childLanes|=r),t===l)break;t=t.return}}function zu(t,r,l,u){var d=t.child;for(d!==null&&(d.return=t);d!==null;){var g=d.dependencies;if(g!==null){var b=d.child;g=g.firstContext;e:for(;g!==null;){var _=g;g=d;for(var C=0;C<r.length;C++)if(_.context===r[C]){g.lanes|=l,_=g.alternate,_!==null&&(_.lanes|=l),Bu(g.return,l,t),u||(b=null);break e}g=_.next}}else if(d.tag===18){if(b=d.return,b===null)throw Error(s(341));b.lanes|=l,g=b.alternate,g!==null&&(g.lanes|=l),Bu(b,l,t),b=null}else b=d.child;if(b!==null)b.return=d;else for(b=d;b!==null;){if(b===t){b=null;break}if(d=b.sibling,d!==null){d.return=b.return,b=d;break}b=b.return}d=b}}function Vs(t,r,l,u){t=null;for(var d=r,g=!1;d!==null;){if(!g){if((d.flags&524288)!==0)g=!0;else if((d.flags&262144)!==0)break}if(d.tag===10){var b=d.alternate;if(b===null)throw Error(s(387));if(b=b.memoizedProps,b!==null){var _=d.type;Vt(d.pendingProps.value,b.value)||(t!==null?t.push(_):t=[_])}}else if(d===Ee.current){if(b=d.alternate,b===null)throw Error(s(387));b.memoizedState.memoizedState!==d.memoizedState.memoizedState&&(t!==null?t.push(La):t=[La])}d=d.return}t!==null&&zu(r,t,l,u),r.flags|=262144}function $l(t){for(t=t.firstContext;t!==null;){if(!Vt(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function Ji(t){Pi=t,Un=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function ft(t){return hg(Pi,t)}function Vl(t,r){return Pi===null&&Ji(t),hg(t,r)}function hg(t,r){var l=r._currentValue;if(r={context:r,memoizedValue:l,next:null},Un===null){if(t===null)throw Error(s(308));Un=r,t.dependencies={lanes:0,firstContext:r},t.flags|=524288}else Un=Un.next=r;return l}var d1=typeof AbortController<"u"?AbortController:function(){var t=[],r=this.signal={aborted:!1,addEventListener:function(l,u){t.push(u)}};this.abort=function(){r.aborted=!0,t.forEach(function(l){return l()})}},p1=n.unstable_scheduleCallback,g1=n.unstable_NormalPriority,Ze={$$typeof:B,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function Uu(){return{controller:new d1,data:new Map,refCount:0}}function aa(t){t.refCount--,t.refCount===0&&p1(g1,function(){t.controller.abort()})}var la=null,Hu=0,Gs=0,Ks=null;function m1(t,r){if(la===null){var l=la=[];Hu=0,Gs=Vf(),Ks={status:"pending",value:void 0,then:function(u){l.push(u)}}}return Hu++,r.then(dg,dg),r}function dg(){if(--Hu===0&&la!==null){Ks!==null&&(Ks.status="fulfilled");var t=la;la=null,Gs=0,Ks=null;for(var r=0;r<t.length;r++)(0,t[r])()}}function y1(t,r){var l=[],u={status:"pending",value:null,reason:null,then:function(d){l.push(d)}};return t.then(function(){u.status="fulfilled",u.value=r;for(var d=0;d<l.length;d++)(0,l[d])(r)},function(d){for(u.status="rejected",u.reason=d,d=0;d<l.length;d++)(0,l[d])(void 0)}),u}var pg=q.S;q.S=function(t,r){Jm=Je(),typeof r=="object"&&r!==null&&typeof r.then=="function"&&m1(t,r),pg!==null&&pg(t,r)};var Zi=k(null);function qu(){var t=Zi.current;return t!==null?t:je.pooledCache}function Gl(t,r){r===null?Z(Zi,Zi.current):Z(Zi,r.pool)}function gg(){var t=qu();return t===null?null:{parent:Ze._currentValue,pool:t}}var Xs=Error(s(460)),Iu=Error(s(474)),Kl=Error(s(542)),Xl={then:function(){}};function mg(t){return t=t.status,t==="fulfilled"||t==="rejected"}function yg(t,r,l){switch(l=t[l],l===void 0?t.push(r):l!==r&&(r.then(Rn,Rn),r=l),r.status){case"fulfilled":return r.value;case"rejected":throw t=r.reason,vg(t),t;default:if(typeof r.status=="string")r.then(Rn,Rn);else{if(t=je,t!==null&&100<t.shellSuspendCounter)throw Error(s(482));t=r,t.status="pending",t.then(function(u){if(r.status==="pending"){var d=r;d.status="fulfilled",d.value=u}},function(u){if(r.status==="pending"){var d=r;d.status="rejected",d.reason=u}})}switch(r.status){case"fulfilled":return r.value;case"rejected":throw t=r.reason,vg(t),t}throw es=r,Xs}}function Wi(t){try{var r=t._init;return r(t._payload)}catch(l){throw l!==null&&typeof l=="object"&&typeof l.then=="function"?(es=l,Xs):l}}var es=null;function bg(){if(es===null)throw Error(s(459));var t=es;return es=null,t}function vg(t){if(t===Xs||t===Kl)throw Error(s(483))}var Fs=null,oa=0;function Fl(t){var r=oa;return oa+=1,Fs===null&&(Fs=[]),yg(Fs,t,r)}function ca(t,r){r=r.props.ref,t.ref=r!==void 0?r:null}function Yl(t,r){throw r.$$typeof===v?Error(s(525)):(t=Object.prototype.toString.call(r),Error(s(31,t==="[object Object]"?"object with keys {"+Object.keys(r).join(", ")+"}":t)))}function Sg(t){function r(O,M){if(t){var j=O.deletions;j===null?(O.deletions=[M],O.flags|=16):j.push(M)}}function l(O,M){if(!t)return null;for(;M!==null;)r(O,M),M=M.sibling;return null}function u(O){for(var M=new Map;O!==null;)O.key!==null?M.set(O.key,O):M.set(O.index,O),O=O.sibling;return M}function d(O,M){return O=Bn(O,M),O.index=0,O.sibling=null,O}function g(O,M,j){return O.index=j,t?(j=O.alternate,j!==null?(j=j.index,j<M?(O.flags|=67108866,M):j):(O.flags|=67108866,M)):(O.flags|=1048576,M)}function b(O){return t&&O.alternate===null&&(O.flags|=67108866),O}function _(O,M,j,F){return M===null||M.tag!==6?(M=ku(j,O.mode,F),M.return=O,M):(M=d(M,j),M.return=O,M)}function C(O,M,j,F){var re=j.type;return re===x?K(O,M,j.props.children,F,j.key):M!==null&&(M.elementType===re||typeof re=="object"&&re!==null&&re.$$typeof===H&&Wi(re)===M.type)?(M=d(M,j.props),ca(M,j),M.return=O,M):(M=ql(j.type,j.key,j.props,null,O.mode,F),ca(M,j),M.return=O,M)}function R(O,M,j,F){return M===null||M.tag!==4||M.stateNode.containerInfo!==j.containerInfo||M.stateNode.implementation!==j.implementation?(M=Mu(j,O.mode,F),M.return=O,M):(M=d(M,j.children||[]),M.return=O,M)}function K(O,M,j,F,re){return M===null||M.tag!==7?(M=Yi(j,O.mode,F,re),M.return=O,M):(M=d(M,j),M.return=O,M)}function Y(O,M,j){if(typeof M=="string"&&M!==""||typeof M=="number"||typeof M=="bigint")return M=ku(""+M,O.mode,j),M.return=O,M;if(typeof M=="object"&&M!==null){switch(M.$$typeof){case S:return j=ql(M.type,M.key,M.props,null,O.mode,j),ca(j,M),j.return=O,j;case T:return M=Mu(M,O.mode,j),M.return=O,M;case H:return M=Wi(M),Y(O,M,j)}if(Ce(M)||G(M))return M=Yi(M,O.mode,j,null),M.return=O,M;if(typeof M.then=="function")return Y(O,Fl(M),j);if(M.$$typeof===B)return Y(O,Vl(O,M),j);Yl(O,M)}return null}function D(O,M,j,F){var re=M!==null?M.key:null;if(typeof j=="string"&&j!==""||typeof j=="number"||typeof j=="bigint")return re!==null?null:_(O,M,""+j,F);if(typeof j=="object"&&j!==null){switch(j.$$typeof){case S:return j.key===re?C(O,M,j,F):null;case T:return j.key===re?R(O,M,j,F):null;case H:return j=Wi(j),D(O,M,j,F)}if(Ce(j)||G(j))return re!==null?null:K(O,M,j,F,null);if(typeof j.then=="function")return D(O,M,Fl(j),F);if(j.$$typeof===B)return D(O,M,Vl(O,j),F);Yl(O,j)}return null}function I(O,M,j,F,re){if(typeof F=="string"&&F!==""||typeof F=="number"||typeof F=="bigint")return O=O.get(j)||null,_(M,O,""+F,re);if(typeof F=="object"&&F!==null){switch(F.$$typeof){case S:return O=O.get(F.key===null?j:F.key)||null,C(M,O,F,re);case T:return O=O.get(F.key===null?j:F.key)||null,R(M,O,F,re);case H:return F=Wi(F),I(O,M,j,F,re)}if(Ce(F)||G(F))return O=O.get(j)||null,K(M,O,F,re,null);if(typeof F.then=="function")return I(O,M,j,Fl(F),re);if(F.$$typeof===B)return I(O,M,j,Vl(M,F),re);Yl(M,F)}return null}function te(O,M,j,F){for(var re=null,Te=null,ie=M,pe=M=0,be=null;ie!==null&&pe<j.length;pe++){ie.index>pe?(be=ie,ie=null):be=ie.sibling;var _e=D(O,ie,j[pe],F);if(_e===null){ie===null&&(ie=be);break}t&&ie&&_e.alternate===null&&r(O,ie),M=g(_e,M,pe),Te===null?re=_e:Te.sibling=_e,Te=_e,ie=be}if(pe===j.length)return l(O,ie),Se&&zn(O,pe),re;if(ie===null){for(;pe<j.length;pe++)ie=Y(O,j[pe],F),ie!==null&&(M=g(ie,M,pe),Te===null?re=ie:Te.sibling=ie,Te=ie);return Se&&zn(O,pe),re}for(ie=u(ie);pe<j.length;pe++)be=I(ie,O,pe,j[pe],F),be!==null&&(t&&be.alternate!==null&&ie.delete(be.key===null?pe:be.key),M=g(be,M,pe),Te===null?re=be:Te.sibling=be,Te=be);return t&&ie.forEach(function(ki){return r(O,ki)}),Se&&zn(O,pe),re}function oe(O,M,j,F){if(j==null)throw Error(s(151));for(var re=null,Te=null,ie=M,pe=M=0,be=null,_e=j.next();ie!==null&&!_e.done;pe++,_e=j.next()){ie.index>pe?(be=ie,ie=null):be=ie.sibling;var ki=D(O,ie,_e.value,F);if(ki===null){ie===null&&(ie=be);break}t&&ie&&ki.alternate===null&&r(O,ie),M=g(ki,M,pe),Te===null?re=ki:Te.sibling=ki,Te=ki,ie=be}if(_e.done)return l(O,ie),Se&&zn(O,pe),re;if(ie===null){for(;!_e.done;pe++,_e=j.next())_e=Y(O,_e.value,F),_e!==null&&(M=g(_e,M,pe),Te===null?re=_e:Te.sibling=_e,Te=_e);return Se&&zn(O,pe),re}for(ie=u(ie);!_e.done;pe++,_e=j.next())_e=I(ie,O,pe,_e.value,F),_e!==null&&(t&&_e.alternate!==null&&ie.delete(_e.key===null?pe:_e.key),M=g(_e,M,pe),Te===null?re=_e:Te.sibling=_e,Te=_e);return t&&ie.forEach(function(Nx){return r(O,Nx)}),Se&&zn(O,pe),re}function Le(O,M,j,F){if(typeof j=="object"&&j!==null&&j.type===x&&j.key===null&&(j=j.props.children),typeof j=="object"&&j!==null){switch(j.$$typeof){case S:e:{for(var re=j.key;M!==null;){if(M.key===re){if(re=j.type,re===x){if(M.tag===7){l(O,M.sibling),F=d(M,j.props.children),F.return=O,O=F;break e}}else if(M.elementType===re||typeof re=="object"&&re!==null&&re.$$typeof===H&&Wi(re)===M.type){l(O,M.sibling),F=d(M,j.props),ca(F,j),F.return=O,O=F;break e}l(O,M);break}else r(O,M);M=M.sibling}j.type===x?(F=Yi(j.props.children,O.mode,F,j.key),F.return=O,O=F):(F=ql(j.type,j.key,j.props,null,O.mode,F),ca(F,j),F.return=O,O=F)}return b(O);case T:e:{for(re=j.key;M!==null;){if(M.key===re)if(M.tag===4&&M.stateNode.containerInfo===j.containerInfo&&M.stateNode.implementation===j.implementation){l(O,M.sibling),F=d(M,j.children||[]),F.return=O,O=F;break e}else{l(O,M);break}else r(O,M);M=M.sibling}F=Mu(j,O.mode,F),F.return=O,O=F}return b(O);case H:return j=Wi(j),Le(O,M,j,F)}if(Ce(j))return te(O,M,j,F);if(G(j)){if(re=G(j),typeof re!="function")throw Error(s(150));return j=re.call(j),oe(O,M,j,F)}if(typeof j.then=="function")return Le(O,M,Fl(j),F);if(j.$$typeof===B)return Le(O,M,Vl(O,j),F);Yl(O,j)}return typeof j=="string"&&j!==""||typeof j=="number"||typeof j=="bigint"?(j=""+j,M!==null&&M.tag===6?(l(O,M.sibling),F=d(M,j),F.return=O,O=F):(l(O,M),F=ku(j,O.mode,F),F.return=O,O=F),b(O)):l(O,M)}return function(O,M,j,F){try{oa=0;var re=Le(O,M,j,F);return Fs=null,re}catch(ie){if(ie===Xs||ie===Kl)throw ie;var Te=Gt(29,ie,null,O.mode);return Te.lanes=F,Te.return=O,Te}finally{}}}var ts=Sg(!0),wg=Sg(!1),hi=!1;function $u(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Vu(t,r){t=t.updateQueue,r.updateQueue===t&&(r.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function di(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function pi(t,r,l){var u=t.updateQueue;if(u===null)return null;if(u=u.shared,(Ae&2)!==0){var d=u.pending;return d===null?r.next=r:(r.next=d.next,d.next=r),u.pending=r,r=Hl(t),sg(t,null,l),r}return Ul(t,u,r,l),Hl(t)}function ua(t,r,l){if(r=r.updateQueue,r!==null&&(r=r.shared,(l&4194048)!==0)){var u=r.lanes;u&=t.pendingLanes,l|=u,r.lanes=l,hp(t,l)}}function Gu(t,r){var l=t.updateQueue,u=t.alternate;if(u!==null&&(u=u.updateQueue,l===u)){var d=null,g=null;if(l=l.firstBaseUpdate,l!==null){do{var b={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};g===null?d=g=b:g=g.next=b,l=l.next}while(l!==null);g===null?d=g=r:g=g.next=r}else d=g=r;l={baseState:u.baseState,firstBaseUpdate:d,lastBaseUpdate:g,shared:u.shared,callbacks:u.callbacks},t.updateQueue=l;return}t=l.lastBaseUpdate,t===null?l.firstBaseUpdate=r:t.next=r,l.lastBaseUpdate=r}var Ku=!1;function fa(){if(Ku){var t=Ks;if(t!==null)throw t}}function ha(t,r,l,u){Ku=!1;var d=t.updateQueue;hi=!1;var g=d.firstBaseUpdate,b=d.lastBaseUpdate,_=d.shared.pending;if(_!==null){d.shared.pending=null;var C=_,R=C.next;C.next=null,b===null?g=R:b.next=R,b=C;var K=t.alternate;K!==null&&(K=K.updateQueue,_=K.lastBaseUpdate,_!==b&&(_===null?K.firstBaseUpdate=R:_.next=R,K.lastBaseUpdate=C))}if(g!==null){var Y=d.baseState;b=0,K=R=C=null,_=g;do{var D=_.lane&-536870913,I=D!==_.lane;if(I?(ye&D)===D:(u&D)===D){D!==0&&D===Gs&&(Ku=!0),K!==null&&(K=K.next={lane:0,tag:_.tag,payload:_.payload,callback:null,next:null});e:{var te=t,oe=_;D=r;var Le=l;switch(oe.tag){case 1:if(te=oe.payload,typeof te=="function"){Y=te.call(Le,Y,D);break e}Y=te;break e;case 3:te.flags=te.flags&-65537|128;case 0:if(te=oe.payload,D=typeof te=="function"?te.call(Le,Y,D):te,D==null)break e;Y=m({},Y,D);break e;case 2:hi=!0}}D=_.callback,D!==null&&(t.flags|=64,I&&(t.flags|=8192),I=d.callbacks,I===null?d.callbacks=[D]:I.push(D))}else I={lane:D,tag:_.tag,payload:_.payload,callback:_.callback,next:null},K===null?(R=K=I,C=Y):K=K.next=I,b|=D;if(_=_.next,_===null){if(_=d.shared.pending,_===null)break;I=_,_=I.next,I.next=null,d.lastBaseUpdate=I,d.shared.pending=null}}while(!0);K===null&&(C=Y),d.baseState=C,d.firstBaseUpdate=R,d.lastBaseUpdate=K,g===null&&(d.shared.lanes=0),vi|=b,t.lanes=b,t.memoizedState=Y}}function xg(t,r){if(typeof t!="function")throw Error(s(191,t));t.call(r)}function Eg(t,r){var l=t.callbacks;if(l!==null)for(t.callbacks=null,t=0;t<l.length;t++)xg(l[t],r)}var Ys=k(null),Ql=k(0);function Tg(t,r){t=Yn,Z(Ql,t),Z(Ys,r),Yn=t|r.baseLanes}function Xu(){Z(Ql,Yn),Z(Ys,Ys.current)}function Fu(){Yn=Ql.current,X(Ys),X(Ql)}var Kt=k(null),an=null;function gi(t){var r=t.alternate;Z(Xe,Xe.current&1),Z(Kt,t),an===null&&(r===null||Ys.current!==null||r.memoizedState!==null)&&(an=t)}function Yu(t){Z(Xe,Xe.current),Z(Kt,t),an===null&&(an=t)}function _g(t){t.tag===22?(Z(Xe,Xe.current),Z(Kt,t),an===null&&(an=t)):mi()}function mi(){Z(Xe,Xe.current),Z(Kt,Kt.current)}function Xt(t){X(Kt),an===t&&(an=null),X(Xe)}var Xe=k(0);function Pl(t){for(var r=t;r!==null;){if(r.tag===13){var l=r.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||th(l)||nh(l)))return r}else if(r.tag===19&&(r.memoizedProps.revealOrder==="forwards"||r.memoizedProps.revealOrder==="backwards"||r.memoizedProps.revealOrder==="unstable_legacy-backwards"||r.memoizedProps.revealOrder==="together")){if((r.flags&128)!==0)return r}else if(r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return null;r=r.return}r.sibling.return=r.return,r=r.sibling}return null}var qn=0,he=null,Me=null,We=null,Jl=!1,Qs=!1,ns=!1,Zl=0,da=0,Ps=null,b1=0;function Ge(){throw Error(s(321))}function Qu(t,r){if(r===null)return!1;for(var l=0;l<r.length&&l<t.length;l++)if(!Vt(t[l],r[l]))return!1;return!0}function Pu(t,r,l,u,d,g){return qn=g,he=r,r.memoizedState=null,r.updateQueue=null,r.lanes=0,q.H=t===null||t.memoizedState===null?om:hf,ns=!1,g=l(u,d),ns=!1,Qs&&(g=Cg(r,l,u,d)),Ag(t),g}function Ag(t){q.H=ma;var r=Me!==null&&Me.next!==null;if(qn=0,We=Me=he=null,Jl=!1,da=0,Ps=null,r)throw Error(s(300));t===null||et||(t=t.dependencies,t!==null&&$l(t)&&(et=!0))}function Cg(t,r,l,u){he=t;var d=0;do{if(Qs&&(Ps=null),da=0,Qs=!1,25<=d)throw Error(s(301));if(d+=1,We=Me=null,t.updateQueue!=null){var g=t.updateQueue;g.lastEffect=null,g.events=null,g.stores=null,g.memoCache!=null&&(g.memoCache.index=0)}q.H=cm,g=r(l,u)}while(Qs);return g}function v1(){var t=q.H,r=t.useState()[0];return r=typeof r.then=="function"?pa(r):r,t=t.useState()[0],(Me!==null?Me.memoizedState:null)!==t&&(he.flags|=1024),r}function Ju(){var t=Zl!==0;return Zl=0,t}function Zu(t,r,l){r.updateQueue=t.updateQueue,r.flags&=-2053,t.lanes&=~l}function Wu(t){if(Jl){for(t=t.memoizedState;t!==null;){var r=t.queue;r!==null&&(r.pending=null),t=t.next}Jl=!1}qn=0,We=Me=he=null,Qs=!1,da=Zl=0,Ps=null}function _t(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return We===null?he.memoizedState=We=t:We=We.next=t,We}function Fe(){if(Me===null){var t=he.alternate;t=t!==null?t.memoizedState:null}else t=Me.next;var r=We===null?he.memoizedState:We.next;if(r!==null)We=r,Me=t;else{if(t===null)throw he.alternate===null?Error(s(467)):Error(s(310));Me=t,t={memoizedState:Me.memoizedState,baseState:Me.baseState,baseQueue:Me.baseQueue,queue:Me.queue,next:null},We===null?he.memoizedState=We=t:We=We.next=t}return We}function Wl(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function pa(t){var r=da;return da+=1,Ps===null&&(Ps=[]),t=yg(Ps,t,r),r=he,(We===null?r.memoizedState:We.next)===null&&(r=r.alternate,q.H=r===null||r.memoizedState===null?om:hf),t}function eo(t){if(t!==null&&typeof t=="object"){if(typeof t.then=="function")return pa(t);if(t.$$typeof===B)return ft(t)}throw Error(s(438,String(t)))}function ef(t){var r=null,l=he.updateQueue;if(l!==null&&(r=l.memoCache),r==null){var u=he.alternate;u!==null&&(u=u.updateQueue,u!==null&&(u=u.memoCache,u!=null&&(r={data:u.data.map(function(d){return d.slice()}),index:0})))}if(r==null&&(r={data:[],index:0}),l===null&&(l=Wl(),he.updateQueue=l),l.memoCache=r,l=r.data[r.index],l===void 0)for(l=r.data[r.index]=Array(t),u=0;u<t;u++)l[u]=ne;return r.index++,l}function In(t,r){return typeof r=="function"?r(t):r}function to(t){var r=Fe();return tf(r,Me,t)}function tf(t,r,l){var u=t.queue;if(u===null)throw Error(s(311));u.lastRenderedReducer=l;var d=t.baseQueue,g=u.pending;if(g!==null){if(d!==null){var b=d.next;d.next=g.next,g.next=b}r.baseQueue=d=g,u.pending=null}if(g=t.baseState,d===null)t.memoizedState=g;else{r=d.next;var _=b=null,C=null,R=r,K=!1;do{var Y=R.lane&-536870913;if(Y!==R.lane?(ye&Y)===Y:(qn&Y)===Y){var D=R.revertLane;if(D===0)C!==null&&(C=C.next={lane:0,revertLane:0,gesture:null,action:R.action,hasEagerState:R.hasEagerState,eagerState:R.eagerState,next:null}),Y===Gs&&(K=!0);else if((qn&D)===D){R=R.next,D===Gs&&(K=!0);continue}else Y={lane:0,revertLane:R.revertLane,gesture:null,action:R.action,hasEagerState:R.hasEagerState,eagerState:R.eagerState,next:null},C===null?(_=C=Y,b=g):C=C.next=Y,he.lanes|=D,vi|=D;Y=R.action,ns&&l(g,Y),g=R.hasEagerState?R.eagerState:l(g,Y)}else D={lane:Y,revertLane:R.revertLane,gesture:R.gesture,action:R.action,hasEagerState:R.hasEagerState,eagerState:R.eagerState,next:null},C===null?(_=C=D,b=g):C=C.next=D,he.lanes|=Y,vi|=Y;R=R.next}while(R!==null&&R!==r);if(C===null?b=g:C.next=_,!Vt(g,t.memoizedState)&&(et=!0,K&&(l=Ks,l!==null)))throw l;t.memoizedState=g,t.baseState=b,t.baseQueue=C,u.lastRenderedState=g}return d===null&&(u.lanes=0),[t.memoizedState,u.dispatch]}function nf(t){var r=Fe(),l=r.queue;if(l===null)throw Error(s(311));l.lastRenderedReducer=t;var u=l.dispatch,d=l.pending,g=r.memoizedState;if(d!==null){l.pending=null;var b=d=d.next;do g=t(g,b.action),b=b.next;while(b!==d);Vt(g,r.memoizedState)||(et=!0),r.memoizedState=g,r.baseQueue===null&&(r.baseState=g),l.lastRenderedState=g}return[g,u]}function Ng(t,r,l){var u=he,d=Fe(),g=Se;if(g){if(l===void 0)throw Error(s(407));l=l()}else l=r();var b=!Vt((Me||d).memoizedState,l);if(b&&(d.memoizedState=l,et=!0),d=d.queue,af(Og.bind(null,u,d,t),[t]),d.getSnapshot!==r||b||We!==null&&We.memoizedState.tag&1){if(u.flags|=2048,Js(9,{destroy:void 0},Mg.bind(null,u,d,l,r),null),je===null)throw Error(s(349));g||(qn&127)!==0||kg(u,r,l)}return l}function kg(t,r,l){t.flags|=16384,t={getSnapshot:r,value:l},r=he.updateQueue,r===null?(r=Wl(),he.updateQueue=r,r.stores=[t]):(l=r.stores,l===null?r.stores=[t]:l.push(t))}function Mg(t,r,l,u){r.value=l,r.getSnapshot=u,Lg(r)&&jg(t)}function Og(t,r,l){return l(function(){Lg(r)&&jg(t)})}function Lg(t){var r=t.getSnapshot;t=t.value;try{var l=r();return!Vt(t,l)}catch{return!0}}function jg(t){var r=Fi(t,2);r!==null&&Dt(r,t,2)}function sf(t){var r=_t();if(typeof t=="function"){var l=t;if(t=l(),ns){Jt(!0);try{l()}finally{Jt(!1)}}}return r.memoizedState=r.baseState=t,r.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:In,lastRenderedState:t},r}function Rg(t,r,l,u){return t.baseState=l,tf(t,Me,typeof u=="function"?u:In)}function S1(t,r,l,u,d){if(so(t))throw Error(s(485));if(t=r.action,t!==null){var g={payload:d,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(b){g.listeners.push(b)}};q.T!==null?l(!0):g.isTransition=!1,u(g),l=r.pending,l===null?(g.next=r.pending=g,Dg(r,g)):(g.next=l.next,r.pending=l.next=g)}}function Dg(t,r){var l=r.action,u=r.payload,d=t.state;if(r.isTransition){var g=q.T,b={};q.T=b;try{var _=l(d,u),C=q.S;C!==null&&C(b,_),Bg(t,r,_)}catch(R){rf(t,r,R)}finally{g!==null&&b.types!==null&&(g.types=b.types),q.T=g}}else try{g=l(d,u),Bg(t,r,g)}catch(R){rf(t,r,R)}}function Bg(t,r,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(u){zg(t,r,u)},function(u){return rf(t,r,u)}):zg(t,r,l)}function zg(t,r,l){r.status="fulfilled",r.value=l,Ug(r),t.state=l,r=t.pending,r!==null&&(l=r.next,l===r?t.pending=null:(l=l.next,r.next=l,Dg(t,l)))}function rf(t,r,l){var u=t.pending;if(t.pending=null,u!==null){u=u.next;do r.status="rejected",r.reason=l,Ug(r),r=r.next;while(r!==u)}t.action=null}function Ug(t){t=t.listeners;for(var r=0;r<t.length;r++)(0,t[r])()}function Hg(t,r){return r}function qg(t,r){if(Se){var l=je.formState;if(l!==null){e:{var u=he;if(Se){if(De){t:{for(var d=De,g=rn;d.nodeType!==8;){if(!g){d=null;break t}if(d=ln(d.nextSibling),d===null){d=null;break t}}g=d.data,d=g==="F!"||g==="F"?d:null}if(d){De=ln(d.nextSibling),u=d.data==="F!";break e}}ui(u)}u=!1}u&&(r=l[0])}}return l=_t(),l.memoizedState=l.baseState=r,u={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Hg,lastRenderedState:r},l.queue=u,l=rm.bind(null,he,u),u.dispatch=l,u=sf(!1),g=ff.bind(null,he,!1,u.queue),u=_t(),d={state:r,dispatch:null,action:t,pending:null},u.queue=d,l=S1.bind(null,he,d,g,l),d.dispatch=l,u.memoizedState=t,[r,l,!1]}function Ig(t){var r=Fe();return $g(r,Me,t)}function $g(t,r,l){if(r=tf(t,r,Hg)[0],t=to(In)[0],typeof r=="object"&&r!==null&&typeof r.then=="function")try{var u=pa(r)}catch(b){throw b===Xs?Kl:b}else u=r;r=Fe();var d=r.queue,g=d.dispatch;return l!==r.memoizedState&&(he.flags|=2048,Js(9,{destroy:void 0},w1.bind(null,d,l),null)),[u,g,t]}function w1(t,r){t.action=r}function Vg(t){var r=Fe(),l=Me;if(l!==null)return $g(r,l,t);Fe(),r=r.memoizedState,l=Fe();var u=l.queue.dispatch;return l.memoizedState=t,[r,u,!1]}function Js(t,r,l,u){return t={tag:t,create:l,deps:u,inst:r,next:null},r=he.updateQueue,r===null&&(r=Wl(),he.updateQueue=r),l=r.lastEffect,l===null?r.lastEffect=t.next=t:(u=l.next,l.next=t,t.next=u,r.lastEffect=t),t}function Gg(){return Fe().memoizedState}function no(t,r,l,u){var d=_t();he.flags|=t,d.memoizedState=Js(1|r,{destroy:void 0},l,u===void 0?null:u)}function io(t,r,l,u){var d=Fe();u=u===void 0?null:u;var g=d.memoizedState.inst;Me!==null&&u!==null&&Qu(u,Me.memoizedState.deps)?d.memoizedState=Js(r,g,l,u):(he.flags|=t,d.memoizedState=Js(1|r,g,l,u))}function Kg(t,r){no(8390656,8,t,r)}function af(t,r){io(2048,8,t,r)}function x1(t){he.flags|=4;var r=he.updateQueue;if(r===null)r=Wl(),he.updateQueue=r,r.events=[t];else{var l=r.events;l===null?r.events=[t]:l.push(t)}}function Xg(t){var r=Fe().memoizedState;return x1({ref:r,nextImpl:t}),function(){if((Ae&2)!==0)throw Error(s(440));return r.impl.apply(void 0,arguments)}}function Fg(t,r){return io(4,2,t,r)}function Yg(t,r){return io(4,4,t,r)}function Qg(t,r){if(typeof r=="function"){t=t();var l=r(t);return function(){typeof l=="function"?l():r(null)}}if(r!=null)return t=t(),r.current=t,function(){r.current=null}}function Pg(t,r,l){l=l!=null?l.concat([t]):null,io(4,4,Qg.bind(null,r,t),l)}function lf(){}function Jg(t,r){var l=Fe();r=r===void 0?null:r;var u=l.memoizedState;return r!==null&&Qu(r,u[1])?u[0]:(l.memoizedState=[t,r],t)}function Zg(t,r){var l=Fe();r=r===void 0?null:r;var u=l.memoizedState;if(r!==null&&Qu(r,u[1]))return u[0];if(u=t(),ns){Jt(!0);try{t()}finally{Jt(!1)}}return l.memoizedState=[u,r],u}function of(t,r,l){return l===void 0||(qn&1073741824)!==0&&(ye&261930)===0?t.memoizedState=r:(t.memoizedState=l,t=Wm(),he.lanes|=t,vi|=t,l)}function Wg(t,r,l,u){return Vt(l,r)?l:Ys.current!==null?(t=of(t,l,u),Vt(t,r)||(et=!0),t):(qn&42)===0||(qn&1073741824)!==0&&(ye&261930)===0?(et=!0,t.memoizedState=l):(t=Wm(),he.lanes|=t,vi|=t,r)}function em(t,r,l,u,d){var g=J.p;J.p=g!==0&&8>g?g:8;var b=q.T,_={};q.T=_,ff(t,!1,r,l);try{var C=d(),R=q.S;if(R!==null&&R(_,C),C!==null&&typeof C=="object"&&typeof C.then=="function"){var K=y1(C,u);ga(t,r,K,Qt(t))}else ga(t,r,u,Qt(t))}catch(Y){ga(t,r,{then:function(){},status:"rejected",reason:Y},Qt())}finally{J.p=g,b!==null&&_.types!==null&&(b.types=_.types),q.T=b}}function E1(){}function cf(t,r,l,u){if(t.tag!==5)throw Error(s(476));var d=tm(t).queue;em(t,d,r,se,l===null?E1:function(){return nm(t),l(u)})}function tm(t){var r=t.memoizedState;if(r!==null)return r;r={memoizedState:se,baseState:se,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:In,lastRenderedState:se},next:null};var l={};return r.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:In,lastRenderedState:l},next:null},t.memoizedState=r,t=t.alternate,t!==null&&(t.memoizedState=r),r}function nm(t){var r=tm(t);r.next===null&&(r=t.alternate.memoizedState),ga(t,r.next.queue,{},Qt())}function uf(){return ft(La)}function im(){return Fe().memoizedState}function sm(){return Fe().memoizedState}function T1(t){for(var r=t.return;r!==null;){switch(r.tag){case 24:case 3:var l=Qt();t=di(l);var u=pi(r,t,l);u!==null&&(Dt(u,r,l),ua(u,r,l)),r={cache:Uu()},t.payload=r;return}r=r.return}}function _1(t,r,l){var u=Qt();l={lane:u,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},so(t)?am(r,l):(l=Cu(t,r,l,u),l!==null&&(Dt(l,t,u),lm(l,r,u)))}function rm(t,r,l){var u=Qt();ga(t,r,l,u)}function ga(t,r,l,u){var d={lane:u,revertLane:0,gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null};if(so(t))am(r,d);else{var g=t.alternate;if(t.lanes===0&&(g===null||g.lanes===0)&&(g=r.lastRenderedReducer,g!==null))try{var b=r.lastRenderedState,_=g(b,l);if(d.hasEagerState=!0,d.eagerState=_,Vt(_,b))return Ul(t,r,d,0),je===null&&zl(),!1}catch{}finally{}if(l=Cu(t,r,d,u),l!==null)return Dt(l,t,u),lm(l,r,u),!0}return!1}function ff(t,r,l,u){if(u={lane:2,revertLane:Vf(),gesture:null,action:u,hasEagerState:!1,eagerState:null,next:null},so(t)){if(r)throw Error(s(479))}else r=Cu(t,l,u,2),r!==null&&Dt(r,t,2)}function so(t){var r=t.alternate;return t===he||r!==null&&r===he}function am(t,r){Qs=Jl=!0;var l=t.pending;l===null?r.next=r:(r.next=l.next,l.next=r),t.pending=r}function lm(t,r,l){if((l&4194048)!==0){var u=r.lanes;u&=t.pendingLanes,l|=u,r.lanes=l,hp(t,l)}}var ma={readContext:ft,use:eo,useCallback:Ge,useContext:Ge,useEffect:Ge,useImperativeHandle:Ge,useLayoutEffect:Ge,useInsertionEffect:Ge,useMemo:Ge,useReducer:Ge,useRef:Ge,useState:Ge,useDebugValue:Ge,useDeferredValue:Ge,useTransition:Ge,useSyncExternalStore:Ge,useId:Ge,useHostTransitionStatus:Ge,useFormState:Ge,useActionState:Ge,useOptimistic:Ge,useMemoCache:Ge,useCacheRefresh:Ge};ma.useEffectEvent=Ge;var om={readContext:ft,use:eo,useCallback:function(t,r){return _t().memoizedState=[t,r===void 0?null:r],t},useContext:ft,useEffect:Kg,useImperativeHandle:function(t,r,l){l=l!=null?l.concat([t]):null,no(4194308,4,Qg.bind(null,r,t),l)},useLayoutEffect:function(t,r){return no(4194308,4,t,r)},useInsertionEffect:function(t,r){no(4,2,t,r)},useMemo:function(t,r){var l=_t();r=r===void 0?null:r;var u=t();if(ns){Jt(!0);try{t()}finally{Jt(!1)}}return l.memoizedState=[u,r],u},useReducer:function(t,r,l){var u=_t();if(l!==void 0){var d=l(r);if(ns){Jt(!0);try{l(r)}finally{Jt(!1)}}}else d=r;return u.memoizedState=u.baseState=d,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:d},u.queue=t,t=t.dispatch=_1.bind(null,he,t),[u.memoizedState,t]},useRef:function(t){var r=_t();return t={current:t},r.memoizedState=t},useState:function(t){t=sf(t);var r=t.queue,l=rm.bind(null,he,r);return r.dispatch=l,[t.memoizedState,l]},useDebugValue:lf,useDeferredValue:function(t,r){var l=_t();return of(l,t,r)},useTransition:function(){var t=sf(!1);return t=em.bind(null,he,t.queue,!0,!1),_t().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,r,l){var u=he,d=_t();if(Se){if(l===void 0)throw Error(s(407));l=l()}else{if(l=r(),je===null)throw Error(s(349));(ye&127)!==0||kg(u,r,l)}d.memoizedState=l;var g={value:l,getSnapshot:r};return d.queue=g,Kg(Og.bind(null,u,g,t),[t]),u.flags|=2048,Js(9,{destroy:void 0},Mg.bind(null,u,g,l,r),null),l},useId:function(){var t=_t(),r=je.identifierPrefix;if(Se){var l=Tn,u=En;l=(u&~(1<<32-at(u)-1)).toString(32)+l,r="_"+r+"R_"+l,l=Zl++,0<l&&(r+="H"+l.toString(32)),r+="_"}else l=b1++,r="_"+r+"r_"+l.toString(32)+"_";return t.memoizedState=r},useHostTransitionStatus:uf,useFormState:qg,useActionState:qg,useOptimistic:function(t){var r=_t();r.memoizedState=r.baseState=t;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return r.queue=l,r=ff.bind(null,he,!0,l),l.dispatch=r,[t,r]},useMemoCache:ef,useCacheRefresh:function(){return _t().memoizedState=T1.bind(null,he)},useEffectEvent:function(t){var r=_t(),l={impl:t};return r.memoizedState=l,function(){if((Ae&2)!==0)throw Error(s(440));return l.impl.apply(void 0,arguments)}}},hf={readContext:ft,use:eo,useCallback:Jg,useContext:ft,useEffect:af,useImperativeHandle:Pg,useInsertionEffect:Fg,useLayoutEffect:Yg,useMemo:Zg,useReducer:to,useRef:Gg,useState:function(){return to(In)},useDebugValue:lf,useDeferredValue:function(t,r){var l=Fe();return Wg(l,Me.memoizedState,t,r)},useTransition:function(){var t=to(In)[0],r=Fe().memoizedState;return[typeof t=="boolean"?t:pa(t),r]},useSyncExternalStore:Ng,useId:im,useHostTransitionStatus:uf,useFormState:Ig,useActionState:Ig,useOptimistic:function(t,r){var l=Fe();return Rg(l,Me,t,r)},useMemoCache:ef,useCacheRefresh:sm};hf.useEffectEvent=Xg;var cm={readContext:ft,use:eo,useCallback:Jg,useContext:ft,useEffect:af,useImperativeHandle:Pg,useInsertionEffect:Fg,useLayoutEffect:Yg,useMemo:Zg,useReducer:nf,useRef:Gg,useState:function(){return nf(In)},useDebugValue:lf,useDeferredValue:function(t,r){var l=Fe();return Me===null?of(l,t,r):Wg(l,Me.memoizedState,t,r)},useTransition:function(){var t=nf(In)[0],r=Fe().memoizedState;return[typeof t=="boolean"?t:pa(t),r]},useSyncExternalStore:Ng,useId:im,useHostTransitionStatus:uf,useFormState:Vg,useActionState:Vg,useOptimistic:function(t,r){var l=Fe();return Me!==null?Rg(l,Me,t,r):(l.baseState=t,[t,l.queue.dispatch])},useMemoCache:ef,useCacheRefresh:sm};cm.useEffectEvent=Xg;function df(t,r,l,u){r=t.memoizedState,l=l(u,r),l=l==null?r:m({},r,l),t.memoizedState=l,t.lanes===0&&(t.updateQueue.baseState=l)}var pf={enqueueSetState:function(t,r,l){t=t._reactInternals;var u=Qt(),d=di(u);d.payload=r,l!=null&&(d.callback=l),r=pi(t,d,u),r!==null&&(Dt(r,t,u),ua(r,t,u))},enqueueReplaceState:function(t,r,l){t=t._reactInternals;var u=Qt(),d=di(u);d.tag=1,d.payload=r,l!=null&&(d.callback=l),r=pi(t,d,u),r!==null&&(Dt(r,t,u),ua(r,t,u))},enqueueForceUpdate:function(t,r){t=t._reactInternals;var l=Qt(),u=di(l);u.tag=2,r!=null&&(u.callback=r),r=pi(t,u,l),r!==null&&(Dt(r,t,l),ua(r,t,l))}};function um(t,r,l,u,d,g,b){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(u,g,b):r.prototype&&r.prototype.isPureReactComponent?!na(l,u)||!na(d,g):!0}function fm(t,r,l,u){t=r.state,typeof r.componentWillReceiveProps=="function"&&r.componentWillReceiveProps(l,u),typeof r.UNSAFE_componentWillReceiveProps=="function"&&r.UNSAFE_componentWillReceiveProps(l,u),r.state!==t&&pf.enqueueReplaceState(r,r.state,null)}function is(t,r){var l=r;if("ref"in r){l={};for(var u in r)u!=="ref"&&(l[u]=r[u])}if(t=t.defaultProps){l===r&&(l=m({},l));for(var d in t)l[d]===void 0&&(l[d]=t[d])}return l}function hm(t){Bl(t)}function dm(t){console.error(t)}function pm(t){Bl(t)}function ro(t,r){try{var l=t.onUncaughtError;l(r.value,{componentStack:r.stack})}catch(u){setTimeout(function(){throw u})}}function gm(t,r,l){try{var u=t.onCaughtError;u(l.value,{componentStack:l.stack,errorBoundary:r.tag===1?r.stateNode:null})}catch(d){setTimeout(function(){throw d})}}function gf(t,r,l){return l=di(l),l.tag=3,l.payload={element:null},l.callback=function(){ro(t,r)},l}function mm(t){return t=di(t),t.tag=3,t}function ym(t,r,l,u){var d=l.type.getDerivedStateFromError;if(typeof d=="function"){var g=u.value;t.payload=function(){return d(g)},t.callback=function(){gm(r,l,u)}}var b=l.stateNode;b!==null&&typeof b.componentDidCatch=="function"&&(t.callback=function(){gm(r,l,u),typeof d!="function"&&(Si===null?Si=new Set([this]):Si.add(this));var _=u.stack;this.componentDidCatch(u.value,{componentStack:_!==null?_:""})})}function A1(t,r,l,u,d){if(l.flags|=32768,u!==null&&typeof u=="object"&&typeof u.then=="function"){if(r=l.alternate,r!==null&&Vs(r,l,d,!0),l=Kt.current,l!==null){switch(l.tag){case 31:case 13:return an===null?bo():l.alternate===null&&Ke===0&&(Ke=3),l.flags&=-257,l.flags|=65536,l.lanes=d,u===Xl?l.flags|=16384:(r=l.updateQueue,r===null?l.updateQueue=new Set([u]):r.add(u),qf(t,u,d)),!1;case 22:return l.flags|=65536,u===Xl?l.flags|=16384:(r=l.updateQueue,r===null?(r={transitions:null,markerInstances:null,retryQueue:new Set([u])},l.updateQueue=r):(l=r.retryQueue,l===null?r.retryQueue=new Set([u]):l.add(u)),qf(t,u,d)),!1}throw Error(s(435,l.tag))}return qf(t,u,d),bo(),!1}if(Se)return r=Kt.current,r!==null?((r.flags&65536)===0&&(r.flags|=256),r.flags|=65536,r.lanes=d,u!==ju&&(t=Error(s(422),{cause:u}),ra(tn(t,l)))):(u!==ju&&(r=Error(s(423),{cause:u}),ra(tn(r,l))),t=t.current.alternate,t.flags|=65536,d&=-d,t.lanes|=d,u=tn(u,l),d=gf(t.stateNode,u,d),Gu(t,d),Ke!==4&&(Ke=2)),!1;var g=Error(s(520),{cause:u});if(g=tn(g,l),Ta===null?Ta=[g]:Ta.push(g),Ke!==4&&(Ke=2),r===null)return!0;u=tn(u,l),l=r;do{switch(l.tag){case 3:return l.flags|=65536,t=d&-d,l.lanes|=t,t=gf(l.stateNode,u,t),Gu(l,t),!1;case 1:if(r=l.type,g=l.stateNode,(l.flags&128)===0&&(typeof r.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(Si===null||!Si.has(g))))return l.flags|=65536,d&=-d,l.lanes|=d,d=mm(d),ym(d,t,l,u),Gu(l,d),!1}l=l.return}while(l!==null);return!1}var mf=Error(s(461)),et=!1;function ht(t,r,l,u){r.child=t===null?wg(r,null,l,u):ts(r,t.child,l,u)}function bm(t,r,l,u,d){l=l.render;var g=r.ref;if("ref"in u){var b={};for(var _ in u)_!=="ref"&&(b[_]=u[_])}else b=u;return Ji(r),u=Pu(t,r,l,b,g,d),_=Ju(),t!==null&&!et?(Zu(t,r,d),$n(t,r,d)):(Se&&_&&Ou(r),r.flags|=1,ht(t,r,u,d),r.child)}function vm(t,r,l,u,d){if(t===null){var g=l.type;return typeof g=="function"&&!Nu(g)&&g.defaultProps===void 0&&l.compare===null?(r.tag=15,r.type=g,Sm(t,r,g,u,d)):(t=ql(l.type,null,u,r,r.mode,d),t.ref=r.ref,t.return=r,r.child=t)}if(g=t.child,!Tf(t,d)){var b=g.memoizedProps;if(l=l.compare,l=l!==null?l:na,l(b,u)&&t.ref===r.ref)return $n(t,r,d)}return r.flags|=1,t=Bn(g,u),t.ref=r.ref,t.return=r,r.child=t}function Sm(t,r,l,u,d){if(t!==null){var g=t.memoizedProps;if(na(g,u)&&t.ref===r.ref)if(et=!1,r.pendingProps=u=g,Tf(t,d))(t.flags&131072)!==0&&(et=!0);else return r.lanes=t.lanes,$n(t,r,d)}return yf(t,r,l,u,d)}function wm(t,r,l,u){var d=u.children,g=t!==null?t.memoizedState:null;if(t===null&&r.stateNode===null&&(r.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),u.mode==="hidden"){if((r.flags&128)!==0){if(g=g!==null?g.baseLanes|l:l,t!==null){for(u=r.child=t.child,d=0;u!==null;)d=d|u.lanes|u.childLanes,u=u.sibling;u=d&~g}else u=0,r.child=null;return xm(t,r,g,l,u)}if((l&536870912)!==0)r.memoizedState={baseLanes:0,cachePool:null},t!==null&&Gl(r,g!==null?g.cachePool:null),g!==null?Tg(r,g):Xu(),_g(r);else return u=r.lanes=536870912,xm(t,r,g!==null?g.baseLanes|l:l,l,u)}else g!==null?(Gl(r,g.cachePool),Tg(r,g),mi(),r.memoizedState=null):(t!==null&&Gl(r,null),Xu(),mi());return ht(t,r,d,l),r.child}function ya(t,r){return t!==null&&t.tag===22||r.stateNode!==null||(r.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.sibling}function xm(t,r,l,u,d){var g=qu();return g=g===null?null:{parent:Ze._currentValue,pool:g},r.memoizedState={baseLanes:l,cachePool:g},t!==null&&Gl(r,null),Xu(),_g(r),t!==null&&Vs(t,r,u,!0),r.childLanes=d,null}function ao(t,r){return r=oo({mode:r.mode,children:r.children},t.mode),r.ref=t.ref,t.child=r,r.return=t,r}function Em(t,r,l){return ts(r,t.child,null,l),t=ao(r,r.pendingProps),t.flags|=2,Xt(r),r.memoizedState=null,t}function C1(t,r,l){var u=r.pendingProps,d=(r.flags&128)!==0;if(r.flags&=-129,t===null){if(Se){if(u.mode==="hidden")return t=ao(r,u),r.lanes=536870912,ya(null,t);if(Yu(r),(t=De)?(t=Dy(t,rn),t=t!==null&&t.data==="&"?t:null,t!==null&&(r.memoizedState={dehydrated:t,treeContext:oi!==null?{id:En,overflow:Tn}:null,retryLane:536870912,hydrationErrors:null},l=ag(t),l.return=r,r.child=l,ut=r,De=null)):t=null,t===null)throw ui(r);return r.lanes=536870912,null}return ao(r,u)}var g=t.memoizedState;if(g!==null){var b=g.dehydrated;if(Yu(r),d)if(r.flags&256)r.flags&=-257,r=Em(t,r,l);else if(r.memoizedState!==null)r.child=t.child,r.flags|=128,r=null;else throw Error(s(558));else if(et||Vs(t,r,l,!1),d=(l&t.childLanes)!==0,et||d){if(u=je,u!==null&&(b=dp(u,l),b!==0&&b!==g.retryLane))throw g.retryLane=b,Fi(t,b),Dt(u,t,b),mf;bo(),r=Em(t,r,l)}else t=g.treeContext,De=ln(b.nextSibling),ut=r,Se=!0,ci=null,rn=!1,t!==null&&cg(r,t),r=ao(r,u),r.flags|=4096;return r}return t=Bn(t.child,{mode:u.mode,children:u.children}),t.ref=r.ref,r.child=t,t.return=r,t}function lo(t,r){var l=r.ref;if(l===null)t!==null&&t.ref!==null&&(r.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(s(284));(t===null||t.ref!==l)&&(r.flags|=4194816)}}function yf(t,r,l,u,d){return Ji(r),l=Pu(t,r,l,u,void 0,d),u=Ju(),t!==null&&!et?(Zu(t,r,d),$n(t,r,d)):(Se&&u&&Ou(r),r.flags|=1,ht(t,r,l,d),r.child)}function Tm(t,r,l,u,d,g){return Ji(r),r.updateQueue=null,l=Cg(r,u,l,d),Ag(t),u=Ju(),t!==null&&!et?(Zu(t,r,g),$n(t,r,g)):(Se&&u&&Ou(r),r.flags|=1,ht(t,r,l,g),r.child)}function _m(t,r,l,u,d){if(Ji(r),r.stateNode===null){var g=Hs,b=l.contextType;typeof b=="object"&&b!==null&&(g=ft(b)),g=new l(u,g),r.memoizedState=g.state!==null&&g.state!==void 0?g.state:null,g.updater=pf,r.stateNode=g,g._reactInternals=r,g=r.stateNode,g.props=u,g.state=r.memoizedState,g.refs={},$u(r),b=l.contextType,g.context=typeof b=="object"&&b!==null?ft(b):Hs,g.state=r.memoizedState,b=l.getDerivedStateFromProps,typeof b=="function"&&(df(r,l,b,u),g.state=r.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof g.getSnapshotBeforeUpdate=="function"||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(b=g.state,typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount(),b!==g.state&&pf.enqueueReplaceState(g,g.state,null),ha(r,u,g,d),fa(),g.state=r.memoizedState),typeof g.componentDidMount=="function"&&(r.flags|=4194308),u=!0}else if(t===null){g=r.stateNode;var _=r.memoizedProps,C=is(l,_);g.props=C;var R=g.context,K=l.contextType;b=Hs,typeof K=="object"&&K!==null&&(b=ft(K));var Y=l.getDerivedStateFromProps;K=typeof Y=="function"||typeof g.getSnapshotBeforeUpdate=="function",_=r.pendingProps!==_,K||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(_||R!==b)&&fm(r,g,u,b),hi=!1;var D=r.memoizedState;g.state=D,ha(r,u,g,d),fa(),R=r.memoizedState,_||D!==R||hi?(typeof Y=="function"&&(df(r,l,Y,u),R=r.memoizedState),(C=hi||um(r,l,C,u,D,R,b))?(K||typeof g.UNSAFE_componentWillMount!="function"&&typeof g.componentWillMount!="function"||(typeof g.componentWillMount=="function"&&g.componentWillMount(),typeof g.UNSAFE_componentWillMount=="function"&&g.UNSAFE_componentWillMount()),typeof g.componentDidMount=="function"&&(r.flags|=4194308)):(typeof g.componentDidMount=="function"&&(r.flags|=4194308),r.memoizedProps=u,r.memoizedState=R),g.props=u,g.state=R,g.context=b,u=C):(typeof g.componentDidMount=="function"&&(r.flags|=4194308),u=!1)}else{g=r.stateNode,Vu(t,r),b=r.memoizedProps,K=is(l,b),g.props=K,Y=r.pendingProps,D=g.context,R=l.contextType,C=Hs,typeof R=="object"&&R!==null&&(C=ft(R)),_=l.getDerivedStateFromProps,(R=typeof _=="function"||typeof g.getSnapshotBeforeUpdate=="function")||typeof g.UNSAFE_componentWillReceiveProps!="function"&&typeof g.componentWillReceiveProps!="function"||(b!==Y||D!==C)&&fm(r,g,u,C),hi=!1,D=r.memoizedState,g.state=D,ha(r,u,g,d),fa();var I=r.memoizedState;b!==Y||D!==I||hi||t!==null&&t.dependencies!==null&&$l(t.dependencies)?(typeof _=="function"&&(df(r,l,_,u),I=r.memoizedState),(K=hi||um(r,l,K,u,D,I,C)||t!==null&&t.dependencies!==null&&$l(t.dependencies))?(R||typeof g.UNSAFE_componentWillUpdate!="function"&&typeof g.componentWillUpdate!="function"||(typeof g.componentWillUpdate=="function"&&g.componentWillUpdate(u,I,C),typeof g.UNSAFE_componentWillUpdate=="function"&&g.UNSAFE_componentWillUpdate(u,I,C)),typeof g.componentDidUpdate=="function"&&(r.flags|=4),typeof g.getSnapshotBeforeUpdate=="function"&&(r.flags|=1024)):(typeof g.componentDidUpdate!="function"||b===t.memoizedProps&&D===t.memoizedState||(r.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||b===t.memoizedProps&&D===t.memoizedState||(r.flags|=1024),r.memoizedProps=u,r.memoizedState=I),g.props=u,g.state=I,g.context=C,u=K):(typeof g.componentDidUpdate!="function"||b===t.memoizedProps&&D===t.memoizedState||(r.flags|=4),typeof g.getSnapshotBeforeUpdate!="function"||b===t.memoizedProps&&D===t.memoizedState||(r.flags|=1024),u=!1)}return g=u,lo(t,r),u=(r.flags&128)!==0,g||u?(g=r.stateNode,l=u&&typeof l.getDerivedStateFromError!="function"?null:g.render(),r.flags|=1,t!==null&&u?(r.child=ts(r,t.child,null,d),r.child=ts(r,null,l,d)):ht(t,r,l,d),r.memoizedState=g.state,t=r.child):t=$n(t,r,d),t}function Am(t,r,l,u){return Qi(),r.flags|=256,ht(t,r,l,u),r.child}var bf={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function vf(t){return{baseLanes:t,cachePool:gg()}}function Sf(t,r,l){return t=t!==null?t.childLanes&~l:0,r&&(t|=Yt),t}function Cm(t,r,l){var u=r.pendingProps,d=!1,g=(r.flags&128)!==0,b;if((b=g)||(b=t!==null&&t.memoizedState===null?!1:(Xe.current&2)!==0),b&&(d=!0,r.flags&=-129),b=(r.flags&32)!==0,r.flags&=-33,t===null){if(Se){if(d?gi(r):mi(),(t=De)?(t=Dy(t,rn),t=t!==null&&t.data!=="&"?t:null,t!==null&&(r.memoizedState={dehydrated:t,treeContext:oi!==null?{id:En,overflow:Tn}:null,retryLane:536870912,hydrationErrors:null},l=ag(t),l.return=r,r.child=l,ut=r,De=null)):t=null,t===null)throw ui(r);return nh(t)?r.lanes=32:r.lanes=536870912,null}var _=u.children;return u=u.fallback,d?(mi(),d=r.mode,_=oo({mode:"hidden",children:_},d),u=Yi(u,d,l,null),_.return=r,u.return=r,_.sibling=u,r.child=_,u=r.child,u.memoizedState=vf(l),u.childLanes=Sf(t,b,l),r.memoizedState=bf,ya(null,u)):(gi(r),wf(r,_))}var C=t.memoizedState;if(C!==null&&(_=C.dehydrated,_!==null)){if(g)r.flags&256?(gi(r),r.flags&=-257,r=xf(t,r,l)):r.memoizedState!==null?(mi(),r.child=t.child,r.flags|=128,r=null):(mi(),_=u.fallback,d=r.mode,u=oo({mode:"visible",children:u.children},d),_=Yi(_,d,l,null),_.flags|=2,u.return=r,_.return=r,u.sibling=_,r.child=u,ts(r,t.child,null,l),u=r.child,u.memoizedState=vf(l),u.childLanes=Sf(t,b,l),r.memoizedState=bf,r=ya(null,u));else if(gi(r),nh(_)){if(b=_.nextSibling&&_.nextSibling.dataset,b)var R=b.dgst;b=R,u=Error(s(419)),u.stack="",u.digest=b,ra({value:u,source:null,stack:null}),r=xf(t,r,l)}else if(et||Vs(t,r,l,!1),b=(l&t.childLanes)!==0,et||b){if(b=je,b!==null&&(u=dp(b,l),u!==0&&u!==C.retryLane))throw C.retryLane=u,Fi(t,u),Dt(b,t,u),mf;th(_)||bo(),r=xf(t,r,l)}else th(_)?(r.flags|=192,r.child=t.child,r=null):(t=C.treeContext,De=ln(_.nextSibling),ut=r,Se=!0,ci=null,rn=!1,t!==null&&cg(r,t),r=wf(r,u.children),r.flags|=4096);return r}return d?(mi(),_=u.fallback,d=r.mode,C=t.child,R=C.sibling,u=Bn(C,{mode:"hidden",children:u.children}),u.subtreeFlags=C.subtreeFlags&65011712,R!==null?_=Bn(R,_):(_=Yi(_,d,l,null),_.flags|=2),_.return=r,u.return=r,u.sibling=_,r.child=u,ya(null,u),u=r.child,_=t.child.memoizedState,_===null?_=vf(l):(d=_.cachePool,d!==null?(C=Ze._currentValue,d=d.parent!==C?{parent:C,pool:C}:d):d=gg(),_={baseLanes:_.baseLanes|l,cachePool:d}),u.memoizedState=_,u.childLanes=Sf(t,b,l),r.memoizedState=bf,ya(t.child,u)):(gi(r),l=t.child,t=l.sibling,l=Bn(l,{mode:"visible",children:u.children}),l.return=r,l.sibling=null,t!==null&&(b=r.deletions,b===null?(r.deletions=[t],r.flags|=16):b.push(t)),r.child=l,r.memoizedState=null,l)}function wf(t,r){return r=oo({mode:"visible",children:r},t.mode),r.return=t,t.child=r}function oo(t,r){return t=Gt(22,t,null,r),t.lanes=0,t}function xf(t,r,l){return ts(r,t.child,null,l),t=wf(r,r.pendingProps.children),t.flags|=2,r.memoizedState=null,t}function Nm(t,r,l){t.lanes|=r;var u=t.alternate;u!==null&&(u.lanes|=r),Bu(t.return,r,l)}function Ef(t,r,l,u,d,g){var b=t.memoizedState;b===null?t.memoizedState={isBackwards:r,rendering:null,renderingStartTime:0,last:u,tail:l,tailMode:d,treeForkCount:g}:(b.isBackwards=r,b.rendering=null,b.renderingStartTime=0,b.last=u,b.tail=l,b.tailMode=d,b.treeForkCount=g)}function km(t,r,l){var u=r.pendingProps,d=u.revealOrder,g=u.tail;u=u.children;var b=Xe.current,_=(b&2)!==0;if(_?(b=b&1|2,r.flags|=128):b&=1,Z(Xe,b),ht(t,r,u,l),u=Se?sa:0,!_&&t!==null&&(t.flags&128)!==0)e:for(t=r.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&Nm(t,l,r);else if(t.tag===19)Nm(t,l,r);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===r)break e;for(;t.sibling===null;){if(t.return===null||t.return===r)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(d){case"forwards":for(l=r.child,d=null;l!==null;)t=l.alternate,t!==null&&Pl(t)===null&&(d=l),l=l.sibling;l=d,l===null?(d=r.child,r.child=null):(d=l.sibling,l.sibling=null),Ef(r,!1,d,l,g,u);break;case"backwards":case"unstable_legacy-backwards":for(l=null,d=r.child,r.child=null;d!==null;){if(t=d.alternate,t!==null&&Pl(t)===null){r.child=d;break}t=d.sibling,d.sibling=l,l=d,d=t}Ef(r,!0,l,null,g,u);break;case"together":Ef(r,!1,null,null,void 0,u);break;default:r.memoizedState=null}return r.child}function $n(t,r,l){if(t!==null&&(r.dependencies=t.dependencies),vi|=r.lanes,(l&r.childLanes)===0)if(t!==null){if(Vs(t,r,l,!1),(l&r.childLanes)===0)return null}else return null;if(t!==null&&r.child!==t.child)throw Error(s(153));if(r.child!==null){for(t=r.child,l=Bn(t,t.pendingProps),r.child=l,l.return=r;t.sibling!==null;)t=t.sibling,l=l.sibling=Bn(t,t.pendingProps),l.return=r;l.sibling=null}return r.child}function Tf(t,r){return(t.lanes&r)!==0?!0:(t=t.dependencies,!!(t!==null&&$l(t)))}function N1(t,r,l){switch(r.tag){case 3:ve(r,r.stateNode.containerInfo),fi(r,Ze,t.memoizedState.cache),Qi();break;case 27:case 5:Ln(r);break;case 4:ve(r,r.stateNode.containerInfo);break;case 10:fi(r,r.type,r.memoizedProps.value);break;case 31:if(r.memoizedState!==null)return r.flags|=128,Yu(r),null;break;case 13:var u=r.memoizedState;if(u!==null)return u.dehydrated!==null?(gi(r),r.flags|=128,null):(l&r.child.childLanes)!==0?Cm(t,r,l):(gi(r),t=$n(t,r,l),t!==null?t.sibling:null);gi(r);break;case 19:var d=(t.flags&128)!==0;if(u=(l&r.childLanes)!==0,u||(Vs(t,r,l,!1),u=(l&r.childLanes)!==0),d){if(u)return km(t,r,l);r.flags|=128}if(d=r.memoizedState,d!==null&&(d.rendering=null,d.tail=null,d.lastEffect=null),Z(Xe,Xe.current),u)break;return null;case 22:return r.lanes=0,wm(t,r,l,r.pendingProps);case 24:fi(r,Ze,t.memoizedState.cache)}return $n(t,r,l)}function Mm(t,r,l){if(t!==null)if(t.memoizedProps!==r.pendingProps)et=!0;else{if(!Tf(t,l)&&(r.flags&128)===0)return et=!1,N1(t,r,l);et=(t.flags&131072)!==0}else et=!1,Se&&(r.flags&1048576)!==0&&og(r,sa,r.index);switch(r.lanes=0,r.tag){case 16:e:{var u=r.pendingProps;if(t=Wi(r.elementType),r.type=t,typeof t=="function")Nu(t)?(u=is(t,u),r.tag=1,r=_m(null,r,t,u,l)):(r.tag=0,r=yf(null,r,t,u,l));else{if(t!=null){var d=t.$$typeof;if(d===V){r.tag=11,r=bm(null,r,t,u,l);break e}else if(d===Q){r.tag=14,r=vm(null,r,t,u,l);break e}}throw r=W(t)||t,Error(s(306,r,""))}}return r;case 0:return yf(t,r,r.type,r.pendingProps,l);case 1:return u=r.type,d=is(u,r.pendingProps),_m(t,r,u,d,l);case 3:e:{if(ve(r,r.stateNode.containerInfo),t===null)throw Error(s(387));u=r.pendingProps;var g=r.memoizedState;d=g.element,Vu(t,r),ha(r,u,null,l);var b=r.memoizedState;if(u=b.cache,fi(r,Ze,u),u!==g.cache&&zu(r,[Ze],l,!0),fa(),u=b.element,g.isDehydrated)if(g={element:u,isDehydrated:!1,cache:b.cache},r.updateQueue.baseState=g,r.memoizedState=g,r.flags&256){r=Am(t,r,u,l);break e}else if(u!==d){d=tn(Error(s(424)),r),ra(d),r=Am(t,r,u,l);break e}else{switch(t=r.stateNode.containerInfo,t.nodeType){case 9:t=t.body;break;default:t=t.nodeName==="HTML"?t.ownerDocument.body:t}for(De=ln(t.firstChild),ut=r,Se=!0,ci=null,rn=!0,l=wg(r,null,u,l),r.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(Qi(),u===d){r=$n(t,r,l);break e}ht(t,r,u,l)}r=r.child}return r;case 26:return lo(t,r),t===null?(l=Iy(r.type,null,r.pendingProps,null))?r.memoizedState=l:Se||(l=r.type,t=r.pendingProps,u=_o(de.current).createElement(l),u[ct]=r,u[kt]=t,dt(u,l,t),lt(u),r.stateNode=u):r.memoizedState=Iy(r.type,t.memoizedProps,r.pendingProps,t.memoizedState),null;case 27:return Ln(r),t===null&&Se&&(u=r.stateNode=Uy(r.type,r.pendingProps,de.current),ut=r,rn=!0,d=De,Ti(r.type)?(ih=d,De=ln(u.firstChild)):De=d),ht(t,r,r.pendingProps.children,l),lo(t,r),t===null&&(r.flags|=4194304),r.child;case 5:return t===null&&Se&&((d=u=De)&&(u=sx(u,r.type,r.pendingProps,rn),u!==null?(r.stateNode=u,ut=r,De=ln(u.firstChild),rn=!1,d=!0):d=!1),d||ui(r)),Ln(r),d=r.type,g=r.pendingProps,b=t!==null?t.memoizedProps:null,u=g.children,Zf(d,g)?u=null:b!==null&&Zf(d,b)&&(r.flags|=32),r.memoizedState!==null&&(d=Pu(t,r,v1,null,null,l),La._currentValue=d),lo(t,r),ht(t,r,u,l),r.child;case 6:return t===null&&Se&&((t=l=De)&&(l=rx(l,r.pendingProps,rn),l!==null?(r.stateNode=l,ut=r,De=null,t=!0):t=!1),t||ui(r)),null;case 13:return Cm(t,r,l);case 4:return ve(r,r.stateNode.containerInfo),u=r.pendingProps,t===null?r.child=ts(r,null,u,l):ht(t,r,u,l),r.child;case 11:return bm(t,r,r.type,r.pendingProps,l);case 7:return ht(t,r,r.pendingProps,l),r.child;case 8:return ht(t,r,r.pendingProps.children,l),r.child;case 12:return ht(t,r,r.pendingProps.children,l),r.child;case 10:return u=r.pendingProps,fi(r,r.type,u.value),ht(t,r,u.children,l),r.child;case 9:return d=r.type._context,u=r.pendingProps.children,Ji(r),d=ft(d),u=u(d),r.flags|=1,ht(t,r,u,l),r.child;case 14:return vm(t,r,r.type,r.pendingProps,l);case 15:return Sm(t,r,r.type,r.pendingProps,l);case 19:return km(t,r,l);case 31:return C1(t,r,l);case 22:return wm(t,r,l,r.pendingProps);case 24:return Ji(r),u=ft(Ze),t===null?(d=qu(),d===null&&(d=je,g=Uu(),d.pooledCache=g,g.refCount++,g!==null&&(d.pooledCacheLanes|=l),d=g),r.memoizedState={parent:u,cache:d},$u(r),fi(r,Ze,d)):((t.lanes&l)!==0&&(Vu(t,r),ha(r,null,null,l),fa()),d=t.memoizedState,g=r.memoizedState,d.parent!==u?(d={parent:u,cache:u},r.memoizedState=d,r.lanes===0&&(r.memoizedState=r.updateQueue.baseState=d),fi(r,Ze,u)):(u=g.cache,fi(r,Ze,u),u!==d.cache&&zu(r,[Ze],l,!0))),ht(t,r,r.pendingProps.children,l),r.child;case 29:throw r.pendingProps}throw Error(s(156,r.tag))}function Vn(t){t.flags|=4}function _f(t,r,l,u,d){if((r=(t.mode&32)!==0)&&(r=!1),r){if(t.flags|=16777216,(d&335544128)===d)if(t.stateNode.complete)t.flags|=8192;else if(iy())t.flags|=8192;else throw es=Xl,Iu}else t.flags&=-16777217}function Om(t,r){if(r.type!=="stylesheet"||(r.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!Xy(r))if(iy())t.flags|=8192;else throw es=Xl,Iu}function co(t,r){r!==null&&(t.flags|=4),t.flags&16384&&(r=t.tag!==22?up():536870912,t.lanes|=r,tr|=r)}function ba(t,r){if(!Se)switch(t.tailMode){case"hidden":r=t.tail;for(var l=null;r!==null;)r.alternate!==null&&(l=r),r=r.sibling;l===null?t.tail=null:l.sibling=null;break;case"collapsed":l=t.tail;for(var u=null;l!==null;)l.alternate!==null&&(u=l),l=l.sibling;u===null?r||t.tail===null?t.tail=null:t.tail.sibling=null:u.sibling=null}}function Be(t){var r=t.alternate!==null&&t.alternate.child===t.child,l=0,u=0;if(r)for(var d=t.child;d!==null;)l|=d.lanes|d.childLanes,u|=d.subtreeFlags&65011712,u|=d.flags&65011712,d.return=t,d=d.sibling;else for(d=t.child;d!==null;)l|=d.lanes|d.childLanes,u|=d.subtreeFlags,u|=d.flags,d.return=t,d=d.sibling;return t.subtreeFlags|=u,t.childLanes=l,r}function k1(t,r,l){var u=r.pendingProps;switch(Lu(r),r.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Be(r),null;case 1:return Be(r),null;case 3:return l=r.stateNode,u=null,t!==null&&(u=t.memoizedState.cache),r.memoizedState.cache!==u&&(r.flags|=2048),Hn(Ze),qe(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(t===null||t.child===null)&&($s(r)?Vn(r):t===null||t.memoizedState.isDehydrated&&(r.flags&256)===0||(r.flags|=1024,Ru())),Be(r),null;case 26:var d=r.type,g=r.memoizedState;return t===null?(Vn(r),g!==null?(Be(r),Om(r,g)):(Be(r),_f(r,d,null,u,l))):g?g!==t.memoizedState?(Vn(r),Be(r),Om(r,g)):(Be(r),r.flags&=-16777217):(t=t.memoizedProps,t!==u&&Vn(r),Be(r),_f(r,d,t,u,l)),null;case 27:if(ri(r),l=de.current,d=r.type,t!==null&&r.stateNode!=null)t.memoizedProps!==u&&Vn(r);else{if(!u){if(r.stateNode===null)throw Error(s(166));return Be(r),null}t=ee.current,$s(r)?ug(r):(t=Uy(d,u,l),r.stateNode=t,Vn(r))}return Be(r),null;case 5:if(ri(r),d=r.type,t!==null&&r.stateNode!=null)t.memoizedProps!==u&&Vn(r);else{if(!u){if(r.stateNode===null)throw Error(s(166));return Be(r),null}if(g=ee.current,$s(r))ug(r);else{var b=_o(de.current);switch(g){case 1:g=b.createElementNS("http://www.w3.org/2000/svg",d);break;case 2:g=b.createElementNS("http://www.w3.org/1998/Math/MathML",d);break;default:switch(d){case"svg":g=b.createElementNS("http://www.w3.org/2000/svg",d);break;case"math":g=b.createElementNS("http://www.w3.org/1998/Math/MathML",d);break;case"script":g=b.createElement("div"),g.innerHTML="<script><\/script>",g=g.removeChild(g.firstChild);break;case"select":g=typeof u.is=="string"?b.createElement("select",{is:u.is}):b.createElement("select"),u.multiple?g.multiple=!0:u.size&&(g.size=u.size);break;default:g=typeof u.is=="string"?b.createElement(d,{is:u.is}):b.createElement(d)}}g[ct]=r,g[kt]=u;e:for(b=r.child;b!==null;){if(b.tag===5||b.tag===6)g.appendChild(b.stateNode);else if(b.tag!==4&&b.tag!==27&&b.child!==null){b.child.return=b,b=b.child;continue}if(b===r)break e;for(;b.sibling===null;){if(b.return===null||b.return===r)break e;b=b.return}b.sibling.return=b.return,b=b.sibling}r.stateNode=g;e:switch(dt(g,d,u),d){case"button":case"input":case"select":case"textarea":u=!!u.autoFocus;break e;case"img":u=!0;break e;default:u=!1}u&&Vn(r)}}return Be(r),_f(r,r.type,t===null?null:t.memoizedProps,r.pendingProps,l),null;case 6:if(t&&r.stateNode!=null)t.memoizedProps!==u&&Vn(r);else{if(typeof u!="string"&&r.stateNode===null)throw Error(s(166));if(t=de.current,$s(r)){if(t=r.stateNode,l=r.memoizedProps,u=null,d=ut,d!==null)switch(d.tag){case 27:case 5:u=d.memoizedProps}t[ct]=r,t=!!(t.nodeValue===l||u!==null&&u.suppressHydrationWarning===!0||Cy(t.nodeValue,l)),t||ui(r,!0)}else t=_o(t).createTextNode(u),t[ct]=r,r.stateNode=t}return Be(r),null;case 31:if(l=r.memoizedState,t===null||t.memoizedState!==null){if(u=$s(r),l!==null){if(t===null){if(!u)throw Error(s(318));if(t=r.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(s(557));t[ct]=r}else Qi(),(r.flags&128)===0&&(r.memoizedState=null),r.flags|=4;Be(r),t=!1}else l=Ru(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=l),t=!0;if(!t)return r.flags&256?(Xt(r),r):(Xt(r),null);if((r.flags&128)!==0)throw Error(s(558))}return Be(r),null;case 13:if(u=r.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(d=$s(r),u!==null&&u.dehydrated!==null){if(t===null){if(!d)throw Error(s(318));if(d=r.memoizedState,d=d!==null?d.dehydrated:null,!d)throw Error(s(317));d[ct]=r}else Qi(),(r.flags&128)===0&&(r.memoizedState=null),r.flags|=4;Be(r),d=!1}else d=Ru(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=d),d=!0;if(!d)return r.flags&256?(Xt(r),r):(Xt(r),null)}return Xt(r),(r.flags&128)!==0?(r.lanes=l,r):(l=u!==null,t=t!==null&&t.memoizedState!==null,l&&(u=r.child,d=null,u.alternate!==null&&u.alternate.memoizedState!==null&&u.alternate.memoizedState.cachePool!==null&&(d=u.alternate.memoizedState.cachePool.pool),g=null,u.memoizedState!==null&&u.memoizedState.cachePool!==null&&(g=u.memoizedState.cachePool.pool),g!==d&&(u.flags|=2048)),l!==t&&l&&(r.child.flags|=8192),co(r,r.updateQueue),Be(r),null);case 4:return qe(),t===null&&Ff(r.stateNode.containerInfo),Be(r),null;case 10:return Hn(r.type),Be(r),null;case 19:if(X(Xe),u=r.memoizedState,u===null)return Be(r),null;if(d=(r.flags&128)!==0,g=u.rendering,g===null)if(d)ba(u,!1);else{if(Ke!==0||t!==null&&(t.flags&128)!==0)for(t=r.child;t!==null;){if(g=Pl(t),g!==null){for(r.flags|=128,ba(u,!1),t=g.updateQueue,r.updateQueue=t,co(r,t),r.subtreeFlags=0,t=l,l=r.child;l!==null;)rg(l,t),l=l.sibling;return Z(Xe,Xe.current&1|2),Se&&zn(r,u.treeForkCount),r.child}t=t.sibling}u.tail!==null&&Je()>go&&(r.flags|=128,d=!0,ba(u,!1),r.lanes=4194304)}else{if(!d)if(t=Pl(g),t!==null){if(r.flags|=128,d=!0,t=t.updateQueue,r.updateQueue=t,co(r,t),ba(u,!0),u.tail===null&&u.tailMode==="hidden"&&!g.alternate&&!Se)return Be(r),null}else 2*Je()-u.renderingStartTime>go&&l!==536870912&&(r.flags|=128,d=!0,ba(u,!1),r.lanes=4194304);u.isBackwards?(g.sibling=r.child,r.child=g):(t=u.last,t!==null?t.sibling=g:r.child=g,u.last=g)}return u.tail!==null?(t=u.tail,u.rendering=t,u.tail=t.sibling,u.renderingStartTime=Je(),t.sibling=null,l=Xe.current,Z(Xe,d?l&1|2:l&1),Se&&zn(r,u.treeForkCount),t):(Be(r),null);case 22:case 23:return Xt(r),Fu(),u=r.memoizedState!==null,t!==null?t.memoizedState!==null!==u&&(r.flags|=8192):u&&(r.flags|=8192),u?(l&536870912)!==0&&(r.flags&128)===0&&(Be(r),r.subtreeFlags&6&&(r.flags|=8192)):Be(r),l=r.updateQueue,l!==null&&co(r,l.retryQueue),l=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),u=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(u=r.memoizedState.cachePool.pool),u!==l&&(r.flags|=2048),t!==null&&X(Zi),null;case 24:return l=null,t!==null&&(l=t.memoizedState.cache),r.memoizedState.cache!==l&&(r.flags|=2048),Hn(Ze),Be(r),null;case 25:return null;case 30:return null}throw Error(s(156,r.tag))}function M1(t,r){switch(Lu(r),r.tag){case 1:return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 3:return Hn(Ze),qe(),t=r.flags,(t&65536)!==0&&(t&128)===0?(r.flags=t&-65537|128,r):null;case 26:case 27:case 5:return ri(r),null;case 31:if(r.memoizedState!==null){if(Xt(r),r.alternate===null)throw Error(s(340));Qi()}return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 13:if(Xt(r),t=r.memoizedState,t!==null&&t.dehydrated!==null){if(r.alternate===null)throw Error(s(340));Qi()}return t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 19:return X(Xe),null;case 4:return qe(),null;case 10:return Hn(r.type),null;case 22:case 23:return Xt(r),Fu(),t!==null&&X(Zi),t=r.flags,t&65536?(r.flags=t&-65537|128,r):null;case 24:return Hn(Ze),null;case 25:return null;default:return null}}function Lm(t,r){switch(Lu(r),r.tag){case 3:Hn(Ze),qe();break;case 26:case 27:case 5:ri(r);break;case 4:qe();break;case 31:r.memoizedState!==null&&Xt(r);break;case 13:Xt(r);break;case 19:X(Xe);break;case 10:Hn(r.type);break;case 22:case 23:Xt(r),Fu(),t!==null&&X(Zi);break;case 24:Hn(Ze)}}function va(t,r){try{var l=r.updateQueue,u=l!==null?l.lastEffect:null;if(u!==null){var d=u.next;l=d;do{if((l.tag&t)===t){u=void 0;var g=l.create,b=l.inst;u=g(),b.destroy=u}l=l.next}while(l!==d)}}catch(_){ke(r,r.return,_)}}function yi(t,r,l){try{var u=r.updateQueue,d=u!==null?u.lastEffect:null;if(d!==null){var g=d.next;u=g;do{if((u.tag&t)===t){var b=u.inst,_=b.destroy;if(_!==void 0){b.destroy=void 0,d=r;var C=l,R=_;try{R()}catch(K){ke(d,C,K)}}}u=u.next}while(u!==g)}}catch(K){ke(r,r.return,K)}}function jm(t){var r=t.updateQueue;if(r!==null){var l=t.stateNode;try{Eg(r,l)}catch(u){ke(t,t.return,u)}}}function Rm(t,r,l){l.props=is(t.type,t.memoizedProps),l.state=t.memoizedState;try{l.componentWillUnmount()}catch(u){ke(t,r,u)}}function Sa(t,r){try{var l=t.ref;if(l!==null){switch(t.tag){case 26:case 27:case 5:var u=t.stateNode;break;case 30:u=t.stateNode;break;default:u=t.stateNode}typeof l=="function"?t.refCleanup=l(u):l.current=u}}catch(d){ke(t,r,d)}}function _n(t,r){var l=t.ref,u=t.refCleanup;if(l!==null)if(typeof u=="function")try{u()}catch(d){ke(t,r,d)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(d){ke(t,r,d)}else l.current=null}function Dm(t){var r=t.type,l=t.memoizedProps,u=t.stateNode;try{e:switch(r){case"button":case"input":case"select":case"textarea":l.autoFocus&&u.focus();break e;case"img":l.src?u.src=l.src:l.srcSet&&(u.srcset=l.srcSet)}}catch(d){ke(t,t.return,d)}}function Af(t,r,l){try{var u=t.stateNode;Z1(u,t.type,l,r),u[kt]=r}catch(d){ke(t,t.return,d)}}function Bm(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&Ti(t.type)||t.tag===4}function Cf(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||Bm(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&Ti(t.type)||t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function Nf(t,r,l){var u=t.tag;if(u===5||u===6)t=t.stateNode,r?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(t,r):(r=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,r.appendChild(t),l=l._reactRootContainer,l!=null||r.onclick!==null||(r.onclick=Rn));else if(u!==4&&(u===27&&Ti(t.type)&&(l=t.stateNode,r=null),t=t.child,t!==null))for(Nf(t,r,l),t=t.sibling;t!==null;)Nf(t,r,l),t=t.sibling}function uo(t,r,l){var u=t.tag;if(u===5||u===6)t=t.stateNode,r?l.insertBefore(t,r):l.appendChild(t);else if(u!==4&&(u===27&&Ti(t.type)&&(l=t.stateNode),t=t.child,t!==null))for(uo(t,r,l),t=t.sibling;t!==null;)uo(t,r,l),t=t.sibling}function zm(t){var r=t.stateNode,l=t.memoizedProps;try{for(var u=t.type,d=r.attributes;d.length;)r.removeAttributeNode(d[0]);dt(r,u,l),r[ct]=t,r[kt]=l}catch(g){ke(t,t.return,g)}}var Gn=!1,tt=!1,kf=!1,Um=typeof WeakSet=="function"?WeakSet:Set,ot=null;function O1(t,r){if(t=t.containerInfo,Pf=Lo,t=Pp(t),wu(t)){if("selectionStart"in t)var l={start:t.selectionStart,end:t.selectionEnd};else e:{l=(l=t.ownerDocument)&&l.defaultView||window;var u=l.getSelection&&l.getSelection();if(u&&u.rangeCount!==0){l=u.anchorNode;var d=u.anchorOffset,g=u.focusNode;u=u.focusOffset;try{l.nodeType,g.nodeType}catch{l=null;break e}var b=0,_=-1,C=-1,R=0,K=0,Y=t,D=null;t:for(;;){for(var I;Y!==l||d!==0&&Y.nodeType!==3||(_=b+d),Y!==g||u!==0&&Y.nodeType!==3||(C=b+u),Y.nodeType===3&&(b+=Y.nodeValue.length),(I=Y.firstChild)!==null;)D=Y,Y=I;for(;;){if(Y===t)break t;if(D===l&&++R===d&&(_=b),D===g&&++K===u&&(C=b),(I=Y.nextSibling)!==null)break;Y=D,D=Y.parentNode}Y=I}l=_===-1||C===-1?null:{start:_,end:C}}else l=null}l=l||{start:0,end:0}}else l=null;for(Jf={focusedElem:t,selectionRange:l},Lo=!1,ot=r;ot!==null;)if(r=ot,t=r.child,(r.subtreeFlags&1028)!==0&&t!==null)t.return=r,ot=t;else for(;ot!==null;){switch(r=ot,g=r.alternate,t=r.flags,r.tag){case 0:if((t&4)!==0&&(t=r.updateQueue,t=t!==null?t.events:null,t!==null))for(l=0;l<t.length;l++)d=t[l],d.ref.impl=d.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&g!==null){t=void 0,l=r,d=g.memoizedProps,g=g.memoizedState,u=l.stateNode;try{var te=is(l.type,d);t=u.getSnapshotBeforeUpdate(te,g),u.__reactInternalSnapshotBeforeUpdate=t}catch(oe){ke(l,l.return,oe)}}break;case 3:if((t&1024)!==0){if(t=r.stateNode.containerInfo,l=t.nodeType,l===9)eh(t);else if(l===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":eh(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(s(163))}if(t=r.sibling,t!==null){t.return=r.return,ot=t;break}ot=r.return}}function Hm(t,r,l){var u=l.flags;switch(l.tag){case 0:case 11:case 15:Xn(t,l),u&4&&va(5,l);break;case 1:if(Xn(t,l),u&4)if(t=l.stateNode,r===null)try{t.componentDidMount()}catch(b){ke(l,l.return,b)}else{var d=is(l.type,r.memoizedProps);r=r.memoizedState;try{t.componentDidUpdate(d,r,t.__reactInternalSnapshotBeforeUpdate)}catch(b){ke(l,l.return,b)}}u&64&&jm(l),u&512&&Sa(l,l.return);break;case 3:if(Xn(t,l),u&64&&(t=l.updateQueue,t!==null)){if(r=null,l.child!==null)switch(l.child.tag){case 27:case 5:r=l.child.stateNode;break;case 1:r=l.child.stateNode}try{Eg(t,r)}catch(b){ke(l,l.return,b)}}break;case 27:r===null&&u&4&&zm(l);case 26:case 5:Xn(t,l),r===null&&u&4&&Dm(l),u&512&&Sa(l,l.return);break;case 12:Xn(t,l);break;case 31:Xn(t,l),u&4&&$m(t,l);break;case 13:Xn(t,l),u&4&&Vm(t,l),u&64&&(t=l.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(l=q1.bind(null,l),ax(t,l))));break;case 22:if(u=l.memoizedState!==null||Gn,!u){r=r!==null&&r.memoizedState!==null||tt,d=Gn;var g=tt;Gn=u,(tt=r)&&!g?Fn(t,l,(l.subtreeFlags&8772)!==0):Xn(t,l),Gn=d,tt=g}break;case 30:break;default:Xn(t,l)}}function qm(t){var r=t.alternate;r!==null&&(t.alternate=null,qm(r)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(r=t.stateNode,r!==null&&su(r)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}var ze=null,Ot=!1;function Kn(t,r,l){for(l=l.child;l!==null;)Im(t,r,l),l=l.sibling}function Im(t,r,l){if(it&&typeof it.onCommitFiberUnmount=="function")try{it.onCommitFiberUnmount(Ii,l)}catch{}switch(l.tag){case 26:tt||_n(l,r),Kn(t,r,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:tt||_n(l,r);var u=ze,d=Ot;Ti(l.type)&&(ze=l.stateNode,Ot=!1),Kn(t,r,l),ka(l.stateNode),ze=u,Ot=d;break;case 5:tt||_n(l,r);case 6:if(u=ze,d=Ot,ze=null,Kn(t,r,l),ze=u,Ot=d,ze!==null)if(Ot)try{(ze.nodeType===9?ze.body:ze.nodeName==="HTML"?ze.ownerDocument.body:ze).removeChild(l.stateNode)}catch(g){ke(l,r,g)}else try{ze.removeChild(l.stateNode)}catch(g){ke(l,r,g)}break;case 18:ze!==null&&(Ot?(t=ze,jy(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,l.stateNode),cr(t)):jy(ze,l.stateNode));break;case 4:u=ze,d=Ot,ze=l.stateNode.containerInfo,Ot=!0,Kn(t,r,l),ze=u,Ot=d;break;case 0:case 11:case 14:case 15:yi(2,l,r),tt||yi(4,l,r),Kn(t,r,l);break;case 1:tt||(_n(l,r),u=l.stateNode,typeof u.componentWillUnmount=="function"&&Rm(l,r,u)),Kn(t,r,l);break;case 21:Kn(t,r,l);break;case 22:tt=(u=tt)||l.memoizedState!==null,Kn(t,r,l),tt=u;break;default:Kn(t,r,l)}}function $m(t,r){if(r.memoizedState===null&&(t=r.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{cr(t)}catch(l){ke(r,r.return,l)}}}function Vm(t,r){if(r.memoizedState===null&&(t=r.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{cr(t)}catch(l){ke(r,r.return,l)}}function L1(t){switch(t.tag){case 31:case 13:case 19:var r=t.stateNode;return r===null&&(r=t.stateNode=new Um),r;case 22:return t=t.stateNode,r=t._retryCache,r===null&&(r=t._retryCache=new Um),r;default:throw Error(s(435,t.tag))}}function fo(t,r){var l=L1(t);r.forEach(function(u){if(!l.has(u)){l.add(u);var d=I1.bind(null,t,u);u.then(d,d)}})}function Lt(t,r){var l=r.deletions;if(l!==null)for(var u=0;u<l.length;u++){var d=l[u],g=t,b=r,_=b;e:for(;_!==null;){switch(_.tag){case 27:if(Ti(_.type)){ze=_.stateNode,Ot=!1;break e}break;case 5:ze=_.stateNode,Ot=!1;break e;case 3:case 4:ze=_.stateNode.containerInfo,Ot=!0;break e}_=_.return}if(ze===null)throw Error(s(160));Im(g,b,d),ze=null,Ot=!1,g=d.alternate,g!==null&&(g.return=null),d.return=null}if(r.subtreeFlags&13886)for(r=r.child;r!==null;)Gm(r,t),r=r.sibling}var yn=null;function Gm(t,r){var l=t.alternate,u=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:Lt(r,t),jt(t),u&4&&(yi(3,t,t.return),va(3,t),yi(5,t,t.return));break;case 1:Lt(r,t),jt(t),u&512&&(tt||l===null||_n(l,l.return)),u&64&&Gn&&(t=t.updateQueue,t!==null&&(u=t.callbacks,u!==null&&(l=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=l===null?u:l.concat(u))));break;case 26:var d=yn;if(Lt(r,t),jt(t),u&512&&(tt||l===null||_n(l,l.return)),u&4){var g=l!==null?l.memoizedState:null;if(u=t.memoizedState,l===null)if(u===null)if(t.stateNode===null){e:{u=t.type,l=t.memoizedProps,d=d.ownerDocument||d;t:switch(u){case"title":g=d.getElementsByTagName("title")[0],(!g||g[Fr]||g[ct]||g.namespaceURI==="http://www.w3.org/2000/svg"||g.hasAttribute("itemprop"))&&(g=d.createElement(u),d.head.insertBefore(g,d.querySelector("head > title"))),dt(g,u,l),g[ct]=t,lt(g),u=g;break e;case"link":var b=Gy("link","href",d).get(u+(l.href||""));if(b){for(var _=0;_<b.length;_++)if(g=b[_],g.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&g.getAttribute("rel")===(l.rel==null?null:l.rel)&&g.getAttribute("title")===(l.title==null?null:l.title)&&g.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){b.splice(_,1);break t}}g=d.createElement(u),dt(g,u,l),d.head.appendChild(g);break;case"meta":if(b=Gy("meta","content",d).get(u+(l.content||""))){for(_=0;_<b.length;_++)if(g=b[_],g.getAttribute("content")===(l.content==null?null:""+l.content)&&g.getAttribute("name")===(l.name==null?null:l.name)&&g.getAttribute("property")===(l.property==null?null:l.property)&&g.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&g.getAttribute("charset")===(l.charSet==null?null:l.charSet)){b.splice(_,1);break t}}g=d.createElement(u),dt(g,u,l),d.head.appendChild(g);break;default:throw Error(s(468,u))}g[ct]=t,lt(g),u=g}t.stateNode=u}else Ky(d,t.type,t.stateNode);else t.stateNode=Vy(d,u,t.memoizedProps);else g!==u?(g===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):g.count--,u===null?Ky(d,t.type,t.stateNode):Vy(d,u,t.memoizedProps)):u===null&&t.stateNode!==null&&Af(t,t.memoizedProps,l.memoizedProps)}break;case 27:Lt(r,t),jt(t),u&512&&(tt||l===null||_n(l,l.return)),l!==null&&u&4&&Af(t,t.memoizedProps,l.memoizedProps);break;case 5:if(Lt(r,t),jt(t),u&512&&(tt||l===null||_n(l,l.return)),t.flags&32){d=t.stateNode;try{Ls(d,"")}catch(te){ke(t,t.return,te)}}u&4&&t.stateNode!=null&&(d=t.memoizedProps,Af(t,d,l!==null?l.memoizedProps:d)),u&1024&&(kf=!0);break;case 6:if(Lt(r,t),jt(t),u&4){if(t.stateNode===null)throw Error(s(162));u=t.memoizedProps,l=t.stateNode;try{l.nodeValue=u}catch(te){ke(t,t.return,te)}}break;case 3:if(No=null,d=yn,yn=Ao(r.containerInfo),Lt(r,t),yn=d,jt(t),u&4&&l!==null&&l.memoizedState.isDehydrated)try{cr(r.containerInfo)}catch(te){ke(t,t.return,te)}kf&&(kf=!1,Km(t));break;case 4:u=yn,yn=Ao(t.stateNode.containerInfo),Lt(r,t),jt(t),yn=u;break;case 12:Lt(r,t),jt(t);break;case 31:Lt(r,t),jt(t),u&4&&(u=t.updateQueue,u!==null&&(t.updateQueue=null,fo(t,u)));break;case 13:Lt(r,t),jt(t),t.child.flags&8192&&t.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(po=Je()),u&4&&(u=t.updateQueue,u!==null&&(t.updateQueue=null,fo(t,u)));break;case 22:d=t.memoizedState!==null;var C=l!==null&&l.memoizedState!==null,R=Gn,K=tt;if(Gn=R||d,tt=K||C,Lt(r,t),tt=K,Gn=R,jt(t),u&8192)e:for(r=t.stateNode,r._visibility=d?r._visibility&-2:r._visibility|1,d&&(l===null||C||Gn||tt||ss(t)),l=null,r=t;;){if(r.tag===5||r.tag===26){if(l===null){C=l=r;try{if(g=C.stateNode,d)b=g.style,typeof b.setProperty=="function"?b.setProperty("display","none","important"):b.display="none";else{_=C.stateNode;var Y=C.memoizedProps.style,D=Y!=null&&Y.hasOwnProperty("display")?Y.display:null;_.style.display=D==null||typeof D=="boolean"?"":(""+D).trim()}}catch(te){ke(C,C.return,te)}}}else if(r.tag===6){if(l===null){C=r;try{C.stateNode.nodeValue=d?"":C.memoizedProps}catch(te){ke(C,C.return,te)}}}else if(r.tag===18){if(l===null){C=r;try{var I=C.stateNode;d?Ry(I,!0):Ry(C.stateNode,!1)}catch(te){ke(C,C.return,te)}}}else if((r.tag!==22&&r.tag!==23||r.memoizedState===null||r===t)&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break e;for(;r.sibling===null;){if(r.return===null||r.return===t)break e;l===r&&(l=null),r=r.return}l===r&&(l=null),r.sibling.return=r.return,r=r.sibling}u&4&&(u=t.updateQueue,u!==null&&(l=u.retryQueue,l!==null&&(u.retryQueue=null,fo(t,l))));break;case 19:Lt(r,t),jt(t),u&4&&(u=t.updateQueue,u!==null&&(t.updateQueue=null,fo(t,u)));break;case 30:break;case 21:break;default:Lt(r,t),jt(t)}}function jt(t){var r=t.flags;if(r&2){try{for(var l,u=t.return;u!==null;){if(Bm(u)){l=u;break}u=u.return}if(l==null)throw Error(s(160));switch(l.tag){case 27:var d=l.stateNode,g=Cf(t);uo(t,g,d);break;case 5:var b=l.stateNode;l.flags&32&&(Ls(b,""),l.flags&=-33);var _=Cf(t);uo(t,_,b);break;case 3:case 4:var C=l.stateNode.containerInfo,R=Cf(t);Nf(t,R,C);break;default:throw Error(s(161))}}catch(K){ke(t,t.return,K)}t.flags&=-3}r&4096&&(t.flags&=-4097)}function Km(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var r=t;Km(r),r.tag===5&&r.flags&1024&&r.stateNode.reset(),t=t.sibling}}function Xn(t,r){if(r.subtreeFlags&8772)for(r=r.child;r!==null;)Hm(t,r.alternate,r),r=r.sibling}function ss(t){for(t=t.child;t!==null;){var r=t;switch(r.tag){case 0:case 11:case 14:case 15:yi(4,r,r.return),ss(r);break;case 1:_n(r,r.return);var l=r.stateNode;typeof l.componentWillUnmount=="function"&&Rm(r,r.return,l),ss(r);break;case 27:ka(r.stateNode);case 26:case 5:_n(r,r.return),ss(r);break;case 22:r.memoizedState===null&&ss(r);break;case 30:ss(r);break;default:ss(r)}t=t.sibling}}function Fn(t,r,l){for(l=l&&(r.subtreeFlags&8772)!==0,r=r.child;r!==null;){var u=r.alternate,d=t,g=r,b=g.flags;switch(g.tag){case 0:case 11:case 15:Fn(d,g,l),va(4,g);break;case 1:if(Fn(d,g,l),u=g,d=u.stateNode,typeof d.componentDidMount=="function")try{d.componentDidMount()}catch(R){ke(u,u.return,R)}if(u=g,d=u.updateQueue,d!==null){var _=u.stateNode;try{var C=d.shared.hiddenCallbacks;if(C!==null)for(d.shared.hiddenCallbacks=null,d=0;d<C.length;d++)xg(C[d],_)}catch(R){ke(u,u.return,R)}}l&&b&64&&jm(g),Sa(g,g.return);break;case 27:zm(g);case 26:case 5:Fn(d,g,l),l&&u===null&&b&4&&Dm(g),Sa(g,g.return);break;case 12:Fn(d,g,l);break;case 31:Fn(d,g,l),l&&b&4&&$m(d,g);break;case 13:Fn(d,g,l),l&&b&4&&Vm(d,g);break;case 22:g.memoizedState===null&&Fn(d,g,l),Sa(g,g.return);break;case 30:break;default:Fn(d,g,l)}r=r.sibling}}function Mf(t,r){var l=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(l=t.memoizedState.cachePool.pool),t=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(t=r.memoizedState.cachePool.pool),t!==l&&(t!=null&&t.refCount++,l!=null&&aa(l))}function Of(t,r){t=null,r.alternate!==null&&(t=r.alternate.memoizedState.cache),r=r.memoizedState.cache,r!==t&&(r.refCount++,t!=null&&aa(t))}function bn(t,r,l,u){if(r.subtreeFlags&10256)for(r=r.child;r!==null;)Xm(t,r,l,u),r=r.sibling}function Xm(t,r,l,u){var d=r.flags;switch(r.tag){case 0:case 11:case 15:bn(t,r,l,u),d&2048&&va(9,r);break;case 1:bn(t,r,l,u);break;case 3:bn(t,r,l,u),d&2048&&(t=null,r.alternate!==null&&(t=r.alternate.memoizedState.cache),r=r.memoizedState.cache,r!==t&&(r.refCount++,t!=null&&aa(t)));break;case 12:if(d&2048){bn(t,r,l,u),t=r.stateNode;try{var g=r.memoizedProps,b=g.id,_=g.onPostCommit;typeof _=="function"&&_(b,r.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(C){ke(r,r.return,C)}}else bn(t,r,l,u);break;case 31:bn(t,r,l,u);break;case 13:bn(t,r,l,u);break;case 23:break;case 22:g=r.stateNode,b=r.alternate,r.memoizedState!==null?g._visibility&2?bn(t,r,l,u):wa(t,r):g._visibility&2?bn(t,r,l,u):(g._visibility|=2,Zs(t,r,l,u,(r.subtreeFlags&10256)!==0||!1)),d&2048&&Mf(b,r);break;case 24:bn(t,r,l,u),d&2048&&Of(r.alternate,r);break;default:bn(t,r,l,u)}}function Zs(t,r,l,u,d){for(d=d&&((r.subtreeFlags&10256)!==0||!1),r=r.child;r!==null;){var g=t,b=r,_=l,C=u,R=b.flags;switch(b.tag){case 0:case 11:case 15:Zs(g,b,_,C,d),va(8,b);break;case 23:break;case 22:var K=b.stateNode;b.memoizedState!==null?K._visibility&2?Zs(g,b,_,C,d):wa(g,b):(K._visibility|=2,Zs(g,b,_,C,d)),d&&R&2048&&Mf(b.alternate,b);break;case 24:Zs(g,b,_,C,d),d&&R&2048&&Of(b.alternate,b);break;default:Zs(g,b,_,C,d)}r=r.sibling}}function wa(t,r){if(r.subtreeFlags&10256)for(r=r.child;r!==null;){var l=t,u=r,d=u.flags;switch(u.tag){case 22:wa(l,u),d&2048&&Mf(u.alternate,u);break;case 24:wa(l,u),d&2048&&Of(u.alternate,u);break;default:wa(l,u)}r=r.sibling}}var xa=8192;function Ws(t,r,l){if(t.subtreeFlags&xa)for(t=t.child;t!==null;)Fm(t,r,l),t=t.sibling}function Fm(t,r,l){switch(t.tag){case 26:Ws(t,r,l),t.flags&xa&&t.memoizedState!==null&&bx(l,yn,t.memoizedState,t.memoizedProps);break;case 5:Ws(t,r,l);break;case 3:case 4:var u=yn;yn=Ao(t.stateNode.containerInfo),Ws(t,r,l),yn=u;break;case 22:t.memoizedState===null&&(u=t.alternate,u!==null&&u.memoizedState!==null?(u=xa,xa=16777216,Ws(t,r,l),xa=u):Ws(t,r,l));break;default:Ws(t,r,l)}}function Ym(t){var r=t.alternate;if(r!==null&&(t=r.child,t!==null)){r.child=null;do r=t.sibling,t.sibling=null,t=r;while(t!==null)}}function Ea(t){var r=t.deletions;if((t.flags&16)!==0){if(r!==null)for(var l=0;l<r.length;l++){var u=r[l];ot=u,Pm(u,t)}Ym(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Qm(t),t=t.sibling}function Qm(t){switch(t.tag){case 0:case 11:case 15:Ea(t),t.flags&2048&&yi(9,t,t.return);break;case 3:Ea(t);break;case 12:Ea(t);break;case 22:var r=t.stateNode;t.memoizedState!==null&&r._visibility&2&&(t.return===null||t.return.tag!==13)?(r._visibility&=-3,ho(t)):Ea(t);break;default:Ea(t)}}function ho(t){var r=t.deletions;if((t.flags&16)!==0){if(r!==null)for(var l=0;l<r.length;l++){var u=r[l];ot=u,Pm(u,t)}Ym(t)}for(t=t.child;t!==null;){switch(r=t,r.tag){case 0:case 11:case 15:yi(8,r,r.return),ho(r);break;case 22:l=r.stateNode,l._visibility&2&&(l._visibility&=-3,ho(r));break;default:ho(r)}t=t.sibling}}function Pm(t,r){for(;ot!==null;){var l=ot;switch(l.tag){case 0:case 11:case 15:yi(8,l,r);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var u=l.memoizedState.cachePool.pool;u!=null&&u.refCount++}break;case 24:aa(l.memoizedState.cache)}if(u=l.child,u!==null)u.return=l,ot=u;else e:for(l=t;ot!==null;){u=ot;var d=u.sibling,g=u.return;if(qm(u),u===l){ot=null;break e}if(d!==null){d.return=g,ot=d;break e}ot=g}}}var j1={getCacheForType:function(t){var r=ft(Ze),l=r.data.get(t);return l===void 0&&(l=t(),r.data.set(t,l)),l},cacheSignal:function(){return ft(Ze).controller.signal}},R1=typeof WeakMap=="function"?WeakMap:Map,Ae=0,je=null,ge=null,ye=0,Ne=0,Ft=null,bi=!1,er=!1,Lf=!1,Yn=0,Ke=0,vi=0,rs=0,jf=0,Yt=0,tr=0,Ta=null,Rt=null,Rf=!1,po=0,Jm=0,go=1/0,mo=null,Si=null,st=0,wi=null,nr=null,Qn=0,Df=0,Bf=null,Zm=null,_a=0,zf=null;function Qt(){return(Ae&2)!==0&&ye!==0?ye&-ye:q.T!==null?Vf():pp()}function Wm(){if(Yt===0)if((ye&536870912)===0||Se){var t=le;le<<=1,(le&3932160)===0&&(le=262144),Yt=t}else Yt=536870912;return t=Kt.current,t!==null&&(t.flags|=32),Yt}function Dt(t,r,l){(t===je&&(Ne===2||Ne===9)||t.cancelPendingCommit!==null)&&(ir(t,0),xi(t,ye,Yt,!1)),Xr(t,l),((Ae&2)===0||t!==je)&&(t===je&&((Ae&2)===0&&(rs|=l),Ke===4&&xi(t,ye,Yt,!1)),An(t))}function ey(t,r,l){if((Ae&6)!==0)throw Error(s(327));var u=!l&&(r&127)===0&&(r&t.expiredLanes)===0||Kr(t,r),d=u?z1(t,r):Hf(t,r,!0),g=u;do{if(d===0){er&&!u&&xi(t,r,0,!1);break}else{if(l=t.current.alternate,g&&!D1(l)){d=Hf(t,r,!1),g=!1;continue}if(d===2){if(g=r,t.errorRecoveryDisabledLanes&g)var b=0;else b=t.pendingLanes&-536870913,b=b!==0?b:b&536870912?536870912:0;if(b!==0){r=b;e:{var _=t;d=Ta;var C=_.current.memoizedState.isDehydrated;if(C&&(ir(_,b).flags|=256),b=Hf(_,b,!1),b!==2){if(Lf&&!C){_.errorRecoveryDisabledLanes|=g,rs|=g,d=4;break e}g=Rt,Rt=d,g!==null&&(Rt===null?Rt=g:Rt.push.apply(Rt,g))}d=b}if(g=!1,d!==2)continue}}if(d===1){ir(t,0),xi(t,r,0,!0);break}e:{switch(u=t,g=d,g){case 0:case 1:throw Error(s(345));case 4:if((r&4194048)!==r)break;case 6:xi(u,r,Yt,!bi);break e;case 2:Rt=null;break;case 3:case 5:break;default:throw Error(s(329))}if((r&62914560)===r&&(d=po+300-Je(),10<d)){if(xi(u,r,Yt,!bi),_l(u,0,!0)!==0)break e;Qn=r,u.timeoutHandle=Oy(ty.bind(null,u,l,Rt,mo,Rf,r,Yt,rs,tr,bi,g,"Throttled",-0,0),d);break e}ty(u,l,Rt,mo,Rf,r,Yt,rs,tr,bi,g,null,-0,0)}}break}while(!0);An(t)}function ty(t,r,l,u,d,g,b,_,C,R,K,Y,D,I){if(t.timeoutHandle=-1,Y=r.subtreeFlags,Y&8192||(Y&16785408)===16785408){Y={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Rn},Fm(r,g,Y);var te=(g&62914560)===g?po-Je():(g&4194048)===g?Jm-Je():0;if(te=vx(Y,te),te!==null){Qn=g,t.cancelPendingCommit=te(cy.bind(null,t,r,g,l,u,d,b,_,C,K,Y,null,D,I)),xi(t,g,b,!R);return}}cy(t,r,g,l,u,d,b,_,C)}function D1(t){for(var r=t;;){var l=r.tag;if((l===0||l===11||l===15)&&r.flags&16384&&(l=r.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var u=0;u<l.length;u++){var d=l[u],g=d.getSnapshot;d=d.value;try{if(!Vt(g(),d))return!1}catch{return!1}}if(l=r.child,r.subtreeFlags&16384&&l!==null)l.return=r,r=l;else{if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return!0;r=r.return}r.sibling.return=r.return,r=r.sibling}}return!0}function xi(t,r,l,u){r&=~jf,r&=~rs,t.suspendedLanes|=r,t.pingedLanes&=~r,u&&(t.warmLanes|=r),u=t.expirationTimes;for(var d=r;0<d;){var g=31-at(d),b=1<<g;u[g]=-1,d&=~b}l!==0&&fp(t,l,r)}function yo(){return(Ae&6)===0?(Aa(0),!1):!0}function Uf(){if(ge!==null){if(Ne===0)var t=ge.return;else t=ge,Un=Pi=null,Wu(t),Fs=null,oa=0,t=ge;for(;t!==null;)Lm(t.alternate,t),t=t.return;ge=null}}function ir(t,r){var l=t.timeoutHandle;l!==-1&&(t.timeoutHandle=-1,tx(l)),l=t.cancelPendingCommit,l!==null&&(t.cancelPendingCommit=null,l()),Qn=0,Uf(),je=t,ge=l=Bn(t.current,null),ye=r,Ne=0,Ft=null,bi=!1,er=Kr(t,r),Lf=!1,tr=Yt=jf=rs=vi=Ke=0,Rt=Ta=null,Rf=!1,(r&8)!==0&&(r|=r&32);var u=t.entangledLanes;if(u!==0)for(t=t.entanglements,u&=r;0<u;){var d=31-at(u),g=1<<d;r|=t[d],u&=~g}return Yn=r,zl(),l}function ny(t,r){he=null,q.H=ma,r===Xs||r===Kl?(r=bg(),Ne=3):r===Iu?(r=bg(),Ne=4):Ne=r===mf?8:r!==null&&typeof r=="object"&&typeof r.then=="function"?6:1,Ft=r,ge===null&&(Ke=1,ro(t,tn(r,t.current)))}function iy(){var t=Kt.current;return t===null?!0:(ye&4194048)===ye?an===null:(ye&62914560)===ye||(ye&536870912)!==0?t===an:!1}function sy(){var t=q.H;return q.H=ma,t===null?ma:t}function ry(){var t=q.A;return q.A=j1,t}function bo(){Ke=4,bi||(ye&4194048)!==ye&&Kt.current!==null||(er=!0),(vi&134217727)===0&&(rs&134217727)===0||je===null||xi(je,ye,Yt,!1)}function Hf(t,r,l){var u=Ae;Ae|=2;var d=sy(),g=ry();(je!==t||ye!==r)&&(mo=null,ir(t,r)),r=!1;var b=Ke;e:do try{if(Ne!==0&&ge!==null){var _=ge,C=Ft;switch(Ne){case 8:Uf(),b=6;break e;case 3:case 2:case 9:case 6:Kt.current===null&&(r=!0);var R=Ne;if(Ne=0,Ft=null,sr(t,_,C,R),l&&er){b=0;break e}break;default:R=Ne,Ne=0,Ft=null,sr(t,_,C,R)}}B1(),b=Ke;break}catch(K){ny(t,K)}while(!0);return r&&t.shellSuspendCounter++,Un=Pi=null,Ae=u,q.H=d,q.A=g,ge===null&&(je=null,ye=0,zl()),b}function B1(){for(;ge!==null;)ay(ge)}function z1(t,r){var l=Ae;Ae|=2;var u=sy(),d=ry();je!==t||ye!==r?(mo=null,go=Je()+500,ir(t,r)):er=Kr(t,r);e:do try{if(Ne!==0&&ge!==null){r=ge;var g=Ft;t:switch(Ne){case 1:Ne=0,Ft=null,sr(t,r,g,1);break;case 2:case 9:if(mg(g)){Ne=0,Ft=null,ly(r);break}r=function(){Ne!==2&&Ne!==9||je!==t||(Ne=7),An(t)},g.then(r,r);break e;case 3:Ne=7;break e;case 4:Ne=5;break e;case 7:mg(g)?(Ne=0,Ft=null,ly(r)):(Ne=0,Ft=null,sr(t,r,g,7));break;case 5:var b=null;switch(ge.tag){case 26:b=ge.memoizedState;case 5:case 27:var _=ge;if(b?Xy(b):_.stateNode.complete){Ne=0,Ft=null;var C=_.sibling;if(C!==null)ge=C;else{var R=_.return;R!==null?(ge=R,vo(R)):ge=null}break t}}Ne=0,Ft=null,sr(t,r,g,5);break;case 6:Ne=0,Ft=null,sr(t,r,g,6);break;case 8:Uf(),Ke=6;break e;default:throw Error(s(462))}}U1();break}catch(K){ny(t,K)}while(!0);return Un=Pi=null,q.H=u,q.A=d,Ae=l,ge!==null?0:(je=null,ye=0,zl(),Ke)}function U1(){for(;ge!==null&&!Es();)ay(ge)}function ay(t){var r=Mm(t.alternate,t,Yn);t.memoizedProps=t.pendingProps,r===null?vo(t):ge=r}function ly(t){var r=t,l=r.alternate;switch(r.tag){case 15:case 0:r=Tm(l,r,r.pendingProps,r.type,void 0,ye);break;case 11:r=Tm(l,r,r.pendingProps,r.type.render,r.ref,ye);break;case 5:Wu(r);default:Lm(l,r),r=ge=rg(r,Yn),r=Mm(l,r,Yn)}t.memoizedProps=t.pendingProps,r===null?vo(t):ge=r}function sr(t,r,l,u){Un=Pi=null,Wu(r),Fs=null,oa=0;var d=r.return;try{if(A1(t,d,r,l,ye)){Ke=1,ro(t,tn(l,t.current)),ge=null;return}}catch(g){if(d!==null)throw ge=d,g;Ke=1,ro(t,tn(l,t.current)),ge=null;return}r.flags&32768?(Se||u===1?t=!0:er||(ye&536870912)!==0?t=!1:(bi=t=!0,(u===2||u===9||u===3||u===6)&&(u=Kt.current,u!==null&&u.tag===13&&(u.flags|=16384))),oy(r,t)):vo(r)}function vo(t){var r=t;do{if((r.flags&32768)!==0){oy(r,bi);return}t=r.return;var l=k1(r.alternate,r,Yn);if(l!==null){ge=l;return}if(r=r.sibling,r!==null){ge=r;return}ge=r=t}while(r!==null);Ke===0&&(Ke=5)}function oy(t,r){do{var l=M1(t.alternate,t);if(l!==null){l.flags&=32767,ge=l;return}if(l=t.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!r&&(t=t.sibling,t!==null)){ge=t;return}ge=t=l}while(t!==null);Ke=6,ge=null}function cy(t,r,l,u,d,g,b,_,C){t.cancelPendingCommit=null;do So();while(st!==0);if((Ae&6)!==0)throw Error(s(327));if(r!==null){if(r===t.current)throw Error(s(177));if(g=r.lanes|r.childLanes,g|=Au,yw(t,l,g,b,_,C),t===je&&(ge=je=null,ye=0),nr=r,wi=t,Qn=l,Df=g,Bf=d,Zm=u,(r.subtreeFlags&10256)!==0||(r.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,$1(Ts,function(){return py(),null})):(t.callbackNode=null,t.callbackPriority=0),u=(r.flags&13878)!==0,(r.subtreeFlags&13878)!==0||u){u=q.T,q.T=null,d=J.p,J.p=2,b=Ae,Ae|=4;try{O1(t,r,l)}finally{Ae=b,J.p=d,q.T=u}}st=1,uy(),fy(),hy()}}function uy(){if(st===1){st=0;var t=wi,r=nr,l=(r.flags&13878)!==0;if((r.subtreeFlags&13878)!==0||l){l=q.T,q.T=null;var u=J.p;J.p=2;var d=Ae;Ae|=4;try{Gm(r,t);var g=Jf,b=Pp(t.containerInfo),_=g.focusedElem,C=g.selectionRange;if(b!==_&&_&&_.ownerDocument&&Qp(_.ownerDocument.documentElement,_)){if(C!==null&&wu(_)){var R=C.start,K=C.end;if(K===void 0&&(K=R),"selectionStart"in _)_.selectionStart=R,_.selectionEnd=Math.min(K,_.value.length);else{var Y=_.ownerDocument||document,D=Y&&Y.defaultView||window;if(D.getSelection){var I=D.getSelection(),te=_.textContent.length,oe=Math.min(C.start,te),Le=C.end===void 0?oe:Math.min(C.end,te);!I.extend&&oe>Le&&(b=Le,Le=oe,oe=b);var O=Yp(_,oe),M=Yp(_,Le);if(O&&M&&(I.rangeCount!==1||I.anchorNode!==O.node||I.anchorOffset!==O.offset||I.focusNode!==M.node||I.focusOffset!==M.offset)){var j=Y.createRange();j.setStart(O.node,O.offset),I.removeAllRanges(),oe>Le?(I.addRange(j),I.extend(M.node,M.offset)):(j.setEnd(M.node,M.offset),I.addRange(j))}}}}for(Y=[],I=_;I=I.parentNode;)I.nodeType===1&&Y.push({element:I,left:I.scrollLeft,top:I.scrollTop});for(typeof _.focus=="function"&&_.focus(),_=0;_<Y.length;_++){var F=Y[_];F.element.scrollLeft=F.left,F.element.scrollTop=F.top}}Lo=!!Pf,Jf=Pf=null}finally{Ae=d,J.p=u,q.T=l}}t.current=r,st=2}}function fy(){if(st===2){st=0;var t=wi,r=nr,l=(r.flags&8772)!==0;if((r.subtreeFlags&8772)!==0||l){l=q.T,q.T=null;var u=J.p;J.p=2;var d=Ae;Ae|=4;try{Hm(t,r.alternate,r)}finally{Ae=d,J.p=u,q.T=l}}st=3}}function hy(){if(st===4||st===3){st=0,Fc();var t=wi,r=nr,l=Qn,u=Zm;(r.subtreeFlags&10256)!==0||(r.flags&10256)!==0?st=5:(st=0,nr=wi=null,dy(t,t.pendingLanes));var d=t.pendingLanes;if(d===0&&(Si=null),nu(l),r=r.stateNode,it&&typeof it.onCommitFiberRoot=="function")try{it.onCommitFiberRoot(Ii,r,void 0,(r.current.flags&128)===128)}catch{}if(u!==null){r=q.T,d=J.p,J.p=2,q.T=null;try{for(var g=t.onRecoverableError,b=0;b<u.length;b++){var _=u[b];g(_.value,{componentStack:_.stack})}}finally{q.T=r,J.p=d}}(Qn&3)!==0&&So(),An(t),d=t.pendingLanes,(l&261930)!==0&&(d&42)!==0?t===zf?_a++:(_a=0,zf=t):_a=0,Aa(0)}}function dy(t,r){(t.pooledCacheLanes&=r)===0&&(r=t.pooledCache,r!=null&&(t.pooledCache=null,aa(r)))}function So(){return uy(),fy(),hy(),py()}function py(){if(st!==5)return!1;var t=wi,r=Df;Df=0;var l=nu(Qn),u=q.T,d=J.p;try{J.p=32>l?32:l,q.T=null,l=Bf,Bf=null;var g=wi,b=Qn;if(st=0,nr=wi=null,Qn=0,(Ae&6)!==0)throw Error(s(331));var _=Ae;if(Ae|=4,Qm(g.current),Xm(g,g.current,b,l),Ae=_,Aa(0,!1),it&&typeof it.onPostCommitFiberRoot=="function")try{it.onPostCommitFiberRoot(Ii,g)}catch{}return!0}finally{J.p=d,q.T=u,dy(t,r)}}function gy(t,r,l){r=tn(l,r),r=gf(t.stateNode,r,2),t=pi(t,r,2),t!==null&&(Xr(t,2),An(t))}function ke(t,r,l){if(t.tag===3)gy(t,t,l);else for(;r!==null;){if(r.tag===3){gy(r,t,l);break}else if(r.tag===1){var u=r.stateNode;if(typeof r.type.getDerivedStateFromError=="function"||typeof u.componentDidCatch=="function"&&(Si===null||!Si.has(u))){t=tn(l,t),l=mm(2),u=pi(r,l,2),u!==null&&(ym(l,u,r,t),Xr(u,2),An(u));break}}r=r.return}}function qf(t,r,l){var u=t.pingCache;if(u===null){u=t.pingCache=new R1;var d=new Set;u.set(r,d)}else d=u.get(r),d===void 0&&(d=new Set,u.set(r,d));d.has(l)||(Lf=!0,d.add(l),t=H1.bind(null,t,r,l),r.then(t,t))}function H1(t,r,l){var u=t.pingCache;u!==null&&u.delete(r),t.pingedLanes|=t.suspendedLanes&l,t.warmLanes&=~l,je===t&&(ye&l)===l&&(Ke===4||Ke===3&&(ye&62914560)===ye&&300>Je()-po?(Ae&2)===0&&ir(t,0):jf|=l,tr===ye&&(tr=0)),An(t)}function my(t,r){r===0&&(r=up()),t=Fi(t,r),t!==null&&(Xr(t,r),An(t))}function q1(t){var r=t.memoizedState,l=0;r!==null&&(l=r.retryLane),my(t,l)}function I1(t,r){var l=0;switch(t.tag){case 31:case 13:var u=t.stateNode,d=t.memoizedState;d!==null&&(l=d.retryLane);break;case 19:u=t.stateNode;break;case 22:u=t.stateNode._retryCache;break;default:throw Error(s(314))}u!==null&&u.delete(r),my(t,l)}function $1(t,r){return Hi(t,r)}var wo=null,rr=null,If=!1,xo=!1,$f=!1,Ei=0;function An(t){t!==rr&&t.next===null&&(rr===null?wo=rr=t:rr=rr.next=t),xo=!0,If||(If=!0,G1())}function Aa(t,r){if(!$f&&xo){$f=!0;do for(var l=!1,u=wo;u!==null;){if(t!==0){var d=u.pendingLanes;if(d===0)var g=0;else{var b=u.suspendedLanes,_=u.pingedLanes;g=(1<<31-at(42|t)+1)-1,g&=d&~(b&~_),g=g&201326741?g&201326741|1:g?g|2:0}g!==0&&(l=!0,Sy(u,g))}else g=ye,g=_l(u,u===je?g:0,u.cancelPendingCommit!==null||u.timeoutHandle!==-1),(g&3)===0||Kr(u,g)||(l=!0,Sy(u,g));u=u.next}while(l);$f=!1}}function V1(){yy()}function yy(){xo=If=!1;var t=0;Ei!==0&&ex()&&(t=Ei);for(var r=Je(),l=null,u=wo;u!==null;){var d=u.next,g=by(u,r);g===0?(u.next=null,l===null?wo=d:l.next=d,d===null&&(rr=l)):(l=u,(t!==0||(g&3)!==0)&&(xo=!0)),u=d}st!==0&&st!==5||Aa(t),Ei!==0&&(Ei=0)}function by(t,r){for(var l=t.suspendedLanes,u=t.pingedLanes,d=t.expirationTimes,g=t.pendingLanes&-62914561;0<g;){var b=31-at(g),_=1<<b,C=d[b];C===-1?((_&l)===0||(_&u)!==0)&&(d[b]=mw(_,r)):C<=r&&(t.expiredLanes|=_),g&=~_}if(r=je,l=ye,l=_l(t,t===r?l:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),u=t.callbackNode,l===0||t===r&&(Ne===2||Ne===9)||t.cancelPendingCommit!==null)return u!==null&&u!==null&&qi(u),t.callbackNode=null,t.callbackPriority=0;if((l&3)===0||Kr(t,l)){if(r=l&-l,r===t.callbackPriority)return r;switch(u!==null&&qi(u),nu(l)){case 2:case 8:l=El;break;case 32:l=Ts;break;case 268435456:l=_s;break;default:l=Ts}return u=vy.bind(null,t),l=Hi(l,u),t.callbackPriority=r,t.callbackNode=l,r}return u!==null&&u!==null&&qi(u),t.callbackPriority=2,t.callbackNode=null,2}function vy(t,r){if(st!==0&&st!==5)return t.callbackNode=null,t.callbackPriority=0,null;var l=t.callbackNode;if(So()&&t.callbackNode!==l)return null;var u=ye;return u=_l(t,t===je?u:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),u===0?null:(ey(t,u,r),by(t,Je()),t.callbackNode!=null&&t.callbackNode===l?vy.bind(null,t):null)}function Sy(t,r){if(So())return null;ey(t,r,!0)}function G1(){nx(function(){(Ae&6)!==0?Hi(xl,V1):yy()})}function Vf(){if(Ei===0){var t=Gs;t===0&&(t=$i,$i<<=1,($i&261888)===0&&($i=256)),Ei=t}return Ei}function wy(t){return t==null||typeof t=="symbol"||typeof t=="boolean"?null:typeof t=="function"?t:kl(""+t)}function xy(t,r){var l=r.ownerDocument.createElement("input");return l.name=r.name,l.value=r.value,t.id&&l.setAttribute("form",t.id),r.parentNode.insertBefore(l,r),t=new FormData(t),l.parentNode.removeChild(l),t}function K1(t,r,l,u,d){if(r==="submit"&&l&&l.stateNode===d){var g=wy((d[kt]||null).action),b=u.submitter;b&&(r=(r=b[kt]||null)?wy(r.formAction):b.getAttribute("formAction"),r!==null&&(g=r,b=null));var _=new jl("action","action",null,u,d);t.push({event:_,listeners:[{instance:null,listener:function(){if(u.defaultPrevented){if(Ei!==0){var C=b?xy(d,b):new FormData(d);cf(l,{pending:!0,data:C,method:d.method,action:g},null,C)}}else typeof g=="function"&&(_.preventDefault(),C=b?xy(d,b):new FormData(d),cf(l,{pending:!0,data:C,method:d.method,action:g},g,C))},currentTarget:d}]})}}for(var Gf=0;Gf<_u.length;Gf++){var Kf=_u[Gf],X1=Kf.toLowerCase(),F1=Kf[0].toUpperCase()+Kf.slice(1);mn(X1,"on"+F1)}mn(Wp,"onAnimationEnd"),mn(eg,"onAnimationIteration"),mn(tg,"onAnimationStart"),mn("dblclick","onDoubleClick"),mn("focusin","onFocus"),mn("focusout","onBlur"),mn(c1,"onTransitionRun"),mn(u1,"onTransitionStart"),mn(f1,"onTransitionCancel"),mn(ng,"onTransitionEnd"),Ms("onMouseEnter",["mouseout","mouseover"]),Ms("onMouseLeave",["mouseout","mouseover"]),Ms("onPointerEnter",["pointerout","pointerover"]),Ms("onPointerLeave",["pointerout","pointerover"]),Vi("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Vi("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Vi("onBeforeInput",["compositionend","keypress","textInput","paste"]),Vi("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Vi("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Vi("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ca="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Y1=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Ca));function Ey(t,r){r=(r&4)!==0;for(var l=0;l<t.length;l++){var u=t[l],d=u.event;u=u.listeners;e:{var g=void 0;if(r)for(var b=u.length-1;0<=b;b--){var _=u[b],C=_.instance,R=_.currentTarget;if(_=_.listener,C!==g&&d.isPropagationStopped())break e;g=_,d.currentTarget=R;try{g(d)}catch(K){Bl(K)}d.currentTarget=null,g=C}else for(b=0;b<u.length;b++){if(_=u[b],C=_.instance,R=_.currentTarget,_=_.listener,C!==g&&d.isPropagationStopped())break e;g=_,d.currentTarget=R;try{g(d)}catch(K){Bl(K)}d.currentTarget=null,g=C}}}}function me(t,r){var l=r[iu];l===void 0&&(l=r[iu]=new Set);var u=t+"__bubble";l.has(u)||(Ty(r,t,2,!1),l.add(u))}function Xf(t,r,l){var u=0;r&&(u|=4),Ty(l,t,u,r)}var Eo="_reactListening"+Math.random().toString(36).slice(2);function Ff(t){if(!t[Eo]){t[Eo]=!0,yp.forEach(function(l){l!=="selectionchange"&&(Y1.has(l)||Xf(l,!1,t),Xf(l,!0,t))});var r=t.nodeType===9?t:t.ownerDocument;r===null||r[Eo]||(r[Eo]=!0,Xf("selectionchange",!1,r))}}function Ty(t,r,l,u){switch(Wy(r)){case 2:var d=xx;break;case 8:d=Ex;break;default:d=oh}l=d.bind(null,r,l,t),d=void 0,!hu||r!=="touchstart"&&r!=="touchmove"&&r!=="wheel"||(d=!0),u?d!==void 0?t.addEventListener(r,l,{capture:!0,passive:d}):t.addEventListener(r,l,!0):d!==void 0?t.addEventListener(r,l,{passive:d}):t.addEventListener(r,l,!1)}function Yf(t,r,l,u,d){var g=u;if((r&1)===0&&(r&2)===0&&u!==null)e:for(;;){if(u===null)return;var b=u.tag;if(b===3||b===4){var _=u.stateNode.containerInfo;if(_===d)break;if(b===4)for(b=u.return;b!==null;){var C=b.tag;if((C===3||C===4)&&b.stateNode.containerInfo===d)return;b=b.return}for(;_!==null;){if(b=Cs(_),b===null)return;if(C=b.tag,C===5||C===6||C===26||C===27){u=g=b;continue e}_=_.parentNode}}u=u.return}kp(function(){var R=g,K=uu(l),Y=[];e:{var D=ig.get(t);if(D!==void 0){var I=jl,te=t;switch(t){case"keypress":if(Ol(l)===0)break e;case"keydown":case"keyup":I=Iw;break;case"focusin":te="focus",I=mu;break;case"focusout":te="blur",I=mu;break;case"beforeblur":case"afterblur":I=mu;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":I=Lp;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":I=kw;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":I=Gw;break;case Wp:case eg:case tg:I=Lw;break;case ng:I=Xw;break;case"scroll":case"scrollend":I=Cw;break;case"wheel":I=Yw;break;case"copy":case"cut":case"paste":I=Rw;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":I=Rp;break;case"toggle":case"beforetoggle":I=Pw}var oe=(r&4)!==0,Le=!oe&&(t==="scroll"||t==="scrollend"),O=oe?D!==null?D+"Capture":null:D;oe=[];for(var M=R,j;M!==null;){var F=M;if(j=F.stateNode,F=F.tag,F!==5&&F!==26&&F!==27||j===null||O===null||(F=Qr(M,O),F!=null&&oe.push(Na(M,F,j))),Le)break;M=M.return}0<oe.length&&(D=new I(D,te,null,l,K),Y.push({event:D,listeners:oe}))}}if((r&7)===0){e:{if(D=t==="mouseover"||t==="pointerover",I=t==="mouseout"||t==="pointerout",D&&l!==cu&&(te=l.relatedTarget||l.fromElement)&&(Cs(te)||te[As]))break e;if((I||D)&&(D=K.window===K?K:(D=K.ownerDocument)?D.defaultView||D.parentWindow:window,I?(te=l.relatedTarget||l.toElement,I=R,te=te?Cs(te):null,te!==null&&(Le=o(te),oe=te.tag,te!==Le||oe!==5&&oe!==27&&oe!==6)&&(te=null)):(I=null,te=R),I!==te)){if(oe=Lp,F="onMouseLeave",O="onMouseEnter",M="mouse",(t==="pointerout"||t==="pointerover")&&(oe=Rp,F="onPointerLeave",O="onPointerEnter",M="pointer"),Le=I==null?D:Yr(I),j=te==null?D:Yr(te),D=new oe(F,M+"leave",I,l,K),D.target=Le,D.relatedTarget=j,F=null,Cs(K)===R&&(oe=new oe(O,M+"enter",te,l,K),oe.target=j,oe.relatedTarget=Le,F=oe),Le=F,I&&te)t:{for(oe=Q1,O=I,M=te,j=0,F=O;F;F=oe(F))j++;F=0;for(var re=M;re;re=oe(re))F++;for(;0<j-F;)O=oe(O),j--;for(;0<F-j;)M=oe(M),F--;for(;j--;){if(O===M||M!==null&&O===M.alternate){oe=O;break t}O=oe(O),M=oe(M)}oe=null}else oe=null;I!==null&&_y(Y,D,I,oe,!1),te!==null&&Le!==null&&_y(Y,Le,te,oe,!0)}}e:{if(D=R?Yr(R):window,I=D.nodeName&&D.nodeName.toLowerCase(),I==="select"||I==="input"&&D.type==="file")var Te=$p;else if(qp(D))if(Vp)Te=a1;else{Te=s1;var ie=i1}else I=D.nodeName,!I||I.toLowerCase()!=="input"||D.type!=="checkbox"&&D.type!=="radio"?R&&ou(R.elementType)&&(Te=$p):Te=r1;if(Te&&(Te=Te(t,R))){Ip(Y,Te,l,K);break e}ie&&ie(t,D,R),t==="focusout"&&R&&D.type==="number"&&R.memoizedProps.value!=null&&lu(D,"number",D.value)}switch(ie=R?Yr(R):window,t){case"focusin":(qp(ie)||ie.contentEditable==="true")&&(Bs=ie,xu=R,ia=null);break;case"focusout":ia=xu=Bs=null;break;case"mousedown":Eu=!0;break;case"contextmenu":case"mouseup":case"dragend":Eu=!1,Jp(Y,l,K);break;case"selectionchange":if(o1)break;case"keydown":case"keyup":Jp(Y,l,K)}var pe;if(bu)e:{switch(t){case"compositionstart":var be="onCompositionStart";break e;case"compositionend":be="onCompositionEnd";break e;case"compositionupdate":be="onCompositionUpdate";break e}be=void 0}else Ds?Up(t,l)&&(be="onCompositionEnd"):t==="keydown"&&l.keyCode===229&&(be="onCompositionStart");be&&(Dp&&l.locale!=="ko"&&(Ds||be!=="onCompositionStart"?be==="onCompositionEnd"&&Ds&&(pe=Mp()):(li=K,du="value"in li?li.value:li.textContent,Ds=!0)),ie=To(R,be),0<ie.length&&(be=new jp(be,t,null,l,K),Y.push({event:be,listeners:ie}),pe?be.data=pe:(pe=Hp(l),pe!==null&&(be.data=pe)))),(pe=Zw?Ww(t,l):e1(t,l))&&(be=To(R,"onBeforeInput"),0<be.length&&(ie=new jp("onBeforeInput","beforeinput",null,l,K),Y.push({event:ie,listeners:be}),ie.data=pe)),K1(Y,t,R,l,K)}Ey(Y,r)})}function Na(t,r,l){return{instance:t,listener:r,currentTarget:l}}function To(t,r){for(var l=r+"Capture",u=[];t!==null;){var d=t,g=d.stateNode;if(d=d.tag,d!==5&&d!==26&&d!==27||g===null||(d=Qr(t,l),d!=null&&u.unshift(Na(t,d,g)),d=Qr(t,r),d!=null&&u.push(Na(t,d,g))),t.tag===3)return u;t=t.return}return[]}function Q1(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t||null}function _y(t,r,l,u,d){for(var g=r._reactName,b=[];l!==null&&l!==u;){var _=l,C=_.alternate,R=_.stateNode;if(_=_.tag,C!==null&&C===u)break;_!==5&&_!==26&&_!==27||R===null||(C=R,d?(R=Qr(l,g),R!=null&&b.unshift(Na(l,R,C))):d||(R=Qr(l,g),R!=null&&b.push(Na(l,R,C)))),l=l.return}b.length!==0&&t.push({event:r,listeners:b})}var P1=/\r\n?/g,J1=/\u0000|\uFFFD/g;function Ay(t){return(typeof t=="string"?t:""+t).replace(P1,`
|
|
50
|
+
`).replace(J1,"")}function Cy(t,r){return r=Ay(r),Ay(t)===r}function Oe(t,r,l,u,d,g){switch(l){case"children":typeof u=="string"?r==="body"||r==="textarea"&&u===""||Ls(t,u):(typeof u=="number"||typeof u=="bigint")&&r!=="body"&&Ls(t,""+u);break;case"className":Cl(t,"class",u);break;case"tabIndex":Cl(t,"tabindex",u);break;case"dir":case"role":case"viewBox":case"width":case"height":Cl(t,l,u);break;case"style":Cp(t,u,g);break;case"data":if(r!=="object"){Cl(t,"data",u);break}case"src":case"href":if(u===""&&(r!=="a"||l!=="href")){t.removeAttribute(l);break}if(u==null||typeof u=="function"||typeof u=="symbol"||typeof u=="boolean"){t.removeAttribute(l);break}u=kl(""+u),t.setAttribute(l,u);break;case"action":case"formAction":if(typeof u=="function"){t.setAttribute(l,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof g=="function"&&(l==="formAction"?(r!=="input"&&Oe(t,r,"name",d.name,d,null),Oe(t,r,"formEncType",d.formEncType,d,null),Oe(t,r,"formMethod",d.formMethod,d,null),Oe(t,r,"formTarget",d.formTarget,d,null)):(Oe(t,r,"encType",d.encType,d,null),Oe(t,r,"method",d.method,d,null),Oe(t,r,"target",d.target,d,null)));if(u==null||typeof u=="symbol"||typeof u=="boolean"){t.removeAttribute(l);break}u=kl(""+u),t.setAttribute(l,u);break;case"onClick":u!=null&&(t.onclick=Rn);break;case"onScroll":u!=null&&me("scroll",t);break;case"onScrollEnd":u!=null&&me("scrollend",t);break;case"dangerouslySetInnerHTML":if(u!=null){if(typeof u!="object"||!("__html"in u))throw Error(s(61));if(l=u.__html,l!=null){if(d.children!=null)throw Error(s(60));t.innerHTML=l}}break;case"multiple":t.multiple=u&&typeof u!="function"&&typeof u!="symbol";break;case"muted":t.muted=u&&typeof u!="function"&&typeof u!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(u==null||typeof u=="function"||typeof u=="boolean"||typeof u=="symbol"){t.removeAttribute("xlink:href");break}l=kl(""+u),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":u!=null&&typeof u!="function"&&typeof u!="symbol"?t.setAttribute(l,""+u):t.removeAttribute(l);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":u&&typeof u!="function"&&typeof u!="symbol"?t.setAttribute(l,""):t.removeAttribute(l);break;case"capture":case"download":u===!0?t.setAttribute(l,""):u!==!1&&u!=null&&typeof u!="function"&&typeof u!="symbol"?t.setAttribute(l,u):t.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":u!=null&&typeof u!="function"&&typeof u!="symbol"&&!isNaN(u)&&1<=u?t.setAttribute(l,u):t.removeAttribute(l);break;case"rowSpan":case"start":u==null||typeof u=="function"||typeof u=="symbol"||isNaN(u)?t.removeAttribute(l):t.setAttribute(l,u);break;case"popover":me("beforetoggle",t),me("toggle",t),Al(t,"popover",u);break;case"xlinkActuate":jn(t,"http://www.w3.org/1999/xlink","xlink:actuate",u);break;case"xlinkArcrole":jn(t,"http://www.w3.org/1999/xlink","xlink:arcrole",u);break;case"xlinkRole":jn(t,"http://www.w3.org/1999/xlink","xlink:role",u);break;case"xlinkShow":jn(t,"http://www.w3.org/1999/xlink","xlink:show",u);break;case"xlinkTitle":jn(t,"http://www.w3.org/1999/xlink","xlink:title",u);break;case"xlinkType":jn(t,"http://www.w3.org/1999/xlink","xlink:type",u);break;case"xmlBase":jn(t,"http://www.w3.org/XML/1998/namespace","xml:base",u);break;case"xmlLang":jn(t,"http://www.w3.org/XML/1998/namespace","xml:lang",u);break;case"xmlSpace":jn(t,"http://www.w3.org/XML/1998/namespace","xml:space",u);break;case"is":Al(t,"is",u);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=_w.get(l)||l,Al(t,l,u))}}function Qf(t,r,l,u,d,g){switch(l){case"style":Cp(t,u,g);break;case"dangerouslySetInnerHTML":if(u!=null){if(typeof u!="object"||!("__html"in u))throw Error(s(61));if(l=u.__html,l!=null){if(d.children!=null)throw Error(s(60));t.innerHTML=l}}break;case"children":typeof u=="string"?Ls(t,u):(typeof u=="number"||typeof u=="bigint")&&Ls(t,""+u);break;case"onScroll":u!=null&&me("scroll",t);break;case"onScrollEnd":u!=null&&me("scrollend",t);break;case"onClick":u!=null&&(t.onclick=Rn);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!bp.hasOwnProperty(l))e:{if(l[0]==="o"&&l[1]==="n"&&(d=l.endsWith("Capture"),r=l.slice(2,d?l.length-7:void 0),g=t[kt]||null,g=g!=null?g[l]:null,typeof g=="function"&&t.removeEventListener(r,g,d),typeof u=="function")){typeof g!="function"&&g!==null&&(l in t?t[l]=null:t.hasAttribute(l)&&t.removeAttribute(l)),t.addEventListener(r,u,d);break e}l in t?t[l]=u:u===!0?t.setAttribute(l,""):Al(t,l,u)}}}function dt(t,r,l){switch(r){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":me("error",t),me("load",t);var u=!1,d=!1,g;for(g in l)if(l.hasOwnProperty(g)){var b=l[g];if(b!=null)switch(g){case"src":u=!0;break;case"srcSet":d=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(s(137,r));default:Oe(t,r,g,b,l,null)}}d&&Oe(t,r,"srcSet",l.srcSet,l,null),u&&Oe(t,r,"src",l.src,l,null);return;case"input":me("invalid",t);var _=g=b=d=null,C=null,R=null;for(u in l)if(l.hasOwnProperty(u)){var K=l[u];if(K!=null)switch(u){case"name":d=K;break;case"type":b=K;break;case"checked":C=K;break;case"defaultChecked":R=K;break;case"value":g=K;break;case"defaultValue":_=K;break;case"children":case"dangerouslySetInnerHTML":if(K!=null)throw Error(s(137,r));break;default:Oe(t,r,u,K,l,null)}}Ep(t,g,_,C,R,b,d,!1);return;case"select":me("invalid",t),u=b=g=null;for(d in l)if(l.hasOwnProperty(d)&&(_=l[d],_!=null))switch(d){case"value":g=_;break;case"defaultValue":b=_;break;case"multiple":u=_;default:Oe(t,r,d,_,l,null)}r=g,l=b,t.multiple=!!u,r!=null?Os(t,!!u,r,!1):l!=null&&Os(t,!!u,l,!0);return;case"textarea":me("invalid",t),g=d=u=null;for(b in l)if(l.hasOwnProperty(b)&&(_=l[b],_!=null))switch(b){case"value":u=_;break;case"defaultValue":d=_;break;case"children":g=_;break;case"dangerouslySetInnerHTML":if(_!=null)throw Error(s(91));break;default:Oe(t,r,b,_,l,null)}_p(t,u,d,g);return;case"option":for(C in l)if(l.hasOwnProperty(C)&&(u=l[C],u!=null))switch(C){case"selected":t.selected=u&&typeof u!="function"&&typeof u!="symbol";break;default:Oe(t,r,C,u,l,null)}return;case"dialog":me("beforetoggle",t),me("toggle",t),me("cancel",t),me("close",t);break;case"iframe":case"object":me("load",t);break;case"video":case"audio":for(u=0;u<Ca.length;u++)me(Ca[u],t);break;case"image":me("error",t),me("load",t);break;case"details":me("toggle",t);break;case"embed":case"source":case"link":me("error",t),me("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(R in l)if(l.hasOwnProperty(R)&&(u=l[R],u!=null))switch(R){case"children":case"dangerouslySetInnerHTML":throw Error(s(137,r));default:Oe(t,r,R,u,l,null)}return;default:if(ou(r)){for(K in l)l.hasOwnProperty(K)&&(u=l[K],u!==void 0&&Qf(t,r,K,u,l,void 0));return}}for(_ in l)l.hasOwnProperty(_)&&(u=l[_],u!=null&&Oe(t,r,_,u,l,null))}function Z1(t,r,l,u){switch(r){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var d=null,g=null,b=null,_=null,C=null,R=null,K=null;for(I in l){var Y=l[I];if(l.hasOwnProperty(I)&&Y!=null)switch(I){case"checked":break;case"value":break;case"defaultValue":C=Y;default:u.hasOwnProperty(I)||Oe(t,r,I,null,u,Y)}}for(var D in u){var I=u[D];if(Y=l[D],u.hasOwnProperty(D)&&(I!=null||Y!=null))switch(D){case"type":g=I;break;case"name":d=I;break;case"checked":R=I;break;case"defaultChecked":K=I;break;case"value":b=I;break;case"defaultValue":_=I;break;case"children":case"dangerouslySetInnerHTML":if(I!=null)throw Error(s(137,r));break;default:I!==Y&&Oe(t,r,D,I,u,Y)}}au(t,b,_,C,R,K,g,d);return;case"select":I=b=_=D=null;for(g in l)if(C=l[g],l.hasOwnProperty(g)&&C!=null)switch(g){case"value":break;case"multiple":I=C;default:u.hasOwnProperty(g)||Oe(t,r,g,null,u,C)}for(d in u)if(g=u[d],C=l[d],u.hasOwnProperty(d)&&(g!=null||C!=null))switch(d){case"value":D=g;break;case"defaultValue":_=g;break;case"multiple":b=g;default:g!==C&&Oe(t,r,d,g,u,C)}r=_,l=b,u=I,D!=null?Os(t,!!l,D,!1):!!u!=!!l&&(r!=null?Os(t,!!l,r,!0):Os(t,!!l,l?[]:"",!1));return;case"textarea":I=D=null;for(_ in l)if(d=l[_],l.hasOwnProperty(_)&&d!=null&&!u.hasOwnProperty(_))switch(_){case"value":break;case"children":break;default:Oe(t,r,_,null,u,d)}for(b in u)if(d=u[b],g=l[b],u.hasOwnProperty(b)&&(d!=null||g!=null))switch(b){case"value":D=d;break;case"defaultValue":I=d;break;case"children":break;case"dangerouslySetInnerHTML":if(d!=null)throw Error(s(91));break;default:d!==g&&Oe(t,r,b,d,u,g)}Tp(t,D,I);return;case"option":for(var te in l)if(D=l[te],l.hasOwnProperty(te)&&D!=null&&!u.hasOwnProperty(te))switch(te){case"selected":t.selected=!1;break;default:Oe(t,r,te,null,u,D)}for(C in u)if(D=u[C],I=l[C],u.hasOwnProperty(C)&&D!==I&&(D!=null||I!=null))switch(C){case"selected":t.selected=D&&typeof D!="function"&&typeof D!="symbol";break;default:Oe(t,r,C,D,u,I)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var oe in l)D=l[oe],l.hasOwnProperty(oe)&&D!=null&&!u.hasOwnProperty(oe)&&Oe(t,r,oe,null,u,D);for(R in u)if(D=u[R],I=l[R],u.hasOwnProperty(R)&&D!==I&&(D!=null||I!=null))switch(R){case"children":case"dangerouslySetInnerHTML":if(D!=null)throw Error(s(137,r));break;default:Oe(t,r,R,D,u,I)}return;default:if(ou(r)){for(var Le in l)D=l[Le],l.hasOwnProperty(Le)&&D!==void 0&&!u.hasOwnProperty(Le)&&Qf(t,r,Le,void 0,u,D);for(K in u)D=u[K],I=l[K],!u.hasOwnProperty(K)||D===I||D===void 0&&I===void 0||Qf(t,r,K,D,u,I);return}}for(var O in l)D=l[O],l.hasOwnProperty(O)&&D!=null&&!u.hasOwnProperty(O)&&Oe(t,r,O,null,u,D);for(Y in u)D=u[Y],I=l[Y],!u.hasOwnProperty(Y)||D===I||D==null&&I==null||Oe(t,r,Y,D,u,I)}function Ny(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function W1(){if(typeof performance.getEntriesByType=="function"){for(var t=0,r=0,l=performance.getEntriesByType("resource"),u=0;u<l.length;u++){var d=l[u],g=d.transferSize,b=d.initiatorType,_=d.duration;if(g&&_&&Ny(b)){for(b=0,_=d.responseEnd,u+=1;u<l.length;u++){var C=l[u],R=C.startTime;if(R>_)break;var K=C.transferSize,Y=C.initiatorType;K&&Ny(Y)&&(C=C.responseEnd,b+=K*(C<_?1:(_-R)/(C-R)))}if(--u,r+=8*(g+b)/(d.duration/1e3),t++,10<t)break}}if(0<t)return r/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t=="number")?t:5}var Pf=null,Jf=null;function _o(t){return t.nodeType===9?t:t.ownerDocument}function ky(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function My(t,r){if(t===0)switch(r){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&r==="foreignObject"?0:t}function Zf(t,r){return t==="textarea"||t==="noscript"||typeof r.children=="string"||typeof r.children=="number"||typeof r.children=="bigint"||typeof r.dangerouslySetInnerHTML=="object"&&r.dangerouslySetInnerHTML!==null&&r.dangerouslySetInnerHTML.__html!=null}var Wf=null;function ex(){var t=window.event;return t&&t.type==="popstate"?t===Wf?!1:(Wf=t,!0):(Wf=null,!1)}var Oy=typeof setTimeout=="function"?setTimeout:void 0,tx=typeof clearTimeout=="function"?clearTimeout:void 0,Ly=typeof Promise=="function"?Promise:void 0,nx=typeof queueMicrotask=="function"?queueMicrotask:typeof Ly<"u"?function(t){return Ly.resolve(null).then(t).catch(ix)}:Oy;function ix(t){setTimeout(function(){throw t})}function Ti(t){return t==="head"}function jy(t,r){var l=r,u=0;do{var d=l.nextSibling;if(t.removeChild(l),d&&d.nodeType===8)if(l=d.data,l==="/$"||l==="/&"){if(u===0){t.removeChild(d),cr(r);return}u--}else if(l==="$"||l==="$?"||l==="$~"||l==="$!"||l==="&")u++;else if(l==="html")ka(t.ownerDocument.documentElement);else if(l==="head"){l=t.ownerDocument.head,ka(l);for(var g=l.firstChild;g;){var b=g.nextSibling,_=g.nodeName;g[Fr]||_==="SCRIPT"||_==="STYLE"||_==="LINK"&&g.rel.toLowerCase()==="stylesheet"||l.removeChild(g),g=b}}else l==="body"&&ka(t.ownerDocument.body);l=d}while(l);cr(r)}function Ry(t,r){var l=t;t=0;do{var u=l.nextSibling;if(l.nodeType===1?r?(l._stashedDisplay=l.style.display,l.style.display="none"):(l.style.display=l._stashedDisplay||"",l.getAttribute("style")===""&&l.removeAttribute("style")):l.nodeType===3&&(r?(l._stashedText=l.nodeValue,l.nodeValue=""):l.nodeValue=l._stashedText||""),u&&u.nodeType===8)if(l=u.data,l==="/$"){if(t===0)break;t--}else l!=="$"&&l!=="$?"&&l!=="$~"&&l!=="$!"||t++;l=u}while(l)}function eh(t){var r=t.firstChild;for(r&&r.nodeType===10&&(r=r.nextSibling);r;){var l=r;switch(r=r.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":eh(l),su(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}t.removeChild(l)}}function sx(t,r,l,u){for(;t.nodeType===1;){var d=l;if(t.nodeName.toLowerCase()!==r.toLowerCase()){if(!u&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(u){if(!t[Fr])switch(r){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(g=t.getAttribute("rel"),g==="stylesheet"&&t.hasAttribute("data-precedence"))break;if(g!==d.rel||t.getAttribute("href")!==(d.href==null||d.href===""?null:d.href)||t.getAttribute("crossorigin")!==(d.crossOrigin==null?null:d.crossOrigin)||t.getAttribute("title")!==(d.title==null?null:d.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(g=t.getAttribute("src"),(g!==(d.src==null?null:d.src)||t.getAttribute("type")!==(d.type==null?null:d.type)||t.getAttribute("crossorigin")!==(d.crossOrigin==null?null:d.crossOrigin))&&g&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}}else if(r==="input"&&t.type==="hidden"){var g=d.name==null?null:""+d.name;if(d.type==="hidden"&&t.getAttribute("name")===g)return t}else return t;if(t=ln(t.nextSibling),t===null)break}return null}function rx(t,r,l){if(r==="")return null;for(;t.nodeType!==3;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!l||(t=ln(t.nextSibling),t===null))return null;return t}function Dy(t,r){for(;t.nodeType!==8;)if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!r||(t=ln(t.nextSibling),t===null))return null;return t}function th(t){return t.data==="$?"||t.data==="$~"}function nh(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function ax(t,r){var l=t.ownerDocument;if(t.data==="$~")t._reactRetry=r;else if(t.data!=="$?"||l.readyState!=="loading")r();else{var u=function(){r(),l.removeEventListener("DOMContentLoaded",u)};l.addEventListener("DOMContentLoaded",u),t._reactRetry=u}}function ln(t){for(;t!=null;t=t.nextSibling){var r=t.nodeType;if(r===1||r===3)break;if(r===8){if(r=t.data,r==="$"||r==="$!"||r==="$?"||r==="$~"||r==="&"||r==="F!"||r==="F")break;if(r==="/$"||r==="/&")return null}}return t}var ih=null;function By(t){t=t.nextSibling;for(var r=0;t;){if(t.nodeType===8){var l=t.data;if(l==="/$"||l==="/&"){if(r===0)return ln(t.nextSibling);r--}else l!=="$"&&l!=="$!"&&l!=="$?"&&l!=="$~"&&l!=="&"||r++}t=t.nextSibling}return null}function zy(t){t=t.previousSibling;for(var r=0;t;){if(t.nodeType===8){var l=t.data;if(l==="$"||l==="$!"||l==="$?"||l==="$~"||l==="&"){if(r===0)return t;r--}else l!=="/$"&&l!=="/&"||r++}t=t.previousSibling}return null}function Uy(t,r,l){switch(r=_o(l),t){case"html":if(t=r.documentElement,!t)throw Error(s(452));return t;case"head":if(t=r.head,!t)throw Error(s(453));return t;case"body":if(t=r.body,!t)throw Error(s(454));return t;default:throw Error(s(451))}}function ka(t){for(var r=t.attributes;r.length;)t.removeAttributeNode(r[0]);su(t)}var on=new Map,Hy=new Set;function Ao(t){return typeof t.getRootNode=="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}var Pn=J.d;J.d={f:lx,r:ox,D:cx,C:ux,L:fx,m:hx,X:px,S:dx,M:gx};function lx(){var t=Pn.f(),r=yo();return t||r}function ox(t){var r=Ns(t);r!==null&&r.tag===5&&r.type==="form"?nm(r):Pn.r(t)}var ar=typeof document>"u"?null:document;function qy(t,r,l){var u=ar;if(u&&typeof r=="string"&&r){var d=Wt(r);d='link[rel="'+t+'"][href="'+d+'"]',typeof l=="string"&&(d+='[crossorigin="'+l+'"]'),Hy.has(d)||(Hy.add(d),t={rel:t,crossOrigin:l,href:r},u.querySelector(d)===null&&(r=u.createElement("link"),dt(r,"link",t),lt(r),u.head.appendChild(r)))}}function cx(t){Pn.D(t),qy("dns-prefetch",t,null)}function ux(t,r){Pn.C(t,r),qy("preconnect",t,r)}function fx(t,r,l){Pn.L(t,r,l);var u=ar;if(u&&t&&r){var d='link[rel="preload"][as="'+Wt(r)+'"]';r==="image"&&l&&l.imageSrcSet?(d+='[imagesrcset="'+Wt(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(d+='[imagesizes="'+Wt(l.imageSizes)+'"]')):d+='[href="'+Wt(t)+'"]';var g=d;switch(r){case"style":g=lr(t);break;case"script":g=or(t)}on.has(g)||(t=m({rel:"preload",href:r==="image"&&l&&l.imageSrcSet?void 0:t,as:r},l),on.set(g,t),u.querySelector(d)!==null||r==="style"&&u.querySelector(Ma(g))||r==="script"&&u.querySelector(Oa(g))||(r=u.createElement("link"),dt(r,"link",t),lt(r),u.head.appendChild(r)))}}function hx(t,r){Pn.m(t,r);var l=ar;if(l&&t){var u=r&&typeof r.as=="string"?r.as:"script",d='link[rel="modulepreload"][as="'+Wt(u)+'"][href="'+Wt(t)+'"]',g=d;switch(u){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":g=or(t)}if(!on.has(g)&&(t=m({rel:"modulepreload",href:t},r),on.set(g,t),l.querySelector(d)===null)){switch(u){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(Oa(g)))return}u=l.createElement("link"),dt(u,"link",t),lt(u),l.head.appendChild(u)}}}function dx(t,r,l){Pn.S(t,r,l);var u=ar;if(u&&t){var d=ks(u).hoistableStyles,g=lr(t);r=r||"default";var b=d.get(g);if(!b){var _={loading:0,preload:null};if(b=u.querySelector(Ma(g)))_.loading=5;else{t=m({rel:"stylesheet",href:t,"data-precedence":r},l),(l=on.get(g))&&sh(t,l);var C=b=u.createElement("link");lt(C),dt(C,"link",t),C._p=new Promise(function(R,K){C.onload=R,C.onerror=K}),C.addEventListener("load",function(){_.loading|=1}),C.addEventListener("error",function(){_.loading|=2}),_.loading|=4,Co(b,r,u)}b={type:"stylesheet",instance:b,count:1,state:_},d.set(g,b)}}}function px(t,r){Pn.X(t,r);var l=ar;if(l&&t){var u=ks(l).hoistableScripts,d=or(t),g=u.get(d);g||(g=l.querySelector(Oa(d)),g||(t=m({src:t,async:!0},r),(r=on.get(d))&&rh(t,r),g=l.createElement("script"),lt(g),dt(g,"link",t),l.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},u.set(d,g))}}function gx(t,r){Pn.M(t,r);var l=ar;if(l&&t){var u=ks(l).hoistableScripts,d=or(t),g=u.get(d);g||(g=l.querySelector(Oa(d)),g||(t=m({src:t,async:!0,type:"module"},r),(r=on.get(d))&&rh(t,r),g=l.createElement("script"),lt(g),dt(g,"link",t),l.head.appendChild(g)),g={type:"script",instance:g,count:1,state:null},u.set(d,g))}}function Iy(t,r,l,u){var d=(d=de.current)?Ao(d):null;if(!d)throw Error(s(446));switch(t){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(r=lr(l.href),l=ks(d).hoistableStyles,u=l.get(r),u||(u={type:"style",instance:null,count:0,state:null},l.set(r,u)),u):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){t=lr(l.href);var g=ks(d).hoistableStyles,b=g.get(t);if(b||(d=d.ownerDocument||d,b={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},g.set(t,b),(g=d.querySelector(Ma(t)))&&!g._p&&(b.instance=g,b.state.loading=5),on.has(t)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},on.set(t,l),g||mx(d,t,l,b.state))),r&&u===null)throw Error(s(528,""));return b}if(r&&u!==null)throw Error(s(529,""));return null;case"script":return r=l.async,l=l.src,typeof l=="string"&&r&&typeof r!="function"&&typeof r!="symbol"?(r=or(l),l=ks(d).hoistableScripts,u=l.get(r),u||(u={type:"script",instance:null,count:0,state:null},l.set(r,u)),u):{type:"void",instance:null,count:0,state:null};default:throw Error(s(444,t))}}function lr(t){return'href="'+Wt(t)+'"'}function Ma(t){return'link[rel="stylesheet"]['+t+"]"}function $y(t){return m({},t,{"data-precedence":t.precedence,precedence:null})}function mx(t,r,l,u){t.querySelector('link[rel="preload"][as="style"]['+r+"]")?u.loading=1:(r=t.createElement("link"),u.preload=r,r.addEventListener("load",function(){return u.loading|=1}),r.addEventListener("error",function(){return u.loading|=2}),dt(r,"link",l),lt(r),t.head.appendChild(r))}function or(t){return'[src="'+Wt(t)+'"]'}function Oa(t){return"script[async]"+t}function Vy(t,r,l){if(r.count++,r.instance===null)switch(r.type){case"style":var u=t.querySelector('style[data-href~="'+Wt(l.href)+'"]');if(u)return r.instance=u,lt(u),u;var d=m({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return u=(t.ownerDocument||t).createElement("style"),lt(u),dt(u,"style",d),Co(u,l.precedence,t),r.instance=u;case"stylesheet":d=lr(l.href);var g=t.querySelector(Ma(d));if(g)return r.state.loading|=4,r.instance=g,lt(g),g;u=$y(l),(d=on.get(d))&&sh(u,d),g=(t.ownerDocument||t).createElement("link"),lt(g);var b=g;return b._p=new Promise(function(_,C){b.onload=_,b.onerror=C}),dt(g,"link",u),r.state.loading|=4,Co(g,l.precedence,t),r.instance=g;case"script":return g=or(l.src),(d=t.querySelector(Oa(g)))?(r.instance=d,lt(d),d):(u=l,(d=on.get(g))&&(u=m({},l),rh(u,d)),t=t.ownerDocument||t,d=t.createElement("script"),lt(d),dt(d,"link",u),t.head.appendChild(d),r.instance=d);case"void":return null;default:throw Error(s(443,r.type))}else r.type==="stylesheet"&&(r.state.loading&4)===0&&(u=r.instance,r.state.loading|=4,Co(u,l.precedence,t));return r.instance}function Co(t,r,l){for(var u=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),d=u.length?u[u.length-1]:null,g=d,b=0;b<u.length;b++){var _=u[b];if(_.dataset.precedence===r)g=_;else if(g!==d)break}g?g.parentNode.insertBefore(t,g.nextSibling):(r=l.nodeType===9?l.head:l,r.insertBefore(t,r.firstChild))}function sh(t,r){t.crossOrigin==null&&(t.crossOrigin=r.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=r.referrerPolicy),t.title==null&&(t.title=r.title)}function rh(t,r){t.crossOrigin==null&&(t.crossOrigin=r.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=r.referrerPolicy),t.integrity==null&&(t.integrity=r.integrity)}var No=null;function Gy(t,r,l){if(No===null){var u=new Map,d=No=new Map;d.set(l,u)}else d=No,u=d.get(l),u||(u=new Map,d.set(l,u));if(u.has(t))return u;for(u.set(t,null),l=l.getElementsByTagName(t),d=0;d<l.length;d++){var g=l[d];if(!(g[Fr]||g[ct]||t==="link"&&g.getAttribute("rel")==="stylesheet")&&g.namespaceURI!=="http://www.w3.org/2000/svg"){var b=g.getAttribute(r)||"";b=t+b;var _=u.get(b);_?_.push(g):u.set(b,[g])}}return u}function Ky(t,r,l){t=t.ownerDocument||t,t.head.insertBefore(l,r==="title"?t.querySelector("head > title"):null)}function yx(t,r,l){if(l===1||r.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof r.precedence!="string"||typeof r.href!="string"||r.href==="")break;return!0;case"link":if(typeof r.rel!="string"||typeof r.href!="string"||r.href===""||r.onLoad||r.onError)break;switch(r.rel){case"stylesheet":return t=r.disabled,typeof r.precedence=="string"&&t==null;default:return!0}case"script":if(r.async&&typeof r.async!="function"&&typeof r.async!="symbol"&&!r.onLoad&&!r.onError&&r.src&&typeof r.src=="string")return!0}return!1}function Xy(t){return!(t.type==="stylesheet"&&(t.state.loading&3)===0)}function bx(t,r,l,u){if(l.type==="stylesheet"&&(typeof u.media!="string"||matchMedia(u.media).matches!==!1)&&(l.state.loading&4)===0){if(l.instance===null){var d=lr(u.href),g=r.querySelector(Ma(d));if(g){r=g._p,r!==null&&typeof r=="object"&&typeof r.then=="function"&&(t.count++,t=ko.bind(t),r.then(t,t)),l.state.loading|=4,l.instance=g,lt(g);return}g=r.ownerDocument||r,u=$y(u),(d=on.get(d))&&sh(u,d),g=g.createElement("link"),lt(g);var b=g;b._p=new Promise(function(_,C){b.onload=_,b.onerror=C}),dt(g,"link",u),l.instance=g}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(l,r),(r=l.state.preload)&&(l.state.loading&3)===0&&(t.count++,l=ko.bind(t),r.addEventListener("load",l),r.addEventListener("error",l))}}var ah=0;function vx(t,r){return t.stylesheets&&t.count===0&&Oo(t,t.stylesheets),0<t.count||0<t.imgCount?function(l){var u=setTimeout(function(){if(t.stylesheets&&Oo(t,t.stylesheets),t.unsuspend){var g=t.unsuspend;t.unsuspend=null,g()}},6e4+r);0<t.imgBytes&&ah===0&&(ah=62500*W1());var d=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&Oo(t,t.stylesheets),t.unsuspend)){var g=t.unsuspend;t.unsuspend=null,g()}},(t.imgBytes>ah?50:800)+r);return t.unsuspend=l,function(){t.unsuspend=null,clearTimeout(u),clearTimeout(d)}}:null}function ko(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Oo(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}var Mo=null;function Oo(t,r){t.stylesheets=null,t.unsuspend!==null&&(t.count++,Mo=new Map,r.forEach(Sx,t),Mo=null,ko.call(t))}function Sx(t,r){if(!(r.state.loading&4)){var l=Mo.get(t);if(l)var u=l.get(null);else{l=new Map,Mo.set(t,l);for(var d=t.querySelectorAll("link[data-precedence],style[data-precedence]"),g=0;g<d.length;g++){var b=d[g];(b.nodeName==="LINK"||b.getAttribute("media")!=="not all")&&(l.set(b.dataset.precedence,b),u=b)}u&&l.set(null,u)}d=r.instance,b=d.getAttribute("data-precedence"),g=l.get(b)||u,g===u&&l.set(null,d),l.set(b,d),this.count++,u=ko.bind(this),d.addEventListener("load",u),d.addEventListener("error",u),g?g.parentNode.insertBefore(d,g.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(d,t.firstChild)),r.state.loading|=4}}var La={$$typeof:B,Provider:null,Consumer:null,_currentValue:se,_currentValue2:se,_threadCount:0};function wx(t,r,l,u,d,g,b,_,C){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=eu(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=eu(0),this.hiddenUpdates=eu(null),this.identifierPrefix=u,this.onUncaughtError=d,this.onCaughtError=g,this.onRecoverableError=b,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=C,this.incompleteTransitions=new Map}function Fy(t,r,l,u,d,g,b,_,C,R,K,Y){return t=new wx(t,r,l,b,C,R,K,Y,_),r=1,g===!0&&(r|=24),g=Gt(3,null,null,r),t.current=g,g.stateNode=t,r=Uu(),r.refCount++,t.pooledCache=r,r.refCount++,g.memoizedState={element:u,isDehydrated:l,cache:r},$u(g),t}function Yy(t){return t?(t=Hs,t):Hs}function Qy(t,r,l,u,d,g){d=Yy(d),u.context===null?u.context=d:u.pendingContext=d,u=di(r),u.payload={element:l},g=g===void 0?null:g,g!==null&&(u.callback=g),l=pi(t,u,r),l!==null&&(Dt(l,t,r),ua(l,t,r))}function Py(t,r){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var l=t.retryLane;t.retryLane=l!==0&&l<r?l:r}}function lh(t,r){Py(t,r),(t=t.alternate)&&Py(t,r)}function Jy(t){if(t.tag===13||t.tag===31){var r=Fi(t,67108864);r!==null&&Dt(r,t,67108864),lh(t,67108864)}}function Zy(t){if(t.tag===13||t.tag===31){var r=Qt();r=tu(r);var l=Fi(t,r);l!==null&&Dt(l,t,r),lh(t,r)}}var Lo=!0;function xx(t,r,l,u){var d=q.T;q.T=null;var g=J.p;try{J.p=2,oh(t,r,l,u)}finally{J.p=g,q.T=d}}function Ex(t,r,l,u){var d=q.T;q.T=null;var g=J.p;try{J.p=8,oh(t,r,l,u)}finally{J.p=g,q.T=d}}function oh(t,r,l,u){if(Lo){var d=ch(u);if(d===null)Yf(t,r,u,jo,l),eb(t,u);else if(_x(d,t,r,l,u))u.stopPropagation();else if(eb(t,u),r&4&&-1<Tx.indexOf(t)){for(;d!==null;){var g=Ns(d);if(g!==null)switch(g.tag){case 3:if(g=g.stateNode,g.current.memoizedState.isDehydrated){var b=Tt(g.pendingLanes);if(b!==0){var _=g;for(_.pendingLanes|=2,_.entangledLanes|=2;b;){var C=1<<31-at(b);_.entanglements[1]|=C,b&=~C}An(g),(Ae&6)===0&&(go=Je()+500,Aa(0))}}break;case 31:case 13:_=Fi(g,2),_!==null&&Dt(_,g,2),yo(),lh(g,2)}if(g=ch(u),g===null&&Yf(t,r,u,jo,l),g===d)break;d=g}d!==null&&u.stopPropagation()}else Yf(t,r,u,null,l)}}function ch(t){return t=uu(t),uh(t)}var jo=null;function uh(t){if(jo=null,t=Cs(t),t!==null){var r=o(t);if(r===null)t=null;else{var l=r.tag;if(l===13){if(t=c(r),t!==null)return t;t=null}else if(l===31){if(t=f(r),t!==null)return t;t=null}else if(l===3){if(r.stateNode.current.memoizedState.isDehydrated)return r.tag===3?r.stateNode.containerInfo:null;t=null}else r!==t&&(t=null)}}return jo=t,null}function Wy(t){switch(t){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Yc()){case xl:return 2;case El:return 8;case Ts:case Tl:return 32;case _s:return 268435456;default:return 32}default:return 32}}var fh=!1,_i=null,Ai=null,Ci=null,ja=new Map,Ra=new Map,Ni=[],Tx="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function eb(t,r){switch(t){case"focusin":case"focusout":_i=null;break;case"dragenter":case"dragleave":Ai=null;break;case"mouseover":case"mouseout":Ci=null;break;case"pointerover":case"pointerout":ja.delete(r.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ra.delete(r.pointerId)}}function Da(t,r,l,u,d,g){return t===null||t.nativeEvent!==g?(t={blockedOn:r,domEventName:l,eventSystemFlags:u,nativeEvent:g,targetContainers:[d]},r!==null&&(r=Ns(r),r!==null&&Jy(r)),t):(t.eventSystemFlags|=u,r=t.targetContainers,d!==null&&r.indexOf(d)===-1&&r.push(d),t)}function _x(t,r,l,u,d){switch(r){case"focusin":return _i=Da(_i,t,r,l,u,d),!0;case"dragenter":return Ai=Da(Ai,t,r,l,u,d),!0;case"mouseover":return Ci=Da(Ci,t,r,l,u,d),!0;case"pointerover":var g=d.pointerId;return ja.set(g,Da(ja.get(g)||null,t,r,l,u,d)),!0;case"gotpointercapture":return g=d.pointerId,Ra.set(g,Da(Ra.get(g)||null,t,r,l,u,d)),!0}return!1}function tb(t){var r=Cs(t.target);if(r!==null){var l=o(r);if(l!==null){if(r=l.tag,r===13){if(r=c(l),r!==null){t.blockedOn=r,gp(t.priority,function(){Zy(l)});return}}else if(r===31){if(r=f(l),r!==null){t.blockedOn=r,gp(t.priority,function(){Zy(l)});return}}else if(r===3&&l.stateNode.current.memoizedState.isDehydrated){t.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}t.blockedOn=null}function Ro(t){if(t.blockedOn!==null)return!1;for(var r=t.targetContainers;0<r.length;){var l=ch(t.nativeEvent);if(l===null){l=t.nativeEvent;var u=new l.constructor(l.type,l);cu=u,l.target.dispatchEvent(u),cu=null}else return r=Ns(l),r!==null&&Jy(r),t.blockedOn=l,!1;r.shift()}return!0}function nb(t,r,l){Ro(t)&&l.delete(r)}function Ax(){fh=!1,_i!==null&&Ro(_i)&&(_i=null),Ai!==null&&Ro(Ai)&&(Ai=null),Ci!==null&&Ro(Ci)&&(Ci=null),ja.forEach(nb),Ra.forEach(nb)}function Do(t,r){t.blockedOn===r&&(t.blockedOn=null,fh||(fh=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,Ax)))}var Bo=null;function ib(t){Bo!==t&&(Bo=t,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){Bo===t&&(Bo=null);for(var r=0;r<t.length;r+=3){var l=t[r],u=t[r+1],d=t[r+2];if(typeof u!="function"){if(uh(u||l)===null)continue;break}var g=Ns(l);g!==null&&(t.splice(r,3),r-=3,cf(g,{pending:!0,data:d,method:l.method,action:u},u,d))}}))}function cr(t){function r(C){return Do(C,t)}_i!==null&&Do(_i,t),Ai!==null&&Do(Ai,t),Ci!==null&&Do(Ci,t),ja.forEach(r),Ra.forEach(r);for(var l=0;l<Ni.length;l++){var u=Ni[l];u.blockedOn===t&&(u.blockedOn=null)}for(;0<Ni.length&&(l=Ni[0],l.blockedOn===null);)tb(l),l.blockedOn===null&&Ni.shift();if(l=(t.ownerDocument||t).$$reactFormReplay,l!=null)for(u=0;u<l.length;u+=3){var d=l[u],g=l[u+1],b=d[kt]||null;if(typeof g=="function")b||ib(l);else if(b){var _=null;if(g&&g.hasAttribute("formAction")){if(d=g,b=g[kt]||null)_=b.formAction;else if(uh(d)!==null)continue}else _=b.action;typeof _=="function"?l[u+1]=_:(l.splice(u,3),u-=3),ib(l)}}}function sb(){function t(g){g.canIntercept&&g.info==="react-transition"&&g.intercept({handler:function(){return new Promise(function(b){return d=b})},focusReset:"manual",scroll:"manual"})}function r(){d!==null&&(d(),d=null),u||setTimeout(l,20)}function l(){if(!u&&!navigation.transition){var g=navigation.currentEntry;g&&g.url!=null&&navigation.navigate(g.url,{state:g.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var u=!1,d=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",r),navigation.addEventListener("navigateerror",r),setTimeout(l,100),function(){u=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",r),navigation.removeEventListener("navigateerror",r),d!==null&&(d(),d=null)}}}function hh(t){this._internalRoot=t}zo.prototype.render=hh.prototype.render=function(t){var r=this._internalRoot;if(r===null)throw Error(s(409));var l=r.current,u=Qt();Qy(l,u,t,r,null,null)},zo.prototype.unmount=hh.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var r=t.containerInfo;Qy(t.current,2,null,t,null,null),yo(),r[As]=null}};function zo(t){this._internalRoot=t}zo.prototype.unstable_scheduleHydration=function(t){if(t){var r=pp();t={blockedOn:null,target:t,priority:r};for(var l=0;l<Ni.length&&r!==0&&r<Ni[l].priority;l++);Ni.splice(l,0,t),l===0&&tb(t)}};var rb=e.version;if(rb!=="19.2.1")throw Error(s(527,rb,"19.2.1"));J.findDOMNode=function(t){var r=t._reactInternals;if(r===void 0)throw typeof t.render=="function"?Error(s(188)):(t=Object.keys(t).join(","),Error(s(268,t)));return t=p(r),t=t!==null?y(t):null,t=t===null?null:t.stateNode,t};var Cx={bundleType:0,version:"19.2.1",rendererPackageName:"react-dom",currentDispatcherRef:q,reconcilerVersion:"19.2.1"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Uo=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Uo.isDisabled&&Uo.supportsFiber)try{Ii=Uo.inject(Cx),it=Uo}catch{}}return za.createRoot=function(t,r){if(!a(t))throw Error(s(299));var l=!1,u="",d=hm,g=dm,b=pm;return r!=null&&(r.unstable_strictMode===!0&&(l=!0),r.identifierPrefix!==void 0&&(u=r.identifierPrefix),r.onUncaughtError!==void 0&&(d=r.onUncaughtError),r.onCaughtError!==void 0&&(g=r.onCaughtError),r.onRecoverableError!==void 0&&(b=r.onRecoverableError)),r=Fy(t,1,!1,null,null,l,u,null,d,g,b,sb),t[As]=r.current,Ff(t),new hh(r)},za.hydrateRoot=function(t,r,l){if(!a(t))throw Error(s(299));var u=!1,d="",g=hm,b=dm,_=pm,C=null;return l!=null&&(l.unstable_strictMode===!0&&(u=!0),l.identifierPrefix!==void 0&&(d=l.identifierPrefix),l.onUncaughtError!==void 0&&(g=l.onUncaughtError),l.onCaughtError!==void 0&&(b=l.onCaughtError),l.onRecoverableError!==void 0&&(_=l.onRecoverableError),l.formState!==void 0&&(C=l.formState)),r=Fy(t,1,!0,r,l??null,u,d,C,g,b,_,sb),r.context=Yy(null),l=r.current,u=Qt(),u=tu(u),d=di(u),d.callback=null,pi(l,d,u),l=u,r.current.lanes=l,Xr(r,l),An(r),t[As]=r.current,Ff(t),new zo(r)},za.version="19.2.1",za}var yb;function Xx(){if(yb)return gh.exports;yb=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}return n(),gh.exports=Kx(),gh.exports}var _2=Xx();const pd=new Map([["APIRequestContext.fetch",{title:'{method} "{url}"'}],["APIRequestContext.fetchResponseBody",{title:"Get response body",group:"getter"}],["APIRequestContext.fetchLog",{internal:!0}],["APIRequestContext.storageState",{title:"Get storage state",group:"configuration"}],["APIRequestContext.disposeAPIResponse",{internal:!0}],["APIRequestContext.dispose",{internal:!0}],["LocalUtils.zip",{internal:!0}],["LocalUtils.harOpen",{internal:!0}],["LocalUtils.harLookup",{internal:!0}],["LocalUtils.harClose",{internal:!0}],["LocalUtils.harUnzip",{internal:!0}],["LocalUtils.connect",{internal:!0}],["LocalUtils.tracingStarted",{internal:!0}],["LocalUtils.addStackToTracingNoReply",{internal:!0}],["LocalUtils.traceDiscarded",{internal:!0}],["LocalUtils.globToRegex",{internal:!0}],["Root.initialize",{internal:!0}],["Playwright.newRequest",{title:"Create request context"}],["DebugController.initialize",{internal:!0}],["DebugController.setReportStateChanged",{internal:!0}],["DebugController.setRecorderMode",{internal:!0}],["DebugController.highlight",{internal:!0}],["DebugController.hideHighlight",{internal:!0}],["DebugController.resume",{internal:!0}],["DebugController.kill",{internal:!0}],["SocksSupport.socksConnected",{internal:!0}],["SocksSupport.socksFailed",{internal:!0}],["SocksSupport.socksData",{internal:!0}],["SocksSupport.socksError",{internal:!0}],["SocksSupport.socksEnd",{internal:!0}],["BrowserType.launch",{title:"Launch browser"}],["BrowserType.launchPersistentContext",{title:"Launch persistent context"}],["BrowserType.connectOverCDP",{title:"Connect over CDP"}],["BrowserType.connectOverCDPTransport",{title:"Connect over CDP transport"}],["Browser.startServer",{title:"Start server"}],["Browser.stopServer",{title:"Stop server"}],["Browser.close",{title:"Close browser",pausesBeforeAction:!0}],["Browser.killForTests",{internal:!0}],["Browser.defaultUserAgentForTest",{internal:!0}],["Browser.newContext",{title:"Create context"}],["Browser.newContextForReuse",{internal:!0}],["Browser.disconnectFromReusedContext",{internal:!0}],["Browser.newBrowserCDPSession",{title:"Create CDP session",group:"configuration"}],["Browser.startTracing",{title:"Start browser tracing",group:"configuration"}],["Browser.stopTracing",{title:"Stop browser tracing",group:"configuration"}],["EventTarget.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["BrowserContext.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["Page.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["Worker.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["WebSocket.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["ElectronApplication.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["AndroidDevice.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["PageAgent.waitForEventInfo",{title:'Wait for event "{info.event}"',snapshot:!0}],["BrowserContext.addCookies",{title:"Add cookies",group:"configuration"}],["BrowserContext.addInitScript",{title:"Add init script",group:"configuration"}],["BrowserContext.clearCookies",{title:"Clear cookies",group:"configuration"}],["BrowserContext.clearPermissions",{title:"Clear permissions",group:"configuration"}],["BrowserContext.close",{title:"Close context",pausesBeforeAction:!0}],["BrowserContext.cookies",{title:"Get cookies",group:"getter"}],["BrowserContext.exposeBinding",{title:"Expose binding",group:"configuration"}],["BrowserContext.grantPermissions",{title:"Grant permissions",group:"configuration"}],["BrowserContext.newPage",{title:"Create page"}],["BrowserContext.registerSelectorEngine",{internal:!0}],["BrowserContext.setTestIdAttributeName",{internal:!0}],["BrowserContext.setExtraHTTPHeaders",{title:"Set extra HTTP headers",group:"configuration"}],["BrowserContext.setGeolocation",{title:"Set geolocation",group:"configuration"}],["BrowserContext.setHTTPCredentials",{title:"Set HTTP credentials",group:"configuration"}],["BrowserContext.setNetworkInterceptionPatterns",{title:"Route requests",group:"route"}],["BrowserContext.setWebSocketInterceptionPatterns",{title:"Route WebSockets",group:"route"}],["BrowserContext.setOffline",{title:"Set offline mode"}],["BrowserContext.storageState",{title:"Get storage state",group:"configuration"}],["BrowserContext.setStorageState",{title:"Set storage state",group:"configuration"}],["BrowserContext.pause",{title:"Pause"}],["BrowserContext.enableRecorder",{internal:!0}],["BrowserContext.disableRecorder",{internal:!0}],["BrowserContext.exposeConsoleApi",{internal:!0}],["BrowserContext.newCDPSession",{title:"Create CDP session",group:"configuration"}],["BrowserContext.harStart",{internal:!0}],["BrowserContext.harExport",{internal:!0}],["BrowserContext.createTempFiles",{internal:!0}],["BrowserContext.updateSubscription",{internal:!0}],["BrowserContext.clockFastForward",{title:'Fast forward clock "{ticksNumber|ticksString}"'}],["BrowserContext.clockInstall",{title:'Install clock "{timeNumber|timeString}"'}],["BrowserContext.clockPauseAt",{title:'Pause clock "{timeNumber|timeString}"'}],["BrowserContext.clockResume",{title:"Resume clock"}],["BrowserContext.clockRunFor",{title:'Run clock "{ticksNumber|ticksString}"'}],["BrowserContext.clockSetFixedTime",{title:'Set fixed time "{timeNumber|timeString}"'}],["BrowserContext.clockSetSystemTime",{title:'Set system time "{timeNumber|timeString}"'}],["Page.addInitScript",{title:"Add init script",group:"configuration"}],["Page.close",{title:"Close page",pausesBeforeAction:!0}],["Page.clearConsoleMessages",{title:"Clear console messages"}],["Page.consoleMessages",{title:"Get console messages",group:"getter"}],["Page.emulateMedia",{title:"Emulate media",snapshot:!0,pausesBeforeAction:!0}],["Page.exposeBinding",{title:"Expose binding",group:"configuration"}],["Page.goBack",{title:"Go back",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.goForward",{title:"Go forward",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.requestGC",{title:"Request garbage collection",group:"configuration"}],["Page.registerLocatorHandler",{title:"Register locator handler"}],["Page.resolveLocatorHandlerNoReply",{internal:!0}],["Page.unregisterLocatorHandler",{title:"Unregister locator handler"}],["Page.reload",{title:"Reload",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.expectScreenshot",{title:"Expect screenshot",snapshot:!0,pausesBeforeAction:!0}],["Page.screenshot",{title:"Screenshot",snapshot:!0,pausesBeforeAction:!0}],["Page.setExtraHTTPHeaders",{title:"Set extra HTTP headers",group:"configuration"}],["Page.setNetworkInterceptionPatterns",{title:"Route requests",group:"route"}],["Page.setWebSocketInterceptionPatterns",{title:"Route WebSockets",group:"route"}],["Page.setViewportSize",{title:"Set viewport size",snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardDown",{title:'Key down "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardUp",{title:'Key up "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardInsertText",{title:'Insert "{text}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardType",{title:'Type "{text}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.keyboardPress",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseMove",{title:"Mouse move",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseDown",{title:"Mouse down",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseUp",{title:"Mouse up",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseClick",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.mouseWheel",{title:"Mouse wheel",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.touchscreenTap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Page.clearPageErrors",{title:"Clear page errors"}],["Page.pageErrors",{title:"Get page errors",group:"getter"}],["Page.pdf",{title:"PDF"}],["Page.requests",{title:"Get network requests",group:"getter"}],["Page.snapshotForAI",{internal:!0}],["Page.startJSCoverage",{title:"Start JS coverage",group:"configuration"}],["Page.stopJSCoverage",{title:"Stop JS coverage",group:"configuration"}],["Page.startCSSCoverage",{title:"Start CSS coverage",group:"configuration"}],["Page.stopCSSCoverage",{title:"Stop CSS coverage",group:"configuration"}],["Page.bringToFront",{title:"Bring to front"}],["Page.pickLocator",{title:"Pick locator",group:"configuration"}],["Page.cancelPickLocator",{title:"Cancel pick locator",group:"configuration"}],["Page.startScreencast",{title:"Start screencast",group:"configuration"}],["Page.stopScreencast",{title:"Stop screencast",group:"configuration"}],["Page.videoStart",{title:"Start video recording",group:"configuration"}],["Page.videoStop",{title:"Stop video recording",group:"configuration"}],["Page.updateSubscription",{internal:!0}],["Page.agent",{internal:!0}],["Page.setDockTile",{internal:!0}],["Frame.evalOnSelector",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.evalOnSelectorAll",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.addScriptTag",{title:"Add script tag",snapshot:!0,pausesBeforeAction:!0}],["Frame.addStyleTag",{title:"Add style tag",snapshot:!0,pausesBeforeAction:!0}],["Frame.ariaSnapshot",{title:"Aria snapshot",snapshot:!0,pausesBeforeAction:!0}],["Frame.blur",{title:"Blur",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.check",{title:"Check",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.click",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.content",{title:"Get content",snapshot:!0,pausesBeforeAction:!0}],["Frame.dragAndDrop",{title:"Drag and drop",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.dblclick",{title:"Double click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.dispatchEvent",{title:'Dispatch "{type}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["Frame.fill",{title:'Fill "{value}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.focus",{title:"Focus",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.frameElement",{title:"Get frame element",group:"getter"}],["Frame.resolveSelector",{internal:!0}],["Frame.highlight",{title:"Highlight element",group:"configuration"}],["Frame.getAttribute",{title:'Get attribute "{name}"',snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.goto",{title:'Navigate to "{url}"',slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["Frame.hover",{title:"Hover",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.innerHTML",{title:"Get HTML",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.innerText",{title:"Get inner text",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.inputValue",{title:"Get input value",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isChecked",{title:"Is checked",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isDisabled",{title:"Is disabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isEnabled",{title:"Is enabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isHidden",{title:"Is hidden",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isVisible",{title:"Is visible",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.isEditable",{title:"Is editable",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.press",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.querySelector",{title:"Query selector",snapshot:!0}],["Frame.querySelectorAll",{title:"Query selector all",snapshot:!0}],["Frame.queryCount",{title:"Query count",snapshot:!0,pausesBeforeAction:!0}],["Frame.selectOption",{title:"Select option",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.setContent",{title:"Set content",snapshot:!0,pausesBeforeAction:!0}],["Frame.setInputFiles",{title:"Set input files",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.tap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.textContent",{title:"Get text content",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["Frame.title",{title:"Get page title",group:"getter"}],["Frame.type",{title:'Type "{text}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.uncheck",{title:"Uncheck",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["Frame.waitForTimeout",{title:"Wait for timeout",snapshot:!0}],["Frame.waitForFunction",{title:"Wait for function",snapshot:!0,pausesBeforeAction:!0}],["Frame.waitForSelector",{title:"Wait for selector",snapshot:!0}],["Frame.expect",{title:'Expect "{expression}"',snapshot:!0,pausesBeforeAction:!0}],["Worker.evaluateExpression",{title:"Evaluate"}],["Worker.evaluateExpressionHandle",{title:"Evaluate"}],["Worker.updateSubscription",{internal:!0}],["Disposable.dispose",{internal:!0}],["JSHandle.dispose",{internal:!0}],["ElementHandle.dispose",{internal:!0}],["JSHandle.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evaluateExpression",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["JSHandle.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evaluateExpressionHandle",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["JSHandle.getPropertyList",{title:"Get property list",group:"getter"}],["ElementHandle.getPropertyList",{title:"Get property list",group:"getter"}],["JSHandle.getProperty",{title:"Get JS property",group:"getter"}],["ElementHandle.getProperty",{title:"Get JS property",group:"getter"}],["JSHandle.jsonValue",{title:"Get JSON value",group:"getter"}],["ElementHandle.jsonValue",{title:"Get JSON value",group:"getter"}],["ElementHandle.evalOnSelector",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.evalOnSelectorAll",{title:"Evaluate",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.boundingBox",{title:"Get bounding box",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.check",{title:"Check",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.click",{title:"Click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.contentFrame",{title:"Get content frame",group:"getter"}],["ElementHandle.dblclick",{title:"Double click",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.dispatchEvent",{title:"Dispatch event",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.fill",{title:'Fill "{value}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.focus",{title:"Focus",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.getAttribute",{title:"Get attribute",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.hover",{title:"Hover",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.innerHTML",{title:"Get HTML",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.innerText",{title:"Get inner text",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.inputValue",{title:"Get input value",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isChecked",{title:"Is checked",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isDisabled",{title:"Is disabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isEditable",{title:"Is editable",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isEnabled",{title:"Is enabled",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isHidden",{title:"Is hidden",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.isVisible",{title:"Is visible",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.ownerFrame",{title:"Get owner frame",group:"getter"}],["ElementHandle.press",{title:'Press "{key}"',slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.querySelector",{title:"Query selector",snapshot:!0}],["ElementHandle.querySelectorAll",{title:"Query selector all",snapshot:!0}],["ElementHandle.screenshot",{title:"Screenshot",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.scrollIntoViewIfNeeded",{title:"Scroll into view",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.selectOption",{title:"Select option",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.selectText",{title:"Select text",slowMo:!0,snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.setInputFiles",{title:"Set input files",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.tap",{title:"Tap",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.textContent",{title:"Get text content",snapshot:!0,pausesBeforeAction:!0,group:"getter"}],["ElementHandle.type",{title:"Type",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.uncheck",{title:"Uncheck",slowMo:!0,snapshot:!0,pausesBeforeInput:!0}],["ElementHandle.waitForElementState",{title:"Wait for state",snapshot:!0,pausesBeforeAction:!0}],["ElementHandle.waitForSelector",{title:"Wait for selector",snapshot:!0}],["Request.response",{internal:!0}],["Request.rawRequestHeaders",{internal:!0}],["Route.redirectNavigationRequest",{internal:!0}],["Route.abort",{title:"Abort request",group:"route"}],["Route.continue",{title:"Continue request",group:"route"}],["Route.fulfill",{title:"Fulfill request",group:"route"}],["WebSocketRoute.connect",{title:"Connect WebSocket to server",group:"route"}],["WebSocketRoute.ensureOpened",{internal:!0}],["WebSocketRoute.sendToPage",{title:"Send WebSocket message",group:"route"}],["WebSocketRoute.sendToServer",{title:"Send WebSocket message",group:"route"}],["WebSocketRoute.closePage",{internal:!0}],["WebSocketRoute.closeServer",{internal:!0}],["Response.body",{title:"Get response body",group:"getter"}],["Response.securityDetails",{internal:!0}],["Response.serverAddr",{internal:!0}],["Response.rawResponseHeaders",{internal:!0}],["Response.httpVersion",{internal:!0}],["Response.sizes",{internal:!0}],["BindingCall.reject",{internal:!0}],["BindingCall.resolve",{internal:!0}],["Dialog.accept",{title:"Accept dialog"}],["Dialog.dismiss",{title:"Dismiss dialog"}],["Tracing.tracingStart",{title:"Start tracing",group:"configuration"}],["Tracing.tracingStartChunk",{title:"Start tracing",group:"configuration"}],["Tracing.tracingGroup",{title:'Trace "{name}"'}],["Tracing.tracingGroupEnd",{title:"Group end"}],["Tracing.tracingStopChunk",{title:"Stop tracing",group:"configuration"}],["Tracing.tracingStop",{title:"Stop tracing",group:"configuration"}],["Artifact.pathAfterFinished",{internal:!0}],["Artifact.saveAs",{internal:!0}],["Artifact.saveAsStream",{internal:!0}],["Artifact.failure",{internal:!0}],["Artifact.stream",{internal:!0}],["Artifact.cancel",{internal:!0}],["Artifact.delete",{internal:!0}],["Stream.read",{internal:!0}],["Stream.close",{internal:!0}],["WritableStream.write",{internal:!0}],["WritableStream.close",{internal:!0}],["CDPSession.send",{title:"Send CDP command",group:"configuration"}],["CDPSession.detach",{title:"Detach CDP session",group:"configuration"}],["Electron.launch",{title:"Launch electron"}],["ElectronApplication.browserWindow",{internal:!0}],["ElectronApplication.evaluateExpression",{title:"Evaluate"}],["ElectronApplication.evaluateExpressionHandle",{title:"Evaluate"}],["ElectronApplication.updateSubscription",{internal:!0}],["Android.devices",{internal:!0}],["AndroidSocket.write",{internal:!0}],["AndroidSocket.close",{internal:!0}],["AndroidDevice.wait",{title:"Wait"}],["AndroidDevice.fill",{title:'Fill "{text}"'}],["AndroidDevice.tap",{title:"Tap"}],["AndroidDevice.drag",{title:"Drag"}],["AndroidDevice.fling",{title:"Fling"}],["AndroidDevice.longTap",{title:"Long tap"}],["AndroidDevice.pinchClose",{title:"Pinch close"}],["AndroidDevice.pinchOpen",{title:"Pinch open"}],["AndroidDevice.scroll",{title:"Scroll"}],["AndroidDevice.swipe",{title:"Swipe"}],["AndroidDevice.info",{internal:!0}],["AndroidDevice.screenshot",{title:"Screenshot"}],["AndroidDevice.inputType",{title:"Type"}],["AndroidDevice.inputPress",{title:"Press"}],["AndroidDevice.inputTap",{title:"Tap"}],["AndroidDevice.inputSwipe",{title:"Swipe"}],["AndroidDevice.inputDrag",{title:"Drag"}],["AndroidDevice.launchBrowser",{title:"Launch browser"}],["AndroidDevice.open",{title:"Open app"}],["AndroidDevice.shell",{title:"Execute shell command",group:"configuration"}],["AndroidDevice.installApk",{title:"Install apk"}],["AndroidDevice.push",{title:"Push"}],["AndroidDevice.connectToWebView",{title:"Connect to Web View"}],["AndroidDevice.close",{internal:!0}],["JsonPipe.send",{internal:!0}],["JsonPipe.close",{internal:!0}],["PageAgent.perform",{title:'Perform "{task}"'}],["PageAgent.expect",{title:'Expect "{expectation}"'}],["PageAgent.extract",{title:'Extract "{query}"'}],["PageAgent.dispose",{internal:!0}],["PageAgent.usage",{title:"Get agent usage",group:"configuration"}]]);function _0(n,e){var i;return(i=Fx(n,e))==null?void 0:i.replaceAll(`
|
|
51
|
+
`,"\\n")}function Fx(n,e){if(n)for(const i of e.split("|")){if(i==="url")try{const a=new URL(n[i]);return a.protocol==="data:"?a.protocol:a.protocol==="about:"?n[i]:a.pathname+a.search}catch{if(n[i]!==void 0)return n[i]}if(i==="timeNumber"&&n[i]!==void 0)return new Date(n[i]).toString();const s=Yx(n,i);if(s!==void 0)return s}}function Yx(n,e){const i=e.split(".");let s=n;for(const a of i){if(typeof s!="object"||s===null)return;s=s[a]}if(s!==void 0)return String(s)}function Qx(n){var i;return(n.title??((i=pd.get(n.type+"."+n.method))==null?void 0:i.title)??n.method).replace(/\{([^}]+)\}/g,(s,a)=>_0(n.params,a)??s)}function Px(n){var e;return(e=pd.get(n.type+"."+n.method))==null?void 0:e.group}const Ka=Symbol("context"),A0=Symbol("nextInContext"),C0=Symbol("prevByEndTime"),N0=Symbol("nextByStartTime"),bb=Symbol("events");class A2{constructor(e,i){var a,o;i.forEach(c=>Jx(c));const s=i.find(c=>c.origin==="library");this.traceUri=e,this.browserName=(s==null?void 0:s.browserName)||"",this.sdkLanguage=s==null?void 0:s.sdkLanguage,this.channel=s==null?void 0:s.channel,this.testIdAttributeName=s==null?void 0:s.testIdAttributeName,this.platform=(s==null?void 0:s.platform)||"",this.playwrightVersion=(a=i.find(c=>c.playwrightVersion))==null?void 0:a.playwrightVersion,this.title=(s==null?void 0:s.title)||"",this.options=(s==null?void 0:s.options)||{},this.testTimeout=(o=i.find(c=>c.origin==="testRunner"))==null?void 0:o.testTimeout,this.actions=Zx(i),this.pages=[].concat(...i.map(c=>c.pages)),this.wallTime=i.map(c=>c.wallTime).reduce((c,f)=>Math.min(c||Number.MAX_VALUE,f),Number.MAX_VALUE),this.startTime=i.map(c=>c.startTime).reduce((c,f)=>Math.min(c,f),Number.MAX_VALUE),this.endTime=i.map(c=>c.endTime).reduce((c,f)=>Math.max(c,f),Number.MIN_VALUE),this.events=[].concat(...i.map(c=>c.events)),this.stdio=[].concat(...i.map(c=>c.stdio)),this.errors=[].concat(...i.map(c=>c.errors)),this.hasSource=i.some(c=>c.hasSource),this.hasStepData=i.some(c=>c.origin==="testRunner"),this.resources=[...i.map(c=>c.resources)].flat().map(c=>({...c,id:`${c.pageref}-${c.time}-${c.request.url}`})),this.attachments=this.actions.flatMap(c=>{var f;return((f=c.attachments)==null?void 0:f.map(h=>({...h,callId:c.callId,traceUri:e})))??[]}),this.visibleAttachments=this.attachments.filter(c=>!c.name.startsWith("_")),this.events.sort((c,f)=>c.time-f.time),this.resources.sort((c,f)=>c._monotonicTime-f._monotonicTime),this.errorDescriptors=this.hasStepData?this._errorDescriptorsFromTestRunner():this._errorDescriptorsFromActions(),this.sources=rE(this.actions,this.errorDescriptors),this.actionCounters=new Map;for(const c of this.actions)c.group=c.group??Px({type:c.class,method:c.method}),c.group&&this.actionCounters.set(c.group,1+(this.actionCounters.get(c.group)||0))}createRelativeUrl(e){const i=new URL("http://localhost/"+e);return i.searchParams.set("trace",this.traceUri),i.toString().substring(17)}failedAction(){return this.actions.findLast(e=>e.error)}filteredActions(e){const i=new Set(e);return this.actions.filter(s=>!s.group||i.has(s.group))}renderActionTree(e){const i=this.filteredActions(e??[]),{rootItem:s}=k0(i),a=[],o=(c,f)=>{const h=Qx({...c.action,type:c.action.class});a.push(`${f}${h||c.id}`);for(const p of c.children)o(p,f+" ")};return s.children.forEach(c=>o(c,"")),a}_errorDescriptorsFromActions(){var i;const e=[];for(const s of this.actions||[])(i=s.error)!=null&&i.message&&e.push({action:s,stack:s.stack,message:s.error.message});return e}_errorDescriptorsFromTestRunner(){return this.errors.filter(e=>!!e.message).map((e,i)=>({stack:e.stack,message:e.message}))}}function Jx(n){for(const i of n.pages)i[Ka]=n;for(let i=0;i<n.actions.length;++i){const s=n.actions[i];s[Ka]=n}let e;for(let i=n.actions.length-1;i>=0;i--){const s=n.actions[i];s[A0]=e,s.class!=="Route"&&(e=s)}for(const i of n.events)i[Ka]=n;for(const i of n.resources)i[Ka]=n}function Zx(n){const e=[],i=Wx(n);e.push(...i),e.sort((s,a)=>a.parentId===s.callId?1:s.parentId===a.callId?-1:s.endTime-a.endTime);for(let s=1;s<e.length;++s)e[s][C0]=e[s-1];e.sort((s,a)=>a.parentId===s.callId?-1:s.parentId===a.callId?1:s.startTime-a.startTime);for(let s=0;s+1<e.length;++s)e[s][N0]=e[s+1];return e}let vb=0;function Wx(n){const e=new Map,i=n.filter(c=>c.origin==="library"),s=n.filter(c=>c.origin==="testRunner");if(!s.length||!i.length)return n.map(c=>c.actions.map(f=>({...f,context:c}))).flat();for(const c of i)for(const f of c.actions)e.set(f.stepId||`tmp-step@${++vb}`,{...f,context:c});const a=tE(s,e);a&&eE(i,a);const o=new Map;for(const c of s)for(const f of c.actions){const h=f.stepId&&e.get(f.stepId);if(h){o.set(f.callId,h.callId),f.error&&(h.error=f.error),f.attachments&&(h.attachments=f.attachments),f.annotations&&(h.annotations=f.annotations),f.parentId&&(h.parentId=o.get(f.parentId)??f.parentId),f.group&&(h.group=f.group),h.startTime=f.startTime,h.endTime=f.endTime;continue}f.parentId&&(f.parentId=o.get(f.parentId)??f.parentId),e.set(f.stepId||`tmp-step@${++vb}`,{...f,context:c})}return[...e.values()]}function eE(n,e){for(const i of n){i.startTime+=e,i.endTime+=e;for(const s of i.actions)s.startTime&&(s.startTime+=e),s.endTime&&(s.endTime+=e);for(const s of i.events)s.time+=e;for(const s of i.stdio)s.timestamp+=e;for(const s of i.pages)for(const a of s.screencastFrames)a.timestamp+=e;for(const s of i.resources)s._monotonicTime&&(s._monotonicTime+=e)}}function tE(n,e){for(const i of n)for(const s of i.actions){if(!s.startTime)continue;const a=s.stepId?e.get(s.stepId):void 0;if(a)return s.startTime-a.startTime}return 0}function k0(n){const e=new Map;for(const a of n)e.set(a.callId,{id:a.callId,parent:void 0,children:[],action:a});const i={action:{...aE},id:"",parent:void 0,children:[]};for(const a of e.values()){i.action.startTime=Math.min(i.action.startTime,a.action.startTime),i.action.endTime=Math.max(i.action.endTime,a.action.endTime);const o=a.action.parentId&&e.get(a.action.parentId)||i;o.children.push(a),a.parent=o}const s=a=>{for(const o of a.children)o.action.stack=o.action.stack??a.action.stack,s(o)};return s(i),{rootItem:i,itemMap:e}}function M0(n){return n[Ka]}function nE(n){return n[A0]}function Sb(n){return n[C0]}function wb(n){return n[N0]}function iE(n){let e=0,i=0;for(const s of sE(n)){if(s.type==="console"){const a=s.messageType;a==="warning"?++i:a==="error"&&++e}s.type==="event"&&s.method==="pageError"&&++e}return{errors:e,warnings:i}}function sE(n){let e=n[bb];if(e)return e;const i=nE(n);return e=M0(n).events.filter(s=>s.time>=n.startTime&&(!i||s.time<i.startTime)),n[bb]=e,e}function rE(n,e){var s;const i=new Map;for(const a of n)for(const o of a.stack||[]){let c=i.get(o.file);c||(c={errors:[],content:void 0},i.set(o.file,c))}for(const a of e){const{action:o,stack:c,message:f}=a;!o||!c||(s=i.get(c[0].file))==null||s.errors.push({line:c[0].line||0,message:f})}return i}const aE={type:"action",callId:"",startTime:0,endTime:0,class:"",method:"",params:{},log:[],context:{origin:"library",startTime:0,endTime:0,browserName:"",wallTime:0,options:{},pages:[],resources:[],actions:[],events:[],stdio:[],errors:[],hasSource:!1,contextId:""}},lE=50,fc=({sidebarSize:n,sidebarHidden:e=!1,sidebarIsFirst:i=!1,orientation:s="vertical",minSidebarSize:a=lE,settingName:o,sidebar:c,main:f})=>{const h=Math.max(a,n)*window.devicePixelRatio,[p,y]=fn(o?o+"."+s+":size":void 0,h),[m,v]=fn(o?o+"."+s+":size":void 0,h),[S,T]=U.useState(null),[x,E]=bs();let A;s==="vertical"?(A=m/window.devicePixelRatio,x&&x.height<A&&(A=x.height-10)):(A=p/window.devicePixelRatio,x&&x.width<A&&(A=x.width-10)),document.body.style.userSelect=S?"none":"inherit";let N={};return s==="vertical"?i?N={top:S?0:A-4,bottom:S?0:void 0,height:S?"initial":8}:N={bottom:S?0:A-4,top:S?0:void 0,height:S?"initial":8}:i?N={left:S?0:A-4,right:S?0:void 0,width:S?"initial":8}:N={right:S?0:A-4,left:S?0:void 0,width:S?"initial":8},w.jsxs("div",{className:Qe("split-view",s,i&&"sidebar-first"),ref:E,children:[w.jsx("div",{className:"split-view-main",children:f}),!e&&w.jsx("div",{style:{flexBasis:A},className:"split-view-sidebar",children:c}),!e&&w.jsx("div",{style:N,className:"split-view-resizer",onMouseDown:B=>T({offset:s==="vertical"?B.clientY:B.clientX,size:A}),onMouseUp:()=>T(null),onMouseMove:B=>{if(!B.buttons)T(null);else if(S){const $=(s==="vertical"?B.clientY:B.clientX)-S.offset,z=i?S.size+$:S.size-$,H=B.target.parentElement.getBoundingClientRect(),L=Math.min(Math.max(a,z),(s==="vertical"?H.height:H.width)-a);s==="vertical"?v(L*window.devicePixelRatio):y(L*window.devicePixelRatio)}}})]})},nt=function(n,e,i){return n>=e&&n<=i};function Bt(n){return nt(n,48,57)}function xb(n){return Bt(n)||nt(n,65,70)||nt(n,97,102)}function oE(n){return nt(n,65,90)}function cE(n){return nt(n,97,122)}function uE(n){return oE(n)||cE(n)}function fE(n){return n>=128}function Po(n){return uE(n)||fE(n)||n===95}function Eb(n){return Po(n)||Bt(n)||n===45}function hE(n){return nt(n,0,8)||n===11||nt(n,14,31)||n===127}function Jo(n){return n===10}function Jn(n){return Jo(n)||n===9||n===32}const dE=1114111;class gd extends Error{constructor(e){super(e),this.name="InvalidCharacterError"}}function pE(n){const e=[];for(let i=0;i<n.length;i++){let s=n.charCodeAt(i);if(s===13&&n.charCodeAt(i+1)===10&&(s=10,i++),(s===13||s===12)&&(s=10),s===0&&(s=65533),nt(s,55296,56319)&&nt(n.charCodeAt(i+1),56320,57343)){const a=s-55296,o=n.charCodeAt(i+1)-56320;s=Math.pow(2,16)+a*Math.pow(2,10)+o,i++}e.push(s)}return e}function rt(n){if(n<=65535)return String.fromCharCode(n);n-=Math.pow(2,16);const e=Math.floor(n/Math.pow(2,10))+55296,i=n%Math.pow(2,10)+56320;return String.fromCharCode(e)+String.fromCharCode(i)}function O0(n){const e=pE(n);let i=-1;const s=[];let a;const o=function(G){return G>=e.length?-1:e[G]},c=function(G){if(G===void 0&&(G=1),G>3)throw"Spec Error: no more than three codepoints of lookahead.";return o(i+G)},f=function(G){return G===void 0&&(G=1),i+=G,a=o(i),!0},h=function(){return i-=1,!0},p=function(G){return G===void 0&&(G=a),G===-1},y=function(){if(m(),f(),Jn(a)){for(;Jn(c());)f();return new hc}else{if(a===34)return T();if(a===35)if(Eb(c())||A(c(1),c(2))){const G=new G0("");return B(c(1),c(2),c(3))&&(G.type="id"),G.value=Q(),G}else return new pt(a);else return a===36?c()===61?(f(),new bE):new pt(a):a===39?T():a===40?new I0:a===41?new md:a===42?c()===61?(f(),new vE):new pt(a):a===43?z()?(h(),v()):new pt(a):a===44?new z0:a===45?z()?(h(),v()):c(1)===45&&c(2)===62?(f(2),new R0):V()?(h(),S()):new pt(a):a===46?z()?(h(),v()):new pt(a):a===58?new D0:a===59?new B0:a===60?c(1)===33&&c(2)===45&&c(3)===45?(f(3),new j0):new pt(a):a===64?B(c(1),c(2),c(3))?new V0(Q()):new pt(a):a===91?new q0:a===92?N()?(h(),S()):new pt(a):a===93?new $h:a===94?c()===61?(f(),new yE):new pt(a):a===123?new U0:a===124?c()===61?(f(),new mE):c()===124?(f(),new $0):new pt(a):a===125?new H0:a===126?c()===61?(f(),new gE):new pt(a):Bt(a)?(h(),v()):Po(a)?(h(),S()):p()?new Wo:new pt(a)}},m=function(){for(;c(1)===47&&c(2)===42;)for(f(2);;)if(f(),a===42&&c()===47){f();break}else if(p())return},v=function(){const G=H();if(B(c(1),c(2),c(3))){const P=new SE;return P.value=G.value,P.repr=G.repr,P.type=G.type,P.unit=Q(),P}else if(c()===37){f();const P=new F0;return P.value=G.value,P.repr=G.repr,P}else{const P=new X0;return P.value=G.value,P.repr=G.repr,P.type=G.type,P}},S=function(){const G=Q();if(G.toLowerCase()==="url"&&c()===40){for(f();Jn(c(1))&&Jn(c(2));)f();return c()===34||c()===39?new Ja(G):Jn(c())&&(c(2)===34||c(2)===39)?new Ja(G):x()}else return c()===40?(f(),new Ja(G)):new yd(G)},T=function(G){G===void 0&&(G=a);let P="";for(;f();){if(a===G||p())return new bd(P);if(Jo(a))return h(),new L0;a===92?p(c())||(Jo(c())?f():P+=rt(E())):P+=rt(a)}throw new Error("Internal error")},x=function(){const G=new K0("");for(;Jn(c());)f();if(p(c()))return G;for(;f();){if(a===41||p())return G;if(Jn(a)){for(;Jn(c());)f();return c()===41||p(c())?(f(),G):(ne(),new Zo)}else{if(a===34||a===39||a===40||hE(a))return ne(),new Zo;if(a===92)if(N())G.value+=rt(E());else return ne(),new Zo;else G.value+=rt(a)}}throw new Error("Internal error")},E=function(){if(f(),xb(a)){const G=[a];for(let W=0;W<5&&xb(c());W++)f(),G.push(a);Jn(c())&&f();let P=parseInt(G.map(function(W){return String.fromCharCode(W)}).join(""),16);return P>dE&&(P=65533),P}else return p()?65533:a},A=function(G,P){return!(G!==92||Jo(P))},N=function(){return A(a,c())},B=function(G,P,W){return G===45?Po(P)||P===45||A(P,W):Po(G)?!0:G===92?A(G,P):!1},V=function(){return B(a,c(1),c(2))},$=function(G,P,W){return G===43||G===45?!!(Bt(P)||P===46&&Bt(W)):G===46?!!Bt(P):!!Bt(G)},z=function(){return $(a,c(1),c(2))},Q=function(){let G="";for(;f();)if(Eb(a))G+=rt(a);else if(N())G+=rt(E());else return h(),G;throw new Error("Internal parse error")},H=function(){let G="",P="integer";for((c()===43||c()===45)&&(f(),G+=rt(a));Bt(c());)f(),G+=rt(a);if(c(1)===46&&Bt(c(2)))for(f(),G+=rt(a),f(),G+=rt(a),P="number";Bt(c());)f(),G+=rt(a);const W=c(1),Ce=c(2),q=c(3);if((W===69||W===101)&&Bt(Ce))for(f(),G+=rt(a),f(),G+=rt(a),P="number";Bt(c());)f(),G+=rt(a);else if((W===69||W===101)&&(Ce===43||Ce===45)&&Bt(q))for(f(),G+=rt(a),f(),G+=rt(a),f(),G+=rt(a),P="number";Bt(c());)f(),G+=rt(a);const J=L(G);return{type:P,value:J,repr:G}},L=function(G){return+G},ne=function(){for(;f();){if(a===41||p())return;N()&&E()}};let ae=0;for(;!p(c());)if(s.push(y()),ae++,ae>e.length*2)throw new Error("I'm infinite-looping!");return s}class Pe{constructor(){this.tokenType=""}toJSON(){return{token:this.tokenType}}toString(){return this.tokenType}toSource(){return""+this}}class L0 extends Pe{constructor(){super(...arguments),this.tokenType="BADSTRING"}}class Zo extends Pe{constructor(){super(...arguments),this.tokenType="BADURL"}}class hc extends Pe{constructor(){super(...arguments),this.tokenType="WHITESPACE"}toString(){return"WS"}toSource(){return" "}}class j0 extends Pe{constructor(){super(...arguments),this.tokenType="CDO"}toSource(){return"<!--"}}class R0 extends Pe{constructor(){super(...arguments),this.tokenType="CDC"}toSource(){return"-->"}}class D0 extends Pe{constructor(){super(...arguments),this.tokenType=":"}}class B0 extends Pe{constructor(){super(...arguments),this.tokenType=";"}}class z0 extends Pe{constructor(){super(...arguments),this.tokenType=","}}class Lr extends Pe{constructor(){super(...arguments),this.value="",this.mirror=""}}class U0 extends Lr{constructor(){super(),this.tokenType="{",this.value="{",this.mirror="}"}}class H0 extends Lr{constructor(){super(),this.tokenType="}",this.value="}",this.mirror="{"}}class q0 extends Lr{constructor(){super(),this.tokenType="[",this.value="[",this.mirror="]"}}class $h extends Lr{constructor(){super(),this.tokenType="]",this.value="]",this.mirror="["}}class I0 extends Lr{constructor(){super(),this.tokenType="(",this.value="(",this.mirror=")"}}class md extends Lr{constructor(){super(),this.tokenType=")",this.value=")",this.mirror="("}}class gE extends Pe{constructor(){super(...arguments),this.tokenType="~="}}class mE extends Pe{constructor(){super(...arguments),this.tokenType="|="}}class yE extends Pe{constructor(){super(...arguments),this.tokenType="^="}}class bE extends Pe{constructor(){super(...arguments),this.tokenType="$="}}class vE extends Pe{constructor(){super(...arguments),this.tokenType="*="}}class $0 extends Pe{constructor(){super(...arguments),this.tokenType="||"}}class Wo extends Pe{constructor(){super(...arguments),this.tokenType="EOF"}toSource(){return""}}class pt extends Pe{constructor(e){super(),this.tokenType="DELIM",this.value="",this.value=rt(e)}toString(){return"DELIM("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e}toSource(){return this.value==="\\"?`\\
|
|
52
|
+
`:this.value}}class jr extends Pe{constructor(){super(...arguments),this.value=""}ASCIIMatch(e){return this.value.toLowerCase()===e.toLowerCase()}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e}}class yd extends jr{constructor(e){super(),this.tokenType="IDENT",this.value=e}toString(){return"IDENT("+this.value+")"}toSource(){return pl(this.value)}}class Ja extends jr{constructor(e){super(),this.tokenType="FUNCTION",this.value=e,this.mirror=")"}toString(){return"FUNCTION("+this.value+")"}toSource(){return pl(this.value)+"("}}class V0 extends jr{constructor(e){super(),this.tokenType="AT-KEYWORD",this.value=e}toString(){return"AT("+this.value+")"}toSource(){return"@"+pl(this.value)}}class G0 extends jr{constructor(e){super(),this.tokenType="HASH",this.value=e,this.type="unrestricted"}toString(){return"HASH("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.type=this.type,e}toSource(){return this.type==="id"?"#"+pl(this.value):"#"+wE(this.value)}}class bd extends jr{constructor(e){super(),this.tokenType="STRING",this.value=e}toString(){return'"'+Y0(this.value)+'"'}}class K0 extends jr{constructor(e){super(),this.tokenType="URL",this.value=e}toString(){return"URL("+this.value+")"}toSource(){return'url("'+Y0(this.value)+'")'}}class X0 extends Pe{constructor(){super(),this.tokenType="NUMBER",this.type="integer",this.repr=""}toString(){return this.type==="integer"?"INT("+this.value+")":"NUMBER("+this.value+")"}toJSON(){const e=super.toJSON();return e.value=this.value,e.type=this.type,e.repr=this.repr,e}toSource(){return this.repr}}class F0 extends Pe{constructor(){super(),this.tokenType="PERCENTAGE",this.repr=""}toString(){return"PERCENTAGE("+this.value+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.repr=this.repr,e}toSource(){return this.repr+"%"}}class SE extends Pe{constructor(){super(),this.tokenType="DIMENSION",this.type="integer",this.repr="",this.unit=""}toString(){return"DIM("+this.value+","+this.unit+")"}toJSON(){const e=this.constructor.prototype.constructor.prototype.toJSON.call(this);return e.value=this.value,e.type=this.type,e.repr=this.repr,e.unit=this.unit,e}toSource(){const e=this.repr;let i=pl(this.unit);return i[0].toLowerCase()==="e"&&(i[1]==="-"||nt(i.charCodeAt(1),48,57))&&(i="\\65 "+i.slice(1,i.length)),e+i}}function pl(n){n=""+n;let e="";const i=n.charCodeAt(0);for(let s=0;s<n.length;s++){const a=n.charCodeAt(s);if(a===0)throw new gd("Invalid character: the input contains U+0000.");nt(a,1,31)||a===127||s===0&&nt(a,48,57)||s===1&&nt(a,48,57)&&i===45?e+="\\"+a.toString(16)+" ":a>=128||a===45||a===95||nt(a,48,57)||nt(a,65,90)||nt(a,97,122)?e+=n[s]:e+="\\"+n[s]}return e}function wE(n){n=""+n;let e="";for(let i=0;i<n.length;i++){const s=n.charCodeAt(i);if(s===0)throw new gd("Invalid character: the input contains U+0000.");s>=128||s===45||s===95||nt(s,48,57)||nt(s,65,90)||nt(s,97,122)?e+=n[i]:e+="\\"+s.toString(16)+" "}return e}function Y0(n){n=""+n;let e="";for(let i=0;i<n.length;i++){const s=n.charCodeAt(i);if(s===0)throw new gd("Invalid character: the input contains U+0000.");nt(s,1,31)||s===127?e+="\\"+s.toString(16)+" ":s===34||s===92?e+="\\"+n[i]:e+=n[i]}return e}class zt extends Error{}function xE(n,e){let i;try{i=O0(n),i[i.length-1]instanceof Wo||i.push(new Wo)}catch(L){const ne=L.message+` while parsing css selector "${n}". Did you mean to CSS.escape it?`,ae=(L.stack||"").indexOf(L.message);throw ae!==-1&&(L.stack=L.stack.substring(0,ae)+ne+L.stack.substring(ae+L.message.length)),L.message=ne,L}const s=i.find(L=>L instanceof V0||L instanceof L0||L instanceof Zo||L instanceof $0||L instanceof j0||L instanceof R0||L instanceof B0||L instanceof U0||L instanceof H0||L instanceof K0||L instanceof F0);if(s)throw new zt(`Unsupported token "${s.toSource()}" while parsing css selector "${n}". Did you mean to CSS.escape it?`);let a=0;const o=new Set;function c(){return new zt(`Unexpected token "${i[a].toSource()}" while parsing css selector "${n}". Did you mean to CSS.escape it?`)}function f(){for(;i[a]instanceof hc;)a++}function h(L=a){return i[L]instanceof yd}function p(L=a){return i[L]instanceof bd}function y(L=a){return i[L]instanceof X0}function m(L=a){return i[L]instanceof z0}function v(L=a){return i[L]instanceof I0}function S(L=a){return i[L]instanceof md}function T(L=a){return i[L]instanceof Ja}function x(L=a){return i[L]instanceof pt&&i[L].value==="*"}function E(L=a){return i[L]instanceof Wo}function A(L=a){return i[L]instanceof pt&&[">","+","~"].includes(i[L].value)}function N(L=a){return m(L)||S(L)||E(L)||A(L)||i[L]instanceof hc}function B(){const L=[V()];for(;f(),!!m();)a++,L.push(V());return L}function V(){return f(),y()||p()?i[a++].value:$()}function $(){const L={simples:[]};for(f(),A()?L.simples.push({selector:{functions:[{name:"scope",args:[]}]},combinator:""}):L.simples.push({selector:z(),combinator:""});;){if(f(),A())L.simples[L.simples.length-1].combinator=i[a++].value,f();else if(N())break;L.simples.push({combinator:"",selector:z()})}return L}function z(){let L="";const ne=[];for(;!N();)if(h()||x())L+=i[a++].toSource();else if(i[a]instanceof G0)L+=i[a++].toSource();else if(i[a]instanceof pt&&i[a].value===".")if(a++,h())L+="."+i[a++].toSource();else throw c();else if(i[a]instanceof D0)if(a++,h())if(!e.has(i[a].value.toLowerCase()))L+=":"+i[a++].toSource();else{const ae=i[a++].value.toLowerCase();ne.push({name:ae,args:[]}),o.add(ae)}else if(T()){const ae=i[a++].value.toLowerCase();if(e.has(ae)?(ne.push({name:ae,args:B()}),o.add(ae)):L+=`:${ae}(${Q()})`,f(),!S())throw c();a++}else throw c();else if(i[a]instanceof q0){for(L+="[",a++;!(i[a]instanceof $h)&&!E();)L+=i[a++].toSource();if(!(i[a]instanceof $h))throw c();L+="]",a++}else throw c();if(!L&&!ne.length)throw c();return{css:L||void 0,functions:ne}}function Q(){let L="",ne=1;for(;!E()&&((v()||T())&&ne++,S()&&ne--,!!ne);)L+=i[a++].toSource();return L}const H=B();if(!E())throw c();if(H.some(L=>typeof L!="object"||!("simples"in L)))throw new zt(`Error while parsing css selector "${n}". Did you mean to CSS.escape it?`);return{selector:H,names:Array.from(o)}}const Vh=new Set(["internal:has","internal:has-not","internal:and","internal:or","internal:chain","left-of","right-of","above","below","near"]),EE=new Set(["left-of","right-of","above","below","near"]),Q0=new Set(["not","is","where","has","scope","light","visible","text","text-matches","text-is","has-text","above","below","right-of","left-of","near","nth-match"]);function gl(n){const e=AE(n),i=[];for(const s of e.parts){if(s.name==="css"||s.name==="css:light"){s.name==="css:light"&&(s.body=":light("+s.body+")");const a=xE(s.body,Q0);i.push({name:"css",body:a.selector,source:s.body});continue}if(Vh.has(s.name)){let a,o;try{const p=JSON.parse("["+s.body+"]");if(!Array.isArray(p)||p.length<1||p.length>2||typeof p[0]!="string")throw new zt(`Malformed selector: ${s.name}=`+s.body);if(a=p[0],p.length===2){if(typeof p[1]!="number"||!EE.has(s.name))throw new zt(`Malformed selector: ${s.name}=`+s.body);o=p[1]}}catch{throw new zt(`Malformed selector: ${s.name}=`+s.body)}const c={name:s.name,source:s.body,body:{parsed:gl(a),distance:o}},f=[...c.body.parsed.parts].reverse().find(p=>p.name==="internal:control"&&p.body==="enter-frame"),h=f?c.body.parsed.parts.indexOf(f):-1;h!==-1&&TE(c.body.parsed.parts.slice(0,h+1),i.slice(0,h+1))&&c.body.parsed.parts.splice(0,h+1),i.push(c);continue}i.push({...s,source:s.body})}if(Vh.has(i[0].name))throw new zt(`"${i[0].name}" selector cannot be first`);return{capture:e.capture,parts:i}}function TE(n,e){return Nn({parts:n})===Nn({parts:e})}function Nn(n,e){return typeof n=="string"?n:n.parts.map((i,s)=>{let a=!0;!e&&s!==n.capture&&(i.name==="css"||i.name==="xpath"&&i.source.startsWith("//")||i.source.startsWith(".."))&&(a=!1);const o=a?i.name+"=":"";return`${s===n.capture?"*":""}${o}${i.source}`}).join(" >> ")}function _E(n,e){const i=(s,a)=>{for(const o of s.parts)e(o,a),Vh.has(o.name)&&i(o.body.parsed,!0)};i(n,!1)}function AE(n){let e=0,i,s=0;const a={parts:[]},o=()=>{const f=n.substring(s,e).trim(),h=f.indexOf("=");let p,y;h!==-1&&f.substring(0,h).trim().match(/^[a-zA-Z_0-9-+:*]+$/)?(p=f.substring(0,h).trim(),y=f.substring(h+1)):f.length>1&&f[0]==='"'&&f[f.length-1]==='"'||f.length>1&&f[0]==="'"&&f[f.length-1]==="'"?(p="text",y=f):/^\(*\/\//.test(f)||f.startsWith("..")?(p="xpath",y=f):(p="css",y=f);let m=!1;if(p[0]==="*"&&(m=!0,p=p.substring(1)),a.parts.push({name:p,body:y}),m){if(a.capture!==void 0)throw new zt("Only one of the selectors can capture using * modifier");a.capture=a.parts.length-1}};if(!n.includes(">>"))return e=n.length,o(),a;const c=()=>{const h=n.substring(s,e).match(/^\s*text\s*=(.*)$/);return!!h&&!!h[1]};for(;e<n.length;){const f=n[e];f==="\\"&&e+1<n.length?e+=2:f===i?(i=void 0,e++):!i&&(f==='"'||f==="'"||f==="`")&&!c()?(i=f,e++):!i&&f===">"&&n[e+1]===">"?(o(),e+=2,s=e):e++}return o(),a}function Za(n,e){let i=0,s=n.length===0;const a=()=>n[i]||"",o=()=>{const E=a();return++i,s=i>=n.length,E},c=E=>{throw s?new zt(`Unexpected end of selector while parsing selector \`${n}\``):new zt(`Error while parsing selector \`${n}\` - unexpected symbol "${a()}" at position ${i}`+(E?" during "+E:""))};function f(){for(;!s&&/\s/.test(a());)o()}function h(E){return E>=""||E>="0"&&E<="9"||E>="A"&&E<="Z"||E>="a"&&E<="z"||E>="0"&&E<="9"||E==="_"||E==="-"}function p(){let E="";for(f();!s&&h(a());)E+=o();return E}function y(E){let A=o();for(A!==E&&c("parsing quoted string");!s&&a()!==E;)a()==="\\"&&o(),A+=o();return a()!==E&&c("parsing quoted string"),A+=o(),A}function m(){o()!=="/"&&c("parsing regular expression");let E="",A=!1;for(;!s;){if(a()==="\\")E+=o(),s&&c("parsing regular expression");else if(A&&a()==="]")A=!1;else if(!A&&a()==="[")A=!0;else if(!A&&a()==="/")break;E+=o()}o()!=="/"&&c("parsing regular expression");let N="";for(;!s&&a().match(/[dgimsuy]/);)N+=o();try{return new RegExp(E,N)}catch(B){throw new zt(`Error while parsing selector \`${n}\`: ${B.message}`)}}function v(){let E="";return f(),a()==="'"||a()==='"'?E=y(a()).slice(1,-1):E=p(),E||c("parsing property path"),E}function S(){f();let E="";return s||(E+=o()),!s&&E!=="="&&(E+=o()),["=","*=","^=","$=","|=","~="].includes(E)||c("parsing operator"),E}function T(){o();const E=[];for(E.push(v()),f();a()===".";)o(),E.push(v()),f();if(a()==="]")return o(),{name:E.join("."),jsonPath:E,op:"<truthy>",value:null,caseSensitive:!1};const A=S();let N,B=!0;if(f(),a()==="/"){if(A!=="=")throw new zt(`Error while parsing selector \`${n}\` - cannot use ${A} in attribute with regular expression`);N=m()}else if(a()==="'"||a()==='"')N=y(a()).slice(1,-1),f(),a()==="i"||a()==="I"?(B=!1,o()):(a()==="s"||a()==="S")&&(B=!0,o());else{for(N="";!s&&(h(a())||a()==="+"||a()===".");)N+=o();N==="true"?N=!0:N==="false"&&(N=!1)}if(f(),a()!=="]"&&c("parsing attribute value"),o(),A!=="="&&typeof N!="string")throw new zt(`Error while parsing selector \`${n}\` - cannot use ${A} in attribute with non-string matching value - ${N}`);return{name:E.join("."),jsonPath:E,op:A,value:N,caseSensitive:B}}const x={name:"",attributes:[]};for(x.name=p(),f();a()==="[";)x.attributes.push(T()),f();if(s||c(void 0),!x.name&&!x.attributes.length)throw new zt(`Error while parsing selector \`${n}\` - selector cannot be empty`);return x}function Ac(n,e="'"){const i=JSON.stringify(n),s=i.substring(1,i.length-1).replace(/\\"/g,'"');if(e==="'")return e+s.replace(/[']/g,"\\'")+e;if(e==='"')return e+s.replace(/["]/g,'\\"')+e;if(e==="`")return e+s.replace(/[`]/g,"\\`")+e;throw new Error("Invalid escape char")}function dc(n){return n.charAt(0).toUpperCase()+n.substring(1)}function P0(n){return n.replace(/([a-z0-9])([A-Z])/g,"$1_$2").replace(/([A-Z])([A-Z][a-z])/g,"$1_$2").toLowerCase()}function mr(n){return`"${n.replace(/["\\]/g,e=>"\\"+e)}"`}let as;function CE(){as=new Map}function Nt(n){let e=as==null?void 0:as.get(n);return e===void 0&&(e=n.replace(/[\u200b\u00ad]/g,"").trim().replace(/\s+/g," "),as==null||as.set(n,e)),e}function Cc(n){return n.replace(/(^|[^\\])(\\\\)*\\(['"`])/g,"$1$2$3")}function J0(n){return n.unicode||n.unicodeSets?String(n):String(n).replace(/(^|[^\\])(\\\\)*(["'`])/g,"$1$2\\$3").replace(/>>/g,"\\>\\>")}function Ut(n,e){return typeof n!="string"?J0(n):`${JSON.stringify(n)}${e?"s":"i"}`}function Ct(n,e){return typeof n!="string"?J0(n):`"${n.replace(/\\/g,"\\\\").replace(/["]/g,'\\"')}"${e?"s":"i"}`}function NE(n,e,i=""){if(n.length<=e)return n;const s=[...n];return s.length>e?s.slice(0,e-i.length).join("")+i:s.join("")}function Tb(n,e){return NE(n,e,"…")}function pc(n){return n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function kE(n,e){const i=n.length,s=e.length;let a=0,o=0;const c=Array(i+1).fill(null).map(()=>Array(s+1).fill(0));for(let f=1;f<=i;f++)for(let h=1;h<=s;h++)n[f-1]===e[h-1]&&(c[f][h]=c[f-1][h-1]+1,c[f][h]>a&&(a=c[f][h],o=f));return n.slice(o-a,o)}function Z0(n,e){try{const i=gl(e),s=ME(i);return s||us(new ev[n],i,!1,1)[0]}catch{return e}}function ME(n){const e=n.parts[n.parts.length-1];if((e==null?void 0:e.name)==="internal:describe"){const i=JSON.parse(e.body);if(typeof i=="string")return i}}function Li(n,e,i=!1){return W0(n,e,i,1)[0]}function W0(n,e,i=!1,s=20,a){try{return us(new ev[n](a),gl(e),i,s)}catch{return[e]}}function us(n,e,i=!1,s=20){const a=[...e.parts],o=[];let c=i?"frame-locator":"page";for(let f=0;f<a.length;f++){const h=a[f],p=c;if(c="locator",h.name==="internal:describe")continue;if(h.name==="nth"){h.body==="0"?o.push([n.generateLocator(p,"first",""),n.generateLocator(p,"nth","0")]):h.body==="-1"?o.push([n.generateLocator(p,"last",""),n.generateLocator(p,"nth","-1")]):o.push([n.generateLocator(p,"nth",h.body)]);continue}if(h.name==="visible"){o.push([n.generateLocator(p,"visible",h.body),n.generateLocator(p,"default",`visible=${h.body}`)]);continue}if(h.name==="internal:text"){const{exact:T,text:x}=Ua(h.body);o.push([n.generateLocator(p,"text",x,{exact:T})]);continue}if(h.name==="internal:has-text"){const{exact:T,text:x}=Ua(h.body);if(!T){o.push([n.generateLocator(p,"has-text",x,{exact:T})]);continue}}if(h.name==="internal:has-not-text"){const{exact:T,text:x}=Ua(h.body);if(!T){o.push([n.generateLocator(p,"has-not-text",x,{exact:T})]);continue}}if(h.name==="internal:has"){const T=us(n,h.body.parsed,!1,s);o.push(T.map(x=>n.generateLocator(p,"has",x)));continue}if(h.name==="internal:has-not"){const T=us(n,h.body.parsed,!1,s);o.push(T.map(x=>n.generateLocator(p,"hasNot",x)));continue}if(h.name==="internal:and"){const T=us(n,h.body.parsed,!1,s);o.push(T.map(x=>n.generateLocator(p,"and",x)));continue}if(h.name==="internal:or"){const T=us(n,h.body.parsed,!1,s);o.push(T.map(x=>n.generateLocator(p,"or",x)));continue}if(h.name==="internal:chain"){const T=us(n,h.body.parsed,!1,s);o.push(T.map(x=>n.generateLocator(p,"chain",x)));continue}if(h.name==="internal:label"){const{exact:T,text:x}=Ua(h.body);o.push([n.generateLocator(p,"label",x,{exact:T})]);continue}if(h.name==="internal:role"){const T=Za(h.body),x={attrs:[]};for(const E of T.attributes)E.name==="name"?(x.exact=E.caseSensitive,x.name=E.value):(E.name==="level"&&typeof E.value=="string"&&(E.value=+E.value),x.attrs.push({name:E.name==="include-hidden"?"includeHidden":E.name,value:E.value}));o.push([n.generateLocator(p,"role",T.name,x)]);continue}if(h.name==="internal:testid"){const T=Za(h.body),{value:x}=T.attributes[0];o.push([n.generateLocator(p,"test-id",x)]);continue}if(h.name==="internal:attr"){const T=Za(h.body),{name:x,value:E,caseSensitive:A}=T.attributes[0],N=E,B=!!A;if(x==="placeholder"){o.push([n.generateLocator(p,"placeholder",N,{exact:B})]);continue}if(x==="alt"){o.push([n.generateLocator(p,"alt",N,{exact:B})]);continue}if(x==="title"){o.push([n.generateLocator(p,"title",N,{exact:B})]);continue}}if(h.name==="internal:control"&&h.body==="enter-frame"){const T=o[o.length-1],x=a[f-1],E=T.map(A=>n.chainLocators([A,n.generateLocator(p,"frame","")]));["xpath","css"].includes(x.name)&&E.push(n.generateLocator(p,"frame-locator",Nn({parts:[x]})),n.generateLocator(p,"frame-locator",Nn({parts:[x]},!0))),T.splice(0,T.length,...E),c="frame-locator";continue}const y=a[f+1],m=Nn({parts:[h]}),v=n.generateLocator(p,"default",m);if(y&&["internal:has-text","internal:has-not-text"].includes(y.name)){const{exact:T,text:x}=Ua(y.body);if(!T){const E=n.generateLocator("locator",y.name==="internal:has-text"?"has-text":"has-not-text",x,{exact:T}),A={};y.name==="internal:has-text"?A.hasText=x:A.hasNotText=x;const N=n.generateLocator(p,"default",m,A);o.push([n.chainLocators([v,E]),N]),f++;continue}}let S;if(["xpath","css"].includes(h.name)){const T=Nn({parts:[h]},!0);S=n.generateLocator(p,"default",T)}o.push([v,S].filter(Boolean))}return OE(n,o,s)}function OE(n,e,i){const s=e.map(()=>""),a=[],o=c=>{if(c===e.length)return a.push(n.chainLocators(s)),a.length<i;for(const f of e[c])if(s[c]=f,!o(c+1))return!1;return!0};return o(0),a}function Ua(n){let e=!1;const i=n.match(/^\/(.*)\/([igm]*)$/);return i?{text:new RegExp(i[1],i[2])}:(n.endsWith('"')?(n=JSON.parse(n),e=!0):n.endsWith('"s')?(n=JSON.parse(n.substring(0,n.length-1)),e=!0):n.endsWith('"i')&&(n=JSON.parse(n.substring(0,n.length-1)),e=!1),{exact:e,text:n})}class LE{constructor(e){this.preferredQuote=e}generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, { hasText: ${this.toHasText(a.hasText)} })`:a.hasNotText!==void 0?`locator(${this.quote(s)}, { hasNotText: ${this.toHasText(a.hasNotText)} })`:`locator(${this.quote(s)})`;case"frame-locator":return`frameLocator(${this.quote(s)})`;case"frame":return"contentFrame()";case"nth":return`nth(${s})`;case"first":return"first()";case"last":return"last()";case"visible":return`filter({ visible: ${s==="true"?"true":"false"} })`;case"role":const o=[];gt(a.name)?o.push(`name: ${this.regexToSourceString(a.name)}`):typeof a.name=="string"&&(o.push(`name: ${this.quote(a.name)}`),a.exact&&o.push("exact: true"));for(const{name:f,value:h}of a.attrs)o.push(`${f}: ${typeof h=="string"?this.quote(h):h}`);const c=o.length?`, { ${o.join(", ")} }`:"";return`getByRole(${this.quote(s)}${c})`;case"has-text":return`filter({ hasText: ${this.toHasText(s)} })`;case"has-not-text":return`filter({ hasNotText: ${this.toHasText(s)} })`;case"has":return`filter({ has: ${s} })`;case"hasNot":return`filter({ hasNot: ${s} })`;case"and":return`and(${s})`;case"or":return`or(${s})`;case"chain":return`locator(${s})`;case"test-id":return`getByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("getByText",s,!!a.exact);case"alt":return this.toCallWithExact("getByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact("getByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact("getByLabel",s,!!a.exact);case"title":return this.toCallWithExact("getByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToSourceString(e){return Cc(String(e))}toCallWithExact(e,i,s){return gt(i)?`${e}(${this.regexToSourceString(i)})`:s?`${e}(${this.quote(i)}, { exact: true })`:`${e}(${this.quote(i)})`}toHasText(e){return gt(e)?this.regexToSourceString(e):this.quote(e)}toTestIdValue(e){return gt(e)?this.regexToSourceString(e):this.quote(e)}quote(e){return Ac(e,this.preferredQuote??"'")}}class jE{generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, has_text=${this.toHasText(a.hasText)})`:a.hasNotText!==void 0?`locator(${this.quote(s)}, has_not_text=${this.toHasText(a.hasNotText)})`:`locator(${this.quote(s)})`;case"frame-locator":return`frame_locator(${this.quote(s)})`;case"frame":return"content_frame";case"nth":return`nth(${s})`;case"first":return"first";case"last":return"last";case"visible":return`filter(visible=${s==="true"?"True":"False"})`;case"role":const o=[];gt(a.name)?o.push(`name=${this.regexToString(a.name)}`):typeof a.name=="string"&&(o.push(`name=${this.quote(a.name)}`),a.exact&&o.push("exact=True"));for(const{name:f,value:h}of a.attrs){let p=typeof h=="string"?this.quote(h):h;typeof h=="boolean"&&(p=h?"True":"False"),o.push(`${P0(f)}=${p}`)}const c=o.length?`, ${o.join(", ")}`:"";return`get_by_role(${this.quote(s)}${c})`;case"has-text":return`filter(has_text=${this.toHasText(s)})`;case"has-not-text":return`filter(has_not_text=${this.toHasText(s)})`;case"has":return`filter(has=${s})`;case"hasNot":return`filter(has_not=${s})`;case"and":return`and_(${s})`;case"or":return`or_(${s})`;case"chain":return`locator(${s})`;case"test-id":return`get_by_test_id(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("get_by_text",s,!!a.exact);case"alt":return this.toCallWithExact("get_by_alt_text",s,!!a.exact);case"placeholder":return this.toCallWithExact("get_by_placeholder",s,!!a.exact);case"label":return this.toCallWithExact("get_by_label",s,!!a.exact);case"title":return this.toCallWithExact("get_by_title",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", re.IGNORECASE":"";return`re.compile(r"${Cc(e.source).replace(/\\\//,"/").replace(/"/g,'\\"')}"${i})`}toCallWithExact(e,i,s){return gt(i)?`${e}(${this.regexToString(i)})`:s?`${e}(${this.quote(i)}, exact=True)`:`${e}(${this.quote(i)})`}toHasText(e){return gt(e)?this.regexToString(e):`${this.quote(e)}`}toTestIdValue(e){return gt(e)?this.regexToString(e):this.quote(e)}quote(e){return Ac(e,'"')}}class RE{generateLocator(e,i,s,a={}){let o;switch(e){case"page":o="Page";break;case"frame-locator":o="FrameLocator";break;case"locator":o="Locator";break}switch(i){case"default":return a.hasText!==void 0?`locator(${this.quote(s)}, new ${o}.LocatorOptions().setHasText(${this.toHasText(a.hasText)}))`:a.hasNotText!==void 0?`locator(${this.quote(s)}, new ${o}.LocatorOptions().setHasNotText(${this.toHasText(a.hasNotText)}))`:`locator(${this.quote(s)})`;case"frame-locator":return`frameLocator(${this.quote(s)})`;case"frame":return"contentFrame()";case"nth":return`nth(${s})`;case"first":return"first()";case"last":return"last()";case"visible":return`filter(new ${o}.FilterOptions().setVisible(${s==="true"?"true":"false"}))`;case"role":const c=[];gt(a.name)?c.push(`.setName(${this.regexToString(a.name)})`):typeof a.name=="string"&&(c.push(`.setName(${this.quote(a.name)})`),a.exact&&c.push(".setExact(true)"));for(const{name:h,value:p}of a.attrs)c.push(`.set${dc(h)}(${typeof p=="string"?this.quote(p):p})`);const f=c.length?`, new ${o}.GetByRoleOptions()${c.join("")}`:"";return`getByRole(AriaRole.${P0(s).toUpperCase()}${f})`;case"has-text":return`filter(new ${o}.FilterOptions().setHasText(${this.toHasText(s)}))`;case"has-not-text":return`filter(new ${o}.FilterOptions().setHasNotText(${this.toHasText(s)}))`;case"has":return`filter(new ${o}.FilterOptions().setHas(${s}))`;case"hasNot":return`filter(new ${o}.FilterOptions().setHasNot(${s}))`;case"and":return`and(${s})`;case"or":return`or(${s})`;case"chain":return`locator(${s})`;case"test-id":return`getByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact(o,"getByText",s,!!a.exact);case"alt":return this.toCallWithExact(o,"getByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact(o,"getByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact(o,"getByLabel",s,!!a.exact);case"title":return this.toCallWithExact(o,"getByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", Pattern.CASE_INSENSITIVE":"";return`Pattern.compile(${this.quote(Cc(e.source))}${i})`}toCallWithExact(e,i,s,a){return gt(s)?`${i}(${this.regexToString(s)})`:a?`${i}(${this.quote(s)}, new ${e}.${dc(i)}Options().setExact(true))`:`${i}(${this.quote(s)})`}toHasText(e){return gt(e)?this.regexToString(e):this.quote(e)}toTestIdValue(e){return gt(e)?this.regexToString(e):this.quote(e)}quote(e){return Ac(e,'"')}}class DE{generateLocator(e,i,s,a={}){switch(i){case"default":return a.hasText!==void 0?`Locator(${this.quote(s)}, new() { ${this.toHasText(a.hasText)} })`:a.hasNotText!==void 0?`Locator(${this.quote(s)}, new() { ${this.toHasNotText(a.hasNotText)} })`:`Locator(${this.quote(s)})`;case"frame-locator":return`FrameLocator(${this.quote(s)})`;case"frame":return"ContentFrame";case"nth":return`Nth(${s})`;case"first":return"First";case"last":return"Last";case"visible":return`Filter(new() { Visible = ${s==="true"?"true":"false"} })`;case"role":const o=[];gt(a.name)?o.push(`NameRegex = ${this.regexToString(a.name)}`):typeof a.name=="string"&&(o.push(`Name = ${this.quote(a.name)}`),a.exact&&o.push("Exact = true"));for(const{name:f,value:h}of a.attrs)o.push(`${dc(f)} = ${typeof h=="string"?this.quote(h):h}`);const c=o.length?`, new() { ${o.join(", ")} }`:"";return`GetByRole(AriaRole.${dc(s)}${c})`;case"has-text":return`Filter(new() { ${this.toHasText(s)} })`;case"has-not-text":return`Filter(new() { ${this.toHasNotText(s)} })`;case"has":return`Filter(new() { Has = ${s} })`;case"hasNot":return`Filter(new() { HasNot = ${s} })`;case"and":return`And(${s})`;case"or":return`Or(${s})`;case"chain":return`Locator(${s})`;case"test-id":return`GetByTestId(${this.toTestIdValue(s)})`;case"text":return this.toCallWithExact("GetByText",s,!!a.exact);case"alt":return this.toCallWithExact("GetByAltText",s,!!a.exact);case"placeholder":return this.toCallWithExact("GetByPlaceholder",s,!!a.exact);case"label":return this.toCallWithExact("GetByLabel",s,!!a.exact);case"title":return this.toCallWithExact("GetByTitle",s,!!a.exact);default:throw new Error("Unknown selector kind "+i)}}chainLocators(e){return e.join(".")}regexToString(e){const i=e.flags.includes("i")?", RegexOptions.IgnoreCase":"";return`new Regex(${this.quote(Cc(e.source))}${i})`}toCallWithExact(e,i,s){return gt(i)?`${e}(${this.regexToString(i)})`:s?`${e}(${this.quote(i)}, new() { Exact = true })`:`${e}(${this.quote(i)})`}toHasText(e){return gt(e)?`HasTextRegex = ${this.regexToString(e)}`:`HasText = ${this.quote(e)}`}toTestIdValue(e){return gt(e)?this.regexToString(e):this.quote(e)}toHasNotText(e){return gt(e)?`HasNotTextRegex = ${this.regexToString(e)}`:`HasNotText = ${this.quote(e)}`}quote(e){return Ac(e,'"')}}class BE{generateLocator(e,i,s,a={}){return JSON.stringify({kind:i,body:s,options:a})}chainLocators(e){const i=e.map(s=>JSON.parse(s));for(let s=0;s<i.length-1;++s)i[s].next=i[s+1];return JSON.stringify(i[0])}}const ev={javascript:LE,python:jE,java:RE,csharp:DE,jsonl:BE};function gt(n){return n instanceof RegExp}const _b=new Map;function zE({name:n,rootItem:e,render:i,title:s,icon:a,isError:o,isVisible:c,selectedItem:f,onAccepted:h,onSelected:p,onHighlighted:y,treeState:m,setTreeState:v,noItemsMessage:S,dataTestId:T,autoExpandDepth:x}){const E=U.useMemo(()=>UE(e,f,m.expandedItems,x||0,c),[e,f,m,x,c]),A=U.useRef(null),[N,B]=U.useState(),[V,$]=U.useState(!1);U.useEffect(()=>{y==null||y(N)},[y,N]),U.useEffect(()=>{const H=A.current;if(!H)return;const L=()=>{_b.set(n,H.scrollTop)};return H.addEventListener("scroll",L,{passive:!0}),()=>H.removeEventListener("scroll",L)},[n]),U.useEffect(()=>{A.current&&(A.current.scrollTop=_b.get(n)||0)},[n]);const z=U.useCallback(H=>{const{expanded:L}=E.get(H);if(L){for(let ne=f;ne;ne=ne.parent)if(ne===H){p==null||p(H);break}m.expandedItems.set(H.id,!1)}else m.expandedItems.set(H.id,!0);v({...m})},[E,f,p,m,v]),Q=U.useCallback(H=>{const{expanded:L}=E.get(H),ne=[H];for(;ne.length;){const ae=ne.pop();ne.push(...ae.children),m.expandedItems.set(ae.id,!L)}v({...m})},[E,m,v]);return w.jsx("div",{className:Qe("tree-view vbox",n+"-tree-view"),"data-testid":T||n+"-tree",children:w.jsxs("div",{className:Qe("tree-view-content"),role:E.size>0?"tree":void 0,tabIndex:0,onKeyDown:H=>{if(f&&H.key==="Enter"){h==null||h(f);return}if(H.key!=="ArrowDown"&&H.key!=="ArrowUp"&&H.key!=="ArrowLeft"&&H.key!=="ArrowRight")return;if(H.stopPropagation(),H.preventDefault(),f&&H.key==="ArrowLeft"){const{expanded:ne,parent:ae}=E.get(f);ne?(m.expandedItems.set(f.id,!1),v({...m})):ae&&(p==null||p(ae));return}if(f&&H.key==="ArrowRight"){f.children.length&&(m.expandedItems.set(f.id,!0),v({...m}));return}let L=f;if(H.key==="ArrowDown"&&(f?L=E.get(f).next:E.size&&(L=[...E.keys()][0])),H.key==="ArrowUp"){if(f)L=E.get(f).prev;else if(E.size){const ne=[...E.keys()];L=ne[ne.length-1]}}y==null||y(void 0),L&&($(!0),p==null||p(L)),B(void 0)},ref:A,children:[S&&E.size===0&&w.jsx("div",{className:"tree-view-empty",children:S}),e.children.map(H=>E.get(H)&&w.jsx(tv,{item:H,treeItems:E,selectedItem:f,onSelected:p,onAccepted:h,isError:o,toggleExpanded:z,toggleSubtree:Q,highlightedItem:N,setHighlightedItem:B,render:i,icon:a,title:s,isKeyboardNavigation:V,setIsKeyboardNavigation:$},H.id))]})})}function tv({item:n,treeItems:e,selectedItem:i,onSelected:s,highlightedItem:a,setHighlightedItem:o,isError:c,onAccepted:f,toggleExpanded:h,toggleSubtree:p,render:y,title:m,icon:v,isKeyboardNavigation:S,setIsKeyboardNavigation:T}){const x=U.useId(),E=U.useRef(null);U.useEffect(()=>{i===n&&S&&E.current&&(w0(E.current),T(!1))},[n,i,S,T]);const A=e.get(n),N=A.depth,B=A.expanded;let V="codicon-blank";typeof B=="boolean"&&(V=B?"codicon-chevron-down":"codicon-chevron-right");const $=y(n),z=B&&n.children.length?n.children:[],Q=m==null?void 0:m(n),H=(v==null?void 0:v(n))||"codicon-blank";return w.jsxs("div",{ref:E,role:"treeitem","aria-selected":n===i,"aria-expanded":B,"aria-controls":x,title:Q,className:"vbox",style:{flex:"none"},children:[w.jsxs("div",{onDoubleClick:()=>f==null?void 0:f(n),className:Qe("tree-view-entry",i===n&&"selected",a===n&&"highlighted",(c==null?void 0:c(n))&&"error"),onClick:()=>s==null?void 0:s(n),onMouseEnter:()=>o(n),onMouseLeave:()=>o(void 0),children:[N?new Array(N).fill(0).map((L,ne)=>w.jsx("div",{className:"tree-view-indent"},"indent-"+ne)):void 0,w.jsx("div",{"aria-hidden":"true",className:"codicon "+V,style:{minWidth:16,marginRight:4},onDoubleClick:L=>{L.preventDefault(),L.stopPropagation()},onClick:L=>{L.stopPropagation(),L.preventDefault(),L.altKey?p(n):h(n)}}),v&&w.jsx("div",{className:"codicon "+H,style:{minWidth:16,marginRight:4},"aria-label":"["+H.replace("codicon","icon")+"]"}),typeof $=="string"?w.jsx("div",{style:{textOverflow:"ellipsis",overflow:"hidden"},children:$}):$]}),!!z.length&&w.jsx("div",{id:x,role:"group",children:z.map(L=>e.get(L)&&w.jsx(tv,{item:L,treeItems:e,selectedItem:i,onSelected:s,onAccepted:f,isError:c,toggleExpanded:h,toggleSubtree:p,highlightedItem:a,setHighlightedItem:o,render:y,title:m,icon:v,isKeyboardNavigation:S,setIsKeyboardNavigation:T},L.id))})]})}function Gh(n,e,i){const s=i.get(n.id);if(s!==void 0)return s;const a=e(n),o=a==="if-needed"?n.children.some(c=>Gh(c,e,i)):a;return i.set(n.id,o),o}function UE(n,e,i,s,a=()=>!0){const o=new Map;if(!Gh(n,a,o))return new Map;const c=new Map,f=new Set;for(let y=e==null?void 0:e.parent;y;y=y.parent)f.add(y.id);let h=null;const p=(y,m)=>{for(const v of y.children){if(!Gh(v,a,o))continue;const S=f.has(v.id)||i.get(v.id),T=s>m&&c.size<25&&S!==!1,x=v.children.length?S??T:void 0,E={depth:m,expanded:x,parent:n===y?null:y,next:null,prev:h};h&&(c.get(h).next=v),h=v,c.set(v,E),x&&p(v,m+1)}};return p(n,0),c}const It=U.forwardRef(function({children:e,title:i="",icon:s,disabled:a=!1,toggled:o=!1,onClick:c=()=>{},style:f,testId:h,className:p,ariaLabel:y},m){return w.jsxs("button",{ref:m,className:Qe(p,"toolbar-button",s,o&&"toggled"),onMouseDown:Ab,onClick:c,onDoubleClick:Ab,title:i,disabled:!!a,style:f,"data-testid":h,"aria-label":y||i,children:[s&&w.jsx("span",{className:`codicon codicon-${s}`,style:e?{marginRight:5}:{}}),e]})}),Ab=n=>{n.stopPropagation(),n.preventDefault()};function nv(n){return n==="scheduled"?"codicon-clock":n==="running"?"codicon-loading":n==="failed"?"codicon-error":n==="passed"?"codicon-check":n==="skipped"?"codicon-circle-slash":"codicon-circle-outline"}function HE(n){return n==="scheduled"?"Pending":n==="running"?"Running":n==="failed"?"Failed":n==="passed"?"Passed":n==="skipped"?"Skipped":"Did not run"}const qE=zE,IE=({actions:n,selectedAction:e,selectedTime:i,setSelectedTime:s,treeState:a,setTreeState:o,sdkLanguage:c,onSelected:f,onHighlighted:h,revealConsole:p,revealActionAttachment:y,isLive:m,actionFilterText:v})=>{const{rootItem:S,itemMap:T}=U.useMemo(()=>k0(n),[n]),{selectedItem:x}=U.useMemo(()=>({selectedItem:e?T.get(e.callId):void 0}),[T,e]),E=U.useCallback(z=>{var Q;return!!((Q=z.action.error)!=null&&Q.message)},[]),A=U.useCallback(z=>s({minimum:z.action.startTime,maximum:z.action.endTime}),[s]),N=U.useCallback(z=>{var H;const Q=!!y&&!!((H=z.action.attachments)!=null&&H.length);return vd(z.action,{sdkLanguage:c,revealConsole:p,revealActionAttachment:()=>y==null?void 0:y(z.action.callId),isLive:m,showDuration:!0,showBadges:!0,showAttachments:Q})},[m,p,y,c]),B=U.useCallback(z=>{if(!(!i||!z.action||z.action.startTime<=i.maximum&&z.action.endTime>=i.minimum))return!1;const H=Sd(z.action).title;return v?H.toLowerCase().includes(v.toLowerCase())?!0:"if-needed":!0},[i,v]),V=U.useCallback(z=>{f==null||f(z.action)},[f]),$=U.useCallback(z=>{h==null||h(z==null?void 0:z.action)},[h]);return w.jsxs("div",{className:"vbox action-list-container",children:[i&&w.jsxs("div",{className:"action-list-show-all",onClick:()=>s(void 0),children:[w.jsx("span",{className:"codicon codicon-triangle-left"}),"Show all"]}),w.jsx(qE,{name:"actions",rootItem:S,treeState:a,setTreeState:o,selectedItem:x,onSelected:V,onHighlighted:$,onAccepted:A,isError:E,isVisible:B,render:N,autoExpandDepth:v!=null&&v.trim()?5:0})]})},vd=(n,e)=>{var E;const{sdkLanguage:i,revealConsole:s,revealActionAttachment:a,isLive:o,showDuration:c,showBadges:f,showAttachments:h}=e,{errors:p,warnings:y}=iE(n),m=n.params.selector?Z0(i||"javascript",n.params.selector):void 0,v=n.class==="Test"&&n.method==="test.step"&&((E=n.annotations)==null?void 0:E.some(A=>A.type==="skip"));let S="";n.endTime?S=mt(n.endTime-n.startTime):n.error?S="Timed out":o||(S="-");const{elements:T,title:x}=Sd(n);return w.jsxs("div",{className:"action-title vbox",children:[w.jsxs("div",{className:"hbox",children:[w.jsx("span",{className:"action-title-method",title:x,children:T}),(c||f||h||v)&&w.jsx("div",{className:"spacer"}),h&&w.jsx(It,{icon:"attach",title:"Open Attachment",onClick:()=>a==null?void 0:a()}),c&&!v&&w.jsx("div",{className:"action-duration",children:S||w.jsx("span",{className:"codicon codicon-loading"})}),v&&w.jsx("span",{className:Qe("action-skipped","codicon",nv("skipped")),title:"skipped"}),f&&w.jsxs("div",{className:"action-icons",onClick:()=>s==null?void 0:s(),children:[!!p&&w.jsxs("div",{className:"action-icon",children:[w.jsx("span",{className:"codicon codicon-error"}),w.jsx("span",{className:"action-icon-value",children:p})]}),!!y&&w.jsxs("div",{className:"action-icon",children:[w.jsx("span",{className:"codicon codicon-warning"}),w.jsx("span",{className:"action-icon-value",children:y})]})]})]}),m&&w.jsx("div",{className:"action-title-selector",title:m,children:m})]})};function Sd(n,e){var p;let i=n.title??((p=pd.get(n.class+"."+n.method))==null?void 0:p.title)??n.method;i=i.replace(/\n/g," ");const s=[],a=[];let o=0;const c=/\{([^}]+)\}/g;let f;for(;(f=c.exec(i))!==null;){const[y,m]=f,v=i.slice(o,f.index);s.push(v),a.push(v);const S=_0(n.params,m);S===void 0?(s.push(y),a.push(y)):f.index===0?(s.push(S),a.push(S)):(s.push(w.jsx("span",{className:"action-title-param",children:S},s.length)),a.push(S)),o=f.index+y.length}if(o<i.length){const y=i.slice(o);s.push(y),a.push(y)}const h=n.params.selector?Z0("javascript",n.params.selector):void 0;return h&&(a.push(" "),a.push(h)),{elements:s,title:a.join("")}}const wd=({value:n,description:e})=>{const[i,s]=U.useState("copy"),a=U.useCallback(()=>{(typeof n=="function"?n():Promise.resolve(n)).then(c=>{navigator.clipboard.writeText(c).then(()=>{s("check"),setTimeout(()=>{s("copy")},3e3)},()=>{s("close")})},()=>{s("close")})},[n]);return w.jsx(It,{title:e||"Copy",icon:i,onClick:a})},ec=({value:n,description:e,copiedDescription:i=e,style:s})=>{const[a,o]=U.useState(!1),c=U.useCallback(async()=>{const f=typeof n=="function"?await n():n;await navigator.clipboard.writeText(f),o(!0),setTimeout(()=>o(!1),3e3)},[n]);return w.jsx(It,{style:s,title:e,onClick:c,className:"copy-to-clipboard-text-button",children:a?i:e})},vs=({text:n})=>w.jsx("div",{className:"fill",style:{display:"flex",alignItems:"center",justifyContent:"center",fontSize:24,fontWeight:"bold",opacity:.5},children:n}),$E=({action:n,startTimeOffset:e,sdkLanguage:i})=>{const s=U.useMemo(()=>Object.keys((n==null?void 0:n.params)??{}).filter(f=>f!=="info"),[n]);if(!n)return w.jsx(vs,{text:"No action selected"});const a=n.startTime-e,o=mt(a),{title:c}=Sd(n);return w.jsxs("div",{className:"call-tab",children:[w.jsx("div",{className:"call-line",children:c}),w.jsx("div",{className:"call-section",children:"Time"}),Ho({name:"start",type:"literal",text:o}),Ho({name:"duration",type:"literal",text:VE(n)}),!!s.length&&w.jsxs(w.Fragment,{children:[w.jsx("div",{className:"call-section",children:"Parameters"}),s.map(f=>Ho(Cb(n,f,n.params[f],i)))]}),!!n.result&&w.jsxs(w.Fragment,{children:[w.jsx("div",{className:"call-section",children:"Return value"}),Object.keys(n.result).map(f=>Ho(Cb(n,f,n.result[f],i)))]})]})};function VE(n){return n.endTime?mt(n.endTime-n.startTime):n.error?"Timed Out":"Running"}function Ho(n){let e=n.text.replace(/\n/g,"↵");return n.type==="string"&&(e=`"${e}"`),w.jsxs("div",{className:"call-line",children:[n.name,":",w.jsx("span",{className:Qe("call-value",n.type),title:n.text,children:e}),["literal","string","number","object","locator"].includes(n.type)&&w.jsx(wd,{value:n.text})]},n.name)}function Cb(n,e,i,s){const a=n.method.includes("eval")||n.method==="waitForFunction";if(e==="files")return{text:"<files>",type:"string",name:e};if((e==="eventInit"||e==="expectedValue"||e==="arg"&&a)&&(i=gc(i.value,new Array(10).fill({handle:"<handle>"}))),(e==="value"&&a||e==="received"&&n.method==="expect")&&(i=gc(i,new Array(10).fill({handle:"<handle>"}))),e==="selector")return{text:Li(s||"javascript",n.params.selector),type:"locator",name:"locator"};const o=typeof i;return o!=="object"||i===null?{text:String(i),type:o,name:e}:i.guid?{text:"<handle>",type:"handle",name:e}:{text:JSON.stringify(i).slice(0,1e3),type:"object",name:e}}function gc(n,e){if(n.n!==void 0)return n.n;if(n.s!==void 0)return n.s;if(n.b!==void 0)return n.b;if(n.v!==void 0){if(n.v==="undefined")return;if(n.v==="null")return null;if(n.v==="NaN")return NaN;if(n.v==="Infinity")return 1/0;if(n.v==="-Infinity")return-1/0;if(n.v==="-0")return-0}if(n.d!==void 0)return new Date(n.d);if(n.r!==void 0)return new RegExp(n.r.p,n.r.f);if(n.a!==void 0)return n.a.map(i=>gc(i,e));if(n.o!==void 0){const i={};for(const{k:s,v:a}of n.o)i[s]=gc(a,e);return i}return n.h!==void 0?e===void 0?"<object>":e[n.h]:"<object>"}const Nb=new Map;function Nc({name:n,items:e=[],id:i,render:s,icon:a,isError:o,isWarning:c,isInfo:f,selectedItem:h,onAccepted:p,onSelected:y,onHighlighted:m,onIconClicked:v,noItemsMessage:S,dataTestId:T,notSelectable:x,ariaLabel:E}){const A=U.useRef(null),[N,B]=U.useState();return U.useEffect(()=>{m==null||m(N)},[m,N]),U.useEffect(()=>{const V=A.current;if(!V)return;const $=()=>{Nb.set(n,V.scrollTop)};return V.addEventListener("scroll",$,{passive:!0}),()=>V.removeEventListener("scroll",$)},[n]),U.useEffect(()=>{A.current&&(A.current.scrollTop=Nb.get(n)||0)},[n]),w.jsx("div",{className:Qe("list-view vbox",n+"-list-view"),role:e.length>0?"list":void 0,"aria-label":E,children:w.jsxs("div",{className:Qe("list-view-content",x&&"not-selectable"),tabIndex:0,onKeyDown:V=>{var H;if(h&&V.key==="Enter"){p==null||p(h,e.indexOf(h));return}if(V.key!=="ArrowDown"&&V.key!=="ArrowUp")return;V.stopPropagation(),V.preventDefault();const $=h?e.indexOf(h):-1;let z=$;V.key==="ArrowDown"&&($===-1?z=0:z=Math.min($+1,e.length-1)),V.key==="ArrowUp"&&($===-1?z=e.length-1:z=Math.max($-1,0));const Q=(H=A.current)==null?void 0:H.children.item(z);w0(Q||void 0),m==null||m(void 0),y==null||y(e[z],z),B(void 0)},ref:A,children:[S&&e.length===0&&w.jsx("div",{className:"list-view-empty",children:S}),e.map((V,$)=>{const z=s(V,$);return w.jsxs("div",{onDoubleClick:()=>p==null?void 0:p(V,$),role:"listitem",className:Qe("list-view-entry",h===V&&"selected",!x&&N===V&&"highlighted",(o==null?void 0:o(V,$))&&"error",(c==null?void 0:c(V,$))&&"warning",(f==null?void 0:f(V,$))&&"info"),"aria-selected":h===V,onClick:()=>y==null?void 0:y(V,$),onMouseEnter:()=>B(V),onMouseLeave:()=>B(void 0),children:[a&&w.jsx("div",{className:"codicon "+(a(V,$)||"codicon-blank"),style:{minWidth:16,marginRight:4},onDoubleClick:Q=>{Q.preventDefault(),Q.stopPropagation()},onClick:Q=>{Q.stopPropagation(),Q.preventDefault(),v==null||v(V,$)}}),typeof z=="string"?w.jsx("div",{style:{textOverflow:"ellipsis",overflow:"hidden"},children:z}):z]},(i==null?void 0:i(V,$))||$)})]})})}const GE=Nc,KE=({action:n,isLive:e})=>{const i=U.useMemo(()=>{var c;if(!n||!n.log.length)return[];const s=n.log,a=n.context.wallTime-n.context.startTime,o=[];for(let f=0;f<s.length;++f){let h="";if(s[f].time!==-1){const p=(c=s[f])==null?void 0:c.time;f+1<s.length?h=mt(s[f+1].time-p):n.endTime>0?h=mt(n.endTime-p):e?h=mt(Date.now()-a-p):h="-"}o.push({message:s[f].message,time:h})}return o},[n,e]);return i.length?w.jsx(GE,{name:"log",ariaLabel:"Log entries",items:i,render:s=>w.jsxs("div",{className:"log-list-item",children:[w.jsx("span",{className:"log-list-duration",children:s.time}),s.message]}),notSelectable:!0}):w.jsx(vs,{text:"No log entries"})};function cl(n,e){const i=/(\x1b\[(\d+(;\d+)*)m)|([^\x1b]+)/g,s=[];let a,o={},c=!1,f=e==null?void 0:e.fg,h=e==null?void 0:e.bg;for(;(a=i.exec(n))!==null;){const[,,p,,y]=a;if(p){const m=+p;switch(m){case 0:o={};break;case 1:o["font-weight"]="bold";break;case 2:o.opacity="0.8";break;case 3:o["font-style"]="italic";break;case 4:o["text-decoration"]="underline";break;case 7:c=!0;break;case 8:o.display="none";break;case 9:o["text-decoration"]="line-through";break;case 22:delete o["font-weight"],delete o["font-style"],delete o.opacity,delete o["text-decoration"];break;case 23:delete o["font-weight"],delete o["font-style"],delete o.opacity;break;case 24:delete o["text-decoration"];break;case 27:c=!1;break;case 30:case 31:case 32:case 33:case 34:case 35:case 36:case 37:f=kb[m-30];break;case 39:f=e==null?void 0:e.fg;break;case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:h=kb[m-40];break;case 49:h=e==null?void 0:e.bg;break;case 53:o["text-decoration"]="overline";break;case 90:case 91:case 92:case 93:case 94:case 95:case 96:case 97:f=Mb[m-90];break;case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:h=Mb[m-100];break}}else if(y){const m={...o},v=c?h:f;v!==void 0&&(m.color=v);const S=c?f:h;S!==void 0&&(m["background-color"]=S),s.push(`<span style="${FE(m)}">${XE(y)}</span>`)}}return s.join("")}const kb={0:"var(--vscode-terminal-ansiBlack)",1:"var(--vscode-terminal-ansiRed)",2:"var(--vscode-terminal-ansiGreen)",3:"var(--vscode-terminal-ansiYellow)",4:"var(--vscode-terminal-ansiBlue)",5:"var(--vscode-terminal-ansiMagenta)",6:"var(--vscode-terminal-ansiCyan)",7:"var(--vscode-terminal-ansiWhite)"},Mb={0:"var(--vscode-terminal-ansiBrightBlack)",1:"var(--vscode-terminal-ansiBrightRed)",2:"var(--vscode-terminal-ansiBrightGreen)",3:"var(--vscode-terminal-ansiBrightYellow)",4:"var(--vscode-terminal-ansiBrightBlue)",5:"var(--vscode-terminal-ansiBrightMagenta)",6:"var(--vscode-terminal-ansiBrightCyan)",7:"var(--vscode-terminal-ansiBrightWhite)"};function XE(n){return n.replace(/[&"<>]/g,e=>({"&":"&",'"':""","<":"<",">":">"})[e])}function FE(n){return Object.entries(n).map(([e,i])=>`${e}: ${i}`).join("; ")}const YE=({error:n})=>{const e=U.useMemo(()=>cl(n),[n]);return w.jsx("div",{className:"error-message",dangerouslySetInnerHTML:{__html:e||""}})},iv=({cursor:n,onPaneMouseMove:e,onPaneMouseUp:i,onPaneDoubleClick:s})=>(yt.useEffect(()=>{const a=document.createElement("div");return a.style.position="fixed",a.style.top="0",a.style.right="0",a.style.bottom="0",a.style.left="0",a.style.zIndex="9999",a.style.cursor=n,document.body.appendChild(a),e&&a.addEventListener("mousemove",e),i&&a.addEventListener("mouseup",i),s&&document.body.addEventListener("dblclick",s),()=>{e&&a.removeEventListener("mousemove",e),i&&a.removeEventListener("mouseup",i),s&&document.body.removeEventListener("dblclick",s),document.body.removeChild(a)}},[n,e,i,s]),w.jsx(w.Fragment,{})),QE={position:"absolute",top:0,right:0,bottom:0,left:0},sv=({orientation:n,offsets:e,setOffsets:i,resizerColor:s,resizerWidth:a,minColumnWidth:o})=>{const c=o||0,[f,h]=yt.useState(null),[p,y]=bs(),m={position:"absolute",right:n==="horizontal"?void 0:0,bottom:n==="horizontal"?0:void 0,width:n==="horizontal"?7:void 0,height:n==="horizontal"?void 0:7,borderTopWidth:n==="horizontal"?void 0:(7-a)/2,borderRightWidth:n==="horizontal"?(7-a)/2:void 0,borderBottomWidth:n==="horizontal"?void 0:(7-a)/2,borderLeftWidth:n==="horizontal"?(7-a)/2:void 0,borderColor:"transparent",borderStyle:"solid",cursor:n==="horizontal"?"ew-resize":"ns-resize"};return w.jsxs("div",{style:{position:"absolute",top:0,right:0,bottom:0,left:-(7-a)/2,zIndex:100,pointerEvents:"none"},ref:y,children:[!!f&&w.jsx(iv,{cursor:n==="horizontal"?"ew-resize":"ns-resize",onPaneMouseUp:()=>h(null),onPaneMouseMove:v=>{if(!v.buttons)h(null);else if(f){const S=n==="horizontal"?v.clientX-f.clientX:v.clientY-f.clientY,T=f.offset+S,x=f.index>0?e[f.index-1]:0,E=n==="horizontal"?p.width:p.height,A=Math.min(Math.max(x+c,T),E-c)-e[f.index];for(let N=f.index;N<e.length;++N)e[N]=e[N]+A;i([...e])}}}),e.map((v,S)=>w.jsx("div",{style:{...m,top:n==="horizontal"?0:v,left:n==="horizontal"?v:0,pointerEvents:"initial"},onMouseDown:T=>h({clientX:T.clientX,clientY:T.clientY,offset:v,index:S}),children:w.jsx("div",{style:{...QE,background:s}})},S))]})};async function vh(n){const e=new Image;return n&&(e.src=n,await new Promise((i,s)=>{e.onload=i,e.onerror=i})),e}const Kh={backgroundImage:`linear-gradient(45deg, #80808020 25%, transparent 25%),
|
|
53
|
+
linear-gradient(-45deg, #80808020 25%, transparent 25%),
|
|
54
|
+
linear-gradient(45deg, transparent 75%, #80808020 75%),
|
|
55
|
+
linear-gradient(-45deg, transparent 75%, #80808020 75%)`,backgroundSize:"20px 20px",backgroundPosition:"0 0, 0 10px, 10px -10px, -10px 0px",boxShadow:`rgb(0 0 0 / 10%) 0px 1.8px 1.9px,
|
|
56
|
+
rgb(0 0 0 / 15%) 0px 6.1px 6.3px,
|
|
57
|
+
rgb(0 0 0 / 10%) 0px -2px 4px,
|
|
58
|
+
rgb(0 0 0 / 15%) 0px -6.1px 12px,
|
|
59
|
+
rgb(0 0 0 / 25%) 0px 6px 12px`},PE=({diff:n,noTargetBlank:e,hideDetails:i})=>{const[s,a]=U.useState(n.diff?"diff":"actual"),[o,c]=U.useState(!1),[f,h]=U.useState(null),[p,y]=U.useState("Expected"),[m,v]=U.useState(null),[S,T]=U.useState(null),[x,E]=bs();U.useEffect(()=>{(async()=>{var L,ne,ae,G;h(await vh((L=n.expected)==null?void 0:L.attachment.path)),y(((ne=n.expected)==null?void 0:ne.title)||"Expected"),v(await vh((ae=n.actual)==null?void 0:ae.attachment.path)),T(await vh((G=n.diff)==null?void 0:G.attachment.path))})()},[n]);const A=f&&m&&S,N=A?Math.max(f.naturalWidth,m.naturalWidth,200):500,B=A?Math.max(f.naturalHeight,m.naturalHeight,200):500,V=Math.min(1,(x.width-30)/N),$=Math.min(1,(x.width-50)/N/2),z=N*V,Q=B*V,H={flex:"none",margin:"0 10px",cursor:"pointer",userSelect:"none"};return w.jsx("div",{"data-testid":"test-result-image-mismatch",style:{display:"flex",flexDirection:"column",alignItems:"center",flex:"auto"},ref:E,children:A&&w.jsxs(w.Fragment,{children:[w.jsxs("div",{"data-testid":"test-result-image-mismatch-tabs",style:{display:"flex",margin:"10px 0 20px"},children:[n.diff&&w.jsx("div",{style:{...H,fontWeight:s==="diff"?600:"initial"},onClick:()=>a("diff"),children:"Diff"}),w.jsx("div",{style:{...H,fontWeight:s==="actual"?600:"initial"},onClick:()=>a("actual"),children:"Actual"}),w.jsx("div",{style:{...H,fontWeight:s==="expected"?600:"initial"},onClick:()=>a("expected"),children:p}),w.jsx("div",{style:{...H,fontWeight:s==="sxs"?600:"initial"},onClick:()=>a("sxs"),children:"Side by side"}),w.jsx("div",{style:{...H,fontWeight:s==="slider"?600:"initial"},onClick:()=>a("slider"),children:"Slider"})]}),w.jsxs("div",{style:{display:"flex",justifyContent:"center",flex:"auto",minHeight:Q+60},children:[n.diff&&s==="diff"&&w.jsx(Zn,{image:S,alt:"Diff",hideSize:i,canvasWidth:z,canvasHeight:Q,scale:V}),n.diff&&s==="actual"&&w.jsx(Zn,{image:m,alt:"Actual",hideSize:i,canvasWidth:z,canvasHeight:Q,scale:V}),n.diff&&s==="expected"&&w.jsx(Zn,{image:f,alt:p,hideSize:i,canvasWidth:z,canvasHeight:Q,scale:V}),n.diff&&s==="slider"&&w.jsx(JE,{expectedImage:f,actualImage:m,hideSize:i,canvasWidth:z,canvasHeight:Q,scale:V,expectedTitle:p}),n.diff&&s==="sxs"&&w.jsxs("div",{style:{display:"flex"},children:[w.jsx(Zn,{image:f,title:p,hideSize:i,canvasWidth:$*N,canvasHeight:$*B,scale:$}),w.jsx(Zn,{image:o?S:m,title:o?"Diff":"Actual",onClick:()=>c(!o),hideSize:i,canvasWidth:$*N,canvasHeight:$*B,scale:$})]}),!n.diff&&s==="actual"&&w.jsx(Zn,{image:m,title:"Actual",hideSize:i,canvasWidth:z,canvasHeight:Q,scale:V}),!n.diff&&s==="expected"&&w.jsx(Zn,{image:f,title:p,hideSize:i,canvasWidth:z,canvasHeight:Q,scale:V}),!n.diff&&s==="sxs"&&w.jsxs("div",{style:{display:"flex"},children:[w.jsx(Zn,{image:f,title:p,canvasWidth:$*N,canvasHeight:$*B,scale:$}),w.jsx(Zn,{image:m,title:"Actual",canvasWidth:$*N,canvasHeight:$*B,scale:$})]})]}),!i&&w.jsxs("div",{style:{alignSelf:"start",lineHeight:"18px",marginLeft:"15px"},children:[w.jsx("div",{children:n.diff&&w.jsx("a",{target:"_blank",href:n.diff.attachment.path,rel:"noreferrer",children:n.diff.attachment.name})}),w.jsx("div",{children:w.jsx("a",{target:e?"":"_blank",href:n.actual.attachment.path,rel:"noreferrer",children:n.actual.attachment.name})}),w.jsx("div",{children:w.jsx("a",{target:e?"":"_blank",href:n.expected.attachment.path,rel:"noreferrer",children:n.expected.attachment.name})})]})]})})},JE=({expectedImage:n,actualImage:e,canvasWidth:i,canvasHeight:s,scale:a,expectedTitle:o,hideSize:c})=>{const f={position:"absolute",top:0,left:0},[h,p]=U.useState(i/2),y=n.naturalWidth===e.naturalWidth&&n.naturalHeight===e.naturalHeight;return w.jsxs("div",{style:{flex:"none",display:"flex",alignItems:"center",flexDirection:"column",userSelect:"none"},children:[!c&&w.jsxs("div",{style:{margin:5},children:[!y&&w.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"Expected "}),w.jsx("span",{children:n.naturalWidth}),w.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),w.jsx("span",{children:n.naturalHeight}),!y&&w.jsx("span",{style:{flex:"none",margin:"0 5px 0 15px"},children:"Actual "}),!y&&w.jsx("span",{children:e.naturalWidth}),!y&&w.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),!y&&w.jsx("span",{children:e.naturalHeight})]}),w.jsxs("div",{style:{position:"relative",width:i,height:s,margin:15,...Kh},children:[w.jsx(sv,{orientation:"horizontal",offsets:[h],setOffsets:m=>p(m[0]),resizerColor:"#57606a80",resizerWidth:6}),w.jsx("img",{alt:o,style:{width:n.naturalWidth*a,height:n.naturalHeight*a},draggable:"false",src:n.src}),w.jsx("div",{style:{...f,bottom:0,overflow:"hidden",width:h,...Kh},children:w.jsx("img",{alt:"Actual",style:{width:e.naturalWidth*a,height:e.naturalHeight*a},draggable:"false",src:e.src})})]})]})},Zn=({image:n,title:e,alt:i,hideSize:s,canvasWidth:a,canvasHeight:o,scale:c,onClick:f})=>w.jsxs("div",{style:{flex:"none",display:"flex",alignItems:"center",flexDirection:"column"},children:[!s&&w.jsxs("div",{style:{margin:5},children:[e&&w.jsx("span",{style:{flex:"none",margin:"0 5px"},children:e}),w.jsx("span",{children:n.naturalWidth}),w.jsx("span",{style:{flex:"none",margin:"0 5px"},children:"x"}),w.jsx("span",{children:n.naturalHeight})]}),w.jsx("div",{style:{display:"flex",flex:"none",width:a,height:o,margin:15,...Kh},children:w.jsx("img",{width:n.naturalWidth*c,height:n.naturalHeight*c,alt:e||i,style:{cursor:f?"pointer":"initial"},draggable:"false",src:n.src,onClick:f})})]}),ZE="modulepreload",WE=function(n,e){return new URL(n,e).href},Ob={},eT=function(e,i,s){let a=Promise.resolve();if(i&&i.length>0){let c=function(y){return Promise.all(y.map(m=>Promise.resolve(m).then(v=>({status:"fulfilled",value:v}),v=>({status:"rejected",reason:v}))))};const f=document.getElementsByTagName("link"),h=document.querySelector("meta[property=csp-nonce]"),p=(h==null?void 0:h.nonce)||(h==null?void 0:h.getAttribute("nonce"));a=c(i.map(y=>{if(y=WE(y,s),y in Ob)return;Ob[y]=!0;const m=y.endsWith(".css"),v=m?'[rel="stylesheet"]':"";if(!!s)for(let x=f.length-1;x>=0;x--){const E=f[x];if(E.href===y&&(!m||E.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${y}"]${v}`))return;const T=document.createElement("link");if(T.rel=m?"stylesheet":ZE,m||(T.as="script"),T.crossOrigin="",T.href=y,p&&T.setAttribute("nonce",p),document.head.appendChild(T),m)return new Promise((x,E)=>{T.addEventListener("load",x),T.addEventListener("error",()=>E(new Error(`Unable to preload CSS for ${y}`)))})}))}function o(c){const f=new Event("vite:preloadError",{cancelable:!0});if(f.payload=c,window.dispatchEvent(f),!f.defaultPrevented)throw c}return a.then(c=>{for(const f of c||[])f.status==="rejected"&&o(f.reason);return e().catch(o)})},tT=20,Cr=({text:n,highlighter:e,mimeType:i,linkify:s,readOnly:a,highlight:o,revealLine:c,lineNumbers:f,isFocused:h,focusOnChange:p,wrapLines:y,onChange:m,dataTestId:v,placeholder:S})=>{const[T,x]=bs(),[E]=U.useState(eT(()=>import("./codeMirrorModule-RgXeHFoQ.js"),__vite__mapDeps([0,1]),import.meta.url).then(V=>V.default)),A=U.useRef(null),[N,B]=U.useState();return U.useEffect(()=>{(async()=>{var H,L;const V=await E;iT(V);const $=x.current;if(!$)return;const z=rT(e)||sT(i)||(s?"text/linkified":"");if(A.current&&z===A.current.cm.getOption("mode")&&!!a===A.current.cm.getOption("readOnly")&&f===A.current.cm.getOption("lineNumbers")&&y===A.current.cm.getOption("lineWrapping")&&S===A.current.cm.getOption("placeholder"))return;(L=(H=A.current)==null?void 0:H.cm)==null||L.getWrapperElement().remove();const Q=V($,{value:"",mode:z,readOnly:!!a,lineNumbers:f,lineWrapping:y,placeholder:S,matchBrackets:!0,autoCloseBrackets:!0,extraKeys:{"Ctrl-F":"findPersistent","Cmd-F":"findPersistent"}});return A.current={cm:Q},h&&Q.focus(),B(Q),Q})()},[E,N,x,e,i,s,f,y,a,h,S]),U.useEffect(()=>{A.current&&A.current.cm.setSize(T.width,T.height)},[T]),U.useLayoutEffect(()=>{var z;if(!N)return;let V=!1;if(N.getValue()!==n&&(N.setValue(n),V=!0,p&&(N.execCommand("selectAll"),N.focus())),V||JSON.stringify(o)!==JSON.stringify(A.current.highlight)){for(const L of A.current.highlight||[])N.removeLineClass(L.line-1,"wrap");for(const L of o||[])N.addLineClass(L.line-1,"wrap",`source-line-${L.type}`);for(const L of A.current.widgets||[])N.removeLineWidget(L);for(const L of A.current.markers||[])L.clear();const Q=[],H=[];for(const L of o||[]){if(L.type!=="subtle-error"&&L.type!=="error")continue;const ne=(z=A.current)==null?void 0:z.cm.getLine(L.line-1);if(ne){const ae={};ae.title=L.message||"",H.push(N.markText({line:L.line-1,ch:0},{line:L.line-1,ch:L.column||ne.length},{className:"source-line-error-underline",attributes:ae}))}if(L.type==="error"){const ae=document.createElement("div");ae.innerHTML=cl(L.message||""),ae.className="source-line-error-widget",Q.push(N.addLineWidget(L.line,ae,{above:!0,coverGutter:!1}))}}A.current.highlight=o,A.current.widgets=Q,A.current.markers=H}typeof c=="number"&&A.current.cm.lineCount()>=c&&N.scrollIntoView({line:Math.max(0,c-1),ch:0},50);let $;return m&&($=()=>m(N.getValue()),N.on("change",$)),()=>{$&&N.off("change",$)}},[N,n,o,c,p,m]),w.jsx("div",{"data-testid":v,className:"cm-wrapper",ref:x,onClick:nT})};function nT(n){var i;if(!(n.target instanceof HTMLElement))return;let e;n.target.classList.contains("cm-linkified")?e=n.target.textContent:n.target.classList.contains("cm-link")&&((i=n.target.nextElementSibling)!=null&&i.classList.contains("cm-url"))&&(e=n.target.nextElementSibling.textContent.slice(1,-1)),e&&(n.preventDefault(),n.stopPropagation(),window.open(e,"_blank"))}let Lb=!1;function iT(n){Lb||(Lb=!0,n.defineSimpleMode("text/linkified",{start:[{regex:x0,token:"linkified"}]}))}function sT(n){if(n){if(n.includes("javascript")||n.includes("json"))return"javascript";if(n.includes("python"))return"python";if(n.includes("csharp"))return"text/x-csharp";if(n.includes("java"))return"text/x-java";if(n.includes("markdown"))return"markdown";if(n.includes("html")||n.includes("svg"))return"htmlmixed";if(n.includes("css"))return"css"}}function rT(n){if(n)return{javascript:"javascript",jsonl:"javascript",python:"python",csharp:"text/x-csharp",java:"text/x-java",markdown:"markdown",html:"htmlmixed",css:"css",yaml:"yaml"}[n]}function aT(n){return!!n.match(/^(application\/json|application\/.*?\+json|text\/(x-)?json)(;\s*charset=.*)?$/)}function lT(n){return!!n.match(/^(application\/xml|application\/.*?\+xml|text\/xml)(;\s*charset=.*)?$/)}function oT(n){return!!n.match(/^(text\/.*?|application\/(json|(x-)?javascript|xml.*?|ecmascript|graphql|x-www-form-urlencoded)|image\/svg(\+xml)?|application\/.*?(\+json|\+xml))(;\s*charset=.*)?$/)}const rv=({title:n,children:e,setExpanded:i,expanded:s,expandOnTitleClick:a,className:o})=>{const c=U.useId(),f=U.useId(),h=U.useCallback(()=>i(!s),[s,i]),p=w.jsx("div",{className:Qe("codicon",s?"codicon-chevron-down":"codicon-chevron-right"),style:{cursor:"pointer",color:"var(--vscode-foreground)",marginLeft:"5px"},onClick:a?void 0:h});return w.jsxs("div",{className:Qe("expandable",s&&"expanded",o),children:[a?w.jsxs("div",{id:c,role:"button","aria-expanded":s,"aria-controls":f,className:"expandable-title",onClick:h,children:[p,n]}):w.jsxs("div",{className:"expandable-title",children:[p,n]}),s&&w.jsx("div",{id:f,"aria-labelledby":c,role:"region",className:"expandable-content",children:e})]})};function av(n){const e=[];let i=0,s;for(;(s=x0.exec(n))!==null;){const o=n.substring(i,s.index);o&&e.push(o);const c=s[0];e.push(cT(c)),i=s.index+c.length}const a=n.substring(i);return a&&e.push(a),e}function cT(n){let e=n;return e.startsWith("www.")&&(e="https://"+e),w.jsx("a",{href:e,target:"_blank",rel:"noopener noreferrer",children:n})}const lv=U.createContext(void 0),si=()=>U.useContext(lv),uT=({attachment:n,reveal:e})=>{const i=si(),[s,a]=U.useState(!1),[o,c]=U.useState(null),[f,h]=U.useState(null),[p,y]=Bx(),m=U.useRef(null),v=oT(n.contentType),S=!!n.sha1||!!n.path;U.useEffect(()=>{var E;if(e)return(E=m.current)==null||E.scrollIntoView({behavior:"smooth"}),y()},[e,y]),U.useEffect(()=>{s&&o===null&&f===null&&(h("Loading ..."),fetch(kc(i,n)).then(E=>E.text()).then(E=>{c(E),h(null)}).catch(E=>{h("Failed to load: "+E.message)}))},[i,s,o,f,n]);const T=U.useMemo(()=>{const E=o?o.split(`
|
|
60
|
+
`).length:0;return Math.min(Math.max(5,E),20)*tT},[o]),x=w.jsxs("span",{style:{marginLeft:5},ref:m,"aria-label":n.name,children:[w.jsx("span",{children:av(n.name)}),S&&w.jsx("a",{style:{marginLeft:5},href:tc(i,n),children:"download"})]});return!v||!S?w.jsx("div",{style:{marginLeft:20},children:x}):w.jsxs("div",{className:Qe(p&&"yellow-flash"),children:[w.jsx(rv,{title:x,expanded:s,setExpanded:a,expandOnTitleClick:!0,children:f&&w.jsx("i",{children:f})}),s&&o!==null&&w.jsx("div",{className:"vbox",style:{height:T},children:w.jsx(Cr,{text:o,readOnly:!0,mimeType:n.contentType,linkify:!0,lineNumbers:!0,wrapLines:!1})})]})},fT=({revealedAttachmentCallId:n})=>{const e=si(),{diffMap:i,screenshots:s,attachments:a}=U.useMemo(()=>{const o=new Set((e==null?void 0:e.visibleAttachments)??[]),c=new Set,f=new Map;for(const h of o){if(!h.path&&!h.sha1)continue;const p=h.name.match(/^(.*)-(expected|actual|diff)\.png$/);if(p){const y=p[1],m=p[2],v=f.get(y)||{expected:void 0,actual:void 0,diff:void 0};v[m]=h,f.set(y,v),o.delete(h)}else h.contentType.startsWith("image/")&&(c.add(h),o.delete(h))}return{diffMap:f,attachments:o,screenshots:c}},[e]);return!i.size&&!s.size&&!a.size?w.jsx(vs,{text:"No attachments"}):w.jsxs("div",{className:"attachments-tab",children:[[...i.values()].map(({expected:o,actual:c,diff:f})=>w.jsxs(w.Fragment,{children:[o&&c&&w.jsx("div",{className:"attachments-section",children:"Image diff"}),o&&c&&w.jsx(PE,{noTargetBlank:!0,diff:{name:"Image diff",expected:{attachment:{...o,path:tc(e,o)},title:"Expected"},actual:{attachment:{...c,path:tc(e,c)}},diff:f?{attachment:{...f,path:tc(e,f)}}:void 0}})]})),s.size?w.jsx("div",{className:"attachments-section",children:"Screenshots"}):void 0,[...s.values()].map((o,c)=>{const f=kc(e,o);return w.jsxs("div",{className:"attachment-item",children:[w.jsx("div",{children:w.jsx("img",{draggable:"false",src:f})}),w.jsx("div",{children:w.jsx("a",{target:"_blank",href:f,rel:"noreferrer",children:o.name})})]},`screenshot-${c}`)}),a.size?w.jsx("div",{className:"attachments-section",children:"Attachments"}):void 0,[...a.values()].map((o,c)=>w.jsx("div",{className:"attachment-item",children:w.jsx(uT,{attachment:o,reveal:n&&o.callId===n.callId?n:void 0})},hT(o,c)))]})};function kc(n,e){return n&&e.sha1?n.createRelativeUrl(`sha1/${e.sha1}`):`file?path=${encodeURIComponent(e.path)}`}function tc(n,e){let i=e.contentType?`&dn=${encodeURIComponent(e.name)}`:"";return e.contentType&&(i+=`&dct=${encodeURIComponent(e.contentType)}`),kc(n,e)+i}function hT(n,e){return e+"-"+(n.sha1?"sha1-"+n.sha1:"path-"+n.path)}const dT=`
|
|
61
|
+
# Instructions
|
|
62
|
+
|
|
63
|
+
- Following Playwright test failed.
|
|
64
|
+
- Explain why, be concise, respect Playwright best practices.
|
|
65
|
+
- Provide a snippet of code with the fix, if possible.
|
|
66
|
+
`.trimStart();async function pT({testInfo:n,metadata:e,errorContext:i,errors:s,buildCodeFrame:a,stdout:o,stderr:c}){var m;const f=new Set(s.filter(v=>v.message&&!v.message.includes(`
|
|
67
|
+
`)).map(v=>v.message));for(const v of s)for(const S of f.keys())(m=v.message)!=null&&m.includes(S)&&f.delete(S);const h=s.filter(v=>!(!v.message||!v.message.includes(`
|
|
68
|
+
`)&&!f.has(v.message)));if(!h.length)return;const p=[dT,"# Test info","",n];o&&p.push("","# Stdout","","```",nc(o),"```"),c&&p.push("","# Stderr","","```",nc(c),"```"),p.push("","# Error details");for(const v of h)p.push("","```",nc(v.message||""),"```");i&&p.push(i);const y=await a(h[h.length-1]);return y&&p.push("","# Test source","","```ts",y,"```"),e!=null&&e.gitDiff&&p.push("","# Local changes","","```diff",e.gitDiff,"```"),p.join(`
|
|
69
|
+
`)}const gT=new RegExp("([\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)|(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~])))","g");function nc(n){return n.replace(gT,"")}const mT=Nc,yT=({stack:n,setSelectedFrame:e,selectedFrame:i})=>{const s=n||[];return w.jsx(mT,{name:"stack-trace",ariaLabel:"Stack trace",items:s,selectedItem:s[i],render:a=>{const o=a.file[1]===":"?"\\":"/";return w.jsxs(w.Fragment,{children:[w.jsx("span",{className:"stack-trace-frame-function",children:a.function||"(anonymous)"}),w.jsx("span",{className:"stack-trace-frame-location",children:a.file.split(o).pop()}),w.jsx("span",{className:"stack-trace-frame-line",children:":"+a.line})]})},onSelected:a=>e(s.indexOf(a))})},xd=({noShadow:n,children:e,noMinHeight:i,className:s,sidebarBackground:a,onClick:o})=>w.jsx("div",{className:Qe("toolbar",n&&"no-shadow",i&&"no-min-height",s,a&&"toolbar-sidebar-background"),onClick:o,children:e});function bT(n,e,i,s,a){const o=si();return cc(async()=>{var S,T,x,E;const c=n==null?void 0:n[e],f=c!=null&&c.file?c:a;if(!f)return{source:{file:"",errors:[],content:void 0},targetLine:0,highlight:[]};const h=f.file;let p=i.get(h);p||(p={errors:((S=a==null?void 0:a.source)==null?void 0:S.errors)||[],content:(T=a==null?void 0:a.source)==null?void 0:T.content},i.set(h,p));const y=(f==null?void 0:f.line)||((x=p.errors[0])==null?void 0:x.line)||0,m=s&&h.startsWith(s)?h.substring(s.length+1):h,v=p.errors.map(A=>({type:"error",line:A.line,message:A.message}));if(v.push({line:y,type:"running"}),((E=a==null?void 0:a.source)==null?void 0:E.content)!==void 0)p.content=a.source.content;else if(p.content===void 0||f===a){const A=await ov(h);try{let N=o?await fetch(o.createRelativeUrl(`sha1/src@${A}.txt`)):void 0;(!N||N.status===404)&&(N=await fetch(`file?path=${encodeURIComponent(h)}`)),N.status>=400?p.content="":p.content=await N.text()}catch{p.content=`<Unable to read "${h}">`}}return{model:o,source:p,highlight:v,targetLine:y,fileName:m,location:f}},[n,e,s,a],{source:{errors:[],content:"Loading…"},highlight:[]})}const vT=({stack:n,sources:e,rootDir:i,fallbackLocation:s,stackFrameLocation:a,onOpenExternally:o})=>{const[c,f]=U.useState(),[h,p]=U.useState(0);U.useEffect(()=>{c!==n&&(f(n),p(0))},[n,c,f,p]);const{source:y,highlight:m,targetLine:v,fileName:S,location:T}=bT(n,h,e,i,s),x=U.useCallback(()=>{T&&(o?o(T):window.location.href=`vscode://file//${T.file}:${T.line}`)},[o,T]),E=((n==null?void 0:n.length)??0)>1,A=ST(S),N=A.endsWith(".md")?"markdown":"javascript";return w.jsx(fc,{sidebarSize:200,orientation:a==="bottom"?"vertical":"horizontal",sidebarHidden:!E,main:w.jsxs("div",{className:"vbox","data-testid":"source-code",children:[S&&w.jsxs(xd,{children:[w.jsx("div",{className:"source-tab-file-name",title:S,children:w.jsx("div",{children:A})}),w.jsx(wd,{description:"Copy filename",value:A}),T&&w.jsx(It,{icon:"link-external",title:"Open in VS Code",onClick:x})]}),w.jsx(Cr,{text:y.content||"",highlighter:N,highlight:m,revealLine:v,readOnly:!0,lineNumbers:!0,dataTestId:"source-code-mirror"})]}),sidebar:w.jsx(yT,{stack:n,selectedFrame:h,setSelectedFrame:p})})};async function ov(n){const e=new TextEncoder().encode(n),i=await crypto.subtle.digest("SHA-1",e),s=[],a=new DataView(i);for(let o=0;o<a.byteLength;o+=1){const c=a.getUint8(o).toString(16).padStart(2,"0");s.push(c)}return s.join("")}function ST(n){if(!n)return"";const e=n!=null&&n.includes("/")?"/":"\\";return(n==null?void 0:n.split(e).pop())??""}const wT=({prompt:n})=>w.jsx(ec,{value:n,description:"Copy prompt",copiedDescription:w.jsxs(w.Fragment,{children:["Copied ",w.jsx("span",{className:"codicon codicon-copy",style:{marginLeft:"5px"}})]}),style:{width:"120px",justifyContent:"center"}});function xT(n){return U.useMemo(()=>{if(!n)return{errors:new Map};const e=new Map;for(const i of n.errorDescriptors)e.set(i.message,i);return{errors:e}},[n])}function ET({message:n,error:e,sdkLanguage:i,revealInSource:s}){var f;let a,o;const c=(f=e.stack)==null?void 0:f[0];return c&&(a=c.file.replace(/.*[/\\](.*)/,"$1")+":"+c.line,o=c.file+":"+c.line),w.jsxs("div",{style:{display:"flex",flexDirection:"column",overflowX:"clip"},children:[w.jsxs("div",{className:"hbox",style:{alignItems:"center",padding:"5px 10px",minHeight:36,fontWeight:"bold",color:"var(--vscode-errorForeground)",flex:0},children:[e.action&&vd(e.action,{sdkLanguage:i}),a&&w.jsxs("div",{className:"action-location",children:["@ ",w.jsx("span",{title:o,onClick:()=>s(e),children:a})]})]}),w.jsx(YE,{error:n})]})}const TT=({errorsModel:n,sdkLanguage:e,revealInSource:i,wallTime:s,testRunMetadata:a})=>{const o=si(),c=cc(async()=>{const p=o==null?void 0:o.attachments.find(y=>y.name==="error-context");if(p)return await fetch(kc(o,p)).then(y=>y.text())},[o],void 0),f=U.useCallback(async p=>{var S;const y=(S=p.stack)==null?void 0:S[0];if(!y)return;let m=o?await fetch(o.createRelativeUrl(`sha1/src@${await ov(y.file)}.txt`)):void 0;if((!m||m.status===404)&&(m=await fetch(`file?path=${encodeURIComponent(y.file)}`)),m.status>=400)return;const v=await m.text();return _T({source:v,message:nc(p.message).split(`
|
|
70
|
+
`)[0]||void 0,location:y,linesAbove:100,linesBelow:100})},[o]),h=cc(()=>pT({testInfo:(o==null?void 0:o.title)??"",metadata:a,errorContext:c,errors:(o==null?void 0:o.errorDescriptors)??[],buildCodeFrame:f}),[c,a,o,f],void 0);return n.errors.size?w.jsxs("div",{className:"fill",style:{overflow:"auto"},children:[w.jsx("span",{style:{position:"absolute",right:"5px",top:"5px",zIndex:1},children:h&&w.jsx(wT,{prompt:h})}),[...n.errors.entries()].map(([p,y])=>{const m=`error-${s}-${p}`;return w.jsx(ET,{message:p,error:y,revealInSource:i,sdkLanguage:e},m)})]}):w.jsx(vs,{text:"No errors"})};function _T({source:n,message:e,location:i,linesAbove:s,linesBelow:a}){const o=n.split(`
|
|
71
|
+
`).slice(),c=Math.max(0,i.line-s-1),f=Math.min(o.length,i.line+a),h=o.slice(c,f),p=String(f).length,y=h.map((m,v)=>`${c+v+1===i.line?"> ":" "}${(c+v+1).toString().padEnd(p," ")} | ${m}`);return e&&y.splice(i.line-c,0,`${" ".repeat(p+2)} | ${" ".repeat(i.column-2)} ^ ${e}`),y.join(`
|
|
72
|
+
`)}const AT=Nc;function CT(n,e){const{entries:i}=U.useMemo(()=>{if(!n)return{entries:[]};const a=[];function o(f){var y,m,v,S,T,x;const h=a[a.length-1];h&&((y=f.browserMessage)==null?void 0:y.bodyString)===((m=h.browserMessage)==null?void 0:m.bodyString)&&((v=f.browserMessage)==null?void 0:v.location)===((S=h.browserMessage)==null?void 0:S.location)&&f.browserError===h.browserError&&((T=f.nodeMessage)==null?void 0:T.html)===((x=h.nodeMessage)==null?void 0:x.html)&&f.isError===h.isError&&f.isWarning===h.isWarning&&f.timestamp-h.timestamp<1e3?h.repeat++:a.push({...f,repeat:1})}const c=[...n.events,...n.stdio].sort((f,h)=>{const p="time"in f?f.time:f.timestamp,y="time"in h?h.time:h.timestamp;return p-y});for(const f of c){if(f.type==="console"){const h=f.args&&f.args.length?kT(f.args):cv(f.text),p=f.location.url,m=`${p?p.substring(p.lastIndexOf("/")+1):"<anonymous>"}:${f.location.lineNumber}`;o({browserMessage:{body:h,bodyString:f.text,location:m},isError:f.messageType==="error",isWarning:f.messageType==="warning",timestamp:f.time})}if(f.type==="event"&&f.method==="pageError"&&o({browserError:f.params.error,isError:!0,isWarning:!1,timestamp:f.time}),f.type==="stderr"||f.type==="stdout"){let h="";f.text&&(h=cl(f.text.trim())||""),f.base64&&(h=cl(atob(f.base64).trim())||""),o({nodeMessage:{html:h},isError:f.type==="stderr",isWarning:!1,timestamp:f.timestamp})}}return{entries:a}},[n]);return{entries:U.useMemo(()=>e?i.filter(a=>a.timestamp>=e.minimum&&a.timestamp<=e.maximum):i,[i,e])}}const NT=({consoleModel:n,boundaries:e,onEntryHovered:i,onAccepted:s})=>n.entries.length?w.jsx("div",{className:"console-tab",children:w.jsx(AT,{name:"console",onAccepted:s,onHighlighted:a=>i==null?void 0:i(a?n.entries.indexOf(a):void 0),items:n.entries,isError:a=>a.isError,isWarning:a=>a.isWarning,render:a=>{const o=mt(a.timestamp-e.minimum),c=w.jsx("span",{className:"console-time",children:o}),f=a.isError?"status-error":a.isWarning?"status-warning":"status-none",h=a.browserMessage||a.browserError?w.jsx("span",{className:Qe("codicon","codicon-browser",f),title:"Browser message"}):w.jsx("span",{className:Qe("codicon","codicon-file",f),title:"Runner message"});let p,y,m,v;const{browserMessage:S,browserError:T,nodeMessage:x}=a;if(S&&(p=S.location,y=S.body),T){const{error:E,value:A}=T;E?(y=E.message,v=E.stack):y=String(A)}return x&&(m=x.html),w.jsxs("div",{className:"console-line",children:[c,h,p&&w.jsx("span",{className:"console-location",children:p}),a.repeat>1&&w.jsx("span",{className:"console-repeat",children:a.repeat}),y&&w.jsx("span",{className:"console-line-message",children:y}),m&&w.jsx("span",{className:"console-line-message",dangerouslySetInnerHTML:{__html:m}}),v&&w.jsx("div",{className:"console-stack",children:v})]})}})}):w.jsx(vs,{text:"No console entries"});function kT(n){if(n.length===1)return cv(n[0].preview);const e=typeof n[0].value=="string"&&n[0].value.includes("%"),i=e?n[0].value:"",s=e?n.slice(1):n;let a=0;const o=/%([%sdifoOc])/g;let c;const f=[];let h=[];f.push(w.jsx("span",{children:h},f.length+1));let p=0;for(;(c=o.exec(i))!==null;){const y=i.substring(p,c.index);h.push(w.jsx("span",{children:y},h.length+1)),p=c.index+2;const m=c[0][1];if(m==="%")h.push(w.jsx("span",{children:"%"},h.length+1));else if(m==="s"||m==="o"||m==="O"||m==="d"||m==="i"||m==="f"){const v=s[a++],S={};typeof(v==null?void 0:v.value)!="string"&&(S.color="var(--vscode-debugTokenExpression-number)"),h.push(w.jsx("span",{style:S,children:(v==null?void 0:v.preview)||""},h.length+1))}else if(m==="c"){h=[];const v=s[a++],S=v?MT(v.preview):{};f.push(w.jsx("span",{style:S,children:h},f.length+1))}}for(p<i.length&&h.push(w.jsx("span",{children:i.substring(p)},h.length+1));a<s.length;a++){const y=s[a],m={};h.length&&h.push(w.jsx("span",{children:" "},h.length+1)),typeof(y==null?void 0:y.value)!="string"&&(m.color="var(--vscode-debugTokenExpression-number)"),h.push(w.jsx("span",{style:m,children:(y==null?void 0:y.preview)||""},h.length+1))}return f}function cv(n){return[w.jsx("span",{dangerouslySetInnerHTML:{__html:cl(n.trim())}})]}function MT(n){try{const e={},i=n.split(";");for(const s of i){const a=s.trim();if(!a)continue;let[o,c]=a.split(":");if(o=o.trim(),c=c.trim(),!OT(o))continue;const f=o.replace(/-([a-z])/g,h=>h[1].toUpperCase());e[f]=c}return e}catch{return{}}}function OT(n){return["background","border","color","font","line","margin","padding","text"].some(i=>n.startsWith(i))}const Xh=({tabs:n,selectedTab:e,setSelectedTab:i,leftToolbar:s,rightToolbar:a,dataTestId:o,mode:c})=>{const f=U.useId();return e||(e=n[0].id),c||(c="default"),w.jsx("div",{className:"tabbed-pane","data-testid":o,children:w.jsxs("div",{className:"vbox",children:[w.jsxs(xd,{children:[s&&w.jsxs("div",{style:{flex:"none",display:"flex",margin:"0 4px",alignItems:"center"},children:[...s]}),c==="default"&&w.jsx("div",{style:{flex:"auto",display:"flex",height:"100%",overflow:"hidden"},role:"tablist",children:[...n.map(h=>w.jsx(uv,{id:h.id,ariaControls:`${f}-${h.id}`,title:h.title,count:h.count,errorCount:h.errorCount,selected:e===h.id,onSelect:i},h.id))]}),c==="select"&&w.jsx("div",{style:{flex:"auto",display:"flex",height:"100%",overflow:"hidden"},role:"tablist",children:w.jsx("select",{style:{width:"100%",background:"none",cursor:"pointer"},value:e,onChange:h=>{i==null||i(n[h.currentTarget.selectedIndex].id)},children:n.map(h=>{let p="";return h.count&&(p=` (${h.count})`),h.errorCount&&(p=` (${h.errorCount})`),w.jsxs("option",{value:h.id,role:"tab","aria-controls":`${f}-${h.id}`,children:[h.title,p]},h.id)})})}),a&&w.jsxs("div",{style:{flex:"none",display:"flex",alignItems:"center"},children:[...a]})]}),n.map(h=>{const p="tab-content tab-"+h.id;if(h.component)return w.jsx("div",{id:`${f}-${h.id}`,role:"tabpanel","aria-label":h.title,className:p,style:{display:e===h.id?"inherit":"none"},children:h.component},h.id);if(e===h.id)return w.jsx("div",{id:`${f}-${h.id}`,role:"tabpanel","aria-label":h.title,className:p,children:h.render()},h.id)})]})})},uv=({id:n,title:e,count:i,errorCount:s,selected:a,onSelect:o,ariaControls:c})=>w.jsxs("div",{className:Qe("tabbed-pane-tab",a&&"selected"),onClick:()=>o==null?void 0:o(n),role:"tab",title:e,"aria-controls":c,"aria-selected":a,children:[w.jsx("div",{className:"tabbed-pane-tab-label",children:e}),!!i&&w.jsx("div",{className:"tabbed-pane-tab-counter",children:i}),!!s&&w.jsx("div",{className:"tabbed-pane-tab-counter error",children:s})]});async function LT(n,e){const i=navigator.platform.includes("Win")?"win":"unix";let s=[];const a=new Set(["accept-encoding","host","method","path","scheme","version","authority","protocol"]);function o(v){return'^"'+v.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/[^a-zA-Z0-9\s_\-:=+~'\/.',?;()*`]/g,"^$&").replace(/%(?=[a-zA-Z0-9_])/g,"%^").replace(/[^ -~\r\n]/g," ").replace(/\r?\n|\r/g,`^
|
|
73
|
+
|
|
74
|
+
`)+'^"'}function c(v){function S(T){let E=T.charCodeAt(0).toString(16);for(;E.length<4;)E="0"+E;return"\\u"+E}return/[\0-\x1F\x7F-\x9F!]|\'/.test(v)?"$'"+v.replace(/\\/g,"\\\\").replace(/\'/g,"\\'").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\0-\x1F\x7F-\x9F!]/g,S)+"'":"'"+v+"'"}const f=i==="win"?o:c;s.push(f(e.request.url).replace(/[[{}\]]/g,"\\$&"));let h="GET";const p=[],y=await fv(n,e);y&&(p.push("--data-raw "+f(y)),a.add("content-length"),h="POST"),e.request.method!==h&&s.push("-X "+f(e.request.method));const m=e.request.headers;for(let v=0;v<m.length;v++){const S=m[v],T=S.name.replace(/^:/,"");if(a.has(T.toLowerCase()))continue;const x=S.value;x.trim()?T.toLowerCase()==="cookie"?s.push("-b "+f(x)):s.push("-H "+f(T+": "+x)):s.push("-H "+f(T+";"))}return s=s.concat(p),"curl "+s.join(s.length>=3?i==="win"?` ^
|
|
75
|
+
`:` \\
|
|
76
|
+
`:" ")}async function jT(n,e,i=0){const s=new Set(["method","path","scheme","version","accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via","user-agent"]),a=new Set(["cookie","authorization"]),o=JSON.stringify(e.request.url),c=e.request.headers,f=c.reduce((x,E)=>{const A=E.name;return!s.has(A.toLowerCase())&&!A.includes(":")&&x.append(A,E.value),x},new Headers),h={};for(const x of f)h[x[0]]=x[1];const p=e.request.cookies.length||c.some(({name:x})=>a.has(x.toLowerCase()))?"include":"omit",y=c.find(({name:x})=>x.toLowerCase()==="referer"),m=y?y.value:void 0,v=await fv(n,e),S={headers:Object.keys(h).length?h:void 0,referrer:m,body:v,method:e.request.method,mode:"cors"};if(i===1){const x=c.find(A=>A.name.toLowerCase()==="cookie"),E={};delete S.mode,x&&(E.cookie=x.value),m&&(delete S.referrer,E.Referer=m),Object.keys(E).length&&(S.headers={...h,...E})}else S.credentials=p;const T=JSON.stringify(S,null,2);return`fetch(${o}, ${T});`}async function fv(n,e){var i,s;return n&&((i=e.request.postData)!=null&&i._sha1)?await fetch(n.createRelativeUrl(`sha1/${e.request.postData._sha1}`)).then(a=>a.text()):(s=e.request.postData)==null?void 0:s.text}class RT{generatePlaywrightRequestCall(e,i){let s=e.method.toLowerCase();const a=new URL(e.url),o=`${a.origin}${a.pathname}`,c={};["delete","get","head","post","put","patch"].includes(s)||(c.method=s,s="fetch"),a.searchParams.size&&(c.params=Object.fromEntries(a.searchParams.entries())),i&&(c.data=i),e.headers.length&&(c.headers=Object.fromEntries(e.headers.map(p=>[p.name,p.value])));const f=[`'${o}'`];return Object.keys(c).length>0&&f.push(this.prettyPrintObject(c)),`await page.request.${s}(${f.join(", ")});`}prettyPrintObject(e,i=2,s=0){if(e===null)return"null";if(e===void 0)return"undefined";if(typeof e!="object")return typeof e=="string"?this.stringLiteral(e):String(e);if(Array.isArray(e)){if(e.length===0)return"[]";const f=" ".repeat(s*i),h=" ".repeat((s+1)*i);return`[
|
|
77
|
+
${e.map(y=>`${h}${this.prettyPrintObject(y,i,s+1)}`).join(`,
|
|
78
|
+
`)}
|
|
79
|
+
${f}]`}if(Object.keys(e).length===0)return"{}";const a=" ".repeat(s*i),o=" ".repeat((s+1)*i);return`{
|
|
80
|
+
${Object.entries(e).map(([f,h])=>{const p=this.prettyPrintObject(h,i,s+1),y=/^[a-zA-Z_$][a-zA-Z0-9_$]*$/.test(f)?f:this.stringLiteral(f);return`${o}${y}: ${p}`}).join(`,
|
|
81
|
+
`)}
|
|
82
|
+
${a}}`}stringLiteral(e){return e=e.replace(/\\/g,"\\\\").replace(/'/g,"\\'"),e.includes(`
|
|
83
|
+
`)||e.includes("\r")||e.includes(" ")?"`"+e+"`":`'${e}'`}}class DT{generatePlaywrightRequestCall(e,i){const s=new URL(e.url),o=[`"${`${s.origin}${s.pathname}`}"`];let c=e.method.toLowerCase();["delete","get","head","post","put","patch"].includes(c)||(o.push(`method="${c}"`),c="fetch"),s.searchParams.size&&o.push(`params=${this.prettyPrintObject(Object.fromEntries(s.searchParams.entries()))}`),i&&o.push(`data=${this.prettyPrintObject(i)}`),e.headers.length&&o.push(`headers=${this.prettyPrintObject(Object.fromEntries(e.headers.map(h=>[h.name,h.value])))}`);const f=o.length===1?o[0]:`
|
|
84
|
+
${o.map(h=>this.indent(h,2)).join(`,
|
|
85
|
+
`)}
|
|
86
|
+
`;return`await page.request.${c}(${f})`}indent(e,i){return e.split(`
|
|
87
|
+
`).map(s=>" ".repeat(i)+s).join(`
|
|
88
|
+
`)}prettyPrintObject(e,i=2,s=0){if(e===null||e===void 0)return"None";if(typeof e!="object")return typeof e=="string"?this.stringLiteral(e):typeof e=="boolean"?e?"True":"False":String(e);if(Array.isArray(e)){if(e.length===0)return"[]";const f=" ".repeat(s*i),h=" ".repeat((s+1)*i);return`[
|
|
89
|
+
${e.map(y=>`${h}${this.prettyPrintObject(y,i,s+1)}`).join(`,
|
|
90
|
+
`)}
|
|
91
|
+
${f}]`}if(Object.keys(e).length===0)return"{}";const a=" ".repeat(s*i),o=" ".repeat((s+1)*i);return`{
|
|
92
|
+
${Object.entries(e).map(([f,h])=>{const p=this.prettyPrintObject(h,i,s+1);return`${o}${this.stringLiteral(f)}: ${p}`}).join(`,
|
|
93
|
+
`)}
|
|
94
|
+
${a}}`}stringLiteral(e){return JSON.stringify(e)}}class BT{generatePlaywrightRequestCall(e,i){const s=new URL(e.url),a=`${s.origin}${s.pathname}`,o={},c=[];let f=e.method.toLowerCase();["delete","get","head","post","put","patch"].includes(f)||(o.Method=f,f="fetch"),s.searchParams.size&&(o.Params=Object.fromEntries(s.searchParams.entries())),i&&(o.Data=i),e.headers.length&&(o.Headers=Object.fromEntries(e.headers.map(y=>[y.name,y.value])));const h=[`"${a}"`];return Object.keys(o).length>0&&h.push(this.prettyPrintObject(o)),`${c.join(`
|
|
95
|
+
`)}${c.length?`
|
|
96
|
+
`:""}await request.${this.toFunctionName(f)}(${h.join(", ")});`}toFunctionName(e){return e[0].toUpperCase()+e.slice(1)+"Async"}prettyPrintObject(e,i=2,s=0){if(e===null||e===void 0)return"null";if(typeof e!="object")return typeof e=="string"?this.stringLiteral(e):typeof e=="boolean"?e?"true":"false":String(e);if(Array.isArray(e)){if(e.length===0)return"new object[] {}";const f=" ".repeat(s*i),h=" ".repeat((s+1)*i);return`new object[] {
|
|
97
|
+
${e.map(y=>`${h}${this.prettyPrintObject(y,i,s+1)}`).join(`,
|
|
98
|
+
`)}
|
|
99
|
+
${f}}`}if(Object.keys(e).length===0)return"new {}";const a=" ".repeat(s*i),o=" ".repeat((s+1)*i);return`new() {
|
|
100
|
+
${Object.entries(e).map(([f,h])=>{const p=this.prettyPrintObject(h,i,s+1),y=s===0?f:`[${this.stringLiteral(f)}]`;return`${o}${y} = ${p}`}).join(`,
|
|
101
|
+
`)}
|
|
102
|
+
${a}}`}stringLiteral(e){return JSON.stringify(e)}}class zT{generatePlaywrightRequestCall(e,i){const s=new URL(e.url),a=[`"${s.origin}${s.pathname}"`],o=[];let c=e.method.toLowerCase();["delete","get","head","post","put","patch"].includes(c)||(o.push(`setMethod("${c}")`),c="fetch");for(const[f,h]of s.searchParams)o.push(`setQueryParam(${this.stringLiteral(f)}, ${this.stringLiteral(h)})`);i&&o.push(`setData(${this.stringLiteral(i)})`);for(const f of e.headers)o.push(`setHeader(${this.stringLiteral(f.name)}, ${this.stringLiteral(f.value)})`);return o.length>0&&a.push(`RequestOptions.create()
|
|
103
|
+
.${o.join(`
|
|
104
|
+
.`)}
|
|
105
|
+
`),`request.${c}(${a.join(", ")});`}stringLiteral(e){return JSON.stringify(e)}}function UT(n){if(n==="javascript")return new RT;if(n==="python")return new DT;if(n==="csharp")return new BT;if(n==="java")return new zT;throw new Error("Unsupported language: "+n)}const HT=({resource:n,sdkLanguage:e,startTimeOffset:i,onClose:s})=>{const[a,o]=U.useState("headers"),c=si(),f=cc(async()=>{if(c&&n.request.postData){const h=n.request.headers.find(y=>y.name.toLowerCase()==="content-type"),p=h?h.value:"";if(n.request.postData._sha1){const y=await fetch(c.createRelativeUrl(`sha1/${n.request.postData._sha1}`));return{text:Fh(await y.text(),p),mimeType:p}}else return{text:Fh(n.request.postData.text,p),mimeType:p}}else return null},[n],null);return w.jsx(Xh,{leftToolbar:[w.jsx(It,{icon:"close",title:"Close",onClick:s},"close")],rightToolbar:[w.jsx(qT,{requestBody:f,resource:n,sdkLanguage:e},"dropdown")],tabs:[{id:"headers",title:"Headers",render:()=>w.jsx(IT,{resource:n,startTimeOffset:i})},{id:"payload",title:"Payload",render:()=>w.jsx($T,{resource:n,requestBody:f})},{id:"response",title:"Response",render:()=>w.jsx(VT,{resource:n})}],selectedTab:a,setSelectedTab:o})},qT=({resource:n,sdkLanguage:e,requestBody:i})=>{const s=si(),a=w.jsxs(w.Fragment,{children:[w.jsx("span",{className:"codicon codicon-check",style:{marginRight:"5px"}})," Copied "]}),o=async()=>UT(e).generatePlaywrightRequestCall(n.request,i==null?void 0:i.text);return w.jsxs("div",{className:"copy-request-dropdown",children:[w.jsxs(It,{className:"copy-request-dropdown-toggle",children:[w.jsx("span",{className:"codicon codicon-copy",style:{marginRight:"5px"}}),"Copy request",w.jsx("span",{className:"codicon codicon-chevron-down",style:{marginLeft:"5px"}})]}),w.jsxs("div",{className:"copy-request-dropdown-menu",children:[w.jsx(ec,{description:"Copy as cURL",copiedDescription:a,value:()=>LT(s,n)}),w.jsx(ec,{description:"Copy as Fetch",copiedDescription:a,value:()=>jT(s,n)}),w.jsx(ec,{description:"Copy as Playwright",copiedDescription:a,value:o})]})]})},Wa=({title:n,data:e,showCount:i,children:s,className:a})=>{const[o,c]=fn(`trace-viewer-network-details-${n.replaceAll(" ","-")}`,!0);return w.jsxs(rv,{expanded:o,setExpanded:c,expandOnTitleClick:!0,title:w.jsxs("span",{className:"network-request-details-header",children:[n,i&&w.jsxs("span",{className:"network-request-details-header-count",children:[" × ",(e==null?void 0:e.length)??0]})]}),className:a,children:[e&&w.jsx("table",{className:"network-request-details-table",children:w.jsx("tbody",{children:e.map(({name:f,value:h},p)=>h!==null&&w.jsxs("tr",{children:[w.jsx("td",{children:f}),w.jsx("td",{children:h})]},p))})}),s]})},IT=({resource:n,startTimeOffset:e})=>{const i=U.useMemo(()=>Object.entries({URL:n.request.url,Method:n.request.method,"Status Code":n.response.status!==-1&&w.jsxs("span",{className:KT(n.response.status),children:[" ",n.response.status," ",n.response.statusText]}),Start:mt(e),Duration:mt(n.time)}).map(([s,a])=>({name:s,value:a})),[n,e]);return w.jsxs("div",{className:"vbox network-request-details-tab",children:[w.jsx(Wa,{title:"General",data:i}),w.jsx(Wa,{title:"Request Headers",showCount:!0,data:n.request.headers}),w.jsx(Wa,{title:"Response Headers",showCount:!0,data:n.response.headers})]})},$T=({resource:n,requestBody:e})=>w.jsxs("div",{className:"vbox network-request-details-tab",children:[n.request.queryString.length===0&&!e&&w.jsx("em",{className:"network-request-no-payload",children:"No payload for this request."}),n.request.queryString.length>0&&w.jsx(Wa,{title:"Query String Parameters",showCount:!0,data:n.request.queryString}),e&&w.jsx(Wa,{title:"Request Body",className:"network-request-request-body",children:w.jsx(Cr,{text:e.text,mimeType:e.mimeType,readOnly:!0,lineNumbers:!0})})]}),VT=({resource:n})=>{const e=si(),[i,s]=U.useState(null);return U.useEffect(()=>{(async()=>{if(e&&n.response.content._sha1){const o=n.response.content.mimeType.includes("image"),c=n.response.content.mimeType.includes("font"),f=await fetch(e.createRelativeUrl(`sha1/${n.response.content._sha1}`));if(o){const h=await f.blob(),p=new FileReader,y=new Promise(m=>p.onload=m);p.readAsDataURL(h),s({dataUrl:(await y).target.result})}else if(c){const h=await f.arrayBuffer();s({font:h})}else{const h=Fh(await f.text(),n.response.content.mimeType);s({text:h,mimeType:n.response.content.mimeType})}}else s(null)})()},[n,e]),w.jsxs("div",{className:"vbox network-request-details-tab",children:[!n.response.content._sha1&&w.jsx("div",{children:"Response body is not available for this request."}),i&&i.font&&w.jsx(GT,{font:i.font}),i&&i.dataUrl&&w.jsx("div",{children:w.jsx("img",{draggable:"false",src:i.dataUrl})}),i&&i.text&&w.jsx(Cr,{text:i.text,mimeType:i.mimeType,readOnly:!0,lineNumbers:!0})]})},GT=({font:n})=>{const[e,i]=U.useState(!1);return U.useEffect(()=>{let s;try{s=new FontFace("font-preview",n),s.status==="loaded"&&document.fonts.add(s),s.status==="error"&&i(!0)}catch{i(!0)}return()=>{document.fonts.delete(s)}},[n]),e?w.jsx("div",{className:"network-font-preview-error",children:"Could not load font preview"}):w.jsxs("div",{className:"network-font-preview",children:["ABCDEFGHIJKLM",w.jsx("br",{}),"NOPQRSTUVWXYZ",w.jsx("br",{}),"abcdefghijklm",w.jsx("br",{}),"nopqrstuvwxyz",w.jsx("br",{}),"1234567890"]})};function KT(n){return n<300||n===304?"green-circle":n<400?"yellow-circle":"red-circle"}const XT=/<[^>]+>[^<]*<\//;function FT(n,e=" "){let i=0;const s=[],a=n.replace(/>\s*</g,`>
|
|
106
|
+
<`).split(`
|
|
107
|
+
`);for(const o of a){const c=o.trim();c&&(c.startsWith("</")?(i=Math.max(i-1,0),s.push(e.repeat(i)+c)):c.endsWith("/>")||c.startsWith("<?")||XT.test(c)?s.push(e.repeat(i)+c):c.startsWith("<")?(s.push(e.repeat(i)+c),i++):s.push(e.repeat(i)+c))}return s.join(`
|
|
108
|
+
`)}function Fh(n,e){if(n===null)return"Loading...";const i=n;if(i==="")return"<Empty>";if(aT(e))try{return JSON.stringify(JSON.parse(i),null,2)}catch{return i}if(lT(e))try{return FT(i)}catch{return i}return e.includes("application/x-www-form-urlencoded")?decodeURIComponent(i):i}function YT(n){const[e,i]=U.useState([]);U.useEffect(()=>{const o=[];for(let c=0;c<n.columns.length-1;++c){const f=n.columns[c];o[c]=(o[c-1]||0)+n.columnWidths.get(f)}i(o)},[n.columns,n.columnWidths]);function s(o){const c=new Map(n.columnWidths.entries());for(let f=0;f<o.length;++f){const h=o[f]-(o[f-1]||0),p=n.columns[f];c.set(p,h)}n.setColumnWidths(c)}const a=U.useCallback(o=>{var c,f;(f=n.setSorting)==null||f.call(n,{by:o,negate:((c=n.sorting)==null?void 0:c.by)===o?!n.sorting.negate:!1})},[n]);return w.jsxs("div",{className:`grid-view ${n.name}-grid-view`,children:[w.jsx(sv,{orientation:"horizontal",offsets:e,setOffsets:s,resizerColor:"var(--vscode-panel-border)",resizerWidth:1,minColumnWidth:25}),w.jsxs("div",{className:"vbox",children:[w.jsx("div",{className:"grid-view-header",children:n.columns.map((o,c)=>w.jsxs("div",{className:"grid-view-header-cell "+QT(o,n.sorting),style:{width:c<n.columns.length-1?n.columnWidths.get(o):void 0},onClick:()=>n.setSorting&&a(o),children:[w.jsx("span",{className:"grid-view-header-cell-title",children:n.columnTitle(o)}),w.jsx("span",{className:"codicon codicon-triangle-up"}),w.jsx("span",{className:"codicon codicon-triangle-down"})]},n.columnTitle(o)))}),w.jsx(Nc,{name:n.name,items:n.items,ariaLabel:n.ariaLabel,id:n.id,render:(o,c)=>w.jsx(w.Fragment,{children:n.columns.map((f,h)=>{const{body:p,title:y}=n.render(o,f,c);return w.jsx("div",{className:`grid-view-cell grid-view-column-${String(f)}`,title:y,style:{width:h<n.columns.length-1?n.columnWidths.get(f):void 0},children:p},n.columnTitle(f))})}),icon:n.icon,isError:n.isError,isWarning:n.isWarning,isInfo:n.isInfo,selectedItem:n.selectedItem,onAccepted:n.onAccepted,onSelected:n.onSelected,onHighlighted:n.onHighlighted,onIconClicked:n.onIconClicked,noItemsMessage:n.noItemsMessage,dataTestId:n.dataTestId,notSelectable:n.notSelectable})]})]})}function QT(n,e){return n===(e==null?void 0:e.by)?" filter-"+(e.negate?"negative":"positive"):""}const PT=["Fetch","HTML","JS","CSS","Font","Image"],JT={searchValue:"",resourceTypes:new Set},ZT=({filterState:n,onFilterStateChange:e})=>w.jsxs("div",{className:"network-filters",children:[w.jsx("input",{type:"search",placeholder:"Filter network",spellCheck:!1,value:n.searchValue,onChange:i=>e({...n,searchValue:i.target.value})}),w.jsxs("div",{className:"network-filters-resource-types",role:"tablist","aria-multiselectable":"true",children:[w.jsx("div",{title:"All",onClick:()=>e({...n,resourceTypes:new Set}),className:`network-filters-resource-type ${n.resourceTypes.size===0?"selected":""}`,children:"All"}),PT.map(i=>w.jsx("div",{title:i,onClick:s=>{let a;s.ctrlKey||s.metaKey?a=n.resourceTypes.symmetricDifference(new Set([i])):a=new Set([i]),e({...n,resourceTypes:a})},className:`network-filters-resource-type ${n.resourceTypes.has(i)?"selected":""}`,role:"tab","aria-selected":n.resourceTypes.has(i),children:i},i))]})]}),WT=YT;function e_(n,e){const i=U.useMemo(()=>((n==null?void 0:n.resources)||[]).filter(c=>e?!!c._monotonicTime&&c._monotonicTime>=e.minimum&&c._monotonicTime<=e.maximum:!0),[n,e]),s=U.useMemo(()=>new a_(n),[n]);return{resources:i,contextIdMap:s}}const t_=({boundaries:n,networkModel:e,onResourceHovered:i,sdkLanguage:s})=>{const[a,o]=U.useState(void 0),[c,f]=U.useState(void 0),[h,p]=U.useState(JT),{renderedEntries:y}=U.useMemo(()=>{const E=e.resources.map(A=>l_(A,n,e.contextIdMap)).filter(h_(h));return a&&c_(E,a),{renderedEntries:E}},[e.resources,e.contextIdMap,h,a,n]),m=U.useMemo(()=>c?y.find(E=>E.resource.id===c):void 0,[c,y]),[v,S]=U.useState(()=>new Map(hv().map(E=>[E,i_(E)]))),T=U.useCallback(E=>{p(E),f(void 0)},[]);if(!e.resources.length)return w.jsx(vs,{text:"No network calls"});const x=w.jsx(WT,{name:"network",ariaLabel:"Network requests",items:y,selectedItem:m,onSelected:E=>f(E.resource.id),onHighlighted:E=>i==null?void 0:i(E==null?void 0:E.resource.id),columns:s_(!!m,y),columnTitle:n_,columnWidths:v,setColumnWidths:S,isError:E=>E.status.code>=400||E.status.code===-1,isInfo:E=>!!E.route,render:(E,A)=>r_(E,A),sorting:a,setSorting:o});return w.jsxs(w.Fragment,{children:[w.jsx(ZT,{filterState:h,onFilterStateChange:T}),!m&&x,m&&w.jsx(fc,{sidebarSize:v.get("name"),sidebarIsFirst:!0,orientation:"horizontal",settingName:"networkResourceDetails",main:w.jsx(HT,{resource:m.resource,sdkLanguage:s,startTimeOffset:m.start,onClose:()=>f(void 0)}),sidebar:x})]})},n_=n=>n==="contextId"?"Source":n==="name"?"Name":n==="method"?"Method":n==="status"?"Status":n==="contentType"?"Content Type":n==="duration"?"Duration":n==="size"?"Size":n==="start"?"Start":n==="route"?"Route":"",i_=n=>n==="name"?200:n==="method"||n==="status"?60:n==="contentType"?200:n==="contextId"?60:100;function s_(n,e){if(n){const s=["name"];return jb(e)&&s.unshift("contextId"),s}let i=hv();return jb(e)||(i=i.filter(s=>s!=="contextId")),i}function hv(){return["contextId","name","method","status","contentType","duration","size","start","route"]}const r_=(n,e)=>e==="contextId"?{body:n.contextId,title:n.name.url}:e==="name"?{body:n.name.name,title:n.name.url}:e==="method"?{body:n.method}:e==="status"?{body:n.status.code>0?n.status.code:"",title:n.status.text}:e==="contentType"?{body:n.contentType}:e==="duration"?{body:mt(n.duration)}:e==="size"?{body:jx(n.size)}:e==="start"?{body:mt(n.start)}:e==="route"?{body:n.route}:{body:""};class a_{constructor(e){this._pagerefToShortId=new Map,this._contextToId=new Map,this._lastPageId=0,this._lastApiRequestContextId=0}contextId(e){return e.pageref?this._pageId(e.pageref):e._apiRequest?this._apiRequestContextId(e):""}_pageId(e){let i=this._pagerefToShortId.get(e);return i||(++this._lastPageId,i="page#"+this._lastPageId,this._pagerefToShortId.set(e,i)),i}_apiRequestContextId(e){const i=M0(e);if(!i)return"";let s=this._contextToId.get(i);return s||(++this._lastApiRequestContextId,s="api#"+this._lastApiRequestContextId,this._contextToId.set(i,s)),s}}function jb(n){const e=new Set;for(const i of n)if(e.add(i.contextId),e.size>1)return!0;return!1}const l_=(n,e,i)=>{const s=o_(n);let a;try{const f=new URL(n.request.url);a=f.pathname.substring(f.pathname.lastIndexOf("/")+1),a||(a=f.host),f.search&&(a+=f.search)}catch{a=n.request.url}let o=n.response.content.mimeType;const c=o.match(/^(.*);\s*charset=.*$/);return c&&(o=c[1]),{name:{name:a,url:n.request.url},method:n.request.method,status:{code:n.response.status,text:n.response.statusText},contentType:o,duration:n.time,size:n.response._transferSize>0?n.response._transferSize:n.response.bodySize,start:n._monotonicTime-e.minimum,route:s,resource:n,contextId:i.contextId(n)}};function o_(n){return n._wasAborted?"aborted":n._wasContinued?"continued":n._wasFulfilled?"fulfilled":n._apiRequest?"api":""}function c_(n,e){const i=u_(e==null?void 0:e.by);i&&n.sort(i),e.negate&&n.reverse()}function u_(n){if(n==="start")return(e,i)=>e.start-i.start;if(n==="duration")return(e,i)=>e.duration-i.duration;if(n==="status")return(e,i)=>e.status.code-i.status.code;if(n==="method")return(e,i)=>{const s=e.method,a=i.method;return s.localeCompare(a)};if(n==="size")return(e,i)=>e.size-i.size;if(n==="contentType")return(e,i)=>e.contentType.localeCompare(i.contentType);if(n==="name")return(e,i)=>e.name.name.localeCompare(i.name.name);if(n==="route")return(e,i)=>e.route.localeCompare(i.route);if(n==="contextId")return(e,i)=>e.contextId.localeCompare(i.contextId)}const f_={Fetch:n=>n==="application/json",HTML:n=>n==="text/html",CSS:n=>n==="text/css",JS:n=>n.includes("javascript"),Font:n=>n.includes("font"),Image:n=>n.includes("image")};function h_({searchValue:n,resourceTypes:e}){return i=>(e.size===0||Array.from(e).some(a=>f_[a](i.contentType)))&&i.name.url.toLowerCase().includes(n.toLowerCase())}function d_(n,e){if(n.role!==e.role||n.name!==e.name||!p_(n,e)||mc(n)!==mc(e))return!1;const i=Object.keys(n.props),s=Object.keys(e.props);return i.length===s.length&&i.every(a=>n.props[a]===e.props[a])}function mc(n){return n.box.cursor==="pointer"}function p_(n,e){return n.active===e.active&&n.checked===e.checked&&n.disabled===e.disabled&&n.expanded===e.expanded&&n.selected===e.selected&&n.level===e.level&&n.pressed===e.pressed}function Ed(n,e,i={}){var v;const s=new n.LineCounter,a={keepSourceTokens:!0,lineCounter:s,...i},o=n.parseDocument(e,a),c=[],f=S=>[s.linePos(S[0]),s.linePos(S[1])],h=S=>{c.push({message:S.message,range:[s.linePos(S.pos[0]),s.linePos(S.pos[1])]})},p=(S,T)=>{for(const x of T.items){if(x instanceof n.Scalar&&typeof x.value=="string"){const N=yc.parse(x,a,c);N&&(S.children=S.children||[],S.children.push(N));continue}if(x instanceof n.YAMLMap){y(S,x);continue}c.push({message:"Sequence items should be strings or maps",range:f(x.range||T.range)})}},y=(S,T)=>{for(const x of T.items){if(S.children=S.children||[],!(x.key instanceof n.Scalar&&typeof x.key.value=="string")){c.push({message:"Only string keys are supported",range:f(x.key.range||T.range)});continue}const A=x.key,N=x.value;if(A.value==="text"){if(!(N instanceof n.Scalar&&typeof N.value=="string")){c.push({message:"Text value should be a string",range:f(x.value.range||T.range)});continue}S.children.push({kind:"text",text:Sh(N.value)});continue}if(A.value==="/children"){if(!(N instanceof n.Scalar&&typeof N.value=="string")||N.value!=="contain"&&N.value!=="equal"&&N.value!=="deep-equal"){c.push({message:'Strict value should be "contain", "equal" or "deep-equal"',range:f(x.value.range||T.range)});continue}S.containerMode=N.value;continue}if(A.value.startsWith("/")){if(!(N instanceof n.Scalar&&typeof N.value=="string")){c.push({message:"Property value should be a string",range:f(x.value.range||T.range)});continue}S.props=S.props??{},S.props[A.value.slice(1)]=Sh(N.value);continue}const B=yc.parse(A,a,c);if(!B)continue;if(N instanceof n.Scalar){const z=typeof N.value;if(z!=="string"&&z!=="number"&&z!=="boolean"){c.push({message:"Node value should be a string or a sequence",range:f(x.value.range||T.range)});continue}S.children.push({...B,children:[{kind:"text",text:Sh(String(N.value))}]});continue}if(N instanceof n.YAMLSeq){S.children.push(B),p(B,N);continue}c.push({message:"Map values should be strings or sequences",range:f(x.value.range||T.range)})}},m={kind:"role",role:"fragment"};return o.errors.forEach(h),c.length?{errors:c,fragment:m}:(o.contents instanceof n.YAMLSeq||c.push({message:'Aria snapshot must be a YAML sequence, elements starting with " -"',range:o.contents?f(o.contents.range):[{line:0,col:0},{line:0,col:0}]}),c.length?{errors:c,fragment:m}:(p(m,o.contents),c.length?{errors:c,fragment:g_}:((v=m.children)==null?void 0:v.length)===1&&(!m.containerMode||m.containerMode==="contain")?{fragment:m.children[0],errors:[]}:{fragment:m,errors:[]}))}const g_={kind:"role",role:"fragment"};function dv(n){return n.replace(/[\u200b\u00ad]/g,"").replace(/[\r\n\s\t]+/g," ").trim()}function Sh(n){return{raw:n,normalized:dv(n)}}class yc{static parse(e,i,s){try{return new yc(e.value)._parse()}catch(a){if(a instanceof Rb){const o=i.prettyErrors===!1?a.message:a.message+`:
|
|
109
|
+
|
|
110
|
+
`+e.value+`
|
|
111
|
+
`+" ".repeat(a.pos)+`^
|
|
112
|
+
`;return s.push({message:o,range:[i.lineCounter.linePos(e.range[0]),i.lineCounter.linePos(e.range[0]+a.pos)]}),null}throw a}}constructor(e){this._input=e,this._pos=0,this._length=e.length}_peek(){return this._input[this._pos]||""}_next(){return this._pos<this._length?this._input[this._pos++]:null}_eof(){return this._pos>=this._length}_isWhitespace(){return!this._eof()&&/\s/.test(this._peek())}_skipWhitespace(){for(;this._isWhitespace();)this._pos++}_readIdentifier(e){this._eof()&&this._throwError(`Unexpected end of input when expecting ${e}`);const i=this._pos;for(;!this._eof()&&/[a-zA-Z]/.test(this._peek());)this._pos++;return this._input.slice(i,this._pos)}_readString(){let e="",i=!1;for(;!this._eof();){const s=this._next();if(i)e+=s,i=!1;else if(s==="\\")i=!0;else{if(s==='"')return e;e+=s}}this._throwError("Unterminated string")}_throwError(e,i=0){throw new Rb(e,i||this._pos)}_readRegex(){let e="",i=!1,s=!1;for(;!this._eof();){const a=this._next();if(i)e+=a,i=!1;else if(a==="\\")i=!0,e+=a;else{if(a==="/"&&!s)return{pattern:e};a==="["?(s=!0,e+=a):a==="]"&&s?(e+=a,s=!1):e+=a}}this._throwError("Unterminated regex")}_readStringOrRegex(){const e=this._peek();return e==='"'?(this._next(),dv(this._readString())):e==="/"?(this._next(),this._readRegex()):null}_readAttributes(e){let i=this._pos;for(;this._skipWhitespace(),this._peek()==="[";){this._next(),this._skipWhitespace(),i=this._pos;const s=this._readIdentifier("attribute");this._skipWhitespace();let a="";if(this._peek()==="=")for(this._next(),this._skipWhitespace(),i=this._pos;this._peek()!=="]"&&!this._isWhitespace()&&!this._eof();)a+=this._next();this._skipWhitespace(),this._peek()!=="]"&&this._throwError("Expected ]"),this._next(),this._applyAttribute(e,s,a||"true",i)}}_parse(){this._skipWhitespace();const e=this._readIdentifier("role");this._skipWhitespace();const i=this._readStringOrRegex()||"",s={kind:"role",role:e,name:i};return this._readAttributes(s),this._skipWhitespace(),this._eof()||this._throwError("Unexpected input"),s}_applyAttribute(e,i,s,a){if(i==="checked"){this._assert(s==="true"||s==="false"||s==="mixed",'Value of "checked" attribute must be a boolean or "mixed"',a),e.checked=s==="true"?!0:s==="false"?!1:"mixed";return}if(i==="disabled"){this._assert(s==="true"||s==="false",'Value of "disabled" attribute must be a boolean',a),e.disabled=s==="true";return}if(i==="expanded"){this._assert(s==="true"||s==="false",'Value of "expanded" attribute must be a boolean',a),e.expanded=s==="true";return}if(i==="active"){this._assert(s==="true"||s==="false",'Value of "active" attribute must be a boolean',a),e.active=s==="true";return}if(i==="level"){this._assert(!isNaN(Number(s)),'Value of "level" attribute must be a number',a),e.level=Number(s);return}if(i==="pressed"){this._assert(s==="true"||s==="false"||s==="mixed",'Value of "pressed" attribute must be a boolean or "mixed"',a),e.pressed=s==="true"?!0:s==="false"?!1:"mixed";return}if(i==="selected"){this._assert(s==="true"||s==="false",'Value of "selected" attribute must be a boolean',a),e.selected=s==="true";return}this._assert(!1,`Unsupported attribute [${i}]`,a)}_assert(e,i,s){e||this._throwError(i||"Assertion error",s)}}class Rb extends Error{constructor(e,i){super(e),this.pos=i}}function m_(n,e){var c,f;function i(h,p,y){let m=1,v=y+m;for(const S of h.children||[])typeof S=="string"?(m++,v++):(m+=i(S,p,v),v+=m);if(!["none","presentation","fragment","iframe","generic"].includes(h.role)&&h.name){let S=p.get(h.role);S||(S=new Map,p.set(h.role,S));const T=S.get(h.name),x=m*100-y;(!T||T.sizeAndPosition<x)&&S.set(h.name,{node:h,sizeAndPosition:x})}return m}const s=new Map;n&&i(n,s,0);const a=new Map;i(e,a,0);const o=[];for(const[h,p]of a)for(const[y,m]of p)((c=s.get(h))==null?void 0:c.get(y))||o.push(m);return o.sort((h,p)=>p.sizeAndPosition-h.sizeAndPosition),(f=o[0])==null?void 0:f.node}function y_(n){return pv(n)?"'"+n.replace(/'/g,"''")+"'":n}function wh(n){return pv(n)?'"'+n.replace(/[\\"\x00-\x1f\x7f-\x9f]/g,e=>{switch(e){case"\\":return"\\\\";case'"':return'\\"';case"\b":return"\\b";case"\f":return"\\f";case`
|
|
113
|
+
`:return"\\n";case"\r":return"\\r";case" ":return"\\t";default:return"\\x"+e.charCodeAt(0).toString(16).padStart(2,"0")}})+'"':n}function pv(n){return!!(n.length===0||/^\s|\s$/.test(n)||/[\x00-\x08\x0b\x0c\x0e-\x1f\x7f-\x9f]/.test(n)||/^-/.test(n)||/[\n:](\s|$)/.test(n)||/\s#/.test(n)||/[\n\r]/.test(n)||/^[&*\],?!>|@"'#%]/.test(n)||/[{}`]/.test(n)||/^\[/.test(n)||!isNaN(Number(n))||["y","n","yes","no","true","false","on","off","null"].includes(n.toLowerCase()))}let gv={};function b_(n){gv=n}function Yh(n,e){for(;e;){if(n.contains(e))return!0;e=yv(e)}return!1}function St(n){if(n.parentElement)return n.parentElement;if(n.parentNode&&n.parentNode.nodeType===11&&n.parentNode.host)return n.parentNode.host}function mv(n){let e=n;for(;e.parentNode;)e=e.parentNode;if(e.nodeType===11||e.nodeType===9)return e}function yv(n){for(;n.parentElement;)n=n.parentElement;return St(n)}function Xa(n,e,i){for(;n;){const s=n.closest(e);if(i&&s!==i&&(s!=null&&s.contains(i)))return;if(s)return s;n=yv(n)}}function zi(n,e){const i=e==="::before"?_d:e==="::after"?Ad:Td;if(i&&i.has(n))return i.get(n);const s=n.ownerDocument&&n.ownerDocument.defaultView?n.ownerDocument.defaultView.getComputedStyle(n,e):void 0;return i==null||i.set(n,s),s}function bv(n,e){if(e=e??zi(n),!e)return!0;if(Element.prototype.checkVisibility&&gv.browserNameForWorkarounds!=="webkit"){if(!n.checkVisibility())return!1}else{const i=n.closest("details,summary");if(i!==n&&(i==null?void 0:i.nodeName)==="DETAILS"&&!i.open)return!1}return e.visibility==="visible"}function bc(n){const e=zi(n);if(!e)return{visible:!0,inline:!1};const i=e.cursor;if(e.display==="contents"){for(let a=n.firstChild;a;a=a.nextSibling){if(a.nodeType===1&&ji(a))return{visible:!0,inline:!1,cursor:i};if(a.nodeType===3&&vv(a))return{visible:!0,inline:!0,cursor:i}}return{visible:!1,inline:!1,cursor:i}}if(!bv(n,e))return{cursor:i,visible:!1,inline:!1};const s=n.getBoundingClientRect();return{cursor:i,visible:s.width>0&&s.height>0,inline:e.display==="inline"}}function ji(n){return bc(n).visible}function vv(n){const e=n.ownerDocument.createRange();e.selectNode(n);const i=e.getBoundingClientRect();return i.width>0&&i.height>0}function Ye(n){const e=n.tagName;return typeof e=="string"?e.toUpperCase():n instanceof HTMLFormElement?"FORM":n.tagName.toUpperCase()}let Td,_d,Ad,Sv=0;function Cd(){++Sv,Td??(Td=new Map),_d??(_d=new Map),Ad??(Ad=new Map)}function Nd(){--Sv||(Td=void 0,_d=void 0,Ad=void 0)}function Db(n){return n.hasAttribute("aria-label")||n.hasAttribute("aria-labelledby")}const Bb="article:not([role]), aside:not([role]), main:not([role]), nav:not([role]), section:not([role]), [role=article], [role=complementary], [role=main], [role=navigation], [role=region]",v_=[["aria-atomic",void 0],["aria-busy",void 0],["aria-controls",void 0],["aria-current",void 0],["aria-describedby",void 0],["aria-details",void 0],["aria-dropeffect",void 0],["aria-flowto",void 0],["aria-grabbed",void 0],["aria-hidden",void 0],["aria-keyshortcuts",void 0],["aria-label",["caption","code","deletion","emphasis","generic","insertion","paragraph","presentation","strong","subscript","superscript"]],["aria-labelledby",["caption","code","deletion","emphasis","generic","insertion","paragraph","presentation","strong","subscript","superscript"]],["aria-live",void 0],["aria-owns",void 0],["aria-relevant",void 0],["aria-roledescription",["generic"]]];function wv(n,e){return v_.some(([i,s])=>!(s!=null&&s.includes(e||""))&&n.hasAttribute(i))}function xv(n){return!Number.isNaN(Number(String(n.getAttribute("tabindex"))))}function S_(n){return!Rv(n)&&(w_(n)||xv(n))}function w_(n){const e=Ye(n);return["BUTTON","DETAILS","SELECT","TEXTAREA"].includes(e)?!0:e==="A"||e==="AREA"?n.hasAttribute("href"):e==="INPUT"?!n.hidden:!1}const xh={A:n=>n.hasAttribute("href")?"link":null,AREA:n=>n.hasAttribute("href")?"link":null,ARTICLE:()=>"article",ASIDE:()=>"complementary",BLOCKQUOTE:()=>"blockquote",BUTTON:()=>"button",CAPTION:()=>"caption",CODE:()=>"code",DATALIST:()=>"listbox",DD:()=>"definition",DEL:()=>"deletion",DETAILS:()=>"group",DFN:()=>"term",DIALOG:()=>"dialog",DT:()=>"term",EM:()=>"emphasis",FIELDSET:()=>"group",FIGURE:()=>"figure",FOOTER:n=>Xa(n,Bb)?null:"contentinfo",FORM:n=>Db(n)?"form":null,H1:()=>"heading",H2:()=>"heading",H3:()=>"heading",H4:()=>"heading",H5:()=>"heading",H6:()=>"heading",HEADER:n=>Xa(n,Bb)?null:"banner",HR:()=>"separator",HTML:()=>"document",IMG:n=>n.getAttribute("alt")===""&&!n.getAttribute("title")&&!wv(n)&&!xv(n)?"presentation":"img",INPUT:n=>{const e=n.type.toLowerCase();if(e==="search")return n.hasAttribute("list")?"combobox":"searchbox";if(["email","tel","text","url",""].includes(e)){const i=Rr(n,n.getAttribute("list"))[0];return i&&Ye(i)==="DATALIST"?"combobox":"textbox"}return e==="hidden"?null:e==="file"?"button":z_[e]||"textbox"},INS:()=>"insertion",LI:()=>"listitem",MAIN:()=>"main",MARK:()=>"mark",MATH:()=>"math",MENU:()=>"list",METER:()=>"meter",NAV:()=>"navigation",OL:()=>"list",OPTGROUP:()=>"group",OPTION:()=>"option",OUTPUT:()=>"status",P:()=>"paragraph",PROGRESS:()=>"progressbar",SEARCH:()=>"search",SECTION:n=>Db(n)?"region":null,SELECT:n=>n.hasAttribute("multiple")||n.size>1?"listbox":"combobox",STRONG:()=>"strong",SUB:()=>"subscript",SUP:()=>"superscript",SVG:()=>"img",TABLE:()=>"table",TBODY:()=>"rowgroup",TD:n=>{const e=Xa(n,"table"),i=e?kd(e):"";return i==="grid"||i==="treegrid"?"gridcell":"cell"},TEXTAREA:()=>"textbox",TFOOT:()=>"rowgroup",TH:n=>{const e=n.getAttribute("scope");if(e==="col"||e==="colgroup")return"columnheader";if(e==="row"||e==="rowgroup")return"rowheader";const i=n.nextElementSibling,s=n.previousElementSibling,a=n.parentElement&&Ye(n.parentElement)==="TR"?n.parentElement:void 0;if(!i&&!s){if(a){const o=Xa(a,"table");if(o&&o.rows.length<=1)return null}return"columnheader"}return zb(i)&&zb(s)?"columnheader":Ub(i)||Ub(s)?"rowheader":"columnheader"},THEAD:()=>"rowgroup",TIME:()=>"time",TR:()=>"row",UL:()=>"list"};function zb(n){return!!n&&Ye(n)==="TH"}function Ub(n){var e;return!n||Ye(n)!=="TD"?!1:!!((e=n.textContent)!=null&&e.trim()||n.children.length>0)}const x_={DD:["DL","DIV"],DIV:["DL"],DT:["DL","DIV"],LI:["OL","UL"],TBODY:["TABLE"],TD:["TR"],TFOOT:["TABLE"],TH:["TR"],THEAD:["TABLE"],TR:["THEAD","TBODY","TFOOT","TABLE"]};function Hb(n){var s;const e=((s=xh[Ye(n)])==null?void 0:s.call(xh,n))||"";if(!e)return null;let i=n;for(;i;){const a=St(i),o=x_[Ye(i)];if(!o||!a||!o.includes(Ye(a)))break;const c=kd(a);if((c==="none"||c==="presentation")&&!Ev(a,c))return c;i=a}return e}const E_=["alert","alertdialog","application","article","banner","blockquote","button","caption","cell","checkbox","code","columnheader","combobox","complementary","contentinfo","definition","deletion","dialog","directory","document","emphasis","feed","figure","form","generic","grid","gridcell","group","heading","img","insertion","link","list","listbox","listitem","log","main","mark","marquee","math","meter","menu","menubar","menuitem","menuitemcheckbox","menuitemradio","navigation","none","note","option","paragraph","presentation","progressbar","radio","radiogroup","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","strong","subscript","superscript","switch","tab","table","tablist","tabpanel","term","textbox","time","timer","toolbar","tooltip","tree","treegrid","treeitem"];function kd(n){return(n.getAttribute("role")||"").split(" ").map(i=>i.trim()).find(i=>E_.includes(i))||null}function Ev(n,e){return wv(n,e)||S_(n)}function bt(n){const e=kd(n);if(!e)return Hb(n);if(e==="none"||e==="presentation"){const i=Hb(n);if(Ev(n,i))return i}return e}function Tv(n){return n===null?void 0:n.toLowerCase()==="true"}function _v(n){return["STYLE","SCRIPT","NOSCRIPT","TEMPLATE"].includes(Ye(n))}function un(n){if(_v(n))return!0;const e=zi(n),i=n.nodeName==="SLOT";if((e==null?void 0:e.display)==="contents"&&!i){for(let a=n.firstChild;a;a=a.nextSibling)if(a.nodeType===1&&!un(a)||a.nodeType===3&&vv(a))return!1;return!0}return!(n.nodeName==="OPTION"&&!!n.closest("select"))&&!i&&!bv(n,e)?!0:Av(n)}function Av(n){let e=Oi==null?void 0:Oi.get(n);if(e===void 0){if(e=!1,n.parentElement&&n.parentElement.shadowRoot&&!n.assignedSlot&&(e=!0),!e){const i=zi(n);e=!i||i.display==="none"||Tv(n.getAttribute("aria-hidden"))===!0}if(!e){const i=St(n);i&&(e=Av(i))}Oi==null||Oi.set(n,e)}return e}function Rr(n,e){if(!e)return[];const i=mv(n);if(!i)return[];try{const s=e.split(" ").filter(o=>!!o),a=[];for(const o of s){const c=i.querySelector("#"+CSS.escape(o));c&&!a.includes(c)&&a.push(c)}return a}catch{return[]}}function Wn(n){return n.trim()}function el(n){return n.split(" ").map(e=>e.replace(/\r\n/g,`
|
|
114
|
+
`).replace(/[\u200b\u00ad]/g,"").replace(/\s\s*/g," ")).join(" ").trim()}function qb(n,e){const i=[...n.querySelectorAll(e)];for(const s of Rr(n,n.getAttribute("aria-owns")))s.matches(e)&&i.push(s),i.push(...s.querySelectorAll(e));return i}function tl(n,e){const i=e==="::before"?Id:e==="::after"?$d:qd;if(i!=null&&i.has(n))return i==null?void 0:i.get(n);const s=zi(n,e);let a;if(s){const o=s.content;o&&o!=="none"&&o!=="normal"&&s.display!=="none"&&s.visibility!=="hidden"&&(a=T_(n,o,!!e))}return e&&a!==void 0&&((s==null?void 0:s.display)||"inline")!=="inline"&&(a=" "+a+" "),i&&i.set(n,a),a}function T_(n,e,i){if(!(!e||e==="none"||e==="normal"))try{let s=O0(e).filter(f=>!(f instanceof hc));const a=s.findIndex(f=>f instanceof pt&&f.value==="/");if(a!==-1)s=s.slice(a+1);else if(!i)return;const o=[];let c=0;for(;c<s.length;)if(s[c]instanceof bd)o.push(s[c].value),c++;else if(c+2<s.length&&s[c]instanceof Ja&&s[c].value==="attr"&&s[c+1]instanceof yd&&s[c+2]instanceof md){const f=s[c+1].value;o.push(n.getAttribute(f)||""),c+=3}else return;return o.join("")}catch{}}function Cv(n){const e=n.getAttribute("aria-labelledby");if(e===null)return null;const i=Rr(n,e);return i.length?i:null}function __(n,e){const i=["button","cell","checkbox","columnheader","gridcell","heading","link","menuitem","menuitemcheckbox","menuitemradio","option","radio","row","rowheader","switch","tab","tooltip","treeitem"].includes(n),s=e&&["","caption","code","contentinfo","definition","deletion","emphasis","insertion","list","listitem","mark","none","paragraph","presentation","region","row","rowgroup","section","strong","subscript","superscript","table","term","time"].includes(n);return i||s}function ul(n,e){const i=e?zd:Bd;let s=i==null?void 0:i.get(n);return s===void 0&&(s="",["caption","code","definition","deletion","emphasis","generic","insertion","mark","paragraph","presentation","strong","subscript","suggestion","superscript","term","time"].includes(bt(n)||"")||(s=el(Sn(n,{includeHidden:e,visitedElements:new Set,embeddedInTargetElement:"self"}))),i==null||i.set(n,s)),s}function Ib(n,e){const i=e?Hd:Ud;let s=i==null?void 0:i.get(n);if(s===void 0){if(s="",n.hasAttribute("aria-describedby")){const a=Rr(n,n.getAttribute("aria-describedby"));s=el(a.map(o=>Sn(o,{includeHidden:e,visitedElements:new Set,embeddedInDescribedBy:{element:o,hidden:un(o)}})).join(" "))}else n.hasAttribute("aria-description")?s=el(n.getAttribute("aria-description")||""):s=el(n.getAttribute("title")||"");i==null||i.set(n,s)}return s}function A_(n){const e=n.getAttribute("aria-invalid");return!e||e.trim()===""||e.toLocaleLowerCase()==="false"?"false":e==="true"||e==="grammar"||e==="spelling"?e:"true"}function C_(n){if("validity"in n){const e=n.validity;return(e==null?void 0:e.valid)===!1}return!1}function N_(n){const e=br;let i=br==null?void 0:br.get(n);if(i===void 0){i="";const s=A_(n)!=="false",a=C_(n);if(s||a){const o=n.getAttribute("aria-errormessage");i=Rr(n,o).map(h=>el(Sn(h,{visitedElements:new Set,embeddedInDescribedBy:{element:h,hidden:un(h)}}))).join(" ").trim()}e==null||e.set(n,i)}return i}function Sn(n,e){var h,p,y,m;if(e.visitedElements.has(n))return"";const i={...e,embeddedInTargetElement:e.embeddedInTargetElement==="self"?"descendant":e.embeddedInTargetElement};if(!e.includeHidden){const v=!!((h=e.embeddedInLabelledBy)!=null&&h.hidden)||!!((p=e.embeddedInDescribedBy)!=null&&p.hidden)||!!((y=e.embeddedInNativeTextAlternative)!=null&&y.hidden)||!!((m=e.embeddedInLabel)!=null&&m.hidden);if(_v(n)||!v&&un(n))return e.visitedElements.add(n),""}const s=Cv(n);if(!e.embeddedInLabelledBy){const v=(s||[]).map(S=>Sn(S,{...e,embeddedInLabelledBy:{element:S,hidden:un(S)},embeddedInDescribedBy:void 0,embeddedInTargetElement:void 0,embeddedInLabel:void 0,embeddedInNativeTextAlternative:void 0})).join(" ");if(v)return v}const a=bt(n)||"",o=Ye(n);if(e.embeddedInLabel||e.embeddedInLabelledBy||e.embeddedInTargetElement==="descendant"){const v=[...n.labels||[]].includes(n),S=(s||[]).includes(n);if(!v&&!S){if(a==="textbox")return e.visitedElements.add(n),o==="INPUT"||o==="TEXTAREA"?n.value:n.textContent||"";if(["combobox","listbox"].includes(a)){e.visitedElements.add(n);let T;if(o==="SELECT")T=[...n.selectedOptions],!T.length&&n.options.length&&T.push(n.options[0]);else{const x=a==="combobox"?qb(n,"*").find(E=>bt(E)==="listbox"):n;T=x?qb(x,'[aria-selected="true"]').filter(E=>bt(E)==="option"):[]}return!T.length&&o==="INPUT"?n.value:T.map(x=>Sn(x,i)).join(" ")}if(["progressbar","scrollbar","slider","spinbutton","meter"].includes(a))return e.visitedElements.add(n),n.hasAttribute("aria-valuetext")?n.getAttribute("aria-valuetext")||"":n.hasAttribute("aria-valuenow")?n.getAttribute("aria-valuenow")||"":n.getAttribute("value")||"";if(["menu"].includes(a))return e.visitedElements.add(n),""}}const c=n.getAttribute("aria-label")||"";if(Wn(c))return e.visitedElements.add(n),c;if(!["presentation","none"].includes(a)){if(o==="INPUT"&&["button","submit","reset"].includes(n.type)){e.visitedElements.add(n);const v=n.value||"";return Wn(v)?v:n.type==="submit"?"Submit":n.type==="reset"?"Reset":n.getAttribute("title")||""}if(o==="INPUT"&&n.type==="file"){e.visitedElements.add(n);const v=n.labels||[];return v.length&&!e.embeddedInLabelledBy?Ha(v,e):"Choose File"}if(o==="INPUT"&&n.type==="image"){e.visitedElements.add(n);const v=n.labels||[];if(v.length&&!e.embeddedInLabelledBy)return Ha(v,e);const S=n.getAttribute("alt")||"";if(Wn(S))return S;const T=n.getAttribute("title")||"";return Wn(T)?T:"Submit"}if(!s&&o==="BUTTON"){e.visitedElements.add(n);const v=n.labels||[];if(v.length)return Ha(v,e)}if(!s&&o==="OUTPUT"){e.visitedElements.add(n);const v=n.labels||[];return v.length?Ha(v,e):n.getAttribute("title")||""}if(!s&&(o==="TEXTAREA"||o==="SELECT"||o==="INPUT")){e.visitedElements.add(n);const v=n.labels||[];if(v.length)return Ha(v,e);const S=o==="INPUT"&&["text","password","search","tel","email","url"].includes(n.type)||o==="TEXTAREA",T=n.getAttribute("placeholder")||"",x=n.getAttribute("title")||"";return!S||x?x:T}if(!s&&o==="FIELDSET"){e.visitedElements.add(n);for(let S=n.firstElementChild;S;S=S.nextElementSibling)if(Ye(S)==="LEGEND")return Sn(S,{...i,embeddedInNativeTextAlternative:{element:S,hidden:un(S)}});return n.getAttribute("title")||""}if(!s&&o==="FIGURE"){e.visitedElements.add(n);for(let S=n.firstElementChild;S;S=S.nextElementSibling)if(Ye(S)==="FIGCAPTION")return Sn(S,{...i,embeddedInNativeTextAlternative:{element:S,hidden:un(S)}});return n.getAttribute("title")||""}if(o==="IMG"){e.visitedElements.add(n);const v=n.getAttribute("alt")||"";return Wn(v)?v:n.getAttribute("title")||""}if(o==="TABLE"){e.visitedElements.add(n);for(let S=n.firstElementChild;S;S=S.nextElementSibling)if(Ye(S)==="CAPTION")return Sn(S,{...i,embeddedInNativeTextAlternative:{element:S,hidden:un(S)}});const v=n.getAttribute("summary")||"";if(v)return v}if(o==="AREA"){e.visitedElements.add(n);const v=n.getAttribute("alt")||"";return Wn(v)?v:n.getAttribute("title")||""}if(o==="SVG"||n.ownerSVGElement){e.visitedElements.add(n);for(let v=n.firstElementChild;v;v=v.nextElementSibling)if(Ye(v)==="TITLE"&&v.ownerSVGElement)return Sn(v,{...i,embeddedInLabelledBy:{element:v,hidden:un(v)}})}if(n.ownerSVGElement&&o==="A"){const v=n.getAttribute("xlink:title")||"";if(Wn(v))return e.visitedElements.add(n),v}}const f=o==="SUMMARY"&&!["presentation","none"].includes(a);if(__(a,e.embeddedInTargetElement==="descendant")||f||e.embeddedInLabelledBy||e.embeddedInDescribedBy||e.embeddedInLabel||e.embeddedInNativeTextAlternative){e.visitedElements.add(n);const v=k_(n,i);if(e.embeddedInTargetElement==="self"?Wn(v):v)return v}if(!["presentation","none"].includes(a)||o==="IFRAME"){e.visitedElements.add(n);const v=n.getAttribute("title")||"";if(Wn(v))return v}return e.visitedElements.add(n),""}function k_(n,e){const i=[],s=(o,c)=>{var f;if(!(c&&o.assignedSlot))if(o.nodeType===1){const h=((f=zi(o))==null?void 0:f.display)||"inline";let p=Sn(o,e);(h!=="inline"||o.nodeName==="BR")&&(p=" "+p+" "),i.push(p)}else o.nodeType===3&&i.push(o.textContent||"")};i.push(tl(n,"::before")||"");const a=tl(n);if(a!==void 0)i.push(a);else{const o=n.nodeName==="SLOT"?n.assignedNodes():[];if(o.length)for(const c of o)s(c,!1);else{for(let c=n.firstChild;c;c=c.nextSibling)s(c,!0);if(n.shadowRoot)for(let c=n.shadowRoot.firstChild;c;c=c.nextSibling)s(c,!0);for(const c of Rr(n,n.getAttribute("aria-owns")))s(c,!0)}}return i.push(tl(n,"::after")||""),i.join("")}const Md=["gridcell","option","row","tab","rowheader","columnheader","treeitem"];function Nv(n){return Ye(n)==="OPTION"?n.selected:Md.includes(bt(n)||"")?Tv(n.getAttribute("aria-selected"))===!0:!1}const Od=["checkbox","menuitemcheckbox","option","radio","switch","menuitemradio","treeitem"];function kv(n){const e=Ld(n,!0);return e==="error"?!1:e}function M_(n){return Ld(n,!0)}function O_(n){return Ld(n,!1)}function Ld(n,e){const i=Ye(n);if(e&&i==="INPUT"&&n.indeterminate)return"mixed";if(i==="INPUT"&&["checkbox","radio"].includes(n.type))return n.checked;if(Od.includes(bt(n)||"")){const s=n.getAttribute("aria-checked");return s==="true"?!0:e&&s==="mixed"?"mixed":!1}return"error"}const L_=["checkbox","combobox","grid","gridcell","listbox","radiogroup","slider","spinbutton","textbox","columnheader","rowheader","searchbox","switch","treegrid"];function j_(n){const e=Ye(n);return["INPUT","TEXTAREA","SELECT"].includes(e)?n.hasAttribute("readonly"):L_.includes(bt(n)||"")?n.getAttribute("aria-readonly")==="true":n.isContentEditable?!1:"error"}const jd=["button"];function Mv(n){if(jd.includes(bt(n)||"")){const e=n.getAttribute("aria-pressed");if(e==="true")return!0;if(e==="mixed")return"mixed"}return!1}const Rd=["application","button","checkbox","combobox","gridcell","link","listbox","menuitem","row","rowheader","tab","treeitem","columnheader","menuitemcheckbox","menuitemradio","rowheader","switch"];function Ov(n){if(Ye(n)==="DETAILS")return n.open;if(Rd.includes(bt(n)||"")){const e=n.getAttribute("aria-expanded");return e===null?void 0:e==="true"}}const Dd=["heading","listitem","row","treeitem"];function Lv(n){const e={H1:1,H2:2,H3:3,H4:4,H5:5,H6:6}[Ye(n)];if(e)return e;if(Dd.includes(bt(n)||"")){const i=n.getAttribute("aria-level"),s=i===null?Number.NaN:Number(i);if(Number.isInteger(s)&&s>=1)return s}return 0}const jv=["application","button","composite","gridcell","group","input","link","menuitem","scrollbar","separator","tab","checkbox","columnheader","combobox","grid","listbox","menu","menubar","menuitemcheckbox","menuitemradio","option","radio","radiogroup","row","rowheader","searchbox","select","slider","spinbutton","switch","tablist","textbox","toolbar","tree","treegrid","treeitem"];function vc(n){return Rv(n)||Dv(n)}function Rv(n){return["BUTTON","INPUT","SELECT","TEXTAREA","OPTION","OPTGROUP"].includes(Ye(n))&&(n.hasAttribute("disabled")||R_(n)||D_(n))}function R_(n){return Ye(n)==="OPTION"&&!!n.closest("OPTGROUP[DISABLED]")}function D_(n){const e=n==null?void 0:n.closest("FIELDSET[DISABLED]");if(!e)return!1;const i=e.querySelector(":scope > LEGEND");return!i||!i.contains(n)}function Dv(n,e=!1){if(!n)return!1;if(e||jv.includes(bt(n)||"")){const i=(n.getAttribute("aria-disabled")||"").toLowerCase();return i==="true"?!0:i==="false"?!1:Dv(St(n),!0)}return!1}function Ha(n,e){return[...n].map(i=>Sn(i,{...e,embeddedInLabel:{element:i,hidden:un(i)},embeddedInNativeTextAlternative:void 0,embeddedInLabelledBy:void 0,embeddedInDescribedBy:void 0,embeddedInTargetElement:void 0})).filter(i=>!!i).join(" ")}function B_(n){const e=Vd;let i=n,s;const a=[];for(;i;i=St(i)){const o=e.get(i);if(o!==void 0){s=o;break}a.push(i);const c=zi(i);if(!c){s=!0;break}const f=c.pointerEvents;if(f){s=f!=="none";break}}s===void 0&&(s=!0);for(const o of a)e.set(o,s);return s}let Bd,zd,Ud,Hd,br,Oi,qd,Id,$d,Vd,Bv=0;function Mc(){Cd(),++Bv,Bd??(Bd=new Map),zd??(zd=new Map),Ud??(Ud=new Map),Hd??(Hd=new Map),br??(br=new Map),Oi??(Oi=new Map),qd??(qd=new Map),Id??(Id=new Map),$d??($d=new Map),Vd??(Vd=new Map)}function Oc(){--Bv||(Bd=void 0,zd=void 0,Ud=void 0,Hd=void 0,br=void 0,Oi=void 0,qd=void 0,Id=void 0,$d=void 0,Vd=void 0),Nd()}const z_={button:"button",checkbox:"checkbox",image:"button",number:"spinbutton",radio:"radio",range:"slider",reset:"button",submit:"button"};let U_=0;function zv(n){return n.mode==="ai"?{visibility:"ariaOrVisible",refs:"interactable",refPrefix:n.refPrefix,includeGenericRole:!0,renderActive:!n.doNotRenderActive,renderCursorPointer:!0}:n.mode==="autoexpect"?{visibility:"ariaAndVisible",refs:"none"}:n.mode==="codegen"?{visibility:"aria",refs:"none",renderStringsAsRegex:!0}:{visibility:"aria",refs:"none"}}function nl(n,e){const i=zv(e),s=new Set,a={root:{role:"fragment",name:"",children:[],props:{},box:bc(n),receivesPointerEvents:!0},elements:new Map,refs:new Map,iframeRefs:[]};Qh(a.root,n);const o=(f,h,p)=>{if(s.has(h))return;if(s.add(h),h.nodeType===Node.TEXT_NODE&&h.nodeValue){if(!p)return;const x=h.nodeValue;f.role!=="textbox"&&x&&f.children.push(h.nodeValue||"");return}if(h.nodeType!==Node.ELEMENT_NODE)return;const y=h,m=!un(y);let v=m;if(i.visibility==="ariaOrVisible"&&(v=m||ji(y)),i.visibility==="ariaAndVisible"&&(v=m&&ji(y)),i.visibility==="aria"&&!v)return;const S=[];if(y.hasAttribute("aria-owns")){const x=y.getAttribute("aria-owns").split(/\s+/);for(const E of x){const A=n.ownerDocument.getElementById(E);A&&S.push(A)}}const T=v?H_(y,i):null;T&&(T.ref&&(a.elements.set(T.ref,y),a.refs.set(y,T.ref),T.role==="iframe"&&a.iframeRefs.push(T.ref)),f.children.push(T)),c(T||f,y,S,v)};function c(f,h,p,y){var T;const v=(((T=zi(h))==null?void 0:T.display)||"inline")!=="inline"||h.nodeName==="BR"?" ":"";v&&f.children.push(v),f.children.push(tl(h,"::before")||"");const S=h.nodeName==="SLOT"?h.assignedNodes():[];if(S.length)for(const x of S)o(f,x,y);else{for(let x=h.firstChild;x;x=x.nextSibling)x.assignedSlot||o(f,x,y);if(h.shadowRoot)for(let x=h.shadowRoot.firstChild;x;x=x.nextSibling)o(f,x,y)}for(const x of p)o(f,x,y);if(f.children.push(tl(h,"::after")||""),v&&f.children.push(v),f.children.length===1&&f.name===f.children[0]&&(f.children=[]),f.role==="link"&&h.hasAttribute("href")){const x=h.getAttribute("href");f.props.url=x}if(f.role==="textbox"&&h.hasAttribute("placeholder")&&h.getAttribute("placeholder")!==f.name){const x=h.getAttribute("placeholder");f.props.placeholder=x}}Mc();try{o(a.root,n,!0)}finally{Oc()}return I_(a.root),q_(a.root),a}function $b(n,e){if(e.refs==="none"||e.refs==="interactable"&&(!n.box.visible||!n.receivesPointerEvents))return;const i=Kd(n);let s=i._ariaRef;(!s||s.role!==n.role||s.name!==n.name)&&(s={role:n.role,name:n.name,ref:(e.refPrefix??"")+"e"+ ++U_},i._ariaRef=s),n.ref=s.ref}function H_(n,e){const i=n.ownerDocument.activeElement===n;if(n.nodeName==="IFRAME"){const p={role:"iframe",name:"",children:[],props:{},box:bc(n),receivesPointerEvents:!0,active:i};return Qh(p,n),$b(p,e),p}const s=e.includeGenericRole?"generic":null,a=bt(n)??s;if(!a||a==="presentation"||a==="none")return null;const o=Nt(ul(n,!1)||""),c=B_(n),f=bc(n);if(a==="generic"&&f.inline&&n.childNodes.length===1&&n.childNodes[0].nodeType===Node.TEXT_NODE)return null;const h={role:a,name:o,children:[],props:{},box:f,receivesPointerEvents:c,active:i};return Qh(h,n),$b(h,e),Od.includes(a)&&(h.checked=kv(n)),jv.includes(a)&&(h.disabled=vc(n)),Rd.includes(a)&&(h.expanded=Ov(n)),Dd.includes(a)&&(h.level=Lv(n)),jd.includes(a)&&(h.pressed=Mv(n)),Md.includes(a)&&(h.selected=Nv(n)),(n instanceof HTMLInputElement||n instanceof HTMLTextAreaElement)&&n.type!=="checkbox"&&n.type!=="radio"&&n.type!=="file"&&(h.children=[n.value]),h}function q_(n){const e=i=>{const s=[];for(const o of i.children||[]){if(typeof o=="string"){s.push(o);continue}const c=e(o);s.push(...c)}return i.role==="generic"&&!i.name&&s.length<=1&&s.every(o=>typeof o!="string"&&!!o.ref)?s:(i.children=s,[i])};e(n)}function I_(n){const e=(s,a)=>{if(!s.length)return;const o=Nt(s.join(""));o&&a.push(o),s.length=0},i=s=>{const a=[],o=[];for(const c of s.children||[])typeof c=="string"?o.push(c):(e(o,a),i(c),a.push(c));e(o,a),s.children=a.length?a:[],s.children.length===1&&s.children[0]===s.name&&(s.children=[])};i(n)}function $_(n,e){return e?n?typeof e=="string"?n===e:!!n.match(new RegExp(e.pattern)):!1:!0}function Vb(n,e){if(!(e!=null&&e.normalized))return!0;if(!n)return!1;if(n===e.normalized||n===e.raw)return!0;const i=V_(e);return i?!!n.match(i):!1}const Eh=Symbol("cachedRegex");function V_(n){if(n[Eh]!==void 0)return n[Eh];const{raw:e}=n,i=e.startsWith("/")&&e.endsWith("/")&&e.length>1;let s;try{s=i?new RegExp(e.slice(1,-1)):null}catch{s=null}return n[Eh]=s,s}function G_(n,e){const i=nl(n,{mode:"expect"});return{matches:Uv(i.root,e,!1,!1),received:{raw:il(i,{mode:"expect"}),regex:il(i,{mode:"codegen"})}}}function K_(n,e){const i=nl(n,{mode:"expect"}).root;return Uv(i,e,!0,!1).map(a=>Kd(a))}function Gd(n,e,i){var s;return typeof n=="string"&&e.kind==="text"?Vb(n,e.text):n===null||typeof n!="object"||e.kind!=="role"||e.role!=="fragment"&&e.role!==n.role||e.checked!==void 0&&e.checked!==n.checked||e.disabled!==void 0&&e.disabled!==n.disabled||e.expanded!==void 0&&e.expanded!==n.expanded||e.level!==void 0&&e.level!==n.level||e.pressed!==void 0&&e.pressed!==n.pressed||e.selected!==void 0&&e.selected!==n.selected||!$_(n.name,e.name)||!Vb(n.props.url,(s=e.props)==null?void 0:s.url)?!1:e.containerMode==="contain"?Kb(n.children||[],e.children||[]):e.containerMode==="equal"?Gb(n.children||[],e.children||[],!1):e.containerMode==="deep-equal"||i?Gb(n.children||[],e.children||[],!0):Kb(n.children||[],e.children||[])}function Gb(n,e,i){if(e.length!==n.length)return!1;for(let s=0;s<e.length;++s)if(!Gd(n[s],e[s],i))return!1;return!0}function Kb(n,e){if(e.length>n.length)return!1;const i=n.slice(),s=e.slice();for(const a of s){let o=i.shift();for(;o&&!Gd(o,a,!1);)o=i.shift();if(!o)return!1}return!0}function Uv(n,e,i,s){const a=[],o=(c,f)=>{if(Gd(c,e,s)){const h=typeof c=="string"?f:c;return h&&a.push(h),!i}if(typeof c=="string")return!1;for(const h of c.children||[])if(o(h,c))return!0;return!1};return o(n,null),a}function Hv(n,e=new Map){n!=null&&n.ref&&e.set(n.ref,n);for(const i of(n==null?void 0:n.children)||[])typeof i!="string"&&Hv(i,e);return e}function X_(n,e){var o;const i=Hv(e==null?void 0:e.root),s=new Map,a=(c,f)=>{let h=c.children.length===(f==null?void 0:f.children.length)&&d_(c,f),p=h;for(let y=0;y<c.children.length;y++){const m=c.children[y],v=f==null?void 0:f.children[y];if(typeof m=="string")h&&(h=m===v),p&&(p=m===v);else{let S=typeof v!="string"?v:void 0;m.ref&&(S=i.get(m.ref));const T=a(m,S);(!S||!T&&!m.ref||S!==v)&&(p=!1),h&&(h=T&&S===v)}}return s.set(c,h?"same":p?"skip":"changed"),h};return a(n.root,i.get((o=e==null?void 0:e.root)==null?void 0:o.ref)),s}function F_(n,e){const i=[],s=a=>{const o=e.get(a);if(o!=="same")if(o==="skip")for(const c of a.children)typeof c!="string"&&s(c);else i.push(a)};for(const a of n)typeof a=="string"?i.push(a):s(a);return i}function il(n,e,i){const s=zv(e),a=[],o=s.renderStringsAsRegex?Q_:()=>!0,c=s.renderStringsAsRegex?Y_:S=>S;let f=n.root.role==="fragment"?n.root.children:[n.root];const h=X_(n,i);i&&(f=F_(f,h));const p=(S,T)=>{const x=wh(c(S));x&&a.push(T+"- text: "+x)},y=(S,T)=>{let x=S.role;if(S.name&&S.name.length<=900){const E=c(S.name);if(E){const A=E.startsWith("/")&&E.endsWith("/")?E:JSON.stringify(E);x+=" "+A}}return S.checked==="mixed"&&(x+=" [checked=mixed]"),S.checked===!0&&(x+=" [checked]"),S.disabled&&(x+=" [disabled]"),S.expanded&&(x+=" [expanded]"),S.active&&s.renderActive&&(x+=" [active]"),S.level&&(x+=` [level=${S.level}]`),S.pressed==="mixed"&&(x+=" [pressed=mixed]"),S.pressed===!0&&(x+=" [pressed]"),S.selected===!0&&(x+=" [selected]"),S.ref&&(x+=` [ref=${S.ref}]`,T&&mc(S)&&(x+=" [cursor=pointer]")),x},m=S=>(S==null?void 0:S.children.length)===1&&typeof S.children[0]=="string"&&!Object.keys(S.props).length?S.children[0]:void 0,v=(S,T,x)=>{if(h.get(S)==="same"&&S.ref){a.push(T+`- ref=${S.ref} [unchanged]`);return}const E=!!i&&!T,A=T+"- "+(E?"<changed> ":"")+y_(y(S,x)),N=m(S);if(!S.children.length&&!Object.keys(S.props).length)a.push(A);else if(N!==void 0)o(S,N)?a.push(A+": "+wh(c(N))):a.push(A);else{a.push(A+":");for(const[$,z]of Object.entries(S.props))a.push(T+" - /"+$+": "+wh(z));const B=T+" ",V=!!S.ref&&x&&mc(S);for(const $ of S.children)typeof $=="string"?p(o(S,$)?$:"",B):v($,B,x&&!V)}};for(const S of f)typeof S=="string"?p(S,""):v(S,"",!!s.renderCursorPointer);return a.join(`
|
|
115
|
+
`)}function Y_(n){const e=[{regex:/\b[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}\b/,replacement:"[0-9a-fA-F-]+"},{regex:/\b[\d,.]+[bkmBKM]+\b/,replacement:"[\\d,.]+[bkmBKM]+"},{regex:/\b\d+[hmsp]+\b/,replacement:"\\d+[hmsp]+"},{regex:/\b[\d,.]+[hmsp]+\b/,replacement:"[\\d,.]+[hmsp]+"},{regex:/\b\d+,\d+\b/,replacement:"\\d+,\\d+"},{regex:/\b\d+\.\d{2,}\b/,replacement:"\\d+\\.\\d+"},{regex:/\b\d{2,}\.\d+\b/,replacement:"\\d+\\.\\d+"},{regex:/\b\d{2,}\b/,replacement:"\\d+"}];let i="",s=0;const a=new RegExp(e.map(o=>"("+o.regex.source+")").join("|"),"g");return n.replace(a,(o,...c)=>{const f=c[c.length-2],h=c.slice(0,-2);i+=pc(n.slice(s,f));for(let p=0;p<h.length;p++)if(h[p]){const{replacement:y}=e[p];i+=y;break}return s=f+o.length,o}),i?(i+=pc(n.slice(s)),String(new RegExp(i))):n}function Q_(n,e){if(!e.length)return!1;if(!n.name)return!0;if(n.name.length>e.length)return!1;const i=e.length<=200&&n.name.length<=200?kE(e,n.name):"";let s=e;for(;i&&s.includes(i);)s=s.replace(i,"");return s.trim().length/e.length>.1}const qv=Symbol("element");function Kd(n){return n[qv]}function Qh(n,e){n[qv]=e}function P_(n,e){const i=m_(n,e);return i?Kd(i):void 0}typeof window<"u"&&(window.serializeDOM=Vv,window.getFlexibleLocators=Gv,window.getAssignedRole=pn,window.getAccessibleName=kr,window.getDirectText=ms);let Ph,Iv,sl,Jh=new WeakMap;function J_(n,e={}){const i=JSON.stringify({p:!!e.checkPseudos,o:!!e.checkOcclusion,e:+e.opacityEpsilon||.05});let s=Jh.get(n);if(s&&s.has(i))return s.get(i);const a=Z_(n,e);return s||(s=new Map,Jh.set(n,s)),s.set(i,a),a}function Z_(n,{checkPseudos:e=!1,checkOcclusion:i=!1,opacityEpsilon:s=.05}={}){var h;if((n===document.body||n===document.documentElement)&&(s=0),!(n instanceof Element)||typeof n.checkVisibility=="function"&&!n.checkVisibility({checkOpacity:!0,checkVisibilityCSS:!0}))return!1;for(let p=n;p;p=p.parentElement){const y=getComputedStyle(p);if(y.display==="none"||y.getPropertyValue("content-visibility")==="hidden"||p.tagName==="DETAILS"&&!p.open||parseFloat(y.opacity)<=s||y.visibility==="hidden"||y.visibility==="collapse")return!1}let a=n.getBoundingClientRect();if(a.width===0&&a.height===0&&getComputedStyle(n).getPropertyValue("content-visibility")==="auto"){const p=(h=n.getClientRects)==null?void 0:h.call(n);p&&p.length&&(a=p[0])}if(window.innerWidth||document.documentElement.clientWidth,window.innerHeight||document.documentElement.clientHeight,W_(n,a))return!1;const o=getComputedStyle(n);if(o.clip&&o.clip!=="auto"&&/rect\(0.+0.+0.+0\)/.test(o.clip))return!1;const c=o.clipPath;if(c&&c!=="none"&&/(?:circle|ellipse)\s*\(\s*0(?:px|%)?\s*\)|inset\s*\(\s*100%\s*\)/.test(c))return!1;const f=o.filter||o.webkitFilter;if(f&&/opacity\(0(?:%|)\)/.test(f))return!1;if(a.width===0&&a.height===0)if(e){if(!tA(n,s))return!1}else return!1;return!(i&&eA(n,a))}function W_(n,e){if(getComputedStyle(n).position==="fixed")return!1;const s=(o,c)=>{const f=getComputedStyle(o),h=c==="x"?f.overflowX:f.overflowY;return["auto","scroll"].includes(h)?c==="x"?o.scrollWidth>o.clientWidth:o.scrollHeight>o.clientHeight:!1},a=(o,c)=>{for(let f=n.parentElement;f&&f!==o;f=f.parentElement)if(s(f,c))return!0;return!1};for(let o=n.parentElement;o&&o!==document.documentElement;o=o.parentElement){const c=getComputedStyle(o),f=c.overflowX==="hidden"||c.overflowX==="clip",h=c.overflowY==="hidden"||c.overflowY==="clip";if(!f&&!h)continue;const p=o.getBoundingClientRect(),y=e.right<=p.left||e.left>=p.right,m=e.bottom<=p.top||e.top>=p.bottom;if(f&&y&&!a(o,"x")||h&&m&&!a(o,"y"))return!0}return!1}function eA(n,e){const i=[[e.left+1,e.top+1],[e.right-1,e.top+1],[e.right-1,e.bottom-1],[e.left+1,e.bottom-1],[e.left+e.width/2,e.top+e.height/2]],s=window.innerWidth,a=window.innerHeight;let o=0;for(const[c,f]of i){if(c<0||f<0||c>s||f>a){o++;continue}const h=document.elementFromPoint(c,f);if(h&&(h===n||n.contains(h)))return!1;o++}return o===i.length}function tA(n,e){const i=s=>{const a=getComputedStyle(n,s);if(a.display==="none"||!a.content||a.content==="none"||/^['"]{2}$/.test(a.content)||a.visibility==="hidden"||parseFloat(a.opacity)<=e)return!1;const o=parseFloat(a.width),c=parseFloat(a.height);return Number.isFinite(o)&&Number.isFinite(c)?o||c:!0};return i("::before")||i("::after")}const $t="data-interactive-id-a9b1c8",ii="data-interactive-score-a9b1c8",Nr="data-ignore-interactive-a9b1c8",Xd=new Set(["script","style","meta","link","noscript","object","embed","base","param","template","path"]),Sc=new Set(["input","textarea","select","button","a","summary","audio","video","iframe"]);function Dr(n,e){if(!n)return;const i=[n];for(;i.length>0;){const s=i.pop();if(s instanceof Element){e(s);for(let a=s.children.length-1;a>=0;a--)i.push(s.children[a]);if(s.shadowRoot){const a=s.shadowRoot.children;for(let o=a.length-1;o>=0;o--)i.push(a[o])}}}}const wc=new Set(["button","link","checkbox","radio","switch","menuitem","menuitemcheckbox","menuitemradio","tab","slider","spinbutton","textbox","combobox","option"]),qo=["button.ant-btn","a.ant-btn","ul.ant-dropdown-menu li.ant-dropdown-menu-item","li.ant-menu-item",".ant-pagination-item a",".ant-pagination-item-link",".ant-select-item-option",".ant-tree-node-content-wrapper",".ant-tabs-tab","label.ant-radio-wrapper","label.ant-checkbox-wrapper",".ant-switch",".ant-slider-handle",".ant-segmented-item",".MuiButton-root",".MuiIconButton-root",".MuiMenuItem-root",".MuiListItemButton-root",".MuiTab-root",".MuiPaginationItem-root",".MuiChip-clickable",".MuiSlider-thumb",".MuiSwitch-switchBase",".MuiCheckbox-root",".MuiRadio-root",".MuiListItem-root.MuiButtonBase-root","button.btn","a.btn",".dropdown-item",".page-link",".list-group-item-action",".nav-link",".p-button",".p-menuitem-link",".p-tabmenuitem",".p-tabview-nav-link",".p-selectable-row",".p-checkbox-box",".p-radiobutton-box",".p-togglebutton",".p-slider-handle",".ui.button",".ui.menu .item",".ui.pagination.menu .item",".ui.dropdown .menu .item",".chakra-button",".chakra-link",".chakra-menu__menuitem",".chakra-tabs__tab",".chakra-slider__thumb",".chakra-switch__thumb"],nA=["hx-","x-on:","@","up-","on:","client:"],Xb=new Set(["click","mousedown","keydown","keyup","change","submit","dblclick","pointerdown","pointerup","touchstart"]);function fs(n){if(n.parentElement)return n.parentElement;const e=n.getRootNode();return e instanceof ShadowRoot?e.host:null}function iA(n){Dr(n,e=>{if(e.matches('input[readonly][tabindex]:not([tabindex="-1"]), input[disabled][tabindex]:not([tabindex="-1"])'))try{if(e.getBoundingClientRect().width>2)return;const i=e.closest('[role="combobox"], .react-select__control, .MuiInputBase-root');i&&(i.setAttribute("data-unified-component","true"),i.setAttribute($t,"true"),i.setAttribute(ii,"9"),e.setAttribute(Nr,"true"))}catch{}if(e.tagName.toLowerCase()==="label"){const i=e.querySelector(":scope > input, :scope > select, :scope > textarea");if(i){e.setAttribute("data-unified-component","true"),i.setAttribute(Nr,"true"),e.setAttribute($t,"true");const s=(i.type||"").toLowerCase(),a=s==="checkbox"||s==="radio"?"10":"9";e.setAttribute(ii,a)}}})}function sA(n){Dr(n,e=>{if(e.tagName.toLowerCase()!=="label"||!e.hasAttribute("for"))return;const i=e;try{const s=i.getAttribute("for");if(!s)return;const a=i.getRootNode(),o=a.getElementById?a.getElementById(s):document.getElementById(s);if(!o)return;const c=(o.tagName||"").toLowerCase(),f=pn(o),h=Sc.has(c)&&!(c==="input"&&o.type==="hidden"),p=wc.has(f);if(h||p){i.setAttribute("data-unified-component","true"),i.setAttribute($t,"true");const y=o.tagName.toLowerCase(),m=(o.getAttribute("type")||"").toLowerCase(),v=y==="input"&&["checkbox","radio"].includes(m);i.setAttribute(ii,v?"10":"6"),v&&o.setAttribute(Nr,"true")}}catch{}})}function rA(n){const e=$t,i=ii,s=new WeakMap,a=h=>{if(!(h instanceof HTMLElement))return!1;try{const p=window.getComputedStyle(h);return p.cursor.includes("pointer")&&p.display!=="none"&&p.visibility!=="hidden"&&parseFloat(p.opacity)>0&&p.pointerEvents!=="none"&&!h.closest("[inert]")}catch{return!1}},o=h=>h instanceof HTMLElement&&h.tabIndex>=0,c=[n],f=[];for(;c.length;){const h=c.pop();if(f.push(h),h instanceof Element){for(const p of h.children)c.push(p);if(h.shadowRoot)for(const p of h.shadowRoot.children)c.push(p)}}for(;f.length;){const h=f.pop();if(!(h instanceof HTMLElement)){s.set(h,{ptr:!1,tab:!1,hasInt:!1});continue}const p=a(h),y=o(h),m=h.hasAttribute(e);let v=!1,S=!1,T=!1;const x=[...h.children||[],...h.shadowRoot?h.shadowRoot.children:[]];for(const N of x){const B=s.get(N);B&&(v||(v=B.ptr),S||(S=B.tab),T||(T=B.hasInt))}const E=(p&&!y&&S||y&&!p&&v)&&!m&&!T;let A=m;E&&(h.setAttribute(e,"true"),h.setAttribute(i,"7"),A=!0),s.set(h,{ptr:p||v,tab:y||S,hasInt:A||T})}}function aA(n){if(!["div","main","header","footer"].includes(n.tagName.toLowerCase()))return!1;try{const e=n.getBoundingClientRect();return e.width>=window.innerWidth*.9&&e.height>=window.innerHeight*.9}catch{return!1}}function Zh(n,e){if(n.textContent.trim().length>0||n.querySelector("img, svg, i, video, canvas, picture")||e.backgroundImage&&e.backgroundImage!=="none"||e.borderWidth&&parseFloat(e.borderWidth)>0)return!0;const i=e.backgroundColor;if(i&&i!=="transparent"&&!i.startsWith("rgba(0, 0, 0, 0")){const s=i.match(/, ([\d.]+)\)/);return!(s&&parseFloat(s[1])===0)}return!1}function lA(n){if(n.textContent.trim()!=="")return!1;const e=Array.from(n.children);return e.length===0?!1:e.every(i=>["img","svg","i","span","picture"].includes(i.tagName.toLowerCase()))}function Wh(n){if(!n)return!1;try{const e=window.getComputedStyle(n,"::before"),i=window.getComputedStyle(n,"::after"),s=a=>a.display!=="none"&&a.content&&a.content!=="none"&&a.content!=='""'&&a.content!=="''";return s(e)||s(i)}catch{return!1}}function oA(n,e){if(!(n!=null&&n.matches)||!(e!=null&&e.length))return!1;for(const i of e)try{if(n.matches(i))return!0}catch{}return!1}function cA(n){var m,v,S;if(n.hasAttribute(Nr))return 0;let e;try{if(n.closest("[inert]")||(e=window.getComputedStyle(n),e.display==="none"||e.visibility==="hidden"||parseFloat(e.opacity)===0))return 0;const T=pn(n);if(e.pointerEvents==="none"&&T!=="button")return 0}catch{return 0}const i=n.hasAttribute("tabindex")&&+n.getAttribute("tabindex")>=0,s=oA(n,sl),a=i&&s,o=n.tagName.toLowerCase();if(["html","body"].includes(o))return 0;const c=pn(n);if(wc.has(c)||n.isContentEditable||o==="input"&&n.type!=="hidden"||["textarea","select","button","summary"].includes(o)||o==="a"&&n.hasAttribute("href")||(o==="audio"||o==="video")&&n.hasAttribute("controls")||o==="iframe"&&n.src&&(n.src.includes("google.com/accounts")||n.src.includes("apple.com")))return 10;try{if(n.getAttribute("aria-controls")&&document.getElementById(n.getAttribute("aria-controls")))return 9}catch{}for(const T of n.attributes)if(nA.some(x=>T.name.startsWith(x)))return 9;if(o==="a"&&([...n.attributes].some(T=>T.name.startsWith("data-"))||(v=(m=window.__eventTypes)==null?void 0:m.get(n))!=null&&v.has("click")))return 9;const f=n.textContent.trim()!==""&&Array.from(n.childNodes).some(T=>T.nodeType===Node.TEXT_NODE);if((o==="div"||o==="span")&&e.cursor==="pointer"&&(lA(n)||f)||(o==="i"||o==="svg")&&e.cursor==="pointer")return 8;let h=0;const p=(S=window.__eventTypes)==null?void 0:S.get(n);p&&[...p].some(T=>Xb.has(T))&&(h=7);const y=Array.from(n.attributes).some(T=>T.name.startsWith("on")&&Xb.has(T.name.slice(2)));if(!h&&y&&(h=7),!h&&n.hasAttribute("tabindex")&&parseInt(n.getAttribute("tabindex"),10)>=0&&(h=7),h>0){if(aA(n)&&e.cursor!=="pointer"&&!a||!Zh(n,e)&&!Wh(n)&&e.cursor!=="pointer"&&!a)return 0;e.cursor==="pointer"?h=8:a&&(h=Math.max(h,7))}if(!h&&a&&(h=7),h===0&&mA(n,e,sl)&&(h=7),h===0&&e.cursor==="pointer"&&(h=6),h===0&&o==="label"&&n.control&&(h=3),h>0)try{const T=n.getBoundingClientRect();if(T.width<8&&T.height<8&&e.overflow==="hidden"&&!Zh(n,e)&&!Wh(n))return 0}catch{}return h}function uA(n){const e=new Map;Dr(n,s=>{const a=s.hasAttribute($t),o=s.getAttribute(ii);if(o!=null&&o!==""){const f=parseInt(o,10);!Number.isNaN(f)&&f>0&&e.set(s,f);return}const c=cA(s);if(c>0){e.set(s,c);return}a&&e.set(s,9)});const i=new Map;for(const[s,a]of e.entries()){if(s.hasAttribute("data-unified-component")||Sc.has(s.tagName.toLowerCase())){a>(i.get(s)||0)&&i.set(s,a);continue}let o={element:s,score:a},c=fs(s);for(;c;)e.has(c)&&e.get(c)>=o.score&&(o={element:c,score:e.get(c)}),c=fs(c);o.score>(i.get(o.element)||0)&&i.set(o.element,o.score)}for(const[s,a]of i.entries())s.setAttribute($t,"true"),s.setAttribute(ii,a)}function fA(n){const e=[];Dr(n,s=>{s.hasAttribute($t)&&e.push(s)});const i=new Set;e.forEach(s=>{if(i.has(s))return;let a=fs(s);for(;a&&a!==n;){if(a.hasAttribute($t)&&!i.has(a)){try{const o=s.tagName.toLowerCase(),c=a.tagName.toLowerCase(),f=window.getComputedStyle(a),h=Sc.has(o),p=Sc.has(c),y=pn(s),m=o==="label"&&s.querySelector("input[type=checkbox], input[type=radio]");if(h&&!p){i.add(a),a=fs(a);continue}else if(m&&!p){i.add(a),a=fs(a);continue}const v=pn(a);if(!wc.has(v)&&!wc.has(y)&&!Zh(a,f)&&!Wh(a)){i.add(a),a=fs(a);continue}}catch{}break}a=fs(a)}}),i.forEach(s=>{s.removeAttribute($t),s.removeAttribute(ii)})}function hA(n,e){if(!n||!n.querySelectorAll||!Array.isArray(e)||e.length===0)return;const i=e.filter(a=>typeof a=="string"&&a.trim()).join(",");if(!i)return;let s;try{s=n.querySelectorAll(i)}catch(a){console.warn("markExtraInteractive: invalid selectors",a);return}s.forEach(a=>{a.hasAttribute($t)||a.setAttribute($t,"true")})}function dA(n,e={}){[$t,ii,Nr,"data-unified-component"].forEach(s=>{Dr(n,a=>{a.hasAttribute(s)&&a.removeAttribute(s)})}),e.extraInteractiveSelectors&&e.extraInteractiveSelectors.length&&hA(n,e.extraInteractiveSelectors),iA(n),sA(n),rA(n),uA(n),fA(n)}function pA(n){var s;if(!n||typeof n.willValidate!="boolean"||!n.willValidate||n.checkValidity())return null;const e=(s=n.validationMessage)==null?void 0:s.trim();if(e)return e;const i=n.validity;return i?i.valueMissing?"Fill this field":i.typeMismatch?"Wrong type":i.patternMismatch?"Not matching the pattern":i.tooShort?"Too short":i.tooLong?"Too long":i.rangeUnderflow?"Too small value":i.rangeOverflow?"Too big value":i.stepMismatch?"Not matching the step":i.badInput?"Invalid input":null:null}function $v(n,e,i=!0){if(n.nodeType!==Node.ELEMENT_NODE)return null;const s=n.tagName.toLowerCase();if(Xd.has(s)||n.hasAttribute("data-ignore-serialization"))return null;let a={},o={x:0,y:0,width:0,height:0};try{a=window.getComputedStyle(n),o=n.getBoundingClientRect()}catch{}const c=J_(n,{checkPseudos:!0,checkOcclusion:!1}),f={tag:s,isVisible:c,attributes:{},box:{x:Math.round(o.x),y:Math.round(o.y),width:Math.round(o.width),height:Math.round(o.height)},computedStyle:{display:a.display||"",visibility:a.visibility||"",opacity:a.opacity||"",cursor:a.cursor||""}};if(s==="input"){const E=pA(n);E&&(f.error=E)}for(const E of n.attributes)f.attributes[E.name]=E.value;const h=n.hasAttribute($t);if(h)f.isInteractive=!0,f.role=pn(n),f.accessibleName=kr(n),f.isDisabled=n.hasAttribute("disabled")||n.getAttribute("aria-disabled")==="true",f.isFocused=document.activeElement===n,s==="input"?f.isChecked=n.checked:n.hasAttribute("aria-checked")&&(f.isChecked=n.getAttribute("aria-checked")==="true");else{const E=ms(n);E&&(f.text=E)}s==="option"?f.isSelected=n.selected:n.hasAttribute("aria-selected")&&(f.isSelected=n.getAttribute("aria-selected")==="true"),f.isInteractive&&xA(n)&&(f.onTop=!0);const p=Gv(n,{forceUnique:!0}),y=p.getByCss,m=y?y.css:n.outerHTML+Iv++,v=EA(m);f.id=v,Ph[v]=p;const S=o.width===0&&o.height===0,T=a.overflow==="hidden"||a.overflowX==="hidden"||a.overflowY==="hidden";if(S&&T&&!h&&!s.includes("-"))f.lazyLoad=!0;else{const E=[],A=[...n.childNodes,...n.shadowRoot?n.shadowRoot.childNodes:[]];for(const N of A){const B=$v(N,e,c);B&&E.push(B)}E.length>0&&(f.children=E)}return f}function Vv(n,e={}){Ph={},Iv=0,sl=null;try{sl=gA(n&&n.ownerDocument?n.ownerDocument:void 0)}catch(s){console.warn("Could not build hover selector cache.",s),sl=[]}const i={compressInvisible:!0,...e};i.extraInteractiveSelectors==null?i.extraInteractiveSelectors=qo:qo&&qo.length&&(i.extraInteractiveSelectors=[...qo,...i.extraInteractiveSelectors]);try{return dA(n,i),{dom:$v(n,i)||{},locators:Ph}}catch(s){return console.error("Fatal error during serialization:",s),{dom:{},locators:{}}}finally{const s=[$t,ii,Nr,"data-unified-component"];Jh=new WeakMap,s.forEach(a=>{Dr(n,o=>{o.hasAttribute(a)&&o.removeAttribute(a)})})}}function gA(n=typeof document<"u"?document:null){var i;if(!n||!n.styleSheets)return[];const e=new Set;for(const s of n.styleSheets){let a;try{a=s.cssRules}catch{continue}if(a){for(const o of a)if(o.type===CSSRule.STYLE_RULE&&((i=o.selectorText)!=null&&i.includes(":hover"))){const c=o.selectorText.split(",");for(let f of c)if(f.includes(":hover")){const h=f.replace(/:hover/g,"").trim();h&&e.add(h)}}}}return Array.from(e)}function mA(n,e,i){if(!(n!=null&&n.matches)||(e||window.getComputedStyle(n)).cursor!=="pointer"||!i||i.length===0)return!1;for(const a of i)try{if(n.matches(a))return!0}catch{}return!1}function ml(n){return`(?:^|[^A-Za-z0-9])(?:${n})(?=$|[^A-Za-z0-9])`}const yA=new RegExp(ml("(?:combo(?:box)?|drop(?:[-_]?(?:down|btn))|select(?:box)?|listbox|date[-_]?picker|color[-_]?picker|calendar)"),"i"),bA=new RegExp(ml("date[-_]?picker"),"i"),vA=new RegExp(ml("color[-_]?picker"),"i"),SA=new RegExp(ml("calendar"),"i"),wA=new RegExp(ml("listbox"),"i"),Th=new WeakSet;function pn(n){if(typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host),!(n instanceof Element)||Th.has(n))return null;Th.add(n);try{const e="combobox",i="datepicker",s="calendar",a="colorpicker";try{if(window.getComputedAccessibleNode){const T=window.getComputedAccessibleNode(n);if(T&&T.role)return T.role==="none"?null:T.role}}catch{}const o=n.getAttribute("role");if(o){const T=o.trim().toLowerCase();return T==="presentation"||T==="none"?null:T==="grid"&&(n.getAttribute("aria-label")||"").toLowerCase().includes("calendar")?s:T}const c=n.getAttribute("aria-haspopup");if(c!==null&&c.toLowerCase()!=="false")return e;const f=n.getAttribute("aria-controls");if(f)try{const T=n.getRootNode&&n.getRootNode(),x=f.trim().split(/\s+/);for(const E of x){if(!E)continue;let A=document.getElementById(E);if(!A&&T&&T!==document&&typeof T.querySelector=="function"){const N=window.CSS&&typeof window.CSS.escape=="function"?CSS.escape(E):E.replace(/[^\w-]/g,"\\$&");A=T.querySelector(`#${N}`)}if(A){const N=pn(A);if(["listbox","grid","tree","menu","dialog"].includes(N))return e}}}catch{}const h=["data-role","data-widget","data-control","data-component","data-type"];for(const T of h){const x=n.getAttribute(T);if(x){const E=x.toLowerCase().trim(),A={dropdownlist:e,dropdown:e,combobox:e,select:e,listbox:"listbox",datepicker:i,calendar:s,colorpicker:a};if(A[E])return A[E]}}let p="";try{p=typeof SVGAnimatedString<"u"&&n.className instanceof SVGAnimatedString?n.className.baseVal:n.className}catch{}const y=String(p||"")+" "+(n.id||"");if(y.trim()&&yA.test(y))return bA.test(y)?i:vA.test(y)?a:SA.test(y)?s:wA.test(y)?"listbox":e;const m=n.tagName.toLowerCase(),v=n.parentElement;if(v)try{const T=pn(v);if(m==="li"){if(["menu","menubar"].includes(T))return"menuitem";if(T==="tablist")return"tab";if(["listbox","grid","tree"].includes(T))return"option"}if(m==="th")return"columnheader"}catch{}if(m==="a")return n.hasAttribute("href")?"link":"button";if(m==="select")return n.multiple||(+n.size||0)>1?"listbox":e;if(m==="input"&&n.hasAttribute("list"))return e;const S={article:"article",aside:"complementary",button:"button",details:"group",summary:"button",dialog:"dialog",dl:"list",dt:"listitem",dd:"listitem",figure:"figure",footer:"contentinfo",form:"form",h1:"heading",h2:"heading",h3:"heading",h4:"heading",h5:"heading",h6:"heading",header:"banner",hr:"separator",img:"img",main:"main",menu:"list",meter:"meter",nav:"navigation",ol:"list",ul:"list",li:"listitem",output:"status",progress:"progressbar",section:"region",table:"table",tbody:"rowgroup",thead:"rowgroup",tfoot:"rowgroup",td:"cell",textarea:"textbox",tr:"row"};if(S[m])return S[m];if(m==="input")switch((n.getAttribute("type")||"text").toLowerCase()){case"button":case"submit":case"reset":case"image":return"button";case"checkbox":return"checkbox";case"radio":return"radio";case"range":return"slider";case"search":return"searchbox";case"date":case"datetime-local":case"month":case"week":case"time":return i;case"color":return a;default:return"textbox"}return null}finally{Th.delete(n)}}function kr(n){if(!(n instanceof Element))return null;try{if(window.getComputedAccessibleNode){const c=window.getComputedAccessibleNode(n);if(c&&c.name)return c.name.trim()}}catch{}const e=n.getAttribute("aria-labelledby");if(e)try{const c=e.split(" ").map(f=>document.getElementById(f)).filter(Boolean);if(c.length>0)return c.map(f=>f.textContent).join(" ").trim()}catch{}const i=n.getAttribute("aria-label");if(i)return i.trim();if(n.labels&&n.labels.length>0)return Array.from(n.labels).map(c=>c.textContent).join(" ").trim();const s=n.getAttribute("placeholder");if(s)return s.trim();if(n.tagName.toLowerCase()==="img"){const c=n.getAttribute("alt");if(c)return c.trim()}const a=ms(n);if(a)return a;const o=n.getAttribute("title");return o?o.trim():null}function ms(n){if(!n||n.nodeType!==Node.ELEMENT_NODE||Xd.has(n.tagName.toLowerCase()))return"";let e="";for(const i of n.childNodes)if(i.nodeType===Node.TEXT_NODE){const s=i.textContent.trim();s&&(e+=(e?" ":"")+s.replace(/\s+/g," "))}return e}function xA(n,e={}){var o;const i=c=>{try{return getComputedStyle(c)}catch{return null}},s=c=>c&&c.pointerEvents!=="none",a=c=>c&&c.visibility!=="hidden"&&(parseFloat(c.opacity||"1")>0||c.pointerEvents==="none");try{if(!(n instanceof Element))return!1;let c=!0;if(typeof n.checkVisibility=="function")try{c=n.checkVisibility({contentVisibilityAuto:!0,opacityProperty:!0,visibilityProperty:!0})}catch{}if(!c)return!1;const f=i(n);if(!f||f.display==="none"||f.visibility==="hidden"||parseFloat(f.opacity||"1")===0||f.pointerEvents==="none"||n.disabled||n.inert)return!1;const h=n.getBoundingClientRect();if(h.width<=0||h.height<=0||h.bottom<0||h.top>innerHeight||h.right<0||h.left>innerWidth)return!1;const p=Math.min(7,Math.max(3,Math.round(Math.sqrt(h.width*h.height/1600)))),y=Math.max(1,Math.ceil(p*p*(e.minRatio??.15)));let m=0,v=0;const S=(o=n.getRootNode)==null?void 0:o.call(n),T=(x,E)=>{for(const A of[S,n.ownerDocument,document])try{if(A&&typeof A.elementsFromPoint=="function"){const N=A.elementsFromPoint(x,E);if(N!=null&&N.length)return N}}catch{}return[]};for(let x=0;x<p;x++){const E=h.top+h.height*(x+.5)/p;if(!(E<0||E>innerHeight))for(let A=0;A<p;A++){const N=h.left+h.width*(A+.5)/p;if(N<0||N>innerWidth)continue;v++;const B=T(N,E);if(!B.length)continue;const V=B.find($=>{const z=i($);return s(z)&&a(z)});if(V&&(V===n||n.contains(V))&&(m++,m>=y))return!0}}return!1}catch(c){return console.warn("isTopInteractiveElement - error:",c),!1}}function kn(n){if(!n)return!1;try{return document.querySelectorAll(n).length===1}catch{return!1}}function EA(n){let e=2166136261;for(let i=0;i<n.length;i++)e^=n.charCodeAt(i),e=Math.imul(e,16777619);return(e>>>0).toString(16)}function Gv(n,e={}){var v,S,T;if(!(n instanceof Element))return{priority:[],locator:{selector:"N/A",source:"Invalid element"}};const i={},s=[],a=new Set,o=(x,E)=>{const A=x.split("_").pop(),N=x.includes("chained")||x.includes("filtered");a.has(A)&&!N||(i[x]=E,s.includes(x)||s.push(x),N||a.add(A))},c={},f=["data-testid","data-test-id","data-test","data-qa"];for(const x of f){const E=n.getAttribute(x);if(E){c.getByTestId={details:{testId:E},isUnique:kn(`[${x}="${CSS.escape(E)}"]`)};break}}const h=pn(n),p=kr(n);if(h&&p){const x=Xv(h).filter(E=>kr(E)===p);c.getByRole={details:{role:h,name:p},isUnique:x.length===1}}const y=ms(n);if(y&&(c.getByText={details:{text:y,exact:!0},isUnique:Fv(y).length===1}),(v=c.getByTestId)!=null&&v.isUnique&&o("getByTestId",c.getByTestId.details),(S=c.getByRole)!=null&&S.isUnique)o("getByRole",c.getByRole.details);else if(c.getByRole){const x=Yb(n);x&&o("filtered_getByRole",{base:{strategy:"getByRole",details:c.getByRole.details},filter:x});const E=Fb(n);E&&o("chained_getByRole",{anchor:{strategy:E.strategy,details:E.details},target:{strategy:"getByRole",details:c.getByRole.details}}),o("getByRole",c.getByRole.details)}if((T=c.getByText)!=null&&T.isUnique)o("getByText",c.getByText.details);else if(c.getByText){const x=Yb(n);x&&o("filtered_getByText",{base:{strategy:"getByText",details:c.getByText.details},filter:x});const E=Fb(n);E&&o("chained_getByText",{anchor:{strategy:E.strategy,details:E.details},target:{strategy:"getByText",details:c.getByText.details}}),o("getByText",c.getByText.details)}const m=n.getAttribute("placeholder");m&&kn(`[placeholder="${CSS.escape(m)}"]`)&&o("getByPlaceholder",{placeholder:m});try{const x=Kv(n,e.forceUnique);o("getByCss",{css:x})}catch(x){console.error("Failed to generate CSS",x)}try{const x=TA(n);o("getByXpath",{xpath:x})}catch(x){console.error("Failed to generate XPath",x)}return i.priority=s,i.locator={selector:s[0]||"N/A",source:`Best locator strategy: ${s[0]||"none found"}`},i}function Kv(n,e=!0){if(!(n instanceof Element))throw new Error("Invalid element provided.");const i=["data-testid","data-test-id","data-qa","data-test"];for(const o of i){const c=n.getAttribute(o);if(c){const f=`[${o}="${CSS.escape(c)}"]`;if(kn(f))return f}}if(n.id){const o=`#${CSS.escape(n.id)}`;if(kn(o))return o}if(!e){const o=(n.className||"").trim().split(/\s+/).filter(Boolean);o.length>0&&`${o.map(c=>CSS.escape(c)).join(".")}`}let s=[],a=n;for(;a&&a.nodeType===Node.ELEMENT_NODE;){let o=a.tagName.toLowerCase();if(a.id){const f=`#${CSS.escape(a.id)}`;if(kn(f))return s.unshift(f),s.join(" > ").replace(/\s*>>>\s*/g," >>> ")}if(a.parentElement){const h=Array.from(a.parentElement.children).filter(p=>p.tagName===a.tagName);if(h.length>1){const p=h.indexOf(a)+1;o+=`:nth-of-type(${p})`}}s.unshift(o);const c=a.parentElement;if(!c&&a.getRootNode()instanceof ShadowRoot){s.unshift(Kv(a.getRootNode().host,!0)+" >>> ");break}a=c}return s.join(" > ").replace(/\s*>>>\s*/g," >>> ")}function TA(n){if(!(n instanceof Element))return"/html";if(n.id&&kn(`#${CSS.escape(n.id)}`))return`//*[@id='${n.id}']`;const e=[];let i=n;for(;i&&i.nodeType===Node.ELEMENT_NODE;){if(!i.parentElement){const f=i.getRootNode();if(f instanceof ShadowRoot){i=f.host;continue}break}const a=i.tagName.toLowerCase();let o=1;for(let f=i.previousElementSibling;f;f=f.previousElementSibling)f.tagName===i.tagName&&o++;const c=Array.prototype.some.call(i.parentElement.children,f=>f!==i&&f.tagName===i.tagName);e.unshift(c||o>1?`${a}[${o}]`:a),i=i.parentElement}e.unshift("");const s="/"+e.join("/");return s.startsWith("/html")?s:"/html"+s}function Xv(n){if(!n)return[];const e=[],i=document.createTreeWalker(document.body,NodeFilter.SHOW_ELEMENT);for(;i.nextNode();){const s=i.currentNode;if(pn(s)===n)try{const o=window.getComputedStyle(s);o.display!=="none"&&o.visibility!=="hidden"&&parseFloat(o.opacity)>0&&e.push(s)}catch{}}return e}function Fv(n){if(!n)return[];const e=[],i=document.createTreeWalker(document.body,NodeFilter.SHOW_ELEMENT);for(;i.nextNode();){const s=i.currentNode;if(!Xd.has(s.tagName.toLowerCase())&&ms(s)===n)try{const a=window.getComputedStyle(s);a.display!=="none"&&a.visibility!=="hidden"&&parseFloat(a.opacity)>0&&(e.includes(s)||e.push(s))}catch{}}return e}function Fb(n){let e=n.parentElement,i=0;for(;e&&e!==document.body&&i<5;){const s=["data-testid","data-test-id","data-test","data-qa"];for(const h of s){const p=e.getAttribute(h);if(p&&kn(`[${h}="${CSS.escape(p)}"]`))return{anchor:e,strategy:"getByTestId",details:{testId:p}}}const a=e.getAttribute("id");if(a&&!a.startsWith("react-select-")&&kn(`#${CSS.escape(a)}`))return{anchor:e,strategy:"getByCss",details:{css:`#${CSS.escape(a)}`}};const o=pn(e),c=kr(e);if(o&&new Set(["form","main","navigation","banner","contentinfo","region","search","article","dialog"]).has(o)&&c&&Xv(o).filter(y=>kr(y)===c).length===1)return{anchor:e,strategy:"getByRole",details:{role:o,name:c}};e=e.parentElement,i++}return null}function Yb(n){const e=ms(n),i=Array.from(n.querySelectorAll("span, div, p, strong, em, b"));for(const a of i){const o=ms(a);if(o&&o!==e&&Fv(o).length===1)return{strategy:"getByText",details:{text:o,exact:!0}}}const s=Array.from(n.querySelectorAll("i, svg"));for(const a of s){const o=a.getAttribute("title");if(o&&kn(`[title="${CSS.escape(o)}"]`))return{strategy:"getByTitle",details:{title:o}};if(a.className&&typeof a.className=="string"){const c=a.className.split(" ").find(f=>f.includes("icon")&&kn(`.${f}`));if(c)return{strategy:"getByCss",details:{css:`.${c}`}}}}return null}try{window.__serializerReady=!0;const n={ts:Date.now(),href:location.href};document.dispatchEvent(new CustomEvent("serializer:ready",{detail:n})),console.debug("[SER] domSerializer ready",n)}catch(n){console.error("[SER] failed to flag readiness",n)}function Yv(n,e,i){if(!n||typeof n!="object")return;const s=n;if(typeof s.id=="string"&&!i.has(s.id)&&(i.add(s.id),e.push(s.id)),!!Array.isArray(s.children))for(const a of s.children)Yv(a,e,i)}function _A(n){if(!n||typeof n!="object")return{};const e={};for(const[i,s]of Object.entries(n))typeof i!="string"||!i||!s||typeof s!="object"||(e[i]=s);return e}function AA(n){const e=Vv(n),i=e.dom&&typeof e.dom=="object"?e.dom:{},s=_A(e.locators),a=[];Yv(i,a,new Set);const c=[],f=new Set;for(const h of[...a,...Object.keys(s)])f.has(h)||(f.add(h),c.push(h));return{dom:i,stableIds:c,idOrder:a,locatorPlans:s}}const Qb=":host{font-size:13px;font-family:system-ui,Ubuntu,Droid Sans,sans-serif;color:#333}svg{position:absolute;height:0}x-pw-tooltip{-webkit-backdrop-filter:blur(5px);backdrop-filter:blur(5px);background-color:#fff;border-radius:6px;box-shadow:0 .5rem 1.2rem #0000004d;display:none;font-size:12.8px;font-weight:400;left:0;line-height:1.5;max-width:600px;position:absolute;top:0;padding:0;flex-direction:column;overflow:hidden}x-pw-tooltip-line{display:flex;max-width:600px;padding:6px;-webkit-user-select:none;user-select:none;cursor:pointer}x-pw-tooltip-footer{display:flex;max-width:600px;padding:6px;-webkit-user-select:none;user-select:none;color:#777}x-pw-dialog{background-color:#fff;pointer-events:auto;border-radius:6px;box-shadow:0 .5rem 1.2rem #0000004d;display:flex;flex-direction:column;position:absolute;z-index:10;font-size:13px}x-pw-dialog:not(.autosize){width:400px;height:150px}x-pw-dialog-body{display:flex;flex-direction:column;flex:auto}x-pw-dialog-body label{margin:5px 8px;display:flex;flex-direction:row;align-items:center}x-pw-highlight{position:absolute;top:0;left:0;width:0;height:0}x-pw-action-point{position:absolute;width:20px;height:20px;background:red;border-radius:10px;margin:-10px 0 0 -10px;z-index:2}x-pw-separator{height:1px;margin:6px 9px;background:#949494e5}x-pw-tool-gripper{height:28px;width:24px;margin:2px 0;cursor:grab}x-pw-tool-gripper:active{cursor:grabbing}x-pw-tool-gripper>x-div{width:16px;height:16px;margin:6px 4px;clip-path:url(#icon-gripper);background-color:#555}x-pw-tools-list>label{display:flex;align-items:center;margin:0 10px;-webkit-user-select:none;user-select:none}x-pw-tools-list{display:flex;width:100%;border-bottom:1px solid #dddddd}x-pw-tool-item{pointer-events:auto;height:28px;width:28px;border-radius:3px}x-pw-tool-item:not(.disabled){cursor:pointer}x-pw-tool-item:not(.disabled):hover{background-color:#dbdbdb}x-pw-tool-item.toggled{background-color:#8acae480}x-pw-tool-item.toggled:not(.disabled):hover{background-color:#8acae4c4}x-pw-tool-item>x-div{width:16px;height:16px;margin:6px;background-color:#3a3a3a}x-pw-tool-item.disabled>x-div{background-color:#61616180;cursor:default}x-pw-tool-item.record.toggled{background-color:transparent}x-pw-tool-item.record.toggled:not(.disabled):hover{background-color:#dbdbdb}x-pw-tool-item.record.toggled>x-div{background-color:#a1260d}x-pw-tool-item.record.disabled.toggled>x-div{opacity:.8}x-pw-tool-item.accept>x-div{background-color:#388a34}x-pw-tool-item.record>x-div{clip-path:url(#icon-circle-large-filled)}x-pw-tool-item.record.toggled>x-div{clip-path:url(#icon-stop-circle)}x-pw-tool-item.pick-locator>x-div{clip-path:url(#icon-inspect)}x-pw-tool-item.text>x-div{clip-path:url(#icon-whole-word)}x-pw-tool-item.visibility>x-div{clip-path:url(#icon-eye)}x-pw-tool-item.value>x-div{clip-path:url(#icon-symbol-constant)}x-pw-tool-item.snapshot>x-div{clip-path:url(#icon-gist)}x-pw-tool-item.accept>x-div{clip-path:url(#icon-check)}x-pw-tool-item.cancel>x-div{clip-path:url(#icon-close)}x-pw-tool-item.succeeded>x-div{clip-path:url(#icon-pass);background-color:#388a34!important}x-pw-overlay{position:absolute;top:0;max-width:min-content;z-index:2147483647;background:transparent;pointer-events:auto}x-pw-overlay x-pw-tools-list{background-color:#fffd;box-shadow:#0000001a 0 5px 5px;border-radius:3px;border-bottom:none}x-pw-overlay x-pw-tool-item{margin:2px}textarea.text-editor{font-family:system-ui,Ubuntu,Droid Sans,sans-serif;flex:auto;border:none;margin:6px 10px;color:#333;outline:1px solid transparent!important;resize:none;padding:0;font-size:13px}textarea.text-editor.does-not-match{outline:1px solid red!important}x-div{display:block}x-spacer{flex:auto}*{box-sizing:border-box}*[hidden]{display:none!important}x-locator-editor{flex:none;width:100%;height:60px;padding:4px;border-bottom:1px solid #dddddd;outline:1px solid transparent}x-locator-editor.does-not-match{outline:1px solid red}.CodeMirror{width:100%!important;height:100%!important}x-pw-action-list{flex:auto;display:flex;flex-direction:column;-webkit-user-select:none;user-select:none}x-pw-action-item{padding:6px 10px;cursor:pointer;overflow:hidden}x-pw-action-item:hover{background-color:#f2f2f2}x-pw-action-item:last-child{border-bottom-left-radius:6px;border-bottom-right-radius:6px}";class _h{constructor(e){this._renderedEntries=[],this._language="javascript",this._injectedScript=e;const i=e.document;if(this._isUnderTest=e.isUnderTest,this._glassPaneElement=i.createElement("x-pw-glass"),this._glassPaneElement.setAttribute("popover","manual"),this._glassPaneElement.style.inset="0",this._glassPaneElement.style.width="100%",this._glassPaneElement.style.height="100%",this._glassPaneElement.style.maxWidth="none",this._glassPaneElement.style.maxHeight="none",this._glassPaneElement.style.padding="0",this._glassPaneElement.style.margin="0",this._glassPaneElement.style.border="none",this._glassPaneElement.style.overflow="visible",this._glassPaneElement.style.pointerEvents="none",this._glassPaneElement.style.display="flex",this._glassPaneElement.style.backgroundColor="transparent",this._actionPointElement=i.createElement("x-pw-action-point"),this._actionPointElement.setAttribute("hidden","true"),this._glassPaneShadow=this._glassPaneElement.attachShadow({mode:this._isUnderTest?"open":"closed"}),typeof this._glassPaneShadow.adoptedStyleSheets.push=="function"){const s=new this._injectedScript.window.CSSStyleSheet;s.replaceSync(Qb),this._glassPaneShadow.adoptedStyleSheets.push(s)}else{const s=this._injectedScript.document.createElement("style");s.textContent=Qb,this._glassPaneShadow.appendChild(s)}this._glassPaneShadow.appendChild(this._actionPointElement)}install(){this._injectedScript.document.documentElement&&((!this._injectedScript.document.documentElement.contains(this._glassPaneElement)||this._glassPaneElement.nextElementSibling)&&this._injectedScript.document.documentElement.appendChild(this._glassPaneElement),this._bringToFront())}_bringToFront(){this._glassPaneElement.hidePopover(),this._glassPaneElement.showPopover()}setLanguage(e){this._language=e}runHighlightOnRaf(e){this._rafRequest&&this._injectedScript.utils.builtins.cancelAnimationFrame(this._rafRequest);const i=this._injectedScript.querySelectorAll(e,this._injectedScript.document.documentElement),s=Li(this._language,Nn(e)),a=i.length>1?"#f6b26b7f":"#6fa8dc7f";this.updateHighlight(i.map((o,c)=>{const f=i.length>1?` [${c+1} of ${i.length}]`:"";return{element:o,color:a,tooltipText:s+f}})),this._rafRequest=this._injectedScript.utils.builtins.requestAnimationFrame(()=>this.runHighlightOnRaf(e))}uninstall(){this._rafRequest&&this._injectedScript.utils.builtins.cancelAnimationFrame(this._rafRequest),this._glassPaneElement.remove()}showActionPoint(e,i){this._actionPointElement.style.top=i+"px",this._actionPointElement.style.left=e+"px",this._actionPointElement.hidden=!1}hideActionPoint(){this._actionPointElement.hidden=!0}clearHighlight(){var e,i;for(const s of this._renderedEntries)(e=s.highlightElement)==null||e.remove(),(i=s.tooltipElement)==null||i.remove();this._renderedEntries=[]}maskElements(e,i){this.updateHighlight(e.map(s=>({element:s,color:i})))}updateHighlight(e){if(!this._highlightIsUpToDate(e)){this.clearHighlight();for(const i of e){const s=this._createHighlightElement();this._glassPaneShadow.appendChild(s);let a;if(i.tooltipText){a=this._injectedScript.document.createElement("x-pw-tooltip"),this._glassPaneShadow.appendChild(a),a.style.top="0",a.style.left="0",a.style.display="flex";const o=this._injectedScript.document.createElement("x-pw-tooltip-line");o.textContent=i.tooltipText,a.appendChild(o)}this._renderedEntries.push({targetElement:i.element,color:i.color,tooltipElement:a,highlightElement:s})}for(const i of this._renderedEntries){if(i.box=i.targetElement.getBoundingClientRect(),!i.tooltipElement)continue;const{anchorLeft:s,anchorTop:a}=this.tooltipPosition(i.box,i.tooltipElement);i.tooltipTop=a,i.tooltipLeft=s}for(const i of this._renderedEntries){i.tooltipElement&&(i.tooltipElement.style.top=i.tooltipTop+"px",i.tooltipElement.style.left=i.tooltipLeft+"px");const s=i.box;i.highlightElement.style.backgroundColor=i.color,i.highlightElement.style.left=s.x+"px",i.highlightElement.style.top=s.y+"px",i.highlightElement.style.width=s.width+"px",i.highlightElement.style.height=s.height+"px",i.highlightElement.style.display="block",this._isUnderTest&&console.error("Highlight box for test: "+JSON.stringify({x:s.x,y:s.y,width:s.width,height:s.height}))}}}firstBox(){var e;return(e=this._renderedEntries[0])==null?void 0:e.box}firstTooltipBox(){const e=this._renderedEntries[0];if(!(!e||!e.tooltipElement||e.tooltipLeft===void 0||e.tooltipTop===void 0))return{x:e.tooltipLeft,y:e.tooltipTop,left:e.tooltipLeft,top:e.tooltipTop,width:e.tooltipElement.offsetWidth,height:e.tooltipElement.offsetHeight,bottom:e.tooltipTop+e.tooltipElement.offsetHeight,right:e.tooltipLeft+e.tooltipElement.offsetWidth,toJSON:()=>{}}}tooltipPosition(e,i){const s=i.offsetWidth,a=i.offsetHeight,o=this._glassPaneElement.offsetWidth,c=this._glassPaneElement.offsetHeight;let f=Math.max(5,e.left);f+s>o-5&&(f=o-s-5);let h=Math.max(0,e.bottom)+5;return h+a>c-5&&(Math.max(0,e.top)>a+5?h=Math.max(0,e.top)-a-5:h=c-5-a),{anchorLeft:f,anchorTop:h}}_highlightIsUpToDate(e){if(e.length!==this._renderedEntries.length)return!1;for(let i=0;i<this._renderedEntries.length;++i){if(e[i].element!==this._renderedEntries[i].targetElement||e[i].color!==this._renderedEntries[i].color)return!1;const s=this._renderedEntries[i].box;if(!s)return!1;const a=e[i].element.getBoundingClientRect();if(a.top!==s.top||a.right!==s.right||a.bottom!==s.bottom||a.left!==s.left)return!1}return!0}_createHighlightElement(){return this._injectedScript.document.createElement("x-pw-highlight")}appendChild(e){this._glassPaneShadow.appendChild(e)}onGlassPaneClick(e){this._glassPaneElement.style.pointerEvents="auto",this._glassPaneElement.style.backgroundColor="rgba(0, 0, 0, 0.3)",this._glassPaneElement.addEventListener("click",e)}offGlassPaneClick(e){this._glassPaneElement.style.pointerEvents="none",this._glassPaneElement.style.backgroundColor="transparent",this._glassPaneElement.removeEventListener("click",e)}}function CA(n,e,i){const s=n.left-e.right;if(!(s<0||i!==void 0&&s>i))return s+Math.max(e.bottom-n.bottom,0)+Math.max(n.top-e.top,0)}function NA(n,e,i){const s=e.left-n.right;if(!(s<0||i!==void 0&&s>i))return s+Math.max(e.bottom-n.bottom,0)+Math.max(n.top-e.top,0)}function kA(n,e,i){const s=e.top-n.bottom;if(!(s<0||i!==void 0&&s>i))return s+Math.max(n.left-e.left,0)+Math.max(e.right-n.right,0)}function MA(n,e,i){const s=n.top-e.bottom;if(!(s<0||i!==void 0&&s>i))return s+Math.max(n.left-e.left,0)+Math.max(e.right-n.right,0)}function OA(n,e,i){const s=i===void 0?50:i;let a=0;return n.left-e.right>=0&&(a+=n.left-e.right),e.left-n.right>=0&&(a+=e.left-n.right),e.top-n.bottom>=0&&(a+=e.top-n.bottom),n.top-e.bottom>=0&&(a+=n.top-e.bottom),a>s?void 0:a}const LA=["left-of","right-of","above","below","near"];function Qv(n,e,i,s){const a=e.getBoundingClientRect(),o={"left-of":NA,"right-of":CA,above:kA,below:MA,near:OA}[n];let c;for(const f of i){if(f===e)continue;const h=o(a,f.getBoundingClientRect(),s);h!==void 0&&(c===void 0||h<c)&&(c=h)}return c}function jA(n,e){const i=typeof n=="string"&&!e.caseSensitive?n.toUpperCase():n,s=typeof e.value=="string"&&!e.caseSensitive?e.value.toUpperCase():e.value;return e.op==="<truthy>"?!!i:e.op==="="?s instanceof RegExp?typeof i=="string"&&!!i.match(s):i===s:typeof i!="string"||typeof s!="string"?!1:e.op==="*="?i.includes(s):e.op==="^="?i.startsWith(s):e.op==="$="?i.endsWith(s):e.op==="|="?i===s||i.startsWith(s+"-"):e.op==="~="?i.split(" ").includes(s):!1}function Fd(n){const e=n.ownerDocument;return n.nodeName==="SCRIPT"||n.nodeName==="NOSCRIPT"||n.nodeName==="STYLE"||e.head&&e.head.contains(n)}function qt(n,e){let i=n.get(e);if(i===void 0){if(i={full:"",normalized:"",immediate:[]},!Fd(e)){let s="";if(e instanceof HTMLInputElement&&(e.type==="submit"||e.type==="button"))i={full:e.value,normalized:Nt(e.value),immediate:[e.value]};else{for(let a=e.firstChild;a;a=a.nextSibling)if(a.nodeType===Node.TEXT_NODE)i.full+=a.nodeValue||"",s+=a.nodeValue||"";else{if(a.nodeType===Node.COMMENT_NODE)continue;s&&i.immediate.push(s),s="",a.nodeType===Node.ELEMENT_NODE&&(i.full+=qt(n,a).full)}s&&i.immediate.push(s),e.shadowRoot&&(i.full+=qt(n,e.shadowRoot).full),i.full&&(i.normalized=Nt(i.full))}}n.set(e,i)}return i}function Lc(n,e,i){if(Fd(e)||!i(qt(n,e)))return"none";for(let s=e.firstChild;s;s=s.nextSibling)if(s.nodeType===Node.ELEMENT_NODE&&i(qt(n,s)))return"selfAndChildren";return e.shadowRoot&&i(qt(n,e.shadowRoot))?"selfAndChildren":"self"}function Pv(n,e){const i=Cv(e);if(i)return i.map(o=>qt(n,o));const s=e.getAttribute("aria-label");if(s!==null&&s.trim())return[{full:s,normalized:Nt(s),immediate:[s]}];const a=e.nodeName==="INPUT"&&e.type!=="hidden";if(["BUTTON","METER","OUTPUT","PROGRESS","SELECT","TEXTAREA"].includes(e.nodeName)||a){const o=e.labels;if(o)return[...o].map(c=>qt(n,c))}return[]}const Jv=["selected","checked","pressed","expanded","level","disabled","name","include-hidden"];Jv.sort();function qa(n,e,i){if(!e.includes(i))throw new Error(`"${n}" attribute is only supported for roles: ${e.slice().sort().map(s=>`"${s}"`).join(", ")}`)}function ur(n,e){if(n.op!=="<truthy>"&&!e.includes(n.value))throw new Error(`"${n.name}" must be one of ${e.map(i=>JSON.stringify(i)).join(", ")}`)}function fr(n,e){if(!e.includes(n.op))throw new Error(`"${n.name}" does not support "${n.op}" matcher`)}function RA(n,e){const i={role:e};for(const s of n)switch(s.name){case"checked":{qa(s.name,Od,e),ur(s,[!0,!1,"mixed"]),fr(s,["<truthy>","="]),i.checked=s.op==="<truthy>"?!0:s.value;break}case"pressed":{qa(s.name,jd,e),ur(s,[!0,!1,"mixed"]),fr(s,["<truthy>","="]),i.pressed=s.op==="<truthy>"?!0:s.value;break}case"selected":{qa(s.name,Md,e),ur(s,[!0,!1]),fr(s,["<truthy>","="]),i.selected=s.op==="<truthy>"?!0:s.value;break}case"expanded":{qa(s.name,Rd,e),ur(s,[!0,!1]),fr(s,["<truthy>","="]),i.expanded=s.op==="<truthy>"?!0:s.value;break}case"level":{if(qa(s.name,Dd,e),typeof s.value=="string"&&(s.value=+s.value),s.op!=="="||typeof s.value!="number"||Number.isNaN(s.value))throw new Error('"level" attribute must be compared to a number');i.level=s.value;break}case"disabled":{ur(s,[!0,!1]),fr(s,["<truthy>","="]),i.disabled=s.op==="<truthy>"?!0:s.value;break}case"name":{if(s.op==="<truthy>")throw new Error('"name" attribute must have a value');if(typeof s.value!="string"&&!(s.value instanceof RegExp))throw new Error('"name" attribute must be a string or a regular expression');i.name=s.value,i.nameOp=s.op,i.exact=s.caseSensitive;break}case"include-hidden":{ur(s,[!0,!1]),fr(s,["<truthy>","="]),i.includeHidden=s.op==="<truthy>"?!0:s.value;break}default:throw new Error(`Unknown attribute "${s.name}", must be one of ${Jv.map(a=>`"${a}"`).join(", ")}.`)}return i}function DA(n,e,i){const s=[],a=c=>{if(bt(c)===e.role&&!(e.selected!==void 0&&Nv(c)!==e.selected)&&!(e.checked!==void 0&&kv(c)!==e.checked)&&!(e.pressed!==void 0&&Mv(c)!==e.pressed)&&!(e.expanded!==void 0&&Ov(c)!==e.expanded)&&!(e.level!==void 0&&Lv(c)!==e.level)&&!(e.disabled!==void 0&&vc(c)!==e.disabled)&&!(!e.includeHidden&&un(c))){if(e.name!==void 0){const f=Nt(ul(c,!!e.includeHidden));if(typeof e.name=="string"&&(e.name=Nt(e.name)),i&&!e.exact&&e.nameOp==="="&&(e.nameOp="*="),!jA(f,{op:e.nameOp||"=",value:e.name,caseSensitive:!!e.exact}))return}s.push(c)}},o=c=>{const f=[];c.shadowRoot&&f.push(c.shadowRoot);for(const h of c.querySelectorAll("*"))a(h),h.shadowRoot&&f.push(h.shadowRoot);f.forEach(o)};return o(n),s}function Pb(n){return{queryAll:(e,i)=>{const s=Za(i),a=s.name.toLowerCase();if(!a)throw new Error("Role must not be empty");const o=RA(s.attributes,a);Mc();try{return DA(e,o,n)}finally{Oc()}}}}class BA{constructor(){this._retainCacheCounter=0,this._cacheText=new Map,this._cacheQueryCSS=new Map,this._cacheMatches=new Map,this._cacheQuery=new Map,this._cacheMatchesSimple=new Map,this._cacheMatchesParents=new Map,this._cacheCallMatches=new Map,this._cacheCallQuery=new Map,this._cacheQuerySimple=new Map,this._engines=new Map,this._engines.set("not",HA),this._engines.set("is",Fa),this._engines.set("where",Fa),this._engines.set("has",zA),this._engines.set("scope",UA),this._engines.set("light",qA),this._engines.set("visible",IA),this._engines.set("text",$A),this._engines.set("text-is",VA),this._engines.set("text-matches",GA),this._engines.set("has-text",KA),this._engines.set("right-of",Ia("right-of")),this._engines.set("left-of",Ia("left-of")),this._engines.set("above",Ia("above")),this._engines.set("below",Ia("below")),this._engines.set("near",Ia("near")),this._engines.set("nth-match",XA);const e=[...this._engines.keys()];e.sort();const i=[...Q0];if(i.sort(),e.join("|")!==i.join("|"))throw new Error(`Please keep customCSSNames in sync with evaluator engines: ${e.join("|")} vs ${i.join("|")}`)}begin(){++this._retainCacheCounter}end(){--this._retainCacheCounter,this._retainCacheCounter||(this._cacheQueryCSS.clear(),this._cacheMatches.clear(),this._cacheQuery.clear(),this._cacheMatchesSimple.clear(),this._cacheMatchesParents.clear(),this._cacheCallMatches.clear(),this._cacheCallQuery.clear(),this._cacheQuerySimple.clear(),this._cacheText.clear())}_cached(e,i,s,a){e.has(i)||e.set(i,[]);const o=e.get(i),c=o.find(h=>s.every((p,y)=>h.rest[y]===p));if(c)return c.result;const f=a();return o.push({rest:s,result:f}),f}_checkSelector(e){if(!(typeof e=="object"&&e&&(Array.isArray(e)||"simples"in e&&e.simples.length)))throw new Error(`Malformed selector "${e}"`);return e}matches(e,i,s){const a=this._checkSelector(i);this.begin();try{return this._cached(this._cacheMatches,e,[a,s.scope,s.pierceShadow,s.originalScope],()=>Array.isArray(a)?this._matchesEngine(Fa,e,a,s):(this._hasScopeClause(a)&&(s=this._expandContextForScopeMatching(s)),this._matchesSimple(e,a.simples[a.simples.length-1].selector,s)?this._matchesParents(e,a,a.simples.length-2,s):!1))}finally{this.end()}}query(e,i){const s=this._checkSelector(i);this.begin();try{return this._cached(this._cacheQuery,s,[e.scope,e.pierceShadow,e.originalScope],()=>{if(Array.isArray(s))return this._queryEngine(Fa,e,s);this._hasScopeClause(s)&&(e=this._expandContextForScopeMatching(e));const a=this._scoreMap;this._scoreMap=new Map;let o=this._querySimple(e,s.simples[s.simples.length-1].selector);return o=o.filter(c=>this._matchesParents(c,s,s.simples.length-2,e)),this._scoreMap.size&&o.sort((c,f)=>{const h=this._scoreMap.get(c),p=this._scoreMap.get(f);return h===p?0:h===void 0?1:p===void 0?-1:h-p}),this._scoreMap=a,o})}finally{this.end()}}_markScore(e,i){this._scoreMap&&this._scoreMap.set(e,i)}_hasScopeClause(e){return e.simples.some(i=>i.selector.functions.some(s=>s.name==="scope"))}_expandContextForScopeMatching(e){if(e.scope.nodeType!==1)return e;const i=St(e.scope);return i?{...e,scope:i,originalScope:e.originalScope||e.scope}:e}_matchesSimple(e,i,s){return this._cached(this._cacheMatchesSimple,e,[i,s.scope,s.pierceShadow,s.originalScope],()=>{if(e===s.scope||i.css&&!this._matchesCSS(e,i.css))return!1;for(const a of i.functions)if(!this._matchesEngine(this._getEngine(a.name),e,a.args,s))return!1;return!0})}_querySimple(e,i){return i.functions.length?this._cached(this._cacheQuerySimple,i,[e.scope,e.pierceShadow,e.originalScope],()=>{let s=i.css;const a=i.functions;s==="*"&&a.length&&(s=void 0);let o,c=-1;s!==void 0?o=this._queryCSS(e,s):(c=a.findIndex(f=>this._getEngine(f.name).query!==void 0),c===-1&&(c=0),o=this._queryEngine(this._getEngine(a[c].name),e,a[c].args));for(let f=0;f<a.length;f++){if(f===c)continue;const h=this._getEngine(a[f].name);h.matches!==void 0&&(o=o.filter(p=>this._matchesEngine(h,p,a[f].args,e)))}for(let f=0;f<a.length;f++){if(f===c)continue;const h=this._getEngine(a[f].name);h.matches===void 0&&(o=o.filter(p=>this._matchesEngine(h,p,a[f].args,e)))}return o}):this._queryCSS(e,i.css||"*")}_matchesParents(e,i,s,a){return s<0?!0:this._cached(this._cacheMatchesParents,e,[i,s,a.scope,a.pierceShadow,a.originalScope],()=>{const{selector:o,combinator:c}=i.simples[s];if(c===">"){const f=Io(e,a);return!f||!this._matchesSimple(f,o,a)?!1:this._matchesParents(f,i,s-1,a)}if(c==="+"){const f=Ah(e,a);return!f||!this._matchesSimple(f,o,a)?!1:this._matchesParents(f,i,s-1,a)}if(c===""){let f=Io(e,a);for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="")break}f=Io(f,a)}return!1}if(c==="~"){let f=Ah(e,a);for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="~")break}f=Ah(f,a)}return!1}if(c===">="){let f=e;for(;f;){if(this._matchesSimple(f,o,a)){if(this._matchesParents(f,i,s-1,a))return!0;if(i.simples[s-1].combinator==="")break}f=Io(f,a)}return!1}throw new Error(`Unsupported combinator "${c}"`)})}_matchesEngine(e,i,s,a){if(e.matches)return this._callMatches(e,i,s,a);if(e.query)return this._callQuery(e,s,a).includes(i);throw new Error('Selector engine should implement "matches" or "query"')}_queryEngine(e,i,s){if(e.query)return this._callQuery(e,s,i);if(e.matches)return this._queryCSS(i,"*").filter(a=>this._callMatches(e,a,s,i));throw new Error('Selector engine should implement "matches" or "query"')}_callMatches(e,i,s,a){return this._cached(this._cacheCallMatches,i,[e,a.scope,a.pierceShadow,a.originalScope,...s],()=>e.matches(i,s,a,this))}_callQuery(e,i,s){return this._cached(this._cacheCallQuery,e,[s.scope,s.pierceShadow,s.originalScope,...i],()=>e.query(s,i,this))}_matchesCSS(e,i){return e.matches(i)}_queryCSS(e,i){return this._cached(this._cacheQueryCSS,i,[e.scope,e.pierceShadow,e.originalScope],()=>{let s=[];function a(o){if(s=s.concat([...o.querySelectorAll(i)]),!!e.pierceShadow){o.shadowRoot&&a(o.shadowRoot);for(const c of o.querySelectorAll("*"))c.shadowRoot&&a(c.shadowRoot)}}return a(e.scope),s})}_getEngine(e){const i=this._engines.get(e);if(!i)throw new Error(`Unknown selector engine "${e}"`);return i}}const Fa={matches(n,e,i,s){if(e.length===0)throw new Error('"is" engine expects non-empty selector list');return e.some(a=>s.matches(n,a,i))},query(n,e,i){if(e.length===0)throw new Error('"is" engine expects non-empty selector list');let s=[];for(const a of e)s=s.concat(i.query(n,a));return e.length===1?s:Zv(s)}},zA={matches(n,e,i,s){if(e.length===0)throw new Error('"has" engine expects non-empty selector list');return s.query({...i,scope:n},e).length>0}},UA={matches(n,e,i,s){if(e.length!==0)throw new Error('"scope" engine expects no arguments');const a=i.originalScope||i.scope;return a.nodeType===9?n===a.documentElement:n===a},query(n,e,i){if(e.length!==0)throw new Error('"scope" engine expects no arguments');const s=n.originalScope||n.scope;if(s.nodeType===9){const a=s.documentElement;return a?[a]:[]}return s.nodeType===1?[s]:[]}},HA={matches(n,e,i,s){if(e.length===0)throw new Error('"not" engine expects non-empty selector list');return!s.matches(n,e,i)}},qA={query(n,e,i){return i.query({...n,pierceShadow:!1},e)},matches(n,e,i,s){return s.matches(n,e,{...i,pierceShadow:!1})}},IA={matches(n,e,i,s){if(e.length)throw new Error('"visible" engine expects no arguments');return ji(n)}},$A={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"text" engine expects a single string');const a=Nt(e[0]).toLowerCase(),o=c=>c.normalized.toLowerCase().includes(a);return Lc(s._cacheText,n,o)==="self"}},VA={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"text-is" engine expects a single string');const a=Nt(e[0]),o=c=>!a&&!c.immediate.length?!0:c.immediate.some(f=>Nt(f)===a);return Lc(s._cacheText,n,o)!=="none"}},GA={matches(n,e,i,s){if(e.length===0||typeof e[0]!="string"||e.length>2||e.length===2&&typeof e[1]!="string")throw new Error('"text-matches" engine expects a regexp body and optional regexp flags');const a=new RegExp(e[0],e.length===2?e[1]:void 0),o=c=>a.test(c.full);return Lc(s._cacheText,n,o)==="self"}},KA={matches(n,e,i,s){if(e.length!==1||typeof e[0]!="string")throw new Error('"has-text" engine expects a single string');if(Fd(n))return!1;const a=Nt(e[0]).toLowerCase();return(c=>c.normalized.toLowerCase().includes(a))(qt(s._cacheText,n))}};function Ia(n){return{matches(e,i,s,a){const o=i.length&&typeof i[i.length-1]=="number"?i[i.length-1]:void 0,c=o===void 0?i:i.slice(0,i.length-1);if(i.length<1+(o===void 0?0:1))throw new Error(`"${n}" engine expects a selector list and optional maximum distance in pixels`);const f=a.query(s,c),h=Qv(n,e,f,o);return h===void 0?!1:(a._markScore(e,h),!0)}}}const XA={query(n,e,i){let s=e[e.length-1];if(e.length<2)throw new Error('"nth-match" engine expects non-empty selector list and an index argument');if(typeof s!="number"||s<1)throw new Error('"nth-match" engine expects a one-based index as the last argument');const a=Fa.query(n,e.slice(0,e.length-1),i);return s--,s<a.length?[a[s]]:[]}};function Io(n,e){if(n!==e.scope)return e.pierceShadow?St(n):n.parentElement||void 0}function Ah(n,e){if(n!==e.scope)return n.previousElementSibling||void 0}function Zv(n){const e=new Map,i=[],s=[];function a(c){let f=e.get(c);if(f)return f;const h=St(c);return h?a(h).children.push(c):i.push(c),f={children:[],taken:!1},e.set(c,f),f}for(const c of n)a(c).taken=!0;function o(c){const f=e.get(c);if(f.taken&&s.push(c),f.children.length>1){const h=new Set(f.children);f.children=[];let p=c.firstElementChild;for(;p&&f.children.length<h.size;)h.has(p)&&f.children.push(p),p=p.nextElementSibling;for(p=c.shadowRoot?c.shadowRoot.firstElementChild:null;p&&f.children.length<h.size;)h.has(p)&&f.children.push(p),p=p.nextElementSibling}f.children.forEach(o)}return i.forEach(o),s}const Wv=10,Br=Wv/2,Jb=1,FA=2,YA=10,QA=50,eS=100,tS=120,nS=140,iS=160,ic=180,sS=200,Zb=250,PA=tS+Br,JA=nS+Br,ZA=eS+Br,WA=iS+Br,eC=ic+Br,tC=sS+Br,nC=300,iC=500,rS=510,Ch=520,aS=530,ed=1e4,sC=1e7,rC=1e3;function Wb(n,e,i){n._evaluator.begin();const s={allowText:new Map,disallowText:new Map};Mc(),Cd();try{let a=[];if(i.forTextExpect){let f=Ya(n,e.ownerDocument.documentElement,i);for(let h=e;h;h=St(h)){const p=ls(s,n,h,{...i,noText:!0});if(!p)continue;if(os(p)<=rC){f=p;break}}a=[sc(f)]}else{if(!e.matches("input,textarea,select")&&!e.isContentEditable){const f=Xa(e,"button,select,input,[role=button],[role=checkbox],[role=radio],a,[role=link]",i.root);f&&ji(f)&&(e=f)}if(i.multiple){const f=ls(s,n,e,i),h=ls(s,n,e,{...i,noText:!0});let p=[f,h];if(s.allowText.clear(),s.disallowText.clear(),f&&Nh(f)&&p.push(ls(s,n,e,{...i,noCSSId:!0})),h&&Nh(h)&&p.push(ls(s,n,e,{...i,noText:!0,noCSSId:!0})),p=p.filter(Boolean),!p.length){const y=Ya(n,e,i);p.push(y),Nh(y)&&p.push(Ya(n,e,{...i,noCSSId:!0}))}a=[...new Set(p.map(y=>sc(y)))]}else{const f=ls(s,n,e,i)||Ya(n,e,i);a=[sc(f)]}}const o=a[0],c=n.parseSelector(o);return{selector:o,selectors:a,elements:n.querySelectorAll(c,i.root??e.ownerDocument)}}finally{Nd(),Oc(),n._evaluator.end()}}function ls(n,e,i,s){if(s.root&&!Yh(s.root,i))throw new Error("Target element must belong to the root's subtree");if(i===s.root)return[{engine:"css",selector:":scope",score:1}];if(i.ownerDocument.documentElement===i)return[{engine:"css",selector:"html",score:1}];let a=null;const o=f=>{(!a||os(f)<os(a))&&(a=f)},c=[];if(!s.noText)for(const f of lC(e,i,!s.isRecursive))c.push({candidate:f,isTextCandidate:!0});for(const f of aC(e,i,s))s.omitInternalEngines&&f.engine.startsWith("internal:")||c.push({candidate:[f],isTextCandidate:!1});c.sort((f,h)=>os(f.candidate)-os(h.candidate));for(const{candidate:f,isTextCandidate:h}of c){const p=e.querySelectorAll(e.parseSelector(sc(f)),s.root??i.ownerDocument);if(!p.includes(i))continue;if(p.length===1){o(f);break}const y=p.indexOf(i);if(!(y>5)&&(o([...f,{engine:"nth",selector:String(y),score:ed}]),!s.isRecursive))for(let m=St(i);m&&m!==s.root;m=St(m)){const v=p.filter(B=>Yh(m,B)&&B!==m),S=v.indexOf(i);if(v.length>5||S===-1||S===y&&v.length>1)continue;const T=v.length===1?f:[...f,{engine:"nth",selector:String(S),score:ed}];if(a&&os([{engine:"",selector:"",score:1},...T])>=os(a))continue;const E=!!s.noText||h,A=E?n.disallowText:n.allowText;let N=A.get(m);N===void 0&&(N=ls(n,e,m,{...s,isRecursive:!0,noText:E})||Ya(e,m,s),A.set(m,N)),N&&o([...N,...T])}}return a}function aC(n,e,i){const s=[];{for(const c of["data-testid","data-test-id","data-test"])c!==i.testIdAttributeName&&e.getAttribute(c)&&s.push({engine:"css",selector:`[${c}=${mr(e.getAttribute(c))}]`,score:FA});if(!i.noCSSId){const c=e.getAttribute("id");c&&!oC(c)&&s.push({engine:"css",selector:lS(c),score:iC})}s.push({engine:"css",selector:ei(e),score:aS})}if(e.nodeName==="IFRAME"){for(const c of["name","title"])e.getAttribute(c)&&s.push({engine:"css",selector:`${ei(e)}[${c}=${mr(e.getAttribute(c))}]`,score:YA});return e.getAttribute(i.testIdAttributeName)&&s.push({engine:"css",selector:`[${i.testIdAttributeName}=${mr(e.getAttribute(i.testIdAttributeName))}]`,score:Jb}),td([s]),s}if(e.getAttribute(i.testIdAttributeName)&&s.push({engine:"internal:testid",selector:`[${i.testIdAttributeName}=${Ct(e.getAttribute(i.testIdAttributeName),!0)}]`,score:Jb}),e.nodeName==="INPUT"||e.nodeName==="TEXTAREA"){const c=e;if(c.placeholder){s.push({engine:"internal:attr",selector:`[placeholder=${Ct(c.placeholder,!0)}]`,score:PA});for(const f of vr(c.placeholder))s.push({engine:"internal:attr",selector:`[placeholder=${Ct(f.text,!1)}]`,score:tS-f.scoreBonus})}}const a=Pv(n._evaluator._cacheText,e);for(const c of a){const f=c.normalized;s.push({engine:"internal:label",selector:Ut(f,!0),score:JA});for(const h of vr(f))s.push({engine:"internal:label",selector:Ut(h.text,!1),score:nS-h.scoreBonus})}const o=bt(e);return o&&!["none","presentation"].includes(o)&&s.push({engine:"internal:role",selector:o,score:rS}),e.getAttribute("name")&&["BUTTON","FORM","FIELDSET","FRAME","IFRAME","INPUT","KEYGEN","OBJECT","OUTPUT","SELECT","TEXTAREA","MAP","META","PARAM"].includes(e.nodeName)&&s.push({engine:"css",selector:`${ei(e)}[name=${mr(e.getAttribute("name"))}]`,score:Ch}),["INPUT","TEXTAREA"].includes(e.nodeName)&&e.getAttribute("type")!=="hidden"&&e.getAttribute("type")&&s.push({engine:"css",selector:`${ei(e)}[type=${mr(e.getAttribute("type"))}]`,score:Ch}),["INPUT","TEXTAREA","SELECT"].includes(e.nodeName)&&e.getAttribute("type")!=="hidden"&&s.push({engine:"css",selector:ei(e),score:Ch+1}),td([s]),s}function lC(n,e,i){if(e.nodeName==="SELECT")return[];const s=[],a=e.getAttribute("title");if(a){s.push([{engine:"internal:attr",selector:`[title=${Ct(a,!0)}]`,score:tC}]);for(const p of vr(a))s.push([{engine:"internal:attr",selector:`[title=${Ct(p.text,!1)}]`,score:sS-p.scoreBonus}])}const o=e.getAttribute("alt");if(o&&["APPLET","AREA","IMG","INPUT"].includes(e.nodeName)){s.push([{engine:"internal:attr",selector:`[alt=${Ct(o,!0)}]`,score:WA}]);for(const p of vr(o))s.push([{engine:"internal:attr",selector:`[alt=${Ct(p.text,!1)}]`,score:iS-p.scoreBonus}])}const c=qt(n._evaluator._cacheText,e).normalized,f=c?vr(c):[];if(c){if(i){c.length<=80&&s.push([{engine:"internal:text",selector:Ut(c,!0),score:eC}]);for(const y of f)s.push([{engine:"internal:text",selector:Ut(y.text,!1),score:ic-y.scoreBonus}])}const p={engine:"css",selector:ei(e),score:aS};for(const y of f)s.push([p,{engine:"internal:has-text",selector:Ut(y.text,!1),score:ic-y.scoreBonus}]);if(i&&c.length<=80){const y=new RegExp("^"+pc(c)+"$");s.push([p,{engine:"internal:has-text",selector:Ut(y,!1),score:Zb}])}}const h=bt(e);if(h&&!["none","presentation"].includes(h)){const p=ul(e,!1);if(p&&!p.match(new RegExp("^\\p{Co}+$","u"))){const y={engine:"internal:role",selector:`${h}[name=${Ct(p,!0)}]`,score:ZA};s.push([y]);for(const m of vr(p))s.push([{engine:"internal:role",selector:`${h}[name=${Ct(m.text,!1)}]`,score:eS-m.scoreBonus}])}else{const y={engine:"internal:role",selector:`${h}`,score:rS};for(const m of f)s.push([y,{engine:"internal:has-text",selector:Ut(m.text,!1),score:ic-m.scoreBonus}]);if(i&&c.length<=80){const m=new RegExp("^"+pc(c)+"$");s.push([y,{engine:"internal:has-text",selector:Ut(m,!1),score:Zb}])}}}return td(s),s}function lS(n){return/^[a-zA-Z][a-zA-Z0-9\-\_]+$/.test(n)?"#"+n:`[id=${mr(n)}]`}function Nh(n){return n.some(e=>e.engine==="css"&&(e.selector.startsWith("#")||e.selector.startsWith('[id="')))}function Ya(n,e,i){const s=i.root??e.ownerDocument,a=[];function o(f){const h=a.slice();f&&h.unshift(f);const p=h.join(" > "),y=n.parseSelector(p);return n.querySelector(y,s,!1)===e?p:void 0}function c(f){const h={engine:"css",selector:f,score:sC},p=n.parseSelector(f),y=n.querySelectorAll(p,s);if(y.length===1)return[h];const m={engine:"nth",selector:String(y.indexOf(e)),score:ed};return[h,m]}for(let f=e;f&&f!==s;f=St(f)){let h="";if(f.id&&!i.noCSSId){const m=lS(f.id),v=o(m);if(v)return c(v);h=m}const p=f.parentNode,y=[...f.classList].map(cC);for(let m=0;m<y.length;++m){const v="."+y.slice(0,m+1).join("."),S=o(v);if(S)return c(S);!h&&p&&p.querySelectorAll(v).length===1&&(h=v)}if(p){const m=[...p.children],v=f.nodeName,T=m.filter(E=>E.nodeName===v).indexOf(f)===0?ei(f):`${ei(f)}:nth-child(${1+m.indexOf(f)})`,x=o(T);if(x)return c(x);h||(h=T)}else h||(h=ei(f));a.unshift(h)}return c(o())}function td(n){for(const e of n)for(const i of e)i.score>QA&&i.score<nC&&(i.score+=Math.min(Wv,i.selector.length/10|0))}function sc(n){const e=[];let i="";for(const{engine:s,selector:a}of n)e.length&&(i!=="css"||s!=="css"||a.startsWith(":nth-match("))&&e.push(">>"),i=s,s==="css"?e.push(a):e.push(`${s}=${a}`);return e.join(" ")}function os(n){let e=0;for(let i=0;i<n.length;i++)e+=n[i].score*(n.length-i);return e}function oC(n){let e,i=0;for(let s=0;s<n.length;++s){const a=n[s];let o;if(!(a==="-"||a==="_")){if(a>="a"&&a<="z"?o="lower":a>="A"&&a<="Z"?o="upper":a>="0"&&a<="9"?o="digit":o="other",o==="lower"&&e==="upper"){e=o;continue}e&&e!==o&&++i,e=o}}return i>=n.length/4}function $o(n,e){if(n.length<=e)return n;n=n.substring(0,e);const i=n.match(/^(.*)\b(.+?)$/);return i?i[1].trimEnd():""}function vr(n){let e=[];{const i=n.match(/^([\d.,]+)[^.,\w]/),s=i?i[1].length:0;if(s){const a=$o(n.substring(s).trimStart(),80);e.push({text:a,scoreBonus:a.length<=30?2:1})}}{const i=n.match(/[^.,\w]([\d.,]+)$/),s=i?i[1].length:0;if(s){const a=$o(n.substring(0,n.length-s).trimEnd(),80);e.push({text:a,scoreBonus:a.length<=30?2:1})}}return n.length<=30?e.push({text:n,scoreBonus:0}):(e.push({text:$o(n,80),scoreBonus:0}),e.push({text:$o(n,30),scoreBonus:1})),e=e.filter(i=>i.text),e.length||e.push({text:n.substring(0,80),scoreBonus:0}),e}function ei(n){return n.nodeName.toLocaleLowerCase().replace(/[:\.]/g,e=>"\\"+e)}function cC(n){let e="";for(let i=0;i<n.length;i++)e+=uC(n,i);return e}function uC(n,e){const i=n.charCodeAt(e);return i===0?"�":i>=1&&i<=31||i>=48&&i<=57&&(e===0||e===1&&n.charCodeAt(0)===45)?"\\"+i.toString(16)+" ":e===0&&i===45&&n.length===1?"\\"+n.charAt(e):i>=128||i===45||i===95||i>=48&&i<=57||i>=65&&i<=90||i>=97&&i<=122?n.charAt(e):"\\"+n.charAt(e)}const e0={queryAll(n,e){e.startsWith("/")&&n.nodeType!==Node.DOCUMENT_NODE&&(e="."+e);const i=[],s=n.ownerDocument||n;if(!s)return i;const a=s.evaluate(e,n,null,XPathResult.ORDERED_NODE_ITERATOR_TYPE);for(let o=a.iterateNext();o;o=a.iterateNext())o.nodeType===Node.ELEMENT_NODE&&i.push(o);return i}};function Yd(n,e,i){return`internal:attr=[${n}=${Ct(e,(i==null?void 0:i.exact)||!1)}]`}function fC(n,e){return`internal:testid=[${n}=${Ct(e,!0)}]`}function hC(n,e){return"internal:label="+Ut(n,!!(e!=null&&e.exact))}function dC(n,e){return Yd("alt",n,e)}function pC(n,e){return Yd("title",n,e)}function gC(n,e){return Yd("placeholder",n,e)}function mC(n,e){return"internal:text="+Ut(n,!!(e!=null&&e.exact))}function yC(n,e={}){const i=[];return e.checked!==void 0&&i.push(["checked",String(e.checked)]),e.disabled!==void 0&&i.push(["disabled",String(e.disabled)]),e.selected!==void 0&&i.push(["selected",String(e.selected)]),e.expanded!==void 0&&i.push(["expanded",String(e.expanded)]),e.includeHidden!==void 0&&i.push(["include-hidden",String(e.includeHidden)]),e.level!==void 0&&i.push(["level",String(e.level)]),e.name!==void 0&&i.push(["name",Ct(e.name,!!e.exact)]),e.pressed!==void 0&&i.push(["pressed",String(e.pressed)]),`internal:role=${n}${i.map(([s,a])=>`[${s}=${a}]`).join("")}`}const $a=Symbol("selector"),bC=class Qa{constructor(e,i,s){if(s!=null&&s.hasText&&(i+=` >> internal:has-text=${Ut(s.hasText,!1)}`),s!=null&&s.hasNotText&&(i+=` >> internal:has-not-text=${Ut(s.hasNotText,!1)}`),s!=null&&s.has&&(i+=" >> internal:has="+JSON.stringify(s.has[$a])),s!=null&&s.hasNot&&(i+=" >> internal:has-not="+JSON.stringify(s.hasNot[$a])),(s==null?void 0:s.visible)!==void 0&&(i+=` >> visible=${s.visible?"true":"false"}`),this[$a]=i,i){const c=e.parseSelector(i);this.element=e.querySelector(c,e.document,!1),this.elements=e.querySelectorAll(c,e.document)}const a=i,o=this;o.locator=(c,f)=>new Qa(e,a?a+" >> "+c:c,f),o.getByTestId=c=>o.locator(fC(e.testIdAttributeNameForStrictErrorAndConsoleCodegen(),c)),o.getByAltText=(c,f)=>o.locator(dC(c,f)),o.getByLabel=(c,f)=>o.locator(hC(c,f)),o.getByPlaceholder=(c,f)=>o.locator(gC(c,f)),o.getByText=(c,f)=>o.locator(mC(c,f)),o.getByTitle=(c,f)=>o.locator(pC(c,f)),o.getByRole=(c,f={})=>o.locator(yC(c,f)),o.filter=c=>new Qa(e,i,c),o.first=()=>o.locator("nth=0"),o.last=()=>o.locator("nth=-1"),o.nth=c=>o.locator(`nth=${c}`),o.and=c=>new Qa(e,a+" >> internal:and="+JSON.stringify(c[$a])),o.or=c=>new Qa(e,a+" >> internal:or="+JSON.stringify(c[$a]))}};let vC=bC;class SC{constructor(e){this._injectedScript=e}install(){this._injectedScript.window.playwright||(this._injectedScript.window.playwright={$:(e,i)=>this._querySelector(e,!!i),$$:e=>this._querySelectorAll(e),inspect:e=>this._inspect(e),selector:e=>this._selector(e),generateLocator:(e,i)=>this._generateLocator(e,i),ariaSnapshot:(e,i)=>this._injectedScript.ariaSnapshot(e||this._injectedScript.document.body,i||{mode:"expect"}),resume:()=>this._resume(),...new vC(this._injectedScript,"")},delete this._injectedScript.window.playwright.filter,delete this._injectedScript.window.playwright.first,delete this._injectedScript.window.playwright.last,delete this._injectedScript.window.playwright.nth,delete this._injectedScript.window.playwright.and,delete this._injectedScript.window.playwright.or)}_querySelector(e,i){if(typeof e!="string")throw new Error("Usage: playwright.query('Playwright >> selector').");const s=this._injectedScript.parseSelector(e);return this._injectedScript.querySelector(s,this._injectedScript.document,i)}_querySelectorAll(e){if(typeof e!="string")throw new Error("Usage: playwright.$$('Playwright >> selector').");const i=this._injectedScript.parseSelector(e);return this._injectedScript.querySelectorAll(i,this._injectedScript.document)}_inspect(e){if(typeof e!="string")throw new Error("Usage: playwright.inspect('Playwright >> selector').");this._injectedScript.window.inspect(this._querySelector(e,!1))}_selector(e){if(!(e instanceof Element))throw new Error("Usage: playwright.selector(element).");return this._injectedScript.generateSelectorSimple(e)}_generateLocator(e,i){if(!(e instanceof Element))throw new Error("Usage: playwright.locator(element).");const s=this._injectedScript.generateSelectorSimple(e);return Li(i||"javascript",s)}_resume(){if(!this._injectedScript.window.__pw_resume)return!1;this._injectedScript.window.__pw_resume().catch(()=>{})}}function wC(n){try{return n instanceof RegExp||Object.prototype.toString.call(n)==="[object RegExp]"}catch{return!1}}function xC(n){try{return n instanceof Date||Object.prototype.toString.call(n)==="[object Date]"}catch{return!1}}function EC(n){try{return n instanceof URL||Object.prototype.toString.call(n)==="[object URL]"}catch{return!1}}function TC(n){var e;try{return n instanceof Error||n&&((e=Object.getPrototypeOf(n))==null?void 0:e.name)==="Error"}catch{return!1}}function _C(n,e){try{return n instanceof e||Object.prototype.toString.call(n)===`[object ${e.name}]`}catch{return!1}}function AC(n){try{return n instanceof ArrayBuffer||Object.prototype.toString.call(n)==="[object ArrayBuffer]"}catch{return!1}}const oS={i8:Int8Array,ui8:Uint8Array,ui8c:Uint8ClampedArray,i16:Int16Array,ui16:Uint16Array,i32:Int32Array,ui32:Uint32Array,f32:Float32Array,f64:Float64Array,bi64:BigInt64Array,bui64:BigUint64Array};function t0(n){if("toBase64"in n)return n.toBase64();const e=Array.from(new Uint8Array(n.buffer,n.byteOffset,n.byteLength)).map(i=>String.fromCharCode(i)).join("");return btoa(e)}function n0(n,e){const i=atob(n),s=new Uint8Array(i.length);for(let a=0;a<i.length;a++)s[a]=i.charCodeAt(a);return new e(s.buffer)}function nd(n,e=[],i=new Map){if(!Object.is(n,void 0)){if(typeof n=="object"&&n){if("ref"in n)return i.get(n.ref);if("v"in n)return n.v==="undefined"?void 0:n.v==="null"?null:n.v==="NaN"?NaN:n.v==="Infinity"?1/0:n.v==="-Infinity"?-1/0:n.v==="-0"?-0:void 0;if("d"in n)return new Date(n.d);if("u"in n)return new URL(n.u);if("bi"in n)return BigInt(n.bi);if("e"in n){const s=new Error(n.e.m);return s.name=n.e.n,s.stack=n.e.s,s}if("r"in n)return new RegExp(n.r.p,n.r.f);if("a"in n){const s=[];i.set(n.id,s);for(const a of n.a)s.push(nd(a,e,i));return s}if("o"in n){const s={};i.set(n.id,s);for(const{k:a,v:o}of n.o)a!=="__proto__"&&(s[a]=nd(o,e,i));return s}if("h"in n)return e[n.h];if("ta"in n)return n0(n.ta.b,oS[n.ta.k]);if("ab"in n)return n0(n.ab.b,Uint8Array).buffer}return n}}function CC(n,e){return id(n,e,{visited:new Map,lastId:0})}function id(n,e,i){if(n&&typeof n=="object"){if(typeof globalThis.Window=="function"&&n instanceof globalThis.Window)return"ref: <Window>";if(typeof globalThis.Document=="function"&&n instanceof globalThis.Document)return"ref: <Document>";if(typeof globalThis.Node=="function"&&n instanceof globalThis.Node)return"ref: <Node>"}return cS(n,e,i)}function cS(n,e,i){var o;const s=e(n);if("fallThrough"in s)n=s.fallThrough;else return s;if(typeof n=="symbol")return{v:"undefined"};if(Object.is(n,void 0))return{v:"undefined"};if(Object.is(n,null))return{v:"null"};if(Object.is(n,NaN))return{v:"NaN"};if(Object.is(n,1/0))return{v:"Infinity"};if(Object.is(n,-1/0))return{v:"-Infinity"};if(Object.is(n,-0))return{v:"-0"};if(typeof n=="boolean"||typeof n=="number"||typeof n=="string")return n;if(typeof n=="bigint")return{bi:n.toString()};if(TC(n)){let c;return(o=n.stack)!=null&&o.startsWith(n.name+": "+n.message)?c=n.stack:c=`${n.name}: ${n.message}
|
|
116
|
+
${n.stack}`,{e:{n:n.name,m:n.message,s:c}}}if(xC(n))return{d:n.toJSON()};if(EC(n))return{u:n.toJSON()};if(wC(n))return{r:{p:n.source,f:n.flags}};for(const[c,f]of Object.entries(oS))if(_C(n,f))return{ta:{b:t0(n),k:c}};if(AC(n))return{ab:{b:t0(new Uint8Array(n))}};const a=i.visited.get(n);if(a)return{ref:a};if(Array.isArray(n)){const c=[],f=++i.lastId;i.visited.set(n,f);for(let h=0;h<n.length;++h)c.push(id(n[h],e,i));return{a:c,id:f}}if(typeof n=="object"){const c=[],f=++i.lastId;i.visited.set(n,f);for(const p of Object.keys(n)){let y;try{y=n[p]}catch{continue}p==="toJSON"&&typeof y=="function"?c.push({k:p,v:{o:[],id:0}}):c.push({k:p,v:id(y,e,i)})}let h;try{c.length===0&&n.toJSON&&typeof n.toJSON=="function"&&(h={value:n.toJSON()})}catch{}return h?cS(h.value,e,i):{o:c,id:f}}}class NC{constructor(e,i){var s,a,o,c,f,h,p,y;this.global=e,this.isUnderTest=i,e.__pwClock?this.builtins=e.__pwClock.builtins:this.builtins={setTimeout:(s=e.setTimeout)==null?void 0:s.bind(e),clearTimeout:(a=e.clearTimeout)==null?void 0:a.bind(e),setInterval:(o=e.setInterval)==null?void 0:o.bind(e),clearInterval:(c=e.clearInterval)==null?void 0:c.bind(e),requestAnimationFrame:(f=e.requestAnimationFrame)==null?void 0:f.bind(e),cancelAnimationFrame:(h=e.cancelAnimationFrame)==null?void 0:h.bind(e),requestIdleCallback:(p=e.requestIdleCallback)==null?void 0:p.bind(e),cancelIdleCallback:(y=e.cancelIdleCallback)==null?void 0:y.bind(e),performance:e.performance,Intl:e.Intl,Date:e.Date,AbortSignal:e.AbortSignal},this.isUnderTest&&(e.builtins=this.builtins)}evaluate(e,i,s,a,...o){const c=o.slice(0,a),f=o.slice(a),h=[];for(let y=0;y<c.length;y++)h[y]=nd(c[y],f);let p=this.global.eval(s);return e===!0?p=p(...h):e===!1?p=p:typeof p=="function"&&(p=p(...h)),i?this._promiseAwareJsonValueNoThrow(p):p}jsonValue(e,i){if(i!==void 0)return CC(i,s=>({fallThrough:s}))}_promiseAwareJsonValueNoThrow(e){const i=s=>{try{return this.jsonValue(!0,s)}catch{return}};return e&&typeof e=="object"&&typeof e.then=="function"?(async()=>{const s=await e;return i(s)})():i(e)}}class uS{constructor(e,i){this._testIdAttributeNameForStrictErrorAndConsoleCodegen="data-testid",this._lastAriaSnapshotForTrack=new Map,this.utils={asLocator:Li,cacheNormalizedWhitespaces:CE,elementText:qt,getAriaRole:bt,getElementAccessibleDescription:Ib,getElementAccessibleName:ul,isElementVisible:ji,isInsideScope:Yh,normalizeWhiteSpace:Nt,parseAriaSnapshot:Ed,generateAriaTree:nl,findNewElement:P_,builtins:null},this.window=e,this.document=e.document,this.isUnderTest=i.isUnderTest,this.utils.builtins=new NC(e,i.isUnderTest).builtins,this._sdkLanguage=i.sdkLanguage,this._testIdAttributeNameForStrictErrorAndConsoleCodegen=i.testIdAttributeName,this._evaluator=new BA,this.consoleApi=new SC(this),this.onGlobalListenersRemoved=new Set,this._autoClosingTags=new Set(["AREA","BASE","BR","COL","COMMAND","EMBED","HR","IMG","INPUT","KEYGEN","LINK","MENUITEM","META","PARAM","SOURCE","TRACK","WBR"]),this._booleanAttributes=new Set(["checked","selected","disabled","readonly","multiple"]),this._eventTypes=new Map([["auxclick","mouse"],["click","mouse"],["dblclick","mouse"],["mousedown","mouse"],["mouseeenter","mouse"],["mouseleave","mouse"],["mousemove","mouse"],["mouseout","mouse"],["mouseover","mouse"],["mouseup","mouse"],["mouseleave","mouse"],["mousewheel","mouse"],["keydown","keyboard"],["keyup","keyboard"],["keypress","keyboard"],["textInput","keyboard"],["touchstart","touch"],["touchmove","touch"],["touchend","touch"],["touchcancel","touch"],["pointerover","pointer"],["pointerout","pointer"],["pointerenter","pointer"],["pointerleave","pointer"],["pointerdown","pointer"],["pointerup","pointer"],["pointermove","pointer"],["pointercancel","pointer"],["gotpointercapture","pointer"],["lostpointercapture","pointer"],["focus","focus"],["blur","focus"],["drag","drag"],["dragstart","drag"],["dragend","drag"],["dragover","drag"],["dragenter","drag"],["dragleave","drag"],["dragexit","drag"],["drop","drag"],["wheel","wheel"],["deviceorientation","deviceorientation"],["deviceorientationabsolute","deviceorientation"],["devicemotion","devicemotion"]]),this._hoverHitTargetInterceptorEvents=new Set(["mousemove"]),this._tapHitTargetInterceptorEvents=new Set(["pointerdown","pointerup","touchstart","touchend","touchcancel"]),this._mouseHitTargetInterceptorEvents=new Set(["mousedown","mouseup","pointerdown","pointerup","click","auxclick","dblclick","contextmenu"]),this._allHitTargetInterceptorEvents=new Set([...this._hoverHitTargetInterceptorEvents,...this._tapHitTargetInterceptorEvents,...this._mouseHitTargetInterceptorEvents]),this._engines=new Map,this._engines.set("xpath",e0),this._engines.set("xpath:light",e0),this._engines.set("role",Pb(!1)),this._engines.set("text",this._createTextEngine(!0,!1)),this._engines.set("text:light",this._createTextEngine(!1,!1)),this._engines.set("id",this._createAttributeEngine("id",!0)),this._engines.set("id:light",this._createAttributeEngine("id",!1)),this._engines.set("data-testid",this._createAttributeEngine("data-testid",!0)),this._engines.set("data-testid:light",this._createAttributeEngine("data-testid",!1)),this._engines.set("data-test-id",this._createAttributeEngine("data-test-id",!0)),this._engines.set("data-test-id:light",this._createAttributeEngine("data-test-id",!1)),this._engines.set("data-test",this._createAttributeEngine("data-test",!0)),this._engines.set("data-test:light",this._createAttributeEngine("data-test",!1)),this._engines.set("css",this._createCSSEngine()),this._engines.set("nth",{queryAll:()=>[]}),this._engines.set("visible",this._createVisibleEngine()),this._engines.set("internal:control",this._createControlEngine()),this._engines.set("internal:has",this._createHasEngine()),this._engines.set("internal:has-not",this._createHasNotEngine()),this._engines.set("internal:and",{queryAll:()=>[]}),this._engines.set("internal:or",{queryAll:()=>[]}),this._engines.set("internal:chain",this._createInternalChainEngine()),this._engines.set("internal:label",this._createInternalLabelEngine()),this._engines.set("internal:text",this._createTextEngine(!0,!0)),this._engines.set("internal:has-text",this._createInternalHasTextEngine()),this._engines.set("internal:has-not-text",this._createInternalHasNotTextEngine()),this._engines.set("internal:attr",this._createNamedAttributeEngine()),this._engines.set("internal:testid",this._createNamedAttributeEngine()),this._engines.set("internal:role",Pb(!0)),this._engines.set("internal:describe",this._createDescribeEngine()),this._engines.set("aria-ref",this._createAriaRefEngine());for(const{name:s,source:a}of i.customEngines)this._engines.set(s,this.eval(a));this._stableRafCount=i.stableRafCount,this._browserName=i.browserName,this._isUtilityWorld=!!i.isUtilityWorld,b_({browserNameForWorkarounds:i.browserName}),this._setupGlobalListenersRemovalDetection(),this._setupHitTargetInterceptors(),this.isUnderTest&&(this.window.__injectedScript=this)}eval(e){return this.window.eval(e)}testIdAttributeNameForStrictErrorAndConsoleCodegen(){return this._testIdAttributeNameForStrictErrorAndConsoleCodegen}parseSelector(e){const i=gl(e);return _E(i,s=>{if(!this._engines.has(s.name))throw this.createStacklessError(`Unknown engine "${s.name}" while parsing selector ${e}`)}),i}generateSelector(e,i){return Wb(this,e,i)}generateSelectorSimple(e,i){return Wb(this,e,{...i,testIdAttributeName:this._testIdAttributeNameForStrictErrorAndConsoleCodegen}).selector}querySelector(e,i,s){const a=this.querySelectorAll(e,i);if(s&&a.length>1)throw this.strictModeViolationError(e,a);return this.checkDeprecatedSelectorUsage(e,a),a[0]}_queryNth(e,i){const s=[...e];let a=+i.body;return a===-1&&(a=s.length-1),new Set(s.slice(a,a+1))}_queryLayoutSelector(e,i,s){const a=i.name,o=i.body,c=[],f=this.querySelectorAll(o.parsed,s);for(const h of e){const p=Qv(a,h,f,o.distance);p!==void 0&&c.push({element:h,score:p})}return c.sort((h,p)=>h.score-p.score),new Set(c.map(h=>h.element))}ariaSnapshot(e,i){return this.incrementalAriaSnapshot(e,i).full}incrementalAriaSnapshot(e,i){if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Can only capture aria snapshot of Element nodes.");const s=nl(e,i),a=il(s,i);let o;if(i.track){const c=this._lastAriaSnapshotForTrack.get(i.track);c&&(o=il(s,i,c)),this._lastAriaSnapshotForTrack.set(i.track,s)}return this._lastAriaSnapshotForQuery=s,{full:a,incremental:o,iframeRefs:s.iframeRefs}}customDomSnapshot(e){if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Can only capture custom DOM snapshot of Element nodes.");return AA(e)}ariaSnapshotForRecorder(){const e=nl(this.document.body,{mode:"ai"});return{ariaSnapshot:il(e,{mode:"ai"}),refs:e.refs}}getAllElementsMatchingExpectAriaTemplate(e,i){return K_(e.documentElement,i)}querySelectorAll(e,i){if(e.capture!==void 0){if(e.parts.some(a=>a.name==="nth"))throw this.createStacklessError("Can't query n-th element in a request with the capture.");const s={parts:e.parts.slice(0,e.capture+1)};if(e.capture<e.parts.length-1){const a={parts:e.parts.slice(e.capture+1)},o={name:"internal:has",body:{parsed:a},source:Nn(a)};s.parts.push(o)}return this.querySelectorAll(s,i)}if(!i.querySelectorAll)throw this.createStacklessError("Node is not queryable.");if(e.capture!==void 0)throw this.createStacklessError("Internal error: there should not be a capture in the selector.");if(i.nodeType===11&&e.parts.length===1&&e.parts[0].name==="css"&&e.parts[0].source===":scope")return[i];this._evaluator.begin();try{let s=new Set([i]);for(const a of e.parts)if(a.name==="nth")s=this._queryNth(s,a);else if(a.name==="internal:and"){const o=this.querySelectorAll(a.body.parsed,i);s=new Set(o.filter(c=>s.has(c)))}else if(a.name==="internal:or"){const o=this.querySelectorAll(a.body.parsed,i);s=new Set(Zv(new Set([...s,...o])))}else if(LA.includes(a.name))s=this._queryLayoutSelector(s,a,i);else{const o=new Set;for(const c of s){const f=this._queryEngineAll(a,c);for(const h of f)o.add(h)}s=o}return[...s]}finally{this._evaluator.end()}}_queryEngineAll(e,i){const s=this._engines.get(e.name).queryAll(i,e.body);for(const a of s)if(!("nodeName"in a))throw this.createStacklessError(`Expected a Node but got ${Object.prototype.toString.call(a)}`);return s}_createAttributeEngine(e,i){const s=a=>[{simples:[{selector:{css:`[${e}=${JSON.stringify(a)}]`,functions:[]},combinator:""}]}];return{queryAll:(a,o)=>this._evaluator.query({scope:a,pierceShadow:i},s(o))}}_createCSSEngine(){return{queryAll:(e,i)=>this._evaluator.query({scope:e,pierceShadow:!0},i)}}_createTextEngine(e,i){return{queryAll:(a,o)=>{const{matcher:c,kind:f}=Go(o,i),h=[];let p=null;const y=v=>{if(f==="lax"&&p&&p.contains(v))return!1;const S=Lc(this._evaluator._cacheText,v,c);S==="none"&&(p=v),(S==="self"||S==="selfAndChildren"&&f==="strict"&&!i)&&h.push(v)};a.nodeType===Node.ELEMENT_NODE&&y(a);const m=this._evaluator._queryCSS({scope:a,pierceShadow:e},"*");for(const v of m)y(v);return h}}}_createInternalHasTextEngine(){return{queryAll:(e,i)=>{if(e.nodeType!==1)return[];const s=e,a=qt(this._evaluator._cacheText,s),{matcher:o}=Go(i,!0);return o(a)?[s]:[]}}}_createInternalHasNotTextEngine(){return{queryAll:(e,i)=>{if(e.nodeType!==1)return[];const s=e,a=qt(this._evaluator._cacheText,s),{matcher:o}=Go(i,!0);return o(a)?[]:[s]}}}_createInternalLabelEngine(){return{queryAll:(e,i)=>{const{matcher:s}=Go(i,!0);return this._evaluator._queryCSS({scope:e,pierceShadow:!0},"*").filter(o=>Pv(this._evaluator._cacheText,o).some(c=>s(c)))}}}_createNamedAttributeEngine(){return{queryAll:(i,s)=>{const a=Za(s);if(a.name||a.attributes.length!==1)throw new Error("Malformed attribute selector: "+s);const{name:o,value:c,caseSensitive:f}=a.attributes[0],h=f?null:c.toLowerCase();let p;return c instanceof RegExp?p=m=>!!m.match(c):f?p=m=>m===c:p=m=>m.toLowerCase().includes(h),this._evaluator._queryCSS({scope:i,pierceShadow:!0},`[${o}]`).filter(m=>p(m.getAttribute(o)))}}}_createDescribeEngine(){return{queryAll:i=>i.nodeType!==1?[]:[i]}}_createControlEngine(){return{queryAll(e,i){if(i==="enter-frame")return[];if(i==="return-empty")return[];if(i==="component")return e.nodeType!==1?[]:[e.childElementCount===1?e.firstElementChild:e];throw new Error(`Internal error, unknown internal:control selector ${i}`)}}}_createHasEngine(){return{queryAll:(i,s)=>i.nodeType!==1?[]:!!this.querySelector(s.parsed,i,!1)?[i]:[]}}_createHasNotEngine(){return{queryAll:(i,s)=>i.nodeType!==1?[]:!!this.querySelector(s.parsed,i,!1)?[]:[i]}}_createVisibleEngine(){return{queryAll:(i,s)=>{if(i.nodeType!==1)return[];const a=s==="true";return ji(i)===a?[i]:[]}}}_createInternalChainEngine(){return{queryAll:(i,s)=>this.querySelectorAll(s.parsed,i)}}extend(e,i){const s=this.window.eval(`
|
|
117
|
+
(() => {
|
|
118
|
+
const module = {};
|
|
119
|
+
${e}
|
|
120
|
+
return module.exports.default();
|
|
121
|
+
})()`);return new s(this,i)}async viewportRatio(e){return await new Promise(i=>{const s=new IntersectionObserver(a=>{i(a[0].intersectionRatio),s.disconnect()});s.observe(e),this.utils.builtins.requestAnimationFrame(()=>{})})}getElementBorderWidth(e){if(e.nodeType!==Node.ELEMENT_NODE||!e.ownerDocument||!e.ownerDocument.defaultView)return{left:0,top:0};const i=e.ownerDocument.defaultView.getComputedStyle(e);return{left:parseInt(i.borderLeftWidth||"",10),top:parseInt(i.borderTopWidth||"",10)}}describeIFrameStyle(e){if(!e.ownerDocument||!e.ownerDocument.defaultView)return"error:notconnected";const i=e.ownerDocument.defaultView;for(let a=e;a;a=St(a))if(i.getComputedStyle(a).transform!=="none")return"transformed";const s=i.getComputedStyle(e);return{left:parseInt(s.borderLeftWidth||"",10)+parseInt(s.paddingLeft||"",10),top:parseInt(s.borderTopWidth||"",10)+parseInt(s.paddingTop||"",10)}}retarget(e,i){let s=e.nodeType===Node.ELEMENT_NODE?e:e.parentElement;if(!s)return null;if(i==="none")return s;if(!s.matches("input, textarea, select")&&!s.isContentEditable&&(i==="button-link"?s=s.closest("button, [role=button], a, [role=link]")||s:s=s.closest("button, [role=button], [role=checkbox], [role=radio]")||s),i==="follow-label"&&!s.matches("a, input, textarea, button, select, [role=link], [role=button], [role=checkbox], [role=radio]")&&!s.isContentEditable){const a=s.closest("label");a&&a.control&&(s=a.control)}return s}async checkElementStates(e,i){if(i.includes("stable")){const s=await this._checkElementIsStable(e);if(s===!1)return{missingState:"stable"};if(s==="error:notconnected")return"error:notconnected"}for(const s of i)if(s!=="stable"){const a=this.elementState(e,s);if(a.received==="error:notconnected")return"error:notconnected";if(!a.matches)return{missingState:s}}}async _checkElementIsStable(e){const i=Symbol("continuePolling");let s,a=0,o=0;const c=()=>{const m=this.retarget(e,"no-follow-label");if(!m)return"error:notconnected";const v=this.utils.builtins.performance.now();if(this._stableRafCount>1&&v-o<15)return i;o=v;const S=m.getBoundingClientRect(),T={x:S.top,y:S.left,width:S.width,height:S.height};if(s){if(!(T.x===s.x&&T.y===s.y&&T.width===s.width&&T.height===s.height))return!1;if(++a>=this._stableRafCount)return!0}return s=T,i};let f,h;const p=new Promise((m,v)=>{f=m,h=v}),y=()=>{try{const m=c();m!==i?f(m):this.utils.builtins.requestAnimationFrame(y)}catch(m){h(m)}};return this.utils.builtins.requestAnimationFrame(y),p}_createAriaRefEngine(){return{queryAll:(i,s)=>{var o,c;const a=(c=(o=this._lastAriaSnapshotForQuery)==null?void 0:o.elements)==null?void 0:c.get(s);return a&&a.isConnected?[a]:[]}}}elementState(e,i){const s=this.retarget(e,["visible","hidden"].includes(i)?"none":"follow-label");if(!s||!s.isConnected)return i==="hidden"?{matches:!0,received:"hidden"}:{matches:!1,received:"error:notconnected"};if(i==="visible"||i==="hidden"){const a=ji(s);return{matches:i==="visible"?a:!a,received:a?"visible":"hidden"}}if(i==="disabled"||i==="enabled"){const a=vc(s);return{matches:i==="disabled"?a:!a,received:a?"disabled":"enabled"}}if(i==="editable"){const a=vc(s),o=j_(s);if(o==="error")throw this.createStacklessError("Element is not an <input>, <textarea>, <select> or [contenteditable] and does not have a role allowing [aria-readonly]");return{matches:!a&&!o,received:a?"disabled":o?"readOnly":"editable"}}if(i==="checked"||i==="unchecked"){const a=i==="checked",o=O_(s);if(o==="error")throw this.createStacklessError("Not a checkbox or radio button");const c=s.nodeName==="INPUT"&&s.type==="radio";return{matches:a===o,received:o?"checked":"unchecked",isRadio:c}}if(i==="indeterminate"){const a=M_(s);if(a==="error")throw this.createStacklessError("Not a checkbox or radio button");return{matches:a==="mixed",received:a===!0?"checked":a===!1?"unchecked":"mixed"}}throw this.createStacklessError(`Unexpected element state "${i}"`)}selectOptions(e,i){const s=this.retarget(e,"follow-label");if(!s)return"error:notconnected";if(s.nodeName.toLowerCase()!=="select")throw this.createStacklessError("Element is not a <select> element");const a=s,o=[...a.options],c=[];let f=i.slice();for(let h=0;h<o.length;h++){const p=o[h],y=m=>{if(m instanceof Node)return p===m;let v=!0;return m.valueOrLabel!==void 0&&(v=v&&(m.valueOrLabel===p.value||m.valueOrLabel===p.label)),m.value!==void 0&&(v=v&&m.value===p.value),m.label!==void 0&&(v=v&&m.label===p.label),m.index!==void 0&&(v=v&&m.index===h),v};if(f.some(y)){if(!this.elementState(p,"enabled").matches)return"error:optionnotenabled";if(c.push(p),a.multiple)f=f.filter(m=>!y(m));else{f=[];break}}}return f.length?"error:optionsnotfound":(a.value=void 0,c.forEach(h=>h.selected=!0),a.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),a.dispatchEvent(new Event("change",{bubbles:!0})),c.map(h=>h.value))}fill(e,i){const s=this.retarget(e,"follow-label");if(!s)return"error:notconnected";if(s.nodeName.toLowerCase()==="input"){const a=s,o=a.type.toLowerCase(),c=new Set(["color","date","time","datetime-local","month","range","week"]);if(!new Set(["","email","number","password","search","tel","text","url"]).has(o)&&!c.has(o))throw this.createStacklessError(`Input of type "${o}" cannot be filled`);if(o==="number"&&(i=i.trim(),isNaN(Number(i))))throw this.createStacklessError("Cannot type text into input[type=number]");if(o==="color"&&(i=i.toLowerCase()),c.has(o)){if(i=i.trim(),a.focus(),a.value=i,a.value!==i)throw this.createStacklessError("Malformed value");return s.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),s.dispatchEvent(new Event("change",{bubbles:!0})),"done"}}else if(s.nodeName.toLowerCase()!=="textarea"){if(!s.isContentEditable)throw this.createStacklessError("Element is not an <input>, <textarea> or [contenteditable] element")}return this.selectText(s),"needsinput"}selectText(e){const i=this.retarget(e,"follow-label");if(!i)return"error:notconnected";if(i.nodeName.toLowerCase()==="input"){const o=i;return o.select(),o.focus(),"done"}if(i.nodeName.toLowerCase()==="textarea"){const o=i;return o.selectionStart=0,o.selectionEnd=o.value.length,o.focus(),"done"}i.focus();const s=i.ownerDocument.createRange();s.selectNodeContents(i);const a=i.ownerDocument.defaultView.getSelection();return a&&(a.removeAllRanges(),a.addRange(s)),"done"}_activelyFocused(e){const i=e.getRootNode().activeElement,s=i===e&&!!e.ownerDocument&&e.ownerDocument.hasFocus();return{activeElement:i,isFocused:s}}focusNode(e,i){if(!e.isConnected)return"error:notconnected";if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Node is not an element");const{activeElement:s,isFocused:a}=this._activelyFocused(e);if(e.isContentEditable&&!a&&s&&s.blur&&s.blur(),e.focus(),e.focus(),i&&!a&&e.nodeName.toLowerCase()==="input")try{e.setSelectionRange(0,0)}catch{}return"done"}blurNode(e){if(!e.isConnected)return"error:notconnected";if(e.nodeType!==Node.ELEMENT_NODE)throw this.createStacklessError("Node is not an element");return e.blur(),"done"}setInputFiles(e,i){if(e.nodeType!==Node.ELEMENT_NODE)return"Node is not of type HTMLElement";const s=e;if(s.nodeName!=="INPUT")return"Not an <input> element";const a=s;if((a.getAttribute("type")||"").toLowerCase()!=="file")return"Not an input[type=file] element";const c=i.map(h=>{const p=Uint8Array.from(atob(h.buffer),y=>y.charCodeAt(0));return new File([p],h.name,{type:h.mimeType,lastModified:h.lastModifiedMs})}),f=new DataTransfer;for(const h of c)f.items.add(h);a.files=f.files,a.dispatchEvent(new Event("input",{bubbles:!0,composed:!0})),a.dispatchEvent(new Event("change",{bubbles:!0}))}expectHitTarget(e,i){const s=[];let a=i;for(;a;){const y=mv(a);if(!y||(s.push(y),y.nodeType===9))break;a=y.host}let o;for(let y=s.length-1;y>=0;y--){const m=s[y],v=m.elementsFromPoint(e.x,e.y),S=m.elementFromPoint(e.x,e.y);if(S&&v[0]&&St(S)===v[0]){const x=this.window.getComputedStyle(S);(x==null?void 0:x.display)==="contents"&&v.unshift(S)}v[0]&&v[0].shadowRoot===m&&v[1]===S&&v.shift();const T=v[0];if(!T||(o=T,y&&T!==s[y-1].host))break}const c=[];for(;o&&o!==i;)c.push(o),o=o.assignedSlot??St(o);if(o===i)return"done";const f=this.previewNode(c[0]||this.document.documentElement);let h,p=i;for(;p;){const y=c.indexOf(p);if(y!==-1){y>1&&(h=this.previewNode(c[y-1]));break}p=St(p)}return h?{hitTargetDescription:`${f} from ${h} subtree`}:{hitTargetDescription:f}}setupHitTargetInterceptor(e,i,s,a){const o=this.retarget(e,"button-link");if(!o||!o.isConnected)return"error:notconnected";if(s){const y=this.expectHitTarget(s,o);if(y!=="done")return y.hitTargetDescription}if(i==="drag")return{stop:()=>"done"};const c={hover:this._hoverHitTargetInterceptorEvents,tap:this._tapHitTargetInterceptorEvents,mouse:this._mouseHitTargetInterceptorEvents}[i];let f;const h=y=>{if(!c.has(y.type)||!y.isTrusted)return;const m=this.window.TouchEvent&&y instanceof this.window.TouchEvent?y.touches[0]:y;f===void 0&&m&&(f=this.expectHitTarget({x:m.clientX,y:m.clientY},o)),(a||f!=="done"&&f!==void 0)&&(y.preventDefault(),y.stopPropagation(),y.stopImmediatePropagation())},p=()=>(this._hitTargetInterceptor===h&&(this._hitTargetInterceptor=void 0),f||"done");return this._hitTargetInterceptor=h,{stop:p}}dispatchEvent(e,i,s){var c,f,h;let a;const o={bubbles:!0,cancelable:!0,composed:!0,...s};switch(this._eventTypes.get(i)){case"mouse":a=new MouseEvent(i,o);break;case"keyboard":a=new KeyboardEvent(i,o);break;case"touch":{if(this._browserName==="webkit"){const p=m=>{var T,x;if(m instanceof Touch)return m;let v=m.pageX;v===void 0&&m.clientX!==void 0&&(v=m.clientX+(((T=this.document.scrollingElement)==null?void 0:T.scrollLeft)||0));let S=m.pageY;return S===void 0&&m.clientY!==void 0&&(S=m.clientY+(((x=this.document.scrollingElement)==null?void 0:x.scrollTop)||0)),this.document.createTouch(this.window,m.target??e,m.identifier,v,S,m.screenX,m.screenY,m.radiusX,m.radiusY,m.rotationAngle,m.force)},y=m=>m instanceof TouchList||!m?m:this.document.createTouchList(...m.map(p));o.target??(o.target=e),o.touches=y(o.touches),o.targetTouches=y(o.targetTouches),o.changedTouches=y(o.changedTouches),a=new TouchEvent(i,o)}else o.target??(o.target=e),o.touches=(c=o.touches)==null?void 0:c.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),o.targetTouches=(f=o.targetTouches)==null?void 0:f.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),o.changedTouches=(h=o.changedTouches)==null?void 0:h.map(p=>p instanceof Touch?p:new Touch({...p,target:p.target??e})),a=new TouchEvent(i,o);break}case"pointer":a=new PointerEvent(i,o);break;case"focus":a=new FocusEvent(i,o);break;case"drag":a=new DragEvent(i,o);break;case"wheel":a=new WheelEvent(i,o);break;case"deviceorientation":try{a=new DeviceOrientationEvent(i,o)}catch{const{bubbles:p,cancelable:y,alpha:m,beta:v,gamma:S,absolute:T}=o;a=this.document.createEvent("DeviceOrientationEvent"),a.initDeviceOrientationEvent(i,p,y,m,v,S,T)}break;case"devicemotion":try{a=new DeviceMotionEvent(i,o)}catch{const{bubbles:p,cancelable:y,acceleration:m,accelerationIncludingGravity:v,rotationRate:S,interval:T}=o;a=this.document.createEvent("DeviceMotionEvent"),a.initDeviceMotionEvent(i,p,y,m,v,S,T)}break;default:a=new Event(i,o);break}e.dispatchEvent(a)}previewNode(e){if(e.nodeType===Node.TEXT_NODE)return Vo(`#text=${e.nodeValue||""}`);if(e.nodeType!==Node.ELEMENT_NODE)return Vo(`<${e.nodeName.toLowerCase()} />`);const i=e,s=[];for(let h=0;h<i.attributes.length;h++){const{name:p,value:y}=i.attributes[h];p!=="style"&&(!y&&this._booleanAttributes.has(p)?s.push(` ${p}`):s.push(` ${p}="${y}"`))}s.sort((h,p)=>h.length-p.length);const a=Tb(s.join(""),500);if(this._autoClosingTags.has(i.nodeName))return Vo(`<${i.nodeName.toLowerCase()}${a}/>`);const o=i.childNodes;let c=!1;if(o.length<=5){c=!0;for(let h=0;h<o.length;h++)c=c&&o[h].nodeType===Node.TEXT_NODE}const f=c?i.textContent||"":o.length?"…":"";return Vo(`<${i.nodeName.toLowerCase()}${a}>${Tb(f,50)}</${i.nodeName.toLowerCase()}>`)}_generateSelectors(e){this._evaluator.begin(),Mc(),Cd();try{const i=this._isUtilityWorld&&this._browserName==="firefox"?2:10;return e.slice(0,i).map(a=>({preview:this.previewNode(a),selector:this.generateSelectorSimple(a)})).map((a,o)=>`${o+1}) ${a.preview} aka ${Li(this._sdkLanguage,a.selector)}`)}finally{Nd(),Oc(),this._evaluator.end()}}strictModeViolationError(e,i){const s=this._generateSelectors(i).map(a=>`
|
|
122
|
+
`+a);return s.length<i.length&&s.push(`
|
|
123
|
+
...`),this.createStacklessError(`strict mode violation: ${Li(this._sdkLanguage,Nn(e))} resolved to ${i.length} elements:${s.join("")}
|
|
124
|
+
`)}checkDeprecatedSelectorUsage(e,i){const s=new Set(["_react","_vue","xpath:light","text:light","id:light","data-testid:light","data-test-id:light","data-test:light"]);if(!i.length)return;const a=e.parts.find(c=>s.has(c.name));if(!a)return;const o=this._generateSelectors(i).map(c=>`
|
|
125
|
+
`+c);throw o.length<i.length&&o.push(`
|
|
126
|
+
...`),this.createStacklessError(`"${a.name}" selector is not supported: ${Li(this._sdkLanguage,Nn(e))} resolved to ${i.length} element${i.length===1?"":"s"}:${o.join("")}
|
|
127
|
+
`)}createStacklessError(e){if(this._browserName==="firefox"){const s=new Error("Error: "+e);return s.stack="",s}const i=new Error(e);return delete i.stack,i}createHighlight(){return new _h(this)}maskSelectors(e,i){this._highlight&&this.hideHighlight(),this._highlight=new _h(this),this._highlight.install();const s=[];for(const a of e)s.push(this.querySelectorAll(a,this.document.documentElement));this._highlight.maskElements(s.flat(),i)}highlight(e){this._highlight||(this._highlight=new _h(this),this._highlight.install()),this._highlight.runHighlightOnRaf(e)}hideHighlight(){this._highlight&&(this._highlight.uninstall(),delete this._highlight)}markTargetElements(e,i){var c,f;((c=this._markedElements)==null?void 0:c.callId)!==i&&(this._markedElements=void 0);const s=((f=this._markedElements)==null?void 0:f.elements)||new Set,a=new CustomEvent("__playwright_unmark_target__",{bubbles:!0,cancelable:!0,detail:i,composed:!0});for(const h of s)e.has(h)||h.dispatchEvent(a);const o=new CustomEvent("__playwright_mark_target__",{bubbles:!0,cancelable:!0,detail:i,composed:!0});for(const h of e)s.has(h)||h.dispatchEvent(o);this._markedElements={callId:i,elements:e}}_setupGlobalListenersRemovalDetection(){const e="__playwright_global_listeners_check__";let i=!1;const s=()=>i=!0;this.window.addEventListener(e,s),new MutationObserver(a=>{if(a.some(c=>Array.from(c.addedNodes).includes(this.document.documentElement))&&(i=!1,this.window.dispatchEvent(new CustomEvent(e)),!i)){this.window.addEventListener(e,s);for(const c of this.onGlobalListenersRemoved)c()}}).observe(this.document,{childList:!0})}_setupHitTargetInterceptors(){const e=s=>{var a;return(a=this._hitTargetInterceptor)==null?void 0:a.call(this,s)},i=()=>{for(const s of this._allHitTargetInterceptorEvents)this.window.addEventListener(s,e,{capture:!0,passive:!1})};i(),this.onGlobalListenersRemoved.add(i)}async expect(e,i,s){var o,c;if(i.expression==="to.have.count"||i.expression.endsWith(".array"))return this.expectArray(s,i);if(!e){if(!i.isNot&&i.expression==="to.be.hidden")return{matches:!0};if(i.isNot&&i.expression==="to.be.visible")return{matches:!1};if(!i.isNot&&i.expression==="to.be.detached")return{matches:!0};if(i.isNot&&i.expression==="to.be.attached")return{matches:!1};if(i.isNot&&i.expression==="to.be.in.viewport")return{matches:!1};if(i.expression==="to.have.title"&&((o=i==null?void 0:i.expectedText)!=null&&o[0])){const f=new hr(i.expectedText[0]),h=this.document.title;return{received:h,matches:f.matches(h)}}if(i.expression==="to.have.url"&&((c=i==null?void 0:i.expectedText)!=null&&c[0])){const f=new hr(i.expectedText[0]),h=this.document.location.href;return{received:h,matches:f.matches(h)}}return{matches:i.isNot,missingReceived:!0}}return await this.expectSingleElement(e,i)}async expectSingleElement(e,i){var a;const s=i.expression;{let o;if(s==="to.have.attribute"){const c=e.hasAttribute(i.expressionArg||"");o={matches:c,received:c?"attribute present":"attribute not present"}}else if(s==="to.be.checked"){const{checked:c,indeterminate:f}=i.expectedValue;if(f){if(c!==void 0)throw this.createStacklessError("Can't assert indeterminate and checked at the same time");o=this.elementState(e,"indeterminate")}else o=this.elementState(e,c===!1?"unchecked":"checked")}else if(s==="to.be.disabled")o=this.elementState(e,"disabled");else if(s==="to.be.editable")o=this.elementState(e,"editable");else if(s==="to.be.readonly")o=this.elementState(e,"editable"),o.matches=!o.matches;else if(s==="to.be.empty")if(e.nodeName==="INPUT"||e.nodeName==="TEXTAREA"){const c=e.value;o={matches:!c,received:c?"notEmpty":"empty"}}else{const c=(a=e.textContent)==null?void 0:a.trim();o={matches:!c,received:c?"notEmpty":"empty"}}else if(s==="to.be.enabled")o=this.elementState(e,"enabled");else if(s==="to.be.focused"){const c=this._activelyFocused(e).isFocused;o={matches:c,received:c?"focused":"inactive"}}else s==="to.be.hidden"?o=this.elementState(e,"hidden"):s==="to.be.visible"?o=this.elementState(e,"visible"):s==="to.be.attached"?o={matches:!0,received:"attached"}:s==="to.be.detached"&&(o={matches:!1,received:"attached"});if(o){if(o.received==="error:notconnected")throw this.createStacklessError("Element is not connected");return o}}if(s==="to.have.property"){let o=e;const c=(i.expressionArg||"").split(".");for(let p=0;p<c.length-1;p++){if(typeof o!="object"||!(c[p]in o))return{received:void 0,matches:!1};o=o[c[p]]}const f=o[c[c.length-1]],h=sd(f,i.expectedValue);return{received:f,matches:h}}if(s==="to.have.css.object"){const o=i.expectedValue??{},c={};let f=!0;const h=this.window.getComputedStyle(e);for(const[p,y]of Object.entries(o)){let m=h[p];typeof m!="string"&&(m=""),m!==y&&(f=!1),c[p]=m}return{received:c,matches:f}}if(s==="to.be.in.viewport"){const o=await this.viewportRatio(e);return{received:`viewport ratio ${o}`,matches:o>0&&o>(i.expectedNumber??0)-1e-9}}if(s==="to.have.values"){if(e=this.retarget(e,"follow-label"),e.nodeName!=="SELECT"||!e.multiple)throw this.createStacklessError("Not a select element with a multiple attribute");const o=[...e.selectedOptions].map(c=>c.value);return o.length!==i.expectedText.length?{received:o,matches:!1}:{received:o,matches:o.map((c,f)=>new hr(i.expectedText[f]).matches(c)).every(Boolean)}}if(s==="to.match.aria"){const o=G_(e,i.expectedValue);return{received:o.received,matches:!!o.matches.length}}{let o;if(s==="to.have.attribute.value"){const c=e.getAttribute(i.expressionArg||"");if(c===null)return{received:null,matches:!1};o=c}else if(["to.have.class","to.contain.class"].includes(s)){if(!i.expectedText)throw this.createStacklessError("Expected text is not provided for "+s);return{received:e.classList.toString(),matches:new hr(i.expectedText[0]).matchesClassList(this,e.classList,s==="to.contain.class")}}else if(s==="to.have.css")o=this.window.getComputedStyle(e).getPropertyValue(i.expressionArg||"");else if(s==="to.have.id")o=e.id;else if(s==="to.have.text")o=i.useInnerText?e.innerText:qt(new Map,e).full;else if(s==="to.have.accessible.name")o=ul(e,!1);else if(s==="to.have.accessible.description")o=Ib(e,!1);else if(s==="to.have.accessible.error.message")o=N_(e);else if(s==="to.have.role")o=bt(e)||"";else if(s==="to.have.value"){if(e=this.retarget(e,"follow-label"),e.nodeName!=="INPUT"&&e.nodeName!=="TEXTAREA"&&e.nodeName!=="SELECT")throw this.createStacklessError("Not an input element");o=e.value}if(o!==void 0&&i.expectedText){const c=new hr(i.expectedText[0]);return{received:o,matches:c.matches(o)}}}throw this.createStacklessError("Unknown expect matcher: "+s)}expectArray(e,i){const s=i.expression;if(s==="to.have.count"){const h=e.length,p=h===i.expectedNumber;return{received:h,matches:p}}if(!i.expectedText)throw this.createStacklessError("Expected text is not provided for "+s);if(["to.have.class.array","to.contain.class.array"].includes(s)){const h=e.map(m=>m.classList),p=h.map(String);if(h.length!==i.expectedText.length)return{received:p,matches:!1};const y=this._matchSequentially(i.expectedText,h,(m,v)=>m.matchesClassList(this,v,s==="to.contain.class.array"));return{received:p,matches:y}}if(!["to.contain.text.array","to.have.text.array"].includes(s))throw this.createStacklessError("Unknown expect matcher: "+s);const a=e.map(h=>i.useInnerText?h.innerText:qt(new Map,h).full),o=s!=="to.contain.text.array";if(!(a.length===i.expectedText.length||!o))return{received:a,matches:!1};const f=this._matchSequentially(i.expectedText,a,(h,p)=>h.matches(p));return{received:a,matches:f}}_matchSequentially(e,i,s){const a=e.map(f=>new hr(f));let o=0,c=0;for(;o<a.length&&c<i.length;)s(a[o],i[c])&&++o,++c;return o===a.length}}function Vo(n){return n.replace(/\n/g,"↵").replace(/\t/g,"⇆")}function kC(n){if(n=n.substring(1,n.length-1),!n.includes("\\"))return n;const e=[];let i=0;for(;i<n.length;)n[i]==="\\"&&i+1<n.length&&i++,e.push(n[i++]);return e.join("")}function Go(n,e){if(n[0]==="/"&&n.lastIndexOf("/")>0){const a=n.lastIndexOf("/"),o=new RegExp(n.substring(1,a),n.substring(a+1));return{matcher:c=>o.test(c.full),kind:"regex"}}const i=e?JSON.parse.bind(JSON):kC;let s=!1;return n.length>1&&n[0]==='"'&&n[n.length-1]==='"'?(n=i(n),s=!0):e&&n.length>1&&n[0]==='"'&&n[n.length-2]==='"'&&n[n.length-1]==="i"?(n=i(n.substring(0,n.length-1)),s=!1):e&&n.length>1&&n[0]==='"'&&n[n.length-2]==='"'&&n[n.length-1]==="s"?(n=i(n.substring(0,n.length-1)),s=!0):n.length>1&&n[0]==="'"&&n[n.length-1]==="'"&&(n=i(n),s=!0),n=Nt(n),s?e?{kind:"strict",matcher:o=>o.normalized===n}:{matcher:o=>!n&&!o.immediate.length?!0:o.immediate.some(c=>Nt(c)===n),kind:"strict"}:(n=n.toLowerCase(),{kind:"lax",matcher:a=>a.normalized.toLowerCase().includes(n)})}class hr{constructor(e){if(this._normalizeWhiteSpace=e.normalizeWhiteSpace,this._ignoreCase=e.ignoreCase,this._string=e.matchSubstring?void 0:this.normalize(e.string),this._substring=e.matchSubstring?this.normalize(e.string):void 0,e.regexSource){const i=new Set((e.regexFlags||"").split(""));e.ignoreCase===!1&&i.delete("i"),e.ignoreCase===!0&&i.add("i"),this._regex=new RegExp(e.regexSource,[...i].join(""))}}matches(e){return this._regex||(e=this.normalize(e)),this._string!==void 0?e===this._string:this._substring!==void 0?e.includes(this._substring):this._regex?!!this._regex.test(e):!1}matchesClassList(e,i,s){if(s){if(this._regex)throw e.createStacklessError("Partial matching does not support regular expressions. Please provide a string value.");return this._string.split(/\s+/g).filter(Boolean).every(a=>i.contains(a))}return this.matches(i.toString())}normalize(e){return e&&(this._normalizeWhiteSpace&&(e=Nt(e)),this._ignoreCase&&(e=e.toLocaleLowerCase()),e)}}function sd(n,e){if(n===e)return!0;if(n&&e&&typeof n=="object"&&typeof e=="object"){if(n.constructor!==e.constructor)return!1;if(Array.isArray(n)){if(n.length!==e.length)return!1;for(let s=0;s<n.length;++s)if(!sd(n[s],e[s]))return!1;return!0}if(n instanceof RegExp)return n.source===e.source&&n.flags===e.flags;if(n.valueOf!==Object.prototype.valueOf)return n.valueOf()===e.valueOf();if(n.toString!==Object.prototype.toString)return n.toString()===e.toString();const i=Object.keys(n);if(i.length!==Object.keys(e).length)return!1;for(let s=0;s<i.length;++s)if(!e.hasOwnProperty(i[s]))return!1;for(const s of i)if(!sd(n[s],e[s]))return!1;return!0}return typeof n=="number"&&typeof e=="number"?isNaN(n)&&isNaN(e):!1}const MC={tagName:"svg",children:[{tagName:"defs",children:[{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-gripper"},children:[{tagName:"path",attrs:{d:"M5 3h2v2H5zm0 4h2v2H5zm0 4h2v2H5zm4-8h2v2H9zm0 4h2v2H9zm0 4h2v2H9z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-circle-large-filled"},children:[{tagName:"path",attrs:{d:"M8 1a6.8 6.8 0 0 1 1.86.253 6.899 6.899 0 0 1 3.083 1.805 6.903 6.903 0 0 1 1.804 3.083C14.916 6.738 15 7.357 15 8s-.084 1.262-.253 1.86a6.9 6.9 0 0 1-.704 1.674 7.157 7.157 0 0 1-2.516 2.509 6.966 6.966 0 0 1-1.668.71A6.984 6.984 0 0 1 8 15a6.984 6.984 0 0 1-1.86-.246 7.098 7.098 0 0 1-1.674-.711 7.3 7.3 0 0 1-1.415-1.094 7.295 7.295 0 0 1-1.094-1.415 7.098 7.098 0 0 1-.71-1.675A6.985 6.985 0 0 1 1 8c0-.643.082-1.262.246-1.86a6.968 6.968 0 0 1 .711-1.667 7.156 7.156 0 0 1 2.509-2.516 6.895 6.895 0 0 1 1.675-.704A6.808 6.808 0 0 1 8 1z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-stop-circle"},children:[{tagName:"path",attrs:{d:"M6 6h4v4H6z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-inspect"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M1 3l1-1h12l1 1v6h-1V3H2v8h5v1H2l-1-1V3zm14.707 9.707L9 6v9.414l2.707-2.707h4zM10 13V8.414l3.293 3.293h-2L10 13z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-whole-word"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M0 11H1V13H15V11H16V14H15H1H0V11Z"}},{tagName:"path",attrs:{d:"M6.84048 11H5.95963V10.1406H5.93814C5.555 10.7995 4.99104 11.1289 4.24625 11.1289C3.69839 11.1289 3.26871 10.9839 2.95718 10.6938C2.64924 10.4038 2.49527 10.0189 2.49527 9.53906C2.49527 8.51139 3.10041 7.91341 4.3107 7.74512L5.95963 7.51416C5.95963 6.57959 5.58186 6.1123 4.82632 6.1123C4.16389 6.1123 3.56591 6.33789 3.03238 6.78906V5.88672C3.57307 5.54297 4.19612 5.37109 4.90152 5.37109C6.19416 5.37109 6.84048 6.05501 6.84048 7.42285V11ZM5.95963 8.21777L4.63297 8.40039C4.22476 8.45768 3.91682 8.55973 3.70914 8.70654C3.50145 8.84977 3.39761 9.10579 3.39761 9.47461C3.39761 9.74316 3.4925 9.96338 3.68228 10.1353C3.87564 10.3035 4.13166 10.3877 4.45035 10.3877C4.8872 10.3877 5.24706 10.2355 5.52994 9.93115C5.8164 9.62321 5.95963 9.2347 5.95963 8.76562V8.21777Z"}},{tagName:"path",attrs:{d:"M9.3475 10.2051H9.32601V11H8.44515V2.85742H9.32601V6.4668H9.3475C9.78076 5.73633 10.4146 5.37109 11.2489 5.37109C11.9543 5.37109 12.5057 5.61816 12.9032 6.1123C13.3042 6.60286 13.5047 7.26172 13.5047 8.08887C13.5047 9.00911 13.2809 9.74674 12.8333 10.3018C12.3857 10.8532 11.7734 11.1289 10.9964 11.1289C10.2695 11.1289 9.71989 10.821 9.3475 10.2051ZM9.32601 7.98682V8.75488C9.32601 9.20964 9.47282 9.59635 9.76644 9.91504C10.0636 10.2301 10.4396 10.3877 10.8944 10.3877C11.4279 10.3877 11.8451 10.1836 12.1458 9.77539C12.4502 9.36719 12.6024 8.79964 12.6024 8.07275C12.6024 7.46045 12.4609 6.98063 12.1781 6.6333C11.8952 6.28597 11.512 6.1123 11.0286 6.1123C10.5166 6.1123 10.1048 6.29134 9.7933 6.64941C9.48177 7.00391 9.32601 7.44971 9.32601 7.98682Z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-eye"},children:[{tagName:"path",attrs:{d:"M7.99993 6.00316C9.47266 6.00316 10.6666 7.19708 10.6666 8.66981C10.6666 10.1426 9.47266 11.3365 7.99993 11.3365C6.52715 11.3365 5.33324 10.1426 5.33324 8.66981C5.33324 7.19708 6.52715 6.00316 7.99993 6.00316ZM7.99993 7.00315C7.07946 7.00315 6.33324 7.74935 6.33324 8.66981C6.33324 9.59028 7.07946 10.3365 7.99993 10.3365C8.9204 10.3365 9.6666 9.59028 9.6666 8.66981C9.6666 7.74935 8.9204 7.00315 7.99993 7.00315ZM7.99993 3.66675C11.0756 3.66675 13.7307 5.76675 14.4673 8.70968C14.5344 8.97755 14.3716 9.24908 14.1037 9.31615C13.8358 9.38315 13.5643 9.22041 13.4973 8.95248C12.8713 6.45205 10.6141 4.66675 7.99993 4.66675C5.38454 4.66675 3.12664 6.45359 2.50182 8.95555C2.43491 9.22341 2.16348 9.38635 1.89557 9.31948C1.62766 9.25255 1.46471 8.98115 1.53162 8.71321C2.26701 5.76856 4.9229 3.66675 7.99993 3.66675Z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-symbol-constant"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M4 6h8v1H4V6zm8 3H4v1h8V9z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M1 4l1-1h12l1 1v8l-1 1H2l-1-1V4zm1 0v8h12V4H2z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-check"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M14.431 3.323l-8.47 10-.79-.036-3.35-4.77.818-.574 2.978 4.24 8.051-9.506.764.646z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-close"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8 8.707l3.646 3.647.708-.707L8.707 8l3.647-3.646-.707-.708L8 7.293 4.354 3.646l-.707.708L7.293 8l-3.646 3.646.707.708L8 8.707z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-pass"},children:[{tagName:"path",attrs:{d:"M6.27 10.87h.71l4.56-4.56-.71-.71-4.2 4.21-1.92-1.92L4 8.6l2.27 2.27z"}},{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M8.6 1c1.6.1 3.1.9 4.2 2 1.3 1.4 2 3.1 2 5.1 0 1.6-.6 3.1-1.6 4.4-1 1.2-2.4 2.1-4 2.4-1.6.3-3.2.1-4.6-.7-1.4-.8-2.5-2-3.1-3.5C.9 9.2.8 7.5 1.3 6c.5-1.6 1.4-2.9 2.8-3.8C5.4 1.3 7 .9 8.6 1zm.5 12.9c1.3-.3 2.5-1 3.4-2.1.8-1.1 1.3-2.4 1.2-3.8 0-1.6-.6-3.2-1.7-4.3-1-1-2.2-1.6-3.6-1.7-1.3-.1-2.7.2-3.8 1-1.1.8-1.9 1.9-2.3 3.3-.4 1.3-.4 2.7.2 4 .6 1.3 1.5 2.3 2.7 3 1.2.7 2.6.9 3.9.6z"}}]},{tagName:"clipPath",attrs:{width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",id:"icon-gist"},children:[{tagName:"path",attrs:{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M10.57 1.14l3.28 3.3.15.36v9.7l-.5.5h-11l-.5-.5v-13l.5-.5h7.72l.35.14zM10 5h3l-3-3v3zM3 2v12h10V6H9.5L9 5.5V2H3zm2.062 7.533l1.817-1.828L6.17 7 4 9.179v.707l2.171 2.174.707-.707-1.816-1.82zM8.8 7.714l.7-.709 2.189 2.175v.709L9.5 12.062l-.705-.709 1.831-1.82L8.8 7.714z"}}]}]}]},hn={multiple:"#f6b26b7f",single:"#6fa8dc7f",assert:"#8acae480",action:"#dc6f6f7f"};class i0{}class kh{constructor(e,i){this._hoveredModel=null,this._hoveredElement=null,this._recorder=e,this._assertVisibility=i}cursor(){return"pointer"}uninstall(){this._hoveredModel=null,this._hoveredElement=null}onClick(e){var i;Ie(e),e.button===0&&(i=this._hoveredModel)!=null&&i.selector&&this._commit(this._hoveredModel.selector,this._hoveredModel)}onPointerDown(e){Ie(e)}onPointerUp(e){Ie(e)}onMouseDown(e){Ie(e)}onMouseUp(e){Ie(e)}onMouseMove(e){var a;Ie(e);let i=this._recorder.deepEventTarget(e);if(i.isConnected||(i=null),this._hoveredElement===i)return;this._hoveredElement=i;let s=null;if(this._hoveredElement){const o=this._recorder.injectedScript.generateSelector(this._hoveredElement,{testIdAttributeName:this._recorder.state.testIdAttributeName,multiple:!1});s={selector:o.selector,elements:o.elements,tooltipText:this._recorder.injectedScript.utils.asLocator(this._recorder.state.language,o.selector),color:this._assertVisibility?hn.assert:hn.single}}((a=this._hoveredModel)==null?void 0:a.selector)!==(s==null?void 0:s.selector)&&(this._hoveredModel=s,this._recorder.updateHighlight(s,!0))}onMouseEnter(e){Ie(e)}onMouseLeave(e){Ie(e);const i=this._recorder.injectedScript.window;i.top!==i&&this._recorder.deepEventTarget(e).nodeType===Node.DOCUMENT_NODE&&this._reset(!0)}onKeyDown(e){Ie(e),e.key==="Escape"&&this._assertVisibility&&this._recorder.setMode("recording")}onKeyUp(e){Ie(e)}onScroll(e){this._reset(!1)}_commit(e,i){var s;this._assertVisibility?(this._recorder.recordAction({name:"assertVisible",selector:e,signals:[]}),this._recorder.setMode("recording"),(s=this._recorder.overlay)==null||s.flashToolSucceeded("assertingVisibility")):this._recorder.elementPicked(e,i)}_reset(e){this._hoveredElement=null,this._hoveredModel=null,this._recorder.updateHighlight(null,e)}}class OC{constructor(e){this._hoveredModel=null,this._hoveredElement=null,this._activeModel=null,this._expectProgrammaticKeyUp=!1,this._observer=null,this._recorder=e,this._performingActions=new Set,this._dialog=new fS(e)}cursor(){return"pointer"}_installObserverIfNeeded(){var e;this._observer||(e=this._recorder.injectedScript.document)!=null&&e.body&&(this._observer=new MutationObserver(i=>{if(this._hoveredElement)for(const s of i)for(const a of s.removedNodes)(a===this._hoveredElement||a.contains(this._hoveredElement))&&this._resetHoveredModel()}),this._observer.observe(this._recorder.injectedScript.document.body,{childList:!0,subtree:!0}))}uninstall(){var e;(e=this._observer)==null||e.disconnect(),this._observer=null,this._hoveredModel=null,this._hoveredElement=null,this._activeModel=null,this._expectProgrammaticKeyUp=!1,this._dialog.close()}onClick(e){if(this._dialog.isShowing()){e.button===2&&e.type==="auxclick"&&Ie(e);return}if(ll(this._hoveredElement)||this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel))return;if(e.button===2&&e.type==="auxclick"){this._showActionListDialog(this._hoveredModel,e);return}const i=al(this._recorder.deepEventTarget(e));if(i&&e.detail===1){this._performAction({name:i.checked?"check":"uncheck",selector:this._hoveredModel.selector,signals:[]});return}this._cancelPendingClickAction(),e.detail===1&&(this._pendingClickAction={action:{name:"click",selector:this._hoveredModel.selector,position:rl(e),signals:[],button:rd(e),modifiers:Tr(e),clickCount:e.detail},timeout:this._recorder.injectedScript.utils.builtins.setTimeout(()=>this._commitPendingClickAction(),200)})}onDblClick(e){this._dialog.isShowing()||ll(this._hoveredElement)||this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel)||(this._cancelPendingClickAction(),this._performAction({name:"click",selector:this._hoveredModel.selector,position:rl(e),signals:[],button:rd(e),modifiers:Tr(e),clickCount:e.detail}))}_commitPendingClickAction(){this._pendingClickAction&&this._performAction(this._pendingClickAction.action),this._cancelPendingClickAction()}_cancelPendingClickAction(){this._pendingClickAction&&this._recorder.injectedScript.utils.builtins.clearTimeout(this._pendingClickAction.timeout),this._pendingClickAction=void 0}onContextMenu(e){if(this._dialog.isShowing()){Ie(e);return}this._shouldIgnoreMouseEvent(e)||this._actionInProgress(e)||this._consumedDueToNoModel(e,this._hoveredModel)||this._showActionListDialog(this._hoveredModel,e)}onPointerDown(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onPointerUp(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onMouseDown(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||(this._consumeWhenAboutToPerform(e),this._activeModel=this._hoveredModel)}onMouseUp(e){this._dialog.isShowing()||this._shouldIgnoreMouseEvent(e)||this._consumeWhenAboutToPerform(e)}onMouseMove(e){if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);this._hoveredElement!==i&&(this._hoveredElement=i,this._updateModelForHoveredElement())}onMouseLeave(e){if(this._dialog.isShowing())return;const i=this._recorder.injectedScript.window;i.top!==i&&this._recorder.deepEventTarget(e).nodeType===Node.DOCUMENT_NODE&&(this._hoveredElement=null,this._updateModelForHoveredElement())}onFocus(e){this._dialog.isShowing()||this._onFocus(!0)}onInput(e){if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);if(i.nodeName==="INPUT"&&i.type.toLowerCase()==="file"){this._recordAction({name:"setInputFiles",selector:this._activeModel.selector,signals:[],files:[...i.files||[]].map(s=>s.name)});return}if(ll(i)){this._recordAction({name:"fill",selector:this._hoveredModel.selector,signals:[],text:i.value});return}if(["INPUT","TEXTAREA"].includes(i.nodeName)||i.isContentEditable){if(i.nodeName==="INPUT"&&["checkbox","radio"].includes(i.type.toLowerCase())||this._consumedDueWrongTarget(e))return;this._recordAction({name:"fill",selector:this._activeModel.selector,signals:[],text:i.isContentEditable?i.innerText:i.value})}if(i.nodeName==="SELECT"){const s=i;this._recordAction({name:"select",selector:this._activeModel.selector,options:[...s.selectedOptions].map(a=>a.value),signals:[]})}}onKeyDown(e){if(!this._dialog.isShowing()&&this._shouldGenerateKeyPressFor(e)){if(this._actionInProgress(e)){this._expectProgrammaticKeyUp=!0;return}if(!this._consumedDueWrongTarget(e)){if(e.key===" "){const i=al(this._recorder.deepEventTarget(e));if(i&&e.detail===0){this._performAction({name:i.checked?"uncheck":"check",selector:this._activeModel.selector,signals:[]});return}}this._performAction({name:"press",selector:this._activeModel.selector,signals:[],key:e.key,modifiers:Tr(e)})}}}onKeyUp(e){if(!this._dialog.isShowing()&&this._shouldGenerateKeyPressFor(e)){if(!this._expectProgrammaticKeyUp){Ie(e);return}this._expectProgrammaticKeyUp=!1}}onScroll(e){this._dialog.isShowing()||this._resetHoveredModel()}_showActionListDialog(e,i){Ie(i);const s=rl(i),a=[{title:"Click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"left",modifiers:0,clickCount:0})},{title:"Right click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"right",modifiers:0,clickCount:0})},{title:"Double click",cb:()=>this._performAction({name:"click",selector:e.selector,position:s,signals:[],button:"left",modifiers:0,clickCount:2})},{title:"Hover",cb:()=>this._performAction({name:"hover",selector:e.selector,position:s,signals:[]})},{title:"Pick locator",cb:()=>this._recorder.elementPicked(e.selector,e)}],o=this._recorder.document.createElement("x-pw-action-list");o.setAttribute("role","list"),o.setAttribute("aria-label","Choose action");for(const p of a){const y=this._recorder.document.createElement("x-pw-action-item");y.setAttribute("role","listitem"),y.textContent=p.title,y.setAttribute("aria-label",p.title),y.addEventListener("click",()=>{this._dialog.close(),p.cb()}),o.appendChild(y)}const c=this._dialog.show({label:"Choose action",body:o,autosize:!0}),f=this._recorder.highlight.firstTooltipBox()||e.elements[0].getBoundingClientRect(),h=this._recorder.highlight.tooltipPosition(f,c);this._dialog.moveTo(h.anchorTop,h.anchorLeft)}_resetHoveredModel(){this._hoveredModel=null,this._hoveredElement=null,this._updateHighlight(!1)}_onFocus(e){const i=DC(this._recorder.document);if(e&&i===this._recorder.document.body)return;const s=i?this._recorder.injectedScript.generateSelector(i,{testIdAttributeName:this._recorder.state.testIdAttributeName}):null;this._activeModel=s&&s.selector?{...s,color:hn.action}:null,e&&(this._hoveredElement=i,this._updateModelForHoveredElement())}_shouldIgnoreMouseEvent(e){const i=this._recorder.deepEventTarget(e),s=i.nodeName;return!!(s==="SELECT"||s==="OPTION"||s==="INPUT"&&["date","range"].includes(i.type))}_actionInProgress(e){const i=e instanceof KeyboardEvent,s=e instanceof MouseEvent||e instanceof PointerEvent;for(const a of this._performingActions)if(i&&a.name==="press"&&e.key===a.key||s&&(a.name==="click"||a.name==="hover"||a.name==="check"||a.name==="uncheck"))return!0;return Ie(e),!1}_consumedDueToNoModel(e,i){return i?!1:(Ie(e),!0)}_consumedDueWrongTarget(e){return this._activeModel&&this._activeModel.elements[0]===this._recorder.deepEventTarget(e)?!1:(Ie(e),!0)}_consumeWhenAboutToPerform(e){this._performingActions.size||Ie(e)}_reportPerformedActionForTests(){this._recorder.injectedScript.isUnderTest&&console.error("Action performed for test: "+JSON.stringify({hovered:this._hoveredModel?this._hoveredModel.selector:null,active:this._activeModel?this._activeModel.selector:null}))}_recordAction(e){this._recorder.recordAction(e).then(()=>this._reportPerformedActionForTests())}_performAction(e){this._recorder.updateHighlight(null,!1),this._performingActions.add(e),this._recorder.performAction(e).finally(()=>{this._performingActions.delete(e),this._onFocus(!1)}).then(()=>this._reportPerformedActionForTests())}_shouldGenerateKeyPressFor(e){if(typeof e.key!="string"||e.key==="Enter"&&(this._recorder.deepEventTarget(e).nodeName==="TEXTAREA"||this._recorder.deepEventTarget(e).isContentEditable)||["Backspace","Delete","AltGraph"].includes(e.key)||e.key==="@"&&e.code==="KeyL")return!1;if(navigator.platform.includes("Mac")){if(e.key==="v"&&e.metaKey)return!1}else if(e.key==="v"&&e.ctrlKey||e.key==="Insert"&&e.shiftKey)return!1;if(["Shift","Control","Meta","Alt","Process"].includes(e.key))return!1;const i=e.ctrlKey||e.altKey||e.metaKey;return e.key.length===1&&!i?!!al(this._recorder.deepEventTarget(e)):!0}_updateModelForHoveredElement(){if(this._installObserverIfNeeded(),this._performingActions.size)return;if(!this._hoveredElement||!this._hoveredElement.isConnected){this._hoveredModel=null,this._hoveredElement=null,this._updateHighlight(!0);return}const{selector:e,elements:i}=this._recorder.injectedScript.generateSelector(this._hoveredElement,{testIdAttributeName:this._recorder.state.testIdAttributeName});this._hoveredModel&&this._hoveredModel.selector===e||(this._hoveredModel=e?{selector:e,elements:i,color:hn.action}:null,this._updateHighlight(!0))}_updateHighlight(e){this._recorder.updateHighlight(this._hoveredModel,e)}}class LC{constructor(e){this._recorder=e}install(){this._recorder.highlight.uninstall()}uninstall(){this._recorder.highlight.install()}onClick(e){const i=this._recorder.deepEventTarget(e);if(ll(i)||e.button===2&&e.type==="auxclick"||this._shouldIgnoreMouseEvent(e))return;const s=al(i),{ariaSnapshot:a,selector:o,ref:c}=this._ariaSnapshot(i);if(s&&e.detail===1){this._recorder.recordAction({name:s.checked?"check":"uncheck",selector:o,ref:c,signals:[],ariaSnapshot:a});return}this._recorder.recordAction({name:"click",selector:o,ref:c,ariaSnapshot:a,position:rl(e),signals:[],button:rd(e),modifiers:Tr(e),clickCount:e.detail})}onContextMenu(e){const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);this._recorder.recordAction({name:"click",selector:a,ref:o,ariaSnapshot:s,position:rl(e),signals:[],button:"right",modifiers:Tr(e),clickCount:1})}onInput(e){const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);if(ll(i)){this._recorder.recordAction({name:"fill",selector:a,ref:o,ariaSnapshot:s,signals:[],text:i.value});return}if(["INPUT","TEXTAREA"].includes(i.nodeName)||i.isContentEditable){if(i.nodeName==="INPUT"&&["checkbox","radio"].includes(i.type.toLowerCase()))return;this._recorder.recordAction({name:"fill",ref:o,selector:a,ariaSnapshot:s,signals:[],text:i.isContentEditable?i.innerText:i.value});return}if(i.nodeName==="SELECT"){const c=i;this._recorder.recordAction({name:"select",selector:a,ref:o,ariaSnapshot:s,options:[...c.selectedOptions].map(f=>f.value),signals:[]});return}}onKeyDown(e){if(!this._shouldGenerateKeyPressFor(e))return;const i=this._recorder.deepEventTarget(e),{ariaSnapshot:s,selector:a,ref:o}=this._ariaSnapshot(i);if(e.key===" "){const c=al(i);if(c&&e.detail===0){this._recorder.recordAction({name:c.checked?"uncheck":"check",selector:a,ref:o,ariaSnapshot:s,signals:[]});return}}this._recorder.recordAction({name:"press",selector:a,ref:o,ariaSnapshot:s,signals:[],key:e.key,modifiers:Tr(e)})}_shouldIgnoreMouseEvent(e){const i=this._recorder.deepEventTarget(e),s=i.nodeName;return!!(s==="SELECT"||s==="OPTION"||s==="INPUT"&&["date","range"].includes(i.type))}_shouldGenerateKeyPressFor(e){if(typeof e.key!="string"||e.key==="Enter"&&(this._recorder.deepEventTarget(e).nodeName==="TEXTAREA"||this._recorder.deepEventTarget(e).isContentEditable)||["Backspace","Delete","AltGraph"].includes(e.key)||e.key==="@"&&e.code==="KeyL")return!1;if(navigator.platform.includes("Mac")){if(e.key==="v"&&e.metaKey)return!1}else if(e.key==="v"&&e.ctrlKey||e.key==="Insert"&&e.shiftKey)return!1;if(["Shift","Control","Meta","Alt","Process"].includes(e.key))return!1;const i=e.ctrlKey||e.altKey||e.metaKey;return e.key.length===1&&!i?!this._isEditable(this._recorder.deepEventTarget(e)):!0}_isEditable(e){return!!(e.nodeName==="TEXTAREA"||e.nodeName==="INPUT"||e.isContentEditable)}_ariaSnapshot(e){const{ariaSnapshot:i,refs:s}=this._recorder.injectedScript.ariaSnapshotForRecorder(),a=e?s.get(e):void 0,o=e?this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName}):void 0;return{ariaSnapshot:i,selector:o==null?void 0:o.selector,ref:a}}}class Mh{constructor(e,i){this._hoverHighlight=null,this._action=null,this._recorder=e,this._textCache=new Map,this._kind=i,this._dialog=new fS(e)}cursor(){return"pointer"}uninstall(){this._dialog.close(),this._hoverHighlight=null}onClick(e){Ie(e),this._kind==="value"?this._commitAssertValue():this._dialog.isShowing()||this._showDialog()}onMouseDown(e){const i=this._recorder.deepEventTarget(e);this._elementHasValue(i)&&e.preventDefault()}onPointerUp(e){var s;const i=(s=this._hoverHighlight)==null?void 0:s.elements[0];this._kind==="value"&&i&&(i.nodeName==="INPUT"||i.nodeName==="SELECT")&&i.disabled&&this._commitAssertValue()}onMouseMove(e){var s;if(this._dialog.isShowing())return;const i=this._recorder.deepEventTarget(e);if(((s=this._hoverHighlight)==null?void 0:s.elements[0])!==i){if(this._kind==="text"||this._kind==="snapshot")this._hoverHighlight=this._recorder.injectedScript.utils.elementText(this._textCache,i).full?{elements:[i],selector:"",color:hn.assert}:null;else if(this._elementHasValue(i)){const a=this._recorder.injectedScript.generateSelector(i,{testIdAttributeName:this._recorder.state.testIdAttributeName});this._hoverHighlight={selector:a.selector,elements:a.elements,color:hn.assert}}else this._hoverHighlight=null;this._recorder.updateHighlight(this._hoverHighlight,!0)}}onKeyDown(e){e.key==="Escape"&&this._recorder.setMode("recording"),Ie(e)}onScroll(e){this._recorder.updateHighlight(this._hoverHighlight,!1)}_elementHasValue(e){return e.nodeName==="TEXTAREA"||e.nodeName==="SELECT"||e.nodeName==="INPUT"&&!["button","image","reset","submit"].includes(e.type)}_generateAction(){var i;this._textCache.clear();const e=(i=this._hoverHighlight)==null?void 0:i.elements[0];if(!e)return null;if(this._kind==="value"){if(!this._elementHasValue(e))return null;const{selector:s}=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName});return e.nodeName==="INPUT"&&["checkbox","radio"].includes(e.type.toLowerCase())?{name:"assertChecked",selector:s,signals:[],checked:!e.checked}:{name:"assertValue",selector:s,signals:[],value:e.value}}else if(this._kind==="snapshot"){const s=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName,forTextExpect:!0});return this._hoverHighlight={selector:s.selector,elements:s.elements,color:hn.assert},this._recorder.updateHighlight(this._hoverHighlight,!0),{name:"assertSnapshot",selector:this._hoverHighlight.selector,signals:[],ariaSnapshot:this._recorder.injectedScript.ariaSnapshot(e,{mode:"codegen"})}}else{const s=this._recorder.injectedScript.generateSelector(e,{testIdAttributeName:this._recorder.state.testIdAttributeName,forTextExpect:!0});return this._hoverHighlight={selector:s.selector,elements:s.elements,color:hn.assert},this._recorder.updateHighlight(this._hoverHighlight,!0),{name:"assertText",selector:this._hoverHighlight.selector,signals:[],text:this._recorder.injectedScript.utils.elementText(this._textCache,e).normalized,substring:!0}}}_renderValue(e){return(e==null?void 0:e.name)==="assertText"?this._recorder.injectedScript.utils.normalizeWhiteSpace(e.text):(e==null?void 0:e.name)==="assertChecked"?String(e.checked):(e==null?void 0:e.name)==="assertValue"?e.value:(e==null?void 0:e.name)==="assertSnapshot"?e.ariaSnapshot:""}_commit(){!this._action||!this._dialog.isShowing()||(this._dialog.close(),this._recorder.recordAction(this._action),this._recorder.setMode("recording"))}_showDialog(){var e,i,s,a;(e=this._hoverHighlight)!=null&&e.elements[0]&&(this._action=this._generateAction(),((i=this._action)==null?void 0:i.name)==="assertText"?this._showTextDialog(this._action):((s=this._action)==null?void 0:s.name)==="assertSnapshot"&&(this._recorder.recordAction(this._action),this._recorder.setMode("recording"),(a=this._recorder.overlay)==null||a.flashToolSucceeded("assertingSnapshot")))}_showTextDialog(e){const i=this._recorder.document.createElement("textarea");i.setAttribute("spellcheck","false"),i.value=this._renderValue(e),i.classList.add("text-editor");const s=()=>{var m;const f=this._recorder.injectedScript.utils.normalizeWhiteSpace(i.value),h=(m=this._hoverHighlight)==null?void 0:m.elements[0];if(!h)return;e.text=f;const p=this._recorder.injectedScript.utils.elementText(this._textCache,h).normalized,y=f&&p.includes(f);i.classList.toggle("does-not-match",!y)};i.addEventListener("input",s);const o=this._dialog.show({label:"Assert that element contains text",body:i,onCommit:()=>this._commit()}),c=this._recorder.highlight.tooltipPosition(this._recorder.highlight.firstBox(),o);this._dialog.moveTo(c.anchorTop,c.anchorLeft),i.focus()}_commitAssertValue(){var i;if(this._kind!=="value")return;const e=this._generateAction();e&&(this._recorder.recordAction(e),this._recorder.setMode("recording"),(i=this._recorder.overlay)==null||i.flashToolSucceeded("assertingValue"))}}class jC{constructor(e){this._listeners=[],this._offsetX=0,this._measure={width:0,height:0},this._recorder=e;const i=this._recorder.document;this._overlayElement=i.createElement("x-pw-overlay");const s=i.createElement("x-pw-tools-list");this._overlayElement.appendChild(s),this._dragHandle=i.createElement("x-pw-tool-gripper"),this._dragHandle.appendChild(i.createElement("x-div")),s.appendChild(this._dragHandle),this._recordToggle=this._recorder.document.createElement("x-pw-tool-item"),this._recordToggle.title="Record",this._recordToggle.classList.add("record"),this._recordToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._recordToggle),this._pickLocatorToggle=this._recorder.document.createElement("x-pw-tool-item"),this._pickLocatorToggle.title="Pick locator",this._pickLocatorToggle.classList.add("pick-locator"),this._pickLocatorToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._pickLocatorToggle),this._assertVisibilityToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertVisibilityToggle.title="Assert visibility",this._assertVisibilityToggle.classList.add("visibility"),this._assertVisibilityToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertVisibilityToggle),this._assertTextToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertTextToggle.title="Assert text",this._assertTextToggle.classList.add("text"),this._assertTextToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertTextToggle),this._assertValuesToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertValuesToggle.title="Assert value",this._assertValuesToggle.classList.add("value"),this._assertValuesToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertValuesToggle),this._assertSnapshotToggle=this._recorder.document.createElement("x-pw-tool-item"),this._assertSnapshotToggle.title="Assert snapshot",this._assertSnapshotToggle.classList.add("snapshot"),this._assertSnapshotToggle.appendChild(this._recorder.document.createElement("x-div")),s.appendChild(this._assertSnapshotToggle),this._updateVisualPosition(),this._refreshListeners()}_refreshListeners(){hS(this._listeners),this._listeners=[Ue(this._dragHandle,"mousedown",e=>{this._dragState={offsetX:this._offsetX,dragStart:{x:e.clientX,y:0}}}),Ue(this._recordToggle,"click",()=>{this._recordToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="none"||this._recorder.state.mode==="standby"||this._recorder.state.mode==="inspecting"?"recording":"standby")}),Ue(this._pickLocatorToggle,"click",()=>{if(this._pickLocatorToggle.classList.contains("disabled"))return;const e={inspecting:"standby",none:"inspecting",standby:"inspecting",recording:"recording-inspecting","recording-inspecting":"recording",assertingText:"recording-inspecting",assertingVisibility:"recording-inspecting",assertingValue:"recording-inspecting",assertingSnapshot:"recording-inspecting"};this._recorder.setMode(e[this._recorder.state.mode])}),Ue(this._assertVisibilityToggle,"click",()=>{this._assertVisibilityToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingVisibility"?"recording":"assertingVisibility")}),Ue(this._assertTextToggle,"click",()=>{this._assertTextToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingText"?"recording":"assertingText")}),Ue(this._assertValuesToggle,"click",()=>{this._assertValuesToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingValue"?"recording":"assertingValue")}),Ue(this._assertSnapshotToggle,"click",()=>{this._assertSnapshotToggle.classList.contains("disabled")||this._recorder.setMode(this._recorder.state.mode==="assertingSnapshot"?"recording":"assertingSnapshot")})]}install(){this._recorder.highlight.appendChild(this._overlayElement),this._refreshListeners(),this._updateVisualPosition()}contains(e){return this._recorder.injectedScript.utils.isInsideScope(this._overlayElement,e)}setUIState(e){const i=e.mode==="recording"||e.mode==="assertingText"||e.mode==="assertingVisibility"||e.mode==="assertingValue"||e.mode==="assertingSnapshot"||e.mode==="recording-inspecting";this._recordToggle.classList.toggle("toggled",i),this._recordToggle.title=i?"Stop Recording":"Start Recording",this._pickLocatorToggle.classList.toggle("toggled",e.mode==="inspecting"||e.mode==="recording-inspecting"),this._assertVisibilityToggle.classList.toggle("toggled",e.mode==="assertingVisibility"),this._assertVisibilityToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertTextToggle.classList.toggle("toggled",e.mode==="assertingText"),this._assertTextToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertValuesToggle.classList.toggle("toggled",e.mode==="assertingValue"),this._assertValuesToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._assertSnapshotToggle.classList.toggle("toggled",e.mode==="assertingSnapshot"),this._assertSnapshotToggle.classList.toggle("disabled",e.mode==="none"||e.mode==="standby"||e.mode==="inspecting"),this._offsetX!==e.overlay.offsetX&&(this._offsetX=e.overlay.offsetX,this._updateVisualPosition()),e.mode==="none"?this._hideOverlay():this._showOverlay()}flashToolSucceeded(e){let i;e==="assertingVisibility"?i=this._assertVisibilityToggle:e==="assertingSnapshot"?i=this._assertSnapshotToggle:i=this._assertValuesToggle,i.classList.add("succeeded"),this._recorder.injectedScript.utils.builtins.setTimeout(()=>i.classList.remove("succeeded"),2e3)}_hideOverlay(){this._overlayElement.setAttribute("hidden","true")}_showOverlay(){this._overlayElement.hasAttribute("hidden")&&(this._overlayElement.removeAttribute("hidden"),this._updateVisualPosition())}_updateVisualPosition(){this._measure=this._overlayElement.getBoundingClientRect(),this._overlayElement.style.left=(this._recorder.injectedScript.window.innerWidth-this._measure.width)/2+this._offsetX+"px"}onMouseMove(e){if(!e.buttons)return this._dragState=void 0,!1;if(this._dragState){this._offsetX=this._dragState.offsetX+e.clientX-this._dragState.dragStart.x;const i=(this._recorder.injectedScript.window.innerWidth-this._measure.width)/2-10;return this._offsetX=Math.max(-i,Math.min(i,this._offsetX)),this._updateVisualPosition(),this._recorder.setOverlayState({offsetX:this._offsetX}),Ie(e),!0}return!1}onMouseUp(e){return this._dragState?(Ie(e),!0):!1}onClick(e){return this._dragState?(this._dragState=void 0,Ie(e),!0):!1}onDblClick(e){return!1}}class RC{constructor(e,i){var s,a;this._listeners=[],this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this.state={mode:"none",testIdAttributeName:"data-testid",language:"javascript",overlay:{offsetX:0}},this._delegate={},this.document=e.document,this.injectedScript=e,this.highlight=e.createHighlight(),this._tools={none:new i0,standby:new i0,inspecting:new kh(this,!1),recording:(i==null?void 0:i.recorderMode)==="api"?new LC(this):new OC(this),"recording-inspecting":new kh(this,!1),assertingText:new Mh(this,"text"),assertingVisibility:new kh(this,!0),assertingValue:new Mh(this,"value"),assertingSnapshot:new Mh(this,"snapshot")},this._currentTool=this._tools.none,(a=(s=this._currentTool).install)==null||a.call(s),e.window.top===e.window&&!(i!=null&&i.hideToolbar)&&(this.overlay=new jC(this),this.overlay.setUIState(this.state)),this._stylesheet=new e.window.CSSStyleSheet,this._stylesheet.replaceSync(`
|
|
128
|
+
body[data-pw-cursor=pointer] *, body[data-pw-cursor=pointer] *::after { cursor: pointer !important; }
|
|
129
|
+
body[data-pw-cursor=text] *, body[data-pw-cursor=text] *::after { cursor: text !important; }
|
|
130
|
+
`),this.installListeners(),e.utils.cacheNormalizedWhitespaces(),e.isUnderTest&&console.error("Recorder script ready for test"),e.consoleApi.install()}installListeners(){var s,a,o;hS(this._listeners),this._listeners=[Ue(this.document,"click",c=>this._onClick(c),!0),Ue(this.document,"auxclick",c=>this._onClick(c),!0),Ue(this.document,"dblclick",c=>this._onDblClick(c),!0),Ue(this.document,"contextmenu",c=>this._onContextMenu(c),!0),Ue(this.document,"dragstart",c=>this._onDragStart(c),!0),Ue(this.document,"input",c=>this._onInput(c),!0),Ue(this.document,"keydown",c=>this._onKeyDown(c),!0),Ue(this.document,"keyup",c=>this._onKeyUp(c),!0),Ue(this.document,"pointerdown",c=>this._onPointerDown(c),!0),Ue(this.document,"pointerup",c=>this._onPointerUp(c),!0),Ue(this.document,"mousedown",c=>this._onMouseDown(c),!0),Ue(this.document,"mouseup",c=>this._onMouseUp(c),!0),Ue(this.document,"mousemove",c=>this._onMouseMove(c),!0),Ue(this.document,"mouseleave",c=>this._onMouseLeave(c),!0),Ue(this.document,"mouseenter",c=>this._onMouseEnter(c),!0),Ue(this.document,"focus",c=>this._onFocus(c),!0),Ue(this.document,"scroll",c=>this._onScroll(c),!0)],this.highlight.install();let e;const i=()=>{this.highlight.install(),e=this.injectedScript.utils.builtins.setTimeout(i,500)};e=this.injectedScript.utils.builtins.setTimeout(i,500),this._listeners.push(()=>this.injectedScript.utils.builtins.clearTimeout(e)),this.highlight.appendChild(dS(this.document,MC)),(s=this.overlay)==null||s.install(),(o=(a=this._currentTool)==null?void 0:a.install)==null||o.call(a),this.document.adoptedStyleSheets.push(this._stylesheet)}_switchCurrentTool(){var s,a,o,c,f,h;const e=this._tools[this.state.mode];if(e===this._currentTool)return;(a=(s=this._currentTool).uninstall)==null||a.call(s),this.clearHighlight(),this._currentTool=e,(c=(o=this._currentTool).install)==null||c.call(o);const i=(f=e.cursor)==null?void 0:f.call(e);i&&((h=this.injectedScript.document.body)==null||h.setAttribute("data-pw-cursor",i))}setUIState(e,i){var o;this._delegate=i,e.actionPoint&&this.state.actionPoint&&e.actionPoint.x===this.state.actionPoint.x&&e.actionPoint.y===this.state.actionPoint.y||!e.actionPoint&&!this.state.actionPoint||(e.actionPoint?this.highlight.showActionPoint(e.actionPoint.x,e.actionPoint.y):this.highlight.hideActionPoint()),this.state=e,this.highlight.setLanguage(e.language),this._switchCurrentTool(),(o=this.overlay)==null||o.setUIState(e);let s="noop";if(e.actionSelector!==this._lastHighlightedSelector){const c=e.actionSelector?BC(this.injectedScript,e.language,e.actionSelector,this.document):null;s=c!=null&&c.length?c:"clear",this._lastHighlightedSelector=c!=null&&c.length?e.actionSelector:void 0}const a=JSON.stringify(e.ariaTemplate);if(this._lastHighlightedAriaTemplateJSON!==a){const c=e.ariaTemplate?this.injectedScript.getAllElementsMatchingExpectAriaTemplate(this.document,e.ariaTemplate):[];if(c.length){const f=c.length>1?hn.multiple:hn.single;s=c.map(h=>({element:h,color:f})),this._lastHighlightedAriaTemplateJSON=a}else this._lastHighlightedSelector||(s="clear"),this._lastHighlightedAriaTemplateJSON="undefined"}s==="clear"?this.highlight.clearHighlight():s!=="noop"&&this.highlight.updateHighlight(s)}clearHighlight(){this.updateHighlight(null,!1)}_onClick(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onClick(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onClick)==null||a.call(s,e))}_onDblClick(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onDblClick(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onDblClick)==null||a.call(s,e))}_onContextMenu(e){var i,s;e.isTrusted&&((s=(i=this._currentTool).onContextMenu)==null||s.call(i,e))}_onDragStart(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onDragStart)==null||s.call(i,e))}_onPointerDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onPointerDown)==null||s.call(i,e))}_onPointerUp(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onPointerUp)==null||s.call(i,e))}_onMouseDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseDown)==null||s.call(i,e))}_onMouseUp(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onMouseUp(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onMouseUp)==null||a.call(s,e))}_onMouseMove(e){var i,s,a;e.isTrusted&&((i=this.overlay)!=null&&i.onMouseMove(e)||this._ignoreOverlayEvent(e)||(a=(s=this._currentTool).onMouseMove)==null||a.call(s,e))}_onMouseEnter(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseEnter)==null||s.call(i,e))}_onMouseLeave(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onMouseLeave)==null||s.call(i,e))}_onFocus(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onFocus)==null||s.call(i,e))}_onScroll(e){var i,s;e.isTrusted&&(this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this.highlight.hideActionPoint(),(s=(i=this._currentTool).onScroll)==null||s.call(i,e))}_onInput(e){var i,s;this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onInput)==null||s.call(i,e)}_onKeyDown(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onKeyDown)==null||s.call(i,e))}_onKeyUp(e){var i,s;e.isTrusted&&(this._ignoreOverlayEvent(e)||(s=(i=this._currentTool).onKeyUp)==null||s.call(i,e))}updateHighlight(e,i){this._lastHighlightedSelector=void 0,this._lastHighlightedAriaTemplateJSON="undefined",this._updateHighlight(e,i)}_updateHighlight(e,i){var a,o;let s=e==null?void 0:e.tooltipText;s===void 0&&(e!=null&&e.selector)&&(s=this.injectedScript.utils.asLocator(this.state.language,e.selector)),e?this.highlight.updateHighlight(e.elements.map(c=>({element:c,color:e.color,tooltipText:s}))):this.highlight.clearHighlight(),i&&((o=(a=this._delegate).highlightUpdated)==null||o.call(a))}_ignoreOverlayEvent(e){return e.composedPath().some(i=>(i.nodeName||"").toLowerCase()==="x-pw-glass")}deepEventTarget(e){var i;for(const s of e.composedPath())if(!((i=this.overlay)!=null&&i.contains(s)))return s;return e.composedPath()[0]}setMode(e){var i,s;(s=(i=this._delegate).setMode)==null||s.call(i,e)}_captureAutoExpectSnapshot(){const e=this.injectedScript.document.documentElement;return e?this.injectedScript.utils.generateAriaTree(e,{mode:"autoexpect"}):void 0}async performAction(e){var s,a,o;const i=this._lastActionAutoexpectSnapshot;if(this._lastActionAutoexpectSnapshot=this._captureAutoExpectSnapshot(),!zC(e)&&this._lastActionAutoexpectSnapshot){const c=this.injectedScript.utils.findNewElement(i==null?void 0:i.root,(s=this._lastActionAutoexpectSnapshot)==null?void 0:s.root);e.preconditionSelector=c?this.injectedScript.generateSelector(c,{testIdAttributeName:this.state.testIdAttributeName}).selector:void 0,e.preconditionSelector===e.selector&&(e.preconditionSelector=void 0)}await((o=(a=this._delegate).performAction)==null?void 0:o.call(a,e).catch(()=>{}))}async recordAction(e){var i,s;this._lastActionAutoexpectSnapshot=this._captureAutoExpectSnapshot(),await((s=(i=this._delegate).recordAction)==null?void 0:s.call(i,e))}setOverlayState(e){var i,s;(s=(i=this._delegate).setOverlayState)==null||s.call(i,e)}elementPicked(e,i){var a,o;const s=this.injectedScript.ariaSnapshot(i.elements[0],{mode:"expect"});(o=(a=this._delegate).elementPicked)==null||o.call(a,{selector:e,ariaSnapshot:s})}}let fS=class{constructor(e){this._dialogElement=null,this._recorder=e}isShowing(){return!!this._dialogElement}show(e){const i=this._recorder.document.createElement("x-pw-tool-item");i.title="Accept",i.classList.add("accept"),i.appendChild(this._recorder.document.createElement("x-div")),i.addEventListener("click",()=>{var f;return(f=e.onCommit)==null?void 0:f.call(e)});const s=this._recorder.document.createElement("x-pw-tool-item");s.title="Close",s.classList.add("cancel"),s.appendChild(this._recorder.document.createElement("x-div")),s.addEventListener("click",()=>{var f;this.close(),(f=e.onCancel)==null||f.call(e)}),this._dialogElement=this._recorder.document.createElement("x-pw-dialog"),e.autosize&&this._dialogElement.classList.add("autosize"),this._keyboardListener=f=>{var h;if(f.key==="Escape"){this.close(),(h=e.onCancel)==null||h.call(e);return}if(e.onCommit&&f.key==="Enter"&&(f.ctrlKey||f.metaKey)){this._dialogElement&&e.onCommit();return}},this._onGlassPaneClickHandler=f=>{var h;this.close(),(h=e.onCancel)==null||h.call(e)},this._dialogElement.addEventListener("click",f=>f.stopPropagation());const a=this._recorder.document.createElement("x-pw-tools-list"),o=this._recorder.document.createElement("label");o.textContent=e.label,a.appendChild(o),a.appendChild(this._recorder.document.createElement("x-spacer")),e.onCommit&&a.appendChild(i),a.appendChild(s),this._dialogElement.appendChild(a);const c=this._recorder.document.createElement("x-pw-dialog-body");return c.appendChild(e.body),this._dialogElement.appendChild(c),this._recorder.highlight.appendChild(this._dialogElement),this._recorder.highlight.onGlassPaneClick(this._onGlassPaneClickHandler),this._recorder.document.addEventListener("keydown",this._keyboardListener,!0),this._dialogElement}moveTo(e,i){this._dialogElement&&(this._dialogElement.style.top=e+"px",this._dialogElement.style.left=i+"px")}close(){this._dialogElement&&(this._dialogElement.remove(),this._recorder.highlight.offGlassPaneClick(this._onGlassPaneClickHandler),this._recorder.document.removeEventListener("keydown",this._keyboardListener),this._dialogElement=null)}};function DC(n){let e=n.activeElement;for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function Tr(n){return(n.altKey?1:0)|(n.ctrlKey?2:0)|(n.metaKey?4:0)|(n.shiftKey?8:0)}function rd(n){switch(n.which){case 1:return"left";case 2:return"middle";case 3:return"right"}return"left"}function rl(n){if(n.target.nodeName==="CANVAS")return{x:n.offsetX,y:n.offsetY}}function Ie(n){n.preventDefault(),n.stopPropagation(),n.stopImmediatePropagation()}function al(n){if(!n||n.nodeName!=="INPUT")return null;const e=n;return["checkbox","radio"].includes(e.type)?e:null}function ll(n){return!n||n.nodeName!=="INPUT"?!1:n.type.toLowerCase()==="range"}function Ue(n,e,i,s){return n.addEventListener(e,i,s),()=>{n.removeEventListener(e,i,s)}}function hS(n){for(const e of n)e();n.splice(0,n.length)}function BC(n,e,i,s){try{const a=n.parseSelector(i),o=n.querySelectorAll(a,s),c=o.length>1?hn.multiple:hn.single,f=n.utils.asLocator(e,i);return o.map((h,p)=>{const y=o.length>1?` [${p+1} of ${o.length}]`:"";return{element:h,color:c,tooltipText:f+y}})}catch{return[]}}function dS(n,{tagName:e,attrs:i,children:s}){const a=n.createElementNS("http://www.w3.org/2000/svg",e);if(i)for(const[o,c]of Object.entries(i))a.setAttribute(o,c);if(s)for(const o of s)a.appendChild(dS(n,o));return a}function zC(n){return n.name.startsWith("assert")}const UC="data:text/html;base64,"+btoa("<body></body><style>body { color-scheme: light dark; background: light-dark(white, #333) }</style>");function HC(n,e){n=n.replace(/AriaRole\s*\.\s*([\w]+)/g,(o,c)=>c.toLowerCase()).replace(/(get_by_role|getByRole)\s*\(\s*(?:["'`])([^'"`]+)['"`]/g,(o,c,f)=>`${c}(${f.toLowerCase()}`);const i=[];let s="";for(let o=0;o<n.length;++o){const c=n[o];if(c!=='"'&&c!=="'"&&c!=="`"&&c!=="/"){s+=c;continue}const f=n[o-1]==="r"||n[o]==="/";++o;let h="";for(;o<n.length;){if(n[o]==="\\"){f?(n[o+1]!==c&&(h+=n[o]),++o,h+=n[o]):(++o,n[o]==="n"?h+=`
|
|
131
|
+
`:n[o]==="r"?h+="\r":n[o]==="t"?h+=" ":h+=n[o]),++o;continue}if(n[o]!==c){h+=n[o++];continue}break}i.push({quote:c,text:h}),s+=(c==="/"?"r":"")+"$"+i.length}s=s.toLowerCase().replace(/get_by_alt_text/g,"getbyalttext").replace(/get_by_test_id/g,"getbytestid").replace(/get_by_([\w]+)/g,"getby$1").replace(/has_not_text/g,"hasnottext").replace(/has_text/g,"hastext").replace(/has_not/g,"hasnot").replace(/frame_locator/g,"framelocator").replace(/content_frame/g,"contentframe").replace(/[{}\s]/g,"").replace(/new\(\)/g,"").replace(/new[\w]+\.[\w]+options\(\)/g,"").replace(/\.set/g,",set").replace(/\.or_\(/g,"or(").replace(/\.and_\(/g,"and(").replace(/:/g,"=").replace(/,re\.ignorecase/g,"i").replace(/,pattern.case_insensitive/g,"i").replace(/,regexoptions.ignorecase/g,"i").replace(/re.compile\(([^)]+)\)/g,"$1").replace(/pattern.compile\(([^)]+)\)/g,"r$1").replace(/newregex\(([^)]+)\)/g,"r$1").replace(/string=/g,"=").replace(/regex=/g,"=").replace(/,,/g,",").replace(/,\)/g,")");const a=i.map(o=>o.quote).filter(o=>"'\"`".includes(o))[0];return{selector:pS(s,i,e),preferredQuote:a}}function s0(n){return[...n.matchAll(/\$\d+/g)].length}function r0(n,e){return n.replace(/\$(\d+)/g,(i,s)=>`$${s-e}`)}function pS(n,e,i){for(;;){const a=n.match(/filter\(,?(has=|hasnot=|sethas\(|sethasnot\()/);if(!a)break;const o=a.index+a[0].length;let c=0,f=o;for(;f<n.length&&(n[f]==="("?c++:n[f]===")"&&c--,!(c<0));f++);let h=n.substring(0,o),p=0;["sethas(","sethasnot("].includes(a[1])&&(p=1,h=h.replace(/sethas\($/,"has=").replace(/sethasnot\($/,"hasnot="));const y=s0(n.substring(0,o)),m=r0(n.substring(o,f),y),v=s0(m),S=e.slice(y,y+v),T=JSON.stringify(pS(m,S,i));n=h.replace(/=$/,"2=")+`$${y+1}`+r0(n.substring(f+p),v-1);const x=e.slice(0,y),E=e.slice(y+v);e=x.concat([{quote:'"',text:T}]).concat(E)}n=n.replace(/\,set([\w]+)\(([^)]+)\)/g,(a,o,c)=>","+o.toLowerCase()+"="+c.toLowerCase()).replace(/framelocator\(([^)]+)\)/g,"$1.internal:control=enter-frame").replace(/contentframe(\(\))?/g,"internal:control=enter-frame").replace(/locator\(([^)]+),hastext=([^),]+)\)/g,"locator($1).internal:has-text=$2").replace(/locator\(([^)]+),hasnottext=([^),]+)\)/g,"locator($1).internal:has-not-text=$2").replace(/locator\(([^)]+),hastext=([^),]+)\)/g,"locator($1).internal:has-text=$2").replace(/locator\(([^)]+)\)/g,"$1").replace(/getbyrole\(([^)]+)\)/g,"internal:role=$1").replace(/getbytext\(([^)]+)\)/g,"internal:text=$1").replace(/getbylabel\(([^)]+)\)/g,"internal:label=$1").replace(/getbytestid\(([^)]+)\)/g,`internal:testid=[${i}=$1]`).replace(/getby(placeholder|alt|title)(?:text)?\(([^)]+)\)/g,"internal:attr=[$1=$2]").replace(/first(\(\))?/g,"nth=0").replace(/last(\(\))?/g,"nth=-1").replace(/nth\(([^)]+)\)/g,"nth=$1").replace(/filter\(,?visible=true\)/g,"visible=true").replace(/filter\(,?visible=false\)/g,"visible=false").replace(/filter\(,?hastext=([^)]+)\)/g,"internal:has-text=$1").replace(/filter\(,?hasnottext=([^)]+)\)/g,"internal:has-not-text=$1").replace(/filter\(,?has2=([^)]+)\)/g,"internal:has=$1").replace(/filter\(,?hasnot2=([^)]+)\)/g,"internal:has-not=$1").replace(/,exact=false/g,"").replace(/,exact=true/g,"s").replace(/,includehidden=/g,",include-hidden=").replace(/\,/g,"][");const s=n.split(".");for(let a=0;a<s.length-1;a++)if(s[a]==="internal:control=enter-frame"&&s[a+1].startsWith("nth=")){const[o]=s.splice(a,1);s.splice(a+1,0,o)}return s.map(a=>!a.startsWith("internal:")||a==="internal:control"?a.replace(/\$(\d+)/g,(o,c)=>e[+c-1].text):(a=a.includes("[")?a.replace(/\]/,"")+"]":a,a=a.replace(/(?:r)\$(\d+)(i)?/g,(o,c,f)=>{const h=e[+c-1];return a.startsWith("internal:attr")||a.startsWith("internal:testid")||a.startsWith("internal:role")?Ct(new RegExp(h.text),!1)+(f||""):Ut(new RegExp(h.text,f),!1)}).replace(/\$(\d+)(i|s)?/g,(o,c,f)=>{const h=e[+c-1];return a.startsWith("internal:has=")||a.startsWith("internal:has-not=")?h.text:a.startsWith("internal:testid")?Ct(h.text,!0):a.startsWith("internal:attr")||a.startsWith("internal:role")?Ct(h.text,f==="s"):Ut(h.text,f==="s")}),a)).join(" >> ")}function qC(n,e,i){try{return IC(n,e,i)}catch{return""}}function IC(n,e,i){try{return gl(e),e}catch{}const{selector:s,preferredQuote:a}=HC(e,i),o=W0(n,s,void 0,void 0,a),c=a0(n,e);return o.some(f=>a0(n,f)===c)?s:""}function a0(n,e){return e=e.replace(/\s/g,""),n==="javascript"&&(e=e.replace(/\\?["`]/g,"'").replace(/,{}/g,"")),e}const $C=({url:n})=>w.jsxs("div",{className:"browser-frame-header",children:[w.jsxs("div",{className:"browser-traffic-lights",children:[w.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(242, 95, 88)"}}),w.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(251, 190, 60)"}}),w.jsx("span",{className:"browser-frame-dot",style:{backgroundColor:"rgb(88, 203, 66)"}})]}),w.jsxs("div",{className:"browser-frame-address-bar",title:n||"about:blank",children:[w.jsx("span",{className:"browser-frame-address",children:n||"about:blank"}),n&&w.jsx(wd,{value:n})]}),w.jsx("div",{style:{marginLeft:"auto"},children:w.jsxs("div",{children:[w.jsx("span",{className:"browser-frame-menu-bar"}),w.jsx("span",{className:"browser-frame-menu-bar"}),w.jsx("span",{className:"browser-frame-menu-bar"})]})})]}),Qd=Symbol.for("yaml.alias"),ad=Symbol.for("yaml.document"),Ri=Symbol.for("yaml.map"),gS=Symbol.for("yaml.pair"),On=Symbol.for("yaml.scalar"),zr=Symbol.for("yaml.seq"),gn=Symbol.for("yaml.node.type"),Ss=n=>!!n&&typeof n=="object"&&n[gn]===Qd,ws=n=>!!n&&typeof n=="object"&&n[gn]===ad,Ur=n=>!!n&&typeof n=="object"&&n[gn]===Ri,He=n=>!!n&&typeof n=="object"&&n[gn]===gS,Re=n=>!!n&&typeof n=="object"&&n[gn]===On,Hr=n=>!!n&&typeof n=="object"&&n[gn]===zr;function $e(n){if(n&&typeof n=="object")switch(n[gn]){case Ri:case zr:return!0}return!1}function Ve(n){if(n&&typeof n=="object")switch(n[gn]){case Qd:case Ri:case On:case zr:return!0}return!1}const VC=n=>(Re(n)||$e(n))&&!!n.anchor,Ht=Symbol("break visit"),mS=Symbol("skip children"),Mn=Symbol("remove node");function Di(n,e){const i=yS(e);ws(n)?Sr(null,n.contents,i,Object.freeze([n]))===Mn&&(n.contents=null):Sr(null,n,i,Object.freeze([]))}Di.BREAK=Ht;Di.SKIP=mS;Di.REMOVE=Mn;function Sr(n,e,i,s){const a=bS(n,e,i,s);if(Ve(a)||He(a))return vS(n,s,a),Sr(n,a,i,s);if(typeof a!="symbol"){if($e(e)){s=Object.freeze(s.concat(e));for(let o=0;o<e.items.length;++o){const c=Sr(o,e.items[o],i,s);if(typeof c=="number")o=c-1;else{if(c===Ht)return Ht;c===Mn&&(e.items.splice(o,1),o-=1)}}}else if(He(e)){s=Object.freeze(s.concat(e));const o=Sr("key",e.key,i,s);if(o===Ht)return Ht;o===Mn&&(e.key=null);const c=Sr("value",e.value,i,s);if(c===Ht)return Ht;c===Mn&&(e.value=null)}}return a}async function jc(n,e){const i=yS(e);ws(n)?await wr(null,n.contents,i,Object.freeze([n]))===Mn&&(n.contents=null):await wr(null,n,i,Object.freeze([]))}jc.BREAK=Ht;jc.SKIP=mS;jc.REMOVE=Mn;async function wr(n,e,i,s){const a=await bS(n,e,i,s);if(Ve(a)||He(a))return vS(n,s,a),wr(n,a,i,s);if(typeof a!="symbol"){if($e(e)){s=Object.freeze(s.concat(e));for(let o=0;o<e.items.length;++o){const c=await wr(o,e.items[o],i,s);if(typeof c=="number")o=c-1;else{if(c===Ht)return Ht;c===Mn&&(e.items.splice(o,1),o-=1)}}}else if(He(e)){s=Object.freeze(s.concat(e));const o=await wr("key",e.key,i,s);if(o===Ht)return Ht;o===Mn&&(e.key=null);const c=await wr("value",e.value,i,s);if(c===Ht)return Ht;c===Mn&&(e.value=null)}}return a}function yS(n){return typeof n=="object"&&(n.Collection||n.Node||n.Value)?Object.assign({Alias:n.Node,Map:n.Node,Scalar:n.Node,Seq:n.Node},n.Value&&{Map:n.Value,Scalar:n.Value,Seq:n.Value},n.Collection&&{Map:n.Collection,Seq:n.Collection},n):n}function bS(n,e,i,s){var a,o,c,f,h;if(typeof i=="function")return i(n,e,s);if(Ur(e))return(a=i.Map)==null?void 0:a.call(i,n,e,s);if(Hr(e))return(o=i.Seq)==null?void 0:o.call(i,n,e,s);if(He(e))return(c=i.Pair)==null?void 0:c.call(i,n,e,s);if(Re(e))return(f=i.Scalar)==null?void 0:f.call(i,n,e,s);if(Ss(e))return(h=i.Alias)==null?void 0:h.call(i,n,e,s)}function vS(n,e,i){const s=e[e.length-1];if($e(s))s.items[n]=i;else if(He(s))n==="key"?s.key=i:s.value=i;else if(ws(s))s.contents=i;else{const a=Ss(s)?"alias":"scalar";throw new Error(`Cannot replace node with ${a} parent`)}}const GC={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},KC=n=>n.replace(/[!,[\]{}]/g,e=>GC[e]);class At{constructor(e,i){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},At.defaultYaml,e),this.tags=Object.assign({},At.defaultTags,i)}clone(){const e=new At(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){const e=new At(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:At.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},At.defaultTags);break}return e}add(e,i){this.atNextDocument&&(this.yaml={explicit:At.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},At.defaultTags),this.atNextDocument=!1);const s=e.trim().split(/[ \t]+/),a=s.shift();switch(a){case"%TAG":{if(s.length!==2&&(i(0,"%TAG directive should contain exactly two parts"),s.length<2))return!1;const[o,c]=s;return this.tags[o]=c,!0}case"%YAML":{if(this.yaml.explicit=!0,s.length!==1)return i(0,"%YAML directive should contain exactly one part"),!1;const[o]=s;if(o==="1.1"||o==="1.2")return this.yaml.version=o,!0;{const c=/^\d+\.\d+$/.test(o);return i(6,`Unsupported YAML version ${o}`,c),!1}}default:return i(0,`Unknown directive ${a}`,!0),!1}}tagName(e,i){if(e==="!")return"!";if(e[0]!=="!")return i(`Not a valid tag: ${e}`),null;if(e[1]==="<"){const c=e.slice(2,-1);return c==="!"||c==="!!"?(i(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(e[e.length-1]!==">"&&i("Verbatim tags must end with a >"),c)}const[,s,a]=e.match(/^(.*!)([^!]*)$/s);a||i(`The ${e} tag has no suffix`);const o=this.tags[s];if(o)try{return o+decodeURIComponent(a)}catch(c){return i(String(c)),null}return s==="!"?e:(i(`Could not resolve tag: ${e}`),null)}tagString(e){for(const[i,s]of Object.entries(this.tags))if(e.startsWith(s))return i+KC(e.substring(s.length));return e[0]==="!"?e:`!<${e}>`}toString(e){const i=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],s=Object.entries(this.tags);let a;if(e&&s.length>0&&Ve(e.contents)){const o={};Di(e.contents,(c,f)=>{Ve(f)&&f.tag&&(o[f.tag]=!0)}),a=Object.keys(o)}else a=[];for(const[o,c]of s)o==="!!"&&c==="tag:yaml.org,2002:"||(!e||a.some(f=>f.startsWith(c)))&&i.push(`%TAG ${o} ${c}`);return i.join(`
|
|
132
|
+
`)}}At.defaultYaml={explicit:!1,version:"1.2"};At.defaultTags={"!!":"tag:yaml.org,2002:"};function SS(n){if(/[\x00-\x19\s,[\]{}]/.test(n)){const i=`Anchor must not contain whitespace or control characters: ${JSON.stringify(n)}`;throw new Error(i)}return!0}function wS(n){const e=new Set;return Di(n,{Value(i,s){s.anchor&&e.add(s.anchor)}}),e}function xS(n,e){for(let i=1;;++i){const s=`${n}${i}`;if(!e.has(s))return s}}function XC(n,e){const i=[],s=new Map;let a=null;return{onAnchor:o=>{i.push(o),a||(a=wS(n));const c=xS(e,a);return a.add(c),c},setAnchors:()=>{for(const o of i){const c=s.get(o);if(typeof c=="object"&&c.anchor&&(Re(c.node)||$e(c.node)))c.node.anchor=c.anchor;else{const f=new Error("Failed to resolve repeated object (this should not happen)");throw f.source=o,f}}},sourceObjects:s}}function xr(n,e,i,s){if(s&&typeof s=="object")if(Array.isArray(s))for(let a=0,o=s.length;a<o;++a){const c=s[a],f=xr(n,s,String(a),c);f===void 0?delete s[a]:f!==c&&(s[a]=f)}else if(s instanceof Map)for(const a of Array.from(s.keys())){const o=s.get(a),c=xr(n,s,a,o);c===void 0?s.delete(a):c!==o&&s.set(a,c)}else if(s instanceof Set)for(const a of Array.from(s)){const o=xr(n,s,a,a);o===void 0?s.delete(a):o!==a&&(s.delete(a),s.add(o))}else for(const[a,o]of Object.entries(s)){const c=xr(n,s,a,o);c===void 0?delete s[a]:c!==o&&(s[a]=c)}return n.call(e,i,s)}function dn(n,e,i){if(Array.isArray(n))return n.map((s,a)=>dn(s,String(a),i));if(n&&typeof n.toJSON=="function"){if(!i||!VC(n))return n.toJSON(e,i);const s={aliasCount:0,count:1,res:void 0};i.anchors.set(n,s),i.onCreate=o=>{s.res=o,delete i.onCreate};const a=n.toJSON(e,i);return i.onCreate&&i.onCreate(a),a}return typeof n=="bigint"&&!(i!=null&&i.keep)?Number(n):n}class Pd{constructor(e){Object.defineProperty(this,gn,{value:e})}clone(){const e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:i,maxAliasCount:s,onAnchor:a,reviver:o}={}){if(!ws(e))throw new TypeError("A document argument is required");const c={anchors:new Map,doc:e,keep:!0,mapAsMap:i===!0,mapKeyWarned:!1,maxAliasCount:typeof s=="number"?s:100},f=dn(this,"",c);if(typeof a=="function")for(const{count:h,res:p}of c.anchors.values())a(p,h);return typeof o=="function"?xr(o,{"":f},"",f):f}}class Rc extends Pd{constructor(e){super(Qd),this.source=e,Object.defineProperty(this,"tag",{set(){throw new Error("Alias nodes cannot have tags")}})}resolve(e){let i;return Di(e,{Node:(s,a)=>{if(a===this)return Di.BREAK;a.anchor===this.source&&(i=a)}}),i}toJSON(e,i){if(!i)return{source:this.source};const{anchors:s,doc:a,maxAliasCount:o}=i,c=this.resolve(a);if(!c){const h=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new ReferenceError(h)}let f=s.get(c);if(f||(dn(c,null,i),f=s.get(c)),!f||f.res===void 0){const h="This should not happen: Alias anchor was not resolved?";throw new ReferenceError(h)}if(o>=0&&(f.count+=1,f.aliasCount===0&&(f.aliasCount=rc(a,c,s)),f.count*f.aliasCount>o)){const h="Excessive alias count indicates a resource exhaustion attack";throw new ReferenceError(h)}return f.res}toString(e,i,s){const a=`*${this.source}`;if(e){if(SS(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){const o=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new Error(o)}if(e.implicitKey)return`${a} `}return a}}function rc(n,e,i){if(Ss(e)){const s=e.resolve(n),a=i&&s&&i.get(s);return a?a.count*a.aliasCount:0}else if($e(e)){let s=0;for(const a of e.items){const o=rc(n,a,i);o>s&&(s=o)}return s}else if(He(e)){const s=rc(n,e.key,i),a=rc(n,e.value,i);return Math.max(s,a)}return 1}const ES=n=>!n||typeof n!="function"&&typeof n!="object";class fe extends Pd{constructor(e){super(On),this.value=e}toJSON(e,i){return i!=null&&i.keep?this.value:dn(this.value,e,i)}toString(){return String(this.value)}}fe.BLOCK_FOLDED="BLOCK_FOLDED";fe.BLOCK_LITERAL="BLOCK_LITERAL";fe.PLAIN="PLAIN";fe.QUOTE_DOUBLE="QUOTE_DOUBLE";fe.QUOTE_SINGLE="QUOTE_SINGLE";const FC="tag:yaml.org,2002:";function YC(n,e,i){if(e){const s=i.filter(o=>o.tag===e),a=s.find(o=>!o.format)??s[0];if(!a)throw new Error(`Tag ${e} not found`);return a}return i.find(s=>{var a;return((a=s.identify)==null?void 0:a.call(s,n))&&!s.format})}function fl(n,e,i){var m,v,S;if(ws(n)&&(n=n.contents),Ve(n))return n;if(He(n)){const T=(v=(m=i.schema[Ri]).createNode)==null?void 0:v.call(m,i.schema,null,i);return T.items.push(n),T}(n instanceof String||n instanceof Number||n instanceof Boolean||typeof BigInt<"u"&&n instanceof BigInt)&&(n=n.valueOf());const{aliasDuplicateObjects:s,onAnchor:a,onTagObj:o,schema:c,sourceObjects:f}=i;let h;if(s&&n&&typeof n=="object"){if(h=f.get(n),h)return h.anchor||(h.anchor=a(n)),new Rc(h.anchor);h={anchor:null,node:null},f.set(n,h)}e!=null&&e.startsWith("!!")&&(e=FC+e.slice(2));let p=YC(n,e,c.tags);if(!p){if(n&&typeof n.toJSON=="function"&&(n=n.toJSON()),!n||typeof n!="object"){const T=new fe(n);return h&&(h.node=T),T}p=n instanceof Map?c[Ri]:Symbol.iterator in Object(n)?c[zr]:c[Ri]}o&&(o(p),delete i.onTagObj);const y=p!=null&&p.createNode?p.createNode(i.schema,n,i):typeof((S=p==null?void 0:p.nodeClass)==null?void 0:S.from)=="function"?p.nodeClass.from(i.schema,n,i):new fe(n);return e?y.tag=e:p.default||(y.tag=p.tag),h&&(h.node=y),y}function xc(n,e,i){let s=i;for(let a=e.length-1;a>=0;--a){const o=e[a];if(typeof o=="number"&&Number.isInteger(o)&&o>=0){const c=[];c[o]=s,s=c}else s=new Map([[o,s]])}return fl(s,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw new Error("This should not happen, please report a bug.")},schema:n,sourceObjects:new Map})}const Pa=n=>n==null||typeof n=="object"&&!!n[Symbol.iterator]().next().done;class TS extends Pd{constructor(e,i){super(e),Object.defineProperty(this,"schema",{value:i,configurable:!0,enumerable:!1,writable:!0})}clone(e){const i=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(i.schema=e),i.items=i.items.map(s=>Ve(s)||He(s)?s.clone(e):s),this.range&&(i.range=this.range.slice()),i}addIn(e,i){if(Pa(e))this.add(i);else{const[s,...a]=e,o=this.get(s,!0);if($e(o))o.addIn(a,i);else if(o===void 0&&this.schema)this.set(s,xc(this.schema,a,i));else throw new Error(`Expected YAML collection at ${s}. Remaining path: ${a}`)}}deleteIn(e){const[i,...s]=e;if(s.length===0)return this.delete(i);const a=this.get(i,!0);if($e(a))return a.deleteIn(s);throw new Error(`Expected YAML collection at ${i}. Remaining path: ${s}`)}getIn(e,i){const[s,...a]=e,o=this.get(s,!0);return a.length===0?!i&&Re(o)?o.value:o:$e(o)?o.getIn(a,i):void 0}hasAllNullValues(e){return this.items.every(i=>{if(!He(i))return!1;const s=i.value;return s==null||e&&Re(s)&&s.value==null&&!s.commentBefore&&!s.comment&&!s.tag})}hasIn(e){const[i,...s]=e;if(s.length===0)return this.has(i);const a=this.get(i,!0);return $e(a)?a.hasIn(s):!1}setIn(e,i){const[s,...a]=e;if(a.length===0)this.set(s,i);else{const o=this.get(s,!0);if($e(o))o.setIn(a,i);else if(o===void 0&&this.schema)this.set(s,xc(this.schema,a,i));else throw new Error(`Expected YAML collection at ${s}. Remaining path: ${a}`)}}}const QC=n=>n.replace(/^(?!$)(?: $)?/gm,"#");function ti(n,e){return/^\n+$/.test(n)?n.substring(1):e?n.replace(/^(?! *$)/gm,e):n}const ds=(n,e,i)=>n.endsWith(`
|
|
133
|
+
`)?ti(i,e):i.includes(`
|
|
134
|
+
`)?`
|
|
135
|
+
`+ti(i,e):(n.endsWith(" ")?"":" ")+i,_S="flow",ld="block",ac="quoted";function Dc(n,e,i="flow",{indentAtStart:s,lineWidth:a=80,minContentWidth:o=20,onFold:c,onOverflow:f}={}){if(!a||a<0)return n;a<o&&(o=0);const h=Math.max(1+o,1+a-e.length);if(n.length<=h)return n;const p=[],y={};let m=a-e.length;typeof s=="number"&&(s>a-Math.max(2,o)?p.push(0):m=a-s);let v,S,T=!1,x=-1,E=-1,A=-1;i===ld&&(x=l0(n,x,e.length),x!==-1&&(m=x+h));for(let B;B=n[x+=1];){if(i===ac&&B==="\\"){switch(E=x,n[x+1]){case"x":x+=3;break;case"u":x+=5;break;case"U":x+=9;break;default:x+=1}A=x}if(B===`
|
|
136
|
+
`)i===ld&&(x=l0(n,x,e.length)),m=x+e.length+h,v=void 0;else{if(B===" "&&S&&S!==" "&&S!==`
|
|
137
|
+
`&&S!==" "){const V=n[x+1];V&&V!==" "&&V!==`
|
|
138
|
+
`&&V!==" "&&(v=x)}if(x>=m)if(v)p.push(v),m=v+h,v=void 0;else if(i===ac){for(;S===" "||S===" ";)S=B,B=n[x+=1],T=!0;const V=x>A+1?x-2:E-1;if(y[V])return n;p.push(V),y[V]=!0,m=V+h,v=void 0}else T=!0}S=B}if(T&&f&&f(),p.length===0)return n;c&&c();let N=n.slice(0,p[0]);for(let B=0;B<p.length;++B){const V=p[B],$=p[B+1]||n.length;V===0?N=`
|
|
139
|
+
${e}${n.slice(0,$)}`:(i===ac&&y[V]&&(N+=`${n[V]}\\`),N+=`
|
|
140
|
+
${e}${n.slice(V+1,$)}`)}return N}function l0(n,e,i){let s=e,a=e+1,o=n[a];for(;o===" "||o===" ";)if(e<a+i)o=n[++e];else{do o=n[++e];while(o&&o!==`
|
|
141
|
+
`);s=e,a=e+1,o=n[a]}return s}const Bc=(n,e)=>({indentAtStart:e?n.indent.length:n.indentAtStart,lineWidth:n.options.lineWidth,minContentWidth:n.options.minContentWidth}),zc=n=>/^(%|---|\.\.\.)/m.test(n);function PC(n,e,i){if(!e||e<0)return!1;const s=e-i,a=n.length;if(a<=s)return!1;for(let o=0,c=0;o<a;++o)if(n[o]===`
|
|
142
|
+
`){if(o-c>s)return!0;if(c=o+1,a-c<=s)return!1}return!0}function ol(n,e){const i=JSON.stringify(n);if(e.options.doubleQuotedAsJSON)return i;const{implicitKey:s}=e,a=e.options.doubleQuotedMinMultiLineLength,o=e.indent||(zc(n)?" ":"");let c="",f=0;for(let h=0,p=i[h];p;p=i[++h])if(p===" "&&i[h+1]==="\\"&&i[h+2]==="n"&&(c+=i.slice(f,h)+"\\ ",h+=1,f=h,p="\\"),p==="\\")switch(i[h+1]){case"u":{c+=i.slice(f,h);const y=i.substr(h+2,4);switch(y){case"0000":c+="\\0";break;case"0007":c+="\\a";break;case"000b":c+="\\v";break;case"001b":c+="\\e";break;case"0085":c+="\\N";break;case"00a0":c+="\\_";break;case"2028":c+="\\L";break;case"2029":c+="\\P";break;default:y.substr(0,2)==="00"?c+="\\x"+y.substr(2):c+=i.substr(h,6)}h+=5,f=h+1}break;case"n":if(s||i[h+2]==='"'||i.length<a)h+=1;else{for(c+=i.slice(f,h)+`
|
|
143
|
+
|
|
144
|
+
`;i[h+2]==="\\"&&i[h+3]==="n"&&i[h+4]!=='"';)c+=`
|
|
145
|
+
`,h+=2;c+=o,i[h+2]===" "&&(c+="\\"),h+=1,f=h+1}break;default:h+=1}return c=f?c+i.slice(f):i,s?c:Dc(c,o,ac,Bc(e,!1))}function od(n,e){if(e.options.singleQuote===!1||e.implicitKey&&n.includes(`
|
|
146
|
+
`)||/[ \t]\n|\n[ \t]/.test(n))return ol(n,e);const i=e.indent||(zc(n)?" ":""),s="'"+n.replace(/'/g,"''").replace(/\n+/g,`$&
|
|
147
|
+
${i}`)+"'";return e.implicitKey?s:Dc(s,i,_S,Bc(e,!1))}function Er(n,e){const{singleQuote:i}=e.options;let s;if(i===!1)s=ol;else{const a=n.includes('"'),o=n.includes("'");a&&!o?s=od:o&&!a?s=ol:s=i?od:ol}return s(n,e)}let cd;try{cd=new RegExp(`(^|(?<!
|
|
148
|
+
))
|
|
149
|
+
+(?!
|
|
150
|
+
|$)`,"g")}catch{cd=/\n+(?!\n|$)/g}function lc({comment:n,type:e,value:i},s,a,o){const{blockQuote:c,commentString:f,lineWidth:h}=s.options;if(!c||/\n[\t ]+$/.test(i)||/^\s*$/.test(i))return Er(i,s);const p=s.indent||(s.forceBlockIndent||zc(i)?" ":""),y=c==="literal"?!0:c==="folded"||e===fe.BLOCK_FOLDED?!1:e===fe.BLOCK_LITERAL?!0:!PC(i,h,p.length);if(!i)return y?`|
|
|
151
|
+
`:`>
|
|
152
|
+
`;let m,v;for(v=i.length;v>0;--v){const z=i[v-1];if(z!==`
|
|
153
|
+
`&&z!==" "&&z!==" ")break}let S=i.substring(v);const T=S.indexOf(`
|
|
154
|
+
`);T===-1?m="-":i===S||T!==S.length-1?(m="+",o&&o()):m="",S&&(i=i.slice(0,-S.length),S[S.length-1]===`
|
|
155
|
+
`&&(S=S.slice(0,-1)),S=S.replace(cd,`$&${p}`));let x=!1,E,A=-1;for(E=0;E<i.length;++E){const z=i[E];if(z===" ")x=!0;else if(z===`
|
|
156
|
+
`)A=E;else break}let N=i.substring(0,A<E?A+1:E);N&&(i=i.substring(N.length),N=N.replace(/\n+/g,`$&${p}`));let V=(y?"|":">")+(x?p?"2":"1":"")+m;if(n&&(V+=" "+f(n.replace(/ ?[\r\n]+/g," ")),a&&a()),y)return i=i.replace(/\n+/g,`$&${p}`),`${V}
|
|
157
|
+
${p}${N}${i}${S}`;i=i.replace(/\n+/g,`
|
|
158
|
+
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${p}`);const $=Dc(`${N}${i}${S}`,p,ld,Bc(s,!0));return`${V}
|
|
159
|
+
${p}${$}`}function JC(n,e,i,s){const{type:a,value:o}=n,{actualString:c,implicitKey:f,indent:h,indentStep:p,inFlow:y}=e;if(f&&o.includes(`
|
|
160
|
+
`)||y&&/[[\]{},]/.test(o))return Er(o,e);if(!o||/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(o))return f||y||!o.includes(`
|
|
161
|
+
`)?Er(o,e):lc(n,e,i,s);if(!f&&!y&&a!==fe.PLAIN&&o.includes(`
|
|
162
|
+
`))return lc(n,e,i,s);if(zc(o)){if(h==="")return e.forceBlockIndent=!0,lc(n,e,i,s);if(f&&h===p)return Er(o,e)}const m=o.replace(/\n+/g,`$&
|
|
163
|
+
${h}`);if(c){const v=x=>{var E;return x.default&&x.tag!=="tag:yaml.org,2002:str"&&((E=x.test)==null?void 0:E.test(m))},{compat:S,tags:T}=e.doc.schema;if(T.some(v)||S!=null&&S.some(v))return Er(o,e)}return f?m:Dc(m,h,_S,Bc(e,!1))}function yl(n,e,i,s){const{implicitKey:a,inFlow:o}=e,c=typeof n.value=="string"?n:Object.assign({},n,{value:String(n.value)});let{type:f}=n;f!==fe.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(c.value)&&(f=fe.QUOTE_DOUBLE);const h=y=>{switch(y){case fe.BLOCK_FOLDED:case fe.BLOCK_LITERAL:return a||o?Er(c.value,e):lc(c,e,i,s);case fe.QUOTE_DOUBLE:return ol(c.value,e);case fe.QUOTE_SINGLE:return od(c.value,e);case fe.PLAIN:return JC(c,e,i,s);default:return null}};let p=h(f);if(p===null){const{defaultKeyType:y,defaultStringType:m}=e.options,v=a&&y||m;if(p=h(v),p===null)throw new Error(`Unsupported default string type ${v}`)}return p}function AS(n,e){const i=Object.assign({blockQuote:!0,commentString:QC,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trueStr:"true",verifyAliasOrder:!0},n.schema.toStringOptions,e);let s;switch(i.collectionStyle){case"block":s=!1;break;case"flow":s=!0;break;default:s=null}return{anchors:new Set,doc:n,flowCollectionPadding:i.flowCollectionPadding?" ":"",indent:"",indentStep:typeof i.indent=="number"?" ".repeat(i.indent):" ",inFlow:s,options:i}}function ZC(n,e){var a;if(e.tag){const o=n.filter(c=>c.tag===e.tag);if(o.length>0)return o.find(c=>c.format===e.format)??o[0]}let i,s;if(Re(e)){s=e.value;let o=n.filter(c=>{var f;return(f=c.identify)==null?void 0:f.call(c,s)});if(o.length>1){const c=o.filter(f=>f.test);c.length>0&&(o=c)}i=o.find(c=>c.format===e.format)??o.find(c=>!c.format)}else s=e,i=n.find(o=>o.nodeClass&&s instanceof o.nodeClass);if(!i){const o=((a=s==null?void 0:s.constructor)==null?void 0:a.name)??typeof s;throw new Error(`Tag not resolved for ${o} value`)}return i}function WC(n,e,{anchors:i,doc:s}){if(!s.directives)return"";const a=[],o=(Re(n)||$e(n))&&n.anchor;o&&SS(o)&&(i.add(o),a.push(`&${o}`));const c=n.tag?n.tag:e.default?null:e.tag;return c&&a.push(s.directives.tagString(c)),a.join(" ")}function Mr(n,e,i,s){var h;if(He(n))return n.toString(e,i,s);if(Ss(n)){if(e.doc.directives)return n.toString(e);if((h=e.resolvedAliases)!=null&&h.has(n))throw new TypeError("Cannot stringify circular structure without alias nodes");e.resolvedAliases?e.resolvedAliases.add(n):e.resolvedAliases=new Set([n]),n=n.resolve(e.doc)}let a;const o=Ve(n)?n:e.doc.createNode(n,{onTagObj:p=>a=p});a||(a=ZC(e.doc.schema.tags,o));const c=WC(o,a,e);c.length>0&&(e.indentAtStart=(e.indentAtStart??0)+c.length+1);const f=typeof a.stringify=="function"?a.stringify(o,e,i,s):Re(o)?yl(o,e,i,s):o.toString(e,i,s);return c?Re(o)||f[0]==="{"||f[0]==="["?`${c} ${f}`:`${c}
|
|
164
|
+
${e.indent}${f}`:f}function eN({key:n,value:e},i,s,a){const{allNullValues:o,doc:c,indent:f,indentStep:h,options:{commentString:p,indentSeq:y,simpleKeys:m}}=i;let v=Ve(n)&&n.comment||null;if(m){if(v)throw new Error("With simple keys, key nodes cannot have comments");if($e(n)||!Ve(n)&&typeof n=="object"){const Q="With simple keys, collection cannot be used as a key value";throw new Error(Q)}}let S=!m&&(!n||v&&e==null&&!i.inFlow||$e(n)||(Re(n)?n.type===fe.BLOCK_FOLDED||n.type===fe.BLOCK_LITERAL:typeof n=="object"));i=Object.assign({},i,{allNullValues:!1,implicitKey:!S&&(m||!o),indent:f+h});let T=!1,x=!1,E=Mr(n,i,()=>T=!0,()=>x=!0);if(!S&&!i.inFlow&&E.length>1024){if(m)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");S=!0}if(i.inFlow){if(o||e==null)return T&&s&&s(),E===""?"?":S?`? ${E}`:E}else if(o&&!m||e==null&&S)return E=`? ${E}`,v&&!T?E+=ds(E,i.indent,p(v)):x&&a&&a(),E;T&&(v=null),S?(v&&(E+=ds(E,i.indent,p(v))),E=`? ${E}
|
|
165
|
+
${f}:`):(E=`${E}:`,v&&(E+=ds(E,i.indent,p(v))));let A,N,B;Ve(e)?(A=!!e.spaceBefore,N=e.commentBefore,B=e.comment):(A=!1,N=null,B=null,e&&typeof e=="object"&&(e=c.createNode(e))),i.implicitKey=!1,!S&&!v&&Re(e)&&(i.indentAtStart=E.length+1),x=!1,!y&&h.length>=2&&!i.inFlow&&!S&&Hr(e)&&!e.flow&&!e.tag&&!e.anchor&&(i.indent=i.indent.substring(2));let V=!1;const $=Mr(e,i,()=>V=!0,()=>x=!0);let z=" ";if(v||A||N){if(z=A?`
|
|
166
|
+
`:"",N){const Q=p(N);z+=`
|
|
167
|
+
${ti(Q,i.indent)}`}$===""&&!i.inFlow?z===`
|
|
168
|
+
`&&(z=`
|
|
169
|
+
|
|
170
|
+
`):z+=`
|
|
171
|
+
${i.indent}`}else if(!S&&$e(e)){const Q=$[0],H=$.indexOf(`
|
|
172
|
+
`),L=H!==-1,ne=i.inFlow??e.flow??e.items.length===0;if(L||!ne){let ae=!1;if(L&&(Q==="&"||Q==="!")){let G=$.indexOf(" ");Q==="&"&&G!==-1&&G<H&&$[G+1]==="!"&&(G=$.indexOf(" ",G+1)),(G===-1||H<G)&&(ae=!0)}ae||(z=`
|
|
173
|
+
${i.indent}`)}}else($===""||$[0]===`
|
|
174
|
+
`)&&(z="");return E+=z+$,i.inFlow?V&&s&&s():B&&!V?E+=ds(E,i.indent,p(B)):x&&a&&a(),E}function CS(n,e){(n==="debug"||n==="warn")&&(typeof process<"u"&&process.emitWarning?process.emitWarning(e):console.warn(e))}const Ko="<<",ni={identify:n=>n===Ko||typeof n=="symbol"&&n.description===Ko,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new fe(Symbol(Ko)),{addToJSMap:NS}),stringify:()=>Ko},tN=(n,e)=>(ni.identify(e)||Re(e)&&(!e.type||e.type===fe.PLAIN)&&ni.identify(e.value))&&(n==null?void 0:n.doc.schema.tags.some(i=>i.tag===ni.tag&&i.default));function NS(n,e,i){if(i=n&&Ss(i)?i.resolve(n.doc):i,Hr(i))for(const s of i.items)Oh(n,e,s);else if(Array.isArray(i))for(const s of i)Oh(n,e,s);else Oh(n,e,i)}function Oh(n,e,i){const s=n&&Ss(i)?i.resolve(n.doc):i;if(!Ur(s))throw new Error("Merge sources must be maps or map aliases");const a=s.toJSON(null,n,Map);for(const[o,c]of a)e instanceof Map?e.has(o)||e.set(o,c):e instanceof Set?e.add(o):Object.prototype.hasOwnProperty.call(e,o)||Object.defineProperty(e,o,{value:c,writable:!0,enumerable:!0,configurable:!0});return e}function kS(n,e,{key:i,value:s}){if(Ve(i)&&i.addToJSMap)i.addToJSMap(n,e,s);else if(tN(n,i))NS(n,e,s);else{const a=dn(i,"",n);if(e instanceof Map)e.set(a,dn(s,a,n));else if(e instanceof Set)e.add(a);else{const o=nN(i,a,n),c=dn(s,o,n);o in e?Object.defineProperty(e,o,{value:c,writable:!0,enumerable:!0,configurable:!0}):e[o]=c}}return e}function nN(n,e,i){if(e===null)return"";if(typeof e!="object")return String(e);if(Ve(n)&&(i!=null&&i.doc)){const s=AS(i.doc,{});s.anchors=new Set;for(const o of i.anchors.keys())s.anchors.add(o.anchor);s.inFlow=!0,s.inStringifyKey=!0;const a=n.toString(s);if(!i.mapKeyWarned){let o=JSON.stringify(a);o.length>40&&(o=o.substring(0,36)+'..."'),CS(i.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${o}. Set mapAsMap: true to use object keys.`),i.mapKeyWarned=!0}return a}return JSON.stringify(e)}function Jd(n,e,i){const s=fl(n,void 0,i),a=fl(e,void 0,i);return new wt(s,a)}class wt{constructor(e,i=null){Object.defineProperty(this,gn,{value:gS}),this.key=e,this.value=i}clone(e){let{key:i,value:s}=this;return Ve(i)&&(i=i.clone(e)),Ve(s)&&(s=s.clone(e)),new wt(i,s)}toJSON(e,i){const s=i!=null&&i.mapAsMap?new Map:{};return kS(i,s,this)}toString(e,i,s){return e!=null&&e.doc?eN(this,e,i,s):JSON.stringify(this)}}function MS(n,e,i){return(e.inFlow??n.flow?sN:iN)(n,e,i)}function iN({comment:n,items:e},i,{blockItemPrefix:s,flowChars:a,itemIndent:o,onChompKeep:c,onComment:f}){const{indent:h,options:{commentString:p}}=i,y=Object.assign({},i,{indent:o,type:null});let m=!1;const v=[];for(let T=0;T<e.length;++T){const x=e[T];let E=null;if(Ve(x))!m&&x.spaceBefore&&v.push(""),Ec(i,v,x.commentBefore,m),x.comment&&(E=x.comment);else if(He(x)){const N=Ve(x.key)?x.key:null;N&&(!m&&N.spaceBefore&&v.push(""),Ec(i,v,N.commentBefore,m))}m=!1;let A=Mr(x,y,()=>E=null,()=>m=!0);E&&(A+=ds(A,o,p(E))),m&&E&&(m=!1),v.push(s+A)}let S;if(v.length===0)S=a.start+a.end;else{S=v[0];for(let T=1;T<v.length;++T){const x=v[T];S+=x?`
|
|
175
|
+
${h}${x}`:`
|
|
176
|
+
`}}return n?(S+=`
|
|
177
|
+
`+ti(p(n),h),f&&f()):m&&c&&c(),S}function sN({items:n},e,{flowChars:i,itemIndent:s}){const{indent:a,indentStep:o,flowCollectionPadding:c,options:{commentString:f}}=e;s+=o;const h=Object.assign({},e,{indent:s,inFlow:!0,type:null});let p=!1,y=0;const m=[];for(let T=0;T<n.length;++T){const x=n[T];let E=null;if(Ve(x))x.spaceBefore&&m.push(""),Ec(e,m,x.commentBefore,!1),x.comment&&(E=x.comment);else if(He(x)){const N=Ve(x.key)?x.key:null;N&&(N.spaceBefore&&m.push(""),Ec(e,m,N.commentBefore,!1),N.comment&&(p=!0));const B=Ve(x.value)?x.value:null;B?(B.comment&&(E=B.comment),B.commentBefore&&(p=!0)):x.value==null&&(N!=null&&N.comment)&&(E=N.comment)}E&&(p=!0);let A=Mr(x,h,()=>E=null);T<n.length-1&&(A+=","),E&&(A+=ds(A,s,f(E))),!p&&(m.length>y||A.includes(`
|
|
178
|
+
`))&&(p=!0),m.push(A),y=m.length}const{start:v,end:S}=i;if(m.length===0)return v+S;if(!p){const T=m.reduce((x,E)=>x+E.length+2,2);p=e.options.lineWidth>0&&T>e.options.lineWidth}if(p){let T=v;for(const x of m)T+=x?`
|
|
179
|
+
${o}${a}${x}`:`
|
|
180
|
+
`;return`${T}
|
|
181
|
+
${a}${S}`}else return`${v}${c}${m.join(" ")}${c}${S}`}function Ec({indent:n,options:{commentString:e}},i,s,a){if(s&&a&&(s=s.replace(/^\n+/,"")),s){const o=ti(e(s),n);i.push(o.trimStart())}}function ps(n,e){const i=Re(e)?e.value:e;for(const s of n)if(He(s)&&(s.key===e||s.key===i||Re(s.key)&&s.key.value===i))return s}class Pt extends TS{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(Ri,e),this.items=[]}static from(e,i,s){const{keepUndefined:a,replacer:o}=s,c=new this(e),f=(h,p)=>{if(typeof o=="function")p=o.call(i,h,p);else if(Array.isArray(o)&&!o.includes(h))return;(p!==void 0||a)&&c.items.push(Jd(h,p,s))};if(i instanceof Map)for(const[h,p]of i)f(h,p);else if(i&&typeof i=="object")for(const h of Object.keys(i))f(h,i[h]);return typeof e.sortMapEntries=="function"&&c.items.sort(e.sortMapEntries),c}add(e,i){var c;let s;He(e)?s=e:!e||typeof e!="object"||!("key"in e)?s=new wt(e,e==null?void 0:e.value):s=new wt(e.key,e.value);const a=ps(this.items,s.key),o=(c=this.schema)==null?void 0:c.sortMapEntries;if(a){if(!i)throw new Error(`Key ${s.key} already set`);Re(a.value)&&ES(s.value)?a.value.value=s.value:a.value=s.value}else if(o){const f=this.items.findIndex(h=>o(s,h)<0);f===-1?this.items.push(s):this.items.splice(f,0,s)}else this.items.push(s)}delete(e){const i=ps(this.items,e);return i?this.items.splice(this.items.indexOf(i),1).length>0:!1}get(e,i){const s=ps(this.items,e),a=s==null?void 0:s.value;return(!i&&Re(a)?a.value:a)??void 0}has(e){return!!ps(this.items,e)}set(e,i){this.add(new wt(e,i),!0)}toJSON(e,i,s){const a=s?new s:i!=null&&i.mapAsMap?new Map:{};i!=null&&i.onCreate&&i.onCreate(a);for(const o of this.items)kS(i,a,o);return a}toString(e,i,s){if(!e)return JSON.stringify(this);for(const a of this.items)if(!He(a))throw new Error(`Map items must all be pairs; found ${JSON.stringify(a)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),MS(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:s,onComment:i})}}const qr={collection:"map",default:!0,nodeClass:Pt,tag:"tag:yaml.org,2002:map",resolve(n,e){return Ur(n)||e("Expected a mapping for this tag"),n},createNode:(n,e,i)=>Pt.from(n,e,i)};class Bi extends TS{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(zr,e),this.items=[]}add(e){this.items.push(e)}delete(e){const i=Xo(e);return typeof i!="number"?!1:this.items.splice(i,1).length>0}get(e,i){const s=Xo(e);if(typeof s!="number")return;const a=this.items[s];return!i&&Re(a)?a.value:a}has(e){const i=Xo(e);return typeof i=="number"&&i<this.items.length}set(e,i){const s=Xo(e);if(typeof s!="number")throw new Error(`Expected a valid index, not ${e}.`);const a=this.items[s];Re(a)&&ES(i)?a.value=i:this.items[s]=i}toJSON(e,i){const s=[];i!=null&&i.onCreate&&i.onCreate(s);let a=0;for(const o of this.items)s.push(dn(o,String(a++),i));return s}toString(e,i,s){return e?MS(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+" ",onChompKeep:s,onComment:i}):JSON.stringify(this)}static from(e,i,s){const{replacer:a}=s,o=new this(e);if(i&&Symbol.iterator in Object(i)){let c=0;for(let f of i){if(typeof a=="function"){const h=i instanceof Set?f:String(c++);f=a.call(i,h,f)}o.items.push(fl(f,void 0,s))}}return o}}function Xo(n){let e=Re(n)?n.value:n;return e&&typeof e=="string"&&(e=Number(e)),typeof e=="number"&&Number.isInteger(e)&&e>=0?e:null}const Ir={collection:"seq",default:!0,nodeClass:Bi,tag:"tag:yaml.org,2002:seq",resolve(n,e){return Hr(n)||e("Expected a sequence for this tag"),n},createNode:(n,e,i)=>Bi.from(n,e,i)},Uc={identify:n=>typeof n=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:n=>n,stringify(n,e,i,s){return e=Object.assign({actualString:!0},e),yl(n,e,i,s)}},Hc={identify:n=>n==null,createNode:()=>new fe(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new fe(null),stringify:({source:n},e)=>typeof n=="string"&&Hc.test.test(n)?n:e.options.nullStr},Zd={identify:n=>typeof n=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:n=>new fe(n[0]==="t"||n[0]==="T"),stringify({source:n,value:e},i){if(n&&Zd.test.test(n)){const s=n[0]==="t"||n[0]==="T";if(e===s)return n}return e?i.options.trueStr:i.options.falseStr}};function wn({format:n,minFractionDigits:e,tag:i,value:s}){if(typeof s=="bigint")return String(s);const a=typeof s=="number"?s:Number(s);if(!isFinite(a))return isNaN(a)?".nan":a<0?"-.inf":".inf";let o=JSON.stringify(s);if(!n&&e&&(!i||i==="tag:yaml.org,2002:float")&&/^\d/.test(o)){let c=o.indexOf(".");c<0&&(c=o.length,o+=".");let f=e-(o.length-c-1);for(;f-- >0;)o+="0"}return o}const OS={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:n=>n.slice(-3).toLowerCase()==="nan"?NaN:n[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:wn},LS={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:n=>parseFloat(n),stringify(n){const e=Number(n.value);return isFinite(e)?e.toExponential():wn(n)}},jS={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(n){const e=new fe(parseFloat(n)),i=n.indexOf(".");return i!==-1&&n[n.length-1]==="0"&&(e.minFractionDigits=n.length-i-1),e},stringify:wn},qc=n=>typeof n=="bigint"||Number.isInteger(n),Wd=(n,e,i,{intAsBigInt:s})=>s?BigInt(n):parseInt(n.substring(e),i);function RS(n,e,i){const{value:s}=n;return qc(s)&&s>=0?i+s.toString(e):wn(n)}const DS={identify:n=>qc(n)&&n>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(n,e,i)=>Wd(n,2,8,i),stringify:n=>RS(n,8,"0o")},BS={identify:qc,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(n,e,i)=>Wd(n,0,10,i),stringify:wn},zS={identify:n=>qc(n)&&n>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(n,e,i)=>Wd(n,2,16,i),stringify:n=>RS(n,16,"0x")},rN=[qr,Ir,Uc,Hc,Zd,DS,BS,zS,OS,LS,jS];function o0(n){return typeof n=="bigint"||Number.isInteger(n)}const Fo=({value:n})=>JSON.stringify(n),aN=[{identify:n=>typeof n=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:n=>n,stringify:Fo},{identify:n=>n==null,createNode:()=>new fe(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:Fo},{identify:n=>typeof n=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true|false$/,resolve:n=>n==="true",stringify:Fo},{identify:o0,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(n,e,{intAsBigInt:i})=>i?BigInt(n):parseInt(n,10),stringify:({value:n})=>o0(n)?n.toString():JSON.stringify(n)},{identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:n=>parseFloat(n),stringify:Fo}],lN={default:!0,tag:"",test:/^/,resolve(n,e){return e(`Unresolved plain scalar ${JSON.stringify(n)}`),n}},oN=[qr,Ir].concat(aN,lN),ep={identify:n=>n instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(n,e){if(typeof Buffer=="function")return Buffer.from(n,"base64");if(typeof atob=="function"){const i=atob(n.replace(/[\n\r]/g,"")),s=new Uint8Array(i.length);for(let a=0;a<i.length;++a)s[a]=i.charCodeAt(a);return s}else return e("This environment does not support reading binary tags; either Buffer or atob is required"),n},stringify({comment:n,type:e,value:i},s,a,o){const c=i;let f;if(typeof Buffer=="function")f=c instanceof Buffer?c.toString("base64"):Buffer.from(c.buffer).toString("base64");else if(typeof btoa=="function"){let h="";for(let p=0;p<c.length;++p)h+=String.fromCharCode(c[p]);f=btoa(h)}else throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(e||(e=fe.BLOCK_LITERAL),e!==fe.QUOTE_DOUBLE){const h=Math.max(s.options.lineWidth-s.indent.length,s.options.minContentWidth),p=Math.ceil(f.length/h),y=new Array(p);for(let m=0,v=0;m<p;++m,v+=h)y[m]=f.substr(v,h);f=y.join(e===fe.BLOCK_LITERAL?`
|
|
182
|
+
`:" ")}return yl({comment:n,type:e,value:f},s,a,o)}};function US(n,e){if(Hr(n))for(let i=0;i<n.items.length;++i){let s=n.items[i];if(!He(s)){if(Ur(s)){s.items.length>1&&e("Each pair must have its own sequence indicator");const a=s.items[0]||new wt(new fe(null));if(s.commentBefore&&(a.key.commentBefore=a.key.commentBefore?`${s.commentBefore}
|
|
183
|
+
${a.key.commentBefore}`:s.commentBefore),s.comment){const o=a.value??a.key;o.comment=o.comment?`${s.comment}
|
|
184
|
+
${o.comment}`:s.comment}s=a}n.items[i]=He(s)?s:new wt(s)}}else e("Expected a sequence for this tag");return n}function HS(n,e,i){const{replacer:s}=i,a=new Bi(n);a.tag="tag:yaml.org,2002:pairs";let o=0;if(e&&Symbol.iterator in Object(e))for(let c of e){typeof s=="function"&&(c=s.call(e,String(o++),c));let f,h;if(Array.isArray(c))if(c.length===2)f=c[0],h=c[1];else throw new TypeError(`Expected [key, value] tuple: ${c}`);else if(c&&c instanceof Object){const p=Object.keys(c);if(p.length===1)f=p[0],h=c[f];else throw new TypeError(`Expected tuple with one key, not ${p.length} keys`)}else f=c;a.items.push(Jd(f,h,i))}return a}const tp={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:US,createNode:HS};class _r extends Bi{constructor(){super(),this.add=Pt.prototype.add.bind(this),this.delete=Pt.prototype.delete.bind(this),this.get=Pt.prototype.get.bind(this),this.has=Pt.prototype.has.bind(this),this.set=Pt.prototype.set.bind(this),this.tag=_r.tag}toJSON(e,i){if(!i)return super.toJSON(e);const s=new Map;i!=null&&i.onCreate&&i.onCreate(s);for(const a of this.items){let o,c;if(He(a)?(o=dn(a.key,"",i),c=dn(a.value,o,i)):o=dn(a,"",i),s.has(o))throw new Error("Ordered maps must not include duplicate keys");s.set(o,c)}return s}static from(e,i,s){const a=HS(e,i,s),o=new this;return o.items=a.items,o}}_r.tag="tag:yaml.org,2002:omap";const np={collection:"seq",identify:n=>n instanceof Map,nodeClass:_r,default:!1,tag:"tag:yaml.org,2002:omap",resolve(n,e){const i=US(n,e),s=[];for(const{key:a}of i.items)Re(a)&&(s.includes(a.value)?e(`Ordered maps must not include duplicate keys: ${a.value}`):s.push(a.value));return Object.assign(new _r,i)},createNode:(n,e,i)=>_r.from(n,e,i)};function qS({value:n,source:e},i){return e&&(n?IS:$S).test.test(e)?e:n?i.options.trueStr:i.options.falseStr}const IS={identify:n=>n===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new fe(!0),stringify:qS},$S={identify:n=>n===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new fe(!1),stringify:qS},cN={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:n=>n.slice(-3).toLowerCase()==="nan"?NaN:n[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:wn},uN={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:n=>parseFloat(n.replace(/_/g,"")),stringify(n){const e=Number(n.value);return isFinite(e)?e.toExponential():wn(n)}},fN={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(n){const e=new fe(parseFloat(n.replace(/_/g,""))),i=n.indexOf(".");if(i!==-1){const s=n.substring(i+1).replace(/_/g,"");s[s.length-1]==="0"&&(e.minFractionDigits=s.length)}return e},stringify:wn},bl=n=>typeof n=="bigint"||Number.isInteger(n);function Ic(n,e,i,{intAsBigInt:s}){const a=n[0];if((a==="-"||a==="+")&&(e+=1),n=n.substring(e).replace(/_/g,""),s){switch(i){case 2:n=`0b${n}`;break;case 8:n=`0o${n}`;break;case 16:n=`0x${n}`;break}const c=BigInt(n);return a==="-"?BigInt(-1)*c:c}const o=parseInt(n,i);return a==="-"?-1*o:o}function ip(n,e,i){const{value:s}=n;if(bl(s)){const a=s.toString(e);return s<0?"-"+i+a.substr(1):i+a}return wn(n)}const hN={identify:bl,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(n,e,i)=>Ic(n,2,2,i),stringify:n=>ip(n,2,"0b")},dN={identify:bl,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(n,e,i)=>Ic(n,1,8,i),stringify:n=>ip(n,8,"0")},pN={identify:bl,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(n,e,i)=>Ic(n,0,10,i),stringify:wn},gN={identify:bl,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(n,e,i)=>Ic(n,2,16,i),stringify:n=>ip(n,16,"0x")};class Ar extends Pt{constructor(e){super(e),this.tag=Ar.tag}add(e){let i;He(e)?i=e:e&&typeof e=="object"&&"key"in e&&"value"in e&&e.value===null?i=new wt(e.key,null):i=new wt(e,null),ps(this.items,i.key)||this.items.push(i)}get(e,i){const s=ps(this.items,e);return!i&&He(s)?Re(s.key)?s.key.value:s.key:s}set(e,i){if(typeof i!="boolean")throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof i}`);const s=ps(this.items,e);s&&!i?this.items.splice(this.items.indexOf(s),1):!s&&i&&this.items.push(new wt(e))}toJSON(e,i){return super.toJSON(e,i,Set)}toString(e,i,s){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),i,s);throw new Error("Set items must all have null values")}static from(e,i,s){const{replacer:a}=s,o=new this(e);if(i&&Symbol.iterator in Object(i))for(let c of i)typeof a=="function"&&(c=a.call(i,c,c)),o.items.push(Jd(c,null,s));return o}}Ar.tag="tag:yaml.org,2002:set";const sp={collection:"map",identify:n=>n instanceof Set,nodeClass:Ar,default:!1,tag:"tag:yaml.org,2002:set",createNode:(n,e,i)=>Ar.from(n,e,i),resolve(n,e){if(Ur(n)){if(n.hasAllNullValues(!0))return Object.assign(new Ar,n);e("Set items must all have null values")}else e("Expected a mapping for this tag");return n}};function rp(n,e){const i=n[0],s=i==="-"||i==="+"?n.substring(1):n,a=c=>e?BigInt(c):Number(c),o=s.replace(/_/g,"").split(":").reduce((c,f)=>c*a(60)+a(f),a(0));return i==="-"?a(-1)*o:o}function VS(n){let{value:e}=n,i=c=>c;if(typeof e=="bigint")i=c=>BigInt(c);else if(isNaN(e)||!isFinite(e))return wn(n);let s="";e<0&&(s="-",e*=i(-1));const a=i(60),o=[e%a];return e<60?o.unshift(0):(e=(e-o[0])/a,o.unshift(e%a),e>=60&&(e=(e-o[0])/a,o.unshift(e))),s+o.map(c=>String(c).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}const GS={identify:n=>typeof n=="bigint"||Number.isInteger(n),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(n,e,{intAsBigInt:i})=>rp(n,i),stringify:VS},KS={identify:n=>typeof n=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:n=>rp(n,!1),stringify:VS},$c={identify:n=>n instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve(n){const e=n.match($c.test);if(!e)throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd");const[,i,s,a,o,c,f]=e.map(Number),h=e[7]?Number((e[7]+"00").substr(1,3)):0;let p=Date.UTC(i,s-1,a,o||0,c||0,f||0,h);const y=e[8];if(y&&y!=="Z"){let m=rp(y,!1);Math.abs(m)<30&&(m*=60),p-=6e4*m}return new Date(p)},stringify:({value:n})=>n.toISOString().replace(/((T00:00)?:00)?\.000Z$/,"")},c0=[qr,Ir,Uc,Hc,IS,$S,hN,dN,pN,gN,cN,uN,fN,ep,ni,np,tp,sp,GS,KS,$c],u0=new Map([["core",rN],["failsafe",[qr,Ir,Uc]],["json",oN],["yaml11",c0],["yaml-1.1",c0]]),f0={binary:ep,bool:Zd,float:jS,floatExp:LS,floatNaN:OS,floatTime:KS,int:BS,intHex:zS,intOct:DS,intTime:GS,map:qr,merge:ni,null:Hc,omap:np,pairs:tp,seq:Ir,set:sp,timestamp:$c},mN={"tag:yaml.org,2002:binary":ep,"tag:yaml.org,2002:merge":ni,"tag:yaml.org,2002:omap":np,"tag:yaml.org,2002:pairs":tp,"tag:yaml.org,2002:set":sp,"tag:yaml.org,2002:timestamp":$c};function Lh(n,e,i){const s=u0.get(e);if(s&&!n)return i&&!s.includes(ni)?s.concat(ni):s.slice();let a=s;if(!a)if(Array.isArray(n))a=[];else{const o=Array.from(u0.keys()).filter(c=>c!=="yaml11").map(c=>JSON.stringify(c)).join(", ");throw new Error(`Unknown schema "${e}"; use one of ${o} or define customTags array`)}if(Array.isArray(n))for(const o of n)a=a.concat(o);else typeof n=="function"&&(a=n(a.slice()));return i&&(a=a.concat(ni)),a.reduce((o,c)=>{const f=typeof c=="string"?f0[c]:c;if(!f){const h=JSON.stringify(c),p=Object.keys(f0).map(y=>JSON.stringify(y)).join(", ");throw new Error(`Unknown custom tag ${h}; use one of ${p}`)}return o.includes(f)||o.push(f),o},[])}const yN=(n,e)=>n.key<e.key?-1:n.key>e.key?1:0;class Vc{constructor({compat:e,customTags:i,merge:s,resolveKnownTags:a,schema:o,sortMapEntries:c,toStringDefaults:f}){this.compat=Array.isArray(e)?Lh(e,"compat"):e?Lh(null,e):null,this.name=typeof o=="string"&&o||"core",this.knownTags=a?mN:{},this.tags=Lh(i,this.name,s),this.toStringOptions=f??null,Object.defineProperty(this,Ri,{value:qr}),Object.defineProperty(this,On,{value:Uc}),Object.defineProperty(this,zr,{value:Ir}),this.sortMapEntries=typeof c=="function"?c:c===!0?yN:null}clone(){const e=Object.create(Vc.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}function bN(n,e){var h;const i=[];let s=e.directives===!0;if(e.directives!==!1&&n.directives){const p=n.directives.toString(n);p?(i.push(p),s=!0):n.directives.docStart&&(s=!0)}s&&i.push("---");const a=AS(n,e),{commentString:o}=a.options;if(n.commentBefore){i.length!==1&&i.unshift("");const p=o(n.commentBefore);i.unshift(ti(p,""))}let c=!1,f=null;if(n.contents){if(Ve(n.contents)){if(n.contents.spaceBefore&&s&&i.push(""),n.contents.commentBefore){const m=o(n.contents.commentBefore);i.push(ti(m,""))}a.forceBlockIndent=!!n.comment,f=n.contents.comment}const p=f?void 0:()=>c=!0;let y=Mr(n.contents,a,()=>f=null,p);f&&(y+=ds(y,"",o(f))),(y[0]==="|"||y[0]===">")&&i[i.length-1]==="---"?i[i.length-1]=`--- ${y}`:i.push(y)}else i.push(Mr(n.contents,a));if((h=n.directives)!=null&&h.docEnd)if(n.comment){const p=o(n.comment);p.includes(`
|
|
185
|
+
`)?(i.push("..."),i.push(ti(p,""))):i.push(`... ${p}`)}else i.push("...");else{let p=n.comment;p&&c&&(p=p.replace(/^\n+/,"")),p&&((!c||f)&&i[i.length-1]!==""&&i.push(""),i.push(ti(o(p),"")))}return i.join(`
|
|
186
|
+
`)+`
|
|
187
|
+
`}class $r{constructor(e,i,s){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,gn,{value:ad});let a=null;typeof i=="function"||Array.isArray(i)?a=i:s===void 0&&i&&(s=i,i=void 0);const o=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},s);this.options=o;let{version:c}=o;s!=null&&s._directives?(this.directives=s._directives.atDocument(),this.directives.yaml.explicit&&(c=this.directives.yaml.version)):this.directives=new At({version:c}),this.setSchema(c,s),this.contents=e===void 0?null:this.createNode(e,a,s)}clone(){const e=Object.create($r.prototype,{[gn]:{value:ad}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=Ve(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){dr(this.contents)&&this.contents.add(e)}addIn(e,i){dr(this.contents)&&this.contents.addIn(e,i)}createAlias(e,i){if(!e.anchor){const s=wS(this);e.anchor=!i||s.has(i)?xS(i||"a",s):i}return new Rc(e.anchor)}createNode(e,i,s){let a;if(typeof i=="function")e=i.call({"":e},"",e),a=i;else if(Array.isArray(i)){const E=N=>typeof N=="number"||N instanceof String||N instanceof Number,A=i.filter(E).map(String);A.length>0&&(i=i.concat(A)),a=i}else s===void 0&&i&&(s=i,i=void 0);const{aliasDuplicateObjects:o,anchorPrefix:c,flow:f,keepUndefined:h,onTagObj:p,tag:y}=s??{},{onAnchor:m,setAnchors:v,sourceObjects:S}=XC(this,c||"a"),T={aliasDuplicateObjects:o??!0,keepUndefined:h??!1,onAnchor:m,onTagObj:p,replacer:a,schema:this.schema,sourceObjects:S},x=fl(e,y,T);return f&&$e(x)&&(x.flow=!0),v(),x}createPair(e,i,s={}){const a=this.createNode(e,null,s),o=this.createNode(i,null,s);return new wt(a,o)}delete(e){return dr(this.contents)?this.contents.delete(e):!1}deleteIn(e){return Pa(e)?this.contents==null?!1:(this.contents=null,!0):dr(this.contents)?this.contents.deleteIn(e):!1}get(e,i){return $e(this.contents)?this.contents.get(e,i):void 0}getIn(e,i){return Pa(e)?!i&&Re(this.contents)?this.contents.value:this.contents:$e(this.contents)?this.contents.getIn(e,i):void 0}has(e){return $e(this.contents)?this.contents.has(e):!1}hasIn(e){return Pa(e)?this.contents!==void 0:$e(this.contents)?this.contents.hasIn(e):!1}set(e,i){this.contents==null?this.contents=xc(this.schema,[e],i):dr(this.contents)&&this.contents.set(e,i)}setIn(e,i){Pa(e)?this.contents=i:this.contents==null?this.contents=xc(this.schema,Array.from(e),i):dr(this.contents)&&this.contents.setIn(e,i)}setSchema(e,i={}){typeof e=="number"&&(e=String(e));let s;switch(e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new At({version:"1.1"}),s={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new At({version:e}),s={resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,s=null;break;default:{const a=JSON.stringify(e);throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${a}`)}}if(i.schema instanceof Object)this.schema=i.schema;else if(s)this.schema=new Vc(Object.assign(s,i));else throw new Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:i,mapAsMap:s,maxAliasCount:a,onAnchor:o,reviver:c}={}){const f={anchors:new Map,doc:this,keep:!e,mapAsMap:s===!0,mapKeyWarned:!1,maxAliasCount:typeof a=="number"?a:100},h=dn(this.contents,i??"",f);if(typeof o=="function")for(const{count:p,res:y}of f.anchors.values())o(y,p);return typeof c=="function"?xr(c,{"":h},"",h):h}toJSON(e,i){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:i})}toString(e={}){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){const i=JSON.stringify(e.indent);throw new Error(`"indent" option must be a positive integer, not ${i}`)}return bN(this,e)}}function dr(n){if($e(n))return!0;throw new Error("Expected a YAML collection as document contents")}class ap extends Error{constructor(e,i,s,a){super(),this.name=e,this.code=s,this.message=a,this.pos=i}}class gs extends ap{constructor(e,i,s){super("YAMLParseError",e,i,s)}}class XS extends ap{constructor(e,i,s){super("YAMLWarning",e,i,s)}}const Tc=(n,e)=>i=>{if(i.pos[0]===-1)return;i.linePos=i.pos.map(f=>e.linePos(f));const{line:s,col:a}=i.linePos[0];i.message+=` at line ${s}, column ${a}`;let o=a-1,c=n.substring(e.lineStarts[s-1],e.lineStarts[s]).replace(/[\n\r]+$/,"");if(o>=60&&c.length>80){const f=Math.min(o-39,c.length-79);c="…"+c.substring(f),o-=f-1}if(c.length>80&&(c=c.substring(0,79)+"…"),s>1&&/^ *$/.test(c.substring(0,o))){let f=n.substring(e.lineStarts[s-2],e.lineStarts[s-1]);f.length>80&&(f=f.substring(0,79)+`…
|
|
188
|
+
`),c=f+c}if(/[^ ]/.test(c)){let f=1;const h=i.linePos[1];h&&h.line===s&&h.col>a&&(f=Math.max(1,Math.min(h.col-a,80-o)));const p=" ".repeat(o)+"^".repeat(f);i.message+=`:
|
|
189
|
+
|
|
190
|
+
${c}
|
|
191
|
+
${p}
|
|
192
|
+
`}};function Or(n,{flow:e,indicator:i,next:s,offset:a,onError:o,parentIndent:c,startOnNewline:f}){let h=!1,p=f,y=f,m="",v="",S=!1,T=!1,x=null,E=null,A=null,N=null,B=null,V=null,$=null;for(const H of n)switch(T&&(H.type!=="space"&&H.type!=="newline"&&H.type!=="comma"&&o(H.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),T=!1),x&&(p&&H.type!=="comment"&&H.type!=="newline"&&o(x,"TAB_AS_INDENT","Tabs are not allowed as indentation"),x=null),H.type){case"space":!e&&(i!=="doc-start"||(s==null?void 0:s.type)!=="flow-collection")&&H.source.includes(" ")&&(x=H),y=!0;break;case"comment":{y||o(H,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const L=H.source.substring(1)||" ";m?m+=v+L:m=L,v="",p=!1;break}case"newline":p?m?m+=H.source:h=!0:v+=H.source,p=!0,S=!0,(E||A)&&(N=H),y=!0;break;case"anchor":E&&o(H,"MULTIPLE_ANCHORS","A node can have at most one anchor"),H.source.endsWith(":")&&o(H.offset+H.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0),E=H,$===null&&($=H.offset),p=!1,y=!1,T=!0;break;case"tag":{A&&o(H,"MULTIPLE_TAGS","A node can have at most one tag"),A=H,$===null&&($=H.offset),p=!1,y=!1,T=!0;break}case i:(E||A)&&o(H,"BAD_PROP_ORDER",`Anchors and tags must be after the ${H.source} indicator`),V&&o(H,"UNEXPECTED_TOKEN",`Unexpected ${H.source} in ${e??"collection"}`),V=H,p=i==="seq-item-ind"||i==="explicit-key-ind",y=!1;break;case"comma":if(e){B&&o(H,"UNEXPECTED_TOKEN",`Unexpected , in ${e}`),B=H,p=!1,y=!1;break}default:o(H,"UNEXPECTED_TOKEN",`Unexpected ${H.type} token`),p=!1,y=!1}const z=n[n.length-1],Q=z?z.offset+z.source.length:a;return T&&s&&s.type!=="space"&&s.type!=="newline"&&s.type!=="comma"&&(s.type!=="scalar"||s.source!=="")&&o(s.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),x&&(p&&x.indent<=c||(s==null?void 0:s.type)==="block-map"||(s==null?void 0:s.type)==="block-seq")&&o(x,"TAB_AS_INDENT","Tabs are not allowed as indentation"),{comma:B,found:V,spaceBefore:h,comment:m,hasNewline:S,anchor:E,tag:A,newlineAfterProp:N,end:Q,start:$??Q}}function hl(n){if(!n)return null;switch(n.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(n.source.includes(`
|
|
193
|
+
`))return!0;if(n.end){for(const e of n.end)if(e.type==="newline")return!0}return!1;case"flow-collection":for(const e of n.items){for(const i of e.start)if(i.type==="newline")return!0;if(e.sep){for(const i of e.sep)if(i.type==="newline")return!0}if(hl(e.key)||hl(e.value))return!0}return!1;default:return!0}}function ud(n,e,i){if((e==null?void 0:e.type)==="flow-collection"){const s=e.end[0];s.indent===n&&(s.source==="]"||s.source==="}")&&hl(e)&&i(s,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}function FS(n,e,i){const{uniqueKeys:s}=n.options;if(s===!1)return!1;const a=typeof s=="function"?s:(o,c)=>o===c||Re(o)&&Re(c)&&o.value===c.value;return e.some(o=>a(o.key,i))}const h0="All mapping items must start at the same column";function vN({composeNode:n,composeEmptyNode:e},i,s,a,o){var y;const c=(o==null?void 0:o.nodeClass)??Pt,f=new c(i.schema);i.atRoot&&(i.atRoot=!1);let h=s.offset,p=null;for(const m of s.items){const{start:v,key:S,sep:T,value:x}=m,E=Or(v,{indicator:"explicit-key-ind",next:S??(T==null?void 0:T[0]),offset:h,onError:a,parentIndent:s.indent,startOnNewline:!0}),A=!E.found;if(A){if(S&&(S.type==="block-seq"?a(h,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key"):"indent"in S&&S.indent!==s.indent&&a(h,"BAD_INDENT",h0)),!E.anchor&&!E.tag&&!T){p=E.end,E.comment&&(f.comment?f.comment+=`
|
|
194
|
+
`+E.comment:f.comment=E.comment);continue}(E.newlineAfterProp||hl(S))&&a(S??v[v.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else((y=E.found)==null?void 0:y.indent)!==s.indent&&a(h,"BAD_INDENT",h0);i.atKey=!0;const N=E.end,B=S?n(i,S,E,a):e(i,N,v,null,E,a);i.schema.compat&&ud(s.indent,S,a),i.atKey=!1,FS(i,f.items,B)&&a(N,"DUPLICATE_KEY","Map keys must be unique");const V=Or(T??[],{indicator:"map-value-ind",next:x,offset:B.range[2],onError:a,parentIndent:s.indent,startOnNewline:!S||S.type==="block-scalar"});if(h=V.end,V.found){A&&((x==null?void 0:x.type)==="block-map"&&!V.hasNewline&&a(h,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings"),i.options.strict&&E.start<V.found.offset-1024&&a(B.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));const $=x?n(i,x,V,a):e(i,h,T,null,V,a);i.schema.compat&&ud(s.indent,x,a),h=$.range[2];const z=new wt(B,$);i.options.keepSourceTokens&&(z.srcToken=m),f.items.push(z)}else{A&&a(B.range,"MISSING_CHAR","Implicit map keys need to be followed by map values"),V.comment&&(B.comment?B.comment+=`
|
|
195
|
+
`+V.comment:B.comment=V.comment);const $=new wt(B);i.options.keepSourceTokens&&($.srcToken=m),f.items.push($)}}return p&&p<h&&a(p,"IMPOSSIBLE","Map comment with trailing content"),f.range=[s.offset,h,p??h],f}function SN({composeNode:n,composeEmptyNode:e},i,s,a,o){const c=(o==null?void 0:o.nodeClass)??Bi,f=new c(i.schema);i.atRoot&&(i.atRoot=!1),i.atKey&&(i.atKey=!1);let h=s.offset,p=null;for(const{start:y,value:m}of s.items){const v=Or(y,{indicator:"seq-item-ind",next:m,offset:h,onError:a,parentIndent:s.indent,startOnNewline:!0});if(!v.found)if(v.anchor||v.tag||m)m&&m.type==="block-seq"?a(v.end,"BAD_INDENT","All sequence items must start at the same column"):a(h,"MISSING_CHAR","Sequence item without - indicator");else{p=v.end,v.comment&&(f.comment=v.comment);continue}const S=m?n(i,m,v,a):e(i,v.end,y,null,v,a);i.schema.compat&&ud(s.indent,m,a),h=S.range[2],f.items.push(S)}return f.range=[s.offset,h,p??h],f}function vl(n,e,i,s){let a="";if(n){let o=!1,c="";for(const f of n){const{source:h,type:p}=f;switch(p){case"space":o=!0;break;case"comment":{i&&!o&&s(f,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const y=h.substring(1)||" ";a?a+=c+y:a=y,c="";break}case"newline":a&&(c+=h),o=!0;break;default:s(f,"UNEXPECTED_TOKEN",`Unexpected ${p} at node end`)}e+=h.length}}return{comment:a,offset:e}}const jh="Block collections are not allowed within flow collections",Rh=n=>n&&(n.type==="block-map"||n.type==="block-seq");function wN({composeNode:n,composeEmptyNode:e},i,s,a,o){const c=s.start.source==="{",f=c?"flow map":"flow sequence",h=(o==null?void 0:o.nodeClass)??(c?Pt:Bi),p=new h(i.schema);p.flow=!0;const y=i.atRoot;y&&(i.atRoot=!1),i.atKey&&(i.atKey=!1);let m=s.offset+s.start.source.length;for(let E=0;E<s.items.length;++E){const A=s.items[E],{start:N,key:B,sep:V,value:$}=A,z=Or(N,{flow:f,indicator:"explicit-key-ind",next:B??(V==null?void 0:V[0]),offset:m,onError:a,parentIndent:s.indent,startOnNewline:!1});if(!z.found){if(!z.anchor&&!z.tag&&!V&&!$){E===0&&z.comma?a(z.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${f}`):E<s.items.length-1&&a(z.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${f}`),z.comment&&(p.comment?p.comment+=`
|
|
196
|
+
`+z.comment:p.comment=z.comment),m=z.end;continue}!c&&i.options.strict&&hl(B)&&a(B,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(E===0)z.comma&&a(z.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${f}`);else if(z.comma||a(z.start,"MISSING_CHAR",`Missing , between ${f} items`),z.comment){let Q="";e:for(const H of N)switch(H.type){case"comma":case"space":break;case"comment":Q=H.source.substring(1);break e;default:break e}if(Q){let H=p.items[p.items.length-1];He(H)&&(H=H.value??H.key),H.comment?H.comment+=`
|
|
197
|
+
`+Q:H.comment=Q,z.comment=z.comment.substring(Q.length+1)}}if(!c&&!V&&!z.found){const Q=$?n(i,$,z,a):e(i,z.end,V,null,z,a);p.items.push(Q),m=Q.range[2],Rh($)&&a(Q.range,"BLOCK_IN_FLOW",jh)}else{i.atKey=!0;const Q=z.end,H=B?n(i,B,z,a):e(i,Q,N,null,z,a);Rh(B)&&a(H.range,"BLOCK_IN_FLOW",jh),i.atKey=!1;const L=Or(V??[],{flow:f,indicator:"map-value-ind",next:$,offset:H.range[2],onError:a,parentIndent:s.indent,startOnNewline:!1});if(L.found){if(!c&&!z.found&&i.options.strict){if(V)for(const G of V){if(G===L.found)break;if(G.type==="newline"){a(G,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}z.start<L.found.offset-1024&&a(L.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else $&&("source"in $&&$.source&&$.source[0]===":"?a($,"MISSING_CHAR",`Missing space after : in ${f}`):a(L.start,"MISSING_CHAR",`Missing , or : between ${f} items`));const ne=$?n(i,$,L,a):L.found?e(i,L.end,V,null,L,a):null;ne?Rh($)&&a(ne.range,"BLOCK_IN_FLOW",jh):L.comment&&(H.comment?H.comment+=`
|
|
198
|
+
`+L.comment:H.comment=L.comment);const ae=new wt(H,ne);if(i.options.keepSourceTokens&&(ae.srcToken=A),c){const G=p;FS(i,G.items,H)&&a(Q,"DUPLICATE_KEY","Map keys must be unique"),G.items.push(ae)}else{const G=new Pt(i.schema);G.flow=!0,G.items.push(ae);const P=(ne??H).range;G.range=[H.range[0],P[1],P[2]],p.items.push(G)}m=ne?ne.range[2]:L.end}}const v=c?"}":"]",[S,...T]=s.end;let x=m;if(S&&S.source===v)x=S.offset+S.source.length;else{const E=f[0].toUpperCase()+f.substring(1),A=y?`${E} must end with a ${v}`:`${E} in block collection must be sufficiently indented and end with a ${v}`;a(m,y?"MISSING_CHAR":"BAD_INDENT",A),S&&S.source.length!==1&&T.unshift(S)}if(T.length>0){const E=vl(T,x,i.options.strict,a);E.comment&&(p.comment?p.comment+=`
|
|
199
|
+
`+E.comment:p.comment=E.comment),p.range=[s.offset,x,E.offset]}else p.range=[s.offset,x,x];return p}function Dh(n,e,i,s,a,o){const c=i.type==="block-map"?vN(n,e,i,s,o):i.type==="block-seq"?SN(n,e,i,s,o):wN(n,e,i,s,o),f=c.constructor;return a==="!"||a===f.tagName?(c.tag=f.tagName,c):(a&&(c.tag=a),c)}function xN(n,e,i,s,a){var v;const o=s.tag,c=o?e.directives.tagName(o.source,S=>a(o,"TAG_RESOLVE_FAILED",S)):null;if(i.type==="block-seq"){const{anchor:S,newlineAfterProp:T}=s,x=S&&o?S.offset>o.offset?S:o:S??o;x&&(!T||T.offset<x.offset)&&a(x,"MISSING_CHAR","Missing newline after block sequence props")}const f=i.type==="block-map"?"map":i.type==="block-seq"?"seq":i.start.source==="{"?"map":"seq";if(!o||!c||c==="!"||c===Pt.tagName&&f==="map"||c===Bi.tagName&&f==="seq")return Dh(n,e,i,a,c);let h=e.schema.tags.find(S=>S.tag===c&&S.collection===f);if(!h){const S=e.schema.knownTags[c];if(S&&S.collection===f)e.schema.tags.push(Object.assign({},S,{default:!1})),h=S;else return S!=null&&S.collection?a(o,"BAD_COLLECTION_TYPE",`${S.tag} used for ${f} collection, but expects ${S.collection}`,!0):a(o,"TAG_RESOLVE_FAILED",`Unresolved tag: ${c}`,!0),Dh(n,e,i,a,c)}const p=Dh(n,e,i,a,c,h),y=((v=h.resolve)==null?void 0:v.call(h,p,S=>a(o,"TAG_RESOLVE_FAILED",S),e.options))??p,m=Ve(y)?y:new fe(y);return m.range=p.range,m.tag=c,h!=null&&h.format&&(m.format=h.format),m}function YS(n,e,i){const s=e.offset,a=EN(e,n.options.strict,i);if(!a)return{value:"",type:null,comment:"",range:[s,s,s]};const o=a.mode===">"?fe.BLOCK_FOLDED:fe.BLOCK_LITERAL,c=e.source?TN(e.source):[];let f=c.length;for(let x=c.length-1;x>=0;--x){const E=c[x][1];if(E===""||E==="\r")f=x;else break}if(f===0){const x=a.chomp==="+"&&c.length>0?`
|
|
200
|
+
`.repeat(Math.max(1,c.length-1)):"";let E=s+a.length;return e.source&&(E+=e.source.length),{value:x,type:o,comment:a.comment,range:[s,E,E]}}let h=e.indent+a.indent,p=e.offset+a.length,y=0;for(let x=0;x<f;++x){const[E,A]=c[x];if(A===""||A==="\r")a.indent===0&&E.length>h&&(h=E.length);else{E.length<h&&i(p+E.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator"),a.indent===0&&(h=E.length),y=x,h===0&&!n.atRoot&&i(p,"BAD_INDENT","Block scalar values in collections must be indented");break}p+=E.length+A.length+1}for(let x=c.length-1;x>=f;--x)c[x][0].length>h&&(f=x+1);let m="",v="",S=!1;for(let x=0;x<y;++x)m+=c[x][0].slice(h)+`
|
|
201
|
+
`;for(let x=y;x<f;++x){let[E,A]=c[x];p+=E.length+A.length+1;const N=A[A.length-1]==="\r";if(N&&(A=A.slice(0,-1)),A&&E.length<h){const V=`Block scalar lines must not be less indented than their ${a.indent?"explicit indentation indicator":"first line"}`;i(p-A.length-(N?2:1),"BAD_INDENT",V),E=""}o===fe.BLOCK_LITERAL?(m+=v+E.slice(h)+A,v=`
|
|
202
|
+
`):E.length>h||A[0]===" "?(v===" "?v=`
|
|
203
|
+
`:!S&&v===`
|
|
204
|
+
`&&(v=`
|
|
205
|
+
|
|
206
|
+
`),m+=v+E.slice(h)+A,v=`
|
|
207
|
+
`,S=!0):A===""?v===`
|
|
208
|
+
`?m+=`
|
|
209
|
+
`:v=`
|
|
210
|
+
`:(m+=v+A,v=" ",S=!1)}switch(a.chomp){case"-":break;case"+":for(let x=f;x<c.length;++x)m+=`
|
|
211
|
+
`+c[x][0].slice(h);m[m.length-1]!==`
|
|
212
|
+
`&&(m+=`
|
|
213
|
+
`);break;default:m+=`
|
|
214
|
+
`}const T=s+a.length+e.source.length;return{value:m,type:o,comment:a.comment,range:[s,T,T]}}function EN({offset:n,props:e},i,s){if(e[0].type!=="block-scalar-header")return s(e[0],"IMPOSSIBLE","Block scalar header not found"),null;const{source:a}=e[0],o=a[0];let c=0,f="",h=-1;for(let v=1;v<a.length;++v){const S=a[v];if(!f&&(S==="-"||S==="+"))f=S;else{const T=Number(S);!c&&T?c=T:h===-1&&(h=n+v)}}h!==-1&&s(h,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${a}`);let p=!1,y="",m=a.length;for(let v=1;v<e.length;++v){const S=e[v];switch(S.type){case"space":p=!0;case"newline":m+=S.source.length;break;case"comment":i&&!p&&s(S,"MISSING_CHAR","Comments must be separated from other tokens by white space characters"),m+=S.source.length,y=S.source.substring(1);break;case"error":s(S,"UNEXPECTED_TOKEN",S.message),m+=S.source.length;break;default:{const T=`Unexpected token in block scalar header: ${S.type}`;s(S,"UNEXPECTED_TOKEN",T);const x=S.source;x&&typeof x=="string"&&(m+=x.length)}}}return{mode:o,indent:c,chomp:f,comment:y,length:m}}function TN(n){const e=n.split(/\n( *)/),i=e[0],s=i.match(/^( *)/),o=[s!=null&&s[1]?[s[1],i.slice(s[1].length)]:["",i]];for(let c=1;c<e.length;c+=2)o.push([e[c],e[c+1]]);return o}function QS(n,e,i){const{offset:s,type:a,source:o,end:c}=n;let f,h;const p=(v,S,T)=>i(s+v,S,T);switch(a){case"scalar":f=fe.PLAIN,h=_N(o,p);break;case"single-quoted-scalar":f=fe.QUOTE_SINGLE,h=AN(o,p);break;case"double-quoted-scalar":f=fe.QUOTE_DOUBLE,h=CN(o,p);break;default:return i(n,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${a}`),{value:"",type:null,comment:"",range:[s,s+o.length,s+o.length]}}const y=s+o.length,m=vl(c,y,e,i);return{value:h,type:f,comment:m.comment,range:[s,y,m.offset]}}function _N(n,e){let i="";switch(n[0]){case" ":i="a tab character";break;case",":i="flow indicator character ,";break;case"%":i="directive indicator character %";break;case"|":case">":{i=`block scalar indicator ${n[0]}`;break}case"@":case"`":{i=`reserved character ${n[0]}`;break}}return i&&e(0,"BAD_SCALAR_START",`Plain value cannot start with ${i}`),PS(n)}function AN(n,e){return(n[n.length-1]!=="'"||n.length===1)&&e(n.length,"MISSING_CHAR","Missing closing 'quote"),PS(n.slice(1,-1)).replace(/''/g,"'")}function PS(n){let e,i;try{e=new RegExp(`(.*?)(?<![ ])[ ]*\r?
|
|
215
|
+
`,"sy"),i=new RegExp(`[ ]*(.*?)(?:(?<![ ])[ ]*)?\r?
|
|
216
|
+
`,"sy")}catch{e=/(.*?)[ \t]*\r?\n/sy,i=/[ \t]*(.*?)[ \t]*\r?\n/sy}let s=e.exec(n);if(!s)return n;let a=s[1],o=" ",c=e.lastIndex;for(i.lastIndex=c;s=i.exec(n);)s[1]===""?o===`
|
|
217
|
+
`?a+=o:o=`
|
|
218
|
+
`:(a+=o+s[1],o=" "),c=i.lastIndex;const f=/[ \t]*(.*)/sy;return f.lastIndex=c,s=f.exec(n),a+o+((s==null?void 0:s[1])??"")}function CN(n,e){let i="";for(let s=1;s<n.length-1;++s){const a=n[s];if(!(a==="\r"&&n[s+1]===`
|
|
219
|
+
`))if(a===`
|
|
220
|
+
`){const{fold:o,offset:c}=NN(n,s);i+=o,s=c}else if(a==="\\"){let o=n[++s];const c=kN[o];if(c)i+=c;else if(o===`
|
|
221
|
+
`)for(o=n[s+1];o===" "||o===" ";)o=n[++s+1];else if(o==="\r"&&n[s+1]===`
|
|
222
|
+
`)for(o=n[++s+1];o===" "||o===" ";)o=n[++s+1];else if(o==="x"||o==="u"||o==="U"){const f={x:2,u:4,U:8}[o];i+=MN(n,s+1,f,e),s+=f}else{const f=n.substr(s-1,2);e(s-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${f}`),i+=f}}else if(a===" "||a===" "){const o=s;let c=n[s+1];for(;c===" "||c===" ";)c=n[++s+1];c!==`
|
|
223
|
+
`&&!(c==="\r"&&n[s+2]===`
|
|
224
|
+
`)&&(i+=s>o?n.slice(o,s+1):a)}else i+=a}return(n[n.length-1]!=='"'||n.length===1)&&e(n.length,"MISSING_CHAR",'Missing closing "quote'),i}function NN(n,e){let i="",s=n[e+1];for(;(s===" "||s===" "||s===`
|
|
225
|
+
`||s==="\r")&&!(s==="\r"&&n[e+2]!==`
|
|
226
|
+
`);)s===`
|
|
227
|
+
`&&(i+=`
|
|
228
|
+
`),e+=1,s=n[e+1];return i||(i=" "),{fold:i,offset:e}}const kN={0:"\0",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:`
|
|
229
|
+
`,r:"\r",t:" ",v:"\v",N:"
",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\"," ":" "};function MN(n,e,i,s){const a=n.substr(e,i),c=a.length===i&&/^[0-9a-fA-F]+$/.test(a)?parseInt(a,16):NaN;if(isNaN(c)){const f=n.substr(e-2,i+2);return s(e-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${f}`),f}return String.fromCodePoint(c)}function JS(n,e,i,s){const{value:a,type:o,comment:c,range:f}=e.type==="block-scalar"?YS(n,e,s):QS(e,n.options.strict,s),h=i?n.directives.tagName(i.source,m=>s(i,"TAG_RESOLVE_FAILED",m)):null;let p;n.options.stringKeys&&n.atKey?p=n.schema[On]:h?p=ON(n.schema,a,h,i,s):e.type==="scalar"?p=LN(n,a,e,s):p=n.schema[On];let y;try{const m=p.resolve(a,v=>s(i??e,"TAG_RESOLVE_FAILED",v),n.options);y=Re(m)?m:new fe(m)}catch(m){const v=m instanceof Error?m.message:String(m);s(i??e,"TAG_RESOLVE_FAILED",v),y=new fe(a)}return y.range=f,y.source=a,o&&(y.type=o),h&&(y.tag=h),p.format&&(y.format=p.format),c&&(y.comment=c),y}function ON(n,e,i,s,a){var f;if(i==="!")return n[On];const o=[];for(const h of n.tags)if(!h.collection&&h.tag===i)if(h.default&&h.test)o.push(h);else return h;for(const h of o)if((f=h.test)!=null&&f.test(e))return h;const c=n.knownTags[i];return c&&!c.collection?(n.tags.push(Object.assign({},c,{default:!1,test:void 0})),c):(a(s,"TAG_RESOLVE_FAILED",`Unresolved tag: ${i}`,i!=="tag:yaml.org,2002:str"),n[On])}function LN({atKey:n,directives:e,schema:i},s,a,o){const c=i.tags.find(f=>{var h;return(f.default===!0||n&&f.default==="key")&&((h=f.test)==null?void 0:h.test(s))})||i[On];if(i.compat){const f=i.compat.find(h=>{var p;return h.default&&((p=h.test)==null?void 0:p.test(s))})??i[On];if(c.tag!==f.tag){const h=e.tagString(c.tag),p=e.tagString(f.tag),y=`Value may be parsed as either ${h} or ${p}`;o(a,"TAG_RESOLVE_FAILED",y,!0)}}return c}function jN(n,e,i){if(e){i===null&&(i=e.length);for(let s=i-1;s>=0;--s){let a=e[s];switch(a.type){case"space":case"comment":case"newline":n-=a.source.length;continue}for(a=e[++s];(a==null?void 0:a.type)==="space";)n+=a.source.length,a=e[++s];break}}return n}const RN={composeNode:ZS,composeEmptyNode:lp};function ZS(n,e,i,s){const a=n.atKey,{spaceBefore:o,comment:c,anchor:f,tag:h}=i;let p,y=!0;switch(e.type){case"alias":p=DN(n,e,s),(f||h)&&s(e,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":p=JS(n,e,h,s),f&&(p.anchor=f.source.substring(1));break;case"block-map":case"block-seq":case"flow-collection":p=xN(RN,n,e,i,s),f&&(p.anchor=f.source.substring(1));break;default:{const m=e.type==="error"?e.message:`Unsupported token (type: ${e.type})`;s(e,"UNEXPECTED_TOKEN",m),p=lp(n,e.offset,void 0,null,i,s),y=!1}}return f&&p.anchor===""&&s(f,"BAD_ALIAS","Anchor cannot be an empty string"),a&&n.options.stringKeys&&(!Re(p)||typeof p.value!="string"||p.tag&&p.tag!=="tag:yaml.org,2002:str")&&s(h??e,"NON_STRING_KEY","With stringKeys, all keys must be strings"),o&&(p.spaceBefore=!0),c&&(e.type==="scalar"&&e.source===""?p.comment=c:p.commentBefore=c),n.options.keepSourceTokens&&y&&(p.srcToken=e),p}function lp(n,e,i,s,{spaceBefore:a,comment:o,anchor:c,tag:f,end:h},p){const y={type:"scalar",offset:jN(e,i,s),indent:-1,source:""},m=JS(n,y,f,p);return c&&(m.anchor=c.source.substring(1),m.anchor===""&&p(c,"BAD_ALIAS","Anchor cannot be an empty string")),a&&(m.spaceBefore=!0),o&&(m.comment=o,m.range[2]=h),m}function DN({options:n},{offset:e,source:i,end:s},a){const o=new Rc(i.substring(1));o.source===""&&a(e,"BAD_ALIAS","Alias cannot be an empty string"),o.source.endsWith(":")&&a(e+i.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);const c=e+i.length,f=vl(s,c,n.strict,a);return o.range=[e,c,f.offset],f.comment&&(o.comment=f.comment),o}function BN(n,e,{offset:i,start:s,value:a,end:o},c){const f=Object.assign({_directives:e},n),h=new $r(void 0,f),p={atKey:!1,atRoot:!0,directives:h.directives,options:h.options,schema:h.schema},y=Or(s,{indicator:"doc-start",next:a??(o==null?void 0:o[0]),offset:i,onError:c,parentIndent:0,startOnNewline:!0});y.found&&(h.directives.docStart=!0,a&&(a.type==="block-map"||a.type==="block-seq")&&!y.hasNewline&&c(y.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")),h.contents=a?ZS(p,a,y,c):lp(p,y.end,s,null,y,c);const m=h.contents.range[2],v=vl(o,m,!1,c);return v.comment&&(h.comment=v.comment),h.range=[i,m,v.offset],h}function Va(n){if(typeof n=="number")return[n,n+1];if(Array.isArray(n))return n.length===2?n:[n[0],n[1]];const{offset:e,source:i}=n;return[e,e+(typeof i=="string"?i.length:1)]}function d0(n){var a;let e="",i=!1,s=!1;for(let o=0;o<n.length;++o){const c=n[o];switch(c[0]){case"#":e+=(e===""?"":s?`
|
|
230
|
+
|
|
231
|
+
`:`
|
|
232
|
+
`)+(c.substring(1)||" "),i=!0,s=!1;break;case"%":((a=n[o+1])==null?void 0:a[0])!=="#"&&(o+=1),i=!1;break;default:i||(s=!0),i=!1}}return{comment:e,afterEmptyLine:s}}class op{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(i,s,a,o)=>{const c=Va(i);o?this.warnings.push(new XS(c,s,a)):this.errors.push(new gs(c,s,a))},this.directives=new At({version:e.version||"1.2"}),this.options=e}decorate(e,i){const{comment:s,afterEmptyLine:a}=d0(this.prelude);if(s){const o=e.contents;if(i)e.comment=e.comment?`${e.comment}
|
|
233
|
+
${s}`:s;else if(a||e.directives.docStart||!o)e.commentBefore=s;else if($e(o)&&!o.flow&&o.items.length>0){let c=o.items[0];He(c)&&(c=c.key);const f=c.commentBefore;c.commentBefore=f?`${s}
|
|
234
|
+
${f}`:s}else{const c=o.commentBefore;o.commentBefore=c?`${s}
|
|
235
|
+
${c}`:s}}i?(Array.prototype.push.apply(e.errors,this.errors),Array.prototype.push.apply(e.warnings,this.warnings)):(e.errors=this.errors,e.warnings=this.warnings),this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:d0(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,i=!1,s=-1){for(const a of e)yield*this.next(a);yield*this.end(i,s)}*next(e){switch(e.type){case"directive":this.directives.add(e.source,(i,s,a)=>{const o=Va(e);o[0]+=i,this.onError(o,"BAD_DIRECTIVE",s,a)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{const i=BN(this.options,this.directives,e,this.onError);this.atDirectives&&!i.directives.docStart&&this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line"),this.decorate(i,!1),this.doc&&(yield this.doc),this.doc=i,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{const i=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,s=new gs(Va(e),"UNEXPECTED_TOKEN",i);this.atDirectives||!this.doc?this.errors.push(s):this.doc.errors.push(s);break}case"doc-end":{if(!this.doc){const s="Unexpected doc-end without preceding document";this.errors.push(new gs(Va(e),"UNEXPECTED_TOKEN",s));break}this.doc.directives.docEnd=!0;const i=vl(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),i.comment){const s=this.doc.comment;this.doc.comment=s?`${s}
|
|
236
|
+
${i.comment}`:i.comment}this.doc.range[2]=i.offset;break}default:this.errors.push(new gs(Va(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,i=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){const s=Object.assign({_directives:this.directives},this.options),a=new $r(void 0,s);this.atDirectives&&this.onError(i,"MISSING_CHAR","Missing directives-end indicator line"),a.range=[0,i,i],this.decorate(a,!1),yield a}}}function zN(n,e=!0,i){if(n){const s=(a,o,c)=>{const f=typeof a=="number"?a:Array.isArray(a)?a[0]:a.offset;if(i)i(f,o,c);else throw new gs([f,f+1],o,c)};switch(n.type){case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return QS(n,e,s);case"block-scalar":return YS({options:{strict:e}},n,s)}}return null}function UN(n,e){const{implicitKey:i=!1,indent:s,inFlow:a=!1,offset:o=-1,type:c="PLAIN"}=e,f=yl({type:c,value:n},{implicitKey:i,indent:s>0?" ".repeat(s):"",inFlow:a,options:{blockQuote:!0,lineWidth:-1}}),h=e.end??[{type:"newline",offset:-1,indent:s,source:`
|
|
237
|
+
`}];switch(f[0]){case"|":case">":{const p=f.indexOf(`
|
|
238
|
+
`),y=f.substring(0,p),m=f.substring(p+1)+`
|
|
239
|
+
`,v=[{type:"block-scalar-header",offset:o,indent:s,source:y}];return WS(v,h)||v.push({type:"newline",offset:-1,indent:s,source:`
|
|
240
|
+
`}),{type:"block-scalar",offset:o,indent:s,props:v,source:m}}case'"':return{type:"double-quoted-scalar",offset:o,indent:s,source:f,end:h};case"'":return{type:"single-quoted-scalar",offset:o,indent:s,source:f,end:h};default:return{type:"scalar",offset:o,indent:s,source:f,end:h}}}function HN(n,e,i={}){let{afterKey:s=!1,implicitKey:a=!1,inFlow:o=!1,type:c}=i,f="indent"in n?n.indent:null;if(s&&typeof f=="number"&&(f+=2),!c)switch(n.type){case"single-quoted-scalar":c="QUOTE_SINGLE";break;case"double-quoted-scalar":c="QUOTE_DOUBLE";break;case"block-scalar":{const p=n.props[0];if(p.type!=="block-scalar-header")throw new Error("Invalid block scalar header");c=p.source[0]===">"?"BLOCK_FOLDED":"BLOCK_LITERAL";break}default:c="PLAIN"}const h=yl({type:c,value:e},{implicitKey:a||f===null,indent:f!==null&&f>0?" ".repeat(f):"",inFlow:o,options:{blockQuote:!0,lineWidth:-1}});switch(h[0]){case"|":case">":qN(n,h);break;case'"':Bh(n,h,"double-quoted-scalar");break;case"'":Bh(n,h,"single-quoted-scalar");break;default:Bh(n,h,"scalar")}}function qN(n,e){const i=e.indexOf(`
|
|
241
|
+
`),s=e.substring(0,i),a=e.substring(i+1)+`
|
|
242
|
+
`;if(n.type==="block-scalar"){const o=n.props[0];if(o.type!=="block-scalar-header")throw new Error("Invalid block scalar header");o.source=s,n.source=a}else{const{offset:o}=n,c="indent"in n?n.indent:-1,f=[{type:"block-scalar-header",offset:o,indent:c,source:s}];WS(f,"end"in n?n.end:void 0)||f.push({type:"newline",offset:-1,indent:c,source:`
|
|
243
|
+
`});for(const h of Object.keys(n))h!=="type"&&h!=="offset"&&delete n[h];Object.assign(n,{type:"block-scalar",indent:c,props:f,source:a})}}function WS(n,e){if(e)for(const i of e)switch(i.type){case"space":case"comment":n.push(i);break;case"newline":return n.push(i),!0}return!1}function Bh(n,e,i){switch(n.type){case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":n.type=i,n.source=e;break;case"block-scalar":{const s=n.props.slice(1);let a=e.length;n.props[0].type==="block-scalar-header"&&(a-=n.props[0].source.length);for(const o of s)o.offset+=a;delete n.props,Object.assign(n,{type:i,source:e,end:s});break}case"block-map":case"block-seq":{const a={type:"newline",offset:n.offset+e.length,indent:n.indent,source:`
|
|
244
|
+
`};delete n.items,Object.assign(n,{type:i,source:e,end:[a]});break}default:{const s="indent"in n?n.indent:-1,a="end"in n&&Array.isArray(n.end)?n.end.filter(o=>o.type==="space"||o.type==="comment"||o.type==="newline"):[];for(const o of Object.keys(n))o!=="type"&&o!=="offset"&&delete n[o];Object.assign(n,{type:i,indent:s,source:e,end:a})}}}const IN=n=>"type"in n?_c(n):oc(n);function _c(n){switch(n.type){case"block-scalar":{let e="";for(const i of n.props)e+=_c(i);return e+n.source}case"block-map":case"block-seq":{let e="";for(const i of n.items)e+=oc(i);return e}case"flow-collection":{let e=n.start.source;for(const i of n.items)e+=oc(i);for(const i of n.end)e+=i.source;return e}case"document":{let e=oc(n);if(n.end)for(const i of n.end)e+=i.source;return e}default:{let e=n.source;if("end"in n&&n.end)for(const i of n.end)e+=i.source;return e}}}function oc({start:n,key:e,sep:i,value:s}){let a="";for(const o of n)a+=o.source;if(e&&(a+=_c(e)),i)for(const o of i)a+=o.source;return s&&(a+=_c(s)),a}const fd=Symbol("break visit"),$N=Symbol("skip children"),ew=Symbol("remove item");function ys(n,e){"type"in n&&n.type==="document"&&(n={start:n.start,value:n.value}),tw(Object.freeze([]),n,e)}ys.BREAK=fd;ys.SKIP=$N;ys.REMOVE=ew;ys.itemAtPath=(n,e)=>{let i=n;for(const[s,a]of e){const o=i==null?void 0:i[s];if(o&&"items"in o)i=o.items[a];else return}return i};ys.parentCollection=(n,e)=>{const i=ys.itemAtPath(n,e.slice(0,-1)),s=e[e.length-1][0],a=i==null?void 0:i[s];if(a&&"items"in a)return a;throw new Error("Parent collection not found")};function tw(n,e,i){let s=i(e,n);if(typeof s=="symbol")return s;for(const a of["key","value"]){const o=e[a];if(o&&"items"in o){for(let c=0;c<o.items.length;++c){const f=tw(Object.freeze(n.concat([[a,c]])),o.items[c],i);if(typeof f=="number")c=f-1;else{if(f===fd)return fd;f===ew&&(o.items.splice(c,1),c-=1)}}typeof s=="function"&&a==="key"&&(s=s(e,n))}}return typeof s=="function"?s(e,n):s}const Gc="\uFEFF",Kc="",Xc="",dl="",VN=n=>!!n&&"items"in n,GN=n=>!!n&&(n.type==="scalar"||n.type==="single-quoted-scalar"||n.type==="double-quoted-scalar"||n.type==="block-scalar");function KN(n){switch(n){case Gc:return"<BOM>";case Kc:return"<DOC>";case Xc:return"<FLOW_END>";case dl:return"<SCALAR>";default:return JSON.stringify(n)}}function nw(n){switch(n){case Gc:return"byte-order-mark";case Kc:return"doc-mode";case Xc:return"flow-error-end";case dl:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case`
|
|
245
|
+
`:case`\r
|
|
246
|
+
`:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(n[0]){case" ":case" ":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}const XN=Object.freeze(Object.defineProperty({__proto__:null,BOM:Gc,DOCUMENT:Kc,FLOW_END:Xc,SCALAR:dl,createScalarToken:UN,isCollection:VN,isScalar:GN,prettyToken:KN,resolveAsScalar:zN,setScalarValue:HN,stringify:IN,tokenType:nw,visit:ys},Symbol.toStringTag,{value:"Module"}));function vn(n){switch(n){case void 0:case" ":case`
|
|
247
|
+
`:case"\r":case" ":return!0;default:return!1}}const p0=new Set("0123456789ABCDEFabcdef"),FN=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),Yo=new Set(",[]{}"),YN=new Set(` ,[]{}
|
|
248
|
+
\r `),zh=n=>!n||YN.has(n);class iw{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,i=!1){if(e){if(typeof e!="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!i;let s=this.next??"stream";for(;s&&(i||this.hasChars(1));)s=yield*this.parseNext(s)}atLineEnd(){let e=this.pos,i=this.buffer[e];for(;i===" "||i===" ";)i=this.buffer[++e];return!i||i==="#"||i===`
|
|
249
|
+
`?!0:i==="\r"?this.buffer[e+1]===`
|
|
250
|
+
`:!1}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let i=this.buffer[e];if(this.indentNext>0){let s=0;for(;i===" ";)i=this.buffer[++s+e];if(i==="\r"){const a=this.buffer[s+e+1];if(a===`
|
|
251
|
+
`||!a&&!this.atEnd)return e+s+1}return i===`
|
|
252
|
+
`||s>=this.indentNext||!i&&!this.atEnd?e+s:-1}if(i==="-"||i==="."){const s=this.buffer.substr(e,3);if((s==="---"||s==="...")&&vn(this.buffer[e+3]))return-1}return e}getLine(){let e=this.lineEndPos;return(typeof e!="number"||e!==-1&&e<this.pos)&&(e=this.buffer.indexOf(`
|
|
253
|
+
`,this.pos),this.lineEndPos=e),e===-1?this.atEnd?this.buffer.substring(this.pos):null:(this.buffer[e-1]==="\r"&&(e-=1),this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(e===null)return this.setNext("stream");if(e[0]===Gc&&(yield*this.pushCount(1),e=e.substring(1)),e[0]==="%"){let i=e.length,s=e.indexOf("#");for(;s!==-1;){const o=e[s-1];if(o===" "||o===" "){i=s-1;break}else s=e.indexOf("#",s+1)}for(;;){const o=e[i-1];if(o===" "||o===" ")i-=1;else break}const a=(yield*this.pushCount(i))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-a),this.pushNewline(),"stream"}if(this.atLineEnd()){const i=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-i),yield*this.pushNewline(),"stream"}return yield Kc,yield*this.parseLineStart()}*parseLineStart(){const e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext("line-start");if(e==="-"||e==="."){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");const i=this.peek(3);if((i==="---"||i==="...")&&vn(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,i==="---"?"doc":"stream"}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!vn(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){const[e,i]=this.peek(2);if(!i&&!this.atEnd)return this.setNext("block-start");if((e==="-"||e==="?"||e===":")&&vn(i)){const s=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=s,yield*this.parseBlockStart()}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);const e=this.getLine();if(e===null)return this.setNext("doc");let i=yield*this.pushIndicators();switch(e[i]){case"#":yield*this.pushCount(e.length-i);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(zh),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return i+=yield*this.parseBlockScalarHeader(),i+=yield*this.pushSpaces(!0),yield*this.pushCount(e.length-i),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,i,s=-1;do e=yield*this.pushNewline(),e>0?(i=yield*this.pushSpaces(!1),this.indentValue=s=i):i=0,i+=yield*this.pushSpaces(!0);while(e+i>0);const a=this.getLine();if(a===null)return this.setNext("flow");if((s!==-1&&s<this.indentNext&&a[0]!=="#"||s===0&&(a.startsWith("---")||a.startsWith("..."))&&vn(a[3]))&&!(s===this.indentNext-1&&this.flowLevel===1&&(a[0]==="]"||a[0]==="}")))return this.flowLevel=0,yield Xc,yield*this.parseLineStart();let o=0;for(;a[o]===",";)o+=yield*this.pushCount(1),o+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(o+=yield*this.pushIndicators(),a[o]){case void 0:return"flow";case"#":return yield*this.pushCount(a.length-o),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(zh),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{const c=this.charAt(1);if(this.flowKey||vn(c)||c===",")return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){const e=this.charAt(0);let i=this.buffer.indexOf(e,this.pos+1);if(e==="'")for(;i!==-1&&this.buffer[i+1]==="'";)i=this.buffer.indexOf("'",i+2);else for(;i!==-1;){let o=0;for(;this.buffer[i-1-o]==="\\";)o+=1;if(o%2===0)break;i=this.buffer.indexOf('"',i+1)}const s=this.buffer.substring(0,i);let a=s.indexOf(`
|
|
254
|
+
`,this.pos);if(a!==-1){for(;a!==-1;){const o=this.continueScalar(a+1);if(o===-1)break;a=s.indexOf(`
|
|
255
|
+
`,o)}a!==-1&&(i=a-(s[a-1]==="\r"?2:1))}if(i===-1){if(!this.atEnd)return this.setNext("quoted-scalar");i=this.buffer.length}return yield*this.pushToIndex(i+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){const i=this.buffer[++e];if(i==="+")this.blockScalarKeep=!0;else if(i>"0"&&i<="9")this.blockScalarIndent=Number(i)-1;else if(i!=="-")break}return yield*this.pushUntil(i=>vn(i)||i==="#")}*parseBlockScalar(){let e=this.pos-1,i=0,s;e:for(let o=this.pos;s=this.buffer[o];++o)switch(s){case" ":i+=1;break;case`
|
|
256
|
+
`:e=o,i=0;break;case"\r":{const c=this.buffer[o+1];if(!c&&!this.atEnd)return this.setNext("block-scalar");if(c===`
|
|
257
|
+
`)break}default:break e}if(!s&&!this.atEnd)return this.setNext("block-scalar");if(i>=this.indentNext){this.blockScalarIndent===-1?this.indentNext=i:this.indentNext=this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{const o=this.continueScalar(e+1);if(o===-1)break;e=this.buffer.indexOf(`
|
|
258
|
+
`,o)}while(e!==-1);if(e===-1){if(!this.atEnd)return this.setNext("block-scalar");e=this.buffer.length}}let a=e+1;for(s=this.buffer[a];s===" ";)s=this.buffer[++a];if(s===" "){for(;s===" "||s===" "||s==="\r"||s===`
|
|
259
|
+
`;)s=this.buffer[++a];e=a-1}else if(!this.blockScalarKeep)do{let o=e-1,c=this.buffer[o];c==="\r"&&(c=this.buffer[--o]);const f=o;for(;c===" ";)c=this.buffer[--o];if(c===`
|
|
260
|
+
`&&o>=this.pos&&o+1+i>f)e=o;else break}while(!0);return yield dl,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){const e=this.flowLevel>0;let i=this.pos-1,s=this.pos-1,a;for(;a=this.buffer[++s];)if(a===":"){const o=this.buffer[s+1];if(vn(o)||e&&Yo.has(o))break;i=s}else if(vn(a)){let o=this.buffer[s+1];if(a==="\r"&&(o===`
|
|
261
|
+
`?(s+=1,a=`
|
|
262
|
+
`,o=this.buffer[s+1]):i=s),o==="#"||e&&Yo.has(o))break;if(a===`
|
|
263
|
+
`){const c=this.continueScalar(s+1);if(c===-1)break;s=Math.max(s,c-2)}}else{if(e&&Yo.has(a))break;i=s}return!a&&!this.atEnd?this.setNext("plain-scalar"):(yield dl,yield*this.pushToIndex(i+1,!0),e?"flow":"doc")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,i){const s=this.buffer.slice(this.pos,e);return s?(yield s,this.pos+=s.length,s.length):(i&&(yield""),0)}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(zh))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{const e=this.flowLevel>0,i=this.charAt(1);if(vn(i)||e&&Yo.has(i))return e?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}return 0}*pushTag(){if(this.charAt(1)==="<"){let e=this.pos+2,i=this.buffer[e];for(;!vn(i)&&i!==">";)i=this.buffer[++e];return yield*this.pushToIndex(i===">"?e+1:e,!1)}else{let e=this.pos+1,i=this.buffer[e];for(;i;)if(FN.has(i))i=this.buffer[++e];else if(i==="%"&&p0.has(this.buffer[e+1])&&p0.has(this.buffer[e+2]))i=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){const e=this.buffer[this.pos];return e===`
|
|
264
|
+
`?yield*this.pushCount(1):e==="\r"&&this.charAt(1)===`
|
|
265
|
+
`?yield*this.pushCount(2):0}*pushSpaces(e){let i=this.pos-1,s;do s=this.buffer[++i];while(s===" "||e&&s===" ");const a=i-this.pos;return a>0&&(yield this.buffer.substr(this.pos,a),this.pos=i),a}*pushUntil(e){let i=this.pos,s=this.buffer[i];for(;!e(s);)s=this.buffer[++i];return yield*this.pushToIndex(i,!1)}}class sw{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let i=0,s=this.lineStarts.length;for(;i<s;){const o=i+s>>1;this.lineStarts[o]<e?i=o+1:s=o}if(this.lineStarts[i]===e)return{line:i+1,col:1};if(i===0)return{line:0,col:e};const a=this.lineStarts[i-1];return{line:i,col:e-a+1}}}}function hs(n,e){for(let i=0;i<n.length;++i)if(n[i].type===e)return!0;return!1}function g0(n){for(let e=0;e<n.length;++e)switch(n[e].type){case"space":case"comment":case"newline":break;default:return e}return-1}function rw(n){switch(n==null?void 0:n.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function Qo(n){switch(n.type){case"document":return n.start;case"block-map":{const e=n.items[n.items.length-1];return e.sep??e.start}case"block-seq":return n.items[n.items.length-1].start;default:return[]}}function pr(n){var i;if(n.length===0)return[];let e=n.length;e:for(;--e>=0;)switch(n[e].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}for(;((i=n[++e])==null?void 0:i.type)==="space";);return n.splice(e,n.length)}function m0(n){if(n.start.type==="flow-seq-start")for(const e of n.items)e.sep&&!e.value&&!hs(e.start,"explicit-key-ind")&&!hs(e.sep,"map-value-ind")&&(e.key&&(e.value=e.key),delete e.key,rw(e.value)?e.value.end?Array.prototype.push.apply(e.value.end,e.sep):e.value.end=e.sep:Array.prototype.push.apply(e.start,e.sep),delete e.sep)}class cp{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new iw,this.onNewLine=e}*parse(e,i=!1){this.onNewLine&&this.offset===0&&this.onNewLine(0);for(const s of this.lexer.lex(e,i))yield*this.next(s);i||(yield*this.end())}*next(e){if(this.source=e,this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}const i=nw(e);if(i)if(i==="scalar")this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=i,yield*this.step(),i){case"newline":this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case"space":this.atNewLine&&e[0]===" "&&(this.indent+=e.length);break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":this.atNewLine&&(this.indent+=e.length);break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=e.length}else{const s=`Not a YAML token: ${e}`;yield*this.pop({type:"error",offset:this.offset,message:s,source:e}),this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){const e=this.peek(1);if(this.type==="doc-end"&&(!e||e.type!=="doc-end")){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}peek(e){return this.stack[this.stack.length-e]}*pop(e){const i=e??this.stack.pop();if(!i)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield i;else{const s=this.peek(1);switch(i.type==="block-scalar"?i.indent="indent"in s?s.indent:0:i.type==="flow-collection"&&s.type==="document"&&(i.indent=0),i.type==="flow-collection"&&m0(i),s.type){case"document":s.value=i;break;case"block-scalar":s.props.push(i);break;case"block-map":{const a=s.items[s.items.length-1];if(a.value){s.items.push({start:[],key:i,sep:[]}),this.onKeyLine=!0;return}else if(a.sep)a.value=i;else{Object.assign(a,{key:i,sep:[]}),this.onKeyLine=!a.explicitKey;return}break}case"block-seq":{const a=s.items[s.items.length-1];a.value?s.items.push({start:[],value:i}):a.value=i;break}case"flow-collection":{const a=s.items[s.items.length-1];!a||a.value?s.items.push({start:[],key:i,sep:[]}):a.sep?a.value=i:Object.assign(a,{key:i,sep:[]});return}default:yield*this.pop(),yield*this.pop(i)}if((s.type==="document"||s.type==="block-map"||s.type==="block-seq")&&(i.type==="block-map"||i.type==="block-seq")){const a=i.items[i.items.length-1];a&&!a.sep&&!a.value&&a.start.length>0&&g0(a.start)===-1&&(i.indent===0||a.start.every(o=>o.type!=="comment"||o.indent<i.indent))&&(s.type==="document"?s.end=a.start:s.items.push({start:a.start}),i.items.splice(-1,1))}}}*stream(){switch(this.type){case"directive-line":yield{type:"directive",offset:this.offset,source:this.source};return;case"byte-order-mark":case"space":case"comment":case"newline":yield this.sourceToken;return;case"doc-mode":case"doc-start":{const e={type:"document",offset:this.offset,start:[]};this.type==="doc-start"&&e.start.push(this.sourceToken),this.stack.push(e);return}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case"doc-start":{g0(e.start)!==-1?(yield*this.pop(),yield*this.step()):e.start.push(this.sourceToken);return}case"anchor":case"tag":case"space":case"comment":case"newline":e.start.push(this.sourceToken);return}const i=this.startBlockValue(e);i?this.stack.push(i):yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if(this.type==="map-value-ind"){const i=Qo(this.peek(2)),s=pr(i);let a;e.end?(a=e.end,a.push(this.sourceToken),delete e.end):a=[this.sourceToken];const o={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:s,key:e,sep:a}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=o}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case"space":case"comment":case"newline":e.props.push(this.sourceToken);return;case"scalar":if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let i=this.source.indexOf(`
|
|
266
|
+
`)+1;for(;i!==0;)this.onNewLine(this.offset+i),i=this.source.indexOf(`
|
|
267
|
+
`,i)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){var s;const i=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,i.value){const a="end"in i.value?i.value.end:void 0,o=Array.isArray(a)?a[a.length-1]:void 0;(o==null?void 0:o.type)==="comment"?a==null||a.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"space":case"comment":if(i.value)e.items.push({start:[this.sourceToken]});else if(i.sep)i.sep.push(this.sourceToken);else{if(this.atIndentedComment(i.start,e.indent)){const a=e.items[e.items.length-2],o=(s=a==null?void 0:a.value)==null?void 0:s.end;if(Array.isArray(o)){Array.prototype.push.apply(o,i.start),o.push(this.sourceToken),e.items.pop();return}}i.start.push(this.sourceToken)}return}if(this.indent>=e.indent){const a=!this.onKeyLine&&this.indent===e.indent,o=a&&(i.sep||i.explicitKey)&&this.type!=="seq-item-ind";let c=[];if(o&&i.sep&&!i.value){const f=[];for(let h=0;h<i.sep.length;++h){const p=i.sep[h];switch(p.type){case"newline":f.push(h);break;case"space":break;case"comment":p.indent>e.indent&&(f.length=0);break;default:f.length=0}}f.length>=2&&(c=i.sep.splice(f[1]))}switch(this.type){case"anchor":case"tag":o||i.value?(c.push(this.sourceToken),e.items.push({start:c}),this.onKeyLine=!0):i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"explicit-key-ind":!i.sep&&!i.explicitKey?(i.start.push(this.sourceToken),i.explicitKey=!0):o||i.value?(c.push(this.sourceToken),e.items.push({start:c,explicitKey:!0})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case"map-value-ind":if(i.explicitKey)if(i.sep)if(i.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(hs(i.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:c,key:null,sep:[this.sourceToken]}]});else if(rw(i.key)&&!hs(i.sep,"newline")){const f=pr(i.start),h=i.key,p=i.sep;p.push(this.sourceToken),delete i.key,delete i.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:f,key:h,sep:p}]})}else c.length>0?i.sep=i.sep.concat(c,this.sourceToken):i.sep.push(this.sourceToken);else if(hs(i.start,"newline"))Object.assign(i,{key:null,sep:[this.sourceToken]});else{const f=pr(i.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:f,key:null,sep:[this.sourceToken]}]})}else i.sep?i.value||o?e.items.push({start:c,key:null,sep:[this.sourceToken]}):hs(i.sep,"map-value-ind")?this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):i.sep.push(this.sourceToken):Object.assign(i,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const f=this.flowScalar(this.type);o||i.value?(e.items.push({start:c,key:f,sep:[]}),this.onKeyLine=!0):i.sep?this.stack.push(f):(Object.assign(i,{key:f,sep:[]}),this.onKeyLine=!0);return}default:{const f=this.startBlockValue(e);if(f){a&&f.type!=="block-seq"&&e.items.push({start:c}),this.stack.push(f);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){var s;const i=e.items[e.items.length-1];switch(this.type){case"newline":if(i.value){const a="end"in i.value?i.value.end:void 0,o=Array.isArray(a)?a[a.length-1]:void 0;(o==null?void 0:o.type)==="comment"?a==null||a.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else i.start.push(this.sourceToken);return;case"space":case"comment":if(i.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(i.start,e.indent)){const a=e.items[e.items.length-2],o=(s=a==null?void 0:a.value)==null?void 0:s.end;if(Array.isArray(o)){Array.prototype.push.apply(o,i.start),o.push(this.sourceToken),e.items.pop();return}}i.start.push(this.sourceToken)}return;case"anchor":case"tag":if(i.value||this.indent<=e.indent)break;i.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;i.value||hs(i.start,"seq-item-ind")?e.items.push({start:[this.sourceToken]}):i.start.push(this.sourceToken);return}if(this.indent>e.indent){const a=this.startBlockValue(e);if(a){this.stack.push(a);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){const i=e.items[e.items.length-1];if(this.type==="flow-error-end"){let s;do yield*this.pop(),s=this.peek(1);while(s&&s.type==="flow-collection")}else if(e.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":!i||i.sep?e.items.push({start:[this.sourceToken]}):i.start.push(this.sourceToken);return;case"map-value-ind":!i||i.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):i.sep?i.sep.push(this.sourceToken):Object.assign(i,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":!i||i.value?e.items.push({start:[this.sourceToken]}):i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const a=this.flowScalar(this.type);!i||i.value?e.items.push({start:[],key:a,sep:[]}):i.sep?this.stack.push(a):Object.assign(i,{key:a,sep:[]});return}case"flow-map-end":case"flow-seq-end":e.end.push(this.sourceToken);return}const s=this.startBlockValue(e);s?this.stack.push(s):(yield*this.pop(),yield*this.step())}else{const s=this.peek(2);if(s.type==="block-map"&&(this.type==="map-value-ind"&&s.indent===e.indent||this.type==="newline"&&!s.items[s.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&s.type!=="flow-collection"){const a=Qo(s),o=pr(a);m0(e);const c=e.end.splice(1,e.end.length);c.push(this.sourceToken);const f={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:o,key:e,sep:c}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=f}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let i=this.source.indexOf(`
|
|
268
|
+
`)+1;for(;i!==0;)this.onNewLine(this.offset+i),i=this.source.indexOf(`
|
|
269
|
+
`,i)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;const i=Qo(e),s=pr(i);return s.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;const i=Qo(e),s=pr(i);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,i){return this.type!=="comment"||this.indent<=i?!1:e.every(s=>s.type==="newline"||s.type==="space")}*documentEnd(e){this.type!=="doc-mode"&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop())}}}function aw(n){const e=n.prettyErrors!==!1;return{lineCounter:n.lineCounter||e&&new sw||null,prettyErrors:e}}function QN(n,e={}){const{lineCounter:i,prettyErrors:s}=aw(e),a=new cp(i==null?void 0:i.addNewLine),o=new op(e),c=Array.from(o.compose(a.parse(n)));if(s&&i)for(const f of c)f.errors.forEach(Tc(n,i)),f.warnings.forEach(Tc(n,i));return c.length>0?c:Object.assign([],{empty:!0},o.streamInfo())}function lw(n,e={}){const{lineCounter:i,prettyErrors:s}=aw(e),a=new cp(i==null?void 0:i.addNewLine),o=new op(e);let c=null;for(const f of o.compose(a.parse(n),!0,n.length))if(!c)c=f;else if(c.options.logLevel!=="silent"){c.errors.push(new gs(f.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}return s&&i&&(c.errors.forEach(Tc(n,i)),c.warnings.forEach(Tc(n,i))),c}function PN(n,e,i){let s;typeof e=="function"?s=e:i===void 0&&e&&typeof e=="object"&&(i=e);const a=lw(n,i);if(!a)return null;if(a.warnings.forEach(o=>CS(a.options.logLevel,o)),a.errors.length>0){if(a.options.logLevel!=="silent")throw a.errors[0];a.errors=[]}return a.toJS(Object.assign({reviver:s},i))}function JN(n,e,i){let s=null;if(typeof e=="function"||Array.isArray(e)?s=e:i===void 0&&e&&(i=e),typeof i=="string"&&(i=i.length),typeof i=="number"){const a=Math.round(i);i=a<1?void 0:a>8?{indent:8}:{indent:a}}if(n===void 0){const{keepUndefined:a}=i??e??{};if(!a)return}return ws(n)&&!s?n.toString(i):new $r(n,s,i).toString(i)}const ow=Object.freeze(Object.defineProperty({__proto__:null,Alias:Rc,CST:XN,Composer:op,Document:$r,Lexer:iw,LineCounter:sw,Pair:wt,Parser:cp,Scalar:fe,Schema:Vc,YAMLError:ap,YAMLMap:Pt,YAMLParseError:gs,YAMLSeq:Bi,YAMLWarning:XS,isAlias:Ss,isCollection:$e,isDocument:ws,isMap:Ur,isNode:Ve,isPair:He,isScalar:Re,isSeq:Hr,parse:PN,parseAllDocuments:QN,parseDocument:lw,stringify:JN,visit:Di,visitAsync:jc},Symbol.toStringTag,{value:"Module"})),ZN=({action:n,model:e,sdkLanguage:i,testIdAttributeName:s,isInspecting:a,setIsInspecting:o,highlightedElement:c,setHighlightedElement:f})=>{const[h,p]=U.useState("action"),[y]=fn("shouldPopulateCanvasFromScreenshot",!1),m=U.useMemo(()=>n2(n),[n]),{snapshotInfoUrl:v,snapshotUrl:S,popoutUrl:T}=U.useMemo(()=>{const E=m[h];return e&&E?i2(e.traceUri,E,y):{snapshotInfoUrl:void 0,snapshotUrl:void 0,popoutUrl:void 0}},[m,h,y,e]),x=U.useMemo(()=>v!==void 0?{snapshotInfoUrl:v,snapshotUrl:S,popoutUrl:T}:void 0,[v,S,T]);return w.jsxs("div",{className:"snapshot-tab vbox",children:[w.jsxs(xd,{children:[w.jsx(It,{className:"pick-locator",title:"Pick locator",icon:"target",toggled:a,onClick:()=>o(!a)}),w.jsx("div",{className:"hbox",style:{height:"100%"},role:"tablist",children:["action","before","after"].map(E=>w.jsx(uv,{id:E,title:t2(E),selected:h===E,onSelect:()=>p(E)},E))}),w.jsx("div",{style:{flex:"auto"}}),w.jsx(It,{icon:"link-external",title:"Open snapshot in a new tab",disabled:!(x!=null&&x.popoutUrl),onClick:()=>{const E=window.open((x==null?void 0:x.popoutUrl)||"","_blank");E==null||E.addEventListener("DOMContentLoaded",()=>{new uS(E,{isUnderTest:uw,sdkLanguage:i,testIdAttributeName:s,stableRafCount:1,browserName:"chromium",customEngines:[]}).consoleApi.install()})}})]}),w.jsx(WN,{snapshotUrls:x,sdkLanguage:i,testIdAttributeName:s,isInspecting:a,setIsInspecting:o,highlightedElement:c,setHighlightedElement:f})]})},WN=({snapshotUrls:n,sdkLanguage:e,testIdAttributeName:i,isInspecting:s,setIsInspecting:a,highlightedElement:o,setHighlightedElement:c})=>{const f=U.useRef(null),h=U.useRef(null),[p,y]=U.useState({viewport:fw,url:""}),m=U.useRef({iteration:0,visibleIframe:0});return U.useEffect(()=>{(async()=>{const v=m.current.iteration+1,S=1-m.current.visibleIframe;m.current.iteration=v;const T=await s2(n==null?void 0:n.snapshotInfoUrl);if(m.current.iteration!==v)return;const x=[f,h][S].current;if(x){let E=()=>{};const A=new Promise(N=>E=N);try{x.addEventListener("load",E),x.addEventListener("error",E);const N=(n==null?void 0:n.snapshotUrl)||UC;x.contentWindow?x.contentWindow.location.replace(N):x.src=N,await A}catch{}finally{x.removeEventListener("load",E),x.removeEventListener("error",E)}}m.current.iteration===v&&(m.current.visibleIframe=S,y(T))})()},[n]),w.jsxs("div",{className:"vbox",tabIndex:0,onKeyDown:v=>{v.key==="Escape"&&s&&a(!1)},children:[w.jsx(y0,{isInspecting:s,sdkLanguage:e,testIdAttributeName:i,highlightedElement:o,setHighlightedElement:c,iframe:f.current,iteration:m.current.iteration}),w.jsx(y0,{isInspecting:s,sdkLanguage:e,testIdAttributeName:i,highlightedElement:o,setHighlightedElement:c,iframe:h.current,iteration:m.current.iteration}),w.jsx(e2,{snapshotInfo:p,children:w.jsxs("div",{className:"snapshot-switcher",children:[w.jsx("iframe",{ref:f,name:"snapshot",title:"DOM Snapshot",className:Qe(m.current.visibleIframe===0&&"snapshot-visible")}),w.jsx("iframe",{ref:h,name:"snapshot",title:"DOM Snapshot",className:Qe(m.current.visibleIframe===1&&"snapshot-visible")})]})})]})},e2=({snapshotInfo:n,children:e})=>{const[i,s]=bs(),a=40,o={width:n.viewport.width,height:n.viewport.height},c={width:Math.max(o.width,480),height:Math.max(o.height+a,320)},f=Math.min(i.width/c.width,i.height/c.height,1),h={x:(i.width-c.width)/2,y:(i.height-c.height)/2};return w.jsx("div",{ref:s,className:"snapshot-wrapper",children:w.jsxs("div",{className:"snapshot-container",style:{width:c.width+"px",height:c.height+"px",transform:`translate(${h.x}px, ${h.y}px) scale(${f})`},children:[w.jsx($C,{url:n.url}),w.jsx("div",{className:"snapshot-browser-body",children:w.jsx("div",{style:{width:o.width+"px",height:o.height+"px"},children:e})})]})})};function t2(n){return n==="before"?"Before":n==="after"?"After":n==="action"?"Action":n}const y0=({iframe:n,isInspecting:e,sdkLanguage:i,testIdAttributeName:s,highlightedElement:a,setHighlightedElement:o,iteration:c})=>(U.useEffect(()=>{const f=a.lastEdited==="ariaSnapshot"?a.ariaSnapshot:void 0,h=a.lastEdited==="locator"?a.locator:void 0,p=!!f||!!h||e,y=[],m=new URLSearchParams(window.location.search).get("isUnderTest")==="true";try{cw(y,p,i,s,m,"",n==null?void 0:n.contentWindow)}catch{}const v=f?Ed(ow,f):void 0,S=h?qC(i,h,s):void 0;for(const{recorder:T,frameSelector:x}of y){const E=S!=null&&S.startsWith(x)?S.substring(x.length).trim():void 0,A=(v==null?void 0:v.errors.length)===0?v.fragment:void 0;T.setUIState({mode:e?"inspecting":"none",actionSelector:E,ariaTemplate:A,language:i,testIdAttributeName:s,overlay:{offsetX:0}},{async elementPicked(N){o({locator:Li(i,x+N.selector),ariaSnapshot:N.ariaSnapshot,lastEdited:"none"})},highlightUpdated(){for(const N of y)N.recorder!==T&&N.recorder.clearHighlight()}})}},[n,e,a,o,i,s,c]),w.jsx(w.Fragment,{}));function cw(n,e,i,s,a,o,c){if(!c)return;const f=c;if(!f._recorder&&e){const h=new uS(c,{isUnderTest:a,sdkLanguage:i,testIdAttributeName:s,stableRafCount:1,browserName:"chromium",customEngines:[]}),p=new RC(h);f._injectedScript=h,f._recorder={recorder:p,frameSelector:o},a&&(window._weakRecordersForTest=window._weakRecordersForTest||new Set,window._weakRecordersForTest.add(new WeakRef(p)))}f._recorder&&n.push(f._recorder);for(let h=0;h<c.frames.length;++h){const p=c.frames[h],y=p.frameElement?f._injectedScript.generateSelectorSimple(p.frameElement,{omitInternalEngines:!0,testIdAttributeName:s})+" >> internal:control=enter-frame >> ":"";cw(n,e,i,s,a,o+y,p)}}const Ga=(n,e,i=!1)=>{if(!n)return;const s=n[e];if(s){if(!n.pageId){console.error("snapshot action must have a pageId");return}return{action:n,snapshotName:s,pageId:n.pageId,point:n.point,hasInputTarget:i}}};function n2(n){if(!n)return{};let e=Ga(n,"beforeSnapshot");if(!e){for(let a=Sb(n);a;a=Sb(a))if(a.endTime<=n.startTime&&a.afterSnapshot){e=Ga(a,"afterSnapshot");break}}let i=Ga(n,"afterSnapshot");if(!i){let a;for(let o=wb(n);o&&o.startTime<=n.endTime;o=wb(o))o.endTime>n.endTime||!o.afterSnapshot||a&&a.endTime>o.endTime||(a=o);a?i=Ga(a,"afterSnapshot"):i=e}const s=Ga(n,"inputSnapshot",!0)??i;return s&&(s.point=n.point),{action:s,before:e,after:i}}const uw=new URLSearchParams(window.location.search).has("isUnderTest");function i2(n,e,i){const s=new URLSearchParams;s.set("trace",n),s.set("name",e.snapshotName),uw&&s.set("isUnderTest","true"),e.point&&(s.set("pointX",String(e.point.x)),s.set("pointY",String(e.point.y)),e.hasInputTarget&&s.set("hasInputTarget","1")),i&&s.set("shouldPopulateCanvasFromScreenshot","1");const a=new URL(`snapshot/${e.pageId}?${s.toString()}`,window.location.href).toString(),o=new URL(`snapshotInfo/${e.pageId}?${s.toString()}`,window.location.href).toString(),c=new URLSearchParams;c.set("r",a),c.set("trace",n);const f=new URL(`snapshot.html?${c.toString()}`,window.location.href).toString();return{snapshotInfoUrl:o,snapshotUrl:a,popoutUrl:f}}async function s2(n){const e={url:"",viewport:fw,timestamp:void 0,wallTime:void 0};if(n){const s=await(await fetch(n)).json();s.error||(e.url=s.url,e.viewport=s.viewport,e.timestamp=s.timestamp,e.wallTime=s.wallTime)}return e}const fw={width:1280,height:720},hw={width:200,height:45},yr=2.5,r2=hw.height+yr*2,a2=({boundaries:n,previewPoint:e})=>{var y,m;const i=si(),[s,a]=bs(),o=U.useRef(null);let c=0;if(o.current&&e){const v=o.current.getBoundingClientRect();c=(e.clientY-v.top+o.current.scrollTop)/r2|0}const f=(m=(y=i==null?void 0:i.pages)==null?void 0:y[c])==null?void 0:m.screencastFrames;let h,p;if(e!==void 0&&f&&f.length){const v=n.minimum+(n.maximum-n.minimum)*e.x/s.width;h=f[v0(f,v,dw)-1];const S={width:Math.min(800,window.innerWidth/2|0),height:Math.min(800,window.innerHeight/2|0)};p=h?pw({width:h.width,height:h.height},S):void 0}return w.jsxs("div",{className:"film-strip",ref:a,children:[w.jsx("div",{className:"film-strip-lanes",ref:o,children:i==null?void 0:i.pages.map((v,S)=>v.screencastFrames.length?w.jsx(l2,{boundaries:n,page:v,width:s.width},S):null)}),i&&(e==null?void 0:e.x)!==void 0&&w.jsxs("div",{className:"film-strip-hover",style:{top:s.bottom+5,left:Math.min(e.x,s.width-(p?p.width:0)-10)},children:[e.action&&w.jsx("div",{className:"film-strip-hover-title",children:vd(e.action,e)}),h&&p&&w.jsx("div",{style:{width:p.width,height:p.height},children:w.jsx("img",{src:i.createRelativeUrl(`sha1/${h.sha1}`),width:p.width,height:p.height})})]})]})},l2=({boundaries:n,page:e,width:i})=>{const s=si(),a={width:0,height:0},o=e.screencastFrames;for(const E of o)a.width=Math.max(a.width,E.width),a.height=Math.max(a.height,E.height);const c=pw(a,hw),f=o[0].timestamp,h=o[o.length-1].timestamp,p=n.maximum-n.minimum,y=(f-n.minimum)/p*i,m=(n.maximum-h)/p*i,S=(h-f)/p*i/(c.width+2*yr)|0,T=(h-f)/S,x=[];for(let E=0;f&&T&&E<S;++E){const A=f+T*E,N=v0(o,A,dw)-1;x.push(w.jsx("div",{className:"film-strip-frame",style:{width:c.width,height:c.height,backgroundImage:`url(${s==null?void 0:s.createRelativeUrl("sha1/"+o[N].sha1)})`,backgroundSize:`${c.width}px ${c.height}px`,margin:yr,marginRight:yr}},E))}return x.push(w.jsx("div",{className:"film-strip-frame",style:{width:c.width,height:c.height,backgroundImage:`url(${s==null?void 0:s.createRelativeUrl("sha1/"+o[o.length-1].sha1)})`,backgroundSize:`${c.width}px ${c.height}px`,margin:yr,marginRight:yr}},x.length)),w.jsx("div",{className:"film-strip-lane",style:{marginLeft:y+"px",marginRight:m+"px"},children:x})};function dw(n,e){return n-e.timestamp}function pw(n,e){const i=Math.max(n.width/e.width,n.height/e.height);return{width:n.width/i|0,height:n.height/i|0}}const o2=({model:n,boundaries:e,consoleEntries:i,networkResources:s,onSelected:a,highlightedAction:o,highlightedResourceKey:c,highlightedConsoleEntryOrdinal:f,selectedTime:h,setSelectedTime:p,sdkLanguage:y})=>{const[m,v]=bs(),[S,T]=U.useState(),[x,E]=U.useState(),[A]=fn("actionsFilter",[]),{offsets:N,curtainLeft:B,curtainRight:V}=U.useMemo(()=>{let P=h||e;if(S&&S.startX!==S.endX){const J=Cn(m.width,e,S.startX),se=Cn(m.width,e,S.endX);P={minimum:Math.min(J,se),maximum:Math.max(J,se)}}const W=cn(m.width,e,P.minimum),q=cn(m.width,e,e.maximum)-cn(m.width,e,P.maximum);return{offsets:c2(m.width,e),curtainLeft:W,curtainRight:q}},[h,e,S,m]),$=U.useMemo(()=>n==null?void 0:n.filteredActions(A),[n,A]),z=U.useMemo(()=>{const P=[];for(const W of $||[])P.push({action:W,leftTime:W.startTime,rightTime:W.endTime||e.maximum,leftPosition:cn(m.width,e,W.startTime),rightPosition:cn(m.width,e,W.endTime||e.maximum),active:!1,error:!!W.error});for(const W of(n==null?void 0:n.resources)||[]){const Ce=W._monotonicTime,q=W._monotonicTime+W.time;P.push({resourceKey:W.id,leftTime:Ce,rightTime:q,leftPosition:cn(m.width,e,Ce),rightPosition:cn(m.width,e,q),active:!1,error:!1})}for(const W of i||[])P.push({consoleMessage:W,leftTime:W.timestamp,rightTime:W.timestamp,leftPosition:cn(m.width,e,W.timestamp),rightPosition:cn(m.width,e,W.timestamp),active:!1,error:W.isError});return P},[n,$,i,e,m]);U.useMemo(()=>{for(const P of z)o?P.active=P.action===o:c?P.active=P.resourceKey===c:f!==void 0?P.active=P.consoleMessage===(i==null?void 0:i[f]):P.active=!1},[z,o,c,f,i]);const Q=U.useCallback(P=>{if(E(void 0),!v.current)return;const W=P.clientX-v.current.getBoundingClientRect().left,Ce=Cn(m.width,e,W),q=h?cn(m.width,e,h.minimum):0,J=h?cn(m.width,e,h.maximum):0;h&&Math.abs(W-q)<10?T({startX:J,endX:W,type:"resize"}):h&&Math.abs(W-J)<10?T({startX:q,endX:W,type:"resize"}):h&&Ce>h.minimum&&Ce<h.maximum&&P.clientY-v.current.getBoundingClientRect().top<20?T({startX:q,endX:J,pivot:W,type:"move"}):T({startX:W,endX:W,type:"resize"})},[e,m,v,h]),H=U.useCallback(P=>{if(!v.current)return;const W=P.clientX-v.current.getBoundingClientRect().left,Ce=Cn(m.width,e,W),q=$==null?void 0:$.findLast(xe=>xe.startTime<=Ce);if(!P.buttons){T(void 0);return}if(q&&a(q),!S)return;let J=S;if(S.type==="resize")J={...S,endX:W};else{const xe=W-S.pivot;let k=S.startX+xe,X=S.endX+xe;k<0&&(k=0,X=k+(S.endX-S.startX)),X>m.width&&(X=m.width,k=X-(S.endX-S.startX)),J={...S,startX:k,endX:X,pivot:W}}T(J);const se=Cn(m.width,e,J.startX),we=Cn(m.width,e,J.endX);se!==we&&p({minimum:Math.min(se,we),maximum:Math.max(se,we)})},[e,S,m,$,a,v,p]),L=U.useCallback(()=>{if(E(void 0),!!S){if(S.startX!==S.endX){const P=Cn(m.width,e,S.startX),W=Cn(m.width,e,S.endX);p({minimum:Math.min(P,W),maximum:Math.max(P,W)})}else{const P=Cn(m.width,e,S.startX),W=$==null?void 0:$.findLast(Ce=>Ce.startTime<=P);W&&a(W),p(void 0)}T(void 0)}},[e,S,m,$,p,a]),ne=U.useCallback(P=>{if(!v.current)return;const W=P.clientX-v.current.getBoundingClientRect().left,Ce=Cn(m.width,e,W),q=$==null?void 0:$.findLast(J=>J.startTime<=Ce);E({x:W,clientY:P.clientY,action:q,sdkLanguage:y})},[e,m,$,v,y]),ae=U.useCallback(()=>{E(void 0)},[]),G=U.useCallback(()=>{p(void 0)},[p]);return w.jsxs("div",{className:"timeline-view-container",children:[!!S&&w.jsx(iv,{cursor:(S==null?void 0:S.type)==="resize"?"ew-resize":"grab",onPaneMouseUp:L,onPaneMouseMove:H,onPaneDoubleClick:G}),w.jsxs("div",{ref:v,className:"timeline-view",onMouseDown:Q,onMouseMove:ne,onMouseLeave:ae,children:[w.jsx("div",{className:"timeline-grid",children:N.map((P,W)=>w.jsx("div",{className:"timeline-divider",style:{left:P.position+"px"},children:w.jsx("div",{className:"timeline-time",children:mt(P.time-e.minimum)})},W))}),w.jsx("div",{style:{height:8}}),w.jsx(a2,{boundaries:e,previewPoint:x}),w.jsx("div",{className:"timeline-bars",children:z.filter(P=>!P.action||P.action.class!=="Test").map((P,W)=>w.jsx("div",{className:Qe("timeline-bar",P.action&&"action",P.resourceKey&&"network",P.consoleMessage&&"console-message",P.active&&"active",P.error&&"error"),style:{left:P.leftPosition,width:Math.max(5,P.rightPosition-P.leftPosition),top:u2(P),bottom:0}},W))}),w.jsx("div",{className:"timeline-marker",style:{display:x!==void 0?"block":"none",left:((x==null?void 0:x.x)||0)+"px"}}),h&&w.jsxs("div",{className:"timeline-window",children:[w.jsx("div",{className:"timeline-window-curtain left",style:{width:B}}),w.jsx("div",{className:"timeline-window-resizer",style:{left:-5}}),w.jsx("div",{className:"timeline-window-center",children:w.jsx("div",{className:"timeline-window-drag"})}),w.jsx("div",{className:"timeline-window-resizer",style:{left:5}}),w.jsx("div",{className:"timeline-window-curtain right",style:{width:V}})]})]})]})};function c2(n,e){let s=n/64;const a=e.maximum-e.minimum,o=n/a;let c=a/s;const f=Math.ceil(Math.log(c)/Math.LN10);c=Math.pow(10,f),c*o>=320&&(c=c/5),c*o>=128&&(c=c/2);const h=e.minimum;let p=e.maximum;p+=64/o,s=Math.ceil((p-h)/c),c||(s=0);const y=[];for(let m=0;m<s;++m){const v=h+c*m;y.push({position:cn(n,e,v),time:v})}return y}function cn(n,e,i){return(i-e.minimum)/(e.maximum-e.minimum)*n}function Cn(n,e,i){return i/n*(e.maximum-e.minimum)+e.minimum}function u2(n){return n.resourceKey?25:20}const f2=({model:n})=>{var i,s;if(!n)return w.jsx(w.Fragment,{});const e=n.wallTime!==void 0?new Date(n.wallTime).toLocaleString(void 0,{timeZoneName:"short"}):void 0;return w.jsxs("div",{style:{flex:"auto",display:"block",overflow:"hidden auto"},children:[w.jsx("div",{className:"call-section",style:{paddingTop:2},children:"Time"}),!!e&&w.jsxs("div",{className:"call-line",children:["start time:",w.jsx("span",{className:"call-value datetime",title:e,children:e})]}),w.jsxs("div",{className:"call-line",children:["duration:",w.jsx("span",{className:"call-value number",title:mt(n.endTime-n.startTime),children:mt(n.endTime-n.startTime)})]}),n.testTimeout!==void 0&&w.jsxs("div",{className:"call-line",children:["test timeout:",w.jsx("span",{className:"call-value number",title:mt(n.testTimeout),children:mt(n.testTimeout)})]}),w.jsx("div",{className:"call-section",children:"Browser"}),w.jsxs("div",{className:"call-line",children:["engine:",w.jsx("span",{className:"call-value string",title:n.browserName,children:n.browserName})]}),n.channel&&w.jsxs("div",{className:"call-line",children:["channel:",w.jsx("span",{className:"call-value string",title:n.channel,children:n.channel})]}),n.platform&&w.jsxs("div",{className:"call-line",children:["platform:",w.jsx("span",{className:"call-value string",title:n.platform,children:n.platform})]}),n.playwrightVersion&&w.jsxs("div",{className:"call-line",children:["playwright version:",w.jsx("span",{className:"call-value string",title:n.playwrightVersion,children:n.playwrightVersion})]}),n.options.userAgent&&w.jsxs("div",{className:"call-line",children:["user agent:",w.jsx("span",{className:"call-value datetime",title:n.options.userAgent,children:n.options.userAgent})]}),n.options.baseURL&&w.jsxs(w.Fragment,{children:[w.jsx("div",{className:"call-section",style:{paddingTop:2},children:"Config"}),w.jsxs("div",{className:"call-line",children:["baseURL:",w.jsx("a",{className:"call-value string",href:n.options.baseURL,title:n.options.baseURL,target:"_blank",rel:"noopener noreferrer",children:n.options.baseURL})]})]}),w.jsx("div",{className:"call-section",children:"Viewport"}),n.options.viewport&&w.jsxs("div",{className:"call-line",children:["width:",w.jsx("span",{className:"call-value number",title:String(!!((i=n.options.viewport)!=null&&i.width)),children:n.options.viewport.width})]}),n.options.viewport&&w.jsxs("div",{className:"call-line",children:["height:",w.jsx("span",{className:"call-value number",title:String(!!((s=n.options.viewport)!=null&&s.height)),children:n.options.viewport.height})]}),w.jsxs("div",{className:"call-line",children:["is mobile:",w.jsx("span",{className:"call-value boolean",title:String(!!n.options.isMobile),children:String(!!n.options.isMobile)})]}),n.options.deviceScaleFactor&&w.jsxs("div",{className:"call-line",children:["device scale:",w.jsx("span",{className:"call-value number",title:String(n.options.deviceScaleFactor),children:String(n.options.deviceScaleFactor)})]}),w.jsx("div",{className:"call-section",children:"Counts"}),w.jsxs("div",{className:"call-line",children:["pages:",w.jsx("span",{className:"call-value number",children:n.pages.length})]}),w.jsxs("div",{className:"call-line",children:["actions:",w.jsx("span",{className:"call-value number",children:n.actions.length})]}),w.jsxs("div",{className:"call-line",children:["events:",w.jsx("span",{className:"call-value number",children:n.events.length})]})]})},h2=({annotations:n})=>n.length?w.jsx("div",{className:"annotations-tab",children:n.map((e,i)=>w.jsxs("div",{className:"annotation-item",children:[w.jsx("span",{style:{fontWeight:"bold"},children:e.type}),e.description&&w.jsxs("span",{children:[": ",av(e.description)]})]},`annotation-${i}`))}):w.jsx(vs,{text:"No annotations"}),d2=({sdkLanguage:n,isInspecting:e,setIsInspecting:i,highlightedElement:s,setHighlightedElement:a})=>{const[o,c]=U.useState(),f=U.useCallback(h=>{const{errors:p}=Ed(ow,h,{prettyErrors:!1}),y=p.map(m=>({message:m.message,line:m.range[1].line,column:m.range[1].col,type:"subtle-error"}));c(y),a({...s,ariaSnapshot:h,lastEdited:"ariaSnapshot"}),i(!1)},[s,a,i]);return w.jsxs("div",{style:{flex:"auto",backgroundColor:"var(--vscode-sideBar-background)",padding:"0 10px 10px 10px",overflow:"auto"},children:[w.jsxs("div",{className:"hbox",style:{lineHeight:"28px",color:"var(--vscode-editorCodeLens-foreground)"},children:[w.jsx("div",{children:"Locator"}),w.jsx(It,{style:{margin:"0 4px"},title:"Pick locator",icon:"target",toggled:e,onClick:()=>i(!e)}),w.jsx("div",{style:{flex:"auto"}}),w.jsx(It,{icon:"files",title:"Copy locator",onClick:()=>{ub(s.locator||"")}})]}),w.jsx("div",{style:{height:50},children:w.jsx(Cr,{text:s.locator||"",highlighter:n,isFocused:!0,wrapLines:!0,onChange:h=>{a({...s,locator:h,lastEdited:"locator"}),i(!1)}})}),w.jsxs("div",{className:"hbox",style:{lineHeight:"28px",color:"var(--vscode-editorCodeLens-foreground)"},children:[w.jsx("div",{style:{flex:"auto"},children:"Aria snapshot"}),w.jsx(It,{icon:"files",title:"Copy snapshot",onClick:()=>{ub(s.ariaSnapshot||"")}})]}),w.jsx("div",{style:{height:150},children:w.jsx(Cr,{text:s.ariaSnapshot||"",highlighter:"yaml",wrapLines:!1,highlight:o,onChange:f})})]})},p2=({className:n,style:e,open:i,isModal:s,minWidth:a,verticalOffset:o,requestClose:c,anchor:f,dataTestId:h,children:p})=>{const y=U.useRef(null),[m,v]=U.useState(0),[S]=Uh(y),[T,x]=Uh(f),E=f?g2(S,T,o):void 0;return U.useEffect(()=>{const A=B=>{!y.current||!(B.target instanceof Node)||y.current.contains(B.target)||c==null||c()},N=B=>{B.key==="Escape"&&(c==null||c())};return i?(document.addEventListener("mousedown",A),document.addEventListener("keydown",N),()=>{document.removeEventListener("mousedown",A),document.removeEventListener("keydown",N)}):()=>{}},[i,c]),U.useLayoutEffect(()=>x(),[i,x]),U.useEffect(()=>{const A=()=>v(N=>N+1);return window.addEventListener("resize",A),()=>{window.removeEventListener("resize",A)}},[]),U.useLayoutEffect(()=>{y.current&&(i?s?y.current.showModal():y.current.show():y.current.close())},[i,s]),w.jsx("dialog",{ref:y,style:{position:"fixed",margin:E?0:void 0,zIndex:110,top:E==null?void 0:E.top,left:E==null?void 0:E.left,minWidth:a||0,...e},className:n,"data-testid":h,children:p})};function g2(n,e,i=4,s=4){let a=Math.max(s,e.left);a+n.width>window.innerWidth-s&&(a=window.innerWidth-n.width-s);let o=Math.max(0,e.bottom)+i;return o+n.height>window.innerHeight-i&&(Math.max(0,e.top)>n.height+i?o=Math.max(0,e.top)-n.height-i:o=window.innerHeight-i-n.height),{left:a,top:o}}const m2=({title:n,icon:e,buttonChildren:i,anchorRef:s,dialogDataTestId:a,children:o})=>{const c=U.useRef(null),f=s??c,[h,p]=U.useState(!1);return w.jsxs(w.Fragment,{children:[w.jsx(It,{ref:c,icon:e,title:n,onClick:()=>p(y=>!y),children:i}),w.jsx(p2,{style:{backgroundColor:"var(--vscode-sideBar-background)",padding:"4px 8px"},open:h,verticalOffset:8,requestClose:()=>p(!1),anchor:f,dataTestId:a,children:o})]})},gw=({settings:n})=>w.jsx("div",{className:"vbox settings-view",children:n.map(e=>{const i=`setting-${e.name.replaceAll(/\s+/g,"-")}`;return w.jsx("div",{className:`setting setting-${e.type}`,title:e.title,children:y2(e,i)},e.name)})}),y2=(n,e)=>{switch(n.type){case"check":return w.jsxs(w.Fragment,{children:[w.jsx("input",{type:"checkbox",id:e,checked:n.value,onChange:()=>n.set(!n.value)}),w.jsxs("label",{htmlFor:e,children:[n.name,!!n.count&&w.jsx("span",{className:"setting-counter",children:n.count})]})]});case"select":return w.jsxs(w.Fragment,{children:[w.jsxs("label",{htmlFor:e,children:[n.name,":",!!n.count&&w.jsx("span",{className:"setting-counter",children:n.count})]}),w.jsx("select",{id:e,value:n.value,onChange:i=>n.set(i.target.value),children:n.options.map(i=>w.jsx("option",{value:i.value,children:i.label},i.value))})]});default:return null}},N2=n=>{var i;const e=S2((i=n.model)==null?void 0:i.traceUri);return w.jsx(lv.Provider,{value:n.model,children:w.jsx(b2,{partition:e,...n})})},b2=n=>{var $i;const{partition:e,model:i,showSourcesFirst:s,rootDir:a,fallbackLocation:o,isLive:c,hideTimeline:f,status:h,annotations:p,inert:y,onOpenExternally:m,revealSource:v,testRunMetadata:S}=n,[T,x]=fn("navigatorTab","actions"),[E,A]=fn("propertiesTab",s?"source":"call"),[N,B]=fn("propertiesSidebarLocation","bottom"),[V]=fn("actionsFilter",[]),[$,z]=Mi("selectedCallId"),[Q,H]=Mi("selectedTime"),[L,ne]=Mi("highlightedCallId"),[ae,G]=Mi("revealedErrorKey"),[P,W]=Mi("highlightedConsoleMessageOrdinal"),[Ce,q]=Mi("revealedAttachmentCallId"),[J,se]=Mi("highlightedResourceKey"),[we,xe]=Mi("treeState",{expandedItems:new Map}),[k,X]=U.useState("");Rx(e);const[Z,ee]=U.useState({lastEdited:"none"}),[ce,de]=U.useState(!1),Ee=U.useCallback(le=>{z(le==null?void 0:le.callId),G(void 0)},[z,G]),ve=U.useMemo(()=>i==null?void 0:i.filteredActions(V),[i,V]),qe=((i==null?void 0:i.actions.length)??0)-((ve==null?void 0:ve.length)??0),Ln=U.useMemo(()=>ve==null?void 0:ve.find(le=>le.callId===L),[ve,L]),ri=U.useCallback(le=>{ne(le==null?void 0:le.callId)},[ne]),Vr=U.useMemo(()=>(i==null?void 0:i.sources)||new Map,[i]);U.useEffect(()=>{H(void 0),G(void 0)},[i,H,G]);const Ui=U.useMemo(()=>{if($){const xn=ve==null?void 0:ve.find(Tt=>Tt.callId===$);if(xn)return xn}const le=i==null?void 0:i.failedAction();if(le)return le;if(ve!=null&&ve.length){let xn=ve.length-1;for(let Tt=0;Tt<ve.length;++Tt)if(ve[Tt].title==="After Hooks"&&Tt){xn=Tt-1;break}return ve[xn]}},[i,ve,$]),xt=U.useMemo(()=>Ln||Ui,[Ui,Ln]),xs=U.useCallback(le=>{Ee(le),ri(void 0)},[Ee,ri]),Et=U.useCallback(le=>{A(le),le!=="inspector"&&de(!1)},[A]),Sl=U.useCallback(le=>{!ce&&le&&Et("inspector"),de(le)},[de,Et,ce]),wl=U.useCallback(le=>{ee(le),Et("inspector")},[Et]),Gr=U.useCallback(le=>{Et("attachments"),q({callId:le})},[Et,q]);U.useEffect(()=>{v&&Et("source")},[v,Et]);const Hi=CT(i,Q),qi=e_(i,Q),Es=xT(i),Fc=U.useMemo(()=>{var le;return ae!==void 0?(le=Es.errors.get(ae))==null?void 0:le.stack:xt==null?void 0:xt.stack},[xt,ae,Es]),Je=(i==null?void 0:i.sdkLanguage)||"javascript",Yc={id:"inspector",title:"Locator",render:()=>w.jsx(d2,{sdkLanguage:Je,isInspecting:ce,setIsInspecting:Sl,highlightedElement:Z,setHighlightedElement:ee})},xl={id:"call",title:"Call",render:()=>w.jsx($E,{action:xt,startTimeOffset:(i==null?void 0:i.startTime)??0,sdkLanguage:Je})},El={id:"log",title:"Log",render:()=>w.jsx(KE,{action:xt,isLive:c})},Ts={id:"errors",title:"Errors",errorCount:Es.errors.size,render:()=>w.jsx(TT,{errorsModel:Es,testRunMetadata:S,sdkLanguage:Je,revealInSource:le=>{le.action?Ee(le.action):G(le.message),Et("source")},wallTime:(i==null?void 0:i.wallTime)??0})};let Tl;!Ui&&o&&(Tl=($i=o.source)==null?void 0:$i.errors.length);const _s={id:"source",title:"Source",errorCount:Tl,render:()=>w.jsx(vT,{stack:Fc,sources:Vr,rootDir:a,stackFrameLocation:N==="bottom"?"right":"bottom",fallbackLocation:o,onOpenExternally:m})},Qc={id:"console",title:"Console",count:Hi.entries.length,render:()=>w.jsx(NT,{consoleModel:Hi,boundaries:Jt,selectedTime:Q,onAccepted:le=>H({minimum:le.timestamp,maximum:le.timestamp}),onEntryHovered:W})},Pc={id:"network",title:"Network",count:qi.resources.length,render:()=>w.jsx(t_,{boundaries:Jt,networkModel:qi,onResourceHovered:se,sdkLanguage:(i==null?void 0:i.sdkLanguage)??"javascript"})},Ii={id:"attachments",title:"Attachments",count:i==null?void 0:i.visibleAttachments.length,render:()=>w.jsx(fT,{revealedAttachmentCallId:Ce})},it=[Yc,xl,El,Ts,Qc,Pc,_s,Ii];if(p!==void 0){const le={id:"annotations",title:"Annotations",count:p.length,render:()=>w.jsx(h2,{annotations:p})};it.push(le)}if(s){const le=it.indexOf(_s);it.splice(le,1),it.splice(1,0,_s)}const{boundaries:Jt}=U.useMemo(()=>{const le={minimum:(i==null?void 0:i.startTime)||0,maximum:(i==null?void 0:i.endTime)||3e4};return le.minimum>le.maximum&&(le.minimum=0,le.maximum=3e4),le.maximum+=(le.maximum-le.minimum)/20,{boundaries:le}},[i]);let at=0;!c&&i&&i.endTime>=0?at=i.endTime-i.startTime:i&&i.wallTime&&(at=Date.now()-i.wallTime);const Jc={id:"actions",title:"Actions",component:w.jsxs("div",{className:"vbox",children:[h&&w.jsxs("div",{className:"workbench-run-status","data-testid":"workbench-run-status",children:[w.jsx("span",{className:Qe("codicon",nv(h))}),w.jsx("div",{children:HE(h)}),w.jsx("div",{className:"spacer"}),w.jsx("div",{className:"workbench-run-duration",children:at?mt(at):""})]}),w.jsx("div",{className:"workbench-action-filter",children:w.jsx("input",{type:"search",placeholder:"Filter actions","aria-label":"Filter actions",spellCheck:!1,value:k,onChange:le=>X(le.target.value)})}),w.jsx(IE,{sdkLanguage:Je,actions:ve||[],selectedAction:i?Ui:void 0,selectedTime:Q,setSelectedTime:H,treeState:we,setTreeState:xe,onSelected:xs,onHighlighted:ri,revealActionAttachment:Gr,revealConsole:()=>Et("console"),isLive:c,actionFilterText:k})]})},Zc={id:"metadata",title:"Metadata",component:w.jsx(f2,{model:i})},Wc=T==="actions"&&w.jsx(v2,{counters:i==null?void 0:i.actionCounters,hiddenActionsCount:qe});return w.jsxs("div",{className:"vbox workbench",...y?{inert:!0}:{},children:[!f&&w.jsx(o2,{model:i,consoleEntries:Hi.entries,networkResources:qi.resources,boundaries:Jt,highlightedAction:Ln,highlightedResourceKey:J,highlightedConsoleEntryOrdinal:P,onSelected:xs,sdkLanguage:Je,selectedTime:Q,setSelectedTime:H}),w.jsx(fc,{sidebarSize:250,orientation:N==="bottom"?"vertical":"horizontal",settingName:"propertiesSidebar",main:w.jsx(fc,{sidebarSize:250,orientation:"horizontal",sidebarIsFirst:!0,settingName:"actionListSidebar",main:w.jsx(ZN,{action:xt,model:i,sdkLanguage:Je,testIdAttributeName:(i==null?void 0:i.testIdAttributeName)||"data-testid",isInspecting:ce,setIsInspecting:Sl,highlightedElement:Z,setHighlightedElement:wl}),sidebar:w.jsx(Xh,{tabs:[Jc,Zc],rightToolbar:[Wc],selectedTab:T,setSelectedTab:x})}),sidebar:w.jsx(Xh,{tabs:it,selectedTab:E,setSelectedTab:Et,rightToolbar:[N==="bottom"?w.jsx(It,{title:"Dock to right",icon:"layout-sidebar-right-off",onClick:()=>{B("right")}}):w.jsx(It,{title:"Dock to bottom",icon:"layout-panel-off",onClick:()=>{B("bottom")}})],mode:N==="bottom"?"default":"select"})})]})},v2=({counters:n,hiddenActionsCount:e})=>{const[i,s]=fn("actionsFilter",[]),a=U.useRef(null),o=w.jsxs(w.Fragment,{children:[e>0&&w.jsxs("span",{className:"workbench-actions-hidden-count",title:e+" actions hidden by filters",children:[e," hidden"]}),w.jsx("span",{ref:a,className:"codicon codicon-filter"})]});return w.jsx(m2,{title:"Filter actions",dialogDataTestId:"actions-filter-dialog",buttonChildren:o,anchorRef:a,children:w.jsx(gw,{settings:[{type:"check",value:i.includes("getter"),set:c=>s(c?[...i,"getter"]:i.filter(f=>f!=="getter")),name:"Getters",count:n==null?void 0:n.get("getter")},{type:"check",value:i.includes("route"),set:c=>s(c?[...i,"route"]:i.filter(f=>f!=="route")),name:"Network routes",count:n==null?void 0:n.get("route")},{type:"check",value:i.includes("configuration"),set:c=>s(c?[...i,"configuration"]:i.filter(f=>f!=="configuration")),name:"Configuration",count:n==null?void 0:n.get("configuration")}]})})};function S2(n){if(!n)return"default";const e=new URL(n,"http://localhost");return e.searchParams.delete("timestamp"),e.toString()}var b0;(n=>{function e(i){for(const s of i.splice(0))s.dispose()}n.disposeAll=e})(b0||(b0={}));class gr{constructor(){this._listeners=new Set,this.event=(e,i)=>{this._listeners.add(e);let s=!1;const a=this,o={dispose(){s||(s=!0,a._listeners.delete(e))}};return i&&i.push(o),o}}fire(e){const i=!this._deliveryQueue;this._deliveryQueue||(this._deliveryQueue=[]);for(const s of this._listeners)this._deliveryQueue.push({listener:s,event:e});if(i){for(let s=0;s<this._deliveryQueue.length;s++){const{listener:a,event:o}=this._deliveryQueue[s];a.call(null,o)}this._deliveryQueue=void 0}}dispose(){this._listeners.clear(),this._deliveryQueue&&(this._deliveryQueue=[])}}class w2 extends Error{constructor(){super("Test server connection closed")}}class k2{constructor(e){this._ws=new WebSocket(e)}onmessage(e){this._ws.addEventListener("message",i=>e(i.data.toString()))}onopen(e){this._ws.addEventListener("open",e)}onerror(e){this._ws.addEventListener("error",e)}onclose(e){this._ws.addEventListener("close",e)}send(e){this._ws.send(e)}close(){this._ws.close()}}class M2{constructor(e){this._onCloseEmitter=new gr,this._onReportEmitter=new gr,this._onStdioEmitter=new gr,this._onTestFilesChangedEmitter=new gr,this._onLoadTraceRequestedEmitter=new gr,this._onTestPausedEmitter=new gr,this._lastId=0,this._callbacks=new Map,this._isClosed=!1,this.onClose=this._onCloseEmitter.event,this.onReport=this._onReportEmitter.event,this.onStdio=this._onStdioEmitter.event,this.onTestFilesChanged=this._onTestFilesChangedEmitter.event,this.onLoadTraceRequested=this._onLoadTraceRequestedEmitter.event,this.onTestPaused=this._onTestPausedEmitter.event,this._transport=e,this._transport.onmessage(s=>{const a=JSON.parse(s),{id:o,result:c,error:f,method:h,params:p}=a;if(o){const y=this._callbacks.get(o);if(!y)return;this._callbacks.delete(o),f?y.reject(new Error(f)):y.resolve(c)}else this._dispatchEvent(h,p)});const i=setInterval(()=>this._sendMessage("ping").catch(()=>{}),3e4);this._connectedPromise=new Promise((s,a)=>{this._transport.onopen(s),this._transport.onerror(a)}),this._transport.onclose(()=>{this._isClosed=!0,this._onCloseEmitter.fire(),clearInterval(i);for(const s of this._callbacks.values())s.reject(new w2);this._callbacks.clear()})}isClosed(){return this._isClosed}async _sendMessage(e,i){const s=globalThis.__logForTest;s==null||s({method:e,params:i}),await this._connectedPromise;const a=++this._lastId,o={id:a,method:e,params:i};return this._transport.send(JSON.stringify(o)),new Promise((c,f)=>{this._callbacks.set(a,{resolve:c,reject:f})})}_sendMessageNoReply(e,i){this._sendMessage(e,i).catch(()=>{})}_dispatchEvent(e,i){e==="report"?this._onReportEmitter.fire(i):e==="stdio"?this._onStdioEmitter.fire(i):e==="testFilesChanged"?this._onTestFilesChangedEmitter.fire(i):e==="loadTraceRequested"?this._onLoadTraceRequestedEmitter.fire(i):e==="testPaused"&&this._onTestPausedEmitter.fire(i)}async initialize(e){await this._sendMessage("initialize",e)}async ping(e){await this._sendMessage("ping",e)}async pingNoReply(e){this._sendMessageNoReply("ping",e)}async watch(e){await this._sendMessage("watch",e)}watchNoReply(e){this._sendMessageNoReply("watch",e)}async open(e){await this._sendMessage("open",e)}openNoReply(e){this._sendMessageNoReply("open",e)}async resizeTerminal(e){await this._sendMessage("resizeTerminal",e)}resizeTerminalNoReply(e){this._sendMessageNoReply("resizeTerminal",e)}async checkBrowsers(e){return await this._sendMessage("checkBrowsers",e)}async installBrowsers(e){await this._sendMessage("installBrowsers",e)}async runGlobalSetup(e){return await this._sendMessage("runGlobalSetup",e)}async runGlobalTeardown(e){return await this._sendMessage("runGlobalTeardown",e)}async startDevServer(e){return await this._sendMessage("startDevServer",e)}async stopDevServer(e){return await this._sendMessage("stopDevServer",e)}async clearCache(e){return await this._sendMessage("clearCache",e)}async listFiles(e){return await this._sendMessage("listFiles",e)}async listTests(e){return await this._sendMessage("listTests",e)}async runTests(e){return await this._sendMessage("runTests",e)}async findRelatedTestFiles(e){return await this._sendMessage("findRelatedTestFiles",e)}async stopTests(e){await this._sendMessage("stopTests",e)}stopTestsNoReply(e){this._sendMessageNoReply("stopTests",e)}async closeGracefully(e){await this._sendMessage("closeGracefully",e)}close(){try{this._transport.close()}catch{}}}const O2=({location:n})=>{const[e,i]=fn("shouldPopulateCanvasFromScreenshot",!1),[s,a]=qx(),[o,c]=fn("mergeFiles",!1);return w.jsx(gw,{settings:[{type:"select",value:s,set:a,name:"Theme",options:Ux},...n==="ui-mode"?[{type:"check",value:o,set:c,name:"Merge files"}]:[],{type:"check",value:e,set:i,name:"Display canvas content",title:"Attempt to display the captured canvas appearance in the snapshot preview. May not be accurate."}]})};export{m2 as D,rv as E,yt as R,fc as S,A2 as T,k2 as W,eT as _,M2 as a,O2 as b,N2 as c,p2 as d,x2 as e,_2 as f,Hx as g,E2 as h,T2 as i,w as j,Qe as k,zE as l,mt as m,xd as n,It as o,fn as p,gw as q,U as r,cs as s,nv as t,bs as u,kx as v};
|