From a56a2baf1f579cb1d364e7933b68b85faf47ceea Mon Sep 17 00:00:00 2001 From: Julian Sommer <115516918+juliansommer@users.noreply.github.com> Date: Tue, 7 Apr 2026 16:22:19 +1000 Subject: [PATCH 01/14] feat: privilege separation (#114) --- .github/workflows/e2e.yml | 19 ++- Makefile | 14 +- build/systemd/spinifex-awsgw.service | 24 +++- build/systemd/spinifex-daemon.service | 26 +++- build/systemd/spinifex-nats.service | 24 +++- build/systemd/spinifex-predastore.service | 24 +++- build/systemd/spinifex-ui.service | 24 +++- build/systemd/spinifex-viperblock.service | 24 +++- build/systemd/spinifex-vpcd.service | 24 +++- cmd/spinifex/cmd/admin.go | 33 ++--- cmd/spinifex/cmd/paths.go | 10 ++ cmd/spinifex/cmd/service.go | 6 + cmd/spinifex/cmd/templates/nats.conf | 2 +- scripts/dev-install.sh | 82 ++++++++++++ scripts/dev-setup.sh | 28 ++-- scripts/setup-ovn.sh | 18 +-- scripts/setup.sh | 133 ++++++++++++++----- scripts/start-dev.sh | 7 + spinifex/admin/admin.go | 94 ++++++++++++- spinifex/services/viperblockd/viperblockd.go | 8 ++ tests/e2e/run-multinode-e2e.sh | 47 +++---- 21 files changed, 540 insertions(+), 131 deletions(-) create mode 100755 scripts/dev-install.sh diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 4d0614639..c4937d5e7 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -180,9 +180,13 @@ jobs: sparse-checkout: scripts/tofu-cluster path: mulga - - name: Clone and build + - name: Build Install Artifacts working-directory: mulga/scripts/tofu-cluster - run: ./build-artifacts.sh "${GIT_BRANCH}" "${RUNNER_TEMP}/spinifex-artifacts.tar" + run: | + ./build-install-artifacts.sh "${GIT_BRANCH}" \ + "${RUNNER_TEMP}/spinifex-distro.tar.gz" \ + "${RUNNER_TEMP}/setup.sh" \ + "${RUNNER_TEMP}/spinifex-tests.tar" - name: Provision VMs working-directory: mulga/scripts/tofu-cluster @@ -194,13 +198,14 @@ jobs: ./scrub-env.sh env2 >> "$TOFU_LOG" 2>&1 || true tofu apply -var-file=envs/env2.tfvars -auto-approve -input=false >> "$TOFU_LOG" 2>&1 - - name: Bootstrap Cluster + - name: Bootstrap via Binary Install working-directory: mulga/scripts/tofu-cluster run: | - SPX_PREBUILT=true \ - SPX_ARTIFACT_TAR="${RUNNER_TEMP}/spinifex-artifacts.tar" \ SPX_EXTERNAL_POOL="192.168.1.240-192.168.1.250" \ - ./bootstrap.sh env2 >> "$TOFU_LOG" 2>&1 + ./bootstrap-install.sh env2 \ + "${RUNNER_TEMP}/setup.sh" \ + "${RUNNER_TEMP}/spinifex-distro.tar.gz" \ + --test-tar "${RUNNER_TEMP}/spinifex-tests.tar" - name: Run E2E Tests working-directory: mulga/scripts/tofu-cluster @@ -218,7 +223,7 @@ jobs: done ssh -o StrictHostKeyChecking=no -i "$SSH_KEY" tf-user@${NODE1_IP} \ - "cd ~/Development/mulga/spinifex && ./tests/e2e/run-multinode-e2e.sh ${NODE_IPS} && ./tests/e2e/run-cert-e2e.sh --multinode ${NODE_IPS}" + "cd ~/e2e-tests && ./run-multinode-e2e.sh ${NODE_IPS} && ./run-cert-e2e.sh --multinode ${NODE_IPS}" - name: Teardown if: always() diff --git a/Makefile b/Makefile index 425da1917..66b16f37c 100644 --- a/Makefile +++ b/Makefile @@ -116,6 +116,17 @@ run: $(MAKE) go_build $(MAKE) go_run +# Fast iteration: build + install binary + restart all services +deploy: build + sudo install -m 755 bin/spx /usr/local/bin/spx + sudo systemctl daemon-reload + sudo systemctl restart spinifex.target + +# Re-run setup.sh after changing systemd units, helper scripts, or logrotate config. +# Not needed for code-only changes — use deploy for those. +reinstall: + scripts/dev-install.sh + clean: rm -f ./bin/$(GO_PROJECT_NAME) rm -rf spinifex/services/spinifexui/frontend/dist @@ -207,7 +218,8 @@ distro-arm64: distro-clean: rm -rf dist/ -.PHONY: build build-ui build-alb-agent build-system-image build-alb-image go_build go_run preflight test test-cover test-race diff-coverage bench run clean \ +.PHONY: build build-ui build-alb-agent build-system-image build-alb-image go_build go_run preflight test test-cover test-race diff-coverage bench run \ + deploy reinstall clean \ install-system install-go install-aws quickinstall \ lint fix govulncheck \ distro distro-amd64 distro-arm64 distro-clean diff --git a/build/systemd/spinifex-awsgw.service b/build/systemd/spinifex-awsgw.service index 1626cebdd..42f6df37b 100644 --- a/build/systemd/spinifex-awsgw.service +++ b/build/systemd/spinifex-awsgw.service @@ -6,7 +6,7 @@ Wants=spinifex-nats.service [Service] Type=simple -User=spinifex +User=spinifex-gw Group=spinifex ExecStartPre=/var/lib/spinifex/wait-for-nats.sh ExecStart=/usr/local/bin/spx service awsgw start @@ -18,5 +18,27 @@ Environment=SPINIFEX_BASE_DIR=/var/lib/spinifex/ Environment=SPINIFEX_AWSGW_TLS_CERT=/etc/spinifex/server.pem Environment=SPINIFEX_AWSGW_TLS_KEY=/etc/spinifex/server.key +# Filesystem access +NoNewPrivileges=yes +ProtectSystem=strict +PrivateDevices=yes +ReadOnlyPaths=/etc/spinifex/spinifex.toml /etc/spinifex/master.key /etc/spinifex/server.pem /etc/spinifex/server.key +ReadWritePaths=/var/lib/spinifex /var/log/spinifex /etc/spinifex/bootstrap.json /tmp + +# Hardening +ProtectHome=yes +PrivateTmp=no +RestrictSUIDSGID=yes +LockPersonality=yes +RestrictRealtime=yes +RestrictNamespaces=yes +ProtectClock=yes +ProtectKernelTunables=yes +ProtectKernelModules=yes +ProtectKernelLogs=yes +ProtectControlGroups=yes +ProtectProc=invisible +SystemCallArchitectures=native + [Install] WantedBy=spinifex.target diff --git a/build/systemd/spinifex-daemon.service b/build/systemd/spinifex-daemon.service index 0722bd50d..1bc5b9f9f 100644 --- a/build/systemd/spinifex-daemon.service +++ b/build/systemd/spinifex-daemon.service @@ -6,7 +6,7 @@ Wants=spinifex-nats.service [Service] Type=simple -User=spinifex +User=spinifex-daemon Group=spinifex ExecStartPre=/var/lib/spinifex/wait-for-nats.sh ExecStart=/usr/local/bin/spx service spinifex start @@ -17,5 +17,29 @@ Environment=SPINIFEX_CONFIG_PATH=/etc/spinifex/spinifex.toml Environment=SPINIFEX_BASE_DIR=/var/lib/spinifex/spinifex/ Environment=SPINIFEX_WAL_DIR=/var/lib/spinifex/spinifex/ +# Filesystem access — NoNewPrivileges omitted (daemon uses sudo for ip, ovs-vsctl, dhcpcd) +ProtectSystem=full +PrivateDevices=no +DevicePolicy=closed +DeviceAllow=/dev/kvm rw +DeviceAllow=/dev/net/tun rw +ReadOnlyPaths=/etc/spinifex/spinifex.toml /etc/spinifex/server.pem /etc/spinifex/server.key +ReadWritePaths=/var/lib/spinifex/spinifex /var/log/spinifex /run/spinifex + +# Hardening +ProtectHome=yes +PrivateTmp=no +RestrictSUIDSGID=yes +LockPersonality=yes +RestrictRealtime=yes +RestrictNamespaces=yes +ProtectClock=yes +ProtectKernelTunables=yes +ProtectKernelModules=yes +ProtectKernelLogs=yes +ProtectControlGroups=yes +ProtectProc=invisible +SystemCallArchitectures=native + [Install] WantedBy=spinifex.target diff --git a/build/systemd/spinifex-nats.service b/build/systemd/spinifex-nats.service index 42797b81d..eaf0e89b7 100644 --- a/build/systemd/spinifex-nats.service +++ b/build/systemd/spinifex-nats.service @@ -5,7 +5,7 @@ Before=spinifex-predastore.service spinifex-daemon.service spinifex-awsgw.servic [Service] Type=simple -User=spinifex +User=spinifex-nats Group=spinifex ExecStart=/usr/local/bin/spx service nats start Restart=on-failure @@ -13,5 +13,27 @@ RestartSec=5 OOMScoreAdjust=-500 Environment=SPINIFEX_CONFIG_PATH=/etc/spinifex/nats/nats.conf +# Filesystem access +NoNewPrivileges=yes +ProtectSystem=strict +PrivateDevices=yes +ReadOnlyPaths=/etc/spinifex/nats +ReadWritePaths=/var/lib/spinifex/nats /var/log/spinifex /tmp + +# Hardening +ProtectHome=yes +PrivateTmp=no +RestrictSUIDSGID=yes +LockPersonality=yes +RestrictRealtime=yes +RestrictNamespaces=yes +ProtectClock=yes +ProtectKernelTunables=yes +ProtectKernelModules=yes +ProtectKernelLogs=yes +ProtectControlGroups=yes +ProtectProc=invisible +SystemCallArchitectures=native + [Install] WantedBy=spinifex.target diff --git a/build/systemd/spinifex-predastore.service b/build/systemd/spinifex-predastore.service index 712fab8cf..40407a227 100644 --- a/build/systemd/spinifex-predastore.service +++ b/build/systemd/spinifex-predastore.service @@ -6,7 +6,7 @@ Wants=spinifex-nats.service [Service] Type=simple -User=spinifex +User=spinifex-storage Group=spinifex ExecStartPre=/var/lib/spinifex/wait-for-nats.sh ExecStart=/var/lib/spinifex/predastore-start.sh @@ -18,5 +18,27 @@ Environment=SPINIFEX_PREDASTORE_BASE_PATH=/var/lib/spinifex/predastore/ Environment=SPINIFEX_PREDASTORE_TLS_CERT=/etc/spinifex/server.pem Environment=SPINIFEX_PREDASTORE_TLS_KEY=/etc/spinifex/server.key +# Filesystem access +NoNewPrivileges=yes +ProtectSystem=strict +PrivateDevices=yes +ReadOnlyPaths=/etc/spinifex/predastore /etc/spinifex/spinifex.toml /etc/spinifex/master.key /etc/spinifex/server.pem /etc/spinifex/server.key +ReadWritePaths=/var/lib/spinifex/predastore /var/log/spinifex /tmp + +# Hardening +ProtectHome=yes +PrivateTmp=no +RestrictSUIDSGID=yes +LockPersonality=yes +RestrictRealtime=yes +RestrictNamespaces=yes +ProtectClock=yes +ProtectKernelTunables=yes +ProtectKernelModules=yes +ProtectKernelLogs=yes +ProtectControlGroups=yes +ProtectProc=invisible +SystemCallArchitectures=native + [Install] WantedBy=spinifex.target diff --git a/build/systemd/spinifex-ui.service b/build/systemd/spinifex-ui.service index 5354fc1c0..e2a6f762f 100644 --- a/build/systemd/spinifex-ui.service +++ b/build/systemd/spinifex-ui.service @@ -5,7 +5,7 @@ After=spinifex-awsgw.service [Service] Type=simple -User=spinifex +User=spinifex-ui Group=spinifex ExecStart=/usr/local/bin/spx service spinifex-ui start Restart=on-failure @@ -14,5 +14,27 @@ OOMScoreAdjust=-500 Environment=SPINIFEX_UI_TLS_CERT=/etc/spinifex/server.pem Environment=SPINIFEX_UI_TLS_KEY=/etc/spinifex/server.key +# Filesystem access +NoNewPrivileges=yes +ProtectSystem=strict +PrivateDevices=yes +ReadOnlyPaths=/etc/spinifex/server.pem /etc/spinifex/server.key +ReadWritePaths=/var/log/spinifex /tmp + +# Hardening +ProtectHome=yes +PrivateTmp=no +RestrictSUIDSGID=yes +LockPersonality=yes +RestrictRealtime=yes +RestrictNamespaces=yes +ProtectClock=yes +ProtectKernelTunables=yes +ProtectKernelModules=yes +ProtectKernelLogs=yes +ProtectControlGroups=yes +ProtectProc=invisible +SystemCallArchitectures=native + [Install] WantedBy=spinifex.target diff --git a/build/systemd/spinifex-viperblock.service b/build/systemd/spinifex-viperblock.service index 9592ddda2..1e17ac3c6 100644 --- a/build/systemd/spinifex-viperblock.service +++ b/build/systemd/spinifex-viperblock.service @@ -6,7 +6,7 @@ Wants=spinifex-nats.service [Service] Type=simple -User=spinifex +User=spinifex-viperblock Group=spinifex ExecStartPre=/var/lib/spinifex/wait-for-nats.sh ExecStart=/usr/local/bin/spx service viperblock start @@ -17,5 +17,27 @@ EnvironmentFile=/etc/spinifex/systemd.env Environment=SPINIFEX_CONFIG_PATH=/etc/spinifex/spinifex.toml Environment=SPINIFEX_BASE_DIR=/var/lib/spinifex/viperblock/ +# Filesystem access +NoNewPrivileges=yes +ProtectSystem=strict +PrivateDevices=yes +ReadOnlyPaths=/etc/spinifex/spinifex.toml /etc/spinifex/systemd.env +ReadWritePaths=/var/lib/spinifex/viperblock /var/log/spinifex /tmp + +# Hardening +ProtectHome=yes +PrivateTmp=no +RestrictSUIDSGID=yes +LockPersonality=yes +RestrictRealtime=yes +RestrictNamespaces=yes +ProtectClock=yes +ProtectKernelTunables=yes +ProtectKernelModules=yes +ProtectKernelLogs=yes +ProtectControlGroups=yes +ProtectProc=invisible +SystemCallArchitectures=native + [Install] WantedBy=spinifex.target diff --git a/build/systemd/spinifex-vpcd.service b/build/systemd/spinifex-vpcd.service index df643cf77..3fea74e97 100644 --- a/build/systemd/spinifex-vpcd.service +++ b/build/systemd/spinifex-vpcd.service @@ -6,7 +6,7 @@ Wants=spinifex-nats.service [Service] Type=simple -User=spinifex +User=spinifex-vpcd Group=spinifex ExecStartPre=/var/lib/spinifex/wait-for-nats.sh ExecStart=/usr/local/bin/spx service vpcd start @@ -14,6 +14,28 @@ Restart=on-failure RestartSec=5 OOMScoreAdjust=-500 Environment=SPINIFEX_CONFIG_PATH=/etc/spinifex/spinifex.toml +Environment=SPINIFEX_BASE_DIR=/var/lib/spinifex/vpcd/ + +# Filesystem access — NoNewPrivileges omitted (vpcd uses sudo for ovs-vsctl, ovn-nbctl, systemctl) +ProtectSystem=full +PrivateDevices=yes +ReadOnlyPaths=/etc/spinifex/spinifex.toml +ReadWritePaths=/var/lib/spinifex/vpcd /var/log/spinifex + +# Hardening +ProtectHome=yes +PrivateTmp=no +RestrictSUIDSGID=yes +LockPersonality=yes +RestrictRealtime=yes +RestrictNamespaces=yes +ProtectClock=yes +ProtectKernelTunables=yes +ProtectKernelModules=yes +ProtectKernelLogs=yes +ProtectControlGroups=yes +ProtectProc=invisible +SystemCallArchitectures=native [Install] WantedBy=spinifex.target diff --git a/cmd/spinifex/cmd/admin.go b/cmd/spinifex/cmd/admin.go index 3491aa349..a18ba253e 100644 --- a/cmd/spinifex/cmd/admin.go +++ b/cmd/spinifex/cmd/admin.go @@ -933,6 +933,7 @@ func runAdminInit(cmd *cobra.Command, args []string) { Region: region, NatsToken: natsToken, DataDir: spxRoot, + LogDir: LogDirFor(spxRoot), ConfigDir: configDir, Node: node, @@ -1014,14 +1015,10 @@ func runAdminInit(cmd *cobra.Command, args []string) { admin.CreateServiceDirectories(spxRoot) - // In production layout (running as root), fix ownership so the service user - // can read config and write data. SUDO_USER identifies the operator account. + // In production layout (running as root), set per-service ownership on + // directories and shared config files (root:spinifex with correct modes). if os.Getuid() == 0 { - sudoUser := os.Getenv("SUDO_USER") - if sudoUser != "" { - admin.ChownRecursive(configDir, sudoUser) - admin.ChownRecursive(spxRoot, sudoUser) - } + admin.SetServiceOwnership() } // Print success message @@ -1171,6 +1168,7 @@ func runAdminInitMultiNode(cmd *cobra.Command, accessKey, secretKey, accountID, Region: region, NatsToken: natsToken, DataDir: spxRoot, + LogDir: LogDirFor(spxRoot), ConfigDir: configDir, Node: node, @@ -1246,14 +1244,10 @@ func runAdminInitMultiNode(cmd *cobra.Command, accessKey, secretKey, accountID, admin.CreateServiceDirectories(spxRoot) - // In production layout (running as root), fix ownership so the service user - // can read config and write data. SUDO_USER identifies the operator account. + // In production layout (running as root), set per-service ownership on + // directories and shared config files (root:spinifex with correct modes). if os.Getuid() == 0 { - sudoUser := os.Getenv("SUDO_USER") - if sudoUser != "" { - admin.ChownRecursive(configDir, sudoUser) - admin.ChownRecursive(spxRoot, sudoUser) - } + admin.SetServiceOwnership() } // Keep formation server running briefly so joining nodes can fetch complete status @@ -1569,6 +1563,7 @@ func runAdminJoin(cmd *cobra.Command, args []string) { Region: creds.Region, NatsToken: creds.NatsToken, DataDir: dataDir, + LogDir: LogDirFor(dataDir), ConfigDir: configDir, Node: node, @@ -1648,14 +1643,10 @@ func runAdminJoin(cmd *cobra.Command, args []string) { admin.CreateServiceDirectories(dataDir) - // In production layout (running as root), fix ownership so the service user - // can read config and write data. SUDO_USER identifies the operator account. + // In production layout (running as root), set per-service ownership on + // directories and shared config files (root:spinifex with correct modes). if os.Getuid() == 0 { - sudoUser := os.Getenv("SUDO_USER") - if sudoUser != "" { - admin.ChownRecursive(configDir, sudoUser) - admin.ChownRecursive(dataDir, sudoUser) - } + admin.SetServiceOwnership() } // Print cluster summary diff --git a/cmd/spinifex/cmd/paths.go b/cmd/spinifex/cmd/paths.go index 54d5e0b86..51c201613 100644 --- a/cmd/spinifex/cmd/paths.go +++ b/cmd/spinifex/cmd/paths.go @@ -26,6 +26,16 @@ func DefaultDataDir() string { return filepath.Join(realUserHomeDir(), "spinifex") } +// LogDirFor returns the log directory for a given data directory. +// Production: /var/log/spinifex (matches systemd ReadWritePaths) +// Development: /logs (supports custom per-node data dirs) +func LogDirFor(dataDir string) string { + if isProductionLayout() { + return "/var/log/spinifex" + } + return filepath.Join(dataDir, "logs") +} + // realUserHomeDir returns the home directory of the real (non-sudo) user. // When running under sudo, SUDO_USER is set to the invoking user — resolve // their home directory so config/data land in the right place. diff --git a/cmd/spinifex/cmd/service.go b/cmd/spinifex/cmd/service.go index 14fa282df..26d8a5d34 100644 --- a/cmd/spinifex/cmd/service.go +++ b/cmd/spinifex/cmd/service.go @@ -733,6 +733,12 @@ var vpcdStartCmd = &cobra.Command{ } } + baseDir := viper.GetString("base-dir") + if baseDir != "" { + fmt.Println("Overwriting vpcd base-dir to:", baseDir) + nodeConfig.BaseDir = baseDir + } + svc, err := service.New("vpcd", &vpcd.Config{ NatsHost: nodeConfig.NATS.Host, NatsToken: nodeConfig.NATS.ACL.Token, diff --git a/cmd/spinifex/cmd/templates/nats.conf b/cmd/spinifex/cmd/templates/nats.conf index be94dfeaa..82216c6f8 100644 --- a/cmd/spinifex/cmd/templates/nats.conf +++ b/cmd/spinifex/cmd/templates/nats.conf @@ -40,7 +40,7 @@ jetstream { debug: false trace: false logtime: true -log_file: "{{.DataDir}}/logs/nats.log" +log_file: "{{.LogDir}}/nats.log" # Limits max_connections: 1000 diff --git a/scripts/dev-install.sh b/scripts/dev-install.sh new file mode 100755 index 000000000..f8d3dc746 --- /dev/null +++ b/scripts/dev-install.sh @@ -0,0 +1,82 @@ +#!/bin/bash +# dev-install.sh — Full local development setup via production installer. +# Builds from source, assembles a tarball, runs setup.sh for scaffolding +# (user creation, directories, systemd units), initializes the cluster, +# and starts services via systemd. +# +# Usage: ./scripts/dev-install.sh +set -euo pipefail + +SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)" +PROJECT_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)" +MULGA_ROOT="$(cd "$PROJECT_ROOT/.." && pwd)" + +echo "=== Building ===" +cd "$PROJECT_ROOT" && make build +cd "$MULGA_ROOT/viperblock" && make go_build_nbd + +echo "=== Assembling tarball for setup.sh ===" +STAGING=$(mktemp -d) +trap 'rm -rf "$STAGING"' EXIT +cp "$PROJECT_ROOT/bin/spx" "$STAGING/spx" +cp "$MULGA_ROOT/viperblock/lib/nbdkit-viperblock-plugin.so" "$STAGING/" +cp "$PROJECT_ROOT/scripts/setup-ovn.sh" "$STAGING/" +mkdir -p "$STAGING/systemd" +cp "$PROJECT_ROOT/build/systemd/"* "$STAGING/systemd/" +mkdir -p "$STAGING/scripts" +cp "$PROJECT_ROOT/build/scripts/"* "$STAGING/scripts/" +cp "$PROJECT_ROOT/build/logrotate/spinifex" "$STAGING/logrotate-spinifex" +tar czf /tmp/spinifex-local.tar.gz -C "$STAGING" . + +echo "=== Cleaning stale state from previous installs ===" +# Stop any running services before modifying files +sudo systemctl stop spinifex.target 2>/dev/null || true +sudo systemctl reset-failed 2>/dev/null || true + +# Remove stale files owned by the dev user in production paths. +# Previous dev-mode installs (admin init without sudo, start-dev.sh) leave +# files owned by tf-user that service users (spinifex-nats, etc.) can't read +# under systemd's ProtectSystem=strict sandboxing. +for dir in /var/lib/spinifex /var/log/spinifex /etc/spinifex; do + if [ -d "$dir" ]; then + # Remove PID files, stale logs, and the legacy ~/spinifex/config symlink + sudo find "$dir" -name '*.pid' -delete 2>/dev/null || true + sudo find "$dir" -name '*.log' -delete 2>/dev/null || true + sudo find "$dir" -name '*.log.*' -delete 2>/dev/null || true + fi +done +# Remove legacy data dir contents that conflict with production layout +if [ -d /var/lib/spinifex/config ]; then + sudo rm -rf /var/lib/spinifex/config +fi + +echo "=== Running setup.sh (creates users, dirs, systemd units) ===" +sudo INSTALL_SPINIFEX_TARBALL=/tmp/spinifex-local.tar.gz bash "$PROJECT_ROOT/scripts/setup.sh" +rm -f /tmp/spinifex-local.tar.gz + +echo "=== Setting up OVN ===" +sudo /usr/local/share/spinifex/setup-ovn.sh --management + +echo "=== Initializing ===" +sudo spx admin init --force --region ap-southeast-2 --az ap-southeast-2a --node node1 --nodes 1 + +echo "=== Installing CA certificate ===" +sudo cp /etc/spinifex/ca.pem /usr/local/share/ca-certificates/spinifex-ca.crt +sudo update-ca-certificates + +echo "=== Starting services ===" +sudo systemctl start spinifex.target + +echo "=== Done ===" +echo "Services: sudo systemctl status spinifex.target" +echo "Logs: journalctl -u 'spinifex-*' -f" +echo "Test: AWS_PROFILE=spinifex aws ec2 describe-instances" +echo "Iterate: make deploy (rebuild + restart all)" + +# Check if user needs to re-login for spinifex group membership +if ! id -Gn 2>/dev/null | grep -qw spinifex; then + echo "" + echo "NOTE: You were added to the 'spinifex' group but your current" + echo "session doesn't reflect it yet. Log out and back in, or run:" + echo " newgrp spinifex" +fi diff --git a/scripts/dev-setup.sh b/scripts/dev-setup.sh index 4009ceab7..3412a2984 100755 --- a/scripts/dev-setup.sh +++ b/scripts/dev-setup.sh @@ -165,24 +165,16 @@ else fi echo "" -echo "🎉 Development environment setup complete!" +echo "Development environment setup complete!" echo "" -echo "📋 Next steps:" +echo "Recommended: Use scripts/dev-install.sh for a production-parity setup" +echo " (systemd, privilege separation, production paths)." echo "" -echo " 1. Setup OVN networking:" -echo " ./scripts/setup-ovn.sh --management" +echo " scripts/dev-install.sh # One-time: build, install, init, start via systemd" +echo " make deploy # Daily: rebuild + copy binary + restart all" +echo " make reinstall # Changed a .service file? Re-run full setup" echo "" -echo " 2. Initialize Spinifex (creates ~/spinifex/ directories, config, certs, and installs CA):" -echo " sudo ./bin/spx admin init --region ap-southeast-2 --az ap-southeast-2a --node node1 --nodes 1" -echo "" -echo " 3. Start services:" -echo " ./scripts/start-dev.sh" -echo "" -echo "🔧 Development endpoints:" -echo " - Spinifex Gateway: https://localhost:$SPINIFEX_GATEWAY_PORT" -echo " - Predastore S3: https://localhost:$PREDASTORE_PORT" -echo " - NATS: nats://localhost:$NATS_PORT" -echo "" -echo "🧪 Test with AWS CLI:" -echo " export AWS_PROFILE=spinifex" -echo " aws ec2 describe-instances" +echo "Legacy workflow (deprecated, retained for pseudo-multinode CI only):" +echo " ./scripts/setup-ovn.sh --management" +echo " sudo ./bin/spx admin init --region ap-southeast-2 --az ap-southeast-2a --node node1 --nodes 1" +echo " ./scripts/start-dev.sh" diff --git a/scripts/setup-ovn.sh b/scripts/setup-ovn.sh index 006f5bb5b..3f25e0079 100755 --- a/scripts/setup-ovn.sh +++ b/scripts/setup-ovn.sh @@ -565,21 +565,13 @@ else echo " systemd override: already exists" fi -# Create sudoers rule for network commands that always need root -# (ip tuntap, ip link set — NET_ADMIN operations) +# Sudoers rules for spinifex-daemon and spinifex-vpcd are managed by setup.sh +# (install_sudoers). Skip writing here to avoid conflicts. SUDOERS_FILE="/etc/sudoers.d/spinifex-network" -if [ ! -f "$SUDOERS_FILE" ]; then - CURRENT_USER=$(whoami) - sudo tee "$SUDOERS_FILE" >/dev/null < /dev/null 2>&1; then + $SUDO groupadd --system "$SPINIFEX_GROUP" fi - info "Services will run as: $SPINIFEX_USER:$SPINIFEX_GROUP" + # Create per-service users with correct home directories + declare -A SERVICE_HOMES=( + [nats]="/var/lib/spinifex/nats" + [gw]="/var/lib/spinifex" + [daemon]="/var/lib/spinifex/spinifex" + [storage]="/var/lib/spinifex/predastore" + [viperblock]="/var/lib/spinifex/viperblock" + [vpcd]="/var/lib/spinifex" + [ui]="/var/lib/spinifex" + ) + for svc in nats gw daemon storage viperblock vpcd ui; do + local user="spinifex-${svc}" + if ! id "$user" > /dev/null 2>&1; then + $SUDO useradd --system --no-create-home \ + --home-dir "${SERVICE_HOMES[$svc]}" \ + --gid "$SPINIFEX_GROUP" \ + --shell /usr/sbin/nologin \ + "$user" + fi + done - # Allow the service user to manage OVN/OVS and tap devices - $SUDO tee /etc/sudoers.d/spinifex-network > /dev/null << SUDOERS -# Spinifex VPC networking: allow service user to manage tap devices, OVS, and OVN -${SPINIFEX_USER} ALL=(root) NOPASSWD: /sbin/ip, /usr/sbin/ip -${SPINIFEX_USER} ALL=(root) NOPASSWD: /usr/bin/ovs-vsctl, /usr/bin/ovs-appctl -${SPINIFEX_USER} ALL=(root) NOPASSWD: /usr/bin/ovn-nbctl, /usr/bin/ovn-sbctl + # Add invoking user to spinifex group for admin CLI access + ADMIN_USER="${SUDO_USER:-$(whoami)}" + if [ "$ADMIN_USER" != "root" ]; then + $SUDO usermod -aG "$SPINIFEX_GROUP" "$ADMIN_USER" + fi + + # KVM access for daemon + if getent group kvm > /dev/null 2>&1; then + $SUDO usermod -aG kvm spinifex-daemon + fi + + info "Service users created (spinifex-{nats,gw,daemon,storage,viperblock,vpcd,ui})" +} + +# --- Install scoped sudoers rules --- +install_sudoers() { + $SUDO tee /etc/sudoers.d/spinifex-network > /dev/null << 'SUDOERS' +# Spinifex daemon: tap devices, OVS bridge management, and DHCP for external IPs +spinifex-daemon ALL=(root) NOPASSWD: /sbin/ip, /usr/sbin/ip +spinifex-daemon ALL=(root) NOPASSWD: /usr/bin/ovs-vsctl, /usr/bin/ovs-appctl +spinifex-daemon ALL=(root) NOPASSWD: /usr/sbin/dhcpcd + +# Spinifex VPC daemon: OVN and OVS read/write, OVN controller status check +spinifex-vpcd ALL=(root) NOPASSWD: /usr/bin/ovs-vsctl, /usr/bin/ovs-appctl +spinifex-vpcd ALL=(root) NOPASSWD: /usr/bin/ovn-nbctl, /usr/bin/ovn-sbctl +spinifex-vpcd ALL=(root) NOPASSWD: /usr/bin/systemctl is-active --quiet ovn-controller SUDOERS $SUDO chmod 0440 /etc/sudoers.d/spinifex-network - info "Sudoers rules installed for $SPINIFEX_USER" + $SUDO visudo -cf /etc/sudoers.d/spinifex-network || fatal "Invalid sudoers syntax in spinifex-network" + info "Scoped sudoers rules installed for spinifex-daemon and spinifex-vpcd" } # --- Install apt dependencies --- @@ -241,12 +280,15 @@ install_files() { create_directories() { info "Creating directories..." + # Top-level directories (root-owned, group-readable by spinifex) $SUDO mkdir -p /etc/spinifex - $SUDO chmod 0700 /etc/spinifex - $SUDO chown "$SPINIFEX_USER:$SPINIFEX_GROUP" /etc/spinifex + $SUDO chmod 0750 /etc/spinifex + $SUDO chown "root:$SPINIFEX_GROUP" /etc/spinifex $SUDO mkdir -p /var/lib/spinifex - $SUDO chown "$SPINIFEX_USER:$SPINIFEX_GROUP" /var/lib/spinifex + # TODO: tighten to 0750 once awsgw gets its own data dir (currently writes awsgw.pid here) + $SUDO chmod 0770 /var/lib/spinifex + $SUDO chown "root:$SPINIFEX_GROUP" /var/lib/spinifex # Symlink so services that expect BaseDir/config/ can find /etc/spinifex/ if [ ! -e /var/lib/spinifex/config ]; then @@ -259,26 +301,57 @@ create_directories() { fi $SUDO mkdir -p /var/log/spinifex - $SUDO chown "$SPINIFEX_USER:$SPINIFEX_GROUP" /var/log/spinifex + $SUDO chmod 0775 /var/log/spinifex + $SUDO chown "root:$SPINIFEX_GROUP" /var/log/spinifex $SUDO mkdir -p /run/spinifex - $SUDO chown "$SPINIFEX_USER:$SPINIFEX_GROUP" /run/spinifex + $SUDO chmod 0775 /run/spinifex + $SUDO chown "root:$SPINIFEX_GROUP" /run/spinifex + + # Per-service config directories + $SUDO mkdir -p /etc/spinifex/nats + $SUDO chown "spinifex-nats:$SPINIFEX_GROUP" /etc/spinifex/nats + $SUDO chmod 0750 /etc/spinifex/nats + + $SUDO mkdir -p /etc/spinifex/predastore + $SUDO chown "spinifex-storage:$SPINIFEX_GROUP" /etc/spinifex/predastore + $SUDO chmod 0750 /etc/spinifex/predastore + + # Per-service data directories + $SUDO mkdir -p /var/lib/spinifex/nats + $SUDO chown "spinifex-nats:$SPINIFEX_GROUP" /var/lib/spinifex/nats + $SUDO chmod 0700 /var/lib/spinifex/nats + + $SUDO mkdir -p /var/lib/spinifex/spinifex + $SUDO chown "spinifex-daemon:$SPINIFEX_GROUP" /var/lib/spinifex/spinifex + $SUDO chmod 0700 /var/lib/spinifex/spinifex + + $SUDO mkdir -p /var/lib/spinifex/predastore + $SUDO chown "spinifex-storage:$SPINIFEX_GROUP" /var/lib/spinifex/predastore + $SUDO chmod 0700 /var/lib/spinifex/predastore $SUDO mkdir -p /var/lib/spinifex/viperblock - $SUDO chown "$SPINIFEX_USER:$SPINIFEX_GROUP" /var/lib/spinifex/viperblock + $SUDO chown "spinifex-viperblock:$SPINIFEX_GROUP" /var/lib/spinifex/viperblock + $SUDO chmod 0700 /var/lib/spinifex/viperblock + $SUDO mkdir -p /var/lib/spinifex/vpcd + $SUDO chown "spinifex-vpcd:$SPINIFEX_GROUP" /var/lib/spinifex/vpcd + $SUDO chmod 0700 /var/lib/spinifex/vpcd + + # Top-level config files (root-owned, group-readable) # Generate environment file with install-specific values (e.g. arch-dependent paths) $SUDO tee /etc/spinifex/systemd.env > /dev/null << EOF # Generated by setup.sh — install-specific environment variables SPINIFEX_VIPERBLOCK_PLUGIN_PATH=${PLUGINDIR}/nbdkit-viperblock-plugin.so EOF - $SUDO chown "$SPINIFEX_USER:$SPINIFEX_GROUP" /etc/spinifex/systemd.env + $SUDO chown "spinifex-viperblock:$SPINIFEX_GROUP" /etc/spinifex/systemd.env + $SUDO chmod 0640 /etc/spinifex/systemd.env info "Generated /etc/spinifex/systemd.env" - # Service helper scripts + # Service helper scripts (root-owned, group-executable by all service users) if [ -d "$EXTRACT_DIR/scripts" ]; then for script in "$EXTRACT_DIR"/scripts/*.sh; do - $SUDO install -o "$SPINIFEX_USER" -g "$SPINIFEX_GROUP" -m 0755 \ + $SUDO install -o root -g "$SPINIFEX_GROUP" -m 0755 \ "$script" "/var/lib/spinifex/$(basename "$script")" info " /var/lib/spinifex/$(basename "$script")" done @@ -294,15 +367,12 @@ install_systemd() { fi for unit in "$EXTRACT_DIR"/systemd/*; do - # Substitute User= and Group= with the detected service user - sed "s/^User=spinifex$/User=$SPINIFEX_USER/;s/^Group=spinifex$/Group=$SPINIFEX_GROUP/" \ - "$unit" | $SUDO tee "/etc/systemd/system/$(basename "$unit")" > /dev/null - $SUDO chmod 0644 "/etc/systemd/system/$(basename "$unit")" + $SUDO install -m 0644 "$unit" "/etc/systemd/system/$(basename "$unit")" info " /etc/systemd/system/$(basename "$unit")" done $SUDO systemctl daemon-reload - info "Systemd units installed (running as $SPINIFEX_USER:$SPINIFEX_GROUP)" + info "Systemd units installed (per-service users)" } # --- Install logrotate --- @@ -343,7 +413,7 @@ print_summary() { echo "" echo " Version: $INSTALLED_VERSION" echo " Architecture: $ARCH" - echo " Service user: $SPINIFEX_USER" + echo " Service users: spinifex-{nats,gw,daemon,storage,viperblock,vpcd,ui}" echo " Binary: /usr/local/bin/spx" echo " Config: /etc/spinifex/" echo " Data: /var/lib/spinifex/" @@ -384,7 +454,8 @@ main() { handle_upgrade install_apt_deps install_aws_cli - detect_service_user + create_service_users + install_sudoers download_spinifex install_files create_directories diff --git a/scripts/start-dev.sh b/scripts/start-dev.sh index b8da4a7f9..46a75b9d8 100755 --- a/scripts/start-dev.sh +++ b/scripts/start-dev.sh @@ -11,6 +11,11 @@ set -euo pipefail +echo "WARNING: start-dev.sh is deprecated for local development." >&2 +echo " Use 'make deploy' for daily iteration or 'scripts/dev-install.sh' for first-time setup." >&2 +echo " start-dev.sh is retained only for pseudo-multinode CI (e2e_pseudo_multi)." >&2 +echo "" >&2 + SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" PROJECT_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)" MULGA_ROOT="$(cd "$PROJECT_ROOT/.." && pwd)" @@ -33,6 +38,8 @@ echo "Using configuration directory: $CONFIG_DIR" LOGS_DIR="$DATA_DIR/logs" WAL_DIR="$DATA_DIR/spinifex" +echo "⚠️ Dev mode: all services run as $(whoami) without privilege separation" +echo "" echo "🚀 Starting Spinifex development environment..." echo "Project root: $PROJECT_ROOT" echo "Data directory: $DATA_DIR" diff --git a/spinifex/admin/admin.go b/spinifex/admin/admin.go index 2185a9359..4d36be803 100644 --- a/spinifex/admin/admin.go +++ b/spinifex/admin/admin.go @@ -40,6 +40,7 @@ type ConfigSettings struct { Region string NatsToken string DataDir string + LogDir string ConfigDir string // Add more fields as needed @@ -212,6 +213,7 @@ func CreateServiceDirectories(spxRoot string) { filepath.Join(spxRoot, "nats"), filepath.Join(spxRoot, "predastore"), filepath.Join(spxRoot, "viperblock"), + filepath.Join(spxRoot, "vpcd"), filepath.Join(spxRoot, "spinifex"), } @@ -241,18 +243,30 @@ func FileExists(path string) bool { func ChownRecursive(path, username string) { u, err := user.Lookup(username) if err != nil { + slog.Warn("ChownRecursive: user lookup failed, skipping", "user", username, "path", path, "err", err) + return + } + uid, err := strconv.Atoi(u.Uid) + if err != nil { + slog.Warn("ChownRecursive: invalid UID, skipping", "user", username, "uid", u.Uid, "err", err) + return + } + gid, err := strconv.Atoi(u.Gid) + if err != nil { + slog.Warn("ChownRecursive: invalid GID, skipping", "user", username, "gid", u.Gid, "err", err) return } - uid, _ := strconv.Atoi(u.Uid) - gid, _ := strconv.Atoi(u.Gid) // Use os.Root to scope filesystem operations and avoid symlink TOCTOU races. // Falls back to direct chown if os.Root is not available. root, rootErr := os.OpenRoot(path) if rootErr != nil { - // Fallback: direct chown on the top-level path only + // Fallback: direct chown on the top-level path only — subdirectory contents + // will retain their original ownership. + slog.Warn("ChownRecursive: OpenRoot not available, only top-level directory ownership changed", + "path", path, "err", rootErr) if chownErr := os.Chown(path, uid, gid); chownErr != nil { // #nosec G122 - slog.Debug("chown failed", "path", path, "err", chownErr) + slog.Warn("chown failed", "path", path, "err", chownErr) } return } @@ -271,6 +285,78 @@ func ChownRecursive(path, username string) { }) } +// SetServiceOwnership sets per-service ownership on data/config directories +// and shared config files to root:spinifex with correct modes. +// Keep in sync with setup.sh create_directories() and plan doc section 2. +func SetServiceOwnership() { + grp, err := user.LookupGroup("spinifex") + if err != nil { + slog.Error("SetServiceOwnership: spinifex group not found, skipping all ownership changes", "err", err) + fmt.Fprintln(os.Stderr, "WARNING: spinifex group not found — service ownership not set. Run setup.sh first or create the group manually.") + return + } + gid, err := strconv.Atoi(grp.Gid) + if err != nil { + slog.Error("SetServiceOwnership: invalid spinifex group GID", "gid", grp.Gid, "err", err) + fmt.Fprintln(os.Stderr, "WARNING: invalid spinifex group GID — service ownership not set.") + return + } + + // Per-service directory trees + for path, u := range map[string]string{ + "/etc/spinifex/nats": "spinifex-nats", + "/var/lib/spinifex/nats": "spinifex-nats", + "/etc/spinifex/predastore": "spinifex-storage", + "/var/lib/spinifex/predastore": "spinifex-storage", + "/var/lib/spinifex/spinifex": "spinifex-daemon", + "/var/lib/spinifex/viperblock": "spinifex-viperblock", + "/var/lib/spinifex/vpcd": "spinifex-vpcd", + } { + if _, err := os.Stat(path); err != nil { + continue + } + ChownRecursive(path, u) + } + + // Shared data directories — root:spinifex 0770 so daemon + admin CLI can write + for _, dir := range []string{ + "/var/lib/spinifex/images", + "/var/lib/spinifex/amis", + "/var/lib/spinifex/volumes", + "/var/lib/spinifex/state", + } { + if _, err := os.Stat(dir); err != nil { + continue + } + if err := os.Lchown(dir, 0, gid); err != nil { + slog.Warn("SetServiceOwnership: chown failed", "path", dir, "err", err) + } + if err := os.Chmod(dir, 0770); err != nil { //nolint:gosec // directories need group-write for daemon + admin CLI + slog.Warn("SetServiceOwnership: chmod failed", "path", dir, "err", err) + } + } + + // Shared config files — root:spinifex, ca.key stays root:root 0600 + for path, mode := range map[string]os.FileMode{ + "/etc/spinifex/spinifex.toml": 0640, + "/etc/spinifex/master.key": 0640, + "/etc/spinifex/bootstrap.json": 0660, // group-write so awsgw can consume and truncate + "/etc/spinifex/server.pem": 0644, + "/etc/spinifex/server.key": 0640, + "/etc/spinifex/ca.pem": 0644, + } { + if _, err := os.Stat(path); err != nil { + continue + } + if err := os.Lchown(path, 0, gid); err != nil { + slog.Warn("SetServiceOwnership: chown failed", "path", path, "err", err) + } + if err := os.Chmod(path, mode); err != nil { + slog.Warn("SetServiceOwnership: chmod failed", "path", path, "err", err) + } + } +} + // updateAWSINIFile updates or creates an AWS INI file section with given key-value pairs func UpdateAWSINIFile(path, section string, values map[string]string) error { var cfg *ini.File diff --git a/spinifex/services/viperblockd/viperblockd.go b/spinifex/services/viperblockd/viperblockd.go index c5eb6d99b..2c0fe7955 100644 --- a/spinifex/services/viperblockd/viperblockd.go +++ b/spinifex/services/viperblockd/viperblockd.go @@ -601,6 +601,14 @@ func launchService(cfg *Config) (err error) { slog.Info("NBDKit started successfully and is running") } + // NBDKit creates the socket with its own umask (typically 0755). + // The daemon (different user, same group) needs write access to connect. + if nbdSocket != "" { + if err := os.Chmod(nbdSocket, 0770); err != nil { //nolint:gosec // socket needs group-write for cross-service access + slog.Warn("Failed to chmod NBD socket", "socket", nbdSocket, "err", err) + } + } + ebsResponse.Mounted = true ebsResponse.URI = nbdURI diff --git a/tests/e2e/run-multinode-e2e.sh b/tests/e2e/run-multinode-e2e.sh index c9addb44d..39ef854f6 100755 --- a/tests/e2e/run-multinode-e2e.sh +++ b/tests/e2e/run-multinode-e2e.sh @@ -11,9 +11,6 @@ set -euo pipefail # Ensure Go is on PATH (SSH non-interactive shells don't source .bashrc) export PATH="/usr/local/go/bin:$HOME/go/bin:$PATH" -# Ensure we are in the spinifex project root -cd "$(dirname "$0")/../.." - # ========================================================================== # Argument parsing # ========================================================================== @@ -36,14 +33,12 @@ NATS_MONITOR_PORT=8222 PREDASTORE_PORT=8443 AWSGW_PORT=9999 SSH_KEY_PATH="$HOME/.ssh/tf-user-ap-southeast-2" -SPINIFEX_DATA_DIR="$HOME/spinifex" -SPINIFEX_CONFIG="$SPINIFEX_DATA_DIR/config/spinifex.toml" -SPINIFEX_BIN="./bin/spx" +SPINIFEX_BIN="spx" # Use Spinifex profile for AWS CLI export AWS_PROFILE=spinifex # Trust Spinifex CA for AWS CLI v2 (bundles its own Python/certifi, ignores system CA store) -export AWS_CA_BUNDLE="$SPINIFEX_DATA_DIR/config/ca.pem" +export AWS_CA_BUNDLE="/etc/spinifex/ca.pem" # Track test results TESTS_PASSED=0 @@ -106,19 +101,15 @@ dump_all_node_logs() { local ip="${NODE_IPS[$i]}" echo "" echo "=== Node $((i+1)) ($ip) ===" - if [ "$ip" = "$LOCAL_IP" ]; then - for f in "$SPINIFEX_DATA_DIR/logs/"*.log; do - [ -f "$f" ] || continue - echo "--- $(basename "$f") (last 50 lines) ---" - tail -50 "$f" 2>/dev/null || echo "(not found)" - done - else - peer_ssh "$ip" 'for f in ~/spinifex/logs/*.log; do - [ -f "$f" ] || continue - echo "--- $(basename "$f") (last 50 lines) ---" - tail -50 "$f" 2>/dev/null || echo "(not found)" - done' || echo "(node unreachable)" - fi + for svc in spinifex-nats spinifex-predastore spinifex-viperblock \ + spinifex-daemon spinifex-awsgw spinifex-vpcd; do + echo "--- ${svc} (last 50 lines) ---" + if [ "$ip" = "$LOCAL_IP" ]; then + sudo journalctl -u "$svc" --no-pager -n 50 2>/dev/null || echo "(not found)" + else + peer_ssh "$ip" "sudo journalctl -u $svc --no-pager -n 50" 2>/dev/null || echo "(node unreachable)" + fi + done done echo "" echo "==========================================" @@ -403,7 +394,7 @@ pass_test "Daemon readiness" # Spinifex CLI: get nodes echo "Checking spx get nodes..." -GET_NODES_OUTPUT=$($SPINIFEX_BIN get nodes --config "$SPINIFEX_CONFIG" --timeout 5s 2>/dev/null) +GET_NODES_OUTPUT=$($SPINIFEX_BIN get nodes --timeout 5s 2>/dev/null) echo "$GET_NODES_OUTPUT" READY_COUNT=$(echo "$GET_NODES_OUTPUT" | grep -c "Ready" || true) if [ "$READY_COUNT" -ge 3 ]; then @@ -415,7 +406,7 @@ fi # Spinifex CLI: get vms (should be empty) echo "Checking spx get vms (empty)..." -GET_VMS_OUTPUT=$($SPINIFEX_BIN get vms --config "$SPINIFEX_CONFIG" --timeout 5s 2>/dev/null) +GET_VMS_OUTPUT=$($SPINIFEX_BIN get vms --timeout 5s 2>/dev/null) echo "$GET_VMS_OUTPUT" pass_test "spx get vms (empty)" @@ -500,7 +491,7 @@ fi # Verify spx get vms shows all instances echo "" echo "Verifying spx get vms..." -GET_VMS_OUTPUT=$($SPINIFEX_BIN get vms --config "$SPINIFEX_CONFIG" --timeout 5s 2>/dev/null) +GET_VMS_OUTPUT=$($SPINIFEX_BIN get vms --timeout 5s 2>/dev/null) echo "$GET_VMS_OUTPUT" for instance_id in "${INSTANCE_IDS[@]}"; do if ! echo "$GET_VMS_OUTPUT" | grep -q "$instance_id"; then @@ -787,8 +778,8 @@ echo "Stopping services on node2 ($NODE2_IP) to simulate node failure..." # Stop services on node2 only — SPINIFEX_FORCE_LOCAL_STOP prevents coordinated # cluster shutdown which would kill all nodes via NATS -peer_ssh "$NODE2_IP" "cd ~/Development/mulga/spinifex && SPINIFEX_FORCE_LOCAL_STOP=1 ./scripts/stop-dev.sh" || { - echo " WARNING: stop-dev.sh returned non-zero (may be expected)" +peer_ssh "$NODE2_IP" "sudo systemctl stop spinifex.target" || { + echo " WARNING: systemctl stop returned non-zero (may be expected)" } # Wait for NATS cluster to detect the failure and reform @@ -848,7 +839,7 @@ echo "Phase 9: Node Recovery" echo "========================================" echo "Restarting services on node2 ($NODE2_IP)..." -peer_ssh "$NODE2_IP" "cd ~/Development/mulga/spinifex && ./scripts/start-dev.sh" || { +peer_ssh "$NODE2_IP" "sudo systemctl start spinifex.target" || { echo " ERROR: Failed to restart services on node2" fail_test "Node2 restart" } @@ -899,7 +890,7 @@ fi # Verify spx get nodes shows 3 Ready again echo " Checking spx get nodes after recovery..." -GET_NODES_RECOVER=$($SPINIFEX_BIN get nodes --config "$SPINIFEX_CONFIG" --timeout 10s 2>/dev/null || echo "") +GET_NODES_RECOVER=$($SPINIFEX_BIN get nodes --timeout 10s 2>/dev/null || echo "") echo "$GET_NODES_RECOVER" READY_RECOVER=$(echo "$GET_NODES_RECOVER" | grep -c "Ready" || true) if [ "$READY_RECOVER" -ge 3 ]; then @@ -1252,7 +1243,7 @@ else echo "Step 4: Validating spread placement across nodes..." # Use spx get vms to check node assignment - SPX_VMS=$($SPINIFEX_BIN get vms --config "$SPINIFEX_CONFIG" --timeout 5s 2>/dev/null) + SPX_VMS=$($SPINIFEX_BIN get vms --timeout 5s 2>/dev/null) echo "$SPX_VMS" SPREAD_NODES=() From 820b605c0bd55105176a454e54b96c0ce5d77d4d Mon Sep 17 00:00:00 2001 From: Julian Sommer <115516918+juliansommer@users.noreply.github.com> Date: Wed, 8 Apr 2026 09:32:25 +1000 Subject: [PATCH 02/14] fix: require sudo admin init --- cmd/spinifex/cmd/admin.go | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/cmd/spinifex/cmd/admin.go b/cmd/spinifex/cmd/admin.go index a18ba253e..fa692285a 100644 --- a/cmd/spinifex/cmd/admin.go +++ b/cmd/spinifex/cmd/admin.go @@ -546,9 +546,9 @@ func runimagesListCmd(cmd *cobra.Command, args []string) { // TODO: Move all logic to a module, use minimal application logic in viper commands func runAdminInit(cmd *cobra.Command, args []string) { if os.Getuid() != 0 { - fmt.Fprintln(os.Stderr, "⚠️ Not running as root — CA certificate will not be installed to system trust store.") - fmt.Fprintln(os.Stderr, " Run with sudo, or manually: sudo cp ~/spinifex/config/ca.pem /usr/local/share/ca-certificates/spinifex-ca.crt && sudo update-ca-certificates") - fmt.Fprintln(os.Stderr) + fmt.Fprintln(os.Stderr, "❌ Error: 'spx admin init' must be run as root (sudo).") + fmt.Fprintln(os.Stderr, " Root is required for user/service setup and CA certificate installation.") + os.Exit(1) } force, _ := cmd.Flags().GetBool("force") @@ -1273,8 +1273,9 @@ func runAdminInitMultiNode(cmd *cobra.Command, accessKey, secretKey, accountID, func runAdminJoin(cmd *cobra.Command, args []string) { if os.Getuid() != 0 { - fmt.Fprintln(os.Stderr, "⚠️ Not running as root — CA certificate will not be installed to system trust store.") - fmt.Fprintln(os.Stderr) + fmt.Fprintln(os.Stderr, "❌ Error: 'spx admin join' must be run as root (sudo).") + fmt.Fprintln(os.Stderr, " Root is required for user/service setup and CA certificate installation.") + os.Exit(1) } node, _ := cmd.Flags().GetString("node") @@ -1656,10 +1657,6 @@ func runAdminJoin(cmd *cobra.Command, args []string) { for name, n := range statusResp.Nodes { fmt.Printf(" - %s (%s)\n", name, n.BindIP) } - fmt.Println("\n📋 Next steps:") - fmt.Println(" 1. Start services:") - fmt.Println(" ./scripts/start-dev.sh") - fmt.Println() } // buildRemoteNodes converts formation NodeInfo into RemoteNode entries, From 45ea467fcc747fee2738cfb97c3facfcea50daa2 Mon Sep 17 00:00:00 2001 From: Julian Sommer <115516918+juliansommer@users.noreply.github.com> Date: Wed, 8 Apr 2026 11:46:43 +1000 Subject: [PATCH 03/14] feat: webserver proxy (#116) --- build/systemd/spinifex-awsgw.service | 2 +- spinifex/admin/admin.go | 6 + spinifex/gateway/ec2/instance/RunInstances.go | 4 + .../gateway/ec2/instance/placement_test.go | 3 + spinifex/services/awsgw/awsgw.go | 9 +- .../dist/assets/DescribeInstancesCommand.js | 2 +- .../frontend/dist/assets/awsClient.js | 4 +- .../frontend/dist/assets/create-key-pair.js | 2 +- .../spinifexui/frontend/dist/assets/ec2.js | 2 +- .../spinifexui/frontend/dist/assets/ec22.js | 2 +- .../spinifexui/frontend/dist/assets/ec23.js | 2 +- .../spinifexui/frontend/dist/assets/iam.js | 2 +- .../spinifexui/frontend/dist/assets/iam2.js | 2 +- .../spinifexui/frontend/dist/assets/index.js | 12 +- .../dist/assets/lazyRouteComponent.js | 2 +- .../spinifexui/frontend/dist/assets/link.js | 2 +- .../spinifexui/frontend/dist/assets/login.js | 2 +- .../spinifexui/frontend/dist/assets/s3.js | 2 +- .../spinifexui/frontend/dist/assets/s32.js | 2 +- .../frontend/dist/assets/upload-button.js | 2 +- .../frontend/dist/assets/useNavigate.js | 2 +- .../frontend/dist/assets/useRouter.js | 1 - .../frontend/dist/assets/useStore.js | 2 +- .../spinifexui/frontend/dist/assets/zod.js | 2 +- .../spinifexui/frontend/dist/index.html | 1 - .../spinifexui/frontend/src/lib/awsClient.ts | 74 +++-- .../frontend/src/lib/signed-fetch.ts | 21 +- .../frontend/src/mutations/s3.test.tsx | 2 +- .../ec2/-components/private-key-modal.tsx | 7 +- .../spinifexui/frontend/src/routes/login.tsx | 5 +- .../spinifexui/frontend/src/types/ec2.ts | 2 +- spinifex/services/spinifexui/proxy.go | 74 +++++ spinifex/services/spinifexui/spinifexui.go | 272 ++++-------------- .../services/spinifexui/spinifexui_test.go | 187 ++++++++++-- spinifex/services/spinifexui/tlssplit.go | 104 +++++++ tests/e2e/lib/multinode-helpers.sh | 24 +- tests/e2e/run-pseudo-multinode-e2e.sh | 10 +- 37 files changed, 522 insertions(+), 334 deletions(-) delete mode 100644 spinifex/services/spinifexui/frontend/dist/assets/useRouter.js create mode 100644 spinifex/services/spinifexui/proxy.go create mode 100644 spinifex/services/spinifexui/tlssplit.go diff --git a/build/systemd/spinifex-awsgw.service b/build/systemd/spinifex-awsgw.service index 42f6df37b..0252031c5 100644 --- a/build/systemd/spinifex-awsgw.service +++ b/build/systemd/spinifex-awsgw.service @@ -23,7 +23,7 @@ NoNewPrivileges=yes ProtectSystem=strict PrivateDevices=yes ReadOnlyPaths=/etc/spinifex/spinifex.toml /etc/spinifex/master.key /etc/spinifex/server.pem /etc/spinifex/server.key -ReadWritePaths=/var/lib/spinifex /var/log/spinifex /etc/spinifex/bootstrap.json /tmp +ReadWritePaths=/var/lib/spinifex /var/log/spinifex /etc/spinifex /tmp # Hardening ProtectHome=yes diff --git a/spinifex/admin/admin.go b/spinifex/admin/admin.go index 4d36be803..3c709faa8 100644 --- a/spinifex/admin/admin.go +++ b/spinifex/admin/admin.go @@ -336,6 +336,12 @@ func SetServiceOwnership() { } } + // /etc/spinifex needs group-write so awsgw (spinifex-gw) can delete + // bootstrap.json after consuming it on first boot. + if err := os.Chmod("/etc/spinifex", 0770); err != nil { //nolint:gosec // directory needs group-write for bootstrap.json deletion + slog.Warn("SetServiceOwnership: chmod /etc/spinifex failed", "err", err) + } + // Shared config files — root:spinifex, ca.key stays root:root 0600 for path, mode := range map[string]os.FileMode{ "/etc/spinifex/spinifex.toml": 0640, diff --git a/spinifex/gateway/ec2/instance/RunInstances.go b/spinifex/gateway/ec2/instance/RunInstances.go index 8ab401669..076cec67f 100644 --- a/spinifex/gateway/ec2/instance/RunInstances.go +++ b/spinifex/gateway/ec2/instance/RunInstances.go @@ -51,6 +51,10 @@ func ValidateRunInstancesInput(input *ec2.RunInstancesInput) (err error) { return errors.New(awserrors.ErrorMissingParameter) } + if input.KeyName == nil || *input.KeyName == "" { + return errors.New(awserrors.ErrorMissingParameter) + } + if !strings.HasPrefix(*input.ImageId, "ami-") { return errors.New(awserrors.ErrorInvalidAMIIDMalformed) } diff --git a/spinifex/gateway/ec2/instance/placement_test.go b/spinifex/gateway/ec2/instance/placement_test.go index a3c00b352..771dc0db9 100644 --- a/spinifex/gateway/ec2/instance/placement_test.go +++ b/spinifex/gateway/ec2/instance/placement_test.go @@ -572,6 +572,7 @@ func TestRunInstances_SingleInstanceDistributes(t *testing.T) { input := &ec2.RunInstancesInput{ ImageId: aws.String("ami-test"), InstanceType: aws.String("t3.micro"), + KeyName: aws.String("test-key"), MinCount: aws.Int64(1), MaxCount: aws.Int64(1), } @@ -1073,6 +1074,7 @@ func TestRunInstances_ClusterPlacementGroupRouting(t *testing.T) { input := &ec2.RunInstancesInput{ ImageId: aws.String("ami-test"), InstanceType: aws.String("t3.micro"), + KeyName: aws.String("test-key"), MinCount: aws.Int64(2), MaxCount: aws.Int64(2), Placement: &ec2.Placement{ @@ -1123,6 +1125,7 @@ func TestRunInstances_MultiInstanceUsesDistribution(t *testing.T) { input := &ec2.RunInstancesInput{ ImageId: aws.String("ami-test"), InstanceType: aws.String("t3.micro"), + KeyName: aws.String("test-key"), MinCount: aws.Int64(2), MaxCount: aws.Int64(2), } diff --git a/spinifex/services/awsgw/awsgw.go b/spinifex/services/awsgw/awsgw.go index 63caedfea..c81894247 100644 --- a/spinifex/services/awsgw/awsgw.go +++ b/spinifex/services/awsgw/awsgw.go @@ -107,8 +107,12 @@ func launchService(config *config.ClusterConfig) error { return fmt.Errorf("initialize IAM service: %w", err) } - // First boot: consume bootstrap.json → seed IAM users into NATS KV → delete file + // First boot: consume bootstrap.json → seed IAM users into NATS KV → delete file. + // Resolve symlinks so the path matches systemd ReadWritePaths for deletion. bootstrapPath := filepath.Join(nodeConfig.BaseDir, "config", "bootstrap.json") + if resolved, err := filepath.EvalSymlinks(bootstrapPath); err == nil { + bootstrapPath = resolved + } data, err := handlers_iam.LoadBootstrapData(bootstrapPath) switch { case err == nil: @@ -118,8 +122,9 @@ func launchService(config *config.ClusterConfig) error { } if err := os.Remove(bootstrapPath); err != nil { slog.Warn("Failed to delete bootstrap file", "path", bootstrapPath, "err", err) + } else { + slog.Info("Bootstrap complete, bootstrap.json deleted") } - slog.Info("Bootstrap complete, bootstrap.json deleted") case os.IsNotExist(err): // No bootstrap file — normal after first boot default: diff --git a/spinifex/services/spinifexui/frontend/dist/assets/DescribeInstancesCommand.js b/spinifex/services/spinifexui/frontend/dist/assets/DescribeInstancesCommand.js index 141222ad4..046104e2f 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/DescribeInstancesCommand.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/DescribeInstancesCommand.js @@ -1 +1 @@ -import{It as e,Lt as t,Vt as n,pt as r}from"./awsClient.js";var i=class extends n.classBuilder().ep(e).m(function(e,n,r,i){return[t(r,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeInstances`,{}).n(`EC2Client`,`DescribeInstancesCommand`).sc(r).build(){};export{i as t}; \ No newline at end of file +import{It as e,Rt as t,pt as n,zt as r}from"./awsClient.js";var i=class extends t.classBuilder().ep(e).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeInstances`,{}).n(`EC2Client`,`DescribeInstancesCommand`).sc(n).build(){};export{i as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/awsClient.js b/spinifex/services/spinifexui/frontend/dist/assets/awsClient.js index 680035706..255797794 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/awsClient.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/awsClient.js @@ -6,5 +6,5 @@ import{i as e,r as t}from"./compiler-runtime.js";import{S as n,_ as r,c as i,d a If you are using React Native, this API is not yet supported, see: https://react-native.canny.io/feature-requests/p/fetch-streaming-body`);return e.stream()};return Object.assign(e,{transformToByteArray:n,transformToString:async e=>{let t=await n();if(e===`base64`)return We(t);if(e===`hex`)return ne(t);if(e===void 0||e===`utf8`||e===`utf-8`)return ce(t);if(typeof TextDecoder==`function`)return new TextDecoder(e).decode(t);throw Error(`TextDecoder is not available, please make sure polyfill is provided.`)},transformToWebStream:()=>{if(t)throw Error(at);if(t=!0,st(e))return r(e);if(Ke(e))return e;throw Error(`Cannot transform payload to web stream, got ${e}`)}})},st=e=>typeof Blob==`function`&&e instanceof Blob;async function ct(e){return typeof e.stream==`function`&&(e=e.stream()),e.tee()}var lt=async(e=new Uint8Array,t)=>{if(e instanceof Uint8Array)return Ge.mutate(e);if(!e)return Ge.mutate(new Uint8Array);let n=t.streamCollector(e);return Ge.mutate(await n)};function ut(e){return encodeURIComponent(e).replace(/[!'()*]/g,function(e){return`%`+e.charCodeAt(0).toString(16).toUpperCase()})}var dt=e=>typeof e==`function`?e():e,ft=(e,t,n,r,i)=>({name:t,namespace:e,traits:n,input:r,output:i}),pt=e=>(t,n)=>async r=>{let{response:i}=await t(r),{operationSchema:a}=_e(n),[,o,s,c,l,u]=a??[];try{return{response:i,output:await e.protocol.deserializeResponse(ft(o,s,c,l,u),{...e,...n},i)}}catch(e){if(Object.defineProperty(e,`$response`,{value:i,enumerable:!1,writable:!1,configurable:!1}),!(`$metadata`in e)){let t=`Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.`;try{e.message+=` `+t}catch{!n.logger||n.logger?.constructor?.name===`NoOpLogger`?console.warn(t):n.logger?.warn?.(t)}e.$responseBodyText!==void 0&&e.$response&&(e.$response.body=e.$responseBodyText);try{if(ge.isInstance(i)){let{headers:t={}}=i,n=Object.entries(t);e.$metadata={httpStatusCode:i.statusCode,requestId:mt(/^x-[\w-]+-request-?id$/,n),extendedRequestId:mt(/^x-[\w-]+-id-2$/,n),cfId:mt(/^x-[\w-]+-cf-id$/,n)}}}catch{}}throw e}},mt=(e,t)=>(t.find(([t])=>t.match(e))||[void 0,void 0])[1];function ht(e){let t={};if(e=e.replace(/^\?/,``),e)for(let n of e.split(`&`)){let[e,r=null]=n.split(`=`);e=decodeURIComponent(e),r&&=decodeURIComponent(r),e in t?Array.isArray(t[e])?t[e].push(r):t[e]=[t[e],r]:t[e]=r}return t}var gt=e=>{if(typeof e==`string`)return gt(new URL(e));let{hostname:t,pathname:n,port:r,protocol:i,search:a}=e,o;return a&&(o=ht(a)),{hostname:t,port:r?parseInt(r):void 0,protocol:i,path:n,query:o}},_t=e=>{if(typeof e==`object`){if(`url`in e){let t=gt(e.url);if(e.headers){t.headers={};for(let[n,r]of Object.entries(e.headers))t.headers[n.toLowerCase()]=r.join(`, `)}return t}return e}return gt(e)},vt=e=>(t,n)=>async r=>{let{operationSchema:i}=_e(n),[,a,o,s,c,l]=i??[],u=n.endpointV2?async()=>_t(n.endpointV2):e.endpoint,d=await e.protocol.serializeRequest(ft(a,o,s,c,l),r.input,{...e,...n,endpoint:u});return t({...r,request:d})},yt={name:`deserializerMiddleware`,step:`deserialize`,tags:[`DESERIALIZER`],override:!0},bt={name:`serializerMiddleware`,step:`serialize`,tags:[`SERIALIZER`],override:!0};function xt(e){return{applyToStack:t=>{t.add(vt(e),bt),t.add(pt(e),yt),e.protocol.setSerdeContext(e)}}}var St=[];function Ct(e){if(typeof e==`object`)return e;if(e|=0,St[e])return St[e];let t={},n=0;for(let r of[`httpLabel`,`idempotent`,`idempotencyToken`,`sensitive`,`httpPayload`,`httpResponseCode`,`httpQueryParams`])(e>>n++&1)==1&&(t[r]=1);return St[e]=t}var wt={it:Symbol.for(`@smithy/nor-struct-it`),ns:Symbol.for(`@smithy/ns`)},Tt=[],Et={},p=class e{ref;memberName;static symbol=Symbol.for(`@smithy/nor`);symbol=e.symbol;name;schema;_isMemberSchema;traits;memberTraits;normalizedTraits;constructor(t,n){this.ref=t,this.memberName=n;let r=[],i=t,a=t;for(this._isMemberSchema=!1;Ot(i);)r.push(i[1]),i=i[0],a=dt(i),this._isMemberSchema=!0;if(r.length>0){this.memberTraits={};for(let e=r.length-1;e>=0;--e){let t=r[e];Object.assign(this.memberTraits,Ct(t))}}else this.memberTraits=0;if(a instanceof e){let e=this.memberTraits;Object.assign(this,a),this.memberTraits=Object.assign({},e,a.getMemberTraits(),this.getMemberTraits()),this.normalizedTraits=void 0,this.memberName=n??a.memberName;return}if(this.schema=dt(a),kt(this.schema)?(this.name=`${this.schema[1]}#${this.schema[2]}`,this.traits=this.schema[3]):(this.name=this.memberName??String(a),this.traits=0),this._isMemberSchema&&!n)throw Error(`@smithy/core/schema - NormalizedSchema member init ${this.getName(!0)} missing member name.`)}static[Symbol.hasInstance](e){let t=this.prototype.isPrototypeOf(e);return!t&&typeof e==`object`&&e?e.symbol===this.symbol:t}static of(t){let n=typeof t==`function`||typeof t==`object`&&!!t;if(typeof t==`number`){if(Tt[t])return Tt[t]}else if(typeof t==`string`){if(Et[t])return Et[t]}else if(n&&t[wt.ns])return t[wt.ns];let r=dt(t);if(r instanceof e)return r;if(Ot(r)){let[n,i]=r;if(n instanceof e)return Object.assign(n.getMergedTraits(),Ct(i)),n;throw Error(`@smithy/core/schema - may not init unwrapped member schema=${JSON.stringify(t,null,2)}.`)}let i=new e(r);return n?t[wt.ns]=i:typeof r==`string`?Et[r]=i:typeof r==`number`?Tt[r]=i:i}getSchema(){let e=this.schema;return Array.isArray(e)&&e[0]===0?e[4]:e}getName(e=!1){let{name:t}=this;return!e&&t&&t.includes(`#`)?t.split(`#`)[1]:t||void 0}getMemberName(){return this.memberName}isMemberSchema(){return this._isMemberSchema}isListSchema(){let e=this.getSchema();return typeof e==`number`?e>=64&&e<128:e[0]===1}isMapSchema(){let e=this.getSchema();return typeof e==`number`?e>=128&&e<=255:e[0]===2}isStructSchema(){let e=this.getSchema();if(typeof e!=`object`)return!1;let t=e[0];return t===3||t===-3||t===4}isUnionSchema(){let e=this.getSchema();return typeof e==`object`?e[0]===4:!1}isBlobSchema(){let e=this.getSchema();return e===21||e===42}isTimestampSchema(){let e=this.getSchema();return typeof e==`number`&&e>=4&&e<=7}isUnitSchema(){return this.getSchema()===`unit`}isDocumentSchema(){return this.getSchema()===15}isStringSchema(){return this.getSchema()===0}isBooleanSchema(){return this.getSchema()===2}isNumericSchema(){return this.getSchema()===1}isBigIntegerSchema(){return this.getSchema()===17}isBigDecimalSchema(){return this.getSchema()===19}isStreaming(){let{streaming:e}=this.getMergedTraits();return!!e||this.getSchema()===42}isIdempotencyToken(){return!!this.getMergedTraits().idempotencyToken}getMergedTraits(){return this.normalizedTraits??={...this.getOwnTraits(),...this.getMemberTraits()}}getMemberTraits(){return Ct(this.memberTraits)}getOwnTraits(){return Ct(this.traits)}getKeySchema(){let[e,t]=[this.isDocumentSchema(),this.isMapSchema()];if(!e&&!t)throw Error(`@smithy/core/schema - cannot get key for non-map: ${this.getName(!0)}`);let n=this.getSchema();return Dt([e?15:n[4]??0,0],`key`)}getValueSchema(){let e=this.getSchema(),[t,n,r]=[this.isDocumentSchema(),this.isMapSchema(),this.isListSchema()],i=typeof e==`number`?63&e:e&&typeof e==`object`&&(n||r)?e[3+e[0]]:t?15:void 0;if(i!=null)return Dt([i,0],n?`value`:`member`);throw Error(`@smithy/core/schema - ${this.getName(!0)} has no value member.`)}getMemberSchema(e){let t=this.getSchema();if(this.isStructSchema()&&t[4].includes(e)){let n=t[4].indexOf(e),r=t[5][n];return Dt(Ot(r)?r:[r,0],e)}if(this.isDocumentSchema())return Dt([15,0],e);throw Error(`@smithy/core/schema - ${this.getName(!0)} has no member=${e}.`)}getMemberSchemas(){let e={};try{for(let[t,n]of this.structIterator())e[t]=n}catch{}return e}getEventStreamMember(){if(this.isStructSchema()){for(let[e,t]of this.structIterator())if(t.isStreaming()&&t.isStructSchema())return e}return``}*structIterator(){if(this.isUnitSchema())return;if(!this.isStructSchema())throw Error(`@smithy/core/schema - cannot iterate non-struct schema.`);let e=this.getSchema(),t=e[4].length,n=e[wt.it];if(n&&t===n.length){yield*n;return}n=Array(t);for(let r=0;rArray.isArray(e)&&e.length===2,kt=e=>Array.isArray(e)&&e.length>=5,At=class e{namespace;schemas;exceptions;static registries=new Map;constructor(e,t=new Map,n=new Map){this.namespace=e,this.schemas=t,this.exceptions=n}static for(t){return e.registries.has(t)||e.registries.set(t,new e(t)),e.registries.get(t)}copyFrom(e){let{schemas:t,exceptions:n}=this;for(let[n,r]of e.schemas)t.has(n)||t.set(n,r);for(let[t,r]of e.exceptions)n.has(t)||n.set(t,r)}register(t,n){let r=this.normalizeShapeId(t);for(let t of[this,e.for(r.split(`#`)[0])])t.schemas.set(r,n)}getSchema(e){let t=this.normalizeShapeId(e);if(!this.schemas.has(t))throw Error(`@smithy/core/schema - schema not found for ${t}`);return this.schemas.get(t)}registerError(t,n){let r=t,i=r[1];for(let t of[this,e.for(i)])t.schemas.set(i+`#`+r[2],r),t.exceptions.set(r,n)}getErrorCtor(t){let n=t;return this.exceptions.has(n)?this.exceptions.get(n):e.for(n[1]).exceptions.get(n)}getBaseException(){for(let e of this.exceptions.keys())if(Array.isArray(e)){let[,t,n]=e,r=t+`#`+n;if(r.startsWith(`smithy.ts.sdk.synthetic.`)&&r.endsWith(`ServiceException`))return e}}find(e){return[...this.schemas.values()].find(e)}clear(){this.schemas.clear(),this.exceptions.clear()}normalizeShapeId(e){return e.includes(`#`)?e:this.namespace+`#`+e}},jt=e=>{if(e!=null){if(typeof e==`string`){let t=parseFloat(e);if(!Number.isNaN(t))return String(t)!==String(e)&&Gt.warn(Wt(`Expected number but observed string: ${e}`)),t}if(typeof e==`number`)return e;throw TypeError(`Expected number, got ${typeof e}: ${e}`)}},Mt=Math.ceil(2**127*(2-2**-23)),Nt=e=>{let t=jt(e);if(t!==void 0&&!Number.isNaN(t)&&t!==1/0&&t!==-1/0&&Math.abs(t)>Mt)throw TypeError(`Expected 32-bit float, got ${e}`);return t},Pt=e=>{if(e!=null){if(Number.isInteger(e)&&!Number.isNaN(e))return e;throw TypeError(`Expected integer, got ${typeof e}: ${e}`)}},Ft=e=>Lt(e,16),It=e=>Lt(e,8),Lt=(e,t)=>{let n=Pt(e);if(n!==void 0&&Rt(n,t)!==n)throw TypeError(`Expected ${t}-bit integer, got ${e}`);return n},Rt=(e,t)=>{switch(t){case 32:return Int32Array.of(e)[0];case 16:return Int16Array.of(e)[0];case 8:return Int8Array.of(e)[0]}},zt=e=>Nt(typeof e==`string`?Vt(e):e),Bt=/(-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?)|(-?Infinity)|(NaN)/g,Vt=e=>{let t=e.match(Bt);if(t===null||t[0].length!==e.length)throw TypeError(`Expected real number, got implicit NaN`);return parseFloat(e)},Ht=e=>Ft(typeof e==`string`?Vt(e):e),Ut=e=>It(typeof e==`string`?Vt(e):e),Wt=e=>String(TypeError(e).stack||e).split(` `).slice(0,5).filter(e=>!e.includes(`stackTraceWarning`)).join(` -`),Gt={warn:console.warn},Kt=[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`],qt=[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`];function Jt(e){let t=e.getUTCFullYear(),n=e.getUTCMonth(),r=e.getUTCDay(),i=e.getUTCDate(),a=e.getUTCHours(),o=e.getUTCMinutes(),s=e.getUTCSeconds(),c=i<10?`0${i}`:`${i}`,l=a<10?`0${a}`:`${a}`,u=o<10?`0${o}`:`${o}`,d=s<10?`0${s}`:`${s}`;return`${Kt[r]}, ${c} ${qt[n]} ${t} ${l}:${u}:${d} GMT`}var Yt=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d{2}) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),Xt=new RegExp(/^(?:Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d{2})-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),Zt=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( [1-9]|\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? (\d{4})$/),Qt=e=>{if(e==null)return;if(typeof e!=`string`)throw TypeError(`RFC-7231 date-times must be expressed as strings`);let t=Yt.exec(e);if(t){let[e,n,r,i,a,o,s,c]=t;return $t(Ht(un(i)),rn(r),cn(n,`day`,1,31),{hours:a,minutes:o,seconds:s,fractionalMilliseconds:c})}if(t=Xt.exec(e),t){let[e,n,r,i,a,o,s,c]=t;return nn($t(en(i),rn(r),cn(n,`day`,1,31),{hours:a,minutes:o,seconds:s,fractionalMilliseconds:c}))}if(t=Zt.exec(e),t){let[e,n,r,i,a,o,s,c]=t;return $t(Ht(un(c)),rn(n),cn(r.trimLeft(),`day`,1,31),{hours:i,minutes:a,seconds:o,fractionalMilliseconds:s})}throw TypeError(`Invalid RFC-7231 date-time value`)},$t=(e,t,n,r)=>{let i=t-1;return on(e,i,n),new Date(Date.UTC(e,i,n,cn(r.hours,`hour`,0,23),cn(r.minutes,`minute`,0,59),cn(r.seconds,`seconds`,0,60),ln(r.fractionalMilliseconds)))},en=e=>{let t=new Date().getUTCFullYear(),n=Math.floor(t/100)*100+Ht(un(e));return ne.getTime()-new Date().getTime()>tn?new Date(Date.UTC(e.getUTCFullYear()-100,e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds())):e,rn=e=>{let t=qt.indexOf(e);if(t<0)throw TypeError(`Invalid month: ${e}`);return t+1},an=[31,28,31,30,31,30,31,31,30,31,30,31],on=(e,t,n)=>{let r=an[t];if(t===1&&sn(e)&&(r=29),n>r)throw TypeError(`Invalid day for ${qt[t]} in ${e}: ${n}`)},sn=e=>e%4==0&&(e%100!=0||e%400==0),cn=(e,t,n,r)=>{let i=Ut(un(e));if(ir)throw TypeError(`${t} must be between ${n} and ${r}, inclusive`);return i},ln=e=>e==null?0:zt(`0.`+e)*1e3,un=e=>{let t=0;for(;tt.toString(16).padStart(2,`0`)),pn=()=>{if(dn)return dn();let e=new Uint8Array(16);return crypto.getRandomValues(e),e[6]=e[6]&15|64,e[8]=e[8]&63|128,fn[e[0]]+fn[e[1]]+fn[e[2]]+fn[e[3]]+`-`+fn[e[4]]+fn[e[5]]+`-`+fn[e[6]]+fn[e[7]]+`-`+fn[e[8]]+fn[e[9]]+`-`+fn[e[10]]+fn[e[11]]+fn[e[12]]+fn[e[13]]+fn[e[14]]+fn[e[15]]},mn=function(e){return Object.assign(new String(e),{deserializeJSON(){return JSON.parse(String(e))},toString(){return String(e)},toJSON(){return String(e)}})};mn.from=e=>e&&typeof e==`object`&&(e instanceof mn||`deserializeJSON`in e)?e:typeof e==`string`||Object.getPrototypeOf(e)===String.prototype?mn(String(e)):mn(JSON.stringify(e)),mn.fromObject=mn.from;function hn(e){return(e.includes(`,`)||e.includes(`"`))&&(e=`"${e.replace(/"/g,`\\"`)}"`),e}var gn=`(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun)(?:[ne|u?r]?s?day)?`,_n=`(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)`,vn=`(\\d?\\d):(\\d{2}):(\\d{2})(?:\\.(\\d+))?`,yn=`(\\d?\\d)`,bn=`(\\d{4})`,xn=new RegExp(/^(\d{4})-(\d\d)-(\d\d)[tT](\d\d):(\d\d):(\d\d)(\.(\d+))?(([-+]\d\d:\d\d)|[zZ])$/),Sn=RegExp(`^${gn}, ${yn} ${_n} ${bn} ${vn} GMT$`),Cn=RegExp(`^${gn}, ${yn}-${_n}-(\\d\\d) ${vn} GMT$`),wn=RegExp(`^${gn} ${_n} ( [1-9]|\\d\\d) ${vn} ${bn}$`),Tn=[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`],En=e=>{if(e==null)return;let t=NaN;if(typeof e==`number`)t=e;else if(typeof e==`string`){if(!/^-?\d*\.?\d+$/.test(e))throw TypeError(`parseEpochTimestamp - numeric string invalid.`);t=Number.parseFloat(e)}else typeof e==`object`&&e.tag===1&&(t=e.value);if(isNaN(t)||Math.abs(t)===1/0)throw TypeError(`Epoch timestamps must be valid finite numbers.`);return new Date(Math.round(t*1e3))},Dn=e=>{if(e==null)return;if(typeof e!=`string`)throw TypeError(`RFC3339 timestamps must be strings`);let t=xn.exec(e);if(!t)throw TypeError(`Invalid RFC3339 timestamp format ${e}`);let[,n,r,i,a,o,s,,c,l]=t;kn(r,1,12),kn(i,1,31),kn(a,0,23),kn(o,0,59),kn(s,0,60);let u=new Date(Date.UTC(Number(n),Number(r)-1,Number(i),Number(a),Number(o),Number(s),Number(c)?Math.round(parseFloat(`0.${c}`)*1e3):0));if(u.setUTCFullYear(Number(n)),l.toUpperCase()!=`Z`){let[,e,t,n]=/([+-])(\d\d):(\d\d)/.exec(l)||[void 0,`+`,0,0],r=e===`-`?1:-1;u.setTime(u.getTime()+r*(Number(t)*60*60*1e3+Number(n)*60*1e3))}return u},On=e=>{if(e==null)return;if(typeof e!=`string`)throw TypeError(`RFC7231 timestamps must be strings.`);let t,n,r,i,a,o,s,c;if((c=Sn.exec(e))?[,t,n,r,i,a,o,s]=c:(c=Cn.exec(e))?([,t,n,r,i,a,o,s]=c,r=(Number(r)+1900).toString()):(c=wn.exec(e))&&([,n,t,i,a,o,s,r]=c),r&&o){let e=Date.UTC(Number(r),Tn.indexOf(n),Number(t),Number(i),Number(a),Number(o),s?Math.round(parseFloat(`0.${s}`)*1e3):0);kn(t,1,31),kn(i,0,23),kn(a,0,59),kn(o,0,60);let c=new Date(e);return c.setUTCFullYear(Number(r)),c}throw TypeError(`Invalid RFC7231 date-time value ${e}.`)};function kn(e,t,n){let r=Number(e);if(rn)throw Error(`Value ${r} out of range [${t}, ${n}]`)}function An(e,t,n){if(n<=0||!Number.isInteger(n))throw Error(`Invalid number of delimiters (`+n+`) for splitEvery.`);let r=e.split(t);if(n===1)return r;let i=[],a=``;for(let e=0;e{let t=e.length,n=[],r=!1,i,a=0;for(let o=0;o{e=e.trim();let t=e.length;return t<2?e:(e[0]===`"`&&e[t-1]===`"`&&(e=e.slice(1,t-1)),e.replace(/\\"/g,`"`))})},Mn=/^-?\d*(\.\d+)?$/,Nn=class e{string;type;constructor(e,t){if(this.string=e,this.type=t,!Mn.test(e))throw Error(`@smithy/core/serde - NumericValue must only contain [0-9], at most one decimal point ".", and an optional negation prefix "-".`)}toString(){return this.string}static[Symbol.hasInstance](t){if(!t||typeof t!=`object`)return!1;let n=t;return e.prototype.isPrototypeOf(t)||n.type===`bigDecimal`&&Mn.test(n.string)}},Pn=class{serdeContext;setSerdeContext(e){this.serdeContext=e}},Fn=`modulepreload`,In=function(e){return`/`+e},Ln={},Rn=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}r=o(t.map(t=>{if(t=In(t,n),t in Ln)return;Ln[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:Fn,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},zn=class extends Pn{options;compositeErrorRegistry;constructor(e){super(),this.options=e,this.compositeErrorRegistry=At.for(e.defaultNamespace);for(let t of e.errorTypeRegistries??[])this.compositeErrorRegistry.copyFrom(t)}getRequestType(){return i}getResponseType(){return ge}setSerdeContext(e){this.serdeContext=e,this.serializer.setSerdeContext(e),this.deserializer.setSerdeContext(e),this.getPayloadCodec()&&this.getPayloadCodec().setSerdeContext(e)}updateServiceEndpoint(e,t){if(`url`in t){e.protocol=t.url.protocol,e.hostname=t.url.hostname,e.port=t.url.port?Number(t.url.port):void 0,e.path=t.url.pathname,e.fragment=t.url.hash||void 0,e.username=t.url.username||void 0,e.password=t.url.password||void 0,e.query||={};for(let[n,r]of t.url.searchParams.entries())e.query[n]=r;if(t.headers)for(let[n,r]of Object.entries(t.headers))e.headers[n]=r.join(`, `);return e}else{if(e.protocol=t.protocol,e.hostname=t.hostname,e.port=t.port?Number(t.port):void 0,e.path=t.path,e.query={...t.query},t.headers)for(let[n,r]of Object.entries(t.headers))e.headers[n]=r;return e}}setHostPrefix(e,t,n){if(this.serdeContext?.disableHostPrefix)return;let r=p.of(t.input),i=Ct(t.traits??{});if(i.endpoint){let t=i.endpoint?.[0];if(typeof t==`string`){let i=[...r.structIterator()].filter(([,e])=>e.getMergedTraits().hostLabel);for(let[e]of i){let r=n[e];if(typeof r!=`string`)throw Error(`@smithy/core/schema - ${e} in input must be a string as hostLabel.`);t=t.replace(`{${e}}`,r)}e.hostname=t+e.hostname}}}deserializeMetadata(e){return{httpStatusCode:e.statusCode,requestId:e.headers[`x-amzn-requestid`]??e.headers[`x-amzn-request-id`]??e.headers[`x-amz-request-id`],extendedRequestId:e.headers[`x-amz-id-2`],cfId:e.headers[`x-amz-cf-id`]}}async serializeEventStream({eventStream:e,requestSchema:t,initialRequest:n}){return(await this.loadEventStreamCapability()).serializeEventStream({eventStream:e,requestSchema:t,initialRequest:n})}async deserializeEventStream({response:e,responseSchema:t,initialResponseContainer:n}){return(await this.loadEventStreamCapability()).deserializeEventStream({response:e,responseSchema:t,initialResponseContainer:n})}async loadEventStreamCapability(){let{EventStreamSerde:e}=await Rn(async()=>{let{EventStreamSerde:e}=await import(`./event-streams.js`);return{EventStreamSerde:e}},__vite__mapDeps([0,1,2]));return new e({marshaller:this.getEventStreamMarshaller(),serializer:this.serializer,deserializer:this.deserializer,serdeContext:this.serdeContext,defaultContentType:this.getDefaultContentType()})}getDefaultContentType(){throw Error(`@smithy/core/protocols - ${this.constructor.name} getDefaultContentType() implementation missing.`)}async deserializeHttpMessage(e,t,n,r,i){return[]}getEventStreamMarshaller(){let e=this.serdeContext;if(!e.eventStreamMarshaller)throw Error(`@smithy/core - HttpProtocol: eventStreamMarshaller missing in serdeContext.`);return e.eventStreamMarshaller}},Bn=class extends zn{async serializeRequest(e,t,n){let r={...t??{}},a=this.serializer,o={},s={},c=await n.endpoint(),l=p.of(e?.input),u=[],d=[],ee=!1,te,f=new i({protocol:``,hostname:``,port:void 0,path:``,fragment:void 0,query:o,headers:s,body:void 0});if(c){this.updateServiceEndpoint(f,c),this.setHostPrefix(f,e,r);let t=Ct(e.traits);if(t.http){f.method=t.http[0];let[e,n]=t.http[1].split(`?`);f.path==`/`?f.path=e:f.path+=e;let r=new URLSearchParams(n??``);Object.assign(o,Object.fromEntries(r))}}for(let[e,t]of l.structIterator()){let n=t.getMergedTraits()??{},i=r[e];if(i==null&&!t.isIdempotencyToken()){if(n.httpLabel&&(f.path.includes(`{${e}+}`)||f.path.includes(`{${e}}`)))throw Error(`No value provided for input HTTP label: ${e}.`);continue}if(n.httpPayload)t.isStreaming()?t.isStructSchema()?r[e]&&(te=await this.serializeEventStream({eventStream:r[e],requestSchema:l})):te=i:(a.write(t,i),te=a.flush()),delete r[e];else if(n.httpLabel){a.write(t,i);let n=a.flush();f.path.includes(`{${e}+}`)?f.path=f.path.replace(`{${e}+}`,n.split(`/`).map(ut).join(`/`)):f.path.includes(`{${e}}`)&&(f.path=f.path.replace(`{${e}}`,ut(n))),delete r[e]}else if(n.httpHeader)a.write(t,i),s[n.httpHeader.toLowerCase()]=String(a.flush()),delete r[e];else if(typeof n.httpPrefixHeaders==`string`){for(let[e,r]of Object.entries(i)){let i=n.httpPrefixHeaders+e;a.write([t.getValueSchema(),{httpHeader:i}],r),s[i.toLowerCase()]=a.flush()}delete r[e]}else n.httpQuery||n.httpQueryParams?(this.serializeQuery(t,i,o),delete r[e]):(ee=!0,u.push(e),d.push(t))}if(ee&&r){let[e,t]=(l.getName(!0)??`#Unknown`).split(`#`),n=l.getSchema()[6],i=[3,e,t,l.getMergedTraits(),u,d,void 0];n?i[6]=n:i.pop(),a.write(i,r),te=a.flush()}return f.headers=s,f.query=o,f.body=te,f}serializeQuery(e,t,n){let r=this.serializer,i=e.getMergedTraits();if(i.httpQueryParams){for(let[r,a]of Object.entries(t))if(!(r in n)){let t=e.getValueSchema();Object.assign(t.getMergedTraits(),{...i,httpQuery:r,httpQueryParams:void 0}),this.serializeQuery(t,a,n)}return}if(e.isListSchema()){let a=!!e.getMergedTraits().sparse,o=[];for(let n of t){r.write([e.getValueSchema(),i],n);let t=r.flush();(a||t!==void 0)&&o.push(t)}n[i.httpQuery]=o}else r.write([e,i],t),n[i.httpQuery]=r.flush()}async deserializeResponse(e,t,n){let r=this.deserializer,i=p.of(e.output),a={};if(n.statusCode>=300){let i=await lt(n.body,t);throw i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n)),Error(`@smithy/core/protocols - HTTP Protocol error handler failed to throw.`)}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=await this.deserializeHttpMessage(i,t,n,a);if(o.length){let e=await lt(n.body,t);if(e.byteLength>0){let t=await r.read(i,e);for(let e of o)t[e]!=null&&(a[e]=t[e])}}else o.discardResponseBody&&await lt(n.body,t);return a.$metadata=this.deserializeMetadata(n),a}async deserializeHttpMessage(e,t,n,r,i){let a;a=r instanceof Set?i:r;let o=!0,s=this.deserializer,c=p.of(e),l=[];for(let[e,r]of c.structIterator()){let i=r.getMemberTraits();if(i.httpPayload){if(o=!1,r.isStreaming())r.isStructSchema()?a[e]=await this.deserializeEventStream({response:n,responseSchema:c}):a[e]=ot(n.body);else if(n.body){let i=await lt(n.body,t);i.byteLength>0&&(a[e]=await s.read(r,i))}}else if(i.httpHeader){let t=String(i.httpHeader).toLowerCase(),o=n.headers[t];if(o!=null)if(r.isListSchema()){let n=r.getValueSchema();n.getMergedTraits().httpHeader=t;let i;i=n.isTimestampSchema()&&n.getSchema()===4?An(o,`,`,2):jn(o);let c=[];for(let e of i)c.push(await s.read(n,e.trim()));a[e]=c}else a[e]=await s.read(r,o)}else if(i.httpPrefixHeaders!==void 0){a[e]={};for(let[t,o]of Object.entries(n.headers))if(t.startsWith(i.httpPrefixHeaders)){let n=r.getValueSchema();n.getMergedTraits().httpHeader=t,a[e][t.slice(i.httpPrefixHeaders.length)]=await s.read(n,o)}}else i.httpResponseCode?a[e]=n.statusCode:l.push(e)}return l.discardResponseBody=o,l}},Vn=class extends zn{async serializeRequest(e,t,n){let r=this.serializer,a={},o={},s=await n.endpoint(),c=p.of(e?.input),l=c.getSchema(),u,d=new i({protocol:``,hostname:``,port:void 0,path:`/`,fragment:void 0,query:a,headers:o,body:void 0});s&&(this.updateServiceEndpoint(d,s),this.setHostPrefix(d,e,t));let ee={...t};if(t){let e=c.getEventStreamMember();if(e){if(ee[e]){let t={};for(let[n,i]of c.structIterator())n!==e&&ee[n]&&(r.write(i,ee[n]),t[n]=r.flush());u=await this.serializeEventStream({eventStream:ee[e],requestSchema:c,initialRequest:t})}}else r.write(l,ee),u=r.flush()}return d.headers=Object.assign(d.headers,o),d.query=a,d.body=u,d.method=`POST`,d}async deserializeResponse(e,t,n){let r=this.deserializer,i=p.of(e.output),a={};if(n.statusCode>=300){let i=await lt(n.body,t);throw i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n)),Error(`@smithy/core/protocols - RPC Protocol error handler failed to throw.`)}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=i.getEventStreamMember();if(o)a[o]=await this.deserializeEventStream({response:n,responseSchema:i,initialResponseContainer:a});else{let e=await lt(n.body,t);e.byteLength>0&&Object.assign(a,await r.read(i,e))}return a.$metadata=this.deserializeMetadata(n),a}};function Hn(e,t){if(t.timestampFormat.useTrait&&e.isTimestampSchema()&&(e.getSchema()===5||e.getSchema()===6||e.getSchema()===7))return e.getSchema();let{httpLabel:n,httpPrefixHeaders:r,httpHeader:i,httpQuery:a}=e.getMergedTraits();return(t.httpBindings?typeof r==`string`||i?6:a||n?5:void 0:void 0)??t.timestampFormat.default}var Un=class extends Pn{settings;constructor(e){super(),this.settings=e}read(e,t){let n=p.of(e);if(n.isListSchema())return jn(t).map(e=>this.read(n.getValueSchema(),e));if(n.isBlobSchema())return(this.serdeContext?.base64Decoder??Ue)(t);if(n.isTimestampSchema())switch(Hn(n,this.settings)){case 5:return Dn(t);case 6:return On(t);case 7:return En(t);default:return console.warn(`Missing timestamp format, parsing value with Date constructor:`,t),new Date(t)}if(n.isStringSchema()){let e=n.getMergedTraits().mediaType,r=t;if(e)return n.getMergedTraits().httpHeader&&(r=this.base64ToUtf8(r)),(e===`application/json`||e.endsWith(`+json`))&&(r=mn.from(r)),r}return n.isNumericSchema()?Number(t):n.isBigIntegerSchema()?BigInt(t):n.isBigDecimalSchema()?new Nn(t,`bigDecimal`):n.isBooleanSchema()?String(t).toLowerCase()===`true`:t}base64ToUtf8(e){return(this.serdeContext?.utf8Encoder??ce)((this.serdeContext?.base64Decoder??Ue)(e))}},Wn=class extends Pn{codecDeserializer;stringDeserializer;constructor(e,t){super(),this.codecDeserializer=e,this.stringDeserializer=new Un(t)}setSerdeContext(e){this.stringDeserializer.setSerdeContext(e),this.codecDeserializer.setSerdeContext(e),this.serdeContext=e}read(e,t){let n=p.of(e),r=n.getMergedTraits(),i=this.serdeContext?.utf8Encoder??ce;if(r.httpHeader||r.httpResponseCode)return this.stringDeserializer.read(n,i(t));if(r.httpPayload){if(n.isBlobSchema()){let e=this.serdeContext?.utf8Decoder??se;return typeof t==`string`?e(t):t}else if(n.isStringSchema())return`byteLength`in t?i(t):t}return this.codecDeserializer.read(n,t)}},Gn=class extends Pn{settings;stringBuffer=``;constructor(e){super(),this.settings=e}write(e,t){let n=p.of(e);switch(typeof t){case`object`:if(t===null){this.stringBuffer=`null`;return}if(n.isTimestampSchema()){if(!(t instanceof Date))throw Error(`@smithy/core/protocols - received non-Date value ${t} when schema expected Date in ${n.getName(!0)}`);switch(Hn(n,this.settings)){case 5:this.stringBuffer=t.toISOString().replace(`.000Z`,`Z`);break;case 6:this.stringBuffer=Jt(t);break;case 7:this.stringBuffer=String(t.getTime()/1e3);break;default:console.warn(`Missing timestamp format, using epoch seconds`,t),this.stringBuffer=String(t.getTime()/1e3)}return}if(n.isBlobSchema()&&`byteLength`in t){this.stringBuffer=(this.serdeContext?.base64Encoder??We)(t);return}if(n.isListSchema()&&Array.isArray(t)){let e=``;for(let r of t){this.write([n.getValueSchema(),n.getMergedTraits()],r);let t=this.flush(),i=n.getValueSchema().isTimestampSchema()?t:hn(t);e!==``&&(e+=`, `),e+=i}this.stringBuffer=e;return}this.stringBuffer=JSON.stringify(t,null,2);break;case`string`:let e=n.getMergedTraits().mediaType,r=t;if(e&&((e===`application/json`||e.endsWith(`+json`))&&(r=mn.from(r)),n.getMergedTraits().httpHeader)){this.stringBuffer=(this.serdeContext?.base64Encoder??We)(r.toString());return}this.stringBuffer=t;break;default:n.isIdempotencyToken()?this.stringBuffer=pn():this.stringBuffer=String(t)}}flush(){let e=this.stringBuffer;return this.stringBuffer=``,e}},Kn=class{codecSerializer;stringSerializer;buffer;constructor(e,t,n=new Gn(t)){this.codecSerializer=e,this.stringSerializer=n}setSerdeContext(e){this.codecSerializer.setSerdeContext(e),this.stringSerializer.setSerdeContext(e)}write(e,t){let n=p.of(e),r=n.getMergedTraits();if(r.httpHeader||r.httpLabel||r.httpQuery){this.stringSerializer.write(n,t),this.buffer=this.stringSerializer.flush();return}return this.codecSerializer.write(n,t)}flush(){if(this.buffer!==void 0){let e=this.buffer;return this.buffer=void 0,e}return this.codecSerializer.flush()}};function qn(e,t,n){e.__smithy_context?e.__smithy_context.features||(e.__smithy_context.features={}):e.__smithy_context={features:{}},e.__smithy_context.features[t]=n}var Jn=class{authSchemes=new Map;constructor(e){for(let[t,n]of Object.entries(e))n!==void 0&&this.authSchemes.set(t,n)}getIdentityProvider(e){return this.authSchemes.get(e)}},Yn=(e=>function(t){return Xn(t)&&t.expiration.getTime()-Date.now()e.expiration!==void 0,Zn=(e,t,n)=>{if(e===void 0)return;let r=typeof e==`function`?e:async()=>Promise.resolve(e),i,a,o,s=!1,c=async e=>{a||=r(e);try{i=await a,o=!0,s=!1}finally{a=void 0}return i};return t===void 0?async e=>((!o||e?.forceRefresh)&&(i=await c(e)),i):async e=>((!o||e?.forceRefresh)&&(i=await c(e)),s?i:n(i)?(t(i)&&await c(e),i):(s=!0,i))};function Qn(e){return e===void 0?!0:typeof e==`string`&&e.length<=50}function $n(e){let t=ze(e.userAgentAppId??void 0),{customUserAgent:n}=e;return Object.assign(e,{customUserAgent:typeof n==`string`?[[n]]:n,userAgentAppId:async()=>{let n=await t();if(!Qn(n)){let t=e.logger?.constructor?.name===`NoOpLogger`||!e.logger?console:e.logger;typeof n==`string`?n.length>50&&t?.warn(`The provided userAgentAppId exceeds the maximum length of 50 characters.`):t?.warn(`userAgentAppId must be a string or undefined.`)}return n}})}var er=class{capacity;data=new Map;parameters=[];constructor({size:e,params:t}){this.capacity=e??50,t&&(this.parameters=t)}get(e,t){let n=this.hash(e);if(n===!1)return t();if(!this.data.has(n)){if(this.data.size>this.capacity+10){let e=this.data.keys(),t=0;for(;;){let{value:n,done:r}=e.next();if(this.data.delete(n),r||++t>10)break}}this.data.set(n,t())}return this.data.get(n)}size(){return this.data.size}hash(e){let t=``,{parameters:n}=this;if(n.length===0)return!1;for(let r of n){let n=String(e[r]??``);if(n.includes(`|;`))return!1;t+=n+`|;`}return t}},tr=RegExp(`^(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}$`),nr=e=>tr.test(e)||e.startsWith(`[`)&&e.endsWith(`]`),rr=RegExp(`^(?!.*-$)(?!-)[a-zA-Z0-9-]{1,63}$`),ir=(e,t=!1)=>{if(!t)return rr.test(e);let n=e.split(`.`);for(let e of n)if(!ir(e))return!1;return!0},ar={},or=`endpoints`;function sr(e){return typeof e!=`object`||!e?e:`ref`in e?`$${sr(e.ref)}`:`fn`in e?`${e.fn}(${(e.argv||[]).map(sr).join(`, `)})`:JSON.stringify(e,null,2)}var cr=class extends Error{constructor(e){super(e),this.name=`EndpointError`}},lr=(e,t)=>e===t,ur=e=>{let t=e.split(`.`),n=[];for(let r of t){let t=r.indexOf(`[`);if(t!==-1){if(r.indexOf(`]`)!==r.length-1)throw new cr(`Path: '${e}' does not end with ']'`);let i=r.slice(t+1,-1);if(Number.isNaN(parseInt(i)))throw new cr(`Invalid array index: '${i}' in path: '${e}'`);t!==0&&n.push(r.slice(0,t)),n.push(i)}else n.push(r)}return n},dr=(e,t)=>ur(t).reduce((n,r)=>{if(typeof n!=`object`)throw new cr(`Index '${r}' in '${t}' not found in '${JSON.stringify(e)}'`);return Array.isArray(n)?n[parseInt(r)]:n[r]},e),fr=e=>e!=null,pr=e=>!e,mr={[pe.HTTP]:80,[pe.HTTPS]:443},hr={booleanEquals:lr,getAttr:dr,isSet:fr,isValidHostLabel:ir,not:pr,parseURL:e=>{let t=(()=>{try{if(e instanceof URL)return e;if(typeof e==`object`&&`hostname`in e){let{hostname:t,port:n,protocol:r=``,path:i=``,query:a={}}=e,o=new URL(`${r}//${t}${n?`:${n}`:``}${i}`);return o.search=Object.entries(a).map(([e,t])=>`${e}=${t}`).join(`&`),o}return new URL(e)}catch{return null}})();if(!t)return console.error(`Unable to parse ${JSON.stringify(e)} as a whatwg URL.`),null;let n=t.href,{host:r,hostname:i,pathname:a,protocol:o,search:s}=t;if(s)return null;let c=o.slice(0,-1);if(!Object.values(pe).includes(c))return null;let l=nr(i);return{scheme:c,authority:`${r}${n.includes(`${r}:${mr[c]}`)||typeof e==`string`&&e.includes(`${r}:${mr[c]}`)?`:${mr[c]}`:``}`,path:a,normalizedPath:a.endsWith(`/`)?a:`${a}/`,isIp:l}},stringEquals:(e,t)=>e===t,substring:(e,t,n,r)=>t>=n||e.lengthencodeURIComponent(e).replace(/[!*'()]/g,e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`)},gr=(e,t)=>{let n=[],r={...t.endpointParams,...t.referenceRecord},i=0;for(;i({...t.endpointParams,...t.referenceRecord})[e],vr=(e,t,n)=>{if(typeof e==`string`)return gr(e,n);if(e.fn)return br.callFunction(e,n);if(e.ref)return _r(e,n);throw new cr(`'${t}': ${String(e)} is not a string, function or reference.`)},yr=({fn:e,argv:t},n)=>{let r=t.map(e=>[`boolean`,`number`].includes(typeof e)?e:br.evaluateExpression(e,`arg`,n)),i=e.split(`.`);return i[0]in ar&&i[1]!=null?ar[i[0]][i[1]](...r):hr[e](...r)},br={evaluateExpression:vr,callFunction:yr},xr=({assign:e,...t},n)=>{if(e&&e in n.referenceRecord)throw new cr(`'${e}' is already defined in Reference Record.`);let r=yr(t,n);return n.logger?.debug?.(`${or} evaluateCondition: ${sr(t)} = ${sr(r)}`),{result:r===``?!0:!!r,...e!=null&&{toAssign:{name:e,value:r}}}},Sr=(e=[],t)=>{let n={};for(let r of e){let{result:e,toAssign:i}=xr(r,{...t,referenceRecord:{...t.referenceRecord,...n}});if(!e)return{result:e};i&&(n[i.name]=i.value,t.logger?.debug?.(`${or} assign: ${i.name} := ${sr(i.value)}`))}return{result:!0,referenceRecord:n}},Cr=(e,t)=>Object.entries(e).reduce((e,[n,r])=>({...e,[n]:r.map(e=>{let r=vr(e,`Header value entry`,t);if(typeof r!=`string`)throw new cr(`Header '${n}' value '${r}' is not a string`);return r})}),{}),wr=(e,t)=>Object.entries(e).reduce((e,[n,r])=>({...e,[n]:Er.getEndpointProperty(r,t)}),{}),Tr=(e,t)=>{if(Array.isArray(e))return e.map(e=>Tr(e,t));switch(typeof e){case`string`:return gr(e,t);case`object`:if(e===null)throw new cr(`Unexpected endpoint property: ${e}`);return Er.getEndpointProperties(e,t);case`boolean`:return e;default:throw new cr(`Unexpected endpoint property type: ${typeof e}`)}},Er={getEndpointProperty:Tr,getEndpointProperties:wr},Dr=(e,t)=>{let n=vr(e,`Endpoint URL`,t);if(typeof n==`string`)try{return new URL(n)}catch(e){throw console.error(`Failed to construct URL with ${n}`,e),e}throw new cr(`Endpoint URL must be a string, got ${typeof n}`)},Or=(e,t)=>{let{conditions:n,endpoint:r}=e,{result:i,referenceRecord:a}=Sr(n,t);if(!i)return;let o={...t,referenceRecord:{...t.referenceRecord,...a}},{url:s,properties:c,headers:l}=r;return t.logger?.debug?.(`${or} Resolving endpoint from template: ${sr(r)}`),{...l!=null&&{headers:Cr(l,o)},...c!=null&&{properties:wr(c,o)},url:Dr(s,o)}},kr=(e,t)=>{let{conditions:n,error:r}=e,{result:i,referenceRecord:a}=Sr(n,t);if(i)throw new cr(vr(r,`Error`,{...t,referenceRecord:{...t.referenceRecord,...a}}))},Ar=(e,t)=>{for(let n of e)if(n.type===`endpoint`){let e=Or(n,t);if(e)return e}else if(n.type===`error`)kr(n,t);else if(n.type===`tree`){let e=jr.evaluateTreeRule(n,t);if(e)return e}else throw new cr(`Unknown endpoint rule: ${n}`);throw new cr(`Rules evaluation failed`)},jr={evaluateRules:Ar,evaluateTreeRule:(e,t)=>{let{conditions:n,rules:r}=e,{result:i,referenceRecord:a}=Sr(n,t);if(i)return jr.evaluateRules(r,{...t,referenceRecord:{...t.referenceRecord,...a}})}},Mr=(e,t)=>{let{endpointParams:n,logger:r}=t,{parameters:i,rules:a}=e;t.logger?.debug?.(`${or} Initial EndpointParams: ${sr(n)}`);let o=Object.entries(i).filter(([,e])=>e.default!=null).map(([e,t])=>[e,t.default]);if(o.length>0)for(let[e,t]of o)n[e]=n[e]??t;let s=Object.entries(i).filter(([,e])=>e.required).map(([e])=>e);for(let e of s)if(n[e]==null)throw new cr(`Missing required parameter: '${e}'`);let c=Ar(a,{endpointParams:n,logger:r,referenceRecord:{}});return t.logger?.debug?.(`${or} Resolved endpoint: ${sr(c)}`),c},Nr=(e,t=!1)=>{if(t){for(let t of e.split(`.`))if(!Nr(t))return!1;return!0}return!(!ir(e)||e.length<3||e.length>63||e!==e.toLowerCase()||nr(e))},Pr=`:`,Fr=`/`,Ir=e=>{let t=e.split(Pr);if(t.length<6)return null;let[n,r,i,a,o,...s]=t;return n!==`arn`||r===``||i===``||s.join(Pr)===``?null:{partition:r,service:i,region:a,accountId:o,resourceId:s.map(e=>e.split(Fr)).flat()}},Lr={partitions:[{id:`aws`,outputs:{dnsSuffix:`amazonaws.com`,dualStackDnsSuffix:`api.aws`,implicitGlobalRegion:`us-east-1`,name:`aws`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^(us|eu|ap|sa|ca|me|af|il|mx)\\-\\w+\\-\\d+$`,regions:{"af-south-1":{description:`Africa (Cape Town)`},"ap-east-1":{description:`Asia Pacific (Hong Kong)`},"ap-east-2":{description:`Asia Pacific (Taipei)`},"ap-northeast-1":{description:`Asia Pacific (Tokyo)`},"ap-northeast-2":{description:`Asia Pacific (Seoul)`},"ap-northeast-3":{description:`Asia Pacific (Osaka)`},"ap-south-1":{description:`Asia Pacific (Mumbai)`},"ap-south-2":{description:`Asia Pacific (Hyderabad)`},"ap-southeast-1":{description:`Asia Pacific (Singapore)`},"ap-southeast-2":{description:`Asia Pacific (Sydney)`},"ap-southeast-3":{description:`Asia Pacific (Jakarta)`},"ap-southeast-4":{description:`Asia Pacific (Melbourne)`},"ap-southeast-5":{description:`Asia Pacific (Malaysia)`},"ap-southeast-6":{description:`Asia Pacific (New Zealand)`},"ap-southeast-7":{description:`Asia Pacific (Thailand)`},"aws-global":{description:`aws global region`},"ca-central-1":{description:`Canada (Central)`},"ca-west-1":{description:`Canada West (Calgary)`},"eu-central-1":{description:`Europe (Frankfurt)`},"eu-central-2":{description:`Europe (Zurich)`},"eu-north-1":{description:`Europe (Stockholm)`},"eu-south-1":{description:`Europe (Milan)`},"eu-south-2":{description:`Europe (Spain)`},"eu-west-1":{description:`Europe (Ireland)`},"eu-west-2":{description:`Europe (London)`},"eu-west-3":{description:`Europe (Paris)`},"il-central-1":{description:`Israel (Tel Aviv)`},"me-central-1":{description:`Middle East (UAE)`},"me-south-1":{description:`Middle East (Bahrain)`},"mx-central-1":{description:`Mexico (Central)`},"sa-east-1":{description:`South America (Sao Paulo)`},"us-east-1":{description:`US East (N. Virginia)`},"us-east-2":{description:`US East (Ohio)`},"us-west-1":{description:`US West (N. California)`},"us-west-2":{description:`US West (Oregon)`}}},{id:`aws-cn`,outputs:{dnsSuffix:`amazonaws.com.cn`,dualStackDnsSuffix:`api.amazonwebservices.com.cn`,implicitGlobalRegion:`cn-northwest-1`,name:`aws-cn`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^cn\\-\\w+\\-\\d+$`,regions:{"aws-cn-global":{description:`aws-cn global region`},"cn-north-1":{description:`China (Beijing)`},"cn-northwest-1":{description:`China (Ningxia)`}}},{id:`aws-eusc`,outputs:{dnsSuffix:`amazonaws.eu`,dualStackDnsSuffix:`api.amazonwebservices.eu`,implicitGlobalRegion:`eusc-de-east-1`,name:`aws-eusc`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^eusc\\-(de)\\-\\w+\\-\\d+$`,regions:{"eusc-de-east-1":{description:`AWS European Sovereign Cloud (Germany)`}}},{id:`aws-iso`,outputs:{dnsSuffix:`c2s.ic.gov`,dualStackDnsSuffix:`api.aws.ic.gov`,implicitGlobalRegion:`us-iso-east-1`,name:`aws-iso`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^us\\-iso\\-\\w+\\-\\d+$`,regions:{"aws-iso-global":{description:`aws-iso global region`},"us-iso-east-1":{description:`US ISO East`},"us-iso-west-1":{description:`US ISO WEST`}}},{id:`aws-iso-b`,outputs:{dnsSuffix:`sc2s.sgov.gov`,dualStackDnsSuffix:`api.aws.scloud`,implicitGlobalRegion:`us-isob-east-1`,name:`aws-iso-b`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^us\\-isob\\-\\w+\\-\\d+$`,regions:{"aws-iso-b-global":{description:`aws-iso-b global region`},"us-isob-east-1":{description:`US ISOB East (Ohio)`},"us-isob-west-1":{description:`US ISOB West`}}},{id:`aws-iso-e`,outputs:{dnsSuffix:`cloud.adc-e.uk`,dualStackDnsSuffix:`api.cloud-aws.adc-e.uk`,implicitGlobalRegion:`eu-isoe-west-1`,name:`aws-iso-e`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^eu\\-isoe\\-\\w+\\-\\d+$`,regions:{"aws-iso-e-global":{description:`aws-iso-e global region`},"eu-isoe-west-1":{description:`EU ISOE West`}}},{id:`aws-iso-f`,outputs:{dnsSuffix:`csp.hci.ic.gov`,dualStackDnsSuffix:`api.aws.hci.ic.gov`,implicitGlobalRegion:`us-isof-south-1`,name:`aws-iso-f`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^us\\-isof\\-\\w+\\-\\d+$`,regions:{"aws-iso-f-global":{description:`aws-iso-f global region`},"us-isof-east-1":{description:`US ISOF EAST`},"us-isof-south-1":{description:`US ISOF SOUTH`}}},{id:`aws-us-gov`,outputs:{dnsSuffix:`amazonaws.com`,dualStackDnsSuffix:`api.aws`,implicitGlobalRegion:`us-gov-west-1`,name:`aws-us-gov`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^us\\-gov\\-\\w+\\-\\d+$`,regions:{"aws-us-gov-global":{description:`aws-us-gov global region`},"us-gov-east-1":{description:`AWS GovCloud (US-East)`},"us-gov-west-1":{description:`AWS GovCloud (US-West)`}}}],version:`1.1`},Rr=``,zr=e=>{let{partitions:t}=Lr;for(let n of t){let{regions:t,outputs:r}=n;for(let[n,i]of Object.entries(t))if(n===e)return{...r,...i}}for(let n of t){let{regionRegex:t,outputs:r}=n;if(new RegExp(t).test(e))return{...r}}let n=t.find(e=>e.id===`aws`);if(!n)throw Error(`Provided region was not found in the partition array or regex, and default partition with id 'aws' doesn't exist.`);return{...n.outputs}},Br=()=>Rr,Vr={isVirtualHostableS3Bucket:Nr,parseArn:Ir,partition:zr};ar.aws=Vr;function Hr(e,t,n){return e.$source||={},e.$source[t]=n,e}function Ur(e,t,n){e.__aws_sdk_context?e.__aws_sdk_context.features||(e.__aws_sdk_context.features={}):e.__aws_sdk_context={features:{}},e.__aws_sdk_context.features[t]=n}var Wr=e=>ge.isInstance(e)?e.headers?.date??e.headers?.Date:void 0,Gr=e=>new Date(Date.now()+e),Kr=(e,t)=>Math.abs(Gr(t).getTime()-e)>=3e5,qr=(e,t)=>{let n=Date.parse(e);return Kr(n,t)?n-Date.now():t},Jr=(e,t)=>{if(!t)throw Error(`Property \`${e}\` is not resolved for AWS SDK SigV4Auth`);return t},Yr=async e=>{let t=Jr(`context`,e.context),n=Jr(`config`,e.config),r=t.endpointV2?.properties?.authSchemes?.[0];return{config:n,signer:await Jr(`signer`,n.signer)(r),signingRegion:e?.signingRegion,signingRegionSet:e?.signingRegionSet,signingName:e?.signingName}},Xr=class{async sign(e,t,n){if(!i.isInstance(e))throw Error("The request is not an instance of `HttpRequest` and cannot be signed");let r=await Yr(n),{config:a,signer:o}=r,{signingRegion:s,signingName:c}=r,l=n.context;if(l?.authSchemes?.length??!1){let[e,t]=l.authSchemes;e?.name===`sigv4a`&&t?.name===`sigv4`&&(s=t?.signingRegion??s,c=t?.signingName??c)}return await o.sign(e,{signingDate:Gr(a.systemClockOffset),signingRegion:s,signingService:c})}errorHandler(e){return t=>{let n=t.ServerTime??Wr(t.$response);if(n){let r=Jr(`config`,e.config),i=r.systemClockOffset;r.systemClockOffset=qr(n,r.systemClockOffset),r.systemClockOffset!==i&&t.$metadata&&(t.$metadata.clockSkewCorrected=!0)}throw t}}successHandler(e,t){let n=Wr(e);if(n){let e=Jr(`config`,t.config);e.systemClockOffset=qr(n,e.systemClockOffset)}}},Zr=class extends Xr{async sign(e,t,n){if(!i.isInstance(e))throw Error("The request is not an instance of `HttpRequest` and cannot be signed");let{config:r,signer:a,signingRegion:o,signingRegionSet:s,signingName:c}=await Yr(n),l=(await r.sigv4aSigningRegionSet?.()??s??[o]).join(`,`);return await a.sign(e,{signingDate:Gr(r.systemClockOffset),signingRegion:l,signingService:c})}},Qr=(e,t,n)=>{let r,i,a,o=!1,s=async()=>{i||=e();try{r=await i,a=!0,o=!1}finally{i=void 0}return r};return t===void 0?async e=>((!a||e?.forceRefresh)&&(r=await s()),r):async e=>((!a||e?.forceRefresh)&&(r=await s()),o?r:n&&!n(r)?(o=!0,r):(t(r)&&await s(),r))},$r=e=>(e.sigv4aSigningRegionSet=ze(e.sigv4aSigningRegionSet),e),ei=e=>{let t=e.credentials,n=!!e.credentials,r;Object.defineProperty(e,`credentials`,{set(i){i&&i!==t&&i!==r&&(n=!0),t=i;let a=ni(e,ti(e,{credentials:t,credentialDefaultProvider:e.credentialDefaultProvider}));if(n&&!a.attributed){let e=typeof t==`object`&&!!t;r=async t=>{let n=await a(t);return e&&(!n.$source||Object.keys(n.$source).length===0)?Hr(n,`CREDENTIALS_CODE`,`e`):n},r.memoized=a.memoized,r.configBound=a.configBound,r.attributed=!0}else r=a},get(){return r},enumerable:!0,configurable:!0}),e.credentials=t;let{signingEscapePath:i=!0,systemClockOffset:a=e.systemClockOffset||0,sha256:o}=e,s;return s=e.signer?ze(e.signer):e.regionInfoProvider?()=>ze(e.region)().then(async t=>[await e.regionInfoProvider(t,{useFipsEndpoint:await e.useFipsEndpoint(),useDualstackEndpoint:await e.useDualstackEndpoint()})||{},t]).then(([t,n])=>{let{signingRegion:r,signingService:a}=t;e.signingRegion=e.signingRegion||r||n,e.signingName=e.signingName||a||e.serviceId;let s={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:o,uriEscapePath:i};return new(e.signerConstructor||re)(s)}):async t=>{t=Object.assign({},{name:`sigv4`,signingName:e.signingName||e.defaultSigningName,signingRegion:await ze(e.region)(),properties:{}},t);let n=t.signingRegion,r=t.signingName;e.signingRegion=e.signingRegion||n,e.signingName=e.signingName||r||e.serviceId;let a={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:o,uriEscapePath:i};return new(e.signerConstructor||re)(a)},Object.assign(e,{systemClockOffset:a,signingEscapePath:i,signer:s})};function ti(e,{credentials:t,credentialDefaultProvider:n}){let r;return r=t?t?.memoized?t:Zn(t,Yn,Xn):n?ze(n(Object.assign({},e,{parentClientConfig:e}))):async()=>{throw Error("@aws-sdk/core::resolveAwsSdkSigV4Config - `credentials` not provided and no credentialDefaultProvider was configured.")},r.memoized=!0,r}function ni(e,t){if(t.configBound)return t;let n=async n=>t({...n,callerClientConfig:e});return n.memoized=t.memoized,n.configBound=!0,n}var ri=typeof TextEncoder==`function`?new TextEncoder:null,ii=e=>{if(typeof e==`string`){if(ri)return ri.encode(e).byteLength;let t=e.length;for(let n=t-1;n>=0;n--){let r=e.charCodeAt(n);r>127&&r<=2047?t++:r>2047&&r<=65535&&(t+=2),r>=56320&&r<=57343&&n--}return t}else if(typeof e.byteLength==`number`)return e.byteLength;else if(typeof e.size==`number`)return e.size;throw Error(`Body Length computation failed for ${e}`)},ai=(e,t)=>{let n=[];if(e&&n.push(e),t)for(let e of t)n.push(e);return n},oi=(e,t)=>`${e||`anonymous`}${t&&t.length>0?` (a.k.a. ${t.join(`,`)})`:``}`,si=()=>{let e=[],t=[],n=!1,r=new Set,i=e=>e.sort((e,t)=>ci[t.step]-ci[e.step]||li[t.priority||`normal`]-li[e.priority||`normal`]),a=n=>{let i=!1,a=e=>{let t=ai(e.name,e.aliases);if(t.includes(n)){i=!0;for(let e of t)r.delete(e);return!1}return!0};return e=e.filter(a),t=t.filter(a),i},o=n=>{let i=!1,a=e=>{if(e.middleware===n){i=!0;for(let t of ai(e.name,e.aliases))r.delete(t);return!1}return!0};return e=e.filter(a),t=t.filter(a),i},s=n=>(e.forEach(e=>{n.add(e.middleware,{...e})}),t.forEach(e=>{n.addRelativeTo(e.middleware,{...e})}),n.identifyOnResolve?.(u.identifyOnResolve()),n),c=e=>{let t=[];return e.before.forEach(e=>{e.before.length===0&&e.after.length===0?t.push(e):t.push(...c(e))}),t.push(e),e.after.reverse().forEach(e=>{e.before.length===0&&e.after.length===0?t.push(e):t.push(...c(e))}),t},l=(n=!1)=>{let r=[],a=[],o={};return e.forEach(e=>{let t={...e,before:[],after:[]};for(let e of ai(t.name,t.aliases))o[e]=t;r.push(t)}),t.forEach(e=>{let t={...e,before:[],after:[]};for(let e of ai(t.name,t.aliases))o[e]=t;a.push(t)}),a.forEach(e=>{if(e.toMiddleware){let t=o[e.toMiddleware];if(t===void 0){if(n)return;throw Error(`${e.toMiddleware} is not found when adding ${oi(e.name,e.aliases)} middleware ${e.relation} ${e.toMiddleware}`)}e.relation===`after`&&t.after.push(e),e.relation===`before`&&t.before.push(e)}}),i(r).map(c).reduce((e,t)=>(e.push(...t),e),[])},u={add:(t,n={})=>{let{name:i,override:a,aliases:o}=n,s={step:`initialize`,priority:`normal`,middleware:t,...n},c=ai(i,o);if(c.length>0){if(c.some(e=>r.has(e))){if(!a)throw Error(`Duplicate middleware name '${oi(i,o)}'`);for(let t of c){let n=e.findIndex(e=>e.name===t||e.aliases?.some(e=>e===t));if(n===-1)continue;let r=e[n];if(r.step!==s.step||s.priority!==r.priority)throw Error(`"${oi(r.name,r.aliases)}" middleware with ${r.priority} priority in ${r.step} step cannot be overridden by "${oi(i,o)}" middleware with ${s.priority} priority in ${s.step} step.`);e.splice(n,1)}}for(let e of c)r.add(e)}e.push(s)},addRelativeTo:(e,n)=>{let{name:i,override:a,aliases:o}=n,s={middleware:e,...n},c=ai(i,o);if(c.length>0){if(c.some(e=>r.has(e))){if(!a)throw Error(`Duplicate middleware name '${oi(i,o)}'`);for(let e of c){let n=t.findIndex(t=>t.name===e||t.aliases?.some(t=>t===e));if(n===-1)continue;let r=t[n];if(r.toMiddleware!==s.toMiddleware||r.relation!==s.relation)throw Error(`"${oi(r.name,r.aliases)}" middleware ${r.relation} "${r.toMiddleware}" middleware cannot be overridden by "${oi(i,o)}" middleware ${s.relation} "${s.toMiddleware}" middleware.`);t.splice(n,1)}}for(let e of c)r.add(e)}t.push(s)},clone:()=>s(si()),use:e=>{e.applyToStack(u)},remove:e=>typeof e==`string`?a(e):o(e),removeByTag:n=>{let i=!1,a=e=>{let{tags:t,name:a,aliases:o}=e;if(t&&t.includes(n)){let e=ai(a,o);for(let t of e)r.delete(t);return i=!0,!1}return!0};return e=e.filter(a),t=t.filter(a),i},concat:e=>{let t=s(si());return t.use(e),t.identifyOnResolve(n||t.identifyOnResolve()||(e.identifyOnResolve?.()??!1)),t},applyToStack:s,identify:()=>l(!0).map(e=>{let t=e.step??e.relation+` `+e.toMiddleware;return oi(e.name,e.aliases)+` - `+t}),identifyOnResolve(e){return typeof e==`boolean`&&(n=e),n},resolve:(e,t)=>{for(let n of l().map(e=>e.middleware).reverse())e=n(e,t);return n&&console.log(u.identify()),e}};return u},ci={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},li={high:3,normal:2,low:1},ui=class{config;middlewareStack=si();initConfig;handlers;constructor(e){this.config=e;let{protocol:t,protocolSettings:n}=e;n&&typeof t==`function`&&(e.protocol=new t(n))}send(e,t,n){let r=typeof t==`function`?void 0:t,i=typeof t==`function`?t:n,a=r===void 0&&this.config.cacheMiddleware===!0,o;if(a){this.handlers||=new WeakMap;let t=this.handlers;t.has(e.constructor)?o=t.get(e.constructor):(o=e.resolveMiddleware(this.middlewareStack,this.config,r),t.set(e.constructor,o))}else delete this.handlers,o=e.resolveMiddleware(this.middlewareStack,this.config,r);if(i)o(e).then(e=>i(null,e.output),e=>i(e)).catch(()=>{});else return o(e).then(e=>e.output)}destroy(){this.config?.requestHandler?.destroy?.(),delete this.handlers}},di=`***SensitiveInformation***`;function fi(e,t){if(t==null)return t;let n=p.of(e);if(n.getMergedTraits().sensitive)return di;if(n.isListSchema()){if(n.getValueSchema().getMergedTraits().sensitive)return di}else if(n.isMapSchema()){if(n.getKeySchema().getMergedTraits().sensitive||n.getValueSchema().getMergedTraits().sensitive)return di}else if(n.isStructSchema()&&typeof t==`object`){let e=t,r={};for(let[t,i]of n.structIterator())e[t]!=null&&(r[t]=fi(i,e[t]));return r}return t}var pi=class{middlewareStack=si();schema;static classBuilder(){return new mi}resolveMiddlewareWithContext(e,t,n,{middlewareFn:r,clientName:i,commandName:a,inputFilterSensitiveLog:o,outputFilterSensitiveLog:s,smithyContext:c,additionalContext:l,CommandCtor:u}){for(let i of r.bind(this)(u,e,t,n))this.middlewareStack.use(i);let d=e.concat(this.middlewareStack),{logger:ee}=t,te={logger:ee,clientName:i,commandName:a,inputFilterSensitiveLog:o,outputFilterSensitiveLog:s,[he]:{commandInstance:this,...c},...l},{requestHandler:f}=t;return d.resolve(e=>f.handle(e.request,n||{}),te)}},mi=class{_init=()=>{};_ep={};_middlewareFn=()=>[];_commandName=``;_clientName=``;_additionalContext={};_smithyContext={};_inputFilterSensitiveLog=void 0;_outputFilterSensitiveLog=void 0;_serializer=null;_deserializer=null;_operationSchema;init(e){this._init=e}ep(e){return this._ep=e,this}m(e){return this._middlewareFn=e,this}s(e,t,n={}){return this._smithyContext={service:e,operation:t,...n},this}c(e={}){return this._additionalContext=e,this}n(e,t){return this._clientName=e,this._commandName=t,this}f(e=e=>e,t=e=>e){return this._inputFilterSensitiveLog=e,this._outputFilterSensitiveLog=t,this}ser(e){return this._serializer=e,this}de(e){return this._deserializer=e,this}sc(e){return this._operationSchema=e,this._smithyContext.operationSchema=e,this}build(){let e=this,t;return t=class extends pi{input;static getEndpointParameterInstructions(){return e._ep}constructor(...[t]){super(),this.input=t??{},e._init(this),this.schema=e._operationSchema}resolveMiddleware(n,r,i){let a=e._operationSchema,o=a?.[4]??a?.input,s=a?.[5]??a?.output;return this.resolveMiddlewareWithContext(n,r,i,{CommandCtor:t,middlewareFn:e._middlewareFn,clientName:e._clientName,commandName:e._commandName,inputFilterSensitiveLog:e._inputFilterSensitiveLog??(a?fi.bind(null,o):e=>e),outputFilterSensitiveLog:e._outputFilterSensitiveLog??(a?fi.bind(null,s):e=>e),smithyContext:e._smithyContext,additionalContext:e._additionalContext})}serialize=e._serializer;deserialize=e._deserializer}}},hi=class e extends Error{$fault;$response;$retryable;$metadata;constructor(e){super(e.message),Object.setPrototypeOf(this,Object.getPrototypeOf(this).constructor.prototype),this.name=e.name,this.$fault=e.$fault,this.$metadata=e.$metadata}static isInstance(t){if(!t)return!1;let n=t;return e.prototype.isPrototypeOf(n)||!!n.$fault&&!!n.$metadata&&(n.$fault===`client`||n.$fault===`server`)}static[Symbol.hasInstance](t){if(!t)return!1;let n=t;return this===e?e.isInstance(t):e.isInstance(t)?n.name&&this.name?this.prototype.isPrototypeOf(t)||n.name===this.name:this.prototype.isPrototypeOf(t):!1}},gi=(e,t={})=>(Object.entries(t).filter(([,e])=>e!==void 0).forEach(([t,n])=>{(e[t]==null||e[t]===``)&&(e[t]=n)}),e.message=e.message||e.Message||`UnknownError`,delete e.Message,e),_i=e=>{switch(e){case`standard`:return{retryMode:`standard`,connectionTimeout:3100};case`in-region`:return{retryMode:`standard`,connectionTimeout:1100};case`cross-region`:return{retryMode:`standard`,connectionTimeout:3100};case`mobile`:return{retryMode:`standard`,connectionTimeout:3e4};default:return{}}},vi=Object.values(me),yi=e=>{let t=[];for(let n in me){let r=me[n];e[r]!==void 0&&t.push({algorithmId:()=>r,checksumConstructor:()=>e[r]})}for(let[n,r]of Object.entries(e.checksumAlgorithms??{}))t.push({algorithmId:()=>n,checksumConstructor:()=>r});return{addChecksumAlgorithm(n){e.checksumAlgorithms=e.checksumAlgorithms??{};let r=n.algorithmId(),i=n.checksumConstructor();vi.includes(r)?e.checksumAlgorithms[r.toUpperCase()]=i:e.checksumAlgorithms[r]=i,t.push(n)},checksumAlgorithms(){return t}}},bi=e=>{let t={};return e.checksumAlgorithms().forEach(e=>{let n=e.algorithmId();vi.includes(n)&&(t[n]=e.checksumConstructor())}),t},xi=e=>({setRetryStrategy(t){e.retryStrategy=t},retryStrategy(){return e.retryStrategy}}),Si=e=>{let t={};return t.retryStrategy=e.retryStrategy(),t},Ci=e=>Object.assign(yi(e),xi(e)),wi=e=>Object.assign(bi(e),Si(e)),Ti=e=>{let t=`#text`;for(let n in e)e.hasOwnProperty(n)&&e[n][t]!==void 0?e[n]=e[n][t]:typeof e[n]==`object`&&e[n]!==null&&(e[n]=Ti(e[n]));return e},Ei=class{trace(){}debug(){}info(){}warn(){}error(){}},Di=class{queryCompat;errorRegistry;constructor(e=!1){this.queryCompat=e}resolveRestContentType(e,t){let n=t.getMemberSchemas(),r=Object.values(n).find(e=>!!e.getMergedTraits().httpPayload);if(r)return r.getMergedTraits().mediaType||(r.isStringSchema()?`text/plain`:r.isBlobSchema()?`application/octet-stream`:e);if(!t.isUnitSchema()&&Object.values(n).find(e=>{let{httpQuery:t,httpQueryParams:n,httpHeader:r,httpLabel:i,httpPrefixHeaders:a}=e.getMergedTraits();return!t&&!n&&!r&&!i&&a===void 0}))return e}async getErrorSchemaOrThrowBaseException(e,t,n,r,i,a){let o=e;e.includes(`#`)&&([,o]=e.split(`#`));let s={$metadata:i,$fault:n.statusCode<500?`client`:`server`};if(!this.errorRegistry)throw Error(`@aws-sdk/core/protocols - error handler not initialized.`);try{return{errorSchema:a?.(this.errorRegistry,o)??this.errorRegistry.getSchema(e),errorMetadata:s}}catch{r.message=r.message??r.Message??`UnknownError`;let e=this.errorRegistry,t=e.getBaseException();if(t){let n=e.getErrorCtor(t)??Error;throw this.decorateServiceException(Object.assign(new n({name:o}),s),r)}let n=r,i=n?.message??n?.Message??n?.Error?.Message??n?.Error?.message;throw this.decorateServiceException(Object.assign(Error(i),{name:o},s),r)}}compose(e,t,n){let r=n;t.includes(`#`)&&([r]=t.split(`#`));let i=At.for(r),a=At.for(`smithy.ts.sdk.synthetic.`+n);e.copyFrom(i),e.copyFrom(a),this.errorRegistry=e}decorateServiceException(e,t={}){if(this.queryCompat){let n=e.Message??t.Message,r=gi(e,t);n&&(r.message=n),r.Error={...r.Error,Type:r.Error?.Type,Code:r.Error?.Code,Message:r.Error?.message??r.Error?.Message??n};let i=r.$metadata.requestId;return i&&(r.RequestId=i),r}return gi(e,t)}setQueryCompatError(e,t){let n=t.headers?.[`x-amzn-query-error`];if(e!==void 0&&n!=null){let[t,r]=n.split(`;`),i=Object.entries(e),a={Code:t,Type:r};Object.assign(e,a);for(let[e,t]of i)a[e===`message`?`Message`:e]=t;delete a.__type,e.Error=a}}queryCompatOutput(e,t){e.Error&&(t.Error=e.Error),e.Type&&(t.Type=e.Type),e.Code&&(t.Code=e.Code)}findQueryCompatibleError(e,t){try{return e.getSchema(t)}catch{return e.find(e=>p.of(e).getMergedTraits().awsQueryError?.[0]===t)}}},Oi=class{serdeContext;setSerdeContext(e){this.serdeContext=e}},ki=class{from;to;keys;constructor(e,t){this.from=e,this.to=t,this.keys=new Set(Object.keys(this.from).filter(e=>e!==`__type`))}mark(e){this.keys.delete(e)}hasUnknown(){return this.keys.size===1&&Object.keys(this.to).length===0}writeUnknown(){if(this.hasUnknown()){let e=this.keys.values().next().value,t=this.from[e];this.to.$unknown=[e,t]}}},Ai=/[&<>"]/g,ji={"&":`&`,"<":`<`,">":`>`,'"':`"`};function Mi(e){return e.replace(Ai,e=>ji[e])}var Ni=/[&"'<>\r\n\u0085\u2028]/g,Pi={"&":`&`,'"':`"`,"'":`'`,"<":`<`,">":`>`,"\r":` `,"\n":` `,"…":`…`,"\u2028":`
`};function Fi(e){return e.replace(Ni,e=>Pi[e])}var Ii=class{value;constructor(e){this.value=e}toString(){return Fi(``+this.value)}},Li=class e{name;children;attributes={};static of(t,n,r){let i=new e(t);return n!==void 0&&i.addChildNode(new Ii(n)),r!==void 0&&i.withName(r),i}constructor(e,t=[]){this.name=e,this.children=t}withName(e){return this.name=e,this}addAttribute(e,t){return this.attributes[e]=t,this}addChildNode(e){return this.children.push(e),this}removeAttribute(e){return delete this.attributes[e],this}n(e){return this.name=e,this}c(e){return this.children.push(e),this}a(e,t){return t!=null&&(this.attributes[e]=t),this}cc(t,n,r=n){if(t[n]!=null){let i=e.of(n,t[n]).withName(r);this.c(i)}}l(e,t,n,r){e[t]!=null&&r().map(e=>{e.withName(n),this.c(e)})}lc(t,n,r,i){if(t[n]!=null){let t=i(),n=new e(r);t.map(e=>{n.c(e)}),this.c(n)}}toString(){let e=!!this.children.length,t=`<${this.name}`,n=this.attributes;for(let e of Object.keys(n)){let r=n[e];r!=null&&(t+=` ${e}="${Mi(``+r)}"`)}return t+=e?`>${this.children.map(e=>e.toString()).join(``)}`:`/>`}},Ri;function zi(e){Ri||=new DOMParser;let t=Ri.parseFromString(e,`application/xml`);if(t.getElementsByTagName(`parsererror`).length>0)throw Error(`DOMParser XML parsing error.`);let n=e=>{if(e.nodeType===Node.TEXT_NODE&&e.textContent?.trim())return e.textContent;if(e.nodeType===Node.ELEMENT_NODE){let t=e;if(t.attributes.length===0&&t.childNodes.length===0)return``;let r={},i=Array.from(t.attributes);for(let e of i)r[`${e.name}`]=e.value;let a=Array.from(t.childNodes);for(let e of a){let o=n(e);if(o!=null){let t=e.nodeName;if(a.length===1&&i.length===0&&t===`#text`)return o;r[t]?Array.isArray(r[t])?r[t].push(o):r[t]=[r[t],o]:r[t]=o}else if(a.length===1&&i.length===0)return t.textContent}return r}return null};return{[t.documentElement.nodeName]:n(t.documentElement)}}var Bi=class extends Oi{settings;stringDeserializer;constructor(e){super(),this.settings=e,this.stringDeserializer=new Un(e)}setSerdeContext(e){this.serdeContext=e,this.stringDeserializer.setSerdeContext(e)}read(e,t,n){let r=p.of(e),i=r.getMemberSchemas();if(r.isStructSchema()&&r.isMemberSchema()&&Object.values(i).find(e=>!!e.getMemberTraits().eventPayload)){let e={},n=Object.keys(i)[0];return i[n].isBlobSchema()?e[n]=t:e[n]=this.read(i[n],t),e}let a=(this.serdeContext?.utf8Encoder??ce)(t),o=this.parseXml(a);return this.readSchema(e,n?o[n]:o)}readSchema(e,t){let n=p.of(e);if(n.isUnitSchema())return;let r=n.getMergedTraits();if(n.isListSchema()&&!Array.isArray(t))return this.readSchema(n,[t]);if(t==null)return t;if(typeof t==`object`){let e=!!r.xmlFlattened;if(n.isListSchema()){let r=n.getValueSchema(),i=[],a=r.getMergedTraits().xmlName??`member`,o=e?t:(t[0]??t)[a];if(o==null)return i;let s=Array.isArray(o)?o:[o];for(let e of s)i.push(this.readSchema(r,e));return i}let i={};if(n.isMapSchema()){let r=n.getKeySchema(),a=n.getValueSchema(),o;o=e?Array.isArray(t)?t:[t]:Array.isArray(t.entry)?t.entry:[t.entry];let s=r.getMergedTraits().xmlName??`key`,c=a.getMergedTraits().xmlName??`value`;for(let e of o){let t=e[s],n=e[c];i[t]=this.readSchema(a,n)}return i}if(n.isStructSchema()){let e=n.isUnionSchema(),r;e&&(r=new ki(t,i));for(let[a,o]of n.structIterator()){let n=o.getMergedTraits(),s=n.httpPayload?n.xmlName??o.getName():o.getMemberTraits().xmlName??a;e&&r.mark(s),t[s]!=null&&(i[a]=this.readSchema(o,t[s]))}return e&&r.writeUnknown(),i}if(n.isDocumentSchema())return t;throw Error(`@aws-sdk/core/protocols - xml deserializer unhandled schema type for ${n.getName(!0)}`)}return n.isListSchema()?[]:n.isMapSchema()||n.isStructSchema()?{}:this.stringDeserializer.read(n,t)}parseXml(e){if(e.length){let t;try{t=zi(e)}catch(t){throw t&&typeof t==`object`&&Object.defineProperty(t,`$responseBodyText`,{value:e}),t}let n=`#text`,r=Object.keys(t)[0],i=t[r];return i[n]&&(i[r]=i[n],delete i[n]),Ti(i)}return{}}},Vi=class extends Oi{settings;buffer;constructor(e){super(),this.settings=e}write(e,t,n=``){this.buffer===void 0&&(this.buffer=``);let r=p.of(e);if(n&&!n.endsWith(`.`)&&(n+=`.`),r.isBlobSchema())(typeof t==`string`||t instanceof Uint8Array)&&(this.writeKey(n),this.writeValue((this.serdeContext?.base64Encoder??We)(t)));else if(r.isBooleanSchema()||r.isNumericSchema()||r.isStringSchema())t==null?r.isIdempotencyToken()&&(this.writeKey(n),this.writeValue(pn())):(this.writeKey(n),this.writeValue(String(t)));else if(r.isBigIntegerSchema())t!=null&&(this.writeKey(n),this.writeValue(String(t)));else if(r.isBigDecimalSchema())t!=null&&(this.writeKey(n),this.writeValue(t instanceof Nn?t.string:String(t)));else if(r.isTimestampSchema()){if(t instanceof Date)switch(this.writeKey(n),Hn(r,this.settings)){case 5:this.writeValue(t.toISOString().replace(`.000Z`,`Z`));break;case 6:this.writeValue(Jt(t));break;case 7:this.writeValue(String(t.getTime()/1e3));break}}else if(r.isDocumentSchema())Array.isArray(t)?this.write(79,t,n):t instanceof Date?this.write(4,t,n):t instanceof Uint8Array?this.write(21,t,n):t&&typeof t==`object`?this.write(143,t,n):(this.writeKey(n),this.writeValue(String(t)));else if(r.isListSchema()){if(Array.isArray(t))if(t.length===0)this.settings.serializeEmptyLists&&(this.writeKey(n),this.writeValue(``));else{let e=r.getValueSchema(),i=this.settings.flattenLists||r.getMergedTraits().xmlFlattened,a=1;for(let r of t){if(r==null)continue;let t=e.getMergedTraits(),o=this.getKey(`member`,t.xmlName,t.ec2QueryName),s=i?`${n}${a}`:`${n}${o}.${a}`;this.write(e,r,s),++a}}}else if(r.isMapSchema()){if(t&&typeof t==`object`){let e=r.getKeySchema(),i=r.getValueSchema(),a=r.getMergedTraits().xmlFlattened,o=1;for(let[r,s]of Object.entries(t)){if(s==null)continue;let t=e.getMergedTraits(),c=this.getKey(`key`,t.xmlName,t.ec2QueryName),l=a?`${n}${o}.${c}`:`${n}entry.${o}.${c}`,u=i.getMergedTraits(),d=this.getKey(`value`,u.xmlName,u.ec2QueryName),ee=a?`${n}${o}.${d}`:`${n}entry.${o}.${d}`;this.write(e,r,l),this.write(i,s,ee),++o}}}else if(r.isStructSchema()){if(t&&typeof t==`object`){let e=!1;for(let[i,a]of r.structIterator()){if(t[i]==null&&!a.isIdempotencyToken())continue;let r=a.getMergedTraits(),o=this.getKey(i,r.xmlName,r.ec2QueryName,`struct`),s=`${n}${o}`;this.write(a,t[i],s),e=!0}if(!e&&r.isUnionSchema()){let{$unknown:e}=t;if(Array.isArray(e)){let[t,r]=e,i=`${n}${t}`;this.write(15,r,i)}}}}else if(!r.isUnitSchema())throw Error(`@aws-sdk/core/protocols - QuerySerializer unrecognized schema type ${r.getName(!0)}`)}flush(){if(this.buffer===void 0)throw Error(`@aws-sdk/core/protocols - QuerySerializer cannot flush with nothing written to buffer.`);let e=this.buffer;return delete this.buffer,e}getKey(e,t,n,r){let{ec2:i,capitalizeKeys:a}=this.settings;if(i&&n)return n;let o=t??e;return a&&r===`struct`?o[0].toUpperCase()+o.slice(1):o}writeKey(e){e.endsWith(`.`)&&(e=e.slice(0,e.length-1)),this.buffer+=`&${ut(e)}=`}writeValue(e){this.buffer+=ut(e)}},Hi=class extends Vn{options;serializer;deserializer;mixin=new Di;constructor(e){super({defaultNamespace:e.defaultNamespace,errorTypeRegistries:e.errorTypeRegistries}),this.options=e;let t={timestampFormat:{useTrait:!0,default:5},httpBindings:!1,xmlNamespace:e.xmlNamespace,serviceNamespace:e.defaultNamespace,serializeEmptyLists:!0};this.serializer=new Vi(t),this.deserializer=new Bi(t)}getShapeId(){return`aws.protocols#awsQuery`}setSerdeContext(e){this.serializer.setSerdeContext(e),this.deserializer.setSerdeContext(e)}getPayloadCodec(){throw Error(`AWSQuery protocol has no payload codec.`)}async serializeRequest(e,t,n){let r=await super.serializeRequest(e,t,n);return r.path.endsWith(`/`)||(r.path+=`/`),Object.assign(r.headers,{"content-type":`application/x-www-form-urlencoded`}),(dt(e.input)===`unit`||!r.body)&&(r.body=``),r.body=`Action=${e.name.split(`#`)[1]??e.name}&Version=${this.options.version}`+r.body,r.body.endsWith(`&`)&&(r.body=r.body.slice(-1)),r}async deserializeResponse(e,t,n){let r=this.deserializer,i=p.of(e.output),a={};if(n.statusCode>=300){let i=await lt(n.body,t);i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n))}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=e.name.split(`#`)[1]??e.name,s=i.isStructSchema()&&this.useNestedResult()?o+`Result`:void 0,c=await lt(n.body,t);return c.byteLength>0&&Object.assign(a,await r.read(i,c,s)),{$metadata:this.deserializeMetadata(n),...a}}useNestedResult(){return!0}async handleError(e,t,n,r,i){let a=this.loadQueryErrorCode(n,r)??`Unknown`;this.mixin.compose(this.compositeErrorRegistry,a,this.options.defaultNamespace);let o=this.loadQueryError(r)??{},s=this.loadQueryErrorMessage(r);o.message=s,o.Error={Type:o.Type,Code:o.Code,Message:s};let{errorSchema:c,errorMetadata:l}=await this.mixin.getErrorSchemaOrThrowBaseException(a,this.options.defaultNamespace,n,o,i,this.mixin.findQueryCompatibleError),u=p.of(c),d=new((this.compositeErrorRegistry.getErrorCtor(c))??Error)(s),ee={Type:o.Error.Type,Code:o.Error.Code,Error:o.Error};for(let[e,t]of u.structIterator()){let n=t.getMergedTraits().xmlName??e,i=o[n]??r[n];ee[e]=this.deserializer.readSchema(t,i)}throw this.mixin.decorateServiceException(Object.assign(d,l,{$fault:u.getMergedTraits().error,message:s},ee),r)}loadQueryErrorCode(e,t){let n=(t.Errors?.[0]?.Error??t.Errors?.Error??t.Error)?.Code;if(n!==void 0)return n;if(e.statusCode==404)return`NotFound`}loadQueryError(e){return e.Errors?.[0]?.Error??e.Errors?.Error??e.Error}loadQueryErrorMessage(e){let t=this.loadQueryError(e);return t?.message??t?.Message??e.message??e.Message??`Unknown`}getDefaultContentType(){return`application/x-www-form-urlencoded`}},Ui=class extends Hi{options;constructor(e){super(e),this.options=e,Object.assign(this.serializer.settings,{capitalizeKeys:!0,flattenLists:!0,serializeEmptyLists:!1,ec2:!0})}getShapeId(){return`aws.protocols#ec2Query`}useNestedResult(){return!1}},Wi=(e,t)=>{if(t?.Error?.Code!==void 0)return t.Error.Code;if(t?.Code!==void 0)return t.Code;if(e.statusCode==404)return`NotFound`},Gi=class extends Oi{settings;stringBuffer;byteBuffer;buffer;constructor(e){super(),this.settings=e}write(e,t){let n=p.of(e);if(n.isStringSchema()&&typeof t==`string`)this.stringBuffer=t;else if(n.isBlobSchema())this.byteBuffer=`byteLength`in t?t:(this.serdeContext?.base64Decoder??Ue)(t);else{this.buffer=this.writeStruct(n,t,void 0);let e=n.getMergedTraits();e.httpPayload&&!e.xmlName&&this.buffer.withName(n.getName())}}flush(){if(this.byteBuffer!==void 0){let e=this.byteBuffer;return delete this.byteBuffer,e}if(this.stringBuffer!==void 0){let e=this.stringBuffer;return delete this.stringBuffer,e}let e=this.buffer;return this.settings.xmlNamespace&&(e?.attributes?.xmlns||e.addAttribute(`xmlns`,this.settings.xmlNamespace)),delete this.buffer,e.toString()}writeStruct(e,t,n){let r=e.getMergedTraits(),i=e.isMemberSchema()&&!r.httpPayload?e.getMemberTraits().xmlName??e.getMemberName():r.xmlName??e.getName();if(!i||!e.isStructSchema())throw Error(`@aws-sdk/core/protocols - xml serializer, cannot write struct with empty name or non-struct, schema=${e.getName(!0)}.`);let a=Li.of(i),[o,s]=this.getXmlnsAttribute(e,n);for(let[n,r]of e.structIterator()){let e=t[n];if(e!=null||r.isIdempotencyToken()){if(r.getMergedTraits().xmlAttribute){a.addAttribute(r.getMergedTraits().xmlName??n,this.writeSimple(r,e));continue}if(r.isListSchema())this.writeList(r,e,a,s);else if(r.isMapSchema())this.writeMap(r,e,a,s);else if(r.isStructSchema())a.addChildNode(this.writeStruct(r,e,s));else{let t=Li.of(r.getMergedTraits().xmlName??r.getMemberName());this.writeSimpleInto(r,e,t,s),a.addChildNode(t)}}}let{$unknown:c}=t;if(c&&e.isUnionSchema()&&Array.isArray(c)&&Object.keys(t).length===1){let[e,n]=c,r=Li.of(e);if(typeof n!=`string`)if(t instanceof Li||t instanceof Ii)a.addChildNode(t);else throw Error(`@aws-sdk - $unknown union member in XML requires value of type string, @aws-sdk/xml-builder::XmlNode or XmlText.`);this.writeSimpleInto(0,n,r,s),a.addChildNode(r)}return s&&a.addAttribute(o,s),a}writeList(e,t,n,r){if(!e.isMemberSchema())throw Error(`@aws-sdk/core/protocols - xml serializer, cannot write non-member list: ${e.getName(!0)}`);let i=e.getMergedTraits(),a=e.getValueSchema(),o=a.getMergedTraits(),s=!!o.sparse,c=!!i.xmlFlattened,[l,u]=this.getXmlnsAttribute(e,r),d=(t,n)=>{if(a.isListSchema())this.writeList(a,Array.isArray(n)?n:[n],t,u);else if(a.isMapSchema())this.writeMap(a,n,t,u);else if(a.isStructSchema()){let r=this.writeStruct(a,n,u);t.addChildNode(r.withName(c?i.xmlName??e.getMemberName():o.xmlName??`member`))}else{let r=Li.of(c?i.xmlName??e.getMemberName():o.xmlName??`member`);this.writeSimpleInto(a,n,r,u),t.addChildNode(r)}};if(c)for(let e of t)(s||e!=null)&&d(n,e);else{let r=Li.of(i.xmlName??e.getMemberName());u&&r.addAttribute(l,u);for(let e of t)(s||e!=null)&&d(r,e);n.addChildNode(r)}}writeMap(e,t,n,r,i=!1){if(!e.isMemberSchema())throw Error(`@aws-sdk/core/protocols - xml serializer, cannot write non-member map: ${e.getName(!0)}`);let a=e.getMergedTraits(),o=e.getKeySchema(),s=o.getMergedTraits().xmlName??`key`,c=e.getValueSchema(),l=c.getMergedTraits(),u=l.xmlName??`value`,d=!!l.sparse,ee=!!a.xmlFlattened,[te,f]=this.getXmlnsAttribute(e,r),ne=(e,t,n)=>{let r=Li.of(s,t),[i,a]=this.getXmlnsAttribute(o,f);a&&r.addAttribute(i,a),e.addChildNode(r);let l=Li.of(u);c.isListSchema()?this.writeList(c,n,l,f):c.isMapSchema()?this.writeMap(c,n,l,f,!0):c.isStructSchema()?l=this.writeStruct(c,n,f):this.writeSimpleInto(c,n,l,f),e.addChildNode(l)};if(ee){for(let[r,i]of Object.entries(t))if(d||i!=null){let t=Li.of(a.xmlName??e.getMemberName());ne(t,r,i),n.addChildNode(t)}}else{let r;i||(r=Li.of(a.xmlName??e.getMemberName()),f&&r.addAttribute(te,f),n.addChildNode(r));for(let[e,a]of Object.entries(t))if(d||a!=null){let t=Li.of(`entry`);ne(t,e,a),(i?n:r).addChildNode(t)}}}writeSimple(e,t){if(t===null)throw Error(`@aws-sdk/core/protocols - (XML serializer) cannot write null value.`);let n=p.of(e),r=null;if(t&&typeof t==`object`)if(n.isBlobSchema())r=(this.serdeContext?.base64Encoder??We)(t);else if(n.isTimestampSchema()&&t instanceof Date)switch(Hn(n,this.settings)){case 5:r=t.toISOString().replace(`.000Z`,`Z`);break;case 6:r=Jt(t);break;case 7:r=String(t.getTime()/1e3);break;default:console.warn(`Missing timestamp format, using http date`,t),r=Jt(t);break}else if(n.isBigDecimalSchema()&&t)return t instanceof Nn?t.string:String(t);else if(n.isMapSchema()||n.isListSchema())throw Error(`@aws-sdk/core/protocols - xml serializer, cannot call _write() on List/Map schema, call writeList or writeMap() instead.`);else throw Error(`@aws-sdk/core/protocols - xml serializer, unhandled schema type for object value and schema: ${n.getName(!0)}`);if((n.isBooleanSchema()||n.isNumericSchema()||n.isBigIntegerSchema()||n.isBigDecimalSchema())&&(r=String(t)),n.isStringSchema()&&(r=t===void 0&&n.isIdempotencyToken()?pn():String(t)),r===null)throw Error(`Unhandled schema-value pair ${n.getName(!0)}=${t}`);return r}writeSimpleInto(e,t,n,r){let i=this.writeSimple(e,t),a=p.of(e),o=new Ii(i),[s,c]=this.getXmlnsAttribute(a,r);c&&n.addAttribute(s,c),n.addChildNode(o)}getXmlnsAttribute(e,t){let[n,r]=e.getMergedTraits().xmlNamespace??[];return r&&r!==t?[n?`xmlns:${n}`:`xmlns`,r]:[void 0,void 0]}},Ki=class extends Oi{settings;constructor(e){super(),this.settings=e}createSerializer(){let e=new Gi(this.settings);return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new Bi(this.settings);return e.setSerdeContext(this.serdeContext),e}},qi=class extends Bn{codec;serializer;deserializer;mixin=new Di;constructor(e){super(e);let t={timestampFormat:{useTrait:!0,default:5},httpBindings:!0,xmlNamespace:e.xmlNamespace,serviceNamespace:e.defaultNamespace};this.codec=new Ki(t),this.serializer=new Kn(this.codec.createSerializer(),t),this.deserializer=new Wn(this.codec.createDeserializer(),t),this.compositeErrorRegistry}getPayloadCodec(){return this.codec}getShapeId(){return`aws.protocols#restXml`}async serializeRequest(e,t,n){let r=await super.serializeRequest(e,t,n),i=p.of(e.input);if(!r.headers[`content-type`]){let e=this.mixin.resolveRestContentType(this.getDefaultContentType(),i);e&&(r.headers[`content-type`]=e)}return typeof r.body==`string`&&r.headers[`content-type`]===this.getDefaultContentType()&&!r.body.startsWith(``+r.body),r}async deserializeResponse(e,t,n){return super.deserializeResponse(e,t,n)}async handleError(e,t,n,r,i){let a=Wi(n,r)??`Unknown`;if(this.mixin.compose(this.compositeErrorRegistry,a,this.options.defaultNamespace),r.Error&&typeof r.Error==`object`)for(let e of Object.keys(r.Error))r[e]=r.Error[e],e.toLowerCase()===`message`&&(r.message=r.Error[e]);r.RequestId&&!i.requestId&&(i.requestId=r.RequestId);let{errorSchema:o,errorMetadata:s}=await this.mixin.getErrorSchemaOrThrowBaseException(a,this.options.defaultNamespace,n,r,i),c=p.of(o),l=r.Error?.message??r.Error?.Message??r.message??r.Message??`UnknownError`,u=new((this.compositeErrorRegistry.getErrorCtor(o))??Error)(l);await this.deserializeHttpMessage(o,t,n,r);let d={};for(let[e,t]of c.structIterator()){let n=t.getMergedTraits().xmlName??e,i=r.Error?.[n]??r[n];d[e]=this.codec.createDeserializer().readSchema(t,i)}throw this.mixin.decorateServiceException(Object.assign(u,s,{$fault:c.getMergedTraits().error,message:l},d),r)}getDefaultContentType(){return`application/xml`}hasUnstructuredPayloadBinding(e){for(let[,t]of e.structIterator())if(t.getMergedTraits().httpPayload)return!(t.isStructSchema()||t.isMapSchema()||t.isListSchema());return!1}},Ji;(function(e){e.STANDARD=`standard`,e.ADAPTIVE=`adaptive`})(Ji||={});var Yi=Ji.STANDARD,Xi=[`BandwidthLimitExceeded`,`EC2ThrottledException`,`LimitExceededException`,`PriorRequestNotComplete`,`ProvisionedThroughputExceededException`,`RequestLimitExceeded`,`RequestThrottled`,`RequestThrottledException`,`SlowDown`,`ThrottledException`,`Throttling`,`ThrottlingException`,`TooManyRequestsException`,`TransactionInProgressException`],Zi=[`TimeoutError`,`RequestTimeout`,`RequestTimeoutException`],Qi=[500,502,503,504],$i=[`ECONNRESET`,`ECONNREFUSED`,`EPIPE`,`ETIMEDOUT`],ea=[`EHOSTUNREACH`,`ENETUNREACH`,`ENOTFOUND`],ta=e=>e?.$retryable!==void 0,na=e=>e.$metadata?.clockSkewCorrected,ra=e=>{let t=new Set([`Failed to fetch`,`NetworkError when attempting to fetch resource`,`The Internet connection appears to be offline`,`Load failed`,`Network request failed`]);return e&&e instanceof TypeError?t.has(e.message):!1},ia=e=>e.$metadata?.httpStatusCode===429||Xi.includes(e.name)||e.$retryable?.throttling==1,aa=(e,t=0)=>ta(e)||na(e)||Zi.includes(e.name)||$i.includes(e?.code||``)||ea.includes(e?.code||``)||Qi.includes(e.$metadata?.httpStatusCode||0)||ra(e)||e.cause!==void 0&&t<=10&&aa(e.cause,t+1),oa=e=>{if(e.$metadata?.httpStatusCode!==void 0){let t=e.$metadata.httpStatusCode;return 500<=t&&t<=599&&!aa(e)}return!1},sa=class e{static setTimeoutFn=setTimeout;beta;minCapacity;minFillRate;scaleConstant;smooth;currentCapacity=0;enabled=!1;lastMaxRate=0;measuredTxRate=0;requestCount=0;fillRate;lastThrottleTime;lastTimestamp=0;lastTxRateBucket;maxCapacity;timeWindow=0;constructor(e){this.beta=e?.beta??.7,this.minCapacity=e?.minCapacity??1,this.minFillRate=e?.minFillRate??.5,this.scaleConstant=e?.scaleConstant??.4,this.smooth=e?.smooth??.8,this.lastThrottleTime=this.getCurrentTimeInSeconds(),this.lastTxRateBucket=Math.floor(this.getCurrentTimeInSeconds()),this.fillRate=this.minFillRate,this.maxCapacity=this.minCapacity}getCurrentTimeInSeconds(){return Date.now()/1e3}async getSendToken(){return this.acquireTokenBucket(1)}async acquireTokenBucket(t){if(this.enabled){if(this.refillTokenBucket(),t>this.currentCapacity){let n=(t-this.currentCapacity)/this.fillRate*1e3;await new Promise(t=>e.setTimeoutFn(t,n))}this.currentCapacity-=t}}refillTokenBucket(){let e=this.getCurrentTimeInSeconds();if(!this.lastTimestamp){this.lastTimestamp=e;return}let t=(e-this.lastTimestamp)*this.fillRate;this.currentCapacity=Math.min(this.maxCapacity,this.currentCapacity+t),this.lastTimestamp=e}updateClientSendingRate(e){let t;if(this.updateMeasuredRate(),ia(e)){let e=this.enabled?Math.min(this.measuredTxRate,this.fillRate):this.measuredTxRate;this.lastMaxRate=e,this.calculateTimeWindow(),this.lastThrottleTime=this.getCurrentTimeInSeconds(),t=this.cubicThrottle(e),this.enableTokenBucket()}else this.calculateTimeWindow(),t=this.cubicSuccess(this.getCurrentTimeInSeconds());let n=Math.min(t,2*this.measuredTxRate);this.updateTokenBucketRate(n)}calculateTimeWindow(){this.timeWindow=this.getPrecise((this.lastMaxRate*(1-this.beta)/this.scaleConstant)**(1/3))}cubicThrottle(e){return this.getPrecise(e*this.beta)}cubicSuccess(e){return this.getPrecise(this.scaleConstant*(e-this.lastThrottleTime-this.timeWindow)**3+this.lastMaxRate)}enableTokenBucket(){this.enabled=!0}updateTokenBucketRate(e){this.refillTokenBucket(),this.fillRate=Math.max(e,this.minFillRate),this.maxCapacity=Math.max(e,this.minCapacity),this.currentCapacity=Math.min(this.currentCapacity,this.maxCapacity)}updateMeasuredRate(){let e=this.getCurrentTimeInSeconds(),t=Math.floor(e*2)/2;if(this.requestCount++,t>this.lastTxRateBucket){let e=this.requestCount/(t-this.lastTxRateBucket);this.measuredTxRate=this.getPrecise(e*this.smooth+this.measuredTxRate*(1-this.smooth)),this.requestCount=0,this.lastTxRateBucket=t}}getPrecise(e){return parseFloat(e.toFixed(8))}},ca=20*1e3,la=`amz-sdk-invocation-id`,ua=`amz-sdk-request`,da=()=>{let e=100;return{computeNextBackoffDelay:t=>Math.floor(Math.min(ca,Math.random()*2**t*e)),setDelayBase:t=>{e=t}}},fa=({retryDelay:e,retryCount:t,retryCost:n})=>({getRetryCount:()=>t,getRetryDelay:()=>Math.min(ca,e),getRetryCost:()=>n}),pa=class{maxAttempts;mode=Ji.STANDARD;capacity=500;retryBackoffStrategy=da();maxAttemptsProvider;constructor(e){this.maxAttempts=e,this.maxAttemptsProvider=typeof e==`function`?e:async()=>e}async acquireInitialRetryToken(e){return fa({retryDelay:100,retryCount:0})}async refreshRetryTokenForRetry(e,t){let n=await this.getMaxAttempts();if(this.shouldRetry(e,t,n)){let n=t.errorType;this.retryBackoffStrategy.setDelayBase(n===`THROTTLING`?500:100);let r=this.retryBackoffStrategy.computeNextBackoffDelay(e.getRetryCount()),i=t.retryAfterHint?Math.max(t.retryAfterHint.getTime()-Date.now()||0,r):r,a=this.getCapacityCost(n);return this.capacity-=a,fa({retryDelay:i,retryCount:e.getRetryCount()+1,retryCost:a})}throw Error(`No retry token available`)}recordSuccess(e){this.capacity=Math.max(500,this.capacity+(e.getRetryCost()??1))}getCapacity(){return this.capacity}async getMaxAttempts(){try{return await this.maxAttemptsProvider()}catch{return console.warn(`Max attempts provider could not resolve. Using default of 3`),3}}shouldRetry(e,t,n){return e.getRetryCount()+1=this.getCapacityCost(t.errorType)&&this.isRetryableError(t.errorType)}getCapacityCost(e){return e===`TRANSIENT`?10:5}isRetryableError(e){return e===`THROTTLING`||e===`TRANSIENT`}},ma=class{maxAttemptsProvider;rateLimiter;standardRetryStrategy;mode=Ji.ADAPTIVE;constructor(e,t){this.maxAttemptsProvider=e;let{rateLimiter:n}=t??{};this.rateLimiter=n??new sa,this.standardRetryStrategy=new pa(e)}async acquireInitialRetryToken(e){return await this.rateLimiter.getSendToken(),this.standardRetryStrategy.acquireInitialRetryToken(e)}async refreshRetryTokenForRetry(e,t){return this.rateLimiter.updateClientSendingRate(t),this.standardRetryStrategy.refreshRetryTokenForRetry(e,t)}recordSuccess(e){this.rateLimiter.updateClientSendingRate({}),this.standardRetryStrategy.recordSuccess(e)}},ha=/\d{12}\.ddb/;async function ga(e,t,n){if(n.request?.headers?.[`smithy-protocol`]===`rpc-v2-cbor`&&Ur(e,`PROTOCOL_RPC_V2_CBOR`,`M`),typeof t.retryStrategy==`function`){let n=await t.retryStrategy();if(typeof n.mode==`string`)switch(n.mode){case Ji.ADAPTIVE:Ur(e,`RETRY_MODE_ADAPTIVE`,`F`);break;case Ji.STANDARD:Ur(e,`RETRY_MODE_STANDARD`,`E`);break}}if(typeof t.accountIdEndpointMode==`function`){let n=e.endpointV2;switch(String(n?.url?.hostname).match(ha)&&Ur(e,`ACCOUNT_ID_ENDPOINT`,`O`),await t.accountIdEndpointMode?.()){case`disabled`:Ur(e,`ACCOUNT_ID_MODE_DISABLED`,`Q`);break;case`preferred`:Ur(e,`ACCOUNT_ID_MODE_PREFERRED`,`P`);break;case`required`:Ur(e,`ACCOUNT_ID_MODE_REQUIRED`,`R`);break}}let r=e.__smithy_context?.selectedHttpAuthScheme?.identity;if(r?.$source){let t=r;t.accountId&&Ur(e,`RESOLVED_ACCOUNT_ID`,`T`);for(let[n,r]of Object.entries(t.$source??{}))Ur(e,n,r)}}var _a=`user-agent`,va=`x-amz-user-agent`,ya=/[^!$%&'*+\-.^_`|~\w]/g,ba=/[^!$%&'*+\-.^_`|~\w#]/g,xa=1024;function Sa(e){let t=``;for(let n in e){let r=e[n];if(t.length+r.length+1<=xa){t.length?t+=`,`+r:t+=r;continue}break}return t}var Ca=e=>(t,n)=>async r=>{let{request:a}=r;if(!i.isInstance(a))return t(r);let{headers:o}=a,s=n?.userAgent?.map(wa)||[],c=(await e.defaultUserAgentProvider()).map(wa);await ga(n,e,r);let l=n;c.push(`m/${Sa(Object.assign({},n.__smithy_context?.features,l.__aws_sdk_context?.features))}`);let u=e?.customUserAgent?.map(wa)||[],d=await e.userAgentAppId();d&&c.push(wa([`app`,`${d}`]));let ee=Br(),te=(ee?[ee]:[]).concat([...c,...s,...u]).join(` `),f=[...c.filter(e=>e.startsWith(`aws-sdk-`)),...u].join(` `);return e.runtime===`browser`?o[va]=te:(f&&(o[va]=o[`x-amz-user-agent`]?`${o[_a]} ${f}`:f),o[_a]=te),t({...r,request:a})},wa=e=>{let t=e[0].split(`/`).map(e=>e.replace(ya,`-`)).join(`/`),n=e[1]?.replace(ba,`-`),r=t.indexOf(`/`),i=t.substring(0,r),a=t.substring(r+1);return i===`api`&&(a=a.toLowerCase()),[i,a,n].filter(e=>e&&e.length>0).reduce((e,t,n)=>{switch(n){case 0:return t;case 1:return`${e}/${t}`;default:return`${e}#${t}`}},``)},Ta={name:`getUserAgentMiddleware`,step:`build`,priority:`low`,tags:[`SET_USER_AGENT`,`USER_AGENT`],override:!0},Ea=e=>({applyToStack:t=>{t.add(Ca(e),Ta)}}),Da=new Set,Oa=(e,t=ir)=>{if(!Da.has(e)&&!t(e))if(e===`*`)console.warn(`@smithy/config-resolver WARN - Please use the caller region instead of "*". See "sigv4a" in https://github.com/aws/aws-sdk-js-v3/blob/main/supplemental-docs/CLIENTS.md.`);else throw Error(`Region not accepted: region="${e}" is not a valid hostname component.`);else Da.add(e)},ka=e=>typeof e==`string`&&(e.startsWith(`fips-`)||e.endsWith(`-fips`)),Aa=e=>ka(e)?[`fips-aws-global`,`aws-fips`].includes(e)?`us-east-1`:e.replace(/fips-(dkr-|prod-)?|-fips/,``):e,ja=e=>{let{region:t,useFipsEndpoint:n}=e;if(!t)throw Error(`Region is missing`);return Object.assign(e,{region:async()=>{let e=Aa(typeof t==`function`?await t():t);return Oa(e),e},useFipsEndpoint:async()=>ka(typeof t==`string`?t:await t())?!0:typeof n==`function`?n():Promise.resolve(!!n)})},Ma=`content-length`;function Na(e){return t=>async n=>{let r=n.request;if(i.isInstance(r)){let{body:t,headers:n}=r;if(t&&Object.keys(n).map(e=>e.toLowerCase()).indexOf(Ma)===-1)try{let n=e(t);r.headers={...r.headers,[Ma]:String(n)}}catch{}}return t({...n,request:r})}}var Pa={step:`build`,tags:[`SET_CONTENT_LENGTH`,`CONTENT_LENGTH`],name:`contentLengthMiddleware`,override:!0},Fa=e=>({applyToStack:t=>{t.add(Na(e.bodyLengthChecker),Pa)}}),Ia=async e=>{let t=e?.Bucket||``;if(typeof e.Bucket==`string`&&(e.Bucket=t.replace(/#/g,`%23`).replace(/\?/g,`%3F`)),Va(t)){if(e.ForcePathStyle===!0)throw Error(`Path-style addressing cannot be used with ARN buckets`)}else (!Ba(t)||t.indexOf(`.`)!==-1&&!String(e.Endpoint).startsWith(`http:`)||t.toLowerCase()!==t||t.length<3)&&(e.ForcePathStyle=!0);return e.DisableMultiRegionAccessPoints&&(e.disableMultiRegionAccessPoints=!0,e.DisableMRAP=!0),e},La=/^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/,Ra=/(\d+\.){3}\d+/,za=/\.\./,Ba=e=>La.test(e)&&!Ra.test(e)&&!za.test(e),Va=e=>{let[t,n,r,,,i]=e.split(`:`),a=t===`arn`&&e.split(`:`).length>=6,o=!!(a&&n&&r&&i);if(a&&!o)throw Error(`Invalid ARN: ${e} was an invalid ARN.`);return o},Ha=(e,t,n,r=!1)=>{let i=async()=>{let i;return i=r?n.clientContextParams?.[e]??n[e]??n[t]:n[e]??n[t],typeof i==`function`?i():i};return e===`credentialScope`||t===`CredentialScope`?async()=>{let e=typeof n.credentials==`function`?await n.credentials():n.credentials;return e?.credentialScope??e?.CredentialScope}:e===`accountId`||t===`AccountId`?async()=>{let e=typeof n.credentials==`function`?await n.credentials():n.credentials;return e?.accountId??e?.AccountId}:e===`endpoint`||t===`endpoint`?async()=>{if(n.isCustomEndpoint===!1)return;let e=await i();if(e&&typeof e==`object`){if(`url`in e)return e.url.href;if(`hostname`in e){let{protocol:t,hostname:n,port:r,path:i}=e;return`${t}//${n}${r?`:`+r:``}${i}`}}return e}:i},Ua=async e=>void 0,Wa=e=>{if(typeof e==`object`){if(`url`in e){let t=gt(e.url);if(e.headers){t.headers={};for(let[n,r]of Object.entries(e.headers))t.headers[n.toLowerCase()]=r.join(`, `)}return t}return e}return gt(e)},Ga=async(e,t,n,r)=>{if(!n.isCustomEndpoint){let e;e=n.serviceConfiguredEndpoint?await n.serviceConfiguredEndpoint():await Ua(n.serviceId),e&&(n.endpoint=()=>Promise.resolve(Wa(e)),n.isCustomEndpoint=!0)}let i=await Ka(e,t,n);if(typeof n.endpointProvider!=`function`)throw Error(`config.endpointProvider is not set.`);let a=n.endpointProvider(i,r);if(n.isCustomEndpoint&&n.endpoint){let e=await n.endpoint();if(e?.headers){a.headers??={};for(let[t,n]of Object.entries(e.headers))a.headers[t]=Array.isArray(n)?n:[n]}}return a},Ka=async(e,t,n)=>{let r={},i=t?.getEndpointParameterInstructions?.()||{};for(let[t,a]of Object.entries(i))switch(a.type){case`staticContextParams`:r[t]=a.value;break;case`contextParams`:r[t]=e[a.name];break;case`clientContextParams`:case`builtInParams`:r[t]=await Ha(a.name,t,n,a.type!==`builtInParams`)();break;case`operationContextParams`:r[t]=a.get(e);break;default:throw Error(`Unrecognized endpoint parameter instruction: `+JSON.stringify(a))}return Object.keys(i).length===0&&Object.assign(r,n),String(n.serviceId).toLowerCase()===`s3`&&await Ia(r),r},qa=({config:e,instructions:t})=>(n,r)=>async i=>{e.isCustomEndpoint&&qn(r,`ENDPOINT_OVERRIDE`,`N`);let a=await Ga(i.input,{getEndpointParameterInstructions(){return t}},{...e},r);r.endpointV2=a,r.authSchemes=a.properties?.authSchemes;let o=r.authSchemes?.[0];if(o){r.signing_region=o.signingRegion,r.signing_service=o.signingName;let e=_e(r)?.selectedHttpAuthScheme?.httpAuthOption;e&&(e.signingProperties=Object.assign(e.signingProperties||{},{signing_region:o.signingRegion,signingRegion:o.signingRegion,signing_service:o.signingName,signingName:o.signingName,signingRegionSet:o.signingRegionSet},o.properties))}return n({...i})},Ja={step:`serialize`,tags:[`ENDPOINT_PARAMETERS`,`ENDPOINT_V2`,`ENDPOINT`],name:`endpointV2Middleware`,override:!0,relation:`before`,toMiddleware:{name:`serializerMiddleware`,step:`serialize`,tags:[`SERIALIZER`],override:!0}.name},Ya=(e,t)=>({applyToStack:n=>{n.addRelativeTo(qa({config:e,instructions:t}),Ja)}}),Xa=e=>{let t=e.tls??!0,{endpoint:n,useDualstackEndpoint:r,useFipsEndpoint:i}=e,a=Object.assign(e,{endpoint:n==null?void 0:async()=>Wa(await f(n)()),tls:t,isCustomEndpoint:!!n,useDualstackEndpoint:f(r??!1),useFipsEndpoint:f(i??!1)}),o;return a.serviceConfiguredEndpoint=async()=>(e.serviceId&&!o&&(o=Ua(e.serviceId)),o),a},Za=e=>e instanceof Error?e:e instanceof Object?Object.assign(Error(),e):Error(typeof e==`string`?e:`AWS SDK error wrapper for ${e}`),Qa=e=>{let{retryStrategy:t,retryMode:n}=e,r=f(e.maxAttempts??3),i=t?Promise.resolve(t):void 0,a=async()=>await f(n)()===Ji.ADAPTIVE?new ma(r):new pa(r);return Object.assign(e,{maxAttempts:r,retryStrategy:()=>i??=a()})},$a=e=>e?.body instanceof ReadableStream,eo=e=>(t,n)=>async r=>{let a=await e.retryStrategy(),o=await e.maxAttempts();if(to(a)){a=a;let e=await a.acquireInitialRetryToken(n.partition_id),s=Error(),c=0,l=0,{request:u}=r,d=i.isInstance(u);for(d&&(u.headers[la]=pn());;)try{d&&(u.headers[ua]=`attempt=${c+1}; max=${o}`);let{response:n,output:i}=await t(r);return a.recordSuccess(e),i.$metadata.attempts=c+1,i.$metadata.totalRetryDelay=l,{response:n,output:i}}catch(t){let r=no(t);if(s=Za(t),d&&$a(u))throw(n.logger instanceof Ei?console:n.logger)?.warn(`An error was encountered in a non-retryable streaming request.`),s;try{e=await a.refreshRetryTokenForRetry(e,r)}catch{throw s.$metadata||={},s.$metadata.attempts=c+1,s.$metadata.totalRetryDelay=l,s}c=e.getRetryCount();let i=e.getRetryDelay();l+=i,await new Promise(e=>setTimeout(e,i))}}else return a=a,a?.mode&&(n.userAgent=[...n.userAgent||[],[`cfg/retry-mode`,a.mode]]),a.retry(t,r)},to=e=>e.acquireInitialRetryToken!==void 0&&e.refreshRetryTokenForRetry!==void 0&&e.recordSuccess!==void 0,no=e=>{let t={error:e,errorType:ro(e)},n=oo(e.$response);return n&&(t.retryAfterHint=n),t},ro=e=>ia(e)?`THROTTLING`:aa(e)?`TRANSIENT`:oa(e)?`SERVER_ERROR`:`CLIENT_ERROR`,io={name:`retryMiddleware`,tags:[`RETRY`],step:`finalizeRequest`,priority:`high`,override:!0},ao=e=>({applyToStack:t=>{t.add(eo(e),io)}}),oo=e=>{if(!ge.isInstance(e))return;let t=Object.keys(e.headers).find(e=>e.toLowerCase()===`retry-after`);if(!t)return;let n=e.headers[t],r=Number(n);return Number.isNaN(r)?new Date(n):new Date(r*1e3)},so=async(e,t,n)=>({operation:_e(t).operation,region:await f(e.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function co(e){return{schemeId:`aws.auth#sigv4`,signingProperties:{name:`ec2`,region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}var lo=e=>{let t=[];switch(e.operation){default:t.push(co(e))}return t},uo=e=>{let t=ei(e);return Object.assign(t,{authSchemePreference:f(e.authSchemePreference??[])})},fo=e=>Object.assign(e,{useDualstackEndpoint:e.useDualstackEndpoint??!1,useFipsEndpoint:e.useFipsEndpoint??!1,defaultSigningName:`ec2`}),po={UseFIPS:{type:`builtInParams`,name:`useFipsEndpoint`},Endpoint:{type:`builtInParams`,name:`endpoint`},Region:{type:`builtInParams`,name:`region`},UseDualStack:{type:`builtInParams`,name:`useDualstackEndpoint`}},mo=`@aws-sdk/client-ec2`,ho=`AWS SDK for JavaScript Ec2 Client for Node.js, Browser and React Native`,go=`3.1019.0`,_o={build:`concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs`,"build:cjs":`node ../../scripts/compilation/inline client-ec2`,"build:es":`tsc -p tsconfig.es.json`,"build:include:deps":`yarn g:turbo run build -F="$npm_package_name"`,"build:types":`tsc -p tsconfig.types.json`,"build:types:downlevel":`downlevel-dts dist-types dist-types/ts3.4`,clean:`premove dist-cjs dist-es dist-types tsconfig.cjs.tsbuildinfo tsconfig.es.tsbuildinfo tsconfig.types.tsbuildinfo`,"extract:docs":`api-extractor run --local`,"generate:client":`node ../../scripts/generate-clients/single-service --solo ec2`,test:`yarn g:vitest run --passWithNoTests`,"test:index":`tsc --noEmit ./test/index-types.ts && node ./test/index-objects.spec.mjs`,"test:integration":`yarn g:vitest run --passWithNoTests -c vitest.config.integ.mts`,"test:integration:watch":`yarn g:vitest run --passWithNoTests -c vitest.config.integ.mts`,"test:watch":`yarn g:vitest watch --passWithNoTests`},vo=`./dist-cjs/index.js`,yo=`./dist-types/index.d.ts`,bo=`./dist-es/index.js`,xo={"@aws-crypto/sha256-browser":`5.2.0`,"@aws-crypto/sha256-js":`5.2.0`,"@aws-sdk/core":`^3.973.25`,"@aws-sdk/credential-provider-node":`^3.972.27`,"@aws-sdk/middleware-host-header":`^3.972.8`,"@aws-sdk/middleware-logger":`^3.972.8`,"@aws-sdk/middleware-recursion-detection":`^3.972.9`,"@aws-sdk/middleware-sdk-ec2":`^3.972.17`,"@aws-sdk/middleware-user-agent":`^3.972.26`,"@aws-sdk/region-config-resolver":`^3.972.10`,"@aws-sdk/types":`^3.973.6`,"@aws-sdk/util-endpoints":`^3.996.5`,"@aws-sdk/util-user-agent-browser":`^3.972.8`,"@aws-sdk/util-user-agent-node":`^3.973.12`,"@smithy/config-resolver":`^4.4.13`,"@smithy/core":`^3.23.12`,"@smithy/fetch-http-handler":`^5.3.15`,"@smithy/hash-node":`^4.2.12`,"@smithy/invalid-dependency":`^4.2.12`,"@smithy/middleware-content-length":`^4.2.12`,"@smithy/middleware-endpoint":`^4.4.27`,"@smithy/middleware-retry":`^4.4.44`,"@smithy/middleware-serde":`^4.2.15`,"@smithy/middleware-stack":`^4.2.12`,"@smithy/node-config-provider":`^4.3.12`,"@smithy/node-http-handler":`^4.5.0`,"@smithy/protocol-http":`^5.3.12`,"@smithy/smithy-client":`^4.12.7`,"@smithy/types":`^4.13.1`,"@smithy/url-parser":`^4.2.12`,"@smithy/util-base64":`^4.3.2`,"@smithy/util-body-length-browser":`^4.2.2`,"@smithy/util-body-length-node":`^4.2.3`,"@smithy/util-defaults-mode-browser":`^4.3.43`,"@smithy/util-defaults-mode-node":`^4.2.47`,"@smithy/util-endpoints":`^3.3.3`,"@smithy/util-middleware":`^4.2.12`,"@smithy/util-retry":`^4.2.12`,"@smithy/util-utf8":`^4.2.2`,"@smithy/util-waiter":`^4.2.13`,tslib:`^2.6.2`},So={"@smithy/snapshot-testing":`^2.0.3`,"@tsconfig/node20":`20.1.8`,"@types/node":`^20.14.8`,concurrently:`7.0.0`,"downlevel-dts":`0.10.1`,premove:`4.0.0`,typescript:`~5.8.3`,vitest:`^4.0.17`},Co={node:`>=20.0.0`},wo={"<4.5":{"dist-types/*":[`dist-types/ts3.4/*`]}},To=[`dist-*/**`],Eo={name:`AWS SDK for JavaScript Team`,url:`https://aws.amazon.com/javascript/`},Do=`Apache-2.0`,Oo={"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.browser`},ko=`https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-ec2`,Ao={type:`git`,url:`https://github.com/aws/aws-sdk-js-v3.git`,directory:`clients/client-ec2`},jo={name:mo,description:ho,version:go,scripts:_o,main:vo,types:yo,module:bo,sideEffects:!1,dependencies:xo,devDependencies:So,engines:Co,typesVersions:wo,files:To,author:Eo,license:Do,browser:Oo,"react-native":{"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.native`},homepage:ko,repository:Ao},Mo=({serviceId:e,clientVersion:t})=>async n=>{let r=typeof window<`u`?window.navigator:void 0,i=r?.userAgent??``,a=r?.userAgentData?.platform??No.os(i)??`other`,o=r?.userAgentData?.brands??[],s=o[o.length-1],c=s?.brand??No.browser(i)??`unknown`,l=s?.version??`unknown`,u=[[`aws-sdk-js`,t],[`ua`,`2.1`],[`os/${a}`,void 0],[`lang/js`],[`md/browser`,`${c}_${l}`]];e&&u.push([`api/${e}`,t]);let d=await n?.userAgentAppId?.();return d&&u.push([`app/${d}`]),u},No={os(e){if(/iPhone|iPad|iPod/.test(e))return`iOS`;if(/Macintosh|Mac OS X/.test(e))return`macOS`;if(/Windows NT/.test(e))return`Windows`;if(/Android/.test(e))return`Android`;if(/Linux/.test(e))return`Linux`},browser(e){if(/EdgiOS|EdgA|Edg\//.test(e))return`Microsoft Edge`;if(/Firefox\//.test(e))return`Firefox`;if(/Chrome\//.test(e))return`Chrome`;if(/Safari\//.test(e))return`Safari`}},Po=e=>()=>Promise.reject(e),Fo=[`in-region`,`cross-region`,`mobile`,`standard`,`legacy`],Io=({defaultsMode:e}={})=>Qr(async()=>{let t=typeof e==`function`?await e():e;switch(t?.toLowerCase()){case`auto`:return Promise.resolve(Lo()?`mobile`:`standard`);case`mobile`:case`in-region`:case`cross-region`:case`standard`:case`legacy`:return Promise.resolve(t?.toLocaleLowerCase());case void 0:return Promise.resolve(`legacy`);default:throw Error(`Invalid parameter for "defaultsMode", expect ${Fo.join(`, `)}, got ${t}`)}}),Lo=()=>{let e=window?.navigator;if(e?.connection){let{effectiveType:t,rtt:n,downlink:r}=e?.connection;if(typeof t==`string`&&t!==`4g`||Number(n)>100||Number(r)<10)return!0}return e?.userAgentData?.mobile||typeof e?.maxTouchPoints==`number`&&e?.maxTouchPoints>1},Ro=`required`,zo=`fn`,Bo=`argv`,Vo=`ref`,Ho=!0,Uo=`isSet`,Wo=`booleanEquals`,Go=`error`,Ko=`endpoint`,qo=`tree`,Jo=`PartitionResult`,Yo=`getAttr`,Xo={[Ro]:!1,type:`string`},Zo={[Ro]:!0,default:!1,type:`boolean`},Qo={[Vo]:`Endpoint`},$o={[zo]:Wo,[Bo]:[{[Vo]:`UseFIPS`},!0]},es={[zo]:Wo,[Bo]:[{[Vo]:`UseDualStack`},!0]},ts={},ns={[zo]:Yo,[Bo]:[{[Vo]:Jo},`supportsFIPS`]},rs={[Vo]:Jo},is={[zo]:Wo,[Bo]:[!0,{[zo]:Yo,[Bo]:[rs,`supportsDualStack`]}]},as=[$o],os=[es],ss=[{[Vo]:`Region`}],cs={version:`1.0`,parameters:{Region:Xo,UseDualStack:Zo,UseFIPS:Zo,Endpoint:Xo},rules:[{conditions:[{[zo]:Uo,[Bo]:[Qo]}],rules:[{conditions:as,error:`Invalid Configuration: FIPS and custom endpoint are not supported`,type:Go},{conditions:os,error:`Invalid Configuration: Dualstack and custom endpoint are not supported`,type:Go},{endpoint:{url:Qo,properties:ts,headers:ts},type:Ko}],type:qo},{conditions:[{[zo]:Uo,[Bo]:ss}],rules:[{conditions:[{[zo]:`aws.partition`,[Bo]:ss,assign:Jo}],rules:[{conditions:[$o,es],rules:[{conditions:[{[zo]:Wo,[Bo]:[Ho,ns]},is],rules:[{endpoint:{url:`https://ec2-fips.{Region}.{PartitionResult#dualStackDnsSuffix}`,properties:ts,headers:ts},type:Ko}],type:qo},{error:`FIPS and DualStack are enabled, but this partition does not support one or both`,type:Go}],type:qo},{conditions:as,rules:[{conditions:[{[zo]:Wo,[Bo]:[ns,Ho]}],rules:[{conditions:[{[zo]:`stringEquals`,[Bo]:[{[zo]:Yo,[Bo]:[rs,`name`]},`aws-us-gov`]}],endpoint:{url:`https://ec2.{Region}.amazonaws.com`,properties:ts,headers:ts},type:Ko},{endpoint:{url:`https://ec2-fips.{Region}.{PartitionResult#dnsSuffix}`,properties:ts,headers:ts},type:Ko}],type:qo},{error:`FIPS is enabled but this partition does not support FIPS`,type:Go}],type:qo},{conditions:os,rules:[{conditions:[is],rules:[{endpoint:{url:`https://ec2.{Region}.{PartitionResult#dualStackDnsSuffix}`,properties:ts,headers:ts},type:Ko}],type:qo},{error:`DualStack is enabled but this partition does not support DualStack`,type:Go}],type:qo},{endpoint:{url:`https://ec2.{Region}.{PartitionResult#dnsSuffix}`,properties:ts,headers:ts},type:Ko}],type:qo}],type:qo},{error:`Invalid Configuration: Missing Region`,type:Go}]},ls=new er({size:50,params:[`Endpoint`,`Region`,`UseDualStack`,`UseFIPS`]}),us=(e,t={})=>ls.get(e,()=>Mr(cs,{endpointParams:e,logger:t.logger}));ar.aws=Vr;var ds=class e extends hi{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}},fs=`AllAvailabilityZones`,ps=`AttributeBooleanValue`,ms=`AssociateCarrierIpAddress`,hs=`AdditionalFlexibleNetworkInterfaces`,gs=`AvailableIpAddressCount`,_s=`AssignIpv6AddressOnCreation`,vs=`AttachInternetGateway`,ys=`AttachInternetGatewayRequest`,bs=`AdditionalInfo`,xs=`AssociationId`,Ss=`AttachmentId`,Cs=`AmiLaunchIndex`,ws=`AttachmentLimitType`,Ts=`AssociatePublicIpAddress`,Es=`AmazonProvidedIpv6CidrBlock`,Ds=`AutoRecoverySupported`,Os=`AssociateRouteTableRequest`,ks=`AssociateRouteTableResult`,As=`AssociateRouteTable`,js=`AllRegions`,Ms=`AssociatedResource`,Ns=`AutoRecovery`,Ps=`AssociationState`,Fs=`AuthorizeSecurityGroupEgress`,Is=`AuthorizeSecurityGroupEgressRequest`,Ls=`AuthorizeSecurityGroupEgressResult`,Rs=`AuthorizeSecurityGroupIngressRequest`,zs=`AuthorizeSecurityGroupIngressResult`,Bs=`AuthorizeSecurityGroupIngress`,Vs=`AmdSevSnp`,Hs=`ArchitectureTypeList`,Us=`AttachTime`,Ws=`AttachVolumeRequest`,Gs=`AttributeValue`,Ks=`AttachVolume`,qs=`AvailabilityZone`,Js=`AvailabilityZoneGeography`,Ys=`AvailabilityZoneGeographyList`,Xs=`AvailabilityZoneId`,Zs=`AvailabilityZoneList`,Qs=`AvailabilityZoneMessage`,$s=`AvailabilityZoneMessageList`,ec=`AvailabilityZoneSubGeography`,tc=`AvailabilityZoneSubGeographyList`,nc=`AvailabilityZones`,rc=`Accelerators`,ic=`Affinity`,ac=`Arn`,oc=`Architecture`,sc=`Associations`,cc=`Association`,lc=`Attribute`,uc=`Attachment`,dc=`Attachments`,fc=`BlobAttributeValue`,pc=`BaselineBandwidthInGbps`,mc=`BaselineBandwidthInMbps`,hc=`BlockDeviceMapping`,gc=`BlockDeviceMappingList`,_c=`BlockDeviceMappingRequestList`,vc=`BlockDeviceMappings`,yc=`BlockDurationMinutes`,bc=`BaselineIops`,xc=`BootMode`,Sc=`BootModeTypeList`,Cc=`BareMetal`,wc=`BlockPublicAccessStates`,Tc=`BurstablePerformanceSupported`,Ec=`BaselineThroughputInMBps`,Dc=`BandwidthWeighting`,Oc=`BandwidthWeightingTypeList`,kc=`BandwidthWeightings`,Ac=`CidrBlock`,jc=`CidrBlockAssociationSet`,Mc=`CapacityBlockId`,Nc=`CidrBlockState`,Pc=`CoreCountList`,Fc=`CoreCount`,Ic=`CpuCredits`,Lc=`CompletionDurationMinutes`,Rc=`CreationDate`,zc=`CarrierGatewayId`,Bc=`CurrentGeneration`,Vc=`CarrierIp`,Hc=`CurrentInstanceBootMode`,Uc=`CreateInternetGateway`,Wc=`CreateInternetGatewayRequest`,Gc=`CreateInternetGatewayResult`,Kc=`CreateImageRequest`,qc=`CreateImageResult`,Jc=`CidrIp`,Yc=`CidrIpv6`,Xc=`CidrIpv4`,Zc=`CoreInfo`,Qc=`CreateImage`,$c=`CreateKeyPair`,el=`CreateKeyPairRequest`,tl=`CoreNetworkArn`,nl=`CpuOptions`,rl=`CustomerOwnedIp`,il=`CustomerOwnedIpv4Pool`,al=`CpuOptionsRequest`,ol=`CreatePlacementGroup`,sl=`CreatePlacementGroupRequest`,cl=`CreatePlacementGroupResult`,ll=`CapacityReservationId`,ul=`CapacityReservationPreference`,dl=`CreateRouteRequest`,fl=`CapacityReservationResourceGroupArn`,pl=`CreateRouteResult`,ml=`CapacityReservationSpecificationResponse`,hl=`CapacityReservationSpecification`,gl=`CapacityReservationTarget`,_l=`CapacityReservationTargetResponse`,vl=`CreateRouteTableRequest`,yl=`CreateRouteTableResult`,bl=`CreateRouteTable`,xl=`CreateRoute`,Sl=`CreateSecurityGroup`,Cl=`CreateSecurityGroupRequest`,wl=`CreateSecurityGroupResult`,Tl=`CopySnapshotRequest`,El=`CopySnapshotRequestPSU`,Dl=`CopySnapshotResult`,Ol=`CreateSnapshotRequest`,kl=`CreateSubnetRequest`,Al=`CreateSubnetResult`,jl=`CreditSpecificationRequest`,Ml=`CopySnapshot`,Nl=`CreditSpecification`,Pl=`CreateSnapshot`,Fl=`CreateSubnet`,Il=`CurrentState`,Ll=`ClientToken`,Rl=`ConnectionTrackingConfiguration`,zl=`ConnectionTrackingSpecification`,Bl=`ConnectionTrackingSpecificationRequest`,Vl=`ConnectionTrackingSpecificationResponse`,Hl=`CompletionTime`,Ul=`CreateTime`,Wl=`CreateVolumeRequest`,Gl=`CreateVpcRequest`,Kl=`CreateVpcResult`,ql=`CreateVolume`,Jl=`CreateVpc`,Yl=`Code`,Xl=`Configured`,Zl=`Count`,Ql=`DisableApiStop`,$l=`DisableApiTermination`,eu=`DestinationAvailabilityZone`,tu=`DescribeAvailabilityZonesRequest`,nu=`DescribeAvailabilityZonesResult`,ru=`DescribeAvailabilityZones`,iu=`DestinationCidrBlock`,au=`DefaultConnectionTrackingConfiguration`,ou=`DefaultCores`,su=`DataEncryptionKeyId`,cu=`DefaultEnaQueueCountPerInterface`,lu=`DefaultForAz`,uu=`DedicatedHostsSupported`,du=`DeviceIndex`,fu=`DestinationIpv6CidrBlock`,pu=`DescribeInternetGatewaysRequest`,mu=`DescribeInternetGatewaysResult`,hu=`DescribeInternetGateways`,gu=`DiskInfoList`,_u=`DescribeImagesRequest`,vu=`DescribeImagesResult`,yu=`DescribeInstancesRequest`,bu=`DescribeInstancesResult`,xu=`DescribeInstanceTypesRequest`,Su=`DescribeInstanceTypesResult`,Cu=`DescribeInstanceTypes`,wu=`DescribeImages`,Tu=`DescribeInstances`,Eu=`DiskInfo`,Du=`DeleteKeyPair`,Ou=`DeleteKeyPairRequest`,ku=`DeleteKeyPairResult`,Au=`DescribeKeyPairsRequest`,ju=`DescribeKeyPairsResult`,Mu=`DescribeKeyPairs`,Nu=`DeviceName`,Pu=`DefaultNetworkCardIndex`,Fu=`DestinationOutpostArn`,Iu=`DhcpOptionsId`,Lu=`DeleteOnTermination`,Ru=`DeletePlacementGroup`,zu=`DeletePlacementGroupRequest`,Bu=`DescribePlacementGroupsRequest`,Vu=`DescribePlacementGroupsResult`,Hu=`DescribePlacementGroups`,Uu=`DestinationPrefixListId`,Wu=`DeregistrationProtection`,m=`DryRun`,Gu=`DescribeRegionsRequest`,Ku=`DescribeRegionsResult`,qu=`DescribeRouteTablesRequest`,Ju=`DescribeRouteTablesResult`,Yu=`DescribeRouteTables`,Xu=`DestinationRegion`,Zu=`DescribeRegions`,Qu=`DeleteSecurityGroup`,$u=`DeleteSecurityGroupRequest`,ed=`DeleteSecurityGroupResult`,td=`DescribeSecurityGroupsRequest`,nd=`DescribeSecurityGroupsResult`,rd=`DescribeSecurityGroups`,id=`DeleteSnapshotRequest`,ad=`DeleteSubnetRequest`,od=`DescribeSnapshotsRequest`,sd=`DescribeSnapshotsResult`,cd=`DescribeSubnetsRequest`,ld=`DescribeSubnetsResult`,ud=`DeleteSnapshot`,dd=`DeleteSubnet`,fd=`DescribeSnapshots`,pd=`DescribeSubnets`,md=`DefaultTcpEstablishedTimeout`,hd=`DefaultThreadsPerCore`,gd=`DeprecationTime`,_d=`DefaultUdpStreamTimeout`,vd=`DefaultUdpTimeout`,yd=`DefaultVCpus`,bd=`DeleteVolumeRequest`,xd=`DeleteVpcRequest`,Sd=`DescribeVolumesRequest`,Cd=`DescribeVolumesResult`,wd=`DescribeVpcsRequest`,Td=`DescribeVpcsResult`,Ed=`DetachVolumeRequest`,Dd=`DeleteVolume`,Od=`DeleteVpc`,kd=`DescribeVolumes`,Ad=`DescribeVpcs`,jd=`DetachVolume`,Md=`Description`,Nd=`Device`,Pd=`Disks`,Fd=`EbsBlockDevice`,Id=`ExecutableByStringList`,Ld=`ExecutableBy`,Rd=`EbsCardIndex`,zd=`EbsCardInfoList`,Bd=`EbsCardInfo`,Vd=`EbsCards`,Hd=`EncryptionControl`,Ud=`EnableDns64`,Wd=`ElasticFileSystem`,Gd=`ElasticFileSystemExclusion`,Kd=`ElasticGpuAssociation`,qd=`ElasticGpuAssociationId`,Jd=`ElasticGpuAssociationList`,Yd=`ElasticGpuAssociationState`,Xd=`ElasticGpuAssociationTime`,Zd=`ElasticGpuAssociations`,Qd=`ElasticGpuId`,$d=`ElasticGpuSpecification`,ef=`ElasticGpuSpecifications`,tf=`ElasticInferenceAccelerator`,nf=`ElasticInferenceAcceleratorAssociation`,rf=`ElasticInferenceAcceleratorAssociationId`,af=`ElasticInferenceAcceleratorAssociationList`,of=`ElasticInferenceAcceleratorAssociationState`,sf=`ElasticInferenceAcceleratorAssociationTime`,cf=`ElasticInferenceAcceleratorArn`,lf=`ElasticInferenceAcceleratorAssociations`,uf=`ElasticInferenceAccelerators`,df=`EbsInstanceBlockDevice`,ff=`EbsInstanceBlockDeviceSpecification`,pf=`EncryptionInTransitSupported`,mf=`EbsInfo`,hf=`EfaInfo`,gf=`EnableLniAtDeviceIndex`,_f=`EbsOptimized`,vf=`EbsOptimizedInfo`,yf=`EgressOnlyInternetGateway`,bf=`EgressOnlyInternetGatewayExclusion`,xf=`EgressOnlyInternetGatewayId`,Sf=`EnclaveOptionsRequest`,Cf=`EbsOptimizedSupport`,wf=`EnclaveOptions`,Tf=`EnablePrimaryIpv6`,Ef=`EnaQueueCount`,Df=`EnableResourceNameDnsAAAARecord`,Of=`EnableResourceNameDnsARecord`,kf=`EnaSrdEnabled`,Af=`EnaSrdSpecification`,jf=`EnaSrdSpecificationRequest`,Mf=`EnaSrdSupported`,Nf=`EnaSrdUdpEnabled`,Pf=`EnaSrdUdpSpecification`,Ff=`EnaSrdUdpSpecificationRequest`,If=`EfaSupported`,Lf=`EncryptionSupport`,Rf=`EnaSupport`,zf=`EndTime`,Bf=`ExecutableUsers`,Vf=`Ebs`,Hf=`Enabled`,Uf=`Encrypted`,Wf=`Endpoint`,Gf=`Force`,Kf=`FpgaDeviceInfo`,qf=`FpgaDeviceInfoList`,Jf=`FpgaDeviceMemoryInfo`,Yf=`FlexibleEnaQueuesSupport`,Xf=`FpgaInfo`,Zf=`FilterList`,Qf=`FromPort`,$f=`FastRestored`,ep=`FullSnapshotSizeInBytes`,tp=`FreeTierEligible`,np=`Filters`,rp=`Filter`,ip=`Fpgas`,ap=`Groups`,op=`GroupArn`,sp=`GetConsoleOutput`,cp=`GetConsoleOutputRequest`,lp=`GetConsoleOutputResult`,up=`GroupDescription`,dp=`GpuDeviceInfo`,fp=`GpuDeviceInfoList`,pp=`GpuDeviceMemoryInfo`,mp=`GatewayId`,hp=`GroupIdentifierList`,gp=`GroupIdStringList`,_p=`GpuInfo`,vp=`GroupId`,yp=`GroupIds`,bp=`GroupIdentifier`,xp=`GroupLongName`,Sp=`GroupName`,Cp=`GroupNameStringList`,wp=`GroupNames`,Tp=`GroupOwnerId`,Ep=`GpuPartitionSize`,Dp=`Geography`,Op=`Gpus`,kp=`HttpEndpoint`,Ap=`HostId`,jp=`HibernationOptions`,Mp=`HibernationOptionsRequest`,Np=`HttpProtocolIpv6`,Pp=`HttpPutResponseHopLimit`,Fp=`HostResourceGroupArn`,Ip=`HibernationSupported`,Lp=`HttpTokens`,Rp=`HostnameType`,zp=`Hibernate`,Bp=`Hypervisor`,Vp=`Id`,Hp=`Ipv6Addresses`,Up=`Ipv6AddressAttribute`,Wp=`Ipv6AddressCount`,Gp=`InstanceAttachmentEnaSrdSpecification`,Kp=`InstanceAttachmentEnaSrdUdpSpecification`,qp=`InferenceAcceleratorInfo`,Jp=`Ipv4AddressesPerInterface`,Yp=`Ipv6AddressesPerInterface`,Xp=`Ipv4AddressesPerSecondaryInterface`,Zp=`ImageAllowed`,Qp=`IpAddress`,$p=`Ipv6Address`,em=`InstanceBlockDeviceMapping`,tm=`InstanceBlockDeviceMappingList`,nm=`InstanceBlockDeviceMappingSpecification`,rm=`InstanceBlockDeviceMappingSpecificationList`,im=`Ipv6CidrBlock`,am=`Ipv6CidrBlockAssociationSet`,om=`Ipv6CidrBlockNetworkBorderGroup`,sm=`Ipv6CidrBlockState`,cm=`IncludeDeprecated`,lm=`InferenceDeviceInfo`,um=`InferenceDeviceInfoList`,dm=`InferenceDeviceMemoryInfo`,fm=`IncludeDisabled`,pm=`IsDefault`,mm=`IsEgress`,hm=`InternetGateway`,gm=`InternetGatewayAttachment`,_m=`InternetGatewayAttachmentList`,vm=`InternetGatewayBlockMode`,ym=`InternetGatewayExclusion`,bm=`InternetGatewayId`,xm=`InternetGatewayIdList`,Sm=`InternetGatewayIds`,Cm=`InternetGatewayList`,wm=`InternetGateways`,Tm=`InstanceId`,Em=`InstanceIpv6Address`,Dm=`InstanceIpv6AddressList`,Om=`InstanceInterruptionBehavior`,km=`IamInstanceProfile`,Am=`Ipv6IpamPoolId`,jm=`Ipv4IpamPoolId`,Mm=`InstanceIpv4PrefixList`,Nm=`InstanceIpv6PrefixList`,Pm=`IamInstanceProfileSpecification`,Fm=`InstanceIpv4Prefix`,Im=`InstanceIpv6Prefix`,Lm=`InstanceInitiatedShutdownBehavior`,Rm=`ImageIdStringList`,zm=`InstanceIdStringList`,Bm=`ImageId`,Vm=`ImageIds`,Hm=`InstanceIds`,Um=`ImportKeyPair`,Wm=`ImportKeyPairRequest`,Gm=`ImportKeyPairResult`,Km=`ImageLocation`,qm=`ImageList`,Jm=`InstanceLifecycle`,Ym=`InstanceList`,Xm=`InstanceMaintenanceOptions`,Zm=`InstanceMaintenanceOptionsRequest`,Qm=`InstanceMarketOptionsRequest`,$m=`InstanceMetadataOptionsRequest`,eh=`InstanceMetadataOptionsResponse`,th=`InstanceMarketOptions`,nh=`InstanceMetadataTags`,rh=`Ipv6Native`,ih=`InstanceNetworkInterface`,ah=`InstanceNetworkInterfaceAssociation`,oh=`InstanceNetworkInterfaceAttachment`,sh=`InstanceNetworkInterfaceList`,ch=`InstanceNetworkInterfaceSpecification`,lh=`InstanceNetworkInterfaceSpecificationList`,uh=`Ipv6NetmaskLength`,dh=`Ipv4NetmaskLength`,fh=`InstanceNetworkPerformanceOptions`,ph=`InstanceNetworkPerformanceOptionsRequest`,mh=`ImageOwnerAlias`,hh=`IpOwnerId`,gh=`InstanceOwnerId`,_h=`InstanceOwningService`,vh=`Ipv6PrefixCount`,yh=`Ipv4PrefixCount`,bh=`IpPermissionsEgress`,xh=`InstancePrivateIpAddress`,Sh=`InstancePrivateIpAddressList`,Ch=`IsPrimaryIpv6`,wh=`IncludePublicKey`,Th=`IpPermissionList`,Eh=`Ipv4PrefixList`,Dh=`Ipv6PrefixList`,Oh=`Ipv4PrefixSpecificationRequest`,kh=`Ipv6PrefixSpecificationRequest`,Ah=`Ipv6Prefixes`,jh=`IpPermissions`,Mh=`IpPermission`,Nh=`IpProtocol`,Ph=`Ipv6Prefix`,Fh=`Ipv6Pool`,Ih=`Ipv4Prefixes`,Lh=`Ipv4Prefix`,Rh=`IpRangeList`,zh=`Ipv6RangeList`,Bh=`IpRanges`,Vh=`IpRange`,Hh=`Ipv6Ranges`,Uh=`Ipv6Range`,Wh=`InstanceStateChange`,Gh=`InstanceStateChangeList`,Kh=`InstanceSecondaryInterfaceAttachment`,qh=`InstanceSecondaryInterfaceList`,Jh=`InstanceSecondaryInterfacePrivateIpAddress`,Yh=`InstanceSecondaryInterfacePrivateIpAddressList`,Xh=`InstanceSecondaryInterfacePrivateIpAddressListRequest`,Zh=`InstanceSecondaryInterfacePrivateIpAddressRequest`,Qh=`InstanceSecondaryInterfaceSpecificationListRequest`,$h=`InstanceSecondaryInterfaceSpecificationRequest`,eg=`InstanceSecondaryInterface`,tg=`InstanceStorageInfo`,ng=`InstanceStorageSupported`,rg=`ImdsSupport`,ig=`InstanceState`,ag=`IpSource`,og=`Ipv6Supported`,sg=`InstanceType`,cg=`InstanceTypeInfoList`,lg=`InstanceTypeInfo`,ug=`ImageType`,dg=`InstanceTenancy`,fg=`InstanceTypes`,pg=`InterfaceType`,mg=`Images`,hg=`Image`,gg=`Instance`,_g=`Instances`,vg=`Iops`,yg=`Key`,bg=`KeyFormat`,xg=`KeyFingerprint`,Sg=`KernelId`,Cg=`KmsKeyId`,wg=`KeyMaterial`,Tg=`KeyName`,Eg=`KeyNameStringList`,Dg=`KeyNames`,Og=`KeyPairs`,kg=`KeyPairId`,Ag=`KeyPairIdStringList`,jg=`KeyPairIds`,Mg=`KeyPairInfo`,Ng=`KeyPairList`,Pg=`KeyPair`,Fg=`KeyType`,Ig=`Kernel`,Lg=`LicenseConfigurationArn`,Rg=`LicenseConfigurationRequest`,zg=`LicenseConfiguration`,Bg=`LambdaExclusion`,Vg=`LogicalGpuCount`,Hg=`LocalGatewayId`,Ug=`LinkedGroupId`,Wg=`LicenseList`,Gg=`LastLaunchedTime`,Kg=`LicenseSpecifications`,qg=`LicenseSpecificationListRequest`,Jg=`LicenseSpecification`,Yg=`LaunchTemplate`,Xg=`LaunchTemplateId`,Zg=`LaunchTemplateName`,Qg=`LaunchTemplateSpecification`,$g=`LaunchTime`,e_=`Latest`,t_=`Lambda`,n_=`Licenses`,r_=`Location`,i_=`MultiAttachEnabled`,a_=`MediaAcceleratorInfo`,o_=`MacAddress`,s_=`MaximumBandwidthInMbps`,c_=`MapCustomerOwnedIpOnLaunch`,l_=`MaxCount`,u_=`MinCount`,d_=`MediaDeviceInfo`,f_=`MediaDeviceInfoList`,p_=`MediaDeviceMemoryInfo`,m_=`MaximumEbsAttachments`,h_=`MaximumEbsCards`,g_=`MaximumEfaInterfaces`,__=`MaximumEnaQueueCount`,v_=`MaximumEnaQueueCountPerInterface`,y_=`MaximumIops`,b_=`ModifyInstanceAttributeRequest`,x_=`ModifyInstanceAttribute`,S_=`MemoryInfo`,C_=`MaximumNetworkCards`,w_=`MaximumNetworkInterfaces`,T_=`MetadataOptions`,E_=`MaintenanceOptions`,D_=`MapPublicIpOnLaunch`,O_=`MaxPrice`,k_=`MaxResults`,A_=`MaximumSecondaryNetworkInterfaces`,j_=`ModificationState`,M_=`MarketType`,N_=`MaximumThroughputInMBps`,P_=`ModifyVolumeRequest`,F_=`ModifyVolumeResult`,I_=`ModifyVolume`,L_=`Main`,R_=`Manufacturer`,z_=`Managed`,B_=`Message`,V_=`Messages`,H_=`Mode`,U_=`Monitoring`,W_=`Name`,G_=`NetworkBorderGroup`,K_=`NetworkCards`,q_=`NetworkCardIndex`,J_=`NetworkCardInfoList`,Y_=`NetworkCardInfo`,X_=`NoDevice`,Z_=`NeuronDeviceCoreInfo`,Q_=`NeuronDeviceInfo`,$_=`NeuronDeviceInfoList`,ev=`NeuronDeviceMemoryInfo`,tv=`NeuronDevices`,nv=`NitroEnclavesSupport`,rv=`NatGateway`,iv=`NatGatewayExclusion`,av=`NatGatewayId`,ov=`NetworkInterfaceId`,sv=`NetworkInterfaces`,cv=`NetworkInfo`,lv=`NeuronInfo`,uv=`NetworkPerformanceOptions`,dv=`NetworkPerformance`,fv=`NoReboot`,pv=`NvmeSupport`,mv=`NitroTpmInfo`,hv=`NitroTpmSupport`,gv=`NitroTpmSupportedVersionsList`,_v=`NextToken`,vv=`NestedVirtualization`,yv=`Origin`,bv=`OutpostArn`,xv=`OwnerAlias`,Sv=`OwnerId`,Cv=`OptInStatus`,wv=`OriginalIops`,Tv=`OwnerIds`,Ev=`OriginalMultiAttachEnabled`,Dv=`OdbNetworkArn`,Ov=`OperatorRequest`,kv=`OperatorResponse`,Av=`OwnerStringList`,jv=`OriginalSize`,Mv=`OriginalThroughput`,Nv=`OriginalVolumeType`,Pv=`Operator`,Fv=`Output`,Iv=`Owners`,Lv=`Owner`,Rv=`Principal`,zv=`PeakBandwidthInGbps`,Bv=`ProductCodeId`,Vv=`ProductCodeList`,Hv=`ProductCodeType`,Uv=`PartitionCount`,Wv=`ProductCode`,Gv=`ProductCodes`,Kv=`PrivateDnsName`,qv=`PrivateDnsNameOptions`,Jv=`PrivateDnsNameOptionsOnLaunch`,Yv=`PrivateDnsNameOptionsRequest`,Xv=`PrivateDnsNameOptionsResponse`,Zv=`PublicDnsName`,Qv=`PlatformDetails`,$v=`PlacementGroup`,ey=`PlacementGroupInfo`,ty=`PlacementGroupIdStringList`,ny=`PlacementGroupList`,ry=`PlacementGroupStrategyList`,iy=`PlacementGroups`,ay=`PublicIp`,oy=`PrivateIpAddressCount`,sy=`PrivateIpAddressSpecification`,cy=`PrivateIpAddressSpecificationList`,ly=`PrivateIpAddress`,uy=`PrivateIpAddresses`,dy=`PublicIpAddress`,fy=`PublicIpv4Pool`,py=`PrimaryIpv6`,my=`ProcessorInfo`,hy=`PublicKey`,gy=`PublicKeyMaterial`,_y=`PrefixListId`,vy=`PrefixListIdList`,yy=`PrefixListIds`,by=`PartitionNumber`,xy=`PeeringStatus`,Sy=`PhcSupport`,Cy=`PreviousState`,wy=`PresignedUrl`,Ty=`PropagatingVgw`,Ey=`PropagatingVgwList`,Dy=`PropagatingVgws`,Oy=`ParentZoneId`,ky=`ParentZoneName`,Ay=`Platform`,jy=`Placement`,My=`Primary`,Ny=`Progress`,Py=`Public`,Fy=`Return`,Iy=`RestorableByUserIds`,Ly=`RestorableBy`,Ry=`RootDeviceName`,zy=`RootDeviceType`,By=`RootDeviceTypeList`,Vy=`RestoreExpiryTime`,Hy=`ResourceExclusions`,Uy=`RegionGeography`,Wy=`ReferencedGroupId`,Gy=`ReferencedGroupInfo`,Ky=`RegionGeographyList`,qy=`RunInstancesMonitoringEnabled`,Jy=`RebootInstancesRequest`,Yy=`RunInstancesRequest`,Xy=`RunInstancesUserData`,Zy=`RamdiskId`,Qy=`ReservationId`,$y=`RebootInstances`,eb=`RequesterId`,tb=`RunInstances`,nb=`RegionList`,rb=`ReservationList`,ib=`RouteList`,ab=`RebootMigrationSupport`,ob=`RebootMigration`,sb=`RegionName`,cb=`RegionNameStringList`,lb=`RegionNames`,ub=`ReferencedSecurityGroup`,db=`RevokeSecurityGroupEgress`,fb=`RevokeSecurityGroupEgressRequest`,pb=`RevokeSecurityGroupEgressResult`,mb=`RevokeSecurityGroupIngressRequest`,hb=`RevokeSecurityGroupIngressResult`,gb=`RevokeSecurityGroupIngress`,_b=`RevokedSecurityGroupRule`,vb=`RevokedSecurityGroupRuleList`,yb=`RevokedSecurityGroupRules`,bb=`RouteTableAssociation`,xb=`RouteTableAssociationId`,Sb=`RouteTableAssociationList`,Cb=`RouteTableAssociationState`,wb=`RouteTableId`,Tb=`RouteTableIdStringList`,Eb=`RouteTableIds`,Db=`RouteTableList`,Ob=`ResourceType`,kb=`RouteTable`,Ab=`RouteTables`,jb=`Ramdisk`,Mb=`Regions`,Nb=`Region`,Pb=`Reservations`,Fb=`Reservation`,Ib=`Route`,Lb=`Routes`,Rb=`SupportedAdditionalProcessorFeatureList`,zb=`SubnetArn`,Bb=`SupportedArchitectures`,Vb=`SupportedBootModes`,Hb=`SubnetCidrBlockState`,Ub=`SustainedClockSpeedInGhz`,Wb=`SourceDestCheck`,Gb=`SpreadDomain`,Kb=`SupportedFeatures`,qb=`SubGeography`,Jb=`SecurityGroupArn`,Yb=`SecurityGroupId`,Xb=`SecurityGroupIdStringList`,Zb=`SecurityGroupIds`,Qb=`SecurityGroupList`,$b=`SecurityGroupRules`,ex=`SecurityGroupRuleArn`,tx=`SecurityGroupRuleIds`,nx=`SecurityGroupRuleIdList`,rx=`SecurityGroupRuleId`,ix=`SecurityGroupRuleList`,ax=`SecurityGroupRule`,ox=`SecurityGroupStringList`,sx=`SecurityGroups`,cx=`SecurityGroup`,lx=`SubnetIds`,ux=`SubnetIpv6CidrBlockAssociation`,dx=`SubnetIpv6CidrBlockAssociationSet`,fx=`SizeInGB`,px=`SourceImageId`,mx=`SecondaryInterfaceId`,hx=`SourceInstanceId`,gx=`SizeInMiB`,_x=`SpotInstanceRequestId`,vx=`SourceImageRegion`,yx=`StartInstancesRequest`,bx=`StartInstancesResult`,xx=`StopInstancesRequest`,Sx=`StopInstancesResult`,Cx=`SnapshotIdStringList`,wx=`SubnetIdStringList`,Tx=`SpotInstanceType`,Ex=`SecondaryInterfaces`,Dx=`SecondaryInterface`,Ox=`SnapshotId`,kx=`SnapshotIds`,Ax=`StartingInstances`,jx=`StartInstances`,Mx=`StoppingInstances`,Nx=`StopInstances`,Px=`SubnetId`,Fx=`SnapshotLocation`,Ix=`SnapshotList`,Lx=`SpreadLevel`,Rx=`SubnetList`,zx=`SpotMarketOptions`,Bx=`StatusMessage`,Vx=`StateMessage`,Hx=`SecondaryNetworkId`,Ux=`SriovNetSupport`,Wx=`SecondaryNetworkSupported`,Gx=`SpotOptions`,Kx=`SkipOsShutdown`,qx=`SecondaryPrivateIpAddressCount`,Jx=`SupportedRootDeviceTypes`,Yx=`SourceRegion`,Xx=`StateReason`,Zx=`SourceSecurityGroupName`,Qx=`SourceSecurityGroupOwnerId`,$x=`SourceSnapshotId`,eS=`SecondarySubnetId`,tS=`SupportedStrategies`,nS=`StartTime`,rS=`StateTransitionReason`,iS=`SseType`,aS=`StorageTier`,oS=`SupportedUsageClasses`,sS=`SensitiveUserData`,cS=`SourceVolumeId`,lS=`SupportedVirtualizationTypes`,uS=`SupportedVersions`,dS=`Size`,fS=`Snapshots`,pS=`Snapshot`,mS=`State`,hS=`Status`,gS=`Strategy`,_S=`Subnet`,vS=`Subnets`,yS=`Tags`,bS=`TcpEstablishedTimeout`,xS=`TotalFpgaMemoryInMiB`,SS=`TransitGatewayId`,CS=`TotalGpuMemoryInMiB`,wS=`TerminateInstances`,TS=`TotalInferenceMemoryInMiB`,ES=`TerminateInstancesRequest`,DS=`TerminateInstancesResult`,OS=`TargetIops`,kS=`TerminatingInstances`,AS=`TagList`,jS=`TargetMultiAttachEnabled`,MS=`TotalMediaMemoryInMiB`,NS=`TotalNeuronDeviceMemoryInMiB`,PS=`ToPort`,FS=`ThreadsPerCore`,IS=`ThreadsPerCoreList`,LS=`TagSpecifications`,RS=`TotalSizeInGB`,zS=`TagSpecificationList`,BS=`TagSpecification`,VS=`TargetSize`,HS=`TpmSupport`,US=`TargetThroughput`,WS=`TransferType`,GS=`TargetVolumeType`,KS=`Tag`,qS=`Tenancy`,JS=`Throughput`,YS=`Timestamp`,XS=`Type`,ZS=`UsageClassTypeList`,QS=`UserData`,$S=`UserId`,eC=`UserIdGroupPairs`,tC=`UserIdGroupPairList`,nC=`UserIdGroupPair`,rC=`UnknownIpPermissions`,iC=`UsageOperation`,aC=`UsageOperationUpdateTime`,oC=`UdpStreamTimeout`,sC=`UdpTimeout`,cC=`Value`,lC=`VolumeAttachmentList`,uC=`VolumeAttachment`,dC=`VpcCidrBlockAssociation`,fC=`VpcCidrBlockAssociationSet`,pC=`VpcCidrBlockState`,mC=`VCpuInfo`,hC=`ValidCores`,gC=`VpcEncryptionControl`,_C=`VpcEncryptionControlConfiguration`,vC=`VpcEncryptionControlExclusion`,yC=`VpcEncryptionControlExclusions`,bC=`VpcEncryptionControlId`,xC=`VpcEndpointId`,SC=`VpcId`,CC=`VpcIpv6CidrBlockAssociation`,wC=`VpcIpv6CidrBlockAssociationSet`,TC=`VolumeInitializationRate`,EC=`VolumeIdStringList`,DC=`VpcIdStringList`,OC=`VolumeId`,kC=`VolumeIds`,AC=`VpcIds`,jC=`VpcLattice`,MC=`VpcLatticeExclusion`,NC=`VolumeList`,PC=`VpcList`,FC=`VolumeModification`,IC=`VirtualName`,LC=`VolumeOwnerId`,RC=`VpcPeeringConnectionId`,zC=`VpcPeeringExclusion`,BC=`VirtualPrivateGateway`,VC=`VirtualPrivateGatewayExclusion`,HC=`VpcPeering`,UC=`ValueStringList`,WC=`VolumeSize`,GC=`VolumeType`,KC=`VirtualizationTypeList`,qC=`ValidThreadsPerCore`,JC=`VirtualizationType`,YC=`ValidUntil`,XC=`Values`,ZC=`Version`,QC=`Volumes`,$C=`Volume`,ew=`Vpc`,tw=`Vpcs`,nw=`WorkloadsList`,rw=`Workloads`,iw=`ZoneId`,aw=`ZoneIdStringList`,ow=`ZoneIds`,sw=`ZoneName`,cw=`ZoneNameStringList`,lw=`ZoneNames`,uw=`ZoneType`,dw=`additionalFlexibleNetworkInterfaces`,fw=`availableIpAddressCount`,pw=`assignIpv6AddressOnCreation`,mw=`additionalInfo`,hw=`associationId`,gw=`attachmentId`,_w=`amiLaunchIndex`,vw=`attachmentLimitType`,yw=`associatePublicIpAddress`,bw=`amazonProvidedIpv6CidrBlock`,xw=`autoRecoverySupported`,Sw=`associatedResource`,Cw=`autoRecovery`,ww=`associationState`,Tw=`amdSevSnp`,Ew=`associationSet`,Dw=`attachmentSet`,Ow=`attachTime`,kw=`availabilityZone`,Aw=`availabilityZoneId`,jw=`availabilityZoneInfo`,Mw=`accelerators`,Nw=`affinity`,Pw=`arn`,Fw=`architecture`,Iw=`association`,Lw=`attachment`,Rw=`attribute`,zw=`baselineBandwidthInGbps`,Bw=`baselineBandwidthInMbps`,Vw=`blockDeviceMapping`,Hw=`baselineIops`,Uw=`bootMode`,Ww=`bareMetal`,Gw=`blockPublicAccessStates`,Kw=`burstablePerformanceSupported`,qw=`baselineThroughputInMBps`,Jw=`bandwidthWeighting`,Yw=`bandwidthWeightings`,Xw=`cidrBlock`,Zw=`cidrBlockAssociationSet`,Qw=`capacityBlockId`,$w=`cidrBlockState`,eT=`coreCount`,tT=`completionDurationMinutes`,nT=`creationDate`,rT=`carrierGatewayId`,iT=`currentGeneration`,aT=`carrierIp`,oT=`currentInstanceBootMode`,sT=`cidrIp`,cT=`cidrIpv6`,lT=`cidrIpv4`,uT=`coreInfo`,dT=`coreNetworkArn`,fT=`cpuOptions`,pT=`customerOwnedIp`,mT=`customerOwnedIpv4Pool`,hT=`capacityReservationId`,gT=`capacityReservationPreference`,_T=`capacityReservationResourceGroupArn`,vT=`capacityReservationSpecification`,yT=`capacityReservationTarget`,bT=`currentState`,xT=`clientToken`,ST=`connectionTrackingConfiguration`,CT=`completionTime`,wT=`createTime`,TT=`code`,ET=`configured`,DT=`count`,OT=`disableApiTermination`,kT=`destinationCidrBlock`,AT=`defaultCores`,jT=`dataEncryptionKeyId`,MT=`defaultEnaQueueCountPerInterface`,NT=`defaultForAz`,PT=`dedicatedHostsSupported`,FT=`deviceIndex`,IT=`destinationIpv6CidrBlock`,LT=`deviceName`,RT=`defaultNetworkCardIndex`,zT=`dnsName`,BT=`dhcpOptionsId`,VT=`deleteOnTermination`,HT=`destinationPrefixListId`,UT=`deregistrationProtection`,h=`dryRun`,WT=`destinationRegion`,GT=`defaultTcpEstablishedTimeout`,KT=`defaultThreadsPerCore`,qT=`deprecationTime`,JT=`defaultUdpStreamTimeout`,YT=`defaultUdpTimeout`,XT=`defaultVCpus`,ZT=`description`,QT=`device`,$T=`disks`,eE=`ebsCardIndex`,tE=`ebsCardSet`,nE=`encryptionControl`,rE=`enableDns64`,iE=`elasticFileSystem`,aE=`elasticGpuAssociationId`,oE=`elasticGpuAssociationState`,sE=`elasticGpuAssociationSet`,cE=`elasticGpuAssociationTime`,lE=`elasticGpuId`,uE=`elasticInferenceAcceleratorArn`,dE=`elasticInferenceAcceleratorAssociationId`,fE=`elasticInferenceAcceleratorAssociationState`,pE=`elasticInferenceAcceleratorAssociationSet`,mE=`elasticInferenceAcceleratorAssociationTime`,hE=`encryptionInTransitSupported`,gE=`ebsInfo`,_E=`efaInfo`,vE=`enableLniAtDeviceIndex`,yE=`ebsOptimized`,bE=`ebsOptimizedInfo`,xE=`egressOnlyInternetGateway`,SE=`egressOnlyInternetGatewayId`,CE=`ebsOptimizedSupport`,wE=`enclaveOptions`,TE=`enaQueueCount`,g=`ec2QueryName`,EE=`enableResourceNameDnsAAAARecord`,DE=`enableResourceNameDnsARecord`,OE=`enaSrdEnabled`,kE=`enaSrdSpecification`,AE=`enaSrdSupported`,jE=`enaSrdUdpEnabled`,ME=`enaSrdUdpSpecification`,NE=`efaSupported`,PE=`encryptionSupport`,FE=`enaSupport`,IE=`endTime`,LE=`ebs`,RE=`enabled`,zE=`encrypted`,BE=`flexibleEnaQueuesSupport`,VE=`fpgaInfo`,HE=`fromPort`,UE=`fastRestored`,WE=`fullSnapshotSizeInBytes`,GE=`freeTierEligible`,KE=`force`,qE=`fpgas`,JE=`groupArn`,YE=`groupDescription`,XE=`gatewayId`,ZE=`gpuInfo`,QE=`groupId`,$E=`groupLongName`,eD=`groupName`,tD=`groupOwnerId`,nD=`gpuPartitionSize`,rD=`geographySet`,iD=`groupSet`,aD=`gpus`,oD=`groups`,sD=`hypervisor`,cD=`httpEndpoint`,lD=`hostId`,uD=`hibernationOptions`,dD=`httpProtocolIpv6`,fD=`httpPutResponseHopLimit`,pD=`hostResourceGroupArn`,mD=`hibernationSupported`,hD=`httpTokens`,gD=`hostnameType`,_D=`id`,vD=`ipv6AddressAttribute`,yD=`ipv6AddressCount`,bD=`inferenceAcceleratorInfo`,xD=`ipv4AddressesPerInterface`,SD=`ipv6AddressesPerInterface`,CD=`ipv4AddressesPerSecondaryInterface`,wD=`ipv6AddressesSet`,TD=`imageAllowed`,ED=`ipAddress`,DD=`ipv6Address`,OD=`ipv6CidrBlock`,kD=`ipv6CidrBlockAssociationSet`,AD=`ipv6CidrBlockState`,jD=`isDefault`,MD=`isEgress`,ND=`internetGateway`,PD=`internetGatewayBlockMode`,FD=`internetGatewayId`,ID=`internetGatewaySet`,LD=`instanceId`,RD=`iamInstanceProfile`,zD=`instanceInitiatedShutdownBehavior`,BD=`imageId`,VD=`imageLocation`,HD=`instanceLifecycle`,UD=`instanceMetadataTags`,WD=`ipv6Native`,GD=`imageOwnerAlias`,KD=`imageOwnerId`,qD=`instanceOwnerId`,JD=`ipOwnerId`,YD=`instanceOwningService`,XD=`ipPermissionsEgress`,ZD=`isPrimaryIpv6`,QD=`ipv4PrefixSet`,$D=`ipv6PrefixSet`,eO=`ipProtocol`,tO=`ipPermissions`,nO=`ipv4Prefix`,rO=`ipv6Pool`,iO=`ipv6Prefix`,aO=`isPublic`,oO=`ipRanges`,sO=`ipv6Ranges`,cO=`instanceStorageInfo`,lO=`instanceStorageSupported`,uO=`imagesSet`,dO=`imageState`,fO=`imdsSupport`,pO=`instancesSet`,mO=`instanceState`,hO=`ipSource`,gO=`ipv6Supported`,_O=`instanceType`,vO=`instanceTypeSet`,yO=`idempotencyToken`,bO=`imageType`,xO=`instanceTenancy`,SO=`interfaceType`,CO=`iops`,_=`item`,wO=`key`,TO=`keyFingerprint`,EO=`kernelId`,DO=`kmsKeyId`,OO=`keyMaterial`,kO=`keyName`,AO=`keyPairId`,jO=`keySet`,MO=`keyType`,NO=`kernel`,PO=`licenseConfigurationArn`,FO=`logicalGpuCount`,IO=`localGatewayId`,LO=`linkedGroupId`,RO=`lastLaunchedTime`,zO=`licenseSet`,BO=`launchTime`,VO=`lambda`,HO=`multiAttachEnabled`,UO=`mediaAcceleratorInfo`,WO=`macAddress`,GO=`maximumBandwidthInMbps`,KO=`mapCustomerOwnedIpOnLaunch`,qO=`maximumEbsAttachments`,JO=`maximumEbsCards`,YO=`maximumEfaInterfaces`,XO=`maximumEnaQueueCount`,ZO=`maximumEnaQueueCountPerInterface`,QO=`maximumIops`,$O=`memoryInfo`,ek=`maximumNetworkCards`,tk=`maximumNetworkInterfaces`,nk=`metadataOptions`,rk=`maintenanceOptions`,ik=`mapPublicIpOnLaunch`,ak=`maxResults`,ok=`messageSet`,sk=`maximumSecondaryNetworkInterfaces`,ck=`modificationState`,lk=`maximumThroughputInMBps`,uk=`main`,dk=`manufacturer`,fk=`managed`,pk=`message`,mk=`monitoring`,hk=`mode`,gk=`name`,_k=`networkBorderGroup`,vk=`networkCards`,yk=`networkCardIndex`,bk=`noDevice`,xk=`neuronDevices`,Sk=`nitroEnclavesSupport`,Ck=`natGateway`,wk=`natGatewayId`,Tk=`networkInterfaceId`,Ek=`networkInterfaceSet`,Dk=`networkInterface`,Ok=`networkInfo`,kk=`neuronInfo`,Ak=`networkPerformanceOptions`,jk=`networkPerformance`,Mk=`noReboot`,Nk=`nvmeSupport`,Pk=`nitroTpmInfo`,Fk=`nitroTpmSupport`,Ik=`nextToken`,Lk=`nestedVirtualization`,Rk=`origin`,zk=`outpostArn`,Bk=`ownerAlias`,Vk=`ownerId`,Hk=`optInStatus`,Uk=`originalIops`,Wk=`originalMultiAttachEnabled`,Gk=`odbNetworkArn`,Kk=`originalSize`,qk=`originalThroughput`,Jk=`originalVolumeType`,Yk=`operator`,Xk=`output`,Zk=`principal`,Qk=`peakBandwidthInGbps`,$k=`productCodes`,eA=`partitionCount`,tA=`productCode`,nA=`privateDnsNameOptions`,rA=`privateDnsNameOptionsOnLaunch`,iA=`privateDnsName`,aA=`publicDnsName`,oA=`platformDetails`,sA=`placementGroup`,cA=`placementGroupInfo`,lA=`placementGroupSet`,uA=`publicIp`,dA=`privateIpAddressesSet`,fA=`privateIpAddressSet`,pA=`privateIpAddress`,mA=`publicIpv4Pool`,hA=`processorInfo`,gA=`publicKey`,_A=`publicKeyMaterial`,vA=`prefixListId`,yA=`prefixListIds`,bA=`partitionNumber`,xA=`peeringStatus`,SA=`phcSupport`,CA=`previousState`,wA=`presignedUrl`,TA=`propagatingVgwSet`,EA=`parentZoneId`,DA=`parentZoneName`,OA=`platform`,kA=`placement`,AA=`primary`,jA=`progress`,MA=`return`,NA=`rootDeviceName`,PA=`rootDeviceType`,FA=`restoreExpiryTime`,IA=`regionEndpoint`,LA=`resourceExclusions`,RA=`referencedGroupId`,zA=`referencedGroupInfo`,BA=`reservationId`,VA=`ramdiskId`,HA=`regionInfo`,UA=`requesterId`,WA=`rebootMigrationSupport`,GA=`rebootMigration`,KA=`regionName`,qA=`revokedSecurityGroupRuleSet`,JA=`reservationSet`,YA=`routeSet`,XA=`routeTableAssociationId`,ZA=`routeTableId`,QA=`routeTableSet`,$A=`resourceType`,ej=`routeTable`,tj=`ramdisk`,nj=`reason`,rj=`smithy.ts.sdk.synthetic.com.amazonaws.ec2`,ij=`supportedArchitectures`,aj=`subnetArn`,oj=`supportedBootModes`,sj=`sustainedClockSpeedInGhz`,cj=`sourceDestCheck`,lj=`spreadDomain`,uj=`supportedFeatures`,dj=`securityGroupArn`,fj=`securityGroupInfo`,pj=`securityGroupRuleArn`,mj=`securityGroupRuleId`,hj=`securityGroupRuleSet`,gj=`subGeographySet`,_j=`sizeInGB`,vj=`sourceInstanceId`,yj=`secondaryInterfaceId`,bj=`sourceImageId`,xj=`sizeInMiB`,Sj=`sourceImageRegion`,Cj=`spotInstanceRequestId`,wj=`secondaryInterfaceSet`,Tj=`snapshotId`,Ej=`subnetId`,Dj=`spreadLevel`,Oj=`statusMessage`,kj=`stateMessage`,Aj=`secondaryNetworkId`,jj=`secondaryNetworkSupported`,Mj=`sriovNetSupport`,Nj=`secondaryPrivateIpAddressCount`,Pj=`supportedRootDeviceTypes`,Fj=`stateReason`,Ij=`sourceSecurityGroupName`,Lj=`sourceSecurityGroupOwnerId`,Rj=`secondarySubnetId`,zj=`snapshotSet`,Bj=`subnetSet`,Vj=`supportedStrategies`,Hj=`startTime`,Uj=`sseType`,Wj=`storageTier`,Gj=`supportedUsageClasses`,Kj=`sourceVolumeId`,qj=`supportedVirtualizationTypes`,Jj=`supportedVersions`,Yj=`size`,Xj=`state`,Zj=`status`,Qj=`strategy`,$j=`subnet`,eM=`tenancy`,tM=`tcpEstablishedTimeout`,nM=`totalFpgaMemoryInMiB`,rM=`transitGatewayId`,iM=`totalGpuMemoryInMiB`,aM=`totalInferenceMemoryInMiB`,oM=`targetIops`,sM=`targetMultiAttachEnabled`,cM=`totalMediaMemoryInMiB`,lM=`totalNeuronDeviceMemoryInMiB`,uM=`toPort`,dM=`threadsPerCore`,fM=`tagSet`,pM=`totalSizeInGB`,mM=`targetSize`,hM=`tpmSupport`,gM=`targetThroughput`,_M=`transferType`,vM=`targetVolumeType`,yM=`throughput`,bM=`timestamp`,xM=`type`,SM=`userData`,CM=`userId`,wM=`unknownIpPermissionSet`,TM=`usageOperation`,EM=`usageOperationUpdateTime`,DM=`udpStreamTimeout`,OM=`udpTimeout`,kM=`value`,AM=`vCpuInfo`,jM=`validCores`,MM=`vpcEncryptionControlId`,NM=`vpcId`,PM=`volumeInitializationRate`,FM=`volumeId`,IM=`vpcLattice`,LM=`volumeModification`,RM=`virtualName`,zM=`volumeOwnerId`,BM=`vpcPeeringConnectionId`,VM=`virtualPrivateGateway`,HM=`vpcPeering`,UM=`volumeSet`,WM=`volumeSize`,GM=`vpcSet`,KM=`volumeType`,qM=`validThreadsPerCore`,JM=`virtualizationType`,YM=`version`,XM=`vpc`,ZM=`workloadSet`,v=`xmlName`,QM=`zoneId`,$M=`zoneName`,eN=`zoneState`,tN=`zoneType`,y=`com.amazonaws.ec2`,nN=At.for(rj),rN=[-3,rj,`EC2ServiceException`,0,[],[]];nN.registerError(rN,ds);var iN=[nN],aN=[0,y,El,8,0],oN=[0,y,Xy,8,0],sN=[0,y,sS,8,0],cN=[3,y,Os,0,[wb,mp,fy,m,Px],[[0,{[g]:`RouteTableId`,[v]:ZA}],0,0,[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`SubnetId`,[v]:Ej}]],1],lN=[3,y,ks,0,[xs,Ps],[[0,{[g]:`AssociationId`,[v]:hw}],[()=>XI,{[g]:`AssociationState`,[v]:ww}]]],uN=[3,y,ys,0,[bm,SC,m],[[0,{[g]:`InternetGatewayId`,[v]:FD}],[0,{[g]:`VpcId`,[v]:NM}],[2,{[g]:`DryRun`,[v]:h}]],2],dN=[3,y,Ws,0,[Nd,Tm,OC,Rd,m],[0,0,0,1,[2,{[g]:`DryRun`,[v]:h}]],3],fN=[3,y,ps,0,[cC],[[2,{[g]:`Value`,[v]:kM}]]],pN=[3,y,Gs,0,[cC],[[0,{[g]:`Value`,[v]:kM}]]],mN=[3,y,Is,0,[vp,LS,m,Zx,Qx,Nh,Qf,PS,Jc,jh],[[0,{[g]:`GroupId`,[v]:QE}],[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`SourceSecurityGroupName`,[v]:Ij}],[0,{[g]:`SourceSecurityGroupOwnerId`,[v]:Lj}],[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[0,{[g]:`CidrIp`,[v]:sT}],[()=>bR,{[g]:`IpPermissions`,[v]:tO}]],1],hN=[3,y,Ls,0,[Fy,$b],[[2,{[g]:`Return`,[v]:MA}],[()=>tz,{[g]:`SecurityGroupRuleSet`,[v]:hj}]]],gN=[3,y,Rs,0,[Jc,Qf,vp,Sp,jh,Nh,Zx,Qx,PS,LS,m],[0,1,0,0,[()=>bR,0],0,0,0,1,[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}]]],_N=[3,y,zs,0,[Fy,$b],[[2,{[g]:`Return`,[v]:MA}],[()=>tz,{[g]:`SecurityGroupRuleSet`,[v]:hj}]]],vN=[3,y,qs,0,[Cv,V_,sb,sw,iw,Sp,G_,uw,ky,Oy,xp,Dp,qb,mS],[[0,{[g]:`OptInStatus`,[v]:Hk}],[()=>ML,{[g]:`MessageSet`,[v]:ok}],[0,{[g]:`RegionName`,[v]:KA}],[0,{[g]:`ZoneName`,[v]:$M}],[0,{[g]:`ZoneId`,[v]:QM}],[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`NetworkBorderGroup`,[v]:_k}],[0,{[g]:`ZoneType`,[v]:tN}],[0,{[g]:`ParentZoneName`,[v]:DA}],[0,{[g]:`ParentZoneId`,[v]:EA}],[0,{[g]:`GroupLongName`,[v]:$E}],[()=>AL,{[g]:`GeographySet`,[v]:rD}],[()=>NL,{[g]:`SubGeographySet`,[v]:gj}],[0,{[g]:`ZoneState`,[v]:eN}]]],yN=[3,y,Js,0,[W_],[[0,{[g]:`Name`,[v]:gk}]]],bN=[3,y,Qs,0,[B_],[[0,{[g]:`Message`,[v]:pk}]]],xN=[3,y,ec,0,[W_],[[0,{[g]:`Name`,[v]:gk}]]],SN=[3,y,fc,0,[cC],[[21,{[g]:`Value`,[v]:kM}]]],CN=[3,y,hc,0,[Vf,X_,Nu,IC],[[()=>VP,{[g]:`Ebs`,[v]:LE}],[0,{[g]:`NoDevice`,[v]:bk}],[0,{[g]:`DeviceName`,[v]:LT}],[0,{[g]:`VirtualName`,[v]:RM}]]],wN=[3,y,wc,0,[vm],[[0,{[g]:`InternetGatewayBlockMode`,[v]:PD}]]],TN=[3,y,hl,0,[ul,gl],[0,()=>DN]],EN=[3,y,ml,0,[ul,gl],[[0,{[g]:`CapacityReservationPreference`,[v]:gT}],[()=>ON,{[g]:`CapacityReservationTarget`,[v]:yT}]]],DN=[3,y,gl,0,[ll,fl],[0,0]],ON=[3,y,_l,0,[ll,fl],[[0,{[g]:`CapacityReservationId`,[v]:hT}],[0,{[g]:`CapacityReservationResourceGroupArn`,[v]:_T}]]],kN=[3,y,Bl,0,[bS,oC,sC],[1,1,1]],AN=[3,y,Vl,0,[bS,oC,sC],[[1,{[g]:`TcpEstablishedTimeout`,[v]:tM}],[1,{[g]:`UdpStreamTimeout`,[v]:DM}],[1,{[g]:`UdpTimeout`,[v]:OM}]]],jN=[3,y,Tl,0,[Yx,$x,Md,Fu,Xu,Uf,Cg,wy,LS,Lc,eu,m],[0,0,0,0,[0,{[g]:`DestinationRegion`,[v]:WT}],[2,{[g]:`Encrypted`,[v]:zE}],[0,{[g]:`KmsKeyId`,[v]:DO}],[()=>aN,{[g]:`PresignedUrl`,[v]:wA}],[()=>uz,{[v]:BS}],1,0,[2,{[g]:`DryRun`,[v]:h}]],2],MN=[3,y,Dl,0,[yS,Ox],[[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`SnapshotId`,[v]:Tj}]]],NN=[3,y,nl,0,[Fc,FS,Vs,vv],[[1,{[g]:`CoreCount`,[v]:eT}],[1,{[g]:`ThreadsPerCore`,[v]:dM}],[0,{[g]:`AmdSevSnp`,[v]:Tw}],[0,{[g]:`NestedVirtualization`,[v]:Lk}]]],PN=[3,y,al,0,[Fc,FS,Vs,vv],[1,1,0,0]],FN=[3,y,Kc,0,[Tm,W_,LS,Fx,m,Md,fv,vc],[[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`Name`,[v]:gk}],[()=>uz,{[v]:BS}],0,[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`Description`,[v]:ZT}],[2,{[g]:`NoReboot`,[v]:Mk}],[()=>IL,{[g]:`BlockDeviceMapping`,[v]:Vw}]],2],IN=[3,y,qc,0,[Bm],[[0,{[g]:`ImageId`,[v]:BD}]]],LN=[3,y,Wc,0,[LS,m],[[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}]]],RN=[3,y,Gc,0,[hm],[[()=>ZF,{[g]:`InternetGateway`,[v]:ND}]]],zN=[3,y,el,0,[Tg,Fg,LS,bg,m],[0,0,[()=>uz,{[v]:BS}],0,[2,{[g]:`DryRun`,[v]:h}]],1],BN=[3,y,sl,0,[Uv,LS,Lx,Ug,Pv,m,Sp,gS],[1,[()=>uz,{[v]:BS}],0,0,()=>wI,[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`Strategy`,[v]:Qj}]]],VN=[3,y,cl,0,[$v],[[()=>DI,{[g]:`PlacementGroup`,[v]:sA}]]],HN=[3,y,dl,0,[wb,Uu,xC,SS,Hg,zc,tl,Dv,m,iu,mp,fu,xf,Tm,ov,RC,av],[[0,{[g]:`RouteTableId`,[v]:ZA}],0,0,0,0,0,0,0,[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`DestinationCidrBlock`,[v]:kT}],[0,{[g]:`GatewayId`,[v]:XE}],[0,{[g]:`DestinationIpv6CidrBlock`,[v]:IT}],[0,{[g]:`EgressOnlyInternetGatewayId`,[v]:SE}],[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`NetworkInterfaceId`,[v]:Tk}],[0,{[g]:`VpcPeeringConnectionId`,[v]:BM}],[0,{[g]:`NatGatewayId`,[v]:wk}]],1],UN=[3,y,pl,0,[Fy],[[2,{[g]:`Return`,[v]:MA}]]],WN=[3,y,vl,0,[SC,LS,Ll,m],[[0,{[g]:`VpcId`,[v]:NM}],[()=>uz,{[v]:BS}],[0,4],[2,{[g]:`DryRun`,[v]:h}]],1],GN=[3,y,yl,0,[kb,Ll],[[()=>JI,{[g]:`RouteTable`,[v]:ej}],[0,{[g]:`ClientToken`,[v]:xT}]]],KN=[3,y,Cl,0,[Md,Sp,SC,LS,m],[[0,{[v]:up}],0,0,[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}]],2],qN=[3,y,wl,0,[vp,yS,Jb],[[0,{[g]:`GroupId`,[v]:QE}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`SecurityGroupArn`,[v]:dj}]]],JN=[3,y,Ol,0,[OC,Md,bv,LS,r_,m],[0,0,0,[()=>uz,{[v]:BS}],0,[2,{[g]:`DryRun`,[v]:h}]],1],YN=[3,y,kl,0,[SC,LS,qs,Xs,Ac,im,bv,rh,jm,dh,Am,uh,m],[0,[()=>uz,{[v]:BS}],0,0,0,0,0,2,0,1,0,1,[2,{[g]:`DryRun`,[v]:h}]],1],XN=[3,y,Al,0,[_S],[[()=>cL,{[g]:`Subnet`,[v]:$j}]]],ZN=[3,y,Wl,0,[qs,Xs,Uf,vg,Cg,bv,dS,Ox,GC,LS,i_,JS,Ll,TC,Pv,m],[0,0,[2,{[g]:`Encrypted`,[v]:zE}],1,0,0,1,0,0,[()=>uz,{[v]:BS}],2,1,[0,4],1,()=>wI,[2,{[g]:`DryRun`,[v]:h}]]],QN=[3,y,Gl,0,[Ac,Fh,im,jm,dh,Am,uh,om,gC,LS,m,dg,Es],[0,0,0,0,1,0,1,0,()=>wL,[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`InstanceTenancy`,[v]:xO}],[2,{[g]:`AmazonProvidedIpv6CidrBlock`,[v]:bw}]]],$N=[3,y,Kl,0,[ew],[[()=>bL,{[g]:`Vpc`,[v]:XM}]]],eP=[3,y,jl,0,[Ic],[0],1],tP=[3,y,au,0,[md,vd,_d],[[1,{[g]:`DefaultTcpEstablishedTimeout`,[v]:GT}],[1,{[g]:`DefaultUdpTimeout`,[v]:YT}],[1,{[g]:`DefaultUdpStreamTimeout`,[v]:JT}]]],nP=[3,y,Ou,0,[Tg,kg,m],[0,0,[2,{[g]:`DryRun`,[v]:h}]]],rP=[3,y,ku,0,[Fy,kg],[[2,{[g]:`Return`,[v]:MA}],[0,{[g]:`KeyPairId`,[v]:AO}]]],iP=[3,y,zu,0,[Sp,m],[[0,{[g]:`GroupName`,[v]:eD}],[2,{[g]:`DryRun`,[v]:h}]],1],aP=[3,y,$u,0,[vp,Sp,m],[0,0,[2,{[g]:`DryRun`,[v]:h}]]],oP=[3,y,ed,0,[Fy,vp],[[2,{[g]:`Return`,[v]:MA}],[0,{[g]:`GroupId`,[v]:QE}]]],sP=[3,y,id,0,[Ox,m],[0,[2,{[g]:`DryRun`,[v]:h}]],1],cP=[3,y,ad,0,[Px,m],[0,[2,{[g]:`DryRun`,[v]:h}]],1],lP=[3,y,bd,0,[OC,m],[0,[2,{[g]:`DryRun`,[v]:h}]],1],uP=[3,y,xd,0,[SC,m],[0,[2,{[g]:`DryRun`,[v]:h}]],1],dP=[3,y,tu,0,[lw,ow,fs,m,np],[[()=>Tz,{[v]:sw}],[()=>wz,{[v]:iw}],2,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],fP=[3,y,nu,0,[nc],[[()=>jL,{[g]:`AvailabilityZoneInfo`,[v]:jw}]]],pP=[3,y,_u,0,[Bf,Vm,Iv,cm,fm,k_,_v,m,np],[[()=>GL,{[v]:Ld}],[()=>QL,{[v]:Bm}],[()=>PR,{[v]:Lv}],2,2,1,0,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],mP=[3,y,vu,0,[_v,mg],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>$L,{[g]:`ImagesSet`,[v]:uO}]]],hP=[3,y,yu,0,[Hm,m,np,_v,k_],[[()=>rR,{[v]:Tm}],[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}],[0,{[g]:`NextToken`,[v]:Ik}],[1,{[g]:`MaxResults`,[v]:ak}]]],gP=[3,y,bu,0,[_v,Pb],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>GR,{[g]:`ReservationSet`,[v]:JA}]]],_P=[3,y,xu,0,[m,fg,np,k_,_v],[2,[64,{[v]:sg}],[()=>KL,{[v]:rp}],1,0]],vP=[3,y,Su,0,[fg,_v],[[()=>gR,{[g]:`InstanceTypeSet`,[v]:vO}],[0,{[g]:`NextToken`,[v]:Ik}]]],yP=[3,y,pu,0,[_v,k_,m,Sm,np],[0,1,[2,{[g]:`DryRun`,[v]:h}],[()=>vR,{[g]:`InternetGatewayId`,[v]:FD}],[()=>KL,{[v]:rp}]]],bP=[3,y,mu,0,[wm,_v],[[()=>yR,{[g]:`InternetGatewaySet`,[v]:ID}],[0,{[g]:`NextToken`,[v]:Ik}]]],xP=[3,y,Au,0,[Dg,jg,wh,m,np],[[()=>TR,{[v]:Tg}],[()=>ER,{[v]:kg}],2,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],SP=[3,y,ju,0,[Og],[[()=>DR,{[g]:`KeySet`,[v]:jO}]]],CP=[3,y,Bu,0,[yp,m,wp,np],[[()=>FR,{[v]:vp}],[2,{[g]:`DryRun`,[v]:h}],[64,{[g]:`GroupName`,[v]:eD}],[()=>KL,{[v]:rp}]]],wP=[3,y,Vu,0,[iy],[[()=>IR,{[g]:`PlacementGroupSet`,[v]:lA}]]],TP=[3,y,Gu,0,[lb,js,m,np],[[()=>WR,{[v]:sb}],2,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],EP=[3,y,Ku,0,[Mb],[[()=>UR,{[g]:`RegionInfo`,[v]:HA}]]],DP=[3,y,qu,0,[_v,k_,m,Eb,np],[0,1,[2,{[g]:`DryRun`,[v]:h}],[()=>XR,{[v]:wb}],[()=>KL,{[v]:rp}]]],OP=[3,y,Ju,0,[Ab,_v],[[()=>ZR,{[g]:`RouteTableSet`,[v]:QA}],[0,{[g]:`NextToken`,[v]:Ik}]]],kP=[3,y,td,0,[yp,wp,_v,k_,m,np],[[()=>XL,{[v]:vp}],[()=>ZL,{[v]:Sp}],0,1,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],AP=[3,y,nd,0,[_v,sx],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>$R,{[g]:`SecurityGroupInfo`,[v]:fj}]]],jP=[3,y,od,0,[k_,_v,Tv,Iy,kx,m,np],[1,0,[()=>PR,{[v]:Lv}],[64,{[v]:Ly}],[()=>rz,{[v]:Ox}],[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],MP=[3,y,sd,0,[_v,fS],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>iz,{[g]:`SnapshotSet`,[v]:zj}]]],NP=[3,y,cd,0,[np,lx,_v,k_,m],[[()=>KL,{[v]:rp}],[()=>az,{[v]:Px}],0,1,[2,{[g]:`DryRun`,[v]:h}]]],PP=[3,y,ld,0,[_v,vS],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>sz,{[g]:`SubnetSet`,[v]:Bj}]]],FP=[3,y,Sd,0,[kC,m,np,_v,k_],[[()=>_z,{[v]:OC}],[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}],[0,{[g]:`NextToken`,[v]:Ik}],[1,{[g]:`MaxResults`,[v]:ak}]]],IP=[3,y,Cd,0,[_v,QC],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>vz,{[g]:`VolumeSet`,[v]:UM}]]],LP=[3,y,wd,0,[np,AC,_v,k_,m],[[()=>KL,{[v]:rp}],[()=>bz,{[v]:SC}],0,1,[2,{[g]:`DryRun`,[v]:h}]]],RP=[3,y,Td,0,[_v,tw],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>Sz,{[g]:`VpcSet`,[v]:GM}]]],zP=[3,y,Ed,0,[OC,Nd,Gf,Tm,m],[0,0,2,0,[2,{[g]:`DryRun`,[v]:h}]],1],BP=[3,y,Eu,0,[fx,Zl,XS],[[1,{[g]:`SizeInGB`,[v]:_j}],[1,{[g]:`Count`,[v]:DT}],[0,{[g]:`Type`,[v]:xM}]]],VP=[3,y,Fd,0,[Lu,vg,Ox,WC,GC,Cg,JS,bv,qs,Uf,TC,Xs,Rd],[[2,{[g]:`DeleteOnTermination`,[v]:VT}],[1,{[g]:`Iops`,[v]:CO}],[0,{[g]:`SnapshotId`,[v]:Tj}],[1,{[g]:`VolumeSize`,[v]:WM}],[0,{[g]:`VolumeType`,[v]:KM}],[0,{[g]:`KmsKeyId`,[v]:DO}],[1,{[g]:`Throughput`,[v]:yM}],[0,{[g]:`OutpostArn`,[v]:zk}],[0,{[g]:`AvailabilityZone`,[v]:kw}],[2,{[g]:`Encrypted`,[v]:zE}],1,0,1]],HP=[3,y,Bd,0,[Rd,mc,Ec,bc,s_,N_,y_],[[1,{[g]:`EbsCardIndex`,[v]:eE}],[1,{[g]:`BaselineBandwidthInMbps`,[v]:Bw}],[1,{[g]:`BaselineThroughputInMBps`,[v]:qw}],[1,{[g]:`BaselineIops`,[v]:Hw}],[1,{[g]:`MaximumBandwidthInMbps`,[v]:GO}],[1,{[g]:`MaximumThroughputInMBps`,[v]:lk}],[1,{[g]:`MaximumIops`,[v]:QO}]]],UP=[3,y,mf,0,[Cf,Lf,vf,pv,m_,ws,h_,Vd],[[0,{[g]:`EbsOptimizedSupport`,[v]:CE}],[0,{[g]:`EncryptionSupport`,[v]:PE}],[()=>KP,{[g]:`EbsOptimizedInfo`,[v]:bE}],[0,{[g]:`NvmeSupport`,[v]:Nk}],[1,{[g]:`MaximumEbsAttachments`,[v]:qO}],[0,{[g]:`AttachmentLimitType`,[v]:vw}],[1,{[g]:`MaximumEbsCards`,[v]:JO}],[()=>BL,{[g]:`EbsCardSet`,[v]:tE}]]],WP=[3,y,df,0,[Us,Lu,hS,OC,Ms,LC,Pv,Rd],[[4,{[g]:`AttachTime`,[v]:Ow}],[2,{[g]:`DeleteOnTermination`,[v]:VT}],[0,{[g]:`Status`,[v]:Zj}],[0,{[g]:`VolumeId`,[v]:FM}],[0,{[g]:`AssociatedResource`,[v]:Sw}],[0,{[g]:`VolumeOwnerId`,[v]:zM}],[()=>TI,{[g]:`Operator`,[v]:Yk}],[1,{[g]:`EbsCardIndex`,[v]:eE}]]],GP=[3,y,ff,0,[OC,Lu],[[0,{[g]:`VolumeId`,[v]:FM}],[2,{[g]:`DeleteOnTermination`,[v]:VT}]]],KP=[3,y,vf,0,[mc,Ec,bc,s_,N_,y_],[[1,{[g]:`BaselineBandwidthInMbps`,[v]:Bw}],[1,{[g]:`BaselineThroughputInMBps`,[v]:qw}],[1,{[g]:`BaselineIops`,[v]:Hw}],[1,{[g]:`MaximumBandwidthInMbps`,[v]:GO}],[1,{[g]:`MaximumThroughputInMBps`,[v]:lk}],[1,{[g]:`MaximumIops`,[v]:QO}]]],qP=[3,y,hf,0,[g_],[[1,{[g]:`MaximumEfaInterfaces`,[v]:YO}]]],JP=[3,y,Kd,0,[Qd,qd,Yd,Xd],[[0,{[g]:`ElasticGpuId`,[v]:lE}],[0,{[g]:`ElasticGpuAssociationId`,[v]:aE}],[0,{[g]:`ElasticGpuAssociationState`,[v]:oE}],[0,{[g]:`ElasticGpuAssociationTime`,[v]:cE}]]],YP=[3,y,$d,0,[XS],[0],1],XP=[3,y,tf,0,[XS,Zl],[0,1],1],ZP=[3,y,nf,0,[cf,rf,of,sf],[[0,{[g]:`ElasticInferenceAcceleratorArn`,[v]:uE}],[0,{[g]:`ElasticInferenceAcceleratorAssociationId`,[v]:dE}],[0,{[g]:`ElasticInferenceAcceleratorAssociationState`,[v]:fE}],[4,{[g]:`ElasticInferenceAcceleratorAssociationTime`,[v]:mE}]]],QP=[3,y,jf,0,[kf,Pf],[2,()=>$P]],$P=[3,y,Ff,0,[Nf],[2]],eF=[3,y,wf,0,[Hf],[[2,{[g]:`Enabled`,[v]:RE}]]],tF=[3,y,Sf,0,[Hf],[2]],nF=[3,y,rp,0,[W_,XC],[0,[()=>mz,{[v]:cC}]]],rF=[3,y,Kf,0,[W_,R_,Zl,S_],[[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`Manufacturer`,[v]:dk}],[1,{[g]:`Count`,[v]:DT}],[()=>iF,{[g]:`MemoryInfo`,[v]:$O}]]],iF=[3,y,Jf,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],aF=[3,y,Xf,0,[ip,xS],[[()=>qL,{[g]:`Fpgas`,[v]:qE}],[1,{[g]:`TotalFpgaMemoryInMiB`,[v]:nM}]]],oF=[3,y,cp,0,[Tm,e_,m],[0,2,[2,{[g]:`DryRun`,[v]:h}]],1],sF=[3,y,lp,0,[Tm,YS,Fv],[[0,{[g]:`InstanceId`,[v]:LD}],[4,{[g]:`Timestamp`,[v]:bM}],[0,{[g]:`Output`,[v]:Xk}]]],cF=[3,y,dp,0,[W_,R_,Zl,Vg,Ep,rw,S_],[[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`Manufacturer`,[v]:dk}],[1,{[g]:`Count`,[v]:DT}],[1,{[g]:`LogicalGpuCount`,[v]:FO}],[1,{[g]:`GpuPartitionSize`,[v]:nD}],[()=>Cz,{[g]:`WorkloadSet`,[v]:ZM}],[()=>lF,{[g]:`MemoryInfo`,[v]:$O}]]],lF=[3,y,pp,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],uF=[3,y,_p,0,[Op,CS],[[()=>JL,{[g]:`Gpus`,[v]:aD}],[1,{[g]:`TotalGpuMemoryInMiB`,[v]:iM}]]],dF=[3,y,bp,0,[vp,Sp],[[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`GroupName`,[v]:eD}]]],fF=[3,y,jp,0,[Xl],[[2,{[g]:`Configured`,[v]:ET}]]],pF=[3,y,Mp,0,[Xl],[2]],mF=[3,y,km,0,[ac,Vp],[[0,{[g]:`Arn`,[v]:Pw}],[0,{[g]:`Id`,[v]:_D}]]],hF=[3,y,Pm,0,[ac,W_],[[0,{[g]:`Arn`,[v]:Pw}],[0,{[g]:`Name`,[v]:gk}]]],gF=[3,y,hg,0,[Qv,iC,vc,Md,Rf,Bp,mh,W_,Ry,zy,Ux,Xx,yS,JC,xc,HS,gd,rg,hx,Wu,Gg,Zp,px,vx,tp,Bm,Km,mS,Sv,Rc,Py,Gv,oc,ug,Sg,Zy,Ay],[[0,{[g]:`PlatformDetails`,[v]:oA}],[0,{[g]:`UsageOperation`,[v]:TM}],[()=>FL,{[g]:`BlockDeviceMapping`,[v]:Vw}],[0,{[g]:`Description`,[v]:ZT}],[2,{[g]:`EnaSupport`,[v]:FE}],[0,{[g]:`Hypervisor`,[v]:sD}],[0,{[g]:`ImageOwnerAlias`,[v]:GD}],[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`RootDeviceName`,[v]:NA}],[0,{[g]:`RootDeviceType`,[v]:PA}],[0,{[g]:`SriovNetSupport`,[v]:Mj}],[()=>aL,{[g]:`StateReason`,[v]:Fj}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VirtualizationType`,[v]:JM}],[0,{[g]:`BootMode`,[v]:Uw}],[0,{[g]:`TpmSupport`,[v]:hM}],[0,{[g]:`DeprecationTime`,[v]:qT}],[0,{[g]:`ImdsSupport`,[v]:fO}],[0,{[g]:`SourceInstanceId`,[v]:vj}],[0,{[g]:`DeregistrationProtection`,[v]:UT}],[0,{[g]:`LastLaunchedTime`,[v]:RO}],[2,{[g]:`ImageAllowed`,[v]:TD}],[0,{[g]:`SourceImageId`,[v]:bj}],[0,{[g]:`SourceImageRegion`,[v]:Sj}],[2,{[g]:`FreeTierEligible`,[v]:GE}],[0,{[g]:`ImageId`,[v]:BD}],[0,{[g]:`ImageLocation`,[v]:VD}],[0,{[g]:`ImageState`,[v]:dO}],[0,{[g]:`ImageOwnerId`,[v]:KD}],[0,{[g]:`CreationDate`,[v]:nT}],[2,{[g]:`IsPublic`,[v]:aO}],[()=>BR,{[g]:`ProductCodes`,[v]:$k}],[0,{[g]:`Architecture`,[v]:Fw}],[0,{[g]:`ImageType`,[v]:bO}],[0,{[g]:`KernelId`,[v]:EO}],[0,{[g]:`RamdiskId`,[v]:VA}],[0,{[g]:`Platform`,[v]:OA}]]],_F=[3,y,Wm,0,[Tg,gy,LS,m],[[0,{[g]:`KeyName`,[v]:kO}],[21,{[g]:`PublicKeyMaterial`,[v]:_A}],[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}]],2],vF=[3,y,Gm,0,[xg,Tg,kg,yS],[[0,{[g]:`KeyFingerprint`,[v]:TO}],[0,{[g]:`KeyName`,[v]:kO}],[0,{[g]:`KeyPairId`,[v]:AO}],[()=>lz,{[g]:`TagSet`,[v]:fM}]]],yF=[3,y,qp,0,[rc,TS],[[()=>eR,{[g]:`Accelerators`,[v]:Mw}],[1,{[g]:`TotalInferenceMemoryInMiB`,[v]:aM}]]],bF=[3,y,lm,0,[Zl,W_,R_,S_],[[1,{[g]:`Count`,[v]:DT}],[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`Manufacturer`,[v]:dk}],[()=>xF,{[g]:`MemoryInfo`,[v]:$O}]]],xF=[3,y,dm,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],SF=[3,y,gg,0,[oc,vc,Ll,_f,Rf,Bp,km,Jm,Zd,lf,sv,bv,Ry,zy,sx,Wb,_x,Ux,Xx,yS,JC,nl,Mc,ll,hl,jp,n_,T_,wf,xc,Qv,iC,aC,qv,$p,HS,E_,Hc,uv,Pv,Ex,Tm,Bm,mS,Kv,Zv,rS,Tg,Cs,Gv,sg,$g,jy,Sg,Zy,Ay,U_,Px,SC,ly,dy],[[0,{[g]:`Architecture`,[v]:Fw}],[()=>tR,{[g]:`BlockDeviceMapping`,[v]:Vw}],[0,{[g]:`ClientToken`,[v]:xT}],[2,{[g]:`EbsOptimized`,[v]:yE}],[2,{[g]:`EnaSupport`,[v]:FE}],[0,{[g]:`Hypervisor`,[v]:sD}],[()=>mF,{[g]:`IamInstanceProfile`,[v]:RD}],[0,{[g]:`InstanceLifecycle`,[v]:HD}],[()=>VL,{[g]:`ElasticGpuAssociationSet`,[v]:sE}],[()=>UL,{[g]:`ElasticInferenceAcceleratorAssociationSet`,[v]:pE}],[()=>cR,{[g]:`NetworkInterfaceSet`,[v]:Ek}],[0,{[g]:`OutpostArn`,[v]:zk}],[0,{[g]:`RootDeviceName`,[v]:NA}],[0,{[g]:`RootDeviceType`,[v]:PA}],[()=>YL,{[g]:`GroupSet`,[v]:iD}],[2,{[g]:`SourceDestCheck`,[v]:cj}],[0,{[g]:`SpotInstanceRequestId`,[v]:Cj}],[0,{[g]:`SriovNetSupport`,[v]:Mj}],[()=>aL,{[g]:`StateReason`,[v]:Fj}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VirtualizationType`,[v]:JM}],[()=>NN,{[g]:`CpuOptions`,[v]:fT}],[0,{[g]:`CapacityBlockId`,[v]:Qw}],[0,{[g]:`CapacityReservationId`,[v]:hT}],[()=>EN,{[g]:`CapacityReservationSpecification`,[v]:vT}],[()=>fF,{[g]:`HibernationOptions`,[v]:uD}],[()=>OR,{[g]:`LicenseSet`,[v]:zO}],[()=>PF,{[g]:`MetadataOptions`,[v]:nk}],[()=>eF,{[g]:`EnclaveOptions`,[v]:wE}],[0,{[g]:`BootMode`,[v]:Uw}],[0,{[g]:`PlatformDetails`,[v]:oA}],[0,{[g]:`UsageOperation`,[v]:TM}],[4,{[g]:`UsageOperationUpdateTime`,[v]:EM}],[()=>MI,{[g]:`PrivateDnsNameOptions`,[v]:nA}],[0,{[g]:`Ipv6Address`,[v]:DD}],[0,{[g]:`TpmSupport`,[v]:hM}],[()=>AF,{[g]:`MaintenanceOptions`,[v]:rk}],[0,{[g]:`CurrentInstanceBootMode`,[v]:oT}],[()=>zF,{[g]:`NetworkPerformanceOptions`,[v]:Ak}],[()=>TI,{[g]:`Operator`,[v]:Yk}],[()=>dR,{[g]:`SecondaryInterfaceSet`,[v]:wj}],[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`ImageId`,[v]:BD}],[()=>qF,{[g]:`InstanceState`,[v]:mO}],[0,{[g]:`PrivateDnsName`,[v]:iA}],[0,{[g]:`DnsName`,[v]:zT}],[0,{[g]:`Reason`,[v]:nj}],[0,{[g]:`KeyName`,[v]:kO}],[1,{[g]:`AmiLaunchIndex`,[v]:_w}],[()=>BR,{[g]:`ProductCodes`,[v]:$k}],[0,{[g]:`InstanceType`,[v]:_O}],[4,{[g]:`LaunchTime`,[v]:BO}],[()=>EI,{[g]:`Placement`,[v]:kA}],[0,{[g]:`KernelId`,[v]:EO}],[0,{[g]:`RamdiskId`,[v]:VA}],[0,{[g]:`Platform`,[v]:OA}],[()=>gI,{[g]:`Monitoring`,[v]:mk}],[0,{[g]:`SubnetId`,[v]:Ej}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`PrivateIpAddress`,[v]:pA}],[0,{[g]:`IpAddress`,[v]:ED}]]],CF=[3,y,Gp,0,[kf,Pf],[[2,{[g]:`EnaSrdEnabled`,[v]:OE}],[()=>wF,{[g]:`EnaSrdUdpSpecification`,[v]:ME}]]],wF=[3,y,Kp,0,[Nf],[[2,{[g]:`EnaSrdUdpEnabled`,[v]:jE}]]],TF=[3,y,em,0,[Nu,Vf],[[0,{[g]:`DeviceName`,[v]:LT}],[()=>WP,{[g]:`Ebs`,[v]:LE}]]],EF=[3,y,nm,0,[Nu,Vf,IC,X_],[[0,{[g]:`DeviceName`,[v]:LT}],[()=>GP,{[g]:`Ebs`,[v]:LE}],[0,{[g]:`VirtualName`,[v]:RM}],[0,{[g]:`NoDevice`,[v]:bk}]]],DF=[3,y,Fm,0,[Lh],[[0,{[g]:`Ipv4Prefix`,[v]:nO}]]],OF=[3,y,Em,0,[$p,Ch],[[0,{[g]:`Ipv6Address`,[v]:DD}],[2,{[g]:`IsPrimaryIpv6`,[v]:ZD}]]],kF=[3,y,Im,0,[Ph],[[0,{[g]:`Ipv6Prefix`,[v]:iO}]]],AF=[3,y,Xm,0,[Ns,ob],[[0,{[g]:`AutoRecovery`,[v]:Cw}],[0,{[g]:`RebootMigration`,[v]:GA}]]],jF=[3,y,Zm,0,[Ns],[0]],MF=[3,y,Qm,0,[M_,Gx],[0,()=>nL]],NF=[3,y,$m,0,[Lp,Pp,kp,Np,nh],[0,1,0,0,0]],PF=[3,y,eh,0,[mS,Lp,Pp,kp,Np,nh],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`HttpTokens`,[v]:hD}],[1,{[g]:`HttpPutResponseHopLimit`,[v]:fD}],[0,{[g]:`HttpEndpoint`,[v]:cD}],[0,{[g]:`HttpProtocolIpv6`,[v]:dD}],[0,{[g]:`InstanceMetadataTags`,[v]:UD}]]],FF=[3,y,ih,0,[cc,uc,Md,ap,Hp,o_,ov,Sv,Kv,ly,uy,Wb,hS,Px,SC,pg,Ih,Ah,Rl,Pv],[[()=>IF,{[g]:`Association`,[v]:Iw}],[()=>LF,{[g]:`Attachment`,[v]:Lw}],[0,{[g]:`Description`,[v]:ZT}],[()=>YL,{[g]:`GroupSet`,[v]:iD}],[()=>aR,{[g]:`Ipv6AddressesSet`,[v]:wD}],[0,{[g]:`MacAddress`,[v]:WO}],[0,{[g]:`NetworkInterfaceId`,[v]:Tk}],[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`PrivateDnsName`,[v]:iA}],[0,{[g]:`PrivateIpAddress`,[v]:pA}],[()=>uR,{[g]:`PrivateIpAddressesSet`,[v]:dA}],[2,{[g]:`SourceDestCheck`,[v]:cj}],[0,{[g]:`Status`,[v]:Zj}],[0,{[g]:`SubnetId`,[v]:Ej}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`InterfaceType`,[v]:SO}],[()=>iR,{[g]:`Ipv4PrefixSet`,[v]:QD}],[()=>oR,{[g]:`Ipv6PrefixSet`,[v]:$D}],[()=>AN,{[g]:`ConnectionTrackingConfiguration`,[v]:ST}],[()=>TI,{[g]:`Operator`,[v]:Yk}]]],IF=[3,y,ah,0,[Vc,rl,hh,Zv,ay],[[0,{[g]:`CarrierIp`,[v]:aT}],[0,{[g]:`CustomerOwnedIp`,[v]:pT}],[0,{[g]:`IpOwnerId`,[v]:JD}],[0,{[g]:`PublicDnsName`,[v]:aA}],[0,{[g]:`PublicIp`,[v]:uA}]]],LF=[3,y,oh,0,[Us,Ss,Lu,du,hS,q_,Af,Ef],[[4,{[g]:`AttachTime`,[v]:Ow}],[0,{[g]:`AttachmentId`,[v]:gw}],[2,{[g]:`DeleteOnTermination`,[v]:VT}],[1,{[g]:`DeviceIndex`,[v]:FT}],[0,{[g]:`Status`,[v]:Zj}],[1,{[g]:`NetworkCardIndex`,[v]:yk}],[()=>CF,{[g]:`EnaSrdSpecification`,[v]:kE}],[1,{[g]:`EnaQueueCount`,[v]:TE}]]],RF=[3,y,ch,0,[Ts,Lu,Md,du,ap,Wp,Hp,ov,ly,uy,qx,Px,ms,pg,q_,Ih,yh,Ah,vh,py,Af,zl,Ef],[[2,{[g]:`AssociatePublicIpAddress`,[v]:yw}],[2,{[g]:`DeleteOnTermination`,[v]:VT}],[0,{[g]:`Description`,[v]:ZT}],[1,{[g]:`DeviceIndex`,[v]:FT}],[()=>QR,{[v]:Yb}],[1,{[g]:`Ipv6AddressCount`,[v]:yD}],[()=>aR,{[g]:`Ipv6Addresses`,[v]:wD}],[0,{[g]:`NetworkInterfaceId`,[v]:Tk}],[0,{[g]:`PrivateIpAddress`,[v]:pA}],[()=>zR,{[g]:`PrivateIpAddresses`,[v]:dA}],[1,{[g]:`SecondaryPrivateIpAddressCount`,[v]:Nj}],[0,{[g]:`SubnetId`,[v]:Ej}],2,0,1,[()=>SR,{[v]:Lh}],1,[()=>CR,{[v]:Ph}],1,2,()=>QP,()=>kN,1]],zF=[3,y,fh,0,[Dc],[[0,{[g]:`BandwidthWeighting`,[v]:Jw}]]],BF=[3,y,ph,0,[Dc],[0]],VF=[3,y,xh,0,[cc,My,Kv,ly],[[()=>IF,{[g]:`Association`,[v]:Iw}],[2,{[g]:`Primary`,[v]:AA}],[0,{[g]:`PrivateDnsName`,[v]:iA}],[0,{[g]:`PrivateIpAddress`,[v]:pA}]]],HF=[3,y,eg,0,[uc,o_,mx,Sv,uy,Wb,hS,eS,Hx,pg],[[()=>UF,{[g]:`Attachment`,[v]:Lw}],[0,{[g]:`MacAddress`,[v]:WO}],[0,{[g]:`SecondaryInterfaceId`,[v]:yj}],[0,{[g]:`OwnerId`,[v]:Vk}],[()=>fR,{[g]:`PrivateIpAddressSet`,[v]:fA}],[2,{[g]:`SourceDestCheck`,[v]:cj}],[0,{[g]:`Status`,[v]:Zj}],[0,{[g]:`SecondarySubnetId`,[v]:Rj}],[0,{[g]:`SecondaryNetworkId`,[v]:Aj}],[0,{[g]:`InterfaceType`,[v]:SO}]]],UF=[3,y,Kh,0,[Us,Ss,Lu,du,hS,q_],[[4,{[g]:`AttachTime`,[v]:Ow}],[0,{[g]:`AttachmentId`,[v]:gw}],[2,{[g]:`DeleteOnTermination`,[v]:VT}],[1,{[g]:`DeviceIndex`,[v]:FT}],[0,{[g]:`Status`,[v]:Zj}],[1,{[g]:`NetworkCardIndex`,[v]:yk}]]],WF=[3,y,Jh,0,[ly],[[0,{[g]:`PrivateIpAddress`,[v]:pA}]]],GF=[3,y,Zh,0,[ly],[0],1],KF=[3,y,$h,0,[Lu,du,uy,oy,eS,pg,q_],[2,1,[()=>pR,{[v]:ly}],1,0,0,1]],qF=[3,y,ig,0,[Yl,W_],[[1,{[g]:`Code`,[v]:TT}],[0,{[g]:`Name`,[v]:gk}]]],JF=[3,y,Wh,0,[Tm,Il,Cy],[[0,{[g]:`InstanceId`,[v]:LD}],[()=>qF,{[g]:`CurrentState`,[v]:bT}],[()=>qF,{[g]:`PreviousState`,[v]:CA}]]],YF=[3,y,tg,0,[RS,Pd,pv,Lf],[[1,{[g]:`TotalSizeInGB`,[v]:pM}],[()=>zL,{[g]:`Disks`,[v]:$T}],[0,{[g]:`NvmeSupport`,[v]:Nk}],[0,{[g]:`EncryptionSupport`,[v]:PE}]]],XF=[3,y,lg,0,[sg,Bc,tp,oS,Jx,lS,Cc,Bp,my,mC,S_,ng,tg,mf,cv,_p,Xf,ey,qp,Ip,Tc,uu,Ds,Vb,nv,hv,mv,a_,lv,Sy,ab],[[0,{[g]:`InstanceType`,[v]:_O}],[2,{[g]:`CurrentGeneration`,[v]:iT}],[2,{[g]:`FreeTierEligible`,[v]:GE}],[()=>fz,{[g]:`SupportedUsageClasses`,[v]:Gj}],[()=>qR,{[g]:`SupportedRootDeviceTypes`,[v]:Pj}],[()=>hz,{[g]:`SupportedVirtualizationTypes`,[v]:qj}],[2,{[g]:`BareMetal`,[v]:Ww}],[0,{[g]:`Hypervisor`,[v]:sD}],[()=>PI,{[g]:`ProcessorInfo`,[v]:hA}],[()=>gL,{[g]:`VCpuInfo`,[v]:AM}],[()=>fI,{[g]:`MemoryInfo`,[v]:$O}],[2,{[g]:`InstanceStorageSupported`,[v]:lO}],[()=>YF,{[g]:`InstanceStorageInfo`,[v]:cO}],[()=>UP,{[g]:`EbsInfo`,[v]:gE}],[()=>vI,{[g]:`NetworkInfo`,[v]:Ok}],[()=>uF,{[g]:`GpuInfo`,[v]:ZE}],[()=>aF,{[g]:`FpgaInfo`,[v]:VE}],[()=>OI,{[g]:`PlacementGroupInfo`,[v]:cA}],[()=>yF,{[g]:`InferenceAcceleratorInfo`,[v]:bD}],[2,{[g]:`HibernationSupported`,[v]:mD}],[2,{[g]:`BurstablePerformanceSupported`,[v]:Kw}],[2,{[g]:`DedicatedHostsSupported`,[v]:PT}],[2,{[g]:`AutoRecoverySupported`,[v]:xw}],[()=>LL,{[g]:`SupportedBootModes`,[v]:oj}],[0,{[g]:`NitroEnclavesSupport`,[v]:Sk}],[0,{[g]:`NitroTpmSupport`,[v]:Fk}],[()=>CI,{[g]:`NitroTpmInfo`,[v]:Pk}],[()=>lI,{[g]:`MediaAcceleratorInfo`,[v]:UO}],[()=>SI,{[g]:`NeuronInfo`,[v]:kk}],[0,{[g]:`PhcSupport`,[v]:SA}],[0,{[g]:`RebootMigrationSupport`,[v]:WA}]]],ZF=[3,y,hm,0,[dc,bm,Sv,yS],[[()=>_R,{[g]:`AttachmentSet`,[v]:Dw}],[0,{[g]:`InternetGatewayId`,[v]:FD}],[0,{[g]:`OwnerId`,[v]:Vk}],[()=>lz,{[g]:`TagSet`,[v]:fM}]]],QF=[3,y,gm,0,[mS,SC],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`VpcId`,[v]:NM}]]],$F=[3,y,Mh,0,[Nh,Qf,PS,eC,Bh,Hh,yy],[[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[()=>pz,{[g]:`Groups`,[v]:oD}],[()=>xR,{[g]:`IpRanges`,[v]:oO}],[()=>wR,{[g]:`Ipv6Ranges`,[v]:sO}],[()=>RR,{[g]:`PrefixListIds`,[v]:yA}]]],eI=[3,y,Vh,0,[Md,Jc],[[0,{[g]:`Description`,[v]:ZT}],[0,{[g]:`CidrIp`,[v]:sT}]]],tI=[3,y,Oh,0,[Lh],[0]],nI=[3,y,kh,0,[Ph],[0]],rI=[3,y,Uh,0,[Md,Yc],[[0,{[g]:`Description`,[v]:ZT}],[0,{[g]:`CidrIpv6`,[v]:cT}]]],iI=[3,y,Pg,0,[kg,yS,Tg,xg,wg],[[0,{[g]:`KeyPairId`,[v]:AO}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`KeyName`,[v]:kO}],[0,{[g]:`KeyFingerprint`,[v]:TO}],[()=>sN,{[g]:`KeyMaterial`,[v]:OO}]]],aI=[3,y,Mg,0,[kg,Fg,yS,hy,Ul,Tg,xg],[[0,{[g]:`KeyPairId`,[v]:AO}],[0,{[g]:`KeyType`,[v]:MO}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`PublicKey`,[v]:gA}],[4,{[g]:`CreateTime`,[v]:wT}],[0,{[g]:`KeyName`,[v]:kO}],[0,{[g]:`KeyFingerprint`,[v]:TO}]]],oI=[3,y,Qg,0,[Xg,Zg,ZC],[0,0,0]],sI=[3,y,zg,0,[Lg],[[0,{[g]:`LicenseConfigurationArn`,[v]:PO}]]],cI=[3,y,Rg,0,[Lg],[0]],lI=[3,y,a_,0,[rc,MS],[[()=>AR,{[g]:`Accelerators`,[v]:Mw}],[1,{[g]:`TotalMediaMemoryInMiB`,[v]:cM}]]],uI=[3,y,d_,0,[Zl,W_,R_,S_],[[1,{[g]:`Count`,[v]:DT}],[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`Manufacturer`,[v]:dk}],[()=>dI,{[g]:`MemoryInfo`,[v]:$O}]]],dI=[3,y,p_,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],fI=[3,y,S_,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],pI=[3,y,b_,0,[Tm,Wb,Ql,m,lc,cC,vc,$l,sg,Ig,jb,QS,Lm,ap,_f,Ux,Rf],[[0,{[g]:`InstanceId`,[v]:LD}],[()=>fN,0],[()=>fN,0],[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`Attribute`,[v]:Rw}],[0,{[g]:`Value`,[v]:kM}],[()=>nR,{[g]:`BlockDeviceMapping`,[v]:Vw}],[()=>fN,{[g]:`DisableApiTermination`,[v]:OT}],[()=>pN,{[g]:`InstanceType`,[v]:_O}],[()=>pN,{[g]:`Kernel`,[v]:NO}],[()=>pN,{[g]:`Ramdisk`,[v]:tj}],[()=>SN,{[g]:`UserData`,[v]:SM}],[()=>pN,{[g]:`InstanceInitiatedShutdownBehavior`,[v]:zD}],[()=>XL,{[v]:vp}],[()=>fN,{[g]:`EbsOptimized`,[v]:yE}],[()=>pN,{[g]:`SriovNetSupport`,[v]:Mj}],[()=>fN,{[g]:`EnaSupport`,[v]:FE}]],1],mI=[3,y,P_,0,[OC,m,dS,GC,vg,JS,i_],[0,2,1,0,1,1,2],1],hI=[3,y,F_,0,[FC],[[()=>yL,{[g]:`VolumeModification`,[v]:LM}]]],gI=[3,y,U_,0,[mS],[[0,{[g]:`State`,[v]:Xj}]]],_I=[3,y,Y_,0,[q_,dv,w_,hs,pc,zv,cu,__,v_],[[1,{[g]:`NetworkCardIndex`,[v]:yk}],[0,{[g]:`NetworkPerformance`,[v]:jk}],[1,{[g]:`MaximumNetworkInterfaces`,[v]:tk}],[1,{[g]:`AdditionalFlexibleNetworkInterfaces`,[v]:dw}],[1,{[g]:`BaselineBandwidthInGbps`,[v]:zw}],[1,{[g]:`PeakBandwidthInGbps`,[v]:Qk}],[1,{[g]:`DefaultEnaQueueCountPerInterface`,[v]:MT}],[1,{[g]:`MaximumEnaQueueCount`,[v]:XO}],[1,{[g]:`MaximumEnaQueueCountPerInterface`,[v]:ZO}]]],vI=[3,y,cv,0,[dv,w_,C_,Pu,K_,Jp,Yp,og,Rf,If,hf,pf,Mf,kc,Yf,Rl,Wx,A_,Xp],[[0,{[g]:`NetworkPerformance`,[v]:jk}],[1,{[g]:`MaximumNetworkInterfaces`,[v]:tk}],[1,{[g]:`MaximumNetworkCards`,[v]:ek}],[1,{[g]:`DefaultNetworkCardIndex`,[v]:RT}],[()=>jR,{[g]:`NetworkCards`,[v]:vk}],[1,{[g]:`Ipv4AddressesPerInterface`,[v]:xD}],[1,{[g]:`Ipv6AddressesPerInterface`,[v]:SD}],[2,{[g]:`Ipv6Supported`,[v]:gO}],[0,{[g]:`EnaSupport`,[v]:FE}],[2,{[g]:`EfaSupported`,[v]:NE}],[()=>qP,{[g]:`EfaInfo`,[v]:_E}],[2,{[g]:`EncryptionInTransitSupported`,[v]:hE}],[2,{[g]:`EnaSrdSupported`,[v]:AE}],[()=>PL,{[g]:`BandwidthWeightings`,[v]:Yw}],[0,{[g]:`FlexibleEnaQueuesSupport`,[v]:BE}],[()=>tP,{[g]:`ConnectionTrackingConfiguration`,[v]:ST}],[2,{[g]:`SecondaryNetworkSupported`,[v]:jj}],[1,{[g]:`MaximumSecondaryNetworkInterfaces`,[v]:sk}],[1,{[g]:`Ipv4AddressesPerSecondaryInterface`,[v]:CD}]]],yI=[3,y,Z_,0,[Zl,ZC],[[1,{[g]:`Count`,[v]:DT}],[1,{[g]:`Version`,[v]:YM}]]],bI=[3,y,Q_,0,[Zl,W_,Zc,S_],[[1,{[g]:`Count`,[v]:DT}],[0,{[g]:`Name`,[v]:gk}],[()=>yI,{[g]:`CoreInfo`,[v]:uT}],[()=>xI,{[g]:`MemoryInfo`,[v]:$O}]]],xI=[3,y,ev,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],SI=[3,y,lv,0,[tv,NS],[[()=>MR,{[g]:`NeuronDevices`,[v]:xk}],[1,{[g]:`TotalNeuronDeviceMemoryInMiB`,[v]:lM}]]],CI=[3,y,mv,0,[uS],[[()=>NR,{[g]:`SupportedVersions`,[v]:Jj}]]],wI=[3,y,Ov,0,[Rv],[0]],TI=[3,y,kv,0,[z_,Rv],[[2,{[g]:`Managed`,[v]:fk}],[0,{[g]:`Principal`,[v]:Zk}]]],EI=[3,y,jy,0,[Xs,ic,Sp,by,Ap,qS,Gb,Fp,vp,qs],[[0,{[g]:`AvailabilityZoneId`,[v]:Aw}],[0,{[g]:`Affinity`,[v]:Nw}],[0,{[g]:`GroupName`,[v]:eD}],[1,{[g]:`PartitionNumber`,[v]:bA}],[0,{[g]:`HostId`,[v]:lD}],[0,{[g]:`Tenancy`,[v]:eM}],[0,{[g]:`SpreadDomain`,[v]:lj}],[0,{[g]:`HostResourceGroupArn`,[v]:pD}],[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`AvailabilityZone`,[v]:kw}]]],DI=[3,y,$v,0,[Sp,mS,gS,Uv,vp,yS,op,Lx,Ug,Pv],[[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`Strategy`,[v]:Qj}],[1,{[g]:`PartitionCount`,[v]:eA}],[0,{[g]:`GroupId`,[v]:QE}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`GroupArn`,[v]:JE}],[0,{[g]:`SpreadLevel`,[v]:Dj}],[0,{[g]:`LinkedGroupId`,[v]:LO}],[()=>TI,{[g]:`Operator`,[v]:Yk}]]],OI=[3,y,ey,0,[tS],[[()=>LR,{[g]:`SupportedStrategies`,[v]:Vj}]]],kI=[3,y,_y,0,[Md,_y],[[0,{[g]:`Description`,[v]:ZT}],[0,{[g]:`PrefixListId`,[v]:vA}]]],AI=[3,y,Jv,0,[Rp,Of,Df],[[0,{[g]:`HostnameType`,[v]:gD}],[2,{[g]:`EnableResourceNameDnsARecord`,[v]:DE}],[2,{[g]:`EnableResourceNameDnsAAAARecord`,[v]:EE}]]],jI=[3,y,Yv,0,[Rp,Of,Df],[0,2,2]],MI=[3,y,Xv,0,[Rp,Of,Df],[[0,{[g]:`HostnameType`,[v]:gD}],[2,{[g]:`EnableResourceNameDnsARecord`,[v]:DE}],[2,{[g]:`EnableResourceNameDnsAAAARecord`,[v]:EE}]]],NI=[3,y,sy,0,[My,ly],[[2,{[g]:`Primary`,[v]:AA}],[0,{[g]:`PrivateIpAddress`,[v]:pA}]]],PI=[3,y,my,0,[Bb,Ub,Kb,R_],[[()=>kL,{[g]:`SupportedArchitectures`,[v]:ij}],[1,{[g]:`SustainedClockSpeedInGhz`,[v]:sj}],[()=>cz,{[g]:`SupportedFeatures`,[v]:uj}],[0,{[g]:`Manufacturer`,[v]:dk}]]],FI=[3,y,Wv,0,[Bv,Hv],[[0,{[g]:`ProductCode`,[v]:tA}],[0,{[g]:`Type`,[v]:xM}]]],II=[3,y,Ty,0,[mp],[[0,{[g]:`GatewayId`,[v]:XE}]]],LI=[3,y,Jy,0,[Hm,m],[[()=>rR,{[v]:Tm}],[2,{[g]:`DryRun`,[v]:h}]],1],RI=[3,y,ub,0,[vp,xy,$S,SC,RC],[[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`PeeringStatus`,[v]:xA}],[0,{[g]:`UserId`,[v]:CM}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`VpcPeeringConnectionId`,[v]:BM}]]],zI=[3,y,Nb,0,[Cv,Dp,sb,Wf],[[0,{[g]:`OptInStatus`,[v]:Hk}],[()=>HR,{[g]:`GeographySet`,[v]:rD}],[0,{[g]:`RegionName`,[v]:KA}],[0,{[g]:`RegionEndpoint`,[v]:IA}]]],BI=[3,y,Uy,0,[W_],[[0,{[g]:`Name`,[v]:gk}]]],VI=[3,y,Fb,0,[Qy,Sv,eb,ap,_g],[[0,{[g]:`ReservationId`,[v]:BA}],[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`RequesterId`,[v]:UA}],[()=>YL,{[g]:`GroupSet`,[v]:iD}],[()=>sR,{[g]:`InstancesSet`,[v]:pO}]]],HI=[3,y,_b,0,[rx,vp,mm,Nh,Qf,PS,Xc,Yc,_y,Wy,Md],[[0,{[g]:`SecurityGroupRuleId`,[v]:mj}],[0,{[g]:`GroupId`,[v]:QE}],[2,{[g]:`IsEgress`,[v]:MD}],[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[0,{[g]:`CidrIpv4`,[v]:lT}],[0,{[g]:`CidrIpv6`,[v]:cT}],[0,{[g]:`PrefixListId`,[v]:vA}],[0,{[g]:`ReferencedGroupId`,[v]:RA}],[0,{[g]:`Description`,[v]:ZT}]]],UI=[3,y,fb,0,[vp,tx,m,Zx,Qx,Nh,Qf,PS,Jc,jh],[[0,{[g]:`GroupId`,[v]:QE}],[()=>ez,{[v]:rx}],[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`SourceSecurityGroupName`,[v]:Ij}],[0,{[g]:`SourceSecurityGroupOwnerId`,[v]:Lj}],[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[0,{[g]:`CidrIp`,[v]:sT}],[()=>bR,{[g]:`IpPermissions`,[v]:tO}]],1],WI=[3,y,pb,0,[Fy,rC,yb],[[2,{[g]:`Return`,[v]:MA}],[()=>bR,{[g]:`UnknownIpPermissionSet`,[v]:wM}],[()=>KR,{[g]:`RevokedSecurityGroupRuleSet`,[v]:qA}]]],GI=[3,y,mb,0,[Jc,Qf,vp,Sp,jh,Nh,Zx,Qx,PS,tx,m],[0,1,0,0,[()=>bR,0],0,0,0,1,[()=>ez,{[v]:rx}],[2,{[g]:`DryRun`,[v]:h}]]],KI=[3,y,hb,0,[Fy,rC,yb],[[2,{[g]:`Return`,[v]:MA}],[()=>bR,{[g]:`UnknownIpPermissionSet`,[v]:wM}],[()=>KR,{[g]:`RevokedSecurityGroupRuleSet`,[v]:qA}]]],qI=[3,y,Ib,0,[iu,fu,Uu,xf,mp,Tm,gh,av,SS,Hg,zc,ov,yv,mS,RC,tl,Dv,Qp],[[0,{[g]:`DestinationCidrBlock`,[v]:kT}],[0,{[g]:`DestinationIpv6CidrBlock`,[v]:IT}],[0,{[g]:`DestinationPrefixListId`,[v]:HT}],[0,{[g]:`EgressOnlyInternetGatewayId`,[v]:SE}],[0,{[g]:`GatewayId`,[v]:XE}],[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`InstanceOwnerId`,[v]:qD}],[0,{[g]:`NatGatewayId`,[v]:wk}],[0,{[g]:`TransitGatewayId`,[v]:rM}],[0,{[g]:`LocalGatewayId`,[v]:IO}],[0,{[g]:`CarrierGatewayId`,[v]:rT}],[0,{[g]:`NetworkInterfaceId`,[v]:Tk}],[0,{[g]:`Origin`,[v]:Rk}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`VpcPeeringConnectionId`,[v]:BM}],[0,{[g]:`CoreNetworkArn`,[v]:dT}],[0,{[g]:`OdbNetworkArn`,[v]:Gk}],[0,{[g]:`IpAddress`,[v]:ED}]]],JI=[3,y,kb,0,[sc,Dy,wb,Lb,yS,SC,Sv],[[()=>YR,{[g]:`AssociationSet`,[v]:Ew}],[()=>VR,{[g]:`PropagatingVgwSet`,[v]:TA}],[0,{[g]:`RouteTableId`,[v]:ZA}],[()=>JR,{[g]:`RouteSet`,[v]:YA}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`OwnerId`,[v]:Vk}]]],YI=[3,y,bb,0,[L_,xb,wb,Px,mp,fy,Ps],[[2,{[g]:`Main`,[v]:uk}],[0,{[g]:`RouteTableAssociationId`,[v]:XA}],[0,{[g]:`RouteTableId`,[v]:ZA}],[0,{[g]:`SubnetId`,[v]:Ej}],[0,{[g]:`GatewayId`,[v]:XE}],[0,{[g]:`PublicIpv4Pool`,[v]:mA}],[()=>XI,{[g]:`AssociationState`,[v]:ww}]]],XI=[3,y,Cb,0,[mS,Bx],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StatusMessage`,[v]:Oj}]]],ZI=[3,y,qy,0,[Hf],[[2,{[g]:`Enabled`,[v]:RE}]],1],QI=[3,y,Yy,0,[l_,u_,vc,Bm,sg,Wp,Hp,Sg,Tg,U_,jy,Zy,Zb,sx,Px,QS,$d,uf,LS,Yg,th,Nl,nl,hl,jp,Kg,T_,wf,qv,E_,Ql,Tf,uv,Pv,Ex,m,$l,Lm,ly,Ll,bs,sv,km,_f],[1,1,[()=>IL,{[v]:hc}],0,0,1,[()=>aR,{[v]:$p}],0,0,[()=>ZI,0],[()=>EI,0],0,[()=>QR,{[v]:Yb}],[()=>nz,{[v]:cx}],0,[()=>oN,0],[()=>HL,0],[()=>WL,{[v]:tf}],[()=>uz,{[v]:BS}],()=>oI,()=>MF,()=>eP,()=>PN,()=>TN,()=>pF,[()=>kR,{[v]:Jg}],()=>NF,()=>tF,()=>jI,()=>jF,2,2,()=>BF,()=>wI,[()=>mR,{[v]:Dx}],[2,{[g]:`DryRun`,[v]:h}],[2,{[g]:`DisableApiTermination`,[v]:OT}],[0,{[g]:`InstanceInitiatedShutdownBehavior`,[v]:zD}],[0,{[g]:`PrivateIpAddress`,[v]:pA}],[0,{[g]:`ClientToken`,[yO]:1,[v]:xT}],[0,{[g]:`AdditionalInfo`,[v]:mw}],[()=>lR,{[g]:`NetworkInterface`,[v]:Dk}],[()=>hF,{[g]:`IamInstanceProfile`,[v]:RD}],[2,{[g]:`EbsOptimized`,[v]:yE}]],2],$I=[3,y,cx,0,[vp,bh,yS,SC,Jb,Sv,Sp,Md,jh],[[0,{[g]:`GroupId`,[v]:QE}],[()=>bR,{[g]:`IpPermissionsEgress`,[v]:XD}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`SecurityGroupArn`,[v]:dj}],[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`GroupDescription`,[v]:YE}],[()=>bR,{[g]:`IpPermissions`,[v]:tO}]]],eL=[3,y,ax,0,[rx,vp,Tp,mm,Nh,Qf,PS,Xc,Yc,_y,Gy,Md,yS,ex],[[0,{[g]:`SecurityGroupRuleId`,[v]:mj}],[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`GroupOwnerId`,[v]:tD}],[2,{[g]:`IsEgress`,[v]:MD}],[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[0,{[g]:`CidrIpv4`,[v]:lT}],[0,{[g]:`CidrIpv6`,[v]:cT}],[0,{[g]:`PrefixListId`,[v]:vA}],[()=>RI,{[g]:`ReferencedGroupInfo`,[v]:zA}],[0,{[g]:`Description`,[v]:ZT}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`SecurityGroupRuleArn`,[v]:pj}]]],tL=[3,y,pS,0,[xv,bv,yS,aS,Vy,iS,qs,WS,Lc,Hl,ep,Ox,OC,mS,Vx,nS,Ny,Sv,Md,WC,Uf,Cg,su],[[0,{[g]:`OwnerAlias`,[v]:Bk}],[0,{[g]:`OutpostArn`,[v]:zk}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`StorageTier`,[v]:Wj}],[4,{[g]:`RestoreExpiryTime`,[v]:FA}],[0,{[g]:`SseType`,[v]:Uj}],[0,{[g]:`AvailabilityZone`,[v]:kw}],[0,{[g]:`TransferType`,[v]:_M}],[1,{[g]:`CompletionDurationMinutes`,[v]:tT}],[4,{[g]:`CompletionTime`,[v]:CT}],[1,{[g]:`FullSnapshotSizeInBytes`,[v]:WE}],[0,{[g]:`SnapshotId`,[v]:Tj}],[0,{[g]:`VolumeId`,[v]:FM}],[0,{[g]:`Status`,[v]:Zj}],[0,{[g]:`StatusMessage`,[v]:Oj}],[4,{[g]:`StartTime`,[v]:Hj}],[0,{[g]:`Progress`,[v]:jA}],[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`Description`,[v]:ZT}],[1,{[g]:`VolumeSize`,[v]:WM}],[2,{[g]:`Encrypted`,[v]:zE}],[0,{[g]:`KmsKeyId`,[v]:DO}],[0,{[g]:`DataEncryptionKeyId`,[v]:jT}]]],nL=[3,y,zx,0,[O_,Tx,yc,YC,Om],[0,0,1,4,0]],rL=[3,y,yx,0,[Hm,bs,m],[[()=>rR,{[v]:Tm}],[0,{[g]:`AdditionalInfo`,[v]:mw}],[2,{[g]:`DryRun`,[v]:h}]],1],iL=[3,y,bx,0,[Ax],[[()=>hR,{[g]:`InstancesSet`,[v]:pO}]]],aL=[3,y,Xx,0,[Yl,B_],[[0,{[g]:`Code`,[v]:TT}],[0,{[g]:`Message`,[v]:pk}]]],oL=[3,y,xx,0,[Hm,zp,Kx,m,Gf],[[()=>rR,{[v]:Tm}],2,2,[2,{[g]:`DryRun`,[v]:h}],[2,{[g]:`Force`,[v]:KE}]],1],sL=[3,y,Sx,0,[Mx],[[()=>hR,{[g]:`InstancesSet`,[v]:pO}]]],cL=[3,y,_S,0,[Xs,gf,c_,il,Sv,_s,am,yS,zb,bv,Ud,rh,Jv,wc,XS,Px,mS,SC,Ac,gs,qs,lu,D_],[[0,{[g]:`AvailabilityZoneId`,[v]:Aw}],[1,{[g]:`EnableLniAtDeviceIndex`,[v]:vE}],[2,{[g]:`MapCustomerOwnedIpOnLaunch`,[v]:KO}],[0,{[g]:`CustomerOwnedIpv4Pool`,[v]:mT}],[0,{[g]:`OwnerId`,[v]:Vk}],[2,{[g]:`AssignIpv6AddressOnCreation`,[v]:pw}],[()=>oz,{[g]:`Ipv6CidrBlockAssociationSet`,[v]:kD}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`SubnetArn`,[v]:aj}],[0,{[g]:`OutpostArn`,[v]:zk}],[2,{[g]:`EnableDns64`,[v]:rE}],[2,{[g]:`Ipv6Native`,[v]:WD}],[()=>AI,{[g]:`PrivateDnsNameOptionsOnLaunch`,[v]:rA}],[()=>wN,{[g]:`BlockPublicAccessStates`,[v]:Gw}],[0,{[g]:`Type`,[v]:xM}],[0,{[g]:`SubnetId`,[v]:Ej}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`CidrBlock`,[v]:Xw}],[1,{[g]:`AvailableIpAddressCount`,[v]:fw}],[0,{[g]:`AvailabilityZone`,[v]:kw}],[2,{[g]:`DefaultForAz`,[v]:NT}],[2,{[g]:`MapPublicIpOnLaunch`,[v]:ik}]]],lL=[3,y,Hb,0,[mS,Bx],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StatusMessage`,[v]:Oj}]]],uL=[3,y,ux,0,[xs,im,sm,Up,ag],[[0,{[g]:`AssociationId`,[v]:hw}],[0,{[g]:`Ipv6CidrBlock`,[v]:OD}],[()=>lL,{[g]:`Ipv6CidrBlockState`,[v]:AD}],[0,{[g]:`Ipv6AddressAttribute`,[v]:vD}],[0,{[g]:`IpSource`,[v]:hO}]]],dL=[3,y,KS,0,[yg,cC],[[0,{[g]:`Key`,[v]:wO}],[0,{[g]:`Value`,[v]:kM}]]],fL=[3,y,BS,0,[Ob,yS],[[0,{[g]:`ResourceType`,[v]:$A}],[()=>lz,{[v]:KS}]]],pL=[3,y,ES,0,[Hm,Gf,Kx,m],[[()=>rR,{[v]:Tm}],2,2,[2,{[g]:`DryRun`,[v]:h}]],1],mL=[3,y,DS,0,[kS],[[()=>hR,{[g]:`InstancesSet`,[v]:pO}]]],hL=[3,y,nC,0,[Md,$S,Sp,vp,SC,RC,xy],[[0,{[g]:`Description`,[v]:ZT}],[0,{[g]:`UserId`,[v]:CM}],[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`VpcPeeringConnectionId`,[v]:BM}],[0,{[g]:`PeeringStatus`,[v]:xA}]]],gL=[3,y,mC,0,[yd,ou,hd,hC,qC],[[1,{[g]:`DefaultVCpus`,[v]:XT}],[1,{[g]:`DefaultCores`,[v]:AT}],[1,{[g]:`DefaultThreadsPerCore`,[v]:KT}],[()=>RL,{[g]:`ValidCores`,[v]:jM}],[()=>dz,{[g]:`ValidThreadsPerCore`,[v]:qM}]]],_L=[3,y,$C,0,[Xs,bv,cS,vg,yS,GC,$f,i_,JS,iS,Pv,TC,OC,dS,Ox,qs,mS,Ul,dc,Uf,Cg],[[0,{[g]:`AvailabilityZoneId`,[v]:Aw}],[0,{[g]:`OutpostArn`,[v]:zk}],[0,{[g]:`SourceVolumeId`,[v]:Kj}],[1,{[g]:`Iops`,[v]:CO}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VolumeType`,[v]:KM}],[2,{[g]:`FastRestored`,[v]:UE}],[2,{[g]:`MultiAttachEnabled`,[v]:HO}],[1,{[g]:`Throughput`,[v]:yM}],[0,{[g]:`SseType`,[v]:Uj}],[()=>TI,{[g]:`Operator`,[v]:Yk}],[1,{[g]:`VolumeInitializationRate`,[v]:PM}],[0,{[g]:`VolumeId`,[v]:FM}],[1,{[g]:`Size`,[v]:Yj}],[0,{[g]:`SnapshotId`,[v]:Tj}],[0,{[g]:`AvailabilityZone`,[v]:kw}],[0,{[g]:`Status`,[v]:Zj}],[4,{[g]:`CreateTime`,[v]:wT}],[()=>gz,{[g]:`AttachmentSet`,[v]:Dw}],[2,{[g]:`Encrypted`,[v]:zE}],[0,{[g]:`KmsKeyId`,[v]:DO}]]],vL=[3,y,uC,0,[Lu,Ms,_h,Rd,OC,Tm,Nd,mS,Us],[[2,{[g]:`DeleteOnTermination`,[v]:VT}],[0,{[g]:`AssociatedResource`,[v]:Sw}],[0,{[g]:`InstanceOwningService`,[v]:YD}],[1,{[g]:`EbsCardIndex`,[v]:eE}],[0,{[g]:`VolumeId`,[v]:FM}],[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`Device`,[v]:QT}],[0,{[g]:`Status`,[v]:Zj}],[4,{[g]:`AttachTime`,[v]:Ow}]]],yL=[3,y,FC,0,[OC,j_,Bx,VS,OS,GS,US,jS,jv,wv,Nv,Mv,Ev,Ny,nS,zf],[[0,{[g]:`VolumeId`,[v]:FM}],[0,{[g]:`ModificationState`,[v]:ck}],[0,{[g]:`StatusMessage`,[v]:Oj}],[1,{[g]:`TargetSize`,[v]:mM}],[1,{[g]:`TargetIops`,[v]:oM}],[0,{[g]:`TargetVolumeType`,[v]:vM}],[1,{[g]:`TargetThroughput`,[v]:gM}],[2,{[g]:`TargetMultiAttachEnabled`,[v]:sM}],[1,{[g]:`OriginalSize`,[v]:Kk}],[1,{[g]:`OriginalIops`,[v]:Uk}],[0,{[g]:`OriginalVolumeType`,[v]:Jk}],[1,{[g]:`OriginalThroughput`,[v]:qk}],[2,{[g]:`OriginalMultiAttachEnabled`,[v]:Wk}],[1,{[g]:`Progress`,[v]:jA}],[4,{[g]:`StartTime`,[v]:Hj}],[4,{[g]:`EndTime`,[v]:IE}]]],bL=[3,y,ew,0,[Sv,dg,am,jc,pm,Hd,yS,wc,SC,mS,Ac,Iu],[[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`InstanceTenancy`,[v]:xO}],[()=>xz,{[g]:`Ipv6CidrBlockAssociationSet`,[v]:kD}],[()=>yz,{[g]:`CidrBlockAssociationSet`,[v]:Zw}],[2,{[g]:`IsDefault`,[v]:jD}],[()=>CL,{[g]:`EncryptionControl`,[v]:nE}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[()=>wN,{[g]:`BlockPublicAccessStates`,[v]:Gw}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`CidrBlock`,[v]:Xw}],[0,{[g]:`DhcpOptionsId`,[v]:BT}]]],xL=[3,y,dC,0,[xs,Ac,Nc],[[0,{[g]:`AssociationId`,[v]:hw}],[0,{[g]:`CidrBlock`,[v]:Xw}],[()=>SL,{[g]:`CidrBlockState`,[v]:$w}]]],SL=[3,y,pC,0,[mS,Bx],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StatusMessage`,[v]:Oj}]]],CL=[3,y,gC,0,[SC,bC,H_,mS,Vx,Hy,yS],[[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`VpcEncryptionControlId`,[v]:MM}],[0,{[g]:`Mode`,[v]:hk}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StateMessage`,[v]:kj}],[()=>EL,{[g]:`ResourceExclusions`,[v]:LA}],[()=>lz,{[g]:`TagSet`,[v]:fM}]]],wL=[3,y,_C,0,[H_,ym,bf,iv,VC,zC,Bg,MC,Gd],[0,0,0,0,0,0,0,0,0],1],TL=[3,y,vC,0,[mS,Vx],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StateMessage`,[v]:kj}]]],EL=[3,y,yC,0,[hm,yf,rv,BC,HC,t_,jC,Wd],[[()=>TL,{[g]:`InternetGateway`,[v]:ND}],[()=>TL,{[g]:`EgressOnlyInternetGateway`,[v]:xE}],[()=>TL,{[g]:`NatGateway`,[v]:Ck}],[()=>TL,{[g]:`VirtualPrivateGateway`,[v]:VM}],[()=>TL,{[g]:`VpcPeering`,[v]:HM}],[()=>TL,{[g]:`Lambda`,[v]:VO}],[()=>TL,{[g]:`VpcLattice`,[v]:IM}],[()=>TL,{[g]:`ElasticFileSystem`,[v]:iE}]]],DL=[3,y,CC,0,[xs,im,sm,G_,Fh,Up,ag],[[0,{[g]:`AssociationId`,[v]:hw}],[0,{[g]:`Ipv6CidrBlock`,[v]:OD}],[()=>SL,{[g]:`Ipv6CidrBlockState`,[v]:AD}],[0,{[g]:`NetworkBorderGroup`,[v]:_k}],[0,{[g]:`Ipv6Pool`,[v]:rO}],[0,{[g]:`Ipv6AddressAttribute`,[v]:vD}],[0,{[g]:`IpSource`,[v]:hO}]]],OL=`unit`,kL=[1,y,Hs,0,[0,{[v]:_}]],AL=[1,y,Ys,0,[()=>yN,{[v]:_}]],jL=[1,y,Zs,0,[()=>vN,{[v]:_}]],ML=[1,y,$s,0,[()=>bN,{[v]:_}]],NL=[1,y,tc,0,[()=>xN,{[v]:_}]],PL=[1,y,Oc,0,[0,{[v]:_}]],FL=[1,y,gc,0,[()=>CN,{[v]:_}]],IL=[1,y,_c,0,[()=>CN,{[v]:hc}]],LL=[1,y,Sc,0,[0,{[v]:_}]],RL=[1,y,Pc,0,[1,{[v]:_}]],zL=[1,y,gu,0,[()=>BP,{[v]:_}]],BL=[1,y,zd,0,[()=>HP,{[v]:_}]],VL=[1,y,Jd,0,[()=>JP,{[v]:_}]],HL=[1,y,ef,0,[()=>YP,{[v]:_}]],UL=[1,y,af,0,[()=>ZP,{[v]:_}]],WL=[1,y,uf,0,[()=>XP,{[v]:_}]],GL=[1,y,Id,0,[0,{[v]:Ld}]],KL=[1,y,Zf,0,[()=>nF,{[v]:rp}]],qL=[1,y,qf,0,[()=>rF,{[v]:_}]],JL=[1,y,fp,0,[()=>cF,{[v]:_}]],YL=[1,y,hp,0,[()=>dF,{[v]:_}]],XL=[1,y,gp,0,[0,{[v]:QE}]],ZL=[1,y,Cp,0,[0,{[v]:Sp}]],QL=[1,y,Rm,0,[0,{[v]:Bm}]],$L=[1,y,qm,0,[()=>gF,{[v]:_}]],eR=[1,y,um,0,[()=>bF,0]],tR=[1,y,tm,0,[()=>TF,{[v]:_}]],nR=[1,y,rm,0,[()=>EF,{[v]:_}]],rR=[1,y,zm,0,[0,{[v]:Tm}]],iR=[1,y,Mm,0,[()=>DF,{[v]:_}]],aR=[1,y,Dm,0,[()=>OF,{[v]:_}]],oR=[1,y,Nm,0,[()=>kF,{[v]:_}]],sR=[1,y,Ym,0,[()=>SF,{[v]:_}]],cR=[1,y,sh,0,[()=>FF,{[v]:_}]],lR=[1,y,lh,0,[()=>RF,{[v]:_}]],uR=[1,y,Sh,0,[()=>VF,{[v]:_}]],dR=[1,y,qh,0,[()=>HF,{[v]:_}]],fR=[1,y,Yh,0,[()=>WF,{[v]:_}]],pR=[1,y,Xh,0,[()=>GF,{[v]:_}]],mR=[1,y,Qh,0,[()=>KF,{[v]:_}]],hR=[1,y,Gh,0,[()=>JF,{[v]:_}]],gR=[1,y,cg,0,[()=>XF,{[v]:_}]],_R=[1,y,_m,0,[()=>QF,{[v]:_}]],vR=[1,y,xm,0,[0,{[v]:_}]],yR=[1,y,Cm,0,[()=>ZF,{[v]:_}]],bR=[1,y,Th,0,[()=>$F,{[v]:_}]],xR=[1,y,Rh,0,[()=>eI,{[v]:_}]],SR=[1,y,Eh,0,[()=>tI,{[v]:_}]],CR=[1,y,Dh,0,[()=>nI,{[v]:_}]],wR=[1,y,zh,0,[()=>rI,{[v]:_}]],TR=[1,y,Eg,0,[0,{[v]:Tg}]],ER=[1,y,Ag,0,[0,{[v]:kg}]],DR=[1,y,Ng,0,[()=>aI,{[v]:_}]],OR=[1,y,Wg,0,[()=>sI,{[v]:_}]],kR=[1,y,qg,0,[()=>cI,{[v]:_}]],AR=[1,y,f_,0,[()=>uI,{[v]:_}]],jR=[1,y,J_,0,[()=>_I,{[v]:_}]],MR=[1,y,$_,0,[()=>bI,{[v]:_}]],NR=[1,y,gv,0,[0,{[v]:_}]],PR=[1,y,Av,0,[0,{[v]:Lv}]],FR=[1,y,ty,0,[0,{[v]:vp}]],IR=[1,y,ny,0,[()=>DI,{[v]:_}]],LR=[1,y,ry,0,[0,{[v]:_}]],RR=[1,y,vy,0,[()=>kI,{[v]:_}]],zR=[1,y,cy,0,[()=>NI,{[v]:_}]],BR=[1,y,Vv,0,[()=>FI,{[v]:_}]],VR=[1,y,Ey,0,[()=>II,{[v]:_}]],HR=[1,y,Ky,0,[()=>BI,{[v]:_}]],UR=[1,y,nb,0,[()=>zI,{[v]:_}]],WR=[1,y,cb,0,[0,{[v]:sb}]],GR=[1,y,rb,0,[()=>VI,{[v]:_}]],KR=[1,y,vb,0,[()=>HI,{[v]:_}]],qR=[1,y,By,0,[0,{[v]:_}]],JR=[1,y,ib,0,[()=>qI,{[v]:_}]],YR=[1,y,Sb,0,[()=>YI,{[v]:_}]],XR=[1,y,Tb,0,[0,{[v]:_}]],ZR=[1,y,Db,0,[()=>JI,{[v]:_}]],QR=[1,y,Xb,0,[0,{[v]:Yb}]],$R=[1,y,Qb,0,[()=>$I,{[v]:_}]],ez=[1,y,nx,0,[0,{[v]:_}]],tz=[1,y,ix,0,[()=>eL,{[v]:_}]],nz=[1,y,ox,0,[0,{[v]:cx}]],rz=[1,y,Cx,0,[0,{[v]:Ox}]],iz=[1,y,Ix,0,[()=>tL,{[v]:_}]],az=[1,y,wx,0,[0,{[v]:Px}]],oz=[1,y,dx,0,[()=>uL,{[v]:_}]],sz=[1,y,Rx,0,[()=>cL,{[v]:_}]],cz=[1,y,Rb,0,[0,{[v]:_}]],lz=[1,y,AS,0,[()=>dL,{[v]:_}]],uz=[1,y,zS,0,[()=>fL,{[v]:_}]],dz=[1,y,IS,0,[1,{[v]:_}]],fz=[1,y,ZS,0,[0,{[v]:_}]],pz=[1,y,tC,0,[()=>hL,{[v]:_}]],mz=[1,y,UC,0,[0,{[v]:_}]],hz=[1,y,KC,0,[0,{[v]:_}]],gz=[1,y,lC,0,[()=>vL,{[v]:_}]],_z=[1,y,EC,0,[0,{[v]:OC}]],vz=[1,y,NC,0,[()=>_L,{[v]:_}]],yz=[1,y,fC,0,[()=>xL,{[v]:_}]],bz=[1,y,DC,0,[0,{[v]:SC}]],xz=[1,y,wC,0,[()=>DL,{[v]:_}]],Sz=[1,y,PC,0,[()=>bL,{[v]:_}]],Cz=[1,y,nw,0,[0,{[v]:_}]],wz=[1,y,aw,0,[0,{[v]:iw}]],Tz=[1,y,cw,0,[0,{[v]:sw}]],Ez=[9,y,As,0,()=>cN,()=>lN],Dz=[9,y,vs,0,()=>uN,()=>OL],Oz=[9,y,Ks,0,()=>dN,()=>vL],kz=[9,y,Fs,0,()=>mN,()=>hN],Az=[9,y,Bs,0,()=>gN,()=>_N],jz=[9,y,Ml,0,()=>jN,()=>MN],Mz=[9,y,Qc,0,()=>FN,()=>IN],Nz=[9,y,Uc,0,()=>LN,()=>RN],Pz=[9,y,$c,0,()=>zN,()=>iI],Fz=[9,y,ol,0,()=>BN,()=>VN],Iz=[9,y,xl,0,()=>HN,()=>UN],Lz=[9,y,bl,0,()=>WN,()=>GN],Rz=[9,y,Sl,0,()=>KN,()=>qN],zz=[9,y,Pl,0,()=>JN,()=>tL],Bz=[9,y,Fl,0,()=>YN,()=>XN],Vz=[9,y,ql,0,()=>ZN,()=>_L],Hz=[9,y,Jl,0,()=>QN,()=>$N],Uz=[9,y,Du,0,()=>nP,()=>rP],Wz=[9,y,Ru,0,()=>iP,()=>OL],Gz=[9,y,Qu,0,()=>aP,()=>oP],Kz=[9,y,ud,0,()=>sP,()=>OL],qz=[9,y,dd,0,()=>cP,()=>OL],Jz=[9,y,Dd,0,()=>lP,()=>OL],Yz=[9,y,Od,0,()=>uP,()=>OL],Xz=[9,y,ru,0,()=>dP,()=>fP],Zz=[9,y,wu,0,()=>pP,()=>mP],Qz=[9,y,Tu,0,()=>hP,()=>gP],$z=[9,y,Cu,0,()=>_P,()=>vP],eB=[9,y,hu,0,()=>yP,()=>bP],tB=[9,y,Mu,0,()=>xP,()=>SP],nB=[9,y,Hu,0,()=>CP,()=>wP],rB=[9,y,Zu,0,()=>TP,()=>EP],iB=[9,y,Yu,0,()=>DP,()=>OP],aB=[9,y,rd,0,()=>kP,()=>AP],oB=[9,y,fd,0,()=>jP,()=>MP],sB=[9,y,pd,0,()=>NP,()=>PP],cB=[9,y,kd,0,()=>FP,()=>IP],lB=[9,y,Ad,0,()=>LP,()=>RP],uB=[9,y,jd,0,()=>zP,()=>vL],dB=[9,y,sp,0,()=>oF,()=>sF],fB=[9,y,Um,0,()=>_F,()=>vF],pB=[9,y,x_,0,()=>pI,()=>OL],mB=[9,y,I_,0,()=>mI,()=>hI],hB=[9,y,$y,0,()=>LI,()=>OL],gB=[9,y,db,0,()=>UI,()=>WI],_B=[9,y,gb,0,()=>GI,()=>KI],vB=[9,y,tb,0,()=>QI,()=>VI],yB=[9,y,jx,0,()=>rL,()=>iL],bB=[9,y,Nx,0,()=>oL,()=>sL],xB=[9,y,wS,0,()=>pL,()=>mL],SB=e=>({apiVersion:`2016-11-15`,base64Decoder:e?.base64Decoder??Ue,base64Encoder:e?.base64Encoder??We,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??us,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??lo,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:`aws.auth#sigv4`,identityProvider:e=>e.getIdentityProvider(`aws.auth#sigv4`),signer:new Xr}],logger:e?.logger??new Ei,protocol:e?.protocol??Ui,protocolSettings:e?.protocolSettings??{defaultNamespace:`com.amazonaws.ec2`,errorTypeRegistries:iN,xmlNamespace:`http://ec2.amazonaws.com/doc/2016-11-15`,version:`2016-11-15`,serviceTarget:`AmazonEC2`},serviceId:e?.serviceId??`EC2`,urlParser:e?.urlParser??gt,utf8Decoder:e?.utf8Decoder??se,utf8Encoder:e?.utf8Encoder??ce}),CB=e=>{let t=Io(e),n=()=>t().then(_i),r=SB(e);return{...r,...e,runtime:`browser`,defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??ii,credentialDefaultProvider:e?.credentialDefaultProvider??(e=>()=>Promise.reject(Error(`Credential is missing`))),defaultUserAgentProvider:e?.defaultUserAgentProvider??Mo({serviceId:r.serviceId,clientVersion:jo.version}),maxAttempts:e?.maxAttempts??3,region:e?.region??Po(`Region is missing`),requestHandler:$e.create(e?.requestHandler??n),retryMode:e?.retryMode??(async()=>(await n()).retryMode||Yi),sha256:e?.sha256??l,streamCollector:e?.streamCollector??tt,useDualstackEndpoint:e?.useDualstackEndpoint??(()=>Promise.resolve(!1)),useFipsEndpoint:e?.useFipsEndpoint??(()=>Promise.resolve(!1))}},wB=e=>({setRegion(t){e.region=t},region(){return e.region}}),TB=e=>({region:e.region()}),EB=e=>{let t=e.httpAuthSchemes,n=e.httpAuthSchemeProvider,r=e.credentials;return{setHttpAuthScheme(e){let n=t.findIndex(t=>t.schemeId===e.schemeId);n===-1?t.push(e):t.splice(n,1,e)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(e){n=e},httpAuthSchemeProvider(){return n},setCredentials(e){r=e},credentials(){return r}}},DB=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()}),OB=(e,t)=>{let n=Object.assign(wB(e),Ci(e),de(e),EB(e));return t.forEach(e=>e.configure(n)),Object.assign(e,TB(n),wi(n),fe(n),DB(n))},kB=class extends ui{config;constructor(...[e]){let t=CB(e||{});super(t),this.initConfig=t,this.config=OB(uo(Xa(ye(ja(Qa($n(fo(t))))))),e?.extensions||[]),this.middlewareStack.use(xt(this.config)),this.middlewareStack.use(Ea(this.config)),this.middlewareStack.use(ao(this.config)),this.middlewareStack.use(Fa(this.config)),this.middlewareStack.use(Se(this.config)),this.middlewareStack.use(Te(this.config)),this.middlewareStack.use(Oe(this.config)),this.middlewareStack.use(Ne(this.config,{httpAuthSchemeParametersProvider:so,identityProviderConfigProvider:async e=>new Jn({"aws.auth#sigv4":e.credentials})})),this.middlewareStack.use(Re(this.config))}destroy(){super.destroy()}},AB=async(e,t,n)=>({operation:_e(t).operation,region:await f(e.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function jB(e){return{schemeId:`aws.auth#sigv4`,signingProperties:{name:`iam`,region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}var MB=e=>{let t=[];switch(e.operation){default:t.push(jB(e))}return t},NB=e=>{let t=ei(e);return Object.assign(t,{authSchemePreference:f(e.authSchemePreference??[])})},PB=e=>Object.assign(e,{useDualstackEndpoint:e.useDualstackEndpoint??!1,useFipsEndpoint:e.useFipsEndpoint??!1,defaultSigningName:`iam`}),FB={UseFIPS:{type:`builtInParams`,name:`useFipsEndpoint`},Endpoint:{type:`builtInParams`,name:`endpoint`},Region:{type:`builtInParams`,name:`region`},UseDualStack:{type:`builtInParams`,name:`useDualstackEndpoint`}},IB=`@aws-sdk/client-iam`,LB=`AWS SDK for JavaScript Iam Client for Node.js, Browser and React Native`,RB=`3.1019.0`,zB={build:`concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs`,"build:cjs":`node ../../scripts/compilation/inline client-iam`,"build:es":`tsc -p tsconfig.es.json`,"build:include:deps":`yarn g:turbo run build -F="$npm_package_name"`,"build:types":`tsc -p tsconfig.types.json`,"build:types:downlevel":`downlevel-dts dist-types dist-types/ts3.4`,clean:`premove dist-cjs dist-es dist-types tsconfig.cjs.tsbuildinfo tsconfig.es.tsbuildinfo tsconfig.types.tsbuildinfo`,"extract:docs":`api-extractor run --local`,"generate:client":`node ../../scripts/generate-clients/single-service --solo iam`,test:`yarn g:vitest run --passWithNoTests`,"test:e2e":`yarn g:vitest run -c vitest.config.e2e.mts --mode development`,"test:e2e:watch":`yarn g:vitest watch -c vitest.config.e2e.mts`,"test:index":`tsc --noEmit ./test/index-types.ts && node ./test/index-objects.spec.mjs`,"test:integration":`yarn g:vitest run --passWithNoTests -c vitest.config.integ.mts`,"test:integration:watch":`yarn g:vitest run --passWithNoTests -c vitest.config.integ.mts`,"test:watch":`yarn g:vitest watch --passWithNoTests`},BB=`./dist-cjs/index.js`,VB=`./dist-types/index.d.ts`,HB=`./dist-es/index.js`,UB={"@aws-crypto/sha256-browser":`5.2.0`,"@aws-crypto/sha256-js":`5.2.0`,"@aws-sdk/core":`^3.973.25`,"@aws-sdk/credential-provider-node":`^3.972.27`,"@aws-sdk/middleware-host-header":`^3.972.8`,"@aws-sdk/middleware-logger":`^3.972.8`,"@aws-sdk/middleware-recursion-detection":`^3.972.9`,"@aws-sdk/middleware-user-agent":`^3.972.26`,"@aws-sdk/region-config-resolver":`^3.972.10`,"@aws-sdk/types":`^3.973.6`,"@aws-sdk/util-endpoints":`^3.996.5`,"@aws-sdk/util-user-agent-browser":`^3.972.8`,"@aws-sdk/util-user-agent-node":`^3.973.12`,"@smithy/config-resolver":`^4.4.13`,"@smithy/core":`^3.23.12`,"@smithy/fetch-http-handler":`^5.3.15`,"@smithy/hash-node":`^4.2.12`,"@smithy/invalid-dependency":`^4.2.12`,"@smithy/middleware-content-length":`^4.2.12`,"@smithy/middleware-endpoint":`^4.4.27`,"@smithy/middleware-retry":`^4.4.44`,"@smithy/middleware-serde":`^4.2.15`,"@smithy/middleware-stack":`^4.2.12`,"@smithy/node-config-provider":`^4.3.12`,"@smithy/node-http-handler":`^4.5.0`,"@smithy/protocol-http":`^5.3.12`,"@smithy/smithy-client":`^4.12.7`,"@smithy/types":`^4.13.1`,"@smithy/url-parser":`^4.2.12`,"@smithy/util-base64":`^4.3.2`,"@smithy/util-body-length-browser":`^4.2.2`,"@smithy/util-body-length-node":`^4.2.3`,"@smithy/util-defaults-mode-browser":`^4.3.43`,"@smithy/util-defaults-mode-node":`^4.2.47`,"@smithy/util-endpoints":`^3.3.3`,"@smithy/util-middleware":`^4.2.12`,"@smithy/util-retry":`^4.2.12`,"@smithy/util-utf8":`^4.2.2`,"@smithy/util-waiter":`^4.2.13`,tslib:`^2.6.2`},WB={"@smithy/snapshot-testing":`^2.0.3`,"@tsconfig/node20":`20.1.8`,"@types/node":`^20.14.8`,concurrently:`7.0.0`,"downlevel-dts":`0.10.1`,premove:`4.0.0`,typescript:`~5.8.3`,vitest:`^4.0.17`},GB={node:`>=20.0.0`},KB={"<4.5":{"dist-types/*":[`dist-types/ts3.4/*`]}},qB=[`dist-*/**`],JB={name:`AWS SDK for JavaScript Team`,url:`https://aws.amazon.com/javascript/`},YB=`Apache-2.0`,XB={"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.browser`},ZB=`https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-iam`,QB={type:`git`,url:`https://github.com/aws/aws-sdk-js-v3.git`,directory:`clients/client-iam`},$B={name:IB,description:LB,version:RB,scripts:zB,main:BB,types:VB,module:HB,sideEffects:!1,dependencies:UB,devDependencies:WB,engines:GB,typesVersions:KB,files:qB,author:JB,license:YB,browser:XB,"react-native":{"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.native`},homepage:ZB,repository:QB},eV=`required`,tV=`fn`,nV=`argv`,rV=`ref`,iV=`properties`,aV=`headers`,oV=`authSchemes`,sV=`name`,cV=`signingRegion`,lV=!0,uV=`isSet`,dV=`booleanEquals`,fV=`error`,pV=`endpoint`,mV=`tree`,hV=`PartitionResult`,gV=`stringEquals`,_V=`sigv4`,vV={[eV]:!0,default:!1,type:`boolean`},yV={[eV]:!1,type:`string`},bV={[rV]:`Endpoint`},xV={[tV]:dV,[nV]:[{[rV]:`UseFIPS`},!0]},SV={[tV]:dV,[nV]:[{[rV]:`UseDualStack`},!0]},CV={},wV={[tV]:gV,[nV]:[{[tV]:`getAttr`,[nV]:[{[rV]:hV},`name`]},`aws`]},TV={[tV]:`getAttr`,[nV]:[{[rV]:hV},`name`]},EV={[tV]:dV,[nV]:[{[rV]:`UseFIPS`},!1]},DV={[oV]:[{[sV]:_V,[cV]:`us-east-1`}]},OV={[tV]:gV,[nV]:[TV,`aws-cn`]},kV={[oV]:[{[sV]:_V,[cV]:`cn-north-1`}]},AV={[tV]:dV,[nV]:[{[rV]:`UseDualStack`},!1]},jV={[tV]:gV,[nV]:[TV,`aws-us-gov`]},MV={url:`https://iam.us-gov.api.aws`,[iV]:{[oV]:[{[sV]:_V,[cV]:`us-gov-west-1`}]},[aV]:{}},NV={url:`https://iam.us-gov.amazonaws.com`,[iV]:{[oV]:[{[sV]:_V,[cV]:`us-gov-west-1`}]},[aV]:{}},PV={[tV]:gV,[nV]:[TV,`aws-iso`]},FV={[oV]:[{[sV]:_V,[cV]:`us-iso-east-1`}]},IV={[tV]:gV,[nV]:[TV,`aws-iso-b`]},LV={[oV]:[{[sV]:_V,[cV]:`us-isob-east-1`}]},RV={[tV]:`getAttr`,[nV]:[{[rV]:hV},`supportsFIPS`]},zV={[tV]:dV,[nV]:[!0,{[tV]:`getAttr`,[nV]:[{[rV]:hV},`supportsDualStack`]}]},BV={[oV]:[{[sV]:_V,[cV]:`{PartitionResult#implicitGlobalRegion}`}]},VV=[{[rV]:`Region`}],HV={version:`1.0`,parameters:{UseDualStack:vV,UseFIPS:vV,Endpoint:yV,Region:yV},rules:[{conditions:[{[tV]:uV,[nV]:[bV]}],rules:[{conditions:[xV],error:`Invalid Configuration: FIPS and custom endpoint are not supported`,type:fV},{rules:[{conditions:[SV],error:`Invalid Configuration: Dualstack and custom endpoint are not supported`,type:fV},{endpoint:{url:bV,[iV]:CV,[aV]:CV},type:pV}],type:mV}],type:mV},{rules:[{conditions:[{[tV]:uV,[nV]:VV}],rules:[{conditions:[{[tV]:`aws.partition`,[nV]:VV,assign:hV}],rules:[{conditions:[wV,EV,SV],endpoint:{url:`https://iam.global.api.aws`,[iV]:DV,[aV]:CV},type:pV},{conditions:[wV,xV,SV],endpoint:{url:`https://iam-fips.global.api.aws`,[iV]:DV,[aV]:CV},type:pV},{conditions:[OV,EV,SV],endpoint:{url:`https://iam.global.api.amazonwebservices.com.cn`,[iV]:kV,[aV]:CV},type:pV},{conditions:[OV,EV,AV],endpoint:{url:`https://iam.cn-north-1.amazonaws.com.cn`,[iV]:kV,[aV]:CV},type:pV},{conditions:[jV,EV,SV],endpoint:MV,type:pV},{conditions:[jV,xV,SV],endpoint:MV,type:pV},{conditions:[jV,EV,AV],endpoint:NV,type:pV},{conditions:[jV,xV,AV],endpoint:NV,type:pV},{conditions:[PV,EV,AV],endpoint:{url:`https://iam.us-iso-east-1.c2s.ic.gov`,[iV]:FV,[aV]:CV},type:pV},{conditions:[PV,xV,AV],endpoint:{url:`https://iam-fips.us-iso-east-1.c2s.ic.gov`,[iV]:FV,[aV]:CV},type:pV},{conditions:[IV,EV,AV],endpoint:{url:`https://iam.us-isob-east-1.sc2s.sgov.gov`,[iV]:LV,[aV]:CV},type:pV},{conditions:[IV,xV,AV],endpoint:{url:`https://iam-fips.us-isob-east-1.sc2s.sgov.gov`,[iV]:LV,[aV]:CV},type:pV},{conditions:[{[tV]:gV,[nV]:[TV,`aws-iso-e`]},EV,AV],endpoint:{url:`https://iam.eu-isoe-west-1.cloud.adc-e.uk`,[iV]:{[oV]:[{[sV]:_V,[cV]:`eu-isoe-west-1`}]},[aV]:CV},type:pV},{conditions:[{[tV]:gV,[nV]:[TV,`aws-iso-f`]},EV,AV],endpoint:{url:`https://iam.us-isof-south-1.csp.hci.ic.gov`,[iV]:{[oV]:[{[sV]:_V,[cV]:`us-isof-south-1`}]},[aV]:CV},type:pV},{conditions:[{[tV]:gV,[nV]:[TV,`aws-eusc`]},EV,AV],endpoint:{url:`https://iam.eusc-de-east-1.amazonaws.eu`,[iV]:{[oV]:[{[sV]:_V,[cV]:`eusc-de-east-1`}]},[aV]:CV},type:pV},{conditions:[xV,SV],rules:[{conditions:[{[tV]:dV,[nV]:[lV,RV]},zV],rules:[{endpoint:{url:`https://iam-fips.{PartitionResult#dualStackDnsSuffix}`,[iV]:BV,[aV]:CV},type:pV}],type:mV},{error:`FIPS and DualStack are enabled, but this partition does not support one or both`,type:fV}],type:mV},{conditions:[xV,AV],rules:[{conditions:[{[tV]:dV,[nV]:[RV,lV]}],rules:[{endpoint:{url:`https://iam-fips.{PartitionResult#dnsSuffix}`,[iV]:BV,[aV]:CV},type:pV}],type:mV},{error:`FIPS is enabled but this partition does not support FIPS`,type:fV}],type:mV},{conditions:[EV,SV],rules:[{conditions:[zV],rules:[{endpoint:{url:`https://iam.{PartitionResult#dualStackDnsSuffix}`,[iV]:BV,[aV]:CV},type:pV}],type:mV},{error:`DualStack is enabled but this partition does not support DualStack`,type:fV}],type:mV},{endpoint:{url:`https://iam.{PartitionResult#dnsSuffix}`,[iV]:BV,[aV]:CV},type:pV}],type:mV}],type:mV},{error:`Invalid Configuration: Missing Region`,type:fV}],type:mV}]},UV=new er({size:50,params:[`Endpoint`,`Region`,`UseDualStack`,`UseFIPS`]}),WV=(e,t={})=>UV.get(e,()=>Mr(HV,{endpointParams:e,logger:t.logger}));ar.aws=Vr;var b=class e extends hi{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}},GV=class e extends b{name=`ConcurrentModificationException`;$fault=`client`;constructor(t){super({name:`ConcurrentModificationException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},KV=class e extends b{name=`NoSuchEntityException`;$fault=`client`;constructor(t){super({name:`NoSuchEntityException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},qV=class e extends b{name=`ServiceFailureException`;$fault=`server`;constructor(t){super({name:`ServiceFailureException`,$fault:`server`,...t}),Object.setPrototypeOf(this,e.prototype)}},JV=class e extends b{name=`AccountNotManagementOrDelegatedAdministratorException`;$fault=`client`;Message;constructor(t){super({name:`AccountNotManagementOrDelegatedAdministratorException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},YV=class e extends b{name=`InvalidInputException`;$fault=`client`;constructor(t){super({name:`InvalidInputException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},XV=class e extends b{name=`LimitExceededException`;$fault=`client`;constructor(t){super({name:`LimitExceededException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},ZV=class e extends b{name=`EntityAlreadyExistsException`;$fault=`client`;constructor(t){super({name:`EntityAlreadyExistsException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},QV=class e extends b{name=`UnmodifiableEntityException`;$fault=`client`;constructor(t){super({name:`UnmodifiableEntityException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},$V=class e extends b{name=`PolicyNotAttachableException`;$fault=`client`;constructor(t){super({name:`PolicyNotAttachableException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},eH=class e extends b{name=`EntityTemporarilyUnmodifiableException`;$fault=`client`;constructor(t){super({name:`EntityTemporarilyUnmodifiableException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},tH=class e extends b{name=`InvalidUserTypeException`;$fault=`client`;constructor(t){super({name:`InvalidUserTypeException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},nH=class e extends b{name=`PasswordPolicyViolationException`;$fault=`client`;constructor(t){super({name:`PasswordPolicyViolationException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},rH=class e extends b{name=`OpenIdIdpCommunicationErrorException`;$fault=`client`;constructor(t){super({name:`OpenIdIdpCommunicationErrorException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},iH=class e extends b{name=`MalformedPolicyDocumentException`;$fault=`client`;constructor(t){super({name:`MalformedPolicyDocumentException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},aH=class e extends b{name=`ServiceNotSupportedException`;$fault=`client`;constructor(t){super({name:`ServiceNotSupportedException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},oH=class e extends b{name=`DeleteConflictException`;$fault=`client`;constructor(t){super({name:`DeleteConflictException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},sH=class e extends b{name=`OrganizationNotFoundException`;$fault=`client`;Message;constructor(t){super({name:`OrganizationNotFoundException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},cH=class e extends b{name=`OrganizationNotInAllFeaturesModeException`;$fault=`client`;Message;constructor(t){super({name:`OrganizationNotInAllFeaturesModeException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},lH=class e extends b{name=`ServiceAccessNotEnabledException`;$fault=`client`;Message;constructor(t){super({name:`ServiceAccessNotEnabledException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},uH=class e extends b{name=`FeatureDisabledException`;$fault=`client`;constructor(t){super({name:`FeatureDisabledException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},dH=class e extends b{name=`InvalidAuthenticationCodeException`;$fault=`client`;constructor(t){super({name:`InvalidAuthenticationCodeException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},fH=class e extends b{name=`CallerIsNotManagementAccountException`;$fault=`client`;Message;constructor(t){super({name:`CallerIsNotManagementAccountException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},pH=class e extends b{name=`FeatureEnabledException`;$fault=`client`;constructor(t){super({name:`FeatureEnabledException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},mH=class e extends b{name=`ReportGenerationLimitExceededException`;$fault=`client`;constructor(t){super({name:`ReportGenerationLimitExceededException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},hH=class e extends b{name=`CredentialReportExpiredException`;$fault=`client`;constructor(t){super({name:`CredentialReportExpiredException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},gH=class e extends b{name=`CredentialReportNotPresentException`;$fault=`client`;constructor(t){super({name:`CredentialReportNotPresentException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},_H=class e extends b{name=`CredentialReportNotReadyException`;$fault=`client`;constructor(t){super({name:`CredentialReportNotReadyException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},vH=class e extends b{name=`UnrecognizedPublicKeyEncodingException`;$fault=`client`;constructor(t){super({name:`UnrecognizedPublicKeyEncodingException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},yH=class e extends b{name=`PolicyEvaluationException`;$fault=`server`;constructor(t){super({name:`PolicyEvaluationException`,$fault:`server`,...t}),Object.setPrototypeOf(this,e.prototype)}},bH=class e extends b{name=`KeyPairMismatchException`;$fault=`client`;constructor(t){super({name:`KeyPairMismatchException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},xH=class e extends b{name=`MalformedCertificateException`;$fault=`client`;constructor(t){super({name:`MalformedCertificateException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},SH=class e extends b{name=`DuplicateCertificateException`;$fault=`client`;constructor(t){super({name:`DuplicateCertificateException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},CH=class e extends b{name=`InvalidCertificateException`;$fault=`client`;constructor(t){super({name:`InvalidCertificateException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},wH=class e extends b{name=`DuplicateSSHPublicKeyException`;$fault=`client`;constructor(t){super({name:`DuplicateSSHPublicKeyException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},TH=class e extends b{name=`InvalidPublicKeyException`;$fault=`client`;constructor(t){super({name:`InvalidPublicKeyException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},EH=`Arn`,DH=`AttachmentCount`,OH=`AccessKey`,kH=`AccessKeyId`,AH=`AccessKeyMetadata`,jH=`AccountNotManagementOrDelegatedAdministratorException`,MH=`AttachedPolicy`,NH=`AttachedPermissionsBoundary`,PH=`AttachedPolicies`,FH=`AttachUserPolicy`,IH=`AttachUserPolicyRequest`,LH=`CreateAccessKey`,RH=`CreateAccessKeyRequest`,zH=`CreateAccessKeyResponse`,BH=`CreateDate`,VH=`CallerIsNotManagementAccountException`,HH=`ConcurrentModificationException`,UH=`CreatePolicyRequest`,WH=`CreatePolicyResponse`,GH=`CreatePolicy`,KH=`CredentialReportExpiredException`,qH=`CredentialReportNotPresentException`,JH=`CredentialReportNotReadyException`,YH=`CreateUser`,XH=`CreateUserRequest`,ZH=`CreateUserResponse`,QH=`Description`,$H=`DeleteAccessKey`,eU=`DeleteAccessKeyRequest`,tU=`DeleteConflictException`,nU=`DuplicateCertificateException`,rU=`DeletePolicyRequest`,iU=`DeletePolicy`,aU=`DuplicateSSHPublicKeyException`,oU=`DeleteUser`,sU=`DetachUserPolicyRequest`,cU=`DetachUserPolicy`,lU=`DeleteUserRequest`,uU=`DefaultVersionId`,dU=`Document`,fU=`EntityAlreadyExistsException`,pU=`EntityTemporarilyUnmodifiableException`,mU=`FeatureDisabledException`,hU=`FeatureEnabledException`,gU=`GetPolicy`,_U=`GetPolicyRequest`,vU=`GetPolicyResponse`,yU=`GetPolicyVersion`,bU=`GetPolicyVersionRequest`,xU=`GetPolicyVersionResponse`,SU=`GetUser`,CU=`GetUserRequest`,wU=`GetUserResponse`,TU=`IsAttachable`,EU=`InvalidAuthenticationCodeException`,DU=`InvalidCertificateException`,OU=`IsDefaultVersion`,kU=`InvalidInputException`,AU=`InvalidPublicKeyException`,jU=`IsTruncated`,MU=`InvalidUserTypeException`,NU=`Key`,PU=`KeyPairMismatchException`,FU=`ListAccessKeys`,IU=`ListAccessKeysRequest`,LU=`ListAccessKeysResponse`,RU=`ListAttachedUserPolicies`,zU=`ListAttachedUserPoliciesRequest`,BU=`ListAttachedUserPoliciesResponse`,VU=`LimitExceededException`,HU=`ListPoliciesRequest`,UU=`ListPoliciesResponse`,WU=`ListPolicies`,GU=`ListUsers`,KU=`ListUsersRequest`,qU=`ListUsersResponse`,JU=`Message`,YU=`MalformedCertificateException`,XU=`MaxItems`,ZU=`MalformedPolicyDocumentException`,QU=`Marker`,$U=`NoSuchEntityException`,eW=`OnlyAttached`,tW=`OpenIdIdpCommunicationErrorException`,nW=`OrganizationNotFoundException`,rW=`OrganizationNotInAllFeaturesModeException`,iW=`PolicyArn`,aW=`PermissionsBoundary`,oW=`PermissionsBoundaryArn`,sW=`PermissionsBoundaryType`,cW=`PermissionsBoundaryUsageCount`,lW=`PolicyDocument`,uW=`PolicyEvaluationException`,dW=`PolicyId`,fW=`PasswordLastUsed`,pW=`PolicyName`,mW=`PolicyNotAttachableException`,hW=`PasswordPolicyViolationException`,gW=`PathPrefix`,_W=`PolicyUsageFilter`,vW=`PolicyVersion`,yW=`Path`,bW=`Policy`,xW=`Policies`,SW=`ReportGenerationLimitExceededException`,CW=`Status`,wW=`SecretAccessKey`,TW=`ServiceAccessNotEnabledException`,EW=`ServiceFailureException`,DW=`ServiceNotSupportedException`,OW=`Scope`,kW=`Tags`,AW=`Tag`,jW=`UpdateAccessKey`,MW=`UpdateAccessKeyRequest`,NW=`UpdateDate`,PW=`UnmodifiableEntityException`,FW=`UserId`,IW=`UserName`,LW=`UnrecognizedPublicKeyEncodingException`,RW=`User`,zW=`Users`,BW=`VersionId`,VW=`Value`,HW=`accessKeyMetadataListType`,UW=`accessKeySecretType`,WW=`attachedPoliciesListType`,x=`awsQueryError`,S=`client`,C=`error`,w=`httpError`,T=`message`,GW=`policyListType`,KW=`smithy.ts.sdk.synthetic.com.amazonaws.iam`,qW=`server`,JW=`tagListType`,YW=`userListType`,E=`com.amazonaws.iam`,XW=At.for(KW),ZW=[-3,KW,`IAMServiceException`,0,[],[]];XW.registerError(ZW,b);var D=At.for(E),QW=[-3,E,jH,{[C]:S,[w]:400},[JU],[0]];D.registerError(QW,JV);var $W=[-3,E,VH,{[C]:S,[w]:400},[JU],[0]];D.registerError($W,fH);var eG=[-3,E,HH,{[x]:[`ConcurrentModification`,409],[C]:S,[w]:409},[T],[0]];D.registerError(eG,GV);var tG=[-3,E,KH,{[x]:[`ReportExpired`,410],[C]:S,[w]:410},[T],[0]];D.registerError(tG,hH);var nG=[-3,E,qH,{[x]:[`ReportNotPresent`,410],[C]:S,[w]:410},[T],[0]];D.registerError(nG,gH);var rG=[-3,E,JH,{[x]:[`ReportInProgress`,404],[C]:S,[w]:404},[T],[0]];D.registerError(rG,_H);var iG=[-3,E,tU,{[x]:[`DeleteConflict`,409],[C]:S,[w]:409},[T],[0]];D.registerError(iG,oH);var aG=[-3,E,nU,{[x]:[`DuplicateCertificate`,409],[C]:S,[w]:409},[T],[0]];D.registerError(aG,SH);var oG=[-3,E,aU,{[x]:[`DuplicateSSHPublicKey`,400],[C]:S,[w]:400},[T],[0]];D.registerError(oG,wH);var sG=[-3,E,fU,{[x]:[`EntityAlreadyExists`,409],[C]:S,[w]:409},[T],[0]];D.registerError(sG,ZV);var cG=[-3,E,pU,{[x]:[`EntityTemporarilyUnmodifiable`,409],[C]:S,[w]:409},[T],[0]];D.registerError(cG,eH);var lG=[-3,E,mU,{[x]:[`FeatureDisabled`,404],[C]:S,[w]:404},[T],[0]];D.registerError(lG,uH);var uG=[-3,E,hU,{[x]:[`FeatureEnabled`,409],[C]:S,[w]:409},[T],[0]];D.registerError(uG,pH);var dG=[-3,E,EU,{[x]:[`InvalidAuthenticationCode`,403],[C]:S,[w]:403},[T],[0]];D.registerError(dG,dH);var fG=[-3,E,DU,{[x]:[`InvalidCertificate`,400],[C]:S,[w]:400},[T],[0]];D.registerError(fG,CH);var pG=[-3,E,kU,{[x]:[`InvalidInput`,400],[C]:S,[w]:400},[T],[0]];D.registerError(pG,YV);var mG=[-3,E,AU,{[x]:[`InvalidPublicKey`,400],[C]:S,[w]:400},[T],[0]];D.registerError(mG,TH);var hG=[-3,E,MU,{[x]:[`InvalidUserType`,400],[C]:S,[w]:400},[T],[0]];D.registerError(hG,tH);var gG=[-3,E,PU,{[x]:[`KeyPairMismatch`,400],[C]:S,[w]:400},[T],[0]];D.registerError(gG,bH);var _G=[-3,E,VU,{[x]:[`LimitExceeded`,409],[C]:S,[w]:409},[T],[0]];D.registerError(_G,XV);var vG=[-3,E,YU,{[x]:[`MalformedCertificate`,400],[C]:S,[w]:400},[T],[0]];D.registerError(vG,xH);var yG=[-3,E,ZU,{[x]:[`MalformedPolicyDocument`,400],[C]:S,[w]:400},[T],[0]];D.registerError(yG,iH);var bG=[-3,E,$U,{[x]:[`NoSuchEntity`,404],[C]:S,[w]:404},[T],[0]];D.registerError(bG,KV);var xG=[-3,E,tW,{[x]:[`OpenIdIdpCommunicationError`,400],[C]:S,[w]:400},[T],[0]];D.registerError(xG,rH);var SG=[-3,E,nW,{[C]:S,[w]:400},[JU],[0]];D.registerError(SG,sH);var CG=[-3,E,rW,{[C]:S,[w]:400},[JU],[0]];D.registerError(CG,cH);var wG=[-3,E,hW,{[x]:[`PasswordPolicyViolation`,400],[C]:S,[w]:400},[T],[0]];D.registerError(wG,nH);var TG=[-3,E,uW,{[x]:[`PolicyEvaluation`,500],[C]:qW,[w]:500},[T],[0]];D.registerError(TG,yH);var EG=[-3,E,mW,{[x]:[`PolicyNotAttachable`,400],[C]:S,[w]:400},[T],[0]];D.registerError(EG,$V);var DG=[-3,E,SW,{[x]:[`ReportGenerationLimitExceeded`,409],[C]:S,[w]:409},[T],[0]];D.registerError(DG,mH);var OG=[-3,E,TW,{[C]:S,[w]:400},[JU],[0]];D.registerError(OG,lH);var kG=[-3,E,EW,{[x]:[`ServiceFailure`,500],[C]:qW,[w]:500},[T],[0]];D.registerError(kG,qV);var AG=[-3,E,DW,{[x]:[`NotSupportedService`,404],[C]:S,[w]:404},[T],[0]];D.registerError(AG,aH);var jG=[-3,E,PW,{[x]:[`UnmodifiableEntity`,400],[C]:S,[w]:400},[T],[0]];D.registerError(jG,QV);var MG=[-3,E,LW,{[x]:[`UnrecognizedPublicKeyEncoding`,400],[C]:S,[w]:400},[T],[0]];D.registerError(MG,vH);var NG=[XW,D],PG=[0,E,UW,8,0],FG=[3,E,OH,0,[IW,kH,CW,wW,BH],[0,0,0,[()=>PG,0],4],4],IG=[3,E,AH,0,[IW,kH,CW,BH],[0,0,0,4]],LG=[3,E,NH,0,[sW,oW],[0,0]],RG=[3,E,MH,0,[pW,iW],[0,0]],zG=[3,E,IH,0,[IW,iW],[0,0],2],BG=[3,E,RH,0,[IW],[0]],VG=[3,E,zH,0,[OH],[[()=>FG,0]],1],HG=[3,E,UH,0,[pW,lW,yW,QH,kW],[0,0,0,0,()=>yK],2],UG=[3,E,WH,0,[bW],[()=>uK]],WG=[3,E,XH,0,[IW,yW,aW,kW],[0,0,0,()=>yK],1],GG=[3,E,ZH,0,[RW],[()=>mK]],KG=[3,E,eU,0,[kH,IW],[0,0],1],qG=[3,E,rU,0,[iW],[0],1],JG=[3,E,lU,0,[IW],[0],1],YG=[3,E,sU,0,[IW,iW],[0,0],2],XG=[3,E,_U,0,[iW],[0],1],ZG=[3,E,vU,0,[bW],[()=>uK]],QG=[3,E,bU,0,[iW,BW],[0,0],2],$G=[3,E,xU,0,[vW],[()=>dK]],eK=[3,E,CU,0,[IW],[0]],tK=[3,E,wU,0,[RW],[()=>mK],1],nK=[3,E,IU,0,[IW,QU,XU],[0,0,1]],rK=[3,E,LU,0,[AH,jU,QU],[()=>gK,2,0],1],iK=[3,E,zU,0,[IW,gW,QU,XU],[0,0,0,1],1],aK=[3,E,BU,0,[PH,jU,QU],[()=>_K,2,0]],oK=[3,E,HU,0,[OW,eW,gW,_W,QU,XU],[0,2,0,0,0,1]],sK=[3,E,UU,0,[xW,jU,QU],[()=>vK,2,0]],cK=[3,E,KU,0,[gW,QU,XU],[0,0,1]],lK=[3,E,qU,0,[zW,jU,QU],[()=>bK,2,0],1],uK=[3,E,bW,0,[pW,dW,EH,yW,uU,DH,cW,TU,QH,BH,NW,kW],[0,0,0,0,0,1,1,2,0,4,4,()=>yK]],dK=[3,E,vW,0,[dU,BW,OU,BH],[0,0,2,4]],fK=[3,E,AW,0,[NU,VW],[0,0],2],pK=[3,E,MW,0,[kH,CW,IW],[0,0,0],2],mK=[3,E,RW,0,[yW,IW,FW,EH,BH,fW,aW,kW],[0,0,0,0,4,4,()=>LG,()=>yK],5],hK=`unit`,gK=[1,E,HW,0,()=>IG],_K=[1,E,WW,0,()=>RG],vK=[1,E,GW,0,()=>uK],yK=[1,E,JW,0,()=>fK],bK=[1,E,YW,0,()=>mK],xK=[9,E,FH,0,()=>zG,()=>hK],SK=[9,E,LH,0,()=>BG,()=>VG],CK=[9,E,GH,0,()=>HG,()=>UG],wK=[9,E,YH,0,()=>WG,()=>GG],TK=[9,E,$H,0,()=>KG,()=>hK],EK=[9,E,iU,0,()=>qG,()=>hK],DK=[9,E,oU,0,()=>JG,()=>hK],OK=[9,E,cU,0,()=>YG,()=>hK],kK=[9,E,gU,0,()=>XG,()=>ZG],AK=[9,E,yU,0,()=>QG,()=>$G],jK=[9,E,SU,0,()=>eK,()=>tK],MK=[9,E,FU,0,()=>nK,()=>rK],NK=[9,E,RU,0,()=>iK,()=>aK],PK=[9,E,WU,0,()=>oK,()=>sK],FK=[9,E,GU,0,()=>cK,()=>lK],IK=[9,E,jW,0,()=>pK,()=>hK],LK=e=>({apiVersion:`2010-05-08`,base64Decoder:e?.base64Decoder??Ue,base64Encoder:e?.base64Encoder??We,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??WV,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??MB,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:`aws.auth#sigv4`,identityProvider:e=>e.getIdentityProvider(`aws.auth#sigv4`),signer:new Xr}],logger:e?.logger??new Ei,protocol:e?.protocol??Hi,protocolSettings:e?.protocolSettings??{defaultNamespace:`com.amazonaws.iam`,errorTypeRegistries:NG,xmlNamespace:`https://iam.amazonaws.com/doc/2010-05-08/`,version:`2010-05-08`,serviceTarget:`AWSIdentityManagementV20100508`},serviceId:e?.serviceId??`IAM`,urlParser:e?.urlParser??gt,utf8Decoder:e?.utf8Decoder??se,utf8Encoder:e?.utf8Encoder??ce}),RK=e=>{let t=Io(e),n=()=>t().then(_i),r=LK(e);return{...r,...e,runtime:`browser`,defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??ii,credentialDefaultProvider:e?.credentialDefaultProvider??(e=>()=>Promise.reject(Error(`Credential is missing`))),defaultUserAgentProvider:e?.defaultUserAgentProvider??Mo({serviceId:r.serviceId,clientVersion:$B.version}),maxAttempts:e?.maxAttempts??3,region:e?.region??Po(`Region is missing`),requestHandler:$e.create(e?.requestHandler??n),retryMode:e?.retryMode??(async()=>(await n()).retryMode||Yi),sha256:e?.sha256??l,streamCollector:e?.streamCollector??tt,useDualstackEndpoint:e?.useDualstackEndpoint??(()=>Promise.resolve(!1)),useFipsEndpoint:e?.useFipsEndpoint??(()=>Promise.resolve(!1))}},zK=e=>{let t=e.httpAuthSchemes,n=e.httpAuthSchemeProvider,r=e.credentials;return{setHttpAuthScheme(e){let n=t.findIndex(t=>t.schemeId===e.schemeId);n===-1?t.push(e):t.splice(n,1,e)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(e){n=e},httpAuthSchemeProvider(){return n},setCredentials(e){r=e},credentials(){return r}}},BK=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()}),VK=(e,t)=>{let n=Object.assign(wB(e),Ci(e),de(e),zK(e));return t.forEach(e=>e.configure(n)),Object.assign(e,TB(n),wi(n),fe(n),BK(n))},HK=class extends ui{config;constructor(...[e]){let t=RK(e||{});super(t),this.initConfig=t,this.config=VK(NB(Xa(ye(ja(Qa($n(PB(t))))))),e?.extensions||[]),this.middlewareStack.use(xt(this.config)),this.middlewareStack.use(Ea(this.config)),this.middlewareStack.use(ao(this.config)),this.middlewareStack.use(Fa(this.config)),this.middlewareStack.use(Se(this.config)),this.middlewareStack.use(Te(this.config)),this.middlewareStack.use(Oe(this.config)),this.middlewareStack.use(Ne(this.config,{httpAuthSchemeParametersProvider:AB,identityProviderConfigProvider:async e=>new Jn({"aws.auth#sigv4":e.credentials})})),this.middlewareStack.use(Re(this.config))}destroy(){super.destroy()}};function UK(e){return t=>async n=>{let{request:r}=n;if(e.expectContinueHeader!==!1&&i.isInstance(r)&&r.body&&e.runtime===`node`&&e.requestHandler?.constructor?.name!==`FetchHttpHandler`){let t=!0;if(typeof e.expectContinueHeader==`number`)try{t=(Number(r.headers?.[`content-length`])??e.bodyLengthChecker?.(r.body)??1/0)>=e.expectContinueHeader}catch{}else t=!!e.expectContinueHeader;t&&(r.headers.Expect=`100-continue`)}return t({...n,request:r})}}var WK={step:`build`,tags:[`SET_EXPECT_HEADER`,`EXPECT_HEADER`],name:`addExpectContinueMiddleware`,override:!0},GK=e=>({applyToStack:t=>{t.add(UK(e),WK)}}),KK={WHEN_SUPPORTED:`WHEN_SUPPORTED`,WHEN_REQUIRED:`WHEN_REQUIRED`},qK=KK.WHEN_SUPPORTED,JK={WHEN_SUPPORTED:`WHEN_SUPPORTED`,WHEN_REQUIRED:`WHEN_REQUIRED`},YK=KK.WHEN_SUPPORTED,XK;(function(e){e.MD5=`MD5`,e.CRC32=`CRC32`,e.CRC32C=`CRC32C`,e.CRC64NVME=`CRC64NVME`,e.SHA1=`SHA1`,e.SHA256=`SHA256`})(XK||={});var ZK;(function(e){e.HEADER=`header`,e.TRAILER=`trailer`})(ZK||={});var QK=XK.CRC32,$K=function(){function e(){this.crc32=new eq}return e.prototype.update=function(e){r(e)||this.crc32.update(ae(e))},e.prototype.digest=function(){return a(this,void 0,void 0,function(){return o(this,function(e){return[2,s(this.crc32.digest())]})})},e.prototype.reset=function(){this.crc32=new eq},e}(),eq=function(){function e(){this.checksum=4294967295}return e.prototype.update=function(e){var t,n;try{for(var r=te(e),i=r.next();!i.done;i=r.next()){var a=i.value;this.checksum=this.checksum>>>8^tq[(this.checksum^a)&255]}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}return this},e.prototype.digest=function(){return(this.checksum^4294967295)>>>0},e}(),tq=c([0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117]),nq=e=>{let{requestChecksumCalculation:t,responseChecksumValidation:n,requestStreamBufferSize:r}=e;return Object.assign(e,{requestChecksumCalculation:f(t??qK),responseChecksumValidation:f(n??YK),requestStreamBufferSize:Number(r??0),checksumAlgorithms:e.checksumAlgorithms??{}})},rq=e=>(t,n)=>async r=>{let i=await e.region(),a=e.region,o=()=>{};n.__s3RegionRedirect&&(Object.defineProperty(e,`region`,{writable:!1,value:async()=>n.__s3RegionRedirect}),o=()=>Object.defineProperty(e,`region`,{writable:!0,value:a}));try{let a=await t(r);if(n.__s3RegionRedirect&&(o(),i!==await e.region()))throw Error(`Region was not restored following S3 region redirect.`);return a}catch(e){throw o(),e}},iq={tags:[`REGION_REDIRECT`,`S3`],name:`regionRedirectEndpointMiddleware`,override:!0,relation:`before`,toMiddleware:`endpointV2Middleware`};function aq(e){return(t,n)=>async r=>{try{return await t(r)}catch(i){if(e.followRegionRedirects){let a=i?.$metadata?.httpStatusCode,o=n.commandName===`HeadBucketCommand`,s=i?.$response?.headers?.[`x-amz-bucket-region`];if(s&&(a===301||a===400&&(i?.name===`IllegalLocationConstraintException`||o))){try{let t=s;n.logger?.debug(`Redirecting from ${await e.region()} to ${t}`),n.__s3RegionRedirect=t}catch(e){throw Error(`Region redirect failed: `+e)}return t(r)}}throw i}}}var oq={step:`initialize`,tags:[`REGION_REDIRECT`,`S3`],name:`regionRedirectMiddleware`,override:!0},sq=e=>({applyToStack:t=>{t.add(aq(e),oq),t.addRelativeTo(rq(e),iq)}}),cq=class e{data;lastPurgeTime=Date.now();static EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS=3e4;constructor(e={}){this.data=e}get(e){let t=this.data[e];if(t)return t}set(e,t){return this.data[e]=t,t}delete(e){delete this.data[e]}async purgeExpired(){let t=Date.now();if(!(this.lastPurgeTime+e.EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS>t))for(let e in this.data){let n=this.data[e];if(!n.isRefreshing){let r=await n.identity;r.expiration&&r.expiration.getTime()(t.expiration?.getTime()??0){i.set(r,new lq(Promise.resolve(e)))})),t)):i.set(r,new lq(this.getIdentity(r))).identity}async getIdentity(e){await this.cache.purgeExpired().catch(e=>{console.warn(`Error while clearing expired entries in S3ExpressIdentityCache: -`+e)});let t=await this.createSessionFn(e);if(!t.Credentials?.AccessKeyId||!t.Credentials?.SecretAccessKey)throw Error(`s3#createSession response credential missing AccessKeyId or SecretAccessKey.`);return{accessKeyId:t.Credentials.AccessKeyId,secretAccessKey:t.Credentials.SecretAccessKey,sessionToken:t.Credentials.SessionToken,expiration:t.Credentials.Expiration?new Date(t.Credentials.Expiration):void 0}}},dq=`sigv4-s3express`,fq=`X-Amz-S3session-Token`,pq=fq.toLowerCase(),mq=class extends re{async signWithCredentials(e,t,n){let r=hq(t);e.headers[pq]=t.sessionToken;let i=this;return gq(i,r),i.signRequest(e,n??{})}async presignWithCredentials(e,t,n){let r=hq(t);return delete e.headers[pq],e.headers[fq]=t.sessionToken,e.query=e.query??{},e.query[fq]=t.sessionToken,gq(this,r),this.presign(e,n)}};function hq(e){return{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey,expiration:e.expiration}}function gq(e,t){let n=setTimeout(()=>{throw Error(`SignatureV4S3Express credential override was created but not called.`)},10),r=e.credentialProvider;e.credentialProvider=()=>(clearTimeout(n),e.credentialProvider=r,Promise.resolve(t))}var _q=e=>(t,n)=>async r=>{if(n.endpointV2){let t=n.endpointV2,a=t.properties?.authSchemes?.[0]?.name===dq;if((t.properties?.backend===`S3Express`||t.properties?.bucketType===`Directory`)&&(Ur(n,`S3_EXPRESS_BUCKET`,`J`),n.isS3ExpressBucket=!0),a){let t=r.input.Bucket;if(t){let a=await e.s3ExpressIdentityProvider.getS3ExpressIdentity(await e.credentials(),{Bucket:t});n.s3ExpressIdentity=a,i.isInstance(r.request)&&a.sessionToken&&(r.request.headers[pq]=a.sessionToken)}}}return t(r)},vq={name:`s3ExpressMiddleware`,step:`build`,tags:[`S3`,`S3_EXPRESS`],override:!0},yq=e=>({applyToStack:t=>{t.add(_q(e),vq)}}),bq=async(e,t,n,r)=>{let i=await r.signWithCredentials(n,e,{});if(i.headers[`X-Amz-Security-Token`]||i.headers[`x-amz-security-token`])throw Error(`X-Amz-Security-Token must not be set for s3-express requests.`);return i},xq=e=>e=>{throw e},Sq=(e,t)=>{},Cq=e=>(t,n)=>async r=>{if(!i.isInstance(r.request))return t(r);let a=_e(n).selectedHttpAuthScheme;if(!a)throw Error(`No HttpAuthScheme was selected: unable to sign request`);let{httpAuthOption:{signingProperties:o={}},identity:s,signer:c}=a,l;l=n.s3ExpressIdentity?await bq(n.s3ExpressIdentity,o,r.request,await e.signer()):await c.sign(r.request,s,o);let u=await t({...r,request:l}).catch((c.errorHandler||xq)(o));return(c.successHandler||Sq)(u.response,o),u},wq=e=>({applyToStack:t=>{t.addRelativeTo(Cq(e),Le)}}),Tq=(e,{session:t})=>{let[n,r]=t,{forcePathStyle:i,useAccelerateEndpoint:a,disableMultiregionAccessPoints:o,followRegionRedirects:s,s3ExpressIdentityProvider:c,bucketEndpoint:l,expectContinueHeader:u}=e;return Object.assign(e,{forcePathStyle:i??!1,useAccelerateEndpoint:a??!1,disableMultiregionAccessPoints:o??!1,followRegionRedirects:s??!1,s3ExpressIdentityProvider:c??new uq(async e=>n().send(new r({Bucket:e}))),bucketEndpoint:l??!1,expectContinueHeader:u??2097152})},Eq={CopyObjectCommand:!0,UploadPartCopyCommand:!0,CompleteMultipartUploadCommand:!0},Dq=3e3,Oq=e=>(t,n)=>async r=>{let i=await t(r),{response:a}=i;if(!ge.isInstance(a))return i;let{statusCode:o,body:s}=a;if(o<200||o>=300||!(typeof s?.stream==`function`||typeof s?.pipe==`function`||typeof s?.tee==`function`))return i;let c=s,l=s;s&&typeof s==`object`&&!(s instanceof Uint8Array)&&([c,l]=await ct(s)),a.body=l;let u=await kq(c,{streamCollector:async e=>Je(e,Dq)});typeof c?.destroy==`function`&&c.destroy();let d=e.utf8Encoder(u.subarray(u.length-16));if(u.length===0&&Eq[n.commandName]){let e=Error(`S3 aborted request`);throw e.name=`InternalError`,e}return d&&d.endsWith(``)&&(a.statusCode=400),i},kq=(e=new Uint8Array,t)=>e instanceof Uint8Array?Promise.resolve(e):t.streamCollector(e)||Promise.resolve(new Uint8Array),Aq={relation:`after`,toMiddleware:`deserializerMiddleware`,tags:[`THROW_200_EXCEPTIONS`,`S3`],name:`throw200ExceptionsMiddleware`,override:!0},jq=e=>({applyToStack:t=>{t.addRelativeTo(Oq(e),Aq)}}),Mq=e=>typeof e==`string`&&e.indexOf(`arn:`)===0&&e.split(`:`).length>=6;function Nq(e){return(t,n)=>async r=>{if(e.bucketEndpoint){let e=n.endpointV2;if(e){let t=r.input.Bucket;if(typeof t==`string`)try{let r=new URL(t);n.endpointV2={...e,url:r}}catch(e){let r=`@aws-sdk/middleware-sdk-s3: bucketEndpoint=true was set but Bucket=${t} could not be parsed as URL.`;throw n.logger?.constructor?.name===`NoOpLogger`?console.warn(r):n.logger?.warn?.(r),e}}}return t(r)}}var Pq={name:`bucketEndpointMiddleware`,override:!0,relation:`after`,toMiddleware:`endpointV2Middleware`};function Fq({bucketEndpoint:e}){return t=>async n=>{let{input:{Bucket:r}}=n;if(!e&&typeof r==`string`&&!Mq(r)&&r.indexOf(`/`)>=0){let e=Error(`Bucket name shouldn't contain '/', received '${r}'`);throw e.name=`InvalidBucketName`,e}return t({...n})}}var Iq={step:`initialize`,tags:[`VALIDATE_BUCKET_NAME`],name:`validateBucketNameMiddleware`,override:!0},Lq=e=>({applyToStack:t=>{t.add(Fq(e),Iq),t.addRelativeTo(Nq(e),Pq)}}),Rq=class extends qi{async serializeRequest(e,t,n){let r=await super.serializeRequest(e,t,n),i=p.of(e.input),a=i.getSchema(),o=0,s=a[6]??0;if(t&&typeof t==`object`)for(let[e,n]of i.structIterator()){if(++o>s)break;if(e===`Bucket`){if(!t.Bucket&&n.getMergedTraits().httpLabel)throw Error(`No value provided for input HTTP label: Bucket.`);break}}return r}},zq=e=>Object.assign(e,{eventStreamMarshaller:e.eventStreamSerdeProvider(e)}),Bq={CrtSignerV4:null},Vq=class{sigv4aSigner;sigv4Signer;signerOptions;static sigv4aDependency(){return typeof Bq.CrtSignerV4==`function`?`crt`:typeof ve.SignatureV4a==`function`?`js`:`none`}constructor(e){this.sigv4Signer=new mq(e),this.signerOptions=e}async sign(e,t={}){return t.signingRegion===`*`?this.getSigv4aSigner().sign(e,t):this.sigv4Signer.sign(e,t)}async signWithCredentials(e,t,n={}){if(n.signingRegion===`*`){let r=this.getSigv4aSigner(),i=Bq.CrtSignerV4;if(i&&r instanceof i)return r.signWithCredentials(e,t,n);throw Error(`signWithCredentials with signingRegion '*' is only supported when using the CRT dependency @aws-sdk/signature-v4-crt. Please check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. You must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}return this.sigv4Signer.signWithCredentials(e,t,n)}async presign(e,t={}){if(t.signingRegion===`*`){let n=this.getSigv4aSigner(),r=Bq.CrtSignerV4;if(r&&n instanceof r)return n.presign(e,t);throw Error(`presign with signingRegion '*' is only supported when using the CRT dependency @aws-sdk/signature-v4-crt. Please check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. You must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}return this.sigv4Signer.presign(e,t)}async presignWithCredentials(e,t,n={}){if(n.signingRegion===`*`)throw Error(`Method presignWithCredentials is not supported for [signingRegion=*].`);return this.sigv4Signer.presignWithCredentials(e,t,n)}getSigv4aSigner(){if(!this.sigv4aSigner){let e=Bq.CrtSignerV4,t=ve.SignatureV4a;if(this.signerOptions.runtime===`node`){if(!e&&!t)throw Error(`Neither CRT nor JS SigV4a implementation is available. Please load either @aws-sdk/signature-v4-crt or @aws-sdk/signature-v4a. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`);if(e&&typeof e==`function`)this.sigv4aSigner=new e({...this.signerOptions,signingAlgorithm:1});else if(t&&typeof t==`function`)this.sigv4aSigner=new t({...this.signerOptions});else throw Error(`Available SigV4a implementation is not a valid constructor. Please ensure you've properly imported @aws-sdk/signature-v4-crt or @aws-sdk/signature-v4a.For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}else{if(!t||typeof t!=`function`)throw Error(`JS SigV4a implementation is not available or not a valid constructor. Please check whether you have installed the @aws-sdk/signature-v4a package explicitly. The CRT implementation is not available for browsers. You must also register the package by calling [require('@aws-sdk/signature-v4a');] or an ESM equivalent such as [import '@aws-sdk/signature-v4a';]. For more information please go to https://github.com/aws/aws-sdk-js-v3#using-javascript-non-crt-implementation-of-sigv4a`);this.sigv4aSigner=new t({...this.signerOptions})}}return this.sigv4aSigner}},Hq=`required`,O=`type`,k=`rules`,A=`conditions`,j=`fn`,M=`argv`,N=`ref`,P=`assign`,F=`url`,I=`properties`,Uq=`backend`,Wq=`authSchemes`,Gq=`disableDoubleEncoding`,Kq=`signingName`,qq=`signingRegion`,L=`headers`,Jq=`signingRegionSet`,Yq=6,Xq=!1,Zq=!0,Qq=`isSet`,$q=`booleanEquals`,R=`error`,eJ=`aws.partition`,z=`stringEquals`,tJ=`getAttr`,nJ=`name`,B=`substring`,rJ=`bucketSuffix`,iJ=`parseURL`,V=`endpoint`,H=`tree`,aJ=`aws.isVirtualHostableS3Bucket`,oJ=`{url#scheme}://{Bucket}.{url#authority}{url#path}`,sJ=`not`,cJ=`accessPointSuffix`,lJ=`{url#scheme}://{url#authority}{url#path}`,uJ=`hardwareType`,dJ=`regionPrefix`,fJ=`bucketAliasSuffix`,pJ=`outpostId`,mJ=`isValidHostLabel`,hJ=`sigv4a`,gJ=`s3-outposts`,_J=`s3`,vJ=`{url#scheme}://{url#authority}{url#normalizedPath}{Bucket}`,yJ=`https://{Bucket}.s3-accelerate.{partitionResult#dnsSuffix}`,bJ=`https://{Bucket}.s3.{partitionResult#dnsSuffix}`,xJ=`aws.parseArn`,SJ=`bucketArn`,CJ=`arnType`,wJ=``,TJ=`s3-object-lambda`,EJ=`accesspoint`,DJ=`accessPointName`,OJ=`{url#scheme}://{accessPointName}-{bucketArn#accountId}.{url#authority}{url#path}`,kJ=`mrapPartition`,AJ=`outpostType`,jJ=`arnPrefix`,MJ=`{url#scheme}://{url#authority}{url#normalizedPath}{uri_encoded_bucket}`,NJ=`https://s3.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,PJ=`https://s3.{partitionResult#dnsSuffix}`,FJ={[Hq]:!1,[O]:`string`},IJ={[Hq]:!0,default:!1,[O]:`boolean`},LJ={[Hq]:!1,[O]:`boolean`},RJ={[j]:$q,[M]:[{[N]:`Accelerate`},!0]},U={[j]:$q,[M]:[{[N]:`UseFIPS`},!0]},W={[j]:$q,[M]:[{[N]:`UseDualStack`},!0]},zJ={[j]:Qq,[M]:[{[N]:`Endpoint`}]},BJ={[j]:eJ,[M]:[{[N]:`Region`}],[P]:`partitionResult`},VJ={[j]:z,[M]:[{[j]:tJ,[M]:[{[N]:`partitionResult`},nJ]},`aws-cn`]},HJ={[j]:Qq,[M]:[{[N]:`Bucket`}]},G={[N]:`Bucket`},UJ={[A]:[RJ],[R]:`S3Express does not support S3 Accelerate.`,[O]:R},WJ={[A]:[zJ,{[j]:iJ,[M]:[{[N]:`Endpoint`}],[P]:`url`}],[k]:[{[A]:[{[j]:Qq,[M]:[{[N]:`DisableS3ExpressSessionAuth`}]},{[j]:$q,[M]:[{[N]:`DisableS3ExpressSessionAuth`},!0]}],[k]:[{[A]:[{[j]:$q,[M]:[{[j]:tJ,[M]:[{[N]:`url`},`isIp`]},!0]}],[k]:[{[A]:[{[j]:`uriEncode`,[M]:[G],[P]:`uri_encoded_bucket`}],[k]:[{[V]:{[F]:`{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],[O]:H}],[O]:H},{[A]:[{[j]:aJ,[M]:[G,!1]}],[k]:[{[V]:{[F]:oJ,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],[O]:H},{[R]:`S3Express bucket name is not a valid virtual hostable name.`,[O]:R}],[O]:H},{[A]:[{[j]:$q,[M]:[{[j]:tJ,[M]:[{[N]:`url`},`isIp`]},!0]}],[k]:[{[A]:[{[j]:`uriEncode`,[M]:[G],[P]:`uri_encoded_bucket`}],[k]:[{[V]:{[F]:`{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],[O]:H}],[O]:H},{[A]:[{[j]:aJ,[M]:[G,!1]}],[k]:[{[V]:{[F]:oJ,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],[O]:H},{[R]:`S3Express bucket name is not a valid virtual hostable name.`,[O]:R}],[O]:H},GJ={[j]:iJ,[M]:[{[N]:`Endpoint`}],[P]:`url`},KJ={[j]:$q,[M]:[{[j]:tJ,[M]:[{[N]:`url`},`isIp`]},!0]},qJ={[N]:`url`},JJ={[j]:`uriEncode`,[M]:[G],[P]:`uri_encoded_bucket`},YJ={[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:`s3express`,[qq]:`{Region}`}]},K={},XJ={[j]:aJ,[M]:[G,!1]},ZJ={[R]:`S3Express bucket name is not a valid virtual hostable name.`,[O]:R},QJ={[j]:Qq,[M]:[{[N]:`UseS3ExpressControlEndpoint`}]},$J={[j]:$q,[M]:[{[N]:`UseS3ExpressControlEndpoint`},!0]},q={[j]:sJ,[M]:[zJ]},J={[j]:$q,[M]:[{[N]:`UseDualStack`},!1]},Y={[j]:$q,[M]:[{[N]:`UseFIPS`},!1]},eY={[R]:`Unrecognized S3Express bucket name format.`,[O]:R},tY={[j]:sJ,[M]:[HJ]},nY={[N]:uJ},rY={[A]:[q],[R]:`Expected a endpoint to be specified but no endpoint was found`,[O]:R},iY={[Wq]:[{[Gq]:!0,[nJ]:hJ,[Kq]:gJ,[Jq]:[`*`]},{[Gq]:!0,[nJ]:`sigv4`,[Kq]:gJ,[qq]:`{Region}`}]},aY={[j]:$q,[M]:[{[N]:`ForcePathStyle`},!1]},oY={[N]:`ForcePathStyle`},sY={[j]:$q,[M]:[{[N]:`Accelerate`},!1]},cY={[j]:z,[M]:[{[N]:`Region`},`aws-global`]},lY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:_J,[qq]:`us-east-1`}]},X={[j]:sJ,[M]:[cY]},uY={[j]:$q,[M]:[{[N]:`UseGlobalEndpoint`},!0]},dY={[F]:`https://{Bucket}.s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:_J,[qq]:`{Region}`}]},[L]:{}},fY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:_J,[qq]:`{Region}`}]},pY={[j]:$q,[M]:[{[N]:`UseGlobalEndpoint`},!1]},mY={[F]:`https://{Bucket}.s3-fips.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},hY={[F]:`https://{Bucket}.s3-accelerate.dualstack.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},gY={[F]:`https://{Bucket}.s3.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},_Y={[j]:$q,[M]:[{[j]:tJ,[M]:[qJ,`isIp`]},!1]},vY={[F]:vJ,[I]:fY,[L]:{}},yY={[F]:oJ,[I]:fY,[L]:{}},bY={[V]:yY,[O]:V},xY={[F]:yJ,[I]:fY,[L]:{}},SY={[F]:`https://{Bucket}.s3.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},CY={[R]:`Invalid region: region was not a valid DNS name.`,[O]:R},wY={[N]:SJ},TY={[N]:CJ},EY={[j]:tJ,[M]:[wY,`service`]},DY={[N]:DJ},OY={[A]:[W],[R]:`S3 Object Lambda does not support Dual-stack`,[O]:R},kY={[A]:[RJ],[R]:`S3 Object Lambda does not support S3 Accelerate`,[O]:R},AY={[A]:[{[j]:Qq,[M]:[{[N]:`DisableAccessPoints`}]},{[j]:$q,[M]:[{[N]:`DisableAccessPoints`},!0]}],[R]:`Access points are not supported for this operation`,[O]:R},jY={[A]:[{[j]:Qq,[M]:[{[N]:`UseArnRegion`}]},{[j]:$q,[M]:[{[N]:`UseArnRegion`},!1]},{[j]:sJ,[M]:[{[j]:z,[M]:[{[j]:tJ,[M]:[wY,`region`]},`{Region}`]}]}],[R]:"Invalid configuration: region from ARN `{bucketArn#region}` does not match client region `{Region}` and UseArnRegion is `false`",[O]:R},MY={[j]:tJ,[M]:[{[N]:`bucketPartition`},nJ]},NY={[j]:tJ,[M]:[wY,`accountId`]},PY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:TJ,[qq]:`{bucketArn#region}`}]},FY={[R]:"Invalid ARN: The access point name may only contain a-z, A-Z, 0-9 and `-`. Found: `{accessPointName}`",[O]:R},IY={[R]:"Invalid ARN: The account id may only contain a-z, A-Z, 0-9 and `-`. Found: `{bucketArn#accountId}`",[O]:R},LY={[R]:"Invalid region in ARN: `{bucketArn#region}` (invalid DNS name)",[O]:R},RY={[R]:"Client was configured for partition `{partitionResult#name}` but ARN (`{Bucket}`) has `{bucketPartition#name}`",[O]:R},zY={[R]:"Invalid ARN: The ARN may only contain a single resource component after `accesspoint`.",[O]:R},BY={[R]:"Invalid ARN: Expected a resource of the format `accesspoint:` but no name was provided",[O]:R},VY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:_J,[qq]:`{bucketArn#region}`}]},HY={[Wq]:[{[Gq]:!0,[nJ]:hJ,[Kq]:gJ,[Jq]:[`*`]},{[Gq]:!0,[nJ]:`sigv4`,[Kq]:gJ,[qq]:`{bucketArn#region}`}]},UY={[j]:xJ,[M]:[G]},WY={[F]:`https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:fY,[L]:{}},GY={[F]:`https://s3-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:fY,[L]:{}},KY={[F]:`https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:fY,[L]:{}},qY={[F]:MJ,[I]:fY,[L]:{}},JY={[F]:`https://s3.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:fY,[L]:{}},YY={[N]:`UseObjectLambdaEndpoint`},XY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:TJ,[qq]:`{Region}`}]},ZY={[F]:`https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},QY={[F]:`https://s3-fips.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},$Y={[F]:`https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},eX={[F]:lJ,[I]:fY,[L]:{}},tX={[F]:`https://s3.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},nX=[{[N]:`Region`}],rX=[{[N]:`Endpoint`}],iX=[G],aX=[RJ],oX=[zJ,GJ],sX=[{[j]:Qq,[M]:[{[N]:`DisableS3ExpressSessionAuth`}]},{[j]:$q,[M]:[{[N]:`DisableS3ExpressSessionAuth`},!0]}],cX=[JJ],lX=[XJ],uX=[BJ],dX=[U,W],fX=[U,J],pX=[Y,W],mX=[Y,J],hX=[{[j]:B,[M]:[G,6,14,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,14,16,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],gX=[{[A]:[U,W],[V]:{[F]:`https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:{}},[O]:V},{[A]:fX,[V]:{[F]:`https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:{}},[O]:V},{[A]:pX,[V]:{[F]:`https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:{}},[O]:V},{[A]:mX,[V]:{[F]:`https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:{}},[O]:V}],_X=[{[j]:B,[M]:[G,6,15,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,15,17,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],vX=[{[j]:B,[M]:[G,6,19,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,19,21,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],yX=[{[j]:B,[M]:[G,6,20,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,20,22,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],bX=[{[j]:B,[M]:[G,6,26,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,26,28,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],xX=[{[A]:[U,W],[V]:{[F]:`https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V},{[A]:fX,[V]:{[F]:`https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V},{[A]:pX,[V]:{[F]:`https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V},{[A]:mX,[V]:{[F]:`https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],SX=[G,0,7,!0],CX=[{[j]:B,[M]:[G,7,15,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,15,17,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],wX=[{[j]:B,[M]:[G,7,16,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,16,18,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],TX=[{[j]:B,[M]:[G,7,20,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,20,22,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],EX=[{[j]:B,[M]:[G,7,21,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,21,23,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],DX=[{[j]:B,[M]:[G,7,27,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,27,29,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],OX=[HJ],kX=[{[j]:mJ,[M]:[{[N]:pJ},!1]}],AX=[{[j]:z,[M]:[{[N]:dJ},`beta`]}],jX=[`*`],MX=[{[j]:mJ,[M]:[{[N]:`Region`},!1]}],NX=[{[j]:z,[M]:[{[N]:`Region`},`us-east-1`]}],PX=[{[j]:z,[M]:[TY,EJ]}],FX=[{[j]:tJ,[M]:[wY,`resourceId[1]`],[P]:DJ},{[j]:sJ,[M]:[{[j]:z,[M]:[DY,wJ]}]}],IX=[wY,`resourceId[1]`],LX=[W],RX=[{[j]:sJ,[M]:[{[j]:z,[M]:[{[j]:tJ,[M]:[wY,`region`]},wJ]}]}],zX=[{[j]:sJ,[M]:[{[j]:Qq,[M]:[{[j]:tJ,[M]:[wY,`resourceId[2]`]}]}]}],BX=[wY,`resourceId[2]`],VX=[{[j]:eJ,[M]:[{[j]:tJ,[M]:[wY,`region`]}],[P]:`bucketPartition`}],HX=[{[j]:z,[M]:[MY,{[j]:tJ,[M]:[{[N]:`partitionResult`},nJ]}]}],UX=[{[j]:mJ,[M]:[{[j]:tJ,[M]:[wY,`region`]},!0]}],WX=[{[j]:mJ,[M]:[NY,!1]}],GX=[{[j]:mJ,[M]:[DY,!1]}],KX=[U],qX=[{[j]:mJ,[M]:[{[N]:`Region`},!0]}],JX={version:`1.0`,parameters:{Bucket:FJ,Region:FJ,UseFIPS:IJ,UseDualStack:IJ,Endpoint:FJ,ForcePathStyle:IJ,Accelerate:IJ,UseGlobalEndpoint:IJ,UseObjectLambdaEndpoint:LJ,Key:FJ,Prefix:FJ,CopySource:FJ,DisableAccessPoints:LJ,DisableMultiRegionAccessPoints:IJ,UseArnRegion:LJ,UseS3ExpressControlEndpoint:LJ,DisableS3ExpressSessionAuth:LJ},[k]:[{[A]:[{[j]:Qq,[M]:nX}],[k]:[{[A]:[RJ,U],error:`Accelerate cannot be used with FIPS`,[O]:R},{[A]:[W,zJ],error:`Cannot set dual-stack in combination with a custom endpoint.`,[O]:R},{[A]:[zJ,U],error:`A custom endpoint cannot be combined with FIPS`,[O]:R},{[A]:[zJ,RJ],error:`A custom endpoint cannot be combined with S3 Accelerate`,[O]:R},{[A]:[U,BJ,VJ],error:`Partition does not support FIPS`,[O]:R},{[A]:[HJ,{[j]:B,[M]:[G,0,Yq,Zq],[P]:rJ},{[j]:z,[M]:[{[N]:rJ},`--x-s3`]}],[k]:[UJ,WJ,{[A]:[QJ,$J],[k]:[{[A]:uX,[k]:[{[A]:[JJ,q],[k]:[{[A]:dX,endpoint:{[F]:`https://s3express-control-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:YJ,[L]:K},[O]:V},{[A]:fX,endpoint:{[F]:`https://s3express-control-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:YJ,[L]:K},[O]:V},{[A]:pX,endpoint:{[F]:`https://s3express-control.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:YJ,[L]:K},[O]:V},{[A]:mX,endpoint:{[F]:`https://s3express-control.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:YJ,[L]:K},[O]:V}],[O]:H}],[O]:H}],[O]:H},{[A]:lX,[k]:[{[A]:uX,[k]:[{[A]:sX,[k]:[{[A]:hX,[k]:gX,[O]:H},{[A]:_X,[k]:gX,[O]:H},{[A]:vX,[k]:gX,[O]:H},{[A]:yX,[k]:gX,[O]:H},{[A]:bX,[k]:gX,[O]:H},eY],[O]:H},{[A]:hX,[k]:xX,[O]:H},{[A]:_X,[k]:xX,[O]:H},{[A]:vX,[k]:xX,[O]:H},{[A]:yX,[k]:xX,[O]:H},{[A]:bX,[k]:xX,[O]:H},eY],[O]:H}],[O]:H},ZJ],[O]:H},{[A]:[HJ,{[j]:B,[M]:SX,[P]:cJ},{[j]:z,[M]:[{[N]:cJ},`--xa-s3`]}],[k]:[UJ,WJ,{[A]:lX,[k]:[{[A]:uX,[k]:[{[A]:sX,[k]:[{[A]:CX,[k]:gX,[O]:H},{[A]:wX,[k]:gX,[O]:H},{[A]:TX,[k]:gX,[O]:H},{[A]:EX,[k]:gX,[O]:H},{[A]:DX,[k]:gX,[O]:H},eY],[O]:H},{[A]:CX,[k]:xX,[O]:H},{[A]:wX,[k]:xX,[O]:H},{[A]:TX,[k]:xX,[O]:H},{[A]:EX,[k]:xX,[O]:H},{[A]:DX,[k]:xX,[O]:H},eY],[O]:H}],[O]:H},ZJ],[O]:H},{[A]:[tY,QJ,$J],[k]:[{[A]:uX,[k]:[{[A]:oX,endpoint:{[F]:lJ,[I]:YJ,[L]:K},[O]:V},{[A]:dX,endpoint:{[F]:`https://s3express-control-fips.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:K},[O]:V},{[A]:fX,endpoint:{[F]:`https://s3express-control-fips.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:K},[O]:V},{[A]:pX,endpoint:{[F]:`https://s3express-control.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:K},[O]:V},{[A]:mX,endpoint:{[F]:`https://s3express-control.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:K},[O]:V}],[O]:H}],[O]:H},{[A]:[HJ,{[j]:B,[M]:[G,49,50,Zq],[P]:uJ},{[j]:B,[M]:[G,8,12,Zq],[P]:dJ},{[j]:B,[M]:SX,[P]:fJ},{[j]:B,[M]:[G,32,49,Zq],[P]:pJ},{[j]:eJ,[M]:nX,[P]:`regionPartition`},{[j]:z,[M]:[{[N]:fJ},`--op-s3`]}],[k]:[{[A]:kX,[k]:[{[A]:lX,[k]:[{[A]:[{[j]:z,[M]:[nY,`e`]}],[k]:[{[A]:AX,[k]:[rY,{[A]:oX,endpoint:{[F]:`https://{Bucket}.ec2.{url#authority}`,[I]:iY,[L]:K},[O]:V}],[O]:H},{endpoint:{[F]:`https://{Bucket}.ec2.s3-outposts.{Region}.{regionPartition#dnsSuffix}`,[I]:iY,[L]:K},[O]:V}],[O]:H},{[A]:[{[j]:z,[M]:[nY,`o`]}],[k]:[{[A]:AX,[k]:[rY,{[A]:oX,endpoint:{[F]:`https://{Bucket}.op-{outpostId}.{url#authority}`,[I]:iY,[L]:K},[O]:V}],[O]:H},{endpoint:{[F]:`https://{Bucket}.op-{outpostId}.s3-outposts.{Region}.{regionPartition#dnsSuffix}`,[I]:iY,[L]:K},[O]:V}],[O]:H},{error:`Unrecognized hardware type: "Expected hardware type o or e but got {hardwareType}"`,[O]:R}],[O]:H},{error:`Invalid Outposts Bucket alias - it must be a valid bucket name.`,[O]:R}],[O]:H},{error:"Invalid ARN: The outpost Id must only contain a-z, A-Z, 0-9 and `-`.",[O]:R}],[O]:H},{[A]:OX,[k]:[{[A]:[zJ,{[j]:sJ,[M]:[{[j]:Qq,[M]:[{[j]:iJ,[M]:rX}]}]}],error:"Custom endpoint `{Endpoint}` was not a valid URI",[O]:R},{[A]:[aY,XJ],[k]:[{[A]:uX,[k]:[{[A]:MX,[k]:[{[A]:[RJ,VJ],error:`S3 Accelerate cannot be used in this region`,[O]:R},{[A]:[W,U,sY,q,cY],endpoint:{[F]:`https://{Bucket}.s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,U,sY,q,X,uY],[k]:[{endpoint:dY,[O]:V}],[O]:H},{[A]:[W,U,sY,q,X,pY],endpoint:dY,[O]:V},{[A]:[J,U,sY,q,cY],endpoint:{[F]:`https://{Bucket}.s3-fips.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[J,U,sY,q,X,uY],[k]:[{endpoint:mY,[O]:V}],[O]:H},{[A]:[J,U,sY,q,X,pY],endpoint:mY,[O]:V},{[A]:[W,Y,RJ,q,cY],endpoint:{[F]:`https://{Bucket}.s3-accelerate.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,Y,RJ,q,X,uY],[k]:[{endpoint:hY,[O]:V}],[O]:H},{[A]:[W,Y,RJ,q,X,pY],endpoint:hY,[O]:V},{[A]:[W,Y,sY,q,cY],endpoint:{[F]:`https://{Bucket}.s3.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,Y,sY,q,X,uY],[k]:[{endpoint:gY,[O]:V}],[O]:H},{[A]:[W,Y,sY,q,X,pY],endpoint:gY,[O]:V},{[A]:[J,Y,sY,zJ,GJ,KJ,cY],endpoint:{[F]:vJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,Y,sY,zJ,GJ,_Y,cY],endpoint:{[F]:oJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,Y,sY,zJ,GJ,KJ,X,uY],[k]:[{[A]:NX,endpoint:vY,[O]:V},{endpoint:vY,[O]:V}],[O]:H},{[A]:[J,Y,sY,zJ,GJ,_Y,X,uY],[k]:[{[A]:NX,endpoint:yY,[O]:V},bY],[O]:H},{[A]:[J,Y,sY,zJ,GJ,KJ,X,pY],endpoint:vY,[O]:V},{[A]:[J,Y,sY,zJ,GJ,_Y,X,pY],endpoint:yY,[O]:V},{[A]:[J,Y,RJ,q,cY],endpoint:{[F]:yJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,Y,RJ,q,X,uY],[k]:[{[A]:NX,endpoint:xY,[O]:V},{endpoint:xY,[O]:V}],[O]:H},{[A]:[J,Y,RJ,q,X,pY],endpoint:xY,[O]:V},{[A]:[J,Y,sY,q,cY],endpoint:{[F]:bJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,Y,sY,q,X,uY],[k]:[{[A]:NX,endpoint:{[F]:bJ,[I]:fY,[L]:K},[O]:V},{endpoint:SY,[O]:V}],[O]:H},{[A]:[J,Y,sY,q,X,pY],endpoint:SY,[O]:V}],[O]:H},CY],[O]:H}],[O]:H},{[A]:[zJ,GJ,{[j]:z,[M]:[{[j]:tJ,[M]:[qJ,`scheme`]},`http`]},{[j]:aJ,[M]:[G,Zq]},aY,Y,J,sY],[k]:[{[A]:uX,[k]:[{[A]:MX,[k]:[bY],[O]:H},CY],[O]:H}],[O]:H},{[A]:[aY,{[j]:xJ,[M]:iX,[P]:SJ}],[k]:[{[A]:[{[j]:tJ,[M]:[wY,`resourceId[0]`],[P]:CJ},{[j]:sJ,[M]:[{[j]:z,[M]:[TY,wJ]}]}],[k]:[{[A]:[{[j]:z,[M]:[EY,TJ]}],[k]:[{[A]:PX,[k]:[{[A]:FX,[k]:[OY,kY,{[A]:RX,[k]:[AY,{[A]:zX,[k]:[jY,{[A]:VX,[k]:[{[A]:uX,[k]:[{[A]:HX,[k]:[{[A]:UX,[k]:[{[A]:[{[j]:z,[M]:[NY,wJ]}],error:`Invalid ARN: Missing account id`,[O]:R},{[A]:WX,[k]:[{[A]:GX,[k]:[{[A]:oX,endpoint:{[F]:OJ,[I]:PY,[L]:K},[O]:V},{[A]:KX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:PY,[L]:K},[O]:V},{endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:PY,[L]:K},[O]:V}],[O]:H},FY],[O]:H},IY],[O]:H},LY],[O]:H},RY],[O]:H}],[O]:H}],[O]:H},zY],[O]:H},{error:`Invalid ARN: bucket ARN is missing a region`,[O]:R}],[O]:H},BY],[O]:H},{error:"Invalid ARN: Object Lambda ARNs only support `accesspoint` arn types, but found: `{arnType}`",[O]:R}],[O]:H},{[A]:PX,[k]:[{[A]:FX,[k]:[{[A]:RX,[k]:[{[A]:PX,[k]:[{[A]:RX,[k]:[AY,{[A]:zX,[k]:[jY,{[A]:VX,[k]:[{[A]:uX,[k]:[{[A]:[{[j]:z,[M]:[MY,`{partitionResult#name}`]}],[k]:[{[A]:UX,[k]:[{[A]:[{[j]:z,[M]:[EY,_J]}],[k]:[{[A]:WX,[k]:[{[A]:GX,[k]:[{[A]:aX,error:`Access Points do not support S3 Accelerate`,[O]:R},{[A]:dX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:VY,[L]:K},[O]:V},{[A]:fX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:VY,[L]:K},[O]:V},{[A]:pX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:VY,[L]:K},[O]:V},{[A]:[Y,J,zJ,GJ],endpoint:{[F]:OJ,[I]:VY,[L]:K},[O]:V},{[A]:mX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:VY,[L]:K},[O]:V}],[O]:H},FY],[O]:H},IY],[O]:H},{error:`Invalid ARN: The ARN was not for the S3 service, found: {bucketArn#service}`,[O]:R}],[O]:H},LY],[O]:H},RY],[O]:H}],[O]:H}],[O]:H},zY],[O]:H}],[O]:H}],[O]:H},{[A]:[{[j]:mJ,[M]:[DY,Zq]}],[k]:[{[A]:LX,error:`S3 MRAP does not support dual-stack`,[O]:R},{[A]:KX,error:`S3 MRAP does not support FIPS`,[O]:R},{[A]:aX,error:`S3 MRAP does not support S3 Accelerate`,[O]:R},{[A]:[{[j]:$q,[M]:[{[N]:`DisableMultiRegionAccessPoints`},Zq]}],error:`Invalid configuration: Multi-Region Access Point ARNs are disabled.`,[O]:R},{[A]:[{[j]:eJ,[M]:nX,[P]:kJ}],[k]:[{[A]:[{[j]:z,[M]:[{[j]:tJ,[M]:[{[N]:kJ},nJ]},{[j]:tJ,[M]:[wY,`partition`]}]}],[k]:[{endpoint:{[F]:`https://{accessPointName}.accesspoint.s3-global.{mrapPartition#dnsSuffix}`,[I]:{[Wq]:[{[Gq]:Zq,name:hJ,[Kq]:_J,[Jq]:jX}]},[L]:K},[O]:V}],[O]:H},{error:"Client was configured for partition `{mrapPartition#name}` but bucket referred to partition `{bucketArn#partition}`",[O]:R}],[O]:H}],[O]:H},{error:`Invalid Access Point Name`,[O]:R}],[O]:H},BY],[O]:H},{[A]:[{[j]:z,[M]:[EY,gJ]}],[k]:[{[A]:LX,error:`S3 Outposts does not support Dual-stack`,[O]:R},{[A]:KX,error:`S3 Outposts does not support FIPS`,[O]:R},{[A]:aX,error:`S3 Outposts does not support S3 Accelerate`,[O]:R},{[A]:[{[j]:Qq,[M]:[{[j]:tJ,[M]:[wY,`resourceId[4]`]}]}],error:`Invalid Arn: Outpost Access Point ARN contains sub resources`,[O]:R},{[A]:[{[j]:tJ,[M]:IX,[P]:pJ}],[k]:[{[A]:kX,[k]:[jY,{[A]:VX,[k]:[{[A]:uX,[k]:[{[A]:HX,[k]:[{[A]:UX,[k]:[{[A]:WX,[k]:[{[A]:[{[j]:tJ,[M]:BX,[P]:AJ}],[k]:[{[A]:[{[j]:tJ,[M]:[wY,`resourceId[3]`],[P]:DJ}],[k]:[{[A]:[{[j]:z,[M]:[{[N]:AJ},EJ]}],[k]:[{[A]:oX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.{outpostId}.{url#authority}`,[I]:HY,[L]:K},[O]:V},{endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.{outpostId}.s3-outposts.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:HY,[L]:K},[O]:V}],[O]:H},{error:"Expected an outpost type `accesspoint`, found {outpostType}",[O]:R}],[O]:H},{error:`Invalid ARN: expected an access point name`,[O]:R}],[O]:H},{error:`Invalid ARN: Expected a 4-component resource`,[O]:R}],[O]:H},IY],[O]:H},LY],[O]:H},RY],[O]:H}],[O]:H}],[O]:H},{error:"Invalid ARN: The outpost Id may only contain a-z, A-Z, 0-9 and `-`. Found: `{outpostId}`",[O]:R}],[O]:H},{error:`Invalid ARN: The Outpost Id was not set`,[O]:R}],[O]:H},{error:`Invalid ARN: Unrecognized format: {Bucket} (type: {arnType})`,[O]:R}],[O]:H},{error:`Invalid ARN: No ARN type specified`,[O]:R}],[O]:H},{[A]:[{[j]:B,[M]:[G,0,4,Xq],[P]:jJ},{[j]:z,[M]:[{[N]:jJ},`arn:`]},{[j]:sJ,[M]:[{[j]:Qq,[M]:[UY]}]}],error:"Invalid ARN: `{Bucket}` was not a valid ARN",[O]:R},{[A]:[{[j]:$q,[M]:[oY,Zq]},UY],error:`Path-style addressing cannot be used with ARN buckets`,[O]:R},{[A]:cX,[k]:[{[A]:uX,[k]:[{[A]:[sY],[k]:[{[A]:[W,q,U,cY],endpoint:{[F]:`https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,q,U,X,uY],[k]:[{endpoint:WY,[O]:V}],[O]:H},{[A]:[W,q,U,X,pY],endpoint:WY,[O]:V},{[A]:[J,q,U,cY],endpoint:{[F]:`https://s3-fips.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:lY,[L]:K},[O]:V},{[A]:[J,q,U,X,uY],[k]:[{endpoint:GY,[O]:V}],[O]:H},{[A]:[J,q,U,X,pY],endpoint:GY,[O]:V},{[A]:[W,q,Y,cY],endpoint:{[F]:`https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,q,Y,X,uY],[k]:[{endpoint:KY,[O]:V}],[O]:H},{[A]:[W,q,Y,X,pY],endpoint:KY,[O]:V},{[A]:[J,zJ,GJ,Y,cY],endpoint:{[F]:MJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,zJ,GJ,Y,X,uY],[k]:[{[A]:NX,endpoint:qY,[O]:V},{endpoint:qY,[O]:V}],[O]:H},{[A]:[J,zJ,GJ,Y,X,pY],endpoint:qY,[O]:V},{[A]:[J,q,Y,cY],endpoint:{[F]:NJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,q,Y,X,uY],[k]:[{[A]:NX,endpoint:{[F]:NJ,[I]:fY,[L]:K},[O]:V},{endpoint:JY,[O]:V}],[O]:H},{[A]:[J,q,Y,X,pY],endpoint:JY,[O]:V}],[O]:H},{error:`Path-style addressing cannot be used with S3 Accelerate`,[O]:R}],[O]:H}],[O]:H}],[O]:H},{[A]:[{[j]:Qq,[M]:[YY]},{[j]:$q,[M]:[YY,Zq]}],[k]:[{[A]:uX,[k]:[{[A]:qX,[k]:[OY,kY,{[A]:oX,endpoint:{[F]:lJ,[I]:XY,[L]:K},[O]:V},{[A]:KX,endpoint:{[F]:`https://s3-object-lambda-fips.{Region}.{partitionResult#dnsSuffix}`,[I]:XY,[L]:K},[O]:V},{endpoint:{[F]:`https://s3-object-lambda.{Region}.{partitionResult#dnsSuffix}`,[I]:XY,[L]:K},[O]:V}],[O]:H},CY],[O]:H}],[O]:H},{[A]:[tY],[k]:[{[A]:uX,[k]:[{[A]:qX,[k]:[{[A]:[U,W,q,cY],endpoint:{[F]:`https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[U,W,q,X,uY],[k]:[{endpoint:ZY,[O]:V}],[O]:H},{[A]:[U,W,q,X,pY],endpoint:ZY,[O]:V},{[A]:[U,J,q,cY],endpoint:{[F]:`https://s3-fips.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[U,J,q,X,uY],[k]:[{endpoint:QY,[O]:V}],[O]:H},{[A]:[U,J,q,X,pY],endpoint:QY,[O]:V},{[A]:[Y,W,q,cY],endpoint:{[F]:`https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[Y,W,q,X,uY],[k]:[{endpoint:$Y,[O]:V}],[O]:H},{[A]:[Y,W,q,X,pY],endpoint:$Y,[O]:V},{[A]:[Y,J,zJ,GJ,cY],endpoint:{[F]:lJ,[I]:lY,[L]:K},[O]:V},{[A]:[Y,J,zJ,GJ,X,uY],[k]:[{[A]:NX,endpoint:eX,[O]:V},{endpoint:eX,[O]:V}],[O]:H},{[A]:[Y,J,zJ,GJ,X,pY],endpoint:eX,[O]:V},{[A]:[Y,J,q,cY],endpoint:{[F]:PJ,[I]:lY,[L]:K},[O]:V},{[A]:[Y,J,q,X,uY],[k]:[{[A]:NX,endpoint:{[F]:PJ,[I]:fY,[L]:K},[O]:V},{endpoint:tX,[O]:V}],[O]:H},{[A]:[Y,J,q,X,pY],endpoint:tX,[O]:V}],[O]:H},CY],[O]:H}],[O]:H}],[O]:H},{error:`A region must be set when sending requests to S3.`,[O]:R}]},YX=new er({size:50,params:[`Accelerate`,`Bucket`,`DisableAccessPoints`,`DisableMultiRegionAccessPoints`,`DisableS3ExpressSessionAuth`,`Endpoint`,`ForcePathStyle`,`Region`,`UseArnRegion`,`UseDualStack`,`UseFIPS`,`UseGlobalEndpoint`,`UseObjectLambdaEndpoint`,`UseS3ExpressControlEndpoint`]}),XX=(e,t={})=>YX.get(e,()=>Mr(JX,{endpointParams:e,logger:t.logger}));ar.aws=Vr;var ZX=(e=>async(t,n,r)=>{if(!r)throw Error("Could not find `input` for `defaultEndpointRuleSetHttpAuthSchemeParametersProvider`");let i=await e(t,n,r),a=_e(n)?.commandInstance?.constructor?.getEndpointParameterInstructions;if(!a)throw Error(`getEndpointParameterInstructions() is not defined on '${n.commandName}'`);let o=await Ka(r,{getEndpointParameterInstructions:a},t);return Object.assign(i,o)})(async(e,t,n)=>({operation:_e(t).operation,region:await f(e.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()}));function QX(e){return{schemeId:`aws.auth#sigv4`,signingProperties:{name:`s3`,region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}function $X(e){return{schemeId:`aws.auth#sigv4a`,signingProperties:{name:`s3`,region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}var eZ=((e,t,n)=>r=>{let i=e(r).properties?.authSchemes;if(!i)return t(r);let a=[];for(let e of i){let{name:t,properties:o={},...s}=e,c=t.toLowerCase();t!==c&&console.warn(`HttpAuthScheme has been normalized with lowercasing: '${t}' to '${c}'`);let l;if(c===`sigv4a`){l=`aws.auth#sigv4a`;let e=i.find(e=>{let t=e.name.toLowerCase();return t!==`sigv4a`&&t.startsWith(`sigv4`)});if(Vq.sigv4aDependency()===`none`&&e)continue}else if(c.startsWith(`sigv4`))l=`aws.auth#sigv4`;else throw Error(`Unknown HttpAuthScheme found in '@smithy.rules#endpointRuleSet': '${c}'`);let u=n[l];if(!u)throw Error(`Could not find HttpAuthOption create function for '${l}'`);let d=u(r);d.schemeId=l,d.signingProperties={...d.signingProperties||{},...s,...o},a.push(d)}return a})(XX,e=>{let t=[];switch(e.operation){default:t.push(QX(e)),t.push($X(e))}return t},{"aws.auth#sigv4":QX,"aws.auth#sigv4a":$X}),tZ=e=>{let t=$r(ei(e));return Object.assign(t,{authSchemePreference:f(e.authSchemePreference??[])})},nZ=e=>Object.assign(e,{useFipsEndpoint:e.useFipsEndpoint??!1,useDualstackEndpoint:e.useDualstackEndpoint??!1,forcePathStyle:e.forcePathStyle??!1,useAccelerateEndpoint:e.useAccelerateEndpoint??!1,useGlobalEndpoint:e.useGlobalEndpoint??!1,disableMultiregionAccessPoints:e.disableMultiregionAccessPoints??!1,defaultSigningName:`s3`,clientContextParams:e.clientContextParams??{}}),rZ={ForcePathStyle:{type:`clientContextParams`,name:`forcePathStyle`},UseArnRegion:{type:`clientContextParams`,name:`useArnRegion`},DisableMultiRegionAccessPoints:{type:`clientContextParams`,name:`disableMultiregionAccessPoints`},Accelerate:{type:`clientContextParams`,name:`useAccelerateEndpoint`},DisableS3ExpressSessionAuth:{type:`clientContextParams`,name:`disableS3ExpressSessionAuth`},UseGlobalEndpoint:{type:`builtInParams`,name:`useGlobalEndpoint`},UseFIPS:{type:`builtInParams`,name:`useFipsEndpoint`},Endpoint:{type:`builtInParams`,name:`endpoint`},Region:{type:`builtInParams`,name:`region`},UseDualStack:{type:`builtInParams`,name:`useDualstackEndpoint`}},iZ=class e extends hi{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}},aZ=class e extends iZ{name=`NoSuchUpload`;$fault=`client`;constructor(t){super({name:`NoSuchUpload`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},oZ=class e extends iZ{name=`AccessDenied`;$fault=`client`;constructor(t){super({name:`AccessDenied`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},sZ=class e extends iZ{name=`ObjectNotInActiveTierError`;$fault=`client`;constructor(t){super({name:`ObjectNotInActiveTierError`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},cZ=class e extends iZ{name=`BucketAlreadyExists`;$fault=`client`;constructor(t){super({name:`BucketAlreadyExists`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},lZ=class e extends iZ{name=`BucketAlreadyOwnedByYou`;$fault=`client`;constructor(t){super({name:`BucketAlreadyOwnedByYou`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},uZ=class e extends iZ{name=`NoSuchBucket`;$fault=`client`;constructor(t){super({name:`NoSuchBucket`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},dZ=class e extends iZ{name=`InvalidObjectState`;$fault=`client`;StorageClass;AccessTier;constructor(t){super({name:`InvalidObjectState`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.StorageClass=t.StorageClass,this.AccessTier=t.AccessTier}},fZ=class e extends iZ{name=`NoSuchKey`;$fault=`client`;constructor(t){super({name:`NoSuchKey`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},pZ=class e extends iZ{name=`NotFound`;$fault=`client`;constructor(t){super({name:`NotFound`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},mZ=class e extends iZ{name=`EncryptionTypeMismatch`;$fault=`client`;constructor(t){super({name:`EncryptionTypeMismatch`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},hZ=class e extends iZ{name=`InvalidRequest`;$fault=`client`;constructor(t){super({name:`InvalidRequest`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},gZ=class e extends iZ{name=`InvalidWriteOffset`;$fault=`client`;constructor(t){super({name:`InvalidWriteOffset`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},_Z=class e extends iZ{name=`TooManyParts`;$fault=`client`;constructor(t){super({name:`TooManyParts`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},vZ=class e extends iZ{name=`IdempotencyParameterMismatch`;$fault=`client`;constructor(t){super({name:`IdempotencyParameterMismatch`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},yZ=class e extends iZ{name=`ObjectAlreadyInActiveTierError`;$fault=`client`;constructor(t){super({name:`ObjectAlreadyInActiveTierError`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},bZ=`ACL`,xZ=`AccessDenied`,SZ=`AbortDate`,CZ=`AccessKeyId`,wZ=`AbortMultipartUpload`,TZ=`AbortMultipartUploadOutput`,EZ=`AbortMultipartUploadRequest`,DZ=`AcceptRanges`,OZ=`AbortRuleId`,kZ=`AccessTier`,AZ=`Bucket`,jZ=`BucketArn`,MZ=`BucketAlreadyExists`,NZ=`BucketAlreadyOwnedByYou`,PZ=`BypassGovernanceRetention`,FZ=`BucketInfo`,IZ=`BucketKeyEnabled`,LZ=`BucketNamespace`,RZ=`BucketRegion`,zZ=`Body`,BZ=`Buckets`,VZ=`ChecksumAlgorithm`,HZ=`CreateBucket`,UZ=`CreateBucketConfiguration`,WZ=`CreateBucketOutput`,GZ=`CreateBucketRequest`,KZ=`CacheControl`,qZ=`ChecksumCRC32`,JZ=`ChecksumCRC32C`,YZ=`ChecksumCRC64NVME`,XZ=`Cache-Control`,ZZ=`CreationDate`,QZ=`Content-Disposition`,$Z=`ContentDisposition`,eQ=`Content-Encoding`,tQ=`ContentEncoding`,nQ=`ContentLanguage`,rQ=`Content-Language`,iQ=`Content-Length`,aQ=`ContentLength`,oQ=`Content-MD5`,sQ=`ContentMD5`,cQ=`CompletedMultipartUpload`,lQ=`CompleteMultipartUploadOutput`,uQ=`CreateMultipartUploadOutput`,dQ=`CompleteMultipartUploadResult`,fQ=`CompleteMultipartUploadRequest`,pQ=`CreateMultipartUploadRequest`,mQ=`CompleteMultipartUpload`,hQ=`CreateMultipartUpload`,gQ=`ChecksumMode`,_Q=`CommonPrefix`,vQ=`CommonPrefixList`,yQ=`CompletedPartList`,bQ=`CompletedPart`,xQ=`CommonPrefixes`,SQ=`ContentRange`,CQ=`Content-Range`,wQ=`ChecksumSHA1`,TQ=`ChecksumSHA256`,EQ=`CreateSessionOutput`,DQ=`CreateSessionResult`,OQ=`CreateSessionRequest`,kQ=`CreateSession`,AQ=`ChecksumType`,jQ=`Content-Type`,MQ=`ContentType`,NQ=`ContinuationToken`,PQ=`Contents`,FQ=`Credentials`,IQ=`DeleteMarker`,LQ=`DisplayName`,RQ=`DeleteObjectOutput`,zQ=`DeleteObjectRequest`,BQ=`DeleteObject`,VQ=`DataRedundancy`,HQ=`Delimiter`,UQ=`Expiration`,WQ=`ExpectedBucketOwner`,GQ=`ExpiresString`,KQ=`EncryptionTypeMismatch`,qQ=`ETag`,JQ=`EncodingType`,YQ=`Expires`,XQ=`FetchOwner`,ZQ=`GrantFullControl`,QQ=`GetObject`,$Q=`GetObjectOutput`,e$=`GetObjectRequest`,t$=`GrantRead`,n$=`GrantReadACP`,r$=`GrantWrite`,i$=`GrantWriteACP`,a$=`ID`,o$=`IfMatch`,s$=`IfMatchInitiatedTime`,c$=`IfMatchLastModifiedTime`,l$=`IfMatchSize`,u$=`If-Modified-Since`,d$=`IfModifiedSince`,f$=`InitiateMultipartUploadResult`,p$=`If-Match`,m$=`IfNoneMatch`,h$=`If-None-Match`,g$=`InvalidObjectState`,_$=`IdempotencyParameterMismatch`,v$=`InvalidRequest`,y$=`IsRestoreInProgress`,b$=`IsTruncated`,x$=`IfUnmodifiedSince`,S$=`If-Unmodified-Since`,C$=`InvalidWriteOffset`,w$=`Key`,T$=`KeyCount`,E$=`Location`,D$=`ListAllMyBucketsResult`,O$=`ListBuckets`,k$=`ListBucketsOutput`,A$=`ListBucketsRequest`,j$=`ListBucketResult`,M$=`LocationConstraint`,N$=`LocationInfo`,P$=`LastModified`,F$=`Last-Modified`,I$=`ListObjectsV2`,L$=`ListObjectsV2Output`,R$=`ListObjectsV2Request`,z$=`Metadata`,B$=`MaxBuckets`,V$=`MFA`,H$=`MaxKeys`,U$=`MissingMeta`,W$=`MpuObjectSize`,G$=`MultipartUpload`,K$=`Name`,q$=`NextContinuationToken`,J$=`NotFound`,Y$=`NoSuchBucket`,X$=`NoSuchKey`,Z$=`NoSuchUpload`,Q$=`Owner`,$$=`ObjectAlreadyInActiveTierError`,e1=`ObjectLockEnabledForBucket`,t1=`ObjectLockLegalHoldStatus`,n1=`ObjectLockMode`,r1=`ObjectLockRetainUntilDate`,i1=`ObjectList`,a1=`ObjectNotInActiveTierError`,o1=`ObjectOwnership`,s1=`OptionalObjectAttributes`,c1=`Object`,l1=`Prefix`,u1=`PartsCount`,d1=`PartNumber`,f1=`PutObject`,p1=`PutObjectOutput`,m1=`PutObjectRequest`,h1=`PutObjectTagging`,g1=`PutObjectTaggingOutput`,_1=`PutObjectTaggingRequest`,v1=`Parts`,y1=`Part`,b1=`RequestCharged`,x1=`ResponseCacheControl`,S1=`ResponseContentDisposition`,C1=`ResponseContentEncoding`,w1=`ResponseContentLanguage`,T1=`ResponseContentType`,E1=`ResponseExpires`,D1=`RestoreExpiryDate`,O1=`RequestPayer`,k1=`ReplicationStatus`,A1=`RestoreStatus`,j1=`Range`,M1=`Restore`,N1=`StartAfter`,P1=`SecretAccessKey`,F1=`StreamingBlob`,I1=`StorageClass`,L1=`SessionCredentialValue`,R1=`SessionCredentials`,z1=`SessionMode`,B1=`ServerSideEncryption`,V1=`SSECustomerAlgorithm`,H1=`SSECustomerKey`,U1=`SSECustomerKeyMD5`,W1=`SSEKMSEncryptionContext`,G1=`SSEKMSKeyId`,K1=`SessionToken`,q1=`Size`,J1=`Tags`,Y1=`TagCount`,X1=`TooManyParts`,Z1=`TagSet`,Q1=`Tag`,$1=`Tagging`,e0=`Type`,t0=`UploadId`,n0=`UploadPart`,r0=`UploadPartOutput`,i0=`UploadPartRequest`,a0=`Value`,o0=`VersionId`,s0=`WriteOffsetBytes`,c0=`WebsiteRedirectLocation`,l0=`accept-ranges`,u0=`bucket-region`,d0=`client`,f0=`continuation-token`,p0=`delimiter`,m0=`error`,h0=`encoding-type`,g0=`fetch-owner`,_0=`http`,v0=`httpChecksum`,y0=`httpError`,Z=`httpHeader`,b0=`httpPayload`,x0=`httpPrefixHeaders`,Q=`httpQuery`,S0=`max-buckets`,C0=`max-keys`,w0=`prefix`,T0=`partNumber`,E0=`response-cache-control`,D0=`response-content-disposition`,O0=`response-content-encoding`,k0=`response-content-language`,A0=`response-content-type`,j0=`response-expires`,M0=`smithy.ts.sdk.synthetic.com.amazonaws.s3`,N0=`start-after`,P0=`streaming`,F0=`uploadId`,I0=`versionId`,L0=`xmlFlattened`,R0=`xmlName`,z0=`x-amz-acl`,B0=`x-amz-abort-date`,V0=`x-amz-abort-rule-id`,H0=`x-amz-bucket-arn`,U0=`x-amz-bypass-governance-retention`,W0=`x-amz-bucket-namespace`,G0=`x-amz-bucket-object-lock-enabled`,K0=`x-amz-checksum-algorithm`,q0=`x-amz-checksum-crc32`,J0=`x-amz-checksum-crc32c`,Y0=`x-amz-checksum-crc64nvme`,X0=`x-amz-checksum-mode`,Z0=`x-amz-checksum-sha1`,Q0=`x-amz-checksum-sha256`,$0=`x-amz-create-session-mode`,e2=`x-amz-checksum-type`,t2=`x-amz-delete-marker`,n2=`x-amz-expiration`,r2=`x-amz-expected-bucket-owner`,i2=`x-amz-grant-full-control`,a2=`x-amz-grant-read`,o2=`x-amz-grant-read-acp`,s2=`x-amz-grant-write`,c2=`x-amz-grant-write-acp`,l2=`x-amz-if-match-initiated-time`,u2=`x-amz-if-match-last-modified-time`,d2=`x-amz-if-match-size`,f2=`x-amz-meta-`,p2=`x-amz-mfa`,m2=`x-amz-missing-meta`,h2=`x-amz-mp-object-size`,g2=`x-amz-mp-parts-count`,_2=`x-amz-object-lock-legal-hold`,v2=`x-amz-object-lock-mode`,y2=`x-amz-object-lock-retain-until-date`,b2=`x-amz-object-ownership`,x2=`x-amz-optional-object-attributes`,S2=`x-amz-object-size`,C2=`x-amz-restore`,w2=`x-amz-request-charged`,T2=`x-amz-request-payer`,E2=`x-amz-replication-status`,D2=`x-amz-storage-class`,O2=`x-amz-sdk-checksum-algorithm`,k2=`x-amz-server-side-encryption`,A2=`x-amz-server-side-encryption-aws-kms-key-id`,j2=`x-amz-server-side-encryption-bucket-key-enabled`,M2=`x-amz-server-side-encryption-context`,N2=`x-amz-server-side-encryption-customer-algorithm`,P2=`x-amz-server-side-encryption-customer-key`,F2=`x-amz-server-side-encryption-customer-key-MD5`,I2=`x-amz-tagging`,L2=`x-amz-tagging-count`,R2=`x-amz-version-id`,z2=`x-amz-write-offset-bytes`,B2=`x-amz-website-redirect-location`,$=`com.amazonaws.s3`,V2=At.for(M0),H2=[-3,M0,`S3ServiceException`,0,[],[]];V2.registerError(H2,iZ);var U2=At.for($),W2=[-3,$,xZ,{[m0]:d0,[y0]:403},[],[]];U2.registerError(W2,oZ);var G2=[-3,$,MZ,{[m0]:d0,[y0]:409},[],[]];U2.registerError(G2,cZ);var K2=[-3,$,NZ,{[m0]:d0,[y0]:409},[],[]];U2.registerError(K2,lZ);var q2=[-3,$,KQ,{[m0]:d0,[y0]:400},[],[]];U2.registerError(q2,mZ);var J2=[-3,$,_$,{[m0]:d0,[y0]:400},[],[]];U2.registerError(J2,vZ);var Y2=[-3,$,g$,{[m0]:d0,[y0]:403},[I1,kZ],[0,0]];U2.registerError(Y2,dZ);var X2=[-3,$,v$,{[m0]:d0,[y0]:400},[],[]];U2.registerError(X2,hZ);var Z2=[-3,$,C$,{[m0]:d0,[y0]:400},[],[]];U2.registerError(Z2,gZ);var Q2=[-3,$,Y$,{[m0]:d0,[y0]:404},[],[]];U2.registerError(Q2,uZ);var $2=[-3,$,X$,{[m0]:d0,[y0]:404},[],[]];U2.registerError($2,fZ);var e4=[-3,$,Z$,{[m0]:d0,[y0]:404},[],[]];U2.registerError(e4,aZ);var t4=[-3,$,J$,{[m0]:d0},[],[]];U2.registerError(t4,pZ);var n4=[-3,$,$$,{[m0]:d0,[y0]:403},[],[]];U2.registerError(n4,yZ);var r4=[-3,$,a1,{[m0]:d0,[y0]:403},[],[]];U2.registerError(r4,sZ);var i4=[-3,$,X1,{[m0]:d0,[y0]:400},[],[]];U2.registerError(i4,_Z);var a4=[V2,U2],o4=[0,$,L1,8,0],s4=[0,$,H1,8,0],c4=[0,$,W1,8,0],l4=[0,$,G1,8,0],u4=[0,$,F1,{[P0]:1},42],d4=[3,$,TZ,0,[b1],[[0,{[Z]:w2}]]],f4=[3,$,EZ,0,[AZ,w$,t0,O1,WQ,s$],[[0,1],[0,1],[0,{[Q]:F0}],[0,{[Z]:T2}],[0,{[Z]:r2}],[6,{[Z]:l2}]],3],p4=[3,$,AZ,0,[K$,ZZ,RZ,jZ],[0,4,0,0]],m4=[3,$,FZ,0,[VQ,e0],[0,0]],h4=[3,$,_Q,0,[l1],[0]],g4=[3,$,cQ,0,[v1],[[()=>X4,{[L0]:1,[R0]:y1}]]],_4=[3,$,bQ,0,[qQ,qZ,JZ,YZ,wQ,TQ,d1],[0,0,0,0,0,0,1]],v4=[3,$,lQ,{[R0]:dQ},[E$,AZ,w$,UQ,qQ,qZ,JZ,YZ,wQ,TQ,AQ,B1,o0,G1,IZ,b1],[0,0,0,[0,{[Z]:n2}],0,0,0,0,0,0,0,[0,{[Z]:k2}],[0,{[Z]:R2}],[()=>l4,{[Z]:A2}],[2,{[Z]:j2}],[0,{[Z]:w2}]]],y4=[3,$,fQ,0,[AZ,w$,t0,G$,qZ,JZ,YZ,wQ,TQ,AQ,W$,O1,WQ,o$,m$,V1,H1,U1],[[0,1],[0,1],[0,{[Q]:F0}],[()=>g4,{[b0]:1,[R0]:mQ}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:e2}],[1,{[Z]:h2}],[0,{[Z]:T2}],[0,{[Z]:r2}],[0,{[Z]:p$}],[0,{[Z]:h$}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}]],3],b4=[3,$,UZ,0,[M$,E$,AZ,J1],[0,()=>F4,()=>m4,[()=>Q4,0]]],x4=[3,$,WZ,0,[E$,jZ],[[0,{[Z]:E$}],[0,{[Z]:H0}]]],S4=[3,$,GZ,0,[AZ,bZ,UZ,ZQ,t$,n$,r$,i$,e1,o1,LZ],[[0,1],[0,{[Z]:z0}],[()=>b4,{[b0]:1,[R0]:UZ}],[0,{[Z]:i2}],[0,{[Z]:a2}],[0,{[Z]:o2}],[0,{[Z]:s2}],[0,{[Z]:c2}],[2,{[Z]:G0}],[0,{[Z]:b2}],[0,{[Z]:W0}]],1],C4=[3,$,uQ,{[R0]:f$},[SZ,OZ,AZ,w$,t0,B1,V1,U1,G1,W1,IZ,b1,VZ,AQ],[[4,{[Z]:B0}],[0,{[Z]:V0}],[0,{[R0]:AZ}],0,0,[0,{[Z]:k2}],[0,{[Z]:N2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}],[0,{[Z]:w2}],[0,{[Z]:K0}],[0,{[Z]:e2}]]],w4=[3,$,pQ,0,[AZ,w$,bZ,KZ,$Z,tQ,nQ,MQ,YQ,ZQ,t$,n$,i$,z$,B1,I1,c0,V1,H1,U1,G1,W1,IZ,O1,$1,n1,r1,t1,WQ,VZ,AQ],[[0,1],[0,1],[0,{[Z]:z0}],[0,{[Z]:XZ}],[0,{[Z]:QZ}],[0,{[Z]:eQ}],[0,{[Z]:rQ}],[0,{[Z]:jQ}],[4,{[Z]:YQ}],[0,{[Z]:i2}],[0,{[Z]:a2}],[0,{[Z]:o2}],[0,{[Z]:c2}],[128,{[x0]:f2}],[0,{[Z]:k2}],[0,{[Z]:D2}],[0,{[Z]:B2}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}],[0,{[Z]:T2}],[0,{[Z]:I2}],[0,{[Z]:v2}],[5,{[Z]:y2}],[0,{[Z]:_2}],[0,{[Z]:r2}],[0,{[Z]:K0}],[0,{[Z]:e2}]],2],T4=[3,$,EQ,{[R0]:DQ},[FQ,B1,G1,W1,IZ],[[()=>U4,{[R0]:FQ}],[0,{[Z]:k2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}]],1],E4=[3,$,OQ,0,[AZ,z1,B1,G1,W1,IZ],[[0,1],[0,{[Z]:$0}],[0,{[Z]:k2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}]],1],D4=[3,$,RQ,0,[IQ,o0,b1],[[2,{[Z]:t2}],[0,{[Z]:R2}],[0,{[Z]:w2}]]],O4=[3,$,zQ,0,[AZ,w$,V$,o0,O1,PZ,WQ,o$,c$,l$],[[0,1],[0,1],[0,{[Z]:p2}],[0,{[Q]:I0}],[0,{[Z]:T2}],[2,{[Z]:U0}],[0,{[Z]:r2}],[0,{[Z]:p$}],[6,{[Z]:u2}],[1,{[Z]:d2}]],2],k4=[3,$,$Q,0,[zZ,IQ,DZ,UQ,M1,P$,aQ,qQ,qZ,JZ,YZ,wQ,TQ,AQ,U$,o0,KZ,$Z,tQ,nQ,SQ,MQ,YQ,GQ,c0,B1,z$,V1,U1,G1,IZ,I1,b1,k1,u1,Y1,n1,r1,t1],[[()=>u4,16],[2,{[Z]:t2}],[0,{[Z]:l0}],[0,{[Z]:n2}],[0,{[Z]:C2}],[4,{[Z]:F$}],[1,{[Z]:iQ}],[0,{[Z]:qQ}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:e2}],[1,{[Z]:m2}],[0,{[Z]:R2}],[0,{[Z]:XZ}],[0,{[Z]:QZ}],[0,{[Z]:eQ}],[0,{[Z]:rQ}],[0,{[Z]:CQ}],[0,{[Z]:jQ}],[4,{[Z]:YQ}],[0,{[Z]:GQ}],[0,{[Z]:B2}],[0,{[Z]:k2}],[128,{[x0]:f2}],[0,{[Z]:N2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[2,{[Z]:j2}],[0,{[Z]:D2}],[0,{[Z]:w2}],[0,{[Z]:E2}],[1,{[Z]:g2}],[1,{[Z]:L2}],[0,{[Z]:v2}],[5,{[Z]:y2}],[0,{[Z]:_2}]]],A4=[3,$,e$,0,[AZ,w$,o$,d$,m$,x$,j1,x1,S1,C1,w1,T1,E1,o0,V1,H1,U1,O1,d1,WQ,gQ],[[0,1],[0,1],[0,{[Z]:p$}],[4,{[Z]:u$}],[0,{[Z]:h$}],[4,{[Z]:S$}],[0,{[Z]:j1}],[0,{[Q]:E0}],[0,{[Q]:D0}],[0,{[Q]:O0}],[0,{[Q]:k0}],[0,{[Q]:A0}],[6,{[Q]:j0}],[0,{[Q]:I0}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}],[0,{[Z]:T2}],[1,{[Q]:T0}],[0,{[Z]:r2}],[0,{[Z]:X0}]],2],j4=[3,$,k$,{[R0]:D$},[BZ,Q$,NQ,l1],[[()=>J4,0],()=>L4,0,0]],M4=[3,$,A$,0,[B$,NQ,l1,RZ],[[1,{[Q]:S0}],[0,{[Q]:f0}],[0,{[Q]:w0}],[0,{[Q]:u0}]]],N4=[3,$,L$,{[R0]:j$},[b$,PQ,K$,l1,HQ,H$,xQ,JQ,T$,NQ,q$,N1,b1],[2,[()=>Z4,{[L0]:1}],0,0,0,1,[()=>Y4,{[L0]:1}],0,1,0,0,0,[0,{[Z]:w2}]]],P4=[3,$,R$,0,[AZ,HQ,JQ,H$,l1,NQ,XQ,N1,O1,WQ,s1],[[0,1],[0,{[Q]:p0}],[0,{[Q]:h0}],[1,{[Q]:C0}],[0,{[Q]:w0}],[0,{[Q]:f0}],[2,{[Q]:g0}],[0,{[Q]:N0}],[0,{[Z]:T2}],[0,{[Z]:r2}],[64,{[Z]:x2}]],1],F4=[3,$,N$,0,[e0,K$],[0,0]],I4=[3,$,c1,0,[w$,P$,qQ,VZ,AQ,q1,I1,Q$,A1],[0,4,0,[64,{[L0]:1}],0,1,0,()=>L4,()=>H4]],L4=[3,$,Q$,0,[LQ,a$],[0,0]],R4=[3,$,p1,0,[UQ,qQ,qZ,JZ,YZ,wQ,TQ,AQ,B1,o0,V1,U1,G1,W1,IZ,q1,b1],[[0,{[Z]:n2}],[0,{[Z]:qQ}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:e2}],[0,{[Z]:k2}],[0,{[Z]:R2}],[0,{[Z]:N2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}],[1,{[Z]:S2}],[0,{[Z]:w2}]]],z4=[3,$,m1,0,[AZ,w$,bZ,zZ,KZ,$Z,tQ,nQ,aQ,sQ,MQ,VZ,qZ,JZ,YZ,wQ,TQ,YQ,o$,m$,ZQ,t$,n$,i$,s0,z$,B1,I1,c0,V1,H1,U1,G1,W1,IZ,O1,$1,n1,r1,t1,WQ],[[0,1],[0,1],[0,{[Z]:z0}],[()=>u4,16],[0,{[Z]:XZ}],[0,{[Z]:QZ}],[0,{[Z]:eQ}],[0,{[Z]:rQ}],[1,{[Z]:iQ}],[0,{[Z]:oQ}],[0,{[Z]:jQ}],[0,{[Z]:O2}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[4,{[Z]:YQ}],[0,{[Z]:p$}],[0,{[Z]:h$}],[0,{[Z]:i2}],[0,{[Z]:a2}],[0,{[Z]:o2}],[0,{[Z]:c2}],[1,{[Z]:z2}],[128,{[x0]:f2}],[0,{[Z]:k2}],[0,{[Z]:D2}],[0,{[Z]:B2}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}],[0,{[Z]:T2}],[0,{[Z]:I2}],[0,{[Z]:v2}],[5,{[Z]:y2}],[0,{[Z]:_2}],[0,{[Z]:r2}]],2],B4=[3,$,g1,0,[o0],[[0,{[Z]:R2}]]],V4=[3,$,_1,0,[AZ,w$,$1,o0,sQ,VZ,WQ,O1],[[0,1],[0,1],[()=>G4,{[b0]:1,[R0]:$1}],[0,{[Q]:I0}],[0,{[Z]:oQ}],[0,{[Z]:O2}],[0,{[Z]:r2}],[0,{[Z]:T2}]],3],H4=[3,$,A1,0,[y$,D1],[2,4]],U4=[3,$,R1,0,[CZ,P1,K1,UQ],[[0,{[R0]:CZ}],[()=>o4,{[R0]:P1}],[()=>o4,{[R0]:K1}],[4,{[R0]:UQ}]],4],W4=[3,$,Q1,0,[w$,a0],[0,0],2],G4=[3,$,$1,0,[Z1],[[()=>Q4,0]],1],K4=[3,$,r0,0,[B1,qQ,qZ,JZ,YZ,wQ,TQ,V1,U1,G1,IZ,b1],[[0,{[Z]:k2}],[0,{[Z]:qQ}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:N2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[2,{[Z]:j2}],[0,{[Z]:w2}]]],q4=[3,$,i0,0,[AZ,w$,d1,t0,zZ,aQ,sQ,VZ,qZ,JZ,YZ,wQ,TQ,V1,H1,U1,O1,WQ],[[0,1],[0,1],[1,{[Q]:T0}],[0,{[Q]:F0}],[()=>u4,16],[1,{[Z]:iQ}],[0,{[Z]:oQ}],[0,{[Z]:O2}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}],[0,{[Z]:T2}],[0,{[Z]:r2}]],4],J4=[1,$,BZ,0,[()=>p4,{[R0]:AZ}]],Y4=[1,$,vQ,0,()=>h4],X4=[1,$,yQ,0,()=>_4],Z4=[1,$,i1,0,[()=>I4,0]],Q4=[1,$,Z1,0,[()=>W4,{[R0]:Q1}]],$4=[9,$,wZ,{[_0]:[`DELETE`,`/{Key+}?x-id=AbortMultipartUpload`,204]},()=>f4,()=>d4],e3=[9,$,mQ,{[_0]:[`POST`,`/{Key+}`,200]},()=>y4,()=>v4],t3=[9,$,HZ,{[_0]:[`PUT`,`/`,200]},()=>S4,()=>x4],n3=[9,$,hQ,{[_0]:[`POST`,`/{Key+}?uploads`,200]},()=>w4,()=>C4],r3=[9,$,kQ,{[_0]:[`GET`,`/?session`,200]},()=>E4,()=>T4],i3=[9,$,BQ,{[_0]:[`DELETE`,`/{Key+}?x-id=DeleteObject`,204]},()=>O4,()=>D4],a3=[9,$,QQ,{[v0]:`-`,[_0]:[`GET`,`/{Key+}?x-id=GetObject`,200]},()=>A4,()=>k4],o3=[9,$,O$,{[_0]:[`GET`,`/?x-id=ListBuckets`,200]},()=>M4,()=>j4],s3=[9,$,I$,{[_0]:[`GET`,`/?list-type=2`,200]},()=>P4,()=>N4],c3=[9,$,f1,{[v0]:`-`,[_0]:[`PUT`,`/{Key+}?x-id=PutObject`,200]},()=>z4,()=>R4],l3=[9,$,h1,{[v0]:`-`,[_0]:[`PUT`,`/{Key+}?tagging`,200]},()=>V4,()=>B4],u3=[9,$,n0,{[v0]:`-`,[_0]:[`PUT`,`/{Key+}?x-id=UploadPart`,200]},()=>q4,()=>K4],d3=class extends pi.classBuilder().ep({...rZ,DisableS3ExpressSessionAuth:{type:`staticContextParams`,value:!0},Bucket:{type:`contextParams`,name:`Bucket`}}).m(function(e,t,n,r){return[Ya(n,e.getEndpointParameterInstructions()),jq(n)]}).s(`AmazonS3`,`CreateSession`,{}).n(`S3Client`,`CreateSessionCommand`).sc(r3).build(){},f3=`@aws-sdk/client-s3`,p3=`AWS SDK for JavaScript S3 Client for Node.js, Browser and React Native`,m3=`3.1019.0`,h3={build:`concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs`,"build:cjs":`node ../../scripts/compilation/inline client-s3`,"build:es":`tsc -p tsconfig.es.json`,"build:include:deps":`yarn g:turbo run build -F="$npm_package_name"`,"build:types":`tsc -p tsconfig.types.json`,"build:types:downlevel":`downlevel-dts dist-types dist-types/ts3.4`,clean:`premove dist-cjs dist-es dist-types tsconfig.cjs.tsbuildinfo tsconfig.es.tsbuildinfo tsconfig.types.tsbuildinfo`,"extract:docs":`api-extractor run --local`,"generate:client":`node ../../scripts/generate-clients/single-service --solo s3`,test:`yarn g:vitest run`,"test:browser":`node ./test/browser-build/esbuild && yarn g:vitest run -c vitest.config.browser.mts`,"test:browser:watch":`node ./test/browser-build/esbuild && yarn g:vitest watch -c vitest.config.browser.mts`,"test:e2e":`yarn g:vitest run -c vitest.config.e2e.mts && yarn test:browser`,"test:e2e:watch":`yarn g:vitest watch -c vitest.config.e2e.mts`,"test:index":`tsc --noEmit ./test/index-types.ts && node ./test/index-objects.spec.mjs`,"test:integration":`yarn g:vitest run -c vitest.config.integ.mts`,"test:integration:watch":`yarn g:vitest watch -c vitest.config.integ.mts`,"test:watch":`yarn g:vitest watch`},g3=`./dist-cjs/index.js`,_3=`./dist-types/index.d.ts`,v3=`./dist-es/index.js`,y3={"@aws-crypto/sha1-browser":`5.2.0`,"@aws-crypto/sha256-browser":`5.2.0`,"@aws-crypto/sha256-js":`5.2.0`,"@aws-sdk/core":`^3.973.25`,"@aws-sdk/credential-provider-node":`^3.972.27`,"@aws-sdk/middleware-bucket-endpoint":`^3.972.8`,"@aws-sdk/middleware-expect-continue":`^3.972.8`,"@aws-sdk/middleware-flexible-checksums":`^3.974.5`,"@aws-sdk/middleware-host-header":`^3.972.8`,"@aws-sdk/middleware-location-constraint":`^3.972.8`,"@aws-sdk/middleware-logger":`^3.972.8`,"@aws-sdk/middleware-recursion-detection":`^3.972.9`,"@aws-sdk/middleware-sdk-s3":`^3.972.26`,"@aws-sdk/middleware-ssec":`^3.972.8`,"@aws-sdk/middleware-user-agent":`^3.972.26`,"@aws-sdk/region-config-resolver":`^3.972.10`,"@aws-sdk/signature-v4-multi-region":`^3.996.14`,"@aws-sdk/types":`^3.973.6`,"@aws-sdk/util-endpoints":`^3.996.5`,"@aws-sdk/util-user-agent-browser":`^3.972.8`,"@aws-sdk/util-user-agent-node":`^3.973.12`,"@smithy/config-resolver":`^4.4.13`,"@smithy/core":`^3.23.12`,"@smithy/eventstream-serde-browser":`^4.2.12`,"@smithy/eventstream-serde-config-resolver":`^4.3.12`,"@smithy/eventstream-serde-node":`^4.2.12`,"@smithy/fetch-http-handler":`^5.3.15`,"@smithy/hash-blob-browser":`^4.2.13`,"@smithy/hash-node":`^4.2.12`,"@smithy/hash-stream-node":`^4.2.12`,"@smithy/invalid-dependency":`^4.2.12`,"@smithy/md5-js":`^4.2.12`,"@smithy/middleware-content-length":`^4.2.12`,"@smithy/middleware-endpoint":`^4.4.27`,"@smithy/middleware-retry":`^4.4.44`,"@smithy/middleware-serde":`^4.2.15`,"@smithy/middleware-stack":`^4.2.12`,"@smithy/node-config-provider":`^4.3.12`,"@smithy/node-http-handler":`^4.5.0`,"@smithy/protocol-http":`^5.3.12`,"@smithy/smithy-client":`^4.12.7`,"@smithy/types":`^4.13.1`,"@smithy/url-parser":`^4.2.12`,"@smithy/util-base64":`^4.3.2`,"@smithy/util-body-length-browser":`^4.2.2`,"@smithy/util-body-length-node":`^4.2.3`,"@smithy/util-defaults-mode-browser":`^4.3.43`,"@smithy/util-defaults-mode-node":`^4.2.47`,"@smithy/util-endpoints":`^3.3.3`,"@smithy/util-middleware":`^4.2.12`,"@smithy/util-retry":`^4.2.12`,"@smithy/util-stream":`^4.5.20`,"@smithy/util-utf8":`^4.2.2`,"@smithy/util-waiter":`^4.2.13`,tslib:`^2.6.2`},b3={"@aws-sdk/signature-v4-crt":`3.1019.0`,"@smithy/snapshot-testing":`^2.0.3`,"@tsconfig/node20":`20.1.8`,"@types/node":`^20.14.8`,concurrently:`7.0.0`,"downlevel-dts":`0.10.1`,premove:`4.0.0`,typescript:`~5.8.3`,vitest:`^4.0.17`},x3={node:`>=20.0.0`},S3={"<4.5":{"dist-types/*":[`dist-types/ts3.4/*`]}},C3=[`dist-*/**`],w3={name:`AWS SDK for JavaScript Team`,url:`https://aws.amazon.com/javascript/`},T3=`Apache-2.0`,E3={"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.browser`},D3=`https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-s3`,O3={type:`git`,url:`https://github.com/aws/aws-sdk-js-v3.git`,directory:`clients/client-s3`},k3={name:f3,description:p3,version:m3,scripts:h3,main:g3,types:_3,module:v3,sideEffects:!1,dependencies:y3,devDependencies:b3,engines:x3,typesVersions:S3,files:C3,author:w3,license:T3,browser:E3,"react-native":{"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.native`},homepage:D3,repository:O3};function A3(e){return typeof e==`string`?e.length===0:e.byteLength===0}var j3={name:`SHA-1`},M3={name:`HMAC`,hash:j3},N3=new Uint8Array([218,57,163,238,94,107,75,13,50,85,191,239,149,96,24,144,175,216,7,9]),P3=function(){function e(e){this.toHash=new Uint8Array,e!==void 0&&(this.key=new Promise(function(t,n){u().crypto.subtle.importKey(`raw`,F3(e),M3,!1,[`sign`]).then(t,n)}),this.key.catch(function(){}))}return e.prototype.update=function(e){if(!A3(e)){var t=F3(e),n=new Uint8Array(this.toHash.byteLength+t.byteLength);n.set(this.toHash,0),n.set(t,this.toHash.byteLength),this.toHash=n}},e.prototype.digest=function(){var e=this;return this.key?this.key.then(function(t){return u().crypto.subtle.sign(M3,t,e.toHash).then(function(e){return new Uint8Array(e)})}):A3(this.toHash)?Promise.resolve(N3):Promise.resolve().then(function(){return u().crypto.subtle.digest(j3,e.toHash)}).then(function(e){return Promise.resolve(new Uint8Array(e))})},e.prototype.reset=function(){this.toHash=new Uint8Array},e}();function F3(e){return typeof e==`string`?oe(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}var I3=function(){function e(e){if(ie(u()))this.hash=new P3(e);else throw Error(`SHA1 not supported`)}return e.prototype.update=function(e,t){this.hash.update(ae(e))},e.prototype.digest=function(){return this.hash.digest()},e.prototype.reset=function(){this.hash.reset()},e}(),L3=class e{bytes;constructor(e){if(this.bytes=e,e.byteLength!==8)throw Error(`Int64 buffers must be exactly 8 bytes`)}static fromNumber(t){if(t>0x8000000000000000||t<-0x8000000000000000)throw Error(`${t} is too large (or, if negative, too small) to represent as an Int64`);let n=new Uint8Array(8);for(let e=7,r=Math.abs(Math.round(t));e>-1&&r>0;e--,r/=256)n[e]=r;return t<0&&R3(n),new e(n)}valueOf(){let e=this.bytes.slice(0),t=e[0]&128;return t&&R3(e),parseInt(ne(e),16)*(t?-1:1)}toString(){return String(this.valueOf())}};function R3(e){for(let t=0;t<8;t++)e[t]^=255;for(let t=7;t>-1&&(e[t]++,e[t]===0);t--);}var z3=class{toUtf8;fromUtf8;constructor(e,t){this.toUtf8=e,this.fromUtf8=t}format(e){let t=[];for(let n of Object.keys(e)){let r=this.fromUtf8(n);t.push(Uint8Array.from([r.byteLength]),r,this.formatHeaderValue(e[n]))}let n=new Uint8Array(t.reduce((e,t)=>e+t.byteLength,0)),r=0;for(let e of t)n.set(e,r),r+=e.byteLength;return n}formatHeaderValue(e){switch(e.type){case`boolean`:return Uint8Array.from([e.value?0:1]);case`byte`:return Uint8Array.from([2,e.value]);case`short`:let t=new DataView(new ArrayBuffer(3));return t.setUint8(0,3),t.setInt16(1,e.value,!1),new Uint8Array(t.buffer);case`integer`:let n=new DataView(new ArrayBuffer(5));return n.setUint8(0,4),n.setInt32(1,e.value,!1),new Uint8Array(n.buffer);case`long`:let r=new Uint8Array(9);return r[0]=5,r.set(e.value.bytes,1),r;case`binary`:let i=new DataView(new ArrayBuffer(3+e.value.byteLength));i.setUint8(0,6),i.setUint16(1,e.value.byteLength,!1);let a=new Uint8Array(i.buffer);return a.set(e.value,3),a;case`string`:let o=this.fromUtf8(e.value),s=new DataView(new ArrayBuffer(3+o.byteLength));s.setUint8(0,7),s.setUint16(1,o.byteLength,!1);let c=new Uint8Array(s.buffer);return c.set(o,3),c;case`timestamp`:let l=new Uint8Array(9);return l[0]=8,l.set(L3.fromNumber(e.value.valueOf()).bytes,1),l;case`uuid`:if(!X3.test(e.value))throw Error(`Invalid UUID received: ${e.value}`);let u=new Uint8Array(17);return u[0]=9,u.set(ee(e.value.replace(/\-/g,``)),1),u}}parse(e){let t={},n=0;for(;n{if(typeof e!=`number`)throw Error(`Attempted to allocate an event message where size was not a number: `+e);t=e,n=4,r=new Uint8Array(e),new DataView(r.buffer).setUint32(0,e,!1)},o=async function*(){let o=e[Symbol.asyncIterator]();for(;;){let{value:e,done:s}=await o.next();if(s){if(!t)return;if(t===n)yield r;else throw Error(`Truncated event message received.`);return}let c=e.length,l=0;for(;l({[Symbol.asyncIterator]:async function*(){let t=e.getReader();try{for(;;){let{done:e,value:n}=await t.read();if(e)return;yield n}}finally{t.releaseLock()}}}),d6=e=>{let t=e[Symbol.asyncIterator]();return new ReadableStream({async pull(e){let{done:n,value:r}=await t.next();if(n)return e.close();e.enqueue(r)}})},f6=class{universalMarshaller;constructor({utf8Encoder:e,utf8Decoder:t}){this.universalMarshaller=new l6({utf8Decoder:t,utf8Encoder:e})}deserialize(e,t){let n=p6(e)?u6(e):e;return this.universalMarshaller.deserialize(n,t)}serialize(e,t){let n=this.universalMarshaller.serialize(e,t);return typeof ReadableStream==`function`?d6(n):n}},p6=e=>typeof ReadableStream==`function`&&e instanceof ReadableStream,m6=e=>new f6(e);async function h6(e,t,n=1024*1024){let r=e.size,i=0;for(;i{n.update(e)}),n.digest()},_6=[1732584193,4023233417,2562383102,271733878],v6=class{state;buffer;bufferLength;bytesHashed;finished;constructor(){this.reset()}update(e){if(w6(e))return;if(this.finished)throw Error(`Attempted to update an already finished hash.`);let t=T6(e),n=0,{byteLength:r}=t;for(this.bytesHashed+=r;r>0;)this.buffer.setUint8(this.bufferLength++,t[n++]),r--,this.bufferLength===64&&(this.hashBuffer(),this.bufferLength=0)}async digest(){if(!this.finished){let{buffer:e,bufferLength:t,bytesHashed:n}=this,r=n*8;if(e.setUint8(this.bufferLength++,128),t%64>=56){for(let t=this.bufferLength;t<64;t++)e.setUint8(t,0);this.hashBuffer(),this.bufferLength=0}for(let t=this.bufferLength;t<56;t++)e.setUint8(t,0);e.setUint32(56,r>>>0,!0),e.setUint32(60,Math.floor(r/4294967296),!0),this.hashBuffer(),this.finished=!0}let e=new DataView(new ArrayBuffer(16));for(let t=0;t<4;t++)e.setUint32(t*4,this.state[t],!0);return new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}hashBuffer(){let{buffer:e,state:t}=this,n=t[0],r=t[1],i=t[2],a=t[3];n=b6(n,r,i,a,e.getUint32(0,!0),7,3614090360),a=b6(a,n,r,i,e.getUint32(4,!0),12,3905402710),i=b6(i,a,n,r,e.getUint32(8,!0),17,606105819),r=b6(r,i,a,n,e.getUint32(12,!0),22,3250441966),n=b6(n,r,i,a,e.getUint32(16,!0),7,4118548399),a=b6(a,n,r,i,e.getUint32(20,!0),12,1200080426),i=b6(i,a,n,r,e.getUint32(24,!0),17,2821735955),r=b6(r,i,a,n,e.getUint32(28,!0),22,4249261313),n=b6(n,r,i,a,e.getUint32(32,!0),7,1770035416),a=b6(a,n,r,i,e.getUint32(36,!0),12,2336552879),i=b6(i,a,n,r,e.getUint32(40,!0),17,4294925233),r=b6(r,i,a,n,e.getUint32(44,!0),22,2304563134),n=b6(n,r,i,a,e.getUint32(48,!0),7,1804603682),a=b6(a,n,r,i,e.getUint32(52,!0),12,4254626195),i=b6(i,a,n,r,e.getUint32(56,!0),17,2792965006),r=b6(r,i,a,n,e.getUint32(60,!0),22,1236535329),n=x6(n,r,i,a,e.getUint32(4,!0),5,4129170786),a=x6(a,n,r,i,e.getUint32(24,!0),9,3225465664),i=x6(i,a,n,r,e.getUint32(44,!0),14,643717713),r=x6(r,i,a,n,e.getUint32(0,!0),20,3921069994),n=x6(n,r,i,a,e.getUint32(20,!0),5,3593408605),a=x6(a,n,r,i,e.getUint32(40,!0),9,38016083),i=x6(i,a,n,r,e.getUint32(60,!0),14,3634488961),r=x6(r,i,a,n,e.getUint32(16,!0),20,3889429448),n=x6(n,r,i,a,e.getUint32(36,!0),5,568446438),a=x6(a,n,r,i,e.getUint32(56,!0),9,3275163606),i=x6(i,a,n,r,e.getUint32(12,!0),14,4107603335),r=x6(r,i,a,n,e.getUint32(32,!0),20,1163531501),n=x6(n,r,i,a,e.getUint32(52,!0),5,2850285829),a=x6(a,n,r,i,e.getUint32(8,!0),9,4243563512),i=x6(i,a,n,r,e.getUint32(28,!0),14,1735328473),r=x6(r,i,a,n,e.getUint32(48,!0),20,2368359562),n=S6(n,r,i,a,e.getUint32(20,!0),4,4294588738),a=S6(a,n,r,i,e.getUint32(32,!0),11,2272392833),i=S6(i,a,n,r,e.getUint32(44,!0),16,1839030562),r=S6(r,i,a,n,e.getUint32(56,!0),23,4259657740),n=S6(n,r,i,a,e.getUint32(4,!0),4,2763975236),a=S6(a,n,r,i,e.getUint32(16,!0),11,1272893353),i=S6(i,a,n,r,e.getUint32(28,!0),16,4139469664),r=S6(r,i,a,n,e.getUint32(40,!0),23,3200236656),n=S6(n,r,i,a,e.getUint32(52,!0),4,681279174),a=S6(a,n,r,i,e.getUint32(0,!0),11,3936430074),i=S6(i,a,n,r,e.getUint32(12,!0),16,3572445317),r=S6(r,i,a,n,e.getUint32(24,!0),23,76029189),n=S6(n,r,i,a,e.getUint32(36,!0),4,3654602809),a=S6(a,n,r,i,e.getUint32(48,!0),11,3873151461),i=S6(i,a,n,r,e.getUint32(60,!0),16,530742520),r=S6(r,i,a,n,e.getUint32(8,!0),23,3299628645),n=C6(n,r,i,a,e.getUint32(0,!0),6,4096336452),a=C6(a,n,r,i,e.getUint32(28,!0),10,1126891415),i=C6(i,a,n,r,e.getUint32(56,!0),15,2878612391),r=C6(r,i,a,n,e.getUint32(20,!0),21,4237533241),n=C6(n,r,i,a,e.getUint32(48,!0),6,1700485571),a=C6(a,n,r,i,e.getUint32(12,!0),10,2399980690),i=C6(i,a,n,r,e.getUint32(40,!0),15,4293915773),r=C6(r,i,a,n,e.getUint32(4,!0),21,2240044497),n=C6(n,r,i,a,e.getUint32(32,!0),6,1873313359),a=C6(a,n,r,i,e.getUint32(60,!0),10,4264355552),i=C6(i,a,n,r,e.getUint32(24,!0),15,2734768916),r=C6(r,i,a,n,e.getUint32(52,!0),21,1309151649),n=C6(n,r,i,a,e.getUint32(16,!0),6,4149444226),a=C6(a,n,r,i,e.getUint32(44,!0),10,3174756917),i=C6(i,a,n,r,e.getUint32(8,!0),15,718787259),r=C6(r,i,a,n,e.getUint32(36,!0),21,3951481745),t[0]=n+t[0]&4294967295,t[1]=r+t[1]&4294967295,t[2]=i+t[2]&4294967295,t[3]=a+t[3]&4294967295}reset(){this.state=Uint32Array.from(_6),this.buffer=new DataView(new ArrayBuffer(64)),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}};function y6(e,t,n,r,i,a){return t=(t+e&4294967295)+(r+a&4294967295)&4294967295,(t<>>32-i)+n&4294967295}function b6(e,t,n,r,i,a,o){return y6(t&n|~t&r,e,t,i,a,o)}function x6(e,t,n,r,i,a,o){return y6(t&r|n&~r,e,t,i,a,o)}function S6(e,t,n,r,i,a,o){return y6(t^n^r,e,t,i,a,o)}function C6(e,t,n,r,i,a,o){return y6(n^(t|~r),e,t,i,a,o)}function w6(e){return typeof e==`string`?e.length===0:e.byteLength===0}function T6(e){return typeof e==`string`?se(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}var E6=e=>({apiVersion:`2006-03-01`,base64Decoder:e?.base64Decoder??Ue,base64Encoder:e?.base64Encoder??We,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??XX,extensions:e?.extensions??[],getAwsChunkedEncodingStream:e?.getAwsChunkedEncodingStream??qe,httpAuthSchemeProvider:e?.httpAuthSchemeProvider??eZ,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:`aws.auth#sigv4`,identityProvider:e=>e.getIdentityProvider(`aws.auth#sigv4`),signer:new Xr},{schemeId:`aws.auth#sigv4a`,identityProvider:e=>e.getIdentityProvider(`aws.auth#sigv4a`),signer:new Zr}],logger:e?.logger??new Ei,protocol:e?.protocol??Rq,protocolSettings:e?.protocolSettings??{defaultNamespace:`com.amazonaws.s3`,errorTypeRegistries:a4,xmlNamespace:`http://s3.amazonaws.com/doc/2006-03-01/`,version:`2006-03-01`,serviceTarget:`AmazonS3`},sdkStreamMixin:e?.sdkStreamMixin??ot,serviceId:e?.serviceId??`S3`,signerConstructor:e?.signerConstructor??Vq,signingEscapePath:e?.signingEscapePath??!1,urlParser:e?.urlParser??gt,useArnRegion:e?.useArnRegion??void 0,utf8Decoder:e?.utf8Decoder??se,utf8Encoder:e?.utf8Encoder??ce}),D6=e=>{let t=Io(e),n=()=>t().then(_i),r=E6(e);return{...r,...e,runtime:`browser`,defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??ii,credentialDefaultProvider:e?.credentialDefaultProvider??(e=>()=>Promise.reject(Error(`Credential is missing`))),defaultUserAgentProvider:e?.defaultUserAgentProvider??Mo({serviceId:r.serviceId,clientVersion:k3.version}),eventStreamSerdeProvider:e?.eventStreamSerdeProvider??m6,maxAttempts:e?.maxAttempts??3,md5:e?.md5??v6,region:e?.region??Po(`Region is missing`),requestHandler:$e.create(e?.requestHandler??n),retryMode:e?.retryMode??(async()=>(await n()).retryMode||Yi),sha1:e?.sha1??I3,sha256:e?.sha256??l,streamCollector:e?.streamCollector??tt,streamHasher:e?.streamHasher??g6,useDualstackEndpoint:e?.useDualstackEndpoint??(()=>Promise.resolve(!1)),useFipsEndpoint:e?.useFipsEndpoint??(()=>Promise.resolve(!1))}},O6=e=>{let t=e.httpAuthSchemes,n=e.httpAuthSchemeProvider,r=e.credentials;return{setHttpAuthScheme(e){let n=t.findIndex(t=>t.schemeId===e.schemeId);n===-1?t.push(e):t.splice(n,1,e)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(e){n=e},httpAuthSchemeProvider(){return n},setCredentials(e){r=e},credentials(){return r}}},k6=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()}),A6=(e,t)=>{let n=Object.assign(wB(e),Ci(e),de(e),O6(e));return t.forEach(e=>e.configure(n)),Object.assign(e,TB(n),wi(n),fe(n),k6(n))},j6=class extends ui{config;constructor(...[e]){let t=D6(e||{});super(t),this.initConfig=t,this.config=A6(Tq(tZ(zq(Xa(ye(ja(Qa(nq($n(nZ(t))))))))),{session:[()=>this,d3]}),e?.extensions||[]),this.middlewareStack.use(xt(this.config)),this.middlewareStack.use(Ea(this.config)),this.middlewareStack.use(ao(this.config)),this.middlewareStack.use(Fa(this.config)),this.middlewareStack.use(Se(this.config)),this.middlewareStack.use(Te(this.config)),this.middlewareStack.use(Oe(this.config)),this.middlewareStack.use(Ne(this.config,{httpAuthSchemeParametersProvider:ZX,identityProviderConfigProvider:async e=>new Jn({"aws.auth#sigv4":e.credentials,"aws.auth#sigv4a":e.credentials})})),this.middlewareStack.use(Re(this.config)),this.middlewareStack.use(Lq(this.config)),this.middlewareStack.use(GK(this.config)),this.middlewareStack.use(sq(this.config)),this.middlewareStack.use(yq(this.config)),this.middlewareStack.use(wq(this.config))}destroy(){super.destroy()}},M6=`ap-southeast-2`,N6=`${window.location.protocol}//${window.location.hostname}:9999`,P6=`${window.location.protocol}//${window.location.hostname}:8443`,F6=null,I6=null,L6=null;function R6(){if(!F6){let e=n();if(!e)throw Error(`AWS credentials not configured`);F6=new kB({endpoint:N6,region:M6,credentials:{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey}})}return F6}function z6(){if(!I6){let e=n();if(!e)throw Error(`AWS credentials not configured`);I6=new HK({endpoint:N6,region:M6,credentials:{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey}})}return I6}function B6(){if(!L6){let e=n();if(!e)throw Error(`AWS credentials not configured`);L6=new j6({endpoint:P6,region:M6,credentials:{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey},forcePathStyle:!0}),L6.middlewareStack.use({applyToStack:e=>{e.add(e=>t=>{let n=t.request;return n?.path?.endsWith(`/`)&&n.path!==`/`&&(n.path=n.path.slice(0,-1)),e(t)},{step:`build`,name:`removeTrailingSlash`})}})}return L6}function V6(){F6=null,I6=null,L6=null}export{zz as $,OK as A,gB as At,Ez as B,Ei as Bt,xK as C,lB as Ct,TK as D,pB as Dt,wK as E,fB as Et,NK as F,xB as Ft,jz as G,ut as Gt,Oz as H,Ur as Ht,PK as I,po as It,Pz as J,We as Jt,Mz as K,Ye as Kt,FK as L,Ya as Lt,AK as M,vB as Mt,jK as N,yB as Nt,EK as O,mB as Ot,MK as P,bB as Pt,Rz as Q,IK as R,Ga as Rt,JK as S,cB as St,CK as T,dB as Tt,kz as U,Rn as Ut,Dz as V,pi as Vt,Az as W,Qt as Wt,Iz as X,ue as Xt,Fz as Y,ge as Yt,Lz as Z,jq as _,rB as _t,$4 as a,Gz as at,QK as b,oB as bt,n3 as c,Jz as ct,o3 as d,Zz as dt,Bz as et,s3 as f,$z as ft,rZ as g,nB as gt,u3 as h,tB as ht,B6 as i,Wz as it,kK as j,_B as jt,DK as k,hB as kt,i3 as l,Yz as lt,l3 as m,eB as mt,R6 as n,Hz as nt,e3 as o,Kz as ot,c3 as p,Qz as pt,Nz as q,Ke as qt,z6 as r,Uz as rt,t3 as s,qz as st,V6 as t,Vz as tt,a3 as u,Xz as ut,$K as v,iB as vt,SK as w,uB as wt,KK as x,sB as xt,XK as y,aB as yt,FB as z,Wa as zt}; \ No newline at end of file +`),Gt={warn:console.warn},Kt=[`Sun`,`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`],qt=[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`];function Jt(e){let t=e.getUTCFullYear(),n=e.getUTCMonth(),r=e.getUTCDay(),i=e.getUTCDate(),a=e.getUTCHours(),o=e.getUTCMinutes(),s=e.getUTCSeconds(),c=i<10?`0${i}`:`${i}`,l=a<10?`0${a}`:`${a}`,u=o<10?`0${o}`:`${o}`,d=s<10?`0${s}`:`${s}`;return`${Kt[r]}, ${c} ${qt[n]} ${t} ${l}:${u}:${d} GMT`}var Yt=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d{2}) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),Xt=new RegExp(/^(?:Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d{2})-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),Zt=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( [1-9]|\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? (\d{4})$/),Qt=e=>{if(e==null)return;if(typeof e!=`string`)throw TypeError(`RFC-7231 date-times must be expressed as strings`);let t=Yt.exec(e);if(t){let[e,n,r,i,a,o,s,c]=t;return $t(Ht(un(i)),rn(r),cn(n,`day`,1,31),{hours:a,minutes:o,seconds:s,fractionalMilliseconds:c})}if(t=Xt.exec(e),t){let[e,n,r,i,a,o,s,c]=t;return nn($t(en(i),rn(r),cn(n,`day`,1,31),{hours:a,minutes:o,seconds:s,fractionalMilliseconds:c}))}if(t=Zt.exec(e),t){let[e,n,r,i,a,o,s,c]=t;return $t(Ht(un(c)),rn(n),cn(r.trimLeft(),`day`,1,31),{hours:i,minutes:a,seconds:o,fractionalMilliseconds:s})}throw TypeError(`Invalid RFC-7231 date-time value`)},$t=(e,t,n,r)=>{let i=t-1;return on(e,i,n),new Date(Date.UTC(e,i,n,cn(r.hours,`hour`,0,23),cn(r.minutes,`minute`,0,59),cn(r.seconds,`seconds`,0,60),ln(r.fractionalMilliseconds)))},en=e=>{let t=new Date().getUTCFullYear(),n=Math.floor(t/100)*100+Ht(un(e));return ne.getTime()-new Date().getTime()>tn?new Date(Date.UTC(e.getUTCFullYear()-100,e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds())):e,rn=e=>{let t=qt.indexOf(e);if(t<0)throw TypeError(`Invalid month: ${e}`);return t+1},an=[31,28,31,30,31,30,31,31,30,31,30,31],on=(e,t,n)=>{let r=an[t];if(t===1&&sn(e)&&(r=29),n>r)throw TypeError(`Invalid day for ${qt[t]} in ${e}: ${n}`)},sn=e=>e%4==0&&(e%100!=0||e%400==0),cn=(e,t,n,r)=>{let i=Ut(un(e));if(ir)throw TypeError(`${t} must be between ${n} and ${r}, inclusive`);return i},ln=e=>e==null?0:zt(`0.`+e)*1e3,un=e=>{let t=0;for(;tt.toString(16).padStart(2,`0`)),pn=()=>{if(dn)return dn();let e=new Uint8Array(16);return crypto.getRandomValues(e),e[6]=e[6]&15|64,e[8]=e[8]&63|128,fn[e[0]]+fn[e[1]]+fn[e[2]]+fn[e[3]]+`-`+fn[e[4]]+fn[e[5]]+`-`+fn[e[6]]+fn[e[7]]+`-`+fn[e[8]]+fn[e[9]]+`-`+fn[e[10]]+fn[e[11]]+fn[e[12]]+fn[e[13]]+fn[e[14]]+fn[e[15]]},mn=function(e){return Object.assign(new String(e),{deserializeJSON(){return JSON.parse(String(e))},toString(){return String(e)},toJSON(){return String(e)}})};mn.from=e=>e&&typeof e==`object`&&(e instanceof mn||`deserializeJSON`in e)?e:typeof e==`string`||Object.getPrototypeOf(e)===String.prototype?mn(String(e)):mn(JSON.stringify(e)),mn.fromObject=mn.from;function hn(e){return(e.includes(`,`)||e.includes(`"`))&&(e=`"${e.replace(/"/g,`\\"`)}"`),e}var gn=`(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun)(?:[ne|u?r]?s?day)?`,_n=`(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)`,vn=`(\\d?\\d):(\\d{2}):(\\d{2})(?:\\.(\\d+))?`,yn=`(\\d?\\d)`,bn=`(\\d{4})`,xn=new RegExp(/^(\d{4})-(\d\d)-(\d\d)[tT](\d\d):(\d\d):(\d\d)(\.(\d+))?(([-+]\d\d:\d\d)|[zZ])$/),Sn=RegExp(`^${gn}, ${yn} ${_n} ${bn} ${vn} GMT$`),Cn=RegExp(`^${gn}, ${yn}-${_n}-(\\d\\d) ${vn} GMT$`),wn=RegExp(`^${gn} ${_n} ( [1-9]|\\d\\d) ${vn} ${bn}$`),Tn=[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`],En=e=>{if(e==null)return;let t=NaN;if(typeof e==`number`)t=e;else if(typeof e==`string`){if(!/^-?\d*\.?\d+$/.test(e))throw TypeError(`parseEpochTimestamp - numeric string invalid.`);t=Number.parseFloat(e)}else typeof e==`object`&&e.tag===1&&(t=e.value);if(isNaN(t)||Math.abs(t)===1/0)throw TypeError(`Epoch timestamps must be valid finite numbers.`);return new Date(Math.round(t*1e3))},Dn=e=>{if(e==null)return;if(typeof e!=`string`)throw TypeError(`RFC3339 timestamps must be strings`);let t=xn.exec(e);if(!t)throw TypeError(`Invalid RFC3339 timestamp format ${e}`);let[,n,r,i,a,o,s,,c,l]=t;kn(r,1,12),kn(i,1,31),kn(a,0,23),kn(o,0,59),kn(s,0,60);let u=new Date(Date.UTC(Number(n),Number(r)-1,Number(i),Number(a),Number(o),Number(s),Number(c)?Math.round(parseFloat(`0.${c}`)*1e3):0));if(u.setUTCFullYear(Number(n)),l.toUpperCase()!=`Z`){let[,e,t,n]=/([+-])(\d\d):(\d\d)/.exec(l)||[void 0,`+`,0,0],r=e===`-`?1:-1;u.setTime(u.getTime()+r*(Number(t)*60*60*1e3+Number(n)*60*1e3))}return u},On=e=>{if(e==null)return;if(typeof e!=`string`)throw TypeError(`RFC7231 timestamps must be strings.`);let t,n,r,i,a,o,s,c;if((c=Sn.exec(e))?[,t,n,r,i,a,o,s]=c:(c=Cn.exec(e))?([,t,n,r,i,a,o,s]=c,r=(Number(r)+1900).toString()):(c=wn.exec(e))&&([,n,t,i,a,o,s,r]=c),r&&o){let e=Date.UTC(Number(r),Tn.indexOf(n),Number(t),Number(i),Number(a),Number(o),s?Math.round(parseFloat(`0.${s}`)*1e3):0);kn(t,1,31),kn(i,0,23),kn(a,0,59),kn(o,0,60);let c=new Date(e);return c.setUTCFullYear(Number(r)),c}throw TypeError(`Invalid RFC7231 date-time value ${e}.`)};function kn(e,t,n){let r=Number(e);if(rn)throw Error(`Value ${r} out of range [${t}, ${n}]`)}function An(e,t,n){if(n<=0||!Number.isInteger(n))throw Error(`Invalid number of delimiters (`+n+`) for splitEvery.`);let r=e.split(t);if(n===1)return r;let i=[],a=``;for(let e=0;e{let t=e.length,n=[],r=!1,i,a=0;for(let o=0;o{e=e.trim();let t=e.length;return t<2?e:(e[0]===`"`&&e[t-1]===`"`&&(e=e.slice(1,t-1)),e.replace(/\\"/g,`"`))})},Mn=/^-?\d*(\.\d+)?$/,Nn=class e{string;type;constructor(e,t){if(this.string=e,this.type=t,!Mn.test(e))throw Error(`@smithy/core/serde - NumericValue must only contain [0-9], at most one decimal point ".", and an optional negation prefix "-".`)}toString(){return this.string}static[Symbol.hasInstance](t){if(!t||typeof t!=`object`)return!1;let n=t;return e.prototype.isPrototypeOf(t)||n.type===`bigDecimal`&&Mn.test(n.string)}},Pn=class{serdeContext;setSerdeContext(e){this.serdeContext=e}},Fn=`modulepreload`,In=function(e){return`/`+e},Ln={},Rn=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}r=o(t.map(t=>{if(t=In(t,n),t in Ln)return;Ln[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:Fn,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},zn=class extends Pn{options;compositeErrorRegistry;constructor(e){super(),this.options=e,this.compositeErrorRegistry=At.for(e.defaultNamespace);for(let t of e.errorTypeRegistries??[])this.compositeErrorRegistry.copyFrom(t)}getRequestType(){return i}getResponseType(){return ge}setSerdeContext(e){this.serdeContext=e,this.serializer.setSerdeContext(e),this.deserializer.setSerdeContext(e),this.getPayloadCodec()&&this.getPayloadCodec().setSerdeContext(e)}updateServiceEndpoint(e,t){if(`url`in t){e.protocol=t.url.protocol,e.hostname=t.url.hostname,e.port=t.url.port?Number(t.url.port):void 0,e.path=t.url.pathname,e.fragment=t.url.hash||void 0,e.username=t.url.username||void 0,e.password=t.url.password||void 0,e.query||={};for(let[n,r]of t.url.searchParams.entries())e.query[n]=r;if(t.headers)for(let[n,r]of Object.entries(t.headers))e.headers[n]=r.join(`, `);return e}else{if(e.protocol=t.protocol,e.hostname=t.hostname,e.port=t.port?Number(t.port):void 0,e.path=t.path,e.query={...t.query},t.headers)for(let[n,r]of Object.entries(t.headers))e.headers[n]=r;return e}}setHostPrefix(e,t,n){if(this.serdeContext?.disableHostPrefix)return;let r=p.of(t.input),i=Ct(t.traits??{});if(i.endpoint){let t=i.endpoint?.[0];if(typeof t==`string`){let i=[...r.structIterator()].filter(([,e])=>e.getMergedTraits().hostLabel);for(let[e]of i){let r=n[e];if(typeof r!=`string`)throw Error(`@smithy/core/schema - ${e} in input must be a string as hostLabel.`);t=t.replace(`{${e}}`,r)}e.hostname=t+e.hostname}}}deserializeMetadata(e){return{httpStatusCode:e.statusCode,requestId:e.headers[`x-amzn-requestid`]??e.headers[`x-amzn-request-id`]??e.headers[`x-amz-request-id`],extendedRequestId:e.headers[`x-amz-id-2`],cfId:e.headers[`x-amz-cf-id`]}}async serializeEventStream({eventStream:e,requestSchema:t,initialRequest:n}){return(await this.loadEventStreamCapability()).serializeEventStream({eventStream:e,requestSchema:t,initialRequest:n})}async deserializeEventStream({response:e,responseSchema:t,initialResponseContainer:n}){return(await this.loadEventStreamCapability()).deserializeEventStream({response:e,responseSchema:t,initialResponseContainer:n})}async loadEventStreamCapability(){let{EventStreamSerde:e}=await Rn(async()=>{let{EventStreamSerde:e}=await import(`./event-streams.js`);return{EventStreamSerde:e}},__vite__mapDeps([0,1,2]));return new e({marshaller:this.getEventStreamMarshaller(),serializer:this.serializer,deserializer:this.deserializer,serdeContext:this.serdeContext,defaultContentType:this.getDefaultContentType()})}getDefaultContentType(){throw Error(`@smithy/core/protocols - ${this.constructor.name} getDefaultContentType() implementation missing.`)}async deserializeHttpMessage(e,t,n,r,i){return[]}getEventStreamMarshaller(){let e=this.serdeContext;if(!e.eventStreamMarshaller)throw Error(`@smithy/core - HttpProtocol: eventStreamMarshaller missing in serdeContext.`);return e.eventStreamMarshaller}},Bn=class extends zn{async serializeRequest(e,t,n){let r=t&&typeof t==`object`?t:{},a=this.serializer,o={},s={},c=await n.endpoint(),l=p.of(e?.input),u=[],d=[],ee=!1,te,f=new i({protocol:``,hostname:``,port:void 0,path:``,fragment:void 0,query:o,headers:s,body:void 0});if(c){this.updateServiceEndpoint(f,c),this.setHostPrefix(f,e,r);let t=Ct(e.traits);if(t.http){f.method=t.http[0];let[e,n]=t.http[1].split(`?`);f.path==`/`?f.path=e:f.path+=e;let r=new URLSearchParams(n??``);Object.assign(o,Object.fromEntries(r))}}for(let[e,t]of l.structIterator()){let n=t.getMergedTraits()??{},i=r[e];if(i==null&&!t.isIdempotencyToken()){if(n.httpLabel&&(f.path.includes(`{${e}+}`)||f.path.includes(`{${e}}`)))throw Error(`No value provided for input HTTP label: ${e}.`);continue}if(n.httpPayload)t.isStreaming()?t.isStructSchema()?r[e]&&(te=await this.serializeEventStream({eventStream:r[e],requestSchema:l})):te=i:(a.write(t,i),te=a.flush());else if(n.httpLabel){a.write(t,i);let n=a.flush();f.path.includes(`{${e}+}`)?f.path=f.path.replace(`{${e}+}`,n.split(`/`).map(ut).join(`/`)):f.path.includes(`{${e}}`)&&(f.path=f.path.replace(`{${e}}`,ut(n)))}else if(n.httpHeader)a.write(t,i),s[n.httpHeader.toLowerCase()]=String(a.flush());else if(typeof n.httpPrefixHeaders==`string`)for(let[e,r]of Object.entries(i)){let i=n.httpPrefixHeaders+e;a.write([t.getValueSchema(),{httpHeader:i}],r),s[i.toLowerCase()]=a.flush()}else n.httpQuery||n.httpQueryParams?this.serializeQuery(t,i,o):(ee=!0,u.push(e),d.push(t))}if(ee&&r){let[e,t]=(l.getName(!0)??`#Unknown`).split(`#`),n=l.getSchema()[6],i=[3,e,t,l.getMergedTraits(),u,d,void 0];n?i[6]=n:i.pop(),a.write(i,r),te=a.flush()}return f.headers=s,f.query=o,f.body=te,f}serializeQuery(e,t,n){let r=this.serializer,i=e.getMergedTraits();if(i.httpQueryParams){for(let[r,a]of Object.entries(t))if(!(r in n)){let t=e.getValueSchema();Object.assign(t.getMergedTraits(),{...i,httpQuery:r,httpQueryParams:void 0}),this.serializeQuery(t,a,n)}return}if(e.isListSchema()){let a=!!e.getMergedTraits().sparse,o=[];for(let n of t){r.write([e.getValueSchema(),i],n);let t=r.flush();(a||t!==void 0)&&o.push(t)}n[i.httpQuery]=o}else r.write([e,i],t),n[i.httpQuery]=r.flush()}async deserializeResponse(e,t,n){let r=this.deserializer,i=p.of(e.output),a={};if(n.statusCode>=300){let i=await lt(n.body,t);throw i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n)),Error(`@smithy/core/protocols - HTTP Protocol error handler failed to throw.`)}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=await this.deserializeHttpMessage(i,t,n,a);if(o.length){let e=await lt(n.body,t);if(e.byteLength>0){let t=await r.read(i,e);for(let e of o)t[e]!=null&&(a[e]=t[e])}}else o.discardResponseBody&&await lt(n.body,t);return a.$metadata=this.deserializeMetadata(n),a}async deserializeHttpMessage(e,t,n,r,i){let a;a=r instanceof Set?i:r;let o=!0,s=this.deserializer,c=p.of(e),l=[];for(let[e,r]of c.structIterator()){let i=r.getMemberTraits();if(i.httpPayload){if(o=!1,r.isStreaming())r.isStructSchema()?a[e]=await this.deserializeEventStream({response:n,responseSchema:c}):a[e]=ot(n.body);else if(n.body){let i=await lt(n.body,t);i.byteLength>0&&(a[e]=await s.read(r,i))}}else if(i.httpHeader){let t=String(i.httpHeader).toLowerCase(),o=n.headers[t];if(o!=null)if(r.isListSchema()){let n=r.getValueSchema();n.getMergedTraits().httpHeader=t;let i;i=n.isTimestampSchema()&&n.getSchema()===4?An(o,`,`,2):jn(o);let c=[];for(let e of i)c.push(await s.read(n,e.trim()));a[e]=c}else a[e]=await s.read(r,o)}else if(i.httpPrefixHeaders!==void 0){a[e]={};for(let[t,o]of Object.entries(n.headers))if(t.startsWith(i.httpPrefixHeaders)){let n=r.getValueSchema();n.getMergedTraits().httpHeader=t,a[e][t.slice(i.httpPrefixHeaders.length)]=await s.read(n,o)}}else i.httpResponseCode?a[e]=n.statusCode:l.push(e)}return l.discardResponseBody=o,l}},Vn=class extends zn{async serializeRequest(e,t,n){let r=this.serializer,a={},o={},s=await n.endpoint(),c=p.of(e?.input),l=c.getSchema(),u,d=t&&typeof t==`object`?t:{},ee=new i({protocol:``,hostname:``,port:void 0,path:`/`,fragment:void 0,query:a,headers:o,body:void 0});if(s&&(this.updateServiceEndpoint(ee,s),this.setHostPrefix(ee,e,d)),d){let e=c.getEventStreamMember();if(e){if(d[e]){let t={};for(let[n,i]of c.structIterator())n!==e&&d[n]&&(r.write(i,d[n]),t[n]=r.flush());u=await this.serializeEventStream({eventStream:d[e],requestSchema:c,initialRequest:t})}}else r.write(l,d),u=r.flush()}return ee.headers=Object.assign(ee.headers,o),ee.query=a,ee.body=u,ee.method=`POST`,ee}async deserializeResponse(e,t,n){let r=this.deserializer,i=p.of(e.output),a={};if(n.statusCode>=300){let i=await lt(n.body,t);throw i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n)),Error(`@smithy/core/protocols - RPC Protocol error handler failed to throw.`)}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=i.getEventStreamMember();if(o)a[o]=await this.deserializeEventStream({response:n,responseSchema:i,initialResponseContainer:a});else{let e=await lt(n.body,t);e.byteLength>0&&Object.assign(a,await r.read(i,e))}return a.$metadata=this.deserializeMetadata(n),a}};function Hn(e,t){if(t.timestampFormat.useTrait&&e.isTimestampSchema()&&(e.getSchema()===5||e.getSchema()===6||e.getSchema()===7))return e.getSchema();let{httpLabel:n,httpPrefixHeaders:r,httpHeader:i,httpQuery:a}=e.getMergedTraits();return(t.httpBindings?typeof r==`string`||i?6:a||n?5:void 0:void 0)??t.timestampFormat.default}var Un=class extends Pn{settings;constructor(e){super(),this.settings=e}read(e,t){let n=p.of(e);if(n.isListSchema())return jn(t).map(e=>this.read(n.getValueSchema(),e));if(n.isBlobSchema())return(this.serdeContext?.base64Decoder??Ue)(t);if(n.isTimestampSchema())switch(Hn(n,this.settings)){case 5:return Dn(t);case 6:return On(t);case 7:return En(t);default:return console.warn(`Missing timestamp format, parsing value with Date constructor:`,t),new Date(t)}if(n.isStringSchema()){let e=n.getMergedTraits().mediaType,r=t;if(e)return n.getMergedTraits().httpHeader&&(r=this.base64ToUtf8(r)),(e===`application/json`||e.endsWith(`+json`))&&(r=mn.from(r)),r}return n.isNumericSchema()?Number(t):n.isBigIntegerSchema()?BigInt(t):n.isBigDecimalSchema()?new Nn(t,`bigDecimal`):n.isBooleanSchema()?String(t).toLowerCase()===`true`:t}base64ToUtf8(e){return(this.serdeContext?.utf8Encoder??ce)((this.serdeContext?.base64Decoder??Ue)(e))}},Wn=class extends Pn{codecDeserializer;stringDeserializer;constructor(e,t){super(),this.codecDeserializer=e,this.stringDeserializer=new Un(t)}setSerdeContext(e){this.stringDeserializer.setSerdeContext(e),this.codecDeserializer.setSerdeContext(e),this.serdeContext=e}read(e,t){let n=p.of(e),r=n.getMergedTraits(),i=this.serdeContext?.utf8Encoder??ce;if(r.httpHeader||r.httpResponseCode)return this.stringDeserializer.read(n,i(t));if(r.httpPayload){if(n.isBlobSchema()){let e=this.serdeContext?.utf8Decoder??se;return typeof t==`string`?e(t):t}else if(n.isStringSchema())return`byteLength`in t?i(t):t}return this.codecDeserializer.read(n,t)}},Gn=class extends Pn{settings;stringBuffer=``;constructor(e){super(),this.settings=e}write(e,t){let n=p.of(e);switch(typeof t){case`object`:if(t===null){this.stringBuffer=`null`;return}if(n.isTimestampSchema()){if(!(t instanceof Date))throw Error(`@smithy/core/protocols - received non-Date value ${t} when schema expected Date in ${n.getName(!0)}`);switch(Hn(n,this.settings)){case 5:this.stringBuffer=t.toISOString().replace(`.000Z`,`Z`);break;case 6:this.stringBuffer=Jt(t);break;case 7:this.stringBuffer=String(t.getTime()/1e3);break;default:console.warn(`Missing timestamp format, using epoch seconds`,t),this.stringBuffer=String(t.getTime()/1e3)}return}if(n.isBlobSchema()&&`byteLength`in t){this.stringBuffer=(this.serdeContext?.base64Encoder??We)(t);return}if(n.isListSchema()&&Array.isArray(t)){let e=``;for(let r of t){this.write([n.getValueSchema(),n.getMergedTraits()],r);let t=this.flush(),i=n.getValueSchema().isTimestampSchema()?t:hn(t);e!==``&&(e+=`, `),e+=i}this.stringBuffer=e;return}this.stringBuffer=JSON.stringify(t,null,2);break;case`string`:let e=n.getMergedTraits().mediaType,r=t;if(e&&((e===`application/json`||e.endsWith(`+json`))&&(r=mn.from(r)),n.getMergedTraits().httpHeader)){this.stringBuffer=(this.serdeContext?.base64Encoder??We)(r.toString());return}this.stringBuffer=t;break;default:n.isIdempotencyToken()?this.stringBuffer=pn():this.stringBuffer=String(t)}}flush(){let e=this.stringBuffer;return this.stringBuffer=``,e}},Kn=class{codecSerializer;stringSerializer;buffer;constructor(e,t,n=new Gn(t)){this.codecSerializer=e,this.stringSerializer=n}setSerdeContext(e){this.codecSerializer.setSerdeContext(e),this.stringSerializer.setSerdeContext(e)}write(e,t){let n=p.of(e),r=n.getMergedTraits();if(r.httpHeader||r.httpLabel||r.httpQuery){this.stringSerializer.write(n,t),this.buffer=this.stringSerializer.flush();return}return this.codecSerializer.write(n,t)}flush(){if(this.buffer!==void 0){let e=this.buffer;return this.buffer=void 0,e}return this.codecSerializer.flush()}};function qn(e,t,n){e.__smithy_context?e.__smithy_context.features||(e.__smithy_context.features={}):e.__smithy_context={features:{}},e.__smithy_context.features[t]=n}var Jn=class{authSchemes=new Map;constructor(e){for(let[t,n]of Object.entries(e))n!==void 0&&this.authSchemes.set(t,n)}getIdentityProvider(e){return this.authSchemes.get(e)}},Yn=(e=>function(t){return Xn(t)&&t.expiration.getTime()-Date.now()e.expiration!==void 0,Zn=(e,t,n)=>{if(e===void 0)return;let r=typeof e==`function`?e:async()=>Promise.resolve(e),i,a,o,s=!1,c=async e=>{a||=r(e);try{i=await a,o=!0,s=!1}finally{a=void 0}return i};return t===void 0?async e=>((!o||e?.forceRefresh)&&(i=await c(e)),i):async e=>((!o||e?.forceRefresh)&&(i=await c(e)),s?i:n(i)?(t(i)&&await c(e),i):(s=!0,i))};function Qn(e){return e===void 0?!0:typeof e==`string`&&e.length<=50}function $n(e){let t=ze(e.userAgentAppId??void 0),{customUserAgent:n}=e;return Object.assign(e,{customUserAgent:typeof n==`string`?[[n]]:n,userAgentAppId:async()=>{let n=await t();if(!Qn(n)){let t=e.logger?.constructor?.name===`NoOpLogger`||!e.logger?console:e.logger;typeof n==`string`?n.length>50&&t?.warn(`The provided userAgentAppId exceeds the maximum length of 50 characters.`):t?.warn(`userAgentAppId must be a string or undefined.`)}return n}})}var er=class{capacity;data=new Map;parameters=[];constructor({size:e,params:t}){this.capacity=e??50,t&&(this.parameters=t)}get(e,t){let n=this.hash(e);if(n===!1)return t();if(!this.data.has(n)){if(this.data.size>this.capacity+10){let e=this.data.keys(),t=0;for(;;){let{value:n,done:r}=e.next();if(this.data.delete(n),r||++t>10)break}}this.data.set(n,t())}return this.data.get(n)}size(){return this.data.size}hash(e){let t=``,{parameters:n}=this;if(n.length===0)return!1;for(let r of n){let n=String(e[r]??``);if(n.includes(`|;`))return!1;t+=n+`|;`}return t}},tr=RegExp(`^(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}$`),nr=e=>tr.test(e)||e.startsWith(`[`)&&e.endsWith(`]`),rr=RegExp(`^(?!.*-$)(?!-)[a-zA-Z0-9-]{1,63}$`),ir=(e,t=!1)=>{if(!t)return rr.test(e);let n=e.split(`.`);for(let e of n)if(!ir(e))return!1;return!0},ar={},or=`endpoints`;function sr(e){return typeof e!=`object`||!e?e:`ref`in e?`$${sr(e.ref)}`:`fn`in e?`${e.fn}(${(e.argv||[]).map(sr).join(`, `)})`:JSON.stringify(e,null,2)}var cr=class extends Error{constructor(e){super(e),this.name=`EndpointError`}},lr=(e,t)=>e===t,ur=e=>{let t=e.split(`.`),n=[];for(let r of t){let t=r.indexOf(`[`);if(t!==-1){if(r.indexOf(`]`)!==r.length-1)throw new cr(`Path: '${e}' does not end with ']'`);let i=r.slice(t+1,-1);if(Number.isNaN(parseInt(i)))throw new cr(`Invalid array index: '${i}' in path: '${e}'`);t!==0&&n.push(r.slice(0,t)),n.push(i)}else n.push(r)}return n},dr=(e,t)=>ur(t).reduce((n,r)=>{if(typeof n!=`object`)throw new cr(`Index '${r}' in '${t}' not found in '${JSON.stringify(e)}'`);return Array.isArray(n)?n[parseInt(r)]:n[r]},e),fr=e=>e!=null,pr=e=>!e,mr={[pe.HTTP]:80,[pe.HTTPS]:443},hr={booleanEquals:lr,getAttr:dr,isSet:fr,isValidHostLabel:ir,not:pr,parseURL:e=>{let t=(()=>{try{if(e instanceof URL)return e;if(typeof e==`object`&&`hostname`in e){let{hostname:t,port:n,protocol:r=``,path:i=``,query:a={}}=e,o=new URL(`${r}//${t}${n?`:${n}`:``}${i}`);return o.search=Object.entries(a).map(([e,t])=>`${e}=${t}`).join(`&`),o}return new URL(e)}catch{return null}})();if(!t)return console.error(`Unable to parse ${JSON.stringify(e)} as a whatwg URL.`),null;let n=t.href,{host:r,hostname:i,pathname:a,protocol:o,search:s}=t;if(s)return null;let c=o.slice(0,-1);if(!Object.values(pe).includes(c))return null;let l=nr(i);return{scheme:c,authority:`${r}${n.includes(`${r}:${mr[c]}`)||typeof e==`string`&&e.includes(`${r}:${mr[c]}`)?`:${mr[c]}`:``}`,path:a,normalizedPath:a.endsWith(`/`)?a:`${a}/`,isIp:l}},stringEquals:(e,t)=>e===t,substring:(e,t,n,r)=>t>=n||e.lengthencodeURIComponent(e).replace(/[!*'()]/g,e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`)},gr=(e,t)=>{let n=[],r={...t.endpointParams,...t.referenceRecord},i=0;for(;i({...t.endpointParams,...t.referenceRecord})[e],vr=(e,t,n)=>{if(typeof e==`string`)return gr(e,n);if(e.fn)return br.callFunction(e,n);if(e.ref)return _r(e,n);throw new cr(`'${t}': ${String(e)} is not a string, function or reference.`)},yr=({fn:e,argv:t},n)=>{let r=t.map(e=>[`boolean`,`number`].includes(typeof e)?e:br.evaluateExpression(e,`arg`,n)),i=e.split(`.`);return i[0]in ar&&i[1]!=null?ar[i[0]][i[1]](...r):hr[e](...r)},br={evaluateExpression:vr,callFunction:yr},xr=({assign:e,...t},n)=>{if(e&&e in n.referenceRecord)throw new cr(`'${e}' is already defined in Reference Record.`);let r=yr(t,n);return n.logger?.debug?.(`${or} evaluateCondition: ${sr(t)} = ${sr(r)}`),{result:r===``?!0:!!r,...e!=null&&{toAssign:{name:e,value:r}}}},Sr=(e=[],t)=>{let n={};for(let r of e){let{result:e,toAssign:i}=xr(r,{...t,referenceRecord:{...t.referenceRecord,...n}});if(!e)return{result:e};i&&(n[i.name]=i.value,t.logger?.debug?.(`${or} assign: ${i.name} := ${sr(i.value)}`))}return{result:!0,referenceRecord:n}},Cr=(e,t)=>Object.entries(e).reduce((e,[n,r])=>({...e,[n]:r.map(e=>{let r=vr(e,`Header value entry`,t);if(typeof r!=`string`)throw new cr(`Header '${n}' value '${r}' is not a string`);return r})}),{}),wr=(e,t)=>Object.entries(e).reduce((e,[n,r])=>({...e,[n]:Er.getEndpointProperty(r,t)}),{}),Tr=(e,t)=>{if(Array.isArray(e))return e.map(e=>Tr(e,t));switch(typeof e){case`string`:return gr(e,t);case`object`:if(e===null)throw new cr(`Unexpected endpoint property: ${e}`);return Er.getEndpointProperties(e,t);case`boolean`:return e;default:throw new cr(`Unexpected endpoint property type: ${typeof e}`)}},Er={getEndpointProperty:Tr,getEndpointProperties:wr},Dr=(e,t)=>{let n=vr(e,`Endpoint URL`,t);if(typeof n==`string`)try{return new URL(n)}catch(e){throw console.error(`Failed to construct URL with ${n}`,e),e}throw new cr(`Endpoint URL must be a string, got ${typeof n}`)},Or=(e,t)=>{let{conditions:n,endpoint:r}=e,{result:i,referenceRecord:a}=Sr(n,t);if(!i)return;let o={...t,referenceRecord:{...t.referenceRecord,...a}},{url:s,properties:c,headers:l}=r;return t.logger?.debug?.(`${or} Resolving endpoint from template: ${sr(r)}`),{...l!=null&&{headers:Cr(l,o)},...c!=null&&{properties:wr(c,o)},url:Dr(s,o)}},kr=(e,t)=>{let{conditions:n,error:r}=e,{result:i,referenceRecord:a}=Sr(n,t);if(i)throw new cr(vr(r,`Error`,{...t,referenceRecord:{...t.referenceRecord,...a}}))},Ar=(e,t)=>{for(let n of e)if(n.type===`endpoint`){let e=Or(n,t);if(e)return e}else if(n.type===`error`)kr(n,t);else if(n.type===`tree`){let e=jr.evaluateTreeRule(n,t);if(e)return e}else throw new cr(`Unknown endpoint rule: ${n}`);throw new cr(`Rules evaluation failed`)},jr={evaluateRules:Ar,evaluateTreeRule:(e,t)=>{let{conditions:n,rules:r}=e,{result:i,referenceRecord:a}=Sr(n,t);if(i)return jr.evaluateRules(r,{...t,referenceRecord:{...t.referenceRecord,...a}})}},Mr=(e,t)=>{let{endpointParams:n,logger:r}=t,{parameters:i,rules:a}=e;t.logger?.debug?.(`${or} Initial EndpointParams: ${sr(n)}`);let o=Object.entries(i).filter(([,e])=>e.default!=null).map(([e,t])=>[e,t.default]);if(o.length>0)for(let[e,t]of o)n[e]=n[e]??t;let s=Object.entries(i).filter(([,e])=>e.required).map(([e])=>e);for(let e of s)if(n[e]==null)throw new cr(`Missing required parameter: '${e}'`);let c=Ar(a,{endpointParams:n,logger:r,referenceRecord:{}});return t.logger?.debug?.(`${or} Resolved endpoint: ${sr(c)}`),c},Nr=(e,t=!1)=>{if(t){for(let t of e.split(`.`))if(!Nr(t))return!1;return!0}return!(!ir(e)||e.length<3||e.length>63||e!==e.toLowerCase()||nr(e))},Pr=`:`,Fr=`/`,Ir=e=>{let t=e.split(Pr);if(t.length<6)return null;let[n,r,i,a,o,...s]=t;return n!==`arn`||r===``||i===``||s.join(Pr)===``?null:{partition:r,service:i,region:a,accountId:o,resourceId:s.map(e=>e.split(Fr)).flat()}},Lr={partitions:[{id:`aws`,outputs:{dnsSuffix:`amazonaws.com`,dualStackDnsSuffix:`api.aws`,implicitGlobalRegion:`us-east-1`,name:`aws`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^(us|eu|ap|sa|ca|me|af|il|mx)\\-\\w+\\-\\d+$`,regions:{"af-south-1":{description:`Africa (Cape Town)`},"ap-east-1":{description:`Asia Pacific (Hong Kong)`},"ap-east-2":{description:`Asia Pacific (Taipei)`},"ap-northeast-1":{description:`Asia Pacific (Tokyo)`},"ap-northeast-2":{description:`Asia Pacific (Seoul)`},"ap-northeast-3":{description:`Asia Pacific (Osaka)`},"ap-south-1":{description:`Asia Pacific (Mumbai)`},"ap-south-2":{description:`Asia Pacific (Hyderabad)`},"ap-southeast-1":{description:`Asia Pacific (Singapore)`},"ap-southeast-2":{description:`Asia Pacific (Sydney)`},"ap-southeast-3":{description:`Asia Pacific (Jakarta)`},"ap-southeast-4":{description:`Asia Pacific (Melbourne)`},"ap-southeast-5":{description:`Asia Pacific (Malaysia)`},"ap-southeast-6":{description:`Asia Pacific (New Zealand)`},"ap-southeast-7":{description:`Asia Pacific (Thailand)`},"aws-global":{description:`aws global region`},"ca-central-1":{description:`Canada (Central)`},"ca-west-1":{description:`Canada West (Calgary)`},"eu-central-1":{description:`Europe (Frankfurt)`},"eu-central-2":{description:`Europe (Zurich)`},"eu-north-1":{description:`Europe (Stockholm)`},"eu-south-1":{description:`Europe (Milan)`},"eu-south-2":{description:`Europe (Spain)`},"eu-west-1":{description:`Europe (Ireland)`},"eu-west-2":{description:`Europe (London)`},"eu-west-3":{description:`Europe (Paris)`},"il-central-1":{description:`Israel (Tel Aviv)`},"me-central-1":{description:`Middle East (UAE)`},"me-south-1":{description:`Middle East (Bahrain)`},"mx-central-1":{description:`Mexico (Central)`},"sa-east-1":{description:`South America (Sao Paulo)`},"us-east-1":{description:`US East (N. Virginia)`},"us-east-2":{description:`US East (Ohio)`},"us-west-1":{description:`US West (N. California)`},"us-west-2":{description:`US West (Oregon)`}}},{id:`aws-cn`,outputs:{dnsSuffix:`amazonaws.com.cn`,dualStackDnsSuffix:`api.amazonwebservices.com.cn`,implicitGlobalRegion:`cn-northwest-1`,name:`aws-cn`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^cn\\-\\w+\\-\\d+$`,regions:{"aws-cn-global":{description:`aws-cn global region`},"cn-north-1":{description:`China (Beijing)`},"cn-northwest-1":{description:`China (Ningxia)`}}},{id:`aws-eusc`,outputs:{dnsSuffix:`amazonaws.eu`,dualStackDnsSuffix:`api.amazonwebservices.eu`,implicitGlobalRegion:`eusc-de-east-1`,name:`aws-eusc`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^eusc\\-(de)\\-\\w+\\-\\d+$`,regions:{"eusc-de-east-1":{description:`AWS European Sovereign Cloud (Germany)`}}},{id:`aws-iso`,outputs:{dnsSuffix:`c2s.ic.gov`,dualStackDnsSuffix:`api.aws.ic.gov`,implicitGlobalRegion:`us-iso-east-1`,name:`aws-iso`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^us\\-iso\\-\\w+\\-\\d+$`,regions:{"aws-iso-global":{description:`aws-iso global region`},"us-iso-east-1":{description:`US ISO East`},"us-iso-west-1":{description:`US ISO WEST`}}},{id:`aws-iso-b`,outputs:{dnsSuffix:`sc2s.sgov.gov`,dualStackDnsSuffix:`api.aws.scloud`,implicitGlobalRegion:`us-isob-east-1`,name:`aws-iso-b`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^us\\-isob\\-\\w+\\-\\d+$`,regions:{"aws-iso-b-global":{description:`aws-iso-b global region`},"us-isob-east-1":{description:`US ISOB East (Ohio)`},"us-isob-west-1":{description:`US ISOB West`}}},{id:`aws-iso-e`,outputs:{dnsSuffix:`cloud.adc-e.uk`,dualStackDnsSuffix:`api.cloud-aws.adc-e.uk`,implicitGlobalRegion:`eu-isoe-west-1`,name:`aws-iso-e`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^eu\\-isoe\\-\\w+\\-\\d+$`,regions:{"aws-iso-e-global":{description:`aws-iso-e global region`},"eu-isoe-west-1":{description:`EU ISOE West`}}},{id:`aws-iso-f`,outputs:{dnsSuffix:`csp.hci.ic.gov`,dualStackDnsSuffix:`api.aws.hci.ic.gov`,implicitGlobalRegion:`us-isof-south-1`,name:`aws-iso-f`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^us\\-isof\\-\\w+\\-\\d+$`,regions:{"aws-iso-f-global":{description:`aws-iso-f global region`},"us-isof-east-1":{description:`US ISOF EAST`},"us-isof-south-1":{description:`US ISOF SOUTH`}}},{id:`aws-us-gov`,outputs:{dnsSuffix:`amazonaws.com`,dualStackDnsSuffix:`api.aws`,implicitGlobalRegion:`us-gov-west-1`,name:`aws-us-gov`,supportsDualStack:!0,supportsFIPS:!0},regionRegex:`^us\\-gov\\-\\w+\\-\\d+$`,regions:{"aws-us-gov-global":{description:`aws-us-gov global region`},"us-gov-east-1":{description:`AWS GovCloud (US-East)`},"us-gov-west-1":{description:`AWS GovCloud (US-West)`}}}],version:`1.1`},Rr=``,zr=e=>{let{partitions:t}=Lr;for(let n of t){let{regions:t,outputs:r}=n;for(let[n,i]of Object.entries(t))if(n===e)return{...r,...i}}for(let n of t){let{regionRegex:t,outputs:r}=n;if(new RegExp(t).test(e))return{...r}}let n=t.find(e=>e.id===`aws`);if(!n)throw Error(`Provided region was not found in the partition array or regex, and default partition with id 'aws' doesn't exist.`);return{...n.outputs}},Br=()=>Rr,Vr={isVirtualHostableS3Bucket:Nr,parseArn:Ir,partition:zr};ar.aws=Vr;function Hr(e,t,n){return e.$source||={},e.$source[t]=n,e}function Ur(e,t,n){e.__aws_sdk_context?e.__aws_sdk_context.features||(e.__aws_sdk_context.features={}):e.__aws_sdk_context={features:{}},e.__aws_sdk_context.features[t]=n}var Wr;(function(e){e.STANDARD=`standard`,e.ADAPTIVE=`adaptive`})(Wr||={});var Gr=Wr.STANDARD,Kr=[`BandwidthLimitExceeded`,`EC2ThrottledException`,`LimitExceededException`,`PriorRequestNotComplete`,`ProvisionedThroughputExceededException`,`RequestLimitExceeded`,`RequestThrottled`,`RequestThrottledException`,`SlowDown`,`ThrottledException`,`Throttling`,`ThrottlingException`,`TooManyRequestsException`,`TransactionInProgressException`],qr=[`TimeoutError`,`RequestTimeout`,`RequestTimeoutException`],Jr=[500,502,503,504],Yr=[`ECONNRESET`,`ECONNREFUSED`,`EPIPE`,`ETIMEDOUT`],Xr=[`EHOSTUNREACH`,`ENETUNREACH`,`ENOTFOUND`],Zr=e=>e?.$retryable!==void 0,Qr=e=>e.$metadata?.clockSkewCorrected,$r=e=>{let t=new Set([`Failed to fetch`,`NetworkError when attempting to fetch resource`,`The Internet connection appears to be offline`,`Load failed`,`Network request failed`]);return e&&e instanceof TypeError?t.has(e.message):!1},ei=e=>e.$metadata?.httpStatusCode===429||Kr.includes(e.name)||e.$retryable?.throttling==1,ti=(e,t=0)=>Zr(e)||Qr(e)||qr.includes(e.name)||Yr.includes(e?.code||``)||Xr.includes(e?.code||``)||Jr.includes(e.$metadata?.httpStatusCode||0)||$r(e)||e.cause!==void 0&&t<=10&&ti(e.cause,t+1),ni=e=>{if(e.$metadata?.httpStatusCode!==void 0){let t=e.$metadata.httpStatusCode;return 500<=t&&t<=599&&!ti(e)}return!1},ri=class e{static setTimeoutFn=setTimeout;beta;minCapacity;minFillRate;scaleConstant;smooth;enabled=!1;availableTokens=0;lastMaxRate=0;measuredTxRate=0;requestCount=0;fillRate;lastThrottleTime;lastTimestamp=0;lastTxRateBucket;maxCapacity;timeWindow=0;constructor(e){this.beta=e?.beta??.7,this.minCapacity=e?.minCapacity??1,this.minFillRate=e?.minFillRate??.5,this.scaleConstant=e?.scaleConstant??.4,this.smooth=e?.smooth??.8,this.lastThrottleTime=this.getCurrentTimeInSeconds(),this.lastTxRateBucket=Math.floor(this.getCurrentTimeInSeconds()),this.fillRate=this.minFillRate,this.maxCapacity=this.minCapacity}getCurrentTimeInSeconds(){return Date.now()/1e3}async getSendToken(){return this.acquireTokenBucket(1)}async acquireTokenBucket(t){if(this.enabled){if(this.refillTokenBucket(),t>this.availableTokens){let n=(t-this.availableTokens)/this.fillRate*1e3;await new Promise(t=>e.setTimeoutFn(t,n))}this.availableTokens-=t}}refillTokenBucket(){let e=this.getCurrentTimeInSeconds();if(!this.lastTimestamp){this.lastTimestamp=e;return}let t=(e-this.lastTimestamp)*this.fillRate;this.availableTokens=Math.min(this.maxCapacity,this.availableTokens+t),this.lastTimestamp=e}updateClientSendingRate(e){let t;this.updateMeasuredRate();let n=e;if(n?.errorType===`THROTTLING`||ei(n?.error??e)){let e=this.enabled?Math.min(this.measuredTxRate,this.fillRate):this.measuredTxRate;this.lastMaxRate=e,this.calculateTimeWindow(),this.lastThrottleTime=this.getCurrentTimeInSeconds(),t=this.cubicThrottle(e),this.enableTokenBucket()}else this.calculateTimeWindow(),t=this.cubicSuccess(this.getCurrentTimeInSeconds());let r=Math.min(t,2*this.measuredTxRate);this.updateTokenBucketRate(r)}calculateTimeWindow(){this.timeWindow=this.getPrecise((this.lastMaxRate*(1-this.beta)/this.scaleConstant)**(1/3))}cubicThrottle(e){return this.getPrecise(e*this.beta)}cubicSuccess(e){return this.getPrecise(this.scaleConstant*(e-this.lastThrottleTime-this.timeWindow)**3+this.lastMaxRate)}enableTokenBucket(){this.enabled=!0}updateTokenBucketRate(e){this.refillTokenBucket(),this.fillRate=Math.max(e,this.minFillRate),this.maxCapacity=Math.max(e,this.minCapacity),this.availableTokens=Math.min(this.availableTokens,this.maxCapacity)}updateMeasuredRate(){let e=this.getCurrentTimeInSeconds(),t=Math.floor(e*2)/2;if(this.requestCount++,t>this.lastTxRateBucket){let e=this.requestCount/(t-this.lastTxRateBucket);this.measuredTxRate=this.getPrecise(e*this.smooth+this.measuredTxRate*(1-this.smooth)),this.requestCount=0,this.lastTxRateBucket=t}}getPrecise(e){return parseFloat(e.toFixed(8))}},ii=20*1e3,ai=`amz-sdk-invocation-id`,oi=`amz-sdk-request`,si=()=>{let e=100;return{computeNextBackoffDelay:t=>Math.floor(Math.min(ii,Math.random()*2**t*e)),setDelayBase:t=>{e=t}}},ci=({retryDelay:e,retryCount:t,retryCost:n})=>({getRetryCount:()=>t,getRetryDelay:()=>Math.min(ii,e),getRetryCost:()=>n}),li=class{maxAttempts;mode=Wr.STANDARD;capacity=500;retryBackoffStrategy=si();maxAttemptsProvider;constructor(e){this.maxAttempts=e,this.maxAttemptsProvider=typeof e==`function`?e:async()=>e}async acquireInitialRetryToken(e){return ci({retryDelay:100,retryCount:0})}async refreshRetryTokenForRetry(e,t){let n=await this.getMaxAttempts();if(this.shouldRetry(e,t,n)){let n=t.errorType;this.retryBackoffStrategy.setDelayBase(n===`THROTTLING`?500:100);let r=this.retryBackoffStrategy.computeNextBackoffDelay(e.getRetryCount()),i=t.retryAfterHint?Math.max(t.retryAfterHint.getTime()-Date.now()||0,r):r,a=this.getCapacityCost(n);return this.capacity-=a,ci({retryDelay:i,retryCount:e.getRetryCount()+1,retryCost:a})}throw Error(`No retry token available`)}recordSuccess(e){this.capacity=Math.max(500,this.capacity+(e.getRetryCost()??1))}getCapacity(){return this.capacity}async getMaxAttempts(){try{return await this.maxAttemptsProvider()}catch{return console.warn(`Max attempts provider could not resolve. Using default of 3`),3}}shouldRetry(e,t,n){return e.getRetryCount()+1=this.getCapacityCost(t.errorType)&&this.isRetryableError(t.errorType)}getCapacityCost(e){return e===`TRANSIENT`?10:5}isRetryableError(e){return e===`THROTTLING`||e===`TRANSIENT`}},ui=class{maxAttemptsProvider;rateLimiter;standardRetryStrategy;mode=Wr.ADAPTIVE;constructor(e,t){this.maxAttemptsProvider=e;let{rateLimiter:n}=t??{};this.rateLimiter=n??new ri,this.standardRetryStrategy=new li(e)}async acquireInitialRetryToken(e){return await this.rateLimiter.getSendToken(),this.standardRetryStrategy.acquireInitialRetryToken(e)}async refreshRetryTokenForRetry(e,t){return this.rateLimiter.updateClientSendingRate(t),this.standardRetryStrategy.refreshRetryTokenForRetry(e,t)}recordSuccess(e){this.rateLimiter.updateClientSendingRate({}),this.standardRetryStrategy.recordSuccess(e)}},di=/\d{12}\.ddb/;async function fi(e,t,n){if(n.request?.headers?.[`smithy-protocol`]===`rpc-v2-cbor`&&Ur(e,`PROTOCOL_RPC_V2_CBOR`,`M`),typeof t.retryStrategy==`function`){let n=await t.retryStrategy();if(typeof n.mode==`string`)switch(n.mode){case Wr.ADAPTIVE:Ur(e,`RETRY_MODE_ADAPTIVE`,`F`);break;case Wr.STANDARD:Ur(e,`RETRY_MODE_STANDARD`,`E`);break}}if(typeof t.accountIdEndpointMode==`function`){let n=e.endpointV2;switch(String(n?.url?.hostname).match(di)&&Ur(e,`ACCOUNT_ID_ENDPOINT`,`O`),await t.accountIdEndpointMode?.()){case`disabled`:Ur(e,`ACCOUNT_ID_MODE_DISABLED`,`Q`);break;case`preferred`:Ur(e,`ACCOUNT_ID_MODE_PREFERRED`,`P`);break;case`required`:Ur(e,`ACCOUNT_ID_MODE_REQUIRED`,`R`);break}}let r=e.__smithy_context?.selectedHttpAuthScheme?.identity;if(r?.$source){let t=r;t.accountId&&Ur(e,`RESOLVED_ACCOUNT_ID`,`T`);for(let[n,r]of Object.entries(t.$source??{}))Ur(e,n,r)}}var pi=`user-agent`,mi=`x-amz-user-agent`,hi=/[^!$%&'*+\-.^_`|~\w]/g,gi=/[^!$%&'*+\-.^_`|~\w#]/g,_i=1024;function vi(e){let t=``;for(let n in e){let r=e[n];if(t.length+r.length+1<=_i){t.length?t+=`,`+r:t+=r;continue}break}return t}var yi=e=>(t,n)=>async r=>{let{request:a}=r;if(!i.isInstance(a))return t(r);let{headers:o}=a,s=n?.userAgent?.map(bi)||[],c=(await e.defaultUserAgentProvider()).map(bi);await fi(n,e,r);let l=n;c.push(`m/${vi(Object.assign({},n.__smithy_context?.features,l.__aws_sdk_context?.features))}`);let u=e?.customUserAgent?.map(bi)||[],d=await e.userAgentAppId();d&&c.push(bi([`app`,`${d}`]));let ee=Br(),te=(ee?[ee]:[]).concat([...c,...s,...u]).join(` `),f=[...c.filter(e=>e.startsWith(`aws-sdk-`)),...u].join(` `);return e.runtime===`browser`?o[mi]=te:(f&&(o[mi]=o[`x-amz-user-agent`]?`${o[pi]} ${f}`:f),o[pi]=te),t({...r,request:a})},bi=e=>{let t=e[0].split(`/`).map(e=>e.replace(hi,`-`)).join(`/`),n=e[1]?.replace(gi,`-`),r=t.indexOf(`/`),i=t.substring(0,r),a=t.substring(r+1);return i===`api`&&(a=a.toLowerCase()),[i,a,n].filter(e=>e&&e.length>0).reduce((e,t,n)=>{switch(n){case 0:return t;case 1:return`${e}/${t}`;default:return`${e}#${t}`}},``)},xi={name:`getUserAgentMiddleware`,step:`build`,priority:`low`,tags:[`SET_USER_AGENT`,`USER_AGENT`],override:!0},Si=e=>({applyToStack:t=>{t.add(yi(e),xi)}}),Ci=new Set,wi=(e,t=ir)=>{if(!Ci.has(e)&&!t(e))if(e===`*`)console.warn(`@smithy/config-resolver WARN - Please use the caller region instead of "*". See "sigv4a" in https://github.com/aws/aws-sdk-js-v3/blob/main/supplemental-docs/CLIENTS.md.`);else throw Error(`Region not accepted: region="${e}" is not a valid hostname component.`);else Ci.add(e)},Ti=e=>typeof e==`string`&&(e.startsWith(`fips-`)||e.endsWith(`-fips`)),Ei=e=>Ti(e)?[`fips-aws-global`,`aws-fips`].includes(e)?`us-east-1`:e.replace(/fips-(dkr-|prod-)?|-fips/,``):e,Di=e=>{let{region:t,useFipsEndpoint:n}=e;if(!t)throw Error(`Region is missing`);return Object.assign(e,{region:async()=>{let e=Ei(typeof t==`function`?await t():t);return wi(e),e},useFipsEndpoint:async()=>Ti(typeof t==`string`?t:await t())?!0:typeof n==`function`?n():Promise.resolve(!!n)})},Oi=`content-length`;function ki(e){return t=>async n=>{let r=n.request;if(i.isInstance(r)){let{body:t,headers:n}=r;if(t&&Object.keys(n).map(e=>e.toLowerCase()).indexOf(Oi)===-1)try{let n=e(t);r.headers={...r.headers,[Oi]:String(n)}}catch{}}return t({...n,request:r})}}var Ai={step:`build`,tags:[`SET_CONTENT_LENGTH`,`CONTENT_LENGTH`],name:`contentLengthMiddleware`,override:!0},ji=e=>({applyToStack:t=>{t.add(ki(e.bodyLengthChecker),Ai)}}),Mi=async e=>{let t=e?.Bucket||``;if(typeof e.Bucket==`string`&&(e.Bucket=t.replace(/#/g,`%23`).replace(/\?/g,`%3F`)),Li(t)){if(e.ForcePathStyle===!0)throw Error(`Path-style addressing cannot be used with ARN buckets`)}else (!Ii(t)||t.indexOf(`.`)!==-1&&!String(e.Endpoint).startsWith(`http:`)||t.toLowerCase()!==t||t.length<3)&&(e.ForcePathStyle=!0);return e.DisableMultiRegionAccessPoints&&(e.disableMultiRegionAccessPoints=!0,e.DisableMRAP=!0),e},Ni=/^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/,Pi=/(\d+\.){3}\d+/,Fi=/\.\./,Ii=e=>Ni.test(e)&&!Pi.test(e)&&!Fi.test(e),Li=e=>{let[t,n,r,,,i]=e.split(`:`),a=t===`arn`&&e.split(`:`).length>=6,o=!!(a&&n&&r&&i);if(a&&!o)throw Error(`Invalid ARN: ${e} was an invalid ARN.`);return o},Ri=(e,t,n,r=!1)=>{let i=async()=>{let i;return i=r?n.clientContextParams?.[e]??n[e]??n[t]:n[e]??n[t],typeof i==`function`?i():i};return e===`credentialScope`||t===`CredentialScope`?async()=>{let e=typeof n.credentials==`function`?await n.credentials():n.credentials;return e?.credentialScope??e?.CredentialScope}:e===`accountId`||t===`AccountId`?async()=>{let e=typeof n.credentials==`function`?await n.credentials():n.credentials;return e?.accountId??e?.AccountId}:e===`endpoint`||t===`endpoint`?async()=>{if(n.isCustomEndpoint===!1)return;let e=await i();if(e&&typeof e==`object`){if(`url`in e)return e.url.href;if(`hostname`in e){let{protocol:t,hostname:n,port:r,path:i}=e;return`${t}//${n}${r?`:`+r:``}${i}`}}return e}:i},zi=async e=>void 0,Bi=e=>{if(typeof e==`object`){if(`url`in e){let t=gt(e.url);if(e.headers){t.headers={};for(let[n,r]of Object.entries(e.headers))t.headers[n.toLowerCase()]=r.join(`, `)}return t}return e}return gt(e)},Vi=async(e,t,n,r)=>{if(!n.isCustomEndpoint){let e;e=n.serviceConfiguredEndpoint?await n.serviceConfiguredEndpoint():await zi(n.serviceId),e&&(n.endpoint=()=>Promise.resolve(Bi(e)),n.isCustomEndpoint=!0)}let i=await Hi(e,t,n);if(typeof n.endpointProvider!=`function`)throw Error(`config.endpointProvider is not set.`);let a=n.endpointProvider(i,r);if(n.isCustomEndpoint&&n.endpoint){let e=await n.endpoint();if(e?.headers){a.headers??={};for(let[t,n]of Object.entries(e.headers))a.headers[t]=Array.isArray(n)?n:[n]}}return a},Hi=async(e,t,n)=>{let r={},i=t?.getEndpointParameterInstructions?.()||{};for(let[t,a]of Object.entries(i))switch(a.type){case`staticContextParams`:r[t]=a.value;break;case`contextParams`:r[t]=e[a.name];break;case`clientContextParams`:case`builtInParams`:r[t]=await Ri(a.name,t,n,a.type!==`builtInParams`)();break;case`operationContextParams`:r[t]=a.get(e);break;default:throw Error(`Unrecognized endpoint parameter instruction: `+JSON.stringify(a))}return Object.keys(i).length===0&&Object.assign(r,n),String(n.serviceId).toLowerCase()===`s3`&&await Mi(r),r},Ui=({config:e,instructions:t})=>(n,r)=>async i=>{e.isCustomEndpoint&&qn(r,`ENDPOINT_OVERRIDE`,`N`);let a=await Vi(i.input,{getEndpointParameterInstructions(){return t}},{...e},r);r.endpointV2=a,r.authSchemes=a.properties?.authSchemes;let o=r.authSchemes?.[0];if(o){r.signing_region=o.signingRegion,r.signing_service=o.signingName;let e=_e(r)?.selectedHttpAuthScheme?.httpAuthOption;e&&(e.signingProperties=Object.assign(e.signingProperties||{},{signing_region:o.signingRegion,signingRegion:o.signingRegion,signing_service:o.signingName,signingName:o.signingName,signingRegionSet:o.signingRegionSet},o.properties))}return n({...i})},Wi={step:`serialize`,tags:[`ENDPOINT_PARAMETERS`,`ENDPOINT_V2`,`ENDPOINT`],name:`endpointV2Middleware`,override:!0,relation:`before`,toMiddleware:{name:`serializerMiddleware`,step:`serialize`,tags:[`SERIALIZER`],override:!0}.name},Gi=(e,t)=>({applyToStack:n=>{n.addRelativeTo(Ui({config:e,instructions:t}),Wi)}}),Ki=e=>{let t=e.tls??!0,{endpoint:n,useDualstackEndpoint:r,useFipsEndpoint:i}=e,a=Object.assign(e,{endpoint:n==null?void 0:async()=>Bi(await f(n)()),tls:t,isCustomEndpoint:!!n,useDualstackEndpoint:f(r??!1),useFipsEndpoint:f(i??!1)}),o;return a.serviceConfiguredEndpoint=async()=>(e.serviceId&&!o&&(o=zi(e.serviceId)),o),a},qi=e=>e instanceof Error?e:e instanceof Object?Object.assign(Error(),e):Error(typeof e==`string`?e:`AWS SDK error wrapper for ${e}`),Ji=e=>{let{retryStrategy:t,retryMode:n}=e,r=f(e.maxAttempts??3),i=t?Promise.resolve(t):void 0,a=async()=>await f(n)()===Wr.ADAPTIVE?new ui(r):new li(r);return Object.assign(e,{maxAttempts:r,retryStrategy:()=>i??=a()})},Yi=(e,t)=>{let n=[];if(e&&n.push(e),t)for(let e of t)n.push(e);return n},Xi=(e,t)=>`${e||`anonymous`}${t&&t.length>0?` (a.k.a. ${t.join(`,`)})`:``}`,Zi=()=>{let e=[],t=[],n=!1,r=new Set,i=e=>e.sort((e,t)=>Qi[t.step]-Qi[e.step]||$i[t.priority||`normal`]-$i[e.priority||`normal`]),a=n=>{let i=!1,a=e=>{let t=Yi(e.name,e.aliases);if(t.includes(n)){i=!0;for(let e of t)r.delete(e);return!1}return!0};return e=e.filter(a),t=t.filter(a),i},o=n=>{let i=!1,a=e=>{if(e.middleware===n){i=!0;for(let t of Yi(e.name,e.aliases))r.delete(t);return!1}return!0};return e=e.filter(a),t=t.filter(a),i},s=n=>(e.forEach(e=>{n.add(e.middleware,{...e})}),t.forEach(e=>{n.addRelativeTo(e.middleware,{...e})}),n.identifyOnResolve?.(u.identifyOnResolve()),n),c=e=>{let t=[];return e.before.forEach(e=>{e.before.length===0&&e.after.length===0?t.push(e):t.push(...c(e))}),t.push(e),e.after.reverse().forEach(e=>{e.before.length===0&&e.after.length===0?t.push(e):t.push(...c(e))}),t},l=(n=!1)=>{let r=[],a=[],o={};return e.forEach(e=>{let t={...e,before:[],after:[]};for(let e of Yi(t.name,t.aliases))o[e]=t;r.push(t)}),t.forEach(e=>{let t={...e,before:[],after:[]};for(let e of Yi(t.name,t.aliases))o[e]=t;a.push(t)}),a.forEach(e=>{if(e.toMiddleware){let t=o[e.toMiddleware];if(t===void 0){if(n)return;throw Error(`${e.toMiddleware} is not found when adding ${Xi(e.name,e.aliases)} middleware ${e.relation} ${e.toMiddleware}`)}e.relation===`after`&&t.after.push(e),e.relation===`before`&&t.before.push(e)}}),i(r).map(c).reduce((e,t)=>(e.push(...t),e),[])},u={add:(t,n={})=>{let{name:i,override:a,aliases:o}=n,s={step:`initialize`,priority:`normal`,middleware:t,...n},c=Yi(i,o);if(c.length>0){if(c.some(e=>r.has(e))){if(!a)throw Error(`Duplicate middleware name '${Xi(i,o)}'`);for(let t of c){let n=e.findIndex(e=>e.name===t||e.aliases?.some(e=>e===t));if(n===-1)continue;let r=e[n];if(r.step!==s.step||s.priority!==r.priority)throw Error(`"${Xi(r.name,r.aliases)}" middleware with ${r.priority} priority in ${r.step} step cannot be overridden by "${Xi(i,o)}" middleware with ${s.priority} priority in ${s.step} step.`);e.splice(n,1)}}for(let e of c)r.add(e)}e.push(s)},addRelativeTo:(e,n)=>{let{name:i,override:a,aliases:o}=n,s={middleware:e,...n},c=Yi(i,o);if(c.length>0){if(c.some(e=>r.has(e))){if(!a)throw Error(`Duplicate middleware name '${Xi(i,o)}'`);for(let e of c){let n=t.findIndex(t=>t.name===e||t.aliases?.some(t=>t===e));if(n===-1)continue;let r=t[n];if(r.toMiddleware!==s.toMiddleware||r.relation!==s.relation)throw Error(`"${Xi(r.name,r.aliases)}" middleware ${r.relation} "${r.toMiddleware}" middleware cannot be overridden by "${Xi(i,o)}" middleware ${s.relation} "${s.toMiddleware}" middleware.`);t.splice(n,1)}}for(let e of c)r.add(e)}t.push(s)},clone:()=>s(Zi()),use:e=>{e.applyToStack(u)},remove:e=>typeof e==`string`?a(e):o(e),removeByTag:n=>{let i=!1,a=e=>{let{tags:t,name:a,aliases:o}=e;if(t&&t.includes(n)){let e=Yi(a,o);for(let t of e)r.delete(t);return i=!0,!1}return!0};return e=e.filter(a),t=t.filter(a),i},concat:e=>{let t=s(Zi());return t.use(e),t.identifyOnResolve(n||t.identifyOnResolve()||(e.identifyOnResolve?.()??!1)),t},applyToStack:s,identify:()=>l(!0).map(e=>{let t=e.step??e.relation+` `+e.toMiddleware;return Xi(e.name,e.aliases)+` - `+t}),identifyOnResolve(e){return typeof e==`boolean`&&(n=e),n},resolve:(e,t)=>{for(let n of l().map(e=>e.middleware).reverse())e=n(e,t);return n&&console.log(u.identify()),e}};return u},Qi={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},$i={high:3,normal:2,low:1},ea=class{config;middlewareStack=Zi();initConfig;handlers;constructor(e){this.config=e;let{protocol:t,protocolSettings:n}=e;n&&typeof t==`function`&&(e.protocol=new t(n))}send(e,t,n){let r=typeof t==`function`?void 0:t,i=typeof t==`function`?t:n,a=r===void 0&&this.config.cacheMiddleware===!0,o;if(a){this.handlers||=new WeakMap;let t=this.handlers;t.has(e.constructor)?o=t.get(e.constructor):(o=e.resolveMiddleware(this.middlewareStack,this.config,r),t.set(e.constructor,o))}else delete this.handlers,o=e.resolveMiddleware(this.middlewareStack,this.config,r);if(i)o(e).then(e=>i(null,e.output),e=>i(e)).catch(()=>{});else return o(e).then(e=>e.output)}destroy(){this.config?.requestHandler?.destroy?.(),delete this.handlers}},ta=`***SensitiveInformation***`;function na(e,t){if(t==null)return t;let n=p.of(e);if(n.getMergedTraits().sensitive)return ta;if(n.isListSchema()){if(n.getValueSchema().getMergedTraits().sensitive)return ta}else if(n.isMapSchema()){if(n.getKeySchema().getMergedTraits().sensitive||n.getValueSchema().getMergedTraits().sensitive)return ta}else if(n.isStructSchema()&&typeof t==`object`){let e=t,r={};for(let[t,i]of n.structIterator())e[t]!=null&&(r[t]=na(i,e[t]));return r}return t}var ra=class{middlewareStack=Zi();schema;static classBuilder(){return new ia}resolveMiddlewareWithContext(e,t,n,{middlewareFn:r,clientName:i,commandName:a,inputFilterSensitiveLog:o,outputFilterSensitiveLog:s,smithyContext:c,additionalContext:l,CommandCtor:u}){for(let i of r.bind(this)(u,e,t,n))this.middlewareStack.use(i);let d=e.concat(this.middlewareStack),{logger:ee}=t,te={logger:ee,clientName:i,commandName:a,inputFilterSensitiveLog:o,outputFilterSensitiveLog:s,[he]:{commandInstance:this,...c},...l},{requestHandler:f}=t;return d.resolve(e=>f.handle(e.request,n||{}),te)}},ia=class{_init=()=>{};_ep={};_middlewareFn=()=>[];_commandName=``;_clientName=``;_additionalContext={};_smithyContext={};_inputFilterSensitiveLog=void 0;_outputFilterSensitiveLog=void 0;_serializer=null;_deserializer=null;_operationSchema;init(e){this._init=e}ep(e){return this._ep=e,this}m(e){return this._middlewareFn=e,this}s(e,t,n={}){return this._smithyContext={service:e,operation:t,...n},this}c(e={}){return this._additionalContext=e,this}n(e,t){return this._clientName=e,this._commandName=t,this}f(e=e=>e,t=e=>e){return this._inputFilterSensitiveLog=e,this._outputFilterSensitiveLog=t,this}ser(e){return this._serializer=e,this}de(e){return this._deserializer=e,this}sc(e){return this._operationSchema=e,this._smithyContext.operationSchema=e,this}build(){let e=this,t;return t=class extends ra{input;static getEndpointParameterInstructions(){return e._ep}constructor(...[t]){super(),this.input=t??{},e._init(this),this.schema=e._operationSchema}resolveMiddleware(n,r,i){let a=e._operationSchema,o=a?.[4]??a?.input,s=a?.[5]??a?.output;return this.resolveMiddlewareWithContext(n,r,i,{CommandCtor:t,middlewareFn:e._middlewareFn,clientName:e._clientName,commandName:e._commandName,inputFilterSensitiveLog:e._inputFilterSensitiveLog??(a?na.bind(null,o):e=>e),outputFilterSensitiveLog:e._outputFilterSensitiveLog??(a?na.bind(null,s):e=>e),smithyContext:e._smithyContext,additionalContext:e._additionalContext})}serialize=e._serializer;deserialize=e._deserializer}}},aa=class e extends Error{$fault;$response;$retryable;$metadata;constructor(e){super(e.message),Object.setPrototypeOf(this,Object.getPrototypeOf(this).constructor.prototype),this.name=e.name,this.$fault=e.$fault,this.$metadata=e.$metadata}static isInstance(t){if(!t)return!1;let n=t;return e.prototype.isPrototypeOf(n)||!!n.$fault&&!!n.$metadata&&(n.$fault===`client`||n.$fault===`server`)}static[Symbol.hasInstance](t){if(!t)return!1;let n=t;return this===e?e.isInstance(t):e.isInstance(t)?n.name&&this.name?this.prototype.isPrototypeOf(t)||n.name===this.name:this.prototype.isPrototypeOf(t):!1}},oa=(e,t={})=>(Object.entries(t).filter(([,e])=>e!==void 0).forEach(([t,n])=>{(e[t]==null||e[t]===``)&&(e[t]=n)}),e.message=e.message||e.Message||`UnknownError`,delete e.Message,e),sa=e=>{switch(e){case`standard`:return{retryMode:`standard`,connectionTimeout:3100};case`in-region`:return{retryMode:`standard`,connectionTimeout:1100};case`cross-region`:return{retryMode:`standard`,connectionTimeout:3100};case`mobile`:return{retryMode:`standard`,connectionTimeout:3e4};default:return{}}},ca=Object.values(me),la=e=>{let t=[];for(let n in me){let r=me[n];e[r]!==void 0&&t.push({algorithmId:()=>r,checksumConstructor:()=>e[r]})}for(let[n,r]of Object.entries(e.checksumAlgorithms??{}))t.push({algorithmId:()=>n,checksumConstructor:()=>r});return{addChecksumAlgorithm(n){e.checksumAlgorithms=e.checksumAlgorithms??{};let r=n.algorithmId(),i=n.checksumConstructor();ca.includes(r)?e.checksumAlgorithms[r.toUpperCase()]=i:e.checksumAlgorithms[r]=i,t.push(n)},checksumAlgorithms(){return t}}},ua=e=>{let t={};return e.checksumAlgorithms().forEach(e=>{let n=e.algorithmId();ca.includes(n)&&(t[n]=e.checksumConstructor())}),t},da=e=>({setRetryStrategy(t){e.retryStrategy=t},retryStrategy(){return e.retryStrategy}}),fa=e=>{let t={};return t.retryStrategy=e.retryStrategy(),t},pa=e=>Object.assign(la(e),da(e)),ma=e=>Object.assign(ua(e),fa(e)),ha=e=>{let t=`#text`;for(let n in e)e.hasOwnProperty(n)&&e[n][t]!==void 0?e[n]=e[n][t]:typeof e[n]==`object`&&e[n]!==null&&(e[n]=ha(e[n]));return e},ga=class{trace(){}debug(){}info(){}warn(){}error(){}},_a=e=>e?.body instanceof ReadableStream,va=e=>(t,n)=>async r=>{let a=await e.retryStrategy(),o=await e.maxAttempts();if(ya(a)){a=a;let e=await a.acquireInitialRetryToken(n.partition_id),s=Error(),c=0,l=0,{request:u}=r,d=i.isInstance(u);for(d&&(u.headers[ai]=pn());;)try{d&&(u.headers[oi]=`attempt=${c+1}; max=${o}`);let{response:n,output:i}=await t(r);return a.recordSuccess(e),i.$metadata.attempts=c+1,i.$metadata.totalRetryDelay=l,{response:n,output:i}}catch(t){let r=ba(t);if(s=qi(t),d&&_a(u))throw(n.logger instanceof ga?console:n.logger)?.warn(`An error was encountered in a non-retryable streaming request.`),s;try{e=await a.refreshRetryTokenForRetry(e,r)}catch{throw s.$metadata||={},s.$metadata.attempts=c+1,s.$metadata.totalRetryDelay=l,s}c=e.getRetryCount();let i=e.getRetryDelay();l+=i,await new Promise(e=>setTimeout(e,i))}}else return a=a,a?.mode&&(n.userAgent=[...n.userAgent||[],[`cfg/retry-mode`,a.mode]]),a.retry(t,r)},ya=e=>e.acquireInitialRetryToken!==void 0&&e.refreshRetryTokenForRetry!==void 0&&e.recordSuccess!==void 0,ba=e=>{let t={error:e,errorType:xa(e)},n=wa(e.$response);return n&&(t.retryAfterHint=n),t},xa=e=>ei(e)?`THROTTLING`:ti(e)?`TRANSIENT`:ni(e)?`SERVER_ERROR`:`CLIENT_ERROR`,Sa={name:`retryMiddleware`,tags:[`RETRY`],step:`finalizeRequest`,priority:`high`,override:!0},Ca=e=>({applyToStack:t=>{t.add(va(e),Sa)}}),wa=e=>{if(!ge.isInstance(e))return;let t=Object.keys(e.headers).find(e=>e.toLowerCase()===`retry-after`);if(!t)return;let n=e.headers[t],r=Number(n);return Number.isNaN(r)?new Date(n):new Date(r*1e3)},Ta=e=>ge.isInstance(e)?e.headers?.date??e.headers?.Date:void 0,Ea=e=>new Date(Date.now()+e),Da=(e,t)=>Math.abs(Ea(t).getTime()-e)>=3e5,Oa=(e,t)=>{let n=Date.parse(e);return Da(n,t)?n-Date.now():t},ka=(e,t)=>{if(!t)throw Error(`Property \`${e}\` is not resolved for AWS SDK SigV4Auth`);return t},Aa=async e=>{let t=ka(`context`,e.context),n=ka(`config`,e.config),r=t.endpointV2?.properties?.authSchemes?.[0];return{config:n,signer:await ka(`signer`,n.signer)(r),signingRegion:e?.signingRegion,signingRegionSet:e?.signingRegionSet,signingName:e?.signingName}},ja=class{async sign(e,t,n){if(!i.isInstance(e))throw Error("The request is not an instance of `HttpRequest` and cannot be signed");let r=await Aa(n),{config:a,signer:o}=r,{signingRegion:s,signingName:c}=r,l=n.context;if(l?.authSchemes?.length??!1){let[e,t]=l.authSchemes;e?.name===`sigv4a`&&t?.name===`sigv4`&&(s=t?.signingRegion??s,c=t?.signingName??c)}return await o.sign(e,{signingDate:Ea(a.systemClockOffset),signingRegion:s,signingService:c})}errorHandler(e){return t=>{let n=t.ServerTime??Ta(t.$response);if(n){let r=ka(`config`,e.config),i=r.systemClockOffset;r.systemClockOffset=Oa(n,r.systemClockOffset),r.systemClockOffset!==i&&t.$metadata&&(t.$metadata.clockSkewCorrected=!0)}throw t}}successHandler(e,t){let n=Ta(e);if(n){let e=ka(`config`,t.config);e.systemClockOffset=Oa(n,e.systemClockOffset)}}},Ma=class extends ja{async sign(e,t,n){if(!i.isInstance(e))throw Error("The request is not an instance of `HttpRequest` and cannot be signed");let{config:r,signer:a,signingRegion:o,signingRegionSet:s,signingName:c}=await Aa(n),l=(await r.sigv4aSigningRegionSet?.()??s??[o]).join(`,`);return await a.sign(e,{signingDate:Ea(r.systemClockOffset),signingRegion:l,signingService:c})}},Na=(e,t,n)=>{let r,i,a,o=!1,s=async()=>{i||=e();try{r=await i,a=!0,o=!1}finally{i=void 0}return r};return t===void 0?async e=>((!a||e?.forceRefresh)&&(r=await s()),r):async e=>((!a||e?.forceRefresh)&&(r=await s()),o?r:n&&!n(r)?(o=!0,r):(t(r)&&await s(),r))},Pa=e=>(e.sigv4aSigningRegionSet=ze(e.sigv4aSigningRegionSet),e),Fa=e=>{let t=e.credentials,n=!!e.credentials,r;Object.defineProperty(e,`credentials`,{set(i){i&&i!==t&&i!==r&&(n=!0),t=i;let a=La(e,Ia(e,{credentials:t,credentialDefaultProvider:e.credentialDefaultProvider}));if(n&&!a.attributed){let e=typeof t==`object`&&!!t;r=async t=>{let n=await a(t);return e&&(!n.$source||Object.keys(n.$source).length===0)?Hr(n,`CREDENTIALS_CODE`,`e`):n},r.memoized=a.memoized,r.configBound=a.configBound,r.attributed=!0}else r=a},get(){return r},enumerable:!0,configurable:!0}),e.credentials=t;let{signingEscapePath:i=!0,systemClockOffset:a=e.systemClockOffset||0,sha256:o}=e,s;return s=e.signer?ze(e.signer):e.regionInfoProvider?()=>ze(e.region)().then(async t=>[await e.regionInfoProvider(t,{useFipsEndpoint:await e.useFipsEndpoint(),useDualstackEndpoint:await e.useDualstackEndpoint()})||{},t]).then(([t,n])=>{let{signingRegion:r,signingService:a}=t;e.signingRegion=e.signingRegion||r||n,e.signingName=e.signingName||a||e.serviceId;let s={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:o,uriEscapePath:i};return new(e.signerConstructor||re)(s)}):async t=>{t=Object.assign({},{name:`sigv4`,signingName:e.signingName||e.defaultSigningName,signingRegion:await ze(e.region)(),properties:{}},t);let n=t.signingRegion,r=t.signingName;e.signingRegion=e.signingRegion||n,e.signingName=e.signingName||r||e.serviceId;let a={...e,credentials:e.credentials,region:e.signingRegion,service:e.signingName,sha256:o,uriEscapePath:i};return new(e.signerConstructor||re)(a)},Object.assign(e,{systemClockOffset:a,signingEscapePath:i,signer:s})};function Ia(e,{credentials:t,credentialDefaultProvider:n}){let r;return r=t?t?.memoized?t:Zn(t,Yn,Xn):n?ze(n(Object.assign({},e,{parentClientConfig:e}))):async()=>{throw Error("@aws-sdk/core::resolveAwsSdkSigV4Config - `credentials` not provided and no credentialDefaultProvider was configured.")},r.memoized=!0,r}function La(e,t){if(t.configBound)return t;let n=async n=>t({...n,callerClientConfig:e});return n.memoized=t.memoized,n.configBound=!0,n}var Ra=async(e,t,n)=>({operation:_e(t).operation,region:await f(e.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function za(e){return{schemeId:`aws.auth#sigv4`,signingProperties:{name:`ec2`,region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}var Ba=e=>{let t=[];switch(e.operation){default:t.push(za(e))}return t},Va=e=>{let t=Fa(e);return Object.assign(t,{authSchemePreference:f(e.authSchemePreference??[])})},Ha=e=>Object.assign(e,{useDualstackEndpoint:e.useDualstackEndpoint??!1,useFipsEndpoint:e.useFipsEndpoint??!1,defaultSigningName:`ec2`}),Ua={UseFIPS:{type:`builtInParams`,name:`useFipsEndpoint`},Endpoint:{type:`builtInParams`,name:`endpoint`},Region:{type:`builtInParams`,name:`region`},UseDualStack:{type:`builtInParams`,name:`useDualstackEndpoint`}},Wa=`@aws-sdk/client-ec2`,Ga=`AWS SDK for JavaScript Ec2 Client for Node.js, Browser and React Native`,Ka=`3.1024.0`,qa={build:`concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs`,"build:cjs":`node ../../scripts/compilation/inline client-ec2`,"build:es":`tsc -p tsconfig.es.json`,"build:include:deps":`yarn g:turbo run build -F="$npm_package_name"`,"build:types":`tsc -p tsconfig.types.json`,"build:types:downlevel":`downlevel-dts dist-types dist-types/ts3.4`,clean:`premove dist-cjs dist-es dist-types tsconfig.cjs.tsbuildinfo tsconfig.es.tsbuildinfo tsconfig.types.tsbuildinfo`,"extract:docs":`api-extractor run --local`,"generate:client":`node ../../scripts/generate-clients/single-service --solo ec2`,test:`yarn g:vitest run --passWithNoTests`,"test:index":`tsc --noEmit ./test/index-types.ts && node ./test/index-objects.spec.mjs`,"test:integration":`yarn g:vitest run --passWithNoTests -c vitest.config.integ.mts`,"test:integration:watch":`yarn g:vitest run --passWithNoTests -c vitest.config.integ.mts`,"test:watch":`yarn g:vitest watch --passWithNoTests`},Ja=`./dist-cjs/index.js`,Ya=`./dist-types/index.d.ts`,Xa=`./dist-es/index.js`,Za={"@aws-crypto/sha256-browser":`5.2.0`,"@aws-crypto/sha256-js":`5.2.0`,"@aws-sdk/core":`^3.973.26`,"@aws-sdk/credential-provider-node":`^3.972.29`,"@aws-sdk/middleware-host-header":`^3.972.8`,"@aws-sdk/middleware-logger":`^3.972.8`,"@aws-sdk/middleware-recursion-detection":`^3.972.9`,"@aws-sdk/middleware-sdk-ec2":`^3.972.18`,"@aws-sdk/middleware-user-agent":`^3.972.28`,"@aws-sdk/region-config-resolver":`^3.972.10`,"@aws-sdk/types":`^3.973.6`,"@aws-sdk/util-endpoints":`^3.996.5`,"@aws-sdk/util-user-agent-browser":`^3.972.8`,"@aws-sdk/util-user-agent-node":`^3.973.14`,"@smithy/config-resolver":`^4.4.13`,"@smithy/core":`^3.23.13`,"@smithy/fetch-http-handler":`^5.3.15`,"@smithy/hash-node":`^4.2.12`,"@smithy/invalid-dependency":`^4.2.12`,"@smithy/middleware-content-length":`^4.2.12`,"@smithy/middleware-endpoint":`^4.4.28`,"@smithy/middleware-retry":`^4.4.46`,"@smithy/middleware-serde":`^4.2.16`,"@smithy/middleware-stack":`^4.2.12`,"@smithy/node-config-provider":`^4.3.12`,"@smithy/node-http-handler":`^4.5.1`,"@smithy/protocol-http":`^5.3.12`,"@smithy/smithy-client":`^4.12.8`,"@smithy/types":`^4.13.1`,"@smithy/url-parser":`^4.2.12`,"@smithy/util-base64":`^4.3.2`,"@smithy/util-body-length-browser":`^4.2.2`,"@smithy/util-body-length-node":`^4.2.3`,"@smithy/util-defaults-mode-browser":`^4.3.44`,"@smithy/util-defaults-mode-node":`^4.2.48`,"@smithy/util-endpoints":`^3.3.3`,"@smithy/util-middleware":`^4.2.12`,"@smithy/util-retry":`^4.2.13`,"@smithy/util-utf8":`^4.2.2`,"@smithy/util-waiter":`^4.2.14`,tslib:`^2.6.2`},Qa={"@smithy/snapshot-testing":`^2.0.4`,"@tsconfig/node20":`20.1.8`,"@types/node":`^20.14.8`,concurrently:`7.0.0`,"downlevel-dts":`0.10.1`,premove:`4.0.0`,typescript:`~5.8.3`,vitest:`^4.0.17`},$a={node:`>=20.0.0`},eo={"<4.5":{"dist-types/*":[`dist-types/ts3.4/*`]}},to=[`dist-*/**`],no={name:`AWS SDK for JavaScript Team`,url:`https://aws.amazon.com/javascript/`},ro=`Apache-2.0`,io={"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.browser`},ao=`https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-ec2`,oo={type:`git`,url:`https://github.com/aws/aws-sdk-js-v3.git`,directory:`clients/client-ec2`},so={name:Wa,description:Ga,version:Ka,scripts:qa,main:Ja,types:Ya,module:Xa,sideEffects:!1,dependencies:Za,devDependencies:Qa,engines:$a,typesVersions:eo,files:to,author:no,license:ro,browser:io,"react-native":{"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.native`},homepage:ao,repository:oo},co=({serviceId:e,clientVersion:t})=>async n=>{let r=typeof window<`u`?window.navigator:void 0,i=r?.userAgent??``,a=r?.userAgentData?.platform??lo.os(i)??`other`,o=r?.userAgentData?.brands??[],s=o[o.length-1],c=s?.brand??lo.browser(i)??`unknown`,l=s?.version??`unknown`,u=[[`aws-sdk-js`,t],[`ua`,`2.1`],[`os/${a}`,void 0],[`lang/js`],[`md/browser`,`${c}_${l}`]];e&&u.push([`api/${e}`,t]);let d=await n?.userAgentAppId?.();return d&&u.push([`app/${d}`]),u},lo={os(e){if(/iPhone|iPad|iPod/.test(e))return`iOS`;if(/Macintosh|Mac OS X/.test(e))return`macOS`;if(/Windows NT/.test(e))return`Windows`;if(/Android/.test(e))return`Android`;if(/Linux/.test(e))return`Linux`},browser(e){if(/EdgiOS|EdgA|Edg\//.test(e))return`Microsoft Edge`;if(/Firefox\//.test(e))return`Firefox`;if(/Chrome\//.test(e))return`Chrome`;if(/Safari\//.test(e))return`Safari`}},uo=e=>()=>Promise.reject(e),fo=typeof TextEncoder==`function`?new TextEncoder:null,po=e=>{if(typeof e==`string`){if(fo)return fo.encode(e).byteLength;let t=e.length;for(let n=t-1;n>=0;n--){let r=e.charCodeAt(n);r>127&&r<=2047?t++:r>2047&&r<=65535&&(t+=2),r>=56320&&r<=57343&&n--}return t}else if(typeof e.byteLength==`number`)return e.byteLength;else if(typeof e.size==`number`)return e.size;throw Error(`Body Length computation failed for ${e}`)},mo=[`in-region`,`cross-region`,`mobile`,`standard`,`legacy`],ho=({defaultsMode:e}={})=>Na(async()=>{let t=typeof e==`function`?await e():e;switch(t?.toLowerCase()){case`auto`:return Promise.resolve(go()?`mobile`:`standard`);case`mobile`:case`in-region`:case`cross-region`:case`standard`:case`legacy`:return Promise.resolve(t?.toLocaleLowerCase());case void 0:return Promise.resolve(`legacy`);default:throw Error(`Invalid parameter for "defaultsMode", expect ${mo.join(`, `)}, got ${t}`)}}),go=()=>{let e=window?.navigator;if(e?.connection){let{effectiveType:t,rtt:n,downlink:r}=e?.connection;if(typeof t==`string`&&t!==`4g`||Number(n)>100||Number(r)<10)return!0}return e?.userAgentData?.mobile||typeof e?.maxTouchPoints==`number`&&e?.maxTouchPoints>1},_o=class{queryCompat;errorRegistry;constructor(e=!1){this.queryCompat=e}resolveRestContentType(e,t){let n=t.getMemberSchemas(),r=Object.values(n).find(e=>!!e.getMergedTraits().httpPayload);if(r)return r.getMergedTraits().mediaType||(r.isStringSchema()?`text/plain`:r.isBlobSchema()?`application/octet-stream`:e);if(!t.isUnitSchema()&&Object.values(n).find(e=>{let{httpQuery:t,httpQueryParams:n,httpHeader:r,httpLabel:i,httpPrefixHeaders:a}=e.getMergedTraits();return!t&&!n&&!r&&!i&&a===void 0}))return e}async getErrorSchemaOrThrowBaseException(e,t,n,r,i,a){let o=e;e.includes(`#`)&&([,o]=e.split(`#`));let s={$metadata:i,$fault:n.statusCode<500?`client`:`server`};if(!this.errorRegistry)throw Error(`@aws-sdk/core/protocols - error handler not initialized.`);try{return{errorSchema:a?.(this.errorRegistry,o)??this.errorRegistry.getSchema(e),errorMetadata:s}}catch{r.message=r.message??r.Message??`UnknownError`;let e=this.errorRegistry,t=e.getBaseException();if(t){let n=e.getErrorCtor(t)??Error;throw this.decorateServiceException(Object.assign(new n({name:o}),s),r)}let n=r,i=n?.message??n?.Message??n?.Error?.Message??n?.Error?.message;throw this.decorateServiceException(Object.assign(Error(i),{name:o},s),r)}}compose(e,t,n){let r=n;t.includes(`#`)&&([r]=t.split(`#`));let i=At.for(r),a=At.for(`smithy.ts.sdk.synthetic.`+n);e.copyFrom(i),e.copyFrom(a),this.errorRegistry=e}decorateServiceException(e,t={}){if(this.queryCompat){let n=e.Message??t.Message,r=oa(e,t);n&&(r.message=n),r.Error={...r.Error,Type:r.Error?.Type,Code:r.Error?.Code,Message:r.Error?.message??r.Error?.Message??n};let i=r.$metadata.requestId;return i&&(r.RequestId=i),r}return oa(e,t)}setQueryCompatError(e,t){let n=t.headers?.[`x-amzn-query-error`];if(e!==void 0&&n!=null){let[t,r]=n.split(`;`),i=Object.entries(e),a={Code:t,Type:r};Object.assign(e,a);for(let[e,t]of i)a[e===`message`?`Message`:e]=t;delete a.__type,e.Error=a}}queryCompatOutput(e,t){e.Error&&(t.Error=e.Error),e.Type&&(t.Type=e.Type),e.Code&&(t.Code=e.Code)}findQueryCompatibleError(e,t){try{return e.getSchema(t)}catch{return e.find(e=>p.of(e).getMergedTraits().awsQueryError?.[0]===t)}}},vo=class{serdeContext;setSerdeContext(e){this.serdeContext=e}},yo=class{from;to;keys;constructor(e,t){this.from=e,this.to=t,this.keys=new Set(Object.keys(this.from).filter(e=>e!==`__type`))}mark(e){this.keys.delete(e)}hasUnknown(){return this.keys.size===1&&Object.keys(this.to).length===0}writeUnknown(){if(this.hasUnknown()){let e=this.keys.values().next().value,t=this.from[e];this.to.$unknown=[e,t]}}},bo=/[&<>"]/g,xo={"&":`&`,"<":`<`,">":`>`,'"':`"`};function So(e){return e.replace(bo,e=>xo[e])}var Co=/[&"'<>\r\n\u0085\u2028]/g,wo={"&":`&`,'"':`"`,"'":`'`,"<":`<`,">":`>`,"\r":` `,"\n":` `,"…":`…`,"\u2028":`
`};function To(e){return e.replace(Co,e=>wo[e])}var Eo=class{value;constructor(e){this.value=e}toString(){return To(``+this.value)}},Do=class e{name;children;attributes={};static of(t,n,r){let i=new e(t);return n!==void 0&&i.addChildNode(new Eo(n)),r!==void 0&&i.withName(r),i}constructor(e,t=[]){this.name=e,this.children=t}withName(e){return this.name=e,this}addAttribute(e,t){return this.attributes[e]=t,this}addChildNode(e){return this.children.push(e),this}removeAttribute(e){return delete this.attributes[e],this}n(e){return this.name=e,this}c(e){return this.children.push(e),this}a(e,t){return t!=null&&(this.attributes[e]=t),this}cc(t,n,r=n){if(t[n]!=null){let i=e.of(n,t[n]).withName(r);this.c(i)}}l(e,t,n,r){e[t]!=null&&r().map(e=>{e.withName(n),this.c(e)})}lc(t,n,r,i){if(t[n]!=null){let t=i(),n=new e(r);t.map(e=>{n.c(e)}),this.c(n)}}toString(){let e=!!this.children.length,t=`<${this.name}`,n=this.attributes;for(let e of Object.keys(n)){let r=n[e];r!=null&&(t+=` ${e}="${So(``+r)}"`)}return t+=e?`>${this.children.map(e=>e.toString()).join(``)}`:`/>`}},Oo;function ko(e){Oo||=new DOMParser;let t=Oo.parseFromString(e,`application/xml`);if(t.getElementsByTagName(`parsererror`).length>0)throw Error(`DOMParser XML parsing error.`);let n=e=>{if(e.nodeType===Node.TEXT_NODE&&e.textContent?.trim())return e.textContent;if(e.nodeType===Node.ELEMENT_NODE){let t=e;if(t.attributes.length===0&&t.childNodes.length===0)return``;let r={},i=Array.from(t.attributes);for(let e of i)r[`${e.name}`]=e.value;let a=Array.from(t.childNodes);for(let e of a){let o=n(e);if(o!=null){let t=e.nodeName;if(a.length===1&&i.length===0&&t===`#text`)return o;r[t]?Array.isArray(r[t])?r[t].push(o):r[t]=[r[t],o]:r[t]=o}else if(a.length===1&&i.length===0)return t.textContent}return r}return null};return{[t.documentElement.nodeName]:n(t.documentElement)}}var Ao=class extends vo{settings;stringDeserializer;constructor(e){super(),this.settings=e,this.stringDeserializer=new Un(e)}setSerdeContext(e){this.serdeContext=e,this.stringDeserializer.setSerdeContext(e)}read(e,t,n){let r=p.of(e),i=r.getMemberSchemas();if(r.isStructSchema()&&r.isMemberSchema()&&Object.values(i).find(e=>!!e.getMemberTraits().eventPayload)){let e={},n=Object.keys(i)[0];return i[n].isBlobSchema()?e[n]=t:e[n]=this.read(i[n],t),e}let a=(this.serdeContext?.utf8Encoder??ce)(t),o=this.parseXml(a);return this.readSchema(e,n?o[n]:o)}readSchema(e,t){let n=p.of(e);if(n.isUnitSchema())return;let r=n.getMergedTraits();if(n.isListSchema()&&!Array.isArray(t))return this.readSchema(n,[t]);if(t==null)return t;if(typeof t==`object`){let e=!!r.xmlFlattened;if(n.isListSchema()){let r=n.getValueSchema(),i=[],a=r.getMergedTraits().xmlName??`member`,o=e?t:(t[0]??t)[a];if(o==null)return i;let s=Array.isArray(o)?o:[o];for(let e of s)i.push(this.readSchema(r,e));return i}let i={};if(n.isMapSchema()){let r=n.getKeySchema(),a=n.getValueSchema(),o;o=e?Array.isArray(t)?t:[t]:Array.isArray(t.entry)?t.entry:[t.entry];let s=r.getMergedTraits().xmlName??`key`,c=a.getMergedTraits().xmlName??`value`;for(let e of o){let t=e[s],n=e[c];i[t]=this.readSchema(a,n)}return i}if(n.isStructSchema()){let e=n.isUnionSchema(),r;e&&(r=new yo(t,i));for(let[a,o]of n.structIterator()){let n=o.getMergedTraits(),s=n.httpPayload?n.xmlName??o.getName():o.getMemberTraits().xmlName??a;e&&r.mark(s),t[s]!=null&&(i[a]=this.readSchema(o,t[s]))}return e&&r.writeUnknown(),i}if(n.isDocumentSchema())return t;throw Error(`@aws-sdk/core/protocols - xml deserializer unhandled schema type for ${n.getName(!0)}`)}return n.isListSchema()?[]:n.isMapSchema()||n.isStructSchema()?{}:this.stringDeserializer.read(n,t)}parseXml(e){if(e.length){let t;try{t=ko(e)}catch(t){throw t&&typeof t==`object`&&Object.defineProperty(t,`$responseBodyText`,{value:e}),t}let n=`#text`,r=Object.keys(t)[0],i=t[r];return i[n]&&(i[r]=i[n],delete i[n]),ha(i)}return{}}},jo=class extends vo{settings;buffer;constructor(e){super(),this.settings=e}write(e,t,n=``){this.buffer===void 0&&(this.buffer=``);let r=p.of(e);if(n&&!n.endsWith(`.`)&&(n+=`.`),r.isBlobSchema())(typeof t==`string`||t instanceof Uint8Array)&&(this.writeKey(n),this.writeValue((this.serdeContext?.base64Encoder??We)(t)));else if(r.isBooleanSchema()||r.isNumericSchema()||r.isStringSchema())t==null?r.isIdempotencyToken()&&(this.writeKey(n),this.writeValue(pn())):(this.writeKey(n),this.writeValue(String(t)));else if(r.isBigIntegerSchema())t!=null&&(this.writeKey(n),this.writeValue(String(t)));else if(r.isBigDecimalSchema())t!=null&&(this.writeKey(n),this.writeValue(t instanceof Nn?t.string:String(t)));else if(r.isTimestampSchema()){if(t instanceof Date)switch(this.writeKey(n),Hn(r,this.settings)){case 5:this.writeValue(t.toISOString().replace(`.000Z`,`Z`));break;case 6:this.writeValue(Jt(t));break;case 7:this.writeValue(String(t.getTime()/1e3));break}}else if(r.isDocumentSchema())Array.isArray(t)?this.write(79,t,n):t instanceof Date?this.write(4,t,n):t instanceof Uint8Array?this.write(21,t,n):t&&typeof t==`object`?this.write(143,t,n):(this.writeKey(n),this.writeValue(String(t)));else if(r.isListSchema()){if(Array.isArray(t))if(t.length===0)this.settings.serializeEmptyLists&&(this.writeKey(n),this.writeValue(``));else{let e=r.getValueSchema(),i=this.settings.flattenLists||r.getMergedTraits().xmlFlattened,a=1;for(let r of t){if(r==null)continue;let t=e.getMergedTraits(),o=this.getKey(`member`,t.xmlName,t.ec2QueryName),s=i?`${n}${a}`:`${n}${o}.${a}`;this.write(e,r,s),++a}}}else if(r.isMapSchema()){if(t&&typeof t==`object`){let e=r.getKeySchema(),i=r.getValueSchema(),a=r.getMergedTraits().xmlFlattened,o=1;for(let[r,s]of Object.entries(t)){if(s==null)continue;let t=e.getMergedTraits(),c=this.getKey(`key`,t.xmlName,t.ec2QueryName),l=a?`${n}${o}.${c}`:`${n}entry.${o}.${c}`,u=i.getMergedTraits(),d=this.getKey(`value`,u.xmlName,u.ec2QueryName),ee=a?`${n}${o}.${d}`:`${n}entry.${o}.${d}`;this.write(e,r,l),this.write(i,s,ee),++o}}}else if(r.isStructSchema()){if(t&&typeof t==`object`){let e=!1;for(let[i,a]of r.structIterator()){if(t[i]==null&&!a.isIdempotencyToken())continue;let r=a.getMergedTraits(),o=this.getKey(i,r.xmlName,r.ec2QueryName,`struct`),s=`${n}${o}`;this.write(a,t[i],s),e=!0}if(!e&&r.isUnionSchema()){let{$unknown:e}=t;if(Array.isArray(e)){let[t,r]=e,i=`${n}${t}`;this.write(15,r,i)}}}}else if(!r.isUnitSchema())throw Error(`@aws-sdk/core/protocols - QuerySerializer unrecognized schema type ${r.getName(!0)}`)}flush(){if(this.buffer===void 0)throw Error(`@aws-sdk/core/protocols - QuerySerializer cannot flush with nothing written to buffer.`);let e=this.buffer;return delete this.buffer,e}getKey(e,t,n,r){let{ec2:i,capitalizeKeys:a}=this.settings;if(i&&n)return n;let o=t??e;return a&&r===`struct`?o[0].toUpperCase()+o.slice(1):o}writeKey(e){e.endsWith(`.`)&&(e=e.slice(0,e.length-1)),this.buffer+=`&${ut(e)}=`}writeValue(e){this.buffer+=ut(e)}},Mo=class extends Vn{options;serializer;deserializer;mixin=new _o;constructor(e){super({defaultNamespace:e.defaultNamespace,errorTypeRegistries:e.errorTypeRegistries}),this.options=e;let t={timestampFormat:{useTrait:!0,default:5},httpBindings:!1,xmlNamespace:e.xmlNamespace,serviceNamespace:e.defaultNamespace,serializeEmptyLists:!0};this.serializer=new jo(t),this.deserializer=new Ao(t)}getShapeId(){return`aws.protocols#awsQuery`}setSerdeContext(e){this.serializer.setSerdeContext(e),this.deserializer.setSerdeContext(e)}getPayloadCodec(){throw Error(`AWSQuery protocol has no payload codec.`)}async serializeRequest(e,t,n){let r=await super.serializeRequest(e,t,n);return r.path.endsWith(`/`)||(r.path+=`/`),Object.assign(r.headers,{"content-type":`application/x-www-form-urlencoded`}),(dt(e.input)===`unit`||!r.body)&&(r.body=``),r.body=`Action=${e.name.split(`#`)[1]??e.name}&Version=${this.options.version}`+r.body,r.body.endsWith(`&`)&&(r.body=r.body.slice(-1)),r}async deserializeResponse(e,t,n){let r=this.deserializer,i=p.of(e.output),a={};if(n.statusCode>=300){let i=await lt(n.body,t);i.byteLength>0&&Object.assign(a,await r.read(15,i)),await this.handleError(e,t,n,a,this.deserializeMetadata(n))}for(let e in n.headers){let t=n.headers[e];delete n.headers[e],n.headers[e.toLowerCase()]=t}let o=e.name.split(`#`)[1]??e.name,s=i.isStructSchema()&&this.useNestedResult()?o+`Result`:void 0,c=await lt(n.body,t);return c.byteLength>0&&Object.assign(a,await r.read(i,c,s)),{$metadata:this.deserializeMetadata(n),...a}}useNestedResult(){return!0}async handleError(e,t,n,r,i){let a=this.loadQueryErrorCode(n,r)??`Unknown`;this.mixin.compose(this.compositeErrorRegistry,a,this.options.defaultNamespace);let o=this.loadQueryError(r)??{},s=this.loadQueryErrorMessage(r);o.message=s,o.Error={Type:o.Type,Code:o.Code,Message:s};let{errorSchema:c,errorMetadata:l}=await this.mixin.getErrorSchemaOrThrowBaseException(a,this.options.defaultNamespace,n,o,i,this.mixin.findQueryCompatibleError),u=p.of(c),d=new((this.compositeErrorRegistry.getErrorCtor(c))??Error)(s),ee={Type:o.Error.Type,Code:o.Error.Code,Error:o.Error};for(let[e,t]of u.structIterator()){let n=t.getMergedTraits().xmlName??e,i=o[n]??r[n];ee[e]=this.deserializer.readSchema(t,i)}throw this.mixin.decorateServiceException(Object.assign(d,l,{$fault:u.getMergedTraits().error,message:s},ee),r)}loadQueryErrorCode(e,t){let n=(t.Errors?.[0]?.Error??t.Errors?.Error??t.Error)?.Code;if(n!==void 0)return n;if(e.statusCode==404)return`NotFound`}loadQueryError(e){return e.Errors?.[0]?.Error??e.Errors?.Error??e.Error}loadQueryErrorMessage(e){let t=this.loadQueryError(e);return t?.message??t?.Message??e.message??e.Message??`Unknown`}getDefaultContentType(){return`application/x-www-form-urlencoded`}},No=class extends Mo{options;constructor(e){super(e),this.options=e,Object.assign(this.serializer.settings,{capitalizeKeys:!0,flattenLists:!0,serializeEmptyLists:!1,ec2:!0})}getShapeId(){return`aws.protocols#ec2Query`}useNestedResult(){return!1}},Po=(e,t)=>{if(t?.Error?.Code!==void 0)return t.Error.Code;if(t?.Code!==void 0)return t.Code;if(e.statusCode==404)return`NotFound`},Fo=class extends vo{settings;stringBuffer;byteBuffer;buffer;constructor(e){super(),this.settings=e}write(e,t){let n=p.of(e);if(n.isStringSchema()&&typeof t==`string`)this.stringBuffer=t;else if(n.isBlobSchema())this.byteBuffer=`byteLength`in t?t:(this.serdeContext?.base64Decoder??Ue)(t);else{this.buffer=this.writeStruct(n,t,void 0);let e=n.getMergedTraits();e.httpPayload&&!e.xmlName&&this.buffer.withName(n.getName())}}flush(){if(this.byteBuffer!==void 0){let e=this.byteBuffer;return delete this.byteBuffer,e}if(this.stringBuffer!==void 0){let e=this.stringBuffer;return delete this.stringBuffer,e}let e=this.buffer;return this.settings.xmlNamespace&&(e?.attributes?.xmlns||e.addAttribute(`xmlns`,this.settings.xmlNamespace)),delete this.buffer,e.toString()}writeStruct(e,t,n){let r=e.getMergedTraits(),i=e.isMemberSchema()&&!r.httpPayload?e.getMemberTraits().xmlName??e.getMemberName():r.xmlName??e.getName();if(!i||!e.isStructSchema())throw Error(`@aws-sdk/core/protocols - xml serializer, cannot write struct with empty name or non-struct, schema=${e.getName(!0)}.`);let a=Do.of(i),[o,s]=this.getXmlnsAttribute(e,n);for(let[n,r]of e.structIterator()){let e=t[n];if(e!=null||r.isIdempotencyToken()){if(r.getMergedTraits().xmlAttribute){a.addAttribute(r.getMergedTraits().xmlName??n,this.writeSimple(r,e));continue}if(r.isListSchema())this.writeList(r,e,a,s);else if(r.isMapSchema())this.writeMap(r,e,a,s);else if(r.isStructSchema())a.addChildNode(this.writeStruct(r,e,s));else{let t=Do.of(r.getMergedTraits().xmlName??r.getMemberName());this.writeSimpleInto(r,e,t,s),a.addChildNode(t)}}}let{$unknown:c}=t;if(c&&e.isUnionSchema()&&Array.isArray(c)&&Object.keys(t).length===1){let[e,n]=c,r=Do.of(e);if(typeof n!=`string`)if(t instanceof Do||t instanceof Eo)a.addChildNode(t);else throw Error(`@aws-sdk - $unknown union member in XML requires value of type string, @aws-sdk/xml-builder::XmlNode or XmlText.`);this.writeSimpleInto(0,n,r,s),a.addChildNode(r)}return s&&a.addAttribute(o,s),a}writeList(e,t,n,r){if(!e.isMemberSchema())throw Error(`@aws-sdk/core/protocols - xml serializer, cannot write non-member list: ${e.getName(!0)}`);let i=e.getMergedTraits(),a=e.getValueSchema(),o=a.getMergedTraits(),s=!!o.sparse,c=!!i.xmlFlattened,[l,u]=this.getXmlnsAttribute(e,r),d=(t,n)=>{if(a.isListSchema())this.writeList(a,Array.isArray(n)?n:[n],t,u);else if(a.isMapSchema())this.writeMap(a,n,t,u);else if(a.isStructSchema()){let r=this.writeStruct(a,n,u);t.addChildNode(r.withName(c?i.xmlName??e.getMemberName():o.xmlName??`member`))}else{let r=Do.of(c?i.xmlName??e.getMemberName():o.xmlName??`member`);this.writeSimpleInto(a,n,r,u),t.addChildNode(r)}};if(c)for(let e of t)(s||e!=null)&&d(n,e);else{let r=Do.of(i.xmlName??e.getMemberName());u&&r.addAttribute(l,u);for(let e of t)(s||e!=null)&&d(r,e);n.addChildNode(r)}}writeMap(e,t,n,r,i=!1){if(!e.isMemberSchema())throw Error(`@aws-sdk/core/protocols - xml serializer, cannot write non-member map: ${e.getName(!0)}`);let a=e.getMergedTraits(),o=e.getKeySchema(),s=o.getMergedTraits().xmlName??`key`,c=e.getValueSchema(),l=c.getMergedTraits(),u=l.xmlName??`value`,d=!!l.sparse,ee=!!a.xmlFlattened,[te,f]=this.getXmlnsAttribute(e,r),ne=(e,t,n)=>{let r=Do.of(s,t),[i,a]=this.getXmlnsAttribute(o,f);a&&r.addAttribute(i,a),e.addChildNode(r);let l=Do.of(u);c.isListSchema()?this.writeList(c,n,l,f):c.isMapSchema()?this.writeMap(c,n,l,f,!0):c.isStructSchema()?l=this.writeStruct(c,n,f):this.writeSimpleInto(c,n,l,f),e.addChildNode(l)};if(ee){for(let[r,i]of Object.entries(t))if(d||i!=null){let t=Do.of(a.xmlName??e.getMemberName());ne(t,r,i),n.addChildNode(t)}}else{let r;i||(r=Do.of(a.xmlName??e.getMemberName()),f&&r.addAttribute(te,f),n.addChildNode(r));for(let[e,a]of Object.entries(t))if(d||a!=null){let t=Do.of(`entry`);ne(t,e,a),(i?n:r).addChildNode(t)}}}writeSimple(e,t){if(t===null)throw Error(`@aws-sdk/core/protocols - (XML serializer) cannot write null value.`);let n=p.of(e),r=null;if(t&&typeof t==`object`)if(n.isBlobSchema())r=(this.serdeContext?.base64Encoder??We)(t);else if(n.isTimestampSchema()&&t instanceof Date)switch(Hn(n,this.settings)){case 5:r=t.toISOString().replace(`.000Z`,`Z`);break;case 6:r=Jt(t);break;case 7:r=String(t.getTime()/1e3);break;default:console.warn(`Missing timestamp format, using http date`,t),r=Jt(t);break}else if(n.isBigDecimalSchema()&&t)return t instanceof Nn?t.string:String(t);else if(n.isMapSchema()||n.isListSchema())throw Error(`@aws-sdk/core/protocols - xml serializer, cannot call _write() on List/Map schema, call writeList or writeMap() instead.`);else throw Error(`@aws-sdk/core/protocols - xml serializer, unhandled schema type for object value and schema: ${n.getName(!0)}`);if((n.isBooleanSchema()||n.isNumericSchema()||n.isBigIntegerSchema()||n.isBigDecimalSchema())&&(r=String(t)),n.isStringSchema()&&(r=t===void 0&&n.isIdempotencyToken()?pn():String(t)),r===null)throw Error(`Unhandled schema-value pair ${n.getName(!0)}=${t}`);return r}writeSimpleInto(e,t,n,r){let i=this.writeSimple(e,t),a=p.of(e),o=new Eo(i),[s,c]=this.getXmlnsAttribute(a,r);c&&n.addAttribute(s,c),n.addChildNode(o)}getXmlnsAttribute(e,t){let[n,r]=e.getMergedTraits().xmlNamespace??[];return r&&r!==t?[n?`xmlns:${n}`:`xmlns`,r]:[void 0,void 0]}},Io=class extends vo{settings;constructor(e){super(),this.settings=e}createSerializer(){let e=new Fo(this.settings);return e.setSerdeContext(this.serdeContext),e}createDeserializer(){let e=new Ao(this.settings);return e.setSerdeContext(this.serdeContext),e}},Lo=class extends Bn{codec;serializer;deserializer;mixin=new _o;constructor(e){super(e);let t={timestampFormat:{useTrait:!0,default:5},httpBindings:!0,xmlNamespace:e.xmlNamespace,serviceNamespace:e.defaultNamespace};this.codec=new Io(t),this.serializer=new Kn(this.codec.createSerializer(),t),this.deserializer=new Wn(this.codec.createDeserializer(),t),this.compositeErrorRegistry}getPayloadCodec(){return this.codec}getShapeId(){return`aws.protocols#restXml`}async serializeRequest(e,t,n){let r=await super.serializeRequest(e,t,n),i=p.of(e.input);if(!r.headers[`content-type`]){let e=this.mixin.resolveRestContentType(this.getDefaultContentType(),i);e&&(r.headers[`content-type`]=e)}return typeof r.body==`string`&&r.headers[`content-type`]===this.getDefaultContentType()&&!r.body.startsWith(``+r.body),r}async deserializeResponse(e,t,n){return super.deserializeResponse(e,t,n)}async handleError(e,t,n,r,i){let a=Po(n,r)??`Unknown`;if(this.mixin.compose(this.compositeErrorRegistry,a,this.options.defaultNamespace),r.Error&&typeof r.Error==`object`)for(let e of Object.keys(r.Error))r[e]=r.Error[e],e.toLowerCase()===`message`&&(r.message=r.Error[e]);r.RequestId&&!i.requestId&&(i.requestId=r.RequestId);let{errorSchema:o,errorMetadata:s}=await this.mixin.getErrorSchemaOrThrowBaseException(a,this.options.defaultNamespace,n,r,i),c=p.of(o),l=r.Error?.message??r.Error?.Message??r.message??r.Message??`UnknownError`,u=new((this.compositeErrorRegistry.getErrorCtor(o))??Error)(l);await this.deserializeHttpMessage(o,t,n,r);let d={};for(let[e,t]of c.structIterator()){let n=t.getMergedTraits().xmlName??e,i=r.Error?.[n]??r[n];d[e]=this.codec.createDeserializer().readSchema(t,i)}throw this.mixin.decorateServiceException(Object.assign(u,s,{$fault:c.getMergedTraits().error,message:l},d),r)}getDefaultContentType(){return`application/xml`}hasUnstructuredPayloadBinding(e){for(let[,t]of e.structIterator())if(t.getMergedTraits().httpPayload)return!(t.isStructSchema()||t.isMapSchema()||t.isListSchema());return!1}},Ro=`required`,zo=`fn`,Bo=`argv`,Vo=`ref`,Ho=!0,Uo=`isSet`,Wo=`booleanEquals`,Go=`error`,Ko=`endpoint`,qo=`tree`,Jo=`PartitionResult`,Yo=`getAttr`,Xo={[Ro]:!1,type:`string`},Zo={[Ro]:!0,default:!1,type:`boolean`},Qo={[Vo]:`Endpoint`},$o={[zo]:Wo,[Bo]:[{[Vo]:`UseFIPS`},!0]},es={[zo]:Wo,[Bo]:[{[Vo]:`UseDualStack`},!0]},ts={},ns={[zo]:Yo,[Bo]:[{[Vo]:Jo},`supportsFIPS`]},rs={[Vo]:Jo},is={[zo]:Wo,[Bo]:[!0,{[zo]:Yo,[Bo]:[rs,`supportsDualStack`]}]},as=[$o],os=[es],ss=[{[Vo]:`Region`}],cs={version:`1.0`,parameters:{Region:Xo,UseDualStack:Zo,UseFIPS:Zo,Endpoint:Xo},rules:[{conditions:[{[zo]:Uo,[Bo]:[Qo]}],rules:[{conditions:as,error:`Invalid Configuration: FIPS and custom endpoint are not supported`,type:Go},{conditions:os,error:`Invalid Configuration: Dualstack and custom endpoint are not supported`,type:Go},{endpoint:{url:Qo,properties:ts,headers:ts},type:Ko}],type:qo},{conditions:[{[zo]:Uo,[Bo]:ss}],rules:[{conditions:[{[zo]:`aws.partition`,[Bo]:ss,assign:Jo}],rules:[{conditions:[$o,es],rules:[{conditions:[{[zo]:Wo,[Bo]:[Ho,ns]},is],rules:[{endpoint:{url:`https://ec2-fips.{Region}.{PartitionResult#dualStackDnsSuffix}`,properties:ts,headers:ts},type:Ko}],type:qo},{error:`FIPS and DualStack are enabled, but this partition does not support one or both`,type:Go}],type:qo},{conditions:as,rules:[{conditions:[{[zo]:Wo,[Bo]:[ns,Ho]}],rules:[{conditions:[{[zo]:`stringEquals`,[Bo]:[{[zo]:Yo,[Bo]:[rs,`name`]},`aws-us-gov`]}],endpoint:{url:`https://ec2.{Region}.amazonaws.com`,properties:ts,headers:ts},type:Ko},{endpoint:{url:`https://ec2-fips.{Region}.{PartitionResult#dnsSuffix}`,properties:ts,headers:ts},type:Ko}],type:qo},{error:`FIPS is enabled but this partition does not support FIPS`,type:Go}],type:qo},{conditions:os,rules:[{conditions:[is],rules:[{endpoint:{url:`https://ec2.{Region}.{PartitionResult#dualStackDnsSuffix}`,properties:ts,headers:ts},type:Ko}],type:qo},{error:`DualStack is enabled but this partition does not support DualStack`,type:Go}],type:qo},{endpoint:{url:`https://ec2.{Region}.{PartitionResult#dnsSuffix}`,properties:ts,headers:ts},type:Ko}],type:qo}],type:qo},{error:`Invalid Configuration: Missing Region`,type:Go}]},ls=new er({size:50,params:[`Endpoint`,`Region`,`UseDualStack`,`UseFIPS`]}),us=(e,t={})=>ls.get(e,()=>Mr(cs,{endpointParams:e,logger:t.logger}));ar.aws=Vr;var ds=class e extends aa{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}},fs=`AllAvailabilityZones`,ps=`AttributeBooleanValue`,ms=`AssociateCarrierIpAddress`,hs=`AdditionalFlexibleNetworkInterfaces`,gs=`AvailableIpAddressCount`,_s=`AssignIpv6AddressOnCreation`,vs=`AttachInternetGateway`,ys=`AttachInternetGatewayRequest`,bs=`AdditionalInfo`,xs=`AssociationId`,Ss=`AttachmentId`,Cs=`AmiLaunchIndex`,ws=`AttachmentLimitType`,Ts=`AssociatePublicIpAddress`,Es=`AmazonProvidedIpv6CidrBlock`,Ds=`AutoRecoverySupported`,Os=`AssociateRouteTableRequest`,ks=`AssociateRouteTableResult`,As=`AssociateRouteTable`,js=`AllRegions`,Ms=`AssociatedResource`,Ns=`AutoRecovery`,Ps=`AssociationState`,Fs=`AuthorizeSecurityGroupEgress`,Is=`AuthorizeSecurityGroupEgressRequest`,Ls=`AuthorizeSecurityGroupEgressResult`,Rs=`AuthorizeSecurityGroupIngressRequest`,zs=`AuthorizeSecurityGroupIngressResult`,Bs=`AuthorizeSecurityGroupIngress`,Vs=`AmdSevSnp`,Hs=`ArchitectureTypeList`,Us=`AttachTime`,Ws=`AttachVolumeRequest`,Gs=`AttributeValue`,Ks=`AttachVolume`,qs=`AvailabilityZone`,Js=`AvailabilityZoneGeography`,Ys=`AvailabilityZoneGeographyList`,Xs=`AvailabilityZoneId`,Zs=`AvailabilityZoneList`,Qs=`AvailabilityZoneMessage`,$s=`AvailabilityZoneMessageList`,ec=`AvailabilityZoneSubGeography`,tc=`AvailabilityZoneSubGeographyList`,nc=`AvailabilityZones`,rc=`Accelerators`,ic=`Affinity`,ac=`Arn`,oc=`Architecture`,sc=`Associations`,cc=`Association`,lc=`Attribute`,uc=`Attachment`,dc=`Attachments`,fc=`BlobAttributeValue`,pc=`BaselineBandwidthInGbps`,mc=`BaselineBandwidthInMbps`,hc=`BlockDeviceMapping`,gc=`BlockDeviceMappingList`,_c=`BlockDeviceMappingRequestList`,vc=`BlockDeviceMappings`,yc=`BlockDurationMinutes`,bc=`BaselineIops`,xc=`BootMode`,Sc=`BootModeTypeList`,Cc=`BareMetal`,wc=`BlockPublicAccessStates`,Tc=`BurstablePerformanceSupported`,Ec=`BaselineThroughputInMBps`,Dc=`BandwidthWeighting`,Oc=`BandwidthWeightingTypeList`,kc=`BandwidthWeightings`,Ac=`CidrBlock`,jc=`CidrBlockAssociationSet`,Mc=`CapacityBlockId`,Nc=`CidrBlockState`,Pc=`CoreCountList`,Fc=`CoreCount`,Ic=`CpuCredits`,Lc=`CompletionDurationMinutes`,Rc=`CreationDate`,zc=`CarrierGatewayId`,Bc=`CurrentGeneration`,Vc=`CarrierIp`,Hc=`CurrentInstanceBootMode`,Uc=`CreateInternetGateway`,Wc=`CreateInternetGatewayRequest`,Gc=`CreateInternetGatewayResult`,Kc=`CreateImageRequest`,qc=`CreateImageResult`,Jc=`CidrIp`,Yc=`CidrIpv6`,Xc=`CidrIpv4`,Zc=`CoreInfo`,Qc=`CreateImage`,$c=`CreateKeyPair`,el=`CreateKeyPairRequest`,tl=`CoreNetworkArn`,nl=`CpuOptions`,rl=`CustomerOwnedIp`,il=`CustomerOwnedIpv4Pool`,al=`CpuOptionsRequest`,ol=`CreatePlacementGroup`,sl=`CreatePlacementGroupRequest`,cl=`CreatePlacementGroupResult`,ll=`CapacityReservationId`,ul=`CapacityReservationPreference`,dl=`CreateRouteRequest`,fl=`CapacityReservationResourceGroupArn`,pl=`CreateRouteResult`,ml=`CapacityReservationSpecificationResponse`,hl=`CapacityReservationSpecification`,gl=`CapacityReservationTarget`,_l=`CapacityReservationTargetResponse`,vl=`CreateRouteTableRequest`,yl=`CreateRouteTableResult`,bl=`CreateRouteTable`,xl=`CreateRoute`,Sl=`CreateSecurityGroup`,Cl=`CreateSecurityGroupRequest`,wl=`CreateSecurityGroupResult`,Tl=`CopySnapshotRequest`,El=`CopySnapshotRequestPSU`,Dl=`CopySnapshotResult`,Ol=`CreateSnapshotRequest`,kl=`CreateSubnetRequest`,Al=`CreateSubnetResult`,jl=`CreditSpecificationRequest`,Ml=`CopySnapshot`,Nl=`CreditSpecification`,Pl=`CreateSnapshot`,Fl=`CreateSubnet`,Il=`CurrentState`,Ll=`ClientToken`,Rl=`ConnectionTrackingConfiguration`,zl=`ConnectionTrackingSpecification`,Bl=`ConnectionTrackingSpecificationRequest`,Vl=`ConnectionTrackingSpecificationResponse`,Hl=`CompletionTime`,Ul=`CreateTime`,Wl=`CreateVolumeRequest`,Gl=`CreateVpcRequest`,Kl=`CreateVpcResult`,ql=`CreateVolume`,Jl=`CreateVpc`,Yl=`Code`,Xl=`Configured`,Zl=`Count`,Ql=`DisableApiStop`,$l=`DisableApiTermination`,eu=`DestinationAvailabilityZone`,tu=`DescribeAvailabilityZonesRequest`,nu=`DescribeAvailabilityZonesResult`,ru=`DescribeAvailabilityZones`,iu=`DestinationCidrBlock`,au=`DefaultConnectionTrackingConfiguration`,ou=`DefaultCores`,su=`DataEncryptionKeyId`,cu=`DefaultEnaQueueCountPerInterface`,lu=`DefaultForAz`,uu=`DedicatedHostsSupported`,du=`DeviceIndex`,fu=`DestinationIpv6CidrBlock`,pu=`DescribeInternetGatewaysRequest`,mu=`DescribeInternetGatewaysResult`,hu=`DescribeInternetGateways`,gu=`DiskInfoList`,_u=`DescribeImagesRequest`,vu=`DescribeImagesResult`,yu=`DescribeInstancesRequest`,bu=`DescribeInstancesResult`,xu=`DescribeInstanceTypesRequest`,Su=`DescribeInstanceTypesResult`,Cu=`DescribeInstanceTypes`,wu=`DescribeImages`,Tu=`DescribeInstances`,Eu=`DiskInfo`,Du=`DeleteKeyPair`,Ou=`DeleteKeyPairRequest`,ku=`DeleteKeyPairResult`,Au=`DescribeKeyPairsRequest`,ju=`DescribeKeyPairsResult`,Mu=`DescribeKeyPairs`,Nu=`DeviceName`,Pu=`DefaultNetworkCardIndex`,Fu=`DestinationOutpostArn`,Iu=`DhcpOptionsId`,Lu=`DeleteOnTermination`,Ru=`DeletePlacementGroup`,zu=`DeletePlacementGroupRequest`,Bu=`DescribePlacementGroupsRequest`,Vu=`DescribePlacementGroupsResult`,Hu=`DescribePlacementGroups`,Uu=`DestinationPrefixListId`,Wu=`DeregistrationProtection`,m=`DryRun`,Gu=`DescribeRegionsRequest`,Ku=`DescribeRegionsResult`,qu=`DescribeRouteTablesRequest`,Ju=`DescribeRouteTablesResult`,Yu=`DescribeRouteTables`,Xu=`DestinationRegion`,Zu=`DescribeRegions`,Qu=`DeleteSecurityGroup`,$u=`DeleteSecurityGroupRequest`,ed=`DeleteSecurityGroupResult`,td=`DescribeSecurityGroupsRequest`,nd=`DescribeSecurityGroupsResult`,rd=`DescribeSecurityGroups`,id=`DeleteSnapshotRequest`,ad=`DeleteSubnetRequest`,od=`DescribeSnapshotsRequest`,sd=`DescribeSnapshotsResult`,cd=`DescribeSubnetsRequest`,ld=`DescribeSubnetsResult`,ud=`DeleteSnapshot`,dd=`DeleteSubnet`,fd=`DescribeSnapshots`,pd=`DescribeSubnets`,md=`DefaultTcpEstablishedTimeout`,hd=`DefaultThreadsPerCore`,gd=`DeprecationTime`,_d=`DefaultUdpStreamTimeout`,vd=`DefaultUdpTimeout`,yd=`DefaultVCpus`,bd=`DeleteVolumeRequest`,xd=`DeleteVpcRequest`,Sd=`DescribeVolumesRequest`,Cd=`DescribeVolumesResult`,wd=`DescribeVpcsRequest`,Td=`DescribeVpcsResult`,Ed=`DetachVolumeRequest`,Dd=`DeleteVolume`,Od=`DeleteVpc`,kd=`DescribeVolumes`,Ad=`DescribeVpcs`,jd=`DetachVolume`,Md=`Description`,Nd=`Device`,Pd=`Disks`,Fd=`EbsBlockDevice`,Id=`ExecutableByStringList`,Ld=`ExecutableBy`,Rd=`EbsCardIndex`,zd=`EbsCardInfoList`,Bd=`EbsCardInfo`,Vd=`EbsCards`,Hd=`EncryptionControl`,Ud=`EnableDns64`,Wd=`ElasticFileSystem`,Gd=`ElasticFileSystemExclusion`,Kd=`ElasticGpuAssociation`,qd=`ElasticGpuAssociationId`,Jd=`ElasticGpuAssociationList`,Yd=`ElasticGpuAssociationState`,Xd=`ElasticGpuAssociationTime`,Zd=`ElasticGpuAssociations`,Qd=`ElasticGpuId`,$d=`ElasticGpuSpecification`,ef=`ElasticGpuSpecifications`,tf=`ElasticInferenceAccelerator`,nf=`ElasticInferenceAcceleratorAssociation`,rf=`ElasticInferenceAcceleratorAssociationId`,af=`ElasticInferenceAcceleratorAssociationList`,of=`ElasticInferenceAcceleratorAssociationState`,sf=`ElasticInferenceAcceleratorAssociationTime`,cf=`ElasticInferenceAcceleratorArn`,lf=`ElasticInferenceAcceleratorAssociations`,uf=`ElasticInferenceAccelerators`,df=`EbsInstanceBlockDevice`,ff=`EbsInstanceBlockDeviceSpecification`,pf=`EncryptionInTransitSupported`,mf=`EbsInfo`,hf=`EfaInfo`,gf=`EnableLniAtDeviceIndex`,_f=`EbsOptimized`,vf=`EbsOptimizedInfo`,yf=`EgressOnlyInternetGateway`,bf=`EgressOnlyInternetGatewayExclusion`,xf=`EgressOnlyInternetGatewayId`,Sf=`EnclaveOptionsRequest`,Cf=`EbsOptimizedSupport`,wf=`EnclaveOptions`,Tf=`EnablePrimaryIpv6`,Ef=`EnaQueueCount`,Df=`EnableResourceNameDnsAAAARecord`,Of=`EnableResourceNameDnsARecord`,kf=`EnaSrdEnabled`,Af=`EnaSrdSpecification`,jf=`EnaSrdSpecificationRequest`,Mf=`EnaSrdSupported`,Nf=`EnaSrdUdpEnabled`,Pf=`EnaSrdUdpSpecification`,Ff=`EnaSrdUdpSpecificationRequest`,If=`EfaSupported`,Lf=`EncryptionSupport`,Rf=`EnaSupport`,zf=`EndTime`,Bf=`ExecutableUsers`,Vf=`Ebs`,Hf=`Enabled`,Uf=`Encrypted`,Wf=`Endpoint`,Gf=`Force`,Kf=`FpgaDeviceInfo`,qf=`FpgaDeviceInfoList`,Jf=`FpgaDeviceMemoryInfo`,Yf=`FlexibleEnaQueuesSupport`,Xf=`FpgaInfo`,Zf=`FilterList`,Qf=`FromPort`,$f=`FastRestored`,ep=`FullSnapshotSizeInBytes`,tp=`FreeTierEligible`,np=`Filters`,rp=`Filter`,ip=`Fpgas`,ap=`Groups`,op=`GroupArn`,sp=`GetConsoleOutput`,cp=`GetConsoleOutputRequest`,lp=`GetConsoleOutputResult`,up=`GroupDescription`,dp=`GpuDeviceInfo`,fp=`GpuDeviceInfoList`,pp=`GpuDeviceMemoryInfo`,mp=`GatewayId`,hp=`GroupIdentifierList`,gp=`GroupIdStringList`,_p=`GpuInfo`,vp=`GroupId`,yp=`GroupIds`,bp=`GroupIdentifier`,xp=`GroupLongName`,Sp=`GroupName`,Cp=`GroupNameStringList`,wp=`GroupNames`,Tp=`GroupOwnerId`,Ep=`GpuPartitionSize`,Dp=`Geography`,Op=`Gpus`,kp=`HttpEndpoint`,Ap=`HostId`,jp=`HibernationOptions`,Mp=`HibernationOptionsRequest`,Np=`HttpProtocolIpv6`,Pp=`HttpPutResponseHopLimit`,Fp=`HostResourceGroupArn`,Ip=`HibernationSupported`,Lp=`HttpTokens`,Rp=`HostnameType`,zp=`Hibernate`,Bp=`Hypervisor`,Vp=`Id`,Hp=`Ipv6Addresses`,Up=`Ipv6AddressAttribute`,Wp=`Ipv6AddressCount`,Gp=`InstanceAttachmentEnaSrdSpecification`,Kp=`InstanceAttachmentEnaSrdUdpSpecification`,qp=`InferenceAcceleratorInfo`,Jp=`Ipv4AddressesPerInterface`,Yp=`Ipv6AddressesPerInterface`,Xp=`Ipv4AddressesPerSecondaryInterface`,Zp=`ImageAllowed`,Qp=`IpAddress`,$p=`Ipv6Address`,em=`InstanceBlockDeviceMapping`,tm=`InstanceBlockDeviceMappingList`,nm=`InstanceBlockDeviceMappingSpecification`,rm=`InstanceBlockDeviceMappingSpecificationList`,im=`Ipv6CidrBlock`,am=`Ipv6CidrBlockAssociationSet`,om=`Ipv6CidrBlockNetworkBorderGroup`,sm=`Ipv6CidrBlockState`,cm=`IncludeDeprecated`,lm=`InferenceDeviceInfo`,um=`InferenceDeviceInfoList`,dm=`InferenceDeviceMemoryInfo`,fm=`IncludeDisabled`,pm=`IsDefault`,mm=`IsEgress`,hm=`InternetGateway`,gm=`InternetGatewayAttachment`,_m=`InternetGatewayAttachmentList`,vm=`InternetGatewayBlockMode`,ym=`InternetGatewayExclusion`,bm=`InternetGatewayId`,xm=`InternetGatewayIdList`,Sm=`InternetGatewayIds`,Cm=`InternetGatewayList`,wm=`InternetGateways`,Tm=`InstanceId`,Em=`InstanceIpv6Address`,Dm=`InstanceIpv6AddressList`,Om=`InstanceInterruptionBehavior`,km=`IamInstanceProfile`,Am=`Ipv6IpamPoolId`,jm=`Ipv4IpamPoolId`,Mm=`InstanceIpv4PrefixList`,Nm=`InstanceIpv6PrefixList`,Pm=`IamInstanceProfileSpecification`,Fm=`InstanceIpv4Prefix`,Im=`InstanceIpv6Prefix`,Lm=`InstanceInitiatedShutdownBehavior`,Rm=`ImageIdStringList`,zm=`InstanceIdStringList`,Bm=`ImageId`,Vm=`ImageIds`,Hm=`InstanceIds`,Um=`ImportKeyPair`,Wm=`ImportKeyPairRequest`,Gm=`ImportKeyPairResult`,Km=`ImageLocation`,qm=`ImageList`,Jm=`InstanceLifecycle`,Ym=`InstanceList`,Xm=`InstanceMaintenanceOptions`,Zm=`InstanceMaintenanceOptionsRequest`,Qm=`InstanceMarketOptionsRequest`,$m=`InstanceMetadataOptionsRequest`,eh=`InstanceMetadataOptionsResponse`,th=`InstanceMarketOptions`,nh=`InstanceMetadataTags`,rh=`Ipv6Native`,ih=`InstanceNetworkInterface`,ah=`InstanceNetworkInterfaceAssociation`,oh=`InstanceNetworkInterfaceAttachment`,sh=`InstanceNetworkInterfaceList`,ch=`InstanceNetworkInterfaceSpecification`,lh=`InstanceNetworkInterfaceSpecificationList`,uh=`Ipv6NetmaskLength`,dh=`Ipv4NetmaskLength`,fh=`InstanceNetworkPerformanceOptions`,ph=`InstanceNetworkPerformanceOptionsRequest`,mh=`ImageOwnerAlias`,hh=`IpOwnerId`,gh=`InstanceOwnerId`,_h=`InstanceOwningService`,vh=`Ipv6PrefixCount`,yh=`Ipv4PrefixCount`,bh=`IpPermissionsEgress`,xh=`InstancePrivateIpAddress`,Sh=`InstancePrivateIpAddressList`,Ch=`IsPrimaryIpv6`,wh=`IncludePublicKey`,Th=`IpPermissionList`,Eh=`Ipv4PrefixList`,Dh=`Ipv6PrefixList`,Oh=`Ipv4PrefixSpecificationRequest`,kh=`Ipv6PrefixSpecificationRequest`,Ah=`Ipv6Prefixes`,jh=`IpPermissions`,Mh=`IpPermission`,Nh=`IpProtocol`,Ph=`Ipv6Prefix`,Fh=`Ipv6Pool`,Ih=`Ipv4Prefixes`,Lh=`Ipv4Prefix`,Rh=`IpRangeList`,zh=`Ipv6RangeList`,Bh=`IpRanges`,Vh=`IpRange`,Hh=`Ipv6Ranges`,Uh=`Ipv6Range`,Wh=`InstanceStateChange`,Gh=`InstanceStateChangeList`,Kh=`InstanceSecondaryInterfaceAttachment`,qh=`InstanceSecondaryInterfaceList`,Jh=`InstanceSecondaryInterfacePrivateIpAddress`,Yh=`InstanceSecondaryInterfacePrivateIpAddressList`,Xh=`InstanceSecondaryInterfacePrivateIpAddressListRequest`,Zh=`InstanceSecondaryInterfacePrivateIpAddressRequest`,Qh=`InstanceSecondaryInterfaceSpecificationListRequest`,$h=`InstanceSecondaryInterfaceSpecificationRequest`,eg=`InstanceSecondaryInterface`,tg=`InstanceStorageInfo`,ng=`InstanceStorageSupported`,rg=`ImdsSupport`,ig=`InstanceState`,ag=`IpSource`,og=`Ipv6Supported`,sg=`InstanceType`,cg=`InstanceTypeInfoList`,lg=`InstanceTypeInfo`,ug=`ImageType`,dg=`InstanceTenancy`,fg=`InstanceTypes`,pg=`InterfaceType`,mg=`Images`,hg=`Image`,gg=`Instance`,_g=`Instances`,vg=`Iops`,yg=`Key`,bg=`KeyFormat`,xg=`KeyFingerprint`,Sg=`KernelId`,Cg=`KmsKeyId`,wg=`KeyMaterial`,Tg=`KeyName`,Eg=`KeyNameStringList`,Dg=`KeyNames`,Og=`KeyPairs`,kg=`KeyPairId`,Ag=`KeyPairIdStringList`,jg=`KeyPairIds`,Mg=`KeyPairInfo`,Ng=`KeyPairList`,Pg=`KeyPair`,Fg=`KeyType`,Ig=`Kernel`,Lg=`LicenseConfigurationArn`,Rg=`LicenseConfigurationRequest`,zg=`LicenseConfiguration`,Bg=`LambdaExclusion`,Vg=`LogicalGpuCount`,Hg=`LocalGatewayId`,Ug=`LinkedGroupId`,Wg=`LicenseList`,Gg=`LastLaunchedTime`,Kg=`LicenseSpecifications`,qg=`LicenseSpecificationListRequest`,Jg=`LicenseSpecification`,Yg=`LaunchTemplate`,Xg=`LaunchTemplateId`,Zg=`LaunchTemplateName`,Qg=`LaunchTemplateSpecification`,$g=`LaunchTime`,e_=`Latest`,t_=`Lambda`,n_=`Licenses`,r_=`Location`,i_=`MultiAttachEnabled`,a_=`MediaAcceleratorInfo`,o_=`MacAddress`,s_=`MaximumBandwidthInMbps`,c_=`MapCustomerOwnedIpOnLaunch`,l_=`MaxCount`,u_=`MinCount`,d_=`MediaDeviceInfo`,f_=`MediaDeviceInfoList`,p_=`MediaDeviceMemoryInfo`,m_=`MaximumEbsAttachments`,h_=`MaximumEbsCards`,g_=`MaximumEfaInterfaces`,__=`MaximumEnaQueueCount`,v_=`MaximumEnaQueueCountPerInterface`,y_=`MaximumIops`,b_=`ModifyInstanceAttributeRequest`,x_=`ModifyInstanceAttribute`,S_=`MemoryInfo`,C_=`MaximumNetworkCards`,w_=`MaximumNetworkInterfaces`,T_=`MetadataOptions`,E_=`MaintenanceOptions`,D_=`MapPublicIpOnLaunch`,O_=`MaxPrice`,k_=`MaxResults`,A_=`MaximumSecondaryNetworkInterfaces`,j_=`ModificationState`,M_=`MarketType`,N_=`MaximumThroughputInMBps`,P_=`ModifyVolumeRequest`,F_=`ModifyVolumeResult`,I_=`ModifyVolume`,L_=`Main`,R_=`Manufacturer`,z_=`Managed`,B_=`Message`,V_=`Messages`,H_=`Mode`,U_=`Monitoring`,W_=`Name`,G_=`NetworkBorderGroup`,K_=`NetworkCards`,q_=`NetworkCardIndex`,J_=`NetworkCardInfoList`,Y_=`NetworkCardInfo`,X_=`NoDevice`,Z_=`NeuronDeviceCoreInfo`,Q_=`NeuronDeviceInfo`,$_=`NeuronDeviceInfoList`,ev=`NeuronDeviceMemoryInfo`,tv=`NeuronDevices`,nv=`NitroEnclavesSupport`,rv=`NatGateway`,iv=`NatGatewayExclusion`,av=`NatGatewayId`,ov=`NetworkInterfaceId`,sv=`NetworkInterfaces`,cv=`NetworkInfo`,lv=`NeuronInfo`,uv=`NetworkPerformanceOptions`,dv=`NetworkPerformance`,fv=`NoReboot`,pv=`NvmeSupport`,mv=`NitroTpmInfo`,hv=`NitroTpmSupport`,gv=`NitroTpmSupportedVersionsList`,_v=`NextToken`,vv=`NestedVirtualization`,yv=`Origin`,bv=`OutpostArn`,xv=`OwnerAlias`,Sv=`OwnerId`,Cv=`OptInStatus`,wv=`OriginalIops`,Tv=`OwnerIds`,Ev=`OriginalMultiAttachEnabled`,Dv=`OdbNetworkArn`,Ov=`OperatorRequest`,kv=`OperatorResponse`,Av=`OwnerStringList`,jv=`OriginalSize`,Mv=`OriginalThroughput`,Nv=`OriginalVolumeType`,Pv=`Operator`,Fv=`Output`,Iv=`Owners`,Lv=`Owner`,Rv=`Principal`,zv=`PeakBandwidthInGbps`,Bv=`ProductCodeId`,Vv=`ProductCodeList`,Hv=`ProductCodeType`,Uv=`PartitionCount`,Wv=`ProductCode`,Gv=`ProductCodes`,Kv=`PrivateDnsName`,qv=`PrivateDnsNameOptions`,Jv=`PrivateDnsNameOptionsOnLaunch`,Yv=`PrivateDnsNameOptionsRequest`,Xv=`PrivateDnsNameOptionsResponse`,Zv=`PublicDnsName`,Qv=`PlatformDetails`,$v=`PlacementGroup`,ey=`PlacementGroupInfo`,ty=`PlacementGroupIdStringList`,ny=`PlacementGroupList`,ry=`PlacementGroupStrategyList`,iy=`PlacementGroups`,ay=`PublicIp`,oy=`PrivateIpAddressCount`,sy=`PrivateIpAddressSpecification`,cy=`PrivateIpAddressSpecificationList`,ly=`PrivateIpAddress`,uy=`PrivateIpAddresses`,dy=`PublicIpAddress`,fy=`PublicIpv4Pool`,py=`PrimaryIpv6`,my=`ProcessorInfo`,hy=`PublicKey`,gy=`PublicKeyMaterial`,_y=`PrefixListId`,vy=`PrefixListIdList`,yy=`PrefixListIds`,by=`PartitionNumber`,xy=`PeeringStatus`,Sy=`PhcSupport`,Cy=`PreviousState`,wy=`PresignedUrl`,Ty=`PropagatingVgw`,Ey=`PropagatingVgwList`,Dy=`PropagatingVgws`,Oy=`ParentZoneId`,ky=`ParentZoneName`,Ay=`Platform`,jy=`Placement`,My=`Primary`,Ny=`Progress`,Py=`Public`,Fy=`Return`,Iy=`RestorableByUserIds`,Ly=`RestorableBy`,Ry=`RootDeviceName`,zy=`RootDeviceType`,By=`RootDeviceTypeList`,Vy=`RestoreExpiryTime`,Hy=`ResourceExclusions`,Uy=`RegionGeography`,Wy=`ReferencedGroupId`,Gy=`ReferencedGroupInfo`,Ky=`RegionGeographyList`,qy=`RunInstancesMonitoringEnabled`,Jy=`RebootInstancesRequest`,Yy=`RunInstancesRequest`,Xy=`RunInstancesUserData`,Zy=`RamdiskId`,Qy=`ReservationId`,$y=`RebootInstances`,eb=`RequesterId`,tb=`RunInstances`,nb=`RegionList`,rb=`ReservationList`,ib=`RouteList`,ab=`RebootMigrationSupport`,ob=`RebootMigration`,sb=`RegionName`,cb=`RegionNameStringList`,lb=`RegionNames`,ub=`ReferencedSecurityGroup`,db=`RevokeSecurityGroupEgress`,fb=`RevokeSecurityGroupEgressRequest`,pb=`RevokeSecurityGroupEgressResult`,mb=`RevokeSecurityGroupIngressRequest`,hb=`RevokeSecurityGroupIngressResult`,gb=`RevokeSecurityGroupIngress`,_b=`RevokedSecurityGroupRule`,vb=`RevokedSecurityGroupRuleList`,yb=`RevokedSecurityGroupRules`,bb=`RouteTableAssociation`,xb=`RouteTableAssociationId`,Sb=`RouteTableAssociationList`,Cb=`RouteTableAssociationState`,wb=`RouteTableId`,Tb=`RouteTableIdStringList`,Eb=`RouteTableIds`,Db=`RouteTableList`,Ob=`ResourceType`,kb=`RouteTable`,Ab=`RouteTables`,jb=`Ramdisk`,Mb=`Regions`,Nb=`Region`,Pb=`Reservations`,Fb=`Reservation`,Ib=`Route`,Lb=`Routes`,Rb=`SupportedAdditionalProcessorFeatureList`,zb=`SubnetArn`,Bb=`SupportedArchitectures`,Vb=`SupportedBootModes`,Hb=`SubnetCidrBlockState`,Ub=`SustainedClockSpeedInGhz`,Wb=`SourceDestCheck`,Gb=`SpreadDomain`,Kb=`SupportedFeatures`,qb=`SubGeography`,Jb=`SecurityGroupArn`,Yb=`SecurityGroupId`,Xb=`SecurityGroupIdStringList`,Zb=`SecurityGroupIds`,Qb=`SecurityGroupList`,$b=`SecurityGroupRules`,ex=`SecurityGroupRuleArn`,tx=`SecurityGroupRuleIds`,nx=`SecurityGroupRuleIdList`,rx=`SecurityGroupRuleId`,ix=`SecurityGroupRuleList`,ax=`SecurityGroupRule`,ox=`SecurityGroupStringList`,sx=`SecurityGroups`,cx=`SecurityGroup`,lx=`SubnetIds`,ux=`SubnetIpv6CidrBlockAssociation`,dx=`SubnetIpv6CidrBlockAssociationSet`,fx=`SizeInGB`,px=`SourceImageId`,mx=`SecondaryInterfaceId`,hx=`SourceInstanceId`,gx=`SizeInMiB`,_x=`SpotInstanceRequestId`,vx=`SourceImageRegion`,yx=`StartInstancesRequest`,bx=`StartInstancesResult`,xx=`StopInstancesRequest`,Sx=`StopInstancesResult`,Cx=`SnapshotIdStringList`,wx=`SubnetIdStringList`,Tx=`SpotInstanceType`,Ex=`SecondaryInterfaces`,Dx=`SecondaryInterface`,Ox=`SnapshotId`,kx=`SnapshotIds`,Ax=`StartingInstances`,jx=`StartInstances`,Mx=`StoppingInstances`,Nx=`StopInstances`,Px=`SubnetId`,Fx=`SnapshotLocation`,Ix=`SnapshotList`,Lx=`SpreadLevel`,Rx=`SubnetList`,zx=`SpotMarketOptions`,Bx=`StatusMessage`,Vx=`StateMessage`,Hx=`SecondaryNetworkId`,Ux=`SriovNetSupport`,Wx=`SecondaryNetworkSupported`,Gx=`SpotOptions`,Kx=`SkipOsShutdown`,qx=`SecondaryPrivateIpAddressCount`,Jx=`SupportedRootDeviceTypes`,Yx=`SourceRegion`,Xx=`StateReason`,Zx=`SourceSecurityGroupName`,Qx=`SourceSecurityGroupOwnerId`,$x=`SourceSnapshotId`,eS=`SecondarySubnetId`,tS=`SupportedStrategies`,nS=`StartTime`,rS=`StateTransitionReason`,iS=`SseType`,aS=`StorageTier`,oS=`SupportedUsageClasses`,sS=`SensitiveUserData`,cS=`SourceVolumeId`,lS=`SupportedVirtualizationTypes`,uS=`SupportedVersions`,dS=`Size`,fS=`Snapshots`,pS=`Snapshot`,mS=`State`,hS=`Status`,gS=`Strategy`,_S=`Subnet`,vS=`Subnets`,yS=`Tags`,bS=`TcpEstablishedTimeout`,xS=`TotalFpgaMemoryInMiB`,SS=`TransitGatewayId`,CS=`TotalGpuMemoryInMiB`,wS=`TerminateInstances`,TS=`TotalInferenceMemoryInMiB`,ES=`TerminateInstancesRequest`,DS=`TerminateInstancesResult`,OS=`TargetIops`,kS=`TerminatingInstances`,AS=`TagList`,jS=`TargetMultiAttachEnabled`,MS=`TotalMediaMemoryInMiB`,NS=`TotalNeuronDeviceMemoryInMiB`,PS=`ToPort`,FS=`ThreadsPerCore`,IS=`ThreadsPerCoreList`,LS=`TagSpecifications`,RS=`TotalSizeInGB`,zS=`TagSpecificationList`,BS=`TagSpecification`,VS=`TargetSize`,HS=`TpmSupport`,US=`TargetThroughput`,WS=`TransferType`,GS=`TargetVolumeType`,KS=`Tag`,qS=`Tenancy`,JS=`Throughput`,YS=`Timestamp`,XS=`Type`,ZS=`UsageClassTypeList`,QS=`UserData`,$S=`UserId`,eC=`UserIdGroupPairs`,tC=`UserIdGroupPairList`,nC=`UserIdGroupPair`,rC=`UnknownIpPermissions`,iC=`UsageOperation`,aC=`UsageOperationUpdateTime`,oC=`UdpStreamTimeout`,sC=`UdpTimeout`,cC=`Value`,lC=`VolumeAttachmentList`,uC=`VolumeAttachment`,dC=`VpcCidrBlockAssociation`,fC=`VpcCidrBlockAssociationSet`,pC=`VpcCidrBlockState`,mC=`VCpuInfo`,hC=`ValidCores`,gC=`VpcEncryptionControl`,_C=`VpcEncryptionControlConfiguration`,vC=`VpcEncryptionControlExclusion`,yC=`VpcEncryptionControlExclusions`,bC=`VpcEncryptionControlId`,xC=`VpcEndpointId`,SC=`VpcId`,CC=`VpcIpv6CidrBlockAssociation`,wC=`VpcIpv6CidrBlockAssociationSet`,TC=`VolumeInitializationRate`,EC=`VolumeIdStringList`,DC=`VpcIdStringList`,OC=`VolumeId`,kC=`VolumeIds`,AC=`VpcIds`,jC=`VpcLattice`,MC=`VpcLatticeExclusion`,NC=`VolumeList`,PC=`VpcList`,FC=`VolumeModification`,IC=`VirtualName`,LC=`VolumeOwnerId`,RC=`VpcPeeringConnectionId`,zC=`VpcPeeringExclusion`,BC=`VirtualPrivateGateway`,VC=`VirtualPrivateGatewayExclusion`,HC=`VpcPeering`,UC=`ValueStringList`,WC=`VolumeSize`,GC=`VolumeType`,KC=`VirtualizationTypeList`,qC=`ValidThreadsPerCore`,JC=`VirtualizationType`,YC=`ValidUntil`,XC=`Values`,ZC=`Version`,QC=`Volumes`,$C=`Volume`,ew=`Vpc`,tw=`Vpcs`,nw=`WorkloadsList`,rw=`Workloads`,iw=`ZoneId`,aw=`ZoneIdStringList`,ow=`ZoneIds`,sw=`ZoneName`,cw=`ZoneNameStringList`,lw=`ZoneNames`,uw=`ZoneType`,dw=`additionalFlexibleNetworkInterfaces`,fw=`availableIpAddressCount`,pw=`assignIpv6AddressOnCreation`,mw=`additionalInfo`,hw=`associationId`,gw=`attachmentId`,_w=`amiLaunchIndex`,vw=`attachmentLimitType`,yw=`associatePublicIpAddress`,bw=`amazonProvidedIpv6CidrBlock`,xw=`autoRecoverySupported`,Sw=`associatedResource`,Cw=`autoRecovery`,ww=`associationState`,Tw=`amdSevSnp`,Ew=`associationSet`,Dw=`attachmentSet`,Ow=`attachTime`,kw=`availabilityZone`,Aw=`availabilityZoneId`,jw=`availabilityZoneInfo`,Mw=`accelerators`,Nw=`affinity`,Pw=`arn`,Fw=`architecture`,Iw=`association`,Lw=`attachment`,Rw=`attribute`,zw=`baselineBandwidthInGbps`,Bw=`baselineBandwidthInMbps`,Vw=`blockDeviceMapping`,Hw=`baselineIops`,Uw=`bootMode`,Ww=`bareMetal`,Gw=`blockPublicAccessStates`,Kw=`burstablePerformanceSupported`,qw=`baselineThroughputInMBps`,Jw=`bandwidthWeighting`,Yw=`bandwidthWeightings`,Xw=`cidrBlock`,Zw=`cidrBlockAssociationSet`,Qw=`capacityBlockId`,$w=`cidrBlockState`,eT=`coreCount`,tT=`completionDurationMinutes`,nT=`creationDate`,rT=`carrierGatewayId`,iT=`currentGeneration`,aT=`carrierIp`,oT=`currentInstanceBootMode`,sT=`cidrIp`,cT=`cidrIpv6`,lT=`cidrIpv4`,uT=`coreInfo`,dT=`coreNetworkArn`,fT=`cpuOptions`,pT=`customerOwnedIp`,mT=`customerOwnedIpv4Pool`,hT=`capacityReservationId`,gT=`capacityReservationPreference`,_T=`capacityReservationResourceGroupArn`,vT=`capacityReservationSpecification`,yT=`capacityReservationTarget`,bT=`currentState`,xT=`clientToken`,ST=`connectionTrackingConfiguration`,CT=`completionTime`,wT=`createTime`,TT=`code`,ET=`configured`,DT=`count`,OT=`disableApiTermination`,kT=`destinationCidrBlock`,AT=`defaultCores`,jT=`dataEncryptionKeyId`,MT=`defaultEnaQueueCountPerInterface`,NT=`defaultForAz`,PT=`dedicatedHostsSupported`,FT=`deviceIndex`,IT=`destinationIpv6CidrBlock`,LT=`deviceName`,RT=`defaultNetworkCardIndex`,zT=`dnsName`,BT=`dhcpOptionsId`,VT=`deleteOnTermination`,HT=`destinationPrefixListId`,UT=`deregistrationProtection`,h=`dryRun`,WT=`destinationRegion`,GT=`defaultTcpEstablishedTimeout`,KT=`defaultThreadsPerCore`,qT=`deprecationTime`,JT=`defaultUdpStreamTimeout`,YT=`defaultUdpTimeout`,XT=`defaultVCpus`,ZT=`description`,QT=`device`,$T=`disks`,eE=`ebsCardIndex`,tE=`ebsCardSet`,nE=`encryptionControl`,rE=`enableDns64`,iE=`elasticFileSystem`,aE=`elasticGpuAssociationId`,oE=`elasticGpuAssociationState`,sE=`elasticGpuAssociationSet`,cE=`elasticGpuAssociationTime`,lE=`elasticGpuId`,uE=`elasticInferenceAcceleratorArn`,dE=`elasticInferenceAcceleratorAssociationId`,fE=`elasticInferenceAcceleratorAssociationState`,pE=`elasticInferenceAcceleratorAssociationSet`,mE=`elasticInferenceAcceleratorAssociationTime`,hE=`encryptionInTransitSupported`,gE=`ebsInfo`,_E=`efaInfo`,vE=`enableLniAtDeviceIndex`,yE=`ebsOptimized`,bE=`ebsOptimizedInfo`,xE=`egressOnlyInternetGateway`,SE=`egressOnlyInternetGatewayId`,CE=`ebsOptimizedSupport`,wE=`enclaveOptions`,TE=`enaQueueCount`,g=`ec2QueryName`,EE=`enableResourceNameDnsAAAARecord`,DE=`enableResourceNameDnsARecord`,OE=`enaSrdEnabled`,kE=`enaSrdSpecification`,AE=`enaSrdSupported`,jE=`enaSrdUdpEnabled`,ME=`enaSrdUdpSpecification`,NE=`efaSupported`,PE=`encryptionSupport`,FE=`enaSupport`,IE=`endTime`,LE=`ebs`,RE=`enabled`,zE=`encrypted`,BE=`flexibleEnaQueuesSupport`,VE=`fpgaInfo`,HE=`fromPort`,UE=`fastRestored`,WE=`fullSnapshotSizeInBytes`,GE=`freeTierEligible`,KE=`force`,qE=`fpgas`,JE=`groupArn`,YE=`groupDescription`,XE=`gatewayId`,ZE=`gpuInfo`,QE=`groupId`,$E=`groupLongName`,eD=`groupName`,tD=`groupOwnerId`,nD=`gpuPartitionSize`,rD=`geographySet`,iD=`groupSet`,aD=`gpus`,oD=`groups`,sD=`hypervisor`,cD=`httpEndpoint`,lD=`hostId`,uD=`hibernationOptions`,dD=`httpProtocolIpv6`,fD=`httpPutResponseHopLimit`,pD=`hostResourceGroupArn`,mD=`hibernationSupported`,hD=`httpTokens`,gD=`hostnameType`,_D=`id`,vD=`ipv6AddressAttribute`,yD=`ipv6AddressCount`,bD=`inferenceAcceleratorInfo`,xD=`ipv4AddressesPerInterface`,SD=`ipv6AddressesPerInterface`,CD=`ipv4AddressesPerSecondaryInterface`,wD=`ipv6AddressesSet`,TD=`imageAllowed`,ED=`ipAddress`,DD=`ipv6Address`,OD=`ipv6CidrBlock`,kD=`ipv6CidrBlockAssociationSet`,AD=`ipv6CidrBlockState`,jD=`isDefault`,MD=`isEgress`,ND=`internetGateway`,PD=`internetGatewayBlockMode`,FD=`internetGatewayId`,ID=`internetGatewaySet`,LD=`instanceId`,RD=`iamInstanceProfile`,zD=`instanceInitiatedShutdownBehavior`,BD=`imageId`,VD=`imageLocation`,HD=`instanceLifecycle`,UD=`instanceMetadataTags`,WD=`ipv6Native`,GD=`imageOwnerAlias`,KD=`imageOwnerId`,qD=`instanceOwnerId`,JD=`ipOwnerId`,YD=`instanceOwningService`,XD=`ipPermissionsEgress`,ZD=`isPrimaryIpv6`,QD=`ipv4PrefixSet`,$D=`ipv6PrefixSet`,eO=`ipProtocol`,tO=`ipPermissions`,nO=`ipv4Prefix`,rO=`ipv6Pool`,iO=`ipv6Prefix`,aO=`isPublic`,oO=`ipRanges`,sO=`ipv6Ranges`,cO=`instanceStorageInfo`,lO=`instanceStorageSupported`,uO=`imagesSet`,dO=`imageState`,fO=`imdsSupport`,pO=`instancesSet`,mO=`instanceState`,hO=`ipSource`,gO=`ipv6Supported`,_O=`instanceType`,vO=`instanceTypeSet`,yO=`idempotencyToken`,bO=`imageType`,xO=`instanceTenancy`,SO=`interfaceType`,CO=`iops`,_=`item`,wO=`key`,TO=`keyFingerprint`,EO=`kernelId`,DO=`kmsKeyId`,OO=`keyMaterial`,kO=`keyName`,AO=`keyPairId`,jO=`keySet`,MO=`keyType`,NO=`kernel`,PO=`licenseConfigurationArn`,FO=`logicalGpuCount`,IO=`localGatewayId`,LO=`linkedGroupId`,RO=`lastLaunchedTime`,zO=`licenseSet`,BO=`launchTime`,VO=`lambda`,HO=`multiAttachEnabled`,UO=`mediaAcceleratorInfo`,WO=`macAddress`,GO=`maximumBandwidthInMbps`,KO=`mapCustomerOwnedIpOnLaunch`,qO=`maximumEbsAttachments`,JO=`maximumEbsCards`,YO=`maximumEfaInterfaces`,XO=`maximumEnaQueueCount`,ZO=`maximumEnaQueueCountPerInterface`,QO=`maximumIops`,$O=`memoryInfo`,ek=`maximumNetworkCards`,tk=`maximumNetworkInterfaces`,nk=`metadataOptions`,rk=`maintenanceOptions`,ik=`mapPublicIpOnLaunch`,ak=`maxResults`,ok=`messageSet`,sk=`maximumSecondaryNetworkInterfaces`,ck=`modificationState`,lk=`maximumThroughputInMBps`,uk=`main`,dk=`manufacturer`,fk=`managed`,pk=`message`,mk=`monitoring`,hk=`mode`,gk=`name`,_k=`networkBorderGroup`,vk=`networkCards`,yk=`networkCardIndex`,bk=`noDevice`,xk=`neuronDevices`,Sk=`nitroEnclavesSupport`,Ck=`natGateway`,wk=`natGatewayId`,Tk=`networkInterfaceId`,Ek=`networkInterfaceSet`,Dk=`networkInterface`,Ok=`networkInfo`,kk=`neuronInfo`,Ak=`networkPerformanceOptions`,jk=`networkPerformance`,Mk=`noReboot`,Nk=`nvmeSupport`,Pk=`nitroTpmInfo`,Fk=`nitroTpmSupport`,Ik=`nextToken`,Lk=`nestedVirtualization`,Rk=`origin`,zk=`outpostArn`,Bk=`ownerAlias`,Vk=`ownerId`,Hk=`optInStatus`,Uk=`originalIops`,Wk=`originalMultiAttachEnabled`,Gk=`odbNetworkArn`,Kk=`originalSize`,qk=`originalThroughput`,Jk=`originalVolumeType`,Yk=`operator`,Xk=`output`,Zk=`principal`,Qk=`peakBandwidthInGbps`,$k=`productCodes`,eA=`partitionCount`,tA=`productCode`,nA=`privateDnsNameOptions`,rA=`privateDnsNameOptionsOnLaunch`,iA=`privateDnsName`,aA=`publicDnsName`,oA=`platformDetails`,sA=`placementGroup`,cA=`placementGroupInfo`,lA=`placementGroupSet`,uA=`publicIp`,dA=`privateIpAddressesSet`,fA=`privateIpAddressSet`,pA=`privateIpAddress`,mA=`publicIpv4Pool`,hA=`processorInfo`,gA=`publicKey`,_A=`publicKeyMaterial`,vA=`prefixListId`,yA=`prefixListIds`,bA=`partitionNumber`,xA=`peeringStatus`,SA=`phcSupport`,CA=`previousState`,wA=`presignedUrl`,TA=`propagatingVgwSet`,EA=`parentZoneId`,DA=`parentZoneName`,OA=`platform`,kA=`placement`,AA=`primary`,jA=`progress`,MA=`return`,NA=`rootDeviceName`,PA=`rootDeviceType`,FA=`restoreExpiryTime`,IA=`regionEndpoint`,LA=`resourceExclusions`,RA=`referencedGroupId`,zA=`referencedGroupInfo`,BA=`reservationId`,VA=`ramdiskId`,HA=`regionInfo`,UA=`requesterId`,WA=`rebootMigrationSupport`,GA=`rebootMigration`,KA=`regionName`,qA=`revokedSecurityGroupRuleSet`,JA=`reservationSet`,YA=`routeSet`,XA=`routeTableAssociationId`,ZA=`routeTableId`,QA=`routeTableSet`,$A=`resourceType`,ej=`routeTable`,tj=`ramdisk`,nj=`reason`,rj=`smithy.ts.sdk.synthetic.com.amazonaws.ec2`,ij=`supportedArchitectures`,aj=`subnetArn`,oj=`supportedBootModes`,sj=`sustainedClockSpeedInGhz`,cj=`sourceDestCheck`,lj=`spreadDomain`,uj=`supportedFeatures`,dj=`securityGroupArn`,fj=`securityGroupInfo`,pj=`securityGroupRuleArn`,mj=`securityGroupRuleId`,hj=`securityGroupRuleSet`,gj=`subGeographySet`,_j=`sizeInGB`,vj=`sourceInstanceId`,yj=`secondaryInterfaceId`,bj=`sourceImageId`,xj=`sizeInMiB`,Sj=`sourceImageRegion`,Cj=`spotInstanceRequestId`,wj=`secondaryInterfaceSet`,Tj=`snapshotId`,Ej=`subnetId`,Dj=`spreadLevel`,Oj=`statusMessage`,kj=`stateMessage`,Aj=`secondaryNetworkId`,jj=`secondaryNetworkSupported`,Mj=`sriovNetSupport`,Nj=`secondaryPrivateIpAddressCount`,Pj=`supportedRootDeviceTypes`,Fj=`stateReason`,Ij=`sourceSecurityGroupName`,Lj=`sourceSecurityGroupOwnerId`,Rj=`secondarySubnetId`,zj=`snapshotSet`,Bj=`subnetSet`,Vj=`supportedStrategies`,Hj=`startTime`,Uj=`sseType`,Wj=`storageTier`,Gj=`supportedUsageClasses`,Kj=`sourceVolumeId`,qj=`supportedVirtualizationTypes`,Jj=`supportedVersions`,Yj=`size`,Xj=`state`,Zj=`status`,Qj=`strategy`,$j=`subnet`,eM=`tenancy`,tM=`tcpEstablishedTimeout`,nM=`totalFpgaMemoryInMiB`,rM=`transitGatewayId`,iM=`totalGpuMemoryInMiB`,aM=`totalInferenceMemoryInMiB`,oM=`targetIops`,sM=`targetMultiAttachEnabled`,cM=`totalMediaMemoryInMiB`,lM=`totalNeuronDeviceMemoryInMiB`,uM=`toPort`,dM=`threadsPerCore`,fM=`tagSet`,pM=`totalSizeInGB`,mM=`targetSize`,hM=`tpmSupport`,gM=`targetThroughput`,_M=`transferType`,vM=`targetVolumeType`,yM=`throughput`,bM=`timestamp`,xM=`type`,SM=`userData`,CM=`userId`,wM=`unknownIpPermissionSet`,TM=`usageOperation`,EM=`usageOperationUpdateTime`,DM=`udpStreamTimeout`,OM=`udpTimeout`,kM=`value`,AM=`vCpuInfo`,jM=`validCores`,MM=`vpcEncryptionControlId`,NM=`vpcId`,PM=`volumeInitializationRate`,FM=`volumeId`,IM=`vpcLattice`,LM=`volumeModification`,RM=`virtualName`,zM=`volumeOwnerId`,BM=`vpcPeeringConnectionId`,VM=`virtualPrivateGateway`,HM=`vpcPeering`,UM=`volumeSet`,WM=`volumeSize`,GM=`vpcSet`,KM=`volumeType`,qM=`validThreadsPerCore`,JM=`virtualizationType`,YM=`version`,XM=`vpc`,ZM=`workloadSet`,v=`xmlName`,QM=`zoneId`,$M=`zoneName`,eN=`zoneState`,tN=`zoneType`,y=`com.amazonaws.ec2`,nN=At.for(rj),rN=[-3,rj,`EC2ServiceException`,0,[],[]];nN.registerError(rN,ds);var iN=[nN],aN=[0,y,El,8,0],oN=[0,y,Xy,8,0],sN=[0,y,sS,8,0],cN=[3,y,Os,0,[wb,mp,fy,m,Px],[[0,{[g]:`RouteTableId`,[v]:ZA}],0,0,[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`SubnetId`,[v]:Ej}]],1],lN=[3,y,ks,0,[xs,Ps],[[0,{[g]:`AssociationId`,[v]:hw}],[()=>XI,{[g]:`AssociationState`,[v]:ww}]]],uN=[3,y,ys,0,[bm,SC,m],[[0,{[g]:`InternetGatewayId`,[v]:FD}],[0,{[g]:`VpcId`,[v]:NM}],[2,{[g]:`DryRun`,[v]:h}]],2],dN=[3,y,Ws,0,[Nd,Tm,OC,Rd,m],[0,0,0,1,[2,{[g]:`DryRun`,[v]:h}]],3],fN=[3,y,ps,0,[cC],[[2,{[g]:`Value`,[v]:kM}]]],pN=[3,y,Gs,0,[cC],[[0,{[g]:`Value`,[v]:kM}]]],mN=[3,y,Is,0,[vp,LS,m,Zx,Qx,Nh,Qf,PS,Jc,jh],[[0,{[g]:`GroupId`,[v]:QE}],[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`SourceSecurityGroupName`,[v]:Ij}],[0,{[g]:`SourceSecurityGroupOwnerId`,[v]:Lj}],[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[0,{[g]:`CidrIp`,[v]:sT}],[()=>bR,{[g]:`IpPermissions`,[v]:tO}]],1],hN=[3,y,Ls,0,[Fy,$b],[[2,{[g]:`Return`,[v]:MA}],[()=>tz,{[g]:`SecurityGroupRuleSet`,[v]:hj}]]],gN=[3,y,Rs,0,[Jc,Qf,vp,Sp,jh,Nh,Zx,Qx,PS,LS,m],[0,1,0,0,[()=>bR,0],0,0,0,1,[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}]]],_N=[3,y,zs,0,[Fy,$b],[[2,{[g]:`Return`,[v]:MA}],[()=>tz,{[g]:`SecurityGroupRuleSet`,[v]:hj}]]],vN=[3,y,qs,0,[Cv,V_,sb,sw,iw,Sp,G_,uw,ky,Oy,xp,Dp,qb,mS],[[0,{[g]:`OptInStatus`,[v]:Hk}],[()=>ML,{[g]:`MessageSet`,[v]:ok}],[0,{[g]:`RegionName`,[v]:KA}],[0,{[g]:`ZoneName`,[v]:$M}],[0,{[g]:`ZoneId`,[v]:QM}],[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`NetworkBorderGroup`,[v]:_k}],[0,{[g]:`ZoneType`,[v]:tN}],[0,{[g]:`ParentZoneName`,[v]:DA}],[0,{[g]:`ParentZoneId`,[v]:EA}],[0,{[g]:`GroupLongName`,[v]:$E}],[()=>AL,{[g]:`GeographySet`,[v]:rD}],[()=>NL,{[g]:`SubGeographySet`,[v]:gj}],[0,{[g]:`ZoneState`,[v]:eN}]]],yN=[3,y,Js,0,[W_],[[0,{[g]:`Name`,[v]:gk}]]],bN=[3,y,Qs,0,[B_],[[0,{[g]:`Message`,[v]:pk}]]],xN=[3,y,ec,0,[W_],[[0,{[g]:`Name`,[v]:gk}]]],SN=[3,y,fc,0,[cC],[[21,{[g]:`Value`,[v]:kM}]]],CN=[3,y,hc,0,[Vf,X_,Nu,IC],[[()=>VP,{[g]:`Ebs`,[v]:LE}],[0,{[g]:`NoDevice`,[v]:bk}],[0,{[g]:`DeviceName`,[v]:LT}],[0,{[g]:`VirtualName`,[v]:RM}]]],wN=[3,y,wc,0,[vm],[[0,{[g]:`InternetGatewayBlockMode`,[v]:PD}]]],TN=[3,y,hl,0,[ul,gl],[0,()=>DN]],EN=[3,y,ml,0,[ul,gl],[[0,{[g]:`CapacityReservationPreference`,[v]:gT}],[()=>ON,{[g]:`CapacityReservationTarget`,[v]:yT}]]],DN=[3,y,gl,0,[ll,fl],[0,0]],ON=[3,y,_l,0,[ll,fl],[[0,{[g]:`CapacityReservationId`,[v]:hT}],[0,{[g]:`CapacityReservationResourceGroupArn`,[v]:_T}]]],kN=[3,y,Bl,0,[bS,oC,sC],[1,1,1]],AN=[3,y,Vl,0,[bS,oC,sC],[[1,{[g]:`TcpEstablishedTimeout`,[v]:tM}],[1,{[g]:`UdpStreamTimeout`,[v]:DM}],[1,{[g]:`UdpTimeout`,[v]:OM}]]],jN=[3,y,Tl,0,[Yx,$x,Md,Fu,Xu,Uf,Cg,wy,LS,Lc,eu,m],[0,0,0,0,[0,{[g]:`DestinationRegion`,[v]:WT}],[2,{[g]:`Encrypted`,[v]:zE}],[0,{[g]:`KmsKeyId`,[v]:DO}],[()=>aN,{[g]:`PresignedUrl`,[v]:wA}],[()=>uz,{[v]:BS}],1,0,[2,{[g]:`DryRun`,[v]:h}]],2],MN=[3,y,Dl,0,[yS,Ox],[[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`SnapshotId`,[v]:Tj}]]],NN=[3,y,nl,0,[Fc,FS,Vs,vv],[[1,{[g]:`CoreCount`,[v]:eT}],[1,{[g]:`ThreadsPerCore`,[v]:dM}],[0,{[g]:`AmdSevSnp`,[v]:Tw}],[0,{[g]:`NestedVirtualization`,[v]:Lk}]]],PN=[3,y,al,0,[Fc,FS,Vs,vv],[1,1,0,0]],FN=[3,y,Kc,0,[Tm,W_,LS,Fx,m,Md,fv,vc],[[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`Name`,[v]:gk}],[()=>uz,{[v]:BS}],0,[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`Description`,[v]:ZT}],[2,{[g]:`NoReboot`,[v]:Mk}],[()=>IL,{[g]:`BlockDeviceMapping`,[v]:Vw}]],2],IN=[3,y,qc,0,[Bm],[[0,{[g]:`ImageId`,[v]:BD}]]],LN=[3,y,Wc,0,[LS,m],[[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}]]],RN=[3,y,Gc,0,[hm],[[()=>ZF,{[g]:`InternetGateway`,[v]:ND}]]],zN=[3,y,el,0,[Tg,Fg,LS,bg,m],[0,0,[()=>uz,{[v]:BS}],0,[2,{[g]:`DryRun`,[v]:h}]],1],BN=[3,y,sl,0,[Uv,LS,Lx,Ug,Pv,m,Sp,gS],[1,[()=>uz,{[v]:BS}],0,0,()=>wI,[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`Strategy`,[v]:Qj}]]],VN=[3,y,cl,0,[$v],[[()=>DI,{[g]:`PlacementGroup`,[v]:sA}]]],HN=[3,y,dl,0,[wb,Uu,xC,SS,Hg,zc,tl,Dv,m,iu,mp,fu,xf,Tm,ov,RC,av],[[0,{[g]:`RouteTableId`,[v]:ZA}],0,0,0,0,0,0,0,[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`DestinationCidrBlock`,[v]:kT}],[0,{[g]:`GatewayId`,[v]:XE}],[0,{[g]:`DestinationIpv6CidrBlock`,[v]:IT}],[0,{[g]:`EgressOnlyInternetGatewayId`,[v]:SE}],[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`NetworkInterfaceId`,[v]:Tk}],[0,{[g]:`VpcPeeringConnectionId`,[v]:BM}],[0,{[g]:`NatGatewayId`,[v]:wk}]],1],UN=[3,y,pl,0,[Fy],[[2,{[g]:`Return`,[v]:MA}]]],WN=[3,y,vl,0,[SC,LS,Ll,m],[[0,{[g]:`VpcId`,[v]:NM}],[()=>uz,{[v]:BS}],[0,4],[2,{[g]:`DryRun`,[v]:h}]],1],GN=[3,y,yl,0,[kb,Ll],[[()=>JI,{[g]:`RouteTable`,[v]:ej}],[0,{[g]:`ClientToken`,[v]:xT}]]],KN=[3,y,Cl,0,[Md,Sp,SC,LS,m],[[0,{[v]:up}],0,0,[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}]],2],qN=[3,y,wl,0,[vp,yS,Jb],[[0,{[g]:`GroupId`,[v]:QE}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`SecurityGroupArn`,[v]:dj}]]],JN=[3,y,Ol,0,[OC,Md,bv,LS,r_,m],[0,0,0,[()=>uz,{[v]:BS}],0,[2,{[g]:`DryRun`,[v]:h}]],1],YN=[3,y,kl,0,[SC,LS,qs,Xs,Ac,im,bv,rh,jm,dh,Am,uh,m],[0,[()=>uz,{[v]:BS}],0,0,0,0,0,2,0,1,0,1,[2,{[g]:`DryRun`,[v]:h}]],1],XN=[3,y,Al,0,[_S],[[()=>cL,{[g]:`Subnet`,[v]:$j}]]],ZN=[3,y,Wl,0,[qs,Xs,Uf,vg,Cg,bv,dS,Ox,GC,LS,i_,JS,Ll,TC,Pv,m],[0,0,[2,{[g]:`Encrypted`,[v]:zE}],1,0,0,1,0,0,[()=>uz,{[v]:BS}],2,1,[0,4],1,()=>wI,[2,{[g]:`DryRun`,[v]:h}]]],QN=[3,y,Gl,0,[Ac,Fh,im,jm,dh,Am,uh,om,gC,LS,m,dg,Es],[0,0,0,0,1,0,1,0,()=>wL,[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`InstanceTenancy`,[v]:xO}],[2,{[g]:`AmazonProvidedIpv6CidrBlock`,[v]:bw}]]],$N=[3,y,Kl,0,[ew],[[()=>bL,{[g]:`Vpc`,[v]:XM}]]],eP=[3,y,jl,0,[Ic],[0],1],tP=[3,y,au,0,[md,vd,_d],[[1,{[g]:`DefaultTcpEstablishedTimeout`,[v]:GT}],[1,{[g]:`DefaultUdpTimeout`,[v]:YT}],[1,{[g]:`DefaultUdpStreamTimeout`,[v]:JT}]]],nP=[3,y,Ou,0,[Tg,kg,m],[0,0,[2,{[g]:`DryRun`,[v]:h}]]],rP=[3,y,ku,0,[Fy,kg],[[2,{[g]:`Return`,[v]:MA}],[0,{[g]:`KeyPairId`,[v]:AO}]]],iP=[3,y,zu,0,[Sp,m],[[0,{[g]:`GroupName`,[v]:eD}],[2,{[g]:`DryRun`,[v]:h}]],1],aP=[3,y,$u,0,[vp,Sp,m],[0,0,[2,{[g]:`DryRun`,[v]:h}]]],oP=[3,y,ed,0,[Fy,vp],[[2,{[g]:`Return`,[v]:MA}],[0,{[g]:`GroupId`,[v]:QE}]]],sP=[3,y,id,0,[Ox,m],[0,[2,{[g]:`DryRun`,[v]:h}]],1],cP=[3,y,ad,0,[Px,m],[0,[2,{[g]:`DryRun`,[v]:h}]],1],lP=[3,y,bd,0,[OC,m],[0,[2,{[g]:`DryRun`,[v]:h}]],1],uP=[3,y,xd,0,[SC,m],[0,[2,{[g]:`DryRun`,[v]:h}]],1],dP=[3,y,tu,0,[lw,ow,fs,m,np],[[()=>Tz,{[v]:sw}],[()=>wz,{[v]:iw}],2,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],fP=[3,y,nu,0,[nc],[[()=>jL,{[g]:`AvailabilityZoneInfo`,[v]:jw}]]],pP=[3,y,_u,0,[Bf,Vm,Iv,cm,fm,k_,_v,m,np],[[()=>GL,{[v]:Ld}],[()=>QL,{[v]:Bm}],[()=>PR,{[v]:Lv}],2,2,1,0,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],mP=[3,y,vu,0,[_v,mg],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>$L,{[g]:`ImagesSet`,[v]:uO}]]],hP=[3,y,yu,0,[Hm,m,np,_v,k_],[[()=>rR,{[v]:Tm}],[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}],[0,{[g]:`NextToken`,[v]:Ik}],[1,{[g]:`MaxResults`,[v]:ak}]]],gP=[3,y,bu,0,[_v,Pb],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>GR,{[g]:`ReservationSet`,[v]:JA}]]],_P=[3,y,xu,0,[m,fg,np,k_,_v],[2,[64,{[v]:sg}],[()=>KL,{[v]:rp}],1,0]],vP=[3,y,Su,0,[fg,_v],[[()=>gR,{[g]:`InstanceTypeSet`,[v]:vO}],[0,{[g]:`NextToken`,[v]:Ik}]]],yP=[3,y,pu,0,[_v,k_,m,Sm,np],[0,1,[2,{[g]:`DryRun`,[v]:h}],[()=>vR,{[g]:`InternetGatewayId`,[v]:FD}],[()=>KL,{[v]:rp}]]],bP=[3,y,mu,0,[wm,_v],[[()=>yR,{[g]:`InternetGatewaySet`,[v]:ID}],[0,{[g]:`NextToken`,[v]:Ik}]]],xP=[3,y,Au,0,[Dg,jg,wh,m,np],[[()=>TR,{[v]:Tg}],[()=>ER,{[v]:kg}],2,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],SP=[3,y,ju,0,[Og],[[()=>DR,{[g]:`KeySet`,[v]:jO}]]],CP=[3,y,Bu,0,[yp,m,wp,np],[[()=>FR,{[v]:vp}],[2,{[g]:`DryRun`,[v]:h}],[64,{[g]:`GroupName`,[v]:eD}],[()=>KL,{[v]:rp}]]],wP=[3,y,Vu,0,[iy],[[()=>IR,{[g]:`PlacementGroupSet`,[v]:lA}]]],TP=[3,y,Gu,0,[lb,js,m,np],[[()=>WR,{[v]:sb}],2,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],EP=[3,y,Ku,0,[Mb],[[()=>UR,{[g]:`RegionInfo`,[v]:HA}]]],DP=[3,y,qu,0,[_v,k_,m,Eb,np],[0,1,[2,{[g]:`DryRun`,[v]:h}],[()=>XR,{[v]:wb}],[()=>KL,{[v]:rp}]]],OP=[3,y,Ju,0,[Ab,_v],[[()=>ZR,{[g]:`RouteTableSet`,[v]:QA}],[0,{[g]:`NextToken`,[v]:Ik}]]],kP=[3,y,td,0,[yp,wp,_v,k_,m,np],[[()=>XL,{[v]:vp}],[()=>ZL,{[v]:Sp}],0,1,[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],AP=[3,y,nd,0,[_v,sx],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>$R,{[g]:`SecurityGroupInfo`,[v]:fj}]]],jP=[3,y,od,0,[k_,_v,Tv,Iy,kx,m,np],[1,0,[()=>PR,{[v]:Lv}],[64,{[v]:Ly}],[()=>rz,{[v]:Ox}],[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}]]],MP=[3,y,sd,0,[_v,fS],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>iz,{[g]:`SnapshotSet`,[v]:zj}]]],NP=[3,y,cd,0,[np,lx,_v,k_,m],[[()=>KL,{[v]:rp}],[()=>az,{[v]:Px}],0,1,[2,{[g]:`DryRun`,[v]:h}]]],PP=[3,y,ld,0,[_v,vS],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>sz,{[g]:`SubnetSet`,[v]:Bj}]]],FP=[3,y,Sd,0,[kC,m,np,_v,k_],[[()=>_z,{[v]:OC}],[2,{[g]:`DryRun`,[v]:h}],[()=>KL,{[v]:rp}],[0,{[g]:`NextToken`,[v]:Ik}],[1,{[g]:`MaxResults`,[v]:ak}]]],IP=[3,y,Cd,0,[_v,QC],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>vz,{[g]:`VolumeSet`,[v]:UM}]]],LP=[3,y,wd,0,[np,AC,_v,k_,m],[[()=>KL,{[v]:rp}],[()=>bz,{[v]:SC}],0,1,[2,{[g]:`DryRun`,[v]:h}]]],RP=[3,y,Td,0,[_v,tw],[[0,{[g]:`NextToken`,[v]:Ik}],[()=>Sz,{[g]:`VpcSet`,[v]:GM}]]],zP=[3,y,Ed,0,[OC,Nd,Gf,Tm,m],[0,0,2,0,[2,{[g]:`DryRun`,[v]:h}]],1],BP=[3,y,Eu,0,[fx,Zl,XS],[[1,{[g]:`SizeInGB`,[v]:_j}],[1,{[g]:`Count`,[v]:DT}],[0,{[g]:`Type`,[v]:xM}]]],VP=[3,y,Fd,0,[Lu,vg,Ox,WC,GC,Cg,JS,bv,qs,Uf,TC,Xs,Rd],[[2,{[g]:`DeleteOnTermination`,[v]:VT}],[1,{[g]:`Iops`,[v]:CO}],[0,{[g]:`SnapshotId`,[v]:Tj}],[1,{[g]:`VolumeSize`,[v]:WM}],[0,{[g]:`VolumeType`,[v]:KM}],[0,{[g]:`KmsKeyId`,[v]:DO}],[1,{[g]:`Throughput`,[v]:yM}],[0,{[g]:`OutpostArn`,[v]:zk}],[0,{[g]:`AvailabilityZone`,[v]:kw}],[2,{[g]:`Encrypted`,[v]:zE}],1,0,1]],HP=[3,y,Bd,0,[Rd,mc,Ec,bc,s_,N_,y_],[[1,{[g]:`EbsCardIndex`,[v]:eE}],[1,{[g]:`BaselineBandwidthInMbps`,[v]:Bw}],[1,{[g]:`BaselineThroughputInMBps`,[v]:qw}],[1,{[g]:`BaselineIops`,[v]:Hw}],[1,{[g]:`MaximumBandwidthInMbps`,[v]:GO}],[1,{[g]:`MaximumThroughputInMBps`,[v]:lk}],[1,{[g]:`MaximumIops`,[v]:QO}]]],UP=[3,y,mf,0,[Cf,Lf,vf,pv,m_,ws,h_,Vd],[[0,{[g]:`EbsOptimizedSupport`,[v]:CE}],[0,{[g]:`EncryptionSupport`,[v]:PE}],[()=>KP,{[g]:`EbsOptimizedInfo`,[v]:bE}],[0,{[g]:`NvmeSupport`,[v]:Nk}],[1,{[g]:`MaximumEbsAttachments`,[v]:qO}],[0,{[g]:`AttachmentLimitType`,[v]:vw}],[1,{[g]:`MaximumEbsCards`,[v]:JO}],[()=>BL,{[g]:`EbsCardSet`,[v]:tE}]]],WP=[3,y,df,0,[Us,Lu,hS,OC,Ms,LC,Pv,Rd],[[4,{[g]:`AttachTime`,[v]:Ow}],[2,{[g]:`DeleteOnTermination`,[v]:VT}],[0,{[g]:`Status`,[v]:Zj}],[0,{[g]:`VolumeId`,[v]:FM}],[0,{[g]:`AssociatedResource`,[v]:Sw}],[0,{[g]:`VolumeOwnerId`,[v]:zM}],[()=>TI,{[g]:`Operator`,[v]:Yk}],[1,{[g]:`EbsCardIndex`,[v]:eE}]]],GP=[3,y,ff,0,[OC,Lu],[[0,{[g]:`VolumeId`,[v]:FM}],[2,{[g]:`DeleteOnTermination`,[v]:VT}]]],KP=[3,y,vf,0,[mc,Ec,bc,s_,N_,y_],[[1,{[g]:`BaselineBandwidthInMbps`,[v]:Bw}],[1,{[g]:`BaselineThroughputInMBps`,[v]:qw}],[1,{[g]:`BaselineIops`,[v]:Hw}],[1,{[g]:`MaximumBandwidthInMbps`,[v]:GO}],[1,{[g]:`MaximumThroughputInMBps`,[v]:lk}],[1,{[g]:`MaximumIops`,[v]:QO}]]],qP=[3,y,hf,0,[g_],[[1,{[g]:`MaximumEfaInterfaces`,[v]:YO}]]],JP=[3,y,Kd,0,[Qd,qd,Yd,Xd],[[0,{[g]:`ElasticGpuId`,[v]:lE}],[0,{[g]:`ElasticGpuAssociationId`,[v]:aE}],[0,{[g]:`ElasticGpuAssociationState`,[v]:oE}],[0,{[g]:`ElasticGpuAssociationTime`,[v]:cE}]]],YP=[3,y,$d,0,[XS],[0],1],XP=[3,y,tf,0,[XS,Zl],[0,1],1],ZP=[3,y,nf,0,[cf,rf,of,sf],[[0,{[g]:`ElasticInferenceAcceleratorArn`,[v]:uE}],[0,{[g]:`ElasticInferenceAcceleratorAssociationId`,[v]:dE}],[0,{[g]:`ElasticInferenceAcceleratorAssociationState`,[v]:fE}],[4,{[g]:`ElasticInferenceAcceleratorAssociationTime`,[v]:mE}]]],QP=[3,y,jf,0,[kf,Pf],[2,()=>$P]],$P=[3,y,Ff,0,[Nf],[2]],eF=[3,y,wf,0,[Hf],[[2,{[g]:`Enabled`,[v]:RE}]]],tF=[3,y,Sf,0,[Hf],[2]],nF=[3,y,rp,0,[W_,XC],[0,[()=>mz,{[v]:cC}]]],rF=[3,y,Kf,0,[W_,R_,Zl,S_],[[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`Manufacturer`,[v]:dk}],[1,{[g]:`Count`,[v]:DT}],[()=>iF,{[g]:`MemoryInfo`,[v]:$O}]]],iF=[3,y,Jf,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],aF=[3,y,Xf,0,[ip,xS],[[()=>qL,{[g]:`Fpgas`,[v]:qE}],[1,{[g]:`TotalFpgaMemoryInMiB`,[v]:nM}]]],oF=[3,y,cp,0,[Tm,e_,m],[0,2,[2,{[g]:`DryRun`,[v]:h}]],1],sF=[3,y,lp,0,[Tm,YS,Fv],[[0,{[g]:`InstanceId`,[v]:LD}],[4,{[g]:`Timestamp`,[v]:bM}],[0,{[g]:`Output`,[v]:Xk}]]],cF=[3,y,dp,0,[W_,R_,Zl,Vg,Ep,rw,S_],[[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`Manufacturer`,[v]:dk}],[1,{[g]:`Count`,[v]:DT}],[1,{[g]:`LogicalGpuCount`,[v]:FO}],[1,{[g]:`GpuPartitionSize`,[v]:nD}],[()=>Cz,{[g]:`WorkloadSet`,[v]:ZM}],[()=>lF,{[g]:`MemoryInfo`,[v]:$O}]]],lF=[3,y,pp,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],uF=[3,y,_p,0,[Op,CS],[[()=>JL,{[g]:`Gpus`,[v]:aD}],[1,{[g]:`TotalGpuMemoryInMiB`,[v]:iM}]]],dF=[3,y,bp,0,[vp,Sp],[[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`GroupName`,[v]:eD}]]],fF=[3,y,jp,0,[Xl],[[2,{[g]:`Configured`,[v]:ET}]]],pF=[3,y,Mp,0,[Xl],[2]],mF=[3,y,km,0,[ac,Vp],[[0,{[g]:`Arn`,[v]:Pw}],[0,{[g]:`Id`,[v]:_D}]]],hF=[3,y,Pm,0,[ac,W_],[[0,{[g]:`Arn`,[v]:Pw}],[0,{[g]:`Name`,[v]:gk}]]],gF=[3,y,hg,0,[Qv,iC,vc,Md,Rf,Bp,mh,W_,Ry,zy,Ux,Xx,yS,JC,xc,HS,gd,rg,hx,Wu,Gg,Zp,px,vx,tp,Bm,Km,mS,Sv,Rc,Py,Gv,oc,ug,Sg,Zy,Ay],[[0,{[g]:`PlatformDetails`,[v]:oA}],[0,{[g]:`UsageOperation`,[v]:TM}],[()=>FL,{[g]:`BlockDeviceMapping`,[v]:Vw}],[0,{[g]:`Description`,[v]:ZT}],[2,{[g]:`EnaSupport`,[v]:FE}],[0,{[g]:`Hypervisor`,[v]:sD}],[0,{[g]:`ImageOwnerAlias`,[v]:GD}],[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`RootDeviceName`,[v]:NA}],[0,{[g]:`RootDeviceType`,[v]:PA}],[0,{[g]:`SriovNetSupport`,[v]:Mj}],[()=>aL,{[g]:`StateReason`,[v]:Fj}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VirtualizationType`,[v]:JM}],[0,{[g]:`BootMode`,[v]:Uw}],[0,{[g]:`TpmSupport`,[v]:hM}],[0,{[g]:`DeprecationTime`,[v]:qT}],[0,{[g]:`ImdsSupport`,[v]:fO}],[0,{[g]:`SourceInstanceId`,[v]:vj}],[0,{[g]:`DeregistrationProtection`,[v]:UT}],[0,{[g]:`LastLaunchedTime`,[v]:RO}],[2,{[g]:`ImageAllowed`,[v]:TD}],[0,{[g]:`SourceImageId`,[v]:bj}],[0,{[g]:`SourceImageRegion`,[v]:Sj}],[2,{[g]:`FreeTierEligible`,[v]:GE}],[0,{[g]:`ImageId`,[v]:BD}],[0,{[g]:`ImageLocation`,[v]:VD}],[0,{[g]:`ImageState`,[v]:dO}],[0,{[g]:`ImageOwnerId`,[v]:KD}],[0,{[g]:`CreationDate`,[v]:nT}],[2,{[g]:`IsPublic`,[v]:aO}],[()=>BR,{[g]:`ProductCodes`,[v]:$k}],[0,{[g]:`Architecture`,[v]:Fw}],[0,{[g]:`ImageType`,[v]:bO}],[0,{[g]:`KernelId`,[v]:EO}],[0,{[g]:`RamdiskId`,[v]:VA}],[0,{[g]:`Platform`,[v]:OA}]]],_F=[3,y,Wm,0,[Tg,gy,LS,m],[[0,{[g]:`KeyName`,[v]:kO}],[21,{[g]:`PublicKeyMaterial`,[v]:_A}],[()=>uz,{[v]:BS}],[2,{[g]:`DryRun`,[v]:h}]],2],vF=[3,y,Gm,0,[xg,Tg,kg,yS],[[0,{[g]:`KeyFingerprint`,[v]:TO}],[0,{[g]:`KeyName`,[v]:kO}],[0,{[g]:`KeyPairId`,[v]:AO}],[()=>lz,{[g]:`TagSet`,[v]:fM}]]],yF=[3,y,qp,0,[rc,TS],[[()=>eR,{[g]:`Accelerators`,[v]:Mw}],[1,{[g]:`TotalInferenceMemoryInMiB`,[v]:aM}]]],bF=[3,y,lm,0,[Zl,W_,R_,S_],[[1,{[g]:`Count`,[v]:DT}],[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`Manufacturer`,[v]:dk}],[()=>xF,{[g]:`MemoryInfo`,[v]:$O}]]],xF=[3,y,dm,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],SF=[3,y,gg,0,[oc,vc,Ll,_f,Rf,Bp,km,Jm,Zd,lf,sv,bv,Ry,zy,sx,Wb,_x,Ux,Xx,yS,JC,nl,Mc,ll,hl,jp,n_,T_,wf,xc,Qv,iC,aC,qv,$p,HS,E_,Hc,uv,Pv,Ex,Tm,Bm,mS,Kv,Zv,rS,Tg,Cs,Gv,sg,$g,jy,Sg,Zy,Ay,U_,Px,SC,ly,dy],[[0,{[g]:`Architecture`,[v]:Fw}],[()=>tR,{[g]:`BlockDeviceMapping`,[v]:Vw}],[0,{[g]:`ClientToken`,[v]:xT}],[2,{[g]:`EbsOptimized`,[v]:yE}],[2,{[g]:`EnaSupport`,[v]:FE}],[0,{[g]:`Hypervisor`,[v]:sD}],[()=>mF,{[g]:`IamInstanceProfile`,[v]:RD}],[0,{[g]:`InstanceLifecycle`,[v]:HD}],[()=>VL,{[g]:`ElasticGpuAssociationSet`,[v]:sE}],[()=>UL,{[g]:`ElasticInferenceAcceleratorAssociationSet`,[v]:pE}],[()=>cR,{[g]:`NetworkInterfaceSet`,[v]:Ek}],[0,{[g]:`OutpostArn`,[v]:zk}],[0,{[g]:`RootDeviceName`,[v]:NA}],[0,{[g]:`RootDeviceType`,[v]:PA}],[()=>YL,{[g]:`GroupSet`,[v]:iD}],[2,{[g]:`SourceDestCheck`,[v]:cj}],[0,{[g]:`SpotInstanceRequestId`,[v]:Cj}],[0,{[g]:`SriovNetSupport`,[v]:Mj}],[()=>aL,{[g]:`StateReason`,[v]:Fj}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VirtualizationType`,[v]:JM}],[()=>NN,{[g]:`CpuOptions`,[v]:fT}],[0,{[g]:`CapacityBlockId`,[v]:Qw}],[0,{[g]:`CapacityReservationId`,[v]:hT}],[()=>EN,{[g]:`CapacityReservationSpecification`,[v]:vT}],[()=>fF,{[g]:`HibernationOptions`,[v]:uD}],[()=>OR,{[g]:`LicenseSet`,[v]:zO}],[()=>PF,{[g]:`MetadataOptions`,[v]:nk}],[()=>eF,{[g]:`EnclaveOptions`,[v]:wE}],[0,{[g]:`BootMode`,[v]:Uw}],[0,{[g]:`PlatformDetails`,[v]:oA}],[0,{[g]:`UsageOperation`,[v]:TM}],[4,{[g]:`UsageOperationUpdateTime`,[v]:EM}],[()=>MI,{[g]:`PrivateDnsNameOptions`,[v]:nA}],[0,{[g]:`Ipv6Address`,[v]:DD}],[0,{[g]:`TpmSupport`,[v]:hM}],[()=>AF,{[g]:`MaintenanceOptions`,[v]:rk}],[0,{[g]:`CurrentInstanceBootMode`,[v]:oT}],[()=>zF,{[g]:`NetworkPerformanceOptions`,[v]:Ak}],[()=>TI,{[g]:`Operator`,[v]:Yk}],[()=>dR,{[g]:`SecondaryInterfaceSet`,[v]:wj}],[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`ImageId`,[v]:BD}],[()=>qF,{[g]:`InstanceState`,[v]:mO}],[0,{[g]:`PrivateDnsName`,[v]:iA}],[0,{[g]:`DnsName`,[v]:zT}],[0,{[g]:`Reason`,[v]:nj}],[0,{[g]:`KeyName`,[v]:kO}],[1,{[g]:`AmiLaunchIndex`,[v]:_w}],[()=>BR,{[g]:`ProductCodes`,[v]:$k}],[0,{[g]:`InstanceType`,[v]:_O}],[4,{[g]:`LaunchTime`,[v]:BO}],[()=>EI,{[g]:`Placement`,[v]:kA}],[0,{[g]:`KernelId`,[v]:EO}],[0,{[g]:`RamdiskId`,[v]:VA}],[0,{[g]:`Platform`,[v]:OA}],[()=>gI,{[g]:`Monitoring`,[v]:mk}],[0,{[g]:`SubnetId`,[v]:Ej}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`PrivateIpAddress`,[v]:pA}],[0,{[g]:`IpAddress`,[v]:ED}]]],CF=[3,y,Gp,0,[kf,Pf],[[2,{[g]:`EnaSrdEnabled`,[v]:OE}],[()=>wF,{[g]:`EnaSrdUdpSpecification`,[v]:ME}]]],wF=[3,y,Kp,0,[Nf],[[2,{[g]:`EnaSrdUdpEnabled`,[v]:jE}]]],TF=[3,y,em,0,[Nu,Vf],[[0,{[g]:`DeviceName`,[v]:LT}],[()=>WP,{[g]:`Ebs`,[v]:LE}]]],EF=[3,y,nm,0,[Nu,Vf,IC,X_],[[0,{[g]:`DeviceName`,[v]:LT}],[()=>GP,{[g]:`Ebs`,[v]:LE}],[0,{[g]:`VirtualName`,[v]:RM}],[0,{[g]:`NoDevice`,[v]:bk}]]],DF=[3,y,Fm,0,[Lh],[[0,{[g]:`Ipv4Prefix`,[v]:nO}]]],OF=[3,y,Em,0,[$p,Ch],[[0,{[g]:`Ipv6Address`,[v]:DD}],[2,{[g]:`IsPrimaryIpv6`,[v]:ZD}]]],kF=[3,y,Im,0,[Ph],[[0,{[g]:`Ipv6Prefix`,[v]:iO}]]],AF=[3,y,Xm,0,[Ns,ob],[[0,{[g]:`AutoRecovery`,[v]:Cw}],[0,{[g]:`RebootMigration`,[v]:GA}]]],jF=[3,y,Zm,0,[Ns],[0]],MF=[3,y,Qm,0,[M_,Gx],[0,()=>nL]],NF=[3,y,$m,0,[Lp,Pp,kp,Np,nh],[0,1,0,0,0]],PF=[3,y,eh,0,[mS,Lp,Pp,kp,Np,nh],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`HttpTokens`,[v]:hD}],[1,{[g]:`HttpPutResponseHopLimit`,[v]:fD}],[0,{[g]:`HttpEndpoint`,[v]:cD}],[0,{[g]:`HttpProtocolIpv6`,[v]:dD}],[0,{[g]:`InstanceMetadataTags`,[v]:UD}]]],FF=[3,y,ih,0,[cc,uc,Md,ap,Hp,o_,ov,Sv,Kv,ly,uy,Wb,hS,Px,SC,pg,Ih,Ah,Rl,Pv],[[()=>IF,{[g]:`Association`,[v]:Iw}],[()=>LF,{[g]:`Attachment`,[v]:Lw}],[0,{[g]:`Description`,[v]:ZT}],[()=>YL,{[g]:`GroupSet`,[v]:iD}],[()=>aR,{[g]:`Ipv6AddressesSet`,[v]:wD}],[0,{[g]:`MacAddress`,[v]:WO}],[0,{[g]:`NetworkInterfaceId`,[v]:Tk}],[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`PrivateDnsName`,[v]:iA}],[0,{[g]:`PrivateIpAddress`,[v]:pA}],[()=>uR,{[g]:`PrivateIpAddressesSet`,[v]:dA}],[2,{[g]:`SourceDestCheck`,[v]:cj}],[0,{[g]:`Status`,[v]:Zj}],[0,{[g]:`SubnetId`,[v]:Ej}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`InterfaceType`,[v]:SO}],[()=>iR,{[g]:`Ipv4PrefixSet`,[v]:QD}],[()=>oR,{[g]:`Ipv6PrefixSet`,[v]:$D}],[()=>AN,{[g]:`ConnectionTrackingConfiguration`,[v]:ST}],[()=>TI,{[g]:`Operator`,[v]:Yk}]]],IF=[3,y,ah,0,[Vc,rl,hh,Zv,ay],[[0,{[g]:`CarrierIp`,[v]:aT}],[0,{[g]:`CustomerOwnedIp`,[v]:pT}],[0,{[g]:`IpOwnerId`,[v]:JD}],[0,{[g]:`PublicDnsName`,[v]:aA}],[0,{[g]:`PublicIp`,[v]:uA}]]],LF=[3,y,oh,0,[Us,Ss,Lu,du,hS,q_,Af,Ef],[[4,{[g]:`AttachTime`,[v]:Ow}],[0,{[g]:`AttachmentId`,[v]:gw}],[2,{[g]:`DeleteOnTermination`,[v]:VT}],[1,{[g]:`DeviceIndex`,[v]:FT}],[0,{[g]:`Status`,[v]:Zj}],[1,{[g]:`NetworkCardIndex`,[v]:yk}],[()=>CF,{[g]:`EnaSrdSpecification`,[v]:kE}],[1,{[g]:`EnaQueueCount`,[v]:TE}]]],RF=[3,y,ch,0,[Ts,Lu,Md,du,ap,Wp,Hp,ov,ly,uy,qx,Px,ms,pg,q_,Ih,yh,Ah,vh,py,Af,zl,Ef],[[2,{[g]:`AssociatePublicIpAddress`,[v]:yw}],[2,{[g]:`DeleteOnTermination`,[v]:VT}],[0,{[g]:`Description`,[v]:ZT}],[1,{[g]:`DeviceIndex`,[v]:FT}],[()=>QR,{[v]:Yb}],[1,{[g]:`Ipv6AddressCount`,[v]:yD}],[()=>aR,{[g]:`Ipv6Addresses`,[v]:wD}],[0,{[g]:`NetworkInterfaceId`,[v]:Tk}],[0,{[g]:`PrivateIpAddress`,[v]:pA}],[()=>zR,{[g]:`PrivateIpAddresses`,[v]:dA}],[1,{[g]:`SecondaryPrivateIpAddressCount`,[v]:Nj}],[0,{[g]:`SubnetId`,[v]:Ej}],2,0,1,[()=>SR,{[v]:Lh}],1,[()=>CR,{[v]:Ph}],1,2,()=>QP,()=>kN,1]],zF=[3,y,fh,0,[Dc],[[0,{[g]:`BandwidthWeighting`,[v]:Jw}]]],BF=[3,y,ph,0,[Dc],[0]],VF=[3,y,xh,0,[cc,My,Kv,ly],[[()=>IF,{[g]:`Association`,[v]:Iw}],[2,{[g]:`Primary`,[v]:AA}],[0,{[g]:`PrivateDnsName`,[v]:iA}],[0,{[g]:`PrivateIpAddress`,[v]:pA}]]],HF=[3,y,eg,0,[uc,o_,mx,Sv,uy,Wb,hS,eS,Hx,pg],[[()=>UF,{[g]:`Attachment`,[v]:Lw}],[0,{[g]:`MacAddress`,[v]:WO}],[0,{[g]:`SecondaryInterfaceId`,[v]:yj}],[0,{[g]:`OwnerId`,[v]:Vk}],[()=>fR,{[g]:`PrivateIpAddressSet`,[v]:fA}],[2,{[g]:`SourceDestCheck`,[v]:cj}],[0,{[g]:`Status`,[v]:Zj}],[0,{[g]:`SecondarySubnetId`,[v]:Rj}],[0,{[g]:`SecondaryNetworkId`,[v]:Aj}],[0,{[g]:`InterfaceType`,[v]:SO}]]],UF=[3,y,Kh,0,[Us,Ss,Lu,du,hS,q_],[[4,{[g]:`AttachTime`,[v]:Ow}],[0,{[g]:`AttachmentId`,[v]:gw}],[2,{[g]:`DeleteOnTermination`,[v]:VT}],[1,{[g]:`DeviceIndex`,[v]:FT}],[0,{[g]:`Status`,[v]:Zj}],[1,{[g]:`NetworkCardIndex`,[v]:yk}]]],WF=[3,y,Jh,0,[ly],[[0,{[g]:`PrivateIpAddress`,[v]:pA}]]],GF=[3,y,Zh,0,[ly],[0],1],KF=[3,y,$h,0,[Lu,du,uy,oy,eS,pg,q_],[2,1,[()=>pR,{[v]:ly}],1,0,0,1]],qF=[3,y,ig,0,[Yl,W_],[[1,{[g]:`Code`,[v]:TT}],[0,{[g]:`Name`,[v]:gk}]]],JF=[3,y,Wh,0,[Tm,Il,Cy],[[0,{[g]:`InstanceId`,[v]:LD}],[()=>qF,{[g]:`CurrentState`,[v]:bT}],[()=>qF,{[g]:`PreviousState`,[v]:CA}]]],YF=[3,y,tg,0,[RS,Pd,pv,Lf],[[1,{[g]:`TotalSizeInGB`,[v]:pM}],[()=>zL,{[g]:`Disks`,[v]:$T}],[0,{[g]:`NvmeSupport`,[v]:Nk}],[0,{[g]:`EncryptionSupport`,[v]:PE}]]],XF=[3,y,lg,0,[sg,Bc,tp,oS,Jx,lS,Cc,Bp,my,mC,S_,ng,tg,mf,cv,_p,Xf,ey,qp,Ip,Tc,uu,Ds,Vb,nv,hv,mv,a_,lv,Sy,ab],[[0,{[g]:`InstanceType`,[v]:_O}],[2,{[g]:`CurrentGeneration`,[v]:iT}],[2,{[g]:`FreeTierEligible`,[v]:GE}],[()=>fz,{[g]:`SupportedUsageClasses`,[v]:Gj}],[()=>qR,{[g]:`SupportedRootDeviceTypes`,[v]:Pj}],[()=>hz,{[g]:`SupportedVirtualizationTypes`,[v]:qj}],[2,{[g]:`BareMetal`,[v]:Ww}],[0,{[g]:`Hypervisor`,[v]:sD}],[()=>PI,{[g]:`ProcessorInfo`,[v]:hA}],[()=>gL,{[g]:`VCpuInfo`,[v]:AM}],[()=>fI,{[g]:`MemoryInfo`,[v]:$O}],[2,{[g]:`InstanceStorageSupported`,[v]:lO}],[()=>YF,{[g]:`InstanceStorageInfo`,[v]:cO}],[()=>UP,{[g]:`EbsInfo`,[v]:gE}],[()=>vI,{[g]:`NetworkInfo`,[v]:Ok}],[()=>uF,{[g]:`GpuInfo`,[v]:ZE}],[()=>aF,{[g]:`FpgaInfo`,[v]:VE}],[()=>OI,{[g]:`PlacementGroupInfo`,[v]:cA}],[()=>yF,{[g]:`InferenceAcceleratorInfo`,[v]:bD}],[2,{[g]:`HibernationSupported`,[v]:mD}],[2,{[g]:`BurstablePerformanceSupported`,[v]:Kw}],[2,{[g]:`DedicatedHostsSupported`,[v]:PT}],[2,{[g]:`AutoRecoverySupported`,[v]:xw}],[()=>LL,{[g]:`SupportedBootModes`,[v]:oj}],[0,{[g]:`NitroEnclavesSupport`,[v]:Sk}],[0,{[g]:`NitroTpmSupport`,[v]:Fk}],[()=>CI,{[g]:`NitroTpmInfo`,[v]:Pk}],[()=>lI,{[g]:`MediaAcceleratorInfo`,[v]:UO}],[()=>SI,{[g]:`NeuronInfo`,[v]:kk}],[0,{[g]:`PhcSupport`,[v]:SA}],[0,{[g]:`RebootMigrationSupport`,[v]:WA}]]],ZF=[3,y,hm,0,[dc,bm,Sv,yS],[[()=>_R,{[g]:`AttachmentSet`,[v]:Dw}],[0,{[g]:`InternetGatewayId`,[v]:FD}],[0,{[g]:`OwnerId`,[v]:Vk}],[()=>lz,{[g]:`TagSet`,[v]:fM}]]],QF=[3,y,gm,0,[mS,SC],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`VpcId`,[v]:NM}]]],$F=[3,y,Mh,0,[Nh,Qf,PS,eC,Bh,Hh,yy],[[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[()=>pz,{[g]:`Groups`,[v]:oD}],[()=>xR,{[g]:`IpRanges`,[v]:oO}],[()=>wR,{[g]:`Ipv6Ranges`,[v]:sO}],[()=>RR,{[g]:`PrefixListIds`,[v]:yA}]]],eI=[3,y,Vh,0,[Md,Jc],[[0,{[g]:`Description`,[v]:ZT}],[0,{[g]:`CidrIp`,[v]:sT}]]],tI=[3,y,Oh,0,[Lh],[0]],nI=[3,y,kh,0,[Ph],[0]],rI=[3,y,Uh,0,[Md,Yc],[[0,{[g]:`Description`,[v]:ZT}],[0,{[g]:`CidrIpv6`,[v]:cT}]]],iI=[3,y,Pg,0,[kg,yS,Tg,xg,wg],[[0,{[g]:`KeyPairId`,[v]:AO}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`KeyName`,[v]:kO}],[0,{[g]:`KeyFingerprint`,[v]:TO}],[()=>sN,{[g]:`KeyMaterial`,[v]:OO}]]],aI=[3,y,Mg,0,[kg,Fg,yS,hy,Ul,Tg,xg],[[0,{[g]:`KeyPairId`,[v]:AO}],[0,{[g]:`KeyType`,[v]:MO}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`PublicKey`,[v]:gA}],[4,{[g]:`CreateTime`,[v]:wT}],[0,{[g]:`KeyName`,[v]:kO}],[0,{[g]:`KeyFingerprint`,[v]:TO}]]],oI=[3,y,Qg,0,[Xg,Zg,ZC],[0,0,0]],sI=[3,y,zg,0,[Lg],[[0,{[g]:`LicenseConfigurationArn`,[v]:PO}]]],cI=[3,y,Rg,0,[Lg],[0]],lI=[3,y,a_,0,[rc,MS],[[()=>AR,{[g]:`Accelerators`,[v]:Mw}],[1,{[g]:`TotalMediaMemoryInMiB`,[v]:cM}]]],uI=[3,y,d_,0,[Zl,W_,R_,S_],[[1,{[g]:`Count`,[v]:DT}],[0,{[g]:`Name`,[v]:gk}],[0,{[g]:`Manufacturer`,[v]:dk}],[()=>dI,{[g]:`MemoryInfo`,[v]:$O}]]],dI=[3,y,p_,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],fI=[3,y,S_,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],pI=[3,y,b_,0,[Tm,Wb,Ql,m,lc,cC,vc,$l,sg,Ig,jb,QS,Lm,ap,_f,Ux,Rf],[[0,{[g]:`InstanceId`,[v]:LD}],[()=>fN,0],[()=>fN,0],[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`Attribute`,[v]:Rw}],[0,{[g]:`Value`,[v]:kM}],[()=>nR,{[g]:`BlockDeviceMapping`,[v]:Vw}],[()=>fN,{[g]:`DisableApiTermination`,[v]:OT}],[()=>pN,{[g]:`InstanceType`,[v]:_O}],[()=>pN,{[g]:`Kernel`,[v]:NO}],[()=>pN,{[g]:`Ramdisk`,[v]:tj}],[()=>SN,{[g]:`UserData`,[v]:SM}],[()=>pN,{[g]:`InstanceInitiatedShutdownBehavior`,[v]:zD}],[()=>XL,{[v]:vp}],[()=>fN,{[g]:`EbsOptimized`,[v]:yE}],[()=>pN,{[g]:`SriovNetSupport`,[v]:Mj}],[()=>fN,{[g]:`EnaSupport`,[v]:FE}]],1],mI=[3,y,P_,0,[OC,m,dS,GC,vg,JS,i_],[0,2,1,0,1,1,2],1],hI=[3,y,F_,0,[FC],[[()=>yL,{[g]:`VolumeModification`,[v]:LM}]]],gI=[3,y,U_,0,[mS],[[0,{[g]:`State`,[v]:Xj}]]],_I=[3,y,Y_,0,[q_,dv,w_,hs,pc,zv,cu,__,v_],[[1,{[g]:`NetworkCardIndex`,[v]:yk}],[0,{[g]:`NetworkPerformance`,[v]:jk}],[1,{[g]:`MaximumNetworkInterfaces`,[v]:tk}],[1,{[g]:`AdditionalFlexibleNetworkInterfaces`,[v]:dw}],[1,{[g]:`BaselineBandwidthInGbps`,[v]:zw}],[1,{[g]:`PeakBandwidthInGbps`,[v]:Qk}],[1,{[g]:`DefaultEnaQueueCountPerInterface`,[v]:MT}],[1,{[g]:`MaximumEnaQueueCount`,[v]:XO}],[1,{[g]:`MaximumEnaQueueCountPerInterface`,[v]:ZO}]]],vI=[3,y,cv,0,[dv,w_,C_,Pu,K_,Jp,Yp,og,Rf,If,hf,pf,Mf,kc,Yf,Rl,Wx,A_,Xp],[[0,{[g]:`NetworkPerformance`,[v]:jk}],[1,{[g]:`MaximumNetworkInterfaces`,[v]:tk}],[1,{[g]:`MaximumNetworkCards`,[v]:ek}],[1,{[g]:`DefaultNetworkCardIndex`,[v]:RT}],[()=>jR,{[g]:`NetworkCards`,[v]:vk}],[1,{[g]:`Ipv4AddressesPerInterface`,[v]:xD}],[1,{[g]:`Ipv6AddressesPerInterface`,[v]:SD}],[2,{[g]:`Ipv6Supported`,[v]:gO}],[0,{[g]:`EnaSupport`,[v]:FE}],[2,{[g]:`EfaSupported`,[v]:NE}],[()=>qP,{[g]:`EfaInfo`,[v]:_E}],[2,{[g]:`EncryptionInTransitSupported`,[v]:hE}],[2,{[g]:`EnaSrdSupported`,[v]:AE}],[()=>PL,{[g]:`BandwidthWeightings`,[v]:Yw}],[0,{[g]:`FlexibleEnaQueuesSupport`,[v]:BE}],[()=>tP,{[g]:`ConnectionTrackingConfiguration`,[v]:ST}],[2,{[g]:`SecondaryNetworkSupported`,[v]:jj}],[1,{[g]:`MaximumSecondaryNetworkInterfaces`,[v]:sk}],[1,{[g]:`Ipv4AddressesPerSecondaryInterface`,[v]:CD}]]],yI=[3,y,Z_,0,[Zl,ZC],[[1,{[g]:`Count`,[v]:DT}],[1,{[g]:`Version`,[v]:YM}]]],bI=[3,y,Q_,0,[Zl,W_,Zc,S_],[[1,{[g]:`Count`,[v]:DT}],[0,{[g]:`Name`,[v]:gk}],[()=>yI,{[g]:`CoreInfo`,[v]:uT}],[()=>xI,{[g]:`MemoryInfo`,[v]:$O}]]],xI=[3,y,ev,0,[gx],[[1,{[g]:`SizeInMiB`,[v]:xj}]]],SI=[3,y,lv,0,[tv,NS],[[()=>MR,{[g]:`NeuronDevices`,[v]:xk}],[1,{[g]:`TotalNeuronDeviceMemoryInMiB`,[v]:lM}]]],CI=[3,y,mv,0,[uS],[[()=>NR,{[g]:`SupportedVersions`,[v]:Jj}]]],wI=[3,y,Ov,0,[Rv],[0]],TI=[3,y,kv,0,[z_,Rv],[[2,{[g]:`Managed`,[v]:fk}],[0,{[g]:`Principal`,[v]:Zk}]]],EI=[3,y,jy,0,[Xs,ic,Sp,by,Ap,qS,Gb,Fp,vp,qs],[[0,{[g]:`AvailabilityZoneId`,[v]:Aw}],[0,{[g]:`Affinity`,[v]:Nw}],[0,{[g]:`GroupName`,[v]:eD}],[1,{[g]:`PartitionNumber`,[v]:bA}],[0,{[g]:`HostId`,[v]:lD}],[0,{[g]:`Tenancy`,[v]:eM}],[0,{[g]:`SpreadDomain`,[v]:lj}],[0,{[g]:`HostResourceGroupArn`,[v]:pD}],[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`AvailabilityZone`,[v]:kw}]]],DI=[3,y,$v,0,[Sp,mS,gS,Uv,vp,yS,op,Lx,Ug,Pv],[[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`Strategy`,[v]:Qj}],[1,{[g]:`PartitionCount`,[v]:eA}],[0,{[g]:`GroupId`,[v]:QE}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`GroupArn`,[v]:JE}],[0,{[g]:`SpreadLevel`,[v]:Dj}],[0,{[g]:`LinkedGroupId`,[v]:LO}],[()=>TI,{[g]:`Operator`,[v]:Yk}]]],OI=[3,y,ey,0,[tS],[[()=>LR,{[g]:`SupportedStrategies`,[v]:Vj}]]],kI=[3,y,_y,0,[Md,_y],[[0,{[g]:`Description`,[v]:ZT}],[0,{[g]:`PrefixListId`,[v]:vA}]]],AI=[3,y,Jv,0,[Rp,Of,Df],[[0,{[g]:`HostnameType`,[v]:gD}],[2,{[g]:`EnableResourceNameDnsARecord`,[v]:DE}],[2,{[g]:`EnableResourceNameDnsAAAARecord`,[v]:EE}]]],jI=[3,y,Yv,0,[Rp,Of,Df],[0,2,2]],MI=[3,y,Xv,0,[Rp,Of,Df],[[0,{[g]:`HostnameType`,[v]:gD}],[2,{[g]:`EnableResourceNameDnsARecord`,[v]:DE}],[2,{[g]:`EnableResourceNameDnsAAAARecord`,[v]:EE}]]],NI=[3,y,sy,0,[My,ly],[[2,{[g]:`Primary`,[v]:AA}],[0,{[g]:`PrivateIpAddress`,[v]:pA}]]],PI=[3,y,my,0,[Bb,Ub,Kb,R_],[[()=>kL,{[g]:`SupportedArchitectures`,[v]:ij}],[1,{[g]:`SustainedClockSpeedInGhz`,[v]:sj}],[()=>cz,{[g]:`SupportedFeatures`,[v]:uj}],[0,{[g]:`Manufacturer`,[v]:dk}]]],FI=[3,y,Wv,0,[Bv,Hv],[[0,{[g]:`ProductCode`,[v]:tA}],[0,{[g]:`Type`,[v]:xM}]]],II=[3,y,Ty,0,[mp],[[0,{[g]:`GatewayId`,[v]:XE}]]],LI=[3,y,Jy,0,[Hm,m],[[()=>rR,{[v]:Tm}],[2,{[g]:`DryRun`,[v]:h}]],1],RI=[3,y,ub,0,[vp,xy,$S,SC,RC],[[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`PeeringStatus`,[v]:xA}],[0,{[g]:`UserId`,[v]:CM}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`VpcPeeringConnectionId`,[v]:BM}]]],zI=[3,y,Nb,0,[Cv,Dp,sb,Wf],[[0,{[g]:`OptInStatus`,[v]:Hk}],[()=>HR,{[g]:`GeographySet`,[v]:rD}],[0,{[g]:`RegionName`,[v]:KA}],[0,{[g]:`RegionEndpoint`,[v]:IA}]]],BI=[3,y,Uy,0,[W_],[[0,{[g]:`Name`,[v]:gk}]]],VI=[3,y,Fb,0,[Qy,Sv,eb,ap,_g],[[0,{[g]:`ReservationId`,[v]:BA}],[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`RequesterId`,[v]:UA}],[()=>YL,{[g]:`GroupSet`,[v]:iD}],[()=>sR,{[g]:`InstancesSet`,[v]:pO}]]],HI=[3,y,_b,0,[rx,vp,mm,Nh,Qf,PS,Xc,Yc,_y,Wy,Md],[[0,{[g]:`SecurityGroupRuleId`,[v]:mj}],[0,{[g]:`GroupId`,[v]:QE}],[2,{[g]:`IsEgress`,[v]:MD}],[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[0,{[g]:`CidrIpv4`,[v]:lT}],[0,{[g]:`CidrIpv6`,[v]:cT}],[0,{[g]:`PrefixListId`,[v]:vA}],[0,{[g]:`ReferencedGroupId`,[v]:RA}],[0,{[g]:`Description`,[v]:ZT}]]],UI=[3,y,fb,0,[vp,tx,m,Zx,Qx,Nh,Qf,PS,Jc,jh],[[0,{[g]:`GroupId`,[v]:QE}],[()=>ez,{[v]:rx}],[2,{[g]:`DryRun`,[v]:h}],[0,{[g]:`SourceSecurityGroupName`,[v]:Ij}],[0,{[g]:`SourceSecurityGroupOwnerId`,[v]:Lj}],[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[0,{[g]:`CidrIp`,[v]:sT}],[()=>bR,{[g]:`IpPermissions`,[v]:tO}]],1],WI=[3,y,pb,0,[Fy,rC,yb],[[2,{[g]:`Return`,[v]:MA}],[()=>bR,{[g]:`UnknownIpPermissionSet`,[v]:wM}],[()=>KR,{[g]:`RevokedSecurityGroupRuleSet`,[v]:qA}]]],GI=[3,y,mb,0,[Jc,Qf,vp,Sp,jh,Nh,Zx,Qx,PS,tx,m],[0,1,0,0,[()=>bR,0],0,0,0,1,[()=>ez,{[v]:rx}],[2,{[g]:`DryRun`,[v]:h}]]],KI=[3,y,hb,0,[Fy,rC,yb],[[2,{[g]:`Return`,[v]:MA}],[()=>bR,{[g]:`UnknownIpPermissionSet`,[v]:wM}],[()=>KR,{[g]:`RevokedSecurityGroupRuleSet`,[v]:qA}]]],qI=[3,y,Ib,0,[iu,fu,Uu,xf,mp,Tm,gh,av,SS,Hg,zc,ov,yv,mS,RC,tl,Dv,Qp],[[0,{[g]:`DestinationCidrBlock`,[v]:kT}],[0,{[g]:`DestinationIpv6CidrBlock`,[v]:IT}],[0,{[g]:`DestinationPrefixListId`,[v]:HT}],[0,{[g]:`EgressOnlyInternetGatewayId`,[v]:SE}],[0,{[g]:`GatewayId`,[v]:XE}],[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`InstanceOwnerId`,[v]:qD}],[0,{[g]:`NatGatewayId`,[v]:wk}],[0,{[g]:`TransitGatewayId`,[v]:rM}],[0,{[g]:`LocalGatewayId`,[v]:IO}],[0,{[g]:`CarrierGatewayId`,[v]:rT}],[0,{[g]:`NetworkInterfaceId`,[v]:Tk}],[0,{[g]:`Origin`,[v]:Rk}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`VpcPeeringConnectionId`,[v]:BM}],[0,{[g]:`CoreNetworkArn`,[v]:dT}],[0,{[g]:`OdbNetworkArn`,[v]:Gk}],[0,{[g]:`IpAddress`,[v]:ED}]]],JI=[3,y,kb,0,[sc,Dy,wb,Lb,yS,SC,Sv],[[()=>YR,{[g]:`AssociationSet`,[v]:Ew}],[()=>VR,{[g]:`PropagatingVgwSet`,[v]:TA}],[0,{[g]:`RouteTableId`,[v]:ZA}],[()=>JR,{[g]:`RouteSet`,[v]:YA}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`OwnerId`,[v]:Vk}]]],YI=[3,y,bb,0,[L_,xb,wb,Px,mp,fy,Ps],[[2,{[g]:`Main`,[v]:uk}],[0,{[g]:`RouteTableAssociationId`,[v]:XA}],[0,{[g]:`RouteTableId`,[v]:ZA}],[0,{[g]:`SubnetId`,[v]:Ej}],[0,{[g]:`GatewayId`,[v]:XE}],[0,{[g]:`PublicIpv4Pool`,[v]:mA}],[()=>XI,{[g]:`AssociationState`,[v]:ww}]]],XI=[3,y,Cb,0,[mS,Bx],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StatusMessage`,[v]:Oj}]]],ZI=[3,y,qy,0,[Hf],[[2,{[g]:`Enabled`,[v]:RE}]],1],QI=[3,y,Yy,0,[l_,u_,vc,Bm,sg,Wp,Hp,Sg,Tg,U_,jy,Zy,Zb,sx,Px,QS,$d,uf,LS,Yg,th,Nl,nl,hl,jp,Kg,T_,wf,qv,E_,Ql,Tf,uv,Pv,Ex,m,$l,Lm,ly,Ll,bs,sv,km,_f],[1,1,[()=>IL,{[v]:hc}],0,0,1,[()=>aR,{[v]:$p}],0,0,[()=>ZI,0],[()=>EI,0],0,[()=>QR,{[v]:Yb}],[()=>nz,{[v]:cx}],0,[()=>oN,0],[()=>HL,0],[()=>WL,{[v]:tf}],[()=>uz,{[v]:BS}],()=>oI,()=>MF,()=>eP,()=>PN,()=>TN,()=>pF,[()=>kR,{[v]:Jg}],()=>NF,()=>tF,()=>jI,()=>jF,2,2,()=>BF,()=>wI,[()=>mR,{[v]:Dx}],[2,{[g]:`DryRun`,[v]:h}],[2,{[g]:`DisableApiTermination`,[v]:OT}],[0,{[g]:`InstanceInitiatedShutdownBehavior`,[v]:zD}],[0,{[g]:`PrivateIpAddress`,[v]:pA}],[0,{[g]:`ClientToken`,[yO]:1,[v]:xT}],[0,{[g]:`AdditionalInfo`,[v]:mw}],[()=>lR,{[g]:`NetworkInterface`,[v]:Dk}],[()=>hF,{[g]:`IamInstanceProfile`,[v]:RD}],[2,{[g]:`EbsOptimized`,[v]:yE}]],2],$I=[3,y,cx,0,[vp,bh,yS,SC,Jb,Sv,Sp,Md,jh],[[0,{[g]:`GroupId`,[v]:QE}],[()=>bR,{[g]:`IpPermissionsEgress`,[v]:XD}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`SecurityGroupArn`,[v]:dj}],[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`GroupDescription`,[v]:YE}],[()=>bR,{[g]:`IpPermissions`,[v]:tO}]]],eL=[3,y,ax,0,[rx,vp,Tp,mm,Nh,Qf,PS,Xc,Yc,_y,Gy,Md,yS,ex],[[0,{[g]:`SecurityGroupRuleId`,[v]:mj}],[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`GroupOwnerId`,[v]:tD}],[2,{[g]:`IsEgress`,[v]:MD}],[0,{[g]:`IpProtocol`,[v]:eO}],[1,{[g]:`FromPort`,[v]:HE}],[1,{[g]:`ToPort`,[v]:uM}],[0,{[g]:`CidrIpv4`,[v]:lT}],[0,{[g]:`CidrIpv6`,[v]:cT}],[0,{[g]:`PrefixListId`,[v]:vA}],[()=>RI,{[g]:`ReferencedGroupInfo`,[v]:zA}],[0,{[g]:`Description`,[v]:ZT}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`SecurityGroupRuleArn`,[v]:pj}]]],tL=[3,y,pS,0,[xv,bv,yS,aS,Vy,iS,qs,WS,Lc,Hl,ep,Ox,OC,mS,Vx,nS,Ny,Sv,Md,WC,Uf,Cg,su],[[0,{[g]:`OwnerAlias`,[v]:Bk}],[0,{[g]:`OutpostArn`,[v]:zk}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`StorageTier`,[v]:Wj}],[4,{[g]:`RestoreExpiryTime`,[v]:FA}],[0,{[g]:`SseType`,[v]:Uj}],[0,{[g]:`AvailabilityZone`,[v]:kw}],[0,{[g]:`TransferType`,[v]:_M}],[1,{[g]:`CompletionDurationMinutes`,[v]:tT}],[4,{[g]:`CompletionTime`,[v]:CT}],[1,{[g]:`FullSnapshotSizeInBytes`,[v]:WE}],[0,{[g]:`SnapshotId`,[v]:Tj}],[0,{[g]:`VolumeId`,[v]:FM}],[0,{[g]:`Status`,[v]:Zj}],[0,{[g]:`StatusMessage`,[v]:Oj}],[4,{[g]:`StartTime`,[v]:Hj}],[0,{[g]:`Progress`,[v]:jA}],[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`Description`,[v]:ZT}],[1,{[g]:`VolumeSize`,[v]:WM}],[2,{[g]:`Encrypted`,[v]:zE}],[0,{[g]:`KmsKeyId`,[v]:DO}],[0,{[g]:`DataEncryptionKeyId`,[v]:jT}]]],nL=[3,y,zx,0,[O_,Tx,yc,YC,Om],[0,0,1,4,0]],rL=[3,y,yx,0,[Hm,bs,m],[[()=>rR,{[v]:Tm}],[0,{[g]:`AdditionalInfo`,[v]:mw}],[2,{[g]:`DryRun`,[v]:h}]],1],iL=[3,y,bx,0,[Ax],[[()=>hR,{[g]:`InstancesSet`,[v]:pO}]]],aL=[3,y,Xx,0,[Yl,B_],[[0,{[g]:`Code`,[v]:TT}],[0,{[g]:`Message`,[v]:pk}]]],oL=[3,y,xx,0,[Hm,zp,Kx,m,Gf],[[()=>rR,{[v]:Tm}],2,2,[2,{[g]:`DryRun`,[v]:h}],[2,{[g]:`Force`,[v]:KE}]],1],sL=[3,y,Sx,0,[Mx],[[()=>hR,{[g]:`InstancesSet`,[v]:pO}]]],cL=[3,y,_S,0,[Xs,gf,c_,il,Sv,_s,am,yS,zb,bv,Ud,rh,Jv,wc,XS,Px,mS,SC,Ac,gs,qs,lu,D_],[[0,{[g]:`AvailabilityZoneId`,[v]:Aw}],[1,{[g]:`EnableLniAtDeviceIndex`,[v]:vE}],[2,{[g]:`MapCustomerOwnedIpOnLaunch`,[v]:KO}],[0,{[g]:`CustomerOwnedIpv4Pool`,[v]:mT}],[0,{[g]:`OwnerId`,[v]:Vk}],[2,{[g]:`AssignIpv6AddressOnCreation`,[v]:pw}],[()=>oz,{[g]:`Ipv6CidrBlockAssociationSet`,[v]:kD}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`SubnetArn`,[v]:aj}],[0,{[g]:`OutpostArn`,[v]:zk}],[2,{[g]:`EnableDns64`,[v]:rE}],[2,{[g]:`Ipv6Native`,[v]:WD}],[()=>AI,{[g]:`PrivateDnsNameOptionsOnLaunch`,[v]:rA}],[()=>wN,{[g]:`BlockPublicAccessStates`,[v]:Gw}],[0,{[g]:`Type`,[v]:xM}],[0,{[g]:`SubnetId`,[v]:Ej}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`CidrBlock`,[v]:Xw}],[1,{[g]:`AvailableIpAddressCount`,[v]:fw}],[0,{[g]:`AvailabilityZone`,[v]:kw}],[2,{[g]:`DefaultForAz`,[v]:NT}],[2,{[g]:`MapPublicIpOnLaunch`,[v]:ik}]]],lL=[3,y,Hb,0,[mS,Bx],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StatusMessage`,[v]:Oj}]]],uL=[3,y,ux,0,[xs,im,sm,Up,ag],[[0,{[g]:`AssociationId`,[v]:hw}],[0,{[g]:`Ipv6CidrBlock`,[v]:OD}],[()=>lL,{[g]:`Ipv6CidrBlockState`,[v]:AD}],[0,{[g]:`Ipv6AddressAttribute`,[v]:vD}],[0,{[g]:`IpSource`,[v]:hO}]]],dL=[3,y,KS,0,[yg,cC],[[0,{[g]:`Key`,[v]:wO}],[0,{[g]:`Value`,[v]:kM}]]],fL=[3,y,BS,0,[Ob,yS],[[0,{[g]:`ResourceType`,[v]:$A}],[()=>lz,{[v]:KS}]]],pL=[3,y,ES,0,[Hm,Gf,Kx,m],[[()=>rR,{[v]:Tm}],2,2,[2,{[g]:`DryRun`,[v]:h}]],1],mL=[3,y,DS,0,[kS],[[()=>hR,{[g]:`InstancesSet`,[v]:pO}]]],hL=[3,y,nC,0,[Md,$S,Sp,vp,SC,RC,xy],[[0,{[g]:`Description`,[v]:ZT}],[0,{[g]:`UserId`,[v]:CM}],[0,{[g]:`GroupName`,[v]:eD}],[0,{[g]:`GroupId`,[v]:QE}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`VpcPeeringConnectionId`,[v]:BM}],[0,{[g]:`PeeringStatus`,[v]:xA}]]],gL=[3,y,mC,0,[yd,ou,hd,hC,qC],[[1,{[g]:`DefaultVCpus`,[v]:XT}],[1,{[g]:`DefaultCores`,[v]:AT}],[1,{[g]:`DefaultThreadsPerCore`,[v]:KT}],[()=>RL,{[g]:`ValidCores`,[v]:jM}],[()=>dz,{[g]:`ValidThreadsPerCore`,[v]:qM}]]],_L=[3,y,$C,0,[Xs,bv,cS,vg,yS,GC,$f,i_,JS,iS,Pv,TC,OC,dS,Ox,qs,mS,Ul,dc,Uf,Cg],[[0,{[g]:`AvailabilityZoneId`,[v]:Aw}],[0,{[g]:`OutpostArn`,[v]:zk}],[0,{[g]:`SourceVolumeId`,[v]:Kj}],[1,{[g]:`Iops`,[v]:CO}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[0,{[g]:`VolumeType`,[v]:KM}],[2,{[g]:`FastRestored`,[v]:UE}],[2,{[g]:`MultiAttachEnabled`,[v]:HO}],[1,{[g]:`Throughput`,[v]:yM}],[0,{[g]:`SseType`,[v]:Uj}],[()=>TI,{[g]:`Operator`,[v]:Yk}],[1,{[g]:`VolumeInitializationRate`,[v]:PM}],[0,{[g]:`VolumeId`,[v]:FM}],[1,{[g]:`Size`,[v]:Yj}],[0,{[g]:`SnapshotId`,[v]:Tj}],[0,{[g]:`AvailabilityZone`,[v]:kw}],[0,{[g]:`Status`,[v]:Zj}],[4,{[g]:`CreateTime`,[v]:wT}],[()=>gz,{[g]:`AttachmentSet`,[v]:Dw}],[2,{[g]:`Encrypted`,[v]:zE}],[0,{[g]:`KmsKeyId`,[v]:DO}]]],vL=[3,y,uC,0,[Lu,Ms,_h,Rd,OC,Tm,Nd,mS,Us],[[2,{[g]:`DeleteOnTermination`,[v]:VT}],[0,{[g]:`AssociatedResource`,[v]:Sw}],[0,{[g]:`InstanceOwningService`,[v]:YD}],[1,{[g]:`EbsCardIndex`,[v]:eE}],[0,{[g]:`VolumeId`,[v]:FM}],[0,{[g]:`InstanceId`,[v]:LD}],[0,{[g]:`Device`,[v]:QT}],[0,{[g]:`Status`,[v]:Zj}],[4,{[g]:`AttachTime`,[v]:Ow}]]],yL=[3,y,FC,0,[OC,j_,Bx,VS,OS,GS,US,jS,jv,wv,Nv,Mv,Ev,Ny,nS,zf],[[0,{[g]:`VolumeId`,[v]:FM}],[0,{[g]:`ModificationState`,[v]:ck}],[0,{[g]:`StatusMessage`,[v]:Oj}],[1,{[g]:`TargetSize`,[v]:mM}],[1,{[g]:`TargetIops`,[v]:oM}],[0,{[g]:`TargetVolumeType`,[v]:vM}],[1,{[g]:`TargetThroughput`,[v]:gM}],[2,{[g]:`TargetMultiAttachEnabled`,[v]:sM}],[1,{[g]:`OriginalSize`,[v]:Kk}],[1,{[g]:`OriginalIops`,[v]:Uk}],[0,{[g]:`OriginalVolumeType`,[v]:Jk}],[1,{[g]:`OriginalThroughput`,[v]:qk}],[2,{[g]:`OriginalMultiAttachEnabled`,[v]:Wk}],[1,{[g]:`Progress`,[v]:jA}],[4,{[g]:`StartTime`,[v]:Hj}],[4,{[g]:`EndTime`,[v]:IE}]]],bL=[3,y,ew,0,[Sv,dg,am,jc,pm,Hd,yS,wc,SC,mS,Ac,Iu],[[0,{[g]:`OwnerId`,[v]:Vk}],[0,{[g]:`InstanceTenancy`,[v]:xO}],[()=>xz,{[g]:`Ipv6CidrBlockAssociationSet`,[v]:kD}],[()=>yz,{[g]:`CidrBlockAssociationSet`,[v]:Zw}],[2,{[g]:`IsDefault`,[v]:jD}],[()=>CL,{[g]:`EncryptionControl`,[v]:nE}],[()=>lz,{[g]:`TagSet`,[v]:fM}],[()=>wN,{[g]:`BlockPublicAccessStates`,[v]:Gw}],[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`CidrBlock`,[v]:Xw}],[0,{[g]:`DhcpOptionsId`,[v]:BT}]]],xL=[3,y,dC,0,[xs,Ac,Nc],[[0,{[g]:`AssociationId`,[v]:hw}],[0,{[g]:`CidrBlock`,[v]:Xw}],[()=>SL,{[g]:`CidrBlockState`,[v]:$w}]]],SL=[3,y,pC,0,[mS,Bx],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StatusMessage`,[v]:Oj}]]],CL=[3,y,gC,0,[SC,bC,H_,mS,Vx,Hy,yS],[[0,{[g]:`VpcId`,[v]:NM}],[0,{[g]:`VpcEncryptionControlId`,[v]:MM}],[0,{[g]:`Mode`,[v]:hk}],[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StateMessage`,[v]:kj}],[()=>EL,{[g]:`ResourceExclusions`,[v]:LA}],[()=>lz,{[g]:`TagSet`,[v]:fM}]]],wL=[3,y,_C,0,[H_,ym,bf,iv,VC,zC,Bg,MC,Gd],[0,0,0,0,0,0,0,0,0],1],TL=[3,y,vC,0,[mS,Vx],[[0,{[g]:`State`,[v]:Xj}],[0,{[g]:`StateMessage`,[v]:kj}]]],EL=[3,y,yC,0,[hm,yf,rv,BC,HC,t_,jC,Wd],[[()=>TL,{[g]:`InternetGateway`,[v]:ND}],[()=>TL,{[g]:`EgressOnlyInternetGateway`,[v]:xE}],[()=>TL,{[g]:`NatGateway`,[v]:Ck}],[()=>TL,{[g]:`VirtualPrivateGateway`,[v]:VM}],[()=>TL,{[g]:`VpcPeering`,[v]:HM}],[()=>TL,{[g]:`Lambda`,[v]:VO}],[()=>TL,{[g]:`VpcLattice`,[v]:IM}],[()=>TL,{[g]:`ElasticFileSystem`,[v]:iE}]]],DL=[3,y,CC,0,[xs,im,sm,G_,Fh,Up,ag],[[0,{[g]:`AssociationId`,[v]:hw}],[0,{[g]:`Ipv6CidrBlock`,[v]:OD}],[()=>SL,{[g]:`Ipv6CidrBlockState`,[v]:AD}],[0,{[g]:`NetworkBorderGroup`,[v]:_k}],[0,{[g]:`Ipv6Pool`,[v]:rO}],[0,{[g]:`Ipv6AddressAttribute`,[v]:vD}],[0,{[g]:`IpSource`,[v]:hO}]]],OL=`unit`,kL=[1,y,Hs,0,[0,{[v]:_}]],AL=[1,y,Ys,0,[()=>yN,{[v]:_}]],jL=[1,y,Zs,0,[()=>vN,{[v]:_}]],ML=[1,y,$s,0,[()=>bN,{[v]:_}]],NL=[1,y,tc,0,[()=>xN,{[v]:_}]],PL=[1,y,Oc,0,[0,{[v]:_}]],FL=[1,y,gc,0,[()=>CN,{[v]:_}]],IL=[1,y,_c,0,[()=>CN,{[v]:hc}]],LL=[1,y,Sc,0,[0,{[v]:_}]],RL=[1,y,Pc,0,[1,{[v]:_}]],zL=[1,y,gu,0,[()=>BP,{[v]:_}]],BL=[1,y,zd,0,[()=>HP,{[v]:_}]],VL=[1,y,Jd,0,[()=>JP,{[v]:_}]],HL=[1,y,ef,0,[()=>YP,{[v]:_}]],UL=[1,y,af,0,[()=>ZP,{[v]:_}]],WL=[1,y,uf,0,[()=>XP,{[v]:_}]],GL=[1,y,Id,0,[0,{[v]:Ld}]],KL=[1,y,Zf,0,[()=>nF,{[v]:rp}]],qL=[1,y,qf,0,[()=>rF,{[v]:_}]],JL=[1,y,fp,0,[()=>cF,{[v]:_}]],YL=[1,y,hp,0,[()=>dF,{[v]:_}]],XL=[1,y,gp,0,[0,{[v]:QE}]],ZL=[1,y,Cp,0,[0,{[v]:Sp}]],QL=[1,y,Rm,0,[0,{[v]:Bm}]],$L=[1,y,qm,0,[()=>gF,{[v]:_}]],eR=[1,y,um,0,[()=>bF,0]],tR=[1,y,tm,0,[()=>TF,{[v]:_}]],nR=[1,y,rm,0,[()=>EF,{[v]:_}]],rR=[1,y,zm,0,[0,{[v]:Tm}]],iR=[1,y,Mm,0,[()=>DF,{[v]:_}]],aR=[1,y,Dm,0,[()=>OF,{[v]:_}]],oR=[1,y,Nm,0,[()=>kF,{[v]:_}]],sR=[1,y,Ym,0,[()=>SF,{[v]:_}]],cR=[1,y,sh,0,[()=>FF,{[v]:_}]],lR=[1,y,lh,0,[()=>RF,{[v]:_}]],uR=[1,y,Sh,0,[()=>VF,{[v]:_}]],dR=[1,y,qh,0,[()=>HF,{[v]:_}]],fR=[1,y,Yh,0,[()=>WF,{[v]:_}]],pR=[1,y,Xh,0,[()=>GF,{[v]:_}]],mR=[1,y,Qh,0,[()=>KF,{[v]:_}]],hR=[1,y,Gh,0,[()=>JF,{[v]:_}]],gR=[1,y,cg,0,[()=>XF,{[v]:_}]],_R=[1,y,_m,0,[()=>QF,{[v]:_}]],vR=[1,y,xm,0,[0,{[v]:_}]],yR=[1,y,Cm,0,[()=>ZF,{[v]:_}]],bR=[1,y,Th,0,[()=>$F,{[v]:_}]],xR=[1,y,Rh,0,[()=>eI,{[v]:_}]],SR=[1,y,Eh,0,[()=>tI,{[v]:_}]],CR=[1,y,Dh,0,[()=>nI,{[v]:_}]],wR=[1,y,zh,0,[()=>rI,{[v]:_}]],TR=[1,y,Eg,0,[0,{[v]:Tg}]],ER=[1,y,Ag,0,[0,{[v]:kg}]],DR=[1,y,Ng,0,[()=>aI,{[v]:_}]],OR=[1,y,Wg,0,[()=>sI,{[v]:_}]],kR=[1,y,qg,0,[()=>cI,{[v]:_}]],AR=[1,y,f_,0,[()=>uI,{[v]:_}]],jR=[1,y,J_,0,[()=>_I,{[v]:_}]],MR=[1,y,$_,0,[()=>bI,{[v]:_}]],NR=[1,y,gv,0,[0,{[v]:_}]],PR=[1,y,Av,0,[0,{[v]:Lv}]],FR=[1,y,ty,0,[0,{[v]:vp}]],IR=[1,y,ny,0,[()=>DI,{[v]:_}]],LR=[1,y,ry,0,[0,{[v]:_}]],RR=[1,y,vy,0,[()=>kI,{[v]:_}]],zR=[1,y,cy,0,[()=>NI,{[v]:_}]],BR=[1,y,Vv,0,[()=>FI,{[v]:_}]],VR=[1,y,Ey,0,[()=>II,{[v]:_}]],HR=[1,y,Ky,0,[()=>BI,{[v]:_}]],UR=[1,y,nb,0,[()=>zI,{[v]:_}]],WR=[1,y,cb,0,[0,{[v]:sb}]],GR=[1,y,rb,0,[()=>VI,{[v]:_}]],KR=[1,y,vb,0,[()=>HI,{[v]:_}]],qR=[1,y,By,0,[0,{[v]:_}]],JR=[1,y,ib,0,[()=>qI,{[v]:_}]],YR=[1,y,Sb,0,[()=>YI,{[v]:_}]],XR=[1,y,Tb,0,[0,{[v]:_}]],ZR=[1,y,Db,0,[()=>JI,{[v]:_}]],QR=[1,y,Xb,0,[0,{[v]:Yb}]],$R=[1,y,Qb,0,[()=>$I,{[v]:_}]],ez=[1,y,nx,0,[0,{[v]:_}]],tz=[1,y,ix,0,[()=>eL,{[v]:_}]],nz=[1,y,ox,0,[0,{[v]:cx}]],rz=[1,y,Cx,0,[0,{[v]:Ox}]],iz=[1,y,Ix,0,[()=>tL,{[v]:_}]],az=[1,y,wx,0,[0,{[v]:Px}]],oz=[1,y,dx,0,[()=>uL,{[v]:_}]],sz=[1,y,Rx,0,[()=>cL,{[v]:_}]],cz=[1,y,Rb,0,[0,{[v]:_}]],lz=[1,y,AS,0,[()=>dL,{[v]:_}]],uz=[1,y,zS,0,[()=>fL,{[v]:_}]],dz=[1,y,IS,0,[1,{[v]:_}]],fz=[1,y,ZS,0,[0,{[v]:_}]],pz=[1,y,tC,0,[()=>hL,{[v]:_}]],mz=[1,y,UC,0,[0,{[v]:_}]],hz=[1,y,KC,0,[0,{[v]:_}]],gz=[1,y,lC,0,[()=>vL,{[v]:_}]],_z=[1,y,EC,0,[0,{[v]:OC}]],vz=[1,y,NC,0,[()=>_L,{[v]:_}]],yz=[1,y,fC,0,[()=>xL,{[v]:_}]],bz=[1,y,DC,0,[0,{[v]:SC}]],xz=[1,y,wC,0,[()=>DL,{[v]:_}]],Sz=[1,y,PC,0,[()=>bL,{[v]:_}]],Cz=[1,y,nw,0,[0,{[v]:_}]],wz=[1,y,aw,0,[0,{[v]:iw}]],Tz=[1,y,cw,0,[0,{[v]:sw}]],Ez=[9,y,As,0,()=>cN,()=>lN],Dz=[9,y,vs,0,()=>uN,()=>OL],Oz=[9,y,Ks,0,()=>dN,()=>vL],kz=[9,y,Fs,0,()=>mN,()=>hN],Az=[9,y,Bs,0,()=>gN,()=>_N],jz=[9,y,Ml,0,()=>jN,()=>MN],Mz=[9,y,Qc,0,()=>FN,()=>IN],Nz=[9,y,Uc,0,()=>LN,()=>RN],Pz=[9,y,$c,0,()=>zN,()=>iI],Fz=[9,y,ol,0,()=>BN,()=>VN],Iz=[9,y,xl,0,()=>HN,()=>UN],Lz=[9,y,bl,0,()=>WN,()=>GN],Rz=[9,y,Sl,0,()=>KN,()=>qN],zz=[9,y,Pl,0,()=>JN,()=>tL],Bz=[9,y,Fl,0,()=>YN,()=>XN],Vz=[9,y,ql,0,()=>ZN,()=>_L],Hz=[9,y,Jl,0,()=>QN,()=>$N],Uz=[9,y,Du,0,()=>nP,()=>rP],Wz=[9,y,Ru,0,()=>iP,()=>OL],Gz=[9,y,Qu,0,()=>aP,()=>oP],Kz=[9,y,ud,0,()=>sP,()=>OL],qz=[9,y,dd,0,()=>cP,()=>OL],Jz=[9,y,Dd,0,()=>lP,()=>OL],Yz=[9,y,Od,0,()=>uP,()=>OL],Xz=[9,y,ru,0,()=>dP,()=>fP],Zz=[9,y,wu,0,()=>pP,()=>mP],Qz=[9,y,Tu,0,()=>hP,()=>gP],$z=[9,y,Cu,0,()=>_P,()=>vP],eB=[9,y,hu,0,()=>yP,()=>bP],tB=[9,y,Mu,0,()=>xP,()=>SP],nB=[9,y,Hu,0,()=>CP,()=>wP],rB=[9,y,Zu,0,()=>TP,()=>EP],iB=[9,y,Yu,0,()=>DP,()=>OP],aB=[9,y,rd,0,()=>kP,()=>AP],oB=[9,y,fd,0,()=>jP,()=>MP],sB=[9,y,pd,0,()=>NP,()=>PP],cB=[9,y,kd,0,()=>FP,()=>IP],lB=[9,y,Ad,0,()=>LP,()=>RP],uB=[9,y,jd,0,()=>zP,()=>vL],dB=[9,y,sp,0,()=>oF,()=>sF],fB=[9,y,Um,0,()=>_F,()=>vF],pB=[9,y,x_,0,()=>pI,()=>OL],mB=[9,y,I_,0,()=>mI,()=>hI],hB=[9,y,$y,0,()=>LI,()=>OL],gB=[9,y,db,0,()=>UI,()=>WI],_B=[9,y,gb,0,()=>GI,()=>KI],vB=[9,y,tb,0,()=>QI,()=>VI],yB=[9,y,jx,0,()=>rL,()=>iL],bB=[9,y,Nx,0,()=>oL,()=>sL],xB=[9,y,wS,0,()=>pL,()=>mL],SB=e=>({apiVersion:`2016-11-15`,base64Decoder:e?.base64Decoder??Ue,base64Encoder:e?.base64Encoder??We,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??us,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??Ba,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:`aws.auth#sigv4`,identityProvider:e=>e.getIdentityProvider(`aws.auth#sigv4`),signer:new ja}],logger:e?.logger??new ga,protocol:e?.protocol??No,protocolSettings:e?.protocolSettings??{defaultNamespace:`com.amazonaws.ec2`,errorTypeRegistries:iN,xmlNamespace:`http://ec2.amazonaws.com/doc/2016-11-15`,version:`2016-11-15`,serviceTarget:`AmazonEC2`},serviceId:e?.serviceId??`EC2`,urlParser:e?.urlParser??gt,utf8Decoder:e?.utf8Decoder??se,utf8Encoder:e?.utf8Encoder??ce}),CB=e=>{let t=ho(e),n=()=>t().then(sa),r=SB(e);return{...r,...e,runtime:`browser`,defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??po,credentialDefaultProvider:e?.credentialDefaultProvider??(e=>()=>Promise.reject(Error(`Credential is missing`))),defaultUserAgentProvider:e?.defaultUserAgentProvider??co({serviceId:r.serviceId,clientVersion:so.version}),maxAttempts:e?.maxAttempts??3,region:e?.region??uo(`Region is missing`),requestHandler:$e.create(e?.requestHandler??n),retryMode:e?.retryMode??(async()=>(await n()).retryMode||Gr),sha256:e?.sha256??l,streamCollector:e?.streamCollector??tt,useDualstackEndpoint:e?.useDualstackEndpoint??(()=>Promise.resolve(!1)),useFipsEndpoint:e?.useFipsEndpoint??(()=>Promise.resolve(!1))}},wB=e=>({setRegion(t){e.region=t},region(){return e.region}}),TB=e=>({region:e.region()}),EB=e=>{let t=e.httpAuthSchemes,n=e.httpAuthSchemeProvider,r=e.credentials;return{setHttpAuthScheme(e){let n=t.findIndex(t=>t.schemeId===e.schemeId);n===-1?t.push(e):t.splice(n,1,e)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(e){n=e},httpAuthSchemeProvider(){return n},setCredentials(e){r=e},credentials(){return r}}},DB=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()}),OB=(e,t)=>{let n=Object.assign(wB(e),pa(e),de(e),EB(e));return t.forEach(e=>e.configure(n)),Object.assign(e,TB(n),ma(n),fe(n),DB(n))},kB=class extends ea{config;constructor(...[e]){let t=CB(e||{});super(t),this.initConfig=t,this.config=OB(Va(Ki(ye(Di(Ji($n(Ha(t))))))),e?.extensions||[]),this.middlewareStack.use(xt(this.config)),this.middlewareStack.use(Si(this.config)),this.middlewareStack.use(Ca(this.config)),this.middlewareStack.use(ji(this.config)),this.middlewareStack.use(Se(this.config)),this.middlewareStack.use(Te(this.config)),this.middlewareStack.use(Oe(this.config)),this.middlewareStack.use(Ne(this.config,{httpAuthSchemeParametersProvider:Ra,identityProviderConfigProvider:async e=>new Jn({"aws.auth#sigv4":e.credentials})})),this.middlewareStack.use(Re(this.config))}destroy(){super.destroy()}},AB=async(e,t,n)=>({operation:_e(t).operation,region:await f(e.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()});function jB(e){return{schemeId:`aws.auth#sigv4`,signingProperties:{name:`iam`,region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}var MB=e=>{let t=[];switch(e.operation){default:t.push(jB(e))}return t},NB=e=>{let t=Fa(e);return Object.assign(t,{authSchemePreference:f(e.authSchemePreference??[])})},PB=e=>Object.assign(e,{useDualstackEndpoint:e.useDualstackEndpoint??!1,useFipsEndpoint:e.useFipsEndpoint??!1,defaultSigningName:`iam`}),FB={UseFIPS:{type:`builtInParams`,name:`useFipsEndpoint`},Endpoint:{type:`builtInParams`,name:`endpoint`},Region:{type:`builtInParams`,name:`region`},UseDualStack:{type:`builtInParams`,name:`useDualstackEndpoint`}},IB=`@aws-sdk/client-iam`,LB=`AWS SDK for JavaScript Iam Client for Node.js, Browser and React Native`,RB=`3.1024.0`,zB={build:`concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs`,"build:cjs":`node ../../scripts/compilation/inline client-iam`,"build:es":`tsc -p tsconfig.es.json`,"build:include:deps":`yarn g:turbo run build -F="$npm_package_name"`,"build:types":`tsc -p tsconfig.types.json`,"build:types:downlevel":`downlevel-dts dist-types dist-types/ts3.4`,clean:`premove dist-cjs dist-es dist-types tsconfig.cjs.tsbuildinfo tsconfig.es.tsbuildinfo tsconfig.types.tsbuildinfo`,"extract:docs":`api-extractor run --local`,"generate:client":`node ../../scripts/generate-clients/single-service --solo iam`,test:`yarn g:vitest run --passWithNoTests`,"test:e2e":`yarn g:vitest run -c vitest.config.e2e.mts --mode development`,"test:e2e:watch":`yarn g:vitest watch -c vitest.config.e2e.mts`,"test:index":`tsc --noEmit ./test/index-types.ts && node ./test/index-objects.spec.mjs`,"test:integration":`yarn g:vitest run --passWithNoTests -c vitest.config.integ.mts`,"test:integration:watch":`yarn g:vitest run --passWithNoTests -c vitest.config.integ.mts`,"test:watch":`yarn g:vitest watch --passWithNoTests`},BB=`./dist-cjs/index.js`,VB=`./dist-types/index.d.ts`,HB=`./dist-es/index.js`,UB={"@aws-crypto/sha256-browser":`5.2.0`,"@aws-crypto/sha256-js":`5.2.0`,"@aws-sdk/core":`^3.973.26`,"@aws-sdk/credential-provider-node":`^3.972.29`,"@aws-sdk/middleware-host-header":`^3.972.8`,"@aws-sdk/middleware-logger":`^3.972.8`,"@aws-sdk/middleware-recursion-detection":`^3.972.9`,"@aws-sdk/middleware-user-agent":`^3.972.28`,"@aws-sdk/region-config-resolver":`^3.972.10`,"@aws-sdk/types":`^3.973.6`,"@aws-sdk/util-endpoints":`^3.996.5`,"@aws-sdk/util-user-agent-browser":`^3.972.8`,"@aws-sdk/util-user-agent-node":`^3.973.14`,"@smithy/config-resolver":`^4.4.13`,"@smithy/core":`^3.23.13`,"@smithy/fetch-http-handler":`^5.3.15`,"@smithy/hash-node":`^4.2.12`,"@smithy/invalid-dependency":`^4.2.12`,"@smithy/middleware-content-length":`^4.2.12`,"@smithy/middleware-endpoint":`^4.4.28`,"@smithy/middleware-retry":`^4.4.46`,"@smithy/middleware-serde":`^4.2.16`,"@smithy/middleware-stack":`^4.2.12`,"@smithy/node-config-provider":`^4.3.12`,"@smithy/node-http-handler":`^4.5.1`,"@smithy/protocol-http":`^5.3.12`,"@smithy/smithy-client":`^4.12.8`,"@smithy/types":`^4.13.1`,"@smithy/url-parser":`^4.2.12`,"@smithy/util-base64":`^4.3.2`,"@smithy/util-body-length-browser":`^4.2.2`,"@smithy/util-body-length-node":`^4.2.3`,"@smithy/util-defaults-mode-browser":`^4.3.44`,"@smithy/util-defaults-mode-node":`^4.2.48`,"@smithy/util-endpoints":`^3.3.3`,"@smithy/util-middleware":`^4.2.12`,"@smithy/util-retry":`^4.2.13`,"@smithy/util-utf8":`^4.2.2`,"@smithy/util-waiter":`^4.2.14`,tslib:`^2.6.2`},WB={"@smithy/snapshot-testing":`^2.0.4`,"@tsconfig/node20":`20.1.8`,"@types/node":`^20.14.8`,concurrently:`7.0.0`,"downlevel-dts":`0.10.1`,premove:`4.0.0`,typescript:`~5.8.3`,vitest:`^4.0.17`},GB={node:`>=20.0.0`},KB={"<4.5":{"dist-types/*":[`dist-types/ts3.4/*`]}},qB=[`dist-*/**`],JB={name:`AWS SDK for JavaScript Team`,url:`https://aws.amazon.com/javascript/`},YB=`Apache-2.0`,XB={"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.browser`},ZB=`https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-iam`,QB={type:`git`,url:`https://github.com/aws/aws-sdk-js-v3.git`,directory:`clients/client-iam`},$B={name:IB,description:LB,version:RB,scripts:zB,main:BB,types:VB,module:HB,sideEffects:!1,dependencies:UB,devDependencies:WB,engines:GB,typesVersions:KB,files:qB,author:JB,license:YB,browser:XB,"react-native":{"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.native`},homepage:ZB,repository:QB},eV=`required`,tV=`fn`,nV=`argv`,rV=`ref`,iV=`properties`,aV=`headers`,oV=`authSchemes`,sV=`name`,cV=`signingRegion`,lV=!0,uV=`isSet`,dV=`booleanEquals`,fV=`error`,pV=`endpoint`,mV=`tree`,hV=`PartitionResult`,gV=`stringEquals`,_V=`sigv4`,vV={[eV]:!0,default:!1,type:`boolean`},yV={[eV]:!1,type:`string`},bV={[rV]:`Endpoint`},xV={[tV]:dV,[nV]:[{[rV]:`UseFIPS`},!0]},SV={[tV]:dV,[nV]:[{[rV]:`UseDualStack`},!0]},CV={},wV={[tV]:gV,[nV]:[{[tV]:`getAttr`,[nV]:[{[rV]:hV},`name`]},`aws`]},TV={[tV]:`getAttr`,[nV]:[{[rV]:hV},`name`]},EV={[tV]:dV,[nV]:[{[rV]:`UseFIPS`},!1]},DV={[oV]:[{[sV]:_V,[cV]:`us-east-1`}]},OV={[tV]:gV,[nV]:[TV,`aws-cn`]},kV={[oV]:[{[sV]:_V,[cV]:`cn-north-1`}]},AV={[tV]:dV,[nV]:[{[rV]:`UseDualStack`},!1]},jV={[tV]:gV,[nV]:[TV,`aws-us-gov`]},MV={url:`https://iam.us-gov.api.aws`,[iV]:{[oV]:[{[sV]:_V,[cV]:`us-gov-west-1`}]},[aV]:{}},NV={url:`https://iam.us-gov.amazonaws.com`,[iV]:{[oV]:[{[sV]:_V,[cV]:`us-gov-west-1`}]},[aV]:{}},PV={[tV]:gV,[nV]:[TV,`aws-iso`]},FV={[oV]:[{[sV]:_V,[cV]:`us-iso-east-1`}]},IV={[tV]:gV,[nV]:[TV,`aws-iso-b`]},LV={[oV]:[{[sV]:_V,[cV]:`us-isob-east-1`}]},RV={[tV]:`getAttr`,[nV]:[{[rV]:hV},`supportsFIPS`]},zV={[tV]:dV,[nV]:[!0,{[tV]:`getAttr`,[nV]:[{[rV]:hV},`supportsDualStack`]}]},BV={[oV]:[{[sV]:_V,[cV]:`{PartitionResult#implicitGlobalRegion}`}]},VV=[{[rV]:`Region`}],HV={version:`1.0`,parameters:{UseDualStack:vV,UseFIPS:vV,Endpoint:yV,Region:yV},rules:[{conditions:[{[tV]:uV,[nV]:[bV]}],rules:[{conditions:[xV],error:`Invalid Configuration: FIPS and custom endpoint are not supported`,type:fV},{rules:[{conditions:[SV],error:`Invalid Configuration: Dualstack and custom endpoint are not supported`,type:fV},{endpoint:{url:bV,[iV]:CV,[aV]:CV},type:pV}],type:mV}],type:mV},{rules:[{conditions:[{[tV]:uV,[nV]:VV}],rules:[{conditions:[{[tV]:`aws.partition`,[nV]:VV,assign:hV}],rules:[{conditions:[wV,EV,SV],endpoint:{url:`https://iam.global.api.aws`,[iV]:DV,[aV]:CV},type:pV},{conditions:[wV,xV,SV],endpoint:{url:`https://iam-fips.global.api.aws`,[iV]:DV,[aV]:CV},type:pV},{conditions:[OV,EV,SV],endpoint:{url:`https://iam.global.api.amazonwebservices.com.cn`,[iV]:kV,[aV]:CV},type:pV},{conditions:[OV,EV,AV],endpoint:{url:`https://iam.cn-north-1.amazonaws.com.cn`,[iV]:kV,[aV]:CV},type:pV},{conditions:[jV,EV,SV],endpoint:MV,type:pV},{conditions:[jV,xV,SV],endpoint:MV,type:pV},{conditions:[jV,EV,AV],endpoint:NV,type:pV},{conditions:[jV,xV,AV],endpoint:NV,type:pV},{conditions:[PV,EV,AV],endpoint:{url:`https://iam.us-iso-east-1.c2s.ic.gov`,[iV]:FV,[aV]:CV},type:pV},{conditions:[PV,xV,AV],endpoint:{url:`https://iam-fips.us-iso-east-1.c2s.ic.gov`,[iV]:FV,[aV]:CV},type:pV},{conditions:[IV,EV,AV],endpoint:{url:`https://iam.us-isob-east-1.sc2s.sgov.gov`,[iV]:LV,[aV]:CV},type:pV},{conditions:[IV,xV,AV],endpoint:{url:`https://iam-fips.us-isob-east-1.sc2s.sgov.gov`,[iV]:LV,[aV]:CV},type:pV},{conditions:[{[tV]:gV,[nV]:[TV,`aws-iso-e`]},EV,AV],endpoint:{url:`https://iam.eu-isoe-west-1.cloud.adc-e.uk`,[iV]:{[oV]:[{[sV]:_V,[cV]:`eu-isoe-west-1`}]},[aV]:CV},type:pV},{conditions:[{[tV]:gV,[nV]:[TV,`aws-iso-f`]},EV,AV],endpoint:{url:`https://iam.us-isof-south-1.csp.hci.ic.gov`,[iV]:{[oV]:[{[sV]:_V,[cV]:`us-isof-south-1`}]},[aV]:CV},type:pV},{conditions:[{[tV]:gV,[nV]:[TV,`aws-eusc`]},EV,AV],endpoint:{url:`https://iam.eusc-de-east-1.amazonaws.eu`,[iV]:{[oV]:[{[sV]:_V,[cV]:`eusc-de-east-1`}]},[aV]:CV},type:pV},{conditions:[xV,SV],rules:[{conditions:[{[tV]:dV,[nV]:[lV,RV]},zV],rules:[{endpoint:{url:`https://iam-fips.{PartitionResult#dualStackDnsSuffix}`,[iV]:BV,[aV]:CV},type:pV}],type:mV},{error:`FIPS and DualStack are enabled, but this partition does not support one or both`,type:fV}],type:mV},{conditions:[xV,AV],rules:[{conditions:[{[tV]:dV,[nV]:[RV,lV]}],rules:[{endpoint:{url:`https://iam-fips.{PartitionResult#dnsSuffix}`,[iV]:BV,[aV]:CV},type:pV}],type:mV},{error:`FIPS is enabled but this partition does not support FIPS`,type:fV}],type:mV},{conditions:[EV,SV],rules:[{conditions:[zV],rules:[{endpoint:{url:`https://iam.{PartitionResult#dualStackDnsSuffix}`,[iV]:BV,[aV]:CV},type:pV}],type:mV},{error:`DualStack is enabled but this partition does not support DualStack`,type:fV}],type:mV},{endpoint:{url:`https://iam.{PartitionResult#dnsSuffix}`,[iV]:BV,[aV]:CV},type:pV}],type:mV}],type:mV},{error:`Invalid Configuration: Missing Region`,type:fV}],type:mV}]},UV=new er({size:50,params:[`Endpoint`,`Region`,`UseDualStack`,`UseFIPS`]}),WV=(e,t={})=>UV.get(e,()=>Mr(HV,{endpointParams:e,logger:t.logger}));ar.aws=Vr;var b=class e extends aa{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}},GV=class e extends b{name=`ConcurrentModificationException`;$fault=`client`;constructor(t){super({name:`ConcurrentModificationException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},KV=class e extends b{name=`NoSuchEntityException`;$fault=`client`;constructor(t){super({name:`NoSuchEntityException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},qV=class e extends b{name=`ServiceFailureException`;$fault=`server`;constructor(t){super({name:`ServiceFailureException`,$fault:`server`,...t}),Object.setPrototypeOf(this,e.prototype)}},JV=class e extends b{name=`AccountNotManagementOrDelegatedAdministratorException`;$fault=`client`;Message;constructor(t){super({name:`AccountNotManagementOrDelegatedAdministratorException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},YV=class e extends b{name=`InvalidInputException`;$fault=`client`;constructor(t){super({name:`InvalidInputException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},XV=class e extends b{name=`LimitExceededException`;$fault=`client`;constructor(t){super({name:`LimitExceededException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},ZV=class e extends b{name=`EntityAlreadyExistsException`;$fault=`client`;constructor(t){super({name:`EntityAlreadyExistsException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},QV=class e extends b{name=`UnmodifiableEntityException`;$fault=`client`;constructor(t){super({name:`UnmodifiableEntityException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},$V=class e extends b{name=`PolicyNotAttachableException`;$fault=`client`;constructor(t){super({name:`PolicyNotAttachableException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},eH=class e extends b{name=`EntityTemporarilyUnmodifiableException`;$fault=`client`;constructor(t){super({name:`EntityTemporarilyUnmodifiableException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},tH=class e extends b{name=`InvalidUserTypeException`;$fault=`client`;constructor(t){super({name:`InvalidUserTypeException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},nH=class e extends b{name=`PasswordPolicyViolationException`;$fault=`client`;constructor(t){super({name:`PasswordPolicyViolationException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},rH=class e extends b{name=`OpenIdIdpCommunicationErrorException`;$fault=`client`;constructor(t){super({name:`OpenIdIdpCommunicationErrorException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},iH=class e extends b{name=`MalformedPolicyDocumentException`;$fault=`client`;constructor(t){super({name:`MalformedPolicyDocumentException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},aH=class e extends b{name=`ServiceNotSupportedException`;$fault=`client`;constructor(t){super({name:`ServiceNotSupportedException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},oH=class e extends b{name=`DeleteConflictException`;$fault=`client`;constructor(t){super({name:`DeleteConflictException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},sH=class e extends b{name=`OrganizationNotFoundException`;$fault=`client`;Message;constructor(t){super({name:`OrganizationNotFoundException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},cH=class e extends b{name=`OrganizationNotInAllFeaturesModeException`;$fault=`client`;Message;constructor(t){super({name:`OrganizationNotInAllFeaturesModeException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},lH=class e extends b{name=`ServiceAccessNotEnabledException`;$fault=`client`;Message;constructor(t){super({name:`ServiceAccessNotEnabledException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},uH=class e extends b{name=`FeatureDisabledException`;$fault=`client`;constructor(t){super({name:`FeatureDisabledException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},dH=class e extends b{name=`InvalidAuthenticationCodeException`;$fault=`client`;constructor(t){super({name:`InvalidAuthenticationCodeException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},fH=class e extends b{name=`CallerIsNotManagementAccountException`;$fault=`client`;Message;constructor(t){super({name:`CallerIsNotManagementAccountException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.Message=t.Message}},pH=class e extends b{name=`FeatureEnabledException`;$fault=`client`;constructor(t){super({name:`FeatureEnabledException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},mH=class e extends b{name=`ReportGenerationLimitExceededException`;$fault=`client`;constructor(t){super({name:`ReportGenerationLimitExceededException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},hH=class e extends b{name=`CredentialReportExpiredException`;$fault=`client`;constructor(t){super({name:`CredentialReportExpiredException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},gH=class e extends b{name=`CredentialReportNotPresentException`;$fault=`client`;constructor(t){super({name:`CredentialReportNotPresentException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},_H=class e extends b{name=`CredentialReportNotReadyException`;$fault=`client`;constructor(t){super({name:`CredentialReportNotReadyException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},vH=class e extends b{name=`UnrecognizedPublicKeyEncodingException`;$fault=`client`;constructor(t){super({name:`UnrecognizedPublicKeyEncodingException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},yH=class e extends b{name=`PolicyEvaluationException`;$fault=`server`;constructor(t){super({name:`PolicyEvaluationException`,$fault:`server`,...t}),Object.setPrototypeOf(this,e.prototype)}},bH=class e extends b{name=`KeyPairMismatchException`;$fault=`client`;constructor(t){super({name:`KeyPairMismatchException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},xH=class e extends b{name=`MalformedCertificateException`;$fault=`client`;constructor(t){super({name:`MalformedCertificateException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},SH=class e extends b{name=`DuplicateCertificateException`;$fault=`client`;constructor(t){super({name:`DuplicateCertificateException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},CH=class e extends b{name=`InvalidCertificateException`;$fault=`client`;constructor(t){super({name:`InvalidCertificateException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},wH=class e extends b{name=`DuplicateSSHPublicKeyException`;$fault=`client`;constructor(t){super({name:`DuplicateSSHPublicKeyException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},TH=class e extends b{name=`InvalidPublicKeyException`;$fault=`client`;constructor(t){super({name:`InvalidPublicKeyException`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},EH=`Arn`,DH=`AttachmentCount`,OH=`AccessKey`,kH=`AccessKeyId`,AH=`AccessKeyMetadata`,jH=`AccountNotManagementOrDelegatedAdministratorException`,MH=`AttachedPolicy`,NH=`AttachedPermissionsBoundary`,PH=`AttachedPolicies`,FH=`AttachUserPolicy`,IH=`AttachUserPolicyRequest`,LH=`CreateAccessKey`,RH=`CreateAccessKeyRequest`,zH=`CreateAccessKeyResponse`,BH=`CreateDate`,VH=`CallerIsNotManagementAccountException`,HH=`ConcurrentModificationException`,UH=`CreatePolicyRequest`,WH=`CreatePolicyResponse`,GH=`CreatePolicy`,KH=`CredentialReportExpiredException`,qH=`CredentialReportNotPresentException`,JH=`CredentialReportNotReadyException`,YH=`CreateUser`,XH=`CreateUserRequest`,ZH=`CreateUserResponse`,QH=`Description`,$H=`DeleteAccessKey`,eU=`DeleteAccessKeyRequest`,tU=`DeleteConflictException`,nU=`DuplicateCertificateException`,rU=`DeletePolicyRequest`,iU=`DeletePolicy`,aU=`DuplicateSSHPublicKeyException`,oU=`DeleteUser`,sU=`DetachUserPolicyRequest`,cU=`DetachUserPolicy`,lU=`DeleteUserRequest`,uU=`DefaultVersionId`,dU=`Document`,fU=`EntityAlreadyExistsException`,pU=`EntityTemporarilyUnmodifiableException`,mU=`FeatureDisabledException`,hU=`FeatureEnabledException`,gU=`GetPolicy`,_U=`GetPolicyRequest`,vU=`GetPolicyResponse`,yU=`GetPolicyVersion`,bU=`GetPolicyVersionRequest`,xU=`GetPolicyVersionResponse`,SU=`GetUser`,CU=`GetUserRequest`,wU=`GetUserResponse`,TU=`IsAttachable`,EU=`InvalidAuthenticationCodeException`,DU=`InvalidCertificateException`,OU=`IsDefaultVersion`,kU=`InvalidInputException`,AU=`InvalidPublicKeyException`,jU=`IsTruncated`,MU=`InvalidUserTypeException`,NU=`Key`,PU=`KeyPairMismatchException`,FU=`ListAccessKeys`,IU=`ListAccessKeysRequest`,LU=`ListAccessKeysResponse`,RU=`ListAttachedUserPolicies`,zU=`ListAttachedUserPoliciesRequest`,BU=`ListAttachedUserPoliciesResponse`,VU=`LimitExceededException`,HU=`ListPoliciesRequest`,UU=`ListPoliciesResponse`,WU=`ListPolicies`,GU=`ListUsers`,KU=`ListUsersRequest`,qU=`ListUsersResponse`,JU=`Message`,YU=`MalformedCertificateException`,XU=`MaxItems`,ZU=`MalformedPolicyDocumentException`,QU=`Marker`,$U=`NoSuchEntityException`,eW=`OnlyAttached`,tW=`OpenIdIdpCommunicationErrorException`,nW=`OrganizationNotFoundException`,rW=`OrganizationNotInAllFeaturesModeException`,iW=`PolicyArn`,aW=`PermissionsBoundary`,oW=`PermissionsBoundaryArn`,sW=`PermissionsBoundaryType`,cW=`PermissionsBoundaryUsageCount`,lW=`PolicyDocument`,uW=`PolicyEvaluationException`,dW=`PolicyId`,fW=`PasswordLastUsed`,pW=`PolicyName`,mW=`PolicyNotAttachableException`,hW=`PasswordPolicyViolationException`,gW=`PathPrefix`,_W=`PolicyUsageFilter`,vW=`PolicyVersion`,yW=`Path`,bW=`Policy`,xW=`Policies`,SW=`ReportGenerationLimitExceededException`,CW=`Status`,wW=`SecretAccessKey`,TW=`ServiceAccessNotEnabledException`,EW=`ServiceFailureException`,DW=`ServiceNotSupportedException`,OW=`Scope`,kW=`Tags`,AW=`Tag`,jW=`UpdateAccessKey`,MW=`UpdateAccessKeyRequest`,NW=`UpdateDate`,PW=`UnmodifiableEntityException`,FW=`UserId`,IW=`UserName`,LW=`UnrecognizedPublicKeyEncodingException`,RW=`User`,zW=`Users`,BW=`VersionId`,VW=`Value`,HW=`accessKeyMetadataListType`,UW=`accessKeySecretType`,WW=`attachedPoliciesListType`,x=`awsQueryError`,S=`client`,C=`error`,w=`httpError`,T=`message`,GW=`policyListType`,KW=`smithy.ts.sdk.synthetic.com.amazonaws.iam`,qW=`server`,JW=`tagListType`,YW=`userListType`,E=`com.amazonaws.iam`,XW=At.for(KW),ZW=[-3,KW,`IAMServiceException`,0,[],[]];XW.registerError(ZW,b);var D=At.for(E),QW=[-3,E,jH,{[C]:S,[w]:400},[JU],[0]];D.registerError(QW,JV);var $W=[-3,E,VH,{[C]:S,[w]:400},[JU],[0]];D.registerError($W,fH);var eG=[-3,E,HH,{[x]:[`ConcurrentModification`,409],[C]:S,[w]:409},[T],[0]];D.registerError(eG,GV);var tG=[-3,E,KH,{[x]:[`ReportExpired`,410],[C]:S,[w]:410},[T],[0]];D.registerError(tG,hH);var nG=[-3,E,qH,{[x]:[`ReportNotPresent`,410],[C]:S,[w]:410},[T],[0]];D.registerError(nG,gH);var rG=[-3,E,JH,{[x]:[`ReportInProgress`,404],[C]:S,[w]:404},[T],[0]];D.registerError(rG,_H);var iG=[-3,E,tU,{[x]:[`DeleteConflict`,409],[C]:S,[w]:409},[T],[0]];D.registerError(iG,oH);var aG=[-3,E,nU,{[x]:[`DuplicateCertificate`,409],[C]:S,[w]:409},[T],[0]];D.registerError(aG,SH);var oG=[-3,E,aU,{[x]:[`DuplicateSSHPublicKey`,400],[C]:S,[w]:400},[T],[0]];D.registerError(oG,wH);var sG=[-3,E,fU,{[x]:[`EntityAlreadyExists`,409],[C]:S,[w]:409},[T],[0]];D.registerError(sG,ZV);var cG=[-3,E,pU,{[x]:[`EntityTemporarilyUnmodifiable`,409],[C]:S,[w]:409},[T],[0]];D.registerError(cG,eH);var lG=[-3,E,mU,{[x]:[`FeatureDisabled`,404],[C]:S,[w]:404},[T],[0]];D.registerError(lG,uH);var uG=[-3,E,hU,{[x]:[`FeatureEnabled`,409],[C]:S,[w]:409},[T],[0]];D.registerError(uG,pH);var dG=[-3,E,EU,{[x]:[`InvalidAuthenticationCode`,403],[C]:S,[w]:403},[T],[0]];D.registerError(dG,dH);var fG=[-3,E,DU,{[x]:[`InvalidCertificate`,400],[C]:S,[w]:400},[T],[0]];D.registerError(fG,CH);var pG=[-3,E,kU,{[x]:[`InvalidInput`,400],[C]:S,[w]:400},[T],[0]];D.registerError(pG,YV);var mG=[-3,E,AU,{[x]:[`InvalidPublicKey`,400],[C]:S,[w]:400},[T],[0]];D.registerError(mG,TH);var hG=[-3,E,MU,{[x]:[`InvalidUserType`,400],[C]:S,[w]:400},[T],[0]];D.registerError(hG,tH);var gG=[-3,E,PU,{[x]:[`KeyPairMismatch`,400],[C]:S,[w]:400},[T],[0]];D.registerError(gG,bH);var _G=[-3,E,VU,{[x]:[`LimitExceeded`,409],[C]:S,[w]:409},[T],[0]];D.registerError(_G,XV);var vG=[-3,E,YU,{[x]:[`MalformedCertificate`,400],[C]:S,[w]:400},[T],[0]];D.registerError(vG,xH);var yG=[-3,E,ZU,{[x]:[`MalformedPolicyDocument`,400],[C]:S,[w]:400},[T],[0]];D.registerError(yG,iH);var bG=[-3,E,$U,{[x]:[`NoSuchEntity`,404],[C]:S,[w]:404},[T],[0]];D.registerError(bG,KV);var xG=[-3,E,tW,{[x]:[`OpenIdIdpCommunicationError`,400],[C]:S,[w]:400},[T],[0]];D.registerError(xG,rH);var SG=[-3,E,nW,{[C]:S,[w]:400},[JU],[0]];D.registerError(SG,sH);var CG=[-3,E,rW,{[C]:S,[w]:400},[JU],[0]];D.registerError(CG,cH);var wG=[-3,E,hW,{[x]:[`PasswordPolicyViolation`,400],[C]:S,[w]:400},[T],[0]];D.registerError(wG,nH);var TG=[-3,E,uW,{[x]:[`PolicyEvaluation`,500],[C]:qW,[w]:500},[T],[0]];D.registerError(TG,yH);var EG=[-3,E,mW,{[x]:[`PolicyNotAttachable`,400],[C]:S,[w]:400},[T],[0]];D.registerError(EG,$V);var DG=[-3,E,SW,{[x]:[`ReportGenerationLimitExceeded`,409],[C]:S,[w]:409},[T],[0]];D.registerError(DG,mH);var OG=[-3,E,TW,{[C]:S,[w]:400},[JU],[0]];D.registerError(OG,lH);var kG=[-3,E,EW,{[x]:[`ServiceFailure`,500],[C]:qW,[w]:500},[T],[0]];D.registerError(kG,qV);var AG=[-3,E,DW,{[x]:[`NotSupportedService`,404],[C]:S,[w]:404},[T],[0]];D.registerError(AG,aH);var jG=[-3,E,PW,{[x]:[`UnmodifiableEntity`,400],[C]:S,[w]:400},[T],[0]];D.registerError(jG,QV);var MG=[-3,E,LW,{[x]:[`UnrecognizedPublicKeyEncoding`,400],[C]:S,[w]:400},[T],[0]];D.registerError(MG,vH);var NG=[XW,D],PG=[0,E,UW,8,0],FG=[3,E,OH,0,[IW,kH,CW,wW,BH],[0,0,0,[()=>PG,0],4],4],IG=[3,E,AH,0,[IW,kH,CW,BH],[0,0,0,4]],LG=[3,E,NH,0,[sW,oW],[0,0]],RG=[3,E,MH,0,[pW,iW],[0,0]],zG=[3,E,IH,0,[IW,iW],[0,0],2],BG=[3,E,RH,0,[IW],[0]],VG=[3,E,zH,0,[OH],[[()=>FG,0]],1],HG=[3,E,UH,0,[pW,lW,yW,QH,kW],[0,0,0,0,()=>yK],2],UG=[3,E,WH,0,[bW],[()=>uK]],WG=[3,E,XH,0,[IW,yW,aW,kW],[0,0,0,()=>yK],1],GG=[3,E,ZH,0,[RW],[()=>mK]],KG=[3,E,eU,0,[kH,IW],[0,0],1],qG=[3,E,rU,0,[iW],[0],1],JG=[3,E,lU,0,[IW],[0],1],YG=[3,E,sU,0,[IW,iW],[0,0],2],XG=[3,E,_U,0,[iW],[0],1],ZG=[3,E,vU,0,[bW],[()=>uK]],QG=[3,E,bU,0,[iW,BW],[0,0],2],$G=[3,E,xU,0,[vW],[()=>dK]],eK=[3,E,CU,0,[IW],[0]],tK=[3,E,wU,0,[RW],[()=>mK],1],nK=[3,E,IU,0,[IW,QU,XU],[0,0,1]],rK=[3,E,LU,0,[AH,jU,QU],[()=>gK,2,0],1],iK=[3,E,zU,0,[IW,gW,QU,XU],[0,0,0,1],1],aK=[3,E,BU,0,[PH,jU,QU],[()=>_K,2,0]],oK=[3,E,HU,0,[OW,eW,gW,_W,QU,XU],[0,2,0,0,0,1]],sK=[3,E,UU,0,[xW,jU,QU],[()=>vK,2,0]],cK=[3,E,KU,0,[gW,QU,XU],[0,0,1]],lK=[3,E,qU,0,[zW,jU,QU],[()=>bK,2,0],1],uK=[3,E,bW,0,[pW,dW,EH,yW,uU,DH,cW,TU,QH,BH,NW,kW],[0,0,0,0,0,1,1,2,0,4,4,()=>yK]],dK=[3,E,vW,0,[dU,BW,OU,BH],[0,0,2,4]],fK=[3,E,AW,0,[NU,VW],[0,0],2],pK=[3,E,MW,0,[kH,CW,IW],[0,0,0],2],mK=[3,E,RW,0,[yW,IW,FW,EH,BH,fW,aW,kW],[0,0,0,0,4,4,()=>LG,()=>yK],5],hK=`unit`,gK=[1,E,HW,0,()=>IG],_K=[1,E,WW,0,()=>RG],vK=[1,E,GW,0,()=>uK],yK=[1,E,JW,0,()=>fK],bK=[1,E,YW,0,()=>mK],xK=[9,E,FH,0,()=>zG,()=>hK],SK=[9,E,LH,0,()=>BG,()=>VG],CK=[9,E,GH,0,()=>HG,()=>UG],wK=[9,E,YH,0,()=>WG,()=>GG],TK=[9,E,$H,0,()=>KG,()=>hK],EK=[9,E,iU,0,()=>qG,()=>hK],DK=[9,E,oU,0,()=>JG,()=>hK],OK=[9,E,cU,0,()=>YG,()=>hK],kK=[9,E,gU,0,()=>XG,()=>ZG],AK=[9,E,yU,0,()=>QG,()=>$G],jK=[9,E,SU,0,()=>eK,()=>tK],MK=[9,E,FU,0,()=>nK,()=>rK],NK=[9,E,RU,0,()=>iK,()=>aK],PK=[9,E,WU,0,()=>oK,()=>sK],FK=[9,E,GU,0,()=>cK,()=>lK],IK=[9,E,jW,0,()=>pK,()=>hK],LK=e=>({apiVersion:`2010-05-08`,base64Decoder:e?.base64Decoder??Ue,base64Encoder:e?.base64Encoder??We,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??WV,extensions:e?.extensions??[],httpAuthSchemeProvider:e?.httpAuthSchemeProvider??MB,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:`aws.auth#sigv4`,identityProvider:e=>e.getIdentityProvider(`aws.auth#sigv4`),signer:new ja}],logger:e?.logger??new ga,protocol:e?.protocol??Mo,protocolSettings:e?.protocolSettings??{defaultNamespace:`com.amazonaws.iam`,errorTypeRegistries:NG,xmlNamespace:`https://iam.amazonaws.com/doc/2010-05-08/`,version:`2010-05-08`,serviceTarget:`AWSIdentityManagementV20100508`},serviceId:e?.serviceId??`IAM`,urlParser:e?.urlParser??gt,utf8Decoder:e?.utf8Decoder??se,utf8Encoder:e?.utf8Encoder??ce}),RK=e=>{let t=ho(e),n=()=>t().then(sa),r=LK(e);return{...r,...e,runtime:`browser`,defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??po,credentialDefaultProvider:e?.credentialDefaultProvider??(e=>()=>Promise.reject(Error(`Credential is missing`))),defaultUserAgentProvider:e?.defaultUserAgentProvider??co({serviceId:r.serviceId,clientVersion:$B.version}),maxAttempts:e?.maxAttempts??3,region:e?.region??uo(`Region is missing`),requestHandler:$e.create(e?.requestHandler??n),retryMode:e?.retryMode??(async()=>(await n()).retryMode||Gr),sha256:e?.sha256??l,streamCollector:e?.streamCollector??tt,useDualstackEndpoint:e?.useDualstackEndpoint??(()=>Promise.resolve(!1)),useFipsEndpoint:e?.useFipsEndpoint??(()=>Promise.resolve(!1))}},zK=e=>{let t=e.httpAuthSchemes,n=e.httpAuthSchemeProvider,r=e.credentials;return{setHttpAuthScheme(e){let n=t.findIndex(t=>t.schemeId===e.schemeId);n===-1?t.push(e):t.splice(n,1,e)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(e){n=e},httpAuthSchemeProvider(){return n},setCredentials(e){r=e},credentials(){return r}}},BK=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()}),VK=(e,t)=>{let n=Object.assign(wB(e),pa(e),de(e),zK(e));return t.forEach(e=>e.configure(n)),Object.assign(e,TB(n),ma(n),fe(n),BK(n))},HK=class extends ea{config;constructor(...[e]){let t=RK(e||{});super(t),this.initConfig=t,this.config=VK(NB(Ki(ye(Di(Ji($n(PB(t))))))),e?.extensions||[]),this.middlewareStack.use(xt(this.config)),this.middlewareStack.use(Si(this.config)),this.middlewareStack.use(Ca(this.config)),this.middlewareStack.use(ji(this.config)),this.middlewareStack.use(Se(this.config)),this.middlewareStack.use(Te(this.config)),this.middlewareStack.use(Oe(this.config)),this.middlewareStack.use(Ne(this.config,{httpAuthSchemeParametersProvider:AB,identityProviderConfigProvider:async e=>new Jn({"aws.auth#sigv4":e.credentials})})),this.middlewareStack.use(Re(this.config))}destroy(){super.destroy()}};function UK(e){return t=>async n=>{let{request:r}=n;if(e.expectContinueHeader!==!1&&i.isInstance(r)&&r.body&&e.runtime===`node`&&e.requestHandler?.constructor?.name!==`FetchHttpHandler`){let t=!0;if(typeof e.expectContinueHeader==`number`)try{t=(Number(r.headers?.[`content-length`])??e.bodyLengthChecker?.(r.body)??1/0)>=e.expectContinueHeader}catch{}else t=!!e.expectContinueHeader;t&&(r.headers.Expect=`100-continue`)}return t({...n,request:r})}}var WK={step:`build`,tags:[`SET_EXPECT_HEADER`,`EXPECT_HEADER`],name:`addExpectContinueMiddleware`,override:!0},GK=e=>({applyToStack:t=>{t.add(UK(e),WK)}}),KK={WHEN_SUPPORTED:`WHEN_SUPPORTED`,WHEN_REQUIRED:`WHEN_REQUIRED`},qK=KK.WHEN_SUPPORTED,JK={WHEN_SUPPORTED:`WHEN_SUPPORTED`,WHEN_REQUIRED:`WHEN_REQUIRED`},YK=KK.WHEN_SUPPORTED,XK;(function(e){e.MD5=`MD5`,e.CRC32=`CRC32`,e.CRC32C=`CRC32C`,e.CRC64NVME=`CRC64NVME`,e.SHA1=`SHA1`,e.SHA256=`SHA256`})(XK||={});var ZK;(function(e){e.HEADER=`header`,e.TRAILER=`trailer`})(ZK||={});var QK=XK.CRC32,$K=function(){function e(){this.crc32=new eq}return e.prototype.update=function(e){r(e)||this.crc32.update(ae(e))},e.prototype.digest=function(){return a(this,void 0,void 0,function(){return o(this,function(e){return[2,s(this.crc32.digest())]})})},e.prototype.reset=function(){this.crc32=new eq},e}(),eq=function(){function e(){this.checksum=4294967295}return e.prototype.update=function(e){var t,n;try{for(var r=te(e),i=r.next();!i.done;i=r.next()){var a=i.value;this.checksum=this.checksum>>>8^tq[(this.checksum^a)&255]}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}return this},e.prototype.digest=function(){return(this.checksum^4294967295)>>>0},e}(),tq=c([0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117]),nq=e=>{let{requestChecksumCalculation:t,responseChecksumValidation:n,requestStreamBufferSize:r}=e;return Object.assign(e,{requestChecksumCalculation:f(t??qK),responseChecksumValidation:f(n??YK),requestStreamBufferSize:Number(r??0),checksumAlgorithms:e.checksumAlgorithms??{}})},rq=e=>(t,n)=>async r=>{let i=await e.region(),a=e.region,o=()=>{};n.__s3RegionRedirect&&(Object.defineProperty(e,`region`,{writable:!1,value:async()=>n.__s3RegionRedirect}),o=()=>Object.defineProperty(e,`region`,{writable:!0,value:a}));try{let a=await t(r);if(n.__s3RegionRedirect&&(o(),i!==await e.region()))throw Error(`Region was not restored following S3 region redirect.`);return a}catch(e){throw o(),e}},iq={tags:[`REGION_REDIRECT`,`S3`],name:`regionRedirectEndpointMiddleware`,override:!0,relation:`before`,toMiddleware:`endpointV2Middleware`};function aq(e){return(t,n)=>async r=>{try{return await t(r)}catch(i){if(e.followRegionRedirects){let a=i?.$metadata?.httpStatusCode,o=n.commandName===`HeadBucketCommand`,s=i?.$response?.headers?.[`x-amz-bucket-region`];if(s&&(a===301||a===400&&(i?.name===`IllegalLocationConstraintException`||o))){try{let t=s;n.logger?.debug(`Redirecting from ${await e.region()} to ${t}`),n.__s3RegionRedirect=t}catch(e){throw Error(`Region redirect failed: `+e)}return t(r)}}throw i}}}var oq={step:`initialize`,tags:[`REGION_REDIRECT`,`S3`],name:`regionRedirectMiddleware`,override:!0},sq=e=>({applyToStack:t=>{t.add(aq(e),oq),t.addRelativeTo(rq(e),iq)}}),cq=class e{data;lastPurgeTime=Date.now();static EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS=3e4;constructor(e={}){this.data=e}get(e){let t=this.data[e];if(t)return t}set(e,t){return this.data[e]=t,t}delete(e){delete this.data[e]}async purgeExpired(){let t=Date.now();if(!(this.lastPurgeTime+e.EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS>t))for(let e in this.data){let n=this.data[e];if(!n.isRefreshing){let r=await n.identity;r.expiration&&r.expiration.getTime()(t.expiration?.getTime()??0){i.set(r,new lq(Promise.resolve(e)))})),t)):i.set(r,new lq(this.getIdentity(r))).identity}async getIdentity(e){await this.cache.purgeExpired().catch(e=>{console.warn(`Error while clearing expired entries in S3ExpressIdentityCache: +`+e)});let t=await this.createSessionFn(e);if(!t.Credentials?.AccessKeyId||!t.Credentials?.SecretAccessKey)throw Error(`s3#createSession response credential missing AccessKeyId or SecretAccessKey.`);return{accessKeyId:t.Credentials.AccessKeyId,secretAccessKey:t.Credentials.SecretAccessKey,sessionToken:t.Credentials.SessionToken,expiration:t.Credentials.Expiration?new Date(t.Credentials.Expiration):void 0}}},dq=`sigv4-s3express`,fq=`X-Amz-S3session-Token`,pq=fq.toLowerCase(),mq=class extends re{async signWithCredentials(e,t,n){let r=hq(t);e.headers[pq]=t.sessionToken;let i=this;return gq(i,r),i.signRequest(e,n??{})}async presignWithCredentials(e,t,n){let r=hq(t);return delete e.headers[pq],e.headers[fq]=t.sessionToken,e.query=e.query??{},e.query[fq]=t.sessionToken,gq(this,r),this.presign(e,n)}};function hq(e){return{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey,expiration:e.expiration}}function gq(e,t){let n=setTimeout(()=>{throw Error(`SignatureV4S3Express credential override was created but not called.`)},10),r=e.credentialProvider;e.credentialProvider=()=>(clearTimeout(n),e.credentialProvider=r,Promise.resolve(t))}var _q=e=>(t,n)=>async r=>{if(n.endpointV2){let t=n.endpointV2,a=t.properties?.authSchemes?.[0]?.name===dq;if((t.properties?.backend===`S3Express`||t.properties?.bucketType===`Directory`)&&(Ur(n,`S3_EXPRESS_BUCKET`,`J`),n.isS3ExpressBucket=!0),a){let t=r.input.Bucket;if(t){let a=await e.s3ExpressIdentityProvider.getS3ExpressIdentity(await e.credentials(),{Bucket:t});n.s3ExpressIdentity=a,i.isInstance(r.request)&&a.sessionToken&&(r.request.headers[pq]=a.sessionToken)}}}return t(r)},vq={name:`s3ExpressMiddleware`,step:`build`,tags:[`S3`,`S3_EXPRESS`],override:!0},yq=e=>({applyToStack:t=>{t.add(_q(e),vq)}}),bq=async(e,t,n,r)=>{let i=await r.signWithCredentials(n,e,{});if(i.headers[`X-Amz-Security-Token`]||i.headers[`x-amz-security-token`])throw Error(`X-Amz-Security-Token must not be set for s3-express requests.`);return i},xq=e=>e=>{throw e},Sq=(e,t)=>{},Cq=e=>(t,n)=>async r=>{if(!i.isInstance(r.request))return t(r);let a=_e(n).selectedHttpAuthScheme;if(!a)throw Error(`No HttpAuthScheme was selected: unable to sign request`);let{httpAuthOption:{signingProperties:o={}},identity:s,signer:c}=a,l;l=n.s3ExpressIdentity?await bq(n.s3ExpressIdentity,o,r.request,await e.signer()):await c.sign(r.request,s,o);let u=await t({...r,request:l}).catch((c.errorHandler||xq)(o));return(c.successHandler||Sq)(u.response,o),u},wq=e=>({applyToStack:t=>{t.addRelativeTo(Cq(e),Le)}}),Tq=(e,{session:t})=>{let[n,r]=t,{forcePathStyle:i,useAccelerateEndpoint:a,disableMultiregionAccessPoints:o,followRegionRedirects:s,s3ExpressIdentityProvider:c,bucketEndpoint:l,expectContinueHeader:u}=e;return Object.assign(e,{forcePathStyle:i??!1,useAccelerateEndpoint:a??!1,disableMultiregionAccessPoints:o??!1,followRegionRedirects:s??!1,s3ExpressIdentityProvider:c??new uq(async e=>n().send(new r({Bucket:e}))),bucketEndpoint:l??!1,expectContinueHeader:u??2097152})},Eq={CopyObjectCommand:!0,UploadPartCopyCommand:!0,CompleteMultipartUploadCommand:!0},Dq=3e3,Oq=e=>(t,n)=>async r=>{let i=await t(r),{response:a}=i;if(!ge.isInstance(a))return i;let{statusCode:o,body:s}=a;if(o<200||o>=300||!(typeof s?.stream==`function`||typeof s?.pipe==`function`||typeof s?.tee==`function`))return i;let c=s,l=s;s&&typeof s==`object`&&!(s instanceof Uint8Array)&&([c,l]=await ct(s)),a.body=l;let u=await kq(c,{streamCollector:async e=>Je(e,Dq)});typeof c?.destroy==`function`&&c.destroy();let d=e.utf8Encoder(u.subarray(u.length-16));if(u.length===0&&Eq[n.commandName]){let e=Error(`S3 aborted request`);throw e.name=`InternalError`,e}return d&&d.endsWith(``)&&(a.statusCode=400),i},kq=(e=new Uint8Array,t)=>e instanceof Uint8Array?Promise.resolve(e):t.streamCollector(e)||Promise.resolve(new Uint8Array),Aq={relation:`after`,toMiddleware:`deserializerMiddleware`,tags:[`THROW_200_EXCEPTIONS`,`S3`],name:`throw200ExceptionsMiddleware`,override:!0},jq=e=>({applyToStack:t=>{t.addRelativeTo(Oq(e),Aq)}}),Mq=e=>typeof e==`string`&&e.indexOf(`arn:`)===0&&e.split(`:`).length>=6;function Nq(e){return(t,n)=>async r=>{if(e.bucketEndpoint){let e=n.endpointV2;if(e){let t=r.input.Bucket;if(typeof t==`string`)try{let r=new URL(t);n.endpointV2={...e,url:r}}catch(e){let r=`@aws-sdk/middleware-sdk-s3: bucketEndpoint=true was set but Bucket=${t} could not be parsed as URL.`;throw n.logger?.constructor?.name===`NoOpLogger`?console.warn(r):n.logger?.warn?.(r),e}}}return t(r)}}var Pq={name:`bucketEndpointMiddleware`,override:!0,relation:`after`,toMiddleware:`endpointV2Middleware`};function Fq({bucketEndpoint:e}){return t=>async n=>{let{input:{Bucket:r}}=n;if(!e&&typeof r==`string`&&!Mq(r)&&r.indexOf(`/`)>=0){let e=Error(`Bucket name shouldn't contain '/', received '${r}'`);throw e.name=`InvalidBucketName`,e}return t({...n})}}var Iq={step:`initialize`,tags:[`VALIDATE_BUCKET_NAME`],name:`validateBucketNameMiddleware`,override:!0},Lq=e=>({applyToStack:t=>{t.add(Fq(e),Iq),t.addRelativeTo(Nq(e),Pq)}}),Rq=class extends Lo{async serializeRequest(e,t,n){let r=await super.serializeRequest(e,t,n),i=p.of(e.input),a=i.getSchema(),o=0,s=a[6]??0;if(t&&typeof t==`object`)for(let[e,n]of i.structIterator()){if(++o>s)break;if(e===`Bucket`){if(!t.Bucket&&n.getMergedTraits().httpLabel)throw Error(`No value provided for input HTTP label: Bucket.`);break}}return r}},zq=e=>Object.assign(e,{eventStreamMarshaller:e.eventStreamSerdeProvider(e)}),Bq={CrtSignerV4:null},Vq=class{sigv4aSigner;sigv4Signer;signerOptions;static sigv4aDependency(){return typeof Bq.CrtSignerV4==`function`?`crt`:typeof ve.SignatureV4a==`function`?`js`:`none`}constructor(e){this.sigv4Signer=new mq(e),this.signerOptions=e}async sign(e,t={}){return t.signingRegion===`*`?this.getSigv4aSigner().sign(e,t):this.sigv4Signer.sign(e,t)}async signWithCredentials(e,t,n={}){if(n.signingRegion===`*`){let r=this.getSigv4aSigner(),i=Bq.CrtSignerV4;if(i&&r instanceof i)return r.signWithCredentials(e,t,n);throw Error(`signWithCredentials with signingRegion '*' is only supported when using the CRT dependency @aws-sdk/signature-v4-crt. Please check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. You must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}return this.sigv4Signer.signWithCredentials(e,t,n)}async presign(e,t={}){if(t.signingRegion===`*`){let n=this.getSigv4aSigner(),r=Bq.CrtSignerV4;if(r&&n instanceof r)return n.presign(e,t);throw Error(`presign with signingRegion '*' is only supported when using the CRT dependency @aws-sdk/signature-v4-crt. Please check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. You must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}return this.sigv4Signer.presign(e,t)}async presignWithCredentials(e,t,n={}){if(n.signingRegion===`*`)throw Error(`Method presignWithCredentials is not supported for [signingRegion=*].`);return this.sigv4Signer.presignWithCredentials(e,t,n)}getSigv4aSigner(){if(!this.sigv4aSigner){let e=Bq.CrtSignerV4,t=ve.SignatureV4a;if(this.signerOptions.runtime===`node`){if(!e&&!t)throw Error(`Neither CRT nor JS SigV4a implementation is available. Please load either @aws-sdk/signature-v4-crt or @aws-sdk/signature-v4a. For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`);if(e&&typeof e==`function`)this.sigv4aSigner=new e({...this.signerOptions,signingAlgorithm:1});else if(t&&typeof t==`function`)this.sigv4aSigner=new t({...this.signerOptions});else throw Error(`Available SigV4a implementation is not a valid constructor. Please ensure you've properly imported @aws-sdk/signature-v4-crt or @aws-sdk/signature-v4a.For more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`)}else{if(!t||typeof t!=`function`)throw Error(`JS SigV4a implementation is not available or not a valid constructor. Please check whether you have installed the @aws-sdk/signature-v4a package explicitly. The CRT implementation is not available for browsers. You must also register the package by calling [require('@aws-sdk/signature-v4a');] or an ESM equivalent such as [import '@aws-sdk/signature-v4a';]. For more information please go to https://github.com/aws/aws-sdk-js-v3#using-javascript-non-crt-implementation-of-sigv4a`);this.sigv4aSigner=new t({...this.signerOptions})}}return this.sigv4aSigner}},Hq=`required`,O=`type`,k=`rules`,A=`conditions`,j=`fn`,M=`argv`,N=`ref`,P=`assign`,F=`url`,I=`properties`,Uq=`backend`,Wq=`authSchemes`,Gq=`disableDoubleEncoding`,Kq=`signingName`,qq=`signingRegion`,L=`headers`,Jq=`signingRegionSet`,Yq=6,Xq=!1,Zq=!0,Qq=`isSet`,$q=`booleanEquals`,R=`error`,eJ=`aws.partition`,z=`stringEquals`,tJ=`getAttr`,nJ=`name`,B=`substring`,rJ=`bucketSuffix`,iJ=`parseURL`,V=`endpoint`,H=`tree`,aJ=`aws.isVirtualHostableS3Bucket`,oJ=`{url#scheme}://{Bucket}.{url#authority}{url#path}`,sJ=`not`,cJ=`accessPointSuffix`,lJ=`{url#scheme}://{url#authority}{url#path}`,uJ=`hardwareType`,dJ=`regionPrefix`,fJ=`bucketAliasSuffix`,pJ=`outpostId`,mJ=`isValidHostLabel`,hJ=`sigv4a`,gJ=`s3-outposts`,_J=`s3`,vJ=`{url#scheme}://{url#authority}{url#normalizedPath}{Bucket}`,yJ=`https://{Bucket}.s3-accelerate.{partitionResult#dnsSuffix}`,bJ=`https://{Bucket}.s3.{partitionResult#dnsSuffix}`,xJ=`aws.parseArn`,SJ=`bucketArn`,CJ=`arnType`,wJ=``,TJ=`s3-object-lambda`,EJ=`accesspoint`,DJ=`accessPointName`,OJ=`{url#scheme}://{accessPointName}-{bucketArn#accountId}.{url#authority}{url#path}`,kJ=`mrapPartition`,AJ=`outpostType`,jJ=`arnPrefix`,MJ=`{url#scheme}://{url#authority}{url#normalizedPath}{uri_encoded_bucket}`,NJ=`https://s3.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,PJ=`https://s3.{partitionResult#dnsSuffix}`,FJ={[Hq]:!1,[O]:`string`},IJ={[Hq]:!0,default:!1,[O]:`boolean`},LJ={[Hq]:!1,[O]:`boolean`},RJ={[j]:$q,[M]:[{[N]:`Accelerate`},!0]},U={[j]:$q,[M]:[{[N]:`UseFIPS`},!0]},W={[j]:$q,[M]:[{[N]:`UseDualStack`},!0]},zJ={[j]:Qq,[M]:[{[N]:`Endpoint`}]},BJ={[j]:eJ,[M]:[{[N]:`Region`}],[P]:`partitionResult`},VJ={[j]:z,[M]:[{[j]:tJ,[M]:[{[N]:`partitionResult`},nJ]},`aws-cn`]},HJ={[j]:Qq,[M]:[{[N]:`Bucket`}]},G={[N]:`Bucket`},UJ={[A]:[RJ],[R]:`S3Express does not support S3 Accelerate.`,[O]:R},WJ={[A]:[zJ,{[j]:iJ,[M]:[{[N]:`Endpoint`}],[P]:`url`}],[k]:[{[A]:[{[j]:Qq,[M]:[{[N]:`DisableS3ExpressSessionAuth`}]},{[j]:$q,[M]:[{[N]:`DisableS3ExpressSessionAuth`},!0]}],[k]:[{[A]:[{[j]:$q,[M]:[{[j]:tJ,[M]:[{[N]:`url`},`isIp`]},!0]}],[k]:[{[A]:[{[j]:`uriEncode`,[M]:[G],[P]:`uri_encoded_bucket`}],[k]:[{[V]:{[F]:`{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],[O]:H}],[O]:H},{[A]:[{[j]:aJ,[M]:[G,!1]}],[k]:[{[V]:{[F]:oJ,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],[O]:H},{[R]:`S3Express bucket name is not a valid virtual hostable name.`,[O]:R}],[O]:H},{[A]:[{[j]:$q,[M]:[{[j]:tJ,[M]:[{[N]:`url`},`isIp`]},!0]}],[k]:[{[A]:[{[j]:`uriEncode`,[M]:[G],[P]:`uri_encoded_bucket`}],[k]:[{[V]:{[F]:`{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],[O]:H}],[O]:H},{[A]:[{[j]:aJ,[M]:[G,!1]}],[k]:[{[V]:{[F]:oJ,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],[O]:H},{[R]:`S3Express bucket name is not a valid virtual hostable name.`,[O]:R}],[O]:H},GJ={[j]:iJ,[M]:[{[N]:`Endpoint`}],[P]:`url`},KJ={[j]:$q,[M]:[{[j]:tJ,[M]:[{[N]:`url`},`isIp`]},!0]},qJ={[N]:`url`},JJ={[j]:`uriEncode`,[M]:[G],[P]:`uri_encoded_bucket`},YJ={[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:`s3express`,[qq]:`{Region}`}]},K={},XJ={[j]:aJ,[M]:[G,!1]},ZJ={[R]:`S3Express bucket name is not a valid virtual hostable name.`,[O]:R},QJ={[j]:Qq,[M]:[{[N]:`UseS3ExpressControlEndpoint`}]},$J={[j]:$q,[M]:[{[N]:`UseS3ExpressControlEndpoint`},!0]},q={[j]:sJ,[M]:[zJ]},J={[j]:$q,[M]:[{[N]:`UseDualStack`},!1]},Y={[j]:$q,[M]:[{[N]:`UseFIPS`},!1]},eY={[R]:`Unrecognized S3Express bucket name format.`,[O]:R},tY={[j]:sJ,[M]:[HJ]},nY={[N]:uJ},rY={[A]:[q],[R]:`Expected a endpoint to be specified but no endpoint was found`,[O]:R},iY={[Wq]:[{[Gq]:!0,[nJ]:hJ,[Kq]:gJ,[Jq]:[`*`]},{[Gq]:!0,[nJ]:`sigv4`,[Kq]:gJ,[qq]:`{Region}`}]},aY={[j]:$q,[M]:[{[N]:`ForcePathStyle`},!1]},oY={[N]:`ForcePathStyle`},sY={[j]:$q,[M]:[{[N]:`Accelerate`},!1]},cY={[j]:z,[M]:[{[N]:`Region`},`aws-global`]},lY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:_J,[qq]:`us-east-1`}]},X={[j]:sJ,[M]:[cY]},uY={[j]:$q,[M]:[{[N]:`UseGlobalEndpoint`},!0]},dY={[F]:`https://{Bucket}.s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:_J,[qq]:`{Region}`}]},[L]:{}},fY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:_J,[qq]:`{Region}`}]},pY={[j]:$q,[M]:[{[N]:`UseGlobalEndpoint`},!1]},mY={[F]:`https://{Bucket}.s3-fips.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},hY={[F]:`https://{Bucket}.s3-accelerate.dualstack.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},gY={[F]:`https://{Bucket}.s3.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},_Y={[j]:$q,[M]:[{[j]:tJ,[M]:[qJ,`isIp`]},!1]},vY={[F]:vJ,[I]:fY,[L]:{}},yY={[F]:oJ,[I]:fY,[L]:{}},bY={[V]:yY,[O]:V},xY={[F]:yJ,[I]:fY,[L]:{}},SY={[F]:`https://{Bucket}.s3.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},CY={[R]:`Invalid region: region was not a valid DNS name.`,[O]:R},wY={[N]:SJ},TY={[N]:CJ},EY={[j]:tJ,[M]:[wY,`service`]},DY={[N]:DJ},OY={[A]:[W],[R]:`S3 Object Lambda does not support Dual-stack`,[O]:R},kY={[A]:[RJ],[R]:`S3 Object Lambda does not support S3 Accelerate`,[O]:R},AY={[A]:[{[j]:Qq,[M]:[{[N]:`DisableAccessPoints`}]},{[j]:$q,[M]:[{[N]:`DisableAccessPoints`},!0]}],[R]:`Access points are not supported for this operation`,[O]:R},jY={[A]:[{[j]:Qq,[M]:[{[N]:`UseArnRegion`}]},{[j]:$q,[M]:[{[N]:`UseArnRegion`},!1]},{[j]:sJ,[M]:[{[j]:z,[M]:[{[j]:tJ,[M]:[wY,`region`]},`{Region}`]}]}],[R]:"Invalid configuration: region from ARN `{bucketArn#region}` does not match client region `{Region}` and UseArnRegion is `false`",[O]:R},MY={[j]:tJ,[M]:[{[N]:`bucketPartition`},nJ]},NY={[j]:tJ,[M]:[wY,`accountId`]},PY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:TJ,[qq]:`{bucketArn#region}`}]},FY={[R]:"Invalid ARN: The access point name may only contain a-z, A-Z, 0-9 and `-`. Found: `{accessPointName}`",[O]:R},IY={[R]:"Invalid ARN: The account id may only contain a-z, A-Z, 0-9 and `-`. Found: `{bucketArn#accountId}`",[O]:R},LY={[R]:"Invalid region in ARN: `{bucketArn#region}` (invalid DNS name)",[O]:R},RY={[R]:"Client was configured for partition `{partitionResult#name}` but ARN (`{Bucket}`) has `{bucketPartition#name}`",[O]:R},zY={[R]:"Invalid ARN: The ARN may only contain a single resource component after `accesspoint`.",[O]:R},BY={[R]:"Invalid ARN: Expected a resource of the format `accesspoint:` but no name was provided",[O]:R},VY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:_J,[qq]:`{bucketArn#region}`}]},HY={[Wq]:[{[Gq]:!0,[nJ]:hJ,[Kq]:gJ,[Jq]:[`*`]},{[Gq]:!0,[nJ]:`sigv4`,[Kq]:gJ,[qq]:`{bucketArn#region}`}]},UY={[j]:xJ,[M]:[G]},WY={[F]:`https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:fY,[L]:{}},GY={[F]:`https://s3-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:fY,[L]:{}},KY={[F]:`https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:fY,[L]:{}},qY={[F]:MJ,[I]:fY,[L]:{}},JY={[F]:`https://s3.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:fY,[L]:{}},YY={[N]:`UseObjectLambdaEndpoint`},XY={[Wq]:[{[Gq]:!0,[nJ]:`sigv4`,[Kq]:TJ,[qq]:`{Region}`}]},ZY={[F]:`https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},QY={[F]:`https://s3-fips.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},$Y={[F]:`https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},eX={[F]:lJ,[I]:fY,[L]:{}},tX={[F]:`https://s3.{Region}.{partitionResult#dnsSuffix}`,[I]:fY,[L]:{}},nX=[{[N]:`Region`}],rX=[{[N]:`Endpoint`}],iX=[G],aX=[RJ],oX=[zJ,GJ],sX=[{[j]:Qq,[M]:[{[N]:`DisableS3ExpressSessionAuth`}]},{[j]:$q,[M]:[{[N]:`DisableS3ExpressSessionAuth`},!0]}],cX=[JJ],lX=[XJ],uX=[BJ],dX=[U,W],fX=[U,J],pX=[Y,W],mX=[Y,J],hX=[{[j]:B,[M]:[G,6,14,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,14,16,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],gX=[{[A]:[U,W],[V]:{[F]:`https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:{}},[O]:V},{[A]:fX,[V]:{[F]:`https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:{}},[O]:V},{[A]:pX,[V]:{[F]:`https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:{}},[O]:V},{[A]:mX,[V]:{[F]:`https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:{}},[O]:V}],_X=[{[j]:B,[M]:[G,6,15,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,15,17,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],vX=[{[j]:B,[M]:[G,6,19,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,19,21,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],yX=[{[j]:B,[M]:[G,6,20,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,20,22,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],bX=[{[j]:B,[M]:[G,6,26,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,26,28,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],xX=[{[A]:[U,W],[V]:{[F]:`https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V},{[A]:fX,[V]:{[F]:`https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V},{[A]:pX,[V]:{[F]:`https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V},{[A]:mX,[V]:{[F]:`https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.{partitionResult#dnsSuffix}`,[I]:{[Uq]:`S3Express`,[Wq]:[{[Gq]:!0,[nJ]:`sigv4-s3express`,[Kq]:`s3express`,[qq]:`{Region}`}]},[L]:{}},[O]:V}],SX=[G,0,7,!0],CX=[{[j]:B,[M]:[G,7,15,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,15,17,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],wX=[{[j]:B,[M]:[G,7,16,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,16,18,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],TX=[{[j]:B,[M]:[G,7,20,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,20,22,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],EX=[{[j]:B,[M]:[G,7,21,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,21,23,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],DX=[{[j]:B,[M]:[G,7,27,!0],[P]:`s3expressAvailabilityZoneId`},{[j]:B,[M]:[G,27,29,!0],[P]:`s3expressAvailabilityZoneDelim`},{[j]:z,[M]:[{[N]:`s3expressAvailabilityZoneDelim`},`--`]}],OX=[HJ],kX=[{[j]:mJ,[M]:[{[N]:pJ},!1]}],AX=[{[j]:z,[M]:[{[N]:dJ},`beta`]}],jX=[`*`],MX=[{[j]:mJ,[M]:[{[N]:`Region`},!1]}],NX=[{[j]:z,[M]:[{[N]:`Region`},`us-east-1`]}],PX=[{[j]:z,[M]:[TY,EJ]}],FX=[{[j]:tJ,[M]:[wY,`resourceId[1]`],[P]:DJ},{[j]:sJ,[M]:[{[j]:z,[M]:[DY,wJ]}]}],IX=[wY,`resourceId[1]`],LX=[W],RX=[{[j]:sJ,[M]:[{[j]:z,[M]:[{[j]:tJ,[M]:[wY,`region`]},wJ]}]}],zX=[{[j]:sJ,[M]:[{[j]:Qq,[M]:[{[j]:tJ,[M]:[wY,`resourceId[2]`]}]}]}],BX=[wY,`resourceId[2]`],VX=[{[j]:eJ,[M]:[{[j]:tJ,[M]:[wY,`region`]}],[P]:`bucketPartition`}],HX=[{[j]:z,[M]:[MY,{[j]:tJ,[M]:[{[N]:`partitionResult`},nJ]}]}],UX=[{[j]:mJ,[M]:[{[j]:tJ,[M]:[wY,`region`]},!0]}],WX=[{[j]:mJ,[M]:[NY,!1]}],GX=[{[j]:mJ,[M]:[DY,!1]}],KX=[U],qX=[{[j]:mJ,[M]:[{[N]:`Region`},!0]}],JX={version:`1.0`,parameters:{Bucket:FJ,Region:FJ,UseFIPS:IJ,UseDualStack:IJ,Endpoint:FJ,ForcePathStyle:IJ,Accelerate:IJ,UseGlobalEndpoint:IJ,UseObjectLambdaEndpoint:LJ,Key:FJ,Prefix:FJ,CopySource:FJ,DisableAccessPoints:LJ,DisableMultiRegionAccessPoints:IJ,UseArnRegion:LJ,UseS3ExpressControlEndpoint:LJ,DisableS3ExpressSessionAuth:LJ},[k]:[{[A]:[{[j]:Qq,[M]:nX}],[k]:[{[A]:[RJ,U],error:`Accelerate cannot be used with FIPS`,[O]:R},{[A]:[W,zJ],error:`Cannot set dual-stack in combination with a custom endpoint.`,[O]:R},{[A]:[zJ,U],error:`A custom endpoint cannot be combined with FIPS`,[O]:R},{[A]:[zJ,RJ],error:`A custom endpoint cannot be combined with S3 Accelerate`,[O]:R},{[A]:[U,BJ,VJ],error:`Partition does not support FIPS`,[O]:R},{[A]:[HJ,{[j]:B,[M]:[G,0,Yq,Zq],[P]:rJ},{[j]:z,[M]:[{[N]:rJ},`--x-s3`]}],[k]:[UJ,WJ,{[A]:[QJ,$J],[k]:[{[A]:uX,[k]:[{[A]:[JJ,q],[k]:[{[A]:dX,endpoint:{[F]:`https://s3express-control-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:YJ,[L]:K},[O]:V},{[A]:fX,endpoint:{[F]:`https://s3express-control-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:YJ,[L]:K},[O]:V},{[A]:pX,endpoint:{[F]:`https://s3express-control.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:YJ,[L]:K},[O]:V},{[A]:mX,endpoint:{[F]:`https://s3express-control.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:YJ,[L]:K},[O]:V}],[O]:H}],[O]:H}],[O]:H},{[A]:lX,[k]:[{[A]:uX,[k]:[{[A]:sX,[k]:[{[A]:hX,[k]:gX,[O]:H},{[A]:_X,[k]:gX,[O]:H},{[A]:vX,[k]:gX,[O]:H},{[A]:yX,[k]:gX,[O]:H},{[A]:bX,[k]:gX,[O]:H},eY],[O]:H},{[A]:hX,[k]:xX,[O]:H},{[A]:_X,[k]:xX,[O]:H},{[A]:vX,[k]:xX,[O]:H},{[A]:yX,[k]:xX,[O]:H},{[A]:bX,[k]:xX,[O]:H},eY],[O]:H}],[O]:H},ZJ],[O]:H},{[A]:[HJ,{[j]:B,[M]:SX,[P]:cJ},{[j]:z,[M]:[{[N]:cJ},`--xa-s3`]}],[k]:[UJ,WJ,{[A]:lX,[k]:[{[A]:uX,[k]:[{[A]:sX,[k]:[{[A]:CX,[k]:gX,[O]:H},{[A]:wX,[k]:gX,[O]:H},{[A]:TX,[k]:gX,[O]:H},{[A]:EX,[k]:gX,[O]:H},{[A]:DX,[k]:gX,[O]:H},eY],[O]:H},{[A]:CX,[k]:xX,[O]:H},{[A]:wX,[k]:xX,[O]:H},{[A]:TX,[k]:xX,[O]:H},{[A]:EX,[k]:xX,[O]:H},{[A]:DX,[k]:xX,[O]:H},eY],[O]:H}],[O]:H},ZJ],[O]:H},{[A]:[tY,QJ,$J],[k]:[{[A]:uX,[k]:[{[A]:oX,endpoint:{[F]:lJ,[I]:YJ,[L]:K},[O]:V},{[A]:dX,endpoint:{[F]:`https://s3express-control-fips.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:K},[O]:V},{[A]:fX,endpoint:{[F]:`https://s3express-control-fips.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:K},[O]:V},{[A]:pX,endpoint:{[F]:`https://s3express-control.dualstack.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:K},[O]:V},{[A]:mX,endpoint:{[F]:`https://s3express-control.{Region}.{partitionResult#dnsSuffix}`,[I]:YJ,[L]:K},[O]:V}],[O]:H}],[O]:H},{[A]:[HJ,{[j]:B,[M]:[G,49,50,Zq],[P]:uJ},{[j]:B,[M]:[G,8,12,Zq],[P]:dJ},{[j]:B,[M]:SX,[P]:fJ},{[j]:B,[M]:[G,32,49,Zq],[P]:pJ},{[j]:eJ,[M]:nX,[P]:`regionPartition`},{[j]:z,[M]:[{[N]:fJ},`--op-s3`]}],[k]:[{[A]:kX,[k]:[{[A]:lX,[k]:[{[A]:[{[j]:z,[M]:[nY,`e`]}],[k]:[{[A]:AX,[k]:[rY,{[A]:oX,endpoint:{[F]:`https://{Bucket}.ec2.{url#authority}`,[I]:iY,[L]:K},[O]:V}],[O]:H},{endpoint:{[F]:`https://{Bucket}.ec2.s3-outposts.{Region}.{regionPartition#dnsSuffix}`,[I]:iY,[L]:K},[O]:V}],[O]:H},{[A]:[{[j]:z,[M]:[nY,`o`]}],[k]:[{[A]:AX,[k]:[rY,{[A]:oX,endpoint:{[F]:`https://{Bucket}.op-{outpostId}.{url#authority}`,[I]:iY,[L]:K},[O]:V}],[O]:H},{endpoint:{[F]:`https://{Bucket}.op-{outpostId}.s3-outposts.{Region}.{regionPartition#dnsSuffix}`,[I]:iY,[L]:K},[O]:V}],[O]:H},{error:`Unrecognized hardware type: "Expected hardware type o or e but got {hardwareType}"`,[O]:R}],[O]:H},{error:`Invalid Outposts Bucket alias - it must be a valid bucket name.`,[O]:R}],[O]:H},{error:"Invalid ARN: The outpost Id must only contain a-z, A-Z, 0-9 and `-`.",[O]:R}],[O]:H},{[A]:OX,[k]:[{[A]:[zJ,{[j]:sJ,[M]:[{[j]:Qq,[M]:[{[j]:iJ,[M]:rX}]}]}],error:"Custom endpoint `{Endpoint}` was not a valid URI",[O]:R},{[A]:[aY,XJ],[k]:[{[A]:uX,[k]:[{[A]:MX,[k]:[{[A]:[RJ,VJ],error:`S3 Accelerate cannot be used in this region`,[O]:R},{[A]:[W,U,sY,q,cY],endpoint:{[F]:`https://{Bucket}.s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,U,sY,q,X,uY],[k]:[{endpoint:dY,[O]:V}],[O]:H},{[A]:[W,U,sY,q,X,pY],endpoint:dY,[O]:V},{[A]:[J,U,sY,q,cY],endpoint:{[F]:`https://{Bucket}.s3-fips.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[J,U,sY,q,X,uY],[k]:[{endpoint:mY,[O]:V}],[O]:H},{[A]:[J,U,sY,q,X,pY],endpoint:mY,[O]:V},{[A]:[W,Y,RJ,q,cY],endpoint:{[F]:`https://{Bucket}.s3-accelerate.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,Y,RJ,q,X,uY],[k]:[{endpoint:hY,[O]:V}],[O]:H},{[A]:[W,Y,RJ,q,X,pY],endpoint:hY,[O]:V},{[A]:[W,Y,sY,q,cY],endpoint:{[F]:`https://{Bucket}.s3.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,Y,sY,q,X,uY],[k]:[{endpoint:gY,[O]:V}],[O]:H},{[A]:[W,Y,sY,q,X,pY],endpoint:gY,[O]:V},{[A]:[J,Y,sY,zJ,GJ,KJ,cY],endpoint:{[F]:vJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,Y,sY,zJ,GJ,_Y,cY],endpoint:{[F]:oJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,Y,sY,zJ,GJ,KJ,X,uY],[k]:[{[A]:NX,endpoint:vY,[O]:V},{endpoint:vY,[O]:V}],[O]:H},{[A]:[J,Y,sY,zJ,GJ,_Y,X,uY],[k]:[{[A]:NX,endpoint:yY,[O]:V},bY],[O]:H},{[A]:[J,Y,sY,zJ,GJ,KJ,X,pY],endpoint:vY,[O]:V},{[A]:[J,Y,sY,zJ,GJ,_Y,X,pY],endpoint:yY,[O]:V},{[A]:[J,Y,RJ,q,cY],endpoint:{[F]:yJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,Y,RJ,q,X,uY],[k]:[{[A]:NX,endpoint:xY,[O]:V},{endpoint:xY,[O]:V}],[O]:H},{[A]:[J,Y,RJ,q,X,pY],endpoint:xY,[O]:V},{[A]:[J,Y,sY,q,cY],endpoint:{[F]:bJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,Y,sY,q,X,uY],[k]:[{[A]:NX,endpoint:{[F]:bJ,[I]:fY,[L]:K},[O]:V},{endpoint:SY,[O]:V}],[O]:H},{[A]:[J,Y,sY,q,X,pY],endpoint:SY,[O]:V}],[O]:H},CY],[O]:H}],[O]:H},{[A]:[zJ,GJ,{[j]:z,[M]:[{[j]:tJ,[M]:[qJ,`scheme`]},`http`]},{[j]:aJ,[M]:[G,Zq]},aY,Y,J,sY],[k]:[{[A]:uX,[k]:[{[A]:MX,[k]:[bY],[O]:H},CY],[O]:H}],[O]:H},{[A]:[aY,{[j]:xJ,[M]:iX,[P]:SJ}],[k]:[{[A]:[{[j]:tJ,[M]:[wY,`resourceId[0]`],[P]:CJ},{[j]:sJ,[M]:[{[j]:z,[M]:[TY,wJ]}]}],[k]:[{[A]:[{[j]:z,[M]:[EY,TJ]}],[k]:[{[A]:PX,[k]:[{[A]:FX,[k]:[OY,kY,{[A]:RX,[k]:[AY,{[A]:zX,[k]:[jY,{[A]:VX,[k]:[{[A]:uX,[k]:[{[A]:HX,[k]:[{[A]:UX,[k]:[{[A]:[{[j]:z,[M]:[NY,wJ]}],error:`Invalid ARN: Missing account id`,[O]:R},{[A]:WX,[k]:[{[A]:GX,[k]:[{[A]:oX,endpoint:{[F]:OJ,[I]:PY,[L]:K},[O]:V},{[A]:KX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:PY,[L]:K},[O]:V},{endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:PY,[L]:K},[O]:V}],[O]:H},FY],[O]:H},IY],[O]:H},LY],[O]:H},RY],[O]:H}],[O]:H}],[O]:H},zY],[O]:H},{error:`Invalid ARN: bucket ARN is missing a region`,[O]:R}],[O]:H},BY],[O]:H},{error:"Invalid ARN: Object Lambda ARNs only support `accesspoint` arn types, but found: `{arnType}`",[O]:R}],[O]:H},{[A]:PX,[k]:[{[A]:FX,[k]:[{[A]:RX,[k]:[{[A]:PX,[k]:[{[A]:RX,[k]:[AY,{[A]:zX,[k]:[jY,{[A]:VX,[k]:[{[A]:uX,[k]:[{[A]:[{[j]:z,[M]:[MY,`{partitionResult#name}`]}],[k]:[{[A]:UX,[k]:[{[A]:[{[j]:z,[M]:[EY,_J]}],[k]:[{[A]:WX,[k]:[{[A]:GX,[k]:[{[A]:aX,error:`Access Points do not support S3 Accelerate`,[O]:R},{[A]:dX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:VY,[L]:K},[O]:V},{[A]:fX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:VY,[L]:K},[O]:V},{[A]:pX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:VY,[L]:K},[O]:V},{[A]:[Y,J,zJ,GJ],endpoint:{[F]:OJ,[I]:VY,[L]:K},[O]:V},{[A]:mX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:VY,[L]:K},[O]:V}],[O]:H},FY],[O]:H},IY],[O]:H},{error:`Invalid ARN: The ARN was not for the S3 service, found: {bucketArn#service}`,[O]:R}],[O]:H},LY],[O]:H},RY],[O]:H}],[O]:H}],[O]:H},zY],[O]:H}],[O]:H}],[O]:H},{[A]:[{[j]:mJ,[M]:[DY,Zq]}],[k]:[{[A]:LX,error:`S3 MRAP does not support dual-stack`,[O]:R},{[A]:KX,error:`S3 MRAP does not support FIPS`,[O]:R},{[A]:aX,error:`S3 MRAP does not support S3 Accelerate`,[O]:R},{[A]:[{[j]:$q,[M]:[{[N]:`DisableMultiRegionAccessPoints`},Zq]}],error:`Invalid configuration: Multi-Region Access Point ARNs are disabled.`,[O]:R},{[A]:[{[j]:eJ,[M]:nX,[P]:kJ}],[k]:[{[A]:[{[j]:z,[M]:[{[j]:tJ,[M]:[{[N]:kJ},nJ]},{[j]:tJ,[M]:[wY,`partition`]}]}],[k]:[{endpoint:{[F]:`https://{accessPointName}.accesspoint.s3-global.{mrapPartition#dnsSuffix}`,[I]:{[Wq]:[{[Gq]:Zq,name:hJ,[Kq]:_J,[Jq]:jX}]},[L]:K},[O]:V}],[O]:H},{error:"Client was configured for partition `{mrapPartition#name}` but bucket referred to partition `{bucketArn#partition}`",[O]:R}],[O]:H}],[O]:H},{error:`Invalid Access Point Name`,[O]:R}],[O]:H},BY],[O]:H},{[A]:[{[j]:z,[M]:[EY,gJ]}],[k]:[{[A]:LX,error:`S3 Outposts does not support Dual-stack`,[O]:R},{[A]:KX,error:`S3 Outposts does not support FIPS`,[O]:R},{[A]:aX,error:`S3 Outposts does not support S3 Accelerate`,[O]:R},{[A]:[{[j]:Qq,[M]:[{[j]:tJ,[M]:[wY,`resourceId[4]`]}]}],error:`Invalid Arn: Outpost Access Point ARN contains sub resources`,[O]:R},{[A]:[{[j]:tJ,[M]:IX,[P]:pJ}],[k]:[{[A]:kX,[k]:[jY,{[A]:VX,[k]:[{[A]:uX,[k]:[{[A]:HX,[k]:[{[A]:UX,[k]:[{[A]:WX,[k]:[{[A]:[{[j]:tJ,[M]:BX,[P]:AJ}],[k]:[{[A]:[{[j]:tJ,[M]:[wY,`resourceId[3]`],[P]:DJ}],[k]:[{[A]:[{[j]:z,[M]:[{[N]:AJ},EJ]}],[k]:[{[A]:oX,endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.{outpostId}.{url#authority}`,[I]:HY,[L]:K},[O]:V},{endpoint:{[F]:`https://{accessPointName}-{bucketArn#accountId}.{outpostId}.s3-outposts.{bucketArn#region}.{bucketPartition#dnsSuffix}`,[I]:HY,[L]:K},[O]:V}],[O]:H},{error:"Expected an outpost type `accesspoint`, found {outpostType}",[O]:R}],[O]:H},{error:`Invalid ARN: expected an access point name`,[O]:R}],[O]:H},{error:`Invalid ARN: Expected a 4-component resource`,[O]:R}],[O]:H},IY],[O]:H},LY],[O]:H},RY],[O]:H}],[O]:H}],[O]:H},{error:"Invalid ARN: The outpost Id may only contain a-z, A-Z, 0-9 and `-`. Found: `{outpostId}`",[O]:R}],[O]:H},{error:`Invalid ARN: The Outpost Id was not set`,[O]:R}],[O]:H},{error:`Invalid ARN: Unrecognized format: {Bucket} (type: {arnType})`,[O]:R}],[O]:H},{error:`Invalid ARN: No ARN type specified`,[O]:R}],[O]:H},{[A]:[{[j]:B,[M]:[G,0,4,Xq],[P]:jJ},{[j]:z,[M]:[{[N]:jJ},`arn:`]},{[j]:sJ,[M]:[{[j]:Qq,[M]:[UY]}]}],error:"Invalid ARN: `{Bucket}` was not a valid ARN",[O]:R},{[A]:[{[j]:$q,[M]:[oY,Zq]},UY],error:`Path-style addressing cannot be used with ARN buckets`,[O]:R},{[A]:cX,[k]:[{[A]:uX,[k]:[{[A]:[sY],[k]:[{[A]:[W,q,U,cY],endpoint:{[F]:`https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,q,U,X,uY],[k]:[{endpoint:WY,[O]:V}],[O]:H},{[A]:[W,q,U,X,pY],endpoint:WY,[O]:V},{[A]:[J,q,U,cY],endpoint:{[F]:`https://s3-fips.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:lY,[L]:K},[O]:V},{[A]:[J,q,U,X,uY],[k]:[{endpoint:GY,[O]:V}],[O]:H},{[A]:[J,q,U,X,pY],endpoint:GY,[O]:V},{[A]:[W,q,Y,cY],endpoint:{[F]:`https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}`,[I]:lY,[L]:K},[O]:V},{[A]:[W,q,Y,X,uY],[k]:[{endpoint:KY,[O]:V}],[O]:H},{[A]:[W,q,Y,X,pY],endpoint:KY,[O]:V},{[A]:[J,zJ,GJ,Y,cY],endpoint:{[F]:MJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,zJ,GJ,Y,X,uY],[k]:[{[A]:NX,endpoint:qY,[O]:V},{endpoint:qY,[O]:V}],[O]:H},{[A]:[J,zJ,GJ,Y,X,pY],endpoint:qY,[O]:V},{[A]:[J,q,Y,cY],endpoint:{[F]:NJ,[I]:lY,[L]:K},[O]:V},{[A]:[J,q,Y,X,uY],[k]:[{[A]:NX,endpoint:{[F]:NJ,[I]:fY,[L]:K},[O]:V},{endpoint:JY,[O]:V}],[O]:H},{[A]:[J,q,Y,X,pY],endpoint:JY,[O]:V}],[O]:H},{error:`Path-style addressing cannot be used with S3 Accelerate`,[O]:R}],[O]:H}],[O]:H}],[O]:H},{[A]:[{[j]:Qq,[M]:[YY]},{[j]:$q,[M]:[YY,Zq]}],[k]:[{[A]:uX,[k]:[{[A]:qX,[k]:[OY,kY,{[A]:oX,endpoint:{[F]:lJ,[I]:XY,[L]:K},[O]:V},{[A]:KX,endpoint:{[F]:`https://s3-object-lambda-fips.{Region}.{partitionResult#dnsSuffix}`,[I]:XY,[L]:K},[O]:V},{endpoint:{[F]:`https://s3-object-lambda.{Region}.{partitionResult#dnsSuffix}`,[I]:XY,[L]:K},[O]:V}],[O]:H},CY],[O]:H}],[O]:H},{[A]:[tY],[k]:[{[A]:uX,[k]:[{[A]:qX,[k]:[{[A]:[U,W,q,cY],endpoint:{[F]:`https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[U,W,q,X,uY],[k]:[{endpoint:ZY,[O]:V}],[O]:H},{[A]:[U,W,q,X,pY],endpoint:ZY,[O]:V},{[A]:[U,J,q,cY],endpoint:{[F]:`https://s3-fips.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[U,J,q,X,uY],[k]:[{endpoint:QY,[O]:V}],[O]:H},{[A]:[U,J,q,X,pY],endpoint:QY,[O]:V},{[A]:[Y,W,q,cY],endpoint:{[F]:`https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}`,[I]:lY,[L]:K},[O]:V},{[A]:[Y,W,q,X,uY],[k]:[{endpoint:$Y,[O]:V}],[O]:H},{[A]:[Y,W,q,X,pY],endpoint:$Y,[O]:V},{[A]:[Y,J,zJ,GJ,cY],endpoint:{[F]:lJ,[I]:lY,[L]:K},[O]:V},{[A]:[Y,J,zJ,GJ,X,uY],[k]:[{[A]:NX,endpoint:eX,[O]:V},{endpoint:eX,[O]:V}],[O]:H},{[A]:[Y,J,zJ,GJ,X,pY],endpoint:eX,[O]:V},{[A]:[Y,J,q,cY],endpoint:{[F]:PJ,[I]:lY,[L]:K},[O]:V},{[A]:[Y,J,q,X,uY],[k]:[{[A]:NX,endpoint:{[F]:PJ,[I]:fY,[L]:K},[O]:V},{endpoint:tX,[O]:V}],[O]:H},{[A]:[Y,J,q,X,pY],endpoint:tX,[O]:V}],[O]:H},CY],[O]:H}],[O]:H}],[O]:H},{error:`A region must be set when sending requests to S3.`,[O]:R}]},YX=new er({size:50,params:[`Accelerate`,`Bucket`,`DisableAccessPoints`,`DisableMultiRegionAccessPoints`,`DisableS3ExpressSessionAuth`,`Endpoint`,`ForcePathStyle`,`Region`,`UseArnRegion`,`UseDualStack`,`UseFIPS`,`UseGlobalEndpoint`,`UseObjectLambdaEndpoint`,`UseS3ExpressControlEndpoint`]}),XX=(e,t={})=>YX.get(e,()=>Mr(JX,{endpointParams:e,logger:t.logger}));ar.aws=Vr;var ZX=(e=>async(t,n,r)=>{if(!r)throw Error("Could not find `input` for `defaultEndpointRuleSetHttpAuthSchemeParametersProvider`");let i=await e(t,n,r),a=_e(n)?.commandInstance?.constructor?.getEndpointParameterInstructions;if(!a)throw Error(`getEndpointParameterInstructions() is not defined on '${n.commandName}'`);let o=await Hi(r,{getEndpointParameterInstructions:a},t);return Object.assign(i,o)})(async(e,t,n)=>({operation:_e(t).operation,region:await f(e.region)()||(()=>{throw Error("expected `region` to be configured for `aws.auth#sigv4`")})()}));function QX(e){return{schemeId:`aws.auth#sigv4`,signingProperties:{name:`s3`,region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}function $X(e){return{schemeId:`aws.auth#sigv4a`,signingProperties:{name:`s3`,region:e.region},propertiesExtractor:(e,t)=>({signingProperties:{config:e,context:t}})}}var eZ=((e,t,n)=>r=>{let i=e(r).properties?.authSchemes;if(!i)return t(r);let a=[];for(let e of i){let{name:t,properties:o={},...s}=e,c=t.toLowerCase();t!==c&&console.warn(`HttpAuthScheme has been normalized with lowercasing: '${t}' to '${c}'`);let l;if(c===`sigv4a`){l=`aws.auth#sigv4a`;let e=i.find(e=>{let t=e.name.toLowerCase();return t!==`sigv4a`&&t.startsWith(`sigv4`)});if(Vq.sigv4aDependency()===`none`&&e)continue}else if(c.startsWith(`sigv4`))l=`aws.auth#sigv4`;else throw Error(`Unknown HttpAuthScheme found in '@smithy.rules#endpointRuleSet': '${c}'`);let u=n[l];if(!u)throw Error(`Could not find HttpAuthOption create function for '${l}'`);let d=u(r);d.schemeId=l,d.signingProperties={...d.signingProperties||{},...s,...o},a.push(d)}return a})(XX,e=>{let t=[];switch(e.operation){default:t.push(QX(e)),t.push($X(e))}return t},{"aws.auth#sigv4":QX,"aws.auth#sigv4a":$X}),tZ=e=>{let t=Pa(Fa(e));return Object.assign(t,{authSchemePreference:f(e.authSchemePreference??[])})},nZ=e=>Object.assign(e,{useFipsEndpoint:e.useFipsEndpoint??!1,useDualstackEndpoint:e.useDualstackEndpoint??!1,forcePathStyle:e.forcePathStyle??!1,useAccelerateEndpoint:e.useAccelerateEndpoint??!1,useGlobalEndpoint:e.useGlobalEndpoint??!1,disableMultiregionAccessPoints:e.disableMultiregionAccessPoints??!1,defaultSigningName:`s3`,clientContextParams:e.clientContextParams??{}}),rZ={ForcePathStyle:{type:`clientContextParams`,name:`forcePathStyle`},UseArnRegion:{type:`clientContextParams`,name:`useArnRegion`},DisableMultiRegionAccessPoints:{type:`clientContextParams`,name:`disableMultiregionAccessPoints`},Accelerate:{type:`clientContextParams`,name:`useAccelerateEndpoint`},DisableS3ExpressSessionAuth:{type:`clientContextParams`,name:`disableS3ExpressSessionAuth`},UseGlobalEndpoint:{type:`builtInParams`,name:`useGlobalEndpoint`},UseFIPS:{type:`builtInParams`,name:`useFipsEndpoint`},Endpoint:{type:`builtInParams`,name:`endpoint`},Region:{type:`builtInParams`,name:`region`},UseDualStack:{type:`builtInParams`,name:`useDualstackEndpoint`}},iZ=class e extends aa{constructor(t){super(t),Object.setPrototypeOf(this,e.prototype)}},aZ=class e extends iZ{name=`NoSuchUpload`;$fault=`client`;constructor(t){super({name:`NoSuchUpload`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},oZ=class e extends iZ{name=`AccessDenied`;$fault=`client`;constructor(t){super({name:`AccessDenied`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},sZ=class e extends iZ{name=`ObjectNotInActiveTierError`;$fault=`client`;constructor(t){super({name:`ObjectNotInActiveTierError`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},cZ=class e extends iZ{name=`BucketAlreadyExists`;$fault=`client`;constructor(t){super({name:`BucketAlreadyExists`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},lZ=class e extends iZ{name=`BucketAlreadyOwnedByYou`;$fault=`client`;constructor(t){super({name:`BucketAlreadyOwnedByYou`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},uZ=class e extends iZ{name=`NoSuchBucket`;$fault=`client`;constructor(t){super({name:`NoSuchBucket`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},dZ=class e extends iZ{name=`InvalidObjectState`;$fault=`client`;StorageClass;AccessTier;constructor(t){super({name:`InvalidObjectState`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype),this.StorageClass=t.StorageClass,this.AccessTier=t.AccessTier}},fZ=class e extends iZ{name=`NoSuchKey`;$fault=`client`;constructor(t){super({name:`NoSuchKey`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},pZ=class e extends iZ{name=`NotFound`;$fault=`client`;constructor(t){super({name:`NotFound`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},mZ=class e extends iZ{name=`EncryptionTypeMismatch`;$fault=`client`;constructor(t){super({name:`EncryptionTypeMismatch`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},hZ=class e extends iZ{name=`InvalidRequest`;$fault=`client`;constructor(t){super({name:`InvalidRequest`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},gZ=class e extends iZ{name=`InvalidWriteOffset`;$fault=`client`;constructor(t){super({name:`InvalidWriteOffset`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},_Z=class e extends iZ{name=`TooManyParts`;$fault=`client`;constructor(t){super({name:`TooManyParts`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},vZ=class e extends iZ{name=`IdempotencyParameterMismatch`;$fault=`client`;constructor(t){super({name:`IdempotencyParameterMismatch`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},yZ=class e extends iZ{name=`ObjectAlreadyInActiveTierError`;$fault=`client`;constructor(t){super({name:`ObjectAlreadyInActiveTierError`,$fault:`client`,...t}),Object.setPrototypeOf(this,e.prototype)}},bZ=`ACL`,xZ=`AccessDenied`,SZ=`AbortDate`,CZ=`AccessKeyId`,wZ=`AbortMultipartUpload`,TZ=`AbortMultipartUploadOutput`,EZ=`AbortMultipartUploadRequest`,DZ=`AcceptRanges`,OZ=`AbortRuleId`,kZ=`AccessTier`,AZ=`Bucket`,jZ=`BucketArn`,MZ=`BucketAlreadyExists`,NZ=`BucketAlreadyOwnedByYou`,PZ=`BypassGovernanceRetention`,FZ=`BucketInfo`,IZ=`BucketKeyEnabled`,LZ=`BucketNamespace`,RZ=`BucketRegion`,zZ=`Body`,BZ=`Buckets`,VZ=`ChecksumAlgorithm`,HZ=`CreateBucket`,UZ=`CreateBucketConfiguration`,WZ=`CreateBucketOutput`,GZ=`CreateBucketRequest`,KZ=`CacheControl`,qZ=`ChecksumCRC32`,JZ=`ChecksumCRC32C`,YZ=`ChecksumCRC64NVME`,XZ=`Cache-Control`,ZZ=`CreationDate`,QZ=`Content-Disposition`,$Z=`ContentDisposition`,eQ=`Content-Encoding`,tQ=`ContentEncoding`,nQ=`ContentLanguage`,rQ=`Content-Language`,iQ=`Content-Length`,aQ=`ContentLength`,oQ=`Content-MD5`,sQ=`ContentMD5`,cQ=`CompletedMultipartUpload`,lQ=`CompleteMultipartUploadOutput`,uQ=`CreateMultipartUploadOutput`,dQ=`CompleteMultipartUploadResult`,fQ=`CompleteMultipartUploadRequest`,pQ=`CreateMultipartUploadRequest`,mQ=`CompleteMultipartUpload`,hQ=`CreateMultipartUpload`,gQ=`ChecksumMode`,_Q=`CommonPrefix`,vQ=`CommonPrefixList`,yQ=`CompletedPartList`,bQ=`CompletedPart`,xQ=`CommonPrefixes`,SQ=`ContentRange`,CQ=`Content-Range`,wQ=`ChecksumSHA1`,TQ=`ChecksumSHA256`,EQ=`CreateSessionOutput`,DQ=`CreateSessionResult`,OQ=`CreateSessionRequest`,kQ=`CreateSession`,AQ=`ChecksumType`,jQ=`Content-Type`,MQ=`ContentType`,NQ=`ContinuationToken`,PQ=`Contents`,FQ=`Credentials`,IQ=`DeleteMarker`,LQ=`DisplayName`,RQ=`DeleteObjectOutput`,zQ=`DeleteObjectRequest`,BQ=`DeleteObject`,VQ=`DataRedundancy`,HQ=`Delimiter`,UQ=`Expiration`,WQ=`ExpectedBucketOwner`,GQ=`ExpiresString`,KQ=`EncryptionTypeMismatch`,qQ=`ETag`,JQ=`EncodingType`,YQ=`Expires`,XQ=`FetchOwner`,ZQ=`GrantFullControl`,QQ=`GetObject`,$Q=`GetObjectOutput`,e$=`GetObjectRequest`,t$=`GrantRead`,n$=`GrantReadACP`,r$=`GrantWrite`,i$=`GrantWriteACP`,a$=`ID`,o$=`IfMatch`,s$=`IfMatchInitiatedTime`,c$=`IfMatchLastModifiedTime`,l$=`IfMatchSize`,u$=`If-Modified-Since`,d$=`IfModifiedSince`,f$=`InitiateMultipartUploadResult`,p$=`If-Match`,m$=`IfNoneMatch`,h$=`If-None-Match`,g$=`InvalidObjectState`,_$=`IdempotencyParameterMismatch`,v$=`InvalidRequest`,y$=`IsRestoreInProgress`,b$=`IsTruncated`,x$=`IfUnmodifiedSince`,S$=`If-Unmodified-Since`,C$=`InvalidWriteOffset`,w$=`Key`,T$=`KeyCount`,E$=`Location`,D$=`ListAllMyBucketsResult`,O$=`ListBuckets`,k$=`ListBucketsOutput`,A$=`ListBucketsRequest`,j$=`ListBucketResult`,M$=`LocationConstraint`,N$=`LocationInfo`,P$=`LastModified`,F$=`Last-Modified`,I$=`ListObjectsV2`,L$=`ListObjectsV2Output`,R$=`ListObjectsV2Request`,z$=`Metadata`,B$=`MaxBuckets`,V$=`MFA`,H$=`MaxKeys`,U$=`MissingMeta`,W$=`MpuObjectSize`,G$=`MultipartUpload`,K$=`Name`,q$=`NextContinuationToken`,J$=`NotFound`,Y$=`NoSuchBucket`,X$=`NoSuchKey`,Z$=`NoSuchUpload`,Q$=`Owner`,$$=`ObjectAlreadyInActiveTierError`,e1=`ObjectLockEnabledForBucket`,t1=`ObjectLockLegalHoldStatus`,n1=`ObjectLockMode`,r1=`ObjectLockRetainUntilDate`,i1=`ObjectList`,a1=`ObjectNotInActiveTierError`,o1=`ObjectOwnership`,s1=`OptionalObjectAttributes`,c1=`Object`,l1=`Prefix`,u1=`PartsCount`,d1=`PartNumber`,f1=`PutObject`,p1=`PutObjectOutput`,m1=`PutObjectRequest`,h1=`PutObjectTagging`,g1=`PutObjectTaggingOutput`,_1=`PutObjectTaggingRequest`,v1=`Parts`,y1=`Part`,b1=`RequestCharged`,x1=`ResponseCacheControl`,S1=`ResponseContentDisposition`,C1=`ResponseContentEncoding`,w1=`ResponseContentLanguage`,T1=`ResponseContentType`,E1=`ResponseExpires`,D1=`RestoreExpiryDate`,O1=`RequestPayer`,k1=`ReplicationStatus`,A1=`RestoreStatus`,j1=`Range`,M1=`Restore`,N1=`StartAfter`,P1=`SecretAccessKey`,F1=`StreamingBlob`,I1=`StorageClass`,L1=`SessionCredentialValue`,R1=`SessionCredentials`,z1=`SessionMode`,B1=`ServerSideEncryption`,V1=`SSECustomerAlgorithm`,H1=`SSECustomerKey`,U1=`SSECustomerKeyMD5`,W1=`SSEKMSEncryptionContext`,G1=`SSEKMSKeyId`,K1=`SessionToken`,q1=`Size`,J1=`Tags`,Y1=`TagCount`,X1=`TooManyParts`,Z1=`TagSet`,Q1=`Tag`,$1=`Tagging`,e0=`Type`,t0=`UploadId`,n0=`UploadPart`,r0=`UploadPartOutput`,i0=`UploadPartRequest`,a0=`Value`,o0=`VersionId`,s0=`WriteOffsetBytes`,c0=`WebsiteRedirectLocation`,l0=`accept-ranges`,u0=`bucket-region`,d0=`client`,f0=`continuation-token`,p0=`delimiter`,m0=`error`,h0=`encoding-type`,g0=`fetch-owner`,_0=`http`,v0=`httpChecksum`,y0=`httpError`,Z=`httpHeader`,b0=`httpPayload`,x0=`httpPrefixHeaders`,Q=`httpQuery`,S0=`max-buckets`,C0=`max-keys`,w0=`prefix`,T0=`partNumber`,E0=`response-cache-control`,D0=`response-content-disposition`,O0=`response-content-encoding`,k0=`response-content-language`,A0=`response-content-type`,j0=`response-expires`,M0=`smithy.ts.sdk.synthetic.com.amazonaws.s3`,N0=`start-after`,P0=`streaming`,F0=`uploadId`,I0=`versionId`,L0=`xmlFlattened`,R0=`xmlName`,z0=`x-amz-acl`,B0=`x-amz-abort-date`,V0=`x-amz-abort-rule-id`,H0=`x-amz-bucket-arn`,U0=`x-amz-bypass-governance-retention`,W0=`x-amz-bucket-namespace`,G0=`x-amz-bucket-object-lock-enabled`,K0=`x-amz-checksum-algorithm`,q0=`x-amz-checksum-crc32`,J0=`x-amz-checksum-crc32c`,Y0=`x-amz-checksum-crc64nvme`,X0=`x-amz-checksum-mode`,Z0=`x-amz-checksum-sha1`,Q0=`x-amz-checksum-sha256`,$0=`x-amz-create-session-mode`,e2=`x-amz-checksum-type`,t2=`x-amz-delete-marker`,n2=`x-amz-expiration`,r2=`x-amz-expected-bucket-owner`,i2=`x-amz-grant-full-control`,a2=`x-amz-grant-read`,o2=`x-amz-grant-read-acp`,s2=`x-amz-grant-write`,c2=`x-amz-grant-write-acp`,l2=`x-amz-if-match-initiated-time`,u2=`x-amz-if-match-last-modified-time`,d2=`x-amz-if-match-size`,f2=`x-amz-meta-`,p2=`x-amz-mfa`,m2=`x-amz-missing-meta`,h2=`x-amz-mp-object-size`,g2=`x-amz-mp-parts-count`,_2=`x-amz-object-lock-legal-hold`,v2=`x-amz-object-lock-mode`,y2=`x-amz-object-lock-retain-until-date`,b2=`x-amz-object-ownership`,x2=`x-amz-optional-object-attributes`,S2=`x-amz-object-size`,C2=`x-amz-restore`,w2=`x-amz-request-charged`,T2=`x-amz-request-payer`,E2=`x-amz-replication-status`,D2=`x-amz-storage-class`,O2=`x-amz-sdk-checksum-algorithm`,k2=`x-amz-server-side-encryption`,A2=`x-amz-server-side-encryption-aws-kms-key-id`,j2=`x-amz-server-side-encryption-bucket-key-enabled`,M2=`x-amz-server-side-encryption-context`,N2=`x-amz-server-side-encryption-customer-algorithm`,P2=`x-amz-server-side-encryption-customer-key`,F2=`x-amz-server-side-encryption-customer-key-MD5`,I2=`x-amz-tagging`,L2=`x-amz-tagging-count`,R2=`x-amz-version-id`,z2=`x-amz-write-offset-bytes`,B2=`x-amz-website-redirect-location`,$=`com.amazonaws.s3`,V2=At.for(M0),H2=[-3,M0,`S3ServiceException`,0,[],[]];V2.registerError(H2,iZ);var U2=At.for($),W2=[-3,$,xZ,{[m0]:d0,[y0]:403},[],[]];U2.registerError(W2,oZ);var G2=[-3,$,MZ,{[m0]:d0,[y0]:409},[],[]];U2.registerError(G2,cZ);var K2=[-3,$,NZ,{[m0]:d0,[y0]:409},[],[]];U2.registerError(K2,lZ);var q2=[-3,$,KQ,{[m0]:d0,[y0]:400},[],[]];U2.registerError(q2,mZ);var J2=[-3,$,_$,{[m0]:d0,[y0]:400},[],[]];U2.registerError(J2,vZ);var Y2=[-3,$,g$,{[m0]:d0,[y0]:403},[I1,kZ],[0,0]];U2.registerError(Y2,dZ);var X2=[-3,$,v$,{[m0]:d0,[y0]:400},[],[]];U2.registerError(X2,hZ);var Z2=[-3,$,C$,{[m0]:d0,[y0]:400},[],[]];U2.registerError(Z2,gZ);var Q2=[-3,$,Y$,{[m0]:d0,[y0]:404},[],[]];U2.registerError(Q2,uZ);var $2=[-3,$,X$,{[m0]:d0,[y0]:404},[],[]];U2.registerError($2,fZ);var e4=[-3,$,Z$,{[m0]:d0,[y0]:404},[],[]];U2.registerError(e4,aZ);var t4=[-3,$,J$,{[m0]:d0},[],[]];U2.registerError(t4,pZ);var n4=[-3,$,$$,{[m0]:d0,[y0]:403},[],[]];U2.registerError(n4,yZ);var r4=[-3,$,a1,{[m0]:d0,[y0]:403},[],[]];U2.registerError(r4,sZ);var i4=[-3,$,X1,{[m0]:d0,[y0]:400},[],[]];U2.registerError(i4,_Z);var a4=[V2,U2],o4=[0,$,L1,8,0],s4=[0,$,H1,8,0],c4=[0,$,W1,8,0],l4=[0,$,G1,8,0],u4=[0,$,F1,{[P0]:1},42],d4=[3,$,TZ,0,[b1],[[0,{[Z]:w2}]]],f4=[3,$,EZ,0,[AZ,w$,t0,O1,WQ,s$],[[0,1],[0,1],[0,{[Q]:F0}],[0,{[Z]:T2}],[0,{[Z]:r2}],[6,{[Z]:l2}]],3],p4=[3,$,AZ,0,[K$,ZZ,RZ,jZ],[0,4,0,0]],m4=[3,$,FZ,0,[VQ,e0],[0,0]],h4=[3,$,_Q,0,[l1],[0]],g4=[3,$,cQ,0,[v1],[[()=>X4,{[L0]:1,[R0]:y1}]]],_4=[3,$,bQ,0,[qQ,qZ,JZ,YZ,wQ,TQ,d1],[0,0,0,0,0,0,1]],v4=[3,$,lQ,{[R0]:dQ},[E$,AZ,w$,UQ,qQ,qZ,JZ,YZ,wQ,TQ,AQ,B1,o0,G1,IZ,b1],[0,0,0,[0,{[Z]:n2}],0,0,0,0,0,0,0,[0,{[Z]:k2}],[0,{[Z]:R2}],[()=>l4,{[Z]:A2}],[2,{[Z]:j2}],[0,{[Z]:w2}]]],y4=[3,$,fQ,0,[AZ,w$,t0,G$,qZ,JZ,YZ,wQ,TQ,AQ,W$,O1,WQ,o$,m$,V1,H1,U1],[[0,1],[0,1],[0,{[Q]:F0}],[()=>g4,{[b0]:1,[R0]:mQ}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:e2}],[1,{[Z]:h2}],[0,{[Z]:T2}],[0,{[Z]:r2}],[0,{[Z]:p$}],[0,{[Z]:h$}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}]],3],b4=[3,$,UZ,0,[M$,E$,AZ,J1],[0,()=>F4,()=>m4,[()=>Q4,0]]],x4=[3,$,WZ,0,[E$,jZ],[[0,{[Z]:E$}],[0,{[Z]:H0}]]],S4=[3,$,GZ,0,[AZ,bZ,UZ,ZQ,t$,n$,r$,i$,e1,o1,LZ],[[0,1],[0,{[Z]:z0}],[()=>b4,{[b0]:1,[R0]:UZ}],[0,{[Z]:i2}],[0,{[Z]:a2}],[0,{[Z]:o2}],[0,{[Z]:s2}],[0,{[Z]:c2}],[2,{[Z]:G0}],[0,{[Z]:b2}],[0,{[Z]:W0}]],1],C4=[3,$,uQ,{[R0]:f$},[SZ,OZ,AZ,w$,t0,B1,V1,U1,G1,W1,IZ,b1,VZ,AQ],[[4,{[Z]:B0}],[0,{[Z]:V0}],[0,{[R0]:AZ}],0,0,[0,{[Z]:k2}],[0,{[Z]:N2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}],[0,{[Z]:w2}],[0,{[Z]:K0}],[0,{[Z]:e2}]]],w4=[3,$,pQ,0,[AZ,w$,bZ,KZ,$Z,tQ,nQ,MQ,YQ,ZQ,t$,n$,i$,z$,B1,I1,c0,V1,H1,U1,G1,W1,IZ,O1,$1,n1,r1,t1,WQ,VZ,AQ],[[0,1],[0,1],[0,{[Z]:z0}],[0,{[Z]:XZ}],[0,{[Z]:QZ}],[0,{[Z]:eQ}],[0,{[Z]:rQ}],[0,{[Z]:jQ}],[4,{[Z]:YQ}],[0,{[Z]:i2}],[0,{[Z]:a2}],[0,{[Z]:o2}],[0,{[Z]:c2}],[128,{[x0]:f2}],[0,{[Z]:k2}],[0,{[Z]:D2}],[0,{[Z]:B2}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}],[0,{[Z]:T2}],[0,{[Z]:I2}],[0,{[Z]:v2}],[5,{[Z]:y2}],[0,{[Z]:_2}],[0,{[Z]:r2}],[0,{[Z]:K0}],[0,{[Z]:e2}]],2],T4=[3,$,EQ,{[R0]:DQ},[FQ,B1,G1,W1,IZ],[[()=>U4,{[R0]:FQ}],[0,{[Z]:k2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}]],1],E4=[3,$,OQ,0,[AZ,z1,B1,G1,W1,IZ],[[0,1],[0,{[Z]:$0}],[0,{[Z]:k2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}]],1],D4=[3,$,RQ,0,[IQ,o0,b1],[[2,{[Z]:t2}],[0,{[Z]:R2}],[0,{[Z]:w2}]]],O4=[3,$,zQ,0,[AZ,w$,V$,o0,O1,PZ,WQ,o$,c$,l$],[[0,1],[0,1],[0,{[Z]:p2}],[0,{[Q]:I0}],[0,{[Z]:T2}],[2,{[Z]:U0}],[0,{[Z]:r2}],[0,{[Z]:p$}],[6,{[Z]:u2}],[1,{[Z]:d2}]],2],k4=[3,$,$Q,0,[zZ,IQ,DZ,UQ,M1,P$,aQ,qQ,qZ,JZ,YZ,wQ,TQ,AQ,U$,o0,KZ,$Z,tQ,nQ,SQ,MQ,YQ,GQ,c0,B1,z$,V1,U1,G1,IZ,I1,b1,k1,u1,Y1,n1,r1,t1],[[()=>u4,16],[2,{[Z]:t2}],[0,{[Z]:l0}],[0,{[Z]:n2}],[0,{[Z]:C2}],[4,{[Z]:F$}],[1,{[Z]:iQ}],[0,{[Z]:qQ}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:e2}],[1,{[Z]:m2}],[0,{[Z]:R2}],[0,{[Z]:XZ}],[0,{[Z]:QZ}],[0,{[Z]:eQ}],[0,{[Z]:rQ}],[0,{[Z]:CQ}],[0,{[Z]:jQ}],[4,{[Z]:YQ}],[0,{[Z]:GQ}],[0,{[Z]:B2}],[0,{[Z]:k2}],[128,{[x0]:f2}],[0,{[Z]:N2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[2,{[Z]:j2}],[0,{[Z]:D2}],[0,{[Z]:w2}],[0,{[Z]:E2}],[1,{[Z]:g2}],[1,{[Z]:L2}],[0,{[Z]:v2}],[5,{[Z]:y2}],[0,{[Z]:_2}]]],A4=[3,$,e$,0,[AZ,w$,o$,d$,m$,x$,j1,x1,S1,C1,w1,T1,E1,o0,V1,H1,U1,O1,d1,WQ,gQ],[[0,1],[0,1],[0,{[Z]:p$}],[4,{[Z]:u$}],[0,{[Z]:h$}],[4,{[Z]:S$}],[0,{[Z]:j1}],[0,{[Q]:E0}],[0,{[Q]:D0}],[0,{[Q]:O0}],[0,{[Q]:k0}],[0,{[Q]:A0}],[6,{[Q]:j0}],[0,{[Q]:I0}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}],[0,{[Z]:T2}],[1,{[Q]:T0}],[0,{[Z]:r2}],[0,{[Z]:X0}]],2],j4=[3,$,k$,{[R0]:D$},[BZ,Q$,NQ,l1],[[()=>J4,0],()=>L4,0,0]],M4=[3,$,A$,0,[B$,NQ,l1,RZ],[[1,{[Q]:S0}],[0,{[Q]:f0}],[0,{[Q]:w0}],[0,{[Q]:u0}]]],N4=[3,$,L$,{[R0]:j$},[b$,PQ,K$,l1,HQ,H$,xQ,JQ,T$,NQ,q$,N1,b1],[2,[()=>Z4,{[L0]:1}],0,0,0,1,[()=>Y4,{[L0]:1}],0,1,0,0,0,[0,{[Z]:w2}]]],P4=[3,$,R$,0,[AZ,HQ,JQ,H$,l1,NQ,XQ,N1,O1,WQ,s1],[[0,1],[0,{[Q]:p0}],[0,{[Q]:h0}],[1,{[Q]:C0}],[0,{[Q]:w0}],[0,{[Q]:f0}],[2,{[Q]:g0}],[0,{[Q]:N0}],[0,{[Z]:T2}],[0,{[Z]:r2}],[64,{[Z]:x2}]],1],F4=[3,$,N$,0,[e0,K$],[0,0]],I4=[3,$,c1,0,[w$,P$,qQ,VZ,AQ,q1,I1,Q$,A1],[0,4,0,[64,{[L0]:1}],0,1,0,()=>L4,()=>H4]],L4=[3,$,Q$,0,[LQ,a$],[0,0]],R4=[3,$,p1,0,[UQ,qQ,qZ,JZ,YZ,wQ,TQ,AQ,B1,o0,V1,U1,G1,W1,IZ,q1,b1],[[0,{[Z]:n2}],[0,{[Z]:qQ}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:e2}],[0,{[Z]:k2}],[0,{[Z]:R2}],[0,{[Z]:N2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}],[1,{[Z]:S2}],[0,{[Z]:w2}]]],z4=[3,$,m1,0,[AZ,w$,bZ,zZ,KZ,$Z,tQ,nQ,aQ,sQ,MQ,VZ,qZ,JZ,YZ,wQ,TQ,YQ,o$,m$,ZQ,t$,n$,i$,s0,z$,B1,I1,c0,V1,H1,U1,G1,W1,IZ,O1,$1,n1,r1,t1,WQ],[[0,1],[0,1],[0,{[Z]:z0}],[()=>u4,16],[0,{[Z]:XZ}],[0,{[Z]:QZ}],[0,{[Z]:eQ}],[0,{[Z]:rQ}],[1,{[Z]:iQ}],[0,{[Z]:oQ}],[0,{[Z]:jQ}],[0,{[Z]:O2}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[4,{[Z]:YQ}],[0,{[Z]:p$}],[0,{[Z]:h$}],[0,{[Z]:i2}],[0,{[Z]:a2}],[0,{[Z]:o2}],[0,{[Z]:c2}],[1,{[Z]:z2}],[128,{[x0]:f2}],[0,{[Z]:k2}],[0,{[Z]:D2}],[0,{[Z]:B2}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[()=>c4,{[Z]:M2}],[2,{[Z]:j2}],[0,{[Z]:T2}],[0,{[Z]:I2}],[0,{[Z]:v2}],[5,{[Z]:y2}],[0,{[Z]:_2}],[0,{[Z]:r2}]],2],B4=[3,$,g1,0,[o0],[[0,{[Z]:R2}]]],V4=[3,$,_1,0,[AZ,w$,$1,o0,sQ,VZ,WQ,O1],[[0,1],[0,1],[()=>G4,{[b0]:1,[R0]:$1}],[0,{[Q]:I0}],[0,{[Z]:oQ}],[0,{[Z]:O2}],[0,{[Z]:r2}],[0,{[Z]:T2}]],3],H4=[3,$,A1,0,[y$,D1],[2,4]],U4=[3,$,R1,0,[CZ,P1,K1,UQ],[[0,{[R0]:CZ}],[()=>o4,{[R0]:P1}],[()=>o4,{[R0]:K1}],[4,{[R0]:UQ}]],4],W4=[3,$,Q1,0,[w$,a0],[0,0],2],G4=[3,$,$1,0,[Z1],[[()=>Q4,0]],1],K4=[3,$,r0,0,[B1,qQ,qZ,JZ,YZ,wQ,TQ,V1,U1,G1,IZ,b1],[[0,{[Z]:k2}],[0,{[Z]:qQ}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:N2}],[0,{[Z]:F2}],[()=>l4,{[Z]:A2}],[2,{[Z]:j2}],[0,{[Z]:w2}]]],q4=[3,$,i0,0,[AZ,w$,d1,t0,zZ,aQ,sQ,VZ,qZ,JZ,YZ,wQ,TQ,V1,H1,U1,O1,WQ],[[0,1],[0,1],[1,{[Q]:T0}],[0,{[Q]:F0}],[()=>u4,16],[1,{[Z]:iQ}],[0,{[Z]:oQ}],[0,{[Z]:O2}],[0,{[Z]:q0}],[0,{[Z]:J0}],[0,{[Z]:Y0}],[0,{[Z]:Z0}],[0,{[Z]:Q0}],[0,{[Z]:N2}],[()=>s4,{[Z]:P2}],[0,{[Z]:F2}],[0,{[Z]:T2}],[0,{[Z]:r2}]],4],J4=[1,$,BZ,0,[()=>p4,{[R0]:AZ}]],Y4=[1,$,vQ,0,()=>h4],X4=[1,$,yQ,0,()=>_4],Z4=[1,$,i1,0,[()=>I4,0]],Q4=[1,$,Z1,0,[()=>W4,{[R0]:Q1}]],$4=[9,$,wZ,{[_0]:[`DELETE`,`/{Key+}?x-id=AbortMultipartUpload`,204]},()=>f4,()=>d4],e3=[9,$,mQ,{[_0]:[`POST`,`/{Key+}`,200]},()=>y4,()=>v4],t3=[9,$,HZ,{[_0]:[`PUT`,`/`,200]},()=>S4,()=>x4],n3=[9,$,hQ,{[_0]:[`POST`,`/{Key+}?uploads`,200]},()=>w4,()=>C4],r3=[9,$,kQ,{[_0]:[`GET`,`/?session`,200]},()=>E4,()=>T4],i3=[9,$,BQ,{[_0]:[`DELETE`,`/{Key+}?x-id=DeleteObject`,204]},()=>O4,()=>D4],a3=[9,$,QQ,{[v0]:`-`,[_0]:[`GET`,`/{Key+}?x-id=GetObject`,200]},()=>A4,()=>k4],o3=[9,$,O$,{[_0]:[`GET`,`/?x-id=ListBuckets`,200]},()=>M4,()=>j4],s3=[9,$,I$,{[_0]:[`GET`,`/?list-type=2`,200]},()=>P4,()=>N4],c3=[9,$,f1,{[v0]:`-`,[_0]:[`PUT`,`/{Key+}?x-id=PutObject`,200]},()=>z4,()=>R4],l3=[9,$,h1,{[v0]:`-`,[_0]:[`PUT`,`/{Key+}?tagging`,200]},()=>V4,()=>B4],u3=[9,$,n0,{[v0]:`-`,[_0]:[`PUT`,`/{Key+}?x-id=UploadPart`,200]},()=>q4,()=>K4],d3=class extends ra.classBuilder().ep({...rZ,DisableS3ExpressSessionAuth:{type:`staticContextParams`,value:!0},Bucket:{type:`contextParams`,name:`Bucket`}}).m(function(e,t,n,r){return[Gi(n,e.getEndpointParameterInstructions()),jq(n)]}).s(`AmazonS3`,`CreateSession`,{}).n(`S3Client`,`CreateSessionCommand`).sc(r3).build(){},f3=`@aws-sdk/client-s3`,p3=`AWS SDK for JavaScript S3 Client for Node.js, Browser and React Native`,m3=`3.1024.0`,h3={build:`concurrently 'yarn:build:types' 'yarn:build:es' && yarn build:cjs`,"build:cjs":`node ../../scripts/compilation/inline client-s3`,"build:es":`tsc -p tsconfig.es.json`,"build:include:deps":`yarn g:turbo run build -F="$npm_package_name"`,"build:types":`tsc -p tsconfig.types.json`,"build:types:downlevel":`downlevel-dts dist-types dist-types/ts3.4`,clean:`premove dist-cjs dist-es dist-types tsconfig.cjs.tsbuildinfo tsconfig.es.tsbuildinfo tsconfig.types.tsbuildinfo`,"extract:docs":`api-extractor run --local`,"generate:client":`node ../../scripts/generate-clients/single-service --solo s3`,test:`yarn g:vitest run`,"test:browser":`node ./test/browser-build/esbuild && yarn g:vitest run -c vitest.config.browser.mts`,"test:browser:watch":`node ./test/browser-build/esbuild && yarn g:vitest watch -c vitest.config.browser.mts`,"test:e2e":`yarn g:vitest run -c vitest.config.e2e.mts && yarn test:browser`,"test:e2e:watch":`yarn g:vitest watch -c vitest.config.e2e.mts`,"test:index":`tsc --noEmit ./test/index-types.ts && node ./test/index-objects.spec.mjs`,"test:integration":`yarn g:vitest run -c vitest.config.integ.mts`,"test:integration:watch":`yarn g:vitest watch -c vitest.config.integ.mts`,"test:watch":`yarn g:vitest watch`},g3=`./dist-cjs/index.js`,_3=`./dist-types/index.d.ts`,v3=`./dist-es/index.js`,y3={"@aws-crypto/sha1-browser":`5.2.0`,"@aws-crypto/sha256-browser":`5.2.0`,"@aws-crypto/sha256-js":`5.2.0`,"@aws-sdk/core":`^3.973.26`,"@aws-sdk/credential-provider-node":`^3.972.29`,"@aws-sdk/middleware-bucket-endpoint":`^3.972.8`,"@aws-sdk/middleware-expect-continue":`^3.972.8`,"@aws-sdk/middleware-flexible-checksums":`^3.974.6`,"@aws-sdk/middleware-host-header":`^3.972.8`,"@aws-sdk/middleware-location-constraint":`^3.972.8`,"@aws-sdk/middleware-logger":`^3.972.8`,"@aws-sdk/middleware-recursion-detection":`^3.972.9`,"@aws-sdk/middleware-sdk-s3":`^3.972.27`,"@aws-sdk/middleware-ssec":`^3.972.8`,"@aws-sdk/middleware-user-agent":`^3.972.28`,"@aws-sdk/region-config-resolver":`^3.972.10`,"@aws-sdk/signature-v4-multi-region":`^3.996.15`,"@aws-sdk/types":`^3.973.6`,"@aws-sdk/util-endpoints":`^3.996.5`,"@aws-sdk/util-user-agent-browser":`^3.972.8`,"@aws-sdk/util-user-agent-node":`^3.973.14`,"@smithy/config-resolver":`^4.4.13`,"@smithy/core":`^3.23.13`,"@smithy/eventstream-serde-browser":`^4.2.12`,"@smithy/eventstream-serde-config-resolver":`^4.3.12`,"@smithy/eventstream-serde-node":`^4.2.12`,"@smithy/fetch-http-handler":`^5.3.15`,"@smithy/hash-blob-browser":`^4.2.13`,"@smithy/hash-node":`^4.2.12`,"@smithy/hash-stream-node":`^4.2.12`,"@smithy/invalid-dependency":`^4.2.12`,"@smithy/md5-js":`^4.2.12`,"@smithy/middleware-content-length":`^4.2.12`,"@smithy/middleware-endpoint":`^4.4.28`,"@smithy/middleware-retry":`^4.4.46`,"@smithy/middleware-serde":`^4.2.16`,"@smithy/middleware-stack":`^4.2.12`,"@smithy/node-config-provider":`^4.3.12`,"@smithy/node-http-handler":`^4.5.1`,"@smithy/protocol-http":`^5.3.12`,"@smithy/smithy-client":`^4.12.8`,"@smithy/types":`^4.13.1`,"@smithy/url-parser":`^4.2.12`,"@smithy/util-base64":`^4.3.2`,"@smithy/util-body-length-browser":`^4.2.2`,"@smithy/util-body-length-node":`^4.2.3`,"@smithy/util-defaults-mode-browser":`^4.3.44`,"@smithy/util-defaults-mode-node":`^4.2.48`,"@smithy/util-endpoints":`^3.3.3`,"@smithy/util-middleware":`^4.2.12`,"@smithy/util-retry":`^4.2.13`,"@smithy/util-stream":`^4.5.21`,"@smithy/util-utf8":`^4.2.2`,"@smithy/util-waiter":`^4.2.14`,tslib:`^2.6.2`},b3={"@aws-sdk/signature-v4-crt":`3.1024.0`,"@smithy/snapshot-testing":`^2.0.4`,"@tsconfig/node20":`20.1.8`,"@types/node":`^20.14.8`,concurrently:`7.0.0`,"downlevel-dts":`0.10.1`,premove:`4.0.0`,typescript:`~5.8.3`,vitest:`^4.0.17`},x3={node:`>=20.0.0`},S3={"<4.5":{"dist-types/*":[`dist-types/ts3.4/*`]}},C3=[`dist-*/**`],w3={name:`AWS SDK for JavaScript Team`,url:`https://aws.amazon.com/javascript/`},T3=`Apache-2.0`,E3={"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.browser`},D3=`https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-s3`,O3={type:`git`,url:`https://github.com/aws/aws-sdk-js-v3.git`,directory:`clients/client-s3`},k3={name:f3,description:p3,version:m3,scripts:h3,main:g3,types:_3,module:v3,sideEffects:!1,dependencies:y3,devDependencies:b3,engines:x3,typesVersions:S3,files:C3,author:w3,license:T3,browser:E3,"react-native":{"./dist-es/runtimeConfig":`./dist-es/runtimeConfig.native`},homepage:D3,repository:O3};function A3(e){return typeof e==`string`?e.length===0:e.byteLength===0}var j3={name:`SHA-1`},M3={name:`HMAC`,hash:j3},N3=new Uint8Array([218,57,163,238,94,107,75,13,50,85,191,239,149,96,24,144,175,216,7,9]),P3=function(){function e(e){this.toHash=new Uint8Array,e!==void 0&&(this.key=new Promise(function(t,n){u().crypto.subtle.importKey(`raw`,F3(e),M3,!1,[`sign`]).then(t,n)}),this.key.catch(function(){}))}return e.prototype.update=function(e){if(!A3(e)){var t=F3(e),n=new Uint8Array(this.toHash.byteLength+t.byteLength);n.set(this.toHash,0),n.set(t,this.toHash.byteLength),this.toHash=n}},e.prototype.digest=function(){var e=this;return this.key?this.key.then(function(t){return u().crypto.subtle.sign(M3,t,e.toHash).then(function(e){return new Uint8Array(e)})}):A3(this.toHash)?Promise.resolve(N3):Promise.resolve().then(function(){return u().crypto.subtle.digest(j3,e.toHash)}).then(function(e){return Promise.resolve(new Uint8Array(e))})},e.prototype.reset=function(){this.toHash=new Uint8Array},e}();function F3(e){return typeof e==`string`?oe(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}var I3=function(){function e(e){if(ie(u()))this.hash=new P3(e);else throw Error(`SHA1 not supported`)}return e.prototype.update=function(e,t){this.hash.update(ae(e))},e.prototype.digest=function(){return this.hash.digest()},e.prototype.reset=function(){this.hash.reset()},e}(),L3=class e{bytes;constructor(e){if(this.bytes=e,e.byteLength!==8)throw Error(`Int64 buffers must be exactly 8 bytes`)}static fromNumber(t){if(t>0x8000000000000000||t<-0x8000000000000000)throw Error(`${t} is too large (or, if negative, too small) to represent as an Int64`);let n=new Uint8Array(8);for(let e=7,r=Math.abs(Math.round(t));e>-1&&r>0;e--,r/=256)n[e]=r;return t<0&&R3(n),new e(n)}valueOf(){let e=this.bytes.slice(0),t=e[0]&128;return t&&R3(e),parseInt(ne(e),16)*(t?-1:1)}toString(){return String(this.valueOf())}};function R3(e){for(let t=0;t<8;t++)e[t]^=255;for(let t=7;t>-1&&(e[t]++,e[t]===0);t--);}var z3=class{toUtf8;fromUtf8;constructor(e,t){this.toUtf8=e,this.fromUtf8=t}format(e){let t=[];for(let n of Object.keys(e)){let r=this.fromUtf8(n);t.push(Uint8Array.from([r.byteLength]),r,this.formatHeaderValue(e[n]))}let n=new Uint8Array(t.reduce((e,t)=>e+t.byteLength,0)),r=0;for(let e of t)n.set(e,r),r+=e.byteLength;return n}formatHeaderValue(e){switch(e.type){case`boolean`:return Uint8Array.from([e.value?0:1]);case`byte`:return Uint8Array.from([2,e.value]);case`short`:let t=new DataView(new ArrayBuffer(3));return t.setUint8(0,3),t.setInt16(1,e.value,!1),new Uint8Array(t.buffer);case`integer`:let n=new DataView(new ArrayBuffer(5));return n.setUint8(0,4),n.setInt32(1,e.value,!1),new Uint8Array(n.buffer);case`long`:let r=new Uint8Array(9);return r[0]=5,r.set(e.value.bytes,1),r;case`binary`:let i=new DataView(new ArrayBuffer(3+e.value.byteLength));i.setUint8(0,6),i.setUint16(1,e.value.byteLength,!1);let a=new Uint8Array(i.buffer);return a.set(e.value,3),a;case`string`:let o=this.fromUtf8(e.value),s=new DataView(new ArrayBuffer(3+o.byteLength));s.setUint8(0,7),s.setUint16(1,o.byteLength,!1);let c=new Uint8Array(s.buffer);return c.set(o,3),c;case`timestamp`:let l=new Uint8Array(9);return l[0]=8,l.set(L3.fromNumber(e.value.valueOf()).bytes,1),l;case`uuid`:if(!X3.test(e.value))throw Error(`Invalid UUID received: ${e.value}`);let u=new Uint8Array(17);return u[0]=9,u.set(ee(e.value.replace(/\-/g,``)),1),u}}parse(e){let t={},n=0;for(;n{if(typeof e!=`number`)throw Error(`Attempted to allocate an event message where size was not a number: `+e);t=e,n=4,r=new Uint8Array(e),new DataView(r.buffer).setUint32(0,e,!1)},o=async function*(){let o=e[Symbol.asyncIterator]();for(;;){let{value:e,done:s}=await o.next();if(s){if(!t)return;if(t===n)yield r;else throw Error(`Truncated event message received.`);return}let c=e.length,l=0;for(;l({[Symbol.asyncIterator]:async function*(){let t=e.getReader();try{for(;;){let{done:e,value:n}=await t.read();if(e)return;yield n}}finally{t.releaseLock()}}}),d6=e=>{let t=e[Symbol.asyncIterator]();return new ReadableStream({async pull(e){let{done:n,value:r}=await t.next();if(n)return e.close();e.enqueue(r)}})},f6=class{universalMarshaller;constructor({utf8Encoder:e,utf8Decoder:t}){this.universalMarshaller=new l6({utf8Decoder:t,utf8Encoder:e})}deserialize(e,t){let n=p6(e)?u6(e):e;return this.universalMarshaller.deserialize(n,t)}serialize(e,t){let n=this.universalMarshaller.serialize(e,t);return typeof ReadableStream==`function`?d6(n):n}},p6=e=>typeof ReadableStream==`function`&&e instanceof ReadableStream,m6=e=>new f6(e);async function h6(e,t,n=1024*1024){let r=e.size,i=0;for(;i{n.update(e)}),n.digest()},_6=[1732584193,4023233417,2562383102,271733878],v6=class{state;buffer;bufferLength;bytesHashed;finished;constructor(){this.reset()}update(e){if(w6(e))return;if(this.finished)throw Error(`Attempted to update an already finished hash.`);let t=T6(e),n=0,{byteLength:r}=t;for(this.bytesHashed+=r;r>0;)this.buffer.setUint8(this.bufferLength++,t[n++]),r--,this.bufferLength===64&&(this.hashBuffer(),this.bufferLength=0)}async digest(){if(!this.finished){let{buffer:e,bufferLength:t,bytesHashed:n}=this,r=n*8;if(e.setUint8(this.bufferLength++,128),t%64>=56){for(let t=this.bufferLength;t<64;t++)e.setUint8(t,0);this.hashBuffer(),this.bufferLength=0}for(let t=this.bufferLength;t<56;t++)e.setUint8(t,0);e.setUint32(56,r>>>0,!0),e.setUint32(60,Math.floor(r/4294967296),!0),this.hashBuffer(),this.finished=!0}let e=new DataView(new ArrayBuffer(16));for(let t=0;t<4;t++)e.setUint32(t*4,this.state[t],!0);return new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}hashBuffer(){let{buffer:e,state:t}=this,n=t[0],r=t[1],i=t[2],a=t[3];n=b6(n,r,i,a,e.getUint32(0,!0),7,3614090360),a=b6(a,n,r,i,e.getUint32(4,!0),12,3905402710),i=b6(i,a,n,r,e.getUint32(8,!0),17,606105819),r=b6(r,i,a,n,e.getUint32(12,!0),22,3250441966),n=b6(n,r,i,a,e.getUint32(16,!0),7,4118548399),a=b6(a,n,r,i,e.getUint32(20,!0),12,1200080426),i=b6(i,a,n,r,e.getUint32(24,!0),17,2821735955),r=b6(r,i,a,n,e.getUint32(28,!0),22,4249261313),n=b6(n,r,i,a,e.getUint32(32,!0),7,1770035416),a=b6(a,n,r,i,e.getUint32(36,!0),12,2336552879),i=b6(i,a,n,r,e.getUint32(40,!0),17,4294925233),r=b6(r,i,a,n,e.getUint32(44,!0),22,2304563134),n=b6(n,r,i,a,e.getUint32(48,!0),7,1804603682),a=b6(a,n,r,i,e.getUint32(52,!0),12,4254626195),i=b6(i,a,n,r,e.getUint32(56,!0),17,2792965006),r=b6(r,i,a,n,e.getUint32(60,!0),22,1236535329),n=x6(n,r,i,a,e.getUint32(4,!0),5,4129170786),a=x6(a,n,r,i,e.getUint32(24,!0),9,3225465664),i=x6(i,a,n,r,e.getUint32(44,!0),14,643717713),r=x6(r,i,a,n,e.getUint32(0,!0),20,3921069994),n=x6(n,r,i,a,e.getUint32(20,!0),5,3593408605),a=x6(a,n,r,i,e.getUint32(40,!0),9,38016083),i=x6(i,a,n,r,e.getUint32(60,!0),14,3634488961),r=x6(r,i,a,n,e.getUint32(16,!0),20,3889429448),n=x6(n,r,i,a,e.getUint32(36,!0),5,568446438),a=x6(a,n,r,i,e.getUint32(56,!0),9,3275163606),i=x6(i,a,n,r,e.getUint32(12,!0),14,4107603335),r=x6(r,i,a,n,e.getUint32(32,!0),20,1163531501),n=x6(n,r,i,a,e.getUint32(52,!0),5,2850285829),a=x6(a,n,r,i,e.getUint32(8,!0),9,4243563512),i=x6(i,a,n,r,e.getUint32(28,!0),14,1735328473),r=x6(r,i,a,n,e.getUint32(48,!0),20,2368359562),n=S6(n,r,i,a,e.getUint32(20,!0),4,4294588738),a=S6(a,n,r,i,e.getUint32(32,!0),11,2272392833),i=S6(i,a,n,r,e.getUint32(44,!0),16,1839030562),r=S6(r,i,a,n,e.getUint32(56,!0),23,4259657740),n=S6(n,r,i,a,e.getUint32(4,!0),4,2763975236),a=S6(a,n,r,i,e.getUint32(16,!0),11,1272893353),i=S6(i,a,n,r,e.getUint32(28,!0),16,4139469664),r=S6(r,i,a,n,e.getUint32(40,!0),23,3200236656),n=S6(n,r,i,a,e.getUint32(52,!0),4,681279174),a=S6(a,n,r,i,e.getUint32(0,!0),11,3936430074),i=S6(i,a,n,r,e.getUint32(12,!0),16,3572445317),r=S6(r,i,a,n,e.getUint32(24,!0),23,76029189),n=S6(n,r,i,a,e.getUint32(36,!0),4,3654602809),a=S6(a,n,r,i,e.getUint32(48,!0),11,3873151461),i=S6(i,a,n,r,e.getUint32(60,!0),16,530742520),r=S6(r,i,a,n,e.getUint32(8,!0),23,3299628645),n=C6(n,r,i,a,e.getUint32(0,!0),6,4096336452),a=C6(a,n,r,i,e.getUint32(28,!0),10,1126891415),i=C6(i,a,n,r,e.getUint32(56,!0),15,2878612391),r=C6(r,i,a,n,e.getUint32(20,!0),21,4237533241),n=C6(n,r,i,a,e.getUint32(48,!0),6,1700485571),a=C6(a,n,r,i,e.getUint32(12,!0),10,2399980690),i=C6(i,a,n,r,e.getUint32(40,!0),15,4293915773),r=C6(r,i,a,n,e.getUint32(4,!0),21,2240044497),n=C6(n,r,i,a,e.getUint32(32,!0),6,1873313359),a=C6(a,n,r,i,e.getUint32(60,!0),10,4264355552),i=C6(i,a,n,r,e.getUint32(24,!0),15,2734768916),r=C6(r,i,a,n,e.getUint32(52,!0),21,1309151649),n=C6(n,r,i,a,e.getUint32(16,!0),6,4149444226),a=C6(a,n,r,i,e.getUint32(44,!0),10,3174756917),i=C6(i,a,n,r,e.getUint32(8,!0),15,718787259),r=C6(r,i,a,n,e.getUint32(36,!0),21,3951481745),t[0]=n+t[0]&4294967295,t[1]=r+t[1]&4294967295,t[2]=i+t[2]&4294967295,t[3]=a+t[3]&4294967295}reset(){this.state=Uint32Array.from(_6),this.buffer=new DataView(new ArrayBuffer(64)),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}};function y6(e,t,n,r,i,a){return t=(t+e&4294967295)+(r+a&4294967295)&4294967295,(t<>>32-i)+n&4294967295}function b6(e,t,n,r,i,a,o){return y6(t&n|~t&r,e,t,i,a,o)}function x6(e,t,n,r,i,a,o){return y6(t&r|n&~r,e,t,i,a,o)}function S6(e,t,n,r,i,a,o){return y6(t^n^r,e,t,i,a,o)}function C6(e,t,n,r,i,a,o){return y6(n^(t|~r),e,t,i,a,o)}function w6(e){return typeof e==`string`?e.length===0:e.byteLength===0}function T6(e){return typeof e==`string`?se(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}var E6=e=>({apiVersion:`2006-03-01`,base64Decoder:e?.base64Decoder??Ue,base64Encoder:e?.base64Encoder??We,disableHostPrefix:e?.disableHostPrefix??!1,endpointProvider:e?.endpointProvider??XX,extensions:e?.extensions??[],getAwsChunkedEncodingStream:e?.getAwsChunkedEncodingStream??qe,httpAuthSchemeProvider:e?.httpAuthSchemeProvider??eZ,httpAuthSchemes:e?.httpAuthSchemes??[{schemeId:`aws.auth#sigv4`,identityProvider:e=>e.getIdentityProvider(`aws.auth#sigv4`),signer:new ja},{schemeId:`aws.auth#sigv4a`,identityProvider:e=>e.getIdentityProvider(`aws.auth#sigv4a`),signer:new Ma}],logger:e?.logger??new ga,protocol:e?.protocol??Rq,protocolSettings:e?.protocolSettings??{defaultNamespace:`com.amazonaws.s3`,errorTypeRegistries:a4,xmlNamespace:`http://s3.amazonaws.com/doc/2006-03-01/`,version:`2006-03-01`,serviceTarget:`AmazonS3`},sdkStreamMixin:e?.sdkStreamMixin??ot,serviceId:e?.serviceId??`S3`,signerConstructor:e?.signerConstructor??Vq,signingEscapePath:e?.signingEscapePath??!1,urlParser:e?.urlParser??gt,useArnRegion:e?.useArnRegion??void 0,utf8Decoder:e?.utf8Decoder??se,utf8Encoder:e?.utf8Encoder??ce}),D6=e=>{let t=ho(e),n=()=>t().then(sa),r=E6(e);return{...r,...e,runtime:`browser`,defaultsMode:t,bodyLengthChecker:e?.bodyLengthChecker??po,credentialDefaultProvider:e?.credentialDefaultProvider??(e=>()=>Promise.reject(Error(`Credential is missing`))),defaultUserAgentProvider:e?.defaultUserAgentProvider??co({serviceId:r.serviceId,clientVersion:k3.version}),eventStreamSerdeProvider:e?.eventStreamSerdeProvider??m6,maxAttempts:e?.maxAttempts??3,md5:e?.md5??v6,region:e?.region??uo(`Region is missing`),requestHandler:$e.create(e?.requestHandler??n),retryMode:e?.retryMode??(async()=>(await n()).retryMode||Gr),sha1:e?.sha1??I3,sha256:e?.sha256??l,streamCollector:e?.streamCollector??tt,streamHasher:e?.streamHasher??g6,useDualstackEndpoint:e?.useDualstackEndpoint??(()=>Promise.resolve(!1)),useFipsEndpoint:e?.useFipsEndpoint??(()=>Promise.resolve(!1))}},O6=e=>{let t=e.httpAuthSchemes,n=e.httpAuthSchemeProvider,r=e.credentials;return{setHttpAuthScheme(e){let n=t.findIndex(t=>t.schemeId===e.schemeId);n===-1?t.push(e):t.splice(n,1,e)},httpAuthSchemes(){return t},setHttpAuthSchemeProvider(e){n=e},httpAuthSchemeProvider(){return n},setCredentials(e){r=e},credentials(){return r}}},k6=e=>({httpAuthSchemes:e.httpAuthSchemes(),httpAuthSchemeProvider:e.httpAuthSchemeProvider(),credentials:e.credentials()}),A6=(e,t)=>{let n=Object.assign(wB(e),pa(e),de(e),O6(e));return t.forEach(e=>e.configure(n)),Object.assign(e,TB(n),ma(n),fe(n),k6(n))},j6=class extends ea{config;constructor(...[e]){let t=D6(e||{});super(t),this.initConfig=t,this.config=A6(Tq(tZ(zq(Ki(ye(Di(Ji(nq($n(nZ(t))))))))),{session:[()=>this,d3]}),e?.extensions||[]),this.middlewareStack.use(xt(this.config)),this.middlewareStack.use(Si(this.config)),this.middlewareStack.use(Ca(this.config)),this.middlewareStack.use(ji(this.config)),this.middlewareStack.use(Se(this.config)),this.middlewareStack.use(Te(this.config)),this.middlewareStack.use(Oe(this.config)),this.middlewareStack.use(Ne(this.config,{httpAuthSchemeParametersProvider:ZX,identityProviderConfigProvider:async e=>new Jn({"aws.auth#sigv4":e.credentials,"aws.auth#sigv4a":e.credentials})})),this.middlewareStack.use(Re(this.config)),this.middlewareStack.use(Lq(this.config)),this.middlewareStack.use(GK(this.config)),this.middlewareStack.use(sq(this.config)),this.middlewareStack.use(yq(this.config)),this.middlewareStack.use(wq(this.config))}destroy(){super.destroy()}},M6=`ap-southeast-2`,N6=`${window.location.protocol}//localhost:9999`,P6=`${window.location.protocol}//localhost:8443`,F6=null,I6=null,L6=null;function R6(){if(!F6){let e=n();if(!e)throw Error(`AWS credentials not configured`);F6=new kB({endpoint:N6,region:M6,credentials:{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey}}),F6.middlewareStack.add(e=>t=>(i.isInstance(t.request)&&(t.request.hostname=window.location.hostname,t.request.port=Number(window.location.port)||443,t.request.path=`/proxy/awsgw${t.request.path}`),e(t)),{step:`finalizeRequest`,name:`proxyRewrite`,override:!0})}return F6}function z6(){if(!I6){let e=n();if(!e)throw Error(`AWS credentials not configured`);I6=new HK({endpoint:N6,region:M6,credentials:{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey}}),I6.middlewareStack.add(e=>t=>(i.isInstance(t.request)&&(t.request.hostname=window.location.hostname,t.request.port=Number(window.location.port)||443,t.request.path=`/proxy/awsgw${t.request.path}`),e(t)),{step:`finalizeRequest`,name:`proxyRewrite`,override:!0})}return I6}function B6(){if(!L6){let e=n();if(!e)throw Error(`AWS credentials not configured`);L6=new j6({endpoint:P6,region:M6,credentials:{accessKeyId:e.accessKeyId,secretAccessKey:e.secretAccessKey},forcePathStyle:!0}),L6.middlewareStack.add(e=>t=>(i.isInstance(t.request)&&t.request.path.endsWith(`/`)&&t.request.path!==`/`&&(t.request.path=t.request.path.slice(0,-1)),e(t)),{step:`build`,name:`removeTrailingSlash`}),L6.middlewareStack.add(e=>t=>(i.isInstance(t.request)&&(t.request.hostname=window.location.hostname,t.request.port=Number(window.location.port)||443,t.request.path=`/proxy/s3${t.request.path}`),e(t)),{step:`finalizeRequest`,name:`proxyRewrite`,override:!0})}return L6}function V6(){F6=null,I6=null,L6=null}export{zz as $,OK as A,gB as At,Ez as B,Vi as Bt,xK as C,lB as Ct,TK as D,pB as Dt,wK as E,fB as Et,NK as F,xB as Ft,jz as G,ut as Gt,Oz as H,Ur as Ht,PK as I,Ua as It,Pz as J,We as Jt,Mz as K,Ye as Kt,FK as L,ga as Lt,AK as M,vB as Mt,jK as N,yB as Nt,EK as O,mB as Ot,MK as P,bB as Pt,Rz as Q,IK as R,ra as Rt,JK as S,cB as St,CK as T,dB as Tt,kz as U,Rn as Ut,Dz as V,Bi as Vt,Az as W,Qt as Wt,Iz as X,ue as Xt,Fz as Y,ge as Yt,Lz as Z,jq as _,rB as _t,$4 as a,Gz as at,QK as b,oB as bt,n3 as c,Jz as ct,o3 as d,Zz as dt,Bz as et,s3 as f,$z as ft,rZ as g,nB as gt,u3 as h,tB as ht,B6 as i,Wz as it,kK as j,_B as jt,DK as k,hB as kt,i3 as l,Yz as lt,l3 as m,eB as mt,R6 as n,Hz as nt,e3 as o,Kz as ot,c3 as p,Qz as pt,Nz as q,Ke as qt,z6 as r,Uz as rt,t3 as s,qz as st,V6 as t,Vz as tt,a3 as u,Xz as ut,$K as v,iB as vt,SK as w,uB as wt,KK as x,sB as xt,XK as y,aB as yt,FB as z,Gi as zt}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/create-key-pair.js b/spinifex/services/spinifexui/frontend/dist/assets/create-key-pair.js index 187b00e8c..7b84dd821 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/create-key-pair.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/create-key-pair.js @@ -1 +1 @@ -import{a as e,n as t,r as n,t as r}from"./compiler-runtime.js";import{t as i}from"./error-banner.js";import{t as a}from"./useNavigate.js";import{t as o}from"./back-link.js";import{t as s}from"./check.js";import{t as c}from"./download.js";import{t as l}from"./cli-command-panel.js";import{t as u}from"./triangle-alert.js";import{t as d}from"./button.js";import{s as f}from"./ec2.js";import{N as p}from"./index.js";import{t as m}from"./page-heading.js";import{a as h,c as g,i as _,l as v,o as y,r as b,s as x,t as S}from"./alert-dialog.js";import{i as C,n as w,t as T}from"./field.js";import{t as E}from"./textarea.js";import{r as D,t as O}from"./zod.js";import{t as k}from"./use-copy-to-clipboard.js";import{n as A}from"./ec23.js";import{t as j}from"./form-actions.js";var M=e(n()),N=r(),P=t();function F(e){let t=(0,N.c)(37),{open:n,keyName:r,keyMaterial:i}=e,o=a(),{copied:l,copy:f}=k(),p;t[0]!==i||t[1]!==r?(p=()=>{let e=new Blob([i],{type:`text/plain`}),t=URL.createObjectURL(e),n=document.createElement(`a`);n.href=t,n.download=`${r}.pem`,n.click(),URL.revokeObjectURL(t)},t[0]=i,t[1]=r,t[2]=p):p=t[2];let m=p,C;t[3]===o?C=t[4]:(C=()=>{o({to:`/ec2/describe-key-pairs`})},t[3]=o,t[4]=C);let w=C,T,D;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(T=(0,P.jsx)(g,{children:(0,P.jsx)(u,{className:`text-destructive`})}),D=(0,P.jsx)(v,{children:`Save Your Private Key`}),t[5]=T,t[6]=D):(T=t[5],D=t[6]);let O;t[7]===r?O=t[8]:(O=(0,P.jsxs)(x,{children:[T,D,(0,P.jsxs)(h,{children:[`This is your only chance to save the private key file for`,` `,(0,P.jsx)(`strong`,{children:r}),`. Please download or copy it now. You won't be able to retrieve it again.`]})]}),t[7]=r,t[8]=O);let A;t[9]===i?A=t[10]:(A=(0,P.jsx)(E,{className:`font-mono text-xs`,readOnly:!0,rows:12,value:i}),t[9]=i,t[10]=A);let j;t[11]!==f||t[12]!==i?(j=()=>f(i),t[11]=f,t[12]=i,t[13]=j):j=t[13];let M;t[14]===l?M=t[15]:(M=l?(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(s,{className:`mr-2 size-4`}),`Copied!`]}):`Copy to Clipboard`,t[14]=l,t[15]=M);let F;t[16]!==j||t[17]!==M?(F=(0,P.jsx)(d,{className:`flex-1`,onClick:j,type:`button`,variant:`outline`,children:M}),t[16]=j,t[17]=M,t[18]=F):F=t[18];let I;t[19]===Symbol.for(`react.memo_cache_sentinel`)?(I=(0,P.jsx)(c,{className:`mr-2 size-4`}),t[19]=I):I=t[19];let L;t[20]===m?L=t[21]:(L=(0,P.jsxs)(d,{className:`flex-1`,onClick:m,type:`button`,variant:`outline`,children:[I,`Download .pem File`]}),t[20]=m,t[21]=L);let R;t[22]!==L||t[23]!==F?(R=(0,P.jsxs)(`div`,{className:`flex gap-2`,children:[F,L]}),t[22]=L,t[23]=F,t[24]=R):R=t[24];let z;t[25]!==R||t[26]!==A?(z=(0,P.jsxs)(`div`,{className:`space-y-3`,children:[A,R]}),t[25]=R,t[26]=A,t[27]=z):z=t[27];let B;t[28]===w?B=t[29]:(B=(0,P.jsx)(y,{children:(0,P.jsx)(b,{onClick:w,children:`Close and Continue`})}),t[28]=w,t[29]=B);let V;t[30]!==z||t[31]!==B||t[32]!==O?(V=(0,P.jsxs)(_,{className:`max-w-2xl`,children:[O,z,B]}),t[30]=z,t[31]=B,t[32]=O,t[33]=V):V=t[33];let H;return t[34]!==n||t[35]!==V?(H=(0,P.jsx)(S,{open:n,children:V}),t[34]=n,t[35]=V,t[36]=H):H=t[36],H}function I(){let e=(0,N.c)(42),t=a(),n=f(),[r,s]=(0,M.useState)(null),c;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(c={resolver:O(A)},e[0]=c):c=e[0];let{handleSubmit:u,register:d,watch:h,formState:g}=D(c),{errors:_,isSubmitting:v}=g,y;e[1]===n?y=e[2]:(y=async e=>{let t=await n.mutateAsync(e);t.KeyMaterial&&s({keyName:e.keyName,material:t.KeyMaterial})},e[1]=n,e[2]=y);let b=y,x,S;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(x=(0,P.jsx)(o,{to:`/ec2/describe-key-pairs`,children:`Back to key pairs`}),S=(0,P.jsx)(m,{title:`Create Key Pair`}),e[3]=x,e[4]=S):(x=e[3],S=e[4]);let E;e[5]===n.error?E=e[6]:(E=n.error&&(0,P.jsx)(i,{error:n.error,msg:`Failed to create key pair`}),e[5]=n.error,e[6]=E);let k;e[7]!==u||e[8]!==b?(k=u(b),e[7]=u,e[8]=b,e[9]=k):k=e[9];let I;e[10]===Symbol.for(`react.memo_cache_sentinel`)?(I=(0,P.jsx)(C,{children:(0,P.jsx)(`label`,{htmlFor:`keyName`,children:`Key Pair Name`})}),e[10]=I):I=e[10];let R=!!_.keyName,z;e[11]===d?z=e[12]:(z=d(`keyName`),e[11]=d,e[12]=z);let B;e[13]!==R||e[14]!==z?(B=(0,P.jsx)(p,{"aria-invalid":R,id:`keyName`,placeholder:`my-key-pair…`,...z}),e[13]=R,e[14]=z,e[15]=B):B=e[15];let V;e[16]===_.keyName?V=e[17]:(V=(0,P.jsx)(w,{errors:[_.keyName]}),e[16]=_.keyName,e[17]=V);let H;e[18]!==B||e[19]!==V?(H=(0,P.jsxs)(T,{children:[I,B,V]}),e[18]=B,e[19]=V,e[20]=H):H=e[20];let U;e[21]===h?U=e[22]:(U=L(h),e[21]=h,e[22]=U);let W;e[23]===U?W=e[24]:(W=(0,P.jsx)(l,{commands:U}),e[23]=U,e[24]=W);let G;e[25]===t?G=e[26]:(G=()=>t({to:`/ec2/describe-key-pairs`}),e[25]=t,e[26]=G);let K;e[27]!==n.isPending||e[28]!==v||e[29]!==G?(K=(0,P.jsx)(j,{isPending:n.isPending,isSubmitting:v,onCancel:G,pendingLabel:`Creating…`,submitLabel:`Create Key Pair`}),e[27]=n.isPending,e[28]=v,e[29]=G,e[30]=K):K=e[30];let q;e[31]!==H||e[32]!==W||e[33]!==K||e[34]!==k?(q=(0,P.jsxs)(`form`,{className:`max-w-4xl space-y-6`,onSubmit:k,children:[H,W,K]}),e[31]=H,e[32]=W,e[33]=K,e[34]=k,e[35]=q):q=e[35];let J;e[36]===r?J=e[37]:(J=r&&(0,P.jsx)(F,{keyMaterial:r.material,keyName:r.keyName,open:!!r}),e[36]=r,e[37]=J);let Y;return e[38]!==q||e[39]!==J||e[40]!==E?(Y=(0,P.jsxs)(P.Fragment,{children:[x,S,E,q,J]}),e[38]=q,e[39]=J,e[40]=E,e[41]=Y):Y=e[41],Y}function L(e){let t=e(`keyName`);return[{label:`Create Key Pair`,parts:[{type:`bin`,value:`AWS_PROFILE=spinifex aws ec2 create-key-pair`},{type:`flag`,value:` --key-name`},{type:`value`,value:` ${(typeof t==`string`?t:``)||``}`}]}]}export{I as component}; \ No newline at end of file +import{a as e,n as t,r as n,t as r}from"./compiler-runtime.js";import{t as i}from"./error-banner.js";import{t as a}from"./useNavigate.js";import{t as o}from"./back-link.js";import{t as s}from"./check.js";import{t as c}from"./download.js";import{t as l}from"./cli-command-panel.js";import{t as u}from"./triangle-alert.js";import{t as d}from"./button.js";import{s as f}from"./ec2.js";import{N as p}from"./index.js";import{t as m}from"./page-heading.js";import{a as h,c as g,i as _,l as v,o as y,r as b,s as x,t as S}from"./alert-dialog.js";import{i as C,n as w,t as T}from"./field.js";import{r as E,t as D}from"./zod.js";import{t as O}from"./use-copy-to-clipboard.js";import{n as k}from"./ec23.js";import{t as A}from"./form-actions.js";var j=e(n()),M=r(),N=t();function P(e){let t=(0,M.c)(37),{open:n,keyName:r,keyMaterial:i}=e,o=a(),{copied:l,copy:f}=O(),p;t[0]!==i||t[1]!==r?(p=()=>{let e=new Blob([i],{type:`text/plain`}),t=URL.createObjectURL(e),n=document.createElement(`a`);n.href=t,n.download=`${r}.pem`,n.click(),URL.revokeObjectURL(t)},t[0]=i,t[1]=r,t[2]=p):p=t[2];let m=p,C;t[3]===o?C=t[4]:(C=()=>{o({to:`/ec2/describe-key-pairs`})},t[3]=o,t[4]=C);let w=C,T,E;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(T=(0,N.jsx)(g,{children:(0,N.jsx)(u,{className:`text-destructive`})}),E=(0,N.jsx)(v,{children:`Save Your Private Key`}),t[5]=T,t[6]=E):(T=t[5],E=t[6]);let D;t[7]===r?D=t[8]:(D=(0,N.jsxs)(x,{children:[T,E,(0,N.jsxs)(h,{children:[`This is your only chance to save the private key file for`,` `,(0,N.jsx)(`strong`,{children:r}),`. Please download or copy it now. You won't be able to retrieve it again.`]})]}),t[7]=r,t[8]=D);let k;t[9]===i?k=t[10]:(k=(0,N.jsx)(`textarea`,{className:`w-full resize-none overflow-y-auto rounded-md border border-input bg-input/20 px-2 py-2 font-mono text-xs`,readOnly:!0,rows:4,value:i}),t[9]=i,t[10]=k);let A;t[11]!==f||t[12]!==i?(A=()=>f(i),t[11]=f,t[12]=i,t[13]=A):A=t[13];let j;t[14]===l?j=t[15]:(j=l?(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(s,{className:`mr-2 size-4`}),`Copied!`]}):`Copy to Clipboard`,t[14]=l,t[15]=j);let P;t[16]!==A||t[17]!==j?(P=(0,N.jsx)(d,{className:`flex-1`,onClick:A,type:`button`,variant:`outline`,children:j}),t[16]=A,t[17]=j,t[18]=P):P=t[18];let F;t[19]===Symbol.for(`react.memo_cache_sentinel`)?(F=(0,N.jsx)(c,{className:`mr-2 size-4`}),t[19]=F):F=t[19];let I;t[20]===m?I=t[21]:(I=(0,N.jsxs)(d,{className:`flex-1`,onClick:m,type:`button`,variant:`outline`,children:[F,`Download .pem File`]}),t[20]=m,t[21]=I);let L;t[22]!==I||t[23]!==P?(L=(0,N.jsxs)(`div`,{className:`flex gap-2`,children:[P,I]}),t[22]=I,t[23]=P,t[24]=L):L=t[24];let R;t[25]!==L||t[26]!==k?(R=(0,N.jsxs)(`div`,{className:`space-y-3`,children:[k,L]}),t[25]=L,t[26]=k,t[27]=R):R=t[27];let z;t[28]===w?z=t[29]:(z=(0,N.jsx)(y,{children:(0,N.jsx)(b,{onClick:w,children:`Close and Continue`})}),t[28]=w,t[29]=z);let B;t[30]!==R||t[31]!==z||t[32]!==D?(B=(0,N.jsxs)(_,{className:`max-w-2xl`,children:[D,R,z]}),t[30]=R,t[31]=z,t[32]=D,t[33]=B):B=t[33];let V;return t[34]!==n||t[35]!==B?(V=(0,N.jsx)(S,{open:n,children:B}),t[34]=n,t[35]=B,t[36]=V):V=t[36],V}function F(){let e=(0,M.c)(42),t=a(),n=f(),[r,s]=(0,j.useState)(null),c;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(c={resolver:D(k)},e[0]=c):c=e[0];let{handleSubmit:u,register:d,watch:h,formState:g}=E(c),{errors:_,isSubmitting:v}=g,y;e[1]===n?y=e[2]:(y=async e=>{let t=await n.mutateAsync(e);t.KeyMaterial&&s({keyName:e.keyName,material:t.KeyMaterial})},e[1]=n,e[2]=y);let b=y,x,S;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(x=(0,N.jsx)(o,{to:`/ec2/describe-key-pairs`,children:`Back to key pairs`}),S=(0,N.jsx)(m,{title:`Create Key Pair`}),e[3]=x,e[4]=S):(x=e[3],S=e[4]);let O;e[5]===n.error?O=e[6]:(O=n.error&&(0,N.jsx)(i,{error:n.error,msg:`Failed to create key pair`}),e[5]=n.error,e[6]=O);let F;e[7]!==u||e[8]!==b?(F=u(b),e[7]=u,e[8]=b,e[9]=F):F=e[9];let L;e[10]===Symbol.for(`react.memo_cache_sentinel`)?(L=(0,N.jsx)(C,{children:(0,N.jsx)(`label`,{htmlFor:`keyName`,children:`Key Pair Name`})}),e[10]=L):L=e[10];let R=!!_.keyName,z;e[11]===d?z=e[12]:(z=d(`keyName`),e[11]=d,e[12]=z);let B;e[13]!==R||e[14]!==z?(B=(0,N.jsx)(p,{"aria-invalid":R,id:`keyName`,placeholder:`my-key-pair…`,...z}),e[13]=R,e[14]=z,e[15]=B):B=e[15];let V;e[16]===_.keyName?V=e[17]:(V=(0,N.jsx)(w,{errors:[_.keyName]}),e[16]=_.keyName,e[17]=V);let H;e[18]!==B||e[19]!==V?(H=(0,N.jsxs)(T,{children:[L,B,V]}),e[18]=B,e[19]=V,e[20]=H):H=e[20];let U;e[21]===h?U=e[22]:(U=I(h),e[21]=h,e[22]=U);let W;e[23]===U?W=e[24]:(W=(0,N.jsx)(l,{commands:U}),e[23]=U,e[24]=W);let G;e[25]===t?G=e[26]:(G=()=>t({to:`/ec2/describe-key-pairs`}),e[25]=t,e[26]=G);let K;e[27]!==n.isPending||e[28]!==v||e[29]!==G?(K=(0,N.jsx)(A,{isPending:n.isPending,isSubmitting:v,onCancel:G,pendingLabel:`Creating…`,submitLabel:`Create Key Pair`}),e[27]=n.isPending,e[28]=v,e[29]=G,e[30]=K):K=e[30];let q;e[31]!==H||e[32]!==W||e[33]!==K||e[34]!==F?(q=(0,N.jsxs)(`form`,{className:`max-w-4xl space-y-6`,onSubmit:F,children:[H,W,K]}),e[31]=H,e[32]=W,e[33]=K,e[34]=F,e[35]=q):q=e[35];let J;e[36]===r?J=e[37]:(J=r&&(0,N.jsx)(P,{keyMaterial:r.material,keyName:r.keyName,open:!!r}),e[36]=r,e[37]=J);let Y;return e[38]!==q||e[39]!==J||e[40]!==O?(Y=(0,N.jsxs)(N.Fragment,{children:[x,S,O,q,J]}),e[38]=q,e[39]=J,e[40]=O,e[41]=Y):Y=e[41],Y}function I(e){let t=e(`keyName`);return[{label:`Create Key Pair`,parts:[{type:`bin`,value:`AWS_PROFILE=spinifex aws ec2 create-key-pair`},{type:`flag`,value:` --key-name`},{type:`value`,value:` ${(typeof t==`string`?t:``)||``}`}]}]}export{F as component}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/ec2.js b/spinifex/services/spinifexui/frontend/dist/assets/ec2.js index 49d89bee0..2281867f6 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/ec2.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/ec2.js @@ -1 +1 @@ -import{t as e}from"./compiler-runtime.js";import{n as t}from"./QueryClientProvider.js";import{n}from"./error-banner.js";import{$ as r,At as i,B as a,Dt as o,Et as s,Ft as c,G as l,Gt as u,H as d,It as f,J as p,K as m,Kt as ee,Lt as h,Mt as g,Nt as _,Ot as v,Pt as te,Q as ne,Rt as re,Tt as ie,U as ae,V as oe,Vt as y,W as se,X as ce,Y as le,Z as ue,at as de,ct as b,et as x,it as S,jt as C,kt as w,lt as T,n as E,nt as D,ot as O,q as k,rt as A,st as j,tt as M,wt as N,zt as P}from"./awsClient.js";import{c as F,t as I}from"./SignatureV4.js";import{c as L}from"./ec22.js";var R=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AssociateRouteTable`,{}).n(`EC2Client`,`AssociateRouteTableCommand`).sc(a).build(){},z=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AttachInternetGateway`,{}).n(`EC2Client`,`AttachInternetGatewayCommand`).sc(oe).build(){},B=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AttachVolume`,{}).n(`EC2Client`,`AttachVolumeCommand`).sc(d).build(){},V=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AuthorizeSecurityGroupEgress`,{}).n(`EC2Client`,`AuthorizeSecurityGroupEgressCommand`).sc(ae).build(){},H=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AuthorizeSecurityGroupIngress`,{}).n(`EC2Client`,`AuthorizeSecurityGroupIngressCommand`).sc(se).build(){};function fe(e){let{port:t,query:n}=e,{protocol:r,path:i,hostname:a}=e;r&&r.slice(-1)!==`:`&&(r+=`:`),t&&(a+=`:${t}`),i&&i.charAt(0)!==`/`&&(i=`/${i}`);let o=n?ee(n):``;o&&o[0]!==`?`&&(o=`?${o}`);let s=``;(e.username!=null||e.password!=null)&&(s=`${e.username??``}:${e.password??``}@`);let c=``;return e.fragment&&(c=`#${e.fragment}`),`${r}//${s}${a}${i}${o}${c}`}var pe=`2016-11-15`;function me(e){return(t,n)=>async n=>{let{input:r}=n;if(!r.PresignedUrl){let t=await e.region(),i=await re(r,{getEndpointParameterInstructions(){return{UseFIPS:{type:`builtInParams`,name:`useFipsEndpoint`},Endpoint:{type:`builtInParams`,name:`endpoint`},Region:{type:`builtInParams`,name:`region`},UseDualStack:{type:`builtInParams`,name:`useDualstackEndpoint`}}}},{...e,region:r.SourceRegion}),a=typeof e.endpoint==`function`?await e.endpoint():P(i),o=new F({...a,protocol:`https`,headers:{host:a.hostname},query:{...Object.entries(r).reduce((e,[t,n])=>(e[t]=String(n??``),e),{}),Action:`CopySnapshot`,Version:pe,DestinationRegion:t}}),s=await new I({credentials:e.credentials,region:r.SourceRegion,service:`ec2`,sha256:e.sha256,uriEscapePath:e.signingEscapePath}).presign(o,{expiresIn:3600});if(n={...n,input:{...n.input,DestinationRegion:t,PresignedUrl:fe(s)}},F.isInstance(n.request)){let{request:e}=n;(e.body??``).includes(`DestinationRegion=`)||(e.body+=`&DestinationRegion=${t}`),(e.body??``).includes(`PresignedUrl=`)||(e.body+=`&PresignedUrl=${u(n.input.PresignedUrl)}`)}}return t(n)}}var he={step:`serialize`,tags:[`CROSS_REGION_PRESIGNED_URL`],name:`crossRegionPresignedUrlMiddleware`,override:!0,relation:`after`,toMiddleware:`endpointV2Middleware`},ge=e=>({applyToStack:t=>{t.add(me(e),he)}}),_e=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions()),ge(n)]}).s(`AmazonEC2`,`CopySnapshot`,{}).n(`EC2Client`,`CopySnapshotCommand`).sc(l).build(){},ve=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateImage`,{}).n(`EC2Client`,`CreateImageCommand`).sc(m).build(){},ye=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateInternetGateway`,{}).n(`EC2Client`,`CreateInternetGatewayCommand`).sc(k).build(){},be=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateKeyPair`,{}).n(`EC2Client`,`CreateKeyPairCommand`).sc(p).build(){},xe=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreatePlacementGroup`,{}).n(`EC2Client`,`CreatePlacementGroupCommand`).sc(le).build(){},Se=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateRoute`,{}).n(`EC2Client`,`CreateRouteCommand`).sc(ce).build(){},U=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateRouteTable`,{}).n(`EC2Client`,`CreateRouteTableCommand`).sc(ue).build(){},Ce=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateSecurityGroup`,{}).n(`EC2Client`,`CreateSecurityGroupCommand`).sc(ne).build(){},we=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateSnapshot`,{}).n(`EC2Client`,`CreateSnapshotCommand`).sc(r).build(){},W=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateSubnet`,{}).n(`EC2Client`,`CreateSubnetCommand`).sc(x).build(){},Te=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateVolume`,{}).n(`EC2Client`,`CreateVolumeCommand`).sc(M).build(){},G=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateVpc`,{}).n(`EC2Client`,`CreateVpcCommand`).sc(D).build(){},Ee=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteKeyPair`,{}).n(`EC2Client`,`DeleteKeyPairCommand`).sc(A).build(){},De=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeletePlacementGroup`,{}).n(`EC2Client`,`DeletePlacementGroupCommand`).sc(S).build(){},Oe=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteSecurityGroup`,{}).n(`EC2Client`,`DeleteSecurityGroupCommand`).sc(de).build(){},ke=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteSnapshot`,{}).n(`EC2Client`,`DeleteSnapshotCommand`).sc(O).build(){},Ae=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteSubnet`,{}).n(`EC2Client`,`DeleteSubnetCommand`).sc(j).build(){},je=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteVolume`,{}).n(`EC2Client`,`DeleteVolumeCommand`).sc(b).build(){},Me=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteVpc`,{}).n(`EC2Client`,`DeleteVpcCommand`).sc(T).build(){},Ne=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DetachVolume`,{}).n(`EC2Client`,`DetachVolumeCommand`).sc(N).build(){},Pe=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`GetConsoleOutput`,{}).n(`EC2Client`,`GetConsoleOutputCommand`).sc(ie).build(){},Fe=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`ImportKeyPair`,{}).n(`EC2Client`,`ImportKeyPairCommand`).sc(s).build(){},Ie=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`ModifyInstanceAttribute`,{}).n(`EC2Client`,`ModifyInstanceAttributeCommand`).sc(o).build(){},Le=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`ModifyVolume`,{}).n(`EC2Client`,`ModifyVolumeCommand`).sc(v).build(){},Re=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`RebootInstances`,{}).n(`EC2Client`,`RebootInstancesCommand`).sc(w).build(){},ze=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`RevokeSecurityGroupEgress`,{}).n(`EC2Client`,`RevokeSecurityGroupEgressCommand`).sc(i).build(){},Be=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`RevokeSecurityGroupIngress`,{}).n(`EC2Client`,`RevokeSecurityGroupIngressCommand`).sc(C).build(){},Ve=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`RunInstances`,{}).n(`EC2Client`,`RunInstancesCommand`).sc(g).build(){},He=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`StartInstances`,{}).n(`EC2Client`,`StartInstancesCommand`).sc(_).build(){},Ue=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`StopInstances`,{}).n(`EC2Client`,`StopInstancesCommand`).sc(te).build(){},We=class extends y.classBuilder().ep(f).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`TerminateInstances`,{}).n(`EC2Client`,`TerminateInstancesCommand`).sc(c).build(){},K={capacity_block:`capacity-block`,capacity_manager_data_export:`capacity-manager-data-export`,capacity_reservation:`capacity-reservation`,capacity_reservation_fleet:`capacity-reservation-fleet`,carrier_gateway:`carrier-gateway`,client_vpn_endpoint:`client-vpn-endpoint`,coip_pool:`coip-pool`,customer_gateway:`customer-gateway`,declarative_policies_report:`declarative-policies-report`,dedicated_host:`dedicated-host`,dhcp_options:`dhcp-options`,egress_only_internet_gateway:`egress-only-internet-gateway`,elastic_gpu:`elastic-gpu`,elastic_ip:`elastic-ip`,export_image_task:`export-image-task`,export_instance_task:`export-instance-task`,fleet:`fleet`,fpga_image:`fpga-image`,host_reservation:`host-reservation`,image:`image`,image_usage_report:`image-usage-report`,import_image_task:`import-image-task`,import_snapshot_task:`import-snapshot-task`,instance:`instance`,instance_connect_endpoint:`instance-connect-endpoint`,instance_event_window:`instance-event-window`,internet_gateway:`internet-gateway`,ipam:`ipam`,ipam_external_resource_verification_token:`ipam-external-resource-verification-token`,ipam_policy:`ipam-policy`,ipam_pool:`ipam-pool`,ipam_prefix_list_resolver:`ipam-prefix-list-resolver`,ipam_prefix_list_resolver_target:`ipam-prefix-list-resolver-target`,ipam_resource_discovery:`ipam-resource-discovery`,ipam_resource_discovery_association:`ipam-resource-discovery-association`,ipam_scope:`ipam-scope`,ipv4pool_ec2:`ipv4pool-ec2`,ipv6pool_ec2:`ipv6pool-ec2`,key_pair:`key-pair`,launch_template:`launch-template`,local_gateway:`local-gateway`,local_gateway_route_table:`local-gateway-route-table`,local_gateway_route_table_virtual_interface_group_association:`local-gateway-route-table-virtual-interface-group-association`,local_gateway_route_table_vpc_association:`local-gateway-route-table-vpc-association`,local_gateway_virtual_interface:`local-gateway-virtual-interface`,local_gateway_virtual_interface_group:`local-gateway-virtual-interface-group`,mac_modification_task:`mac-modification-task`,natgateway:`natgateway`,network_acl:`network-acl`,network_insights_access_scope:`network-insights-access-scope`,network_insights_access_scope_analysis:`network-insights-access-scope-analysis`,network_insights_analysis:`network-insights-analysis`,network_insights_path:`network-insights-path`,network_interface:`network-interface`,outpost_lag:`outpost-lag`,placement_group:`placement-group`,prefix_list:`prefix-list`,replace_root_volume_task:`replace-root-volume-task`,reserved_instances:`reserved-instances`,route_server:`route-server`,route_server_endpoint:`route-server-endpoint`,route_server_peer:`route-server-peer`,route_table:`route-table`,secondary_interface:`secondary-interface`,secondary_network:`secondary-network`,secondary_subnet:`secondary-subnet`,security_group:`security-group`,security_group_rule:`security-group-rule`,service_link_virtual_interface:`service-link-virtual-interface`,snapshot:`snapshot`,spot_fleet_request:`spot-fleet-request`,spot_instances_request:`spot-instances-request`,subnet:`subnet`,subnet_cidr_reservation:`subnet-cidr-reservation`,traffic_mirror_filter:`traffic-mirror-filter`,traffic_mirror_filter_rule:`traffic-mirror-filter-rule`,traffic_mirror_session:`traffic-mirror-session`,traffic_mirror_target:`traffic-mirror-target`,transit_gateway:`transit-gateway`,transit_gateway_attachment:`transit-gateway-attachment`,transit_gateway_connect_peer:`transit-gateway-connect-peer`,transit_gateway_metering_policy:`transit-gateway-metering-policy`,transit_gateway_multicast_domain:`transit-gateway-multicast-domain`,transit_gateway_policy_table:`transit-gateway-policy-table`,transit_gateway_route_table:`transit-gateway-route-table`,transit_gateway_route_table_announcement:`transit-gateway-route-table-announcement`,verified_access_endpoint:`verified-access-endpoint`,verified_access_endpoint_target:`verified-access-endpoint-target`,verified_access_group:`verified-access-group`,verified_access_instance:`verified-access-instance`,verified_access_policy:`verified-access-policy`,verified_access_trust_provider:`verified-access-trust-provider`,volume:`volume`,vpc:`vpc`,vpc_block_public_access_exclusion:`vpc-block-public-access-exclusion`,vpc_encryption_control:`vpc-encryption-control`,vpc_endpoint:`vpc-endpoint`,vpc_endpoint_connection:`vpc-endpoint-connection`,vpc_endpoint_connection_device_type:`vpc-endpoint-connection-device-type`,vpc_endpoint_service:`vpc-endpoint-service`,vpc_endpoint_service_permission:`vpc-endpoint-service-permission`,vpc_flow_log:`vpc-flow-log`,vpc_peering_connection:`vpc-peering-connection`,vpn_concentrator:`vpn-concentrator`,vpn_connection:`vpn-connection`,vpn_connection_device_type:`vpn-connection-device-type`,vpn_gateway:`vpn-gateway`};function q(e){let t=e.split(`/`),n=t[0]??``,r=t[1]??`0`,i=Number.parseInt(r,10),a=n.split(`.`).map(e=>Number.parseInt(e,10)),o=a[0]??0,s=a[1]??0,c=a[2]??0,l=a[3]??0;return{network:((o<<24|s<<16|c<<8|l)>>>0&(i===0?0:4294967295<<32-i>>>0))>>>0,prefix:i}}function J(e){return`${e>>>24&255}.${e>>>16&255}.${e>>>8&255}.${e&255}`}function Y(e){return 2**(32-e)}function Ge(e){let t=e+4;return Math.min(t,28)}function X(e,t,n){let{network:r,prefix:i}=q(e),a=Ge(i),o=Y(a),s=Y(i)/2,c=[];for(let e=0;e>>0;c.push({cidr:`${J(t)}/${a}`,label:`Public Subnet ${e+1}`})}let l=[];for(let e=0;e>>0;l.push({cidr:`${J(t)}/${a}`,label:`Private Subnet ${e+1}`})}return{publicSubnets:c,privateSubnets:l}}function Ke(e,t){let n=q(e),r=q(t),i=n.network+Y(n.prefix)-1>>>0,a=r.network+Y(r.prefix)-1>>>0;return n.network<=a&&r.network<=i}function qe(e,t){let n=q(e),r=q(t),i=n.network+Y(n.prefix)-1>>>0,a=r.network+Y(r.prefix)-1>>>0;return r.network>=n.network&&a<=i}function Je(e,t=16,n=28){let r=/^(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\/(\d{1,2})$/.exec(e);if(!r||[Number.parseInt(r[1]??`0`,10),Number.parseInt(r[2]??`0`,10),Number.parseInt(r[3]??`0`,10),Number.parseInt(r[4]??`0`,10)].some(e=>e>255))return!1;let i=Number.parseInt(r[5]??`0`,10);return i>=t&&i<=n}var Z=e(),Ye=/\s+/;function Xe(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Ze,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function Ze(e){let t=new He({InstanceIds:[e]});return E().send(t)}function Qe(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:$e,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function $e(e){let t=new Ue({InstanceIds:[e]});return E().send(t)}function et(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:tt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function tt(e){let t=new We({InstanceIds:[e]});return E().send(t)}function nt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:rt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function rt(e){let t=new Re({InstanceIds:[e]});return E().send(t)}function it(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:at,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function at(e){let t=new Ve({ImageId:e.imageId,InstanceType:e.instanceType,KeyName:e.keyName,MinCount:e.count,MaxCount:e.count,SubnetId:e.subnetId||void 0,Placement:e.placementGroupName?{GroupName:e.placementGroupName}:void 0});return E().send(t)}function ot(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:st,onSuccess:()=>{r.invalidateQueries(L)}},e[0]=r,e[1]=i),n(i)}function st(e){let t=new be({KeyName:e.keyName,KeyType:`rsa`});return E().send(t)}function ct(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:lt,onSuccess:()=>{r.invalidateQueries(L)}},e[0]=r,e[1]=i),n(i)}function lt(e){let t=e.publicKeyMaterial.trim().split(Ye).slice(0,2).join(` `),n=new Fe({KeyName:e.keyName,PublicKeyMaterial:new TextEncoder().encode(t)});return E().send(n)}function ut(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:dt,onSuccess:()=>{r.invalidateQueries(L)}},e[0]=r,e[1]=i),n(i)}function dt(e){let t=new Ee({KeyPairId:e});return E().send(t)}function ft(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:pt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]})}},e[0]=r,e[1]=i),n(i)}function pt(e){let t=new Te({Size:e.size,AvailabilityZone:e.availabilityZone,VolumeType:`gp3`});return E().send(t)}function mt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:ht,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]})}},e[0]=r,e[1]=i),n(i)}function ht(e){let t=new Le({VolumeId:e.volumeId,Size:e.size});return E().send(t)}function gt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:_t,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]})}},e[0]=r,e[1]=i),n(i)}function _t(e){let t=new je({VolumeId:e});return E().send(t)}function vt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:yt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`snapshots`]})}},e[0]=r,e[1]=i),n(i)}function yt(e){let t=new we({VolumeId:e.volumeId,Description:e.description||void 0});return E().send(t)}function bt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:xt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`snapshots`]})}},e[0]=r,e[1]=i),n(i)}function xt(e){let t=new ke({SnapshotId:e});return E().send(t)}function St(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Ct,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`snapshots`]})}},e[0]=r,e[1]=i),n(i)}function Ct(e){let t=new _e({SourceSnapshotId:e.sourceSnapshotId,SourceRegion:e.sourceRegion,Description:e.description||void 0});return E().send(t)}function wt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Tt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]}),r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function Tt(e){let t=new B({VolumeId:e.volumeId,InstanceId:e.instanceId,Device:e.device||void 0});return E().send(t)}function Et(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Dt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]}),r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function Dt(e){let t=new Ne({VolumeId:e.volumeId,InstanceId:e.instanceId||void 0,Force:e.force});return E().send(t)}function Ot(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:kt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function kt(e){let{instanceId:t,...n}=e,r=new Ie({InstanceId:t,InstanceType:{Value:n.instanceType}});return E().send(r)}function At(){let e=(0,Z.c)(1),t;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t={mutationFn:jt},e[0]=t):t=e[0],n(t)}function jt(e){let t=new Pe({InstanceId:e});return E().send(t)}function Mt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Nt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`images`]})}},e[0]=r,e[1]=i),n(i)}function Nt(e){let t=new ve({InstanceId:e.instanceId,Name:e.name,Description:e.description||void 0});return E().send(t)}function Pt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Ft,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`vpcs`]})}},e[0]=r,e[1]=i),n(i)}function Ft(e){let t=new G({CidrBlock:e.cidrBlock,TagSpecifications:e.name?[{ResourceType:`vpc`,Tags:[{Key:`Name`,Value:e.name}]}]:void 0});return E().send(t)}function It(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Lt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`vpcs`]})}},e[0]=r,e[1]=i),n(i)}function Lt(e){let t=new Me({VpcId:e});return E().send(t)}function Rt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:zt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`subnets`]})}},e[0]=r,e[1]=i),n(i)}function zt(e){let t=new W({VpcId:e.vpcId,CidrBlock:e.cidrBlock,AvailabilityZone:e.availabilityZone||void 0});return E().send(t)}function Bt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Vt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`subnets`]})}},e[0]=r,e[1]=i),n(i)}function Vt(e){let t=new Ae({SubnetId:e});return E().send(t)}function Q(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Ht,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`placementGroups`]})}},e[0]=r,e[1]=i),n(i)}function Ht(e){let t=new xe({GroupName:e.groupName,Strategy:e.strategy});return E().send(t)}function Ut(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Wt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`placementGroups`]})}},e[0]=r,e[1]=i),n(i)}function Wt(e){let t=new De({GroupName:e});return E().send(t)}function Gt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Kt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]})}},e[0]=r,e[1]=i),n(i)}function Kt(e){let t=new Ce({GroupName:e.groupName,Description:e.description,VpcId:e.vpcId});return E().send(t)}function qt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Jt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]})}},e[0]=r,e[1]=i),n(i)}function Jt(e){let t=new Oe({GroupId:e});return E().send(t)}function Yt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Xt,onSuccess:(e,t)=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]}),r.invalidateQueries({queryKey:[`ec2`,`securityGroups`,t.groupId]})}},e[0]=r,e[1]=i),n(i)}function Xt(e){let t=new H({GroupId:e.groupId,IpPermissions:[{IpProtocol:e.ipProtocol,FromPort:e.fromPort,ToPort:e.toPort,IpRanges:[{CidrIp:e.cidrIp}]}]});return E().send(t)}function Zt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Qt,onSuccess:(e,t)=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]}),r.invalidateQueries({queryKey:[`ec2`,`securityGroups`,t.groupId]})}},e[0]=r,e[1]=i),n(i)}function Qt(e){let t=new V({GroupId:e.groupId,IpPermissions:[{IpProtocol:e.ipProtocol,FromPort:e.fromPort,ToPort:e.toPort,IpRanges:[{CidrIp:e.cidrIp}]}]});return E().send(t)}function $t(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:en,onSuccess:(e,t)=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]}),r.invalidateQueries({queryKey:[`ec2`,`securityGroups`,t.groupId]})}},e[0]=r,e[1]=i),n(i)}function en(e){let t=new Be({GroupId:e.groupId,IpPermissions:[{IpProtocol:e.ipProtocol,FromPort:e.fromPort,ToPort:e.toPort,IpRanges:[{CidrIp:e.cidrIp}]}]});return E().send(t)}function tn(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:nn,onSuccess:(e,t)=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]}),r.invalidateQueries({queryKey:[`ec2`,`securityGroups`,t.groupId]})}},e[0]=r,e[1]=i),n(i)}function nn(e){let t=new ze({GroupId:e.groupId,IpPermissions:[{IpProtocol:e.ipProtocol,FromPort:e.fromPort,ToPort:e.toPort,IpRanges:[{CidrIp:e.cidrIp}]}]});return E().send(t)}function rn(e,t){let n=[];return e&&n.push({Key:`Name`,Value:e}),n.push(...t),n}function $(e,t,n){let r=rn(t,n);if(r.length!==0)return[{ResourceType:e,Tags:r}]}function an(){let e=t();return n({mutationFn:async e=>{let t=E(),n=[],r=e.autoGenerateNames?e.namePrefix:void 0,i=e.tags.map(e=>({Key:e.key,Value:e.value})),a=`creating VPC`;try{let o=r?`${r}-vpc`:e.namePrefix,s=e.tenancy,c=(await t.send(new G({CidrBlock:e.cidrBlock,InstanceTenancy:s,TagSpecifications:$(K.vpc,o,i)}))).Vpc?.VpcId;if(!c)throw Error(`VPC was created but no VPC ID was returned by the API`);if(n.push({type:`VPC`,id:c}),e.mode===`vpc-only`)return{vpcId:c,created:n};let l=X(e.cidrBlock,e.publicSubnetCount,e.privateSubnetCount),u=e.publicSubnetCidrs.length>0?e.publicSubnetCidrs:l.publicSubnets.map(e=>e.cidr),d=e.privateSubnetCidrs.length>0?e.privateSubnetCidrs:l.privateSubnets.map(e=>e.cidr);a=`creating public subnets`;let f=[];for(let a=0;a0){a=`creating internet gateway`;let e=r?`${r}-igw`:void 0,o=(await t.send(new ye({TagSpecifications:$(K.internet_gateway,e,i)}))).InternetGateway?.InternetGatewayId;if(!o)throw Error(`Internet gateway was created but no ID was returned`);n.push({type:`Internet Gateway`,id:o}),a=`attaching internet gateway to VPC`,await t.send(new z({InternetGatewayId:o,VpcId:c})),a=`creating public route table`;let s=r?`${r}-rtb-public`:void 0,l=(await t.send(new U({VpcId:c,TagSpecifications:$(K.route_table,s,i)}))).RouteTable?.RouteTableId;if(!l)throw Error(`Public route table was created but no ID was returned`);n.push({type:`Public Route Table`,id:l}),a=`creating default route to internet gateway`,await t.send(new Se({RouteTableId:l,DestinationCidrBlock:`0.0.0.0/0`,GatewayId:o})),a=`associating public subnets with route table`;for(let e of f)await t.send(new R({RouteTableId:l,SubnetId:e}))}if(e.privateSubnetCount>0){a=`creating private route table`;let e=r?`${r}-rtb-private`:void 0,o=(await t.send(new U({VpcId:c,TagSpecifications:$(K.route_table,e,i)}))).RouteTable?.RouteTableId;if(!o)throw Error(`Private route table was created but no ID was returned`);n.push({type:`Private Route Table`,id:o}),a=`associating private subnets with route table`;for(let e of p)await t.send(new R({RouteTableId:o,SubnetId:e}))}return{vpcId:c,created:n}}catch(e){return{vpcId:n.find(e=>e.type===`VPC`)?.id,created:n,error:e instanceof Error?e:Error(String(e)),failedStep:`Failed while ${a}`}}},onSuccess:()=>{e.invalidateQueries({queryKey:[`ec2`,`vpcs`]}),e.invalidateQueries({queryKey:[`ec2`,`subnets`]}),e.invalidateQueries({queryKey:[`ec2`,`internetGateways`]}),e.invalidateQueries({queryKey:[`ec2`,`routeTables`]})}})}export{Xe as A,At as C,nt as D,mt as E,Ke as F,Je as I,et as M,X as N,tn as O,qe as P,Et as S,Ot as T,qt as _,Mt as a,gt as b,Q as c,Rt as d,ft as f,Ut as g,ut as h,St as i,Qe as j,$t as k,Gt as l,an as m,Zt as n,it as o,Pt as p,Yt as r,ot as s,wt as t,vt as u,bt as v,ct as w,It as x,Bt as y}; \ No newline at end of file +import{t as e}from"./compiler-runtime.js";import{n as t}from"./QueryClientProvider.js";import{n}from"./error-banner.js";import{$ as r,At as i,B as a,Bt as o,Dt as s,Et as c,Ft as l,G as u,Gt as d,H as f,It as p,J as ee,K as m,Kt as h,Mt as g,Nt as _,Ot as v,Pt as te,Q as ne,Rt as y,Tt as re,U as ie,V as ae,Vt as oe,W as se,X as ce,Y as le,Z as ue,at as de,ct as b,et as x,it as S,jt as C,kt as w,lt as T,n as E,nt as D,ot as O,q as k,rt as A,st as j,tt as M,wt as N,zt as P}from"./awsClient.js";import{c as F,t as I}from"./SignatureV4.js";import{c as L}from"./ec22.js";var R=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AssociateRouteTable`,{}).n(`EC2Client`,`AssociateRouteTableCommand`).sc(a).build(){},z=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AttachInternetGateway`,{}).n(`EC2Client`,`AttachInternetGatewayCommand`).sc(ae).build(){},B=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AttachVolume`,{}).n(`EC2Client`,`AttachVolumeCommand`).sc(f).build(){},V=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AuthorizeSecurityGroupEgress`,{}).n(`EC2Client`,`AuthorizeSecurityGroupEgressCommand`).sc(ie).build(){},H=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`AuthorizeSecurityGroupIngress`,{}).n(`EC2Client`,`AuthorizeSecurityGroupIngressCommand`).sc(se).build(){};function fe(e){let{port:t,query:n}=e,{protocol:r,path:i,hostname:a}=e;r&&r.slice(-1)!==`:`&&(r+=`:`),t&&(a+=`:${t}`),i&&i.charAt(0)!==`/`&&(i=`/${i}`);let o=n?h(n):``;o&&o[0]!==`?`&&(o=`?${o}`);let s=``;(e.username!=null||e.password!=null)&&(s=`${e.username??``}:${e.password??``}@`);let c=``;return e.fragment&&(c=`#${e.fragment}`),`${r}//${s}${a}${i}${o}${c}`}var pe=`2016-11-15`;function me(e){return(t,n)=>async n=>{let{input:r}=n;if(!r.PresignedUrl){let t=await e.region(),i=await o(r,{getEndpointParameterInstructions(){return{UseFIPS:{type:`builtInParams`,name:`useFipsEndpoint`},Endpoint:{type:`builtInParams`,name:`endpoint`},Region:{type:`builtInParams`,name:`region`},UseDualStack:{type:`builtInParams`,name:`useDualstackEndpoint`}}}},{...e,region:r.SourceRegion}),a=typeof e.endpoint==`function`?await e.endpoint():oe(i),s=new F({...a,protocol:`https`,headers:{host:a.hostname},query:{...Object.entries(r).reduce((e,[t,n])=>(e[t]=String(n??``),e),{}),Action:`CopySnapshot`,Version:pe,DestinationRegion:t}}),c=await new I({credentials:e.credentials,region:r.SourceRegion,service:`ec2`,sha256:e.sha256,uriEscapePath:e.signingEscapePath}).presign(s,{expiresIn:3600});if(n={...n,input:{...n.input,DestinationRegion:t,PresignedUrl:fe(c)}},F.isInstance(n.request)){let{request:e}=n;(e.body??``).includes(`DestinationRegion=`)||(e.body+=`&DestinationRegion=${t}`),(e.body??``).includes(`PresignedUrl=`)||(e.body+=`&PresignedUrl=${d(n.input.PresignedUrl)}`)}}return t(n)}}var he={step:`serialize`,tags:[`CROSS_REGION_PRESIGNED_URL`],name:`crossRegionPresignedUrlMiddleware`,override:!0,relation:`after`,toMiddleware:`endpointV2Middleware`},ge=e=>({applyToStack:t=>{t.add(me(e),he)}}),_e=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions()),ge(n)]}).s(`AmazonEC2`,`CopySnapshot`,{}).n(`EC2Client`,`CopySnapshotCommand`).sc(u).build(){},ve=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateImage`,{}).n(`EC2Client`,`CreateImageCommand`).sc(m).build(){},ye=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateInternetGateway`,{}).n(`EC2Client`,`CreateInternetGatewayCommand`).sc(k).build(){},be=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateKeyPair`,{}).n(`EC2Client`,`CreateKeyPairCommand`).sc(ee).build(){},xe=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreatePlacementGroup`,{}).n(`EC2Client`,`CreatePlacementGroupCommand`).sc(le).build(){},Se=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateRoute`,{}).n(`EC2Client`,`CreateRouteCommand`).sc(ce).build(){},U=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateRouteTable`,{}).n(`EC2Client`,`CreateRouteTableCommand`).sc(ue).build(){},Ce=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateSecurityGroup`,{}).n(`EC2Client`,`CreateSecurityGroupCommand`).sc(ne).build(){},we=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateSnapshot`,{}).n(`EC2Client`,`CreateSnapshotCommand`).sc(r).build(){},W=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateSubnet`,{}).n(`EC2Client`,`CreateSubnetCommand`).sc(x).build(){},Te=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateVolume`,{}).n(`EC2Client`,`CreateVolumeCommand`).sc(M).build(){},G=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`CreateVpc`,{}).n(`EC2Client`,`CreateVpcCommand`).sc(D).build(){},Ee=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteKeyPair`,{}).n(`EC2Client`,`DeleteKeyPairCommand`).sc(A).build(){},De=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeletePlacementGroup`,{}).n(`EC2Client`,`DeletePlacementGroupCommand`).sc(S).build(){},Oe=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteSecurityGroup`,{}).n(`EC2Client`,`DeleteSecurityGroupCommand`).sc(de).build(){},ke=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteSnapshot`,{}).n(`EC2Client`,`DeleteSnapshotCommand`).sc(O).build(){},Ae=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteSubnet`,{}).n(`EC2Client`,`DeleteSubnetCommand`).sc(j).build(){},je=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteVolume`,{}).n(`EC2Client`,`DeleteVolumeCommand`).sc(b).build(){},Me=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DeleteVpc`,{}).n(`EC2Client`,`DeleteVpcCommand`).sc(T).build(){},Ne=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DetachVolume`,{}).n(`EC2Client`,`DetachVolumeCommand`).sc(N).build(){},Pe=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`GetConsoleOutput`,{}).n(`EC2Client`,`GetConsoleOutputCommand`).sc(re).build(){},Fe=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`ImportKeyPair`,{}).n(`EC2Client`,`ImportKeyPairCommand`).sc(c).build(){},Ie=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`ModifyInstanceAttribute`,{}).n(`EC2Client`,`ModifyInstanceAttributeCommand`).sc(s).build(){},Le=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`ModifyVolume`,{}).n(`EC2Client`,`ModifyVolumeCommand`).sc(v).build(){},Re=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`RebootInstances`,{}).n(`EC2Client`,`RebootInstancesCommand`).sc(w).build(){},ze=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`RevokeSecurityGroupEgress`,{}).n(`EC2Client`,`RevokeSecurityGroupEgressCommand`).sc(i).build(){},Be=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`RevokeSecurityGroupIngress`,{}).n(`EC2Client`,`RevokeSecurityGroupIngressCommand`).sc(C).build(){},Ve=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`RunInstances`,{}).n(`EC2Client`,`RunInstancesCommand`).sc(g).build(){},He=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`StartInstances`,{}).n(`EC2Client`,`StartInstancesCommand`).sc(_).build(){},Ue=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`StopInstances`,{}).n(`EC2Client`,`StopInstancesCommand`).sc(te).build(){},We=class extends y.classBuilder().ep(p).m(function(e,t,n,r){return[P(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`TerminateInstances`,{}).n(`EC2Client`,`TerminateInstancesCommand`).sc(l).build(){},K={capacity_block:`capacity-block`,capacity_manager_data_export:`capacity-manager-data-export`,capacity_reservation:`capacity-reservation`,capacity_reservation_fleet:`capacity-reservation-fleet`,carrier_gateway:`carrier-gateway`,client_vpn_endpoint:`client-vpn-endpoint`,coip_pool:`coip-pool`,customer_gateway:`customer-gateway`,declarative_policies_report:`declarative-policies-report`,dedicated_host:`dedicated-host`,dhcp_options:`dhcp-options`,egress_only_internet_gateway:`egress-only-internet-gateway`,elastic_gpu:`elastic-gpu`,elastic_ip:`elastic-ip`,export_image_task:`export-image-task`,export_instance_task:`export-instance-task`,fleet:`fleet`,fpga_image:`fpga-image`,host_reservation:`host-reservation`,image:`image`,image_usage_report:`image-usage-report`,import_image_task:`import-image-task`,import_snapshot_task:`import-snapshot-task`,instance:`instance`,instance_connect_endpoint:`instance-connect-endpoint`,instance_event_window:`instance-event-window`,internet_gateway:`internet-gateway`,ipam:`ipam`,ipam_external_resource_verification_token:`ipam-external-resource-verification-token`,ipam_policy:`ipam-policy`,ipam_pool:`ipam-pool`,ipam_prefix_list_resolver:`ipam-prefix-list-resolver`,ipam_prefix_list_resolver_target:`ipam-prefix-list-resolver-target`,ipam_resource_discovery:`ipam-resource-discovery`,ipam_resource_discovery_association:`ipam-resource-discovery-association`,ipam_scope:`ipam-scope`,ipv4pool_ec2:`ipv4pool-ec2`,ipv6pool_ec2:`ipv6pool-ec2`,key_pair:`key-pair`,launch_template:`launch-template`,local_gateway:`local-gateway`,local_gateway_route_table:`local-gateway-route-table`,local_gateway_route_table_virtual_interface_group_association:`local-gateway-route-table-virtual-interface-group-association`,local_gateway_route_table_vpc_association:`local-gateway-route-table-vpc-association`,local_gateway_virtual_interface:`local-gateway-virtual-interface`,local_gateway_virtual_interface_group:`local-gateway-virtual-interface-group`,mac_modification_task:`mac-modification-task`,natgateway:`natgateway`,network_acl:`network-acl`,network_insights_access_scope:`network-insights-access-scope`,network_insights_access_scope_analysis:`network-insights-access-scope-analysis`,network_insights_analysis:`network-insights-analysis`,network_insights_path:`network-insights-path`,network_interface:`network-interface`,outpost_lag:`outpost-lag`,placement_group:`placement-group`,prefix_list:`prefix-list`,replace_root_volume_task:`replace-root-volume-task`,reserved_instances:`reserved-instances`,route_server:`route-server`,route_server_endpoint:`route-server-endpoint`,route_server_peer:`route-server-peer`,route_table:`route-table`,secondary_interface:`secondary-interface`,secondary_network:`secondary-network`,secondary_subnet:`secondary-subnet`,security_group:`security-group`,security_group_rule:`security-group-rule`,service_link_virtual_interface:`service-link-virtual-interface`,snapshot:`snapshot`,spot_fleet_request:`spot-fleet-request`,spot_instances_request:`spot-instances-request`,subnet:`subnet`,subnet_cidr_reservation:`subnet-cidr-reservation`,traffic_mirror_filter:`traffic-mirror-filter`,traffic_mirror_filter_rule:`traffic-mirror-filter-rule`,traffic_mirror_session:`traffic-mirror-session`,traffic_mirror_target:`traffic-mirror-target`,transit_gateway:`transit-gateway`,transit_gateway_attachment:`transit-gateway-attachment`,transit_gateway_connect_peer:`transit-gateway-connect-peer`,transit_gateway_metering_policy:`transit-gateway-metering-policy`,transit_gateway_multicast_domain:`transit-gateway-multicast-domain`,transit_gateway_policy_table:`transit-gateway-policy-table`,transit_gateway_route_table:`transit-gateway-route-table`,transit_gateway_route_table_announcement:`transit-gateway-route-table-announcement`,verified_access_endpoint:`verified-access-endpoint`,verified_access_endpoint_target:`verified-access-endpoint-target`,verified_access_group:`verified-access-group`,verified_access_instance:`verified-access-instance`,verified_access_policy:`verified-access-policy`,verified_access_trust_provider:`verified-access-trust-provider`,volume:`volume`,vpc:`vpc`,vpc_block_public_access_exclusion:`vpc-block-public-access-exclusion`,vpc_encryption_control:`vpc-encryption-control`,vpc_endpoint:`vpc-endpoint`,vpc_endpoint_connection:`vpc-endpoint-connection`,vpc_endpoint_connection_device_type:`vpc-endpoint-connection-device-type`,vpc_endpoint_service:`vpc-endpoint-service`,vpc_endpoint_service_permission:`vpc-endpoint-service-permission`,vpc_flow_log:`vpc-flow-log`,vpc_peering_connection:`vpc-peering-connection`,vpn_concentrator:`vpn-concentrator`,vpn_connection:`vpn-connection`,vpn_connection_device_type:`vpn-connection-device-type`,vpn_gateway:`vpn-gateway`};function q(e){let t=e.split(`/`),n=t[0]??``,r=t[1]??`0`,i=Number.parseInt(r,10),a=n.split(`.`).map(e=>Number.parseInt(e,10)),o=a[0]??0,s=a[1]??0,c=a[2]??0,l=a[3]??0;return{network:((o<<24|s<<16|c<<8|l)>>>0&(i===0?0:4294967295<<32-i>>>0))>>>0,prefix:i}}function J(e){return`${e>>>24&255}.${e>>>16&255}.${e>>>8&255}.${e&255}`}function Y(e){return 2**(32-e)}function Ge(e){let t=e+4;return Math.min(t,28)}function X(e,t,n){let{network:r,prefix:i}=q(e),a=Ge(i),o=Y(a),s=Y(i)/2,c=[];for(let e=0;e>>0;c.push({cidr:`${J(t)}/${a}`,label:`Public Subnet ${e+1}`})}let l=[];for(let e=0;e>>0;l.push({cidr:`${J(t)}/${a}`,label:`Private Subnet ${e+1}`})}return{publicSubnets:c,privateSubnets:l}}function Ke(e,t){let n=q(e),r=q(t),i=n.network+Y(n.prefix)-1>>>0,a=r.network+Y(r.prefix)-1>>>0;return n.network<=a&&r.network<=i}function qe(e,t){let n=q(e),r=q(t),i=n.network+Y(n.prefix)-1>>>0,a=r.network+Y(r.prefix)-1>>>0;return r.network>=n.network&&a<=i}function Je(e,t=16,n=28){let r=/^(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\/(\d{1,2})$/.exec(e);if(!r||[Number.parseInt(r[1]??`0`,10),Number.parseInt(r[2]??`0`,10),Number.parseInt(r[3]??`0`,10),Number.parseInt(r[4]??`0`,10)].some(e=>e>255))return!1;let i=Number.parseInt(r[5]??`0`,10);return i>=t&&i<=n}var Z=e(),Ye=/\s+/;function Xe(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Ze,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function Ze(e){let t=new He({InstanceIds:[e]});return E().send(t)}function Qe(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:$e,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function $e(e){let t=new Ue({InstanceIds:[e]});return E().send(t)}function et(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:tt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function tt(e){let t=new We({InstanceIds:[e]});return E().send(t)}function nt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:rt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function rt(e){let t=new Re({InstanceIds:[e]});return E().send(t)}function it(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:at,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function at(e){let t=new Ve({ImageId:e.imageId,InstanceType:e.instanceType,KeyName:e.keyName,MinCount:e.count,MaxCount:e.count,SubnetId:e.subnetId||void 0,Placement:e.placementGroupName?{GroupName:e.placementGroupName}:void 0});return E().send(t)}function ot(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:st,onSuccess:()=>{r.invalidateQueries(L)}},e[0]=r,e[1]=i),n(i)}function st(e){let t=new be({KeyName:e.keyName,KeyType:`rsa`});return E().send(t)}function ct(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:lt,onSuccess:()=>{r.invalidateQueries(L)}},e[0]=r,e[1]=i),n(i)}function lt(e){let t=e.publicKeyMaterial.trim().split(Ye).slice(0,2).join(` `),n=new Fe({KeyName:e.keyName,PublicKeyMaterial:new TextEncoder().encode(t)});return E().send(n)}function ut(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:dt,onSuccess:()=>{r.invalidateQueries(L)}},e[0]=r,e[1]=i),n(i)}function dt(e){let t=new Ee({KeyPairId:e});return E().send(t)}function ft(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:pt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]})}},e[0]=r,e[1]=i),n(i)}function pt(e){let t=new Te({Size:e.size,AvailabilityZone:e.availabilityZone,VolumeType:`gp3`});return E().send(t)}function mt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:ht,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]})}},e[0]=r,e[1]=i),n(i)}function ht(e){let t=new Le({VolumeId:e.volumeId,Size:e.size});return E().send(t)}function gt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:_t,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]})}},e[0]=r,e[1]=i),n(i)}function _t(e){let t=new je({VolumeId:e});return E().send(t)}function vt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:yt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`snapshots`]})}},e[0]=r,e[1]=i),n(i)}function yt(e){let t=new we({VolumeId:e.volumeId,Description:e.description||void 0});return E().send(t)}function bt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:xt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`snapshots`]})}},e[0]=r,e[1]=i),n(i)}function xt(e){let t=new ke({SnapshotId:e});return E().send(t)}function St(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Ct,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`snapshots`]})}},e[0]=r,e[1]=i),n(i)}function Ct(e){let t=new _e({SourceSnapshotId:e.sourceSnapshotId,SourceRegion:e.sourceRegion,Description:e.description||void 0});return E().send(t)}function wt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Tt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]}),r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function Tt(e){let t=new B({VolumeId:e.volumeId,InstanceId:e.instanceId,Device:e.device||void 0});return E().send(t)}function Et(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Dt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`volumes`]}),r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function Dt(e){let t=new Ne({VolumeId:e.volumeId,InstanceId:e.instanceId||void 0,Force:e.force});return E().send(t)}function Ot(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:kt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`instances`]})}},e[0]=r,e[1]=i),n(i)}function kt(e){let{instanceId:t,...n}=e,r=new Ie({InstanceId:t,InstanceType:{Value:n.instanceType}});return E().send(r)}function At(){let e=(0,Z.c)(1),t;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t={mutationFn:jt},e[0]=t):t=e[0],n(t)}function jt(e){let t=new Pe({InstanceId:e});return E().send(t)}function Mt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Nt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`images`]})}},e[0]=r,e[1]=i),n(i)}function Nt(e){let t=new ve({InstanceId:e.instanceId,Name:e.name,Description:e.description||void 0});return E().send(t)}function Pt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Ft,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`vpcs`]})}},e[0]=r,e[1]=i),n(i)}function Ft(e){let t=new G({CidrBlock:e.cidrBlock,TagSpecifications:e.name?[{ResourceType:`vpc`,Tags:[{Key:`Name`,Value:e.name}]}]:void 0});return E().send(t)}function It(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Lt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`vpcs`]})}},e[0]=r,e[1]=i),n(i)}function Lt(e){let t=new Me({VpcId:e});return E().send(t)}function Rt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:zt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`subnets`]})}},e[0]=r,e[1]=i),n(i)}function zt(e){let t=new W({VpcId:e.vpcId,CidrBlock:e.cidrBlock,AvailabilityZone:e.availabilityZone||void 0});return E().send(t)}function Bt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Vt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`subnets`]})}},e[0]=r,e[1]=i),n(i)}function Vt(e){let t=new Ae({SubnetId:e});return E().send(t)}function Q(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Ht,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`placementGroups`]})}},e[0]=r,e[1]=i),n(i)}function Ht(e){let t=new xe({GroupName:e.groupName,Strategy:e.strategy});return E().send(t)}function Ut(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Wt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`placementGroups`]})}},e[0]=r,e[1]=i),n(i)}function Wt(e){let t=new De({GroupName:e});return E().send(t)}function Gt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Kt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]})}},e[0]=r,e[1]=i),n(i)}function Kt(e){let t=new Ce({GroupName:e.groupName,Description:e.description,VpcId:e.vpcId});return E().send(t)}function qt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Jt,onSuccess:()=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]})}},e[0]=r,e[1]=i),n(i)}function Jt(e){let t=new Oe({GroupId:e});return E().send(t)}function Yt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Xt,onSuccess:(e,t)=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]}),r.invalidateQueries({queryKey:[`ec2`,`securityGroups`,t.groupId]})}},e[0]=r,e[1]=i),n(i)}function Xt(e){let t=new H({GroupId:e.groupId,IpPermissions:[{IpProtocol:e.ipProtocol,FromPort:e.fromPort,ToPort:e.toPort,IpRanges:[{CidrIp:e.cidrIp}]}]});return E().send(t)}function Zt(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:Qt,onSuccess:(e,t)=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]}),r.invalidateQueries({queryKey:[`ec2`,`securityGroups`,t.groupId]})}},e[0]=r,e[1]=i),n(i)}function Qt(e){let t=new V({GroupId:e.groupId,IpPermissions:[{IpProtocol:e.ipProtocol,FromPort:e.fromPort,ToPort:e.toPort,IpRanges:[{CidrIp:e.cidrIp}]}]});return E().send(t)}function $t(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:en,onSuccess:(e,t)=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]}),r.invalidateQueries({queryKey:[`ec2`,`securityGroups`,t.groupId]})}},e[0]=r,e[1]=i),n(i)}function en(e){let t=new Be({GroupId:e.groupId,IpPermissions:[{IpProtocol:e.ipProtocol,FromPort:e.fromPort,ToPort:e.toPort,IpRanges:[{CidrIp:e.cidrIp}]}]});return E().send(t)}function tn(){let e=(0,Z.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:nn,onSuccess:(e,t)=>{r.invalidateQueries({queryKey:[`ec2`,`securityGroups`]}),r.invalidateQueries({queryKey:[`ec2`,`securityGroups`,t.groupId]})}},e[0]=r,e[1]=i),n(i)}function nn(e){let t=new ze({GroupId:e.groupId,IpPermissions:[{IpProtocol:e.ipProtocol,FromPort:e.fromPort,ToPort:e.toPort,IpRanges:[{CidrIp:e.cidrIp}]}]});return E().send(t)}function rn(e,t){let n=[];return e&&n.push({Key:`Name`,Value:e}),n.push(...t),n}function $(e,t,n){let r=rn(t,n);if(r.length!==0)return[{ResourceType:e,Tags:r}]}function an(){let e=t();return n({mutationFn:async e=>{let t=E(),n=[],r=e.autoGenerateNames?e.namePrefix:void 0,i=e.tags.map(e=>({Key:e.key,Value:e.value})),a=`creating VPC`;try{let o=r?`${r}-vpc`:e.namePrefix,s=e.tenancy,c=(await t.send(new G({CidrBlock:e.cidrBlock,InstanceTenancy:s,TagSpecifications:$(K.vpc,o,i)}))).Vpc?.VpcId;if(!c)throw Error(`VPC was created but no VPC ID was returned by the API`);if(n.push({type:`VPC`,id:c}),e.mode===`vpc-only`)return{vpcId:c,created:n};let l=X(e.cidrBlock,e.publicSubnetCount,e.privateSubnetCount),u=e.publicSubnetCidrs.length>0?e.publicSubnetCidrs:l.publicSubnets.map(e=>e.cidr),d=e.privateSubnetCidrs.length>0?e.privateSubnetCidrs:l.privateSubnets.map(e=>e.cidr);a=`creating public subnets`;let f=[];for(let a=0;a0){a=`creating internet gateway`;let e=r?`${r}-igw`:void 0,o=(await t.send(new ye({TagSpecifications:$(K.internet_gateway,e,i)}))).InternetGateway?.InternetGatewayId;if(!o)throw Error(`Internet gateway was created but no ID was returned`);n.push({type:`Internet Gateway`,id:o}),a=`attaching internet gateway to VPC`,await t.send(new z({InternetGatewayId:o,VpcId:c})),a=`creating public route table`;let s=r?`${r}-rtb-public`:void 0,l=(await t.send(new U({VpcId:c,TagSpecifications:$(K.route_table,s,i)}))).RouteTable?.RouteTableId;if(!l)throw Error(`Public route table was created but no ID was returned`);n.push({type:`Public Route Table`,id:l}),a=`creating default route to internet gateway`,await t.send(new Se({RouteTableId:l,DestinationCidrBlock:`0.0.0.0/0`,GatewayId:o})),a=`associating public subnets with route table`;for(let e of f)await t.send(new R({RouteTableId:l,SubnetId:e}))}if(e.privateSubnetCount>0){a=`creating private route table`;let e=r?`${r}-rtb-private`:void 0,o=(await t.send(new U({VpcId:c,TagSpecifications:$(K.route_table,e,i)}))).RouteTable?.RouteTableId;if(!o)throw Error(`Private route table was created but no ID was returned`);n.push({type:`Private Route Table`,id:o}),a=`associating private subnets with route table`;for(let e of p)await t.send(new R({RouteTableId:o,SubnetId:e}))}return{vpcId:c,created:n}}catch(e){return{vpcId:n.find(e=>e.type===`VPC`)?.id,created:n,error:e instanceof Error?e:Error(String(e)),failedStep:`Failed while ${a}`}}},onSuccess:()=>{e.invalidateQueries({queryKey:[`ec2`,`vpcs`]}),e.invalidateQueries({queryKey:[`ec2`,`subnets`]}),e.invalidateQueries({queryKey:[`ec2`,`internetGateways`]}),e.invalidateQueries({queryKey:[`ec2`,`routeTables`]})}})}export{Xe as A,At as C,nt as D,mt as E,Ke as F,Je as I,et as M,X as N,tn as O,qe as P,Et as S,Ot as T,qt as _,Mt as a,gt as b,Q as c,Rt as d,ft as f,Ut as g,ut as h,St as i,Qe as j,$t as k,Gt as l,an as m,Zt as n,it as o,Pt as p,Yt as r,ot as s,wt as t,vt as u,bt as v,ct as w,It as x,Bt as y}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/ec22.js b/spinifex/services/spinifexui/frontend/dist/assets/ec22.js index 3ca50c8d0..70640219d 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/ec22.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/ec22.js @@ -1 +1 @@ -import{t as e}from"./queryOptions.js";import{Ct as t,It as n,Lt as r,St as i,Vt as a,_t as o,bt as s,dt as c,ft as l,gt as u,ht as d,mt as f,n as p,ut as m,vt as h,xt as g,yt as _}from"./awsClient.js";import{t as v}from"./DescribeInstancesCommand.js";var y=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeAvailabilityZones`,{}).n(`EC2Client`,`DescribeAvailabilityZonesCommand`).sc(m).build(){},b=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeImages`,{}).n(`EC2Client`,`DescribeImagesCommand`).sc(c).build(){},x=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeInstanceTypes`,{}).n(`EC2Client`,`DescribeInstanceTypesCommand`).sc(l).build(){},S=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeInternetGateways`,{}).n(`EC2Client`,`DescribeInternetGatewaysCommand`).sc(f).build(){},C=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeKeyPairs`,{}).n(`EC2Client`,`DescribeKeyPairsCommand`).sc(d).build(){},w=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribePlacementGroups`,{}).n(`EC2Client`,`DescribePlacementGroupsCommand`).sc(u).build(){},T=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeRegions`,{}).n(`EC2Client`,`DescribeRegionsCommand`).sc(o).build(){},E=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeRouteTables`,{}).n(`EC2Client`,`DescribeRouteTablesCommand`).sc(h).build(){},D=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeSecurityGroups`,{}).n(`EC2Client`,`DescribeSecurityGroupsCommand`).sc(_).build(){},O=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeSnapshots`,{}).n(`EC2Client`,`DescribeSnapshotsCommand`).sc(s).build(){},k=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeSubnets`,{}).n(`EC2Client`,`DescribeSubnetsCommand`).sc(g).build(){},A=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeVolumes`,{}).n(`EC2Client`,`DescribeVolumesCommand`).sc(i).build(){},j=class extends a.classBuilder().ep(n).m(function(e,t,n,i){return[r(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeVpcs`,{}).n(`EC2Client`,`DescribeVpcsCommand`).sc(t).build(){},M=e({queryKey:[`ec2`,`availabilityZones`],queryFn:()=>{let e=new y({});return p().send(e)},staleTime:3e5}),N=e({queryKey:[`ec2`,`instances`],queryFn:()=>{let e=new v({});return p().send(e)},refetchInterval:5e3}),P=t=>e({queryKey:[`ec2`,`instances`,t],queryFn:()=>{let e=new v({InstanceIds:[t]});return p().send(e)},refetchInterval:5e3}),F=e({queryKey:[`ec2`,`instances`,`types`],queryFn:()=>{let e=new x({Filters:[{Name:`capacity`,Values:[`true`]}]});return p().send(e)},refetchInterval:5e3}),I=e({queryKey:[`ec2`,`images`],queryFn:()=>{let e=new b({});return p().send(e)}}),L=t=>e({queryKey:[`ec2`,`images`,t??`none`],queryFn:()=>{if(!t)return{Images:[],$metadata:{}};let e=new b({ImageIds:[t]});return p().send(e)}}),R=e({queryKey:[`ec2`,`keypairs`],queryFn:()=>{let e=new C({});return p().send(e)}}),z=t=>e({queryKey:[`ec2`,`keypairs`,t],queryFn:()=>{let e=new C({KeyPairIds:[t]});return p().send(e)}}),B=e({queryKey:[`ec2`,`regions`],queryFn:()=>{let e=new T({});return p().send(e)},staleTime:3e5}),V=e({queryKey:[`ec2`,`subnets`],queryFn:()=>{let e=new k({});return p().send(e)}}),H=t=>e({queryKey:[`ec2`,`subnets`,t],queryFn:()=>{let e=new k({SubnetIds:[t]});return p().send(e)}}),U=e({queryKey:[`ec2`,`snapshots`],queryFn:()=>{let e=new O({});return p().send(e)},refetchInterval:5e3}),W=t=>e({queryKey:[`ec2`,`snapshots`,t],queryFn:()=>{let e=new O({SnapshotIds:[t]});return p().send(e)},refetchInterval:5e3});e({queryKey:[`ec2`,`internetGateways`],queryFn:()=>{let e=new S({});return p().send(e)}}),e({queryKey:[`ec2`,`routeTables`],queryFn:()=>{let e=new E({});return p().send(e)}});var G=e({queryKey:[`ec2`,`vpcs`],queryFn:()=>{let e=new j({});return p().send(e)}}),K=t=>e({queryKey:[`ec2`,`vpcs`,t],queryFn:()=>{let e=new j({VpcIds:[t]});return p().send(e)}}),q=e({queryKey:[`ec2`,`placementGroups`],queryFn:()=>{let e=new w({});return p().send(e)}}),J=t=>e({queryKey:[`ec2`,`placementGroups`,t],queryFn:()=>{let e=new w({GroupIds:[t]});return p().send(e)}}),Y=e({queryKey:[`ec2`,`securityGroups`],queryFn:()=>{let e=new D({});return p().send(e)}}),X=t=>e({queryKey:[`ec2`,`securityGroups`,t],queryFn:()=>{let e=new D({GroupIds:[t]});return p().send(e)}}),Z=e({queryKey:[`ec2`,`volumes`],queryFn:()=>{let e=new A({});return p().send(e)},refetchInterval:5e3}),Q=t=>e({queryKey:[`ec2`,`volumes`,t],queryFn:()=>{let e=new A({VolumeIds:[t]});return p().send(e)},refetchInterval:5e3});export{V as _,F as a,K as b,R as c,B as d,X as f,H as g,U as h,P as i,J as l,W as m,L as n,N as o,Y as p,I as r,z as s,M as t,q as u,Q as v,G as x,Z as y}; \ No newline at end of file +import{t as e}from"./queryOptions.js";import{Ct as t,It as n,Rt as r,St as i,_t as a,bt as o,dt as s,ft as c,gt as l,ht as u,mt as d,n as f,ut as p,vt as m,xt as h,yt as g,zt as _}from"./awsClient.js";import{t as v}from"./DescribeInstancesCommand.js";var y=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeAvailabilityZones`,{}).n(`EC2Client`,`DescribeAvailabilityZonesCommand`).sc(p).build(){},b=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeImages`,{}).n(`EC2Client`,`DescribeImagesCommand`).sc(s).build(){},x=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeInstanceTypes`,{}).n(`EC2Client`,`DescribeInstanceTypesCommand`).sc(c).build(){},S=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeInternetGateways`,{}).n(`EC2Client`,`DescribeInternetGatewaysCommand`).sc(d).build(){},C=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeKeyPairs`,{}).n(`EC2Client`,`DescribeKeyPairsCommand`).sc(u).build(){},w=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribePlacementGroups`,{}).n(`EC2Client`,`DescribePlacementGroupsCommand`).sc(l).build(){},T=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeRegions`,{}).n(`EC2Client`,`DescribeRegionsCommand`).sc(a).build(){},E=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeRouteTables`,{}).n(`EC2Client`,`DescribeRouteTablesCommand`).sc(m).build(){},D=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeSecurityGroups`,{}).n(`EC2Client`,`DescribeSecurityGroupsCommand`).sc(g).build(){},O=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeSnapshots`,{}).n(`EC2Client`,`DescribeSnapshotsCommand`).sc(o).build(){},k=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeSubnets`,{}).n(`EC2Client`,`DescribeSubnetsCommand`).sc(h).build(){},A=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeVolumes`,{}).n(`EC2Client`,`DescribeVolumesCommand`).sc(i).build(){},j=class extends r.classBuilder().ep(n).m(function(e,t,n,r){return[_(n,e.getEndpointParameterInstructions())]}).s(`AmazonEC2`,`DescribeVpcs`,{}).n(`EC2Client`,`DescribeVpcsCommand`).sc(t).build(){},M=e({queryKey:[`ec2`,`availabilityZones`],queryFn:()=>{let e=new y({});return f().send(e)},staleTime:3e5}),N=e({queryKey:[`ec2`,`instances`],queryFn:()=>{let e=new v({});return f().send(e)},refetchInterval:5e3}),P=t=>e({queryKey:[`ec2`,`instances`,t],queryFn:()=>{let e=new v({InstanceIds:[t]});return f().send(e)},refetchInterval:5e3}),F=e({queryKey:[`ec2`,`instances`,`types`],queryFn:()=>{let e=new x({Filters:[{Name:`capacity`,Values:[`true`]}]});return f().send(e)},refetchInterval:5e3}),I=e({queryKey:[`ec2`,`images`],queryFn:()=>{let e=new b({});return f().send(e)}}),L=t=>e({queryKey:[`ec2`,`images`,t??`none`],queryFn:()=>{if(!t)return{Images:[],$metadata:{}};let e=new b({ImageIds:[t]});return f().send(e)}}),R=e({queryKey:[`ec2`,`keypairs`],queryFn:()=>{let e=new C({});return f().send(e)}}),z=t=>e({queryKey:[`ec2`,`keypairs`,t],queryFn:()=>{let e=new C({KeyPairIds:[t]});return f().send(e)}}),B=e({queryKey:[`ec2`,`regions`],queryFn:()=>{let e=new T({});return f().send(e)},staleTime:3e5}),V=e({queryKey:[`ec2`,`subnets`],queryFn:()=>{let e=new k({});return f().send(e)}}),H=t=>e({queryKey:[`ec2`,`subnets`,t],queryFn:()=>{let e=new k({SubnetIds:[t]});return f().send(e)}}),U=e({queryKey:[`ec2`,`snapshots`],queryFn:()=>{let e=new O({});return f().send(e)},refetchInterval:5e3}),W=t=>e({queryKey:[`ec2`,`snapshots`,t],queryFn:()=>{let e=new O({SnapshotIds:[t]});return f().send(e)},refetchInterval:5e3});e({queryKey:[`ec2`,`internetGateways`],queryFn:()=>{let e=new S({});return f().send(e)}}),e({queryKey:[`ec2`,`routeTables`],queryFn:()=>{let e=new E({});return f().send(e)}});var G=e({queryKey:[`ec2`,`vpcs`],queryFn:()=>{let e=new j({});return f().send(e)}}),K=t=>e({queryKey:[`ec2`,`vpcs`,t],queryFn:()=>{let e=new j({VpcIds:[t]});return f().send(e)}}),q=e({queryKey:[`ec2`,`placementGroups`],queryFn:()=>{let e=new w({});return f().send(e)}}),J=t=>e({queryKey:[`ec2`,`placementGroups`,t],queryFn:()=>{let e=new w({GroupIds:[t]});return f().send(e)}}),Y=e({queryKey:[`ec2`,`securityGroups`],queryFn:()=>{let e=new D({});return f().send(e)}}),X=t=>e({queryKey:[`ec2`,`securityGroups`,t],queryFn:()=>{let e=new D({GroupIds:[t]});return f().send(e)}}),Z=e({queryKey:[`ec2`,`volumes`],queryFn:()=>{let e=new A({});return f().send(e)},refetchInterval:5e3}),Q=t=>e({queryKey:[`ec2`,`volumes`,t],queryFn:()=>{let e=new A({VolumeIds:[t]});return f().send(e)},refetchInterval:5e3});export{V as _,F as a,K as b,R as c,B as d,X as f,H as g,U as h,P as i,J as l,W as m,L as n,N as o,Y as p,I as r,z as s,M as t,q as u,Q as v,G as x,Z as y}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/ec23.js b/spinifex/services/spinifexui/frontend/dist/assets/ec23.js index 5b70315bb..19be92c35 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/ec23.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/ec23.js @@ -1 +1 @@ -import{A as e,D as t,E as n,O as r,T as i,k as a,w as o}from"./SignatureV4.js";import{F as s,I as c,P as l}from"./ec2.js";var u=/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\/\d{1,2}$/,d=e().min(1,`Key name is required`).max(255,`Key name must be 255 characters or less`).regex(/^[\w\s._\-:/()#,@[\]+=&;{}!$*]+$/,`Key name contains invalid characters`),f=a({imageId:e(`Please select an Image`),instanceType:e(`Please select an instance type`),keyName:e(`Please select a key pair`),subnetId:e().optional(),placementGroupName:e().optional(),count:t(`Instance count must be a whole number`).min(1,`Instance count must be at least 1`)}),p=a({keyName:d}),m=a({keyName:d,publicKeyMaterial:e().min(1,`Public key is required`).refine(e=>e.trim().length>0,`Public key cannot be empty`)}),h=a({size:r().int(`Size must be a whole number`).min(1,`Size must be at least 1 GiB`).max(16384,`Size must be at most 16384 GiB`),availabilityZone:e().min(1,`Availability zone is required`)}),g=a({size:r().int(`Size must be a whole number`).min(1,`Size must be at least 1 GiB`)}),_=a({volumeId:e().min(1,`Volume is required`),description:e().optional()});a({sourceSnapshotId:e().min(1,`Source snapshot is required`),sourceRegion:e().min(1,`Source region is required`),description:e().optional()}),a({volumeId:e().min(1,`Volume is required`),instanceId:e().min(1,`Instance is required`),device:e().optional()}),a({volumeId:e().min(1,`Volume is required`),instanceId:e().optional(),force:n().optional()}),a({instanceType:e().min(1,`Instance type is required`)}),a({name:e().min(1,`Name is required`),description:e().optional()});var v=a({vpcId:e().min(1,`VPC is required`),cidrBlock:e().min(1,`CIDR block is required`).regex(u,`Must be a valid CIDR block (e.g. 10.0.1.0/24)`),availabilityZone:e().optional()});a({cidrBlock:e().min(1,`CIDR block is required`).regex(u,`Must be a valid CIDR block (e.g. 10.0.0.0/16)`),name:e().optional()});var y=a({key:e().min(1,`Key is required`),value:e()}),b=a({mode:o([`vpc-only`,`vpc-and-more`]),namePrefix:e().optional(),autoGenerateNames:n(),cidrBlock:e().min(1,`CIDR block is required`).regex(u,`Must be a valid CIDR block (e.g. 10.0.0.0/16)`).refine(e=>c(e),`CIDR has invalid octets or prefix length (must be /16 to /28)`),tenancy:o([`default`,`dedicated`]),publicSubnetCount:r().int().min(0).max(1),privateSubnetCount:r().int().min(0).max(2),publicSubnetCidrs:i(e()),privateSubnetCidrs:i(e()),tags:i(y)}).superRefine((e,t)=>{if(e.mode!==`vpc-and-more`)return;let n=[];for(let[r,i]of e.publicSubnetCidrs.entries())c(i,16,28)?(l(e.cidrBlock,i)||t.addIssue({code:`custom`,message:`Subnet CIDR must be within the VPC CIDR range`,path:[`publicSubnetCidrs`,r]}),n.push({cidr:i,field:`publicSubnetCidrs`,index:r})):t.addIssue({code:`custom`,message:`Invalid subnet CIDR format or prefix length`,path:[`publicSubnetCidrs`,r]});for(let[r,i]of e.privateSubnetCidrs.entries())c(i,16,28)?(l(e.cidrBlock,i)||t.addIssue({code:`custom`,message:`Subnet CIDR must be within the VPC CIDR range`,path:[`privateSubnetCidrs`,r]}),n.push({cidr:i,field:`privateSubnetCidrs`,index:r})):t.addIssue({code:`custom`,message:`Invalid subnet CIDR format or prefix length`,path:[`privateSubnetCidrs`,r]});for(let e=0;ee.trim().length>0,`Public key cannot be empty`)}),h=a({size:r().int(`Size must be a whole number`).min(1,`Size must be at least 1 GiB`).max(16384,`Size must be at most 16384 GiB`),availabilityZone:e().min(1,`Availability zone is required`)}),g=a({size:r().int(`Size must be a whole number`).min(1,`Size must be at least 1 GiB`)}),_=a({volumeId:e().min(1,`Volume is required`),description:e().optional()});a({sourceSnapshotId:e().min(1,`Source snapshot is required`),sourceRegion:e().min(1,`Source region is required`),description:e().optional()}),a({volumeId:e().min(1,`Volume is required`),instanceId:e().min(1,`Instance is required`),device:e().optional()}),a({volumeId:e().min(1,`Volume is required`),instanceId:e().optional(),force:n().optional()}),a({instanceType:e().min(1,`Instance type is required`)}),a({name:e().min(1,`Name is required`),description:e().optional()});var v=a({vpcId:e().min(1,`VPC is required`),cidrBlock:e().min(1,`CIDR block is required`).regex(u,`Must be a valid CIDR block (e.g. 10.0.1.0/24)`),availabilityZone:e().optional()});a({cidrBlock:e().min(1,`CIDR block is required`).regex(u,`Must be a valid CIDR block (e.g. 10.0.0.0/16)`),name:e().optional()});var y=a({key:e().min(1,`Key is required`),value:e()}),b=a({mode:o([`vpc-only`,`vpc-and-more`]),namePrefix:e().optional(),autoGenerateNames:n(),cidrBlock:e().min(1,`CIDR block is required`).regex(u,`Must be a valid CIDR block (e.g. 10.0.0.0/16)`).refine(e=>c(e),`CIDR has invalid octets or prefix length (must be /16 to /28)`),tenancy:o([`default`,`dedicated`]),publicSubnetCount:r().int().min(0).max(1),privateSubnetCount:r().int().min(0).max(2),publicSubnetCidrs:i(e()),privateSubnetCidrs:i(e()),tags:i(y)}).superRefine((e,t)=>{if(e.mode!==`vpc-and-more`)return;let n=[];for(let[r,i]of e.publicSubnetCidrs.entries())c(i,16,28)?(l(e.cidrBlock,i)||t.addIssue({code:`custom`,message:`Subnet CIDR must be within the VPC CIDR range`,path:[`publicSubnetCidrs`,r]}),n.push({cidr:i,field:`publicSubnetCidrs`,index:r})):t.addIssue({code:`custom`,message:`Invalid subnet CIDR format or prefix length`,path:[`publicSubnetCidrs`,r]});for(let[r,i]of e.privateSubnetCidrs.entries())c(i,16,28)?(l(e.cidrBlock,i)||t.addIssue({code:`custom`,message:`Subnet CIDR must be within the VPC CIDR range`,path:[`privateSubnetCidrs`,r]}),n.push({cidr:i,field:`privateSubnetCidrs`,index:r})):t.addIssue({code:`custom`,message:`Invalid subnet CIDR format or prefix length`,path:[`privateSubnetCidrs`,r]});for(let e=0;e{r.invalidateQueries({queryKey:[`iam`,`users`]})}},e[0]=r,e[1]=i),n(i)}function D(e){let t=new y({UserName:e.userName,Path:e.path||void 0});return p().send(t)}function O(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:k,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`users`]})}},e[0]=r,e[1]=i),n(i)}function k(e){let t=new S({UserName:e});return p().send(t)}function A(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:j,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`access-keys`]})}},e[0]=r,e[1]=i),n(i)}function j(e){let t=new _({UserName:e});return p().send(t)}function M(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:N,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`access-keys`]})}},e[0]=r,e[1]=i),n(i)}function N(e){let{userName:t,accessKeyId:n}=e,r=new b({UserName:t,AccessKeyId:n});return p().send(r)}function P(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:F,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`access-keys`]})}},e[0]=r,e[1]=i),n(i)}function F(e){let{userName:t,accessKeyId:n,status:r}=e,i=new w({UserName:t,AccessKeyId:n,Status:r});return p().send(i)}function I(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:L,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`policies`]})}},e[0]=r,e[1]=i),n(i)}function L(e){let t=new v({PolicyName:e.policyName,Description:e.description||void 0,PolicyDocument:e.policyDocument});return p().send(t)}function R(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:z,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`policies`]})}},e[0]=r,e[1]=i),n(i)}function z(e){let t=new x({PolicyArn:e});return p().send(t)}function B(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:V,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`attached-user-policies`]})}},e[0]=r,e[1]=i),n(i)}function V(e){let{userName:t,policyArn:n}=e,r=new g({UserName:t,PolicyArn:n});return p().send(r)}function H(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:U,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`attached-user-policies`]})}},e[0]=r,e[1]=i),n(i)}function U(e){let{userName:t,policyArn:n}=e,r=new C({UserName:t,PolicyArn:n});return p().send(r)}export{M as a,H as c,E as i,P as l,A as n,R as o,I as r,O as s,B as t}; \ No newline at end of file +import{t as e}from"./compiler-runtime.js";import{n as t}from"./QueryClientProvider.js";import{n}from"./error-banner.js";import{A as r,C as i,D as a,E as o,O as s,R as c,Rt as l,T as u,k as d,r as f,w as p,z as m,zt as h}from"./awsClient.js";var g=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`AttachUserPolicy`,{}).n(`IAMClient`,`AttachUserPolicyCommand`).sc(i).build(){},_=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`CreateAccessKey`,{}).n(`IAMClient`,`CreateAccessKeyCommand`).sc(p).build(){},v=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`CreatePolicy`,{}).n(`IAMClient`,`CreatePolicyCommand`).sc(u).build(){},y=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`CreateUser`,{}).n(`IAMClient`,`CreateUserCommand`).sc(o).build(){},b=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`DeleteAccessKey`,{}).n(`IAMClient`,`DeleteAccessKeyCommand`).sc(a).build(){},x=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`DeletePolicy`,{}).n(`IAMClient`,`DeletePolicyCommand`).sc(s).build(){},S=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`DeleteUser`,{}).n(`IAMClient`,`DeleteUserCommand`).sc(d).build(){},C=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`DetachUserPolicy`,{}).n(`IAMClient`,`DetachUserPolicyCommand`).sc(r).build(){},w=class extends l.classBuilder().ep(m).m(function(e,t,n,r){return[h(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`UpdateAccessKey`,{}).n(`IAMClient`,`UpdateAccessKeyCommand`).sc(c).build(){},T=e();function E(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:D,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`users`]})}},e[0]=r,e[1]=i),n(i)}function D(e){let t=new y({UserName:e.userName,Path:e.path||void 0});return f().send(t)}function O(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:k,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`users`]})}},e[0]=r,e[1]=i),n(i)}function k(e){let t=new S({UserName:e});return f().send(t)}function A(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:j,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`access-keys`]})}},e[0]=r,e[1]=i),n(i)}function j(e){let t=new _({UserName:e});return f().send(t)}function M(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:N,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`access-keys`]})}},e[0]=r,e[1]=i),n(i)}function N(e){let{userName:t,accessKeyId:n}=e,r=new b({UserName:t,AccessKeyId:n});return f().send(r)}function P(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:F,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`access-keys`]})}},e[0]=r,e[1]=i),n(i)}function F(e){let{userName:t,accessKeyId:n,status:r}=e,i=new w({UserName:t,AccessKeyId:n,Status:r});return f().send(i)}function I(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:L,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`policies`]})}},e[0]=r,e[1]=i),n(i)}function L(e){let t=new v({PolicyName:e.policyName,Description:e.description||void 0,PolicyDocument:e.policyDocument});return f().send(t)}function R(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:z,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`policies`]})}},e[0]=r,e[1]=i),n(i)}function z(e){let t=new x({PolicyArn:e});return f().send(t)}function B(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:V,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`attached-user-policies`]})}},e[0]=r,e[1]=i),n(i)}function V(e){let{userName:t,policyArn:n}=e,r=new g({UserName:t,PolicyArn:n});return f().send(r)}function H(){let e=(0,T.c)(2),r=t(),i;return e[0]===r?i=e[1]:(i={mutationFn:U,onSuccess:()=>{r.invalidateQueries({queryKey:[`iam`,`attached-user-policies`]})}},e[0]=r,e[1]=i),n(i)}function U(e){let{userName:t,policyArn:n}=e,r=new C({UserName:t,PolicyArn:n});return f().send(r)}export{M as a,H as c,E as i,P as l,A as n,R as o,I as r,O as s,B as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/iam2.js b/spinifex/services/spinifexui/frontend/dist/assets/iam2.js index 94888ccfe..b5ac0cddf 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/iam2.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/iam2.js @@ -1 +1 @@ -import{t as e}from"./queryOptions.js";import{F as t,I as n,L as r,Lt as i,M as a,N as o,P as s,Vt as c,j as l,r as u,z as d}from"./awsClient.js";var f=class extends c.classBuilder().ep(d).m(function(e,t,n,r){return[i(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`GetPolicy`,{}).n(`IAMClient`,`GetPolicyCommand`).sc(l).build(){},p=class extends c.classBuilder().ep(d).m(function(e,t,n,r){return[i(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`GetPolicyVersion`,{}).n(`IAMClient`,`GetPolicyVersionCommand`).sc(a).build(){},m=class extends c.classBuilder().ep(d).m(function(e,t,n,r){return[i(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`GetUser`,{}).n(`IAMClient`,`GetUserCommand`).sc(o).build(){},h=class extends c.classBuilder().ep(d).m(function(e,t,n,r){return[i(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`ListAccessKeys`,{}).n(`IAMClient`,`ListAccessKeysCommand`).sc(s).build(){},g=class extends c.classBuilder().ep(d).m(function(e,t,n,r){return[i(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`ListAttachedUserPolicies`,{}).n(`IAMClient`,`ListAttachedUserPoliciesCommand`).sc(t).build(){},_=class extends c.classBuilder().ep(d).m(function(e,t,n,r){return[i(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`ListPolicies`,{}).n(`IAMClient`,`ListPoliciesCommand`).sc(n).build(){},v=class extends c.classBuilder().ep(d).m(function(e,t,n,r){return[i(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`ListUsers`,{}).n(`IAMClient`,`ListUsersCommand`).sc(r).build(){},y=e({queryKey:[`iam`,`users`],queryFn:()=>{let e=new v({});return u().send(e)},staleTime:3e5}),b=t=>e({queryKey:[`iam`,`users`,t],queryFn:()=>{let e=new m({UserName:t});return u().send(e)},staleTime:3e5}),x=t=>e({queryKey:[`iam`,`access-keys`,t],queryFn:()=>{let e=new h({UserName:t});return u().send(e)},staleTime:3e5}),S=e({queryKey:[`iam`,`policies`],queryFn:()=>{let e=new _({Scope:`Local`});return u().send(e)},staleTime:3e5}),C=t=>e({queryKey:[`iam`,`policies`,t],queryFn:()=>{let e=new f({PolicyArn:t});return u().send(e)},staleTime:3e5}),w=(t,n)=>e({queryKey:[`iam`,`policy-versions`,t,n],queryFn:()=>{let e=new p({PolicyArn:t,VersionId:n});return u().send(e)},staleTime:3e5}),T=t=>e({queryKey:[`iam`,`attached-user-policies`,t],queryFn:()=>{let e=new g({UserName:t});return u().send(e)},staleTime:3e5});export{w as a,C as i,T as n,b as o,S as r,y as s,x as t}; \ No newline at end of file +import{t as e}from"./queryOptions.js";import{F as t,I as n,L as r,M as i,N as a,P as o,Rt as s,j as c,r as l,z as u,zt as d}from"./awsClient.js";var f=class extends s.classBuilder().ep(u).m(function(e,t,n,r){return[d(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`GetPolicy`,{}).n(`IAMClient`,`GetPolicyCommand`).sc(c).build(){},p=class extends s.classBuilder().ep(u).m(function(e,t,n,r){return[d(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`GetPolicyVersion`,{}).n(`IAMClient`,`GetPolicyVersionCommand`).sc(i).build(){},m=class extends s.classBuilder().ep(u).m(function(e,t,n,r){return[d(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`GetUser`,{}).n(`IAMClient`,`GetUserCommand`).sc(a).build(){},h=class extends s.classBuilder().ep(u).m(function(e,t,n,r){return[d(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`ListAccessKeys`,{}).n(`IAMClient`,`ListAccessKeysCommand`).sc(o).build(){},g=class extends s.classBuilder().ep(u).m(function(e,t,n,r){return[d(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`ListAttachedUserPolicies`,{}).n(`IAMClient`,`ListAttachedUserPoliciesCommand`).sc(t).build(){},_=class extends s.classBuilder().ep(u).m(function(e,t,n,r){return[d(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`ListPolicies`,{}).n(`IAMClient`,`ListPoliciesCommand`).sc(n).build(){},v=class extends s.classBuilder().ep(u).m(function(e,t,n,r){return[d(n,e.getEndpointParameterInstructions())]}).s(`AWSIdentityManagementV20100508`,`ListUsers`,{}).n(`IAMClient`,`ListUsersCommand`).sc(r).build(){},y=e({queryKey:[`iam`,`users`],queryFn:()=>{let e=new v({});return l().send(e)},staleTime:3e5}),b=t=>e({queryKey:[`iam`,`users`,t],queryFn:()=>{let e=new m({UserName:t});return l().send(e)},staleTime:3e5}),x=t=>e({queryKey:[`iam`,`access-keys`,t],queryFn:()=>{let e=new h({UserName:t});return l().send(e)},staleTime:3e5}),S=e({queryKey:[`iam`,`policies`],queryFn:()=>{let e=new _({Scope:`Local`});return l().send(e)},staleTime:3e5}),C=t=>e({queryKey:[`iam`,`policies`,t],queryFn:()=>{let e=new f({PolicyArn:t});return l().send(e)},staleTime:3e5}),w=(t,n)=>e({queryKey:[`iam`,`policy-versions`,t,n],queryFn:()=>{let e=new p({PolicyArn:t,VersionId:n});return l().send(e)},staleTime:3e5}),T=t=>e({queryKey:[`iam`,`attached-user-policies`,t],queryFn:()=>{let e=new g({UserName:t});return l().send(e)},staleTime:3e5});export{w as a,C as i,T as n,b as o,S as r,y as s,x as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/index.js b/spinifex/services/spinifexui/frontend/dist/assets/index.js index 91b0e4e51..eec6943c0 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/index.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/index.js @@ -1,10 +1,10 @@ -const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/login.js","assets/compiler-runtime.js","assets/awsClient.js","assets/SignatureV4.js","assets/fromUtf8.browser.js","assets/toUtf8.browser.js","assets/DescribeInstancesCommand.js","assets/button.js","assets/dist.js","assets/separator.js","assets/createBaseUIEventDetails.js","assets/useTransitionStatus.js","assets/zod.js","assets/useNavigate.js","assets/useRouter.js","assets/card.js","assets/field.js","assets/route.js","assets/_auth.js","assets/ec22.js","assets/queryOptions.js","assets/s32.js","assets/admin.js","assets/useBaseQuery.js","assets/QueryClientProvider.js","assets/link.js","assets/useStore.js","assets/createLucideIcon.js","assets/chevron-down.js","assets/chevron-right.js","assets/page-heading.js","assets/state-badge.js","assets/nodes.js","assets/redirect.js","assets/service-metrics.js","assets/ls.js","assets/useSuspenseQuery.js","assets/list-card.js","assets/create-bucket.js","assets/s3.js","assets/error-banner.js","assets/back-link.js","assets/cli-command-panel.js","assets/check.js","assets/copy.js","assets/use-copy-to-clipboard.js","assets/form-actions.js","assets/create-user.js","assets/iam.js","assets/iam3.js","assets/create-policy.js","assets/textarea.js","assets/create-vpc.js","assets/ec2.js","assets/select.js","assets/useOpenInteractionType.js","assets/ec23.js","assets/create-volume.js","assets/create-subnet.js","assets/create-snapshot.js","assets/create-security-group.js","assets/create-placement-group.js","assets/import-key-pair.js","assets/create-key-pair.js","assets/alert-dialog.js","assets/download.js","assets/triangle-alert.js","assets/run-instances.js","assets/route2.js","assets/_bucket.js","assets/upload-button.js","assets/trash-2.js","assets/delete-confirmation-dialog.js","assets/list-users.js","assets/iam2.js","assets/list-policies.js","assets/describe-vpcs.js","assets/describe-volumes.js","assets/describe-subnets.js","assets/describe-snapshots.js","assets/describe-security-groups.js","assets/describe-placement-groups.js","assets/describe-key-pairs.js","assets/describe-instances.js","assets/describe-images.js","assets/_.js","assets/_userName.js","assets/detail-row.js","assets/_policyArn.js","assets/_id10.js","assets/_id9.js","assets/_id8.js","assets/_id7.js","assets/_id6.js","assets/_id5.js","assets/_id4.js","assets/_id3.js","assets/_id2.js","assets/ami-details.js","assets/_id.js"])))=>i.map(i=>d[i]); -import{a as e,i as t,n,r,t as i}from"./compiler-runtime.js";import{C as a,M as o,O as s,S as c,T as l,_ as u,a as d,b as f,c as p,d as m,f as h,g,h as _,i as v,j as y,k as b,m as x,n as S,o as C,p as w,r as T,s as E,t as D,w as O,x as k,y as A}from"./QueryClientProvider.js";import{n as ee,o as j,s as M,t as N}from"./useRouter.js";import{A as P,C as te,D as ne,E as re,F as ie,I as F,L as I,N as ae,O as oe,P as se,S as ce,T as le,_ as ue,a as de,b as fe,f as pe,g as me,h as he,i as ge,j as _e,k as ve,l as ye,o as be,p as xe,s as Se,t as Ce,u as we,v as Te,w as Ee,x as De,y as Oe}from"./useStore.js";import{i as ke,n as Ae,r as je}from"./matchContext.js";import{n as Me,t as Ne}from"./redirect.js";import{t as Pe}from"./link.js";import{n as L,r as Fe,t as R}from"./lazyRouteComponent.js";import{t as Ie}from"./useNavigate.js";import{Ut as z,Xt as Le,t as Re}from"./awsClient.js";import{g as ze,i as Be,l as Ve,m as He,n as Ue,o as We,p as Ge,t as Ke}from"./dist.js";import{F as qe,I as Je,P as Ye,S as Xe,c as Ze,l as Qe,t as $e,x as et}from"./SignatureV4.js";import{t as tt}from"./createLucideIcon.js";import{C as nt,T as rt,_ as B,c as it,d as at,f as ot,g as st,h as ct,i as lt,l as ut,m as dt,n as ft,o as pt,p as mt,r as ht,s as gt,t as _t,u as vt,v as yt,w as bt,x as xt,y as St}from"./button.js";import{a as Ct,c as wt,i as Tt,n as Et,r as Dt,s as Ot,t as kt}from"./separator.js";import{B as At,H as jt,L as Mt,N as Nt,R as Pt,S as Ft,T as It,V as Lt,_ as Rt,f as zt,g as Bt,i as Vt,p as Ht,r as Ut,s as Wt,t as Gt,u as Kt,v as qt,w as Jt,y as Yt}from"./createBaseUIEventDetails.js";import{a as Xt,l as Zt,n as Qt,t as $t}from"./useTransitionStatus.js";import{$ as en,C as tn,D as nn,E as rn,G as an,H as on,J as sn,K as cn,O as ln,Q as un,U as dn,W as fn,X as pn,Y as mn,Z as hn,_ as gn,a as _n,at as vn,b as yn,c as bn,et as xn,g as Sn,h as V,ht as Cn,i as wn,it as Tn,j as En,k as Dn,l as On,lt as kn,m as An,mt as jn,nt as Mn,o as Nn,ot as Pn,p as Fn,pt as In,q as Ln,r as Rn,rt as zn,s as Bn,st as Vn,t as Hn,tt as Un,u as Wn,v as Gn,x as Kn,y as qn}from"./useOpenInteractionType.js";import{_ as Jn,a as Yn,b as Xn,c as Zn,d as Qn,f as $n,g as er,h as tr,i as nr,l as rr,m as ir,n as ar,o as or,p as sr,r as cr,s as lr,t as ur,u as dr,v as fr,x as pr,y as mr}from"./ec22.js";import{a as hr,i as gr,n as _r,o as vr,r as yr,s as br,t as xr}from"./iam2.js";import{n as Sr,t as Cr}from"./s32.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var wr=class extends T{#e;#t;#n;#r;#i;#a;#o;constructor(e){super(),this.#o=!1,this.#a=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.#r=e.client,this.#n=this.#r.getQueryCache(),this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#e=Dr(this.options),this.state=e.state??this.#e,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#i?.promise}setOptions(e){if(this.options={...this.#a,...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){let e=Dr(this.options);e.data!==void 0&&(this.setState(Er(e.data,e.dataUpdatedAt)),this.#e=e)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus===`idle`&&this.#n.remove(this)}setData(e,t){let n=a(this.state.data,e,this.options);return this.#c({data:n,type:`success`,dataUpdatedAt:t?.updatedAt,manual:t?.manual}),n}setState(e,t){this.#c({type:`setState`,state:e,setStateOptions:t})}cancel(e){let t=this.#i?.promise;return this.#i?.cancel(e),t?t.then(k).catch(k):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return this.#e}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(e=>O(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===s||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>l(e.options.staleTime,this)===`static`):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e===`static`?!1:this.state.isInvalidated?!0:!b(this.state.dataUpdatedAt,e)}onFocus(){this.observers.find(e=>e.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#i?.continue()}onOnline(){this.observers.find(e=>e.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#i?.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.#n.notify({type:`observerAdded`,query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(this.#i&&(this.#o||this.#s()?this.#i.cancel({revert:!0}):this.#i.cancelRetry()),this.scheduleGc()),this.#n.notify({type:`observerRemoved`,query:this,observer:e}))}getObserversCount(){return this.observers.length}#s(){return this.state.fetchStatus===`paused`&&this.state.status===`pending`}invalidate(){this.state.isInvalidated||this.#c({type:`invalidate`})}async fetch(e,t){if(this.state.fetchStatus!==`idle`&&this.#i?.status()!==`rejected`){if(this.state.data!==void 0&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#i)return this.#i.continueRetry(),this.#i.promise}if(e&&this.setOptions(e),!this.options.queryFn){let e=this.observers.find(e=>e.options.queryFn);e&&this.setOptions(e.options)}let n=new AbortController,r=e=>{Object.defineProperty(e,`signal`,{enumerable:!0,get:()=>(this.#o=!0,n.signal)})},i=()=>{let e=x(this.options,t),n=(()=>{let e={client:this.#r,queryKey:this.queryKey,meta:this.meta};return r(e),e})();return this.#o=!1,this.options.persister?this.options.persister(e,n,this):e(n)},a=(()=>{let e={fetchOptions:t,options:this.options,queryKey:this.queryKey,client:this.#r,state:this.state,fetchFn:i};return r(e),e})();this.options.behavior?.onFetch(a,this),this.#t=this.state,(this.state.fetchStatus===`idle`||this.state.fetchMeta!==a.fetchOptions?.meta)&&this.#c({type:`fetch`,meta:a.fetchOptions?.meta}),this.#i=C({initialPromise:t?.initialPromise,fn:a.fetchFn,onCancel:e=>{e instanceof v&&e.revert&&this.setState({...this.#t,fetchStatus:`idle`}),n.abort()},onFail:(e,t)=>{this.#c({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#c({type:`pause`})},onContinue:()=>{this.#c({type:`continue`})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0});try{let e=await this.#i.start();if(e===void 0)throw Error(`${this.queryHash} data is undefined`);return this.setData(e),this.#n.config.onSuccess?.(e,this),this.#n.config.onSettled?.(e,this.state.error,this),e}catch(e){if(e instanceof v){if(e.silent)return this.#i.promise;if(e.revert){if(this.state.data===void 0)throw e;return this.state.data}}throw this.#c({type:`error`,error:e}),this.#n.config.onError?.(e,this),this.#n.config.onSettled?.(this.state.data,e,this),e}finally{this.scheduleGc()}}#c(e){this.state=(t=>{switch(e.type){case`failed`:return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case`pause`:return{...t,fetchStatus:`paused`};case`continue`:return{...t,fetchStatus:`fetching`};case`fetch`:return{...t,...Tr(t.data,this.options),fetchMeta:e.meta??null};case`success`:let n={...t,...Er(e.data,e.dataUpdatedAt),dataUpdateCount:t.dataUpdateCount+1,...!e.manual&&{fetchStatus:`idle`,fetchFailureCount:0,fetchFailureReason:null}};return this.#t=e.manual?n:void 0,n;case`error`:let r=e.error;return{...t,error:r,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:r,fetchStatus:`idle`,status:`error`,isInvalidated:!0};case`invalidate`:return{...t,isInvalidated:!0};case`setState`:return{...t,...e.state}}})(this.state),p.batch(()=>{this.observers.forEach(e=>{e.onQueryUpdate()}),this.#n.notify({query:this,type:`updated`,action:e})})}};function Tr(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:d(t.networkMode)?`fetching`:`paused`,...e===void 0&&{error:null,status:`pending`}}}function Er(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:`success`}}function Dr(e){let t=typeof e.initialData==`function`?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt==`function`?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?`success`:`pending`,fetchStatus:`idle`}}function Or(e){return{onFetch:(t,n)=>{let r=t.options,i=t.fetchOptions?.meta?.fetchMore?.direction,a=t.state.data?.pages||[],o=t.state.data?.pageParams||[],s={pages:[],pageParams:[]},c=0,l=async()=>{let n=!1,l=e=>{m(e,()=>t.signal,()=>n=!0)},u=x(t.options,t.fetchOptions),d=async(e,r,i)=>{if(n)return Promise.reject();if(r==null&&e.pages.length)return Promise.resolve(e);let a=await u((()=>{let e={client:t.client,queryKey:t.queryKey,pageParam:r,direction:i?`backward`:`forward`,meta:t.options.meta};return l(e),e})()),{maxPages:o}=t.options,s=i?w:h;return{pages:s(e.pages,a,o),pageParams:s(e.pageParams,r,o)}};if(i&&a.length){let e=i===`backward`,t=e?Ar:kr,n={pages:a,pageParams:o};s=await d(n,t(r,n),e)}else{let t=e??a.length;do{let e=c===0?o[0]??r.initialPageParam:kr(r,s);if(c>0&&e==null)break;s=await d(s,e),c++}while(ct.options.persister?.(l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n):t.fetchFn=l}}}function kr(e,{pages:t,pageParams:n}){let r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function Ar(e,{pages:t,pageParams:n}){return t.length>0?e.getPreviousPageParam?.(t[0],t,n[0],n):void 0}var jr=class extends T{#e;#t;#n;#r;constructor(e){super(),this.#e=e.client,this.mutationId=e.mutationId,this.#n=e.mutationCache,this.#t=[],this.state=e.state||Mr(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#t.includes(e)||(this.#t.push(e),this.clearGcTimeout(),this.#n.notify({type:`observerAdded`,mutation:this,observer:e}))}removeObserver(e){this.#t=this.#t.filter(t=>t!==e),this.scheduleGc(),this.#n.notify({type:`observerRemoved`,mutation:this,observer:e})}optionalRemove(){this.#t.length||(this.state.status===`pending`?this.scheduleGc():this.#n.remove(this))}continue(){return this.#r?.continue()??this.execute(this.state.variables)}async execute(e){let t=()=>{this.#i({type:`continue`})},n={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#r=C({fn:()=>this.options.mutationFn?this.options.mutationFn(e,n):Promise.reject(Error(`No mutationFn found`)),onFail:(e,t)=>{this.#i({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#i({type:`pause`})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});let r=this.state.status===`pending`,i=!this.#r.canStart();try{if(r)t();else{this.#i({type:`pending`,variables:e,isPaused:i}),this.#n.config.onMutate&&await this.#n.config.onMutate(e,this,n);let t=await this.options.onMutate?.(e,n);t!==this.state.context&&this.#i({type:`pending`,context:t,variables:e,isPaused:i})}let a=await this.#r.start();return await this.#n.config.onSuccess?.(a,e,this.state.context,this,n),await this.options.onSuccess?.(a,e,this.state.context,n),await this.#n.config.onSettled?.(a,null,this.state.variables,this.state.context,this,n),await this.options.onSettled?.(a,null,e,this.state.context,n),this.#i({type:`success`,data:a}),a}catch(t){try{await this.#n.config.onError?.(t,e,this.state.context,this,n)}catch(e){Promise.reject(e)}try{await this.options.onError?.(t,e,this.state.context,n)}catch(e){Promise.reject(e)}try{await this.#n.config.onSettled?.(void 0,t,this.state.variables,this.state.context,this,n)}catch(e){Promise.reject(e)}try{await this.options.onSettled?.(void 0,t,e,this.state.context,n)}catch(e){Promise.reject(e)}throw this.#i({type:`error`,error:t}),t}finally{this.#n.runNext(this)}}#i(e){this.state=(t=>{switch(e.type){case`failed`:return{...t,failureCount:e.failureCount,failureReason:e.error};case`pause`:return{...t,isPaused:!0};case`continue`:return{...t,isPaused:!1};case`pending`:return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:`pending`,variables:e.variables,submittedAt:Date.now()};case`success`:return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:`success`,isPaused:!1};case`error`:return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:`error`}}})(this.state),p.batch(()=>{this.#t.forEach(t=>{t.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:`updated`,action:e})})}};function Mr(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:`idle`,variables:void 0,submittedAt:0}}var Nr=class extends o{constructor(e={}){super(),this.config=e,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(e,t,n){let r=new jr({client:e,mutationCache:this,mutationId:++this.#n,options:e.defaultMutationOptions(t),state:n});return this.add(r),r}add(e){this.#e.add(e);let t=Pr(e);if(typeof t==`string`){let n=this.#t.get(t);n?n.push(e):this.#t.set(t,[e])}this.notify({type:`added`,mutation:e})}remove(e){if(this.#e.delete(e)){let t=Pr(e);if(typeof t==`string`){let n=this.#t.get(t);if(n)if(n.length>1){let t=n.indexOf(e);t!==-1&&n.splice(t,1)}else n[0]===e&&this.#t.delete(t)}}this.notify({type:`removed`,mutation:e})}canRun(e){let t=Pr(e);if(typeof t==`string`){let n=this.#t.get(t)?.find(e=>e.state.status===`pending`);return!n||n===e}else return!0}runNext(e){let t=Pr(e);return typeof t==`string`?(this.#t.get(t)?.find(t=>t!==e&&t.state.isPaused))?.continue()??Promise.resolve():Promise.resolve()}clear(){p.batch(()=>{this.#e.forEach(e=>{this.notify({type:`removed`,mutation:e})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(e){let t={exact:!0,...e};return this.getAll().find(e=>A(t,e))}findAll(e={}){return this.getAll().filter(t=>A(e,t))}notify(e){p.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){let e=this.getAll().filter(e=>e.state.isPaused);return p.batch(()=>Promise.all(e.map(e=>e.continue().catch(k))))}};function Pr(e){return e.options.scope?.id}var Fr=class extends o{constructor(e={}){super(),this.config=e,this.#e=new Map}#e;build(e,t,n){let r=t.queryKey,i=t.queryHash??u(r,t),a=this.get(i);return a||(a=new wr({client:e,queryKey:r,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(a)),a}add(e){this.#e.has(e.queryHash)||(this.#e.set(e.queryHash,e),this.notify({type:`added`,query:e}))}remove(e){let t=this.#e.get(e.queryHash);t&&(e.destroy(),t===e&&this.#e.delete(e.queryHash),this.notify({type:`removed`,query:e}))}clear(){p.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#e.get(e)}getAll(){return[...this.#e.values()]}find(e){let t={exact:!0,...e};return this.getAll().find(e=>f(t,e))}findAll(e={}){let t=this.getAll();return Object.keys(e).length>0?t.filter(t=>f(e,t)):t}notify(e){p.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){p.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){p.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},Ir=class{#e;#t;#n;#r;#i;#a;#o;#s;constructor(e={}){this.#e=e.queryCache||new Fr,this.#t=e.mutationCache||new Nr,this.#n=e.defaultOptions||{},this.#r=new Map,this.#i=new Map,this.#a=0}mount(){this.#a++,this.#a===1&&(this.#o=y.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#s=E.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#a--,this.#a===0&&(this.#o?.(),this.#o=void 0,this.#s?.(),this.#s=void 0)}isFetching(e){return this.#e.findAll({...e,fetchStatus:`fetching`}).length}isMutating(e){return this.#t.findAll({...e,status:`pending`}).length}getQueryData(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state.data}ensureQueryData(e){let t=this.defaultQueryOptions(e),n=this.#e.build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(l(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return this.#e.findAll(e).map(({queryKey:e,state:t})=>[e,t.data])}setQueryData(e,t,n){let r=this.defaultQueryOptions({queryKey:e}),i=this.#e.get(r.queryHash)?.state.data,a=_(t,i);if(a!==void 0)return this.#e.build(this,r).setData(a,{...n,manual:!0})}setQueriesData(e,t,n){return p.batch(()=>this.#e.findAll(e).map(({queryKey:e})=>[e,this.setQueryData(e,t,n)]))}getQueryState(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state}removeQueries(e){let t=this.#e;p.batch(()=>{t.findAll(e).forEach(e=>{t.remove(e)})})}resetQueries(e,t){let n=this.#e;return p.batch(()=>(n.findAll(e).forEach(e=>{e.reset()}),this.refetchQueries({type:`active`,...e},t)))}cancelQueries(e,t={}){let n={revert:!0,...t},r=p.batch(()=>this.#e.findAll(e).map(e=>e.cancel(n)));return Promise.all(r).then(k).catch(k)}invalidateQueries(e,t={}){return p.batch(()=>(this.#e.findAll(e).forEach(e=>{e.invalidate()}),e?.refetchType===`none`?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??`active`},t)))}refetchQueries(e,t={}){let n={...t,cancelRefetch:t.cancelRefetch??!0},r=p.batch(()=>this.#e.findAll(e).filter(e=>!e.isDisabled()&&!e.isStatic()).map(e=>{let t=e.fetch(void 0,n);return n.throwOnError||(t=t.catch(k)),e.state.fetchStatus===`paused`?Promise.resolve():t}));return Promise.all(r).then(k)}fetchQuery(e){let t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);let n=this.#e.build(this,t);return n.isStaleByTime(l(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(k).catch(k)}fetchInfiniteQuery(e){return e.behavior=Or(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(k).catch(k)}ensureInfiniteQueryData(e){return e.behavior=Or(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return E.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(e){this.#n=e}setQueryDefaults(e,t){this.#r.set(g(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){let t=[...this.#r.values()],n={};return t.forEach(t=>{c(e,t.queryKey)&&Object.assign(n,t.defaultOptions)}),n}setMutationDefaults(e,t){this.#i.set(g(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){let t=[...this.#i.values()],n={};return t.forEach(t=>{c(e,t.mutationKey)&&Object.assign(n,t.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;let t={...this.#n.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||=u(t.queryKey,t),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!==`always`),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode=`offlineFirst`),t.queryFn===s&&(t.enabled=!1),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#n.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}};function Lr(){try{return typeof window<`u`&&typeof window.sessionStorage==`object`?window.sessionStorage:void 0}catch{return}}var Rr=`tsr-scroll-restoration-v1_3`;function zr(){let e=Lr();if(!e)return null;let t={};try{let n=JSON.parse(e.getItem(`tsr-scroll-restoration-v1_3`)||`{}`);ae(n)&&(t=n)}catch{}return{get state(){return t},set:e=>{t=P(e,t)||t},persist:()=>{try{e.setItem(Rr,JSON.stringify(t))}catch{}}}}var Br=zr(),Vr=e=>e.state.__TSR_key||e.href;function Hr(e){let t=[],n;for(;n=e.parentNode;)t.push(`${e.tagName}:nth-child(${Array.prototype.indexOf.call(n.children,e)+1})`),e=n;return`${t.reverse().join(` > `)}`.toLowerCase()}var Ur=!1,Wr=`window`,Gr=`data-scroll-restoration-id`;function Kr(e,t){if(!Br)return;let n=Br;if((t??e.options.scrollRestoration??!1)&&(e.isScrollRestoring=!0),e.isScrollRestorationSetup||!n)return;e.isScrollRestorationSetup=!0,Ur=!1;let r=e.options.getScrollRestorationKey||Vr,i=new Map;window.history.scrollRestoration=`manual`;let a=t=>{if(!(Ur||!e.isScrollRestoring))if(t.target===document||t.target===window)i.set(Wr,{scrollX:window.scrollX||0,scrollY:window.scrollY||0});else{let e=t.target;i.set(e,{scrollX:e.scrollLeft||0,scrollY:e.scrollTop||0})}},o=t=>{if(!e.isScrollRestoring||!t||i.size===0||!n)return;let r=n.state[t]||={};for(let[e,t]of i){let n;if(e===Wr)n=Wr;else if(e.isConnected){let t=e.getAttribute(Gr);n=t?`[${Gr}="${t}"]`:Hr(e)}n&&(r[n]=t)}};document.addEventListener(`scroll`,a,!0),e.subscribe(`onBeforeLoad`,e=>{o(e.fromLocation?r(e.fromLocation):void 0),i.clear()}),window.addEventListener(`pagehide`,()=>{o(r(e.stores.resolvedLocation.state??e.stores.location.state)),n.persist()}),e.subscribe(`onRendered`,t=>{let a=r(t.toLocation),o=e.options.scrollRestorationBehavior,s=e.options.scrollToTopSelectors;if(i.clear(),!e.resetNextScroll){e.resetNextScroll=!0;return}if(!(typeof e.options.scrollRestoration==`function`&&!e.options.scrollRestoration({location:e.latestLocation}))){Ur=!0;try{let t=e.isScrollRestoring?n.state[a]:void 0,r=!1;if(t)for(let e in t){let n=t[e];if(!ae(n))continue;let{scrollX:i,scrollY:a}=n;if(!(!Number.isFinite(i)||!Number.isFinite(a))){if(e===Wr)window.scrollTo({top:a,left:i,behavior:o}),r=!0;else if(e){let t;try{t=document.querySelector(e)}catch{continue}t&&(t.scrollLeft=i,t.scrollTop=a,r=!0)}}}if(!r){let t=e.history.location.hash.slice(1);if(t){let e=window.history.state?.__hashScrollIntoViewOptions??!0;if(e){let n=document.getElementById(t);n&&n.scrollIntoView(e)}}else{let e={top:0,left:0,behavior:o};if(window.scrollTo(e),s)for(let t of s){if(t===Wr)continue;let n=typeof t==`function`?t():document.querySelector(t);n&&n.scrollTo(e)}}}}finally{Ur=!1}e.isScrollRestoring&&n.set(e=>(e[a]||={},e))}})}function qr(e,t=String){let n=new URLSearchParams;for(let r in e){let i=e[r];i!==void 0&&n.set(r,t(i))}return n.toString()}function Jr(e){return e?e===`false`?!1:e===`true`?!0:e*0==0&&+e+``===e?+e:e:``}function Yr(e){let t=new URLSearchParams(e),n=Object.create(null);for(let[e,r]of t.entries()){let t=n[e];t==null?n[e]=Jr(r):Array.isArray(t)?t.push(Jr(r)):n[e]=[t,Jr(r)]}return n}var Xr=Qr(JSON.parse),Zr=$r(JSON.stringify,JSON.parse);function Qr(e){return t=>{t[0]===`?`&&(t=t.substring(1));let n=Yr(t);for(let t in n){let r=n[t];if(typeof r==`string`)try{n[t]=e(r)}catch{}}return n}}function $r(e,t){let n=typeof t==`function`;function r(r){if(typeof r==`object`&&r)try{return e(r)}catch{}else if(n&&typeof r==`string`)try{return t(r),e(r)}catch{}return r}return e=>{let t=qr(e,r);return t?`?${t}`:``}}function ei(e){return{input:({url:t})=>{for(let n of e)t=ni(n,t);return t},output:({url:t})=>{for(let n=e.length-1;n>=0;n--)t=ri(e[n],t);return t}}}function ti(e){let t=xe(e.basepath),n=`/${t}`,r=`${n}/`,i=e.caseSensitive?n:n.toLowerCase(),a=e.caseSensitive?r:r.toLowerCase();return{input:({url:t})=>{let r=e.caseSensitive?t.pathname:t.pathname.toLowerCase();return r===i?t.pathname=`/`:r.startsWith(a)&&(t.pathname=t.pathname.slice(n.length)),t},output:({url:e})=>(e.pathname=we([`/`,t,e.pathname]),e)}}function ni(e,t){let n=e?.input?.({url:t});if(n){if(typeof n==`string`)return new URL(n);if(n instanceof URL)return n}return t}function ri(e,t){let n=e?.output?.({url:t});if(n){if(typeof n==`string`)return new URL(n);if(n instanceof URL)return n}return t}function ii(e,t){let{createMutableStore:n,createReadonlyStore:r,batch:i,init:a}=t,o=new Map,s=new Map,c=new Map,l=n(e.status),u=n(e.loadedAt),d=n(e.isLoading),f=n(e.isTransitioning),p=n(e.location),m=n(e.resolvedLocation),h=n(e.statusCode),g=n(e.redirect),_=n([]),v=n([]),y=n([]),b=r(()=>ai(o,_.state)),x=r(()=>ai(s,v.state)),S=r(()=>ai(c,y.state)),C=r(()=>_.state[0]),w=r(()=>_.state.some(e=>o.get(e)?.state.status===`pending`)),T=r(()=>({locationHref:p.state.href,resolvedLocationHref:m.state?.href,status:l.state})),E=r(()=>({status:l.state,loadedAt:u.state,isLoading:d.state,isTransitioning:f.state,matches:b.state,location:p.state,resolvedLocation:m.state,statusCode:h.state,redirect:g.state})),D=De(64);function O(e){let t=D.get(e);return t||(t=r(()=>{let t=_.state;for(let n of t){let t=o.get(n);if(t&&t.routeId===e)return t.state}}),D.set(e,t)),t}let k={status:l,loadedAt:u,isLoading:d,isTransitioning:f,location:p,resolvedLocation:m,statusCode:h,redirect:g,matchesId:_,pendingMatchesId:v,cachedMatchesId:y,activeMatchesSnapshot:b,pendingMatchesSnapshot:x,cachedMatchesSnapshot:S,firstMatchId:C,hasPendingMatches:w,matchRouteReactivity:T,activeMatchStoresById:o,pendingMatchStoresById:s,cachedMatchStoresById:c,__store:E,getMatchStoreByRouteId:O,setActiveMatches:A,setPendingMatches:ee,setCachedMatches:j};A(e.matches),a?.(k);function A(e){oi(e,o,_,n,i)}function ee(e){oi(e,s,v,n,i)}function j(e){oi(e,c,y,n,i)}return k}function ai(e,t){let n=[];for(let r of t){let t=e.get(r);t&&n.push(t.state)}return n}function oi(e,t,n,r,i){let a=e.map(e=>e.id),o=new Set(a);i(()=>{for(let e of t.keys())o.has(e)||t.delete(e);for(let n of e){let e=t.get(n.id);if(!e){let e=r(n);e.routeId=n.routeId,t.set(n.id,e);continue}e.routeId=n.routeId,e.state!==n&&e.setState(()=>n)}Ee(n.state,a)||n.setState(()=>a)})}var si=e=>{if(!e.rendered)return e.rendered=!0,e.onReady?.()},ci=e=>e.stores.matchesId.state.some(t=>e.stores.activeMatchStoresById.get(t)?.state._forcePending),li=(e,t)=>!!(e.preload&&!e.router.stores.activeMatchStoresById.has(t)),ui=(e,t,n=!0)=>{let r={...e.router.options.context??{}},i=n?t:t-1;for(let t=0;t<=i;t++){let n=e.matches[t];if(!n)continue;let i=e.router.getMatch(n.id);i&&Object.assign(r,i.__routeContext,i.__beforeLoadContext)}return r},di=(e,t)=>{if(!e.matches.length)return;let n=t.routeId,r=e.matches.findIndex(t=>t.routeId===e.router.routeTree.id),i=r>=0?r:0,a=n?e.matches.findIndex(e=>e.routeId===n):e.firstBadMatchIndex??e.matches.length-1;a<0&&(a=i);for(let t=a;t>=0;t--){let n=e.matches[t];if(e.router.looseRoutesById[n.routeId].options.notFoundComponent)return t}return n?a:i},fi=(e,t,n)=>{if(!(!Ne(n)&&!ke(n)))throw Ne(n)&&n.redirectHandled&&!n.options.reloadDocument?n:(t&&(t._nonReactive.beforeLoadPromise?.resolve(),t._nonReactive.loaderPromise?.resolve(),t._nonReactive.beforeLoadPromise=void 0,t._nonReactive.loaderPromise=void 0,t._nonReactive.error=n,e.updateMatch(t.id,r=>({...r,status:Ne(n)?`redirected`:r.status===`pending`?`success`:r.status,context:ui(e,t.index),isFetching:!1,error:n})),ke(n)&&!n.routeId&&(n.routeId=t.routeId),t._nonReactive.loadPromise?.resolve()),Ne(n)&&(e.rendered=!0,n.options._fromLocation=e.location,n.redirectHandled=!0,n=e.router.resolveRedirect(n)),n)},pi=(e,t)=>{let n=e.router.getMatch(t);return!!(!n||n._nonReactive.dehydrated)},mi=(e,t,n)=>{let r=ui(e,n);e.updateMatch(t,e=>({...e,context:r}))},hi=(e,t,n,r)=>{let{id:i,routeId:a}=e.matches[t],o=e.router.looseRoutesById[a];if(n instanceof Promise)throw n;n.routerCode=r,e.firstBadMatchIndex??=t,fi(e,e.router.getMatch(i),n);try{o.options.onError?.(n)}catch(t){n=t,fi(e,e.router.getMatch(i),n)}e.updateMatch(i,e=>(e._nonReactive.beforeLoadPromise?.resolve(),e._nonReactive.beforeLoadPromise=void 0,e._nonReactive.loadPromise?.resolve(),{...e,error:n,status:`error`,isFetching:!1,updatedAt:Date.now(),abortController:new AbortController})),!e.preload&&!Ne(n)&&!ke(n)&&(e.serialError??=n)},gi=(e,t,n,r)=>{if(r._nonReactive.pendingTimeout!==void 0)return;let i=n.options.pendingMs??e.router.options.defaultPendingMs;if(e.onReady&&!li(e,t)&&(n.options.loader||n.options.beforeLoad||Di(n))&&typeof i==`number`&&i!==1/0&&(n.options.pendingComponent??e.router.options?.defaultPendingComponent)){let t=setTimeout(()=>{si(e)},i);r._nonReactive.pendingTimeout=t}},_i=(e,t,n)=>{let r=e.router.getMatch(t);if(!r._nonReactive.beforeLoadPromise&&!r._nonReactive.loaderPromise)return;gi(e,t,n,r);let i=()=>{let n=e.router.getMatch(t);n.preload&&(n.status===`redirected`||n.status===`notFound`)&&fi(e,n,n.error)};return r._nonReactive.beforeLoadPromise?r._nonReactive.beforeLoadPromise.then(i):i()},vi=(e,t,n,r)=>{let i=e.router.getMatch(t),a=i._nonReactive.loadPromise;i._nonReactive.loadPromise=le(()=>{a?.resolve(),a=void 0});let{paramsError:o,searchError:s}=i;o&&hi(e,n,o,`PARSE_PARAMS`),s&&hi(e,n,s,`VALIDATE_SEARCH`),gi(e,t,r,i);let c=new AbortController,l=!1,u=()=>{l||(l=!0,e.updateMatch(t,e=>({...e,isFetching:`beforeLoad`,fetchCount:e.fetchCount+1,abortController:c})))},d=()=>{i._nonReactive.beforeLoadPromise?.resolve(),i._nonReactive.beforeLoadPromise=void 0,e.updateMatch(t,e=>({...e,isFetching:!1}))};if(!r.options.beforeLoad){e.router.batch(()=>{u(),d()});return}i._nonReactive.beforeLoadPromise=le();let f={...ui(e,n,!1),...i.__routeContext},{search:p,params:m,cause:h}=i,g=li(e,t),_={search:p,abortController:c,params:m,preload:g,context:f,location:e.location,navigate:t=>e.router.navigate({...t,_fromLocation:e.location}),buildLocation:e.router.buildLocation,cause:g?`preload`:h,matches:e.matches,routeId:r.id,...e.router.options.additionalContext},v=r=>{if(r===void 0){e.router.batch(()=>{u(),d()});return}(Ne(r)||ke(r))&&(u(),hi(e,n,r,`BEFORE_LOAD`)),e.router.batch(()=>{u(),e.updateMatch(t,e=>({...e,__beforeLoadContext:r})),d()})},y;try{if(y=r.options.beforeLoad(_),se(y))return u(),y.catch(t=>{hi(e,n,t,`BEFORE_LOAD`)}).then(v)}catch(t){u(),hi(e,n,t,`BEFORE_LOAD`)}v(y)},yi=(e,t)=>{let{id:n,routeId:r}=e.matches[t],i=e.router.looseRoutesById[r],a=()=>s(),o=()=>vi(e,n,t,i),s=()=>{if(pi(e,n))return;let t=_i(e,n,i);return se(t)?t.then(o):o()};return a()},bi=(e,t,n)=>{let r=e.router.getMatch(t);if(!r||!n.options.head&&!n.options.scripts&&!n.options.headers)return;let i={ssr:e.router.options.ssr,matches:e.matches,match:r,params:r.params,loaderData:r.loaderData};return Promise.all([n.options.head?.(i),n.options.scripts?.(i),n.options.headers?.(i)]).then(([e,t,n])=>({meta:e?.meta,links:e?.links,headScripts:e?.scripts,headers:n,scripts:t,styles:e?.styles}))},xi=(e,t,n,r,i)=>{let a=t[r-1],{params:o,loaderDeps:s,abortController:c,cause:l}=e.router.getMatch(n),u=ui(e,r),d=li(e,n);return{params:o,deps:s,preload:!!d,parentMatchPromise:a,abortController:c,context:u,location:e.location,navigate:t=>e.router.navigate({...t,_fromLocation:e.location}),cause:d?`preload`:l,route:i,...e.router.options.additionalContext}},Si=async(e,t,n,r,i)=>{try{let a=e.router.getMatch(n);try{Ei(i);let o=i.options.loader,s=typeof o==`function`?o:o?.handler,c=s?.(xi(e,t,n,r,i)),l=!!s&&se(c);if((l||i._lazyPromise||i._componentsPromise||i.options.head||i.options.scripts||i.options.headers||a._nonReactive.minPendingPromise)&&e.updateMatch(n,e=>({...e,isFetching:`loader`})),s){let t=l?await c:c;fi(e,e.router.getMatch(n),t),t!==void 0&&e.updateMatch(n,e=>({...e,loaderData:t}))}i._lazyPromise&&await i._lazyPromise;let u=a._nonReactive.minPendingPromise;u&&await u,i._componentsPromise&&await i._componentsPromise,e.updateMatch(n,t=>({...t,error:void 0,context:ui(e,r),status:`success`,isFetching:!1,updatedAt:Date.now()}))}catch(t){let o=t;if(o?.name===`AbortError`){if(a.abortController.signal.aborted){a._nonReactive.loaderPromise?.resolve(),a._nonReactive.loaderPromise=void 0;return}e.updateMatch(n,t=>({...t,status:t.status===`pending`?`success`:t.status,isFetching:!1,context:ui(e,r)}));return}let s=a._nonReactive.minPendingPromise;s&&await s,ke(t)&&await i.options.notFoundComponent?.preload?.(),fi(e,e.router.getMatch(n),t);try{i.options.onError?.(t)}catch(t){o=t,fi(e,e.router.getMatch(n),t)}!Ne(o)&&!ke(o)&&await Ei(i,[`errorComponent`]),e.updateMatch(n,t=>({...t,error:o,context:ui(e,r),status:`error`,isFetching:!1}))}}catch(t){let r=e.router.getMatch(n);r&&(r._nonReactive.loaderPromise=void 0),fi(e,r,t)}},Ci=async(e,t,n)=>{async function r(r,a,c,l,d){let f=Date.now()-a.updatedAt,p=r?d.options.preloadStaleTime??e.router.options.defaultPreloadStaleTime??3e4:d.options.staleTime??e.router.options.defaultStaleTime??0,m=d.options.shouldReload,h=typeof m==`function`?m(xi(e,t,i,n,d)):m,{status:g,invalid:_}=l,v=f>=p&&(!!e.forceStaleReload||l.cause===`enter`||c!==void 0&&c!==l.id);o=g===`success`&&(_||(h??v)),r&&d.options.preload===!1||(o&&!e.sync&&u?(s=!0,(async()=>{try{await Si(e,t,i,n,d);let r=e.router.getMatch(i);r._nonReactive.loaderPromise?.resolve(),r._nonReactive.loadPromise?.resolve(),r._nonReactive.loaderPromise=void 0,r._nonReactive.loadPromise=void 0}catch(t){Ne(t)&&await e.router.navigate(t.options)}})()):g!==`success`||o?await Si(e,t,i,n,d):mi(e,i,n))}let{id:i,routeId:a}=e.matches[n],o=!1,s=!1,c=e.router.looseRoutesById[a],l=c.options.loader,u=((typeof l==`function`?void 0:l?.staleReloadMode)??e.router.options.defaultStaleReloadMode)!==`blocking`;if(pi(e,i)){if(!e.router.getMatch(i))return e.matches[n];mi(e,i,n)}else{let t=e.router.getMatch(i),o=e.router.stores.matchesId.state[n],s=(o&&e.router.stores.activeMatchStoresById.get(o)||null)?.routeId===a?o:e.router.stores.activeMatchesSnapshot.state.find(e=>e.routeId===a)?.id,l=li(e,i);if(t._nonReactive.loaderPromise){if(t.status===`success`&&!e.sync&&!t.preload&&u)return t;await t._nonReactive.loaderPromise;let n=e.router.getMatch(i),a=n._nonReactive.error||n.error;a&&fi(e,n,a),n.status===`pending`&&await r(l,t,s,n,c)}else{let n=l&&!e.router.stores.activeMatchStoresById.has(i),a=e.router.getMatch(i);a._nonReactive.loaderPromise=le(),n!==a.preload&&e.updateMatch(i,e=>({...e,preload:n})),await r(l,t,s,a,c)}}let d=e.router.getMatch(i);s||(d._nonReactive.loaderPromise?.resolve(),d._nonReactive.loadPromise?.resolve(),d._nonReactive.loadPromise=void 0),clearTimeout(d._nonReactive.pendingTimeout),d._nonReactive.pendingTimeout=void 0,s||(d._nonReactive.loaderPromise=void 0),d._nonReactive.dehydrated=void 0;let f=s?d.isFetching:!1;return f!==d.isFetching||d.invalid!==!1?(e.updateMatch(i,e=>({...e,isFetching:f,invalid:!1})),e.router.getMatch(i)):d};async function wi(e){let t=e,n=[];ci(t.router)&&si(t);let r;for(let e=0;e({...e,...a?{status:`success`,globalNotFound:!0,error:void 0}:{status:`notFound`,error:l},isFetching:!1})),u=e,await Ei(r,[`notFoundComponent`])}else if(!t.preload){let e=t.matches[0];e.globalNotFound||t.router.getMatch(e.id)?.globalNotFound&&t.updateMatch(e.id,e=>({...e,globalNotFound:!1,error:void 0}))}if(t.serialError&&t.firstBadMatchIndex!==void 0){let e=t.router.looseRoutesById[t.matches[t.firstBadMatchIndex].routeId];await Ei(e,[`errorComponent`])}for(let e=0;e<=u;e++){let{id:n,routeId:r}=t.matches[e],i=t.router.looseRoutesById[r];try{let e=bi(t,n,i);if(e){let r=await e;t.updateMatch(n,e=>({...e,...r}))}}catch(e){console.error(`Error executing head for route ${r}:`,e)}}let d=si(t);if(se(d)&&await d,l)throw l;if(t.serialError&&!t.preload&&!t.onReady)throw t.serialError;return t.matches}function Ti(e,t){let n=t.map(t=>e.options[t]?.preload?.()).filter(Boolean);if(n.length!==0)return Promise.all(n)}function Ei(e,t=Oi){!e._lazyLoaded&&e._lazyPromise===void 0&&(e.lazyFn?e._lazyPromise=e.lazyFn().then(t=>{let{id:n,...r}=t.options;Object.assign(e.options,r),e._lazyLoaded=!0,e._lazyPromise=void 0}):e._lazyLoaded=!0);let n=()=>e._componentsLoaded?void 0:t===Oi?(()=>{if(e._componentsPromise===void 0){let t=Ti(e,Oi);t?e._componentsPromise=t.then(()=>{e._componentsLoaded=!0,e._componentsPromise=void 0}):e._componentsLoaded=!0}return e._componentsPromise})():Ti(e,t);return e._lazyPromise?e._lazyPromise.then(n):n()}function Di(e){for(let t of Oi)if(e.options[t]?.preload)return!0;return!1}var Oi=[`component`,`errorComponent`,`pendingComponent`,`notFoundComponent`],ki=`__TSR_index`,Ai=`popstate`,H=`beforeunload`;function ji(e){let t=e.getLocation(),n=new Set,r=r=>{t=e.getLocation(),n.forEach(e=>e({location:t,action:r}))},i=n=>{e.notifyOnIndexChange??!0?r(n):t=e.getLocation()},a=async({task:n,navigateOpts:r,...i})=>{if(r?.ignoreBlocker??!1){n();return}let a=e.getBlockers?.()??[],o=i.type===`PUSH`||i.type===`REPLACE`;if(typeof document<`u`&&a.length&&o)for(let n of a){let r=Fi(i.path,i.state);if(await n.blockerFn({currentLocation:t,nextLocation:r,action:i.type})){e.onBlocked?.();return}}n()};return{get location(){return t},get length(){return e.getLength()},subscribers:n,subscribe:e=>(n.add(e),()=>{n.delete(e)}),push:(n,i,o)=>{let s=t.state[ki];i=Mi(s+1,i),a({task:()=>{e.pushState(n,i),r({type:`PUSH`})},navigateOpts:o,type:`PUSH`,path:n,state:i})},replace:(n,i,o)=>{let s=t.state[ki];i=Mi(s,i),a({task:()=>{e.replaceState(n,i),r({type:`REPLACE`})},navigateOpts:o,type:`REPLACE`,path:n,state:i})},go:(t,n)=>{a({task:()=>{e.go(t),i({type:`GO`,index:t})},navigateOpts:n,type:`GO`})},back:t=>{a({task:()=>{e.back(t?.ignoreBlocker??!1),i({type:`BACK`})},navigateOpts:t,type:`BACK`})},forward:t=>{a({task:()=>{e.forward(t?.ignoreBlocker??!1),i({type:`FORWARD`})},navigateOpts:t,type:`FORWARD`})},canGoBack:()=>t.state[ki]!==0,createHref:t=>e.createHref(t),block:t=>{if(!e.setBlockers)return()=>{};let n=e.getBlockers?.()??[];return e.setBlockers([...n,t]),()=>{let n=e.getBlockers?.()??[];e.setBlockers?.(n.filter(e=>e!==t))}},flush:()=>e.flush?.(),destroy:()=>e.destroy?.(),notify:r}}function Mi(e,t){t||={};let n=Ii();return{...t,key:n,__TSR_key:n,[ki]:e}}function Ni(e){let t=e?.window??(typeof document<`u`?window:void 0),n=t.history.pushState,r=t.history.replaceState,i=[],a=()=>i,o=e=>i=e,s=e?.createHref??(e=>e),c=e?.parseLocation??(()=>Fi(`${t.location.pathname}${t.location.search}${t.location.hash}`,t.history.state));if(!t.history.state?.__TSR_key&&!t.history.state?.key){let e=Ii();t.history.replaceState({[ki]:0,key:e,__TSR_key:e},``)}let l=c(),u,d=!1,f=!1,p=!1,m=!1,h=()=>l,g,_,v=()=>{g&&(C._ignoreSubscribers=!0,(g.isPush?t.history.pushState:t.history.replaceState)(g.state,``,g.href),C._ignoreSubscribers=!1,g=void 0,_=void 0,u=void 0)},y=(e,t,n)=>{let r=s(t);_||(u=l),l=Fi(t,n),g={href:r,state:n,isPush:g?.isPush||e===`push`},_||=Promise.resolve().then(()=>v())},b=e=>{l=c(),C.notify({type:e})},x=async()=>{if(f){f=!1;return}let e=c(),n=e.state[ki]-l.state[ki],r=n===1,i=n===-1,o=!r&&!i||d;d=!1;let s=o?`GO`:i?`BACK`:`FORWARD`,u=o?{type:`GO`,index:n}:{type:i?`BACK`:`FORWARD`};if(p)p=!1;else{let n=a();if(typeof document<`u`&&n.length){for(let r of n)if(await r.blockerFn({currentLocation:l,nextLocation:e,action:s})){f=!0,t.history.go(1),C.notify(u);return}}}l=c(),C.notify(u)},S=e=>{if(m){m=!1;return}let t=!1,n=a();if(typeof document<`u`&&n.length)for(let e of n){let n=e.enableBeforeUnload??!0;if(n===!0){t=!0;break}if(typeof n==`function`&&n()===!0){t=!0;break}}if(t)return e.preventDefault(),e.returnValue=``},C=ji({getLocation:h,getLength:()=>t.history.length,pushState:(e,t)=>y(`push`,e,t),replaceState:(e,t)=>y(`replace`,e,t),back:e=>(e&&(p=!0),m=!0,t.history.back()),forward:e=>{e&&(p=!0),m=!0,t.history.forward()},go:e=>{d=!0,t.history.go(e)},createHref:e=>s(e),flush:v,destroy:()=>{t.history.pushState=n,t.history.replaceState=r,t.removeEventListener(H,S,{capture:!0}),t.removeEventListener(Ai,x)},onBlocked:()=>{u&&l!==u&&(l=u)},getBlockers:a,setBlockers:o,notifyOnIndexChange:!1});return t.addEventListener(H,S,{capture:!0}),t.addEventListener(Ai,x),t.history.pushState=function(...e){let r=n.apply(t.history,e);return C._ignoreSubscribers||b(`PUSH`),r},t.history.replaceState=function(...e){let n=r.apply(t.history,e);return C._ignoreSubscribers||b(`REPLACE`),n},C}function Pi(e){let t=e.replace(/[\x00-\x1f\x7f]/g,``);return t.startsWith(`//`)&&(t=`/`+t.replace(/^\/+/,``)),t}function Fi(e,t){let n=Pi(e),r=n.indexOf(`#`),i=n.indexOf(`?`),a=Ii();return{href:n,pathname:n.substring(0,r>0?i>0?Math.min(r,i):r:i>0?i:n.length),hash:r>-1?n.substring(r):``,search:i>-1?n.slice(i,r===-1?void 0:r):``,state:t||{[ki]:0,key:a,__TSR_key:a}}}function Ii(){return(Math.random()+1).toString(36).substring(7)}function Li(e,t){let n=t,r=e;return{fromLocation:n,toLocation:r,pathChanged:n?.pathname!==r.pathname,hrefChanged:n?.href!==r.href,hashChanged:n?.hash!==r.hash}}var Ri=class{constructor(e,t){this.tempLocationKey=`${Math.round(Math.random()*1e7)}`,this.resetNextScroll=!0,this.shouldViewTransition=void 0,this.isViewTransitionTypesSupported=void 0,this.subscribers=new Set,this.isScrollRestoring=!1,this.isScrollRestorationSetup=!1,this.startTransition=e=>e(),this.update=e=>{let t=this.options,n=this.basepath??t?.basepath??`/`,r=this.basepath===void 0,i=t?.rewrite;if(this.options={...t,...e},this.isServer=this.options.isServer??typeof document>`u`,this.protocolAllowlist=new Set(this.options.protocolAllowlist),this.options.pathParamsAllowedCharacters&&(this.pathParamsDecoder=Se(this.options.pathParamsAllowedCharacters)),(!this.history||this.options.history&&this.options.history!==this.history)&&(this.options.history?this.history=this.options.history:this.history=Ni()),this.origin=this.options.origin,this.origin||(window?.origin&&window.origin!==`null`?this.origin=window.origin:this.origin=`http://localhost`),this.history&&this.updateLatestLocation(),this.options.routeTree!==this.routeTree){this.routeTree=this.options.routeTree;let e;this.resolvePathCache=De(1e3),e=this.buildRouteTree(),this.setRoutes(e)}if(!this.stores&&this.latestLocation){let e=this.getStoreConfig(this);this.batch=e.batch,this.stores=ii(Vi(this.latestLocation),e),Kr(this)}let a=!1,o=this.options.basepath??`/`,s=this.options.rewrite;if(r||n!==o||i!==s){this.basepath=o;let e=[],t=xe(o);t&&t!==`/`&&e.push(ti({basepath:o})),s&&e.push(s),this.rewrite=e.length===0?void 0:e.length===1?e[0]:ei(e),this.history&&this.updateLatestLocation(),a=!0}a&&this.stores&&this.stores.location.setState(()=>this.latestLocation),typeof window<`u`&&`CSS`in window&&typeof window.CSS?.supports==`function`&&(this.isViewTransitionTypesSupported=window.CSS.supports(`selector(:active-view-transition-type(a)`))},this.updateLatestLocation=()=>{this.latestLocation=this.parseLocation(this.history.location,this.latestLocation)},this.buildRouteTree=()=>{let e=fe(this.routeTree,this.options.caseSensitive,(e,t)=>{e.init({originalIndex:t})});return this.options.routeMasks&&Oe(this.options.routeMasks,e.processedTree),e},this.subscribe=(e,t)=>{let n={eventType:e,fn:t};return this.subscribers.add(n),()=>{this.subscribers.delete(n)}},this.emit=e=>{this.subscribers.forEach(t=>{t.eventType===e.type&&t.fn(e)})},this.parseLocation=(e,t)=>{let n=({pathname:e,search:n,hash:r,href:i,state:a})=>{if(!this.rewrite&&!/[ \x00-\x1f\x7f\u0080-\uffff]/.test(e)){let o=this.options.parseSearch(n),s=this.options.stringifySearch(o);return{href:e+s+r,publicHref:i,pathname:re(e).path,external:!1,searchStr:s,search:F(t?.search,o),hash:re(r.slice(1)).path,state:I(t?.state,a)}}let o=new URL(i,this.origin),s=ni(this.rewrite,o),c=this.options.parseSearch(s.search),l=this.options.stringifySearch(c);return s.search=l,{href:s.href.replace(s.origin,``),publicHref:i,pathname:re(s.pathname).path,external:!!this.rewrite&&s.origin!==this.origin,searchStr:l,search:F(t?.search,c),hash:re(s.hash.slice(1)).path,state:I(t?.state,a)}},r=n(e),{__tempLocation:i,__tempKey:a}=r.state;if(i&&(!a||a===this.tempLocationKey)){let e=n(i);return e.state.key=r.state.key,e.state.__TSR_key=r.state.__TSR_key,delete e.state.__tempLocation,{...e,maskedLocation:r}}return r},this.resolvePathWithBase=(e,t)=>pe({base:e,to:be(t),trailingSlash:this.options.trailingSlash,cache:this.resolvePathCache}),this.matchRoutes=(e,t,n)=>typeof e==`string`?this.matchRoutesInternal({pathname:e,search:t},n):this.matchRoutesInternal(e,t),this.getMatchedRoutes=e=>Ui({pathname:e,routesById:this.routesById,processedTree:this.processedTree}),this.cancelMatch=e=>{let t=this.getMatch(e);t&&(t.abortController.abort(),clearTimeout(t._nonReactive.pendingTimeout),t._nonReactive.pendingTimeout=void 0)},this.cancelMatches=()=>{this.stores.pendingMatchesId.state.forEach(e=>{this.cancelMatch(e)}),this.stores.matchesId.state.forEach(e=>{if(this.stores.pendingMatchStoresById.has(e))return;let t=this.stores.activeMatchStoresById.get(e)?.state;t&&(t.status===`pending`||t.isFetching===`loader`)&&this.cancelMatch(e)})},this.buildLocation=e=>{let t=(t={})=>{let n=t._fromLocation||this.pendingBuiltLocation||this.latestLocation,r=this.matchRoutesLightweight(n);t.from;let i=t.unsafeRelative===`path`?n.pathname:t.from??r.fullPath,a=this.resolvePathWithBase(i,`.`),o=r.search,s=Object.assign(Object.create(null),r.params),c=t.to?this.resolvePathWithBase(a,`${t.to}`):this.resolvePathWithBase(a,`.`),l=t.params===!1||t.params===null?Object.create(null):(t.params??!0)===!0?s:Object.assign(s,P(t.params,s)),u=this.getMatchedRoutes(c),d=u.matchedRoutes;if((!u.foundRoute||u.foundRoute.path!==`/`&&u.routeParams[`**`])&&this.options.notFoundRoute&&(d=[...d,this.options.notFoundRoute]),Object.keys(l).length>0)for(let e of d){let t=e.options.params?.stringify??e.options.stringifyParams;if(t)try{Object.assign(l,t(l))}catch{}}let f=e.leaveParams?c:re(ye({path:c,params:l,decoder:this.pathParamsDecoder,server:this.isServer}).interpolatedPath).path,p=o;if(e._includeValidateSearch&&this.options.search?.strict){let e={};d.forEach(t=>{if(t.options.validateSearch)try{Object.assign(e,Hi(t.options.validateSearch,{...e,...p}))}catch{}}),p=e}p=Wi({search:p,dest:t,destRoutes:d,_includeValidateSearch:e._includeValidateSearch}),p=F(o,p);let m=this.options.stringifySearch(p),h=t.hash===!0?n.hash:t.hash?P(t.hash,n.hash):void 0,g=h?`#${h}`:``,_=t.state===!0?n.state:t.state?P(t.state,n.state):{};_=I(n.state,_);let v=`${f}${m}${g}`,y,b,x=!1;if(this.rewrite){let e=new URL(v,this.origin),t=ri(this.rewrite,e);y=e.href.replace(e.origin,``),t.origin===this.origin?b=t.pathname+t.search+t.hash:(b=t.href,x=!0)}else y=oe(v),b=y;return{publicHref:b,href:y,pathname:f,search:p,searchStr:m,state:_,hash:h??``,external:x,unmaskOnReload:t.unmaskOnReload}},n=(n={},r)=>{let i=t(n),a=r?t(r):void 0;if(!a){let n=Object.create(null);if(this.options.routeMasks){let o=me(i.pathname,this.processedTree);if(o){Object.assign(n,o.rawParams);let{from:i,params:s,...c}=o.route,l=s===!1||s===null?Object.create(null):(s??!0)===!0?n:Object.assign(n,P(s,n));r={from:e.from,...c,params:l},a=t(r)}}}return a&&(i.maskedLocation=a),i};return e.mask?n(e,{from:e.from,...e.mask}):n(e)},this.commitLocation=async({viewTransition:e,ignoreBlocker:t,...n})=>{let r=()=>{let e=[`key`,`__TSR_key`,`__TSR_index`,`__hashScrollIntoViewOptions`];e.forEach(e=>{n.state[e]=this.latestLocation.state[e]});let t=ne(n.state,this.latestLocation.state);return e.forEach(e=>{delete n.state[e]}),t},i=he(this.latestLocation.href)===he(n.href),a=this.commitLocationPromise;if(this.commitLocationPromise=le(()=>{a?.resolve(),a=void 0}),i&&r())this.load();else{let{maskedLocation:r,hashScrollIntoView:i,...a}=n;r&&(a={...r,state:{...r.state,__tempKey:void 0,__tempLocation:{...a,search:a.searchStr,state:{...a.state,__tempKey:void 0,__tempLocation:void 0,__TSR_key:void 0,key:void 0}}}},(a.unmaskOnReload??this.options.unmaskOnReload??!1)&&(a.state.__tempKey=this.tempLocationKey)),a.state.__hashScrollIntoViewOptions=i??this.options.defaultHashScrollIntoView??!0,this.shouldViewTransition=e,this.history[n.replace?`replace`:`push`](a.publicHref,a.state,{ignoreBlocker:t})}return this.resetNextScroll=n.resetScroll??!0,this.history.subscribers.size||this.load(),this.commitLocationPromise},this.buildAndCommitLocation=({replace:e,resetScroll:t,hashScrollIntoView:n,viewTransition:r,ignoreBlocker:i,href:a,...o}={})=>{if(a){let t=this.history.location.state.__TSR_index,n=Fi(a,{__TSR_index:e?t:t+1}),r=new URL(n.pathname,this.origin);o.to=ni(this.rewrite,r).pathname,o.search=this.options.parseSearch(n.search),o.hash=n.hash.slice(1)}let s=this.buildLocation({...o,_includeValidateSearch:!0});this.pendingBuiltLocation=s;let c=this.commitLocation({...s,viewTransition:r,replace:e,resetScroll:t,hashScrollIntoView:n,ignoreBlocker:i});return Promise.resolve().then(()=>{this.pendingBuiltLocation===s&&(this.pendingBuiltLocation=void 0)}),c},this.navigate=async({to:e,reloadDocument:t,href:n,publicHref:r,...i})=>{let a=!1;if(n)try{new URL(`${n}`),a=!0}catch{}if(a&&!t&&(t=!0),t){if(e!==void 0||!n){let t=this.buildLocation({to:e,...i});n??=t.publicHref,r??=t.publicHref}let t=!a&&r?r:n;if(_e(t,this.protocolAllowlist))return Promise.resolve();if(!i.ignoreBlocker){let e=this.history.getBlockers?.()??[];for(let t of e)if(t?.blockerFn&&await t.blockerFn({currentLocation:this.latestLocation,nextLocation:this.latestLocation,action:`PUSH`}))return Promise.resolve()}return i.replace?window.location.replace(t):window.location.href=t,Promise.resolve()}return this.buildAndCommitLocation({...i,href:n,to:e,_isNavigate:!0})},this.beforeLoad=()=>{this.cancelMatches(),this.updateLatestLocation();let e=this.matchRoutes(this.latestLocation),t=this.stores.cachedMatchesSnapshot.state.filter(t=>!e.some(e=>e.id===t.id));this.batch(()=>{this.stores.status.setState(()=>`pending`),this.stores.statusCode.setState(()=>200),this.stores.isLoading.setState(()=>!0),this.stores.location.setState(()=>this.latestLocation),this.stores.setPendingMatches(e),this.stores.setCachedMatches(t)})},this.load=async e=>{let t,n,r,i=this.stores.resolvedLocation.state??this.stores.location.state;for(r=new Promise(a=>{this.startTransition(async()=>{try{this.beforeLoad();let t=this.latestLocation,n=this.stores.resolvedLocation.state,r=Li(t,n);this.stores.redirect.state||this.emit({type:`onBeforeNavigate`,...r}),this.emit({type:`onBeforeLoad`,...r}),await wi({router:this,sync:e?.sync,forceStaleReload:i.href===t.href,matches:this.stores.pendingMatchesSnapshot.state,location:t,updateMatch:this.updateMatch,onReady:async()=>{this.startTransition(()=>{this.startViewTransition(async()=>{let e=null,t=null,n=null,r=null;this.batch(()=>{let i=this.stores.pendingMatchesSnapshot.state,a=i.length,o=this.stores.activeMatchesSnapshot.state;e=a?o.filter(e=>!this.stores.pendingMatchStoresById.has(e.id)):null;let s=new Set;for(let e of this.stores.pendingMatchStoresById.values())e.routeId&&s.add(e.routeId);let c=new Set;for(let e of this.stores.activeMatchStoresById.values())e.routeId&&c.add(e.routeId);t=a?o.filter(e=>!s.has(e.routeId)):null,n=a?i.filter(e=>!c.has(e.routeId)):null,r=a?i.filter(e=>c.has(e.routeId)):o,this.stores.isLoading.setState(()=>!1),this.stores.loadedAt.setState(()=>Date.now()),a&&(this.stores.setActiveMatches(i),this.stores.setPendingMatches([]),this.stores.setCachedMatches([...this.stores.cachedMatchesSnapshot.state,...e.filter(e=>e.status!==`error`&&e.status!==`notFound`&&e.status!==`redirected`)]),this.clearExpiredCache())});for(let[e,i]of[[t,`onLeave`],[n,`onEnter`],[r,`onStay`]])if(e)for(let t of e)this.looseRoutesById[t.routeId].options[i]?.(t)})})}})}catch(e){Ne(e)?(t=e,this.navigate({...t.options,replace:!0,ignoreBlocker:!0})):ke(e)&&(n=e);let r=t?t.status:n?404:this.stores.activeMatchesSnapshot.state.some(e=>e.status===`error`)?500:200;this.batch(()=>{this.stores.statusCode.setState(()=>r),this.stores.redirect.setState(()=>t)})}this.latestLoadPromise===r&&(this.commitLocationPromise?.resolve(),this.latestLoadPromise=void 0,this.commitLocationPromise=void 0),a()})}),this.latestLoadPromise=r,await r;this.latestLoadPromise&&r!==this.latestLoadPromise;)await this.latestLoadPromise;let a;this.hasNotFoundMatch()?a=404:this.stores.activeMatchesSnapshot.state.some(e=>e.status===`error`)&&(a=500),a!==void 0&&this.stores.statusCode.setState(()=>a)},this.startViewTransition=e=>{let t=this.shouldViewTransition??this.options.defaultViewTransition;if(this.shouldViewTransition=void 0,t&&typeof document<`u`&&`startViewTransition`in document&&typeof document.startViewTransition==`function`){let n;if(typeof t==`object`&&this.isViewTransitionTypesSupported){let r=this.latestLocation,i=this.stores.resolvedLocation.state,a=typeof t.types==`function`?t.types(Li(r,i)):t.types;if(a===!1){e();return}n={update:e,types:a}}else n=e;document.startViewTransition(n)}else e()},this.updateMatch=(e,t)=>{this.startTransition(()=>{let n=this.stores.pendingMatchStoresById.get(e);if(n){n.setState(t);return}let r=this.stores.activeMatchStoresById.get(e);if(r){r.setState(t);return}let i=this.stores.cachedMatchStoresById.get(e);if(i){let n=t(i.state);n.status===`redirected`?this.stores.cachedMatchStoresById.delete(e)&&this.stores.cachedMatchesId.setState(t=>t.filter(t=>t!==e)):i.setState(()=>n)}})},this.getMatch=e=>this.stores.cachedMatchStoresById.get(e)?.state??this.stores.pendingMatchStoresById.get(e)?.state??this.stores.activeMatchStoresById.get(e)?.state,this.invalidate=e=>{let t=t=>e?.filter?.(t)??!0?{...t,invalid:!0,...e?.forcePending||t.status===`error`||t.status===`notFound`?{status:`pending`,error:void 0}:void 0}:t;return this.batch(()=>{this.stores.setActiveMatches(this.stores.activeMatchesSnapshot.state.map(t)),this.stores.setCachedMatches(this.stores.cachedMatchesSnapshot.state.map(t)),this.stores.setPendingMatches(this.stores.pendingMatchesSnapshot.state.map(t))}),this.shouldViewTransition=!1,this.load({sync:e?.sync})},this.getParsedLocationHref=e=>e.publicHref||`/`,this.resolveRedirect=e=>{let t=e.headers.get(`Location`);if(!e.options.href||e.options._builtLocation){let t=e.options._builtLocation??this.buildLocation(e.options),n=this.getParsedLocationHref(t);e.options.href=n,e.headers.set(`Location`,n)}else if(t)try{let n=new URL(t);if(this.origin&&n.origin===this.origin){let t=n.pathname+n.search+n.hash;e.options.href=t,e.headers.set(`Location`,t)}}catch{}if(e.options.href&&!e.options._builtLocation&&_e(e.options.href,this.protocolAllowlist))throw Error(`Redirect blocked: unsafe protocol`);return e.headers.get(`Location`)||e.headers.set(`Location`,e.options.href),e},this.clearCache=e=>{let t=e?.filter;t===void 0?this.stores.setCachedMatches([]):this.stores.setCachedMatches(this.stores.cachedMatchesSnapshot.state.filter(e=>!t(e)))},this.clearExpiredCache=()=>{let e=Date.now();this.clearCache({filter:t=>{let n=this.looseRoutesById[t.routeId];if(!n.options.loader)return!0;let r=(t.preload?n.options.preloadGcTime??this.options.defaultPreloadGcTime:n.options.gcTime??this.options.defaultGcTime)??300*1e3;return t.status===`error`?!0:e-t.updatedAt>=r}})},this.loadRouteChunk=Ei,this.preloadRoute=async e=>{let t=e._builtLocation??this.buildLocation(e),n=this.matchRoutes(t,{throwOnError:!0,preload:!0,dest:e}),r=new Set([...this.stores.matchesId.state,...this.stores.pendingMatchesId.state]),i=new Set([...r,...this.stores.cachedMatchesId.state]),a=n.filter(e=>!i.has(e.id));if(a.length){let e=this.stores.cachedMatchesSnapshot.state;this.stores.setCachedMatches([...e,...a])}try{return n=await wi({router:this,matches:n,location:t,preload:!0,updateMatch:(e,t)=>{r.has(e)?n=n.map(n=>n.id===e?t(n):n):this.updateMatch(e,t)}}),n}catch(e){if(Ne(e))return e.options.reloadDocument?void 0:await this.preloadRoute({...e.options,_fromLocation:t});ke(e)||console.error(e);return}},this.matchRoute=(e,t)=>{let n={...e,to:e.to?this.resolvePathWithBase(e.from||``,e.to):void 0,params:e.params||{},leaveParams:!0},r=this.buildLocation(n);if(t?.pending&&this.stores.status.state!==`pending`)return!1;let i=(t?.pending===void 0?!this.stores.isLoading.state:t.pending)?this.latestLocation:this.stores.resolvedLocation.state||this.stores.location.state,a=Te(r.pathname,t?.caseSensitive??!1,t?.fuzzy??!1,i.pathname,this.processedTree);return!a||e.params&&!ne(a.rawParams,e.params,{partial:!0})?!1:t?.includeSearch??!0?ne(i.search,r.search,{partial:!0})?a.rawParams:!1:a.rawParams},this.hasNotFoundMatch=()=>this.stores.activeMatchesSnapshot.state.some(e=>e.status===`notFound`||e.globalNotFound),this.getStoreConfig=t,this.update({defaultPreloadDelay:50,defaultPendingMs:1e3,defaultPendingMinMs:500,context:void 0,...e,caseSensitive:e.caseSensitive??!1,notFoundMode:e.notFoundMode??`fuzzy`,stringifySearch:e.stringifySearch??Zr,parseSearch:e.parseSearch??Xr,protocolAllowlist:e.protocolAllowlist??te}),typeof document<`u`&&(self.__TSR_ROUTER__=this)}isShell(){return!!this.options.isShell}isPrerendering(){return!!this.options.isPrerendering}get state(){return this.stores.__store.state}setRoutes({routesById:e,routesByPath:t,processedTree:n}){this.routesById=e,this.routesByPath=t,this.processedTree=n;let r=this.options.notFoundRoute;r&&(r.init({originalIndex:99999999999}),this.routesById[r.id]=r)}get looseRoutesById(){return this.routesById}getParentContext(e){return e?.id?e.context??this.options.context??void 0:this.options.context??void 0}matchRoutesInternal(e,t){let n=this.getMatchedRoutes(e.pathname),{foundRoute:r,routeParams:i,parsedParams:a}=n,{matchedRoutes:o}=n,s=!1;(r?r.path!==`/`&&i[`**`]:he(e.pathname))&&(this.options.notFoundRoute?o=[...o,this.options.notFoundRoute]:s=!0);let c=s?Ki(this.options.notFoundMode,o):void 0,l=Array(o.length),u=new Map;for(let e of this.stores.activeMatchStoresById.values())e.routeId&&u.set(e.routeId,e.state);for(let n=0;nthis.navigate({...t,_fromLocation:e}),buildLocation:this.buildLocation,cause:n.cause,abortController:n.abortController,preload:!!n.preload,matches:l,routeId:r.id};n.__routeContext=r.options.context(t)??void 0}n.context={...a,...n.__routeContext,...n.__beforeLoadContext}}}return l}matchRoutesLightweight(e){let{matchedRoutes:t,routeParams:n,parsedParams:r}=this.getMatchedRoutes(e.pathname),i=ie(t),a={...e.search};for(let e of t)try{Object.assign(a,Hi(e.options.validateSearch,a))}catch{}let o=ie(this.stores.matchesId.state),s=o&&this.stores.activeMatchStoresById.get(o)?.state,c=s&&s.routeId===i.id&&s.pathname===e.pathname,l;if(c)l=s.params;else{let e=Object.assign(Object.create(null),n);for(let i of t)try{qi(i,n,r??{},e)}catch{}l=e}return{matchedRoutes:t,fullPath:i.fullPath,search:a,params:l}}},zi=class extends Error{},Bi=class extends Error{};function Vi(e){return{loadedAt:0,isLoading:!1,isTransitioning:!1,status:`idle`,resolvedLocation:void 0,location:e,matches:[],statusCode:200}}function Hi(e,t){if(e==null)return{};if(`~standard`in e){let n=e[`~standard`].validate(t);if(n instanceof Promise)throw new zi(`Async validation not supported`);if(n.issues)throw new zi(JSON.stringify(n.issues,void 0,2),{cause:n});return n.value}return`parse`in e?e.parse(t):typeof e==`function`?e(t):{}}function Ui({pathname:e,routesById:t,processedTree:n}){let r=Object.create(null),i=he(e),a,o,s=ue(i,n,!0);return s&&(a=s.route,Object.assign(r,s.rawParams),o=Object.assign(Object.create(null),s.parsedParams)),{matchedRoutes:s?.branch||[t.__root__],routeParams:r,foundRoute:a,parsedParams:o}}function Wi({search:e,dest:t,destRoutes:n,_includeValidateSearch:r}){return Gi(n)(e,t,r??!1)}function Gi(e){let t={dest:null,_includeValidateSearch:!1,middlewares:[]};for(let n of e)`search`in n.options?n.options.search?.middlewares&&t.middlewares.push(...n.options.search.middlewares):(n.options.preSearchFilters||n.options.postSearchFilters)&&t.middlewares.push(({search:e,next:t})=>{let r=e;`preSearchFilters`in n.options&&n.options.preSearchFilters&&(r=n.options.preSearchFilters.reduce((e,t)=>t(e),e));let i=t(r);return`postSearchFilters`in n.options&&n.options.postSearchFilters?n.options.postSearchFilters.reduce((e,t)=>t(e),i):i}),n.options.validateSearch&&t.middlewares.push(({search:e,next:r})=>{let i=r(e);if(!t._includeValidateSearch)return i;try{return{...i,...Hi(n.options.validateSearch,i)??void 0}}catch{return i}});t.middlewares.push(({search:e})=>{let n=t.dest;return n.search?n.search===!0?e:P(n.search,e):{}});let n=(e,t,r)=>{if(e>=r.length)return t;let i=r[e];return i({search:t,next:t=>n(e+1,t,r)})};return function(e,r,i){return t.dest=r,t._includeValidateSearch=i,n(0,e,t.middlewares)}}function Ki(e,t){if(e!==`root`)for(let e=t.length-1;e>=0;e--){let n=t[e];if(n.children)return n.id}return je}function qi(e,t,n,r){let i=e.options.params?.parse??e.options.parseParams;if(i)if(e.options.skipRouteOnParseError)for(let e in t)e in n&&(r[e]=n[e]);else{let e=i(r);Object.assign(r,e)}}function Ji(e,t){if(e)return typeof e==`string`?e:e[t]}function Yi(e){return typeof e==`string`?{href:e,crossOrigin:void 0}:e}function Xi(e){if(typeof document<`u`&&document.querySelector){let t=e.stores.location.state,n=t.state.__hashScrollIntoViewOptions??!0;if(n&&t.hash!==``){let e=document.getElementById(t.hash);e&&e.scrollIntoView(n)}}}var U=e(r(),1),W=n();function Zi(e){let t=e.errorComponent??$i;return(0,W.jsx)(Qi,{getResetKey:e.getResetKey,onCatch:e.onCatch,children:({error:n,reset:r})=>n?U.createElement(t,{error:n,reset:r}):e.children})}var Qi=class extends U.Component{constructor(...e){super(...e),this.state={error:null}}static getDerivedStateFromProps(e){return{resetKey:e.getResetKey()}}static getDerivedStateFromError(e){return{error:e}}reset(){this.setState({error:null})}componentDidUpdate(e,t){t.error&&t.resetKey!==this.state.resetKey&&this.reset()}componentDidCatch(e,t){this.props.onCatch&&this.props.onCatch(e,t)}render(){return this.props.children({error:this.state.resetKey===this.props.getResetKey()?this.state.error:null,reset:()=>{this.reset()}})}};function $i({error:e}){let[t,n]=U.useState(!1);return(0,W.jsxs)(`div`,{style:{padding:`.5rem`,maxWidth:`100%`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`.5rem`},children:[(0,W.jsx)(`strong`,{style:{fontSize:`1rem`},children:`Something went wrong!`}),(0,W.jsx)(`button`,{style:{appearance:`none`,fontSize:`.6em`,border:`1px solid currentColor`,padding:`.1rem .2rem`,fontWeight:`bold`,borderRadius:`.25rem`},onClick:()=>n(e=>!e),children:t?`Hide Error`:`Show Error`})]}),(0,W.jsx)(`div`,{style:{height:`.25rem`}}),t?(0,W.jsx)(`div`,{children:(0,W.jsx)(`pre`,{style:{fontSize:`.7em`,border:`1px solid red`,borderRadius:`.25rem`,padding:`.3rem`,color:`red`,overflow:`auto`},children:e.message?(0,W.jsx)(`code`,{children:e.message}):null})}):null]})}var ea=(e=>(e[e.None=0]=`None`,e[e.Mutable=1]=`Mutable`,e[e.Watching=2]=`Watching`,e[e.RecursedCheck=4]=`RecursedCheck`,e[e.Recursed=8]=`Recursed`,e[e.Dirty=16]=`Dirty`,e[e.Pending=32]=`Pending`,e))(ea||{});function ta({update:e,notify:t,unwatched:n}){return{link:r,unlink:i,propagate:a,checkDirty:o,shallowPropagate:s};function r(e,t,n){let r=t.depsTail;if(r!==void 0&&r.dep===e)return;let i=r===void 0?t.deps:r.nextDep;if(i!==void 0&&i.dep===e){i.version=n,t.depsTail=i;return}let a=e.subsTail;if(a!==void 0&&a.version===n&&a.sub===t)return;let o=t.depsTail=e.subsTail={version:n,dep:e,sub:t,prevDep:r,nextDep:i,prevSub:a,nextSub:void 0};i!==void 0&&(i.prevDep=o),r===void 0?t.deps=o:r.nextDep=o,a===void 0?e.subs=o:a.nextSub=o}function i(e,t=e.sub){let r=e.dep,i=e.prevDep,a=e.nextDep,o=e.nextSub,s=e.prevSub;return a===void 0?t.depsTail=i:a.prevDep=i,i===void 0?t.deps=a:i.nextDep=a,o===void 0?r.subsTail=s:o.prevSub=s,s===void 0?(r.subs=o)===void 0&&n(r):s.nextSub=o,a}function a(e){let n=e.nextSub,r;top:do{let i=e.sub,a=i.flags;if(a&60?a&12?a&4?!(a&48)&&c(e,i)?(i.flags=a|40,a&=1):a=0:i.flags=a&-9|32:a=0:i.flags=a|32,a&2&&t(i),a&1){let t=i.subs;if(t!==void 0){let i=(e=t).nextSub;i!==void 0&&(r={value:n,prev:r},n=i);continue}}if((e=n)!==void 0){n=e.nextSub;continue}for(;r!==void 0;)if(e=r.value,r=r.prev,e!==void 0){n=e.nextSub;continue top}break}while(!0)}function o(t,n){let r,i=0,a=!1;top:do{let o=t.dep,c=o.flags;if(n.flags&16)a=!0;else if((c&17)==17){if(e(o)){let e=o.subs;e.nextSub!==void 0&&s(e),a=!0}}else if((c&33)==33){(t.nextSub!==void 0||t.prevSub!==void 0)&&(r={value:t,prev:r}),t=o.deps,n=o,++i;continue}if(!a){let e=t.nextDep;if(e!==void 0){t=e;continue}}for(;i--;){let i=n.subs,o=i.nextSub!==void 0;if(o?(t=r.value,r=r.prev):t=i,a){if(e(n)){o&&s(i),n=t.sub;continue}a=!1}else n.flags&=-33;n=t.sub;let c=t.nextDep;if(c!==void 0){t=c;continue top}}return a}while(!0)}function s(e){do{let n=e.sub,r=n.flags;(r&48)==32&&(n.flags=r|16,(r&6)==2&&t(n))}while((e=e.nextSub)!==void 0)}function c(e,t){let n=t.depsTail;for(;n!==void 0;){if(n===e)return!0;n=n.prevDep}return!1}}function na(e,t,n){let r=typeof e==`object`,i=r?e:void 0;return{next:(r?e.next:e)?.bind(i),error:(r?e.error:t)?.bind(i),complete:(r?e.complete:n)?.bind(i)}}var ra=[],ia=0,{link:aa,unlink:oa,propagate:sa,checkDirty:ca,shallowPropagate:la}=ta({update(e){return e._update()},notify(e){ra[da++]=e,e.flags&=~ea.Watching},unwatched(e){e.depsTail!==void 0&&(e.depsTail=void 0,e.flags=ea.Mutable|ea.Dirty,ha(e))}}),ua=0,da=0,fa,pa=0;function ma(e){try{++pa,e()}finally{--pa||ga()}}function ha(e){let t=e.depsTail,n=t===void 0?e.deps:t.nextDep;for(;n!==void 0;)n=oa(n,e)}function ga(){if(!(pa>0)){for(;ua{i.get(),n.current?t.next?.(i._snapshot):n.current=!0});return{unsubscribe:()=>{r.stop()}}},_update(e){let a=fa,o=t?.compare??Object.is;if(n)fa=i,++ia,i.depsTail=void 0;else if(e===void 0)return!1;n&&(i.flags=ea.Mutable|ea.RecursedCheck);try{let t=i._snapshot,a=typeof e==`function`?e(t):e===void 0&&n?r(t):e;return t===void 0||!o(t,a)?(i._snapshot=a,!0):!1}finally{fa=a,n&&(i.flags&=~ea.RecursedCheck),ha(i)}}};return n?(i.flags=ea.Mutable|ea.Dirty,i.get=function(){let e=i.flags;if(e&ea.Dirty||e&ea.Pending&&ca(i.deps,i)){if(i._update()){let e=i.subs;e!==void 0&&la(e)}}else e&ea.Pending&&(i.flags=e&~ea.Pending);return fa!==void 0&&aa(i,fa,ia),i._snapshot}):i.set=function(e){if(i._update(e)){let e=i.subs;e!==void 0&&(sa(e),la(e),ga())}},i}function va(e){let t=()=>{let t=fa;fa=n,++ia,n.depsTail=void 0,n.flags=ea.Watching|ea.RecursedCheck;try{return e()}finally{fa=t,n.flags&=~ea.RecursedCheck,ha(n)}},n={deps:void 0,depsTail:void 0,subs:void 0,subsTail:void 0,flags:ea.Watching|ea.RecursedCheck,notify(){let e=this.flags;e&ea.Dirty||e&ea.Pending&&ca(this.deps,this)?t():this.flags=ea.Watching},stop(){this.flags=ea.None,this.depsTail=void 0,ha(this)}};return t(),n}var ya=class{constructor(e){this.atom=_a(e)}setState(e){this.atom.set(e)}get state(){return this.atom.get()}get(){return this.state}subscribe(e){return this.atom.subscribe(na(e))}},ba=class{constructor(e){this.atom=_a(e)}get state(){return this.atom.get()}get(){return this.state}subscribe(e){return this.atom.subscribe(na(e))}};function xa(e){return typeof e==`function`?new ba(e):new ya(e)}function Sa(e){let t=N(),n=`not-found-${Ce(t.stores.location,e=>e.pathname)}-${Ce(t.stores.status,e=>e)}`;return(0,W.jsx)(Zi,{getResetKey:()=>n,onCatch:(t,n)=>{if(ke(t))e.onCatch?.(t,n);else throw t},errorComponent:({error:t})=>{if(ke(t))return e.fallback?.(t);throw t},children:e.children})}function Ca(){return(0,W.jsx)(`p`,{children:`Not Found`})}function wa(e){return(0,W.jsx)(W.Fragment,{children:e.children})}function Ta(e,t,n){return t.options.notFoundComponent?(0,W.jsx)(t.options.notFoundComponent,{...n}):e.options.defaultNotFoundComponent?(0,W.jsx)(e.options.defaultNotFoundComponent,{...n}):(0,W.jsx)(Ca,{})}var Ea=U.memo(function({matchId:e}){let t=N(),n=t.stores.activeMatchStoresById.get(e);n||ce();let r=Ce(t.stores.loadedAt,e=>e),i=Ce(n,e=>e);return(0,W.jsx)(Da,{router:t,matchId:e,resetKey:r,matchState:U.useMemo(()=>{let e=i.routeId,n=t.routesById[e].parentRoute?.id;return{routeId:e,ssr:i.ssr,_displayPending:i._displayPending,parentRouteId:n}},[i._displayPending,i.routeId,i.ssr,t.routesById])})});function Da({router:e,matchId:t,resetKey:n,matchState:r}){let i=e.routesById[r.routeId],a=i.options.pendingComponent??e.options.defaultPendingComponent,o=a?(0,W.jsx)(a,{}):null,s=i.options.errorComponent??e.options.defaultErrorComponent,c=i.options.onCatch??e.options.defaultOnCatch,l=i.isRoot?i.options.notFoundComponent??e.options.notFoundRoute?.options.component:i.options.notFoundComponent,u=r.ssr===!1||r.ssr===`data-only`,d=(!i.isRoot||i.options.wrapInSuspense||u)&&(i.options.wrapInSuspense??a??(i.options.errorComponent?.preload||u))?U.Suspense:wa,f=s?Zi:wa,p=l?Sa:wa;return(0,W.jsxs)(i.isRoot?i.options.shellComponent??wa:wa,{children:[(0,W.jsx)(Ae.Provider,{value:t,children:(0,W.jsx)(d,{fallback:o,children:(0,W.jsx)(f,{getResetKey:()=>n,errorComponent:s||$i,onCatch:(e,t)=>{if(ke(e))throw e;c?.(e,t)},children:(0,W.jsx)(p,{fallback:e=>{if(!l||e.routeId&&e.routeId!==r.routeId||!e.routeId&&!i.isRoot)throw e;return U.createElement(l,e)},children:u||r._displayPending?(0,W.jsx)(ge,{fallback:o,children:(0,W.jsx)(ka,{matchId:t})}):(0,W.jsx)(ka,{matchId:t})})})})}),r.parentRouteId===`__root__`?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(Oa,{resetKey:n}),(e.options.scrollRestoration,null)]}):null]})}function Oa({resetKey:e}){let t=N(),n=U.useRef(void 0);return j(()=>{let e=t.latestLocation.href;(n.current===void 0||n.current!==e)&&(t.emit({type:`onRendered`,...Li(t.stores.location.state,t.stores.resolvedLocation.state)}),n.current=e)},[t.latestLocation.state.__TSR_key,e,t]),null}var ka=U.memo(function({matchId:e}){let t=N(),n=t.stores.activeMatchStoresById.get(e);n||ce();let r=Ce(n,e=>e),i=r.routeId,a=t.routesById[i],o=U.useMemo(()=>{let e=(t.routesById[i].options.remountDeps??t.options.defaultRemountDeps)?.({routeId:i,loaderDeps:r.loaderDeps,params:r._strictParams,search:r._strictSearch});return e?JSON.stringify(e):void 0},[i,r.loaderDeps,r._strictParams,r._strictSearch,t.options.defaultRemountDeps,t.routesById]),s=U.useMemo(()=>{let e=a.options.component??t.options.defaultComponent;return e?(0,W.jsx)(e,{},o):(0,W.jsx)(Aa,{})},[o,a.options.component,t.options.defaultComponent]);if(r._displayPending)throw t.getMatch(r.id)?._nonReactive.displayPendingPromise;if(r._forcePending)throw t.getMatch(r.id)?._nonReactive.minPendingPromise;if(r.status===`pending`){let e=a.options.pendingMinMs??t.options.defaultPendingMinMs;if(e){let n=t.getMatch(r.id);if(n&&!n._nonReactive.minPendingPromise){let t=le();n._nonReactive.minPendingPromise=t,setTimeout(()=>{t.resolve(),n._nonReactive.minPendingPromise=void 0},e)}}throw t.getMatch(r.id)?._nonReactive.loadPromise}if(r.status===`notFound`)return ke(r.error)||ce(),Ta(t,a,r.error);if(r.status===`redirected`)throw Ne(r.error)||ce(),t.getMatch(r.id)?._nonReactive.loadPromise;if(r.status===`error`)throw r.error;return s}),Aa=U.memo(function(){let e=N(),t=U.useContext(Ae),n,r=!1,i;{let a=t?e.stores.activeMatchStoresById.get(t):void 0;[n,r]=Ce(a,e=>[e?.routeId,e?.globalNotFound??!1]),i=Ce(e.stores.matchesId,e=>e[e.findIndex(e=>e===t)+1])}let a=n?e.routesById[n]:void 0,o=e.options.defaultPendingComponent?(0,W.jsx)(e.options.defaultPendingComponent,{}):null;if(r)return a||ce(),Ta(e,a,void 0);if(!i)return null;let s=(0,W.jsx)(Ea,{matchId:i});return n===`__root__`?(0,W.jsx)(U.Suspense,{fallback:o,children:s}):s});function ja(){let e=N(),t=U.useRef({router:e,mounted:!1}),[n,r]=U.useState(!1),i=Ce(e.stores.isLoading,e=>e),a=Ce(e.stores.hasPendingMatches,e=>e),o=M(i),s=i||n||a,c=M(s),l=i||a,u=M(l);return e.startTransition=e=>{r(!0),U.startTransition(()=>{e(),r(!1)})},U.useEffect(()=>{let t=e.history.subscribe(e.load),n=e.buildLocation({to:e.latestLocation.pathname,search:!0,params:!0,hash:!0,state:!0,_includeValidateSearch:!0});return he(e.latestLocation.publicHref)!==he(n.publicHref)&&e.commitLocation({...n,replace:!0}),()=>{t()}},[e,e.history]),j(()=>{typeof window<`u`&&e.ssr||t.current.router===e&&t.current.mounted||(t.current={router:e,mounted:!0},(async()=>{try{await e.load()}catch(e){console.error(e)}})())},[e]),j(()=>{o&&!i&&e.emit({type:`onLoad`,...Li(e.stores.location.state,e.stores.resolvedLocation.state)})},[o,e,i]),j(()=>{u&&!l&&e.emit({type:`onBeforeRouteMount`,...Li(e.stores.location.state,e.stores.resolvedLocation.state)})},[l,u,e]),j(()=>{if(c&&!s){let t=Li(e.stores.location.state,e.stores.resolvedLocation.state);e.emit({type:`onResolved`,...t}),ma(()=>{e.stores.status.setState(()=>`idle`),e.stores.resolvedLocation.setState(()=>e.stores.location.state)}),t.hrefChanged&&Xi(e)}},[s,c,e]),null}function Ma(){let e=N(),t=e.routesById.__root__.options.pendingComponent??e.options.defaultPendingComponent,n=t?(0,W.jsx)(t,{}):null,r=(0,W.jsxs)(typeof document<`u`&&e.ssr?wa:U.Suspense,{fallback:n,children:[(0,W.jsx)(ja,{}),(0,W.jsx)(Na,{})]});return e.options.InnerWrap?(0,W.jsx)(e.options.InnerWrap,{children:r}):r}function Na(){let e=N(),t=Ce(e.stores.firstMatchId,e=>e),n=Ce(e.stores.loadedAt,e=>e),r=t?(0,W.jsx)(Ea,{matchId:t}):null;return(0,W.jsx)(Ae.Provider,{value:t,children:e.options.disableGlobalCatchBoundary?r:(0,W.jsx)(Zi,{getResetKey:()=>n,errorComponent:$i,onCatch:void 0,children:r})})}var Pa=e=>({createMutableStore:xa,createReadonlyStore:xa,batch:ma}),Fa=e=>new Ia(e),Ia=class extends Ri{constructor(e){super(e,Pa)}};function La({router:e,children:t,...n}){Object.keys(n).length>0&&e.update({...e.options,...n,context:{...e.options.context,...n.context}});let r=(0,W.jsx)(ee.Provider,{value:e,children:t});return e.options.Wrap?(0,W.jsx)(e.options.Wrap,{children:r}):r}function Ra({router:e,...t}){return(0,W.jsx)(La,{router:e,...t,children:(0,W.jsx)(Ma,{})})}function za(e){let t=N(),n=(0,U.useRef)(void 0);return Ce(t.stores.location,r=>{let i=e?.select?e.select(r):r;if(e?.structuralSharing??t.options.defaultStructuralSharing){let e=I(n.current,i);return n.current=e,e}return i})}function Ba({tag:e,attrs:t,children:n,nonce:r}){switch(e){case`title`:return(0,W.jsx)(`title`,{...t,suppressHydrationWarning:!0,children:n});case`meta`:return(0,W.jsx)(`meta`,{...t,suppressHydrationWarning:!0});case`link`:return(0,W.jsx)(`link`,{...t,nonce:r,suppressHydrationWarning:!0});case`style`:return(0,W.jsx)(`style`,{...t,dangerouslySetInnerHTML:{__html:n},nonce:r});case`script`:return(0,W.jsx)(Va,{attrs:t,children:n});default:return null}}function Va({attrs:e,children:t}){N();let n=de(),r=typeof e?.type==`string`&&e.type!==``&&e.type!==`text/javascript`&&e.type!==`module`;if(U.useEffect(()=>{if(!r){if(e?.src){let t=(()=>{try{let t=document.baseURI||window.location.href;return new URL(e.src,t).href}catch{return e.src}})();if(Array.from(document.querySelectorAll(`script[src]`)).find(e=>e.src===t))return;let n=document.createElement(`script`);for(let[t,r]of Object.entries(e))t!==`suppressHydrationWarning`&&r!==void 0&&r!==!1&&n.setAttribute(t,typeof r==`boolean`?``:String(r));return document.head.appendChild(n),()=>{n.parentNode&&n.parentNode.removeChild(n)}}if(typeof t==`string`){let n=typeof e?.type==`string`?e.type:`text/javascript`,r=typeof e?.nonce==`string`?e.nonce:void 0;if(Array.from(document.querySelectorAll(`script:not([src])`)).find(e=>{if(!(e instanceof HTMLScriptElement))return!1;let i=e.getAttribute(`type`)??`text/javascript`,a=e.getAttribute(`nonce`)??void 0;return e.textContent===t&&i===n&&a===r}))return;let i=document.createElement(`script`);if(i.textContent=t,e)for(let[t,n]of Object.entries(e))t!==`suppressHydrationWarning`&&n!==void 0&&n!==!1&&i.setAttribute(t,typeof n==`boolean`?``:String(n));return document.head.appendChild(i),()=>{i.parentNode&&i.parentNode.removeChild(i)}}}},[e,t,r]),r&&typeof t==`string`)return(0,W.jsx)(`script`,{...e,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:t}});if(!n){if(e?.src)return(0,W.jsx)(`script`,{...e,suppressHydrationWarning:!0});if(typeof t==`string`)return(0,W.jsx)(`script`,{...e,dangerouslySetInnerHTML:{__html:t},suppressHydrationWarning:!0})}return null}var Ha=e=>{let t=N(),n=t.options.ssr?.nonce,r=Ce(t.stores.activeMatchesSnapshot,e=>e.map(e=>e.meta).filter(Boolean),ne),i=U.useMemo(()=>{let e=[],t={},i;for(let a=r.length-1;a>=0;a--){let o=r[a];for(let r=o.length-1;r>=0;r--){let a=o[r];if(a)if(a.title)i||={tag:`title`,children:a.title};else if(`script:ld+json`in a)try{let t=JSON.stringify(a[`script:ld+json`]);e.push({tag:`script`,attrs:{type:`application/ld+json`},children:ve(t)})}catch{}else{let r=a.name??a.property;if(r){if(t[r])continue;t[r]=!0}e.push({tag:`meta`,attrs:{...a,nonce:n}})}}}return i&&e.push(i),n&&e.push({tag:`meta`,attrs:{property:`csp-nonce`,content:n}}),e.reverse(),e},[r,n]),a=Ce(t.stores.activeMatchesSnapshot,r=>{let i=r.map(e=>e.links).filter(Boolean).flat(1).map(e=>({tag:`link`,attrs:{...e,nonce:n}})),a=t.ssr?.manifest,o=r.map(e=>a?.routes[e.routeId]?.assets??[]).filter(Boolean).flat(1).filter(e=>e.tag===`link`).map(t=>({tag:`link`,attrs:{...t.attrs,crossOrigin:Ji(e,`stylesheet`)??t.attrs?.crossOrigin,suppressHydrationWarning:!0,nonce:n}}));return[...i,...o]},ne),o=Ce(t.stores.activeMatchesSnapshot,r=>{let i=[];return r.map(e=>t.looseRoutesById[e.routeId]).forEach(r=>t.ssr?.manifest?.routes[r.id]?.preloads?.filter(Boolean).forEach(t=>{let r=Yi(t);i.push({tag:`link`,attrs:{rel:`modulepreload`,href:r.href,crossOrigin:Ji(e,`modulepreload`)??r.crossOrigin,nonce:n}})})),i},ne),s=Ce(t.stores.activeMatchesSnapshot,e=>e.map(e=>e.styles).flat(1).filter(Boolean).map(({children:e,...t})=>({tag:`style`,attrs:{...t,nonce:n},children:e})),ne),c=Ce(t.stores.activeMatchesSnapshot,e=>e.map(e=>e.headScripts).flat(1).filter(Boolean).map(({children:e,...t})=>({tag:`script`,attrs:{...t,nonce:n},children:e})),ne);return Ua([...i,...o,...a,...s,...c],e=>JSON.stringify(e))};function Ua(e,t){let n=new Set;return e.filter(e=>{let r=t(e);return n.has(r)?!1:(n.add(r),!0)})}function Wa(e){let t=Ha(e.assetCrossOrigin),n=N().options.ssr?.nonce;return(0,W.jsx)(W.Fragment,{children:t.map(e=>(0,U.createElement)(Ba,{...e,key:`tsr-meta-${JSON.stringify(e)}`,nonce:n}))})}var Ga=t((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0>>1,a=e[r];if(0>>1;ri(c,n))li(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(li(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m)if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&ee(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-Tt&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&ee(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function ee(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,ee(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),Ka=t(((e,t)=>{t.exports=Ga()})),qa=t((e=>{var t=Ka(),n=r(),i=Le();function a(e){var t=`https://react.dev/errors/`+e;if(1re||(e.current=ne[re],ne[re]=null,re--)}function I(e,t){re++,ne[re]=e.current,e.current=t}var ae=ie(null),oe=ie(null),se=ie(null),ce=ie(null);function le(e,t){switch(I(se,t),I(oe,e),I(ae,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Vd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Vd(t),e=Hd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}F(ae),I(ae,e)}function ue(){F(ae),F(oe),F(se)}function de(e){e.memoizedState!==null&&I(ce,e);var t=ae.current,n=Hd(t,e.type);t!==n&&(I(oe,e),I(ae,n))}function fe(e){oe.current===e&&(F(ae),F(oe)),ce.current===e&&(F(ce),Qf._currentValue=te)}var pe,me;function he(e){if(pe===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);pe=t&&t[1]||``,me=-1i.map(i=>d[i]); +import{a as e,i as t,n,r,t as i}from"./compiler-runtime.js";import{C as a,M as o,O as s,S as c,T as l,_ as u,a as d,b as f,c as p,d as m,f as h,g,h as _,i as v,j as y,k as b,m as x,n as S,o as C,p as w,r as T,s as E,t as D,w as O,x as k,y as A}from"./QueryClientProvider.js";import{A as ee,C as te,D as j,E as M,F as N,I as ne,L as re,M as ie,N as ae,O as P,R as F,S as oe,T as se,U as ce,W as le,_ as ue,a as de,b as fe,c as pe,d as me,f as he,h as ge,i as _e,j as ve,k as ye,l as be,m as xe,o as Se,s as Ce,t as we,v as Te,w as I,x as Ee,y as De,z as Oe}from"./useStore.js";import{i as ke,n as Ae,r as je}from"./matchContext.js";import{n as Me,t as Ne}from"./redirect.js";import{t as Pe}from"./link.js";import{n as L,r as Fe,t as R}from"./lazyRouteComponent.js";import{t as Ie}from"./useNavigate.js";import{Ut as z,Xt as Le,t as Re}from"./awsClient.js";import{g as ze,i as Be,l as Ve,m as He,n as Ue,o as We,p as Ge,t as Ke}from"./dist.js";import{F as qe,I as Je,P as Ye,S as Xe,c as Ze,l as Qe,t as $e,x as et}from"./SignatureV4.js";import{t as tt}from"./createLucideIcon.js";import{C as nt,T as rt,_ as B,c as it,d as at,f as ot,g as st,h as ct,i as lt,l as ut,m as dt,n as ft,o as pt,p as mt,r as ht,s as gt,t as _t,u as vt,v as yt,w as bt,x as xt,y as St}from"./button.js";import{a as Ct,c as wt,i as Tt,n as Et,r as Dt,s as Ot,t as kt}from"./separator.js";import{B as At,H as jt,L as Mt,N as Nt,R as Pt,S as Ft,T as It,V as Lt,_ as Rt,f as zt,g as Bt,i as Vt,p as Ht,r as Ut,s as Wt,t as Gt,u as Kt,v as qt,w as Jt,y as Yt}from"./createBaseUIEventDetails.js";import{a as Xt,l as Zt,n as Qt,t as $t}from"./useTransitionStatus.js";import{$ as en,C as tn,D as nn,E as rn,G as an,H as on,J as sn,K as cn,O as ln,Q as un,U as dn,W as fn,X as pn,Y as mn,Z as hn,_ as gn,a as _n,at as vn,b as yn,c as bn,et as xn,g as Sn,h as V,ht as Cn,i as wn,it as Tn,j as En,k as Dn,l as On,lt as kn,m as An,mt as jn,nt as Mn,o as Nn,ot as Pn,p as Fn,pt as In,q as Ln,r as Rn,rt as zn,s as Bn,st as Vn,t as Hn,tt as Un,u as Wn,v as Gn,x as Kn,y as qn}from"./useOpenInteractionType.js";import{_ as Jn,a as Yn,b as Xn,c as Zn,d as Qn,f as $n,g as er,h as tr,i as nr,l as rr,m as ir,n as ar,o as or,p as sr,r as cr,s as lr,t as ur,u as dr,v as fr,x as pr,y as mr}from"./ec22.js";import{a as hr,i as gr,n as _r,o as vr,r as yr,s as br,t as xr}from"./iam2.js";import{n as Sr,t as Cr}from"./s32.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var wr=class extends T{#e;#t;#n;#r;#i;#a;#o;constructor(e){super(),this.#o=!1,this.#a=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.#r=e.client,this.#n=this.#r.getQueryCache(),this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#e=Dr(this.options),this.state=e.state??this.#e,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#i?.promise}setOptions(e){if(this.options={...this.#a,...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){let e=Dr(this.options);e.data!==void 0&&(this.setState(Er(e.data,e.dataUpdatedAt)),this.#e=e)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus===`idle`&&this.#n.remove(this)}setData(e,t){let n=a(this.state.data,e,this.options);return this.#c({data:n,type:`success`,dataUpdatedAt:t?.updatedAt,manual:t?.manual}),n}setState(e,t){this.#c({type:`setState`,state:e,setStateOptions:t})}cancel(e){let t=this.#i?.promise;return this.#i?.cancel(e),t?t.then(k).catch(k):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return this.#e}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(e=>O(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===s||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>l(e.options.staleTime,this)===`static`):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e===`static`?!1:this.state.isInvalidated?!0:!b(this.state.dataUpdatedAt,e)}onFocus(){this.observers.find(e=>e.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#i?.continue()}onOnline(){this.observers.find(e=>e.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#i?.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.#n.notify({type:`observerAdded`,query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(this.#i&&(this.#o||this.#s()?this.#i.cancel({revert:!0}):this.#i.cancelRetry()),this.scheduleGc()),this.#n.notify({type:`observerRemoved`,query:this,observer:e}))}getObserversCount(){return this.observers.length}#s(){return this.state.fetchStatus===`paused`&&this.state.status===`pending`}invalidate(){this.state.isInvalidated||this.#c({type:`invalidate`})}async fetch(e,t){if(this.state.fetchStatus!==`idle`&&this.#i?.status()!==`rejected`){if(this.state.data!==void 0&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#i)return this.#i.continueRetry(),this.#i.promise}if(e&&this.setOptions(e),!this.options.queryFn){let e=this.observers.find(e=>e.options.queryFn);e&&this.setOptions(e.options)}let n=new AbortController,r=e=>{Object.defineProperty(e,`signal`,{enumerable:!0,get:()=>(this.#o=!0,n.signal)})},i=()=>{let e=x(this.options,t),n=(()=>{let e={client:this.#r,queryKey:this.queryKey,meta:this.meta};return r(e),e})();return this.#o=!1,this.options.persister?this.options.persister(e,n,this):e(n)},a=(()=>{let e={fetchOptions:t,options:this.options,queryKey:this.queryKey,client:this.#r,state:this.state,fetchFn:i};return r(e),e})();this.options.behavior?.onFetch(a,this),this.#t=this.state,(this.state.fetchStatus===`idle`||this.state.fetchMeta!==a.fetchOptions?.meta)&&this.#c({type:`fetch`,meta:a.fetchOptions?.meta}),this.#i=C({initialPromise:t?.initialPromise,fn:a.fetchFn,onCancel:e=>{e instanceof v&&e.revert&&this.setState({...this.#t,fetchStatus:`idle`}),n.abort()},onFail:(e,t)=>{this.#c({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#c({type:`pause`})},onContinue:()=>{this.#c({type:`continue`})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0});try{let e=await this.#i.start();if(e===void 0)throw Error(`${this.queryHash} data is undefined`);return this.setData(e),this.#n.config.onSuccess?.(e,this),this.#n.config.onSettled?.(e,this.state.error,this),e}catch(e){if(e instanceof v){if(e.silent)return this.#i.promise;if(e.revert){if(this.state.data===void 0)throw e;return this.state.data}}throw this.#c({type:`error`,error:e}),this.#n.config.onError?.(e,this),this.#n.config.onSettled?.(this.state.data,e,this),e}finally{this.scheduleGc()}}#c(e){this.state=(t=>{switch(e.type){case`failed`:return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case`pause`:return{...t,fetchStatus:`paused`};case`continue`:return{...t,fetchStatus:`fetching`};case`fetch`:return{...t,...Tr(t.data,this.options),fetchMeta:e.meta??null};case`success`:let n={...t,...Er(e.data,e.dataUpdatedAt),dataUpdateCount:t.dataUpdateCount+1,...!e.manual&&{fetchStatus:`idle`,fetchFailureCount:0,fetchFailureReason:null}};return this.#t=e.manual?n:void 0,n;case`error`:let r=e.error;return{...t,error:r,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:r,fetchStatus:`idle`,status:`error`,isInvalidated:!0};case`invalidate`:return{...t,isInvalidated:!0};case`setState`:return{...t,...e.state}}})(this.state),p.batch(()=>{this.observers.forEach(e=>{e.onQueryUpdate()}),this.#n.notify({query:this,type:`updated`,action:e})})}};function Tr(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:d(t.networkMode)?`fetching`:`paused`,...e===void 0&&{error:null,status:`pending`}}}function Er(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:`success`}}function Dr(e){let t=typeof e.initialData==`function`?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt==`function`?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?`success`:`pending`,fetchStatus:`idle`}}function Or(e){return{onFetch:(t,n)=>{let r=t.options,i=t.fetchOptions?.meta?.fetchMore?.direction,a=t.state.data?.pages||[],o=t.state.data?.pageParams||[],s={pages:[],pageParams:[]},c=0,l=async()=>{let n=!1,l=e=>{m(e,()=>t.signal,()=>n=!0)},u=x(t.options,t.fetchOptions),d=async(e,r,i)=>{if(n)return Promise.reject();if(r==null&&e.pages.length)return Promise.resolve(e);let a=await u((()=>{let e={client:t.client,queryKey:t.queryKey,pageParam:r,direction:i?`backward`:`forward`,meta:t.options.meta};return l(e),e})()),{maxPages:o}=t.options,s=i?w:h;return{pages:s(e.pages,a,o),pageParams:s(e.pageParams,r,o)}};if(i&&a.length){let e=i===`backward`,t=e?Ar:kr,n={pages:a,pageParams:o};s=await d(n,t(r,n),e)}else{let t=e??a.length;do{let e=c===0?o[0]??r.initialPageParam:kr(r,s);if(c>0&&e==null)break;s=await d(s,e),c++}while(ct.options.persister?.(l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n):t.fetchFn=l}}}function kr(e,{pages:t,pageParams:n}){let r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function Ar(e,{pages:t,pageParams:n}){return t.length>0?e.getPreviousPageParam?.(t[0],t,n[0],n):void 0}var jr=class extends T{#e;#t;#n;#r;constructor(e){super(),this.#e=e.client,this.mutationId=e.mutationId,this.#n=e.mutationCache,this.#t=[],this.state=e.state||Mr(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#t.includes(e)||(this.#t.push(e),this.clearGcTimeout(),this.#n.notify({type:`observerAdded`,mutation:this,observer:e}))}removeObserver(e){this.#t=this.#t.filter(t=>t!==e),this.scheduleGc(),this.#n.notify({type:`observerRemoved`,mutation:this,observer:e})}optionalRemove(){this.#t.length||(this.state.status===`pending`?this.scheduleGc():this.#n.remove(this))}continue(){return this.#r?.continue()??this.execute(this.state.variables)}async execute(e){let t=()=>{this.#i({type:`continue`})},n={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#r=C({fn:()=>this.options.mutationFn?this.options.mutationFn(e,n):Promise.reject(Error(`No mutationFn found`)),onFail:(e,t)=>{this.#i({type:`failed`,failureCount:e,error:t})},onPause:()=>{this.#i({type:`pause`})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});let r=this.state.status===`pending`,i=!this.#r.canStart();try{if(r)t();else{this.#i({type:`pending`,variables:e,isPaused:i}),this.#n.config.onMutate&&await this.#n.config.onMutate(e,this,n);let t=await this.options.onMutate?.(e,n);t!==this.state.context&&this.#i({type:`pending`,context:t,variables:e,isPaused:i})}let a=await this.#r.start();return await this.#n.config.onSuccess?.(a,e,this.state.context,this,n),await this.options.onSuccess?.(a,e,this.state.context,n),await this.#n.config.onSettled?.(a,null,this.state.variables,this.state.context,this,n),await this.options.onSettled?.(a,null,e,this.state.context,n),this.#i({type:`success`,data:a}),a}catch(t){try{await this.#n.config.onError?.(t,e,this.state.context,this,n)}catch(e){Promise.reject(e)}try{await this.options.onError?.(t,e,this.state.context,n)}catch(e){Promise.reject(e)}try{await this.#n.config.onSettled?.(void 0,t,this.state.variables,this.state.context,this,n)}catch(e){Promise.reject(e)}try{await this.options.onSettled?.(void 0,t,e,this.state.context,n)}catch(e){Promise.reject(e)}throw this.#i({type:`error`,error:t}),t}finally{this.#n.runNext(this)}}#i(e){this.state=(t=>{switch(e.type){case`failed`:return{...t,failureCount:e.failureCount,failureReason:e.error};case`pause`:return{...t,isPaused:!0};case`continue`:return{...t,isPaused:!1};case`pending`:return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:`pending`,variables:e.variables,submittedAt:Date.now()};case`success`:return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:`success`,isPaused:!1};case`error`:return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:`error`}}})(this.state),p.batch(()=>{this.#t.forEach(t=>{t.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:`updated`,action:e})})}};function Mr(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:`idle`,variables:void 0,submittedAt:0}}var Nr=class extends o{constructor(e={}){super(),this.config=e,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(e,t,n){let r=new jr({client:e,mutationCache:this,mutationId:++this.#n,options:e.defaultMutationOptions(t),state:n});return this.add(r),r}add(e){this.#e.add(e);let t=Pr(e);if(typeof t==`string`){let n=this.#t.get(t);n?n.push(e):this.#t.set(t,[e])}this.notify({type:`added`,mutation:e})}remove(e){if(this.#e.delete(e)){let t=Pr(e);if(typeof t==`string`){let n=this.#t.get(t);if(n)if(n.length>1){let t=n.indexOf(e);t!==-1&&n.splice(t,1)}else n[0]===e&&this.#t.delete(t)}}this.notify({type:`removed`,mutation:e})}canRun(e){let t=Pr(e);if(typeof t==`string`){let n=this.#t.get(t)?.find(e=>e.state.status===`pending`);return!n||n===e}else return!0}runNext(e){let t=Pr(e);return typeof t==`string`?(this.#t.get(t)?.find(t=>t!==e&&t.state.isPaused))?.continue()??Promise.resolve():Promise.resolve()}clear(){p.batch(()=>{this.#e.forEach(e=>{this.notify({type:`removed`,mutation:e})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(e){let t={exact:!0,...e};return this.getAll().find(e=>A(t,e))}findAll(e={}){return this.getAll().filter(t=>A(e,t))}notify(e){p.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){let e=this.getAll().filter(e=>e.state.isPaused);return p.batch(()=>Promise.all(e.map(e=>e.continue().catch(k))))}};function Pr(e){return e.options.scope?.id}var Fr=class extends o{constructor(e={}){super(),this.config=e,this.#e=new Map}#e;build(e,t,n){let r=t.queryKey,i=t.queryHash??u(r,t),a=this.get(i);return a||(a=new wr({client:e,queryKey:r,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(a)),a}add(e){this.#e.has(e.queryHash)||(this.#e.set(e.queryHash,e),this.notify({type:`added`,query:e}))}remove(e){let t=this.#e.get(e.queryHash);t&&(e.destroy(),t===e&&this.#e.delete(e.queryHash),this.notify({type:`removed`,query:e}))}clear(){p.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#e.get(e)}getAll(){return[...this.#e.values()]}find(e){let t={exact:!0,...e};return this.getAll().find(e=>f(t,e))}findAll(e={}){let t=this.getAll();return Object.keys(e).length>0?t.filter(t=>f(e,t)):t}notify(e){p.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){p.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){p.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},Ir=class{#e;#t;#n;#r;#i;#a;#o;#s;constructor(e={}){this.#e=e.queryCache||new Fr,this.#t=e.mutationCache||new Nr,this.#n=e.defaultOptions||{},this.#r=new Map,this.#i=new Map,this.#a=0}mount(){this.#a++,this.#a===1&&(this.#o=y.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#s=E.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#a--,this.#a===0&&(this.#o?.(),this.#o=void 0,this.#s?.(),this.#s=void 0)}isFetching(e){return this.#e.findAll({...e,fetchStatus:`fetching`}).length}isMutating(e){return this.#t.findAll({...e,status:`pending`}).length}getQueryData(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state.data}ensureQueryData(e){let t=this.defaultQueryOptions(e),n=this.#e.build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(l(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return this.#e.findAll(e).map(({queryKey:e,state:t})=>[e,t.data])}setQueryData(e,t,n){let r=this.defaultQueryOptions({queryKey:e}),i=this.#e.get(r.queryHash)?.state.data,a=_(t,i);if(a!==void 0)return this.#e.build(this,r).setData(a,{...n,manual:!0})}setQueriesData(e,t,n){return p.batch(()=>this.#e.findAll(e).map(({queryKey:e})=>[e,this.setQueryData(e,t,n)]))}getQueryState(e){let t=this.defaultQueryOptions({queryKey:e});return this.#e.get(t.queryHash)?.state}removeQueries(e){let t=this.#e;p.batch(()=>{t.findAll(e).forEach(e=>{t.remove(e)})})}resetQueries(e,t){let n=this.#e;return p.batch(()=>(n.findAll(e).forEach(e=>{e.reset()}),this.refetchQueries({type:`active`,...e},t)))}cancelQueries(e,t={}){let n={revert:!0,...t},r=p.batch(()=>this.#e.findAll(e).map(e=>e.cancel(n)));return Promise.all(r).then(k).catch(k)}invalidateQueries(e,t={}){return p.batch(()=>(this.#e.findAll(e).forEach(e=>{e.invalidate()}),e?.refetchType===`none`?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??`active`},t)))}refetchQueries(e,t={}){let n={...t,cancelRefetch:t.cancelRefetch??!0},r=p.batch(()=>this.#e.findAll(e).filter(e=>!e.isDisabled()&&!e.isStatic()).map(e=>{let t=e.fetch(void 0,n);return n.throwOnError||(t=t.catch(k)),e.state.fetchStatus===`paused`?Promise.resolve():t}));return Promise.all(r).then(k)}fetchQuery(e){let t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);let n=this.#e.build(this,t);return n.isStaleByTime(l(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(k).catch(k)}fetchInfiniteQuery(e){return e.behavior=Or(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(k).catch(k)}ensureInfiniteQueryData(e){return e.behavior=Or(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return E.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(e){this.#n=e}setQueryDefaults(e,t){this.#r.set(g(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){let t=[...this.#r.values()],n={};return t.forEach(t=>{c(e,t.queryKey)&&Object.assign(n,t.defaultOptions)}),n}setMutationDefaults(e,t){this.#i.set(g(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){let t=[...this.#i.values()],n={};return t.forEach(t=>{c(e,t.mutationKey)&&Object.assign(n,t.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;let t={...this.#n.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||=u(t.queryKey,t),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!==`always`),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode=`offlineFirst`),t.queryFn===s&&(t.enabled=!1),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#n.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}};function Lr(){try{return typeof window<`u`&&typeof window.sessionStorage==`object`?window.sessionStorage:void 0}catch{return}}var Rr=`tsr-scroll-restoration-v1_3`;function zr(){let e=Lr();if(!e)return null;let t={};try{let n=JSON.parse(e.getItem(`tsr-scroll-restoration-v1_3`)||`{}`);N(n)&&(t=n)}catch{}return{get state(){return t},set:e=>{t=ie(e,t)||t},persist:()=>{try{e.setItem(Rr,JSON.stringify(t))}catch{}}}}var Br=zr(),Vr=e=>e.state.__TSR_key||e.href;function Hr(e){let t=[],n;for(;n=e.parentNode;)t.push(`${e.tagName}:nth-child(${Array.prototype.indexOf.call(n.children,e)+1})`),e=n;return`${t.reverse().join(` > `)}`.toLowerCase()}var Ur=!1,Wr=`window`,Gr=`data-scroll-restoration-id`;function Kr(e,t){if(!Br)return;let n=Br;if((t??e.options.scrollRestoration??!1)&&(e.isScrollRestoring=!0),e.isScrollRestorationSetup||!n)return;e.isScrollRestorationSetup=!0,Ur=!1;let r=e.options.getScrollRestorationKey||Vr,i=new Map;window.history.scrollRestoration=`manual`;let a=t=>{if(!(Ur||!e.isScrollRestoring))if(t.target===document||t.target===window)i.set(Wr,{scrollX:window.scrollX||0,scrollY:window.scrollY||0});else{let e=t.target;i.set(e,{scrollX:e.scrollLeft||0,scrollY:e.scrollTop||0})}},o=t=>{if(!e.isScrollRestoring||!t||i.size===0||!n)return;let r=n.state[t]||={};for(let[e,t]of i){let n;if(e===Wr)n=Wr;else if(e.isConnected){let t=e.getAttribute(Gr);n=t?`[${Gr}="${t}"]`:Hr(e)}n&&(r[n]=t)}};document.addEventListener(`scroll`,a,!0),e.subscribe(`onBeforeLoad`,e=>{o(e.fromLocation?r(e.fromLocation):void 0),i.clear()}),window.addEventListener(`pagehide`,()=>{o(r(e.stores.resolvedLocation.state??e.stores.location.state)),n.persist()}),e.subscribe(`onRendered`,t=>{let a=r(t.toLocation),o=e.options.scrollRestorationBehavior,s=e.options.scrollToTopSelectors;if(i.clear(),!e.resetNextScroll){e.resetNextScroll=!0;return}if(!(typeof e.options.scrollRestoration==`function`&&!e.options.scrollRestoration({location:e.latestLocation}))){Ur=!0;try{let t=e.isScrollRestoring?n.state[a]:void 0,r=!1;if(t)for(let e in t){let n=t[e];if(!N(n))continue;let{scrollX:i,scrollY:a}=n;if(!(!Number.isFinite(i)||!Number.isFinite(a))){if(e===Wr)window.scrollTo({top:a,left:i,behavior:o}),r=!0;else if(e){let t;try{t=document.querySelector(e)}catch{continue}t&&(t.scrollLeft=i,t.scrollTop=a,r=!0)}}}if(!r){let t=e.history.location.hash.slice(1);if(t){let e=window.history.state?.__hashScrollIntoViewOptions??!0;if(e){let n=document.getElementById(t);n&&n.scrollIntoView(e)}}else{let e={top:0,left:0,behavior:o};if(window.scrollTo(e),s)for(let t of s){if(t===Wr)continue;let n=typeof t==`function`?t():document.querySelector(t);n&&n.scrollTo(e)}}}}finally{Ur=!1}e.isScrollRestoring&&n.set(e=>(e[a]||={},e))}})}function qr(e,t=String){let n=new URLSearchParams;for(let r in e){let i=e[r];i!==void 0&&n.set(r,t(i))}return n.toString()}function Jr(e){return e?e===`false`?!1:e===`true`?!0:e*0==0&&+e+``===e?+e:e:``}function Yr(e){let t=new URLSearchParams(e),n=Object.create(null);for(let[e,r]of t.entries()){let t=n[e];t==null?n[e]=Jr(r):Array.isArray(t)?t.push(Jr(r)):n[e]=[t,Jr(r)]}return n}var Xr=Qr(JSON.parse),Zr=$r(JSON.stringify,JSON.parse);function Qr(e){return t=>{t[0]===`?`&&(t=t.substring(1));let n=Yr(t);for(let t in n){let r=n[t];if(typeof r==`string`)try{n[t]=e(r)}catch{}}return n}}function $r(e,t){let n=typeof t==`function`;function r(r){if(typeof r==`object`&&r)try{return e(r)}catch{}else if(n&&typeof r==`string`)try{return t(r),e(r)}catch{}return r}return e=>{let t=qr(e,r);return t?`?${t}`:``}}function ei(e){return{input:({url:t})=>{for(let n of e)t=ni(n,t);return t},output:({url:t})=>{for(let n=e.length-1;n>=0;n--)t=ri(e[n],t);return t}}}function ti(e){let t=ge(e.basepath),n=`/${t}`,r=`${n}/`,i=e.caseSensitive?n:n.toLowerCase(),a=e.caseSensitive?r:r.toLowerCase();return{input:({url:t})=>{let r=e.caseSensitive?t.pathname:t.pathname.toLowerCase();return r===i?t.pathname=`/`:r.startsWith(a)&&(t.pathname=t.pathname.slice(n.length)),t},output:({url:e})=>(e.pathname=he([`/`,t,e.pathname]),e)}}function ni(e,t){let n=e?.input?.({url:t});if(n){if(typeof n==`string`)return new URL(n);if(n instanceof URL)return n}return t}function ri(e,t){let n=e?.output?.({url:t});if(n){if(typeof n==`string`)return new URL(n);if(n instanceof URL)return n}return t}function ii(e,t){let{createMutableStore:n,createReadonlyStore:r,batch:i,init:a}=t,o=new Map,s=new Map,c=new Map,l=n(e.status),u=n(e.loadedAt),d=n(e.isLoading),f=n(e.isTransitioning),p=n(e.location),m=n(e.resolvedLocation),h=n(e.statusCode),g=n(e.redirect),_=n([]),v=n([]),y=n([]),b=r(()=>ai(o,_.state)),x=r(()=>ai(s,v.state)),S=r(()=>ai(c,y.state)),C=r(()=>_.state[0]),w=r(()=>_.state.some(e=>o.get(e)?.state.status===`pending`)),T=r(()=>({locationHref:p.state.href,resolvedLocationHref:m.state?.href,status:l.state})),E=r(()=>({status:l.state,loadedAt:u.state,isLoading:d.state,isTransitioning:f.state,matches:b.state,location:p.state,resolvedLocation:m.state,statusCode:h.state,redirect:g.state})),D=te(64);function O(e){let t=D.get(e);return t||(t=r(()=>{let t=_.state;for(let n of t){let t=o.get(n);if(t&&t.routeId===e)return t.state}}),D.set(e,t)),t}let k={status:l,loadedAt:u,isLoading:d,isTransitioning:f,location:p,resolvedLocation:m,statusCode:h,redirect:g,matchesId:_,pendingMatchesId:v,cachedMatchesId:y,activeMatchesSnapshot:b,pendingMatchesSnapshot:x,cachedMatchesSnapshot:S,firstMatchId:C,hasPendingMatches:w,matchRouteReactivity:T,activeMatchStoresById:o,pendingMatchStoresById:s,cachedMatchStoresById:c,__store:E,getMatchStoreByRouteId:O,setActiveMatches:A,setPendingMatches:ee,setCachedMatches:j};A(e.matches),a?.(k);function A(e){oi(e,o,_,n,i)}function ee(e){oi(e,s,v,n,i)}function j(e){oi(e,c,y,n,i)}return k}function ai(e,t){let n=[];for(let r of t){let t=e.get(r);t&&n.push(t.state)}return n}function oi(e,t,n,r,i){let a=e.map(e=>e.id),o=new Set(a);i(()=>{for(let e of t.keys())o.has(e)||t.delete(e);for(let n of e){let e=t.get(n.id);if(!e){let e=r(n);e.routeId=n.routeId,t.set(n.id,e);continue}e.routeId=n.routeId,e.state!==n&&e.setState(()=>n)}M(n.state,a)||n.setState(()=>a)})}var si=e=>{if(!e.rendered)return e.rendered=!0,e.onReady?.()},ci=e=>e.stores.matchesId.state.some(t=>e.stores.activeMatchStoresById.get(t)?.state._forcePending),li=(e,t)=>!!(e.preload&&!e.router.stores.activeMatchStoresById.has(t)),ui=(e,t,n=!0)=>{let r={...e.router.options.context??{}},i=n?t:t-1;for(let t=0;t<=i;t++){let n=e.matches[t];if(!n)continue;let i=e.router.getMatch(n.id);i&&Object.assign(r,i.__routeContext,i.__beforeLoadContext)}return r},di=(e,t)=>{if(!e.matches.length)return;let n=t.routeId,r=e.matches.findIndex(t=>t.routeId===e.router.routeTree.id),i=r>=0?r:0,a=n?e.matches.findIndex(e=>e.routeId===n):e.firstBadMatchIndex??e.matches.length-1;a<0&&(a=i);for(let t=a;t>=0;t--){let n=e.matches[t];if(e.router.looseRoutesById[n.routeId].options.notFoundComponent)return t}return n?a:i},fi=(e,t,n)=>{if(!(!Ne(n)&&!ke(n)))throw Ne(n)&&n.redirectHandled&&!n.options.reloadDocument?n:(t&&(t._nonReactive.beforeLoadPromise?.resolve(),t._nonReactive.loaderPromise?.resolve(),t._nonReactive.beforeLoadPromise=void 0,t._nonReactive.loaderPromise=void 0,t._nonReactive.error=n,e.updateMatch(t.id,r=>({...r,status:Ne(n)?`redirected`:r.status===`pending`?`success`:r.status,context:ui(e,t.index),isFetching:!1,error:n})),ke(n)&&!n.routeId&&(n.routeId=t.routeId),t._nonReactive.loadPromise?.resolve()),Ne(n)&&(e.rendered=!0,n.options._fromLocation=e.location,n.redirectHandled=!0,n=e.router.resolveRedirect(n)),n)},pi=(e,t)=>{let n=e.router.getMatch(t);return!!(!n||n._nonReactive.dehydrated)},mi=(e,t,n)=>{let r=ui(e,n);e.updateMatch(t,e=>({...e,context:r}))},hi=(e,t,n,r)=>{let{id:i,routeId:a}=e.matches[t],o=e.router.looseRoutesById[a];if(n instanceof Promise)throw n;n.routerCode=r,e.firstBadMatchIndex??=t,fi(e,e.router.getMatch(i),n);try{o.options.onError?.(n)}catch(t){n=t,fi(e,e.router.getMatch(i),n)}e.updateMatch(i,e=>(e._nonReactive.beforeLoadPromise?.resolve(),e._nonReactive.beforeLoadPromise=void 0,e._nonReactive.loadPromise?.resolve(),{...e,error:n,status:`error`,isFetching:!1,updatedAt:Date.now(),abortController:new AbortController})),!e.preload&&!Ne(n)&&!ke(n)&&(e.serialError??=n)},gi=(e,t,n,r)=>{if(r._nonReactive.pendingTimeout!==void 0)return;let i=n.options.pendingMs??e.router.options.defaultPendingMs;if(e.onReady&&!li(e,t)&&(n.options.loader||n.options.beforeLoad||Di(n))&&typeof i==`number`&&i!==1/0&&(n.options.pendingComponent??e.router.options?.defaultPendingComponent)){let t=setTimeout(()=>{si(e)},i);r._nonReactive.pendingTimeout=t}},_i=(e,t,n)=>{let r=e.router.getMatch(t);if(!r._nonReactive.beforeLoadPromise&&!r._nonReactive.loaderPromise)return;gi(e,t,n,r);let i=()=>{let n=e.router.getMatch(t);n.preload&&(n.status===`redirected`||n.status===`notFound`)&&fi(e,n,n.error)};return r._nonReactive.beforeLoadPromise?r._nonReactive.beforeLoadPromise.then(i):i()},vi=(e,t,n,r)=>{let i=e.router.getMatch(t),a=i._nonReactive.loadPromise;i._nonReactive.loadPromise=j(()=>{a?.resolve(),a=void 0});let{paramsError:o,searchError:s}=i;o&&hi(e,n,o,`PARSE_PARAMS`),s&&hi(e,n,s,`VALIDATE_SEARCH`),gi(e,t,r,i);let c=new AbortController,l=!1,u=()=>{l||(l=!0,e.updateMatch(t,e=>({...e,isFetching:`beforeLoad`,fetchCount:e.fetchCount+1,abortController:c})))},d=()=>{i._nonReactive.beforeLoadPromise?.resolve(),i._nonReactive.beforeLoadPromise=void 0,e.updateMatch(t,e=>({...e,isFetching:!1}))};if(!r.options.beforeLoad){e.router.batch(()=>{u(),d()});return}i._nonReactive.beforeLoadPromise=j();let f={...ui(e,n,!1),...i.__routeContext},{search:p,params:m,cause:h}=i,g=li(e,t),_={search:p,abortController:c,params:m,preload:g,context:f,location:e.location,navigate:t=>e.router.navigate({...t,_fromLocation:e.location}),buildLocation:e.router.buildLocation,cause:g?`preload`:h,matches:e.matches,routeId:r.id,...e.router.options.additionalContext},v=r=>{if(r===void 0){e.router.batch(()=>{u(),d()});return}(Ne(r)||ke(r))&&(u(),hi(e,n,r,`BEFORE_LOAD`)),e.router.batch(()=>{u(),e.updateMatch(t,e=>({...e,__beforeLoadContext:r})),d()})},y;try{if(y=r.options.beforeLoad(_),ne(y))return u(),y.catch(t=>{hi(e,n,t,`BEFORE_LOAD`)}).then(v)}catch(t){u(),hi(e,n,t,`BEFORE_LOAD`)}v(y)},yi=(e,t)=>{let{id:n,routeId:r}=e.matches[t],i=e.router.looseRoutesById[r],a=()=>s(),o=()=>vi(e,n,t,i),s=()=>{if(pi(e,n))return;let t=_i(e,n,i);return ne(t)?t.then(o):o()};return a()},bi=(e,t,n)=>{let r=e.router.getMatch(t);if(!r||!n.options.head&&!n.options.scripts&&!n.options.headers)return;let i={ssr:e.router.options.ssr,matches:e.matches,match:r,params:r.params,loaderData:r.loaderData};return Promise.all([n.options.head?.(i),n.options.scripts?.(i),n.options.headers?.(i)]).then(([e,t,n])=>({meta:e?.meta,links:e?.links,headScripts:e?.scripts,headers:n,scripts:t,styles:e?.styles}))},xi=(e,t,n,r,i)=>{let a=t[r-1],{params:o,loaderDeps:s,abortController:c,cause:l}=e.router.getMatch(n),u=ui(e,r),d=li(e,n);return{params:o,deps:s,preload:!!d,parentMatchPromise:a,abortController:c,context:u,location:e.location,navigate:t=>e.router.navigate({...t,_fromLocation:e.location}),cause:d?`preload`:l,route:i,...e.router.options.additionalContext}},Si=async(e,t,n,r,i)=>{try{let a=e.router.getMatch(n);try{Ei(i);let o=i.options.loader,s=typeof o==`function`?o:o?.handler,c=s?.(xi(e,t,n,r,i)),l=!!s&&ne(c);if((l||i._lazyPromise||i._componentsPromise||i.options.head||i.options.scripts||i.options.headers||a._nonReactive.minPendingPromise)&&e.updateMatch(n,e=>({...e,isFetching:`loader`})),s){let t=l?await c:c;fi(e,e.router.getMatch(n),t),t!==void 0&&e.updateMatch(n,e=>({...e,loaderData:t}))}i._lazyPromise&&await i._lazyPromise;let u=a._nonReactive.minPendingPromise;u&&await u,i._componentsPromise&&await i._componentsPromise,e.updateMatch(n,t=>({...t,error:void 0,context:ui(e,r),status:`success`,isFetching:!1,updatedAt:Date.now()}))}catch(t){let o=t;if(o?.name===`AbortError`){if(a.abortController.signal.aborted){a._nonReactive.loaderPromise?.resolve(),a._nonReactive.loaderPromise=void 0;return}e.updateMatch(n,t=>({...t,status:t.status===`pending`?`success`:t.status,isFetching:!1,context:ui(e,r)}));return}let s=a._nonReactive.minPendingPromise;s&&await s,ke(t)&&await i.options.notFoundComponent?.preload?.(),fi(e,e.router.getMatch(n),t);try{i.options.onError?.(t)}catch(t){o=t,fi(e,e.router.getMatch(n),t)}!Ne(o)&&!ke(o)&&await Ei(i,[`errorComponent`]),e.updateMatch(n,t=>({...t,error:o,context:ui(e,r),status:`error`,isFetching:!1}))}}catch(t){let r=e.router.getMatch(n);r&&(r._nonReactive.loaderPromise=void 0),fi(e,r,t)}},Ci=async(e,t,n)=>{async function r(r,a,c,l,d){let f=Date.now()-a.updatedAt,p=r?d.options.preloadStaleTime??e.router.options.defaultPreloadStaleTime??3e4:d.options.staleTime??e.router.options.defaultStaleTime??0,m=d.options.shouldReload,h=typeof m==`function`?m(xi(e,t,i,n,d)):m,{status:g,invalid:_}=l,v=f>=p&&(!!e.forceStaleReload||l.cause===`enter`||c!==void 0&&c!==l.id);o=g===`success`&&(_||(h??v)),r&&d.options.preload===!1||(o&&!e.sync&&u?(s=!0,(async()=>{try{await Si(e,t,i,n,d);let r=e.router.getMatch(i);r._nonReactive.loaderPromise?.resolve(),r._nonReactive.loadPromise?.resolve(),r._nonReactive.loaderPromise=void 0,r._nonReactive.loadPromise=void 0}catch(t){Ne(t)&&await e.router.navigate(t.options)}})()):g!==`success`||o?await Si(e,t,i,n,d):mi(e,i,n))}let{id:i,routeId:a}=e.matches[n],o=!1,s=!1,c=e.router.looseRoutesById[a],l=c.options.loader,u=((typeof l==`function`?void 0:l?.staleReloadMode)??e.router.options.defaultStaleReloadMode)!==`blocking`;if(pi(e,i)){if(!e.router.getMatch(i))return e.matches[n];mi(e,i,n)}else{let t=e.router.getMatch(i),o=e.router.stores.matchesId.state[n],s=(o&&e.router.stores.activeMatchStoresById.get(o)||null)?.routeId===a?o:e.router.stores.activeMatchesSnapshot.state.find(e=>e.routeId===a)?.id,l=li(e,i);if(t._nonReactive.loaderPromise){if(t.status===`success`&&!e.sync&&!t.preload&&u)return t;await t._nonReactive.loaderPromise;let n=e.router.getMatch(i),a=n._nonReactive.error||n.error;a&&fi(e,n,a),n.status===`pending`&&await r(l,t,s,n,c)}else{let n=l&&!e.router.stores.activeMatchStoresById.has(i),a=e.router.getMatch(i);a._nonReactive.loaderPromise=j(),n!==a.preload&&e.updateMatch(i,e=>({...e,preload:n})),await r(l,t,s,a,c)}}let d=e.router.getMatch(i);s||(d._nonReactive.loaderPromise?.resolve(),d._nonReactive.loadPromise?.resolve(),d._nonReactive.loadPromise=void 0),clearTimeout(d._nonReactive.pendingTimeout),d._nonReactive.pendingTimeout=void 0,s||(d._nonReactive.loaderPromise=void 0),d._nonReactive.dehydrated=void 0;let f=s?d.isFetching:!1;return f!==d.isFetching||d.invalid!==!1?(e.updateMatch(i,e=>({...e,isFetching:f,invalid:!1})),e.router.getMatch(i)):d};async function wi(e){let t=e,n=[];ci(t.router)&&si(t);let r;for(let e=0;e({...e,...a?{status:`success`,globalNotFound:!0,error:void 0}:{status:`notFound`,error:l},isFetching:!1})),u=e,await Ei(r,[`notFoundComponent`])}else if(!t.preload){let e=t.matches[0];e.globalNotFound||t.router.getMatch(e.id)?.globalNotFound&&t.updateMatch(e.id,e=>({...e,globalNotFound:!1,error:void 0}))}if(t.serialError&&t.firstBadMatchIndex!==void 0){let e=t.router.looseRoutesById[t.matches[t.firstBadMatchIndex].routeId];await Ei(e,[`errorComponent`])}for(let e=0;e<=u;e++){let{id:n,routeId:r}=t.matches[e],i=t.router.looseRoutesById[r];try{let e=bi(t,n,i);if(e){let r=await e;t.updateMatch(n,e=>({...e,...r}))}}catch(e){console.error(`Error executing head for route ${r}:`,e)}}let d=si(t);if(ne(d)&&await d,l)throw l;if(t.serialError&&!t.preload&&!t.onReady)throw t.serialError;return t.matches}function Ti(e,t){let n=t.map(t=>e.options[t]?.preload?.()).filter(Boolean);if(n.length!==0)return Promise.all(n)}function Ei(e,t=Oi){!e._lazyLoaded&&e._lazyPromise===void 0&&(e.lazyFn?e._lazyPromise=e.lazyFn().then(t=>{let{id:n,...r}=t.options;Object.assign(e.options,r),e._lazyLoaded=!0,e._lazyPromise=void 0}):e._lazyLoaded=!0);let n=()=>e._componentsLoaded?void 0:t===Oi?(()=>{if(e._componentsPromise===void 0){let t=Ti(e,Oi);t?e._componentsPromise=t.then(()=>{e._componentsLoaded=!0,e._componentsPromise=void 0}):e._componentsLoaded=!0}return e._componentsPromise})():Ti(e,t);return e._lazyPromise?e._lazyPromise.then(n):n()}function Di(e){for(let t of Oi)if(e.options[t]?.preload)return!0;return!1}var Oi=[`component`,`errorComponent`,`pendingComponent`,`notFoundComponent`],ki=`__TSR_index`,Ai=`popstate`,H=`beforeunload`;function ji(e){let t=e.getLocation(),n=new Set,r=r=>{t=e.getLocation(),n.forEach(e=>e({location:t,action:r}))},i=n=>{e.notifyOnIndexChange??!0?r(n):t=e.getLocation()},a=async({task:n,navigateOpts:r,...i})=>{if(r?.ignoreBlocker??!1){n();return}let a=e.getBlockers?.()??[],o=i.type===`PUSH`||i.type===`REPLACE`;if(typeof document<`u`&&a.length&&o)for(let n of a){let r=Fi(i.path,i.state);if(await n.blockerFn({currentLocation:t,nextLocation:r,action:i.type})){e.onBlocked?.();return}}n()};return{get location(){return t},get length(){return e.getLength()},subscribers:n,subscribe:e=>(n.add(e),()=>{n.delete(e)}),push:(n,i,o)=>{let s=t.state[ki];i=Mi(s+1,i),a({task:()=>{e.pushState(n,i),r({type:`PUSH`})},navigateOpts:o,type:`PUSH`,path:n,state:i})},replace:(n,i,o)=>{let s=t.state[ki];i=Mi(s,i),a({task:()=>{e.replaceState(n,i),r({type:`REPLACE`})},navigateOpts:o,type:`REPLACE`,path:n,state:i})},go:(t,n)=>{a({task:()=>{e.go(t),i({type:`GO`,index:t})},navigateOpts:n,type:`GO`})},back:t=>{a({task:()=>{e.back(t?.ignoreBlocker??!1),i({type:`BACK`})},navigateOpts:t,type:`BACK`})},forward:t=>{a({task:()=>{e.forward(t?.ignoreBlocker??!1),i({type:`FORWARD`})},navigateOpts:t,type:`FORWARD`})},canGoBack:()=>t.state[ki]!==0,createHref:t=>e.createHref(t),block:t=>{if(!e.setBlockers)return()=>{};let n=e.getBlockers?.()??[];return e.setBlockers([...n,t]),()=>{let n=e.getBlockers?.()??[];e.setBlockers?.(n.filter(e=>e!==t))}},flush:()=>e.flush?.(),destroy:()=>e.destroy?.(),notify:r}}function Mi(e,t){t||={};let n=Ii();return{...t,key:n,__TSR_key:n,[ki]:e}}function Ni(e){let t=e?.window??(typeof document<`u`?window:void 0),n=t.history.pushState,r=t.history.replaceState,i=[],a=()=>i,o=e=>i=e,s=e?.createHref??(e=>e),c=e?.parseLocation??(()=>Fi(`${t.location.pathname}${t.location.search}${t.location.hash}`,t.history.state));if(!t.history.state?.__TSR_key&&!t.history.state?.key){let e=Ii();t.history.replaceState({[ki]:0,key:e,__TSR_key:e},``)}let l=c(),u,d=!1,f=!1,p=!1,m=!1,h=()=>l,g,_,v=()=>{g&&(C._ignoreSubscribers=!0,(g.isPush?t.history.pushState:t.history.replaceState)(g.state,``,g.href),C._ignoreSubscribers=!1,g=void 0,_=void 0,u=void 0)},y=(e,t,n)=>{let r=s(t);_||(u=l),l=Fi(t,n),g={href:r,state:n,isPush:g?.isPush||e===`push`},_||=Promise.resolve().then(()=>v())},b=e=>{l=c(),C.notify({type:e})},x=async()=>{if(f){f=!1;return}let e=c(),n=e.state[ki]-l.state[ki],r=n===1,i=n===-1,o=!r&&!i||d;d=!1;let s=o?`GO`:i?`BACK`:`FORWARD`,u=o?{type:`GO`,index:n}:{type:i?`BACK`:`FORWARD`};if(p)p=!1;else{let n=a();if(typeof document<`u`&&n.length){for(let r of n)if(await r.blockerFn({currentLocation:l,nextLocation:e,action:s})){f=!0,t.history.go(1),C.notify(u);return}}}l=c(),C.notify(u)},S=e=>{if(m){m=!1;return}let t=!1,n=a();if(typeof document<`u`&&n.length)for(let e of n){let n=e.enableBeforeUnload??!0;if(n===!0){t=!0;break}if(typeof n==`function`&&n()===!0){t=!0;break}}if(t)return e.preventDefault(),e.returnValue=``},C=ji({getLocation:h,getLength:()=>t.history.length,pushState:(e,t)=>y(`push`,e,t),replaceState:(e,t)=>y(`replace`,e,t),back:e=>(e&&(p=!0),m=!0,t.history.back()),forward:e=>{e&&(p=!0),m=!0,t.history.forward()},go:e=>{d=!0,t.history.go(e)},createHref:e=>s(e),flush:v,destroy:()=>{t.history.pushState=n,t.history.replaceState=r,t.removeEventListener(H,S,{capture:!0}),t.removeEventListener(Ai,x)},onBlocked:()=>{u&&l!==u&&(l=u)},getBlockers:a,setBlockers:o,notifyOnIndexChange:!1});return t.addEventListener(H,S,{capture:!0}),t.addEventListener(Ai,x),t.history.pushState=function(...e){let r=n.apply(t.history,e);return C._ignoreSubscribers||b(`PUSH`),r},t.history.replaceState=function(...e){let n=r.apply(t.history,e);return C._ignoreSubscribers||b(`REPLACE`),n},C}function Pi(e){let t=e.replace(/[\x00-\x1f\x7f]/g,``);return t.startsWith(`//`)&&(t=`/`+t.replace(/^\/+/,``)),t}function Fi(e,t){let n=Pi(e),r=n.indexOf(`#`),i=n.indexOf(`?`),a=Ii();return{href:n,pathname:n.substring(0,r>0?i>0?Math.min(r,i):r:i>0?i:n.length),hash:r>-1?n.substring(r):``,search:i>-1?n.slice(i,r===-1?void 0:r):``,state:t||{[ki]:0,key:a,__TSR_key:a}}}function Ii(){return(Math.random()+1).toString(36).substring(7)}function Li(e,t){let n=t,r=e;return{fromLocation:n,toLocation:r,pathChanged:n?.pathname!==r.pathname,hrefChanged:n?.href!==r.href,hashChanged:n?.hash!==r.hash}}var Ri=class{constructor(e,t){this.tempLocationKey=`${Math.round(Math.random()*1e7)}`,this.resetNextScroll=!0,this.shouldViewTransition=void 0,this.isViewTransitionTypesSupported=void 0,this.subscribers=new Set,this.isScrollRestoring=!1,this.isScrollRestorationSetup=!1,this.startTransition=e=>e(),this.update=e=>{let t=this.options,n=this.basepath??t?.basepath??`/`,r=this.basepath===void 0,i=t?.rewrite;if(this.options={...t,...e},this.isServer=this.options.isServer??typeof document>`u`,this.protocolAllowlist=new Set(this.options.protocolAllowlist),this.options.pathParamsAllowedCharacters&&(this.pathParamsDecoder=be(this.options.pathParamsAllowedCharacters)),(!this.history||this.options.history&&this.options.history!==this.history)&&(this.options.history?this.history=this.options.history:this.history=Ni()),this.origin=this.options.origin,this.origin||(window?.origin&&window.origin!==`null`?this.origin=window.origin:this.origin=`http://localhost`),this.history&&this.updateLatestLocation(),this.options.routeTree!==this.routeTree){this.routeTree=this.options.routeTree;let e;this.resolvePathCache=te(1e3),e=this.buildRouteTree(),this.setRoutes(e)}if(!this.stores&&this.latestLocation){let e=this.getStoreConfig(this);this.batch=e.batch,this.stores=ii(Vi(this.latestLocation),e),Kr(this)}let a=!1,o=this.options.basepath??`/`,s=this.options.rewrite;if(r||n!==o||i!==s){this.basepath=o;let e=[],t=ge(o);t&&t!==`/`&&e.push(ti({basepath:o})),s&&e.push(s),this.rewrite=e.length===0?void 0:e.length===1?e[0]:ei(e),this.history&&this.updateLatestLocation(),a=!0}a&&this.stores&&this.stores.location.setState(()=>this.latestLocation),typeof window<`u`&&`CSS`in window&&typeof window.CSS?.supports==`function`&&(this.isViewTransitionTypesSupported=window.CSS.supports(`selector(:active-view-transition-type(a)`))},this.updateLatestLocation=()=>{this.latestLocation=this.parseLocation(this.history.location,this.latestLocation)},this.buildRouteTree=()=>{let e=oe(this.routeTree,this.options.caseSensitive,(e,t)=>{e.init({originalIndex:t})});return this.options.routeMasks&&Ee(this.options.routeMasks,e.processedTree),e},this.subscribe=(e,t)=>{let n={eventType:e,fn:t};return this.subscribers.add(n),()=>{this.subscribers.delete(n)}},this.emit=e=>{this.subscribers.forEach(t=>{t.eventType===e.type&&t.fn(e)})},this.parseLocation=(e,t)=>{let n=({pathname:e,search:n,hash:r,href:i,state:a})=>{if(!this.rewrite&&!/[ \x00-\x1f\x7f\u0080-\uffff]/.test(e)){let i=this.options.parseSearch(n),o=this.options.stringifySearch(i);return{href:e+o+r,publicHref:e+o+r,pathname:P(e).path,external:!1,searchStr:o,search:F(t?.search,i),hash:P(r.slice(1)).path,state:Oe(t?.state,a)}}let o=new URL(i,this.origin),s=ni(this.rewrite,o),c=this.options.parseSearch(s.search),l=this.options.stringifySearch(c);return s.search=l,{href:s.href.replace(s.origin,``),publicHref:i,pathname:P(s.pathname).path,external:!!this.rewrite&&s.origin!==this.origin,searchStr:l,search:F(t?.search,c),hash:P(s.hash.slice(1)).path,state:Oe(t?.state,a)}},r=n(e),{__tempLocation:i,__tempKey:a}=r.state;if(i&&(!a||a===this.tempLocationKey)){let e=n(i);return e.state.key=r.state.key,e.state.__TSR_key=r.state.__TSR_key,delete e.state.__tempLocation,{...e,maskedLocation:r}}return r},this.resolvePathWithBase=(e,t)=>xe({base:e,to:pe(t),trailingSlash:this.options.trailingSlash,cache:this.resolvePathCache}),this.matchRoutes=(e,t,n)=>typeof e==`string`?this.matchRoutesInternal({pathname:e,search:t},n):this.matchRoutesInternal(e,t),this.getMatchedRoutes=e=>Ui({pathname:e,routesById:this.routesById,processedTree:this.processedTree}),this.cancelMatch=e=>{let t=this.getMatch(e);t&&(t.abortController.abort(),clearTimeout(t._nonReactive.pendingTimeout),t._nonReactive.pendingTimeout=void 0)},this.cancelMatches=()=>{this.stores.pendingMatchesId.state.forEach(e=>{this.cancelMatch(e)}),this.stores.matchesId.state.forEach(e=>{if(this.stores.pendingMatchStoresById.has(e))return;let t=this.stores.activeMatchStoresById.get(e)?.state;t&&(t.status===`pending`||t.isFetching===`loader`)&&this.cancelMatch(e)})},this.buildLocation=e=>{let t=(t={})=>{let n=t._fromLocation||this.pendingBuiltLocation||this.latestLocation,r=this.matchRoutesLightweight(n);t.from;let i=t.unsafeRelative===`path`?n.pathname:t.from??r.fullPath,a=this.resolvePathWithBase(i,`.`),o=r.search,s=Object.assign(Object.create(null),r.params),c=t.to?this.resolvePathWithBase(a,`${t.to}`):this.resolvePathWithBase(a,`.`),l=t.params===!1||t.params===null?Object.create(null):(t.params??!0)===!0?s:Object.assign(s,ie(t.params,s)),u=this.getMatchedRoutes(c),d=u.matchedRoutes;if((!u.foundRoute||u.foundRoute.path!==`/`&&u.routeParams[`**`])&&this.options.notFoundRoute&&(d=[...d,this.options.notFoundRoute]),Object.keys(l).length>0)for(let e of d){let t=e.options.params?.stringify??e.options.stringifyParams;if(t)try{Object.assign(l,t(l))}catch{}}let f=e.leaveParams?c:P(me({path:c,params:l,decoder:this.pathParamsDecoder,server:this.isServer}).interpolatedPath).path,p=o;if(e._includeValidateSearch&&this.options.search?.strict){let e={};d.forEach(t=>{if(t.options.validateSearch)try{Object.assign(e,Hi(t.options.validateSearch,{...e,...p}))}catch{}}),p=e}p=Wi({search:p,dest:t,destRoutes:d,_includeValidateSearch:e._includeValidateSearch}),p=F(o,p);let m=this.options.stringifySearch(p),h=t.hash===!0?n.hash:t.hash?ie(t.hash,n.hash):void 0,g=h?`#${h}`:``,_=t.state===!0?n.state:t.state?ie(t.state,n.state):{};_=Oe(n.state,_);let v=`${f}${m}${g}`,y,b,x=!1;if(this.rewrite){let e=new URL(v,this.origin),t=ri(this.rewrite,e);y=e.href.replace(e.origin,``),t.origin===this.origin?b=t.pathname+t.search+t.hash:(b=t.href,x=!0)}else y=ee(v),b=y;return{publicHref:b,href:y,pathname:f,search:p,searchStr:m,state:_,hash:h??``,external:x,unmaskOnReload:t.unmaskOnReload}},n=(n={},r)=>{let i=t(n),a=r?t(r):void 0;if(!a){let n=Object.create(null);if(this.options.routeMasks){let o=Te(i.pathname,this.processedTree);if(o){Object.assign(n,o.rawParams);let{from:i,params:s,...c}=o.route,l=s===!1||s===null?Object.create(null):(s??!0)===!0?n:Object.assign(n,ie(s,n));r={from:e.from,...c,params:l},a=t(r)}}}return a&&(i.maskedLocation=a),i};return e.mask?n(e,{from:e.from,...e.mask}):n(e)},this.commitLocation=async({viewTransition:e,ignoreBlocker:t,...n})=>{let r=()=>{let e=[`key`,`__TSR_key`,`__TSR_index`,`__hashScrollIntoViewOptions`];e.forEach(e=>{n.state[e]=this.latestLocation.state[e]});let t=ye(n.state,this.latestLocation.state);return e.forEach(e=>{delete n.state[e]}),t},i=ue(this.latestLocation.href)===ue(n.href),a=this.commitLocationPromise;if(this.commitLocationPromise=j(()=>{a?.resolve(),a=void 0}),i&&r())this.load();else{let{maskedLocation:r,hashScrollIntoView:i,...a}=n;r&&(a={...r,state:{...r.state,__tempKey:void 0,__tempLocation:{...a,search:a.searchStr,state:{...a.state,__tempKey:void 0,__tempLocation:void 0,__TSR_key:void 0,key:void 0}}}},(a.unmaskOnReload??this.options.unmaskOnReload??!1)&&(a.state.__tempKey=this.tempLocationKey)),a.state.__hashScrollIntoViewOptions=i??this.options.defaultHashScrollIntoView??!0,this.shouldViewTransition=e,this.history[n.replace?`replace`:`push`](a.publicHref,a.state,{ignoreBlocker:t})}return this.resetNextScroll=n.resetScroll??!0,this.history.subscribers.size||this.load(),this.commitLocationPromise},this.buildAndCommitLocation=({replace:e,resetScroll:t,hashScrollIntoView:n,viewTransition:r,ignoreBlocker:i,href:a,...o}={})=>{if(a){let t=this.history.location.state.__TSR_index,n=Fi(a,{__TSR_index:e?t:t+1}),r=new URL(n.pathname,this.origin);o.to=ni(this.rewrite,r).pathname,o.search=this.options.parseSearch(n.search),o.hash=n.hash.slice(1)}let s=this.buildLocation({...o,_includeValidateSearch:!0});this.pendingBuiltLocation=s;let c=this.commitLocation({...s,viewTransition:r,replace:e,resetScroll:t,hashScrollIntoView:n,ignoreBlocker:i});return Promise.resolve().then(()=>{this.pendingBuiltLocation===s&&(this.pendingBuiltLocation=void 0)}),c},this.navigate=async({to:e,reloadDocument:t,href:n,publicHref:r,...i})=>{let a=!1;if(n)try{new URL(`${n}`),a=!0}catch{}if(a&&!t&&(t=!0),t){if(e!==void 0||!n){let t=this.buildLocation({to:e,...i});n??=t.publicHref,r??=t.publicHref}let t=!a&&r?r:n;if(ae(t,this.protocolAllowlist))return Promise.resolve();if(!i.ignoreBlocker){let e=this.history.getBlockers?.()??[];for(let t of e)if(t?.blockerFn&&await t.blockerFn({currentLocation:this.latestLocation,nextLocation:this.latestLocation,action:`PUSH`}))return Promise.resolve()}return i.replace?window.location.replace(t):window.location.href=t,Promise.resolve()}return this.buildAndCommitLocation({...i,href:n,to:e,_isNavigate:!0})},this.beforeLoad=()=>{this.cancelMatches(),this.updateLatestLocation();let e=this.matchRoutes(this.latestLocation),t=this.stores.cachedMatchesSnapshot.state.filter(t=>!e.some(e=>e.id===t.id));this.batch(()=>{this.stores.status.setState(()=>`pending`),this.stores.statusCode.setState(()=>200),this.stores.isLoading.setState(()=>!0),this.stores.location.setState(()=>this.latestLocation),this.stores.setPendingMatches(e),this.stores.setCachedMatches(t)})},this.load=async e=>{let t,n,r,i=this.stores.resolvedLocation.state??this.stores.location.state;for(r=new Promise(a=>{this.startTransition(async()=>{try{this.beforeLoad();let t=this.latestLocation,n=this.stores.resolvedLocation.state,r=Li(t,n);this.stores.redirect.state||this.emit({type:`onBeforeNavigate`,...r}),this.emit({type:`onBeforeLoad`,...r}),await wi({router:this,sync:e?.sync,forceStaleReload:i.href===t.href,matches:this.stores.pendingMatchesSnapshot.state,location:t,updateMatch:this.updateMatch,onReady:async()=>{this.startTransition(()=>{this.startViewTransition(async()=>{let e=null,t=null,n=null,r=null;this.batch(()=>{let i=this.stores.pendingMatchesSnapshot.state,a=i.length,o=this.stores.activeMatchesSnapshot.state;e=a?o.filter(e=>!this.stores.pendingMatchStoresById.has(e.id)):null;let s=new Set;for(let e of this.stores.pendingMatchStoresById.values())e.routeId&&s.add(e.routeId);let c=new Set;for(let e of this.stores.activeMatchStoresById.values())e.routeId&&c.add(e.routeId);t=a?o.filter(e=>!s.has(e.routeId)):null,n=a?i.filter(e=>!c.has(e.routeId)):null,r=a?i.filter(e=>c.has(e.routeId)):o,this.stores.isLoading.setState(()=>!1),this.stores.loadedAt.setState(()=>Date.now()),a&&(this.stores.setActiveMatches(i),this.stores.setPendingMatches([]),this.stores.setCachedMatches([...this.stores.cachedMatchesSnapshot.state,...e.filter(e=>e.status!==`error`&&e.status!==`notFound`&&e.status!==`redirected`)]),this.clearExpiredCache())});for(let[e,i]of[[t,`onLeave`],[n,`onEnter`],[r,`onStay`]])if(e)for(let t of e)this.looseRoutesById[t.routeId].options[i]?.(t)})})}})}catch(e){Ne(e)?(t=e,this.navigate({...t.options,replace:!0,ignoreBlocker:!0})):ke(e)&&(n=e);let r=t?t.status:n?404:this.stores.activeMatchesSnapshot.state.some(e=>e.status===`error`)?500:200;this.batch(()=>{this.stores.statusCode.setState(()=>r),this.stores.redirect.setState(()=>t)})}this.latestLoadPromise===r&&(this.commitLocationPromise?.resolve(),this.latestLoadPromise=void 0,this.commitLocationPromise=void 0),a()})}),this.latestLoadPromise=r,await r;this.latestLoadPromise&&r!==this.latestLoadPromise;)await this.latestLoadPromise;let a;this.hasNotFoundMatch()?a=404:this.stores.activeMatchesSnapshot.state.some(e=>e.status===`error`)&&(a=500),a!==void 0&&this.stores.statusCode.setState(()=>a)},this.startViewTransition=e=>{let t=this.shouldViewTransition??this.options.defaultViewTransition;if(this.shouldViewTransition=void 0,t&&typeof document<`u`&&`startViewTransition`in document&&typeof document.startViewTransition==`function`){let n;if(typeof t==`object`&&this.isViewTransitionTypesSupported){let r=this.latestLocation,i=this.stores.resolvedLocation.state,a=typeof t.types==`function`?t.types(Li(r,i)):t.types;if(a===!1){e();return}n={update:e,types:a}}else n=e;document.startViewTransition(n)}else e()},this.updateMatch=(e,t)=>{this.startTransition(()=>{let n=this.stores.pendingMatchStoresById.get(e);if(n){n.setState(t);return}let r=this.stores.activeMatchStoresById.get(e);if(r){r.setState(t);return}let i=this.stores.cachedMatchStoresById.get(e);if(i){let n=t(i.state);n.status===`redirected`?this.stores.cachedMatchStoresById.delete(e)&&this.stores.cachedMatchesId.setState(t=>t.filter(t=>t!==e)):i.setState(()=>n)}})},this.getMatch=e=>this.stores.cachedMatchStoresById.get(e)?.state??this.stores.pendingMatchStoresById.get(e)?.state??this.stores.activeMatchStoresById.get(e)?.state,this.invalidate=e=>{let t=t=>e?.filter?.(t)??!0?{...t,invalid:!0,...e?.forcePending||t.status===`error`||t.status===`notFound`?{status:`pending`,error:void 0}:void 0}:t;return this.batch(()=>{this.stores.setActiveMatches(this.stores.activeMatchesSnapshot.state.map(t)),this.stores.setCachedMatches(this.stores.cachedMatchesSnapshot.state.map(t)),this.stores.setPendingMatches(this.stores.pendingMatchesSnapshot.state.map(t))}),this.shouldViewTransition=!1,this.load({sync:e?.sync})},this.getParsedLocationHref=e=>e.publicHref||`/`,this.resolveRedirect=e=>{let t=e.headers.get(`Location`);if(!e.options.href||e.options._builtLocation){let t=e.options._builtLocation??this.buildLocation(e.options),n=this.getParsedLocationHref(t);e.options.href=n,e.headers.set(`Location`,n)}else if(t)try{let n=new URL(t);if(this.origin&&n.origin===this.origin){let t=n.pathname+n.search+n.hash;e.options.href=t,e.headers.set(`Location`,t)}}catch{}if(e.options.href&&!e.options._builtLocation&&ae(e.options.href,this.protocolAllowlist))throw Error(`Redirect blocked: unsafe protocol`);return e.headers.get(`Location`)||e.headers.set(`Location`,e.options.href),e},this.clearCache=e=>{let t=e?.filter;t===void 0?this.stores.setCachedMatches([]):this.stores.setCachedMatches(this.stores.cachedMatchesSnapshot.state.filter(e=>!t(e)))},this.clearExpiredCache=()=>{let e=Date.now();this.clearCache({filter:t=>{let n=this.looseRoutesById[t.routeId];if(!n.options.loader)return!0;let r=(t.preload?n.options.preloadGcTime??this.options.defaultPreloadGcTime:n.options.gcTime??this.options.defaultGcTime)??300*1e3;return t.status===`error`?!0:e-t.updatedAt>=r}})},this.loadRouteChunk=Ei,this.preloadRoute=async e=>{let t=e._builtLocation??this.buildLocation(e),n=this.matchRoutes(t,{throwOnError:!0,preload:!0,dest:e}),r=new Set([...this.stores.matchesId.state,...this.stores.pendingMatchesId.state]),i=new Set([...r,...this.stores.cachedMatchesId.state]),a=n.filter(e=>!i.has(e.id));if(a.length){let e=this.stores.cachedMatchesSnapshot.state;this.stores.setCachedMatches([...e,...a])}try{return n=await wi({router:this,matches:n,location:t,preload:!0,updateMatch:(e,t)=>{r.has(e)?n=n.map(n=>n.id===e?t(n):n):this.updateMatch(e,t)}}),n}catch(e){if(Ne(e))return e.options.reloadDocument?void 0:await this.preloadRoute({...e.options,_fromLocation:t});ke(e)||console.error(e);return}},this.matchRoute=(e,t)=>{let n={...e,to:e.to?this.resolvePathWithBase(e.from||``,e.to):void 0,params:e.params||{},leaveParams:!0},r=this.buildLocation(n);if(t?.pending&&this.stores.status.state!==`pending`)return!1;let i=(t?.pending===void 0?!this.stores.isLoading.state:t.pending)?this.latestLocation:this.stores.resolvedLocation.state||this.stores.location.state,a=fe(r.pathname,t?.caseSensitive??!1,t?.fuzzy??!1,i.pathname,this.processedTree);return!a||e.params&&!ye(a.rawParams,e.params,{partial:!0})?!1:t?.includeSearch??!0?ye(i.search,r.search,{partial:!0})?a.rawParams:!1:a.rawParams},this.hasNotFoundMatch=()=>this.stores.activeMatchesSnapshot.state.some(e=>e.status===`notFound`||e.globalNotFound),this.getStoreConfig=t,this.update({defaultPreloadDelay:50,defaultPendingMs:1e3,defaultPendingMinMs:500,context:void 0,...e,caseSensitive:e.caseSensitive??!1,notFoundMode:e.notFoundMode??`fuzzy`,stringifySearch:e.stringifySearch??Zr,parseSearch:e.parseSearch??Xr,protocolAllowlist:e.protocolAllowlist??se}),typeof document<`u`&&(self.__TSR_ROUTER__=this)}isShell(){return!!this.options.isShell}isPrerendering(){return!!this.options.isPrerendering}get state(){return this.stores.__store.state}setRoutes({routesById:e,routesByPath:t,processedTree:n}){this.routesById=e,this.routesByPath=t,this.processedTree=n;let r=this.options.notFoundRoute;r&&(r.init({originalIndex:99999999999}),this.routesById[r.id]=r)}get looseRoutesById(){return this.routesById}getParentContext(e){return e?.id?e.context??this.options.context??void 0:this.options.context??void 0}matchRoutesInternal(e,t){let n=this.getMatchedRoutes(e.pathname),{foundRoute:r,routeParams:i,parsedParams:a}=n,{matchedRoutes:o}=n,s=!1;(r?r.path!==`/`&&i[`**`]:ue(e.pathname))&&(this.options.notFoundRoute?o=[...o,this.options.notFoundRoute]:s=!0);let c=s?Ki(this.options.notFoundMode,o):void 0,l=Array(o.length),u=new Map;for(let e of this.stores.activeMatchStoresById.values())e.routeId&&u.set(e.routeId,e.state);for(let n=0;nthis.navigate({...t,_fromLocation:e}),buildLocation:this.buildLocation,cause:n.cause,abortController:n.abortController,preload:!!n.preload,matches:l,routeId:r.id};n.__routeContext=r.options.context(t)??void 0}n.context={...a,...n.__routeContext,...n.__beforeLoadContext}}}return l}matchRoutesLightweight(e){let{matchedRoutes:t,routeParams:n,parsedParams:r}=this.getMatchedRoutes(e.pathname),i=re(t),a={...e.search};for(let e of t)try{Object.assign(a,Hi(e.options.validateSearch,a))}catch{}let o=re(this.stores.matchesId.state),s=o&&this.stores.activeMatchStoresById.get(o)?.state,c=s&&s.routeId===i.id&&s.pathname===e.pathname,l;if(c)l=s.params;else{let e=Object.assign(Object.create(null),n);for(let i of t)try{qi(i,n,r??{},e)}catch{}l=e}return{matchedRoutes:t,fullPath:i.fullPath,search:a,params:l}}},zi=class extends Error{},Bi=class extends Error{};function Vi(e){return{loadedAt:0,isLoading:!1,isTransitioning:!1,status:`idle`,resolvedLocation:void 0,location:e,matches:[],statusCode:200}}function Hi(e,t){if(e==null)return{};if(`~standard`in e){let n=e[`~standard`].validate(t);if(n instanceof Promise)throw new zi(`Async validation not supported`);if(n.issues)throw new zi(JSON.stringify(n.issues,void 0,2),{cause:n});return n.value}return`parse`in e?e.parse(t):typeof e==`function`?e(t):{}}function Ui({pathname:e,routesById:t,processedTree:n}){let r=Object.create(null),i=ue(e),a,o,s=De(i,n,!0);return s&&(a=s.route,Object.assign(r,s.rawParams),o=Object.assign(Object.create(null),s.parsedParams)),{matchedRoutes:s?.branch||[t.__root__],routeParams:r,foundRoute:a,parsedParams:o}}function Wi({search:e,dest:t,destRoutes:n,_includeValidateSearch:r}){return Gi(n)(e,t,r??!1)}function Gi(e){let t={dest:null,_includeValidateSearch:!1,middlewares:[]};for(let n of e)`search`in n.options?n.options.search?.middlewares&&t.middlewares.push(...n.options.search.middlewares):(n.options.preSearchFilters||n.options.postSearchFilters)&&t.middlewares.push(({search:e,next:t})=>{let r=e;`preSearchFilters`in n.options&&n.options.preSearchFilters&&(r=n.options.preSearchFilters.reduce((e,t)=>t(e),e));let i=t(r);return`postSearchFilters`in n.options&&n.options.postSearchFilters?n.options.postSearchFilters.reduce((e,t)=>t(e),i):i}),n.options.validateSearch&&t.middlewares.push(({search:e,next:r})=>{let i=r(e);if(!t._includeValidateSearch)return i;try{return{...i,...Hi(n.options.validateSearch,i)??void 0}}catch{return i}});t.middlewares.push(({search:e})=>{let n=t.dest;return n.search?n.search===!0?e:ie(n.search,e):{}});let n=(e,t,r)=>{if(e>=r.length)return t;let i=r[e];return i({search:t,next:t=>n(e+1,t,r)})};return function(e,r,i){return t.dest=r,t._includeValidateSearch=i,n(0,e,t.middlewares)}}function Ki(e,t){if(e!==`root`)for(let e=t.length-1;e>=0;e--){let n=t[e];if(n.children)return n.id}return je}function qi(e,t,n,r){let i=e.options.params?.parse??e.options.parseParams;if(i)if(e.options.skipRouteOnParseError)for(let e in t)e in n&&(r[e]=n[e]);else{let e=i(r);Object.assign(r,e)}}function Ji(e,t){if(e)return typeof e==`string`?e:e[t]}function Yi(e){return typeof e==`string`?{href:e,crossOrigin:void 0}:e}function Xi(e){if(typeof document<`u`&&document.querySelector){let t=e.stores.location.state,n=t.state.__hashScrollIntoViewOptions??!0;if(n&&t.hash!==``){let e=document.getElementById(t.hash);e&&e.scrollIntoView(n)}}}var U=e(r(),1),W=n();function Zi(e){let t=e.errorComponent??$i;return(0,W.jsx)(Qi,{getResetKey:e.getResetKey,onCatch:e.onCatch,children:({error:n,reset:r})=>n?U.createElement(t,{error:n,reset:r}):e.children})}var Qi=class extends U.Component{constructor(...e){super(...e),this.state={error:null}}static getDerivedStateFromProps(e){return{resetKey:e.getResetKey()}}static getDerivedStateFromError(e){return{error:e}}reset(){this.setState({error:null})}componentDidUpdate(e,t){t.error&&t.resetKey!==this.state.resetKey&&this.reset()}componentDidCatch(e,t){this.props.onCatch&&this.props.onCatch(e,t)}render(){return this.props.children({error:this.state.resetKey===this.props.getResetKey()?this.state.error:null,reset:()=>{this.reset()}})}};function $i({error:e}){let[t,n]=U.useState(!1);return(0,W.jsxs)(`div`,{style:{padding:`.5rem`,maxWidth:`100%`},children:[(0,W.jsxs)(`div`,{style:{display:`flex`,alignItems:`center`,gap:`.5rem`},children:[(0,W.jsx)(`strong`,{style:{fontSize:`1rem`},children:`Something went wrong!`}),(0,W.jsx)(`button`,{style:{appearance:`none`,fontSize:`.6em`,border:`1px solid currentColor`,padding:`.1rem .2rem`,fontWeight:`bold`,borderRadius:`.25rem`},onClick:()=>n(e=>!e),children:t?`Hide Error`:`Show Error`})]}),(0,W.jsx)(`div`,{style:{height:`.25rem`}}),t?(0,W.jsx)(`div`,{children:(0,W.jsx)(`pre`,{style:{fontSize:`.7em`,border:`1px solid red`,borderRadius:`.25rem`,padding:`.3rem`,color:`red`,overflow:`auto`},children:e.message?(0,W.jsx)(`code`,{children:e.message}):null})}):null]})}var ea=(e=>(e[e.None=0]=`None`,e[e.Mutable=1]=`Mutable`,e[e.Watching=2]=`Watching`,e[e.RecursedCheck=4]=`RecursedCheck`,e[e.Recursed=8]=`Recursed`,e[e.Dirty=16]=`Dirty`,e[e.Pending=32]=`Pending`,e))(ea||{});function ta({update:e,notify:t,unwatched:n}){return{link:r,unlink:i,propagate:a,checkDirty:o,shallowPropagate:s};function r(e,t,n){let r=t.depsTail;if(r!==void 0&&r.dep===e)return;let i=r===void 0?t.deps:r.nextDep;if(i!==void 0&&i.dep===e){i.version=n,t.depsTail=i;return}let a=e.subsTail;if(a!==void 0&&a.version===n&&a.sub===t)return;let o=t.depsTail=e.subsTail={version:n,dep:e,sub:t,prevDep:r,nextDep:i,prevSub:a,nextSub:void 0};i!==void 0&&(i.prevDep=o),r===void 0?t.deps=o:r.nextDep=o,a===void 0?e.subs=o:a.nextSub=o}function i(e,t=e.sub){let r=e.dep,i=e.prevDep,a=e.nextDep,o=e.nextSub,s=e.prevSub;return a===void 0?t.depsTail=i:a.prevDep=i,i===void 0?t.deps=a:i.nextDep=a,o===void 0?r.subsTail=s:o.prevSub=s,s===void 0?(r.subs=o)===void 0&&n(r):s.nextSub=o,a}function a(e){let n=e.nextSub,r;top:do{let i=e.sub,a=i.flags;if(a&60?a&12?a&4?!(a&48)&&c(e,i)?(i.flags=a|40,a&=1):a=0:i.flags=a&-9|32:a=0:i.flags=a|32,a&2&&t(i),a&1){let t=i.subs;if(t!==void 0){let i=(e=t).nextSub;i!==void 0&&(r={value:n,prev:r},n=i);continue}}if((e=n)!==void 0){n=e.nextSub;continue}for(;r!==void 0;)if(e=r.value,r=r.prev,e!==void 0){n=e.nextSub;continue top}break}while(!0)}function o(t,n){let r,i=0,a=!1;top:do{let o=t.dep,c=o.flags;if(n.flags&16)a=!0;else if((c&17)==17){if(e(o)){let e=o.subs;e.nextSub!==void 0&&s(e),a=!0}}else if((c&33)==33){(t.nextSub!==void 0||t.prevSub!==void 0)&&(r={value:t,prev:r}),t=o.deps,n=o,++i;continue}if(!a){let e=t.nextDep;if(e!==void 0){t=e;continue}}for(;i--;){let i=n.subs,o=i.nextSub!==void 0;if(o?(t=r.value,r=r.prev):t=i,a){if(e(n)){o&&s(i),n=t.sub;continue}a=!1}else n.flags&=-33;n=t.sub;let c=t.nextDep;if(c!==void 0){t=c;continue top}}return a}while(!0)}function s(e){do{let n=e.sub,r=n.flags;(r&48)==32&&(n.flags=r|16,(r&6)==2&&t(n))}while((e=e.nextSub)!==void 0)}function c(e,t){let n=t.depsTail;for(;n!==void 0;){if(n===e)return!0;n=n.prevDep}return!1}}function na(e,t,n){let r=typeof e==`object`,i=r?e:void 0;return{next:(r?e.next:e)?.bind(i),error:(r?e.error:t)?.bind(i),complete:(r?e.complete:n)?.bind(i)}}var ra=[],ia=0,{link:aa,unlink:oa,propagate:sa,checkDirty:ca,shallowPropagate:la}=ta({update(e){return e._update()},notify(e){ra[da++]=e,e.flags&=~ea.Watching},unwatched(e){e.depsTail!==void 0&&(e.depsTail=void 0,e.flags=ea.Mutable|ea.Dirty,ha(e))}}),ua=0,da=0,fa,pa=0;function ma(e){try{++pa,e()}finally{--pa||ga()}}function ha(e){let t=e.depsTail,n=t===void 0?e.deps:t.nextDep;for(;n!==void 0;)n=oa(n,e)}function ga(){if(!(pa>0)){for(;ua{i.get(),n.current?t.next?.(i._snapshot):n.current=!0});return{unsubscribe:()=>{r.stop()}}},_update(e){let a=fa,o=t?.compare??Object.is;if(n)fa=i,++ia,i.depsTail=void 0;else if(e===void 0)return!1;n&&(i.flags=ea.Mutable|ea.RecursedCheck);try{let t=i._snapshot,a=typeof e==`function`?e(t):e===void 0&&n?r(t):e;return t===void 0||!o(t,a)?(i._snapshot=a,!0):!1}finally{fa=a,n&&(i.flags&=~ea.RecursedCheck),ha(i)}}};return n?(i.flags=ea.Mutable|ea.Dirty,i.get=function(){let e=i.flags;if(e&ea.Dirty||e&ea.Pending&&ca(i.deps,i)){if(i._update()){let e=i.subs;e!==void 0&&la(e)}}else e&ea.Pending&&(i.flags=e&~ea.Pending);return fa!==void 0&&aa(i,fa,ia),i._snapshot}):i.set=function(e){if(i._update(e)){let e=i.subs;e!==void 0&&(sa(e),la(e),ga())}},i}function va(e){let t=()=>{let t=fa;fa=n,++ia,n.depsTail=void 0,n.flags=ea.Watching|ea.RecursedCheck;try{return e()}finally{fa=t,n.flags&=~ea.RecursedCheck,ha(n)}},n={deps:void 0,depsTail:void 0,subs:void 0,subsTail:void 0,flags:ea.Watching|ea.RecursedCheck,notify(){let e=this.flags;e&ea.Dirty||e&ea.Pending&&ca(this.deps,this)?t():this.flags=ea.Watching},stop(){this.flags=ea.None,this.depsTail=void 0,ha(this)}};return t(),n}var ya=class{constructor(e){this.atom=_a(e)}setState(e){this.atom.set(e)}get state(){return this.atom.get()}get(){return this.state}subscribe(e){return this.atom.subscribe(na(e))}},ba=class{constructor(e){this.atom=_a(e)}get state(){return this.atom.get()}get(){return this.state}subscribe(e){return this.atom.subscribe(na(e))}};function xa(e){return typeof e==`function`?new ba(e):new ya(e)}function Sa(e){let t=_e(),n=`not-found-${we(t.stores.location,e=>e.pathname)}-${we(t.stores.status,e=>e)}`;return(0,W.jsx)(Zi,{getResetKey:()=>n,onCatch:(t,n)=>{if(ke(t))e.onCatch?.(t,n);else throw t},errorComponent:({error:t})=>{if(ke(t))return e.fallback?.(t);throw t},children:e.children})}function Ca(){return(0,W.jsx)(`p`,{children:`Not Found`})}function wa(e){return(0,W.jsx)(W.Fragment,{children:e.children})}function Ta(e,t,n){return t.options.notFoundComponent?(0,W.jsx)(t.options.notFoundComponent,{...n}):e.options.defaultNotFoundComponent?(0,W.jsx)(e.options.defaultNotFoundComponent,{...n}):(0,W.jsx)(Ca,{})}var Ea=U.memo(function({matchId:e}){let t=_e(),n=t.stores.activeMatchStoresById.get(e);n||I();let r=we(t.stores.loadedAt,e=>e),i=we(n,e=>e);return(0,W.jsx)(Da,{router:t,matchId:e,resetKey:r,matchState:U.useMemo(()=>{let e=i.routeId,n=t.routesById[e].parentRoute?.id;return{routeId:e,ssr:i.ssr,_displayPending:i._displayPending,parentRouteId:n}},[i._displayPending,i.routeId,i.ssr,t.routesById])})});function Da({router:e,matchId:t,resetKey:n,matchState:r}){let i=e.routesById[r.routeId],a=i.options.pendingComponent??e.options.defaultPendingComponent,o=a?(0,W.jsx)(a,{}):null,s=i.options.errorComponent??e.options.defaultErrorComponent,c=i.options.onCatch??e.options.defaultOnCatch,l=i.isRoot?i.options.notFoundComponent??e.options.notFoundRoute?.options.component:i.options.notFoundComponent,u=r.ssr===!1||r.ssr===`data-only`,d=(!i.isRoot||i.options.wrapInSuspense||u)&&(i.options.wrapInSuspense??a??(i.options.errorComponent?.preload||u))?U.Suspense:wa,f=s?Zi:wa,p=l?Sa:wa;return(0,W.jsxs)(i.isRoot?i.options.shellComponent??wa:wa,{children:[(0,W.jsx)(Ae.Provider,{value:t,children:(0,W.jsx)(d,{fallback:o,children:(0,W.jsx)(f,{getResetKey:()=>n,errorComponent:s||$i,onCatch:(e,t)=>{if(ke(e))throw e.routeId??=r.routeId,e;c?.(e,t)},children:(0,W.jsx)(p,{fallback:e=>{if(e.routeId??=r.routeId,!l||e.routeId&&e.routeId!==r.routeId||!e.routeId&&!i.isRoot)throw e;return U.createElement(l,e)},children:u||r._displayPending?(0,W.jsx)(Se,{fallback:o,children:(0,W.jsx)(ka,{matchId:t})}):(0,W.jsx)(ka,{matchId:t})})})})}),r.parentRouteId===`__root__`?(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(Oa,{resetKey:n}),(e.options.scrollRestoration,null)]}):null]})}function Oa({resetKey:e}){let t=_e(),n=U.useRef(void 0);return ce(()=>{let e=t.latestLocation.href;(n.current===void 0||n.current!==e)&&(t.emit({type:`onRendered`,...Li(t.stores.location.state,t.stores.resolvedLocation.state)}),n.current=e)},[t.latestLocation.state.__TSR_key,e,t]),null}var ka=U.memo(function({matchId:e}){let t=_e(),n=t.stores.activeMatchStoresById.get(e);n||I();let r=we(n,e=>e),i=r.routeId,a=t.routesById[i],o=U.useMemo(()=>{let e=(t.routesById[i].options.remountDeps??t.options.defaultRemountDeps)?.({routeId:i,loaderDeps:r.loaderDeps,params:r._strictParams,search:r._strictSearch});return e?JSON.stringify(e):void 0},[i,r.loaderDeps,r._strictParams,r._strictSearch,t.options.defaultRemountDeps,t.routesById]),s=U.useMemo(()=>{let e=a.options.component??t.options.defaultComponent;return e?(0,W.jsx)(e,{},o):(0,W.jsx)(Aa,{})},[o,a.options.component,t.options.defaultComponent]);if(r._displayPending)throw t.getMatch(r.id)?._nonReactive.displayPendingPromise;if(r._forcePending)throw t.getMatch(r.id)?._nonReactive.minPendingPromise;if(r.status===`pending`){let e=a.options.pendingMinMs??t.options.defaultPendingMinMs;if(e){let n=t.getMatch(r.id);if(n&&!n._nonReactive.minPendingPromise){let t=j();n._nonReactive.minPendingPromise=t,setTimeout(()=>{t.resolve(),n._nonReactive.minPendingPromise=void 0},e)}}throw t.getMatch(r.id)?._nonReactive.loadPromise}if(r.status===`notFound`)return ke(r.error)||I(),Ta(t,a,r.error);if(r.status===`redirected`)throw Ne(r.error)||I(),t.getMatch(r.id)?._nonReactive.loadPromise;if(r.status===`error`)throw r.error;return s}),Aa=U.memo(function(){let e=_e(),t=U.useContext(Ae),n,r=!1,i;{let a=t?e.stores.activeMatchStoresById.get(t):void 0;[n,r]=we(a,e=>[e?.routeId,e?.globalNotFound??!1]),i=we(e.stores.matchesId,e=>e[e.findIndex(e=>e===t)+1])}let a=n?e.routesById[n]:void 0,o=e.options.defaultPendingComponent?(0,W.jsx)(e.options.defaultPendingComponent,{}):null;if(r)return a||I(),Ta(e,a,void 0);if(!i)return null;let s=(0,W.jsx)(Ea,{matchId:i});return n===`__root__`?(0,W.jsx)(U.Suspense,{fallback:o,children:s}):s});function ja(){let e=_e(),t=U.useRef({router:e,mounted:!1}),[n,r]=U.useState(!1),i=we(e.stores.isLoading,e=>e),a=we(e.stores.hasPendingMatches,e=>e),o=le(i),s=i||n||a,c=le(s),l=i||a,u=le(l);return e.startTransition=e=>{r(!0),U.startTransition(()=>{e(),r(!1)})},U.useEffect(()=>{let t=e.history.subscribe(e.load),n=e.buildLocation({to:e.latestLocation.pathname,search:!0,params:!0,hash:!0,state:!0,_includeValidateSearch:!0});return ue(e.latestLocation.publicHref)!==ue(n.publicHref)&&e.commitLocation({...n,replace:!0}),()=>{t()}},[e,e.history]),ce(()=>{typeof window<`u`&&e.ssr||t.current.router===e&&t.current.mounted||(t.current={router:e,mounted:!0},(async()=>{try{await e.load()}catch(e){console.error(e)}})())},[e]),ce(()=>{o&&!i&&e.emit({type:`onLoad`,...Li(e.stores.location.state,e.stores.resolvedLocation.state)})},[o,e,i]),ce(()=>{u&&!l&&e.emit({type:`onBeforeRouteMount`,...Li(e.stores.location.state,e.stores.resolvedLocation.state)})},[l,u,e]),ce(()=>{if(c&&!s){let t=Li(e.stores.location.state,e.stores.resolvedLocation.state);e.emit({type:`onResolved`,...t}),ma(()=>{e.stores.status.setState(()=>`idle`),e.stores.resolvedLocation.setState(()=>e.stores.location.state)}),t.hrefChanged&&Xi(e)}},[s,c,e]),null}function Ma(){let e=_e(),t=e.routesById.__root__.options.pendingComponent??e.options.defaultPendingComponent,n=t?(0,W.jsx)(t,{}):null,r=(0,W.jsxs)(typeof document<`u`&&e.ssr?wa:U.Suspense,{fallback:n,children:[(0,W.jsx)(ja,{}),(0,W.jsx)(Na,{})]});return e.options.InnerWrap?(0,W.jsx)(e.options.InnerWrap,{children:r}):r}function Na(){let e=_e(),t=we(e.stores.firstMatchId,e=>e),n=we(e.stores.loadedAt,e=>e),r=t?(0,W.jsx)(Ea,{matchId:t}):null;return(0,W.jsx)(Ae.Provider,{value:t,children:e.options.disableGlobalCatchBoundary?r:(0,W.jsx)(Zi,{getResetKey:()=>n,errorComponent:$i,onCatch:void 0,children:r})})}var Pa=e=>({createMutableStore:xa,createReadonlyStore:xa,batch:ma}),Fa=e=>new Ia(e),Ia=class extends Ri{constructor(e){super(e,Pa)}};function La({router:e,children:t,...n}){Object.keys(n).length>0&&e.update({...e.options,...n,context:{...e.options.context,...n.context}});let r=(0,W.jsx)(de.Provider,{value:e,children:t});return e.options.Wrap?(0,W.jsx)(e.options.Wrap,{children:r}):r}function Ra({router:e,...t}){return(0,W.jsx)(La,{router:e,...t,children:(0,W.jsx)(Ma,{})})}function za(e){let t=_e(),n=(0,U.useRef)(void 0);return we(t.stores.location,r=>{let i=e?.select?e.select(r):r;if(e?.structuralSharing??t.options.defaultStructuralSharing){let e=Oe(n.current,i);return n.current=e,e}return i})}function Ba({tag:e,attrs:t,children:n,nonce:r}){switch(e){case`title`:return(0,W.jsx)(`title`,{...t,suppressHydrationWarning:!0,children:n});case`meta`:return(0,W.jsx)(`meta`,{...t,suppressHydrationWarning:!0});case`link`:return(0,W.jsx)(`link`,{...t,nonce:r,suppressHydrationWarning:!0});case`style`:return(0,W.jsx)(`style`,{...t,dangerouslySetInnerHTML:{__html:n},nonce:r});case`script`:return(0,W.jsx)(Va,{attrs:t,children:n});default:return null}}function Va({attrs:e,children:t}){_e();let n=Ce(),r=typeof e?.type==`string`&&e.type!==``&&e.type!==`text/javascript`&&e.type!==`module`;if(U.useEffect(()=>{if(!r){if(e?.src){let t=(()=>{try{let t=document.baseURI||window.location.href;return new URL(e.src,t).href}catch{return e.src}})();if(Array.from(document.querySelectorAll(`script[src]`)).find(e=>e.src===t))return;let n=document.createElement(`script`);for(let[t,r]of Object.entries(e))t!==`suppressHydrationWarning`&&r!==void 0&&r!==!1&&n.setAttribute(t,typeof r==`boolean`?``:String(r));return document.head.appendChild(n),()=>{n.parentNode&&n.parentNode.removeChild(n)}}if(typeof t==`string`){let n=typeof e?.type==`string`?e.type:`text/javascript`,r=typeof e?.nonce==`string`?e.nonce:void 0;if(Array.from(document.querySelectorAll(`script:not([src])`)).find(e=>{if(!(e instanceof HTMLScriptElement))return!1;let i=e.getAttribute(`type`)??`text/javascript`,a=e.getAttribute(`nonce`)??void 0;return e.textContent===t&&i===n&&a===r}))return;let i=document.createElement(`script`);if(i.textContent=t,e)for(let[t,n]of Object.entries(e))t!==`suppressHydrationWarning`&&n!==void 0&&n!==!1&&i.setAttribute(t,typeof n==`boolean`?``:String(n));return document.head.appendChild(i),()=>{i.parentNode&&i.parentNode.removeChild(i)}}}},[e,t,r]),r&&typeof t==`string`)return(0,W.jsx)(`script`,{...e,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:t}});if(!n){if(e?.src)return(0,W.jsx)(`script`,{...e,suppressHydrationWarning:!0});if(typeof t==`string`)return(0,W.jsx)(`script`,{...e,dangerouslySetInnerHTML:{__html:t},suppressHydrationWarning:!0})}return null}var Ha=e=>{let t=_e(),n=t.options.ssr?.nonce,r=we(t.stores.activeMatchesSnapshot,e=>e.map(e=>e.meta).filter(Boolean),ye),i=U.useMemo(()=>{let e=[],t={},i;for(let a=r.length-1;a>=0;a--){let o=r[a];for(let r=o.length-1;r>=0;r--){let a=o[r];if(a)if(a.title)i||={tag:`title`,children:a.title};else if(`script:ld+json`in a)try{let t=JSON.stringify(a[`script:ld+json`]);e.push({tag:`script`,attrs:{type:`application/ld+json`},children:ve(t)})}catch{}else{let r=a.name??a.property;if(r){if(t[r])continue;t[r]=!0}e.push({tag:`meta`,attrs:{...a,nonce:n}})}}}return i&&e.push(i),n&&e.push({tag:`meta`,attrs:{property:`csp-nonce`,content:n}}),e.reverse(),e},[r,n]),a=we(t.stores.activeMatchesSnapshot,r=>{let i=r.map(e=>e.links).filter(Boolean).flat(1).map(e=>({tag:`link`,attrs:{...e,nonce:n}})),a=t.ssr?.manifest,o=r.map(e=>a?.routes[e.routeId]?.assets??[]).filter(Boolean).flat(1).filter(e=>e.tag===`link`).map(t=>({tag:`link`,attrs:{...t.attrs,crossOrigin:Ji(e,`stylesheet`)??t.attrs?.crossOrigin,suppressHydrationWarning:!0,nonce:n}}));return[...i,...o]},ye),o=we(t.stores.activeMatchesSnapshot,r=>{let i=[];return r.map(e=>t.looseRoutesById[e.routeId]).forEach(r=>t.ssr?.manifest?.routes[r.id]?.preloads?.filter(Boolean).forEach(t=>{let r=Yi(t);i.push({tag:`link`,attrs:{rel:`modulepreload`,href:r.href,crossOrigin:Ji(e,`modulepreload`)??r.crossOrigin,nonce:n}})})),i},ye),s=we(t.stores.activeMatchesSnapshot,e=>e.map(e=>e.styles).flat(1).filter(Boolean).map(({children:e,...t})=>({tag:`style`,attrs:{...t,nonce:n},children:e})),ye),c=we(t.stores.activeMatchesSnapshot,e=>e.map(e=>e.headScripts).flat(1).filter(Boolean).map(({children:e,...t})=>({tag:`script`,attrs:{...t,nonce:n},children:e})),ye);return Ua([...i,...o,...a,...s,...c],e=>JSON.stringify(e))};function Ua(e,t){let n=new Set;return e.filter(e=>{let r=t(e);return n.has(r)?!1:(n.add(r),!0)})}function Wa(e){let t=Ha(e.assetCrossOrigin),n=_e().options.ssr?.nonce;return(0,W.jsx)(W.Fragment,{children:t.map(e=>(0,U.createElement)(Ba,{...e,key:`tsr-meta-${JSON.stringify(e)}`,nonce:n}))})}var Ga=t((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0>>1,a=e[r];if(0>>1;ri(c,n))li(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(li(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m)if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&ee(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-Tt&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&ee(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function ee(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,ee(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),Ka=t(((e,t)=>{t.exports=Ga()})),qa=t((e=>{var t=Ka(),n=r(),i=Le();function a(e){var t=`https://react.dev/errors/`+e;if(1ie||(e.current=re[ie],re[ie]=null,ie--)}function F(e,t){ie++,re[ie]=e.current,e.current=t}var oe=ae(null),se=ae(null),ce=ae(null),le=ae(null);function ue(e,t){switch(F(ce,t),F(se,e),F(oe,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Vd(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Vd(t),e=Hd(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}P(oe),F(oe,e)}function de(){P(oe),P(se),P(ce)}function fe(e){e.memoizedState!==null&&F(le,e);var t=oe.current,n=Hd(t,e.type);t!==n&&(F(se,e),F(oe,n))}function pe(e){se.current===e&&(P(oe),P(se)),le.current===e&&(P(le),Qf._currentValue=ne)}var me,he;function ge(e){if(me===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);me=t&&t[1]||``,he=-1)`:-1i||c[r]!==l[i]){var u=` -`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(``)&&(u=u.replace(``,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{ge=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?he(n):``}function ve(e,t){switch(e.tag){case 26:case 27:case 5:return he(e.type);case 16:return he(`Lazy`);case 13:return e.child!==t&&t!==null?he(`Suspense Fallback`):he(`Suspense`);case 19:return he(`SuspenseList`);case 0:case 15:return _e(e.type,!1);case 11:return _e(e.type.render,!1);case 1:return _e(e.type,!0);case 31:return he(`Activity`);default:return``}}function ye(e){try{var t=``,n=null;do t+=ve(e,n),n=e,e=e.return;while(e);return t}catch(e){return` +`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(``)&&(u=u.replace(``,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{_e=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?ge(n):``}function ye(e,t){switch(e.tag){case 26:case 27:case 5:return ge(e.type);case 16:return ge(`Lazy`);case 13:return e.child!==t&&t!==null?ge(`Suspense Fallback`):ge(`Suspense`);case 19:return ge(`SuspenseList`);case 0:case 15:return ve(e.type,!1);case 11:return ve(e.type.render,!1);case 1:return ve(e.type,!0);case 31:return ge(`Activity`);default:return``}}function be(e){try{var t=``,n=null;do t+=ye(e,n),n=e,e=e.return;while(e);return t}catch(e){return` Error generating stack: `+e.message+` -`+e.stack}}var be=Object.prototype.hasOwnProperty,xe=t.unstable_scheduleCallback,Se=t.unstable_cancelCallback,Ce=t.unstable_shouldYield,we=t.unstable_requestPaint,Te=t.unstable_now,Ee=t.unstable_getCurrentPriorityLevel,De=t.unstable_ImmediatePriority,Oe=t.unstable_UserBlockingPriority,ke=t.unstable_NormalPriority,Ae=t.unstable_LowPriority,je=t.unstable_IdlePriority,Me=t.log,Ne=t.unstable_setDisableYieldValue,Pe=null,L=null;function Fe(e){if(typeof Me==`function`&&Ne(e),L&&typeof L.setStrictMode==`function`)try{L.setStrictMode(Pe,e)}catch{}}var R=Math.clz32?Math.clz32:Re,Ie=Math.log,z=Math.LN2;function Re(e){return e>>>=0,e===0?32:31-(Ie(e)/z|0)|0}var ze=256,Be=262144,Ve=4194304;function He(e){var t=e&42;if(t!==0)return t;switch(e&-e){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 e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Ue(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=He(n))):i=He(o):i=He(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=He(n))):i=He(o)):i=He(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function We(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ge(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+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 t+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 Ke(){var e=Ve;return Ve<<=1,!(Ve&62914560)&&(Ve=4194304),e}function qe(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Je(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Ye(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0`u`||window.document===void 0||window.document.createElement===void 0),sn=!1;if(on)try{var cn={};Object.defineProperty(cn,`passive`,{get:function(){sn=!0}}),window.addEventListener(`test`,cn,cn),window.removeEventListener(`test`,cn,cn)}catch{sn=!1}var ln=null,un=null,dn=null;function fn(){if(dn)return dn;var e,t=un,n=t.length,r,i=`value`in ln?ln.value:ln.textContent,a=i.length;for(e=0;e=Un),Kn=` `,qn=!1;function Jn(e,t){switch(e){case`keyup`:return Vn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Yn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Xn=!1;function Zn(e,t){switch(e){case`compositionend`:return Yn(t);case`keypress`:return t.which===32?(qn=!0,Kn):null;case`textInput`:return e=t.data,e===Kn&&qn?null:e;default:return null}}function Qn(e,t){if(Xn)return e===`compositionend`||!Hn&&Jn(e,t)?(e=fn(),dn=un=ln=null,Xn=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=br(n)}}function Sr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Sr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Cr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Nt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Nt(e.document)}return t}function wr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Tr=on&&`documentMode`in document&&11>=document.documentMode,Er=null,Dr=null,Or=null,kr=!1;function Ar(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;kr||Er==null||Er!==Nt(r)||(r=Er,`selectionStart`in r&&wr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Or&&yr(Or,r)||(Or=r,r=Td(Dr,`onSelect`),0>=o,i-=o,Si=1<<32-R(t)+i|n<h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),H&&wi(i,h),l;if(d===null){for(;hg?(_=h,h=null):_=h.sibling;var y=p(i,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(i,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(i,h),H&&wi(i,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(i,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return H&&wi(i,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,i,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(i,e)}),H&&wi(i,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===_&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case h:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===_){if(r.tag===7){n(e,r.sibling),c=i(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===E&&Sa(l)===r.type){n(e,r.sibling),c=i(r,o.props),ka(c,o),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}o.type===_?(c=li(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=ci(o.type,o.key,o.props,null,e.mode,c),ka(c,o),c.return=e,e=c)}return s(e);case g:a:{for(l=o.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=i(r,o.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=fi(o,e.mode,c),c.return=e,e=c}return s(e);case E:return o=Sa(o),b(e,r,o,c)}if(M(o))return v(e,r,o,c);if(A(o)){if(l=A(o),typeof l!=`function`)throw Error(a(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,Oa(o),c);if(o.$$typeof===x)return b(e,r,W(e,o),c);Aa(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=i(r,o),c.return=e,e=c):(n(e,r),c=ui(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Da=0;var i=b(e,t,n,r);return Ea=null,i}catch(t){if(t===ga||t===va)throw t;var a=ii(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ma=ja(!0),Na=ja(!1),Pa=!1;function Fa(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ia(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function La(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ra(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,q&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=ti(e),ei(e,null,n),t}return Zr(e,r,t,n),ti(e)}function za(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ze(e,n)}}function Ba(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Va=!1;function Ha(){if(Va){var e=sa;if(e!==null)throw e}}function Ua(e,t,n,r){Va=!1;var i=e.updateQueue;Pa=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,m=f!==s.lane;if(m?(Y&f)===f:(r&f)===f){f!==0&&f===oa&&(Va=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,f);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,f=typeof h==`function`?h.call(_,d,f):h,f==null)break a;d=p({},d,f);break a;case 2:Pa=!0}}f=s.callback,f!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[f]:m.push(f))}else m={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Gl|=o,e.lanes=o,e.memoizedState=d}}function Wa(e,t){if(typeof e!=`function`)throw Error(a(191,e));e.call(t)}function Ga(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;ea?a:8;var o=N.T,s={};N.T=s,js(e,!1,t,n);try{var c=i(),l=N.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?As(e,t,ua(c,r),pu(e)):As(e,t,r,pu(e))}catch(n){As(e,t,{then:function(){},status:`rejected`,reason:n},pu())}finally{P.p=a,o!==null&&s.types!==null&&(o.types=s.types),N.T=o}}function bs(){}function xs(e,t,n,r){if(e.tag!==5)throw Error(a(476));var i=Ss(e).queue;ys(e,i,t,te,n===null?bs:function(){return Cs(e),n(r)})}function Ss(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:te,baseState:te,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Mo,lastRenderedState:te},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Mo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Cs(e){var t=Ss(e);t.next===null&&(t=e.alternate.memoizedState),As(e,t.next.queue,{},pu())}function ws(){return U(Qf)}function Ts(){return Do().memoizedState}function Es(){return Do().memoizedState}function Ds(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=pu();e=La(n);var r=Ra(t,e,n);r!==null&&(hu(r,t,n),za(r,t,n)),t={cache:na()},e.payload=t;return}t=t.return}}function Os(e,t,n){var r=pu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Ms(e)?Ns(t,n):(n=Qr(e,t,n,r),n!==null&&(hu(n,e,r),Ps(n,t,r)))}function ks(e,t,n){As(e,t,n,pu())}function As(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Ms(e))Ns(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,vr(s,o))return Zr(e,t,i,0),Rl===null&&Xr(),!1}catch{}if(n=Qr(e,t,i,r),n!==null)return hu(n,e,r),Ps(n,t,r),!0}return!1}function js(e,t,n,r){if(r={lane:2,revertLane:ud(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Ms(e)){if(t)throw Error(a(479))}else t=Qr(e,n,r,2),t!==null&&hu(t,e,2)}function Ms(e){var t=e.alternate;return e===K||t!==null&&t===K}function Ns(e,t){uo=lo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ps(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ze(e,n)}}var Fs={readContext:U,use:Ao,useCallback:_o,useContext:_o,useEffect:_o,useImperativeHandle:_o,useLayoutEffect:_o,useInsertionEffect:_o,useMemo:_o,useReducer:_o,useRef:_o,useState:_o,useDebugValue:_o,useDeferredValue:_o,useTransition:_o,useSyncExternalStore:_o,useId:_o,useHostTransitionStatus:_o,useFormState:_o,useActionState:_o,useOptimistic:_o,useMemoCache:_o,useCacheRefresh:_o};Fs.useEffectEvent=_o;var Is={readContext:U,use:Ao,useCallback:function(e,t){return Eo().memoizedState=[e,t===void 0?null:t],e},useContext:U,useEffect:os,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),is(4194308,4,fs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return is(4194308,4,e,t)},useInsertionEffect:function(e,t){is(4,2,e,t)},useMemo:function(e,t){var n=Eo();t=t===void 0?null:t;var r=e();if(fo){Fe(!0);try{e()}finally{Fe(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Eo();if(n!==void 0){var i=n(t);if(fo){Fe(!0);try{n(t)}finally{Fe(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Os.bind(null,K,e),[r.memoizedState,e]},useRef:function(e){var t=Eo();return e={current:e},t.memoizedState=e},useState:function(e){e=Ho(e);var t=e.queue,n=ks.bind(null,K,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:ms,useDeferredValue:function(e,t){return _s(Eo(),e,t)},useTransition:function(){var e=Ho(!1);return e=ys.bind(null,K,e.queue,!0,!1),Eo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=K,i=Eo();if(H){if(n===void 0)throw Error(a(407));n=n()}else{if(n=t(),Rl===null)throw Error(a(349));Y&127||Lo(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,os(zo.bind(null,r,o,e),[e]),r.flags|=2048,ns(9,{destroy:void 0},Ro.bind(null,r,o,n,t),null),n},useId:function(){var e=Eo(),t=Rl.identifierPrefix;if(H){var n=Ci,r=Si;n=(r&~(1<<32-R(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=po++,0<\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(i,{is:r.is}):s.createElement(i)}}o[B]=t,o[it]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Pd(o,i,r),i){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Ac(t)}}return Fc(t),jc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Ac(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(a(166));if(e=se.current,Li(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,i=ki,i!==null)switch(i.tag){case 27:case 5:r=i.memoizedProps}e[B]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||Pi(t,!0)}else e=Bd(e).createTextNode(r),e[B]=t,t.stateNode=e}return Fc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Li(t),n!==null){if(e===null){if(!r)throw Error(a(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(557));e[B]=t}else Ri(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Fc(t),e=!1}else n=zi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(ro(t),t):(ro(t),null);if(t.flags&128)throw Error(a(558))}return Fc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=Li(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(a(318));if(i=t.memoizedState,i=i===null?null:i.dehydrated,!i)throw Error(a(317));i[B]=t}else Ri(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Fc(t),i=!1}else i=zi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return t.flags&256?(ro(t),t):(ro(t),null)}return ro(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,i=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(i=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==i&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Nc(t,t.updateQueue),Fc(t),null);case 4:return ue(),e===null&&xd(t.stateNode.containerInfo),Fc(t),null;case 10:return Gi(t.type),Fc(t),null;case 19:if(F(io),r=t.memoizedState,r===null)return Fc(t),null;if(i=(t.flags&128)!=0,o=r.rendering,o===null)if(i)Pc(r,!1);else{if(Wl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=ao(e),o!==null){for(t.flags|=128,Pc(r,!1),e=o.updateQueue,t.updateQueue=e,Nc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)si(n,e),n=n.sibling;return I(io,io.current&1|2),H&&wi(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&Te()>tu&&(t.flags|=128,i=!0,Pc(r,!1),t.lanes=4194304)}else{if(!i)if(e=ao(o),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Nc(t,e),Pc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!H)return Fc(t),null}else 2*Te()-r.renderingStartTime>tu&&n!==536870912&&(t.flags|=128,i=!0,Pc(r,!1),t.lanes=4194304);r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Fc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=Te(),e.sibling=null,n=io.current,I(io,i?n&1|2:n&1),H&&wi(t,r.treeForkCount),e);case 22:case 23:return ro(t),Xa(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Fc(t),t.subtreeFlags&6&&(t.flags|=8192)):Fc(t),n=t.updateQueue,n!==null&&Nc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&F(fa),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Gi(ta),Fc(t),null;case 25:return null;case 30:return null}throw Error(a(156,t.tag))}function Lc(e,t){switch(Di(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Gi(ta),ue(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return fe(t),null;case 31:if(t.memoizedState!==null){if(ro(t),t.alternate===null)throw Error(a(340));Ri()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(ro(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(a(340));Ri()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return F(io),null;case 4:return ue(),null;case 10:return Gi(t.type),null;case 22:case 23:return ro(t),Xa(),e!==null&&F(fa),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Gi(ta),null;case 25:return null;default:return null}}function Rc(e,t){switch(Di(t),t.tag){case 3:Gi(ta),ue();break;case 26:case 27:case 5:fe(t);break;case 4:ue();break;case 31:t.memoizedState!==null&&ro(t);break;case 13:ro(t);break;case 19:F(io);break;case 10:Gi(t.type);break;case 22:case 23:ro(t),Xa(),e!==null&&F(fa);break;case 24:Gi(ta)}}function zc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Z(t,t.return,e)}}function Bc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Z(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Z(t,t.return,e)}}function Vc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Ga(t,n)}catch(t){Z(e,e.return,t)}}}function Hc(e,t,n){n.props=Us(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Z(e,t,n)}}function Uc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Z(e,t,n)}}function Wc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){Z(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Z(e,t,n)}else n.current=null}function Gc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Z(e,e.return,t)}}function Kc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[it]=t}catch(t){Z(e,e.return,t)}}function qc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function Jc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||qc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Yc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Xt));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Yc(e,t,n),e=e.sibling;e!==null;)Yc(e,t,n),e=e.sibling}function Xc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Xc(e,t,n),e=e.sibling;e!==null;)Xc(e,t,n),e=e.sibling}function Zc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[B]=e,t[it]=n}catch(t){Z(e,e.return,t)}}var Qc=!1,$c=!1,el=!1,tl=typeof WeakSet==`function`?WeakSet:Set,nl=null;function rl(e,t){if(e=e.containerInfo,Rd=sp,e=Cr(e),wr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||i!==0&&f.nodeType!==3||(c=s+i),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===i&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,nl=t;nl!==null;)if(t=nl,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,nl=e;else for(;nl!==null;){switch(t=nl,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n title`))),Pd(o,r,n),o[B]=e,gt(o),r=o;break a;case`link`:var s=Vf(`link`,`href`,i).get(r+(n.href||``));if(s){for(var c=0;cg&&(o=g,g=h,h=o);var _=xr(s,h),v=xr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;sn?32:n,N.T=null,n=lu,lu=null;var o=au,s=su;if(iu=0,ou=au=null,su=0,q&6)throw Error(a(331));var c=q;if(q|=4,Nl(o.current),Tl(o,o.current,s,n),q=c,id(0,!1),L&&typeof L.onPostCommitFiberRoot==`function`)try{L.onPostCommitFiberRoot(Pe,o)}catch{}return!0}finally{P.p=i,N.T=r,Vu(e,t)}}function Wu(e,t,n){t=mi(n,t),t=Ys(e.stateNode,t,2),e=Ra(e,t,2),e!==null&&(Je(e,2),rd(e))}function Z(e,t,n){if(e.tag===3)Wu(e,e,n);else for(;t!==null;){if(t.tag===3){Wu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(ru===null||!ru.has(r))){e=mi(n,e),n=Xs(2),r=Ra(t,n,2),r!==null&&(Zs(n,r,t,e),Je(r,2),rd(r));break}}t=t.return}}function Gu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Ll;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Hl=!0,i.add(n),e=Ku.bind(null,e,t,n),t.then(e,e))}function Ku(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Rl===e&&(Y&n)===n&&(Wl===4||Wl===3&&(Y&62914560)===Y&&300>Te()-$l?!(q&2)&&Su(e,0):ql|=n,Yl===Y&&(Yl=0)),rd(e)}function qu(e,t){t===0&&(t=Ke()),e=$r(e,t),e!==null&&(Je(e,t),rd(e))}function Ju(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),qu(e,n)}function Yu(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(a(314))}r!==null&&r.delete(t),qu(e,n)}function Xu(e,t){return xe(e,t)}var Zu=null,Qu=null,$u=!1,ed=!1,td=!1,nd=0;function rd(e){e!==Qu&&e.next===null&&(Qu===null?Zu=Qu=e:Qu=Qu.next=e),ed=!0,$u||($u=!0,ld())}function id(e,t){if(!td&&ed){td=!0;do for(var n=!1,r=Zu;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-R(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,cd(r,a))}else a=Y,a=Ue(r,r===Rl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||We(r,a)||(n=!0,cd(r,a));r=r.next}while(n);td=!1}}function ad(){Q()}function Q(){ed=$u=!1;var e=0;nd!==0&&Gd()&&(e=nd);for(var t=Te(),n=null,r=Zu;r!==null;){var i=r.next,a=od(r,t);a===0?(r.next=null,n===null?Zu=i:n.next=i,i===null&&(Qu=n)):(n=r,(e!==0||a&3)&&(ed=!0)),r=i}iu!==0&&iu!==5||id(e,!1),nd!==0&&(nd=0)}function od(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=Ft(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),gt(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Ft(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Ft(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Ft(n.imageSizes)+`"]`)):i+=`[href="`+Ft(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=p({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),gt(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Ft(r)+`"][href="`+Ft(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=p({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),gt(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=ht(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=p({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);gt(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=ht(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=p({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),gt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=ht(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=p({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),gt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var i=(i=se.current)?gf(i):null;if(!i)throw Error(a(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=ht(i).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var o=ht(i).hoistableStyles,s=o.get(e);if(s||(i=i.ownerDocument||i,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=i.querySelector(jf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),o||Nf(i,e,n,s.state))),t&&r===null)throw Error(a(528,``));return s}if(t&&r!==null)throw Error(a(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=ht(i).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(a(444,e))}}function Af(e){return`href="`+Ft(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return p({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),gt(t),e.head.appendChild(t))}function Pf(e){return`[src="`+Ft(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Ft(n.href)+`"]`);if(r)return t.instance=r,gt(r),r;var i=p({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),gt(r),Pd(r,`style`,i),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:i=Af(n.href);var o=e.querySelector(jf(i));if(o)return t.state.loading|=4,t.instance=o,gt(o),o;r=Mf(n),(i=mf.get(i))&&Rf(r,i),o=(e.ownerDocument||e).createElement(`link`),gt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Pd(o,`link`,r),t.state.loading|=4,Lf(o,n.precedence,e),t.instance=o;case`script`:return o=Pf(n.src),(i=e.querySelector(Ff(o)))?(t.instance=i,gt(i),i):(r=n,(i=mf.get(o))&&(r=p({},n),zf(r,i)),e=e.ownerDocument||e,i=e.createElement(`script`),gt(i),Pd(i,`link`,r),e.head.appendChild(i),t.instance=i);case`void`:return null;default:throw Error(a(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o title`):null)}function Uf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,gt(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),gt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a{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)}}n(),t.exports=qa()}))(),1),G=i(),Ya=(0,U.createContext)(void 0);function Xa(e,t){try{let t=localStorage.getItem(e);if(t===`light`||t===`dark`||t===`system`)return t}catch{}return t}function Za(e){let t=(0,G.c)(14),{children:n,defaultTheme:r,storageKey:i}=e,a=r===void 0?`dark`:r,o=i===void 0?`ui-theme`:i,s;t[0]!==a||t[1]!==o?(s=()=>Xa(o,a),t[0]=a,t[1]=o,t[2]=s):s=t[2];let[c,l]=(0,U.useState)(s),u,d;t[3]===c?(u=t[4],d=t[5]):(u=()=>{let e=window.document.documentElement;if(e.classList.remove(`light`,`dark`),c===`system`){let t=window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`;e.classList.add(t);return}e.classList.add(c)},d=[c],t[3]=c,t[4]=u,t[5]=d),(0,U.useEffect)(u,d);let f;t[6]===o?f=t[7]:(f=e=>{try{localStorage.setItem(o,e)}catch{}l(e)},t[6]=o,t[7]=f);let p;t[8]!==f||t[9]!==c?(p={theme:c,setTheme:f},t[8]=f,t[9]=c,t[10]=p):p=t[10];let m=p,h;return t[11]!==n||t[12]!==m?(h=(0,W.jsx)(Ya.Provider,{value:m,children:n}),t[11]=n,t[12]=m,t[13]=h):h=t[13],h}function Qa(){let e=(0,U.useContext)(Ya);if(e===void 0)throw Error(`useTheme must be used within a ThemeProvider`);return e}function $a(e){return Ue(e.defaultTagName??`div`,e,e)}var eo=tt(`activity`,[[`path`,{d:`M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2`,key:`169zse`}]]),to=tt(`book-open`,[[`path`,{d:`M12 7v14`,key:`1akyts`}],[`path`,{d:`M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z`,key:`ruj8y`}]]),no=tt(`camera`,[[`path`,{d:`M13.997 4a2 2 0 0 1 1.76 1.05l.486.9A2 2 0 0 0 18.003 7H20a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h1.997a2 2 0 0 0 1.759-1.048l.489-.904A2 2 0 0 1 10.004 4z`,key:`18u6gg`}],[`circle`,{cx:`12`,cy:`13`,r:`3`,key:`1vg3eu`}]]),ro=tt(`circle-alert`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`line`,{x1:`12`,x2:`12`,y1:`8`,y2:`12`,key:`1pkeuh`}],[`line`,{x1:`12`,x2:`12.01`,y1:`16`,y2:`16`,key:`4dfq90`}]]),io=tt(`hard-drive`,[[`path`,{d:`M10 16h.01`,key:`1bzywj`}],[`path`,{d:`M2.212 11.577a2 2 0 0 0-.212.896V18a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-5.527a2 2 0 0 0-.212-.896L18.55 5.11A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z`,key:`18tbho`}],[`path`,{d:`M21.946 12.013H2.054`,key:`zqlbp7`}],[`path`,{d:`M6 16h.01`,key:`1pmjb7`}]]),ao=tt(`house`,[[`path`,{d:`M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8`,key:`5wwlr5`}],[`path`,{d:`M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,key:`r6nss1`}]]),oo=tt(`image`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,ry:`2`,key:`1m3agn`}],[`circle`,{cx:`9`,cy:`9`,r:`2`,key:`af1f0g`}],[`path`,{d:`m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21`,key:`1xmnt7`}]]),K=tt(`key`,[[`path`,{d:`m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4`,key:`g0fldk`}],[`path`,{d:`m21 2-9.6 9.6`,key:`1j0ho8`}],[`circle`,{cx:`7.5`,cy:`15.5`,r:`5.5`,key:`yqb3hr`}]]),so=tt(`layers`,[[`path`,{d:`M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z`,key:`zw3jo`}],[`path`,{d:`M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12`,key:`1wduqc`}],[`path`,{d:`M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17`,key:`kqbvx6`}]]),co=tt(`layout-grid`,[[`rect`,{width:`7`,height:`7`,x:`3`,y:`3`,rx:`1`,key:`1g98yp`}],[`rect`,{width:`7`,height:`7`,x:`14`,y:`3`,rx:`1`,key:`6d4xhi`}],[`rect`,{width:`7`,height:`7`,x:`14`,y:`14`,rx:`1`,key:`nxv5o0`}],[`rect`,{width:`7`,height:`7`,x:`3`,y:`14`,rx:`1`,key:`1bb6yr`}]]),lo=tt(`log-out`,[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]),uo=tt(`moon`,[[`path`,{d:`M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401`,key:`kfwtm`}]]),fo=tt(`network`,[[`rect`,{x:`16`,y:`16`,width:`6`,height:`6`,rx:`1`,key:`4q2zg0`}],[`rect`,{x:`2`,y:`16`,width:`6`,height:`6`,rx:`1`,key:`8cvhb9`}],[`rect`,{x:`9`,y:`2`,width:`6`,height:`6`,rx:`1`,key:`1egb70`}],[`path`,{d:`M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3`,key:`1jsf9p`}],[`path`,{d:`M12 12V8`,key:`2874zd`}]]),po=tt(`panel-left`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}]]),mo=tt(`server`,[[`rect`,{width:`20`,height:`8`,x:`2`,y:`2`,rx:`2`,ry:`2`,key:`ngkwjq`}],[`rect`,{width:`20`,height:`8`,x:`2`,y:`14`,rx:`2`,ry:`2`,key:`iecqi9`}],[`line`,{x1:`6`,x2:`6.01`,y1:`6`,y2:`6`,key:`16zg32`}],[`line`,{x1:`6`,x2:`6.01`,y1:`18`,y2:`18`,key:`nzw8ys`}]]),ho=tt(`shield-check`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}],[`path`,{d:`m9 12 2 2 4-4`,key:`dzmm74`}]]),go=tt(`shield`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}]]),_o=tt(`sun`,[[`circle`,{cx:`12`,cy:`12`,r:`4`,key:`4exip2`}],[`path`,{d:`M12 2v2`,key:`tus03m`}],[`path`,{d:`M12 20v2`,key:`1lh1kg`}],[`path`,{d:`m4.93 4.93 1.41 1.41`,key:`149t6j`}],[`path`,{d:`m17.66 17.66 1.41 1.41`,key:`ptbguv`}],[`path`,{d:`M2 12h2`,key:`1t8f8n`}],[`path`,{d:`M20 12h2`,key:`1q8mjw`}],[`path`,{d:`m6.34 17.66-1.41 1.41`,key:`1m8zz5`}],[`path`,{d:`m19.07 4.93-1.41 1.41`,key:`1shlcs`}]]),vo=tt(`users`,[[`path`,{d:`M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2`,key:`1yyitq`}],[`path`,{d:`M16 3.128a4 4 0 0 1 0 7.744`,key:`16gr8j`}],[`path`,{d:`M22 21v-2a4 4 0 0 0-3-3.87`,key:`kshegd`}],[`circle`,{cx:`9`,cy:`7`,r:`4`,key:`nufk8`}]]),yo=tt(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),bo=U.forwardRef(function(e,t){let{render:n,className:r,id:i,name:a,value:o,disabled:s=!1,onValueChange:c,defaultValue:l,autoFocus:u=!1,...d}=e,{state:f,name:p,disabled:m,setTouched:h,setDirty:g,validityData:_,setFocused:v,setFilled:y,validationMode:b,validation:x}=Ot(),S=m||s,C=p??a,w={...f,disabled:S},{labelId:T}=Ct(),E=Dt({id:i});lt(()=>{let e=o!=null;x.inputRef.current?.value||e&&o!==``?y(!0):e&&o===``&&y(!1)},[x.inputRef,y,o]);let D=U.useRef(null);lt(()=>{u&&D.current===Bt(At(D.current))&&v(!0)},[u,v]);let[O]=Tt({controlled:o,default:l,name:`FieldControl`,state:`value`}),k=o!==void 0,A=k?O:void 0;return Et({id:E,name:C,commit:x.commit,value:A,getValue:()=>x.inputRef.current?.value,controlRef:x.inputRef}),Ue(`input`,e,{ref:[t,D],state:w,props:[{id:E,disabled:S,name:C,ref:x.inputRef,"aria-labelledby":T,autoFocus:u,...k?{value:A}:{defaultValue:l},onChange(e){let t=e.currentTarget.value;c?.(t,Gt(Kt,e.nativeEvent)),g(t!==_.initialValue),y(t!==``)},onFocus(){v(!0)},onBlur(e){h(!0),v(!1),b===`onBlur`&&x.commit(e.currentTarget.value)},onKeyDown(e){e.currentTarget.tagName===`INPUT`&&e.key===`Enter`&&(h(!0),x.commit(e.currentTarget.value))}},x.getInputValidationProps(),d],stateAttributesMapping:wt})}),xo=U.forwardRef(function(e,t){return(0,W.jsx)(bo,{ref:t,...e})});function So(e){let t=(0,G.c)(10),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({className:n,type:i,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let a;t[4]===n?a=t[5]:(a=qe(`h-7 w-full min-w-0 rounded-md border border-input bg-input/20 px-2 py-0.5 text-sm transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-xs/relaxed file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-2 focus-visible:ring-ring/30 disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-2 aria-invalid:ring-destructive/20 md:text-xs/relaxed dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40`,n),t[4]=n,t[5]=a);let o;return t[6]!==r||t[7]!==a||t[8]!==i?(o=(0,W.jsx)(xo,{className:a,"data-slot":`input`,type:i,...r}),t[6]=r,t[7]=a,t[8]=i,t[9]=o):o=t[9],o}var Co=U.createContext(void 0);function wo(e){let t=U.useContext(Co);if(e===!1&&t===void 0)throw Error(He(27));return t}var To={...Dn,...Xt},Eo=U.forwardRef(function(e,t){let{render:n,className:r,forceRender:i=!1,...a}=e,{store:o}=wo(),s=o.useState(`open`),c=o.useState(`nested`),l=o.useState(`mounted`);return Ue(`div`,e,{state:{open:s,transitionStatus:o.useState(`transitionStatus`)},ref:[o.context.backdropRef,t],stateAttributesMapping:To,props:[{role:`presentation`,hidden:!l,style:{userSelect:`none`,WebkitUserSelect:`none`}},a],enabled:i||!c})}),Do=U.forwardRef(function(e,t){let{render:n,className:r,disabled:i=!1,nativeButton:a=!0,...o}=e,{store:s}=wo(),c=s.useState(`open`);function l(e){c&&s.setOpen(!1,Gt(Ut,e.nativeEvent))}let{getButtonProps:u,buttonRef:d}=ht({disabled:i,native:a});return Ue(`button`,e,{state:{disabled:i},ref:[t,d],props:[{onClick:l},o,u]})}),Oo=U.forwardRef(function(e,t){let{render:n,className:r,id:i,...a}=e,{store:o}=wo(),s=Lt(i);return o.useSyncedValueWithCleanup(`descriptionElementId`,s),Ue(`p`,e,{ref:t,props:[{id:s},a]})});function ko(e,t){return t!=null&&!kn(t)?0:typeof e==`function`?e():e}function Ao(e,t,n){let r=ko(e,n);return typeof r==`number`?r:r?.[t]}function jo(e){return typeof e==`function`?e():e}function Mo(e,t){return t||e===`click`||e===`mousedown`}var No=U.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new jn,currentIdRef:{current:null},currentContextRef:{current:null}});function Po(e){let{children:t,delay:n,timeoutMs:r=0}=e,i=U.useRef(n),a=U.useRef(n),o=U.useRef(null),s=U.useRef(null),c=Cn();return(0,W.jsx)(No.Provider,{value:U.useMemo(()=>({hasProvider:!0,delayRef:i,initialDelayRef:a,currentIdRef:o,timeoutMs:r,currentContextRef:s,timeout:c}),[r,c]),children:t})}function Fo(e,t={open:!1}){let n=`rootStore`in e?e.rootStore:e,r=n.useState(`floatingId`),{open:i}=t,{currentIdRef:a,delayRef:o,timeoutMs:s,initialDelayRef:c,currentContextRef:l,hasProvider:u,timeout:d}=U.useContext(No),[f,p]=U.useState(!1);return lt(()=>{function e(){p(!1),l.current?.setIsInstantPhase(!1),a.current=null,l.current=null,o.current=c.current}if(a.current&&!i&&a.current===r){if(p(!1),s){let t=r;return d.start(s,()=>{n.select(`open`)||a.current&&a.current!==t||e()}),()=>{d.clear()}}e()}},[i,r,a,o,s,c,l,d,n]),lt(()=>{if(!i)return;let e=l.current,t=a.current;d.clear(),l.current={onOpenChange:n.setOpen,setIsInstantPhase:p},a.current=r,o.current={open:0,close:Ao(c.current,`close`)},t!==null&&t!==r?(p(!0),e?.setIsInstantPhase(!0),e?.onOpenChange(!1,Gt(Kt))):(p(!1),e?.setIsInstantPhase(!1))},[i,r,n,a,o,s,c,l,d]),lt(()=>()=>{l.current=null},[l]),U.useMemo(()=>({hasProvider:u,delayRef:o,isInstantPhase:f}),[u,o,f])}function Io(e,t){let n=null,r=null,i=!1;return{contextElement:e||void 0,getBoundingClientRect(){let a=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},o=t.axis===`x`||t.axis===`both`,s=t.axis===`y`||t.axis===`both`,c=[`mouseenter`,`mousemove`].includes(t.dataRef.current.openEvent?.type||``)&&t.pointerType!==`touch`,l=a.width,u=a.height,d=a.x,f=a.y;return n==null&&t.x&&o&&(n=a.x-t.x),r==null&&t.y&&s&&(r=a.y-t.y),d-=n||0,f-=r||0,l=0,u=0,!i||c?(l=t.axis===`y`?a.width:0,u=t.axis===`x`?a.height:0,d=o&&t.x!=null?t.x:d,f=s&&t.y!=null?t.y:f):i&&!c&&(u=t.axis===`x`?a.height:u,l=t.axis===`y`?a.width:l),i=!0,{width:l,height:u,x:d,y:f,top:f,right:d+l,bottom:f+u,left:d}}}}function Lo(e){return e!=null&&e.clientX!=null}function Ro(e,t={}){let n=`rootStore`in e?e.rootStore:e,r=n.useState(`open`),i=n.useState(`floatingElement`),a=n.useState(`domReferenceElement`),o=n.context.dataRef,{enabled:s=!0,axis:c=`both`}=t,l=U.useRef(!1),u=U.useRef(null),[d,f]=U.useState(),[p,m]=U.useState([]),h=pt((e,t,r)=>{l.current||o.current.openEvent&&!Lo(o.current.openEvent)||n.set(`positionReference`,Io(r??a,{x:e,y:t,axis:c,dataRef:o,pointerType:d}))}),g=pt(e=>{r?u.current||m([]):h(e.clientX,e.clientY,e.currentTarget)}),_=kn(d)?i:r,v=U.useCallback(()=>{if(!_||!s)return;let e=ct(i);function t(n){Rt(i,Yt(n))?(e.removeEventListener(`mousemove`,t),u.current=null):h(n.clientX,n.clientY)}if(!o.current.openEvent||Lo(o.current.openEvent)){e.addEventListener(`mousemove`,t);let n=()=>{e.removeEventListener(`mousemove`,t),u.current=null};return u.current=n,n}n.set(`positionReference`,a)},[_,s,i,o,a,n,h]);U.useEffect(()=>v(),[v,p]),U.useEffect(()=>{s&&!i&&(l.current=!1)},[s,i]),U.useEffect(()=>{!s&&r&&(l.current=!0)},[s,r]);let y=U.useMemo(()=>{function e(e){f(e.pointerType)}return{onPointerDown:e,onPointerEnter:e,onMouseMove:g,onMouseEnter:g}},[g]);return U.useMemo(()=>s?{reference:y,trigger:y}:{},[s,y])}function zo(e,t,n){let{reference:r,floating:i}=e,a=Mn(t),o=Ln(t),s=mn(o),c=Un(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(cn(t)){case`start`:p[o]-=f*(n&&l?-1:1);break;case`end`:p[o]+=f*(n&&l?-1:1);break}return p}async function Bo(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=fn(t,e),p=xn(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=vn(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=vn(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var Vo=50,Ho=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:Bo},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=zo(l,r,c),f=r,p=0,m={};for(let n=0;ne<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(!(u===`alignment`&&_!==Mn(t))||T.every(e=>Mn(e.placement)===_?e.overflows[0]>0:!0)))return{data:{index:e,overflows:T},reset:{placement:t}};let n=T.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=T.filter(e=>{if(x){let t=Mn(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o;break}if(r!==n)return{reset:{placement:n}}}return{}}}};function Wo(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Go(e){return Vn.some(t=>e[t]>=0)}var Ko=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=fn(e,t);switch(i){case`referenceHidden`:{let e=Wo(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:Go(e)}}}case`escaped`:{let e=Wo(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:Go(e)}}}default:return{}}}}},qo=new Set([`left`,`top`]);async function Jo(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Un(n),s=cn(n),c=Mn(n)===`y`,l=qo.has(o)?-1:1,u=a&&c?-1:1,d=fn(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var Yo=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await Jo(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},Xo=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=fn(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=Mn(Un(i)),p=hn(f),m=u[p],h=u[f];if(o){let e=p===`y`?`top`:`left`,t=p===`y`?`bottom`:`right`,n=m+d[e],r=m-d[t];m=on(n,m,r)}if(s){let e=f===`y`?`top`:`left`,t=f===`y`?`bottom`:`right`,n=h+d[e],r=h-d[t];h=on(n,h,r)}let g=c.fn({...t,[p]:m,[f]:h});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:o,[f]:s}}}}}},Zo=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=fn(e,t),u={x:n,y:r},d=Mn(i),f=hn(d),p=u[f],m=u[d],h=fn(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;pn&&(p=n)}if(l){let e=f===`y`?`width`:`height`,t=qo.has(Un(i)),n=a.reference[d]-a.floating[e]+(t&&o.offset?.[d]||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:o.offset?.[d]||0)-(t?g.crossAxis:0);mr&&(m=r)}return{[f]:p,[d]:m}}}},Qo=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){var n,r;let{placement:i,rects:a,platform:o,elements:s}=t,{apply:c=()=>{},...l}=fn(e,t),u=await o.detectOverflow(t,l),d=Un(i),f=cn(i),p=Mn(i)===`y`,{width:m,height:h}=a.floating,g,_;d===`top`||d===`bottom`?(g=d,_=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(_=d,g=f===`end`?`top`:`bottom`);let v=h-u.top-u.bottom,y=m-u.left-u.right,b=Tn(h-u[g],v),x=Tn(m-u[_],y),S=!t.middlewareData.shift,C=b,w=x;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(w=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=v),S&&!f){let e=zn(u.left,0),t=zn(u.right,0),n=zn(u.top,0),r=zn(u.bottom,0);p?w=m-2*(e!==0||t!==0?e+t:zn(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:zn(u.top,u.bottom))}await c({...t,availableWidth:w,availableHeight:C});let T=await o.getDimensions(s.floating);return m!==T.width||h!==T.height?{reset:{rects:!0}}:{}}}};function $o(e){let t=gt(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=yt(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Pn(n)!==a||Pn(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function es(e){return B(e)?e:e.contextElement}function ts(e){let t=es(e);if(!yt(t))return dn(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=$o(t),o=(a?Pn(n.width):n.width)/r,s=(a?Pn(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var ns=dn(0);function rs(e){let t=ct(e);return!rt()||!t.visualViewport?ns:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function is(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==ct(e)?!1:t}function as(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=es(e),o=dn(1);t&&(r?B(r)&&(o=ts(r)):o=ts(e));let s=is(a,n,r)?rs(a):dn(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=ct(a),t=r&&B(r)?ct(r):r,n=e,i=vt(n);for(;i&&r&&t!==n;){let e=ts(i),t=i.getBoundingClientRect(),r=gt(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=ct(i),i=vt(n)}}return vn({width:u,height:d,x:c,y:l})}function os(e,t){let n=ot(e).scrollLeft;return t?t.left+n:as(ut(e)).left+n}function ss(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-os(e,n),y:n.top+t.scrollTop}}function cs(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=ut(r),s=t?bt(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=dn(1),u=dn(0),d=yt(r);if((d||!d&&!a)&&((at(r)!==`body`||xt(o))&&(c=ot(r)),d)){let e=as(r);l=ts(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?ss(o,c):dn(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function ls(e){return Array.from(e.getClientRects())}function us(e){let t=ut(e),n=ot(e),r=e.ownerDocument.body,i=zn(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=zn(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+os(e),s=-n.scrollTop;return gt(r).direction===`rtl`&&(o+=zn(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var ds=25;function fs(e,t){let n=ct(e),r=ut(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=rt();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=os(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=ds&&(a-=o)}else l<=ds&&(a+=l);return{width:a,height:o,x:s,y:c}}function ps(e,t){let n=as(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=yt(e)?ts(e):dn(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function ms(e,t,n){let r;if(t===`viewport`)r=fs(e,n);else if(t===`document`)r=us(ut(e));else if(B(t))r=ps(t,n);else{let n=rs(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return vn(r)}function hs(e,t){let n=dt(e);return n===t||!B(n)||St(n)?!1:gt(n).position===`fixed`||hs(n,t)}function gs(e,t){let n=t.get(e);if(n)return n;let r=mt(e,[],!1).filter(e=>B(e)&&at(e)!==`body`),i=null,a=gt(e).position===`fixed`,o=a?dt(e):e;for(;B(o)&&!St(o);){let t=gt(o),n=st(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||xt(o)&&!n&&hs(e,o))?r=r.filter(e=>e!==o):i=t,o=dt(o)}return t.set(e,r),r}function _s(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?bt(t)?[]:gs(t,this._c):[].concat(n),r],o=ms(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e{o(!1,1e-7)},1e3)}n===1&&!Es(l,e.getBoundingClientRect())&&o(),y=!1}try{n=new IntersectionObserver(b,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(b,v)}n.observe(e)}return o(!0),a}function Os(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=es(e),u=i||a?[...l?mt(l):[],...t?mt(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?Ds(l,n):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?as(e):null;c&&g();function g(){let t=as(e);h&&!Es(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d?.(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var ks=Yo,As=Xo,js=Uo,Ms=Qo,Ns=Ko,Ps=Zo,Fs=(e,t,n)=>{let r=new Map,i={platform:Ts,...n},a={...i.platform,_c:r};return Ho(e,t,{...i,platform:a})},Is=e(Le(),1),Ls=typeof document<`u`?U.useLayoutEffect:function(){};function Rs(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Rs(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!Rs(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function zs(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Bs(e,t){let n=zs(e);return Math.round(t*n)/n}function Vs(e){let t=U.useRef(e);return Ls(()=>{t.current=e}),t}function Hs(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,d]=U.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=U.useState(r);Rs(f,r)||p(r);let[m,h]=U.useState(null),[g,_]=U.useState(null),v=U.useCallback(e=>{e!==S.current&&(S.current=e,h(e))},[]),y=U.useCallback(e=>{e!==C.current&&(C.current=e,_(e))},[]),b=a||m,x=o||g,S=U.useRef(null),C=U.useRef(null),w=U.useRef(u),T=c!=null,E=Vs(c),D=Vs(i),O=Vs(l),k=U.useCallback(()=>{if(!S.current||!C.current)return;let e={placement:t,strategy:n,middleware:f};D.current&&(e.platform=D.current),Fs(S.current,C.current,e).then(e=>{let t={...e,isPositioned:O.current!==!1};A.current&&!Rs(w.current,t)&&(w.current=t,Is.flushSync(()=>{d(t)}))})},[f,t,n,D,O]);Ls(()=>{l===!1&&w.current.isPositioned&&(w.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let A=U.useRef(!1);Ls(()=>(A.current=!0,()=>{A.current=!1}),[]),Ls(()=>{if(b&&(S.current=b),x&&(C.current=x),b&&x){if(E.current)return E.current(b,x,k);k()}},[b,x,k,E,T]);let ee=U.useMemo(()=>({reference:S,floating:C,setReference:v,setFloating:y}),[v,y]),j=U.useMemo(()=>({reference:b,floating:x}),[b,x]),M=U.useMemo(()=>{let e={position:n,left:0,top:0};if(!j.floating)return e;let t=Bs(j.floating,u.x),r=Bs(j.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...zs(j.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,j.floating,u.x,u.y]);return U.useMemo(()=>({...u,update:k,refs:ee,elements:j,floatingStyles:M}),[u,k,ee,j,M])}var Us=(e,t)=>{let n=ks(e);return{name:n.name,fn:n.fn,options:[e,t]}},Ws=(e,t)=>{let n=As(e);return{name:n.name,fn:n.fn,options:[e,t]}},Gs=(e,t)=>({fn:Ps(e).fn,options:[e,t]}),Ks=(e,t)=>{let n=js(e);return{name:n.name,fn:n.fn,options:[e,t]}},qs=(e,t)=>{let n=Ms(e);return{name:n.name,fn:n.fn,options:[e,t]}},Js=(e,t)=>{let n=Ns(e);return{name:n.name,fn:n.fn,options:[e,t]}};function Ys(e,t){let n=U.useRef(null),r=U.useRef(null);return U.useCallback(i=>{if(e!==void 0){if(n.current!==null){let e=n.current,i=r.current,a=t.context.triggerElements.getById(e);i&&a===i&&t.context.triggerElements.delete(e),n.current=null,r.current=null}i!==null&&(n.current=e,r.current=i,t.context.triggerElements.add(e,i))}},[t,e])}function Xs(e,t,n,r){let i=n.useState(`isMountedByTrigger`,e),a=Ys(e,n),o=pt(t=>{if(a(t),!t||!n.select(`open`))return;let i=n.select(`activeTriggerId`);if(i===e){n.update({activeTriggerElement:t,...r});return}i??n.update({activeTriggerId:e,activeTriggerElement:t,...r})});return lt(()=>{i&&n.update({activeTriggerElement:t.current,...r})},[i,n,t,...Object.values(r)]),{registerTrigger:o,isMountedByThisTrigger:i}}function Zs(e){let t=e.useState(`open`);lt(()=>{if(t&&!e.select(`activeTriggerId`)&&e.context.triggerElements.size===1){let t=e.context.triggerElements.entries().next();if(!t.done){let[n,r]=t.value;e.update({activeTriggerId:n,activeTriggerElement:r})}}},[t,e])}function Qs(e,t,n){let{mounted:r,setMounted:i,transitionStatus:a}=$t(e);t.useSyncedValues({mounted:r,transitionStatus:a});let o=pt(()=>{i(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1}),n?.(),t.context.onOpenChangeComplete?.(!1)});return Qt({enabled:!t.useState(`preventUnmountingOnClose`),open:e,ref:t.context.popupRef,onComplete(){e||o()}}),{forceUnmount:o,transitionStatus:a}}function $s(){return new On({open:!1,floatingElement:null,referenceElement:null,triggerElements:new bn,floatingId:``,nested:!1,noEmit:!1,onOpenChange:void 0})}function ec(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:`idle`,floatingRootContext:$s(),preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:Ve,inactiveTriggerProps:Ve,popupProps:Ve}}var tc=V(e=>e.triggerIdProp??e.activeTriggerId),nc={open:V(e=>e.openProp??e.open),mounted:V(e=>e.mounted),transitionStatus:V(e=>e.transitionStatus),floatingRootContext:V(e=>e.floatingRootContext),preventUnmountingOnClose:V(e=>e.preventUnmountingOnClose),payload:V(e=>e.payload),activeTriggerId:tc,activeTriggerElement:V(e=>e.mounted?e.activeTriggerElement:null),isTriggerActive:V((e,t)=>t!==void 0&&tc(e)===t),isOpenedByTrigger:V((e,t)=>t!==void 0&&tc(e)===t&&e.open),isMountedByTrigger:V((e,t)=>t!==void 0&&tc(e)===t&&e.mounted),triggerProps:V((e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps),popupProps:V(e=>e.popupProps),popupElement:V(e=>e.popupElement),positionerElement:V(e=>e.positionerElement)};function rc(e){let{open:t=!1,onOpenChange:n,elements:r={}}=e,i=jt(),a=Gn()!=null,o=Ge(()=>new On({open:t,onOpenChange:n,referenceElement:r.reference??null,floatingElement:r.floating??null,triggerElements:new bn,floatingId:i,nested:a,noEmit:!1})).current;return lt(()=>{let e={open:t,floatingId:i};r.reference!==void 0&&(e.referenceElement=r.reference,e.domReferenceElement=B(r.reference)?r.reference:null),r.floating!==void 0&&(e.floatingElement=r.floating),o.update(e)},[t,i,r.reference,r.floating,o]),o.context.onOpenChange=n,o.context.nested=a,o.context.noEmit=!1,o}function ic(e={}){let{nodeId:t,externalTree:n}=e,r=rc(e),i=e.rootContext||r,a={reference:i.useState(`referenceElement`),floating:i.useState(`floatingElement`),domReference:i.useState(`domReferenceElement`)},[o,s]=U.useState(null),c=U.useRef(null),l=qn(n);lt(()=>{a.domReference&&(c.current=a.domReference)},[a.domReference]);let u=Hs({...e,elements:{...a,...o&&{reference:o}}}),d=U.useCallback(e=>{let t=B(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),getClientRects:()=>e.getClientRects(),contextElement:e}:e;s(t),u.refs.setReference(t)},[u.refs]),[f,p]=U.useState(null),[m,h]=U.useState(null);i.useSyncedValue(`referenceElement`,f),i.useSyncedValue(`domReferenceElement`,B(f)?f:null),i.useSyncedValue(`floatingElement`,m);let g=U.useCallback(e=>{(B(e)||e===null)&&(c.current=e,p(e)),(B(u.refs.reference.current)||u.refs.reference.current===null||e!==null&&!B(e))&&u.refs.setReference(e)},[u.refs,p]),_=U.useCallback(e=>{h(e),u.refs.setFloating(e)},[u.refs]),v=U.useMemo(()=>({...u.refs,setReference:g,setFloating:_,setPositionReference:d,domReference:c}),[u.refs,g,_,d]),y=U.useMemo(()=>({...u.elements,domReference:a.domReference}),[u.elements,a.domReference]),b=i.useState(`open`),x=i.useState(`floatingId`),S=U.useMemo(()=>({...u,dataRef:i.context.dataRef,open:b,onOpenChange:i.setOpen,events:i.context.events,floatingId:x,refs:v,elements:y,nodeId:t,rootStore:i}),[u,v,y,t,i,b,x]);return lt(()=>{i.context.dataRef.current.floatingContext=S;let e=l?.nodesRef.current.find(e=>e.id===t);e&&(e.context=S)}),U.useMemo(()=>({...u,context:S,refs:v,elements:y,rootStore:i}),[u,v,y,S,i])}function ac(e){let{popupStore:t,noEmit:n=!1,treatPopupAsFloatingElement:r=!1,onOpenChange:i}=e,a=jt(),o=Gn()!=null,s=t.useState(`open`),c=t.useState(`activeTriggerElement`),l=t.useState(r?`popupElement`:`positionerElement`),u=t.context.triggerElements,d=Ge(()=>new On({open:s,referenceElement:c,floatingElement:l,triggerElements:u,onOpenChange:i,floatingId:a,nested:o,noEmit:n})).current;return lt(()=>{let e={open:s,floatingId:a,referenceElement:c,floatingElement:l};B(c)&&(e.domReferenceElement=c),d.state.positionReference===d.state.referenceElement&&(e.positionReference=c),d.update(e)},[s,a,c,l,d]),d.context.onOpenChange=i,d.context.nested=o,d.context.noEmit=n,d}var oc=Mt&&Pt;function sc(e,t={}){let n=`rootStore`in e?e.rootStore:e,{events:r,dataRef:i}=n.context,{enabled:a=!0,delay:o}=t,s=U.useRef(!1),c=U.useRef(null),l=Cn(),u=U.useRef(!0);U.useEffect(()=>{let e=n.select(`domReferenceElement`);if(!a)return;let t=ct(e);function r(){let e=n.select(`domReferenceElement`);!n.select(`open`)&&yt(e)&&e===Bt(At(e))&&(s.current=!0)}function i(){u.current=!0}function o(){u.current=!1}return t.addEventListener(`blur`,r),oc&&(t.addEventListener(`keydown`,i,!0),t.addEventListener(`pointerdown`,o,!0)),()=>{t.removeEventListener(`blur`,r),oc&&(t.removeEventListener(`keydown`,i,!0),t.removeEventListener(`pointerdown`,o,!0))}},[n,a]),U.useEffect(()=>{if(!a)return;function e(e){if(e.reason===`trigger-press`||e.reason===`escape-key`){let e=n.select(`domReferenceElement`);B(e)&&(c.current=e,s.current=!0)}}return r.on(`openchange`,e),()=>{r.off(`openchange`,e)}},[r,a,n]);let d=U.useMemo(()=>({onMouseLeave(){s.current=!1,c.current=null},onFocus(e){let t=e.currentTarget;if(s.current){if(c.current===t)return;s.current=!1,c.current=null}let r=Yt(e.nativeEvent);if(B(r)){if(oc&&!e.relatedTarget){if(!u.current&&!Jt(r))return}else if(!It(r))return}let i=Ft(e.relatedTarget,n.context.triggerElements),{nativeEvent:a,currentTarget:d}=e,f=typeof o==`function`?o():o;if(n.select(`open`)&&i||f===0||f===void 0){n.setOpen(!0,Gt(zt,a,d));return}l.start(f,()=>{s.current||n.setOpen(!0,Gt(zt,a,d))})},onBlur(e){s.current=!1,c.current=null;let t=e.relatedTarget,r=e.nativeEvent,a=B(t)&&t.hasAttribute(tn(`focus-guard`))&&t.getAttribute(`data-type`)===`outside`;l.start(0,()=>{let e=n.select(`domReferenceElement`),o=Bt(e?e.ownerDocument:document);!t&&o===e||Rt(i.current.floatingContext?.refs.floating.current,o)||Rt(e,o)||a||Ft(t??o,n.context.triggerElements)||n.setOpen(!1,Gt(zt,r))})}}),[i,n,l,o]);return U.useMemo(()=>a?{reference:d,trigger:d}:{},[a,d])}var cc=`button,a,[role="button"],select,[tabindex]:not([tabindex="-1"]),${Nt}`;function lc(e){return e?!!e.closest(cc):!1}var uc=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new jn,this.restTimeout=new jn,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose};function dc(e){e.performedPointerEventsMutation&&(e.pointerEventsScopeElement?.style.removeProperty(`pointer-events`),e.pointerEventsReferenceElement?.style.removeProperty(`pointer-events`),e.pointerEventsFloatingElement?.style.removeProperty(`pointer-events`),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null)}function fc(e,t){let{scopeElement:n,referenceElement:r,floatingElement:i}=t;dc(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=n,e.pointerEventsReferenceElement=r,e.pointerEventsFloatingElement=i,n.style.pointerEvents=`none`,r.style.pointerEvents=`auto`,i.style.pointerEvents=`auto`}function pc(e){let t=Ge(uc.create).current,n=e.context.dataRef.current;return n.hoverInteractionState||=t,Zt(n.hoverInteractionState.disposeEffect),n.hoverInteractionState}function mc(e,t={}){let n=`rootStore`in e?e.rootStore:e,r=n.useState(`open`),i=n.useState(`floatingElement`),a=n.useState(`domReferenceElement`),{dataRef:o}=n.context,{enabled:s=!0,closeDelay:c=0}=t,l=pc(n),u=qn(),d=Gn(),f=pt(()=>Mo(o.current.openEvent?.type,l.interactedInside)),p=pt(()=>{let e=o.current.openEvent?.type;return e?.includes(`mouse`)&&e!==`mousedown`}),m=pt(e=>Ft(e,n.context.triggerElements)),h=U.useCallback(e=>{let t=Ao(c,`close`,l.pointerType),r=()=>{n.setOpen(!1,Gt(Ht,e)),u?.events.emit(`floating.closed`,e)};t?l.openChangeTimeout.start(t,r):(l.openChangeTimeout.clear(),r())},[c,n,l,u]),g=pt(()=>{dc(l)}),_=pt(e=>{let t=Yt(e);if(!lc(t)){l.interactedInside=!1;return}l.interactedInside=t?.closest(`[aria-haspopup]`)!=null});lt(()=>{r||(l.pointerType=void 0,l.restTimeoutPending=!1,l.interactedInside=!1,g())},[r,l,g]),U.useEffect(()=>g,[g]),lt(()=>{if(s&&r&&l.handleCloseOptions?.blockPointerEvents&&p()&&B(a)&&i){let e=a,t=i,n=At(i),r=u?.nodesRef.current.find(e=>e.id===d)?.context?.elements.floating;return r&&(r.style.pointerEvents=``),fc(l,{scopeElement:l.handleCloseOptions?.getScope?.()??l.pointerEventsScopeElement??r??e.closest(`[data-rootownerid]`)??n.body,referenceElement:e,floatingElement:t}),()=>{g()}}},[s,r,a,i,l,p,u,d,g]);let v=Cn();U.useEffect(()=>{if(!s)return;function e(){l.openChangeTimeout.clear(),v.clear(),u?.events.off(`floating.closed`,r),g()}function t(e){if(u&&d&&In(u.nodesRef.current,d).length>0){u.events.on(`floating.closed`,r);return}if(!m(e.relatedTarget)){if(l.handler){l.handler(e);return}g(),f()||h(e)}}function r(e){!u||!d||In(u.nodesRef.current,d).length>0||v.start(0,()=>{u.events.off(`floating.closed`,r),n.setOpen(!1,Gt(Ht,e)),u.events.emit(`floating.closed`,e)})}let a=i;return a&&(a.addEventListener(`mouseenter`,e),a.addEventListener(`mouseleave`,t),a.addEventListener(`pointerdown`,_,!0)),()=>{a&&(a.removeEventListener(`mouseenter`,e),a.removeEventListener(`mouseleave`,t),a.removeEventListener(`pointerdown`,_,!0)),u?.events.off(`floating.closed`,r)}},[s,i,n,o,f,m,h,g,_,l,u,d,v])}var hc={current:null};function gc(e,t={}){let n=`rootStore`in e?e.rootStore:e,{dataRef:r,events:i}=n.context,{enabled:a=!0,delay:o=0,handleClose:s=null,mouseOnly:c=!1,restMs:l=0,move:u=!0,triggerElementRef:d=hc,externalTree:f,isActiveTrigger:p=!0,getHandleCloseContext:m}=t,h=qn(f),g=pc(n),_=rn(s),v=rn(o),y=rn(l),b=rn(a);p&&(g.handleCloseOptions=_.current?.__options);let x=pt(()=>Mo(r.current.openEvent?.type,g.interactedInside)),S=pt(e=>Ft(e,n.context.triggerElements)),C=pt((e,t,r)=>{let i=n.context.triggerElements;if(i.hasElement(t))return!e||!Rt(e,t);if(!B(r))return!1;let a=r;return i.hasMatchingElement(e=>Rt(e,a))&&(!e||!Rt(e,a))}),w=U.useCallback((e,t=!0)=>{let r=Ao(v.current,`close`,g.pointerType);r?g.openChangeTimeout.start(r,()=>{n.setOpen(!1,Gt(Ht,e)),h?.events.emit(`floating.closed`,e)}):t&&(g.openChangeTimeout.clear(),n.setOpen(!1,Gt(Ht,e)),h?.events.emit(`floating.closed`,e))},[v,n,g,h]),T=pt(()=>{g.handler&&=(At(n.select(`domReferenceElement`)).removeEventListener(`mousemove`,g.handler),void 0)});U.useEffect(()=>T,[T]);let E=pt(()=>{dc(g)});return U.useEffect(()=>{if(!a)return;function e(e){e.open||(T(),g.openChangeTimeout.clear(),g.restTimeout.clear(),g.blockMouseMove=!0,g.restTimeoutPending=!1)}return i.on(`openchange`,e),()=>{i.off(`openchange`,e)}},[a,i,g,T]),U.useEffect(()=>{if(!a)return;let e=d.current??(p?n.select(`domReferenceElement`):null);if(!B(e))return;function t(e){if(g.openChangeTimeout.clear(),g.blockMouseMove=!1,c&&!kn(g.pointerType)||jo(y.current)>0&&!Ao(v.current,`open`))return;let t=Ao(v.current,`open`,g.pointerType),r=e.currentTarget??null,i=n.select(`domReferenceElement`),a=r==null?!1:C(i,r,e.target),o=n.select(`open`),s=!o||a;a&&o?n.setOpen(!0,Gt(Ht,e,r)):t?g.openChangeTimeout.start(t,()=>{s&&n.setOpen(!0,Gt(Ht,e,r))}):s&&n.setOpen(!0,Gt(Ht,e,r))}function i(e){if(x()){E();return}T();let t=At(n.select(`domReferenceElement`));g.restTimeout.clear(),g.restTimeoutPending=!1;let i=r.current.floatingContext??m?.();if(!S(e.relatedTarget)){if(_.current&&i){n.select(`open`)||g.openChangeTimeout.clear();let r=d.current;g.handler=_.current({...i,tree:h,x:e.clientX,y:e.clientY,onClose(){E(),T(),b.current&&!x()&&r===n.select(`domReferenceElement`)&&w(e,!0)}}),t.addEventListener(`mousemove`,g.handler),g.handler(e);return}(g.pointerType!==`touch`||!Rt(n.select(`floatingElement`),e.relatedTarget))&&w(e)}}return u&&e.addEventListener(`mousemove`,t,{once:!0}),e.addEventListener(`mouseenter`,t),e.addEventListener(`mouseleave`,i),()=>{u&&e.removeEventListener(`mousemove`,t),e.removeEventListener(`mouseenter`,t),e.removeEventListener(`mouseleave`,i)}},[T,E,r,v,w,n,a,_,g,p,C,x,S,c,u,y,d,h,b,m]),U.useMemo(()=>{if(!a)return;function e(e){g.pointerType=e.pointerType}return{onPointerDown:e,onPointerEnter:e,onMouseMove(e){let{nativeEvent:t}=e,r=e.currentTarget,i=n.select(`domReferenceElement`),a=n.select(`open`),o=C(i,r,e.target);if(c&&!kn(g.pointerType))return;let s=jo(y.current);if(a&&!o||s===0||!o&&g.restTimeoutPending&&e.movementX**2+e.movementY**2<2)return;g.restTimeout.clear();function l(){if(g.restTimeoutPending=!1,x())return;let e=n.select(`open`);!g.blockMouseMove&&(!e||o)&&n.setOpen(!0,Gt(Ht,t,r))}g.pointerType===`touch`?Is.flushSync(()=>{l()}):o&&a?l():(g.restTimeoutPending=!0,g.restTimeout.start(s,l))}}},[a,g,x,C,c,n,y])}var _c=new Map([[`select`,`listbox`],[`combobox`,`listbox`],[`label`,!1]]);function vc(e,t={}){let n=`rootStore`in e?e.rootStore:e,r=n.useState(`open`),i=n.useState(`floatingId`),a=n.useState(`domReferenceElement`),o=n.useState(`floatingElement`),{role:s=`dialog`}=t,c=jt(),l=a?.id||c,u=U.useMemo(()=>qt(o)?.id||i,[o,i]),d=_c.get(s)??s,f=Gn()!=null,p=U.useMemo(()=>d===`tooltip`||s===`label`?Ve:{"aria-haspopup":d===`alertdialog`?`dialog`:d,"aria-expanded":`false`,...d===`listbox`&&{role:`combobox`},...d===`menu`&&f&&{role:`menuitem`},...s===`select`&&{"aria-autocomplete":`none`},...s===`combobox`&&{"aria-autocomplete":`list`}},[d,f,s]),m=U.useMemo(()=>d===`tooltip`||s===`label`?{[`aria-${s===`label`?`labelledby`:`describedby`}`]:r?u:void 0}:{...p,"aria-expanded":r?`true`:`false`,"aria-controls":r?u:void 0,...d===`menu`&&{id:l}},[d,u,r,l,s,p]),h=U.useMemo(()=>{let e={id:u,...d&&{role:d}};return d===`tooltip`||s===`label`?e:{...e,...d===`menu`&&{"aria-labelledby":l}}},[d,u,l,s]),g=U.useCallback(({active:e,selected:t})=>{let n={role:`option`,...e&&{id:`${u}-fui-option`}};switch(s){case`select`:case`combobox`:return{...n,"aria-selected":t};default:}return{}},[u,s]);return U.useMemo(()=>({reference:m,floating:h,item:g,trigger:p}),[m,h,p,g])}var yc=.1,bc=yc*yc,xc=.5;function Sc(e,t,n,r,i,a){return r>=t!=a>=t&&e<=(i-n)*(t-r)/(a-r)+n}function Cc(e,t,n,r,i,a,o,s,c,l){let u=!1;return Sc(e,t,n,r,i,a)&&(u=!u),Sc(e,t,i,a,o,s)&&(u=!u),Sc(e,t,o,s,c,l)&&(u=!u),Sc(e,t,c,l,n,r)&&(u=!u),u}function wc(e,t,n){return e>=n.x&&e<=n.x+n.width&&t>=n.y&&t<=n.y+n.height}function Tc(e,t,n,r,i,a){return e>=Math.min(n,i)&&e<=Math.max(n,i)&&t>=Math.min(r,a)&&t<=Math.max(r,a)}function Ec(e={}){let{blockPointerEvents:t=!1}=e,n=new jn,r=({x:e,y:t,placement:r,elements:i,onClose:a,nodeId:o,tree:s})=>{let c=r?.split(`-`)[0],l=!1,u=null,d=null,f=typeof performance<`u`?performance.now():0;function p(e,t){let n=performance.now(),r=n-f;if(u===null||d===null||r===0)return u=e,d=t,f=n,!1;let i=e-u,a=t-d,o=i*i+a*a,s=r*r*bc;return u=e,d=t,f=n,o0)}function b(){y()||m()}if(y())return;let x=a.getBoundingClientRect(),S=u.getBoundingClientRect(),C=e>S.right-S.width/2,w=t>S.bottom-S.height/2,T=S.width>x.width,E=S.height>x.height,D=(T?x:S).left,O=(T?x:S).right,k=(E?x:S).top,A=(E?x:S).bottom;if(c===`top`&&t>=x.bottom-1||c===`bottom`&&t<=x.top+1||c===`left`&&e>=x.right-1||c===`right`&&e<=x.left+1){b();return}let ee=!1;switch(c){case`top`:ee=Tc(d,f,D,x.top+1,O,S.bottom-1);break;case`bottom`:ee=Tc(d,f,D,S.top+1,O,x.bottom-1);break;case`left`:ee=Tc(d,f,S.right-1,A,x.left+1,k);break;case`right`:ee=Tc(d,f,x.right-1,A,S.left+1,k);break;default:}if(ee)return;if(l&&!wc(d,f,x)){b();return}if(!g&&p(d,f)){b();return}let j=!1;switch(c){case`top`:{let n=T?xc/2:xc*4,r=T||C?e+n:e-n,i=T?e-n:C?e+n:e-n,a=t+xc+1,o=C||T?S.bottom-xc:S.top,s=C?T?S.bottom-xc:S.top:S.bottom-xc;j=Cc(d,f,r,a,i,a,S.left,o,S.right,s);break}case`bottom`:{let n=T?xc/2:xc*4,r=T||C?e+n:e-n,i=T?e-n:C?e+n:e-n,a=t-xc,o=C||T?S.top+xc:S.bottom,s=C?T?S.top+xc:S.bottom:S.top+xc;j=Cc(d,f,r,a,i,a,S.left,o,S.right,s);break}case`left`:{let n=E?xc/2:xc*4,r=E||w?t+n:t-n,i=E?t-n:w?t+n:t-n,a=e+xc+1,o=w||E?S.right-xc:S.left,s=w?E?S.right-xc:S.left:S.right-xc;j=Cc(d,f,o,S.top,s,S.bottom,a,r,a,i);break}case`right`:{let n=E?xc/2:xc*4,r=E||w?t+n:t-n,i=E?t-n:w?t+n:t-n,a=e-xc,o=w||E?S.left+xc:S.right,s=w?E?S.left+xc:S.right:S.left+xc;j=Cc(d,f,a,r,a,i,o,S.top,s,S.bottom);break}default:}j?l||n.start(40,b):b()}};return r.__options={blockPointerEvents:t},r}var Dc=function(e){return e.nestedDialogs=`--nested-dialogs`,e}({}),Oc=function(e){return e[e.open=nn.open]=`open`,e[e.closed=nn.closed]=`closed`,e[e.startingStyle=nn.startingStyle]=`startingStyle`,e[e.endingStyle=nn.endingStyle]=`endingStyle`,e.nested=`data-nested`,e.nestedDialogOpen=`data-nested-dialog-open`,e}({}),kc=U.createContext(void 0);function Ac(){let e=U.useContext(kc);if(e===void 0)throw Error(He(26));return e}var jc={...Dn,...Xt,nestedDialogOpen(e){return e?{[Oc.nestedDialogOpen]:``}:null}},Mc=U.forwardRef(function(e,t){let{className:n,finalFocus:r,initialFocus:i,render:a,...o}=e,{store:s}=wo(),c=s.useState(`descriptionElementId`),l=s.useState(`disablePointerDismissal`),u=s.useState(`floatingRootContext`),d=s.useState(`popupProps`),f=s.useState(`modal`),p=s.useState(`mounted`),m=s.useState(`nested`),h=s.useState(`nestedOpenDialogCount`),g=s.useState(`open`),_=s.useState(`openMethod`),v=s.useState(`titleElementId`),y=s.useState(`transitionStatus`),b=s.useState(`role`);Ac(),Qt({open:g,ref:s.context.popupRef,onComplete(){g&&s.context.onOpenChangeComplete?.(!0)}});function x(e){return e===`touch`?s.context.popupRef.current:!0}let S=i===void 0?x:i,C=Ue(`div`,e,{state:{open:g,nested:m,transitionStatus:y,nestedDialogOpen:h>0},props:[d,{"aria-labelledby":v??void 0,"aria-describedby":c??void 0,role:b,tabIndex:-1,hidden:!p,onKeyDown(e){Nn.has(e.key)&&e.stopPropagation()},style:{[Dc.nestedDialogs]:h}},o],ref:[t,s.context.popupRef,s.useStateSetter(`popupElement`)],stateAttributesMapping:jc});return(0,W.jsx)(gn,{context:u,openInteractionType:_,disabled:!p,closeOnFocusOut:!l,initialFocus:S,returnFocus:r,modal:f!==!1,restoreFocus:`popup`,children:C})}),Nc=U.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,{store:i}=wo(),a=i.useState(`mounted`),o=i.useState(`modal`),s=i.useState(`open`);return a||n?(0,W.jsx)(kc.Provider,{value:n,children:(0,W.jsxs)(yn,{ref:t,...r,children:[a&&o===!0&&(0,W.jsx)(wn,{ref:i.context.internalBackdropRef,inert:_n(!s)}),e.children]})}):null});function Pc(e){let t=U.useRef(!0);t.current&&(t.current=!1,e())}function Fc(e){let{store:t,parentContext:n,actionsRef:r}=e,i=t.useState(`open`),a=t.useState(`disablePointerDismissal`),o=t.useState(`modal`),s=t.useState(`popupElement`),{openMethod:c,triggerProps:l}=Hn(i);Zs(t);let{forceUnmount:u}=Qs(i,t),d=pt(e=>{let n=Gt(e);return n.preventUnmountOnClose=()=>{t.set(`preventUnmountingOnClose`,!0)},n}),f=U.useCallback(()=>{t.setOpen(!1,d(Wt))},[t,d]);U.useImperativeHandle(r,()=>({unmount:u,close:f}),[u,f]);let p=ac({popupStore:t,onOpenChange:t.setOpen,treatPopupAsFloatingElement:!0,noEmit:!0}),[m,h]=U.useState(0),g=m===0,_=vc(p),v=Sn(p,{outsidePressEvent(){return t.context.internalBackdropRef.current||t.context.backdropRef.current?`intentional`:{mouse:o===`trap-focus`?`sloppy`:`intentional`,touch:`sloppy`}},outsidePress(e){if(!t.context.outsidePressEnabledRef.current||`button`in e&&e.button!==0||`touches`in e&&e.touches.length!==1)return!1;let n=Yt(e);if(g&&!a){let e=n;return o&&(t.context.internalBackdropRef.current||t.context.backdropRef.current)?t.context.internalBackdropRef.current===e||t.context.backdropRef.current===e||Rt(e,s)&&!e?.hasAttribute(`data-base-ui-portal`):!0}return!1},escapeKey:g});Rn(i&&o===!0,s);let{getReferenceProps:y,getFloatingProps:b,getTriggerProps:x}=Bn([_,v]);t.useContextCallback(`onNestedDialogOpen`,e=>{h(e+1)}),t.useContextCallback(`onNestedDialogClose`,()=>{h(0)}),U.useEffect(()=>(n?.onNestedDialogOpen&&i&&n.onNestedDialogOpen(m),n?.onNestedDialogClose&&!i&&n.onNestedDialogClose(),()=>{n?.onNestedDialogClose&&i&&n.onNestedDialogClose()}),[i,n,m]);let S=U.useMemo(()=>y(l),[y,l]),C=U.useMemo(()=>x(l),[x,l]),w=U.useMemo(()=>b(),[b]);t.useSyncedValues({openMethod:c,activeTriggerProps:S,inactiveTriggerProps:C,popupProps:w,floatingRootContext:p,nestedOpenDialogCount:m})}var Ic={...nc,modal:V(e=>e.modal),nested:V(e=>e.nested),nestedOpenDialogCount:V(e=>e.nestedOpenDialogCount),disablePointerDismissal:V(e=>e.disablePointerDismissal),openMethod:V(e=>e.openMethod),descriptionElementId:V(e=>e.descriptionElementId),titleElementId:V(e=>e.titleElementId),viewportElement:V(e=>e.viewportElement),role:V(e=>e.role)},Lc=class extends Wn{constructor(e){super(Rc(e),{popupRef:U.createRef(),backdropRef:U.createRef(),internalBackdropRef:U.createRef(),outsidePressEnabledRef:{current:!0},triggerElements:new bn,onOpenChange:void 0,onOpenChangeComplete:void 0},Ic)}setOpen=(e,t)=>{if(t.preventUnmountOnClose=()=>{this.set(`preventUnmountingOnClose`,!0)},!e&&t.trigger==null&&this.state.activeTriggerId!=null&&(t.trigger=this.state.activeTriggerElement??void 0),this.context.onOpenChange?.(e,t),t.isCanceled)return;let n={open:e,nativeEvent:t.event,reason:t.reason,nested:this.state.nested};this.state.floatingRootContext.context.events?.emit(`openchange`,n);let r={open:e},i=t.trigger?.id??null;(i||e)&&(r.activeTriggerId=i,r.activeTriggerElement=t.trigger??null),this.update(r)}};function Rc(e={}){return{...ec(),modal:!0,disablePointerDismissal:!1,popupElement:null,viewportElement:null,descriptionElementId:void 0,titleElementId:void 0,openMethod:null,nested:!1,nestedOpenDialogCount:0,role:`dialog`,...e}}function zc(e){let{children:t,open:n,defaultOpen:r=!1,onOpenChange:i,onOpenChangeComplete:a,disablePointerDismissal:o=!1,modal:s=!0,actionsRef:c,handle:l,triggerId:u,defaultTriggerId:d=null}=e,f=wo(!0),p=!!f,m=Ge(()=>l?.store??new Lc({open:r,openProp:n,activeTriggerId:d,triggerIdProp:u,modal:s,disablePointerDismissal:o,nested:p})).current;Pc(()=>{n===void 0&&m.state.open===!1&&r===!0&&m.update({open:!0,activeTriggerId:d})}),m.useControlledProp(`openProp`,n),m.useControlledProp(`triggerIdProp`,u),m.useSyncedValues({disablePointerDismissal:o,nested:p,modal:s}),m.useContextCallback(`onOpenChange`,i),m.useContextCallback(`onOpenChangeComplete`,a);let h=m.useState(`payload`);Fc({store:m,actionsRef:c,parentContext:f?.store.context,onOpenChange:i,triggerIdProp:u});let g=U.useMemo(()=>({store:m}),[m]);return(0,W.jsx)(Co.Provider,{value:g,children:typeof t==`function`?t({payload:h}):t})}var Bc=U.forwardRef(function(e,t){let{render:n,className:r,id:i,...a}=e,{store:o}=wo(),s=Lt(i);return o.useSyncedValueWithCleanup(`titleElementId`,s),Ue(`h2`,e,{ref:t,props:[{id:s},a]})});function Vc(e){let t=(0,G.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,W.jsx)(zc,{"data-slot":`sheet`,...n}),t[2]=n,t[3]=r),r}function Hc(e){let t=(0,G.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,W.jsx)(Nc,{"data-slot":`sheet-portal`,...n}),t[2]=n,t[3]=r),r}function Uc(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`data-closed:fade-out-0 data-open:fade-in-0 data-closed:animate-out data-open:animate-in fixed inset-0 z-50 bg-black/80 duration-100 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xs`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(Eo,{className:i,"data-slot":`sheet-overlay`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Wc(e){let t=(0,G.c)(17),n,r,i,a,o;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5]):({className:r,children:n,side:a,showCloseButton:o,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o);let s=a===void 0?`right`:a,c=o===void 0?!0:o,l;t[6]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,W.jsx)(Uc,{}),t[6]=l):l=t[6];let u;t[7]===r?u=t[8]:(u=qe(`data-[side=right]:data-closed:slide-out-to-right-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=top]:data-closed:slide-out-to-top-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:fade-out-0 data-open:fade-in-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-closed:animate-out data-open:animate-in fixed z-50 flex flex-col bg-background bg-clip-padding text-xs/relaxed shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm`,r),t[7]=r,t[8]=u);let d;t[9]===c?d=t[10]:(d=c&&(0,W.jsxs)(Do,{"data-slot":`sheet-close`,render:(0,W.jsx)(_t,{className:`absolute top-4 right-4`,size:`icon-sm`,variant:`ghost`}),children:[(0,W.jsx)(yo,{}),(0,W.jsx)(`span`,{className:`sr-only`,children:`Close`})]}),t[9]=c,t[10]=d);let f;return t[11]!==n||t[12]!==i||t[13]!==s||t[14]!==u||t[15]!==d?(f=(0,W.jsxs)(Hc,{children:[l,(0,W.jsxs)(Mc,{className:u,"data-side":s,"data-slot":`sheet-content`,...i,children:[n,d]})]}),t[11]=n,t[12]=i,t[13]=s,t[14]=u,t[15]=d,t[16]=f):f=t[16],f}function Gc(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`flex flex-col gap-1.5 p-6`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-slot":`sheet-header`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Kc(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`text-sm font-medium text-foreground`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(Bc,{className:i,"data-slot":`sheet-title`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function qc(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`text-xs/relaxed text-muted-foreground`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(Oo,{className:i,"data-slot":`sheet-description`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}var Jc=U.createContext(void 0);function Yc(e){let t=U.useContext(Jc);if(t===void 0&&!e)throw Error(He(72));return t}var Xc={...nc,disabled:V(e=>e.disabled),instantType:V(e=>e.instantType),isInstantPhase:V(e=>e.isInstantPhase),trackCursorAxis:V(e=>e.trackCursorAxis),disableHoverablePopup:V(e=>e.disableHoverablePopup),lastOpenChangeReason:V(e=>e.openChangeReason),closeOnClick:V(e=>e.closeOnClick),closeDelay:V(e=>e.closeDelay),hasViewport:V(e=>e.hasViewport)},Zc=class e extends Wn{constructor(e){super({...Qc(),...e},{popupRef:U.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:new bn},Xc)}setOpen=(e,t)=>{let n=t.reason,r=n===Ht,i=e&&n===`trigger-focus`,a=!e&&(n===`trigger-press`||n===`escape-key`);if(t.preventUnmountOnClose=()=>{this.set(`preventUnmountingOnClose`,!0)},this.context.onOpenChange?.(e,t),t.isCanceled)return;let o=()=>{let r={open:e,openChangeReason:n};i?r.instantType=`focus`:a?r.instantType=`dismiss`:n===`trigger-hover`&&(r.instantType=void 0);let o=t.trigger?.id??null;(o||e)&&(r.activeTriggerId=o,r.activeTriggerElement=t.trigger??null),this.update(r)};r?Is.flushSync(o):o()};static useStore(t,n){let r=Ge(()=>new e(n)).current,i=t??r,a=ac({popupStore:i,onOpenChange:i.setOpen});return i.state.floatingRootContext=a,i}};function Qc(){return{...ec(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:`none`,disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,hasViewport:!1}}var $c=Fn(function(e){let{disabled:t=!1,defaultOpen:n=!1,open:r,disableHoverablePopup:i=!1,trackCursorAxis:a=`none`,actionsRef:o,onOpenChange:s,onOpenChangeComplete:c,handle:l,triggerId:u,defaultTriggerId:d=null,children:f}=e,p=Zc.useStore(l?.store,{open:n,openProp:r,activeTriggerId:d,triggerIdProp:u});Pc(()=>{r===void 0&&p.state.open===!1&&n===!0&&p.update({open:!0,activeTriggerId:d})}),p.useControlledProp(`openProp`,r),p.useControlledProp(`triggerIdProp`,u),p.useContextCallback(`onOpenChange`,s),p.useContextCallback(`onOpenChangeComplete`,c);let m=p.useState(`open`),h=!t&&m,g=p.useState(`activeTriggerId`),_=p.useState(`payload`);p.useSyncedValues({trackCursorAxis:a,disableHoverablePopup:i}),lt(()=>{m&&t&&p.setOpen(!1,Gt(Vt))},[m,t,p]),p.useSyncedValue(`disabled`,t),Zs(p);let{forceUnmount:v,transitionStatus:y}=Qs(h,p),b=p.useState(`isInstantPhase`),x=p.useState(`instantType`),S=p.useState(`lastOpenChangeReason`),C=U.useRef(null);lt(()=>{y===`ending`&&S===`none`||y!==`ending`&&b?(x!==`delay`&&(C.current=x),p.set(`instantType`,`delay`)):C.current!==null&&(p.set(`instantType`,C.current),C.current=null)},[y,b,S,x,p]),lt(()=>{h&&(g??p.set(`payload`,void 0))},[p,g,h]);let w=U.useCallback(()=>{p.setOpen(!1,el(p,Wt))},[p]);U.useImperativeHandle(o,()=>({unmount:v,close:w}),[v,w]);let T=p.useState(`floatingRootContext`),{getReferenceProps:E,getFloatingProps:D,getTriggerProps:O}=Bn([Sn(T,{enabled:!t,referencePress:()=>p.select(`closeOnClick`)}),Ro(T,{enabled:!t&&a!==`none`,axis:a===`none`?void 0:a})]),k=U.useMemo(()=>E(),[E]),A=U.useMemo(()=>O(),[O]),ee=U.useMemo(()=>D(),[D]);return p.useSyncedValues({activeTriggerProps:k,inactiveTriggerProps:A,popupProps:ee}),(0,W.jsx)(Jc.Provider,{value:p,children:typeof f==`function`?f({payload:_}):f})});function el(e,t){let n=Gt(t);return n.preventUnmountOnClose=()=>{e.set(`preventUnmountingOnClose`,!0)},n}var tl=U.createContext(void 0);function nl(){return U.useContext(tl)}var rl=function(e){return e[e.popupOpen=ln.popupOpen]=`popupOpen`,e.triggerDisabled=`data-trigger-disabled`,e}({}),il=An(function(e,t){let{className:n,render:r,handle:i,payload:a,disabled:o,delay:s,closeOnClick:c=!0,closeDelay:l,id:u,...d}=e,f=Yc(!0),p=i?.store??f;if(!p)throw Error(He(82));let m=Lt(u),h=p.useState(`isTriggerActive`,m),g=p.useState(`isOpenedByTrigger`,m),_=p.useState(`floatingRootContext`),v=U.useRef(null),y=s??600,b=l??0,{registerTrigger:x,isMountedByThisTrigger:S}=Xs(m,v,p,{payload:a,closeOnClick:c,closeDelay:b}),C=nl(),{delayRef:w,isInstantPhase:T,hasProvider:E}=Fo(_,{open:g});p.useSyncedValue(`isInstantPhase`,T);let D=p.useState(`disabled`),O=o??D,k=p.useState(`trackCursorAxis`),A=p.useState(`disableHoverablePopup`),ee=gc(_,{enabled:!O,mouseOnly:!0,move:!1,handleClose:!A&&k!==`both`?Ec():null,restMs(){let e=C?.delay,t=typeof w.current==`object`?w.current.open:void 0,n=y;return E&&(n=t===0?0:s??e??y),n},delay(){let e=typeof w.current==`object`?w.current.close:void 0,t=b;return l==null&&E&&(t=e),{close:t}},triggerElementRef:v,isActiveTrigger:h}),j=sc(_,{enabled:!O}).reference,M={open:g},N=p.useState(`triggerProps`,S);return Ue(`button`,e,{state:M,ref:[t,x,v],props:[ee,j,N,{onPointerDown(){p.set(`closeOnClick`,c)},id:m,[rl.triggerDisabled]:O?``:void 0},d],stateAttributesMapping:En})}),al=U.createContext(void 0);function ol(){let e=U.useContext(al);if(e===void 0)throw Error(He(70));return e}var sl=U.forwardRef(function(e,t){let{children:n,container:r,className:i,render:a,...o}=e,{portalNode:s,portalSubtree:c}=Kn({container:r,ref:t,componentProps:e,elementProps:o});return!c&&!s?null:(0,W.jsxs)(U.Fragment,{children:[c,s&&Is.createPortal(n,s)]})}),cl=U.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e;return Yc().useState(`mounted`)||n?(0,W.jsx)(al.Provider,{value:n,children:(0,W.jsx)(sl,{ref:t,...r})}):null}),ll=U.createContext(void 0);function ul(){let e=U.useContext(ll);if(e===void 0)throw Error(He(71));return e}var dl=U.createContext(void 0);function fl(){return U.useContext(dl)?.direction??`ltr`}var pl=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0,offsetParent:d=`real`}=fn(e,t)||{};if(l==null)return{};let f=xn(u),p={x:n,y:r},m=Ln(i),h=mn(m),g=await o.getDimensions(l),_=m===`y`,v=_?`top`:`left`,y=_?`bottom`:`right`,b=_?`clientHeight`:`clientWidth`,x=a.reference[h]+a.reference[m]-p[m]-a.floating[h],S=p[m]-a.reference[m],C=d===`real`?await o.getOffsetParent?.(l):s.floating,w=s.floating[b]||a.floating[h];(!w||!await o.isElement?.(C))&&(w=s.floating[b]||a.floating[h]);let T=x/2-S/2,E=w/2-g[h]/2-1,D=Math.min(f[v],E),O=Math.min(f[y],E),k=D,A=w-g[h]-O,ee=w/2-g[h]/2+T,j=on(k,ee,A),M=!c.arrow&&cn(i)!=null&&ee!==j&&a.reference[h]/2-(ee({...pl(e),options:[e,t]}),hl={name:`hide`,async fn(e){let{width:t,height:n,x:r,y:i}=e.rects.reference,a=t===0&&n===0&&r===0&&i===0;return{data:{referenceHidden:(await Js().fn(e)).data?.referenceHidden||a}}}},gl={sideX:`left`,sideY:`top`},_l={name:`adaptiveOrigin`,async fn(e){let{x:t,y:n,rects:{floating:r},elements:{floating:i},platform:a,strategy:o,placement:s}=e,c=ct(i),l=c.getComputedStyle(i);if(!(l.transitionDuration!==`0s`&&l.transitionDuration!==``))return{x:t,y:n,data:gl};let u=await a.getOffsetParent?.(i),d={width:0,height:0};if(o===`fixed`&&c?.visualViewport)d={width:c.visualViewport.width,height:c.visualViewport.height};else if(u===c){let e=At(i);d={width:e.documentElement.clientWidth,height:e.documentElement.clientHeight}}else await a.isElement?.(u)&&(d=await a.getDimensions(u));let f=Un(s),p=t,m=n;f===`left`&&(p=d.width-(t+r.width)),f===`top`&&(m=d.height-(n+r.height));let h=f===`left`?`right`:gl.sideX,g=f===`top`?`bottom`:gl.sideY;return{x:p,y:m,data:{sideX:h,sideY:g}}}};function vl(e,t,n){let r=e===`inline-start`||e===`inline-end`;return{top:`top`,right:r?n?`inline-start`:`inline-end`:`right`,bottom:`bottom`,left:r?n?`inline-end`:`inline-start`:`left`}[t]}function yl(e,t,n){let{rects:r,placement:i}=e;return{side:vl(t,Un(i),n),align:cn(i)||`center`,anchor:{width:r.reference.width,height:r.reference.height},positioner:{width:r.floating.width,height:r.floating.height}}}function bl(e){let{anchor:t,positionMethod:n=`absolute`,side:r=`bottom`,sideOffset:i=0,align:a=`center`,alignOffset:o=0,collisionBoundary:s,collisionPadding:c=5,sticky:l=!1,arrowPadding:u=5,disableAnchorTracking:d=!1,keepMounted:f=!1,floatingRootContext:p,mounted:m,collisionAvoidance:h,shiftCrossAxis:g=!1,nodeId:_,adaptiveOrigin:v,lazyFlip:y=!1,externalTree:b}=e,[x,S]=U.useState(null);!m&&x!==null&&S(null);let C=h.side||`flip`,w=h.align||`flip`,T=h.fallbackAxisSide||`end`,E=typeof t==`function`?t:void 0,D=pt(E),O=E?D:t,k=rn(t),A=fl()===`rtl`,ee=x||{top:`top`,right:`right`,bottom:`bottom`,left:`left`,"inline-end":A?`left`:`right`,"inline-start":A?`right`:`left`}[r],j=a===`center`?ee:`${ee}-${a}`,M=c,N=r===`bottom`?1:0,P=r===`top`?1:0,te=r===`right`?1:0,ne=r===`left`?1:0;typeof M==`number`?M={top:M+N,right:M+ne,bottom:M+P,left:M+te}:M&&={top:(M.top||0)+N,right:(M.right||0)+ne,bottom:(M.bottom||0)+P,left:(M.left||0)+te};let re={boundary:s===`clipping-ancestors`?`clippingAncestors`:s,padding:M},ie=U.useRef(null),F=rn(i),I=rn(o),ae=[Us(e=>{let t=yl(e,r,A),n=typeof F.current==`function`?F.current(t):F.current,i=typeof I.current==`function`?I.current(t):I.current;return{mainAxis:n,crossAxis:i,alignmentAxis:i}},[typeof i==`function`?0:i,typeof o==`function`?0:o,A,r])],oe=w===`none`&&C!==`shift`,se=!oe&&(l||g||C===`shift`),ce=C===`none`?null:Ks({...re,padding:{top:M.top+1,right:M.right+1,bottom:M.bottom+1,left:M.left+1},mainAxis:!g&&C===`flip`,crossAxis:w===`flip`?`alignment`:!1,fallbackAxisSideDirection:T}),le=oe?null:Ws(e=>{let t=At(e.elements.floating).documentElement;return{...re,rootBoundary:g?{x:0,y:0,width:t.clientWidth,height:t.clientHeight}:void 0,mainAxis:w!==`none`,crossAxis:se,limiter:l||g?void 0:Gs(e=>{if(!ie.current)return{};let{width:t,height:n}=ie.current.getBoundingClientRect(),r=Mn(Un(e.placement)),i=r===`y`?t:n,a=r===`y`?M.left+M.right:M.top+M.bottom;return{offset:i/2+a/2}})}},[re,l,g,M,w]);C===`shift`||w===`shift`||a===`center`?ae.push(le,ce):ae.push(ce,le),ae.push(qs({...re,apply({elements:{floating:e},availableWidth:t,availableHeight:n,rects:r}){let i=e.style;i.setProperty(`--available-width`,`${t}px`),i.setProperty(`--available-height`,`${n}px`);let a=window.devicePixelRatio||1,{x:o,y:s,width:c,height:l}=r.reference,u=(Math.round((o+c)*a)-Math.round(o*a))/a,d=(Math.round((s+l)*a)-Math.round(s*a))/a;i.setProperty(`--anchor-width`,`${u}px`),i.setProperty(`--anchor-height`,`${d}px`)}}),ml(()=>({element:ie.current||document.createElement(`div`),padding:u,offsetParent:`floating`}),[u]),{name:`transformOrigin`,fn(e){let{elements:t,middlewareData:n,placement:a,rects:o,y:s}=e,c=Un(a),l=Mn(c),u=ie.current,d=n.arrow?.x||0,f=n.arrow?.y||0,p=u?.clientWidth||0,m=u?.clientHeight||0,h=d+p/2,g=f+m/2,_=Math.abs(n.shift?.y||0),v=o.reference.height/2,y=typeof i==`function`?i(yl(e,r,A)):i,b=_>y,x={top:`${h}px calc(100% + ${y}px)`,bottom:`${h}px ${-y}px`,left:`calc(100% + ${y}px) ${g}px`,right:`${-y}px ${g}px`}[c],S=`${h}px ${o.reference.y+v-s}px`;return t.floating.style.setProperty(`--transform-origin`,se&&l===`y`&&b?S:x),{}}},hl,v),lt(()=>{!m&&p&&p.update({referenceElement:null,floatingElement:null,domReferenceElement:null})},[m,p]);let ue=U.useMemo(()=>({elementResize:!d&&typeof ResizeObserver<`u`,layoutShift:!d&&typeof IntersectionObserver<`u`}),[d]),{refs:de,elements:fe,x:pe,y:me,middlewareData:he,update:ge,placement:_e,context:ve,isPositioned:ye,floatingStyles:be}=ic({rootContext:p,placement:j,middleware:ae,strategy:n,whileElementsMounted:f?void 0:(...e)=>Os(...e,ue),nodeId:_,externalTree:b}),{sideX:xe,sideY:Se}=he.adaptiveOrigin||gl,Ce=ye?n:`fixed`,we=U.useMemo(()=>{let e=v?{position:Ce,[xe]:pe,[Se]:me}:{position:Ce,...be};return ye||(e.opacity=0),e},[v,Ce,xe,pe,Se,me,be,ye]),Te=U.useRef(null);lt(()=>{if(!m)return;let e=k.current,t=typeof e==`function`?e():e,n=(xl(t)?t.current:t)||null;n!==Te.current&&(de.setPositionReference(n),Te.current=n)},[m,de,O,k]),U.useEffect(()=>{if(!m)return;let e=k.current;typeof e!=`function`&&xl(e)&&e.current!==Te.current&&(de.setPositionReference(e.current),Te.current=e.current)},[m,de,O,k]),U.useEffect(()=>{if(f&&m&&fe.domReference&&fe.floating)return Os(fe.domReference,fe.floating,ge,ue)},[f,m,fe,ge,ue]);let Ee=Un(_e),De=vl(r,Ee,A),Oe=cn(_e)||`center`,ke=!!he.hide?.referenceHidden;lt(()=>{y&&m&&ye&&S(Ee)},[y,m,ye,Ee]);let Ae=U.useMemo(()=>({position:`absolute`,top:he.arrow?.y,left:he.arrow?.x}),[he.arrow]),je=he.arrow?.centerOffset!==0;return U.useMemo(()=>({positionerStyles:we,arrowStyles:Ae,arrowRef:ie,arrowUncentered:je,side:De,align:Oe,physicalSide:Ee,anchorHidden:ke,refs:de,context:ve,isPositioned:ye,update:ge}),[we,Ae,ie,je,De,Oe,Ee,ke,de,ve,ye,ge])}function xl(e){return e!=null&&`current`in e}function Sl(e){return e===`starting`?Be:Ve}var Cl=U.forwardRef(function(e,t){let{render:n,className:r,anchor:i,positionMethod:a=`absolute`,side:o=`top`,align:s=`center`,sideOffset:c=0,alignOffset:l=0,collisionBoundary:u=`clipping-ancestors`,collisionPadding:d=5,arrowPadding:f=5,sticky:p=!1,disableAnchorTracking:m=!1,collisionAvoidance:h=We,...g}=e,_=Yc(),v=ol(),y=_.useState(`open`),b=_.useState(`mounted`),x=_.useState(`trackCursorAxis`),S=_.useState(`disableHoverablePopup`),C=_.useState(`floatingRootContext`),w=_.useState(`instantType`),T=_.useState(`transitionStatus`),E=bl({anchor:i,positionMethod:a,floatingRootContext:C,mounted:b,side:o,sideOffset:c,align:s,alignOffset:l,collisionBoundary:u,collisionPadding:d,sticky:p,arrowPadding:f,disableAnchorTracking:m,keepMounted:v,collisionAvoidance:h,adaptiveOrigin:_.useState(`hasViewport`)?_l:void 0}),D=U.useMemo(()=>{let e={};return(!y||x===`both`||S)&&(e.pointerEvents=`none`),{role:`presentation`,hidden:!b,style:{...E.positionerStyles,...e}}},[y,x,S,b,E.positionerStyles]),O=U.useMemo(()=>({open:y,side:E.side,align:E.align,anchorHidden:E.anchorHidden,instant:x===`none`?w:`tracking-cursor`}),[y,E.side,E.align,E.anchorHidden,x,w]),k=U.useMemo(()=>({...O,arrowRef:E.arrowRef,arrowStyles:E.arrowStyles,arrowUncentered:E.arrowUncentered}),[O,E.arrowRef,E.arrowStyles,E.arrowUncentered]),A=Ue(`div`,e,{state:O,props:[D,Sl(T),g],ref:[t,_.useStateSetter(`positionerElement`)],stateAttributesMapping:Dn});return(0,W.jsx)(ll.Provider,{value:k,children:A})}),wl={...Dn,...Xt},Tl=U.forwardRef(function(e,t){let{className:n,render:r,...i}=e,a=Yc(),{side:o,align:s}=ul(),c=a.useState(`open`),l=a.useState(`instantType`),u=a.useState(`transitionStatus`),d=a.useState(`popupProps`),f=a.useState(`floatingRootContext`);Qt({open:c,ref:a.context.popupRef,onComplete(){c&&a.context.onOpenChangeComplete?.(!0)}});let p=a.useState(`disabled`),m=a.useState(`closeDelay`);return mc(f,{enabled:!p,closeDelay:m}),Ue(`div`,e,{state:{open:c,side:o,align:s,instant:l,transitionStatus:u},ref:[t,a.context.popupRef,a.useStateSetter(`popupElement`)],props:[d,Sl(u),i],stateAttributesMapping:wl})}),El=U.forwardRef(function(e,t){let{className:n,render:r,...i}=e,a=Yc().useState(`instantType`),{open:o,arrowRef:s,side:c,align:l,arrowUncentered:u,arrowStyles:d}=ul();return Ue(`div`,e,{state:{open:o,side:c,align:l,uncentered:u,instant:a},ref:[t,s],props:[{style:d,"aria-hidden":!0},i],stateAttributesMapping:Dn})}),Dl=function(e){let{delay:t,closeDelay:n,timeout:r=400}=e,i=U.useMemo(()=>({delay:t,closeDelay:n}),[t,n]),a=U.useMemo(()=>({open:t,close:n}),[t,n]);return(0,W.jsx)(tl.Provider,{value:i,children:(0,W.jsx)(Po,{delay:a,timeoutMs:r,children:e.children})})};function Ol(e){let t=(0,G.c)(6),n,r;t[0]===e?(n=t[1],r=t[2]):({delay:r,...n}=e,t[0]=e,t[1]=n,t[2]=r);let i=r===void 0?0:r,a;return t[3]!==i||t[4]!==n?(a=(0,W.jsx)(Dl,{"data-slot":`tooltip-provider`,delay:i,...n}),t[3]=i,t[4]=n,t[5]=a):a=t[5],a}function kl(e){let t=(0,G.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,W.jsx)(Ol,{children:(0,W.jsx)($c,{"data-slot":`tooltip`,...n})}),t[2]=n,t[3]=r),r}function Al(e){let t=(0,G.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,W.jsx)(il,{"data-slot":`tooltip-trigger`,...n}),t[2]=n,t[3]=r),r}function jl(e){let t=(0,G.c)(21),n,r,i,a,o,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5],s=t[6],c=t[7]):({className:r,side:a,sideOffset:o,align:s,alignOffset:c,children:n,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o,t[6]=s,t[7]=c);let l=a===void 0?`top`:a,u=o===void 0?4:o,d=s===void 0?`center`:s,f=c===void 0?0:c,p;t[8]===r?p=t[9]:(p=qe(`data-open:fade-in-0 data-open:zoom-in-95 data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-closed:fade-out-0 data-closed:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=delayed-open]:animate-in data-closed:animate-out data-open:animate-in z-50 w-fit max-w-xs origin-(--transform-origin) rounded-md bg-foreground px-3 py-1.5 text-xs text-background **:data-[slot=kbd]:rounded-md`,r),t[8]=r,t[9]=p);let m;t[10]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,W.jsx)(El,{className:`z-50 size-2.5 translate-y-[calc(-50%-2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground data-[side=bottom]:top-1 data-[side=left]:top-1/2! data-[side=left]:-right-1 data-[side=left]:-translate-y-1/2 data-[side=right]:top-1/2! data-[side=right]:-left-1 data-[side=right]:-translate-y-1/2 data-[side=top]:-bottom-2.5`}),t[10]=m):m=t[10];let h;t[11]!==n||t[12]!==i||t[13]!==p?(h=(0,W.jsxs)(Tl,{className:p,"data-slot":`tooltip-content`,...i,children:[n,m]}),t[11]=n,t[12]=i,t[13]=p,t[14]=h):h=t[14];let g;return t[15]!==d||t[16]!==f||t[17]!==l||t[18]!==u||t[19]!==h?(g=(0,W.jsx)(cl,{children:(0,W.jsx)(Cl,{align:d,alignOffset:f,className:`isolate z-50`,side:l,sideOffset:u,children:h})}),t[15]=d,t[16]=f,t[17]=l,t[18]=u,t[19]=h,t[20]=g):g=t[20],g}var Ml=window.matchMedia(`(max-width: 767px)`);function Nl(e){return Ml.addEventListener(`change`,e),()=>Ml.removeEventListener(`change`,e)}function Pl(){return Ml.matches}function Fl(){return(0,U.useSyncExternalStore)(Nl,Pl)}var Il=`sidebar_state`,Ll=3600*24*7,q=`12rem`,Rl=`16rem`,J=`3rem`,Y=`b`,X=U.createContext(null);function zl(){let e=U.useContext(X);if(!e)throw Error(`useSidebar must be used within a SidebarProvider.`);return e}function Bl(e){let t=(0,G.c)(36),n,r,i,a,o,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5],s=t[6],c=t[7]):({defaultOpen:c,open:i,onOpenChange:o,className:r,style:s,children:n,...a}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o,t[6]=s,t[7]=c);let l=c===void 0?!0:c,u=Fl(),[d,f]=U.useState(!1),[p,m]=U.useState(l),h=i??p,g;t[8]!==h||t[9]!==o?(g=e=>{let t=typeof e==`function`?e(h):e;o?o(t):m(t),document.cookie=`${Il}=${t}; path=/; max-age=${Ll}`},t[8]=h,t[9]=o,t[10]=g):g=t[10];let _=g,v;t[11]!==u||t[12]!==_?(v=()=>u?f(Hl):_(Vl),t[11]=u,t[12]=_,t[13]=v):v=t[13];let y=v,b,x;t[14]===y?(b=t[15],x=t[16]):(b=()=>{let e=e=>{e.key===Y&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),y())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},x=[y],t[14]=y,t[15]=b,t[16]=x),U.useEffect(b,x);let S=h?`expanded`:`collapsed`,C;t[17]!==u||t[18]!==h||t[19]!==d||t[20]!==_||t[21]!==S||t[22]!==y?(C={state:S,open:h,setOpen:_,isMobile:u,openMobile:d,setOpenMobile:f,toggleSidebar:y},t[17]=u,t[18]=h,t[19]=d,t[20]=_,t[21]=S,t[22]=y,t[23]=C):C=t[23];let w=C,T;t[24]===r?T=t[25]:(T=qe(`group/sidebar-wrapper flex min-h-svh w-full has-data-[variant=inset]:bg-sidebar`,r),t[24]=r,t[25]=T);let E;t[26]===s?E=t[27]:(E={"--sidebar-width":q,"--sidebar-width-icon":J,...s},t[26]=s,t[27]=E);let D=E,O;t[28]!==n||t[29]!==a||t[30]!==T||t[31]!==D?(O=(0,W.jsx)(`div`,{className:T,"data-slot":`sidebar-wrapper`,style:D,...a,children:n}),t[28]=n,t[29]=a,t[30]=T,t[31]=D,t[32]=O):O=t[32];let k;return t[33]!==w||t[34]!==O?(k=(0,W.jsx)(X.Provider,{value:w,children:O}),t[33]=w,t[34]=O,t[35]=k):k=t[35],k}function Vl(e){return!e}function Hl(e){return!e}function Ul(e){let t=(0,G.c)(46),n,r,i,a,o,s;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5],s=t[6]):({side:a,variant:o,collapsible:s,className:r,children:n,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o,t[6]=s);let c=a===void 0?`left`:a,l=o===void 0?`sidebar`:o,u=s===void 0?`offExamples`:s,{isMobile:d,state:f,openMobile:p,setOpenMobile:m}=zl();if(u===`none`){let e;t[7]===r?e=t[8]:(e=qe(`flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground`,r),t[7]=r,t[8]=e);let a;return t[9]!==n||t[10]!==i||t[11]!==e?(a=(0,W.jsx)(`div`,{className:e,"data-slot":`sidebar`,...i,children:n}),t[9]=n,t[10]=i,t[11]=e,t[12]=a):a=t[12],a}if(d){let e;t[13]===Symbol.for(`react.memo_cache_sentinel`)?(e={"--sidebar-width":Rl},t[13]=e):e=t[13];let r=e,a;t[14]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,W.jsxs)(Gc,{className:`sr-only`,children:[(0,W.jsx)(Kc,{children:`Sidebar`}),(0,W.jsx)(qc,{children:`Displays the mobile sidebar.`})]}),t[14]=a):a=t[14];let o;t[15]===n?o=t[16]:(o=(0,W.jsx)(`div`,{className:`flex h-full w-full flex-col`,children:n}),t[15]=n,t[16]=o);let s;t[17]!==c||t[18]!==o?(s=(0,W.jsxs)(Wc,{className:`w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden`,"data-mobile":`true`,"data-sidebar":`sidebar`,"data-slot":`sidebar`,side:c,style:r,children:[a,o]}),t[17]=c,t[18]=o,t[19]=s):s=t[19];let l;return t[20]!==p||t[21]!==i||t[22]!==m||t[23]!==s?(l=(0,W.jsx)(Vc,{onOpenChange:m,open:p,...i,children:s}),t[20]=p,t[21]=i,t[22]=m,t[23]=s,t[24]=l):l=t[24],l}let h=f===`collapsed`?u:``,g=l===`floating`||l===`inset`?`group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon)`,_;t[25]===g?_=t[26]:(_=qe(`relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear`,`group-data-[collapsible=offExamples]:w-0`,`group-data-[side=right]:rotate-180`,g),t[25]=g,t[26]=_);let v;t[27]===_?v=t[28]:(v=(0,W.jsx)(`div`,{className:_,"data-slot":`sidebar-gap`}),t[27]=_,t[28]=v);let y=c===`left`?`left-0 group-data-[collapsible=offExamples]:left-[calc(var(--sidebar-width)*-1)]`:`right-0 group-data-[collapsible=offExamples]:right-[calc(var(--sidebar-width)*-1)]`,b=l===`floating`||l===`inset`?`p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l`,x;t[29]!==r||t[30]!==y||t[31]!==b?(x=qe(`fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex`,y,b,r),t[29]=r,t[30]=y,t[31]=b,t[32]=x):x=t[32];let S;t[33]===n?S=t[34]:(S=(0,W.jsx)(`div`,{className:`flex size-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:shadow-sm group-data-[variant=floating]:ring-1 group-data-[variant=floating]:ring-sidebar-border`,"data-sidebar":`sidebar`,"data-slot":`sidebar-inner`,children:n}),t[33]=n,t[34]=S);let C;t[35]!==i||t[36]!==x||t[37]!==S?(C=(0,W.jsx)(`div`,{className:x,"data-slot":`sidebar-container`,...i,children:S}),t[35]=i,t[36]=x,t[37]=S,t[38]=C):C=t[38];let w;return t[39]!==c||t[40]!==f||t[41]!==C||t[42]!==h||t[43]!==v||t[44]!==l?(w=(0,W.jsxs)(`div`,{className:`group peer hidden text-sidebar-foreground md:block`,"data-collapsible":h,"data-side":c,"data-slot":`sidebar`,"data-state":f,"data-variant":l,children:[v,C]}),t[39]=c,t[40]=f,t[41]=C,t[42]=h,t[43]=v,t[44]=l,t[45]=w):w=t[45],w}function Wl(e){let t=(0,G.c)(15),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({className:n,onClick:r,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let{toggleSidebar:a}=zl(),o;t[4]===n?o=t[5]:(o=qe(n),t[4]=n,t[5]=o);let s;t[6]!==r||t[7]!==a?(s=e=>{r?.(e),a()},t[6]=r,t[7]=a,t[8]=s):s=t[8];let c,l;t[9]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,W.jsx)(po,{}),l=(0,W.jsx)(`span`,{className:`sr-only`,children:`Toggle Sidebar`}),t[9]=c,t[10]=l):(c=t[9],l=t[10]);let u;return t[11]!==i||t[12]!==o||t[13]!==s?(u=(0,W.jsxs)(_t,{className:o,"data-sidebar":`trigger`,"data-slot":`sidebar-trigger`,onClick:s,size:`icon-lg`,variant:`ghost`,...i,children:[c,l]}),t[11]=i,t[12]=o,t[13]=s,t[14]=u):u=t[14],u}function Gl(e){let t=(0,G.c)(9),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let{toggleSidebar:i}=zl(),a;t[3]===n?a=t[4]:(a=qe(`absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border sm:flex`,`in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize`,`[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize`,`group-data-[collapsible=offExamples]:translate-x-0 group-data-[collapsible=offExamples]:after:left-full hover:group-data-[collapsible=offExamples]:bg-sidebar`,`[[data-side=left][data-collapsible=offExamples]_&]:-right-2`,`[[data-side=right][data-collapsible=offExamples]_&]:-left-2`,n),t[3]=n,t[4]=a);let o;return t[5]!==r||t[6]!==a||t[7]!==i?(o=(0,W.jsx)(`button`,{"aria-label":`Toggle Sidebar`,className:a,"data-sidebar":`rail`,"data-slot":`sidebar-rail`,onClick:i,tabIndex:-1,title:`Toggle Sidebar`,...r}),t[5]=r,t[6]=a,t[7]=i,t[8]=o):o=t[8],o}function Kl(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`flex flex-col gap-2 p-2`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-sidebar":`header`,"data-slot":`sidebar-header`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function ql(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`flex flex-col gap-2 p-2`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-sidebar":`footer`,"data-slot":`sidebar-footer`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Jl(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`mx-2 w-auto bg-sidebar-border`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(kt,{className:i,"data-sidebar":`separator`,"data-slot":`sidebar-separator`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Yl(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`no-scrollbar flex min-h-0 flex-1 flex-col gap-0 overflow-auto group-data-[collapsible=icon]:overflow-hidden`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-sidebar":`content`,"data-slot":`sidebar-content`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Xl(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`relative flex w-full min-w-0 flex-col px-2 py-1`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-sidebar":`group`,"data-slot":`sidebar-group`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Zl(e){let t=(0,G.c)(10),n,r,i,a;if(t[0]!==e){let{className:o,render:s,...c}=e;n=s,a=$a,r=`div`,i=ze({className:qe(`flex h-8 shrink-0 items-center rounded-md px-2 text-xs text-sidebar-foreground/70 ring-sidebar-ring outline-hidden transition-[margin,opacity] duration-200 ease-linear group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0`,o)},c),t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a}else n=t[1],r=t[2],i=t[3],a=t[4];let o;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(o={slot:`sidebar-group-label`,sidebar:`group-label`},t[5]=o):o=t[5];let s;return t[6]!==n||t[7]!==r||t[8]!==i?(s={defaultTagName:r,props:i,render:n,state:o},t[6]=n,t[7]=r,t[8]=i,t[9]=s):s=t[9],a(s)}function Ql(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`flex w-full min-w-0 flex-col gap-px`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`ul`,{className:i,"data-sidebar":`menu`,"data-slot":`sidebar-menu`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function $l(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`group/menu-item relative`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`li`,{className:i,"data-sidebar":`menu-item`,"data-slot":`sidebar-menu-item`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}var eu=Ke(`peer/menu-button group/menu-button flex w-full items-center gap-2 overflow-hidden rounded-[calc(var(--radius-sm)+2px)] p-2 text-left text-xs ring-sidebar-ring outline-hidden transition-[width,height,padding] group-has-data-[sidebar=menu-action]/menu-item:pr-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-active:bg-sidebar-accent data-active:font-medium data-active:text-sidebar-accent-foreground data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground [&_svg]:size-4 [&_svg]:shrink-0 [&>span:last-child]:truncate`,{variants:{variant:{default:`hover:bg-sidebar-accent hover:text-sidebar-accent-foreground`,outline:`bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]`},size:{default:`h-8 text-xs`,sm:`h-7 text-xs`,lg:`h-12 text-xs group-data-[collapsible=icon]:p-0!`}},defaultVariants:{variant:`default`,size:`default`}});function tu(e){let t=(0,G.c)(15),{render:n,isActive:r,variant:i,size:a,tooltip:o,className:s,...c}=e,l=r===void 0?!1:r,u=i===void 0?`default`:i,d=a===void 0?`default`:a,{isMobile:f,state:p}=zl(),m=ze({className:qe(eu({variant:u,size:d}),s)},c),h=o?Al:n,g;t[0]!==l||t[1]!==d?(g={slot:`sidebar-menu-button`,sidebar:`menu-button`,size:d,active:l},t[0]=l,t[1]=d,t[2]=g):g=t[2];let _;t[3]!==m||t[4]!==h||t[5]!==g?(_={defaultTagName:`button`,props:m,render:h,state:g},t[3]=m,t[4]=h,t[5]=g,t[6]=_):_=t[6];let v=$a(_);if(!o)return v;let y;t[7]===o?y=t[8]:(y=typeof o==`string`?{children:o}:o,t[7]=o,t[8]=y);let b=y,x=p!==`collapsed`||f,S;t[9]!==x||t[10]!==b?(S=(0,W.jsx)(jl,{align:`center`,hidden:x,side:`right`,...b}),t[9]=x,t[10]=b,t[11]=S):S=t[11];let C;return t[12]!==v||t[13]!==S?(C=(0,W.jsxs)(kl,{children:[v,S]}),t[12]=v,t[13]=S,t[14]=C):C=t[14],C}var nu=`ap-southeast-2`,ru=9999;async function iu({action:e,credentials:t,service:n=`spinifex`}){let r=window.location.hostname,i=ru,a=window.location.protocol.replace(`:`,``),o=`Action=${e}`,s=new Ze({method:`POST`,protocol:a,hostname:r,port:i,path:`/`,headers:{host:`${r}:${i}`,"content-type":`application/x-www-form-urlencoded`},body:o}),c=await new $e({credentials:{accessKeyId:t.accessKeyId,secretAccessKey:t.secretAccessKey},region:nu,service:n,sha256:Qe}).sign(s),l={};for(let[e,t]of Object.entries(c.headers))typeof t==`string`&&(l[e]=t);let u=`${a}://${r}:${i}/`,d=await fetch(u,{method:`POST`,headers:l,body:o});if(!d.ok)throw Error(`${e} failed: ${d.status}`);return d.json()}var au=`000000000001`,ou=(0,U.createContext)(void 0);function su({children:e}){let[t,n]=(0,U.useState)({isAdmin:!1,accountId:null,userName:null,version:null,license:null,loading:!0});return(0,U.useEffect)(()=>{async function e(){let e=Xe();if(!e){n(e=>({...e,loading:!1}));return}try{let t=await iu({action:`GetCallerIdentity`,credentials:e}),r=t.account_id===au,i=null;if(r)try{i=await iu({action:`GetVersion`,credentials:e})}catch{}n({isAdmin:r,accountId:t.account_id,userName:t.user_name,version:i,license:i?.license??null,loading:!1})}catch{n(e=>({...e,loading:!1}))}}e()},[]),(0,W.jsx)(ou,{value:t,children:e})}function cu(){let e=(0,U.useContext)(ou);if(e===void 0)throw Error(`useAdmin must be used within an AdminProvider`);return e}function lu(){let e=(0,G.c)(8),{theme:t,setTheme:n}=Qa(),r;e[0]!==n||e[1]!==t?(r=()=>{n(t===`light`?`dark`:t===`dark`?`light`:`dark`)},e[0]=n,e[1]=t,e[2]=r):r=e[2];let i=r,a,o,s;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,W.jsx)(_o,{className:`size-[1.2rem] scale-100 rotate-0 transition-all dark:scale-0 dark:-rotate-90`}),o=(0,W.jsx)(uo,{className:`absolute size-[1.2rem] scale-0 rotate-90 transition-all dark:scale-100 dark:rotate-0`}),s=(0,W.jsx)(`span`,{className:`sr-only`,children:`Toggle theme`}),e[3]=a,e[4]=o,e[5]=s):(a=e[3],o=e[4],s=e[5]);let c;return e[6]===i?c=e[7]:(c=(0,W.jsxs)(_t,{className:`rounded-full`,onClick:i,size:`icon-sm`,variant:`ghost`,children:[a,o,s]}),e[6]=i,e[7]=c),c}function uu(){let e=(0,G.c)(7),{isAdmin:t,license:n}=cu(),r=t&&n===`open-source`,i,a;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(i=qe(`z-50 flex h-10 shrink-0 items-center gap-2 border-b border-sidebar-border bg-sidebar px-4 text-sidebar-foreground`,`sticky top-0`),a=(0,W.jsx)(Wl,{className:`-ml-1`}),e[0]=i,e[1]=a):(i=e[0],a=e[1]);let o;e[2]===r?o=e[3]:(o=r&&(0,W.jsx)(`a`,{href:`https://mulgadc.com/purchase`,target:`_blank`,rel:`noopener noreferrer`,className:qe(ft({variant:`outline`,size:`sm`})),children:`Upgrade`}),e[2]=r,e[3]=o);let s;e[4]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,W.jsx)(lu,{}),e[4]=s):s=e[4];let c;return e[5]===o?c=e[6]:(c=(0,W.jsxs)(`header`,{className:i,children:[a,(0,W.jsxs)(`div`,{className:`flex w-full items-center justify-end gap-2`,children:[o,s]})]}),e[5]=o,e[6]=c),c}function du(){let e=(0,G.c)(3),t,n;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,W.jsx)(`h1`,{className:`text-4xl font-bold`,children:`404`}),n=(0,W.jsx)(`p`,{className:`text-muted-foreground`,children:`Page not found`}),e[0]=t,e[1]=n):(t=e[0],n=e[1]);let r;return e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,W.jsxs)(`div`,{className:`flex flex-1 flex-col items-center justify-center gap-4`,children:[t,n,(0,W.jsx)(Pe,{to:`/`,children:(0,W.jsx)(_t,{variant:`outline`,children:`Go back home`})})]}),e[2]=r):r=e[2],r}function fu(){let e=(0,G.c)(130),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t={select:pu},e[0]=t):t=e[0];let n=za(t),r=Ie(),i=S(),{isAdmin:a}=cu(),o;e[1]!==r||e[2]!==i?(o=function(){et(),Re(),i.clear(),r({to:`/login`})},e[1]=r,e[2]=i,e[3]=o):o=e[3];let s=o,c;e[4]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,W.jsxs)(Kl,{className:`flex flex-row items-center gap-2 px-4 py-3`,children:[(0,W.jsx)(`img`,{src:`/mulga-logo.svg`,alt:`Mulga`,className:`size-6 shrink-0 dark:invert`}),(0,W.jsx)(`span`,{className:`truncate text-sm font-semibold group-data-[collapsible=icon]:hidden`,children:`Spinifex`})]}),e[4]=c):c=e[4];let l;e[5]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,W.jsx)(Zl,{children:`General`}),e[5]=l):l=e[5];let u=n===`/`,d,f;e[6]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,W.jsx)(ao,{className:`size-4`}),f=(0,W.jsx)(`span`,{children:`Dashboard`}),e[6]=d,e[7]=f):(d=e[6],f=e[7]);let p;e[8]===u?p=e[9]:(p=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/`,children:(0,W.jsxs)(tu,{isActive:u,tooltip:`Dashboard`,children:[d,f]})})}),e[8]=u,e[9]=p);let m;e[10]!==a||e[11]!==n?(m=a&&(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/nodes`,children:(0,W.jsxs)(tu,{isActive:n.startsWith(`/nodes`),tooltip:`Nodes`,children:[(0,W.jsx)(mo,{className:`size-4`}),(0,W.jsx)(`span`,{children:`Nodes`})]})})}),e[10]=a,e[11]=n,e[12]=m):m=e[12];let h;e[13]!==p||e[14]!==m?(h=(0,W.jsxs)(Xl,{children:[l,(0,W.jsxs)(Ql,{children:[p,m]})]}),e[13]=p,e[14]=m,e[15]=h):h=e[15];let g;e[16]===Symbol.for(`react.memo_cache_sentinel`)?(g=(0,W.jsx)(Zl,{children:`EC2`}),e[16]=g):g=e[16];let _;e[17]===n?_=e[18]:(_=n.startsWith(`/ec2/describe-instances`)||n.startsWith(`/ec2/run-instances`),e[17]=n,e[18]=_);let v,y;e[19]===Symbol.for(`react.memo_cache_sentinel`)?(v=(0,W.jsx)(mo,{className:`size-4`}),y=(0,W.jsx)(`span`,{children:`Instances`}),e[19]=v,e[20]=y):(v=e[19],y=e[20]);let b;e[21]===_?b=e[22]:(b=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-instances`,children:(0,W.jsxs)(tu,{isActive:_,tooltip:`EC2 Instances`,children:[v,y]})})}),e[21]=_,e[22]=b);let x;e[23]===n?x=e[24]:(x=n.startsWith(`/ec2/describe-images`),e[23]=n,e[24]=x);let C,w;e[25]===Symbol.for(`react.memo_cache_sentinel`)?(C=(0,W.jsx)(oo,{className:`size-4`}),w=(0,W.jsx)(`span`,{children:`Images`}),e[25]=C,e[26]=w):(C=e[25],w=e[26]);let T;e[27]===x?T=e[28]:(T=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-images`,children:(0,W.jsxs)(tu,{isActive:x,tooltip:`Images`,children:[C,w]})})}),e[27]=x,e[28]=T);let E;e[29]===n?E=e[30]:(E=n.startsWith(`/ec2/describe-key-pairs`),e[29]=n,e[30]=E);let D,O;e[31]===Symbol.for(`react.memo_cache_sentinel`)?(D=(0,W.jsx)(K,{className:`size-4`}),O=(0,W.jsx)(`span`,{children:`Key Pairs`}),e[31]=D,e[32]=O):(D=e[31],O=e[32]);let k;e[33]===E?k=e[34]:(k=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-key-pairs`,children:(0,W.jsxs)(tu,{isActive:E,tooltip:`Key Pairs`,children:[D,O]})})}),e[33]=E,e[34]=k);let A;e[35]===n?A=e[36]:(A=n.startsWith(`/ec2/describe-volumes`)||n.startsWith(`/ec2/create-volume`)||n.startsWith(`/ec2/modify-volume`),e[35]=n,e[36]=A);let ee,j;e[37]===Symbol.for(`react.memo_cache_sentinel`)?(ee=(0,W.jsx)(io,{className:`size-4`}),j=(0,W.jsx)(`span`,{children:`Volumes`}),e[37]=ee,e[38]=j):(ee=e[37],j=e[38]);let M;e[39]===A?M=e[40]:(M=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-volumes`,children:(0,W.jsxs)(tu,{isActive:A,tooltip:`Volumes`,children:[ee,j]})})}),e[39]=A,e[40]=M);let N;e[41]===n?N=e[42]:(N=n.startsWith(`/ec2/describe-snapshots`)||n.startsWith(`/ec2/create-snapshot`),e[41]=n,e[42]=N);let P,te;e[43]===Symbol.for(`react.memo_cache_sentinel`)?(P=(0,W.jsx)(no,{className:`size-4`}),te=(0,W.jsx)(`span`,{children:`Snapshots`}),e[43]=P,e[44]=te):(P=e[43],te=e[44]);let ne;e[45]===N?ne=e[46]:(ne=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-snapshots`,children:(0,W.jsxs)(tu,{isActive:N,tooltip:`Snapshots`,children:[P,te]})})}),e[45]=N,e[46]=ne);let re;e[47]===n?re=e[48]:(re=n.startsWith(`/ec2/describe-placement-groups`)||n.startsWith(`/ec2/create-placement-group`),e[47]=n,e[48]=re);let ie,F;e[49]===Symbol.for(`react.memo_cache_sentinel`)?(ie=(0,W.jsx)(so,{className:`size-4`}),F=(0,W.jsx)(`span`,{children:`Placement Groups`}),e[49]=ie,e[50]=F):(ie=e[49],F=e[50]);let I;e[51]===re?I=e[52]:(I=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-placement-groups`,children:(0,W.jsxs)(tu,{isActive:re,tooltip:`Placement Groups`,children:[ie,F]})})}),e[51]=re,e[52]=I);let ae;e[53]!==b||e[54]!==T||e[55]!==k||e[56]!==M||e[57]!==ne||e[58]!==I?(ae=(0,W.jsxs)(Xl,{children:[g,(0,W.jsxs)(Ql,{children:[b,T,k,M,ne,I]})]}),e[53]=b,e[54]=T,e[55]=k,e[56]=M,e[57]=ne,e[58]=I,e[59]=ae):ae=e[59];let oe;e[60]===Symbol.for(`react.memo_cache_sentinel`)?(oe=(0,W.jsx)(Zl,{children:`Networking`}),e[60]=oe):oe=e[60];let se;e[61]===n?se=e[62]:(se=n.startsWith(`/ec2/describe-vpcs`)||n.startsWith(`/ec2/create-vpc`),e[61]=n,e[62]=se);let ce,le;e[63]===Symbol.for(`react.memo_cache_sentinel`)?(ce=(0,W.jsx)(fo,{className:`size-4`}),le=(0,W.jsx)(`span`,{children:`VPCs`}),e[63]=ce,e[64]=le):(ce=e[63],le=e[64]);let ue;e[65]===se?ue=e[66]:(ue=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-vpcs`,children:(0,W.jsxs)(tu,{isActive:se,tooltip:`VPCs`,children:[ce,le]})})}),e[65]=se,e[66]=ue);let de;e[67]===n?de=e[68]:(de=n.startsWith(`/ec2/describe-subnets`)||n.startsWith(`/ec2/create-subnet`),e[67]=n,e[68]=de);let fe,pe;e[69]===Symbol.for(`react.memo_cache_sentinel`)?(fe=(0,W.jsx)(co,{className:`size-4`}),pe=(0,W.jsx)(`span`,{children:`Subnets`}),e[69]=fe,e[70]=pe):(fe=e[69],pe=e[70]);let me;e[71]===de?me=e[72]:(me=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-subnets`,children:(0,W.jsxs)(tu,{isActive:de,tooltip:`Subnets`,children:[fe,pe]})})}),e[71]=de,e[72]=me);let he;e[73]===n?he=e[74]:(he=n.startsWith(`/ec2/describe-security-groups`)||n.startsWith(`/ec2/create-security-group`),e[73]=n,e[74]=he);let ge,_e;e[75]===Symbol.for(`react.memo_cache_sentinel`)?(ge=(0,W.jsx)(ho,{className:`size-4`}),_e=(0,W.jsx)(`span`,{children:`Security Groups`}),e[75]=ge,e[76]=_e):(ge=e[75],_e=e[76]);let ve;e[77]===he?ve=e[78]:(ve=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-security-groups`,children:(0,W.jsxs)(tu,{isActive:he,tooltip:`Security Groups`,children:[ge,_e]})})}),e[77]=he,e[78]=ve);let ye;e[79]!==ue||e[80]!==me||e[81]!==ve?(ye=(0,W.jsxs)(Xl,{children:[oe,(0,W.jsxs)(Ql,{children:[ue,me,ve]})]}),e[79]=ue,e[80]=me,e[81]=ve,e[82]=ye):ye=e[82];let be;e[83]===Symbol.for(`react.memo_cache_sentinel`)?(be=(0,W.jsx)(Zl,{children:`IAM`}),e[83]=be):be=e[83];let xe;e[84]===n?xe=e[85]:(xe=n.startsWith(`/iam/list-users`)||n.startsWith(`/iam/create-user`),e[84]=n,e[85]=xe);let Se,Ce;e[86]===Symbol.for(`react.memo_cache_sentinel`)?(Se=(0,W.jsx)(vo,{className:`size-4`}),Ce=(0,W.jsx)(`span`,{children:`Users`}),e[86]=Se,e[87]=Ce):(Se=e[86],Ce=e[87]);let we;e[88]===xe?we=e[89]:(we=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/iam/list-users`,children:(0,W.jsxs)(tu,{isActive:xe,tooltip:`Users`,children:[Se,Ce]})})}),e[88]=xe,e[89]=we);let Te;e[90]===n?Te=e[91]:(Te=n.startsWith(`/iam/list-policies`)||n.startsWith(`/iam/create-policy`),e[90]=n,e[91]=Te);let Ee,De;e[92]===Symbol.for(`react.memo_cache_sentinel`)?(Ee=(0,W.jsx)(go,{className:`size-4`}),De=(0,W.jsx)(`span`,{children:`Policies`}),e[92]=Ee,e[93]=De):(Ee=e[92],De=e[93]);let Oe;e[94]===Te?Oe=e[95]:(Oe=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/iam/list-policies`,children:(0,W.jsxs)(tu,{isActive:Te,tooltip:`Policies`,children:[Ee,De]})})}),e[94]=Te,e[95]=Oe);let ke;e[96]!==we||e[97]!==Oe?(ke=(0,W.jsxs)(Xl,{children:[be,(0,W.jsxs)(Ql,{children:[we,Oe]})]}),e[96]=we,e[97]=Oe,e[98]=ke):ke=e[98];let Ae;e[99]===Symbol.for(`react.memo_cache_sentinel`)?(Ae=(0,W.jsx)(Zl,{children:`S3`}),e[99]=Ae):Ae=e[99];let je;e[100]===n?je=e[101]:(je=n.startsWith(`/s3/ls`),e[100]=n,e[101]=je);let Me,Ne;e[102]===Symbol.for(`react.memo_cache_sentinel`)?(Me=(0,W.jsx)(mo,{className:`size-4`}),Ne=(0,W.jsx)(`span`,{children:`Buckets`}),e[102]=Me,e[103]=Ne):(Me=e[102],Ne=e[103]);let L;e[104]===je?L=e[105]:(L=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/s3/ls`,children:(0,W.jsxs)(tu,{isActive:je,tooltip:`Buckets`,children:[Me,Ne]})})}),e[104]=je,e[105]=L);let Fe;e[106]!==a||e[107]!==n?(Fe=a&&(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/s3/service-metrics`,children:(0,W.jsxs)(tu,{isActive:n.startsWith(`/s3/service-metrics`),tooltip:`Service Metrics`,children:[(0,W.jsx)(eo,{className:`size-4`}),(0,W.jsx)(`span`,{children:`Service Metrics`})]})})}),e[106]=a,e[107]=n,e[108]=Fe):Fe=e[108];let R;e[109]!==L||e[110]!==Fe?(R=(0,W.jsxs)(Xl,{children:[Ae,(0,W.jsxs)(Ql,{children:[L,Fe]})]}),e[109]=L,e[110]=Fe,e[111]=R):R=e[111];let z;e[112]===a?z=e[113]:(z=a&&(0,W.jsxs)(Xl,{children:[(0,W.jsx)(Zl,{children:`Documentation`}),(0,W.jsx)(Ql,{children:(0,W.jsx)($l,{children:(0,W.jsx)(`a`,{href:`https://docs.mulgadc.com`,target:`_blank`,rel:`noopener noreferrer`,children:(0,W.jsxs)(tu,{tooltip:`Documentation`,children:[(0,W.jsx)(to,{className:`size-4`}),(0,W.jsx)(`span`,{children:`Docs`})]})})})})]}),e[112]=a,e[113]=z);let Le;e[114]!==ae||e[115]!==ye||e[116]!==ke||e[117]!==R||e[118]!==z||e[119]!==h?(Le=(0,W.jsxs)(Yl,{children:[h,ae,ye,ke,R,z]}),e[114]=ae,e[115]=ye,e[116]=ke,e[117]=R,e[118]=z,e[119]=h,e[120]=Le):Le=e[120];let ze;e[121]===Symbol.for(`react.memo_cache_sentinel`)?(ze=(0,W.jsx)(Jl,{className:`mx-0 w-full`}),e[121]=ze):ze=e[121];let Be,Ve;e[122]===Symbol.for(`react.memo_cache_sentinel`)?(Be=(0,W.jsx)(lo,{className:`size-4`}),Ve=(0,W.jsx)(`span`,{children:`Sign out`}),e[122]=Be,e[123]=Ve):(Be=e[122],Ve=e[123]);let He;e[124]===s?He=e[125]:(He=(0,W.jsxs)(ql,{children:[ze,(0,W.jsx)(Ql,{children:(0,W.jsx)($l,{children:(0,W.jsxs)(tu,{onClick:s,tooltip:`Sign out`,children:[Be,Ve]})})})]}),e[124]=s,e[125]=He);let Ue;e[126]===Symbol.for(`react.memo_cache_sentinel`)?(Ue=(0,W.jsx)(Gl,{}),e[126]=Ue):Ue=e[126];let We;return e[127]!==Le||e[128]!==He?(We=(0,W.jsxs)(Ul,{collapsible:`icon`,children:[c,Le,He,Ue]}),e[127]=Le,e[128]=He,e[129]=We):We=e[129],We}function pu(e){return e.pathname}function mu(e){let t=(0,G.c)(18),{error:n,reset:r}=e,i=N(),a=S(),o;t[0]!==a||t[1]!==r||t[2]!==i?(o=function(){a.invalidateQueries(),r(),i.invalidate()},t[0]=a,t[1]=r,t[2]=i,t[3]=o):o=t[3];let s=o,c;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,W.jsx)(fu,{}),t[4]=c):c=t[4];let l;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,W.jsx)(uu,{}),t[5]=l):l=t[5];let u,d;t[6]===Symbol.for(`react.memo_cache_sentinel`)?(u=(0,W.jsx)(`div`,{className:`flex justify-center`,children:(0,W.jsx)(ro,{className:`size-12 text-destructive`})}),d=(0,W.jsx)(`h1`,{className:`text-2xl font-semibold`,children:`Something went wrong`}),t[6]=u,t[7]=d):(u=t[6],d=t[7]);let f=n.message||`An unexpected error occurred`,p;t[8]===f?p=t[9]:(p=(0,W.jsx)(`p`,{className:`text-muted-foreground`,children:f}),t[8]=f,t[9]=p);let m;t[10]===s?m=t[11]:(m=(0,W.jsx)(_t,{onClick:s,variant:`default`,children:`Try Again`}),t[10]=s,t[11]=m);let h;t[12]===Symbol.for(`react.memo_cache_sentinel`)?(h=(0,W.jsx)(Pe,{to:`/`,children:(0,W.jsx)(_t,{variant:`outline`,children:`Go Home`})}),t[12]=h):h=t[12];let g;t[13]===m?g=t[14]:(g=(0,W.jsxs)(`div`,{className:`flex justify-center gap-2`,children:[m,h]}),t[13]=m,t[14]=g);let _;return t[15]!==g||t[16]!==p?(_=(0,W.jsxs)(W.Fragment,{children:[c,(0,W.jsxs)(`main`,{className:`flex flex-1 flex-col`,children:[l,(0,W.jsx)(`div`,{className:`flex flex-1 items-center justify-center p-6 pt-0`,children:(0,W.jsxs)(`div`,{className:`max-w-md space-y-4 text-center`,children:[u,d,p,g]})})]})]}),t[15]=g,t[16]=p,t[17]=_):_=t[17],_}var hu=Fe()({head:()=>({meta:[{title:`Mulga`}]}),component:()=>(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(Wa,{}),(0,W.jsx)(fu,{}),(0,W.jsxs)(`main`,{className:`flex flex-1 flex-col`,children:[(0,W.jsx)(uu,{}),(0,W.jsx)(`div`,{className:`flex flex-1 flex-col p-8`,children:(0,W.jsx)(Aa,{})})]})]}),errorComponent:mu,notFoundComponent:du}),gu=L(`/login`)({beforeLoad:()=>{if(Xe())throw Me({to:`/`})},component:R(()=>z(()=>import(`./login.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16])),`component`)}),_u=L(`/_auth`)({beforeLoad:()=>{if(!Xe())throw Me({to:`/login`})},component:R(()=>z(()=>import(`./route.js`),__vite__mapDeps([17,1])),`component`)}),vu=L(`/_auth/`)({loader:async({context:e})=>{await Promise.all([e.queryClient.ensureQueryData(or),e.queryClient.ensureQueryData(mr),e.queryClient.ensureQueryData(pr),e.queryClient.ensureQueryData(Zn),e.queryClient.ensureQueryData(Sr),e.queryClient.ensureQueryData(sr)])},head:()=>({meta:[{title:`Dashboard | Mulga`}]}),component:R(()=>z(()=>import(`./_auth.js`),__vite__mapDeps([18,1,3,4,19,2,5,6,20,21,22,8,23,24,25,26,14,27,28,29,30,31,15])),`component`)}),yu=L(`/_auth/nodes`)({beforeLoad:()=>{},head:()=>({meta:[{title:`Nodes | Mulga`}]}),component:R(()=>z(()=>import(`./nodes.js`),__vite__mapDeps([32,1,22,3,4,8,23,24,20,33,30,15])),`component`)}),bu=L(`/_auth/s3/service-metrics`)({head:()=>({meta:[{title:`Service Metrics | Mulga`}]}),component:R(()=>z(()=>import(`./service-metrics.js`),__vite__mapDeps([34,1,22,3,4,8,23,24,20,33,30,15])),`component`)}),xu=L(`/_auth/s3/ls/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(Sr)},head:()=>({meta:[{title:`Buckets | S3 | Mulga`}]}),component:R(()=>z(()=>import(`./ls.js`),__vite__mapDeps([35,1,3,4,21,2,5,20,7,8,36,23,24,25,26,14,37,30])),`component`)}),Su=L(`/_auth/s3/(buckets)/create-bucket`)({head:()=>({meta:[{title:`Create Bucket | S3 | Mulga`}]}),component:R(()=>z(()=>import(`./create-bucket.js`),__vite__mapDeps([38,1,39,2,3,4,5,24,40,12,13,14,41,25,26,27,42,7,8,43,28,44,45,46,30,16,9,10])),`component`)}),Cu=L(`/_auth/iam/(users)/create-user`)({head:()=>({meta:[{title:`Create User | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./create-user.js`),__vite__mapDeps([47,1,48,2,3,4,5,24,40,12,13,14,41,25,26,27,42,7,8,43,28,44,45,46,30,16,9,10,49])),`component`)}),wu=L(`/_auth/iam/(policies)/create-policy`)({head:()=>({meta:[{title:`Create Policy | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./create-policy.js`),__vite__mapDeps([50,1,48,2,3,4,5,24,40,12,13,14,41,25,26,27,42,7,8,43,28,44,45,46,30,16,9,10,51,49])),`component`)}),Tu=L(`/_auth/ec2/(vpc)/create-vpc`)({head:()=>({meta:[{title:`Create VPC | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-vpc.js`),__vite__mapDeps([52,1,53,2,3,4,5,19,6,20,24,40,7,8,54,55,10,11,26,9,27,43,28,12,13,14,41,25,29,42,44,45,46,30,16,56])),`component`)}),Eu=L(`/_auth/ec2/(volumes)/create-volume`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(ur)},head:()=>({meta:[{title:`Create Volume | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-volume.js`),__vite__mapDeps([57,1,53,2,3,4,5,19,6,20,24,40,54,7,8,55,10,11,26,9,27,43,28,12,36,23,13,14,41,25,42,44,45,46,30,16,56])),`component`)}),Du=L(`/_auth/ec2/(subnet)/create-subnet`)({loader:async({context:e})=>{await Promise.all([e.queryClient.ensureQueryData(pr),e.queryClient.ensureQueryData(ur)])},head:()=>({meta:[{title:`Create Subnet | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-subnet.js`),__vite__mapDeps([58,1,3,4,53,2,5,19,6,20,24,40,54,7,8,55,10,11,26,9,27,43,28,12,36,23,13,14,41,25,42,44,45,46,30,16,56])),`component`)}),Ou=L(`/_auth/ec2/(snapshots)/create-snapshot`)({validateSearch:e=>({volumeId:typeof e.volumeId==`string`?e.volumeId:void 0}),loader:async({context:e})=>{await e.queryClient.ensureQueryData(mr)},head:()=>({meta:[{title:`Create Snapshot | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-snapshot.js`),__vite__mapDeps([59,1,53,2,3,4,5,19,6,20,24,40,54,7,8,55,10,11,26,9,27,43,28,12,36,23,13,14,41,25,42,44,45,46,30,16,51,56])),`component`)}),ku=L(`/_auth/ec2/(security-groups)/create-security-group`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(pr)},head:()=>({meta:[{title:`Create Security Group | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-security-group.js`),__vite__mapDeps([60,1,3,4,53,2,5,19,6,20,24,40,54,7,8,55,10,11,26,9,27,43,28,12,36,23,13,14,41,25,42,44,45,46,30,16,56])),`component`)}),Au=L(`/_auth/ec2/(placement-groups)/create-placement-group`)({head:()=>({meta:[{title:`Create Placement Group | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-placement-group.js`),__vite__mapDeps([61,1,53,2,3,4,5,19,6,20,24,40,54,7,8,55,10,11,26,9,27,43,28,12,13,14,41,25,42,44,45,46,30,16,56])),`component`)}),ju=L(`/_auth/ec2/(key)/import-key-pair`)({head:()=>({meta:[{title:`Import Key Pair | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./import-key-pair.js`),__vite__mapDeps([62,1,53,2,3,4,5,19,6,20,24,40,12,13,14,41,25,26,27,42,7,8,43,28,44,45,46,30,16,9,10,51,56])),`component`)}),Mu=L(`/_auth/ec2/(key)/create-key-pair`)({head:()=>({meta:[{title:`Create Key Pair | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-key-pair.js`),__vite__mapDeps([63,1,53,2,3,4,5,19,6,20,24,40,64,7,8,12,13,14,41,25,26,27,43,65,42,28,44,45,66,46,30,16,9,10,51,56])),`component`)}),Nu=L(`/_auth/ec2/(instances)/run-instances`)({loader:async({context:e})=>{await Promise.all([e.queryClient.ensureQueryData(cr),e.queryClient.ensureQueryData(Zn),e.queryClient.ensureQueryData(Yn),e.queryClient.ensureQueryData(Jn),e.queryClient.ensureQueryData(dr)])},head:()=>({meta:[{title:`Run Instances | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./run-instances.js`),__vite__mapDeps([67,1,53,2,3,4,5,19,6,20,24,40,7,8,54,55,10,11,26,9,27,43,28,12,36,23,13,14,41,25,42,44,45,30,16,56])),`component`)}),Pu=L(`/_auth/s3/ls/$bucket`)({component:R(()=>z(()=>import(`./route2.js`),__vite__mapDeps([68,1])),`component`)}),Fu=L(`/_auth/s3/ls/$bucket/`)({loader:async({context:e,params:t})=>{await e.queryClient.ensureQueryData(Cr(t.bucket))},head:({params:e})=>({meta:[{title:`${e.bucket} | S3 | Mulga`}]}),component:R(()=>z(()=>import(`./_bucket.js`),__vite__mapDeps([69,1,39,2,3,4,5,24,40,70,7,8,25,26,14,27,65,71,72,64,21,20,36,23,41,30])),`component`)}),Iu=L(`/_auth/iam/(users)/list-users/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(br)},head:()=>({meta:[{title:`Users | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./list-users.js`),__vite__mapDeps([73,1,74,2,3,4,5,20,7,8,36,23,24,25,26,14,37,30])),`component`)}),Lu=L(`/_auth/iam/(policies)/list-policies/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(yr)},head:()=>({meta:[{title:`Policies | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./list-policies.js`),__vite__mapDeps([75,1,74,2,3,4,5,20,7,8,36,23,24,25,26,14,37,30])),`component`)}),Ru=L(`/_auth/ec2/(vpc)/describe-vpcs/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(pr)},head:()=>({meta:[{title:`VPCs | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-vpcs.js`),__vite__mapDeps([76,1,3,4,19,2,5,6,20,7,8,36,23,24,25,26,14,37,30,31])),`component`)}),zu=L(`/_auth/ec2/(volumes)/describe-volumes/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(mr)},head:()=>({meta:[{title:`Volumes | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-volumes.js`),__vite__mapDeps([77,1,19,2,3,4,5,6,20,7,8,36,23,24,25,26,14,37,30,31])),`component`)}),Bu=L(`/_auth/ec2/(subnet)/describe-subnets/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(Jn)},head:()=>({meta:[{title:`Subnets | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-subnets.js`),__vite__mapDeps([78,1,3,4,19,2,5,6,20,7,8,36,23,24,25,26,14,37,30,31])),`component`)}),Vu=L(`/_auth/ec2/(snapshots)/describe-snapshots/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(tr)},head:()=>({meta:[{title:`Snapshots | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-snapshots.js`),__vite__mapDeps([79,1,19,2,3,4,5,6,20,7,8,36,23,24,25,26,14,37,30,31])),`component`)}),Hu=L(`/_auth/ec2/(security-groups)/describe-security-groups/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(sr)},head:()=>({meta:[{title:`Security Groups | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-security-groups.js`),__vite__mapDeps([80,1,19,2,3,4,5,6,20,7,8,36,23,24,25,26,14,37,30])),`component`)}),Uu=L(`/_auth/ec2/(placement-groups)/describe-placement-groups/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(dr)},head:()=>({meta:[{title:`Placement Groups | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-placement-groups.js`),__vite__mapDeps([81,1,19,2,3,4,5,6,20,7,8,36,23,24,25,26,14,37,30,31])),`component`)}),Wu=L(`/_auth/ec2/(key)/describe-key-pairs/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(Zn)},head:()=>({meta:[{title:`Key Pairs | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-key-pairs.js`),__vite__mapDeps([82,1,19,2,3,4,5,6,20,7,8,36,23,24,25,26,14,37,30])),`component`)}),Z=L(`/_auth/ec2/(instances)/describe-instances/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(or)},head:()=>({meta:[{title:`Instances | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-instances.js`),__vite__mapDeps([83,1,19,2,3,4,5,6,20,7,8,36,23,24,25,26,14,37,30,31])),`component`)}),Gu=L(`/_auth/ec2/(images)/describe-images/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(cr)},head:()=>({meta:[{title:`Images | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-images.js`),__vite__mapDeps([84,1,19,2,3,4,5,6,20,36,23,24,37,25,26,14,30,31])),`component`)}),Ku=L(`/_auth/s3/ls/$bucket/$`)({loader:async({context:e,params:t})=>{let n=Je(t._splat??``);await e.queryClient.ensureQueryData(Cr(t.bucket,n))},head:({params:e})=>({meta:[{title:`${Ye(e._splat??``,`${e.bucket}/`)} | S3 | Mulga`}]}),component:R(()=>z(()=>import(`./_.js`),__vite__mapDeps([85,1,39,2,3,4,5,24,40,70,7,8,25,26,14,27,65,71,72,64,21,20,36,23,41])),`component`)}),qu=L(`/_auth/iam/(users)/list-users/$userName`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(vr(t.userName)),e.queryClient.ensureQueryData(xr(t.userName)),e.queryClient.ensureQueryData(_r(t.userName)),e.queryClient.ensureQueryData(yr)])},head:({params:e})=>({meta:[{title:`${e.userName} | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./_userName.js`),__vite__mapDeps([86,1,3,4,48,2,5,24,40,74,20,64,7,8,36,23,13,14,41,25,26,27,43,71,66,72,87,30,31,45])),`component`)}),Ju=L(`/_auth/iam/(policies)/list-policies/$policyArn`)({loader:async({context:e,params:t})=>{let n=decodeURIComponent(t.policyArn),r=await e.queryClient.ensureQueryData(gr(n)),i=r.Policy?.DefaultVersionId;return i&&await e.queryClient.ensureQueryData(hr(n,i)),r},head:({loaderData:e})=>({meta:[{title:`${e?.Policy?.PolicyName??`Policy`} | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./_policyArn.js`),__vite__mapDeps([88,1,3,4,48,2,5,24,40,74,20,7,8,36,23,13,14,41,25,26,27,71,72,64,87,30])),`component`)}),Yu=L(`/_auth/ec2/(vpc)/describe-vpcs/$id`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(Xn(t.id)),e.queryClient.ensureQueryData(Jn)])},head:({params:e})=>({meta:[{title:`${e.id} | VPC | Mulga`}]}),component:R(()=>z(()=>import(`./_id10.js`),__vite__mapDeps([89,1,3,4,53,2,5,19,6,20,24,40,7,8,36,23,25,26,14,13,41,27,71,72,64,87,30,31])),`component`)}),Xu=L(`/_auth/ec2/(volumes)/modify-volume/$id`)({loader:async({context:e,params:t})=>{await e.queryClient.ensureQueryData(fr(t.id))},head:({params:e})=>({meta:[{title:`Resize ${e.id} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id9.js`),__vite__mapDeps([90,1,53,2,3,4,5,19,6,20,24,40,12,36,23,13,14,41,25,26,27,46,7,8,30,16,9,10,56])),`component`)}),Zu=L(`/_auth/ec2/(volumes)/describe-volumes/$id`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(fr(t.id)),e.queryClient.ensureQueryData(or)])},head:({params:e})=>({meta:[{title:`${e.id} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id8.js`),__vite__mapDeps([91,1,3,4,53,2,5,19,6,20,24,40,64,7,8,54,55,10,11,26,9,27,43,28,36,23,25,14,13,41,71,72,87,30,31,16])),`component`)}),Qu=L(`/_auth/ec2/(subnet)/describe-subnets/$id`)({loader:async({context:e,params:t})=>{await e.queryClient.ensureQueryData(er(t.id))},head:({params:e})=>({meta:[{title:`${e.id} | Subnet | Mulga`}]}),component:R(()=>z(()=>import(`./_id7.js`),__vite__mapDeps([92,1,3,4,53,2,5,19,6,20,24,40,7,8,36,23,25,26,14,13,41,27,71,72,64,87,30,31])),`component`)}),$u=L(`/_auth/ec2/(snapshots)/describe-snapshots/$id`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(ir(t.id)),e.queryClient.ensureQueryData(Qn)])},head:({params:e})=>({meta:[{title:`${e.id} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id6.js`),__vite__mapDeps([93,1,3,4,53,2,5,19,6,20,24,40,64,7,8,36,23,25,26,14,13,41,27,44,71,72,87,30,31,16,9,10])),`component`)}),ed=L(`/_auth/ec2/(security-groups)/describe-security-groups/$id`)({loader:async({context:e,params:t})=>{await e.queryClient.ensureQueryData($n(t.id))},head:({params:e})=>({meta:[{title:`${e.id} | Security Group | Mulga`}]}),component:R(()=>z(()=>import(`./_id5.js`),__vite__mapDeps([94,1,53,2,3,4,5,19,6,20,24,40,64,7,8,54,55,10,11,26,9,27,43,28,12,36,23,25,14,13,41,71,72,87,30,16,56])),`component`)}),td=L(`/_auth/ec2/(placement-groups)/describe-placement-groups/$id`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(rr(t.id)),e.queryClient.ensureQueryData(or)])},head:({params:e})=>({meta:[{title:`${e.id} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id4.js`),__vite__mapDeps([95,1,53,2,3,4,5,19,6,20,24,40,7,8,36,23,25,26,14,13,41,27,71,72,64,87,30,31])),`component`)}),nd=L(`/_auth/ec2/(key)/describe-key-pairs/$id`)({loader:async({context:e,params:t})=>await e.queryClient.ensureQueryData(lr(t.id)),head:({loaderData:e})=>({meta:[{title:`${e?.KeyPairs?.[0]?.KeyName??`Key Pair`} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id3.js`),__vite__mapDeps([96,1,3,4,53,2,5,19,6,20,24,40,7,8,36,23,13,14,41,25,26,27,71,72,64,87,30])),`component`)}),rd=L(`/_auth/ec2/(instances)/describe-instances/$id`)({loader:async({context:e,params:t})=>{let[n]=await Promise.all([e.queryClient.ensureQueryData(nr(t.id)),e.queryClient.ensureQueryData(Yn)]),r=n.Reservations?.[0]?.Instances?.[0]?.ImageId;return await e.queryClient.ensureQueryData(ar(r)),n},head:({loaderData:e})=>({meta:[{title:`${e?.Reservations?.[0]?.Instances?.[0]?.InstanceId??`Instance`} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id2.js`),__vite__mapDeps([97,1,3,4,53,2,5,19,6,20,24,40,64,7,8,54,55,10,11,26,9,27,43,28,36,23,25,14,41,71,87,30,31,16,51,98])),`component`)}),id=L(`/_auth/ec2/(images)/describe-images/$id`)({loader:async({context:e,params:t})=>await e.queryClient.ensureQueryData(ar(t.id)),head:({loaderData:e})=>({meta:[{title:`${e?.Images?.[0]?.Name??`Image`} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id.js`),__vite__mapDeps([99,1,19,2,3,4,5,6,20,36,23,24,41,25,26,14,27,30,31,98,87])),`component`)}),ad=gu.update({id:`/login`,path:`/login`,getParentRoute:()=>hu}),Q=_u.update({id:`/_auth`,getParentRoute:()=>hu}),od=vu.update({id:`/`,path:`/`,getParentRoute:()=>Q}),sd=yu.update({id:`/nodes`,path:`/nodes`,getParentRoute:()=>Q}),cd=bu.update({id:`/s3/service-metrics`,path:`/s3/service-metrics`,getParentRoute:()=>Q}),ld=xu.update({id:`/s3/ls/`,path:`/s3/ls/`,getParentRoute:()=>Q}),ud=Su.update({id:`/s3/(buckets)/create-bucket`,path:`/s3/create-bucket`,getParentRoute:()=>Q}),dd=Cu.update({id:`/iam/(users)/create-user`,path:`/iam/create-user`,getParentRoute:()=>Q}),fd=wu.update({id:`/iam/(policies)/create-policy`,path:`/iam/create-policy`,getParentRoute:()=>Q}),pd=Tu.update({id:`/ec2/(vpc)/create-vpc`,path:`/ec2/create-vpc`,getParentRoute:()=>Q}),md=Eu.update({id:`/ec2/(volumes)/create-volume`,path:`/ec2/create-volume`,getParentRoute:()=>Q}),hd=Du.update({id:`/ec2/(subnet)/create-subnet`,path:`/ec2/create-subnet`,getParentRoute:()=>Q}),gd=Ou.update({id:`/ec2/(snapshots)/create-snapshot`,path:`/ec2/create-snapshot`,getParentRoute:()=>Q}),_d=ku.update({id:`/ec2/(security-groups)/create-security-group`,path:`/ec2/create-security-group`,getParentRoute:()=>Q}),vd=Au.update({id:`/ec2/(placement-groups)/create-placement-group`,path:`/ec2/create-placement-group`,getParentRoute:()=>Q}),$=ju.update({id:`/ec2/(key)/import-key-pair`,path:`/ec2/import-key-pair`,getParentRoute:()=>Q}),yd=Mu.update({id:`/ec2/(key)/create-key-pair`,path:`/ec2/create-key-pair`,getParentRoute:()=>Q}),bd=Nu.update({id:`/ec2/(instances)/run-instances`,path:`/ec2/run-instances`,getParentRoute:()=>Q}),xd=Pu.update({id:`/s3/ls/$bucket`,path:`/s3/ls/$bucket`,getParentRoute:()=>Q}),Sd=Fu.update({id:`/`,path:`/`,getParentRoute:()=>xd}),Cd=Iu.update({id:`/iam/(users)/list-users/`,path:`/iam/list-users/`,getParentRoute:()=>Q}),wd=Lu.update({id:`/iam/(policies)/list-policies/`,path:`/iam/list-policies/`,getParentRoute:()=>Q}),Td=Ru.update({id:`/ec2/(vpc)/describe-vpcs/`,path:`/ec2/describe-vpcs/`,getParentRoute:()=>Q}),Ed=zu.update({id:`/ec2/(volumes)/describe-volumes/`,path:`/ec2/describe-volumes/`,getParentRoute:()=>Q}),Dd=Bu.update({id:`/ec2/(subnet)/describe-subnets/`,path:`/ec2/describe-subnets/`,getParentRoute:()=>Q}),Od=Vu.update({id:`/ec2/(snapshots)/describe-snapshots/`,path:`/ec2/describe-snapshots/`,getParentRoute:()=>Q}),kd=Hu.update({id:`/ec2/(security-groups)/describe-security-groups/`,path:`/ec2/describe-security-groups/`,getParentRoute:()=>Q}),Ad=Uu.update({id:`/ec2/(placement-groups)/describe-placement-groups/`,path:`/ec2/describe-placement-groups/`,getParentRoute:()=>Q}),jd=Wu.update({id:`/ec2/(key)/describe-key-pairs/`,path:`/ec2/describe-key-pairs/`,getParentRoute:()=>Q}),Md=Z.update({id:`/ec2/(instances)/describe-instances/`,path:`/ec2/describe-instances/`,getParentRoute:()=>Q}),Nd=Gu.update({id:`/ec2/(images)/describe-images/`,path:`/ec2/describe-images/`,getParentRoute:()=>Q}),Pd=Ku.update({id:`/$`,path:`/$`,getParentRoute:()=>xd}),Fd=qu.update({id:`/iam/(users)/list-users/$userName`,path:`/iam/list-users/$userName`,getParentRoute:()=>Q}),Id=Ju.update({id:`/iam/(policies)/list-policies/$policyArn`,path:`/iam/list-policies/$policyArn`,getParentRoute:()=>Q}),Ld=Yu.update({id:`/ec2/(vpc)/describe-vpcs/$id`,path:`/ec2/describe-vpcs/$id`,getParentRoute:()=>Q}),Rd=Xu.update({id:`/ec2/(volumes)/modify-volume/$id`,path:`/ec2/modify-volume/$id`,getParentRoute:()=>Q}),zd=Zu.update({id:`/ec2/(volumes)/describe-volumes/$id`,path:`/ec2/describe-volumes/$id`,getParentRoute:()=>Q}),Bd=Qu.update({id:`/ec2/(subnet)/describe-subnets/$id`,path:`/ec2/describe-subnets/$id`,getParentRoute:()=>Q}),Vd=$u.update({id:`/ec2/(snapshots)/describe-snapshots/$id`,path:`/ec2/describe-snapshots/$id`,getParentRoute:()=>Q}),Hd=ed.update({id:`/ec2/(security-groups)/describe-security-groups/$id`,path:`/ec2/describe-security-groups/$id`,getParentRoute:()=>Q}),Ud=td.update({id:`/ec2/(placement-groups)/describe-placement-groups/$id`,path:`/ec2/describe-placement-groups/$id`,getParentRoute:()=>Q}),Wd=nd.update({id:`/ec2/(key)/describe-key-pairs/$id`,path:`/ec2/describe-key-pairs/$id`,getParentRoute:()=>Q}),Gd=rd.update({id:`/ec2/(instances)/describe-instances/$id`,path:`/ec2/describe-instances/$id`,getParentRoute:()=>Q}),Kd=id.update({id:`/ec2/(images)/describe-images/$id`,path:`/ec2/describe-images/$id`,getParentRoute:()=>Q}),qd={AuthS3LsBucketSplatRoute:Pd,AuthS3LsBucketIndexRoute:Sd},Jd={AuthNodesRoute:sd,AuthIndexRoute:od,AuthS3ServiceMetricsRoute:cd,AuthS3LsBucketRouteRoute:xd._addFileChildren(qd),AuthEc2instancesRunInstancesRoute:bd,AuthEc2keyCreateKeyPairRoute:yd,AuthEc2keyImportKeyPairRoute:$,AuthEc2placementGroupsCreatePlacementGroupRoute:vd,AuthEc2securityGroupsCreateSecurityGroupRoute:_d,AuthEc2snapshotsCreateSnapshotRoute:gd,AuthEc2subnetCreateSubnetRoute:hd,AuthEc2volumesCreateVolumeRoute:md,AuthEc2vpcCreateVpcRoute:pd,AuthIampoliciesCreatePolicyRoute:fd,AuthIamusersCreateUserRoute:dd,AuthS3bucketsCreateBucketRoute:ud,AuthS3LsIndexRoute:ld,AuthEc2imagesDescribeImagesIdRoute:Kd,AuthEc2instancesDescribeInstancesIdRoute:Gd,AuthEc2keyDescribeKeyPairsIdRoute:Wd,AuthEc2placementGroupsDescribePlacementGroupsIdRoute:Ud,AuthEc2securityGroupsDescribeSecurityGroupsIdRoute:Hd,AuthEc2snapshotsDescribeSnapshotsIdRoute:Vd,AuthEc2subnetDescribeSubnetsIdRoute:Bd,AuthEc2volumesDescribeVolumesIdRoute:zd,AuthEc2volumesModifyVolumeIdRoute:Rd,AuthEc2vpcDescribeVpcsIdRoute:Ld,AuthIampoliciesListPoliciesPolicyArnRoute:Id,AuthIamusersListUsersUserNameRoute:Fd,AuthEc2imagesDescribeImagesIndexRoute:Nd,AuthEc2instancesDescribeInstancesIndexRoute:Md,AuthEc2keyDescribeKeyPairsIndexRoute:jd,AuthEc2placementGroupsDescribePlacementGroupsIndexRoute:Ad,AuthEc2securityGroupsDescribeSecurityGroupsIndexRoute:kd,AuthEc2snapshotsDescribeSnapshotsIndexRoute:Od,AuthEc2subnetDescribeSubnetsIndexRoute:Dd,AuthEc2volumesDescribeVolumesIndexRoute:Ed,AuthEc2vpcDescribeVpcsIndexRoute:Td,AuthIampoliciesListPoliciesIndexRoute:wd,AuthIamusersListUsersIndexRoute:Cd},Yd={AuthRouteRoute:Q._addFileChildren(Jd),LoginRoute:ad},Xd=hu._addFileChildren(Yd)._addFileTypes(),Zd=new Ir({defaultOptions:{queries:{staleTime:5e3}}}),Qd=Fa({routeTree:Xd,context:{queryClient:Zd},defaultPreload:`intent`,scrollRestoration:!0,defaultStructuralSharing:!0,defaultPreloadStaleTime:0}),$d=document.querySelector(`#app`);$d&&!$d.innerHTML&&Ja.createRoot($d).render((0,W.jsx)(U.StrictMode,{children:(0,W.jsx)(Za,{defaultTheme:`dark`,storageKey:`spinifex-ui-theme`,children:(0,W.jsx)(D,{client:Zd,children:(0,W.jsx)(su,{children:(0,W.jsx)(Bl,{children:(0,W.jsx)(Ra,{router:Qd})})})})})}));export{Eo as A,no as B,Pc as C,Ts as D,rc as E,go as F,Aa as H,mo as I,fo as L,wo as M,So as N,Oo as O,yo as P,K as R,Fc as S,Mc as T,Mr as U,$a as V,Tr as W,iu as _,ed as a,Bc as b,Zu as c,Ju as d,qu as f,cu as g,Ou as h,td as i,Co as j,Do as k,Xu as l,Fu as m,rd as n,$u as o,Ku as p,nd as r,Qu as s,id as t,Yu as u,Sl as v,Nc as w,Lc as x,bl as y,io as z}; \ No newline at end of file +`+e.stack}}var xe=Object.prototype.hasOwnProperty,Se=t.unstable_scheduleCallback,Ce=t.unstable_cancelCallback,we=t.unstable_shouldYield,Te=t.unstable_requestPaint,I=t.unstable_now,Ee=t.unstable_getCurrentPriorityLevel,De=t.unstable_ImmediatePriority,Oe=t.unstable_UserBlockingPriority,ke=t.unstable_NormalPriority,Ae=t.unstable_LowPriority,je=t.unstable_IdlePriority,Me=t.log,Ne=t.unstable_setDisableYieldValue,Pe=null,L=null;function Fe(e){if(typeof Me==`function`&&Ne(e),L&&typeof L.setStrictMode==`function`)try{L.setStrictMode(Pe,e)}catch{}}var R=Math.clz32?Math.clz32:Re,Ie=Math.log,z=Math.LN2;function Re(e){return e>>>=0,e===0?32:31-(Ie(e)/z|0)|0}var ze=256,Be=262144,Ve=4194304;function He(e){var t=e&42;if(t!==0)return t;switch(e&-e){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 e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Ue(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=He(n))):i=He(o):i=He(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=He(n))):i=He(o)):i=He(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function We(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ge(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+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 t+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 Ke(){var e=Ve;return Ve<<=1,!(Ve&62914560)&&(Ve=4194304),e}function qe(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Je(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Ye(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0`u`||window.document===void 0||window.document.createElement===void 0),sn=!1;if(on)try{var cn={};Object.defineProperty(cn,`passive`,{get:function(){sn=!0}}),window.addEventListener(`test`,cn,cn),window.removeEventListener(`test`,cn,cn)}catch{sn=!1}var ln=null,un=null,dn=null;function fn(){if(dn)return dn;var e,t=un,n=t.length,r,i=`value`in ln?ln.value:ln.textContent,a=i.length;for(e=0;e=Un),Kn=` `,qn=!1;function Jn(e,t){switch(e){case`keyup`:return Vn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function Yn(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var Xn=!1;function Zn(e,t){switch(e){case`compositionend`:return Yn(t);case`keypress`:return t.which===32?(qn=!0,Kn):null;case`textInput`:return e=t.data,e===Kn&&qn?null:e;default:return null}}function Qn(e,t){if(Xn)return e===`compositionend`||!Hn&&Jn(e,t)?(e=fn(),dn=un=ln=null,Xn=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=br(n)}}function Sr(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Sr(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Cr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Nt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Nt(e.document)}return t}function wr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Tr=on&&`documentMode`in document&&11>=document.documentMode,Er=null,Dr=null,Or=null,kr=!1;function Ar(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;kr||Er==null||Er!==Nt(r)||(r=Er,`selectionStart`in r&&wr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Or&&yr(Or,r)||(Or=r,r=Td(Dr,`onSelect`),0>=o,i-=o,Si=1<<32-R(t)+i|n<h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),H&&wi(i,h),l;if(d===null){for(;hg?(_=h,h=null):_=h.sibling;var y=p(i,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(i,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(i,h),H&&wi(i,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(i,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return H&&wi(i,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,i,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(i,e)}),H&&wi(i,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===_&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case h:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===_){if(r.tag===7){n(e,r.sibling),c=i(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===E&&Sa(l)===r.type){n(e,r.sibling),c=i(r,o.props),ka(c,o),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}o.type===_?(c=li(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=ci(o.type,o.key,o.props,null,e.mode,c),ka(c,o),c.return=e,e=c)}return s(e);case g:a:{for(l=o.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=i(r,o.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=fi(o,e.mode,c),c.return=e,e=c}return s(e);case E:return o=Sa(o),b(e,r,o,c)}if(j(o))return v(e,r,o,c);if(A(o)){if(l=A(o),typeof l!=`function`)throw Error(a(150));return o=l.call(o),y(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,Oa(o),c);if(o.$$typeof===x)return b(e,r,W(e,o),c);Aa(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=i(r,o),c.return=e,e=c):(n(e,r),c=ui(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Da=0;var i=b(e,t,n,r);return Ea=null,i}catch(t){if(t===ga||t===va)throw t;var a=ii(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ma=ja(!0),Na=ja(!1),Pa=!1;function Fa(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Ia(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function La(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ra(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,q&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=ti(e),ei(e,null,n),t}return Zr(e,r,t,n),ti(e)}function za(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ze(e,n)}}function Ba(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Va=!1;function Ha(){if(Va){var e=sa;if(e!==null)throw e}}function Ua(e,t,n,r){Va=!1;var i=e.updateQueue;Pa=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,m=f!==s.lane;if(m?(Y&f)===f:(r&f)===f){f!==0&&f===oa&&(Va=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var h=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(h=g.payload,typeof h==`function`){d=h.call(_,d,f);break a}d=h;break a;case 3:h.flags=h.flags&-65537|128;case 0:if(h=g.payload,f=typeof h==`function`?h.call(_,d,f):h,f==null)break a;d=p({},d,f);break a;case 2:Pa=!0}}f=s.callback,f!==null&&(e.flags|=64,m&&(e.flags|=8192),m=i.callbacks,m===null?i.callbacks=[f]:m.push(f))}else m={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=m,c=d):u=u.next=m,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;m=s,s=m.next,m.next=null,i.lastBaseUpdate=m,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),Gl|=o,e.lanes=o,e.memoizedState=d}}function Wa(e,t){if(typeof e!=`function`)throw Error(a(191,e));e.call(t)}function Ga(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;ea?a:8;var o=M.T,s={};M.T=s,js(e,!1,t,n);try{var c=i(),l=M.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?As(e,t,ua(c,r),pu(e)):As(e,t,r,pu(e))}catch(n){As(e,t,{then:function(){},status:`rejected`,reason:n},pu())}finally{N.p=a,o!==null&&s.types!==null&&(o.types=s.types),M.T=o}}function bs(){}function xs(e,t,n,r){if(e.tag!==5)throw Error(a(476));var i=Ss(e).queue;ys(e,i,t,ne,n===null?bs:function(){return Cs(e),n(r)})}function Ss(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ne,baseState:ne,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Mo,lastRenderedState:ne},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Mo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Cs(e){var t=Ss(e);t.next===null&&(t=e.alternate.memoizedState),As(e,t.next.queue,{},pu())}function ws(){return U(Qf)}function Ts(){return Do().memoizedState}function Es(){return Do().memoizedState}function Ds(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=pu();e=La(n);var r=Ra(t,e,n);r!==null&&(hu(r,t,n),za(r,t,n)),t={cache:na()},e.payload=t;return}t=t.return}}function Os(e,t,n){var r=pu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Ms(e)?Ns(t,n):(n=Qr(e,t,n,r),n!==null&&(hu(n,e,r),Ps(n,t,r)))}function ks(e,t,n){As(e,t,n,pu())}function As(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Ms(e))Ns(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,vr(s,o))return Zr(e,t,i,0),Rl===null&&Xr(),!1}catch{}if(n=Qr(e,t,i,r),n!==null)return hu(n,e,r),Ps(n,t,r),!0}return!1}function js(e,t,n,r){if(r={lane:2,revertLane:ud(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Ms(e)){if(t)throw Error(a(479))}else t=Qr(e,n,r,2),t!==null&&hu(t,e,2)}function Ms(e){var t=e.alternate;return e===K||t!==null&&t===K}function Ns(e,t){uo=lo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ps(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,Ze(e,n)}}var Fs={readContext:U,use:Ao,useCallback:_o,useContext:_o,useEffect:_o,useImperativeHandle:_o,useLayoutEffect:_o,useInsertionEffect:_o,useMemo:_o,useReducer:_o,useRef:_o,useState:_o,useDebugValue:_o,useDeferredValue:_o,useTransition:_o,useSyncExternalStore:_o,useId:_o,useHostTransitionStatus:_o,useFormState:_o,useActionState:_o,useOptimistic:_o,useMemoCache:_o,useCacheRefresh:_o};Fs.useEffectEvent=_o;var Is={readContext:U,use:Ao,useCallback:function(e,t){return Eo().memoizedState=[e,t===void 0?null:t],e},useContext:U,useEffect:os,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),is(4194308,4,fs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return is(4194308,4,e,t)},useInsertionEffect:function(e,t){is(4,2,e,t)},useMemo:function(e,t){var n=Eo();t=t===void 0?null:t;var r=e();if(fo){Fe(!0);try{e()}finally{Fe(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Eo();if(n!==void 0){var i=n(t);if(fo){Fe(!0);try{n(t)}finally{Fe(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Os.bind(null,K,e),[r.memoizedState,e]},useRef:function(e){var t=Eo();return e={current:e},t.memoizedState=e},useState:function(e){e=Ho(e);var t=e.queue,n=ks.bind(null,K,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:ms,useDeferredValue:function(e,t){return _s(Eo(),e,t)},useTransition:function(){var e=Ho(!1);return e=ys.bind(null,K,e.queue,!0,!1),Eo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=K,i=Eo();if(H){if(n===void 0)throw Error(a(407));n=n()}else{if(n=t(),Rl===null)throw Error(a(349));Y&127||Lo(r,t,n)}i.memoizedState=n;var o={value:n,getSnapshot:t};return i.queue=o,os(zo.bind(null,r,o,e),[e]),r.flags|=2048,ns(9,{destroy:void 0},Ro.bind(null,r,o,n,t),null),n},useId:function(){var e=Eo(),t=Rl.identifierPrefix;if(H){var n=Ci,r=Si;n=(r&~(1<<32-R(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=po++,0<\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(i,{is:r.is}):s.createElement(i)}}o[B]=t,o[it]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Pd(o,i,r),i){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Ac(t)}}return Fc(t),jc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Ac(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(a(166));if(e=ce.current,Li(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,i=ki,i!==null)switch(i.tag){case 27:case 5:r=i.memoizedProps}e[B]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||jd(e.nodeValue,n)),e||Pi(t,!0)}else e=Bd(e).createTextNode(r),e[B]=t,t.stateNode=e}return Fc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Li(t),n!==null){if(e===null){if(!r)throw Error(a(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(a(557));e[B]=t}else Ri(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Fc(t),e=!1}else n=zi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(ro(t),t):(ro(t),null);if(t.flags&128)throw Error(a(558))}return Fc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=Li(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(a(318));if(i=t.memoizedState,i=i===null?null:i.dehydrated,!i)throw Error(a(317));i[B]=t}else Ri(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Fc(t),i=!1}else i=zi(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i)return t.flags&256?(ro(t),t):(ro(t),null)}return ro(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,i=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(i=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==i&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Nc(t,t.updateQueue),Fc(t),null);case 4:return de(),e===null&&xd(t.stateNode.containerInfo),Fc(t),null;case 10:return Gi(t.type),Fc(t),null;case 19:if(P(io),r=t.memoizedState,r===null)return Fc(t),null;if(i=(t.flags&128)!=0,o=r.rendering,o===null)if(i)Pc(r,!1);else{if(Wl!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=ao(e),o!==null){for(t.flags|=128,Pc(r,!1),e=o.updateQueue,t.updateQueue=e,Nc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)si(n,e),n=n.sibling;return F(io,io.current&1|2),H&&wi(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&I()>tu&&(t.flags|=128,i=!0,Pc(r,!1),t.lanes=4194304)}else{if(!i)if(e=ao(o),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Nc(t,e),Pc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!H)return Fc(t),null}else 2*I()-r.renderingStartTime>tu&&n!==536870912&&(t.flags|=128,i=!0,Pc(r,!1),t.lanes=4194304);r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Fc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=I(),e.sibling=null,n=io.current,F(io,i?n&1|2:n&1),H&&wi(t,r.treeForkCount),e);case 22:case 23:return ro(t),Xa(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Fc(t),t.subtreeFlags&6&&(t.flags|=8192)):Fc(t),n=t.updateQueue,n!==null&&Nc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&P(fa),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),Gi(ta),Fc(t),null;case 25:return null;case 30:return null}throw Error(a(156,t.tag))}function Lc(e,t){switch(Di(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Gi(ta),de(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return pe(t),null;case 31:if(t.memoizedState!==null){if(ro(t),t.alternate===null)throw Error(a(340));Ri()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(ro(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(a(340));Ri()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return P(io),null;case 4:return de(),null;case 10:return Gi(t.type),null;case 22:case 23:return ro(t),Xa(),e!==null&&P(fa),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Gi(ta),null;case 25:return null;default:return null}}function Rc(e,t){switch(Di(t),t.tag){case 3:Gi(ta),de();break;case 26:case 27:case 5:pe(t);break;case 4:de();break;case 31:t.memoizedState!==null&&ro(t);break;case 13:ro(t);break;case 19:P(io);break;case 10:Gi(t.type);break;case 22:case 23:ro(t),Xa(),e!==null&&P(fa);break;case 24:Gi(ta)}}function zc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){Z(t,t.return,e)}}function Bc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){Z(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){Z(t,t.return,e)}}function Vc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{Ga(t,n)}catch(t){Z(e,e.return,t)}}}function Hc(e,t,n){n.props=Us(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Z(e,t,n)}}function Uc(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){Z(e,t,n)}}function Wc(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){Z(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){Z(e,t,n)}else n.current=null}function Gc(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Z(e,e.return,t)}}function Kc(e,t,n){try{var r=e.stateNode;Fd(r,e.type,n,t),r[it]=t}catch(t){Z(e,e.return,t)}}function qc(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Zd(e.type)||e.tag===4}function Jc(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||qc(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Zd(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Yc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Xt));else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(Yc(e,t,n),e=e.sibling;e!==null;)Yc(e,t,n),e=e.sibling}function Xc(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&Zd(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Xc(e,t,n),e=e.sibling;e!==null;)Xc(e,t,n),e=e.sibling}function Zc(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Pd(t,r,n),t[B]=e,t[it]=n}catch(t){Z(e,e.return,t)}}var Qc=!1,$c=!1,el=!1,tl=typeof WeakSet==`function`?WeakSet:Set,nl=null;function rl(e,t){if(e=e.containerInfo,Rd=sp,e=Cr(e),wr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||i!==0&&f.nodeType!==3||(c=s+i),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===i&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(zd={focusedElem:e,selectionRange:n},sp=!1,nl=t;nl!==null;)if(t=nl,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,nl=e;else for(;nl!==null;){switch(t=nl,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n title`))),Pd(o,r,n),o[B]=e,gt(o),r=o;break a;case`link`:var s=Vf(`link`,`href`,i).get(r+(n.href||``));if(s){for(var c=0;cg&&(o=g,g=h,h=o);var _=xr(s,h),v=xr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;sn?32:n,M.T=null,n=lu,lu=null;var o=au,s=su;if(iu=0,ou=au=null,su=0,q&6)throw Error(a(331));var c=q;if(q|=4,Nl(o.current),Tl(o,o.current,s,n),q=c,id(0,!1),L&&typeof L.onPostCommitFiberRoot==`function`)try{L.onPostCommitFiberRoot(Pe,o)}catch{}return!0}finally{N.p=i,M.T=r,Vu(e,t)}}function Wu(e,t,n){t=mi(n,t),t=Ys(e.stateNode,t,2),e=Ra(e,t,2),e!==null&&(Je(e,2),rd(e))}function Z(e,t,n){if(e.tag===3)Wu(e,e,n);else for(;t!==null;){if(t.tag===3){Wu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(ru===null||!ru.has(r))){e=mi(n,e),n=Xs(2),r=Ra(t,n,2),r!==null&&(Zs(n,r,t,e),Je(r,2),rd(r));break}}t=t.return}}function Gu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Ll;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Hl=!0,i.add(n),e=Ku.bind(null,e,t,n),t.then(e,e))}function Ku(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Rl===e&&(Y&n)===n&&(Wl===4||Wl===3&&(Y&62914560)===Y&&300>I()-$l?!(q&2)&&Su(e,0):ql|=n,Yl===Y&&(Yl=0)),rd(e)}function qu(e,t){t===0&&(t=Ke()),e=$r(e,t),e!==null&&(Je(e,t),rd(e))}function Ju(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),qu(e,n)}function Yu(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(a(314))}r!==null&&r.delete(t),qu(e,n)}function Xu(e,t){return Se(e,t)}var Zu=null,Qu=null,$u=!1,ed=!1,td=!1,nd=0;function rd(e){e!==Qu&&e.next===null&&(Qu===null?Zu=Qu=e:Qu=Qu.next=e),ed=!0,$u||($u=!0,ld())}function id(e,t){if(!td&&ed){td=!0;do for(var n=!1,r=Zu;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-R(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,cd(r,a))}else a=Y,a=Ue(r,r===Rl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||We(r,a)||(n=!0,cd(r,a));r=r.next}while(n);td=!1}}function ad(){Q()}function Q(){ed=$u=!1;var e=0;nd!==0&&Gd()&&(e=nd);for(var t=I(),n=null,r=Zu;r!==null;){var i=r.next,a=od(r,t);a===0?(r.next=null,n===null?Zu=i:n.next=i,i===null&&(Qu=n)):(n=r,(e!==0||a&3)&&(ed=!0)),r=i}iu!==0&&iu!==5||id(e,!1),nd!==0&&(nd=0)}function od(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0s)break;var u=c.transferSize,d=c.initiatorType;u&&Id(d)&&(c=c.responseEnd,o+=u*(c`u`?null:document;function xf(e,t,n){var r=bf;if(r&&typeof t==`string`&&t){var i=Ft(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),hf.has(i)||(hf.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Pd(t,`link`,e),gt(t),r.head.appendChild(t)))}}function Sf(e){_f.D(e),xf(`dns-prefetch`,e,null)}function Cf(e,t){_f.C(e,t),xf(`preconnect`,e,t)}function wf(e,t,n){_f.L(e,t,n);var r=bf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Ft(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Ft(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Ft(n.imageSizes)+`"]`)):i+=`[href="`+Ft(e)+`"]`;var a=i;switch(t){case`style`:a=Af(e);break;case`script`:a=Pf(e)}mf.has(a)||(e=p({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),mf.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(jf(a))||t===`script`&&r.querySelector(Ff(a))||(t=r.createElement(`link`),Pd(t,`link`,e),gt(t),r.head.appendChild(t)))}}function Tf(e,t){_f.m(e,t);var n=bf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Ft(r)+`"][href="`+Ft(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Pf(e)}if(!mf.has(a)&&(e=p({rel:`modulepreload`,href:e},t),mf.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(Ff(a)))return}r=n.createElement(`link`),Pd(r,`link`,e),gt(r),n.head.appendChild(r)}}}function Ef(e,t,n){_f.S(e,t,n);var r=bf;if(r&&e){var i=ht(r).hoistableStyles,a=Af(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(jf(a)))s.loading=5;else{e=p({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=mf.get(a))&&Rf(e,n);var c=o=r.createElement(`link`);gt(c),Pd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Lf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function Df(e,t){_f.X(e,t);var n=bf;if(n&&e){var r=ht(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=p({src:e,async:!0},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),gt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Of(e,t){_f.M(e,t);var n=bf;if(n&&e){var r=ht(n).hoistableScripts,i=Pf(e),a=r.get(i);a||(a=n.querySelector(Ff(i)),a||(e=p({src:e,async:!0,type:`module`},t),(t=mf.get(i))&&zf(e,t),a=n.createElement(`script`),gt(a),Pd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function kf(e,t,n,r){var i=(i=ce.current)?gf(i):null;if(!i)throw Error(a(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Af(n.href),n=ht(i).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Af(n.href);var o=ht(i).hoistableStyles,s=o.get(e);if(s||(i=i.ownerDocument||i,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=i.querySelector(jf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),mf.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},mf.set(e,n),o||Nf(i,e,n,s.state))),t&&r===null)throw Error(a(528,``));return s}if(t&&r!==null)throw Error(a(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Pf(n),n=ht(i).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(a(444,e))}}function Af(e){return`href="`+Ft(e)+`"`}function jf(e){return`link[rel="stylesheet"][`+e+`]`}function Mf(e){return p({},e,{"data-precedence":e.precedence,precedence:null})}function Nf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Pd(t,`link`,n),gt(t),e.head.appendChild(t))}function Pf(e){return`[src="`+Ft(e)+`"]`}function Ff(e){return`script[async]`+e}function If(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Ft(n.href)+`"]`);if(r)return t.instance=r,gt(r),r;var i=p({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),gt(r),Pd(r,`style`,i),Lf(r,n.precedence,e),t.instance=r;case`stylesheet`:i=Af(n.href);var o=e.querySelector(jf(i));if(o)return t.state.loading|=4,t.instance=o,gt(o),o;r=Mf(n),(i=mf.get(i))&&Rf(r,i),o=(e.ownerDocument||e).createElement(`link`),gt(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Pd(o,`link`,r),t.state.loading|=4,Lf(o,n.precedence,e),t.instance=o;case`script`:return o=Pf(n.src),(i=e.querySelector(Ff(o)))?(t.instance=i,gt(i),i):(r=n,(i=mf.get(o))&&(r=p({},n),zf(r,i)),e=e.ownerDocument||e,i=e.createElement(`script`),gt(i),Pd(i,`link`,r),e.head.appendChild(i),t.instance=i);case`void`:return null;default:throw Error(a(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Lf(r,n.precedence,e));return t.instance}function Lf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o title`):null)}function Uf(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function Wf(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function Gf(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Af(r.href),a=t.querySelector(jf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=Jf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,gt(a);return}a=t.ownerDocument||t,r=Mf(r),(i=mf.get(i))&&Rf(r,i),a=a.createElement(`link`),gt(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Pd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=Jf.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var Kf=0;function qf(e,t){return e.stylesheets&&e.count===0&&Xf(e,e.stylesheets),0Kf?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function Jf(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)Xf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Yf=null;function Xf(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Yf=new Map,t.forEach(Zf,e),Yf=null,Jf.call(e))}function Zf(e,t){if(!(t.state.loading&4)){var n=Yf.get(e);if(n)var r=n.get(null);else{n=new Map,Yf.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a{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)}}n(),t.exports=qa()}))(),1),G=i(),Ya=(0,U.createContext)(void 0);function Xa(e,t){try{let t=localStorage.getItem(e);if(t===`light`||t===`dark`||t===`system`)return t}catch{}return t}function Za(e){let t=(0,G.c)(14),{children:n,defaultTheme:r,storageKey:i}=e,a=r===void 0?`dark`:r,o=i===void 0?`ui-theme`:i,s;t[0]!==a||t[1]!==o?(s=()=>Xa(o,a),t[0]=a,t[1]=o,t[2]=s):s=t[2];let[c,l]=(0,U.useState)(s),u,d;t[3]===c?(u=t[4],d=t[5]):(u=()=>{let e=window.document.documentElement;if(e.classList.remove(`light`,`dark`),c===`system`){let t=window.matchMedia(`(prefers-color-scheme: dark)`).matches?`dark`:`light`;e.classList.add(t);return}e.classList.add(c)},d=[c],t[3]=c,t[4]=u,t[5]=d),(0,U.useEffect)(u,d);let f;t[6]===o?f=t[7]:(f=e=>{try{localStorage.setItem(o,e)}catch{}l(e)},t[6]=o,t[7]=f);let p;t[8]!==f||t[9]!==c?(p={theme:c,setTheme:f},t[8]=f,t[9]=c,t[10]=p):p=t[10];let m=p,h;return t[11]!==n||t[12]!==m?(h=(0,W.jsx)(Ya.Provider,{value:m,children:n}),t[11]=n,t[12]=m,t[13]=h):h=t[13],h}function Qa(){let e=(0,U.useContext)(Ya);if(e===void 0)throw Error(`useTheme must be used within a ThemeProvider`);return e}function $a(e){return Ue(e.defaultTagName??`div`,e,e)}var eo=tt(`activity`,[[`path`,{d:`M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2`,key:`169zse`}]]),to=tt(`book-open`,[[`path`,{d:`M12 7v14`,key:`1akyts`}],[`path`,{d:`M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z`,key:`ruj8y`}]]),no=tt(`camera`,[[`path`,{d:`M13.997 4a2 2 0 0 1 1.76 1.05l.486.9A2 2 0 0 0 18.003 7H20a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h1.997a2 2 0 0 0 1.759-1.048l.489-.904A2 2 0 0 1 10.004 4z`,key:`18u6gg`}],[`circle`,{cx:`12`,cy:`13`,r:`3`,key:`1vg3eu`}]]),ro=tt(`circle-alert`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`line`,{x1:`12`,x2:`12`,y1:`8`,y2:`12`,key:`1pkeuh`}],[`line`,{x1:`12`,x2:`12.01`,y1:`16`,y2:`16`,key:`4dfq90`}]]),io=tt(`hard-drive`,[[`path`,{d:`M10 16h.01`,key:`1bzywj`}],[`path`,{d:`M2.212 11.577a2 2 0 0 0-.212.896V18a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-5.527a2 2 0 0 0-.212-.896L18.55 5.11A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z`,key:`18tbho`}],[`path`,{d:`M21.946 12.013H2.054`,key:`zqlbp7`}],[`path`,{d:`M6 16h.01`,key:`1pmjb7`}]]),ao=tt(`house`,[[`path`,{d:`M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8`,key:`5wwlr5`}],[`path`,{d:`M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z`,key:`r6nss1`}]]),oo=tt(`image`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,ry:`2`,key:`1m3agn`}],[`circle`,{cx:`9`,cy:`9`,r:`2`,key:`af1f0g`}],[`path`,{d:`m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21`,key:`1xmnt7`}]]),K=tt(`key`,[[`path`,{d:`m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4`,key:`g0fldk`}],[`path`,{d:`m21 2-9.6 9.6`,key:`1j0ho8`}],[`circle`,{cx:`7.5`,cy:`15.5`,r:`5.5`,key:`yqb3hr`}]]),so=tt(`layers`,[[`path`,{d:`M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z`,key:`zw3jo`}],[`path`,{d:`M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12`,key:`1wduqc`}],[`path`,{d:`M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17`,key:`kqbvx6`}]]),co=tt(`layout-grid`,[[`rect`,{width:`7`,height:`7`,x:`3`,y:`3`,rx:`1`,key:`1g98yp`}],[`rect`,{width:`7`,height:`7`,x:`14`,y:`3`,rx:`1`,key:`6d4xhi`}],[`rect`,{width:`7`,height:`7`,x:`14`,y:`14`,rx:`1`,key:`nxv5o0`}],[`rect`,{width:`7`,height:`7`,x:`3`,y:`14`,rx:`1`,key:`1bb6yr`}]]),lo=tt(`log-out`,[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]),uo=tt(`moon`,[[`path`,{d:`M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401`,key:`kfwtm`}]]),fo=tt(`network`,[[`rect`,{x:`16`,y:`16`,width:`6`,height:`6`,rx:`1`,key:`4q2zg0`}],[`rect`,{x:`2`,y:`16`,width:`6`,height:`6`,rx:`1`,key:`8cvhb9`}],[`rect`,{x:`9`,y:`2`,width:`6`,height:`6`,rx:`1`,key:`1egb70`}],[`path`,{d:`M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3`,key:`1jsf9p`}],[`path`,{d:`M12 12V8`,key:`2874zd`}]]),po=tt(`panel-left`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}]]),mo=tt(`server`,[[`rect`,{width:`20`,height:`8`,x:`2`,y:`2`,rx:`2`,ry:`2`,key:`ngkwjq`}],[`rect`,{width:`20`,height:`8`,x:`2`,y:`14`,rx:`2`,ry:`2`,key:`iecqi9`}],[`line`,{x1:`6`,x2:`6.01`,y1:`6`,y2:`6`,key:`16zg32`}],[`line`,{x1:`6`,x2:`6.01`,y1:`18`,y2:`18`,key:`nzw8ys`}]]),ho=tt(`shield-check`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}],[`path`,{d:`m9 12 2 2 4-4`,key:`dzmm74`}]]),go=tt(`shield`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}]]),_o=tt(`sun`,[[`circle`,{cx:`12`,cy:`12`,r:`4`,key:`4exip2`}],[`path`,{d:`M12 2v2`,key:`tus03m`}],[`path`,{d:`M12 20v2`,key:`1lh1kg`}],[`path`,{d:`m4.93 4.93 1.41 1.41`,key:`149t6j`}],[`path`,{d:`m17.66 17.66 1.41 1.41`,key:`ptbguv`}],[`path`,{d:`M2 12h2`,key:`1t8f8n`}],[`path`,{d:`M20 12h2`,key:`1q8mjw`}],[`path`,{d:`m6.34 17.66-1.41 1.41`,key:`1m8zz5`}],[`path`,{d:`m19.07 4.93-1.41 1.41`,key:`1shlcs`}]]),vo=tt(`users`,[[`path`,{d:`M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2`,key:`1yyitq`}],[`path`,{d:`M16 3.128a4 4 0 0 1 0 7.744`,key:`16gr8j`}],[`path`,{d:`M22 21v-2a4 4 0 0 0-3-3.87`,key:`kshegd`}],[`circle`,{cx:`9`,cy:`7`,r:`4`,key:`nufk8`}]]),yo=tt(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),bo=U.forwardRef(function(e,t){let{render:n,className:r,id:i,name:a,value:o,disabled:s=!1,onValueChange:c,defaultValue:l,autoFocus:u=!1,...d}=e,{state:f,name:p,disabled:m,setTouched:h,setDirty:g,validityData:_,setFocused:v,setFilled:y,validationMode:b,validation:x}=Ot(),S=m||s,C=p??a,w={...f,disabled:S},{labelId:T}=Ct(),E=Dt({id:i});lt(()=>{let e=o!=null;x.inputRef.current?.value||e&&o!==``?y(!0):e&&o===``&&y(!1)},[x.inputRef,y,o]);let D=U.useRef(null);lt(()=>{u&&D.current===Bt(At(D.current))&&v(!0)},[u,v]);let[O]=Tt({controlled:o,default:l,name:`FieldControl`,state:`value`}),k=o!==void 0,A=k?O:void 0;return Et({id:E,name:C,commit:x.commit,value:A,getValue:()=>x.inputRef.current?.value,controlRef:x.inputRef}),Ue(`input`,e,{ref:[t,D],state:w,props:[{id:E,disabled:S,name:C,ref:x.inputRef,"aria-labelledby":T,autoFocus:u,...k?{value:A}:{defaultValue:l},onChange(e){let t=e.currentTarget.value;c?.(t,Gt(Kt,e.nativeEvent)),g(t!==_.initialValue),y(t!==``)},onFocus(){v(!0)},onBlur(e){h(!0),v(!1),b===`onBlur`&&x.commit(e.currentTarget.value)},onKeyDown(e){e.currentTarget.tagName===`INPUT`&&e.key===`Enter`&&(h(!0),x.commit(e.currentTarget.value))}},x.getInputValidationProps(),d],stateAttributesMapping:wt})}),xo=U.forwardRef(function(e,t){return(0,W.jsx)(bo,{ref:t,...e})});function So(e){let t=(0,G.c)(10),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({className:n,type:i,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let a;t[4]===n?a=t[5]:(a=qe(`h-7 w-full min-w-0 rounded-md border border-input bg-input/20 px-2 py-0.5 text-sm transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-xs/relaxed file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-2 focus-visible:ring-ring/30 disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-2 aria-invalid:ring-destructive/20 md:text-xs/relaxed dark:bg-input/30 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40`,n),t[4]=n,t[5]=a);let o;return t[6]!==r||t[7]!==a||t[8]!==i?(o=(0,W.jsx)(xo,{className:a,"data-slot":`input`,type:i,...r}),t[6]=r,t[7]=a,t[8]=i,t[9]=o):o=t[9],o}var Co=U.createContext(void 0);function wo(e){let t=U.useContext(Co);if(e===!1&&t===void 0)throw Error(He(27));return t}var To={...Dn,...Xt},Eo=U.forwardRef(function(e,t){let{render:n,className:r,forceRender:i=!1,...a}=e,{store:o}=wo(),s=o.useState(`open`),c=o.useState(`nested`),l=o.useState(`mounted`);return Ue(`div`,e,{state:{open:s,transitionStatus:o.useState(`transitionStatus`)},ref:[o.context.backdropRef,t],stateAttributesMapping:To,props:[{role:`presentation`,hidden:!l,style:{userSelect:`none`,WebkitUserSelect:`none`}},a],enabled:i||!c})}),Do=U.forwardRef(function(e,t){let{render:n,className:r,disabled:i=!1,nativeButton:a=!0,...o}=e,{store:s}=wo(),c=s.useState(`open`);function l(e){c&&s.setOpen(!1,Gt(Ut,e.nativeEvent))}let{getButtonProps:u,buttonRef:d}=ht({disabled:i,native:a});return Ue(`button`,e,{state:{disabled:i},ref:[t,d],props:[{onClick:l},o,u]})}),Oo=U.forwardRef(function(e,t){let{render:n,className:r,id:i,...a}=e,{store:o}=wo(),s=Lt(i);return o.useSyncedValueWithCleanup(`descriptionElementId`,s),Ue(`p`,e,{ref:t,props:[{id:s},a]})});function ko(e,t){return t!=null&&!kn(t)?0:typeof e==`function`?e():e}function Ao(e,t,n){let r=ko(e,n);return typeof r==`number`?r:r?.[t]}function jo(e){return typeof e==`function`?e():e}function Mo(e,t){return t||e===`click`||e===`mousedown`}var No=U.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new jn,currentIdRef:{current:null},currentContextRef:{current:null}});function Po(e){let{children:t,delay:n,timeoutMs:r=0}=e,i=U.useRef(n),a=U.useRef(n),o=U.useRef(null),s=U.useRef(null),c=Cn();return(0,W.jsx)(No.Provider,{value:U.useMemo(()=>({hasProvider:!0,delayRef:i,initialDelayRef:a,currentIdRef:o,timeoutMs:r,currentContextRef:s,timeout:c}),[r,c]),children:t})}function Fo(e,t={open:!1}){let n=`rootStore`in e?e.rootStore:e,r=n.useState(`floatingId`),{open:i}=t,{currentIdRef:a,delayRef:o,timeoutMs:s,initialDelayRef:c,currentContextRef:l,hasProvider:u,timeout:d}=U.useContext(No),[f,p]=U.useState(!1);return lt(()=>{function e(){p(!1),l.current?.setIsInstantPhase(!1),a.current=null,l.current=null,o.current=c.current}if(a.current&&!i&&a.current===r){if(p(!1),s){let t=r;return d.start(s,()=>{n.select(`open`)||a.current&&a.current!==t||e()}),()=>{d.clear()}}e()}},[i,r,a,o,s,c,l,d,n]),lt(()=>{if(!i)return;let e=l.current,t=a.current;d.clear(),l.current={onOpenChange:n.setOpen,setIsInstantPhase:p},a.current=r,o.current={open:0,close:Ao(c.current,`close`)},t!==null&&t!==r?(p(!0),e?.setIsInstantPhase(!0),e?.onOpenChange(!1,Gt(Kt))):(p(!1),e?.setIsInstantPhase(!1))},[i,r,n,a,o,s,c,l,d]),lt(()=>()=>{l.current=null},[l]),U.useMemo(()=>({hasProvider:u,delayRef:o,isInstantPhase:f}),[u,o,f])}function Io(e,t){let n=null,r=null,i=!1;return{contextElement:e||void 0,getBoundingClientRect(){let a=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},o=t.axis===`x`||t.axis===`both`,s=t.axis===`y`||t.axis===`both`,c=[`mouseenter`,`mousemove`].includes(t.dataRef.current.openEvent?.type||``)&&t.pointerType!==`touch`,l=a.width,u=a.height,d=a.x,f=a.y;return n==null&&t.x&&o&&(n=a.x-t.x),r==null&&t.y&&s&&(r=a.y-t.y),d-=n||0,f-=r||0,l=0,u=0,!i||c?(l=t.axis===`y`?a.width:0,u=t.axis===`x`?a.height:0,d=o&&t.x!=null?t.x:d,f=s&&t.y!=null?t.y:f):i&&!c&&(u=t.axis===`x`?a.height:u,l=t.axis===`y`?a.width:l),i=!0,{width:l,height:u,x:d,y:f,top:f,right:d+l,bottom:f+u,left:d}}}}function Lo(e){return e!=null&&e.clientX!=null}function Ro(e,t={}){let n=`rootStore`in e?e.rootStore:e,r=n.useState(`open`),i=n.useState(`floatingElement`),a=n.useState(`domReferenceElement`),o=n.context.dataRef,{enabled:s=!0,axis:c=`both`}=t,l=U.useRef(!1),u=U.useRef(null),[d,f]=U.useState(),[p,m]=U.useState([]),h=pt((e,t,r)=>{l.current||o.current.openEvent&&!Lo(o.current.openEvent)||n.set(`positionReference`,Io(r??a,{x:e,y:t,axis:c,dataRef:o,pointerType:d}))}),g=pt(e=>{r?u.current||m([]):h(e.clientX,e.clientY,e.currentTarget)}),_=kn(d)?i:r,v=U.useCallback(()=>{if(!_||!s)return;let e=ct(i);function t(n){Rt(i,Yt(n))?(e.removeEventListener(`mousemove`,t),u.current=null):h(n.clientX,n.clientY)}if(!o.current.openEvent||Lo(o.current.openEvent)){e.addEventListener(`mousemove`,t);let n=()=>{e.removeEventListener(`mousemove`,t),u.current=null};return u.current=n,n}n.set(`positionReference`,a)},[_,s,i,o,a,n,h]);U.useEffect(()=>v(),[v,p]),U.useEffect(()=>{s&&!i&&(l.current=!1)},[s,i]),U.useEffect(()=>{!s&&r&&(l.current=!0)},[s,r]);let y=U.useMemo(()=>{function e(e){f(e.pointerType)}return{onPointerDown:e,onPointerEnter:e,onMouseMove:g,onMouseEnter:g}},[g]);return U.useMemo(()=>s?{reference:y,trigger:y}:{},[s,y])}function zo(e,t,n){let{reference:r,floating:i}=e,a=Mn(t),o=Ln(t),s=mn(o),c=Un(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(cn(t)){case`start`:p[o]-=f*(n&&l?-1:1);break;case`end`:p[o]+=f*(n&&l?-1:1);break}return p}async function Bo(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=fn(t,e),p=xn(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=vn(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=vn(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var Vo=50,Ho=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:Bo},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=zo(l,r,c),f=r,p=0,m={};for(let n=0;ne<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(!(u===`alignment`&&_!==Mn(t))||T.every(e=>Mn(e.placement)===_?e.overflows[0]>0:!0)))return{data:{index:e,overflows:T},reset:{placement:t}};let n=T.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=T.filter(e=>{if(x){let t=Mn(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o;break}if(r!==n)return{reset:{placement:n}}}return{}}}};function Wo(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Go(e){return Vn.some(t=>e[t]>=0)}var Ko=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=fn(e,t);switch(i){case`referenceHidden`:{let e=Wo(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:Go(e)}}}case`escaped`:{let e=Wo(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:Go(e)}}}default:return{}}}}},qo=new Set([`left`,`top`]);async function Jo(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Un(n),s=cn(n),c=Mn(n)===`y`,l=qo.has(o)?-1:1,u=a&&c?-1:1,d=fn(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var Yo=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await Jo(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},Xo=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=fn(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=Mn(Un(i)),p=hn(f),m=u[p],h=u[f];if(o){let e=p===`y`?`top`:`left`,t=p===`y`?`bottom`:`right`,n=m+d[e],r=m-d[t];m=on(n,m,r)}if(s){let e=f===`y`?`top`:`left`,t=f===`y`?`bottom`:`right`,n=h+d[e],r=h-d[t];h=on(n,h,r)}let g=c.fn({...t,[p]:m,[f]:h});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:o,[f]:s}}}}}},Zo=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=fn(e,t),u={x:n,y:r},d=Mn(i),f=hn(d),p=u[f],m=u[d],h=fn(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;pn&&(p=n)}if(l){let e=f===`y`?`width`:`height`,t=qo.has(Un(i)),n=a.reference[d]-a.floating[e]+(t&&o.offset?.[d]||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:o.offset?.[d]||0)-(t?g.crossAxis:0);mr&&(m=r)}return{[f]:p,[d]:m}}}},Qo=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){var n,r;let{placement:i,rects:a,platform:o,elements:s}=t,{apply:c=()=>{},...l}=fn(e,t),u=await o.detectOverflow(t,l),d=Un(i),f=cn(i),p=Mn(i)===`y`,{width:m,height:h}=a.floating,g,_;d===`top`||d===`bottom`?(g=d,_=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(_=d,g=f===`end`?`top`:`bottom`);let v=h-u.top-u.bottom,y=m-u.left-u.right,b=Tn(h-u[g],v),x=Tn(m-u[_],y),S=!t.middlewareData.shift,C=b,w=x;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(w=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=v),S&&!f){let e=zn(u.left,0),t=zn(u.right,0),n=zn(u.top,0),r=zn(u.bottom,0);p?w=m-2*(e!==0||t!==0?e+t:zn(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:zn(u.top,u.bottom))}await c({...t,availableWidth:w,availableHeight:C});let T=await o.getDimensions(s.floating);return m!==T.width||h!==T.height?{reset:{rects:!0}}:{}}}};function $o(e){let t=gt(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=yt(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=Pn(n)!==a||Pn(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function es(e){return B(e)?e:e.contextElement}function ts(e){let t=es(e);if(!yt(t))return dn(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=$o(t),o=(a?Pn(n.width):n.width)/r,s=(a?Pn(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var ns=dn(0);function rs(e){let t=ct(e);return!rt()||!t.visualViewport?ns:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function is(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==ct(e)?!1:t}function as(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=es(e),o=dn(1);t&&(r?B(r)&&(o=ts(r)):o=ts(e));let s=is(a,n,r)?rs(a):dn(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=ct(a),t=r&&B(r)?ct(r):r,n=e,i=vt(n);for(;i&&r&&t!==n;){let e=ts(i),t=i.getBoundingClientRect(),r=gt(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=ct(i),i=vt(n)}}return vn({width:u,height:d,x:c,y:l})}function os(e,t){let n=ot(e).scrollLeft;return t?t.left+n:as(ut(e)).left+n}function ss(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-os(e,n),y:n.top+t.scrollTop}}function cs(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=ut(r),s=t?bt(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=dn(1),u=dn(0),d=yt(r);if((d||!d&&!a)&&((at(r)!==`body`||xt(o))&&(c=ot(r)),d)){let e=as(r);l=ts(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?ss(o,c):dn(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function ls(e){return Array.from(e.getClientRects())}function us(e){let t=ut(e),n=ot(e),r=e.ownerDocument.body,i=zn(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=zn(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+os(e),s=-n.scrollTop;return gt(r).direction===`rtl`&&(o+=zn(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var ds=25;function fs(e,t){let n=ct(e),r=ut(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=rt();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=os(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=ds&&(a-=o)}else l<=ds&&(a+=l);return{width:a,height:o,x:s,y:c}}function ps(e,t){let n=as(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=yt(e)?ts(e):dn(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function ms(e,t,n){let r;if(t===`viewport`)r=fs(e,n);else if(t===`document`)r=us(ut(e));else if(B(t))r=ps(t,n);else{let n=rs(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return vn(r)}function hs(e,t){let n=dt(e);return n===t||!B(n)||St(n)?!1:gt(n).position===`fixed`||hs(n,t)}function gs(e,t){let n=t.get(e);if(n)return n;let r=mt(e,[],!1).filter(e=>B(e)&&at(e)!==`body`),i=null,a=gt(e).position===`fixed`,o=a?dt(e):e;for(;B(o)&&!St(o);){let t=gt(o),n=st(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||xt(o)&&!n&&hs(e,o))?r=r.filter(e=>e!==o):i=t,o=dt(o)}return t.set(e,r),r}function _s(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?bt(t)?[]:gs(t,this._c):[].concat(n),r],o=ms(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e{o(!1,1e-7)},1e3)}n===1&&!Es(l,e.getBoundingClientRect())&&o(),y=!1}try{n=new IntersectionObserver(b,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(b,v)}n.observe(e)}return o(!0),a}function Os(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=es(e),u=i||a?[...l?mt(l):[],...t?mt(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?Ds(l,n):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?as(e):null;c&&g();function g(){let t=as(e);h&&!Es(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d?.(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var ks=Yo,As=Xo,js=Uo,Ms=Qo,Ns=Ko,Ps=Zo,Fs=(e,t,n)=>{let r=new Map,i={platform:Ts,...n},a={...i.platform,_c:r};return Ho(e,t,{...i,platform:a})},Is=e(Le(),1),Ls=typeof document<`u`?U.useLayoutEffect:function(){};function Rs(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Rs(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!Rs(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function zs(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Bs(e,t){let n=zs(e);return Math.round(t*n)/n}function Vs(e){let t=U.useRef(e);return Ls(()=>{t.current=e}),t}function Hs(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,d]=U.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=U.useState(r);Rs(f,r)||p(r);let[m,h]=U.useState(null),[g,_]=U.useState(null),v=U.useCallback(e=>{e!==S.current&&(S.current=e,h(e))},[]),y=U.useCallback(e=>{e!==C.current&&(C.current=e,_(e))},[]),b=a||m,x=o||g,S=U.useRef(null),C=U.useRef(null),w=U.useRef(u),T=c!=null,E=Vs(c),D=Vs(i),O=Vs(l),k=U.useCallback(()=>{if(!S.current||!C.current)return;let e={placement:t,strategy:n,middleware:f};D.current&&(e.platform=D.current),Fs(S.current,C.current,e).then(e=>{let t={...e,isPositioned:O.current!==!1};A.current&&!Rs(w.current,t)&&(w.current=t,Is.flushSync(()=>{d(t)}))})},[f,t,n,D,O]);Ls(()=>{l===!1&&w.current.isPositioned&&(w.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let A=U.useRef(!1);Ls(()=>(A.current=!0,()=>{A.current=!1}),[]),Ls(()=>{if(b&&(S.current=b),x&&(C.current=x),b&&x){if(E.current)return E.current(b,x,k);k()}},[b,x,k,E,T]);let ee=U.useMemo(()=>({reference:S,floating:C,setReference:v,setFloating:y}),[v,y]),te=U.useMemo(()=>({reference:b,floating:x}),[b,x]),j=U.useMemo(()=>{let e={position:n,left:0,top:0};if(!te.floating)return e;let t=Bs(te.floating,u.x),r=Bs(te.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...zs(te.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,te.floating,u.x,u.y]);return U.useMemo(()=>({...u,update:k,refs:ee,elements:te,floatingStyles:j}),[u,k,ee,te,j])}var Us=(e,t)=>{let n=ks(e);return{name:n.name,fn:n.fn,options:[e,t]}},Ws=(e,t)=>{let n=As(e);return{name:n.name,fn:n.fn,options:[e,t]}},Gs=(e,t)=>({fn:Ps(e).fn,options:[e,t]}),Ks=(e,t)=>{let n=js(e);return{name:n.name,fn:n.fn,options:[e,t]}},qs=(e,t)=>{let n=Ms(e);return{name:n.name,fn:n.fn,options:[e,t]}},Js=(e,t)=>{let n=Ns(e);return{name:n.name,fn:n.fn,options:[e,t]}};function Ys(e,t){let n=U.useRef(null),r=U.useRef(null);return U.useCallback(i=>{if(e!==void 0){if(n.current!==null){let e=n.current,i=r.current,a=t.context.triggerElements.getById(e);i&&a===i&&t.context.triggerElements.delete(e),n.current=null,r.current=null}i!==null&&(n.current=e,r.current=i,t.context.triggerElements.add(e,i))}},[t,e])}function Xs(e,t,n,r){let i=n.useState(`isMountedByTrigger`,e),a=Ys(e,n),o=pt(t=>{if(a(t),!t||!n.select(`open`))return;let i=n.select(`activeTriggerId`);if(i===e){n.update({activeTriggerElement:t,...r});return}i??n.update({activeTriggerId:e,activeTriggerElement:t,...r})});return lt(()=>{i&&n.update({activeTriggerElement:t.current,...r})},[i,n,t,...Object.values(r)]),{registerTrigger:o,isMountedByThisTrigger:i}}function Zs(e){let t=e.useState(`open`);lt(()=>{if(t&&!e.select(`activeTriggerId`)&&e.context.triggerElements.size===1){let t=e.context.triggerElements.entries().next();if(!t.done){let[n,r]=t.value;e.update({activeTriggerId:n,activeTriggerElement:r})}}},[t,e])}function Qs(e,t,n){let{mounted:r,setMounted:i,transitionStatus:a}=$t(e);t.useSyncedValues({mounted:r,transitionStatus:a});let o=pt(()=>{i(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1}),n?.(),t.context.onOpenChangeComplete?.(!1)});return Qt({enabled:!t.useState(`preventUnmountingOnClose`),open:e,ref:t.context.popupRef,onComplete(){e||o()}}),{forceUnmount:o,transitionStatus:a}}function $s(){return new On({open:!1,floatingElement:null,referenceElement:null,triggerElements:new bn,floatingId:``,nested:!1,noEmit:!1,onOpenChange:void 0})}function ec(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:`idle`,floatingRootContext:$s(),preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:Ve,inactiveTriggerProps:Ve,popupProps:Ve}}var tc=V(e=>e.triggerIdProp??e.activeTriggerId),nc={open:V(e=>e.openProp??e.open),mounted:V(e=>e.mounted),transitionStatus:V(e=>e.transitionStatus),floatingRootContext:V(e=>e.floatingRootContext),preventUnmountingOnClose:V(e=>e.preventUnmountingOnClose),payload:V(e=>e.payload),activeTriggerId:tc,activeTriggerElement:V(e=>e.mounted?e.activeTriggerElement:null),isTriggerActive:V((e,t)=>t!==void 0&&tc(e)===t),isOpenedByTrigger:V((e,t)=>t!==void 0&&tc(e)===t&&e.open),isMountedByTrigger:V((e,t)=>t!==void 0&&tc(e)===t&&e.mounted),triggerProps:V((e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps),popupProps:V(e=>e.popupProps),popupElement:V(e=>e.popupElement),positionerElement:V(e=>e.positionerElement)};function rc(e){let{open:t=!1,onOpenChange:n,elements:r={}}=e,i=jt(),a=Gn()!=null,o=Ge(()=>new On({open:t,onOpenChange:n,referenceElement:r.reference??null,floatingElement:r.floating??null,triggerElements:new bn,floatingId:i,nested:a,noEmit:!1})).current;return lt(()=>{let e={open:t,floatingId:i};r.reference!==void 0&&(e.referenceElement=r.reference,e.domReferenceElement=B(r.reference)?r.reference:null),r.floating!==void 0&&(e.floatingElement=r.floating),o.update(e)},[t,i,r.reference,r.floating,o]),o.context.onOpenChange=n,o.context.nested=a,o.context.noEmit=!1,o}function ic(e={}){let{nodeId:t,externalTree:n}=e,r=rc(e),i=e.rootContext||r,a={reference:i.useState(`referenceElement`),floating:i.useState(`floatingElement`),domReference:i.useState(`domReferenceElement`)},[o,s]=U.useState(null),c=U.useRef(null),l=qn(n);lt(()=>{a.domReference&&(c.current=a.domReference)},[a.domReference]);let u=Hs({...e,elements:{...a,...o&&{reference:o}}}),d=U.useCallback(e=>{let t=B(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),getClientRects:()=>e.getClientRects(),contextElement:e}:e;s(t),u.refs.setReference(t)},[u.refs]),[f,p]=U.useState(null),[m,h]=U.useState(null);i.useSyncedValue(`referenceElement`,f),i.useSyncedValue(`domReferenceElement`,B(f)?f:null),i.useSyncedValue(`floatingElement`,m);let g=U.useCallback(e=>{(B(e)||e===null)&&(c.current=e,p(e)),(B(u.refs.reference.current)||u.refs.reference.current===null||e!==null&&!B(e))&&u.refs.setReference(e)},[u.refs,p]),_=U.useCallback(e=>{h(e),u.refs.setFloating(e)},[u.refs]),v=U.useMemo(()=>({...u.refs,setReference:g,setFloating:_,setPositionReference:d,domReference:c}),[u.refs,g,_,d]),y=U.useMemo(()=>({...u.elements,domReference:a.domReference}),[u.elements,a.domReference]),b=i.useState(`open`),x=i.useState(`floatingId`),S=U.useMemo(()=>({...u,dataRef:i.context.dataRef,open:b,onOpenChange:i.setOpen,events:i.context.events,floatingId:x,refs:v,elements:y,nodeId:t,rootStore:i}),[u,v,y,t,i,b,x]);return lt(()=>{i.context.dataRef.current.floatingContext=S;let e=l?.nodesRef.current.find(e=>e.id===t);e&&(e.context=S)}),U.useMemo(()=>({...u,context:S,refs:v,elements:y,rootStore:i}),[u,v,y,S,i])}function ac(e){let{popupStore:t,noEmit:n=!1,treatPopupAsFloatingElement:r=!1,onOpenChange:i}=e,a=jt(),o=Gn()!=null,s=t.useState(`open`),c=t.useState(`activeTriggerElement`),l=t.useState(r?`popupElement`:`positionerElement`),u=t.context.triggerElements,d=Ge(()=>new On({open:s,referenceElement:c,floatingElement:l,triggerElements:u,onOpenChange:i,floatingId:a,nested:o,noEmit:n})).current;return lt(()=>{let e={open:s,floatingId:a,referenceElement:c,floatingElement:l};B(c)&&(e.domReferenceElement=c),d.state.positionReference===d.state.referenceElement&&(e.positionReference=c),d.update(e)},[s,a,c,l,d]),d.context.onOpenChange=i,d.context.nested=o,d.context.noEmit=n,d}var oc=Mt&&Pt;function sc(e,t={}){let n=`rootStore`in e?e.rootStore:e,{events:r,dataRef:i}=n.context,{enabled:a=!0,delay:o}=t,s=U.useRef(!1),c=U.useRef(null),l=Cn(),u=U.useRef(!0);U.useEffect(()=>{let e=n.select(`domReferenceElement`);if(!a)return;let t=ct(e);function r(){let e=n.select(`domReferenceElement`);!n.select(`open`)&&yt(e)&&e===Bt(At(e))&&(s.current=!0)}function i(){u.current=!0}function o(){u.current=!1}return t.addEventListener(`blur`,r),oc&&(t.addEventListener(`keydown`,i,!0),t.addEventListener(`pointerdown`,o,!0)),()=>{t.removeEventListener(`blur`,r),oc&&(t.removeEventListener(`keydown`,i,!0),t.removeEventListener(`pointerdown`,o,!0))}},[n,a]),U.useEffect(()=>{if(!a)return;function e(e){if(e.reason===`trigger-press`||e.reason===`escape-key`){let e=n.select(`domReferenceElement`);B(e)&&(c.current=e,s.current=!0)}}return r.on(`openchange`,e),()=>{r.off(`openchange`,e)}},[r,a,n]);let d=U.useMemo(()=>({onMouseLeave(){s.current=!1,c.current=null},onFocus(e){let t=e.currentTarget;if(s.current){if(c.current===t)return;s.current=!1,c.current=null}let r=Yt(e.nativeEvent);if(B(r)){if(oc&&!e.relatedTarget){if(!u.current&&!Jt(r))return}else if(!It(r))return}let i=Ft(e.relatedTarget,n.context.triggerElements),{nativeEvent:a,currentTarget:d}=e,f=typeof o==`function`?o():o;if(n.select(`open`)&&i||f===0||f===void 0){n.setOpen(!0,Gt(zt,a,d));return}l.start(f,()=>{s.current||n.setOpen(!0,Gt(zt,a,d))})},onBlur(e){s.current=!1,c.current=null;let t=e.relatedTarget,r=e.nativeEvent,a=B(t)&&t.hasAttribute(tn(`focus-guard`))&&t.getAttribute(`data-type`)===`outside`;l.start(0,()=>{let e=n.select(`domReferenceElement`),o=Bt(e?e.ownerDocument:document);!t&&o===e||Rt(i.current.floatingContext?.refs.floating.current,o)||Rt(e,o)||a||Ft(t??o,n.context.triggerElements)||n.setOpen(!1,Gt(zt,r))})}}),[i,n,l,o]);return U.useMemo(()=>a?{reference:d,trigger:d}:{},[a,d])}var cc=`button,a,[role="button"],select,[tabindex]:not([tabindex="-1"]),${Nt}`;function lc(e){return e?!!e.closest(cc):!1}var uc=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new jn,this.restTimeout=new jn,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose};function dc(e){e.performedPointerEventsMutation&&(e.pointerEventsScopeElement?.style.removeProperty(`pointer-events`),e.pointerEventsReferenceElement?.style.removeProperty(`pointer-events`),e.pointerEventsFloatingElement?.style.removeProperty(`pointer-events`),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null)}function fc(e,t){let{scopeElement:n,referenceElement:r,floatingElement:i}=t;dc(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=n,e.pointerEventsReferenceElement=r,e.pointerEventsFloatingElement=i,n.style.pointerEvents=`none`,r.style.pointerEvents=`auto`,i.style.pointerEvents=`auto`}function pc(e){let t=Ge(uc.create).current,n=e.context.dataRef.current;return n.hoverInteractionState||=t,Zt(n.hoverInteractionState.disposeEffect),n.hoverInteractionState}function mc(e,t={}){let n=`rootStore`in e?e.rootStore:e,r=n.useState(`open`),i=n.useState(`floatingElement`),a=n.useState(`domReferenceElement`),{dataRef:o}=n.context,{enabled:s=!0,closeDelay:c=0}=t,l=pc(n),u=qn(),d=Gn(),f=pt(()=>Mo(o.current.openEvent?.type,l.interactedInside)),p=pt(()=>{let e=o.current.openEvent?.type;return e?.includes(`mouse`)&&e!==`mousedown`}),m=pt(e=>Ft(e,n.context.triggerElements)),h=U.useCallback(e=>{let t=Ao(c,`close`,l.pointerType),r=()=>{n.setOpen(!1,Gt(Ht,e)),u?.events.emit(`floating.closed`,e)};t?l.openChangeTimeout.start(t,r):(l.openChangeTimeout.clear(),r())},[c,n,l,u]),g=pt(()=>{dc(l)}),_=pt(e=>{let t=Yt(e);if(!lc(t)){l.interactedInside=!1;return}l.interactedInside=t?.closest(`[aria-haspopup]`)!=null});lt(()=>{r||(l.pointerType=void 0,l.restTimeoutPending=!1,l.interactedInside=!1,g())},[r,l,g]),U.useEffect(()=>g,[g]),lt(()=>{if(s&&r&&l.handleCloseOptions?.blockPointerEvents&&p()&&B(a)&&i){let e=a,t=i,n=At(i),r=u?.nodesRef.current.find(e=>e.id===d)?.context?.elements.floating;return r&&(r.style.pointerEvents=``),fc(l,{scopeElement:l.handleCloseOptions?.getScope?.()??l.pointerEventsScopeElement??r??e.closest(`[data-rootownerid]`)??n.body,referenceElement:e,floatingElement:t}),()=>{g()}}},[s,r,a,i,l,p,u,d,g]);let v=Cn();U.useEffect(()=>{if(!s)return;function e(){l.openChangeTimeout.clear(),v.clear(),u?.events.off(`floating.closed`,r),g()}function t(e){if(u&&d&&In(u.nodesRef.current,d).length>0){u.events.on(`floating.closed`,r);return}if(!m(e.relatedTarget)){if(l.handler){l.handler(e);return}g(),f()||h(e)}}function r(e){!u||!d||In(u.nodesRef.current,d).length>0||v.start(0,()=>{u.events.off(`floating.closed`,r),n.setOpen(!1,Gt(Ht,e)),u.events.emit(`floating.closed`,e)})}let a=i;return a&&(a.addEventListener(`mouseenter`,e),a.addEventListener(`mouseleave`,t),a.addEventListener(`pointerdown`,_,!0)),()=>{a&&(a.removeEventListener(`mouseenter`,e),a.removeEventListener(`mouseleave`,t),a.removeEventListener(`pointerdown`,_,!0)),u?.events.off(`floating.closed`,r)}},[s,i,n,o,f,m,h,g,_,l,u,d,v])}var hc={current:null};function gc(e,t={}){let n=`rootStore`in e?e.rootStore:e,{dataRef:r,events:i}=n.context,{enabled:a=!0,delay:o=0,handleClose:s=null,mouseOnly:c=!1,restMs:l=0,move:u=!0,triggerElementRef:d=hc,externalTree:f,isActiveTrigger:p=!0,getHandleCloseContext:m}=t,h=qn(f),g=pc(n),_=rn(s),v=rn(o),y=rn(l),b=rn(a);p&&(g.handleCloseOptions=_.current?.__options);let x=pt(()=>Mo(r.current.openEvent?.type,g.interactedInside)),S=pt(e=>Ft(e,n.context.triggerElements)),C=pt((e,t,r)=>{let i=n.context.triggerElements;if(i.hasElement(t))return!e||!Rt(e,t);if(!B(r))return!1;let a=r;return i.hasMatchingElement(e=>Rt(e,a))&&(!e||!Rt(e,a))}),w=U.useCallback((e,t=!0)=>{let r=Ao(v.current,`close`,g.pointerType);r?g.openChangeTimeout.start(r,()=>{n.setOpen(!1,Gt(Ht,e)),h?.events.emit(`floating.closed`,e)}):t&&(g.openChangeTimeout.clear(),n.setOpen(!1,Gt(Ht,e)),h?.events.emit(`floating.closed`,e))},[v,n,g,h]),T=pt(()=>{g.handler&&=(At(n.select(`domReferenceElement`)).removeEventListener(`mousemove`,g.handler),void 0)});U.useEffect(()=>T,[T]);let E=pt(()=>{dc(g)});return U.useEffect(()=>{if(!a)return;function e(e){e.open||(T(),g.openChangeTimeout.clear(),g.restTimeout.clear(),g.blockMouseMove=!0,g.restTimeoutPending=!1)}return i.on(`openchange`,e),()=>{i.off(`openchange`,e)}},[a,i,g,T]),U.useEffect(()=>{if(!a)return;let e=d.current??(p?n.select(`domReferenceElement`):null);if(!B(e))return;function t(e){if(g.openChangeTimeout.clear(),g.blockMouseMove=!1,c&&!kn(g.pointerType)||jo(y.current)>0&&!Ao(v.current,`open`))return;let t=Ao(v.current,`open`,g.pointerType),r=e.currentTarget??null,i=n.select(`domReferenceElement`),a=r==null?!1:C(i,r,e.target),o=n.select(`open`),s=!o||a;a&&o?n.setOpen(!0,Gt(Ht,e,r)):t?g.openChangeTimeout.start(t,()=>{s&&n.setOpen(!0,Gt(Ht,e,r))}):s&&n.setOpen(!0,Gt(Ht,e,r))}function i(e){if(x()){E();return}T();let t=At(n.select(`domReferenceElement`));g.restTimeout.clear(),g.restTimeoutPending=!1;let i=r.current.floatingContext??m?.();if(!S(e.relatedTarget)){if(_.current&&i){n.select(`open`)||g.openChangeTimeout.clear();let r=d.current;g.handler=_.current({...i,tree:h,x:e.clientX,y:e.clientY,onClose(){E(),T(),b.current&&!x()&&r===n.select(`domReferenceElement`)&&w(e,!0)}}),t.addEventListener(`mousemove`,g.handler),g.handler(e);return}(g.pointerType!==`touch`||!Rt(n.select(`floatingElement`),e.relatedTarget))&&w(e)}}return u&&e.addEventListener(`mousemove`,t,{once:!0}),e.addEventListener(`mouseenter`,t),e.addEventListener(`mouseleave`,i),()=>{u&&e.removeEventListener(`mousemove`,t),e.removeEventListener(`mouseenter`,t),e.removeEventListener(`mouseleave`,i)}},[T,E,r,v,w,n,a,_,g,p,C,x,S,c,u,y,d,h,b,m]),U.useMemo(()=>{if(!a)return;function e(e){g.pointerType=e.pointerType}return{onPointerDown:e,onPointerEnter:e,onMouseMove(e){let{nativeEvent:t}=e,r=e.currentTarget,i=n.select(`domReferenceElement`),a=n.select(`open`),o=C(i,r,e.target);if(c&&!kn(g.pointerType))return;let s=jo(y.current);if(a&&!o||s===0||!o&&g.restTimeoutPending&&e.movementX**2+e.movementY**2<2)return;g.restTimeout.clear();function l(){if(g.restTimeoutPending=!1,x())return;let e=n.select(`open`);!g.blockMouseMove&&(!e||o)&&n.setOpen(!0,Gt(Ht,t,r))}g.pointerType===`touch`?Is.flushSync(()=>{l()}):o&&a?l():(g.restTimeoutPending=!0,g.restTimeout.start(s,l))}}},[a,g,x,C,c,n,y])}var _c=new Map([[`select`,`listbox`],[`combobox`,`listbox`],[`label`,!1]]);function vc(e,t={}){let n=`rootStore`in e?e.rootStore:e,r=n.useState(`open`),i=n.useState(`floatingId`),a=n.useState(`domReferenceElement`),o=n.useState(`floatingElement`),{role:s=`dialog`}=t,c=jt(),l=a?.id||c,u=U.useMemo(()=>qt(o)?.id||i,[o,i]),d=_c.get(s)??s,f=Gn()!=null,p=U.useMemo(()=>d===`tooltip`||s===`label`?Ve:{"aria-haspopup":d===`alertdialog`?`dialog`:d,"aria-expanded":`false`,...d===`listbox`&&{role:`combobox`},...d===`menu`&&f&&{role:`menuitem`},...s===`select`&&{"aria-autocomplete":`none`},...s===`combobox`&&{"aria-autocomplete":`list`}},[d,f,s]),m=U.useMemo(()=>d===`tooltip`||s===`label`?{[`aria-${s===`label`?`labelledby`:`describedby`}`]:r?u:void 0}:{...p,"aria-expanded":r?`true`:`false`,"aria-controls":r?u:void 0,...d===`menu`&&{id:l}},[d,u,r,l,s,p]),h=U.useMemo(()=>{let e={id:u,...d&&{role:d}};return d===`tooltip`||s===`label`?e:{...e,...d===`menu`&&{"aria-labelledby":l}}},[d,u,l,s]),g=U.useCallback(({active:e,selected:t})=>{let n={role:`option`,...e&&{id:`${u}-fui-option`}};switch(s){case`select`:case`combobox`:return{...n,"aria-selected":t};default:}return{}},[u,s]);return U.useMemo(()=>({reference:m,floating:h,item:g,trigger:p}),[m,h,p,g])}var yc=.1,bc=yc*yc,xc=.5;function Sc(e,t,n,r,i,a){return r>=t!=a>=t&&e<=(i-n)*(t-r)/(a-r)+n}function Cc(e,t,n,r,i,a,o,s,c,l){let u=!1;return Sc(e,t,n,r,i,a)&&(u=!u),Sc(e,t,i,a,o,s)&&(u=!u),Sc(e,t,o,s,c,l)&&(u=!u),Sc(e,t,c,l,n,r)&&(u=!u),u}function wc(e,t,n){return e>=n.x&&e<=n.x+n.width&&t>=n.y&&t<=n.y+n.height}function Tc(e,t,n,r,i,a){return e>=Math.min(n,i)&&e<=Math.max(n,i)&&t>=Math.min(r,a)&&t<=Math.max(r,a)}function Ec(e={}){let{blockPointerEvents:t=!1}=e,n=new jn,r=({x:e,y:t,placement:r,elements:i,onClose:a,nodeId:o,tree:s})=>{let c=r?.split(`-`)[0],l=!1,u=null,d=null,f=typeof performance<`u`?performance.now():0;function p(e,t){let n=performance.now(),r=n-f;if(u===null||d===null||r===0)return u=e,d=t,f=n,!1;let i=e-u,a=t-d,o=i*i+a*a,s=r*r*bc;return u=e,d=t,f=n,o0)}function b(){y()||m()}if(y())return;let x=a.getBoundingClientRect(),S=u.getBoundingClientRect(),C=e>S.right-S.width/2,w=t>S.bottom-S.height/2,T=S.width>x.width,E=S.height>x.height,D=(T?x:S).left,O=(T?x:S).right,k=(E?x:S).top,A=(E?x:S).bottom;if(c===`top`&&t>=x.bottom-1||c===`bottom`&&t<=x.top+1||c===`left`&&e>=x.right-1||c===`right`&&e<=x.left+1){b();return}let ee=!1;switch(c){case`top`:ee=Tc(d,f,D,x.top+1,O,S.bottom-1);break;case`bottom`:ee=Tc(d,f,D,S.top+1,O,x.bottom-1);break;case`left`:ee=Tc(d,f,S.right-1,A,x.left+1,k);break;case`right`:ee=Tc(d,f,x.right-1,A,S.left+1,k);break;default:}if(ee)return;if(l&&!wc(d,f,x)){b();return}if(!g&&p(d,f)){b();return}let te=!1;switch(c){case`top`:{let n=T?xc/2:xc*4,r=T||C?e+n:e-n,i=T?e-n:C?e+n:e-n,a=t+xc+1,o=C||T?S.bottom-xc:S.top,s=C?T?S.bottom-xc:S.top:S.bottom-xc;te=Cc(d,f,r,a,i,a,S.left,o,S.right,s);break}case`bottom`:{let n=T?xc/2:xc*4,r=T||C?e+n:e-n,i=T?e-n:C?e+n:e-n,a=t-xc,o=C||T?S.top+xc:S.bottom,s=C?T?S.top+xc:S.bottom:S.top+xc;te=Cc(d,f,r,a,i,a,S.left,o,S.right,s);break}case`left`:{let n=E?xc/2:xc*4,r=E||w?t+n:t-n,i=E?t-n:w?t+n:t-n,a=e+xc+1,o=w||E?S.right-xc:S.left,s=w?E?S.right-xc:S.left:S.right-xc;te=Cc(d,f,o,S.top,s,S.bottom,a,r,a,i);break}case`right`:{let n=E?xc/2:xc*4,r=E||w?t+n:t-n,i=E?t-n:w?t+n:t-n,a=e-xc,o=w||E?S.left+xc:S.right,s=w?E?S.left+xc:S.right:S.left+xc;te=Cc(d,f,a,r,a,i,o,S.top,s,S.bottom);break}default:}te?l||n.start(40,b):b()}};return r.__options={blockPointerEvents:t},r}var Dc=function(e){return e.nestedDialogs=`--nested-dialogs`,e}({}),Oc=function(e){return e[e.open=nn.open]=`open`,e[e.closed=nn.closed]=`closed`,e[e.startingStyle=nn.startingStyle]=`startingStyle`,e[e.endingStyle=nn.endingStyle]=`endingStyle`,e.nested=`data-nested`,e.nestedDialogOpen=`data-nested-dialog-open`,e}({}),kc=U.createContext(void 0);function Ac(){let e=U.useContext(kc);if(e===void 0)throw Error(He(26));return e}var jc={...Dn,...Xt,nestedDialogOpen(e){return e?{[Oc.nestedDialogOpen]:``}:null}},Mc=U.forwardRef(function(e,t){let{className:n,finalFocus:r,initialFocus:i,render:a,...o}=e,{store:s}=wo(),c=s.useState(`descriptionElementId`),l=s.useState(`disablePointerDismissal`),u=s.useState(`floatingRootContext`),d=s.useState(`popupProps`),f=s.useState(`modal`),p=s.useState(`mounted`),m=s.useState(`nested`),h=s.useState(`nestedOpenDialogCount`),g=s.useState(`open`),_=s.useState(`openMethod`),v=s.useState(`titleElementId`),y=s.useState(`transitionStatus`),b=s.useState(`role`);Ac(),Qt({open:g,ref:s.context.popupRef,onComplete(){g&&s.context.onOpenChangeComplete?.(!0)}});function x(e){return e===`touch`?s.context.popupRef.current:!0}let S=i===void 0?x:i,C=Ue(`div`,e,{state:{open:g,nested:m,transitionStatus:y,nestedDialogOpen:h>0},props:[d,{"aria-labelledby":v??void 0,"aria-describedby":c??void 0,role:b,tabIndex:-1,hidden:!p,onKeyDown(e){Nn.has(e.key)&&e.stopPropagation()},style:{[Dc.nestedDialogs]:h}},o],ref:[t,s.context.popupRef,s.useStateSetter(`popupElement`)],stateAttributesMapping:jc});return(0,W.jsx)(gn,{context:u,openInteractionType:_,disabled:!p,closeOnFocusOut:!l,initialFocus:S,returnFocus:r,modal:f!==!1,restoreFocus:`popup`,children:C})}),Nc=U.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,{store:i}=wo(),a=i.useState(`mounted`),o=i.useState(`modal`),s=i.useState(`open`);return a||n?(0,W.jsx)(kc.Provider,{value:n,children:(0,W.jsxs)(yn,{ref:t,...r,children:[a&&o===!0&&(0,W.jsx)(wn,{ref:i.context.internalBackdropRef,inert:_n(!s)}),e.children]})}):null});function Pc(e){let t=U.useRef(!0);t.current&&(t.current=!1,e())}function Fc(e){let{store:t,parentContext:n,actionsRef:r}=e,i=t.useState(`open`),a=t.useState(`disablePointerDismissal`),o=t.useState(`modal`),s=t.useState(`popupElement`),{openMethod:c,triggerProps:l}=Hn(i);Zs(t);let{forceUnmount:u}=Qs(i,t),d=pt(e=>{let n=Gt(e);return n.preventUnmountOnClose=()=>{t.set(`preventUnmountingOnClose`,!0)},n}),f=U.useCallback(()=>{t.setOpen(!1,d(Wt))},[t,d]);U.useImperativeHandle(r,()=>({unmount:u,close:f}),[u,f]);let p=ac({popupStore:t,onOpenChange:t.setOpen,treatPopupAsFloatingElement:!0,noEmit:!0}),[m,h]=U.useState(0),g=m===0,_=vc(p),v=Sn(p,{outsidePressEvent(){return t.context.internalBackdropRef.current||t.context.backdropRef.current?`intentional`:{mouse:o===`trap-focus`?`sloppy`:`intentional`,touch:`sloppy`}},outsidePress(e){if(!t.context.outsidePressEnabledRef.current||`button`in e&&e.button!==0||`touches`in e&&e.touches.length!==1)return!1;let n=Yt(e);if(g&&!a){let e=n;return o&&(t.context.internalBackdropRef.current||t.context.backdropRef.current)?t.context.internalBackdropRef.current===e||t.context.backdropRef.current===e||Rt(e,s)&&!e?.hasAttribute(`data-base-ui-portal`):!0}return!1},escapeKey:g});Rn(i&&o===!0,s);let{getReferenceProps:y,getFloatingProps:b,getTriggerProps:x}=Bn([_,v]);t.useContextCallback(`onNestedDialogOpen`,e=>{h(e+1)}),t.useContextCallback(`onNestedDialogClose`,()=>{h(0)}),U.useEffect(()=>(n?.onNestedDialogOpen&&i&&n.onNestedDialogOpen(m),n?.onNestedDialogClose&&!i&&n.onNestedDialogClose(),()=>{n?.onNestedDialogClose&&i&&n.onNestedDialogClose()}),[i,n,m]);let S=U.useMemo(()=>y(l),[y,l]),C=U.useMemo(()=>x(l),[x,l]),w=U.useMemo(()=>b(),[b]);t.useSyncedValues({openMethod:c,activeTriggerProps:S,inactiveTriggerProps:C,popupProps:w,floatingRootContext:p,nestedOpenDialogCount:m})}var Ic={...nc,modal:V(e=>e.modal),nested:V(e=>e.nested),nestedOpenDialogCount:V(e=>e.nestedOpenDialogCount),disablePointerDismissal:V(e=>e.disablePointerDismissal),openMethod:V(e=>e.openMethod),descriptionElementId:V(e=>e.descriptionElementId),titleElementId:V(e=>e.titleElementId),viewportElement:V(e=>e.viewportElement),role:V(e=>e.role)},Lc=class extends Wn{constructor(e){super(Rc(e),{popupRef:U.createRef(),backdropRef:U.createRef(),internalBackdropRef:U.createRef(),outsidePressEnabledRef:{current:!0},triggerElements:new bn,onOpenChange:void 0,onOpenChangeComplete:void 0},Ic)}setOpen=(e,t)=>{if(t.preventUnmountOnClose=()=>{this.set(`preventUnmountingOnClose`,!0)},!e&&t.trigger==null&&this.state.activeTriggerId!=null&&(t.trigger=this.state.activeTriggerElement??void 0),this.context.onOpenChange?.(e,t),t.isCanceled)return;let n={open:e,nativeEvent:t.event,reason:t.reason,nested:this.state.nested};this.state.floatingRootContext.context.events?.emit(`openchange`,n);let r={open:e},i=t.trigger?.id??null;(i||e)&&(r.activeTriggerId=i,r.activeTriggerElement=t.trigger??null),this.update(r)}};function Rc(e={}){return{...ec(),modal:!0,disablePointerDismissal:!1,popupElement:null,viewportElement:null,descriptionElementId:void 0,titleElementId:void 0,openMethod:null,nested:!1,nestedOpenDialogCount:0,role:`dialog`,...e}}function zc(e){let{children:t,open:n,defaultOpen:r=!1,onOpenChange:i,onOpenChangeComplete:a,disablePointerDismissal:o=!1,modal:s=!0,actionsRef:c,handle:l,triggerId:u,defaultTriggerId:d=null}=e,f=wo(!0),p=!!f,m=Ge(()=>l?.store??new Lc({open:r,openProp:n,activeTriggerId:d,triggerIdProp:u,modal:s,disablePointerDismissal:o,nested:p})).current;Pc(()=>{n===void 0&&m.state.open===!1&&r===!0&&m.update({open:!0,activeTriggerId:d})}),m.useControlledProp(`openProp`,n),m.useControlledProp(`triggerIdProp`,u),m.useSyncedValues({disablePointerDismissal:o,nested:p,modal:s}),m.useContextCallback(`onOpenChange`,i),m.useContextCallback(`onOpenChangeComplete`,a);let h=m.useState(`payload`);Fc({store:m,actionsRef:c,parentContext:f?.store.context,onOpenChange:i,triggerIdProp:u});let g=U.useMemo(()=>({store:m}),[m]);return(0,W.jsx)(Co.Provider,{value:g,children:typeof t==`function`?t({payload:h}):t})}var Bc=U.forwardRef(function(e,t){let{render:n,className:r,id:i,...a}=e,{store:o}=wo(),s=Lt(i);return o.useSyncedValueWithCleanup(`titleElementId`,s),Ue(`h2`,e,{ref:t,props:[{id:s},a]})});function Vc(e){let t=(0,G.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,W.jsx)(zc,{"data-slot":`sheet`,...n}),t[2]=n,t[3]=r),r}function Hc(e){let t=(0,G.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,W.jsx)(Nc,{"data-slot":`sheet-portal`,...n}),t[2]=n,t[3]=r),r}function Uc(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`data-closed:fade-out-0 data-open:fade-in-0 data-closed:animate-out data-open:animate-in fixed inset-0 z-50 bg-black/80 duration-100 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xs`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(Eo,{className:i,"data-slot":`sheet-overlay`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Wc(e){let t=(0,G.c)(17),n,r,i,a,o;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5]):({className:r,children:n,side:a,showCloseButton:o,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o);let s=a===void 0?`right`:a,c=o===void 0?!0:o,l;t[6]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,W.jsx)(Uc,{}),t[6]=l):l=t[6];let u;t[7]===r?u=t[8]:(u=qe(`data-[side=right]:data-closed:slide-out-to-right-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=top]:data-closed:slide-out-to-top-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:fade-out-0 data-open:fade-in-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-closed:animate-out data-open:animate-in fixed z-50 flex flex-col bg-background bg-clip-padding text-xs/relaxed shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm`,r),t[7]=r,t[8]=u);let d;t[9]===c?d=t[10]:(d=c&&(0,W.jsxs)(Do,{"data-slot":`sheet-close`,render:(0,W.jsx)(_t,{className:`absolute top-4 right-4`,size:`icon-sm`,variant:`ghost`}),children:[(0,W.jsx)(yo,{}),(0,W.jsx)(`span`,{className:`sr-only`,children:`Close`})]}),t[9]=c,t[10]=d);let f;return t[11]!==n||t[12]!==i||t[13]!==s||t[14]!==u||t[15]!==d?(f=(0,W.jsxs)(Hc,{children:[l,(0,W.jsxs)(Mc,{className:u,"data-side":s,"data-slot":`sheet-content`,...i,children:[n,d]})]}),t[11]=n,t[12]=i,t[13]=s,t[14]=u,t[15]=d,t[16]=f):f=t[16],f}function Gc(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`flex flex-col gap-1.5 p-6`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-slot":`sheet-header`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Kc(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`text-sm font-medium text-foreground`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(Bc,{className:i,"data-slot":`sheet-title`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function qc(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`text-xs/relaxed text-muted-foreground`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(Oo,{className:i,"data-slot":`sheet-description`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}var Jc=U.createContext(void 0);function Yc(e){let t=U.useContext(Jc);if(t===void 0&&!e)throw Error(He(72));return t}var Xc={...nc,disabled:V(e=>e.disabled),instantType:V(e=>e.instantType),isInstantPhase:V(e=>e.isInstantPhase),trackCursorAxis:V(e=>e.trackCursorAxis),disableHoverablePopup:V(e=>e.disableHoverablePopup),lastOpenChangeReason:V(e=>e.openChangeReason),closeOnClick:V(e=>e.closeOnClick),closeDelay:V(e=>e.closeDelay),hasViewport:V(e=>e.hasViewport)},Zc=class e extends Wn{constructor(e){super({...Qc(),...e},{popupRef:U.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:new bn},Xc)}setOpen=(e,t)=>{let n=t.reason,r=n===Ht,i=e&&n===`trigger-focus`,a=!e&&(n===`trigger-press`||n===`escape-key`);if(t.preventUnmountOnClose=()=>{this.set(`preventUnmountingOnClose`,!0)},this.context.onOpenChange?.(e,t),t.isCanceled)return;let o=()=>{let r={open:e,openChangeReason:n};i?r.instantType=`focus`:a?r.instantType=`dismiss`:n===`trigger-hover`&&(r.instantType=void 0);let o=t.trigger?.id??null;(o||e)&&(r.activeTriggerId=o,r.activeTriggerElement=t.trigger??null),this.update(r)};r?Is.flushSync(o):o()};static useStore(t,n){let r=Ge(()=>new e(n)).current,i=t??r,a=ac({popupStore:i,onOpenChange:i.setOpen});return i.state.floatingRootContext=a,i}};function Qc(){return{...ec(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:`none`,disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,hasViewport:!1}}var $c=Fn(function(e){let{disabled:t=!1,defaultOpen:n=!1,open:r,disableHoverablePopup:i=!1,trackCursorAxis:a=`none`,actionsRef:o,onOpenChange:s,onOpenChangeComplete:c,handle:l,triggerId:u,defaultTriggerId:d=null,children:f}=e,p=Zc.useStore(l?.store,{open:n,openProp:r,activeTriggerId:d,triggerIdProp:u});Pc(()=>{r===void 0&&p.state.open===!1&&n===!0&&p.update({open:!0,activeTriggerId:d})}),p.useControlledProp(`openProp`,r),p.useControlledProp(`triggerIdProp`,u),p.useContextCallback(`onOpenChange`,s),p.useContextCallback(`onOpenChangeComplete`,c);let m=p.useState(`open`),h=!t&&m,g=p.useState(`activeTriggerId`),_=p.useState(`payload`);p.useSyncedValues({trackCursorAxis:a,disableHoverablePopup:i}),lt(()=>{m&&t&&p.setOpen(!1,Gt(Vt))},[m,t,p]),p.useSyncedValue(`disabled`,t),Zs(p);let{forceUnmount:v,transitionStatus:y}=Qs(h,p),b=p.useState(`isInstantPhase`),x=p.useState(`instantType`),S=p.useState(`lastOpenChangeReason`),C=U.useRef(null);lt(()=>{y===`ending`&&S===`none`||y!==`ending`&&b?(x!==`delay`&&(C.current=x),p.set(`instantType`,`delay`)):C.current!==null&&(p.set(`instantType`,C.current),C.current=null)},[y,b,S,x,p]),lt(()=>{h&&(g??p.set(`payload`,void 0))},[p,g,h]);let w=U.useCallback(()=>{p.setOpen(!1,el(p,Wt))},[p]);U.useImperativeHandle(o,()=>({unmount:v,close:w}),[v,w]);let T=p.useState(`floatingRootContext`),{getReferenceProps:E,getFloatingProps:D,getTriggerProps:O}=Bn([Sn(T,{enabled:!t,referencePress:()=>p.select(`closeOnClick`)}),Ro(T,{enabled:!t&&a!==`none`,axis:a===`none`?void 0:a})]),k=U.useMemo(()=>E(),[E]),A=U.useMemo(()=>O(),[O]),ee=U.useMemo(()=>D(),[D]);return p.useSyncedValues({activeTriggerProps:k,inactiveTriggerProps:A,popupProps:ee}),(0,W.jsx)(Jc.Provider,{value:p,children:typeof f==`function`?f({payload:_}):f})});function el(e,t){let n=Gt(t);return n.preventUnmountOnClose=()=>{e.set(`preventUnmountingOnClose`,!0)},n}var tl=U.createContext(void 0);function nl(){return U.useContext(tl)}var rl=function(e){return e[e.popupOpen=ln.popupOpen]=`popupOpen`,e.triggerDisabled=`data-trigger-disabled`,e}({}),il=An(function(e,t){let{className:n,render:r,handle:i,payload:a,disabled:o,delay:s,closeOnClick:c=!0,closeDelay:l,id:u,...d}=e,f=Yc(!0),p=i?.store??f;if(!p)throw Error(He(82));let m=Lt(u),h=p.useState(`isTriggerActive`,m),g=p.useState(`isOpenedByTrigger`,m),_=p.useState(`floatingRootContext`),v=U.useRef(null),y=s??600,b=l??0,{registerTrigger:x,isMountedByThisTrigger:S}=Xs(m,v,p,{payload:a,closeOnClick:c,closeDelay:b}),C=nl(),{delayRef:w,isInstantPhase:T,hasProvider:E}=Fo(_,{open:g});p.useSyncedValue(`isInstantPhase`,T);let D=p.useState(`disabled`),O=o??D,k=p.useState(`trackCursorAxis`),A=p.useState(`disableHoverablePopup`),ee=gc(_,{enabled:!O,mouseOnly:!0,move:!1,handleClose:!A&&k!==`both`?Ec():null,restMs(){let e=C?.delay,t=typeof w.current==`object`?w.current.open:void 0,n=y;return E&&(n=t===0?0:s??e??y),n},delay(){let e=typeof w.current==`object`?w.current.close:void 0,t=b;return l==null&&E&&(t=e),{close:t}},triggerElementRef:v,isActiveTrigger:h}),te=sc(_,{enabled:!O}).reference,j={open:g},M=p.useState(`triggerProps`,S);return Ue(`button`,e,{state:j,ref:[t,x,v],props:[ee,te,M,{onPointerDown(){p.set(`closeOnClick`,c)},id:m,[rl.triggerDisabled]:O?``:void 0},d],stateAttributesMapping:En})}),al=U.createContext(void 0);function ol(){let e=U.useContext(al);if(e===void 0)throw Error(He(70));return e}var sl=U.forwardRef(function(e,t){let{children:n,container:r,className:i,render:a,...o}=e,{portalNode:s,portalSubtree:c}=Kn({container:r,ref:t,componentProps:e,elementProps:o});return!c&&!s?null:(0,W.jsxs)(U.Fragment,{children:[c,s&&Is.createPortal(n,s)]})}),cl=U.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e;return Yc().useState(`mounted`)||n?(0,W.jsx)(al.Provider,{value:n,children:(0,W.jsx)(sl,{ref:t,...r})}):null}),ll=U.createContext(void 0);function ul(){let e=U.useContext(ll);if(e===void 0)throw Error(He(71));return e}var dl=U.createContext(void 0);function fl(){return U.useContext(dl)?.direction??`ltr`}var pl=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0,offsetParent:d=`real`}=fn(e,t)||{};if(l==null)return{};let f=xn(u),p={x:n,y:r},m=Ln(i),h=mn(m),g=await o.getDimensions(l),_=m===`y`,v=_?`top`:`left`,y=_?`bottom`:`right`,b=_?`clientHeight`:`clientWidth`,x=a.reference[h]+a.reference[m]-p[m]-a.floating[h],S=p[m]-a.reference[m],C=d===`real`?await o.getOffsetParent?.(l):s.floating,w=s.floating[b]||a.floating[h];(!w||!await o.isElement?.(C))&&(w=s.floating[b]||a.floating[h]);let T=x/2-S/2,E=w/2-g[h]/2-1,D=Math.min(f[v],E),O=Math.min(f[y],E),k=D,A=w-g[h]-O,ee=w/2-g[h]/2+T,te=on(k,ee,A),j=!c.arrow&&cn(i)!=null&&ee!==te&&a.reference[h]/2-(ee({...pl(e),options:[e,t]}),hl={name:`hide`,async fn(e){let{width:t,height:n,x:r,y:i}=e.rects.reference,a=t===0&&n===0&&r===0&&i===0;return{data:{referenceHidden:(await Js().fn(e)).data?.referenceHidden||a}}}},gl={sideX:`left`,sideY:`top`},_l={name:`adaptiveOrigin`,async fn(e){let{x:t,y:n,rects:{floating:r},elements:{floating:i},platform:a,strategy:o,placement:s}=e,c=ct(i),l=c.getComputedStyle(i);if(!(l.transitionDuration!==`0s`&&l.transitionDuration!==``))return{x:t,y:n,data:gl};let u=await a.getOffsetParent?.(i),d={width:0,height:0};if(o===`fixed`&&c?.visualViewport)d={width:c.visualViewport.width,height:c.visualViewport.height};else if(u===c){let e=At(i);d={width:e.documentElement.clientWidth,height:e.documentElement.clientHeight}}else await a.isElement?.(u)&&(d=await a.getDimensions(u));let f=Un(s),p=t,m=n;f===`left`&&(p=d.width-(t+r.width)),f===`top`&&(m=d.height-(n+r.height));let h=f===`left`?`right`:gl.sideX,g=f===`top`?`bottom`:gl.sideY;return{x:p,y:m,data:{sideX:h,sideY:g}}}};function vl(e,t,n){let r=e===`inline-start`||e===`inline-end`;return{top:`top`,right:r?n?`inline-start`:`inline-end`:`right`,bottom:`bottom`,left:r?n?`inline-end`:`inline-start`:`left`}[t]}function yl(e,t,n){let{rects:r,placement:i}=e;return{side:vl(t,Un(i),n),align:cn(i)||`center`,anchor:{width:r.reference.width,height:r.reference.height},positioner:{width:r.floating.width,height:r.floating.height}}}function bl(e){let{anchor:t,positionMethod:n=`absolute`,side:r=`bottom`,sideOffset:i=0,align:a=`center`,alignOffset:o=0,collisionBoundary:s,collisionPadding:c=5,sticky:l=!1,arrowPadding:u=5,disableAnchorTracking:d=!1,keepMounted:f=!1,floatingRootContext:p,mounted:m,collisionAvoidance:h,shiftCrossAxis:g=!1,nodeId:_,adaptiveOrigin:v,lazyFlip:y=!1,externalTree:b}=e,[x,S]=U.useState(null);!m&&x!==null&&S(null);let C=h.side||`flip`,w=h.align||`flip`,T=h.fallbackAxisSide||`end`,E=typeof t==`function`?t:void 0,D=pt(E),O=E?D:t,k=rn(t),A=fl()===`rtl`,ee=x||{top:`top`,right:`right`,bottom:`bottom`,left:`left`,"inline-end":A?`left`:`right`,"inline-start":A?`right`:`left`}[r],te=a===`center`?ee:`${ee}-${a}`,j=c,M=r===`bottom`?1:0,N=r===`top`?1:0,ne=r===`right`?1:0,re=r===`left`?1:0;typeof j==`number`?j={top:j+M,right:j+re,bottom:j+N,left:j+ne}:j&&={top:(j.top||0)+M,right:(j.right||0)+re,bottom:(j.bottom||0)+N,left:(j.left||0)+ne};let ie={boundary:s===`clipping-ancestors`?`clippingAncestors`:s,padding:j},ae=U.useRef(null),P=rn(i),F=rn(o),oe=[Us(e=>{let t=yl(e,r,A),n=typeof P.current==`function`?P.current(t):P.current,i=typeof F.current==`function`?F.current(t):F.current;return{mainAxis:n,crossAxis:i,alignmentAxis:i}},[typeof i==`function`?0:i,typeof o==`function`?0:o,A,r])],se=w===`none`&&C!==`shift`,ce=!se&&(l||g||C===`shift`),le=C===`none`?null:Ks({...ie,padding:{top:j.top+1,right:j.right+1,bottom:j.bottom+1,left:j.left+1},mainAxis:!g&&C===`flip`,crossAxis:w===`flip`?`alignment`:!1,fallbackAxisSideDirection:T}),ue=se?null:Ws(e=>{let t=At(e.elements.floating).documentElement;return{...ie,rootBoundary:g?{x:0,y:0,width:t.clientWidth,height:t.clientHeight}:void 0,mainAxis:w!==`none`,crossAxis:ce,limiter:l||g?void 0:Gs(e=>{if(!ae.current)return{};let{width:t,height:n}=ae.current.getBoundingClientRect(),r=Mn(Un(e.placement)),i=r===`y`?t:n,a=r===`y`?j.left+j.right:j.top+j.bottom;return{offset:i/2+a/2}})}},[ie,l,g,j,w]);C===`shift`||w===`shift`||a===`center`?oe.push(ue,le):oe.push(le,ue),oe.push(qs({...ie,apply({elements:{floating:e},availableWidth:t,availableHeight:n,rects:r}){let i=e.style;i.setProperty(`--available-width`,`${t}px`),i.setProperty(`--available-height`,`${n}px`);let a=window.devicePixelRatio||1,{x:o,y:s,width:c,height:l}=r.reference,u=(Math.round((o+c)*a)-Math.round(o*a))/a,d=(Math.round((s+l)*a)-Math.round(s*a))/a;i.setProperty(`--anchor-width`,`${u}px`),i.setProperty(`--anchor-height`,`${d}px`)}}),ml(()=>({element:ae.current||document.createElement(`div`),padding:u,offsetParent:`floating`}),[u]),{name:`transformOrigin`,fn(e){let{elements:t,middlewareData:n,placement:a,rects:o,y:s}=e,c=Un(a),l=Mn(c),u=ae.current,d=n.arrow?.x||0,f=n.arrow?.y||0,p=u?.clientWidth||0,m=u?.clientHeight||0,h=d+p/2,g=f+m/2,_=Math.abs(n.shift?.y||0),v=o.reference.height/2,y=typeof i==`function`?i(yl(e,r,A)):i,b=_>y,x={top:`${h}px calc(100% + ${y}px)`,bottom:`${h}px ${-y}px`,left:`calc(100% + ${y}px) ${g}px`,right:`${-y}px ${g}px`}[c],S=`${h}px ${o.reference.y+v-s}px`;return t.floating.style.setProperty(`--transform-origin`,ce&&l===`y`&&b?S:x),{}}},hl,v),lt(()=>{!m&&p&&p.update({referenceElement:null,floatingElement:null,domReferenceElement:null})},[m,p]);let de=U.useMemo(()=>({elementResize:!d&&typeof ResizeObserver<`u`,layoutShift:!d&&typeof IntersectionObserver<`u`}),[d]),{refs:fe,elements:pe,x:me,y:he,middlewareData:ge,update:_e,placement:ve,context:ye,isPositioned:be,floatingStyles:xe}=ic({rootContext:p,placement:te,middleware:oe,strategy:n,whileElementsMounted:f?void 0:(...e)=>Os(...e,de),nodeId:_,externalTree:b}),{sideX:Se,sideY:Ce}=ge.adaptiveOrigin||gl,we=be?n:`fixed`,Te=U.useMemo(()=>{let e=v?{position:we,[Se]:me,[Ce]:he}:{position:we,...xe};return be||(e.opacity=0),e},[v,we,Se,me,Ce,he,xe,be]),I=U.useRef(null);lt(()=>{if(!m)return;let e=k.current,t=typeof e==`function`?e():e,n=(xl(t)?t.current:t)||null;n!==I.current&&(fe.setPositionReference(n),I.current=n)},[m,fe,O,k]),U.useEffect(()=>{if(!m)return;let e=k.current;typeof e!=`function`&&xl(e)&&e.current!==I.current&&(fe.setPositionReference(e.current),I.current=e.current)},[m,fe,O,k]),U.useEffect(()=>{if(f&&m&&pe.domReference&&pe.floating)return Os(pe.domReference,pe.floating,_e,de)},[f,m,pe,_e,de]);let Ee=Un(ve),De=vl(r,Ee,A),Oe=cn(ve)||`center`,ke=!!ge.hide?.referenceHidden;lt(()=>{y&&m&&be&&S(Ee)},[y,m,be,Ee]);let Ae=U.useMemo(()=>({position:`absolute`,top:ge.arrow?.y,left:ge.arrow?.x}),[ge.arrow]),je=ge.arrow?.centerOffset!==0;return U.useMemo(()=>({positionerStyles:Te,arrowStyles:Ae,arrowRef:ae,arrowUncentered:je,side:De,align:Oe,physicalSide:Ee,anchorHidden:ke,refs:fe,context:ye,isPositioned:be,update:_e}),[Te,Ae,ae,je,De,Oe,Ee,ke,fe,ye,be,_e])}function xl(e){return e!=null&&`current`in e}function Sl(e){return e===`starting`?Be:Ve}var Cl=U.forwardRef(function(e,t){let{render:n,className:r,anchor:i,positionMethod:a=`absolute`,side:o=`top`,align:s=`center`,sideOffset:c=0,alignOffset:l=0,collisionBoundary:u=`clipping-ancestors`,collisionPadding:d=5,arrowPadding:f=5,sticky:p=!1,disableAnchorTracking:m=!1,collisionAvoidance:h=We,...g}=e,_=Yc(),v=ol(),y=_.useState(`open`),b=_.useState(`mounted`),x=_.useState(`trackCursorAxis`),S=_.useState(`disableHoverablePopup`),C=_.useState(`floatingRootContext`),w=_.useState(`instantType`),T=_.useState(`transitionStatus`),E=bl({anchor:i,positionMethod:a,floatingRootContext:C,mounted:b,side:o,sideOffset:c,align:s,alignOffset:l,collisionBoundary:u,collisionPadding:d,sticky:p,arrowPadding:f,disableAnchorTracking:m,keepMounted:v,collisionAvoidance:h,adaptiveOrigin:_.useState(`hasViewport`)?_l:void 0}),D=U.useMemo(()=>{let e={};return(!y||x===`both`||S)&&(e.pointerEvents=`none`),{role:`presentation`,hidden:!b,style:{...E.positionerStyles,...e}}},[y,x,S,b,E.positionerStyles]),O=U.useMemo(()=>({open:y,side:E.side,align:E.align,anchorHidden:E.anchorHidden,instant:x===`none`?w:`tracking-cursor`}),[y,E.side,E.align,E.anchorHidden,x,w]),k=U.useMemo(()=>({...O,arrowRef:E.arrowRef,arrowStyles:E.arrowStyles,arrowUncentered:E.arrowUncentered}),[O,E.arrowRef,E.arrowStyles,E.arrowUncentered]),A=Ue(`div`,e,{state:O,props:[D,Sl(T),g],ref:[t,_.useStateSetter(`positionerElement`)],stateAttributesMapping:Dn});return(0,W.jsx)(ll.Provider,{value:k,children:A})}),wl={...Dn,...Xt},Tl=U.forwardRef(function(e,t){let{className:n,render:r,...i}=e,a=Yc(),{side:o,align:s}=ul(),c=a.useState(`open`),l=a.useState(`instantType`),u=a.useState(`transitionStatus`),d=a.useState(`popupProps`),f=a.useState(`floatingRootContext`);Qt({open:c,ref:a.context.popupRef,onComplete(){c&&a.context.onOpenChangeComplete?.(!0)}});let p=a.useState(`disabled`),m=a.useState(`closeDelay`);return mc(f,{enabled:!p,closeDelay:m}),Ue(`div`,e,{state:{open:c,side:o,align:s,instant:l,transitionStatus:u},ref:[t,a.context.popupRef,a.useStateSetter(`popupElement`)],props:[d,Sl(u),i],stateAttributesMapping:wl})}),El=U.forwardRef(function(e,t){let{className:n,render:r,...i}=e,a=Yc().useState(`instantType`),{open:o,arrowRef:s,side:c,align:l,arrowUncentered:u,arrowStyles:d}=ul();return Ue(`div`,e,{state:{open:o,side:c,align:l,uncentered:u,instant:a},ref:[t,s],props:[{style:d,"aria-hidden":!0},i],stateAttributesMapping:Dn})}),Dl=function(e){let{delay:t,closeDelay:n,timeout:r=400}=e,i=U.useMemo(()=>({delay:t,closeDelay:n}),[t,n]),a=U.useMemo(()=>({open:t,close:n}),[t,n]);return(0,W.jsx)(tl.Provider,{value:i,children:(0,W.jsx)(Po,{delay:a,timeoutMs:r,children:e.children})})};function Ol(e){let t=(0,G.c)(6),n,r;t[0]===e?(n=t[1],r=t[2]):({delay:r,...n}=e,t[0]=e,t[1]=n,t[2]=r);let i=r===void 0?0:r,a;return t[3]!==i||t[4]!==n?(a=(0,W.jsx)(Dl,{"data-slot":`tooltip-provider`,delay:i,...n}),t[3]=i,t[4]=n,t[5]=a):a=t[5],a}function kl(e){let t=(0,G.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,W.jsx)(Ol,{children:(0,W.jsx)($c,{"data-slot":`tooltip`,...n})}),t[2]=n,t[3]=r),r}function Al(e){let t=(0,G.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,W.jsx)(il,{"data-slot":`tooltip-trigger`,...n}),t[2]=n,t[3]=r),r}function jl(e){let t=(0,G.c)(21),n,r,i,a,o,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5],s=t[6],c=t[7]):({className:r,side:a,sideOffset:o,align:s,alignOffset:c,children:n,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o,t[6]=s,t[7]=c);let l=a===void 0?`top`:a,u=o===void 0?4:o,d=s===void 0?`center`:s,f=c===void 0?0:c,p;t[8]===r?p=t[9]:(p=qe(`data-open:fade-in-0 data-open:zoom-in-95 data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-closed:fade-out-0 data-closed:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=delayed-open]:animate-in data-closed:animate-out data-open:animate-in z-50 w-fit max-w-xs origin-(--transform-origin) rounded-md bg-foreground px-3 py-1.5 text-xs text-background **:data-[slot=kbd]:rounded-md`,r),t[8]=r,t[9]=p);let m;t[10]===Symbol.for(`react.memo_cache_sentinel`)?(m=(0,W.jsx)(El,{className:`z-50 size-2.5 translate-y-[calc(-50%-2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground data-[side=bottom]:top-1 data-[side=left]:top-1/2! data-[side=left]:-right-1 data-[side=left]:-translate-y-1/2 data-[side=right]:top-1/2! data-[side=right]:-left-1 data-[side=right]:-translate-y-1/2 data-[side=top]:-bottom-2.5`}),t[10]=m):m=t[10];let h;t[11]!==n||t[12]!==i||t[13]!==p?(h=(0,W.jsxs)(Tl,{className:p,"data-slot":`tooltip-content`,...i,children:[n,m]}),t[11]=n,t[12]=i,t[13]=p,t[14]=h):h=t[14];let g;return t[15]!==d||t[16]!==f||t[17]!==l||t[18]!==u||t[19]!==h?(g=(0,W.jsx)(cl,{children:(0,W.jsx)(Cl,{align:d,alignOffset:f,className:`isolate z-50`,side:l,sideOffset:u,children:h})}),t[15]=d,t[16]=f,t[17]=l,t[18]=u,t[19]=h,t[20]=g):g=t[20],g}var Ml=window.matchMedia(`(max-width: 767px)`);function Nl(e){return Ml.addEventListener(`change`,e),()=>Ml.removeEventListener(`change`,e)}function Pl(){return Ml.matches}function Fl(){return(0,U.useSyncExternalStore)(Nl,Pl)}var Il=`sidebar_state`,Ll=3600*24*7,q=`12rem`,Rl=`16rem`,J=`3rem`,Y=`b`,X=U.createContext(null);function zl(){let e=U.useContext(X);if(!e)throw Error(`useSidebar must be used within a SidebarProvider.`);return e}function Bl(e){let t=(0,G.c)(36),n,r,i,a,o,s,c;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5],s=t[6],c=t[7]):({defaultOpen:c,open:i,onOpenChange:o,className:r,style:s,children:n,...a}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o,t[6]=s,t[7]=c);let l=c===void 0?!0:c,u=Fl(),[d,f]=U.useState(!1),[p,m]=U.useState(l),h=i??p,g;t[8]!==h||t[9]!==o?(g=e=>{let t=typeof e==`function`?e(h):e;o?o(t):m(t),document.cookie=`${Il}=${t}; path=/; max-age=${Ll}`},t[8]=h,t[9]=o,t[10]=g):g=t[10];let _=g,v;t[11]!==u||t[12]!==_?(v=()=>u?f(Hl):_(Vl),t[11]=u,t[12]=_,t[13]=v):v=t[13];let y=v,b,x;t[14]===y?(b=t[15],x=t[16]):(b=()=>{let e=e=>{e.key===Y&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),y())};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},x=[y],t[14]=y,t[15]=b,t[16]=x),U.useEffect(b,x);let S=h?`expanded`:`collapsed`,C;t[17]!==u||t[18]!==h||t[19]!==d||t[20]!==_||t[21]!==S||t[22]!==y?(C={state:S,open:h,setOpen:_,isMobile:u,openMobile:d,setOpenMobile:f,toggleSidebar:y},t[17]=u,t[18]=h,t[19]=d,t[20]=_,t[21]=S,t[22]=y,t[23]=C):C=t[23];let w=C,T;t[24]===r?T=t[25]:(T=qe(`group/sidebar-wrapper flex min-h-svh w-full has-data-[variant=inset]:bg-sidebar`,r),t[24]=r,t[25]=T);let E;t[26]===s?E=t[27]:(E={"--sidebar-width":q,"--sidebar-width-icon":J,...s},t[26]=s,t[27]=E);let D=E,O;t[28]!==n||t[29]!==a||t[30]!==T||t[31]!==D?(O=(0,W.jsx)(`div`,{className:T,"data-slot":`sidebar-wrapper`,style:D,...a,children:n}),t[28]=n,t[29]=a,t[30]=T,t[31]=D,t[32]=O):O=t[32];let k;return t[33]!==w||t[34]!==O?(k=(0,W.jsx)(X.Provider,{value:w,children:O}),t[33]=w,t[34]=O,t[35]=k):k=t[35],k}function Vl(e){return!e}function Hl(e){return!e}function Ul(e){let t=(0,G.c)(46),n,r,i,a,o,s;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5],s=t[6]):({side:a,variant:o,collapsible:s,className:r,children:n,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o,t[6]=s);let c=a===void 0?`left`:a,l=o===void 0?`sidebar`:o,u=s===void 0?`offExamples`:s,{isMobile:d,state:f,openMobile:p,setOpenMobile:m}=zl();if(u===`none`){let e;t[7]===r?e=t[8]:(e=qe(`flex h-full w-(--sidebar-width) flex-col bg-sidebar text-sidebar-foreground`,r),t[7]=r,t[8]=e);let a;return t[9]!==n||t[10]!==i||t[11]!==e?(a=(0,W.jsx)(`div`,{className:e,"data-slot":`sidebar`,...i,children:n}),t[9]=n,t[10]=i,t[11]=e,t[12]=a):a=t[12],a}if(d){let e;t[13]===Symbol.for(`react.memo_cache_sentinel`)?(e={"--sidebar-width":Rl},t[13]=e):e=t[13];let r=e,a;t[14]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,W.jsxs)(Gc,{className:`sr-only`,children:[(0,W.jsx)(Kc,{children:`Sidebar`}),(0,W.jsx)(qc,{children:`Displays the mobile sidebar.`})]}),t[14]=a):a=t[14];let o;t[15]===n?o=t[16]:(o=(0,W.jsx)(`div`,{className:`flex h-full w-full flex-col`,children:n}),t[15]=n,t[16]=o);let s;t[17]!==c||t[18]!==o?(s=(0,W.jsxs)(Wc,{className:`w-(--sidebar-width) bg-sidebar p-0 text-sidebar-foreground [&>button]:hidden`,"data-mobile":`true`,"data-sidebar":`sidebar`,"data-slot":`sidebar`,side:c,style:r,children:[a,o]}),t[17]=c,t[18]=o,t[19]=s):s=t[19];let l;return t[20]!==p||t[21]!==i||t[22]!==m||t[23]!==s?(l=(0,W.jsx)(Vc,{onOpenChange:m,open:p,...i,children:s}),t[20]=p,t[21]=i,t[22]=m,t[23]=s,t[24]=l):l=t[24],l}let h=f===`collapsed`?u:``,g=l===`floating`||l===`inset`?`group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon)`,_;t[25]===g?_=t[26]:(_=qe(`relative w-(--sidebar-width) bg-transparent transition-[width] duration-200 ease-linear`,`group-data-[collapsible=offExamples]:w-0`,`group-data-[side=right]:rotate-180`,g),t[25]=g,t[26]=_);let v;t[27]===_?v=t[28]:(v=(0,W.jsx)(`div`,{className:_,"data-slot":`sidebar-gap`}),t[27]=_,t[28]=v);let y=c===`left`?`left-0 group-data-[collapsible=offExamples]:left-[calc(var(--sidebar-width)*-1)]`:`right-0 group-data-[collapsible=offExamples]:right-[calc(var(--sidebar-width)*-1)]`,b=l===`floating`||l===`inset`?`p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]`:`group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l`,x;t[29]!==r||t[30]!==y||t[31]!==b?(x=qe(`fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex`,y,b,r),t[29]=r,t[30]=y,t[31]=b,t[32]=x):x=t[32];let S;t[33]===n?S=t[34]:(S=(0,W.jsx)(`div`,{className:`flex size-full flex-col bg-sidebar group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:shadow-sm group-data-[variant=floating]:ring-1 group-data-[variant=floating]:ring-sidebar-border`,"data-sidebar":`sidebar`,"data-slot":`sidebar-inner`,children:n}),t[33]=n,t[34]=S);let C;t[35]!==i||t[36]!==x||t[37]!==S?(C=(0,W.jsx)(`div`,{className:x,"data-slot":`sidebar-container`,...i,children:S}),t[35]=i,t[36]=x,t[37]=S,t[38]=C):C=t[38];let w;return t[39]!==c||t[40]!==f||t[41]!==C||t[42]!==h||t[43]!==v||t[44]!==l?(w=(0,W.jsxs)(`div`,{className:`group peer hidden text-sidebar-foreground md:block`,"data-collapsible":h,"data-side":c,"data-slot":`sidebar`,"data-state":f,"data-variant":l,children:[v,C]}),t[39]=c,t[40]=f,t[41]=C,t[42]=h,t[43]=v,t[44]=l,t[45]=w):w=t[45],w}function Wl(e){let t=(0,G.c)(15),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({className:n,onClick:r,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let{toggleSidebar:a}=zl(),o;t[4]===n?o=t[5]:(o=qe(n),t[4]=n,t[5]=o);let s;t[6]!==r||t[7]!==a?(s=e=>{r?.(e),a()},t[6]=r,t[7]=a,t[8]=s):s=t[8];let c,l;t[9]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,W.jsx)(po,{}),l=(0,W.jsx)(`span`,{className:`sr-only`,children:`Toggle Sidebar`}),t[9]=c,t[10]=l):(c=t[9],l=t[10]);let u;return t[11]!==i||t[12]!==o||t[13]!==s?(u=(0,W.jsxs)(_t,{className:o,"data-sidebar":`trigger`,"data-slot":`sidebar-trigger`,onClick:s,size:`icon-lg`,variant:`ghost`,...i,children:[c,l]}),t[11]=i,t[12]=o,t[13]=s,t[14]=u):u=t[14],u}function Gl(e){let t=(0,G.c)(9),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let{toggleSidebar:i}=zl(),a;t[3]===n?a=t[4]:(a=qe(`absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] hover:after:bg-sidebar-border sm:flex`,`in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize`,`[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize`,`group-data-[collapsible=offExamples]:translate-x-0 group-data-[collapsible=offExamples]:after:left-full hover:group-data-[collapsible=offExamples]:bg-sidebar`,`[[data-side=left][data-collapsible=offExamples]_&]:-right-2`,`[[data-side=right][data-collapsible=offExamples]_&]:-left-2`,n),t[3]=n,t[4]=a);let o;return t[5]!==r||t[6]!==a||t[7]!==i?(o=(0,W.jsx)(`button`,{"aria-label":`Toggle Sidebar`,className:a,"data-sidebar":`rail`,"data-slot":`sidebar-rail`,onClick:i,tabIndex:-1,title:`Toggle Sidebar`,...r}),t[5]=r,t[6]=a,t[7]=i,t[8]=o):o=t[8],o}function Kl(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`flex flex-col gap-2 p-2`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-sidebar":`header`,"data-slot":`sidebar-header`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function ql(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`flex flex-col gap-2 p-2`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-sidebar":`footer`,"data-slot":`sidebar-footer`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Jl(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`mx-2 w-auto bg-sidebar-border`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(kt,{className:i,"data-sidebar":`separator`,"data-slot":`sidebar-separator`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Yl(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`no-scrollbar flex min-h-0 flex-1 flex-col gap-0 overflow-auto group-data-[collapsible=icon]:overflow-hidden`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-sidebar":`content`,"data-slot":`sidebar-content`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Xl(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`relative flex w-full min-w-0 flex-col px-2 py-1`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`div`,{className:i,"data-sidebar":`group`,"data-slot":`sidebar-group`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Zl(e){let t=(0,G.c)(10),n,r,i,a;if(t[0]!==e){let{className:o,render:s,...c}=e;n=s,a=$a,r=`div`,i=ze({className:qe(`flex h-8 shrink-0 items-center rounded-md px-2 text-xs text-sidebar-foreground/70 ring-sidebar-ring outline-hidden transition-[margin,opacity] duration-200 ease-linear group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0 focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0`,o)},c),t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a}else n=t[1],r=t[2],i=t[3],a=t[4];let o;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(o={slot:`sidebar-group-label`,sidebar:`group-label`},t[5]=o):o=t[5];let s;return t[6]!==n||t[7]!==r||t[8]!==i?(s={defaultTagName:r,props:i,render:n,state:o},t[6]=n,t[7]=r,t[8]=i,t[9]=s):s=t[9],a(s)}function Ql(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`flex w-full min-w-0 flex-col gap-px`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`ul`,{className:i,"data-sidebar":`menu`,"data-slot":`sidebar-menu`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function $l(e){let t=(0,G.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=qe(`group/menu-item relative`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,W.jsx)(`li`,{className:i,"data-sidebar":`menu-item`,"data-slot":`sidebar-menu-item`,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}var eu=Ke(`peer/menu-button group/menu-button flex w-full items-center gap-2 overflow-hidden rounded-[calc(var(--radius-sm)+2px)] p-2 text-left text-xs ring-sidebar-ring outline-hidden transition-[width,height,padding] group-has-data-[sidebar=menu-action]/menu-item:pr-8 group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-active:bg-sidebar-accent data-active:font-medium data-active:text-sidebar-accent-foreground data-open:hover:bg-sidebar-accent data-open:hover:text-sidebar-accent-foreground [&_svg]:size-4 [&_svg]:shrink-0 [&>span:last-child]:truncate`,{variants:{variant:{default:`hover:bg-sidebar-accent hover:text-sidebar-accent-foreground`,outline:`bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]`},size:{default:`h-8 text-xs`,sm:`h-7 text-xs`,lg:`h-12 text-xs group-data-[collapsible=icon]:p-0!`}},defaultVariants:{variant:`default`,size:`default`}});function tu(e){let t=(0,G.c)(15),{render:n,isActive:r,variant:i,size:a,tooltip:o,className:s,...c}=e,l=r===void 0?!1:r,u=i===void 0?`default`:i,d=a===void 0?`default`:a,{isMobile:f,state:p}=zl(),m=ze({className:qe(eu({variant:u,size:d}),s)},c),h=o?Al:n,g;t[0]!==l||t[1]!==d?(g={slot:`sidebar-menu-button`,sidebar:`menu-button`,size:d,active:l},t[0]=l,t[1]=d,t[2]=g):g=t[2];let _;t[3]!==m||t[4]!==h||t[5]!==g?(_={defaultTagName:`button`,props:m,render:h,state:g},t[3]=m,t[4]=h,t[5]=g,t[6]=_):_=t[6];let v=$a(_);if(!o)return v;let y;t[7]===o?y=t[8]:(y=typeof o==`string`?{children:o}:o,t[7]=o,t[8]=y);let b=y,x=p!==`collapsed`||f,S;t[9]!==x||t[10]!==b?(S=(0,W.jsx)(jl,{align:`center`,hidden:x,side:`right`,...b}),t[9]=x,t[10]=b,t[11]=S):S=t[11];let C;return t[12]!==v||t[13]!==S?(C=(0,W.jsxs)(kl,{children:[v,S]}),t[12]=v,t[13]=S,t[14]=C):C=t[14],C}var nu=`ap-southeast-2`,ru=9999;async function iu({action:e,credentials:t,service:n=`spinifex`}){let r=window.location.protocol.replace(`:`,``),i=`Action=${e}`,a=new Ze({method:`POST`,protocol:r,hostname:`localhost`,port:ru,path:`/`,headers:{host:`localhost:${ru}`,"content-type":`application/x-www-form-urlencoded`},body:i}),o=await new $e({credentials:{accessKeyId:t.accessKeyId,secretAccessKey:t.secretAccessKey},region:nu,service:n,sha256:Qe}).sign(a),s={};for(let[e,t]of Object.entries(o.headers))typeof t==`string`&&(s[e]=t);let c=`${window.location.protocol}//${window.location.host}/proxy/awsgw/`,l=await fetch(c,{method:`POST`,headers:s,body:i});if(!l.ok){let t=await l.text().catch(()=>``);throw Error(`${e} failed: ${l.status}${t?` - ${t}`:``}`)}return l.json()}var au=`000000000001`,ou=(0,U.createContext)(void 0);function su({children:e}){let[t,n]=(0,U.useState)({isAdmin:!1,accountId:null,userName:null,version:null,license:null,loading:!0});return(0,U.useEffect)(()=>{async function e(){let e=Xe();if(!e){n(e=>({...e,loading:!1}));return}try{let t=await iu({action:`GetCallerIdentity`,credentials:e}),r=t.account_id===au,i=null;if(r)try{i=await iu({action:`GetVersion`,credentials:e})}catch{}n({isAdmin:r,accountId:t.account_id,userName:t.user_name,version:i,license:i?.license??null,loading:!1})}catch{n(e=>({...e,loading:!1}))}}e()},[]),(0,W.jsx)(ou,{value:t,children:e})}function cu(){let e=(0,U.useContext)(ou);if(e===void 0)throw Error(`useAdmin must be used within an AdminProvider`);return e}function lu(){let e=(0,G.c)(8),{theme:t,setTheme:n}=Qa(),r;e[0]!==n||e[1]!==t?(r=()=>{n(t===`light`?`dark`:t===`dark`?`light`:`dark`)},e[0]=n,e[1]=t,e[2]=r):r=e[2];let i=r,a,o,s;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(a=(0,W.jsx)(_o,{className:`size-[1.2rem] scale-100 rotate-0 transition-all dark:scale-0 dark:-rotate-90`}),o=(0,W.jsx)(uo,{className:`absolute size-[1.2rem] scale-0 rotate-90 transition-all dark:scale-100 dark:rotate-0`}),s=(0,W.jsx)(`span`,{className:`sr-only`,children:`Toggle theme`}),e[3]=a,e[4]=o,e[5]=s):(a=e[3],o=e[4],s=e[5]);let c;return e[6]===i?c=e[7]:(c=(0,W.jsxs)(_t,{className:`rounded-full`,onClick:i,size:`icon-sm`,variant:`ghost`,children:[a,o,s]}),e[6]=i,e[7]=c),c}function uu(){let e=(0,G.c)(7),{isAdmin:t,license:n}=cu(),r=t&&n===`open-source`,i,a;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(i=qe(`z-50 flex h-10 shrink-0 items-center gap-2 border-b border-sidebar-border bg-sidebar px-4 text-sidebar-foreground`,`sticky top-0`),a=(0,W.jsx)(Wl,{className:`-ml-1`}),e[0]=i,e[1]=a):(i=e[0],a=e[1]);let o;e[2]===r?o=e[3]:(o=r&&(0,W.jsx)(`a`,{href:`https://mulgadc.com/purchase`,target:`_blank`,rel:`noopener noreferrer`,className:qe(ft({variant:`outline`,size:`sm`})),children:`Upgrade`}),e[2]=r,e[3]=o);let s;e[4]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,W.jsx)(lu,{}),e[4]=s):s=e[4];let c;return e[5]===o?c=e[6]:(c=(0,W.jsxs)(`header`,{className:i,children:[a,(0,W.jsxs)(`div`,{className:`flex w-full items-center justify-end gap-2`,children:[o,s]})]}),e[5]=o,e[6]=c),c}function du(){let e=(0,G.c)(3),t,n;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,W.jsx)(`h1`,{className:`text-4xl font-bold`,children:`404`}),n=(0,W.jsx)(`p`,{className:`text-muted-foreground`,children:`Page not found`}),e[0]=t,e[1]=n):(t=e[0],n=e[1]);let r;return e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,W.jsxs)(`div`,{className:`flex flex-1 flex-col items-center justify-center gap-4`,children:[t,n,(0,W.jsx)(Pe,{to:`/`,children:(0,W.jsx)(_t,{variant:`outline`,children:`Go back home`})})]}),e[2]=r):r=e[2],r}function fu(){let e=(0,G.c)(130),t;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t={select:pu},e[0]=t):t=e[0];let n=za(t),r=Ie(),i=S(),{isAdmin:a}=cu(),o;e[1]!==r||e[2]!==i?(o=function(){et(),Re(),i.clear(),r({to:`/login`})},e[1]=r,e[2]=i,e[3]=o):o=e[3];let s=o,c;e[4]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,W.jsxs)(Kl,{className:`flex flex-row items-center gap-2 px-4 py-3`,children:[(0,W.jsx)(`img`,{src:`/mulga-logo.svg`,alt:`Mulga`,className:`size-6 shrink-0 dark:invert`}),(0,W.jsx)(`span`,{className:`truncate text-sm font-semibold group-data-[collapsible=icon]:hidden`,children:`Spinifex`})]}),e[4]=c):c=e[4];let l;e[5]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,W.jsx)(Zl,{children:`General`}),e[5]=l):l=e[5];let u=n===`/`,d,f;e[6]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,W.jsx)(ao,{className:`size-4`}),f=(0,W.jsx)(`span`,{children:`Dashboard`}),e[6]=d,e[7]=f):(d=e[6],f=e[7]);let p;e[8]===u?p=e[9]:(p=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/`,children:(0,W.jsxs)(tu,{isActive:u,tooltip:`Dashboard`,children:[d,f]})})}),e[8]=u,e[9]=p);let m;e[10]!==a||e[11]!==n?(m=a&&(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/nodes`,children:(0,W.jsxs)(tu,{isActive:n.startsWith(`/nodes`),tooltip:`Nodes`,children:[(0,W.jsx)(mo,{className:`size-4`}),(0,W.jsx)(`span`,{children:`Nodes`})]})})}),e[10]=a,e[11]=n,e[12]=m):m=e[12];let h;e[13]!==p||e[14]!==m?(h=(0,W.jsxs)(Xl,{children:[l,(0,W.jsxs)(Ql,{children:[p,m]})]}),e[13]=p,e[14]=m,e[15]=h):h=e[15];let g;e[16]===Symbol.for(`react.memo_cache_sentinel`)?(g=(0,W.jsx)(Zl,{children:`EC2`}),e[16]=g):g=e[16];let _;e[17]===n?_=e[18]:(_=n.startsWith(`/ec2/describe-instances`)||n.startsWith(`/ec2/run-instances`),e[17]=n,e[18]=_);let v,y;e[19]===Symbol.for(`react.memo_cache_sentinel`)?(v=(0,W.jsx)(mo,{className:`size-4`}),y=(0,W.jsx)(`span`,{children:`Instances`}),e[19]=v,e[20]=y):(v=e[19],y=e[20]);let b;e[21]===_?b=e[22]:(b=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-instances`,children:(0,W.jsxs)(tu,{isActive:_,tooltip:`EC2 Instances`,children:[v,y]})})}),e[21]=_,e[22]=b);let x;e[23]===n?x=e[24]:(x=n.startsWith(`/ec2/describe-images`),e[23]=n,e[24]=x);let C,w;e[25]===Symbol.for(`react.memo_cache_sentinel`)?(C=(0,W.jsx)(oo,{className:`size-4`}),w=(0,W.jsx)(`span`,{children:`Images`}),e[25]=C,e[26]=w):(C=e[25],w=e[26]);let T;e[27]===x?T=e[28]:(T=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-images`,children:(0,W.jsxs)(tu,{isActive:x,tooltip:`Images`,children:[C,w]})})}),e[27]=x,e[28]=T);let E;e[29]===n?E=e[30]:(E=n.startsWith(`/ec2/describe-key-pairs`),e[29]=n,e[30]=E);let D,O;e[31]===Symbol.for(`react.memo_cache_sentinel`)?(D=(0,W.jsx)(K,{className:`size-4`}),O=(0,W.jsx)(`span`,{children:`Key Pairs`}),e[31]=D,e[32]=O):(D=e[31],O=e[32]);let k;e[33]===E?k=e[34]:(k=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-key-pairs`,children:(0,W.jsxs)(tu,{isActive:E,tooltip:`Key Pairs`,children:[D,O]})})}),e[33]=E,e[34]=k);let A;e[35]===n?A=e[36]:(A=n.startsWith(`/ec2/describe-volumes`)||n.startsWith(`/ec2/create-volume`)||n.startsWith(`/ec2/modify-volume`),e[35]=n,e[36]=A);let ee,te;e[37]===Symbol.for(`react.memo_cache_sentinel`)?(ee=(0,W.jsx)(io,{className:`size-4`}),te=(0,W.jsx)(`span`,{children:`Volumes`}),e[37]=ee,e[38]=te):(ee=e[37],te=e[38]);let j;e[39]===A?j=e[40]:(j=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-volumes`,children:(0,W.jsxs)(tu,{isActive:A,tooltip:`Volumes`,children:[ee,te]})})}),e[39]=A,e[40]=j);let M;e[41]===n?M=e[42]:(M=n.startsWith(`/ec2/describe-snapshots`)||n.startsWith(`/ec2/create-snapshot`),e[41]=n,e[42]=M);let N,ne;e[43]===Symbol.for(`react.memo_cache_sentinel`)?(N=(0,W.jsx)(no,{className:`size-4`}),ne=(0,W.jsx)(`span`,{children:`Snapshots`}),e[43]=N,e[44]=ne):(N=e[43],ne=e[44]);let re;e[45]===M?re=e[46]:(re=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-snapshots`,children:(0,W.jsxs)(tu,{isActive:M,tooltip:`Snapshots`,children:[N,ne]})})}),e[45]=M,e[46]=re);let ie;e[47]===n?ie=e[48]:(ie=n.startsWith(`/ec2/describe-placement-groups`)||n.startsWith(`/ec2/create-placement-group`),e[47]=n,e[48]=ie);let ae,P;e[49]===Symbol.for(`react.memo_cache_sentinel`)?(ae=(0,W.jsx)(so,{className:`size-4`}),P=(0,W.jsx)(`span`,{children:`Placement Groups`}),e[49]=ae,e[50]=P):(ae=e[49],P=e[50]);let F;e[51]===ie?F=e[52]:(F=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-placement-groups`,children:(0,W.jsxs)(tu,{isActive:ie,tooltip:`Placement Groups`,children:[ae,P]})})}),e[51]=ie,e[52]=F);let oe;e[53]!==b||e[54]!==T||e[55]!==k||e[56]!==j||e[57]!==re||e[58]!==F?(oe=(0,W.jsxs)(Xl,{children:[g,(0,W.jsxs)(Ql,{children:[b,T,k,j,re,F]})]}),e[53]=b,e[54]=T,e[55]=k,e[56]=j,e[57]=re,e[58]=F,e[59]=oe):oe=e[59];let se;e[60]===Symbol.for(`react.memo_cache_sentinel`)?(se=(0,W.jsx)(Zl,{children:`Networking`}),e[60]=se):se=e[60];let ce;e[61]===n?ce=e[62]:(ce=n.startsWith(`/ec2/describe-vpcs`)||n.startsWith(`/ec2/create-vpc`),e[61]=n,e[62]=ce);let le,ue;e[63]===Symbol.for(`react.memo_cache_sentinel`)?(le=(0,W.jsx)(fo,{className:`size-4`}),ue=(0,W.jsx)(`span`,{children:`VPCs`}),e[63]=le,e[64]=ue):(le=e[63],ue=e[64]);let de;e[65]===ce?de=e[66]:(de=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-vpcs`,children:(0,W.jsxs)(tu,{isActive:ce,tooltip:`VPCs`,children:[le,ue]})})}),e[65]=ce,e[66]=de);let fe;e[67]===n?fe=e[68]:(fe=n.startsWith(`/ec2/describe-subnets`)||n.startsWith(`/ec2/create-subnet`),e[67]=n,e[68]=fe);let pe,me;e[69]===Symbol.for(`react.memo_cache_sentinel`)?(pe=(0,W.jsx)(co,{className:`size-4`}),me=(0,W.jsx)(`span`,{children:`Subnets`}),e[69]=pe,e[70]=me):(pe=e[69],me=e[70]);let he;e[71]===fe?he=e[72]:(he=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-subnets`,children:(0,W.jsxs)(tu,{isActive:fe,tooltip:`Subnets`,children:[pe,me]})})}),e[71]=fe,e[72]=he);let ge;e[73]===n?ge=e[74]:(ge=n.startsWith(`/ec2/describe-security-groups`)||n.startsWith(`/ec2/create-security-group`),e[73]=n,e[74]=ge);let _e,ve;e[75]===Symbol.for(`react.memo_cache_sentinel`)?(_e=(0,W.jsx)(ho,{className:`size-4`}),ve=(0,W.jsx)(`span`,{children:`Security Groups`}),e[75]=_e,e[76]=ve):(_e=e[75],ve=e[76]);let ye;e[77]===ge?ye=e[78]:(ye=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/ec2/describe-security-groups`,children:(0,W.jsxs)(tu,{isActive:ge,tooltip:`Security Groups`,children:[_e,ve]})})}),e[77]=ge,e[78]=ye);let be;e[79]!==de||e[80]!==he||e[81]!==ye?(be=(0,W.jsxs)(Xl,{children:[se,(0,W.jsxs)(Ql,{children:[de,he,ye]})]}),e[79]=de,e[80]=he,e[81]=ye,e[82]=be):be=e[82];let xe;e[83]===Symbol.for(`react.memo_cache_sentinel`)?(xe=(0,W.jsx)(Zl,{children:`IAM`}),e[83]=xe):xe=e[83];let Se;e[84]===n?Se=e[85]:(Se=n.startsWith(`/iam/list-users`)||n.startsWith(`/iam/create-user`),e[84]=n,e[85]=Se);let Ce,we;e[86]===Symbol.for(`react.memo_cache_sentinel`)?(Ce=(0,W.jsx)(vo,{className:`size-4`}),we=(0,W.jsx)(`span`,{children:`Users`}),e[86]=Ce,e[87]=we):(Ce=e[86],we=e[87]);let Te;e[88]===Se?Te=e[89]:(Te=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/iam/list-users`,children:(0,W.jsxs)(tu,{isActive:Se,tooltip:`Users`,children:[Ce,we]})})}),e[88]=Se,e[89]=Te);let I;e[90]===n?I=e[91]:(I=n.startsWith(`/iam/list-policies`)||n.startsWith(`/iam/create-policy`),e[90]=n,e[91]=I);let Ee,De;e[92]===Symbol.for(`react.memo_cache_sentinel`)?(Ee=(0,W.jsx)(go,{className:`size-4`}),De=(0,W.jsx)(`span`,{children:`Policies`}),e[92]=Ee,e[93]=De):(Ee=e[92],De=e[93]);let Oe;e[94]===I?Oe=e[95]:(Oe=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/iam/list-policies`,children:(0,W.jsxs)(tu,{isActive:I,tooltip:`Policies`,children:[Ee,De]})})}),e[94]=I,e[95]=Oe);let ke;e[96]!==Te||e[97]!==Oe?(ke=(0,W.jsxs)(Xl,{children:[xe,(0,W.jsxs)(Ql,{children:[Te,Oe]})]}),e[96]=Te,e[97]=Oe,e[98]=ke):ke=e[98];let Ae;e[99]===Symbol.for(`react.memo_cache_sentinel`)?(Ae=(0,W.jsx)(Zl,{children:`S3`}),e[99]=Ae):Ae=e[99];let je;e[100]===n?je=e[101]:(je=n.startsWith(`/s3/ls`),e[100]=n,e[101]=je);let Me,Ne;e[102]===Symbol.for(`react.memo_cache_sentinel`)?(Me=(0,W.jsx)(mo,{className:`size-4`}),Ne=(0,W.jsx)(`span`,{children:`Buckets`}),e[102]=Me,e[103]=Ne):(Me=e[102],Ne=e[103]);let L;e[104]===je?L=e[105]:(L=(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/s3/ls`,children:(0,W.jsxs)(tu,{isActive:je,tooltip:`Buckets`,children:[Me,Ne]})})}),e[104]=je,e[105]=L);let Fe;e[106]!==a||e[107]!==n?(Fe=a&&(0,W.jsx)($l,{children:(0,W.jsx)(Pe,{to:`/s3/service-metrics`,children:(0,W.jsxs)(tu,{isActive:n.startsWith(`/s3/service-metrics`),tooltip:`Service Metrics`,children:[(0,W.jsx)(eo,{className:`size-4`}),(0,W.jsx)(`span`,{children:`Service Metrics`})]})})}),e[106]=a,e[107]=n,e[108]=Fe):Fe=e[108];let R;e[109]!==L||e[110]!==Fe?(R=(0,W.jsxs)(Xl,{children:[Ae,(0,W.jsxs)(Ql,{children:[L,Fe]})]}),e[109]=L,e[110]=Fe,e[111]=R):R=e[111];let z;e[112]===a?z=e[113]:(z=a&&(0,W.jsxs)(Xl,{children:[(0,W.jsx)(Zl,{children:`Documentation`}),(0,W.jsx)(Ql,{children:(0,W.jsx)($l,{children:(0,W.jsx)(`a`,{href:`https://docs.mulgadc.com`,target:`_blank`,rel:`noopener noreferrer`,children:(0,W.jsxs)(tu,{tooltip:`Documentation`,children:[(0,W.jsx)(to,{className:`size-4`}),(0,W.jsx)(`span`,{children:`Docs`})]})})})})]}),e[112]=a,e[113]=z);let Le;e[114]!==oe||e[115]!==be||e[116]!==ke||e[117]!==R||e[118]!==z||e[119]!==h?(Le=(0,W.jsxs)(Yl,{children:[h,oe,be,ke,R,z]}),e[114]=oe,e[115]=be,e[116]=ke,e[117]=R,e[118]=z,e[119]=h,e[120]=Le):Le=e[120];let ze;e[121]===Symbol.for(`react.memo_cache_sentinel`)?(ze=(0,W.jsx)(Jl,{className:`mx-0 w-full`}),e[121]=ze):ze=e[121];let Be,Ve;e[122]===Symbol.for(`react.memo_cache_sentinel`)?(Be=(0,W.jsx)(lo,{className:`size-4`}),Ve=(0,W.jsx)(`span`,{children:`Sign out`}),e[122]=Be,e[123]=Ve):(Be=e[122],Ve=e[123]);let He;e[124]===s?He=e[125]:(He=(0,W.jsxs)(ql,{children:[ze,(0,W.jsx)(Ql,{children:(0,W.jsx)($l,{children:(0,W.jsxs)(tu,{onClick:s,tooltip:`Sign out`,children:[Be,Ve]})})})]}),e[124]=s,e[125]=He);let Ue;e[126]===Symbol.for(`react.memo_cache_sentinel`)?(Ue=(0,W.jsx)(Gl,{}),e[126]=Ue):Ue=e[126];let We;return e[127]!==Le||e[128]!==He?(We=(0,W.jsxs)(Ul,{collapsible:`icon`,children:[c,Le,He,Ue]}),e[127]=Le,e[128]=He,e[129]=We):We=e[129],We}function pu(e){return e.pathname}function mu(e){let t=(0,G.c)(18),{error:n,reset:r}=e,i=_e(),a=S(),o;t[0]!==a||t[1]!==r||t[2]!==i?(o=function(){a.invalidateQueries(),r(),i.invalidate()},t[0]=a,t[1]=r,t[2]=i,t[3]=o):o=t[3];let s=o,c;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,W.jsx)(fu,{}),t[4]=c):c=t[4];let l;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(l=(0,W.jsx)(uu,{}),t[5]=l):l=t[5];let u,d;t[6]===Symbol.for(`react.memo_cache_sentinel`)?(u=(0,W.jsx)(`div`,{className:`flex justify-center`,children:(0,W.jsx)(ro,{className:`size-12 text-destructive`})}),d=(0,W.jsx)(`h1`,{className:`text-2xl font-semibold`,children:`Something went wrong`}),t[6]=u,t[7]=d):(u=t[6],d=t[7]);let f=n.message||`An unexpected error occurred`,p;t[8]===f?p=t[9]:(p=(0,W.jsx)(`p`,{className:`text-muted-foreground`,children:f}),t[8]=f,t[9]=p);let m;t[10]===s?m=t[11]:(m=(0,W.jsx)(_t,{onClick:s,variant:`default`,children:`Try Again`}),t[10]=s,t[11]=m);let h;t[12]===Symbol.for(`react.memo_cache_sentinel`)?(h=(0,W.jsx)(Pe,{to:`/`,children:(0,W.jsx)(_t,{variant:`outline`,children:`Go Home`})}),t[12]=h):h=t[12];let g;t[13]===m?g=t[14]:(g=(0,W.jsxs)(`div`,{className:`flex justify-center gap-2`,children:[m,h]}),t[13]=m,t[14]=g);let _;return t[15]!==g||t[16]!==p?(_=(0,W.jsxs)(W.Fragment,{children:[c,(0,W.jsxs)(`main`,{className:`flex flex-1 flex-col`,children:[l,(0,W.jsx)(`div`,{className:`flex flex-1 items-center justify-center p-6 pt-0`,children:(0,W.jsxs)(`div`,{className:`max-w-md space-y-4 text-center`,children:[u,d,p,g]})})]})]}),t[15]=g,t[16]=p,t[17]=_):_=t[17],_}var hu=Fe()({head:()=>({meta:[{title:`Mulga`}]}),component:()=>(0,W.jsxs)(W.Fragment,{children:[(0,W.jsx)(Wa,{}),(0,W.jsx)(fu,{}),(0,W.jsxs)(`main`,{className:`flex flex-1 flex-col`,children:[(0,W.jsx)(uu,{}),(0,W.jsx)(`div`,{className:`flex flex-1 flex-col p-8`,children:(0,W.jsx)(Aa,{})})]})]}),errorComponent:mu,notFoundComponent:du}),gu=L(`/login`)({beforeLoad:()=>{if(Xe())throw Me({to:`/`})},component:R(()=>z(()=>import(`./login.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14])),`component`)}),_u=L(`/_auth`)({beforeLoad:()=>{if(!Xe())throw Me({to:`/login`})},component:R(()=>z(()=>import(`./route.js`),__vite__mapDeps([15,1])),`component`)}),vu=L(`/_auth/`)({loader:async({context:e})=>{await Promise.all([e.queryClient.ensureQueryData(or),e.queryClient.ensureQueryData(mr),e.queryClient.ensureQueryData(pr),e.queryClient.ensureQueryData(Zn),e.queryClient.ensureQueryData(Sr),e.queryClient.ensureQueryData(sr)])},head:()=>({meta:[{title:`Dashboard | Mulga`}]}),component:R(()=>z(()=>import(`./_auth.js`),__vite__mapDeps([16,1,3,4,17,2,5,6,18,19,20,8,21,22,23,24,25,26,27,28,29,13])),`component`)}),yu=L(`/_auth/nodes`)({beforeLoad:()=>{},head:()=>({meta:[{title:`Nodes | Mulga`}]}),component:R(()=>z(()=>import(`./nodes.js`),__vite__mapDeps([30,1,20,3,4,8,21,22,18,31,28,13])),`component`)}),bu=L(`/_auth/s3/service-metrics`)({head:()=>({meta:[{title:`Service Metrics | Mulga`}]}),component:R(()=>z(()=>import(`./service-metrics.js`),__vite__mapDeps([32,1,20,3,4,8,21,22,18,31,28,13])),`component`)}),xu=L(`/_auth/s3/ls/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(Sr)},head:()=>({meta:[{title:`Buckets | S3 | Mulga`}]}),component:R(()=>z(()=>import(`./ls.js`),__vite__mapDeps([33,1,3,4,19,2,5,18,7,8,34,21,22,23,24,35,28])),`component`)}),Su=L(`/_auth/s3/(buckets)/create-bucket`)({head:()=>({meta:[{title:`Create Bucket | S3 | Mulga`}]}),component:R(()=>z(()=>import(`./create-bucket.js`),__vite__mapDeps([36,1,37,2,3,4,5,22,38,12,39,24,40,23,25,41,7,8,42,26,43,44,45,28,14,9,10])),`component`)}),Cu=L(`/_auth/iam/(users)/create-user`)({head:()=>({meta:[{title:`Create User | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./create-user.js`),__vite__mapDeps([46,1,47,2,3,4,5,22,38,12,39,24,40,23,25,41,7,8,42,26,43,44,45,28,14,9,10,48])),`component`)}),wu=L(`/_auth/iam/(policies)/create-policy`)({head:()=>({meta:[{title:`Create Policy | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./create-policy.js`),__vite__mapDeps([49,1,47,2,3,4,5,22,38,12,39,24,40,23,25,41,7,8,42,26,43,44,45,28,14,9,10,50,48])),`component`)}),Tu=L(`/_auth/ec2/(vpc)/create-vpc`)({head:()=>({meta:[{title:`Create VPC | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-vpc.js`),__vite__mapDeps([51,1,52,2,3,4,5,17,6,18,22,38,7,8,53,54,10,11,24,9,25,42,26,12,39,40,23,27,41,43,44,45,28,14,55])),`component`)}),Eu=L(`/_auth/ec2/(volumes)/create-volume`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(ur)},head:()=>({meta:[{title:`Create Volume | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-volume.js`),__vite__mapDeps([56,1,52,2,3,4,5,17,6,18,22,38,53,7,8,54,10,11,24,9,25,42,26,12,34,21,39,40,23,41,43,44,45,28,14,55])),`component`)}),Du=L(`/_auth/ec2/(subnet)/create-subnet`)({loader:async({context:e})=>{await Promise.all([e.queryClient.ensureQueryData(pr),e.queryClient.ensureQueryData(ur)])},head:()=>({meta:[{title:`Create Subnet | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-subnet.js`),__vite__mapDeps([57,1,3,4,52,2,5,17,6,18,22,38,53,7,8,54,10,11,24,9,25,42,26,12,34,21,39,40,23,41,43,44,45,28,14,55])),`component`)}),Ou=L(`/_auth/ec2/(snapshots)/create-snapshot`)({validateSearch:e=>({volumeId:typeof e.volumeId==`string`?e.volumeId:void 0}),loader:async({context:e})=>{await e.queryClient.ensureQueryData(mr)},head:()=>({meta:[{title:`Create Snapshot | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-snapshot.js`),__vite__mapDeps([58,1,52,2,3,4,5,17,6,18,22,38,53,7,8,54,10,11,24,9,25,42,26,12,34,21,39,40,23,41,43,44,45,28,14,50,55])),`component`)}),ku=L(`/_auth/ec2/(security-groups)/create-security-group`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(pr)},head:()=>({meta:[{title:`Create Security Group | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-security-group.js`),__vite__mapDeps([59,1,3,4,52,2,5,17,6,18,22,38,53,7,8,54,10,11,24,9,25,42,26,12,34,21,39,40,23,41,43,44,45,28,14,55])),`component`)}),Au=L(`/_auth/ec2/(placement-groups)/create-placement-group`)({head:()=>({meta:[{title:`Create Placement Group | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-placement-group.js`),__vite__mapDeps([60,1,52,2,3,4,5,17,6,18,22,38,53,7,8,54,10,11,24,9,25,42,26,12,39,40,23,41,43,44,45,28,14,55])),`component`)}),ju=L(`/_auth/ec2/(key)/import-key-pair`)({head:()=>({meta:[{title:`Import Key Pair | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./import-key-pair.js`),__vite__mapDeps([61,1,52,2,3,4,5,17,6,18,22,38,12,39,24,40,23,25,41,7,8,42,26,43,44,45,28,14,9,10,50,55])),`component`)}),Mu=L(`/_auth/ec2/(key)/create-key-pair`)({head:()=>({meta:[{title:`Create Key Pair | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./create-key-pair.js`),__vite__mapDeps([62,1,52,2,3,4,5,17,6,18,22,38,63,7,8,12,39,24,40,23,25,42,64,41,26,43,44,65,45,28,14,9,10,55])),`component`)}),Nu=L(`/_auth/ec2/(instances)/run-instances`)({loader:async({context:e})=>{await Promise.all([e.queryClient.ensureQueryData(cr),e.queryClient.ensureQueryData(Zn),e.queryClient.ensureQueryData(Yn),e.queryClient.ensureQueryData(Jn),e.queryClient.ensureQueryData(dr)])},head:()=>({meta:[{title:`Run Instances | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./run-instances.js`),__vite__mapDeps([66,1,52,2,3,4,5,17,6,18,22,38,7,8,53,54,10,11,24,9,25,42,26,12,34,21,39,40,23,41,43,44,28,14,55])),`component`)}),Pu=L(`/_auth/s3/ls/$bucket`)({component:R(()=>z(()=>import(`./route2.js`),__vite__mapDeps([67,1])),`component`)}),Fu=L(`/_auth/s3/ls/$bucket/`)({loader:async({context:e,params:t})=>{await e.queryClient.ensureQueryData(Cr(t.bucket))},head:({params:e})=>({meta:[{title:`${e.bucket} | S3 | Mulga`}]}),component:R(()=>z(()=>import(`./_bucket.js`),__vite__mapDeps([68,1,37,2,3,4,5,22,38,69,7,8,23,24,25,64,70,71,63,19,18,34,21,40,28])),`component`)}),Iu=L(`/_auth/iam/(users)/list-users/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(br)},head:()=>({meta:[{title:`Users | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./list-users.js`),__vite__mapDeps([72,1,73,2,3,4,5,18,7,8,34,21,22,23,24,35,28])),`component`)}),Lu=L(`/_auth/iam/(policies)/list-policies/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(yr)},head:()=>({meta:[{title:`Policies | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./list-policies.js`),__vite__mapDeps([74,1,73,2,3,4,5,18,7,8,34,21,22,23,24,35,28])),`component`)}),Ru=L(`/_auth/ec2/(vpc)/describe-vpcs/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(pr)},head:()=>({meta:[{title:`VPCs | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-vpcs.js`),__vite__mapDeps([75,1,3,4,17,2,5,6,18,7,8,34,21,22,23,24,35,28,29])),`component`)}),zu=L(`/_auth/ec2/(volumes)/describe-volumes/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(mr)},head:()=>({meta:[{title:`Volumes | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-volumes.js`),__vite__mapDeps([76,1,17,2,3,4,5,6,18,7,8,34,21,22,23,24,35,28,29])),`component`)}),Bu=L(`/_auth/ec2/(subnet)/describe-subnets/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(Jn)},head:()=>({meta:[{title:`Subnets | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-subnets.js`),__vite__mapDeps([77,1,3,4,17,2,5,6,18,7,8,34,21,22,23,24,35,28,29])),`component`)}),Vu=L(`/_auth/ec2/(snapshots)/describe-snapshots/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(tr)},head:()=>({meta:[{title:`Snapshots | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-snapshots.js`),__vite__mapDeps([78,1,17,2,3,4,5,6,18,7,8,34,21,22,23,24,35,28,29])),`component`)}),Hu=L(`/_auth/ec2/(security-groups)/describe-security-groups/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(sr)},head:()=>({meta:[{title:`Security Groups | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-security-groups.js`),__vite__mapDeps([79,1,17,2,3,4,5,6,18,7,8,34,21,22,23,24,35,28])),`component`)}),Uu=L(`/_auth/ec2/(placement-groups)/describe-placement-groups/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(dr)},head:()=>({meta:[{title:`Placement Groups | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-placement-groups.js`),__vite__mapDeps([80,1,17,2,3,4,5,6,18,7,8,34,21,22,23,24,35,28,29])),`component`)}),Wu=L(`/_auth/ec2/(key)/describe-key-pairs/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(Zn)},head:()=>({meta:[{title:`Key Pairs | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-key-pairs.js`),__vite__mapDeps([81,1,17,2,3,4,5,6,18,7,8,34,21,22,23,24,35,28])),`component`)}),Z=L(`/_auth/ec2/(instances)/describe-instances/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(or)},head:()=>({meta:[{title:`Instances | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-instances.js`),__vite__mapDeps([82,1,17,2,3,4,5,6,18,7,8,34,21,22,23,24,35,28,29])),`component`)}),Gu=L(`/_auth/ec2/(images)/describe-images/`)({loader:async({context:e})=>{await e.queryClient.ensureQueryData(cr)},head:()=>({meta:[{title:`Images | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./describe-images.js`),__vite__mapDeps([83,1,17,2,3,4,5,6,18,34,21,22,35,23,24,28,29])),`component`)}),Ku=L(`/_auth/s3/ls/$bucket/$`)({loader:async({context:e,params:t})=>{let n=Je(t._splat??``);await e.queryClient.ensureQueryData(Cr(t.bucket,n))},head:({params:e})=>({meta:[{title:`${Ye(e._splat??``,`${e.bucket}/`)} | S3 | Mulga`}]}),component:R(()=>z(()=>import(`./_.js`),__vite__mapDeps([84,1,37,2,3,4,5,22,38,69,7,8,23,24,25,64,70,71,63,19,18,34,21,40])),`component`)}),qu=L(`/_auth/iam/(users)/list-users/$userName`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(vr(t.userName)),e.queryClient.ensureQueryData(xr(t.userName)),e.queryClient.ensureQueryData(_r(t.userName)),e.queryClient.ensureQueryData(yr)])},head:({params:e})=>({meta:[{title:`${e.userName} | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./_userName.js`),__vite__mapDeps([85,1,3,4,47,2,5,22,38,73,18,63,7,8,34,21,39,24,40,23,25,42,70,65,71,86,28,29,44])),`component`)}),Ju=L(`/_auth/iam/(policies)/list-policies/$policyArn`)({loader:async({context:e,params:t})=>{let n=decodeURIComponent(t.policyArn),r=await e.queryClient.ensureQueryData(gr(n)),i=r.Policy?.DefaultVersionId;return i&&await e.queryClient.ensureQueryData(hr(n,i)),r},head:({loaderData:e})=>({meta:[{title:`${e?.Policy?.PolicyName??`Policy`} | IAM | Mulga`}]}),component:R(()=>z(()=>import(`./_policyArn.js`),__vite__mapDeps([87,1,3,4,47,2,5,22,38,73,18,7,8,34,21,39,24,40,23,25,70,71,63,86,28])),`component`)}),Yu=L(`/_auth/ec2/(vpc)/describe-vpcs/$id`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(Xn(t.id)),e.queryClient.ensureQueryData(Jn)])},head:({params:e})=>({meta:[{title:`${e.id} | VPC | Mulga`}]}),component:R(()=>z(()=>import(`./_id10.js`),__vite__mapDeps([88,1,3,4,52,2,5,17,6,18,22,38,7,8,34,21,23,24,39,40,25,70,71,63,86,28,29])),`component`)}),Xu=L(`/_auth/ec2/(volumes)/modify-volume/$id`)({loader:async({context:e,params:t})=>{await e.queryClient.ensureQueryData(fr(t.id))},head:({params:e})=>({meta:[{title:`Resize ${e.id} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id9.js`),__vite__mapDeps([89,1,52,2,3,4,5,17,6,18,22,38,12,34,21,39,24,40,23,25,45,7,8,28,14,9,10,55])),`component`)}),Zu=L(`/_auth/ec2/(volumes)/describe-volumes/$id`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(fr(t.id)),e.queryClient.ensureQueryData(or)])},head:({params:e})=>({meta:[{title:`${e.id} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id8.js`),__vite__mapDeps([90,1,3,4,52,2,5,17,6,18,22,38,63,7,8,53,54,10,11,24,9,25,42,26,34,21,23,39,40,70,71,86,28,29,14])),`component`)}),Qu=L(`/_auth/ec2/(subnet)/describe-subnets/$id`)({loader:async({context:e,params:t})=>{await e.queryClient.ensureQueryData(er(t.id))},head:({params:e})=>({meta:[{title:`${e.id} | Subnet | Mulga`}]}),component:R(()=>z(()=>import(`./_id7.js`),__vite__mapDeps([91,1,3,4,52,2,5,17,6,18,22,38,7,8,34,21,23,24,39,40,25,70,71,63,86,28,29])),`component`)}),$u=L(`/_auth/ec2/(snapshots)/describe-snapshots/$id`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(ir(t.id)),e.queryClient.ensureQueryData(Qn)])},head:({params:e})=>({meta:[{title:`${e.id} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id6.js`),__vite__mapDeps([92,1,3,4,52,2,5,17,6,18,22,38,63,7,8,34,21,23,24,39,40,25,43,70,71,86,28,29,14,9,10])),`component`)}),ed=L(`/_auth/ec2/(security-groups)/describe-security-groups/$id`)({loader:async({context:e,params:t})=>{await e.queryClient.ensureQueryData($n(t.id))},head:({params:e})=>({meta:[{title:`${e.id} | Security Group | Mulga`}]}),component:R(()=>z(()=>import(`./_id5.js`),__vite__mapDeps([93,1,52,2,3,4,5,17,6,18,22,38,63,7,8,53,54,10,11,24,9,25,42,26,12,34,21,23,39,40,70,71,86,28,14,55])),`component`)}),td=L(`/_auth/ec2/(placement-groups)/describe-placement-groups/$id`)({loader:async({context:e,params:t})=>{await Promise.all([e.queryClient.ensureQueryData(rr(t.id)),e.queryClient.ensureQueryData(or)])},head:({params:e})=>({meta:[{title:`${e.id} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id4.js`),__vite__mapDeps([94,1,52,2,3,4,5,17,6,18,22,38,7,8,34,21,23,24,39,40,25,70,71,63,86,28,29])),`component`)}),nd=L(`/_auth/ec2/(key)/describe-key-pairs/$id`)({loader:async({context:e,params:t})=>await e.queryClient.ensureQueryData(lr(t.id)),head:({loaderData:e})=>({meta:[{title:`${e?.KeyPairs?.[0]?.KeyName??`Key Pair`} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id3.js`),__vite__mapDeps([95,1,3,4,52,2,5,17,6,18,22,38,7,8,34,21,39,24,40,23,25,70,71,63,86,28])),`component`)}),rd=L(`/_auth/ec2/(instances)/describe-instances/$id`)({loader:async({context:e,params:t})=>{let[n]=await Promise.all([e.queryClient.ensureQueryData(nr(t.id)),e.queryClient.ensureQueryData(Yn)]),r=n.Reservations?.[0]?.Instances?.[0]?.ImageId;return await e.queryClient.ensureQueryData(ar(r)),n},head:({loaderData:e})=>({meta:[{title:`${e?.Reservations?.[0]?.Instances?.[0]?.InstanceId??`Instance`} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id2.js`),__vite__mapDeps([96,1,3,4,52,2,5,17,6,18,22,38,63,7,8,53,54,10,11,24,9,25,42,26,34,21,23,40,70,86,28,29,14,50,97])),`component`)}),id=L(`/_auth/ec2/(images)/describe-images/$id`)({loader:async({context:e,params:t})=>await e.queryClient.ensureQueryData(ar(t.id)),head:({loaderData:e})=>({meta:[{title:`${e?.Images?.[0]?.Name??`Image`} | EC2 | Mulga`}]}),component:R(()=>z(()=>import(`./_id.js`),__vite__mapDeps([98,1,17,2,3,4,5,6,18,34,21,22,40,23,24,25,28,29,97,86])),`component`)}),ad=gu.update({id:`/login`,path:`/login`,getParentRoute:()=>hu}),Q=_u.update({id:`/_auth`,getParentRoute:()=>hu}),od=vu.update({id:`/`,path:`/`,getParentRoute:()=>Q}),sd=yu.update({id:`/nodes`,path:`/nodes`,getParentRoute:()=>Q}),cd=bu.update({id:`/s3/service-metrics`,path:`/s3/service-metrics`,getParentRoute:()=>Q}),ld=xu.update({id:`/s3/ls/`,path:`/s3/ls/`,getParentRoute:()=>Q}),ud=Su.update({id:`/s3/(buckets)/create-bucket`,path:`/s3/create-bucket`,getParentRoute:()=>Q}),dd=Cu.update({id:`/iam/(users)/create-user`,path:`/iam/create-user`,getParentRoute:()=>Q}),fd=wu.update({id:`/iam/(policies)/create-policy`,path:`/iam/create-policy`,getParentRoute:()=>Q}),pd=Tu.update({id:`/ec2/(vpc)/create-vpc`,path:`/ec2/create-vpc`,getParentRoute:()=>Q}),md=Eu.update({id:`/ec2/(volumes)/create-volume`,path:`/ec2/create-volume`,getParentRoute:()=>Q}),hd=Du.update({id:`/ec2/(subnet)/create-subnet`,path:`/ec2/create-subnet`,getParentRoute:()=>Q}),gd=Ou.update({id:`/ec2/(snapshots)/create-snapshot`,path:`/ec2/create-snapshot`,getParentRoute:()=>Q}),_d=ku.update({id:`/ec2/(security-groups)/create-security-group`,path:`/ec2/create-security-group`,getParentRoute:()=>Q}),vd=Au.update({id:`/ec2/(placement-groups)/create-placement-group`,path:`/ec2/create-placement-group`,getParentRoute:()=>Q}),$=ju.update({id:`/ec2/(key)/import-key-pair`,path:`/ec2/import-key-pair`,getParentRoute:()=>Q}),yd=Mu.update({id:`/ec2/(key)/create-key-pair`,path:`/ec2/create-key-pair`,getParentRoute:()=>Q}),bd=Nu.update({id:`/ec2/(instances)/run-instances`,path:`/ec2/run-instances`,getParentRoute:()=>Q}),xd=Pu.update({id:`/s3/ls/$bucket`,path:`/s3/ls/$bucket`,getParentRoute:()=>Q}),Sd=Fu.update({id:`/`,path:`/`,getParentRoute:()=>xd}),Cd=Iu.update({id:`/iam/(users)/list-users/`,path:`/iam/list-users/`,getParentRoute:()=>Q}),wd=Lu.update({id:`/iam/(policies)/list-policies/`,path:`/iam/list-policies/`,getParentRoute:()=>Q}),Td=Ru.update({id:`/ec2/(vpc)/describe-vpcs/`,path:`/ec2/describe-vpcs/`,getParentRoute:()=>Q}),Ed=zu.update({id:`/ec2/(volumes)/describe-volumes/`,path:`/ec2/describe-volumes/`,getParentRoute:()=>Q}),Dd=Bu.update({id:`/ec2/(subnet)/describe-subnets/`,path:`/ec2/describe-subnets/`,getParentRoute:()=>Q}),Od=Vu.update({id:`/ec2/(snapshots)/describe-snapshots/`,path:`/ec2/describe-snapshots/`,getParentRoute:()=>Q}),kd=Hu.update({id:`/ec2/(security-groups)/describe-security-groups/`,path:`/ec2/describe-security-groups/`,getParentRoute:()=>Q}),Ad=Uu.update({id:`/ec2/(placement-groups)/describe-placement-groups/`,path:`/ec2/describe-placement-groups/`,getParentRoute:()=>Q}),jd=Wu.update({id:`/ec2/(key)/describe-key-pairs/`,path:`/ec2/describe-key-pairs/`,getParentRoute:()=>Q}),Md=Z.update({id:`/ec2/(instances)/describe-instances/`,path:`/ec2/describe-instances/`,getParentRoute:()=>Q}),Nd=Gu.update({id:`/ec2/(images)/describe-images/`,path:`/ec2/describe-images/`,getParentRoute:()=>Q}),Pd=Ku.update({id:`/$`,path:`/$`,getParentRoute:()=>xd}),Fd=qu.update({id:`/iam/(users)/list-users/$userName`,path:`/iam/list-users/$userName`,getParentRoute:()=>Q}),Id=Ju.update({id:`/iam/(policies)/list-policies/$policyArn`,path:`/iam/list-policies/$policyArn`,getParentRoute:()=>Q}),Ld=Yu.update({id:`/ec2/(vpc)/describe-vpcs/$id`,path:`/ec2/describe-vpcs/$id`,getParentRoute:()=>Q}),Rd=Xu.update({id:`/ec2/(volumes)/modify-volume/$id`,path:`/ec2/modify-volume/$id`,getParentRoute:()=>Q}),zd=Zu.update({id:`/ec2/(volumes)/describe-volumes/$id`,path:`/ec2/describe-volumes/$id`,getParentRoute:()=>Q}),Bd=Qu.update({id:`/ec2/(subnet)/describe-subnets/$id`,path:`/ec2/describe-subnets/$id`,getParentRoute:()=>Q}),Vd=$u.update({id:`/ec2/(snapshots)/describe-snapshots/$id`,path:`/ec2/describe-snapshots/$id`,getParentRoute:()=>Q}),Hd=ed.update({id:`/ec2/(security-groups)/describe-security-groups/$id`,path:`/ec2/describe-security-groups/$id`,getParentRoute:()=>Q}),Ud=td.update({id:`/ec2/(placement-groups)/describe-placement-groups/$id`,path:`/ec2/describe-placement-groups/$id`,getParentRoute:()=>Q}),Wd=nd.update({id:`/ec2/(key)/describe-key-pairs/$id`,path:`/ec2/describe-key-pairs/$id`,getParentRoute:()=>Q}),Gd=rd.update({id:`/ec2/(instances)/describe-instances/$id`,path:`/ec2/describe-instances/$id`,getParentRoute:()=>Q}),Kd=id.update({id:`/ec2/(images)/describe-images/$id`,path:`/ec2/describe-images/$id`,getParentRoute:()=>Q}),qd={AuthS3LsBucketSplatRoute:Pd,AuthS3LsBucketIndexRoute:Sd},Jd={AuthNodesRoute:sd,AuthIndexRoute:od,AuthS3ServiceMetricsRoute:cd,AuthS3LsBucketRouteRoute:xd._addFileChildren(qd),AuthEc2instancesRunInstancesRoute:bd,AuthEc2keyCreateKeyPairRoute:yd,AuthEc2keyImportKeyPairRoute:$,AuthEc2placementGroupsCreatePlacementGroupRoute:vd,AuthEc2securityGroupsCreateSecurityGroupRoute:_d,AuthEc2snapshotsCreateSnapshotRoute:gd,AuthEc2subnetCreateSubnetRoute:hd,AuthEc2volumesCreateVolumeRoute:md,AuthEc2vpcCreateVpcRoute:pd,AuthIampoliciesCreatePolicyRoute:fd,AuthIamusersCreateUserRoute:dd,AuthS3bucketsCreateBucketRoute:ud,AuthS3LsIndexRoute:ld,AuthEc2imagesDescribeImagesIdRoute:Kd,AuthEc2instancesDescribeInstancesIdRoute:Gd,AuthEc2keyDescribeKeyPairsIdRoute:Wd,AuthEc2placementGroupsDescribePlacementGroupsIdRoute:Ud,AuthEc2securityGroupsDescribeSecurityGroupsIdRoute:Hd,AuthEc2snapshotsDescribeSnapshotsIdRoute:Vd,AuthEc2subnetDescribeSubnetsIdRoute:Bd,AuthEc2volumesDescribeVolumesIdRoute:zd,AuthEc2volumesModifyVolumeIdRoute:Rd,AuthEc2vpcDescribeVpcsIdRoute:Ld,AuthIampoliciesListPoliciesPolicyArnRoute:Id,AuthIamusersListUsersUserNameRoute:Fd,AuthEc2imagesDescribeImagesIndexRoute:Nd,AuthEc2instancesDescribeInstancesIndexRoute:Md,AuthEc2keyDescribeKeyPairsIndexRoute:jd,AuthEc2placementGroupsDescribePlacementGroupsIndexRoute:Ad,AuthEc2securityGroupsDescribeSecurityGroupsIndexRoute:kd,AuthEc2snapshotsDescribeSnapshotsIndexRoute:Od,AuthEc2subnetDescribeSubnetsIndexRoute:Dd,AuthEc2volumesDescribeVolumesIndexRoute:Ed,AuthEc2vpcDescribeVpcsIndexRoute:Td,AuthIampoliciesListPoliciesIndexRoute:wd,AuthIamusersListUsersIndexRoute:Cd},Yd={AuthRouteRoute:Q._addFileChildren(Jd),LoginRoute:ad},Xd=hu._addFileChildren(Yd)._addFileTypes(),Zd=new Ir({defaultOptions:{queries:{staleTime:5e3}}}),Qd=Fa({routeTree:Xd,context:{queryClient:Zd},defaultPreload:`intent`,scrollRestoration:!0,defaultStructuralSharing:!0,defaultPreloadStaleTime:0}),$d=document.querySelector(`#app`);$d&&!$d.innerHTML&&Ja.createRoot($d).render((0,W.jsx)(U.StrictMode,{children:(0,W.jsx)(Za,{defaultTheme:`dark`,storageKey:`spinifex-ui-theme`,children:(0,W.jsx)(D,{client:Zd,children:(0,W.jsx)(su,{children:(0,W.jsx)(Bl,{children:(0,W.jsx)(Ra,{router:Qd})})})})})}));export{Eo as A,no as B,Pc as C,Ts as D,rc as E,go as F,Aa as H,mo as I,fo as L,wo as M,So as N,Oo as O,yo as P,K as R,Fc as S,Mc as T,Mr as U,$a as V,Tr as W,iu as _,ed as a,Bc as b,Zu as c,Ju as d,qu as f,cu as g,Ou as h,td as i,Co as j,Do as k,Xu as l,Fu as m,rd as n,$u as o,Ku as p,nd as r,Qu as s,id as t,Yu as u,Sl as v,Nc as w,Lc as x,bl as y,io as z}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/lazyRouteComponent.js b/spinifex/services/spinifexui/frontend/dist/assets/lazyRouteComponent.js index 0d0fbcbab..32c9feda1 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/lazyRouteComponent.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/lazyRouteComponent.js @@ -1 +1 @@ -import{a as e,n as t,r as n}from"./compiler-runtime.js";import{r,t as i}from"./useRouter.js";import{L as a,M as o,S as s,h as c,m as l,t as u,u as d}from"./useStore.js";import{n as f,r as p,t as m}from"./matchContext.js";import{n as h}from"./redirect.js";import{t as g}from"./link.js";import{t as _}from"./useNavigate.js";var v=class{get to(){return this._to}get id(){return this._id}get path(){return this._path}get fullPath(){return this._fullPath}constructor(e){if(this.init=e=>{this.originalIndex=e.originalIndex;let t=this.options,n=!t?.path&&!t?.id;this.parentRoute=this.options.getParentRoute?.(),n?this._path=p:this.parentRoute||s();let r=n?p:t?.path;r&&r!==`/`&&(r=l(r));let i=t?.id||r,a=n?p:d([this.parentRoute.id===`__root__`?``:this.parentRoute.id,i]);r===`__root__`&&(r=`/`),a!==`__root__`&&(a=d([`/`,a]));let o=a===`__root__`?`/`:d([this.parentRoute.fullPath,r]);this._path=r,this._id=a,this._fullPath=o,this._to=c(o)},this.addChildren=e=>this._addFileChildren(e),this._addFileChildren=e=>(Array.isArray(e)&&(this.children=e),typeof e==`object`&&e&&(this.children=Object.values(e)),this),this._addFileTypes=()=>this,this.updateLoader=e=>(Object.assign(this.options,e),this),this.update=e=>(Object.assign(this.options,e),this),this.lazy=e=>(this.lazyFn=e,this),this.redirect=e=>h({from:this.fullPath,...e}),this.options=e||{},this.isRoot=!e?.getParentRoute,e?.id&&e?.path)throw Error(`Route cannot have both an 'id' and a 'path' option.`)}},y=class extends v{constructor(e){super(e)}},b=e(n(),1),x={state:void 0,get:()=>void 0,subscribe:()=>()=>{}};function S(e){let t=i(),n=b.useContext(e.from?m:f),r=e.from??n,o=r?e.from?t.stores.getMatchStoreByRouteId(r):t.stores.activeMatchStoresById.get(r):void 0,c=b.useRef(void 0);return u(o??x,n=>{if((e.shouldThrow??!0)&&!n&&s(),n===void 0)return;let r=e.select?e.select(n):n;if(e.structuralSharing??t.options.defaultStructuralSharing){let e=a(c.current,r);return c.current=e,e}return r})}function C(e){return S({from:e.from,strict:e.strict,structuralSharing:e.structuralSharing,select:t=>e.select?e.select(t.loaderData):t.loaderData})}function w(e){let{select:t,...n}=e;return S({...n,select:e=>t?t(e.loaderDeps):e.loaderDeps})}function T(e){return S({from:e.from,shouldThrow:e.shouldThrow,structuralSharing:e.structuralSharing,strict:e.strict,select:t=>{let n=e.strict===!1?t.params:t._strictParams;return e.select?e.select(n):n}})}function E(e){return S({from:e.from,strict:e.strict,shouldThrow:e.shouldThrow,structuralSharing:e.structuralSharing,select:t=>e.select?e.select(t.search):t.search})}function D(e){return S({...e,select:t=>e.select?e.select(t.context):t.context})}var O=t(),k=class extends v{constructor(e){super(e),this.useMatch=e=>S({select:e?.select,from:this.id,structuralSharing:e?.structuralSharing}),this.useRouteContext=e=>D({...e,from:this.id}),this.useSearch=e=>E({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useParams=e=>T({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useLoaderDeps=e=>w({...e,from:this.id}),this.useLoaderData=e=>C({...e,from:this.id}),this.useNavigate=()=>_({from:this.fullPath}),this.Link=b.forwardRef((e,t)=>(0,O.jsx)(g,{ref:t,from:this.fullPath,...e}))}};function A(e){return new k(e)}function j(){return e=>N(e)}var M=class extends y{constructor(e){super(e),this.useMatch=e=>S({select:e?.select,from:this.id,structuralSharing:e?.structuralSharing}),this.useRouteContext=e=>D({...e,from:this.id}),this.useSearch=e=>E({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useParams=e=>T({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useLoaderDeps=e=>w({...e,from:this.id}),this.useLoaderData=e=>C({...e,from:this.id}),this.useNavigate=()=>_({from:this.fullPath}),this.Link=b.forwardRef((e,t)=>(0,O.jsx)(g,{ref:t,from:this.fullPath,...e}))}};function N(e){return new M(e)}function P(e){return typeof e==`object`?new F(e,{silent:!0}).createRoute(e):new F(e,{silent:!0}).createRoute}var F=class{constructor(e,t){this.path=e,this.createRoute=e=>{let t=A(e);return t.isRoot=!1,t},this.silent=t?.silent}};function I(e,t){let n,i,a,s,c=()=>(n||=e().then(e=>{n=void 0,i=e[t??`default`]}).catch(e=>{if(a=e,o(a)&&a instanceof Error&&typeof window<`u`&&typeof sessionStorage<`u`){let e=`tanstack_router_reload:${a.message}`;sessionStorage.getItem(e)||(sessionStorage.setItem(e,`1`),s=!0)}}),n),l=function(e){if(s)throw window.location.reload(),new Promise(()=>{});if(a)throw a;if(!i)if(r)r(c());else throw c();return b.createElement(i,e)};return l.preload=c,l}export{P as n,j as r,I as t}; \ No newline at end of file +import{a as e,n as t,r as n}from"./compiler-runtime.js";import{B as r,P as i,_ as a,f as o,g as s,i as c,t as l,w as u,z as d}from"./useStore.js";import{n as f,r as p,t as m}from"./matchContext.js";import{n as h}from"./redirect.js";import{t as g}from"./link.js";import{t as _}from"./useNavigate.js";var v=class{get to(){return this._to}get id(){return this._id}get path(){return this._path}get fullPath(){return this._fullPath}constructor(e){if(this.init=e=>{this.originalIndex=e.originalIndex;let t=this.options,n=!t?.path&&!t?.id;this.parentRoute=this.options.getParentRoute?.(),n?this._path=p:this.parentRoute||u();let r=n?p:t?.path;r&&r!==`/`&&(r=s(r));let i=t?.id||r,c=n?p:o([this.parentRoute.id===`__root__`?``:this.parentRoute.id,i]);r===`__root__`&&(r=`/`),c!==`__root__`&&(c=o([`/`,c]));let l=c===`__root__`?`/`:o([this.parentRoute.fullPath,r]);this._path=r,this._id=c,this._fullPath=l,this._to=a(l)},this.addChildren=e=>this._addFileChildren(e),this._addFileChildren=e=>(Array.isArray(e)&&(this.children=e),typeof e==`object`&&e&&(this.children=Object.values(e)),this),this._addFileTypes=()=>this,this.updateLoader=e=>(Object.assign(this.options,e),this),this.update=e=>(Object.assign(this.options,e),this),this.lazy=e=>(this.lazyFn=e,this),this.redirect=e=>h({from:this.fullPath,...e}),this.options=e||{},this.isRoot=!e?.getParentRoute,e?.id&&e?.path)throw Error(`Route cannot have both an 'id' and a 'path' option.`)}},y=class extends v{constructor(e){super(e)}},b=e(n(),1),x={state:void 0,get:()=>void 0,subscribe:()=>()=>{}};function S(e){let t=c(),n=b.useContext(e.from?m:f),r=e.from??n,i=r?e.from?t.stores.getMatchStoreByRouteId(r):t.stores.activeMatchStoresById.get(r):void 0,a=b.useRef(void 0);return l(i??x,n=>{if((e.shouldThrow??!0)&&!n&&u(),n===void 0)return;let r=e.select?e.select(n):n;if(e.structuralSharing??t.options.defaultStructuralSharing){let e=d(a.current,r);return a.current=e,e}return r})}function C(e){return S({from:e.from,strict:e.strict,structuralSharing:e.structuralSharing,select:t=>e.select?e.select(t.loaderData):t.loaderData})}function w(e){let{select:t,...n}=e;return S({...n,select:e=>t?t(e.loaderDeps):e.loaderDeps})}function T(e){return S({from:e.from,shouldThrow:e.shouldThrow,structuralSharing:e.structuralSharing,strict:e.strict,select:t=>{let n=e.strict===!1?t.params:t._strictParams;return e.select?e.select(n):n}})}function E(e){return S({from:e.from,strict:e.strict,shouldThrow:e.shouldThrow,structuralSharing:e.structuralSharing,select:t=>e.select?e.select(t.search):t.search})}function D(e){return S({...e,select:t=>e.select?e.select(t.context):t.context})}var O=t(),k=class extends v{constructor(e){super(e),this.useMatch=e=>S({select:e?.select,from:this.id,structuralSharing:e?.structuralSharing}),this.useRouteContext=e=>D({...e,from:this.id}),this.useSearch=e=>E({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useParams=e=>T({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useLoaderDeps=e=>w({...e,from:this.id}),this.useLoaderData=e=>C({...e,from:this.id}),this.useNavigate=()=>_({from:this.fullPath}),this.Link=b.forwardRef((e,t)=>(0,O.jsx)(g,{ref:t,from:this.fullPath,...e}))}};function A(e){return new k(e)}function j(){return e=>N(e)}var M=class extends y{constructor(e){super(e),this.useMatch=e=>S({select:e?.select,from:this.id,structuralSharing:e?.structuralSharing}),this.useRouteContext=e=>D({...e,from:this.id}),this.useSearch=e=>E({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useParams=e=>T({select:e?.select,structuralSharing:e?.structuralSharing,from:this.id}),this.useLoaderDeps=e=>w({...e,from:this.id}),this.useLoaderData=e=>C({...e,from:this.id}),this.useNavigate=()=>_({from:this.fullPath}),this.Link=b.forwardRef((e,t)=>(0,O.jsx)(g,{ref:t,from:this.fullPath,...e}))}};function N(e){return new M(e)}function P(e){return typeof e==`object`?new F(e,{silent:!0}).createRoute(e):new F(e,{silent:!0}).createRoute}var F=class{constructor(e,t){this.path=e,this.createRoute=e=>{let t=A(e);return t.isRoot=!1,t},this.silent=t?.silent}};function I(e,t){let n,a,o,s,c=()=>(n||=e().then(e=>{n=void 0,a=e[t??`default`]}).catch(e=>{if(o=e,i(o)&&o instanceof Error&&typeof window<`u`&&typeof sessionStorage<`u`){let e=`tanstack_router_reload:${o.message}`;sessionStorage.getItem(e)||(sessionStorage.setItem(e,`1`),s=!0)}}),n),l=function(e){if(s)throw window.location.reload(),new Promise(()=>{});if(o)throw o;if(!a)if(r)r(c());else throw c();return b.createElement(a,e)};return l.preload=c,l}export{P as n,j as r,I as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/link.js b/spinifex/services/spinifexui/frontend/dist/assets/link.js index 6db09ee31..150a8514f 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/link.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/link.js @@ -1 +1 @@ -import{a as e,n as t,r as n}from"./compiler-runtime.js";import{a as r,i as ee,t as i}from"./useRouter.js";import{A as a,D as te,a as ne,c as o,d as s,j as c,t as re}from"./useStore.js";import{Xt as l}from"./awsClient.js";var ie=`Error preloading route! ☝️`,u=e(n(),1);t();var d=e(l(),1);function f(e,t){let n=i(),l=ee(t),{activeProps:f,inactiveProps:g,activeOptions:_,to:v,preload:pe,preloadDelay:me,hashScrollIntoView:he,replace:ge,startTransition:_e,resetScroll:y,viewTransition:b,children:x,target:S,disabled:C,style:w,className:T,onClick:E,onBlur:D,onFocus:O,onMouseEnter:k,onMouseLeave:A,onTouchStart:j,ignoreBlocker:M,params:ve,search:ye,hash:be,state:xe,mask:Se,reloadDocument:Ce,unsafeRelative:we,from:Te,_fromLocation:Ee,...N}=e,P=ne(),F=u.useMemo(()=>e,[n,e.from,e._fromLocation,e.hash,e.to,e.search,e.params,e.state,e.mask,e.unsafeRelative]),I=re(n.stores.location,e=>e,(e,t)=>e.href===t.href),L=u.useMemo(()=>{let e={_fromLocation:I,...F};return n.buildLocation(e)},[n,I,F]),R=L.maskedLocation?L.maskedLocation.publicHref:L.publicHref,z=L.maskedLocation?L.maskedLocation.external:L.external,B=u.useMemo(()=>ue(R,z,n.history,C),[C,z,R,n.history]),V=u.useMemo(()=>{if(B?.external)return c(B.href,n.protocolAllowlist)?void 0:B.href;if(!de(v)&&!(typeof v!=`string`||v.indexOf(`:`)===-1))try{return new URL(v),c(v,n.protocolAllowlist)?void 0:v}catch{}},[v,B,n.protocolAllowlist]),H=u.useMemo(()=>{if(V)return!1;if(_?.exact){if(!o(I.pathname,L.pathname,n.basepath))return!1}else{let e=s(I.pathname,n.basepath),t=s(L.pathname,n.basepath);if(!(e.startsWith(t)&&(e.length===t.length||e[t.length]===`/`)))return!1}return(_?.includeSearch??!0)&&!te(I.search,L.search,{partial:!_?.exact,ignoreUndefined:!_?.explicitUndefined})?!1:_?.includeHash?P&&I.hash===L.hash:!0},[_?.exact,_?.explicitUndefined,_?.includeHash,_?.includeSearch,I,V,P,L.hash,L.pathname,L.search,n.basepath]),U=H?a(f,{})??ae:p,W=H?p:a(g,{})??p,G=[T,U.className,W.className].filter(Boolean).join(` `),K=(w||U.style||W.style)&&{...w,...U.style,...W.style},[De,q]=u.useState(!1),J=u.useRef(!1),Y=e.reloadDocument||V?!1:pe??n.options.defaultPreload,X=me??n.options.defaultPreloadDelay??0,Z=u.useCallback(()=>{n.preloadRoute({...F,_builtLocation:L}).catch(e=>{console.warn(e),console.warn(ie)})},[n,F,L]);r(l,u.useCallback(e=>{e?.isIntersecting&&Z()},[Z]),le,{disabled:!!C||Y!==`viewport`}),u.useEffect(()=>{J.current||!C&&Y===`render`&&(Z(),J.current=!0)},[C,Z,Y]);let Oe=e=>{let t=e.currentTarget.getAttribute(`target`),r=S===void 0?t:S;if(!C&&!fe(e)&&!e.defaultPrevented&&(!r||r===`_self`)&&e.button===0){e.preventDefault(),(0,d.flushSync)(()=>{q(!0)});let t=n.subscribe(`onResolved`,()=>{t(),q(!1)});n.navigate({...F,replace:ge,resetScroll:y,hashScrollIntoView:he,startTransition:_e,viewTransition:b,ignoreBlocker:M})}};if(V)return{...N,ref:l,href:V,...x&&{children:x},...S&&{target:S},...C&&{disabled:C},...w&&{style:w},...T&&{className:T},...E&&{onClick:E},...D&&{onBlur:D},...O&&{onFocus:O},...k&&{onMouseEnter:k},...A&&{onMouseLeave:A},...j&&{onTouchStart:j}};let Q=e=>{if(C||Y!==`intent`)return;if(!X){Z();return}let t=e.currentTarget;if(m.has(t))return;let n=setTimeout(()=>{m.delete(t),Z()},X);m.set(t,n)},ke=e=>{C||Y!==`intent`||Z()},$=e=>{if(C||!Y||!X)return;let t=e.currentTarget,n=m.get(t);n&&(clearTimeout(n),m.delete(t))};return{...N,...U,...W,href:B?.href,ref:l,onClick:h([E,Oe]),onBlur:h([D,$]),onFocus:h([O,Q]),onMouseEnter:h([k,Q]),onMouseLeave:h([A,$]),onTouchStart:h([j,ke]),disabled:!!C,target:S,...K&&{style:K},...G&&{className:G},...C&&oe,...H&&se,...P&&De&&ce}}var p={},ae={className:`active`},oe={role:`link`,"aria-disabled":!0},se={"data-status":`active`,"aria-current":`page`},ce={"data-transitioning":`transitioning`},m=new WeakMap,le={rootMargin:`100px`},h=e=>t=>{for(let n of e)if(n){if(t.defaultPrevented)return;n(t)}};function ue(e,t,n,r){if(!r)return t?{href:e,external:!0}:{href:n.createHref(e)||`/`,external:!1}}function de(e){if(typeof e!=`string`)return!1;let t=e.charCodeAt(0);return t===47?e.charCodeAt(1)!==47:t===46}var g=u.forwardRef((e,t)=>{let{_asChild:n,...r}=e,{type:ee,...i}=f(r,t),a=typeof r.children==`function`?r.children({isActive:i[`data-status`]===`active`}):r.children;if(!n){let{disabled:e,...t}=i;return u.createElement(`a`,t,a)}return u.createElement(n,i,a)});function fe(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}export{g as t}; \ No newline at end of file +import{a as e,n as t,r as n}from"./compiler-runtime.js";import{H as r,M as i,N as a,V as o,i as ee,k as te,p as s,s as ne,t as re,u as ie}from"./useStore.js";import{Xt as c}from"./awsClient.js";var ae=`Error preloading route! ☝️`,l=e(n(),1);t();var oe=e(c(),1);function u(e,t){let n=ee(),c=o(t),{activeProps:u,inactiveProps:h,activeOptions:g,to:_,preload:me,preloadDelay:he,hashScrollIntoView:ge,replace:_e,startTransition:v,resetScroll:y,viewTransition:b,children:x,target:S,disabled:C,style:w,className:T,onClick:E,onBlur:D,onFocus:O,onMouseEnter:k,onMouseLeave:A,onTouchStart:j,ignoreBlocker:M,params:ve,search:ye,hash:be,state:xe,mask:Se,reloadDocument:Ce,unsafeRelative:we,from:Te,_fromLocation:Ee,...N}=e,P=ne(),F=l.useMemo(()=>e,[n,e.from,e._fromLocation,e.hash,e.to,e.search,e.params,e.state,e.mask,e.unsafeRelative]),I=re(n.stores.location,e=>e,(e,t)=>e.href===t.href),L=l.useMemo(()=>{let e={_fromLocation:I,...F};return n.buildLocation(e)},[n,I,F]),R=L.maskedLocation?L.maskedLocation.publicHref:L.publicHref,z=L.maskedLocation?L.maskedLocation.external:L.external,B=l.useMemo(()=>de(R,z,n.history,C),[C,z,R,n.history]),V=l.useMemo(()=>{if(B?.external)return a(B.href,n.protocolAllowlist)?void 0:B.href;if(!fe(_)&&!(typeof _!=`string`||_.indexOf(`:`)===-1))try{return new URL(_),a(_,n.protocolAllowlist)?void 0:_}catch{}},[_,B,n.protocolAllowlist]),H=l.useMemo(()=>{if(V)return!1;if(g?.exact){if(!ie(I.pathname,L.pathname,n.basepath))return!1}else{let e=s(I.pathname,n.basepath),t=s(L.pathname,n.basepath);if(!(e.startsWith(t)&&(e.length===t.length||e[t.length]===`/`)))return!1}return(g?.includeSearch??!0)&&!te(I.search,L.search,{partial:!g?.exact,ignoreUndefined:!g?.explicitUndefined})?!1:g?.includeHash?P&&I.hash===L.hash:!0},[g?.exact,g?.explicitUndefined,g?.includeHash,g?.includeSearch,I,V,P,L.hash,L.pathname,L.search,n.basepath]),U=H?i(u,{})??se:d,W=H?d:i(h,{})??d,G=[T,U.className,W.className].filter(Boolean).join(` `),K=(w||U.style||W.style)&&{...w,...U.style,...W.style},[De,q]=l.useState(!1),J=l.useRef(!1),Y=e.reloadDocument||V?!1:me??n.options.defaultPreload,X=he??n.options.defaultPreloadDelay??0,Z=l.useCallback(()=>{n.preloadRoute({...F,_builtLocation:L}).catch(e=>{console.warn(e),console.warn(ae)})},[n,F,L]);r(c,l.useCallback(e=>{e?.isIntersecting&&Z()},[Z]),p,{disabled:!!C||Y!==`viewport`}),l.useEffect(()=>{J.current||!C&&Y===`render`&&(Z(),J.current=!0)},[C,Z,Y]);let Oe=e=>{let t=e.currentTarget.getAttribute(`target`),r=S===void 0?t:S;if(!C&&!pe(e)&&!e.defaultPrevented&&(!r||r===`_self`)&&e.button===0){e.preventDefault(),(0,oe.flushSync)(()=>{q(!0)});let t=n.subscribe(`onResolved`,()=>{t(),q(!1)});n.navigate({...F,replace:_e,resetScroll:y,hashScrollIntoView:ge,startTransition:v,viewTransition:b,ignoreBlocker:M})}};if(V)return{...N,ref:c,href:V,...x&&{children:x},...S&&{target:S},...C&&{disabled:C},...w&&{style:w},...T&&{className:T},...E&&{onClick:E},...D&&{onBlur:D},...O&&{onFocus:O},...k&&{onMouseEnter:k},...A&&{onMouseLeave:A},...j&&{onTouchStart:j}};let Q=e=>{if(C||Y!==`intent`)return;if(!X){Z();return}let t=e.currentTarget;if(f.has(t))return;let n=setTimeout(()=>{f.delete(t),Z()},X);f.set(t,n)},ke=e=>{C||Y!==`intent`||Z()},$=e=>{if(C||!Y||!X)return;let t=e.currentTarget,n=f.get(t);n&&(clearTimeout(n),f.delete(t))};return{...N,...U,...W,href:B?.href,ref:c,onClick:m([E,Oe]),onBlur:m([D,$]),onFocus:m([O,Q]),onMouseEnter:m([k,Q]),onMouseLeave:m([A,$]),onTouchStart:m([j,ke]),disabled:!!C,target:S,...K&&{style:K},...G&&{className:G},...C&&ce,...H&&le,...P&&De&&ue}}var d={},se={className:`active`},ce={role:`link`,"aria-disabled":!0},le={"data-status":`active`,"aria-current":`page`},ue={"data-transitioning":`transitioning`},f=new WeakMap,p={rootMargin:`100px`},m=e=>t=>{for(let n of e)if(n){if(t.defaultPrevented)return;n(t)}};function de(e,t,n,r){if(!r)return t?{href:e,external:!0}:{href:n.createHref(e)||`/`,external:!1}}function fe(e){if(typeof e!=`string`)return!1;let t=e.charCodeAt(0);return t===47?e.charCodeAt(1)!==47:t===46}var h=l.forwardRef((e,t)=>{let{_asChild:n,...r}=e,{type:i,...a}=u(r,t),o=typeof r.children==`function`?r.children({isActive:a[`data-status`]===`active`}):r.children;if(!n){let{disabled:e,...t}=a;return l.createElement(`a`,t,o)}return l.createElement(n,a,o)});function pe(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}export{h as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/login.js b/spinifex/services/spinifexui/frontend/dist/assets/login.js index e3de80bfe..ccb4f71b0 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/login.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/login.js @@ -1 +1 @@ -import{a as e,n as t,r as n,t as r}from"./compiler-runtime.js";import{t as i}from"./useNavigate.js";import{n as a,t as o}from"./awsClient.js";import{f as s,m as c,n as l}from"./dist.js";import{C as u,b as d,x as f}from"./SignatureV4.js";import{i as p,o as m,r as h,t as g}from"./button.js";import{i as _}from"./separator.js";import{V as v,m as y,t as b,u as x}from"./createBaseUIEventDetails.js";import{a as S,c as C,i as w,l as T,n as E,r as D,s as O,t as k}from"./useTransitionStatus.js";import{t as A}from"./DescribeInstancesCommand.js";import{N as j}from"./index.js";import{i as M,n as N,r as P,t as F}from"./field.js";import{r as I,t as L}from"./zod.js";import{a as ee,o as te,r as ne,t as R}from"./card.js";var z=e(n());function B(e){let{open:t,defaultOpen:n,onOpenChange:r,disabled:i}=e,a=t!==void 0,[o,s]=_({controlled:t,default:n,name:`Collapsible`,state:`open`}),{mounted:c,setMounted:l,transitionStatus:u}=k(o,!0,!0),[d,f]=z.useState(o),[{height:h,width:g},x]=z.useState({height:void 0,width:void 0}),S=v(),[C,w]=z.useState(),T=C??S,[E,O]=z.useState(!1),[A,j]=z.useState(!1),M=z.useRef(null),N=z.useRef(null),P=z.useRef(null),F=z.useRef(null),I=D(F,!1),L=m(e=>{let t=!o,n=b(y,e.nativeEvent);if(r(t,n),n.isCanceled)return;let i=F.current;N.current===`css-animation`&&i!=null&&i.style.removeProperty(`animation-name`),!E&&!A&&(N.current!=null&&N.current!==`css-animation`&&!c&&t&&l(!0),N.current===`css-animation`&&(!d&&t&&f(!0),!c&&t&&l(!0))),s(t),N.current===`none`&&c&&!t&&l(!1)});return p(()=>{a&&N.current===`none`&&!A&&!o&&l(!1)},[a,A,o,t,l]),z.useMemo(()=>({abortControllerRef:M,animationTypeRef:N,disabled:i,handleTrigger:L,height:h,mounted:c,open:o,panelId:T,panelRef:F,runOnceAnimationsFinish:I,setDimensions:x,setHiddenUntilFound:O,setKeepMounted:j,setMounted:l,setOpen:s,setPanelIdState:w,setVisible:f,transitionDimensionRef:P,transitionStatus:u,visible:d,width:g}),[M,N,i,L,h,c,o,T,F,I,x,O,j,l,s,f,P,u,d,g])}var V=z.createContext(void 0);function H(){let e=z.useContext(V);if(e===void 0)throw Error(c(15));return e}var U=function(e){return e.open=`data-open`,e.closed=`data-closed`,e[e.startingStyle=w.startingStyle]=`startingStyle`,e[e.endingStyle=w.endingStyle]=`endingStyle`,e}({}),W=function(e){return e.panelOpen=`data-panel-open`,e}({}),G={[U.open]:``},K={[U.closed]:``},q={open(e){return e?{[W.panelOpen]:``}:null}},J={open(e){return e?G:K},...S},Y=t(),X=z.forwardRef(function(e,t){let{render:n,className:r,defaultOpen:i=!1,disabled:a=!1,onOpenChange:o,open:s,...c}=e,u=m(o),d=B({open:s,defaultOpen:i,onOpenChange:u,disabled:a}),f=z.useMemo(()=>({open:d.open,disabled:d.disabled,transitionStatus:d.transitionStatus}),[d.open,d.disabled,d.transitionStatus]),p=z.useMemo(()=>({...d,onOpenChange:u,state:f}),[d,u,f]),h=l(`div`,e,{state:f,ref:t,props:c,stateAttributesMapping:J});return(0,Y.jsx)(V.Provider,{value:p,children:h})}),Z={...q,...S},re=z.forwardRef(function(e,t){let{panelId:n,open:r,handleTrigger:i,state:a,disabled:o}=H(),{className:s,disabled:c=o,id:u,render:d,nativeButton:f=!0,...p}=e,{getButtonProps:m,buttonRef:g}=h({disabled:c,focusableWhenDisabled:!0,native:f}),_=z.useMemo(()=>({"aria-controls":r?n:void 0,"aria-expanded":r,onClick:i}),[n,r,i]);return l(`button`,e,{state:a,ref:[t,g],props:[_,p,m],stateAttributesMapping:Z})}),ie=function(e){return e.disabled=`data-disabled`,e.orientation=`data-orientation`,e}({});function ae(e){let{abortControllerRef:t,animationTypeRef:n,externalRef:r,height:i,hiddenUntilFound:a,keepMounted:o,id:c,mounted:l,onOpenChange:u,open:d,panelRef:f,runOnceAnimationsFinish:h,setDimensions:g,setMounted:_,setOpen:v,setVisible:y,transitionDimensionRef:S,visible:w,width:E}=e,D=z.useRef(!1),k=z.useRef(null),A=z.useRef(d),j=z.useRef(d),M=C(),N=z.useMemo(()=>n.current===`css-animation`?!w:!d&&!l,[d,l,w,n]),P=s(r,f,m(e=>{if(!e)return;if(n.current==null||S.current==null){let t=getComputedStyle(e),r=t.animationName!==`none`&&t.animationName!==``,i=t.transitionDuration!==`0s`&&t.transitionDuration!==``;r&&i||(t.animationName===`none`&&t.transitionDuration!==`0s`?n.current=`css-transition`:t.animationName!==`none`&&t.transitionDuration===`0s`?n.current=`css-animation`:n.current=`none`),e.getAttribute(ie.orientation)===`horizontal`||t.transitionProperty.indexOf(`width`)>-1?S.current=`width`:S.current=`height`}if(n.current!==`css-transition`)return;(i===void 0||E===void 0)&&(g({height:e.scrollHeight,width:e.scrollWidth}),j.current&&e.style.setProperty(`transition-duration`,`0s`));let t=-1,r=-1;return t=O.request(()=>{j.current=!1,r=O.request(()=>{setTimeout(()=>{e.style.removeProperty(`transition-duration`)})})}),()=>{O.cancel(t),O.cancel(r)}}));return p(()=>{if(n.current!==`css-transition`)return;let e=f.current;if(!e)return;let r=-1;if(t.current!=null&&(t.current.abort(),t.current=null),d){let t={"justify-content":e.style.justifyContent,"align-items":e.style.alignItems,"align-content":e.style.alignContent,"justify-items":e.style.justifyItems};Object.keys(t).forEach(t=>{e.style.setProperty(t,`initial`,`important`)}),!j.current&&!o&&e.setAttribute(U.startingStyle,``),g({height:e.scrollHeight,width:e.scrollWidth}),r=O.request(()=>{Object.entries(t).forEach(([t,n])=>{n===``?e.style.removeProperty(t):e.style.setProperty(t,n)})})}else{if(e.scrollHeight===0&&e.scrollWidth===0)return;g({height:e.scrollHeight,width:e.scrollWidth});let n=new AbortController;t.current=n;let r=n.signal,i=null,a=U.endingStyle;return i=new MutationObserver(o=>{o.some(e=>e.type===`attributes`&&e.attributeName===a)&&(i?.disconnect(),i=null,h(()=>{g({height:0,width:0}),e.style.removeProperty(`content-visibility`),_(!1),t.current===n&&(t.current=null)},r))}),i.observe(e,{attributes:!0,attributeFilter:[a]}),()=>{i?.disconnect(),M.cancel(),t.current===n&&(n.abort(),t.current=null)}}return()=>{O.cancel(r)}},[t,n,M,a,o,l,d,f,h,g,_]),p(()=>{if(n.current!==`css-animation`)return;let e=f.current;e&&(k.current=e.style.animationName||k.current,e.style.setProperty(`animation-name`,`none`),g({height:e.scrollHeight,width:e.scrollWidth}),!A.current&&!D.current&&e.style.removeProperty(`animation-name`),d?(t.current!=null&&(t.current.abort(),t.current=null),_(!0),y(!0)):(t.current=new AbortController,h(()=>{_(!1),y(!1),t.current=null},t.current.signal)))},[t,n,d,f,h,g,_,y,w]),T(()=>{let e=O.request(()=>{A.current=!1});return()=>O.cancel(e)}),p(()=>{if(!a)return;let e=f.current;if(!e)return;let t=-1,n=-1;return d&&D.current&&(e.style.transitionDuration=`0s`,g({height:e.scrollHeight,width:e.scrollWidth}),t=O.request(()=>{D.current=!1,n=O.request(()=>{setTimeout(()=>{e.style.removeProperty(`transition-duration`)})})})),()=>{O.cancel(t),O.cancel(n)}},[a,d,f,g]),p(()=>{let e=f.current;e&&a&&N&&(e.setAttribute(`hidden`,`until-found`),n.current===`css-transition`&&e.setAttribute(U.startingStyle,``))},[a,N,n,f]),z.useEffect(function(){let e=f.current;if(!e)return;function t(e){D.current=!0,v(!0),u(!0,b(x,e))}return e.addEventListener(`beforematch`,t),()=>{e.removeEventListener(`beforematch`,t)}},[u,f,v]),z.useMemo(()=>({props:{hidden:N,id:c,ref:P}}),[N,c,P])}var Q=function(e){return e.collapsiblePanelHeight=`--collapsible-panel-height`,e.collapsiblePanelWidth=`--collapsible-panel-width`,e}({}),oe=z.forwardRef(function(e,t){let{className:n,hiddenUntilFound:r,keepMounted:i,render:a,id:o,...s}=e,{abortControllerRef:c,animationTypeRef:u,height:d,mounted:f,onOpenChange:m,open:h,panelId:g,panelRef:_,runOnceAnimationsFinish:v,setDimensions:y,setHiddenUntilFound:b,setKeepMounted:x,setMounted:S,setPanelIdState:C,setOpen:w,setVisible:T,state:D,transitionDimensionRef:O,visible:k,width:A,transitionStatus:j}=H(),M=r??!1,N=i??!1;p(()=>{if(o)return C(o),()=>{C(void 0)}},[o,C]),p(()=>{b(M)},[b,M]),p(()=>{x(N)},[x,N]);let{props:P}=ae({abortControllerRef:c,animationTypeRef:u,externalRef:t,height:d,hiddenUntilFound:M,id:g,keepMounted:N,mounted:f,onOpenChange:m,open:h,panelRef:_,runOnceAnimationsFinish:v,setDimensions:y,setMounted:S,setOpen:w,setVisible:T,transitionDimensionRef:O,visible:k,width:A});E({open:h&&j===`idle`,ref:_,onComplete(){h&&y({height:void 0,width:void 0})}});let F=l(`div`,e,{state:z.useMemo(()=>({...D,transitionStatus:j}),[D,j]),ref:[t,_],props:[P,{style:{[Q.collapsiblePanelHeight]:d===void 0?`auto`:`${d}px`,[Q.collapsiblePanelWidth]:A===void 0?`auto`:`${A}px`}},s],stateAttributesMapping:J});return N||M||!N&&f?F:null}),$=r();function se(e){let t=(0,$.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,Y.jsx)(X,{"data-slot":`collapsible`,...n}),t[2]=n,t[3]=r),r}function ce(e){let t=(0,$.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,Y.jsx)(re,{"data-slot":`collapsible-trigger`,...n}),t[2]=n,t[3]=r),r}function le(e){let t=(0,$.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,Y.jsx)(oe,{"data-slot":`collapsible-content`,...n}),t[2]=n,t[3]=r),r}function ue(){let e=(0,$.c)(47),t=i(),[n,r]=(0,z.useState)(null),s;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(s={resolver:L(d)},e[0]=s):s=e[0];let{register:c,handleSubmit:l,formState:p}=I(s),{errors:m,isSubmitting:h}=p,_;e[1]===t?_=e[2]:(_=async function(e){r(null),o(),u(e);try{await a().send(new A({})),t({to:`/`})}catch{f(),o(),r(`Invalid credentials. Please check your Access Key ID and Secret Access Key.`)}},e[1]=t,e[2]=_);let v=_,y;e[3]===Symbol.for(`react.memo_cache_sentinel`)?(y=(0,Y.jsx)(ee,{children:(0,Y.jsx)(te,{children:`AWS Credentials`})}),e[3]=y):y=e[3];let b;e[4]===n?b=e[5]:(b=n&&(0,Y.jsx)(`p`,{className:`mb-4 rounded-md bg-destructive/10 p-3 text-sm text-destructive`,children:n}),e[4]=n,e[5]=b);let x;e[6]!==l||e[7]!==v?(x=l(v),e[6]=l,e[7]=v,e[8]=x):x=e[8];let S;e[9]===Symbol.for(`react.memo_cache_sentinel`)?(S=(0,Y.jsx)(M,{children:(0,Y.jsx)(`label`,{htmlFor:`accessKeyId`,children:`Access Key ID`})}),e[9]=S):S=e[9];let C=!!m.accessKeyId,w;e[10]===c?w=e[11]:(w=c(`accessKeyId`),e[10]=c,e[11]=w);let T;e[12]!==C||e[13]!==w?(T=(0,Y.jsx)(j,{"aria-invalid":C,autoComplete:`username`,id:`accessKeyId`,placeholder:`AKIAIOSFODNN7EXAMPLE`,...w}),e[12]=C,e[13]=w,e[14]=T):T=e[14];let E;e[15]===m.accessKeyId?E=e[16]:(E=(0,Y.jsx)(N,{errors:[m.accessKeyId]}),e[15]=m.accessKeyId,e[16]=E);let D;e[17]!==E||e[18]!==T?(D=(0,Y.jsxs)(F,{children:[S,T,E]}),e[17]=E,e[18]=T,e[19]=D):D=e[19];let O;e[20]===Symbol.for(`react.memo_cache_sentinel`)?(O=(0,Y.jsx)(M,{children:(0,Y.jsx)(`label`,{htmlFor:`secretAccessKey`,children:`Secret Access Key`})}),e[20]=O):O=e[20];let k=!!m.secretAccessKey,B;e[21]===c?B=e[22]:(B=c(`secretAccessKey`),e[21]=c,e[22]=B);let V;e[23]!==k||e[24]!==B?(V=(0,Y.jsx)(j,{"aria-invalid":k,autoComplete:`current-password`,id:`secretAccessKey`,placeholder:`wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY`,type:`password`,...B}),e[23]=k,e[24]=B,e[25]=V):V=e[25];let H;e[26]===m.secretAccessKey?H=e[27]:(H=(0,Y.jsx)(N,{errors:[m.secretAccessKey]}),e[26]=m.secretAccessKey,e[27]=H);let U;e[28]!==V||e[29]!==H?(U=(0,Y.jsxs)(F,{children:[O,V,H]}),e[28]=V,e[29]=H,e[30]=U):U=e[30];let W=h?`Signing in...`:`Sign In`,G;e[31]!==h||e[32]!==W?(G=(0,Y.jsx)(g,{className:`w-full`,disabled:h,type:`submit`,children:W}),e[31]=h,e[32]=W,e[33]=G):G=e[33];let K;e[34]!==D||e[35]!==U||e[36]!==G?(K=(0,Y.jsxs)(P,{children:[D,U,G]}),e[34]=D,e[35]=U,e[36]=G,e[37]=K):K=e[37];let q;e[38]!==K||e[39]!==x?(q=(0,Y.jsx)(`form`,{onSubmit:x,children:K}),e[38]=K,e[39]=x,e[40]=q):q=e[40];let J;e[41]!==q||e[42]!==b?(J=(0,Y.jsxs)(R,{children:[y,(0,Y.jsxs)(ne,{children:[b,q]})]}),e[41]=q,e[42]=b,e[43]=J):J=e[43];let X;e[44]===Symbol.for(`react.memo_cache_sentinel`)?(X=(0,Y.jsx)(de,{}),e[44]=X):X=e[44];let Z;return e[45]===J?Z=e[46]:(Z=(0,Y.jsx)(`div`,{className:`flex flex-1 items-center justify-center`,children:(0,Y.jsxs)(`div`,{className:`flex w-full max-w-sm flex-col gap-4`,children:[J,X]})}),e[45]=J,e[46]=Z),Z}function de(){let e=(0,$.c)(4),t,n;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,Y.jsxs)(`div`,{children:[(0,Y.jsx)(`p`,{className:`text-sm font-medium`,children:`Install Local Certificate Authority`}),(0,Y.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:`To avoid browser certificate warnings, download and install the Spinifex CA as a trusted root on your OS.`})]}),n=(0,Y.jsx)(`a`,{className:`inline-flex h-8 w-full items-center justify-center rounded-md border border-input bg-background px-3 text-sm font-medium hover:bg-accent hover:text-accent-foreground`,download:`spinifex-ca.pem`,href:`/api/ca.pem`,children:`Download CA Certificate`}),e[0]=t,e[1]=n):(t=e[0],n=e[1]);let r;e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,Y.jsx)(ce,{className:`cursor-pointer text-xs text-muted-foreground underline-offset-4 hover:underline`,children:`Installation instructions`}),e[2]=r):r=e[2];let i;return e[3]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,Y.jsx)(R,{className:`border-muted bg-muted/30`,children:(0,Y.jsx)(ne,{className:`pt-4 pb-4`,children:(0,Y.jsxs)(`div`,{className:`flex flex-col gap-3`,children:[t,n,(0,Y.jsxs)(se,{children:[r,(0,Y.jsx)(le,{children:(0,Y.jsxs)(`div`,{className:`mt-2 flex flex-col gap-2 text-xs text-muted-foreground`,children:[(0,Y.jsxs)(`div`,{children:[(0,Y.jsx)(`p`,{className:`font-medium text-foreground`,children:`macOS`}),(0,Y.jsx)(`code`,{className:`mt-1 block rounded bg-muted p-2 text-[11px] break-all`,children:`sudo security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain spinifex-ca.pem`})]}),(0,Y.jsxs)(`div`,{children:[(0,Y.jsx)(`p`,{className:`font-medium text-foreground`,children:`Windows`}),(0,Y.jsx)(`p`,{children:`Double-click the file → Install Certificate → Local Machine → Trusted Root Certification Authorities`})]}),(0,Y.jsxs)(`div`,{children:[(0,Y.jsx)(`p`,{className:`font-medium text-foreground`,children:`Linux`}),(0,Y.jsx)(`code`,{className:`mt-1 block rounded bg-muted p-2 text-[11px] break-all`,children:`sudo cp spinifex-ca.pem /usr/local/share/ca-certificates/spinifex-ca.crt && sudo update-ca-certificates`})]})]})})]})]})})}),e[3]=i):i=e[3],i}export{ue as component}; \ No newline at end of file +import{a as e,n as t,r as n,t as r}from"./compiler-runtime.js";import{n as i,t as a}from"./awsClient.js";import{f as o,m as s,n as c}from"./dist.js";import{C as l,b as u,x as d}from"./SignatureV4.js";import{i as f,o as p,r as m,t as h}from"./button.js";import{i as g}from"./separator.js";import{V as _,m as v,t as y,u as b}from"./createBaseUIEventDetails.js";import{a as x,c as S,i as C,l as w,n as T,r as E,s as D,t as O}from"./useTransitionStatus.js";import{t as k}from"./DescribeInstancesCommand.js";import{N as A}from"./index.js";import{i as j,n as M,r as N,t as P}from"./field.js";import{r as F,t as I}from"./zod.js";import{a as L,o as R,r as z,t as B}from"./card.js";var V=e(n());function H(e){let{open:t,defaultOpen:n,onOpenChange:r,disabled:i}=e,a=t!==void 0,[o,s]=g({controlled:t,default:n,name:`Collapsible`,state:`open`}),{mounted:c,setMounted:l,transitionStatus:u}=O(o,!0,!0),[d,m]=V.useState(o),[{height:h,width:b},x]=V.useState({height:void 0,width:void 0}),S=_(),[C,w]=V.useState(),T=C??S,[D,k]=V.useState(!1),[A,j]=V.useState(!1),M=V.useRef(null),N=V.useRef(null),P=V.useRef(null),F=V.useRef(null),I=E(F,!1),L=p(e=>{let t=!o,n=y(v,e.nativeEvent);if(r(t,n),n.isCanceled)return;let i=F.current;N.current===`css-animation`&&i!=null&&i.style.removeProperty(`animation-name`),!D&&!A&&(N.current!=null&&N.current!==`css-animation`&&!c&&t&&l(!0),N.current===`css-animation`&&(!d&&t&&m(!0),!c&&t&&l(!0))),s(t),N.current===`none`&&c&&!t&&l(!1)});return f(()=>{a&&N.current===`none`&&!A&&!o&&l(!1)},[a,A,o,t,l]),V.useMemo(()=>({abortControllerRef:M,animationTypeRef:N,disabled:i,handleTrigger:L,height:h,mounted:c,open:o,panelId:T,panelRef:F,runOnceAnimationsFinish:I,setDimensions:x,setHiddenUntilFound:k,setKeepMounted:j,setMounted:l,setOpen:s,setPanelIdState:w,setVisible:m,transitionDimensionRef:P,transitionStatus:u,visible:d,width:b}),[M,N,i,L,h,c,o,T,F,I,x,k,j,l,s,m,P,u,d,b])}var U=V.createContext(void 0);function W(){let e=V.useContext(U);if(e===void 0)throw Error(s(15));return e}var G=function(e){return e.open=`data-open`,e.closed=`data-closed`,e[e.startingStyle=C.startingStyle]=`startingStyle`,e[e.endingStyle=C.endingStyle]=`endingStyle`,e}({}),K=function(e){return e.panelOpen=`data-panel-open`,e}({}),q={[G.open]:``},J={[G.closed]:``},Y={open(e){return e?{[K.panelOpen]:``}:null}},X={open(e){return e?q:J},...x},Z=t(),ee=V.forwardRef(function(e,t){let{render:n,className:r,defaultOpen:i=!1,disabled:a=!1,onOpenChange:o,open:s,...l}=e,u=p(o),d=H({open:s,defaultOpen:i,onOpenChange:u,disabled:a}),f=V.useMemo(()=>({open:d.open,disabled:d.disabled,transitionStatus:d.transitionStatus}),[d.open,d.disabled,d.transitionStatus]),m=V.useMemo(()=>({...d,onOpenChange:u,state:f}),[d,u,f]),h=c(`div`,e,{state:f,ref:t,props:l,stateAttributesMapping:X});return(0,Z.jsx)(U.Provider,{value:m,children:h})}),te={...Y,...x},ne=V.forwardRef(function(e,t){let{panelId:n,open:r,handleTrigger:i,state:a,disabled:o}=W(),{className:s,disabled:l=o,id:u,render:d,nativeButton:f=!0,...p}=e,{getButtonProps:h,buttonRef:g}=m({disabled:l,focusableWhenDisabled:!0,native:f}),_=V.useMemo(()=>({"aria-controls":r?n:void 0,"aria-expanded":r,onClick:i}),[n,r,i]);return c(`button`,e,{state:a,ref:[t,g],props:[_,p,h],stateAttributesMapping:te})}),re=function(e){return e.disabled=`data-disabled`,e.orientation=`data-orientation`,e}({});function ie(e){let{abortControllerRef:t,animationTypeRef:n,externalRef:r,height:i,hiddenUntilFound:a,keepMounted:s,id:c,mounted:l,onOpenChange:u,open:d,panelRef:m,runOnceAnimationsFinish:h,setDimensions:g,setMounted:_,setOpen:v,setVisible:x,transitionDimensionRef:C,visible:T,width:E}=e,O=V.useRef(!1),k=V.useRef(null),A=V.useRef(d),j=V.useRef(d),M=S(),N=V.useMemo(()=>n.current===`css-animation`?!T:!d&&!l,[d,l,T,n]),P=o(r,m,p(e=>{if(!e)return;if(n.current==null||C.current==null){let t=getComputedStyle(e),r=t.animationName!==`none`&&t.animationName!==``,i=t.transitionDuration!==`0s`&&t.transitionDuration!==``;r&&i||(t.animationName===`none`&&t.transitionDuration!==`0s`?n.current=`css-transition`:t.animationName!==`none`&&t.transitionDuration===`0s`?n.current=`css-animation`:n.current=`none`),e.getAttribute(re.orientation)===`horizontal`||t.transitionProperty.indexOf(`width`)>-1?C.current=`width`:C.current=`height`}if(n.current!==`css-transition`)return;(i===void 0||E===void 0)&&(g({height:e.scrollHeight,width:e.scrollWidth}),j.current&&e.style.setProperty(`transition-duration`,`0s`));let t=-1,r=-1;return t=D.request(()=>{j.current=!1,r=D.request(()=>{setTimeout(()=>{e.style.removeProperty(`transition-duration`)})})}),()=>{D.cancel(t),D.cancel(r)}}));return f(()=>{if(n.current!==`css-transition`)return;let e=m.current;if(!e)return;let r=-1;if(t.current!=null&&(t.current.abort(),t.current=null),d){let t={"justify-content":e.style.justifyContent,"align-items":e.style.alignItems,"align-content":e.style.alignContent,"justify-items":e.style.justifyItems};Object.keys(t).forEach(t=>{e.style.setProperty(t,`initial`,`important`)}),!j.current&&!s&&e.setAttribute(G.startingStyle,``),g({height:e.scrollHeight,width:e.scrollWidth}),r=D.request(()=>{Object.entries(t).forEach(([t,n])=>{n===``?e.style.removeProperty(t):e.style.setProperty(t,n)})})}else{if(e.scrollHeight===0&&e.scrollWidth===0)return;g({height:e.scrollHeight,width:e.scrollWidth});let n=new AbortController;t.current=n;let r=n.signal,i=null,a=G.endingStyle;return i=new MutationObserver(o=>{o.some(e=>e.type===`attributes`&&e.attributeName===a)&&(i?.disconnect(),i=null,h(()=>{g({height:0,width:0}),e.style.removeProperty(`content-visibility`),_(!1),t.current===n&&(t.current=null)},r))}),i.observe(e,{attributes:!0,attributeFilter:[a]}),()=>{i?.disconnect(),M.cancel(),t.current===n&&(n.abort(),t.current=null)}}return()=>{D.cancel(r)}},[t,n,M,a,s,l,d,m,h,g,_]),f(()=>{if(n.current!==`css-animation`)return;let e=m.current;e&&(k.current=e.style.animationName||k.current,e.style.setProperty(`animation-name`,`none`),g({height:e.scrollHeight,width:e.scrollWidth}),!A.current&&!O.current&&e.style.removeProperty(`animation-name`),d?(t.current!=null&&(t.current.abort(),t.current=null),_(!0),x(!0)):(t.current=new AbortController,h(()=>{_(!1),x(!1),t.current=null},t.current.signal)))},[t,n,d,m,h,g,_,x,T]),w(()=>{let e=D.request(()=>{A.current=!1});return()=>D.cancel(e)}),f(()=>{if(!a)return;let e=m.current;if(!e)return;let t=-1,n=-1;return d&&O.current&&(e.style.transitionDuration=`0s`,g({height:e.scrollHeight,width:e.scrollWidth}),t=D.request(()=>{O.current=!1,n=D.request(()=>{setTimeout(()=>{e.style.removeProperty(`transition-duration`)})})})),()=>{D.cancel(t),D.cancel(n)}},[a,d,m,g]),f(()=>{let e=m.current;e&&a&&N&&(e.setAttribute(`hidden`,`until-found`),n.current===`css-transition`&&e.setAttribute(G.startingStyle,``))},[a,N,n,m]),V.useEffect(function(){let e=m.current;if(!e)return;function t(e){O.current=!0,v(!0),u(!0,y(b,e))}return e.addEventListener(`beforematch`,t),()=>{e.removeEventListener(`beforematch`,t)}},[u,m,v]),V.useMemo(()=>({props:{hidden:N,id:c,ref:P}}),[N,c,P])}var Q=function(e){return e.collapsiblePanelHeight=`--collapsible-panel-height`,e.collapsiblePanelWidth=`--collapsible-panel-width`,e}({}),ae=V.forwardRef(function(e,t){let{className:n,hiddenUntilFound:r,keepMounted:i,render:a,id:o,...s}=e,{abortControllerRef:l,animationTypeRef:u,height:d,mounted:p,onOpenChange:m,open:h,panelId:g,panelRef:_,runOnceAnimationsFinish:v,setDimensions:y,setHiddenUntilFound:b,setKeepMounted:x,setMounted:S,setPanelIdState:C,setOpen:w,setVisible:E,state:D,transitionDimensionRef:O,visible:k,width:A,transitionStatus:j}=W(),M=r??!1,N=i??!1;f(()=>{if(o)return C(o),()=>{C(void 0)}},[o,C]),f(()=>{b(M)},[b,M]),f(()=>{x(N)},[x,N]);let{props:P}=ie({abortControllerRef:l,animationTypeRef:u,externalRef:t,height:d,hiddenUntilFound:M,id:g,keepMounted:N,mounted:p,onOpenChange:m,open:h,panelRef:_,runOnceAnimationsFinish:v,setDimensions:y,setMounted:S,setOpen:w,setVisible:E,transitionDimensionRef:O,visible:k,width:A});T({open:h&&j===`idle`,ref:_,onComplete(){h&&y({height:void 0,width:void 0})}});let F=c(`div`,e,{state:V.useMemo(()=>({...D,transitionStatus:j}),[D,j]),ref:[t,_],props:[P,{style:{[Q.collapsiblePanelHeight]:d===void 0?`auto`:`${d}px`,[Q.collapsiblePanelWidth]:A===void 0?`auto`:`${A}px`}},s],stateAttributesMapping:X});return N||M||!N&&p?F:null}),$=r();function oe(e){let t=(0,$.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,Z.jsx)(ee,{"data-slot":`collapsible`,...n}),t[2]=n,t[3]=r),r}function se(e){let t=(0,$.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,Z.jsx)(ne,{"data-slot":`collapsible-trigger`,...n}),t[2]=n,t[3]=r),r}function ce(e){let t=(0,$.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,Z.jsx)(ae,{"data-slot":`collapsible-content`,...n}),t[2]=n,t[3]=r),r}function le(){let[e,t]=(0,V.useState)(null),{register:n,handleSubmit:r,formState:{errors:o,isSubmitting:s}}=F({resolver:I(u)});async function c(e){t(null),a(),l(e);try{await i().send(new k({})),window.location.href=`/`}catch{d(),a(),t(`Invalid credentials. Please check your Access Key ID and Secret Access Key.`)}}return(0,Z.jsx)(`div`,{className:`flex flex-1 items-center justify-center`,children:(0,Z.jsxs)(`div`,{className:`flex w-full max-w-sm flex-col gap-4`,children:[(0,Z.jsxs)(B,{children:[(0,Z.jsx)(L,{children:(0,Z.jsx)(R,{children:`AWS Credentials`})}),(0,Z.jsxs)(z,{children:[e&&(0,Z.jsx)(`p`,{className:`mb-4 rounded-md bg-destructive/10 p-3 text-sm text-destructive`,children:e}),(0,Z.jsx)(`form`,{onSubmit:r(c),children:(0,Z.jsxs)(N,{children:[(0,Z.jsxs)(P,{children:[(0,Z.jsx)(j,{children:(0,Z.jsx)(`label`,{htmlFor:`accessKeyId`,children:`Access Key ID`})}),(0,Z.jsx)(A,{"aria-invalid":!!o.accessKeyId,autoComplete:`username`,id:`accessKeyId`,placeholder:`AKIAIOSFODNN7EXAMPLE`,...n(`accessKeyId`)}),(0,Z.jsx)(M,{errors:[o.accessKeyId]})]}),(0,Z.jsxs)(P,{children:[(0,Z.jsx)(j,{children:(0,Z.jsx)(`label`,{htmlFor:`secretAccessKey`,children:`Secret Access Key`})}),(0,Z.jsx)(A,{"aria-invalid":!!o.secretAccessKey,autoComplete:`current-password`,id:`secretAccessKey`,placeholder:`wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY`,type:`password`,...n(`secretAccessKey`)}),(0,Z.jsx)(M,{errors:[o.secretAccessKey]})]}),(0,Z.jsx)(h,{className:`w-full`,disabled:s,type:`submit`,children:s?`Signing in...`:`Sign In`})]})})]})]}),(0,Z.jsx)(ue,{})]})})}function ue(){let e=(0,$.c)(4),t,n;e[0]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`p`,{className:`text-sm font-medium`,children:`Install Local Certificate Authority`}),(0,Z.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:`To avoid browser certificate warnings, download and install the Spinifex CA as a trusted root on your OS.`})]}),n=(0,Z.jsx)(`a`,{className:`inline-flex h-8 w-full items-center justify-center rounded-md border border-input bg-background px-3 text-sm font-medium hover:bg-accent hover:text-accent-foreground`,download:`spinifex-ca.pem`,href:`/api/ca.pem`,children:`Download CA Certificate`}),e[0]=t,e[1]=n):(t=e[0],n=e[1]);let r;e[2]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,Z.jsx)(se,{className:`cursor-pointer text-xs text-muted-foreground underline-offset-4 hover:underline`,children:`Installation instructions`}),e[2]=r):r=e[2];let i;return e[3]===Symbol.for(`react.memo_cache_sentinel`)?(i=(0,Z.jsx)(B,{className:`border-muted bg-muted/30`,children:(0,Z.jsx)(z,{className:`pt-4 pb-4`,children:(0,Z.jsxs)(`div`,{className:`flex flex-col gap-3`,children:[t,n,(0,Z.jsxs)(oe,{children:[r,(0,Z.jsx)(ce,{children:(0,Z.jsxs)(`div`,{className:`mt-2 flex flex-col gap-2 text-xs text-muted-foreground`,children:[(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`p`,{className:`font-medium text-foreground`,children:`macOS`}),(0,Z.jsx)(`code`,{className:`mt-1 block rounded bg-muted p-2 text-[11px] break-all`,children:`sudo security add-trusted-cert -d -r trustRoot -k /Library/Keychains/System.keychain spinifex-ca.pem`})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`p`,{className:`font-medium text-foreground`,children:`Windows`}),(0,Z.jsx)(`p`,{children:`Double-click the file → Install Certificate → Local Machine → Trusted Root Certification Authorities`})]}),(0,Z.jsxs)(`div`,{children:[(0,Z.jsx)(`p`,{className:`font-medium text-foreground`,children:`Linux`}),(0,Z.jsx)(`code`,{className:`mt-1 block rounded bg-muted p-2 text-[11px] break-all`,children:`sudo cp spinifex-ca.pem /usr/local/share/ca-certificates/spinifex-ca.crt && sudo update-ca-certificates`})]})]})})]})]})})}),e[3]=i):i=e[3],i}export{le as component}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/s3.js b/spinifex/services/spinifexui/frontend/dist/assets/s3.js index 96389a7ec..07d643ada 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/s3.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/s3.js @@ -1,4 +1,4 @@ -import{i as e,t}from"./compiler-runtime.js";import{n}from"./QueryClientProvider.js";import{n as r}from"./error-banner.js";import{Bt as i,Gt as a,Ht as o,Jt as s,Lt as c,Rt as l,S as u,Vt as d,_ as f,a as p,b as m,c as h,g,h as _,i as v,l as y,m as b,o as x,p as S,qt as C,s as w,v as T,x as E,y as D,zt as O}from"./awsClient.js";import{_ as ee,a as k,c as A,d as j,f as te,g as M,h as ne,i as N,p as P,v as F}from"./SignatureV4.js";var I=typeof ReadableStream==`function`?ReadableStream:function(){},L=class extends I{},R=({expectedChecksum:e,checksum:t,source:n,checksumSourceLocation:r,base64Encoder:i})=>{if(!C(n))throw Error(`@smithy/util-stream: unsupported source type ${n?.constructor?.name??n} in ChecksumStream.`);let a=i??s;if(typeof TransformStream!=`function`)throw Error(`@smithy/util-stream: unable to instantiate ChecksumStream because API unavailable: ReadableStream/TransformStream.`);let o=new TransformStream({start(){},async transform(e,n){t.update(e),n.enqueue(e)},async flush(n){let i=a(await t.digest());if(e!==i){let t=Error(`Checksum mismatch: expected "${e}" but received "${i}" in response header "${r}".`);n.error(t)}else n.terminate()}});n.pipeThrough(o);let c=o.readable;return Object.setPrototypeOf(c,L.prototype),c},re=class{allocByteArray;byteLength=0;byteArrays=[];constructor(e){this.allocByteArray=e}push(e){this.byteArrays.push(e),this.byteLength+=e.byteLength}flush(){if(this.byteArrays.length===1){let e=this.byteArrays[0];return this.reset(),e}let e=this.allocByteArray(this.byteLength),t=0;for(let n=0;nnew Uint8Array(e))],s=-1,c=async e=>{let{value:l,done:u}=await r.read(),d=l;if(u){if(s!==-1){let t=ie(o,s);H(t)>0&&e.enqueue(t)}e.close()}else{let r=U(d,!1);if(s!==r&&(s>=0&&e.enqueue(ie(o,s)),s=r),s===-1){e.enqueue(d);return}let l=H(d);a+=l;let u=H(o[s]);if(l>=t&&u===0)e.enqueue(d);else{let r=V(o,s,d);!i&&a>t*2&&(i=!0,n?.warn(`@smithy/util-stream - stream chunk size ${l} is below threshold of ${t}, automatically buffering.`)),r>=t?e.enqueue(ie(o,s)):await c(e)}}};return new ReadableStream({pull:c})}var B=z;function V(e,t,n){switch(t){case 0:return e[0]+=n,H(e[0]);case 1:case 2:return e[t].push(n),H(e[t])}}function ie(e,t){switch(t){case 0:let n=e[0];return e[0]=``,n;case 1:case 2:return e[t].flush()}throw Error(`@smithy/util-stream - invalid index ${t} given to flush()`)}function H(e){return e?.byteLength??e?.length??0}function U(e,t=!0){return t&&typeof Buffer<`u`&&e instanceof Buffer?2:e instanceof Uint8Array?1:typeof e==`string`?0:-1}var W=(e,{requestChecksumRequired:t,requestAlgorithmMember:n,requestChecksumCalculation:r})=>{if(!n)return r===E.WHEN_SUPPORTED||t?m:void 0;if(e[n])return e[n]},G=e=>e===D.MD5?`content-md5`:`x-amz-checksum-${e.toLowerCase()}`,ae=(e,t)=>{let n=e.toLowerCase();for(let e of Object.keys(t))if(n===e.toLowerCase())return!0;return!1},oe=(e,t)=>{let n=e.toLowerCase();for(let e of Object.keys(t))if(e.toLowerCase().startsWith(n))return!0;return!1},se=e=>e!==void 0&&typeof e!=`string`&&!ArrayBuffer.isView(e)&&!N(e),ce=function(){function e(){this.crc32c=new le}return e.prototype.update=function(e){ee(e)||this.crc32c.update(F(e))},e.prototype.digest=function(){return j(this,void 0,void 0,function(){return te(this,function(e){return[2,M(this.crc32c.digest())]})})},e.prototype.reset=function(){this.crc32c=new le},e}(),le=function(){function e(){this.checksum=4294967295}return e.prototype.update=function(e){var t,n;try{for(var r=P(e),i=r.next();!i.done;i=r.next()){var a=i.value;this.checksum=this.checksum>>>8^ue[(this.checksum^a)&255]}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}return this},e.prototype.digest=function(){return(this.checksum^4294967295)>>>0},e}(),ue=ne([0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697]),de=()=>{let e=Array(8);for(let t=0;t<8;t++){let n=Array(512);for(let e=0;e<256;e++){let r=BigInt(e);for(let e=0;e<8*(t+1);e++)r&1n?r=r>>1n^11127430586519243189n:r>>=1n;n[e*2]=Number(r>>32n&4294967295n),n[e*2+1]=Number(r&4294967295n)}e[t]=new Uint32Array(n)}return e},fe,K,pe,me,he,ge,_e,ve,ye,be=()=>{fe||(fe=de(),[K,pe,me,he,ge,_e,ve,ye]=fe)},xe=class{c1=0;c2=0;constructor(){be(),this.reset()}update(e){let t=e.length,n=0,r=this.c1,i=this.c2;for(;n+8<=t;){let t=((i^e[n++])&255)<<1,a=((i>>>8^e[n++])&255)<<1,o=((i>>>16^e[n++])&255)<<1,s=((i>>>24^e[n++])&255)<<1,c=((r^e[n++])&255)<<1,l=((r>>>8^e[n++])&255)<<1,u=((r>>>16^e[n++])&255)<<1,d=((r>>>24^e[n++])&255)<<1;r=ye[t]^ve[a]^_e[o]^ge[s]^he[c]^me[l]^pe[u]^K[d],i=ye[t+1]^ve[a+1]^_e[o+1]^ge[s+1]^he[c+1]^me[l+1]^pe[u+1]^K[d+1]}for(;n>>8|(r&255)<<24)>>>0,r=r>>>8^K[t],i^=K[t+1],n++}this.c1=r,this.c2=i}async digest(){let e=this.c1^4294967295,t=this.c2^4294967295;return new Uint8Array([e>>>24,e>>>16&255,e>>>8&255,e&255,t>>>24,t>>>16&255,t>>>8&255,t&255])}reset(){this.c1=4294967295,this.c2=4294967295}},Se={CrtCrc64Nvme:null},Ce=()=>T,we=[D.CRC32,D.CRC32C,D.CRC64NVME,D.SHA1,D.SHA256],Te=[D.SHA256,D.SHA1,D.CRC32,D.CRC32C,D.CRC64NVME],Ee=(e,t)=>{let{checksumAlgorithms:n={}}=t;switch(e){case D.MD5:return n?.MD5??t.md5;case D.CRC32:return n?.CRC32??Ce();case D.CRC32C:return n?.CRC32C??ce;case D.CRC64NVME:return typeof Se.CrtCrc64Nvme==`function`?n?.CRC64NVME??Se.CrtCrc64Nvme:n?.CRC64NVME??xe;case D.SHA1:return n?.SHA1??t.sha1;case D.SHA256:return n?.SHA256??t.sha256;default:if(n?.[e])return n[e];throw Error(`The checksum algorithm "${e}" is not supported by the client. Select one of ${we}, or provide an implementation to the client constructor checksums field.`)}},De=(e,t)=>{let n=new e;return n.update(k(t||``)),n.digest()},Oe={name:`flexibleChecksumsMiddleware`,step:`build`,tags:[`BODY_CHECKSUM`],override:!0},ke=(e,t)=>(n,r)=>async i=>{if(!A.isInstance(i.request)||oe(`x-amz-checksum-`,i.request.headers))return n(i);let{request:a,input:s}=i,{body:c,headers:l}=a,{base64Encoder:u,streamHasher:d}=e,{requestChecksumRequired:f,requestAlgorithmMember:p}=t,h=await e.requestChecksumCalculation(),g=p?.name,_=p?.httpHeader;g&&!s[g]&&(h===E.WHEN_SUPPORTED||f)&&(s[g]=m,_&&(l[_]=m));let v=W(s,{requestChecksumRequired:f,requestAlgorithmMember:p?.name,requestChecksumCalculation:h}),y=c,b=l;if(v){switch(v){case D.CRC32:o(r,`FLEXIBLE_CHECKSUMS_REQ_CRC32`,`U`);break;case D.CRC32C:o(r,`FLEXIBLE_CHECKSUMS_REQ_CRC32C`,`V`);break;case D.CRC64NVME:o(r,`FLEXIBLE_CHECKSUMS_REQ_CRC64`,`W`);break;case D.SHA1:o(r,`FLEXIBLE_CHECKSUMS_REQ_SHA1`,`X`);break;case D.SHA256:o(r,`FLEXIBLE_CHECKSUMS_REQ_SHA256`,`Y`);break}let t=G(v),n=Ee(v,e);if(se(c)){let{getAwsChunkedEncodingStream:i,bodyLengthChecker:a}=e;y=i(typeof e.requestStreamBufferSize==`number`&&e.requestStreamBufferSize>=8*1024?B(c,e.requestStreamBufferSize,r.logger):c,{base64Encoder:u,bodyLengthChecker:a,checksumLocationName:t,checksumAlgorithmFn:n,streamHasher:d}),b={...l,"content-encoding":l[`content-encoding`]?`${l[`content-encoding`]},aws-chunked`:`aws-chunked`,"transfer-encoding":`chunked`,"x-amz-decoded-content-length":l[`content-length`],"x-amz-content-sha256":`STREAMING-UNSIGNED-PAYLOAD-TRAILER`,"x-amz-trailer":t},delete b[`content-length`]}else if(!ae(t,l)){let e=await De(n,c);b={...l,[t]:u(e)}}}try{return await n({...i,request:{...a,headers:b,body:y}})}catch(e){if(e instanceof Error&&e.name===`InvalidChunkSizeError`)try{e.message.endsWith(`.`)||(e.message+=`.`),e.message+=` Set [requestStreamBufferSize=number e.g. 65_536] in client constructor to instruct AWS SDK to buffer your input stream.`}catch{}throw e}},Ae={name:`flexibleChecksumsInputMiddleware`,toMiddleware:`serializerMiddleware`,relation:`before`,tags:[`BODY_CHECKSUM`],override:!0},je=(e,t)=>(n,r)=>async i=>{let a=i.input,{requestValidationModeMember:s}=t,c=await e.requestChecksumCalculation(),l=await e.responseChecksumValidation();switch(c){case E.WHEN_REQUIRED:o(r,`FLEXIBLE_CHECKSUMS_REQ_WHEN_REQUIRED`,`a`);break;case E.WHEN_SUPPORTED:o(r,`FLEXIBLE_CHECKSUMS_REQ_WHEN_SUPPORTED`,`Z`);break}switch(l){case u.WHEN_REQUIRED:o(r,`FLEXIBLE_CHECKSUMS_RES_WHEN_REQUIRED`,`c`);break;case u.WHEN_SUPPORTED:o(r,`FLEXIBLE_CHECKSUMS_RES_WHEN_SUPPORTED`,`b`);break}return s&&!a[s]&&l===u.WHEN_SUPPORTED&&(a[s]=`ENABLED`),n(i)},Me=(e=[])=>{let t=[],n=Te.length;for(let r of e){let e=Te.indexOf(r);e===-1?t[n++]=r:t[e]=r}return t.filter(Boolean)},Ne=e=>{let t=e.lastIndexOf(`-`);if(t!==-1){let n=e.slice(t+1);if(!n.startsWith(`0`)){let e=parseInt(n,10);if(!isNaN(e)&&e>=1&&e<=1e4)return!0}}return!1},Pe=async(e,{checksumAlgorithmFn:t,base64Encoder:n})=>n(await De(t,e)),Fe=async(e,{config:t,responseAlgorithms:n,logger:r})=>{let i=Me(n),{body:a,headers:o}=e;for(let n of i){let i=G(n),s=o[i];if(s){let o;try{o=Ee(n,t)}catch(e){if(n===D.CRC64NVME){r?.warn(`Skipping ${D.CRC64NVME} checksum validation: ${e.message}`);continue}throw e}let{base64Encoder:c}=t;if(se(a)){e.body=R({expectedChecksum:s,checksumSourceLocation:i,checksum:new o,source:a,base64Encoder:c});return}let l=await Pe(a,{checksumAlgorithmFn:o,base64Encoder:c});if(l===s)break;throw Error(`Checksum mismatch: expected "${l}" but received "${s}" in response header "${i}".`)}}},Ie={name:`flexibleChecksumsResponseMiddleware`,toMiddleware:`deserializerMiddleware`,relation:`after`,tags:[`BODY_CHECKSUM`],override:!0},Le=(e,t)=>(n,r)=>async i=>{if(!A.isInstance(i.request))return n(i);let a=i.input,o=await n(i),s=o.response,{requestValidationModeMember:c,responseAlgorithms:l}=t;if(c&&a[c]===`ENABLED`){let{clientName:t,commandName:n}=r,i=Object.keys(e.checksumAlgorithms??{}).filter(e=>{let t=G(e);return s.headers[t]!==void 0}),a=Me([...l??[],...i]);if(t===`S3Client`&&n===`GetObjectCommand`&&a.every(e=>{let t=G(e),n=s.headers[t];return!n||Ne(n)}))return o;await Fe(s,{config:e,responseAlgorithms:a,logger:r.logger})}return o},Re=(e,t)=>({applyToStack:n=>{n.add(ke(e,t),Oe),n.addRelativeTo(je(e,t),Ae),n.addRelativeTo(Le(e,t),Ie)}}),ze=`content-length`,Be=`x-amz-decoded-content-length`;function Ve(){return(e,t)=>async n=>{let{request:r}=n;if(A.isInstance(r)&&!(ze in r.headers)&&!(Be in r.headers)){let e=`Are you using a Stream of unknown length as the Body of a PutObject request? Consider using Upload instead from @aws-sdk/lib-storage.`;typeof t?.logger?.warn==`function`&&!(t.logger instanceof i)?t.logger.warn(e):console.warn(e)}return e({...n})}}var He={step:`finalizeRequest`,tags:[`CHECK_CONTENT_LENGTH_HEADER`],name:`getCheckContentLengthHeaderPlugin`,override:!0},Ue=e=>({applyToStack:e=>{e.add(Ve(),He)}}),We=class extends d.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[c(n,e.getEndpointParameterInstructions()),f(n)]}).s(`AmazonS3`,`AbortMultipartUpload`,{}).n(`S3Client`,`AbortMultipartUploadCommand`).sc(p).build(){};function Ge(e){return t=>async n=>{let r={...n.input};for(let t of[{target:`SSECustomerKey`,hash:`SSECustomerKeyMD5`},{target:`CopySourceSSECustomerKey`,hash:`CopySourceSSECustomerKeyMD5`}]){let n=r[t.target];if(n){let i;typeof n==`string`?qe(n,e)?i=e.base64Decoder(n):(i=e.utf8Decoder(n),r[t.target]=e.base64Encoder(i)):(i=ArrayBuffer.isView(n)?new Uint8Array(n.buffer,n.byteOffset,n.byteLength):new Uint8Array(n),r[t.target]=e.base64Encoder(i));let a=new e.md5;a.update(i),r[t.hash]=e.base64Encoder(await a.digest())}}return t({...n,input:r})}}var Ke={name:`ssecMiddleware`,step:`initialize`,tags:[`SSE`],override:!0},q=e=>({applyToStack:t=>{t.add(Ge(e),Ke)}});function qe(e,t){if(!/^(?:[A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(e))return!1;try{return t.base64Decoder(e).length===32}catch{return!1}}var Je=class extends d.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[c(n,e.getEndpointParameterInstructions()),f(n),q(n)]}).s(`AmazonS3`,`CompleteMultipartUpload`,{}).n(`S3Client`,`CompleteMultipartUploadCommand`).sc(x).build(){};function Ye(e){return t=>async n=>{let{CreateBucketConfiguration:r}=n.input,i=await e.region();return!r?.LocationConstraint&&!r?.Location&&i!==`us-east-1`&&(n.input.CreateBucketConfiguration=n.input.CreateBucketConfiguration??{},n.input.CreateBucketConfiguration.LocationConstraint=i),t(n)}}var Xe={step:`initialize`,tags:[`LOCATION_CONSTRAINT`,`CREATE_BUCKET_CONFIGURATION`],name:`locationConstraintMiddleware`,override:!0},Ze=e=>({applyToStack:t=>{t.add(Ye(e),Xe)}}),Qe=class extends d.classBuilder().ep({...g,UseS3ExpressControlEndpoint:{type:`staticContextParams`,value:!0},DisableAccessPoints:{type:`staticContextParams`,value:!0},Bucket:{type:`contextParams`,name:`Bucket`}}).m(function(e,t,n,r){return[c(n,e.getEndpointParameterInstructions()),f(n),Ze(n)]}).s(`AmazonS3`,`CreateBucket`,{}).n(`S3Client`,`CreateBucketCommand`).sc(w).build(){},$e=class extends d.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[c(n,e.getEndpointParameterInstructions()),f(n),q(n)]}).s(`AmazonS3`,`CreateMultipartUpload`,{}).n(`S3Client`,`CreateMultipartUploadCommand`).sc(h).build(){},et=class extends d.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[c(n,e.getEndpointParameterInstructions()),f(n)]}).s(`AmazonS3`,`DeleteObject`,{}).n(`S3Client`,`DeleteObjectCommand`).sc(y).build(){},tt=class extends d.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[c(n,e.getEndpointParameterInstructions()),Re(n,{requestAlgorithmMember:{httpHeader:`x-amz-sdk-checksum-algorithm`,name:`ChecksumAlgorithm`},requestChecksumRequired:!1}),Ue(n),f(n),q(n)]}).s(`AmazonS3`,`PutObject`,{}).n(`S3Client`,`PutObjectCommand`).sc(S).build(){},nt=class extends d.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`}}).m(function(e,t,n,r){return[c(n,e.getEndpointParameterInstructions()),Re(n,{requestAlgorithmMember:{httpHeader:`x-amz-sdk-checksum-algorithm`,name:`ChecksumAlgorithm`},requestChecksumRequired:!0}),f(n)]}).s(`AmazonS3`,`PutObjectTagging`,{}).n(`S3Client`,`PutObjectTaggingCommand`).sc(b).build(){},rt=class extends d.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[c(n,e.getEndpointParameterInstructions()),Re(n,{requestAlgorithmMember:{httpHeader:`x-amz-sdk-checksum-algorithm`,name:`ChecksumAlgorithm`},requestChecksumRequired:!1}),f(n),q(n)]}).s(`AmazonS3`,`UploadPart`,{}).n(`S3Client`,`UploadPartCommand`).sc(_).build(){},it={CRC32:`CRC32`,CRC32C:`CRC32C`,CRC64NVME:`CRC64NVME`,SHA1:`SHA1`,SHA256:`SHA256`},at=e(((e,t)=>{var n=typeof Reflect==`object`?Reflect:null,r=n&&typeof n.apply==`function`?n.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)},i=n&&typeof n.ownKeys==`function`?n.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};function a(e){console&&console.warn&&console.warn(e)}var o=Number.isNaN||function(e){return e!==e};function s(){s.init.call(this)}t.exports=s,t.exports.once=y,s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var c=10;function l(e){if(typeof e!=`function`)throw TypeError(`The "listener" argument must be of type Function. Received type `+typeof e)}Object.defineProperty(s,`defaultMaxListeners`,{enumerable:!0,get:function(){return c},set:function(e){if(typeof e!=`number`||e<0||o(e))throw RangeError(`The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received `+e+`.`);c=e}}),s.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},s.prototype.setMaxListeners=function(e){if(typeof e!=`number`||e<0||o(e))throw RangeError(`The value of "n" is out of range. It must be a non-negative number. Received `+e+`.`);return this._maxListeners=e,this};function u(e){return e._maxListeners===void 0?s.defaultMaxListeners:e._maxListeners}s.prototype.getMaxListeners=function(){return u(this)},s.prototype.emit=function(e){for(var t=[],n=1;n0&&(o=t[0]),o instanceof Error)throw o;var s=Error(`Unhandled error.`+(o?` (`+o.message+`)`:``));throw s.context=o,s}var c=a[e];if(c===void 0)return!1;if(typeof c==`function`)r(c,this,t);else for(var l=c.length,u=g(c,l),n=0;n0&&s.length>i&&!s.warned){s.warned=!0;var c=Error(`Possible EventEmitter memory leak detected. `+s.length+` `+String(t)+` listeners added. Use emitter.setMaxListeners() to increase limit`);c.name=`MaxListenersExceededWarning`,c.emitter=e,c.type=t,c.count=s.length,a(c)}return e}s.prototype.addListener=function(e,t){return d(this,e,t,!1)},s.prototype.on=s.prototype.addListener,s.prototype.prependListener=function(e,t){return d(this,e,t,!0)};function f(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function p(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=f.bind(r);return i.listener=n,r.wrapFn=i,i}s.prototype.once=function(e,t){return l(t),this.on(e,p(this,e,t)),this},s.prototype.prependOnceListener=function(e,t){return l(t),this.prependListener(e,p(this,e,t)),this},s.prototype.removeListener=function(e,t){var n,r,i,a,o;if(l(t),r=this._events,r===void 0||(n=r[e],n===void 0))return this;if(n===t||n.listener===t)--this._eventsCount===0?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit(`removeListener`,e,n.listener||t));else if(typeof n!=`function`){for(i=-1,a=n.length-1;a>=0;a--)if(n[a]===t||n[a].listener===t){o=n[a].listener,i=a;break}if(i<0)return this;i===0?n.shift():_(n,i),n.length===1&&(r[e]=n[0]),r.removeListener!==void 0&&this.emit(`removeListener`,e,o||t)}return this},s.prototype.off=s.prototype.removeListener,s.prototype.removeAllListeners=function(e){var t,n=this._events,r;if(n===void 0)return this;if(n.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):n[e]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete n[e]),this;if(arguments.length===0){var i=Object.keys(n),a;for(r=0;r=0;r--)this.removeListener(e,t[r]);return this};function m(e,t,n){var r=e._events;if(r===void 0)return[];var i=r[t];return i===void 0?[]:typeof i==`function`?n?[i.listener||i]:[i]:n?v(i):g(i,i.length)}s.prototype.listeners=function(e){return m(this,e,!0)},s.prototype.rawListeners=function(e){return m(this,e,!1)},s.listenerCount=function(e,t){return typeof e.listenerCount==`function`?e.listenerCount(t):h.call(e,t)},s.prototype.listenerCount=h;function h(e){var t=this._events;if(t!==void 0){var n=t[e];if(typeof n==`function`)return 1;if(n!==void 0)return n.length}return 0}s.prototype.eventNames=function(){return this._eventsCount>0?i(this._events):[]};function g(e,t){for(var n=Array(t),r=0;r{e.byteLength=c,e.toByteArray=u,e.fromByteArray=p;for(var t=[],n=[],r=typeof Uint8Array<`u`?Uint8Array:Array,i=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/`,a=0,o=i.length;a0)throw Error(`Invalid string. Length must be a multiple of 4`);var n=e.indexOf(`=`);n===-1&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function c(e){var t=s(e),n=t[0],r=t[1];return(n+r)*3/4-r}function l(e,t,n){return(t+n)*3/4-n}function u(e){var t,i=s(e),a=i[0],o=i[1],c=new r(l(e,a,o)),u=0,d=o>0?a-4:a,f;for(f=0;f>16&255,c[u++]=t>>8&255,c[u++]=t&255;return o===2&&(t=n[e.charCodeAt(f)]<<2|n[e.charCodeAt(f+1)]>>4,c[u++]=t&255),o===1&&(t=n[e.charCodeAt(f)]<<10|n[e.charCodeAt(f+1)]<<4|n[e.charCodeAt(f+2)]>>2,c[u++]=t>>8&255,c[u++]=t&255),c}function d(e){return t[e>>18&63]+t[e>>12&63]+t[e>>6&63]+t[e&63]}function f(e,t,n){for(var r,i=[],a=t;ac?c:s+o));return i===1?(n=e[r-1],a.push(t[n>>2]+t[n<<4&63]+`==`)):i===2&&(n=(e[r-2]<<8)+e[r-1],a.push(t[n>>10]+t[n>>4&63]+t[n<<2&63]+`=`)),a.join(``)}})),st=e((e=>{e.read=function(e,t,n,r,i){var a,o,s=i*8-r-1,c=(1<>1,u=-7,d=n?i-1:0,f=n?-1:1,p=e[t+d];for(d+=f,a=p&(1<<-u)-1,p>>=-u,u+=s;u>0;a=a*256+e[t+d],d+=f,u-=8);for(o=a&(1<<-u)-1,a>>=-u,u+=r;u>0;o=o*256+e[t+d],d+=f,u-=8);if(a===0)a=1-l;else if(a===c)return o?NaN:(p?-1:1)*(1/0);else o+=2**r,a-=l;return(p?-1:1)*o*2**(a-r)},e.write=function(e,t,n,r,i,a){var o,s,c,l=a*8-i-1,u=(1<>1,f=i===23?2**-24-2**-77:0,p=r?0:a-1,m=r?1:-1,h=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,o=u):(o=Math.floor(Math.log(t)/Math.LN2),t*(c=2**-o)<1&&(o--,c*=2),o+d>=1?t+=f/c:t+=f*2**(1-d),t*c>=2&&(o++,c/=2),o+d>=u?(s=0,o=u):o+d>=1?(s=(t*c-1)*2**i,o+=d):(s=t*2**(d-1)*2**i,o=0));i>=8;e[n+p]=s&255,p+=m,s/=256,i-=8);for(o=o<0;e[n+p]=o&255,p+=m,o/=256,l-=8);e[n+p-m]|=h*128}})),J=e((e=>{var t=ot(),n=st(),r=typeof Symbol==`function`&&typeof Symbol.for==`function`?Symbol.for(`nodejs.util.inspect.custom`):null;e.Buffer=s,e.SlowBuffer=_,e.INSPECT_MAX_BYTES=50;var i=2147483647;e.kMaxLength=i,s.TYPED_ARRAY_SUPPORT=a(),!s.TYPED_ARRAY_SUPPORT&&typeof console<`u`&&typeof console.error==`function`&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function a(){try{var e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),e.foo()===42}catch{return!1}}Object.defineProperty(s.prototype,`parent`,{enumerable:!0,get:function(){if(s.isBuffer(this))return this.buffer}}),Object.defineProperty(s.prototype,`offset`,{enumerable:!0,get:function(){if(s.isBuffer(this))return this.byteOffset}});function o(e){if(e>i)throw RangeError(`The value "`+e+`" is invalid for option "size"`);var t=new Uint8Array(e);return Object.setPrototypeOf(t,s.prototype),t}function s(e,t,n){if(typeof e==`number`){if(typeof t==`string`)throw TypeError(`The "string" argument must be of type string. Received type number`);return d(e)}return c(e,t,n)}s.poolSize=8192;function c(e,t,n){if(typeof e==`string`)return f(e,t);if(ArrayBuffer.isView(e))return p(e);if(e==null)throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type `+typeof e);if(W(e,ArrayBuffer)||e&&W(e.buffer,ArrayBuffer)||typeof SharedArrayBuffer<`u`&&(W(e,SharedArrayBuffer)||e&&W(e.buffer,SharedArrayBuffer)))return m(e,t,n);if(typeof e==`number`)throw TypeError(`The "value" argument must not be of type number. Received type number`);var r=e.valueOf&&e.valueOf();if(r!=null&&r!==e)return s.from(r,t,n);var i=h(e);if(i)return i;if(typeof Symbol<`u`&&Symbol.toPrimitive!=null&&typeof e[Symbol.toPrimitive]==`function`)return s.from(e[Symbol.toPrimitive](`string`),t,n);throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type `+typeof e)}s.from=function(e,t,n){return c(e,t,n)},Object.setPrototypeOf(s.prototype,Uint8Array.prototype),Object.setPrototypeOf(s,Uint8Array);function l(e){if(typeof e!=`number`)throw TypeError(`"size" argument must be of type number`);if(e<0)throw RangeError(`The value "`+e+`" is invalid for option "size"`)}function u(e,t,n){return l(e),e<=0||t===void 0?o(e):typeof n==`string`?o(e).fill(t,n):o(e).fill(t)}s.alloc=function(e,t,n){return u(e,t,n)};function d(e){return l(e),o(e<0?0:g(e)|0)}s.allocUnsafe=function(e){return d(e)},s.allocUnsafeSlow=function(e){return d(e)};function f(e,t){if((typeof t!=`string`||t===``)&&(t=`utf8`),!s.isEncoding(t))throw TypeError(`Unknown encoding: `+t);var n=v(e,t)|0,r=o(n),i=r.write(e,t);return i!==n&&(r=r.slice(0,i)),r}function p(e){for(var t=e.length<0?0:g(e.length)|0,n=o(t),r=0;r=i)throw RangeError(`Attempt to allocate Buffer larger than maximum size: 0x`+i.toString(16)+` bytes`);return e|0}function _(e){return+e!=e&&(e=0),s.alloc(+e)}s.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==s.prototype},s.compare=function(e,t){if(W(e,Uint8Array)&&(e=s.from(e,e.offset,e.byteLength)),W(t,Uint8Array)&&(t=s.from(t,t.offset,t.byteLength)),!s.isBuffer(e)||!s.isBuffer(t))throw TypeError(`The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array`);if(e===t)return 0;for(var n=e.length,r=t.length,i=0,a=Math.min(n,r);i2&&arguments[2]===!0;if(!r&&n===0)return 0;for(var i=!1;;)switch(t){case`ascii`:case`latin1`:case`binary`:return n;case`utf8`:case`utf-8`:return B(e).length;case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return n*2;case`hex`:return n>>>1;case`base64`:return H(e).length;default:if(i)return r?-1:B(e).length;t=(``+t).toLowerCase(),i=!0}}s.byteLength=v;function y(e,t,n){var r=!1;if((t===void 0||t<0)&&(t=0),t>this.length||((n===void 0||n>this.length)&&(n=this.length),n<=0)||(n>>>=0,t>>>=0,n<=t))return``;for(e||=`utf8`;;)switch(e){case`hex`:return ne(this,t,n);case`utf8`:case`utf-8`:return k(this,t,n);case`ascii`:return te(this,t,n);case`latin1`:case`binary`:return M(this,t,n);case`base64`:return ee(this,t,n);case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return N(this,t,n);default:if(r)throw TypeError(`Unknown encoding: `+e);e=(e+``).toLowerCase(),r=!0}}s.prototype._isBuffer=!0;function b(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}s.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw RangeError(`Buffer size must be a multiple of 16-bits`);for(var t=0;tn&&(t+=` ... `),``},r&&(s.prototype[r]=s.prototype.inspect),s.prototype.compare=function(e,t,n,r,i){if(W(e,Uint8Array)&&(e=s.from(e,e.offset,e.byteLength)),!s.isBuffer(e))throw TypeError(`The "target" argument must be one of type Buffer or Uint8Array. Received type `+typeof e);if(t===void 0&&(t=0),n===void 0&&(n=e?e.length:0),r===void 0&&(r=0),i===void 0&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw RangeError(`out of range index`);if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;for(var a=i-r,o=n-t,c=Math.min(a,o),l=this.slice(r,i),u=e.slice(t,n),d=0;d2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,G(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0)if(i)n=0;else return-1;if(typeof t==`string`&&(t=s.from(t,r)),s.isBuffer(t))return t.length===0?-1:S(e,t,n,r,i);if(typeof t==`number`)return t&=255,typeof Uint8Array.prototype.indexOf==`function`?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):S(e,[t],n,r,i);throw TypeError(`val must be string, number or Buffer`)}function S(e,t,n,r,i){var a=1,o=e.length,s=t.length;if(r!==void 0&&(r=String(r).toLowerCase(),r===`ucs2`||r===`ucs-2`||r===`utf16le`||r===`utf-16le`)){if(e.length<2||t.length<2)return-1;a=2,o/=2,s/=2,n/=2}function c(e,t){return a===1?e[t]:e.readUInt16BE(t*a)}var l;if(i){var u=-1;for(l=n;lo&&(n=o-s),l=n;l>=0;l--){for(var d=!0,f=0;fi&&(r=i)):r=i;var a=t.length;r>a/2&&(r=a/2);for(var o=0;o>>=0,isFinite(n)?(n>>>=0,r===void 0&&(r=`utf8`)):(r=n,n=void 0);else throw Error(`Buffer.write(string, encoding, offset[, length]) is no longer supported`);var i=this.length-t;if((n===void 0||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw RangeError(`Attempt to write outside buffer bounds`);r||=`utf8`;for(var a=!1;;)switch(r){case`hex`:return C(this,e,t,n);case`utf8`:case`utf-8`:return w(this,e,t,n);case`ascii`:return T(this,e,t,n);case`latin1`:case`binary`:return E(this,e,t,n);case`base64`:return D(this,e,t,n);case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return O(this,e,t,n);default:if(a)throw TypeError(`Unknown encoding: `+r);r=(``+r).toLowerCase(),a=!0}},s.prototype.toJSON=function(){return{type:`Buffer`,data:Array.prototype.slice.call(this._arr||this,0)}};function ee(e,n,r){return n===0&&r===e.length?t.fromByteArray(e):t.fromByteArray(e.slice(n,r))}function k(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i239?4:a>223?3:a>191?2:1;if(i+s<=n){var c,l,u,d;switch(s){case 1:a<128&&(o=a);break;case 2:c=e[i+1],(c&192)==128&&(d=(a&31)<<6|c&63,d>127&&(o=d));break;case 3:c=e[i+1],l=e[i+2],(c&192)==128&&(l&192)==128&&(d=(a&15)<<12|(c&63)<<6|l&63,d>2047&&(d<55296||d>57343)&&(o=d));break;case 4:c=e[i+1],l=e[i+2],u=e[i+3],(c&192)==128&&(l&192)==128&&(u&192)==128&&(d=(a&15)<<18|(c&63)<<12|(l&63)<<6|u&63,d>65535&&d<1114112&&(o=d))}}o===null?(o=65533,s=1):o>65535&&(o-=65536,r.push(o>>>10&1023|55296),o=56320|o&1023),r.push(o),i+=s}return j(r)}var A=4096;function j(e){var t=e.length;if(t<=A)return String.fromCharCode.apply(String,e);for(var n=``,r=0;rr)&&(n=r);for(var i=``,a=t;an&&(e=n),t<0?(t+=n,t<0&&(t=0)):t>n&&(t=n),tn)throw RangeError(`Trying to access beyond buffer length`)}s.prototype.readUIntLE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e],i=1,a=0;++a>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e+--t],i=1;t>0&&(i*=256);)r+=this[e+--t]*i;return r},s.prototype.readUInt8=function(e,t){return e>>>=0,t||P(e,1,this.length),this[e]},s.prototype.readUInt16LE=function(e,t){return e>>>=0,t||P(e,2,this.length),this[e]|this[e+1]<<8},s.prototype.readUInt16BE=function(e,t){return e>>>=0,t||P(e,2,this.length),this[e]<<8|this[e+1]},s.prototype.readUInt32LE=function(e,t){return e>>>=0,t||P(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216},s.prototype.readUInt32BE=function(e,t){return e>>>=0,t||P(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])},s.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e],i=1,a=0;++a=i&&(r-=2**(8*t)),r},s.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=t,i=1,a=this[e+--r];r>0&&(i*=256);)a+=this[e+--r]*i;return i*=128,a>=i&&(a-=2**(8*t)),a},s.prototype.readInt8=function(e,t){return e>>>=0,t||P(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]},s.prototype.readInt16LE=function(e,t){e>>>=0,t||P(e,2,this.length);var n=this[e]|this[e+1]<<8;return n&32768?n|4294901760:n},s.prototype.readInt16BE=function(e,t){e>>>=0,t||P(e,2,this.length);var n=this[e+1]|this[e]<<8;return n&32768?n|4294901760:n},s.prototype.readInt32LE=function(e,t){return e>>>=0,t||P(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},s.prototype.readInt32BE=function(e,t){return e>>>=0,t||P(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},s.prototype.readFloatLE=function(e,t){return e>>>=0,t||P(e,4,this.length),n.read(this,e,!0,23,4)},s.prototype.readFloatBE=function(e,t){return e>>>=0,t||P(e,4,this.length),n.read(this,e,!1,23,4)},s.prototype.readDoubleLE=function(e,t){return e>>>=0,t||P(e,8,this.length),n.read(this,e,!0,52,8)},s.prototype.readDoubleBE=function(e,t){return e>>>=0,t||P(e,8,this.length),n.read(this,e,!1,52,8)};function F(e,t,n,r,i,a){if(!s.isBuffer(e))throw TypeError(`"buffer" argument must be a Buffer instance`);if(t>i||te.length)throw RangeError(`Index out of range`)}s.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){var i=2**(8*n)-1;F(this,e,t,n,i,0)}var a=1,o=0;for(this[t]=e&255;++o>>=0,n>>>=0,!r){var i=2**(8*n)-1;F(this,e,t,n,i,0)}var a=n-1,o=1;for(this[t+a]=e&255;--a>=0&&(o*=256);)this[t+a]=e/o&255;return t+n},s.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,1,255,0),this[t]=e&255,t+1},s.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,2,65535,0),this[t]=e&255,this[t+1]=e>>>8,t+2},s.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=e&255,t+2},s.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=e&255,t+4},s.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4},s.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=2**(8*n-1);F(this,e,t,n,i-1,-i)}var a=0,o=1,s=0;for(this[t]=e&255;++a>0)-s&255;return t+n},s.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=2**(8*n-1);F(this,e,t,n,i-1,-i)}var a=n-1,o=1,s=0;for(this[t+a]=e&255;--a>=0&&(o*=256);)e<0&&s===0&&this[t+a+1]!==0&&(s=1),this[t+a]=(e/o>>0)-s&255;return t+n},s.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=e&255,t+1},s.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,2,32767,-32768),this[t]=e&255,this[t+1]=e>>>8,t+2},s.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=e&255,t+2},s.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,4,2147483647,-2147483648),this[t]=e&255,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},s.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};function I(e,t,n,r,i,a){if(n+r>e.length||n<0)throw RangeError(`Index out of range`)}function L(e,t,r,i,a){return t=+t,r>>>=0,a||I(e,t,r,4,34028234663852886e22,-34028234663852886e22),n.write(e,t,r,i,23,4),r+4}s.prototype.writeFloatLE=function(e,t,n){return L(this,e,t,!0,n)},s.prototype.writeFloatBE=function(e,t,n){return L(this,e,t,!1,n)};function R(e,t,r,i,a){return t=+t,r>>>=0,a||I(e,t,r,8,17976931348623157e292,-17976931348623157e292),n.write(e,t,r,i,52,8),r+8}s.prototype.writeDoubleLE=function(e,t,n){return R(this,e,t,!0,n)},s.prototype.writeDoubleBE=function(e,t,n){return R(this,e,t,!1,n)},s.prototype.copy=function(e,t,n,r){if(!s.isBuffer(e))throw TypeError(`argument should be a Buffer`);if(n||=0,!r&&r!==0&&(r=this.length),t>=e.length&&(t=e.length),t||=0,r>0&&r=this.length)throw RangeError(`Index out of range`);if(r<0)throw RangeError(`sourceEnd out of bounds`);r>this.length&&(r=this.length),e.length-t=0;--a)e[a+t]=this[a+n];else Uint8Array.prototype.set.call(e,this.subarray(n,r),t);return i},s.prototype.fill=function(e,t,n,r){if(typeof e==`string`){if(typeof t==`string`?(r=t,t=0,n=this.length):typeof n==`string`&&(r=n,n=this.length),r!==void 0&&typeof r!=`string`)throw TypeError(`encoding must be a string`);if(typeof r==`string`&&!s.isEncoding(r))throw TypeError(`Unknown encoding: `+r);if(e.length===1){var i=e.charCodeAt(0);(r===`utf8`&&i<128||r===`latin1`)&&(e=i)}}else typeof e==`number`?e&=255:typeof e==`boolean`&&(e=Number(e));if(t<0||this.length>>=0,n=n===void 0?this.length:n>>>0,e||=0;var a;if(typeof e==`number`)for(a=t;a55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&a.push(239,191,189);continue}else if(o+1===r){(t-=3)>-1&&a.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&a.push(239,191,189),i=n;continue}n=(i-55296<<10|n-56320)+65536}else i&&(t-=3)>-1&&a.push(239,191,189);if(i=null,n<128){if(--t<0)break;a.push(n)}else if(n<2048){if((t-=2)<0)break;a.push(n>>6|192,n&63|128)}else if(n<65536){if((t-=3)<0)break;a.push(n>>12|224,n>>6&63|128,n&63|128)}else if(n<1114112){if((t-=4)<0)break;a.push(n>>18|240,n>>12&63|128,n>>6&63|128,n&63|128)}else throw Error(`Invalid code point`)}return a}function V(e){for(var t=[],n=0;n>8,i=n%256,a.push(i),a.push(r);return a}function H(e){return t.toByteArray(z(e))}function U(e,t,n,r){for(var i=0;i=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function W(e,t){return e instanceof t||e!=null&&e.constructor!=null&&e.constructor.name!=null&&e.constructor.name===t.name}function G(e){return e!==e}var ae=(function(){for(var e=`0123456789abcdef`,t=Array(256),n=0;n<16;++n)for(var r=n*16,i=0;i<16;++i)t[r+i]=e[n]+e[i];return t})()})),ct={lstatSync:()=>{},isFileReadStream(e){return!1},runtime:`browser`},Y=J(),lt=e=>{if(e==null)return 0;if(typeof e==`string`)return Y.Buffer.byteLength(e);if(typeof e.byteLength==`number`)return e.byteLength;if(typeof e.length==`number`)return e.length;if(typeof e.size==`number`)return e.size;if(typeof e.start==`number`&&typeof e.end==`number`)return e.end+1-e.start;if(ct.isFileReadStream(e))try{return ct.lstatSync(e.path).size}catch{return}},X;(function(e){e.EMPTY_INPUT=`a null or undefined Body`,e.CONTENT_LENGTH=`the ContentLength property of the params set by the caller`,e.STRING_LENGTH=`the encoded byte length of the Body string`,e.TYPED_ARRAY=`the byteLength of a typed byte array such as Uint8Array`,e.LENGTH=`the value of Body.length`,e.SIZE=`the value of Body.size`,e.START_END_DIFF=`the numeric difference between Body.start and Body.end`,e.LSTAT=`the size of the file given by Body.path on disk as reported by lstatSync`})(X||={});var ut=(e,t)=>{if(t!=null)return X.CONTENT_LENGTH;if(e==null)return X.EMPTY_INPUT;if(typeof e==`string`)return X.STRING_LENGTH;if(typeof e.byteLength==`number`)return X.TYPED_ARRAY;if(typeof e.length==`number`)return X.LENGTH;if(typeof e.size==`number`)return X.SIZE;if(typeof e.start==`number`&&typeof e.end==`number`)return X.START_END_DIFF;if(ct.isFileReadStream(e))try{return ct.lstatSync(e.path).size,X.LSTAT}catch{return}},Z=e(((e,t)=>{typeof Object.create==`function`?t.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(e,t){if(t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}}})),dt=e(((e,t)=>{t.exports=at().EventEmitter})),ft=e(((e,t)=>{t.exports={}})),pt=e(((e,t)=>{function n(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function r(e){for(var t=1;t0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:`unshift`,value:function(e){var t={data:e,next:this.head};this.length===0&&(this.tail=t),this.head=t,++this.length}},{key:`shift`,value:function(){if(this.length!==0){var e=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:`clear`,value:function(){this.head=this.tail=null,this.length=0}},{key:`join`,value:function(e){if(this.length===0)return``;for(var t=this.head,n=``+t.data;t=t.next;)n+=e+t.data;return n}},{key:`concat`,value:function(e){if(this.length===0)return u.alloc(0);for(var t=u.allocUnsafe(e>>>0),n=this.head,r=0;n;)p(n.data,t,r),r+=n.data.length,n=n.next;return t}},{key:`consume`,value:function(e,t){var n;return ei.length?i.length:e;if(a===i.length?r+=i:r+=i.slice(0,e),e-=a,e===0){a===i.length?(++n,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(a));break}++n}return this.length-=n,r}},{key:`_getBuffer`,value:function(e){var t=u.allocUnsafe(e),n=this.head,r=1;for(n.data.copy(t),e-=n.data.length;n=n.next;){var i=n.data,a=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,a),e-=a,e===0){a===i.length?(++r,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=i.slice(a));break}++r}return this.length-=r,t}},{key:f,value:function(e,t){return d(this,r(r({},t),{},{depth:0,customInspect:!1}))}}]),e}()})),mt=e(((e,t)=>{function n(e,t){var n=this,a=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return a||s?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(o,this,e)):process.nextTick(o,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?n._writableState?n._writableState.errorEmitted?process.nextTick(i,n):(n._writableState.errorEmitted=!0,process.nextTick(r,n,e)):process.nextTick(r,n,e):t?(process.nextTick(i,n),t(e)):process.nextTick(i,n)}),this)}function r(e,t){o(e,t),i(e)}function i(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit(`close`)}function a(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function o(e,t){e.emit(`error`,t)}function s(e,t){var n=e._readableState,r=e._writableState;n&&n.autoDestroy||r&&r.autoDestroy?e.destroy(t):e.emit(`error`,t)}t.exports={destroy:n,undestroy:a,errorOrDestroy:s}})),Q=e(((e,t)=>{function n(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var r={};function i(e,t,i){i||=Error;function a(e,n,r){return typeof t==`string`?t:t(e,n,r)}var o=function(e){n(t,e);function t(t,n,r){return e.call(this,a(t,n,r))||this}return t}(i);o.prototype.name=i.name,o.prototype.code=e,r[e]=o}function a(e,t){if(Array.isArray(e)){var n=e.length;return e=e.map(function(e){return String(e)}),n>2?`one of ${t} ${e.slice(0,n-1).join(`, `)}, or `+e[n-1]:n===2?`one of ${t} ${e[0]} or ${e[1]}`:`of ${t} ${e[0]}`}else return`of ${t} ${String(e)}`}function o(e,t,n){return e.substr(!n||n<0?0:+n,t.length)===t}function s(e,t,n){return(n===void 0||n>e.length)&&(n=e.length),e.substring(n-t.length,n)===t}function c(e,t,n){return typeof n!=`number`&&(n=0),n+t.length>e.length?!1:e.indexOf(t,n)!==-1}i(`ERR_INVALID_OPT_VALUE`,function(e,t){return`The value "`+t+`" is invalid for option "`+e+`"`},TypeError),i(`ERR_INVALID_ARG_TYPE`,function(e,t,n){var r;typeof t==`string`&&o(t,`not `)?(r=`must not be`,t=t.replace(/^not /,``)):r=`must be`;var i=s(e,` argument`)?`The ${e} ${r} ${a(t,`type`)}`:`The "${e}" ${c(e,`.`)?`property`:`argument`} ${r} ${a(t,`type`)}`;return i+=`. Received type ${typeof n}`,i},TypeError),i(`ERR_STREAM_PUSH_AFTER_EOF`,`stream.push() after EOF`),i(`ERR_METHOD_NOT_IMPLEMENTED`,function(e){return`The `+e+` method is not implemented`}),i(`ERR_STREAM_PREMATURE_CLOSE`,`Premature close`),i(`ERR_STREAM_DESTROYED`,function(e){return`Cannot call `+e+` after a stream was destroyed`}),i(`ERR_MULTIPLE_CALLBACK`,`Callback called multiple times`),i(`ERR_STREAM_CANNOT_PIPE`,`Cannot pipe, not readable`),i(`ERR_STREAM_WRITE_AFTER_END`,`write after end`),i(`ERR_STREAM_NULL_VALUES`,`May not write null values to stream`,TypeError),i(`ERR_UNKNOWN_ENCODING`,function(e){return`Unknown encoding: `+e},TypeError),i(`ERR_STREAM_UNSHIFT_AFTER_END_EVENT`,`stream.unshift() after end event`),t.exports.codes=r})),ht=e(((e,t)=>{var n=Q().codes.ERR_INVALID_OPT_VALUE;function r(e,t,n){return e.highWaterMark==null?t?e[n]:null:e.highWaterMark}function i(e,t,i,a){var o=r(t,a,i);if(o!=null){if(!(isFinite(o)&&Math.floor(o)===o)||o<0)throw new n(a?i:`highWaterMark`,o);return Math.floor(o)}return e.objectMode?16:16*1024}t.exports={getHighWaterMark:i}})),gt=e(((e,t)=>{t.exports=n;function n(e,t){if(r(`noDeprecation`))return e;var n=!1;function i(){if(!n){if(r(`throwDeprecation`))throw Error(t);r(`traceDeprecation`)?console.trace(t):console.warn(t),n=!0}return e.apply(this,arguments)}return i}function r(e){try{if(!global.localStorage)return!1}catch{return!1}var t=global.localStorage[e];return t==null?!1:String(t).toLowerCase()===`true`}})),_t=e(((e,t)=>{t.exports=T;function n(e){var t=this;this.next=null,this.entry=null,this.finish=function(){re(t,e)}}var r;T.WritableState=C;var i={deprecate:gt()},a=dt(),o=J().Buffer,s=(typeof global<`u`?global:typeof window<`u`?window:typeof self<`u`?self:{}).Uint8Array||function(){};function c(e){return o.from(e)}function l(e){return o.isBuffer(e)||e instanceof s}var u=mt(),d=ht().getHighWaterMark,f=Q().codes,p=f.ERR_INVALID_ARG_TYPE,m=f.ERR_METHOD_NOT_IMPLEMENTED,h=f.ERR_MULTIPLE_CALLBACK,g=f.ERR_STREAM_CANNOT_PIPE,_=f.ERR_STREAM_DESTROYED,v=f.ERR_STREAM_NULL_VALUES,y=f.ERR_STREAM_WRITE_AFTER_END,b=f.ERR_UNKNOWN_ENCODING,x=u.errorOrDestroy;Z()(T,a);function S(){}function C(e,t,i){r||=$(),e||={},typeof i!=`boolean`&&(i=t instanceof r),this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=d(this,e,`writableHighWaterMark`,i),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1,this.decodeStrings=e.decodeStrings!==!1,this.defaultEncoding=e.defaultEncoding||`utf8`,this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){te(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=e.emitClose!==!1,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new n(this)}C.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},(function(){try{Object.defineProperty(C.prototype,`buffer`,{get:i.deprecate(function(){return this.getBuffer()},`_writableState.buffer is deprecated. Use _writableState.getBuffer instead.`,`DEP0003`)})}catch{}})();var w;typeof Symbol==`function`&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]==`function`?(w=Function.prototype[Symbol.hasInstance],Object.defineProperty(T,Symbol.hasInstance,{value:function(e){return w.call(this,e)?!0:this===T?e&&e._writableState instanceof C:!1}})):w=function(e){return e instanceof this};function T(e){r||=$();var t=this instanceof r;if(!t&&!w.call(T,this))return new T(e);this._writableState=new C(e,this,t),this.writable=!0,e&&(typeof e.write==`function`&&(this._write=e.write),typeof e.writev==`function`&&(this._writev=e.writev),typeof e.destroy==`function`&&(this._destroy=e.destroy),typeof e.final==`function`&&(this._final=e.final)),a.call(this)}T.prototype.pipe=function(){x(this,new g)};function E(e,t){var n=new y;x(e,n),process.nextTick(t,n)}function D(e,t,n,r){var i;return n===null?i=new v:typeof n!=`string`&&!t.objectMode&&(i=new p(`chunk`,[`string`,`Buffer`],n)),i?(x(e,i),process.nextTick(r,i),!1):!0}T.prototype.write=function(e,t,n){var r=this._writableState,i=!1,a=!r.objectMode&&l(e);return a&&!o.isBuffer(e)&&(e=c(e)),typeof t==`function`&&(n=t,t=null),a?t=`buffer`:t||=r.defaultEncoding,typeof n!=`function`&&(n=S),r.ending?E(this,n):(a||D(this,r,e,n))&&(r.pendingcb++,i=ee(this,r,a,e,t,n)),i},T.prototype.cork=function(){this._writableState.corked++},T.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest&&N(this,e))},T.prototype.setDefaultEncoding=function(e){if(typeof e==`string`&&(e=e.toLowerCase()),!([`hex`,`utf8`,`utf-8`,`ascii`,`binary`,`base64`,`ucs2`,`ucs-2`,`utf16le`,`utf-16le`,`raw`].indexOf((e+``).toLowerCase())>-1))throw new b(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(T.prototype,`writableBuffer`,{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function O(e,t,n){return!e.objectMode&&e.decodeStrings!==!1&&typeof t==`string`&&(t=o.from(t,n)),t}Object.defineProperty(T.prototype,`writableHighWaterMark`,{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function ee(e,t,n,r,i,a){if(!n){var o=O(t,r,i);r!==o&&(n=!0,i=`buffer`,r=o)}var s=t.objectMode?1:r.length;t.length+=s;var c=t.length{var n=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};t.exports=c;var r=Ct(),i=_t();Z()(c,r);for(var a=n(i.prototype),o=0;o{var n=J(),r=n.Buffer;function i(e,t){for(var n in e)t[n]=e[n]}r.from&&r.alloc&&r.allocUnsafe&&r.allocUnsafeSlow?t.exports=n:(i(n,e),e.Buffer=a);function a(e,t,n){return r(e,t,n)}a.prototype=Object.create(r.prototype),i(r,a),a.from=function(e,t,n){if(typeof e==`number`)throw TypeError(`Argument must not be a number`);return r(e,t,n)},a.alloc=function(e,t,n){if(typeof e!=`number`)throw TypeError(`Argument must be a number`);var i=r(e);return t===void 0?i.fill(0):typeof n==`string`?i.fill(t,n):i.fill(t),i},a.allocUnsafe=function(e){if(typeof e!=`number`)throw TypeError(`Argument must be a number`);return r(e)},a.allocUnsafeSlow=function(e){if(typeof e!=`number`)throw TypeError(`Argument must be a number`);return n.SlowBuffer(e)}})),yt=e((e=>{var t=vt().Buffer,n=t.isEncoding||function(e){switch(e=``+e,e&&e.toLowerCase()){case`hex`:case`utf8`:case`utf-8`:case`ascii`:case`binary`:case`base64`:case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:case`raw`:return!0;default:return!1}};function r(e){if(!e)return`utf8`;for(var t;;)switch(e){case`utf8`:case`utf-8`:return`utf8`;case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return`utf16le`;case`latin1`:case`binary`:return`latin1`;case`base64`:case`ascii`:case`hex`:return e;default:if(t)return;e=(``+e).toLowerCase(),t=!0}}function i(e){var i=r(e);if(typeof i!=`string`&&(t.isEncoding===n||!n(e)))throw Error(`Unknown encoding: `+e);return i||e}e.StringDecoder=a;function a(e){this.encoding=i(e);var n;switch(this.encoding){case`utf16le`:this.text=f,this.end=p,n=4;break;case`utf8`:this.fillLast=l,n=4;break;case`base64`:this.text=m,this.end=h,n=3;break;default:this.write=g,this.end=_;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(n)}a.prototype.write=function(e){if(e.length===0)return``;var t,n;if(this.lastNeed){if(t=this.fillLast(e),t===void 0)return``;n=this.lastNeed,this.lastNeed=0}else n=0;return n>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e,t,n){var r=t.length-1;if(r=0?(i>0&&(e.lastNeed=i-1),i):--r=0?(i>0&&(e.lastNeed=i-2),i):--r=0?(i>0&&(i===2?i=0:e.lastNeed=i-3),i):0))}function c(e,t,n){if((t[0]&192)!=128)return e.lastNeed=0,`�`;if(e.lastNeed>1&&t.length>1){if((t[1]&192)!=128)return e.lastNeed=1,`�`;if(e.lastNeed>2&&t.length>2&&(t[2]&192)!=128)return e.lastNeed=2,`�`}}function l(e){var t=this.lastTotal-this.lastNeed,n=c(this,e,t);if(n!==void 0)return n;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}function u(e,t){var n=s(this,e,t);if(!this.lastNeed)return e.toString(`utf8`,t);this.lastTotal=n;var r=e.length-(n-this.lastNeed);return e.copy(this.lastChar,0,r),e.toString(`utf8`,t,r)}function d(e){var t=e&&e.length?this.write(e):``;return this.lastNeed?t+`�`:t}function f(e,t){if((e.length-t)%2==0){var n=e.toString(`utf16le`,t);if(n){var r=n.charCodeAt(n.length-1);if(r>=55296&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],n.slice(0,-1)}return n}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString(`utf16le`,t,e.length-1)}function p(e){var t=e&&e.length?this.write(e):``;if(this.lastNeed){var n=this.lastTotal-this.lastNeed;return t+this.lastChar.toString(`utf16le`,0,n)}return t}function m(e,t){var n=(e.length-t)%3;return n===0?e.toString(`base64`,t):(this.lastNeed=3-n,this.lastTotal=3,n===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString(`base64`,t,e.length-n))}function h(e){var t=e&&e.length?this.write(e):``;return this.lastNeed?t+this.lastChar.toString(`base64`,0,3-this.lastNeed):t}function g(e){return e.toString(this.encoding)}function _(e){return e&&e.length?this.write(e):``}})),bt=e(((e,t)=>{var n=Q().codes.ERR_STREAM_PREMATURE_CLOSE;function r(e){var t=!1;return function(){if(!t){t=!0;var n=[...arguments];e.apply(this,n)}}}function i(){}function a(e){return e.setHeader&&typeof e.abort==`function`}function o(e,t,s){if(typeof t==`function`)return o(e,null,t);t||={},s=r(s||i);var c=t.readable||t.readable!==!1&&e.readable,l=t.writable||t.writable!==!1&&e.writable,u=function(){e.writable||f()},d=e._writableState&&e._writableState.finished,f=function(){l=!1,d=!0,c||s.call(e)},p=e._readableState&&e._readableState.endEmitted,m=function(){c=!1,p=!0,l||s.call(e)},h=function(t){s.call(e,t)},g=function(){var t;if(c&&!p)return(!e._readableState||!e._readableState.ended)&&(t=new n),s.call(e,t);if(l&&!d)return(!e._writableState||!e._writableState.ended)&&(t=new n),s.call(e,t)},_=function(){e.req.on(`finish`,f)};return a(e)?(e.on(`complete`,f),e.on(`abort`,g),e.req?_():e.on(`request`,_)):l&&!e._writableState&&(e.on(`end`,u),e.on(`close`,u)),e.on(`end`,m),e.on(`finish`,f),t.error!==!1&&e.on(`error`,h),e.on(`close`,g),function(){e.removeListener(`complete`,f),e.removeListener(`abort`,g),e.removeListener(`request`,_),e.req&&e.req.removeListener(`finish`,f),e.removeListener(`end`,u),e.removeListener(`close`,u),e.removeListener(`finish`,f),e.removeListener(`end`,m),e.removeListener(`error`,h),e.removeListener(`close`,g)}}t.exports=o})),xt=e(((e,t)=>{var n;function r(e,t,n){return t=i(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){var t=a(e,`string`);return typeof t==`symbol`?t:String(t)}function a(e,t){if(typeof e!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(typeof r!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var o=bt(),s=Symbol(`lastResolve`),c=Symbol(`lastReject`),l=Symbol(`error`),u=Symbol(`ended`),d=Symbol(`lastPromise`),f=Symbol(`handlePromise`),p=Symbol(`stream`);function m(e,t){return{value:e,done:t}}function h(e){var t=e[s];if(t!==null){var n=e[p].read();n!==null&&(e[d]=null,e[s]=null,e[c]=null,t(m(n,!1)))}}function g(e){process.nextTick(h,e)}function _(e,t){return function(n,r){e.then(function(){if(t[u]){n(m(void 0,!0));return}t[f](n,r)},r)}}var v=Object.getPrototypeOf(function(){}),y=Object.setPrototypeOf((n={get stream(){return this[p]},next:function(){var e=this,t=this[l];if(t!==null)return Promise.reject(t);if(this[u])return Promise.resolve(m(void 0,!0));if(this[p].destroyed)return new Promise(function(t,n){process.nextTick(function(){e[l]?n(e[l]):t(m(void 0,!0))})});var n=this[d],r;if(n)r=new Promise(_(n,this));else{var i=this[p].read();if(i!==null)return Promise.resolve(m(i,!1));r=new Promise(this[f])}return this[d]=r,r}},r(n,Symbol.asyncIterator,function(){return this}),r(n,`return`,function(){var e=this;return new Promise(function(t,n){e[p].destroy(null,function(e){if(e){n(e);return}t(m(void 0,!0))})})}),n),v);t.exports=function(e){var t,n=Object.create(y,(t={},r(t,p,{value:e,writable:!0}),r(t,s,{value:null,writable:!0}),r(t,c,{value:null,writable:!0}),r(t,l,{value:null,writable:!0}),r(t,u,{value:e._readableState.endEmitted,writable:!0}),r(t,f,{value:function(e,t){var r=n[p].read();r?(n[d]=null,n[s]=null,n[c]=null,e(m(r,!1))):(n[s]=e,n[c]=t)},writable:!0}),t));return n[d]=null,o(e,function(e){if(e&&e.code!==`ERR_STREAM_PREMATURE_CLOSE`){var t=n[c];t!==null&&(n[d]=null,n[s]=null,n[c]=null,t(e)),n[l]=e;return}var r=n[s];r!==null&&(n[d]=null,n[s]=null,n[c]=null,r(m(void 0,!0))),n[u]=!0}),e.on(`readable`,g.bind(null,n)),n}})),St=e(((e,t)=>{t.exports=function(){throw Error(`Readable.from is not available in the browser`)}})),Ct=e(((e,t)=>{t.exports=E;var n;E.ReadableState=T,at().EventEmitter;var r=function(e,t){return e.listeners(t).length},i=dt(),a=J().Buffer,o=(typeof global<`u`?global:typeof window<`u`?window:typeof self<`u`?self:{}).Uint8Array||function(){};function s(e){return a.from(e)}function c(e){return a.isBuffer(e)||e instanceof o}var l=ft(),u=l&&l.debuglog?l.debuglog(`stream`):function(){},d=pt(),f=mt(),p=ht().getHighWaterMark,m=Q().codes,h=m.ERR_INVALID_ARG_TYPE,g=m.ERR_STREAM_PUSH_AFTER_EOF,_=m.ERR_METHOD_NOT_IMPLEMENTED,v=m.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,y,b,x;Z()(E,i);var S=f.errorOrDestroy,C=[`error`,`close`,`destroy`,`pause`,`resume`];function w(e,t,n){if(typeof e.prependListener==`function`)return e.prependListener(t,n);!e._events||!e._events[t]?e.on(t,n):Array.isArray(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]}function T(e,t,r){n||=$(),e||={},typeof r!=`boolean`&&(r=t instanceof n),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=p(this,e,`readableHighWaterMark`,r),this.buffer=new d,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=e.emitClose!==!1,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||`utf8`,this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(y||=yt().StringDecoder,this.decoder=new y(e.encoding),this.encoding=e.encoding)}function E(e){if(n||=$(),!(this instanceof E))return new E(e);var t=this instanceof n;this._readableState=new T(e,this,t),this.readable=!0,e&&(typeof e.read==`function`&&(this._read=e.read),typeof e.destroy==`function`&&(this._destroy=e.destroy)),i.call(this)}Object.defineProperty(E.prototype,`destroyed`,{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=f.destroy,E.prototype._undestroy=f.undestroy,E.prototype._destroy=function(e,t){t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:typeof e==`string`&&(t||=n.defaultEncoding,t!==n.encoding&&(e=a.from(e,t),t=``),r=!0),D(this,e,t,!1,r)},E.prototype.unshift=function(e){return D(this,e,null,!0,!1)};function D(e,t,n,r,i){u(`readableAddChunk`,t);var o=e._readableState;if(t===null)o.reading=!1,te(e,o);else{var c;if(i||(c=ee(o,t)),c)S(e,c);else if(o.objectMode||t&&t.length>0)if(typeof t!=`string`&&!o.objectMode&&Object.getPrototypeOf(t)!==a.prototype&&(t=s(t)),r)o.endEmitted?S(e,new v):O(e,o,t,!0);else if(o.ended)S(e,new g);else if(o.destroyed)return!1;else o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||t.length!==0?O(e,o,t,!1):N(e,o)):O(e,o,t,!1);else r||(o.reading=!1,N(e,o))}return!o.ended&&(o.length=k?e=k:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||t.length===0&&t.ended?0:t.objectMode?1:e===e?(e>t.highWaterMark&&(t.highWaterMark=A(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0)):t.flowing&&t.length?t.buffer.head.data.length:t.length}E.prototype.read=function(e){u(`read`,e),e=parseInt(e,10);var t=this._readableState,n=e;if(e!==0&&(t.emittedReadable=!1),e===0&&t.needReadable&&((t.highWaterMark===0?t.length>0:t.length>=t.highWaterMark)||t.ended))return u(`read: emitReadable`,t.length,t.ended),t.length===0&&t.ended?V(this):M(this),null;if(e=j(e,t),e===0&&t.ended)return t.length===0&&V(this),null;var r=t.needReadable;u(`need readable`,r),(t.length===0||t.length-e0?B(e,t):null;return i===null?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),t.length===0&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),i!==null&&this.emit(`data`,i),i};function te(e,t){if(u(`onEofChunk`),!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,t.sync?M(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,ne(e)))}}function M(e){var t=e._readableState;u(`emitReadable`,t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(u(`emitReadable`,t.flowing),t.emittedReadable=!0,process.nextTick(ne,e))}function ne(e){var t=e._readableState;u(`emitReadable_`,t.destroyed,t.length,t.ended),!t.destroyed&&(t.length||t.ended)&&(e.emit(`readable`),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,z(e)}function N(e,t){t.readingMore||(t.readingMore=!0,process.nextTick(P,e,t))}function P(e,t){for(;!t.reading&&!t.ended&&(t.length1&&H(i.pipes,e)!==-1)&&!l&&(u(`false write response, pause`,i.awaitDrain),i.awaitDrain++),n.pause())}function p(t){u(`onerror`,t),g(),e.removeListener(`error`,p),r(e,`error`)===0&&S(e,t)}w(e,`error`,p);function m(){e.removeListener(`finish`,h),g()}e.once(`close`,m);function h(){u(`onfinish`),e.removeListener(`close`,m),g()}e.once(`finish`,h);function g(){u(`unpipe`),n.unpipe(e)}return e.emit(`pipe`,n),i.flowing||(u(`pipe resume`),n.resume()),e};function F(e){return function(){var t=e._readableState;u(`pipeOnDrain`,t.awaitDrain),t.awaitDrain&&t.awaitDrain--,t.awaitDrain===0&&r(e,`data`)&&(t.flowing=!0,z(e))}}E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(t.pipesCount===0)return this;if(t.pipesCount===1)return e&&e!==t.pipes?this:(e||=t.pipes,t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit(`unpipe`,this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var a=0;a0,r.flowing!==!1&&this.resume()):e===`readable`&&!r.endEmitted&&!r.readableListening&&(r.readableListening=r.needReadable=!0,r.flowing=!1,r.emittedReadable=!1,u(`on readable`,r.length,r.reading),r.length?M(this):r.reading||process.nextTick(L,this)),n},E.prototype.addListener=E.prototype.on,E.prototype.removeListener=function(e,t){var n=i.prototype.removeListener.call(this,e,t);return e===`readable`&&process.nextTick(I,this),n},E.prototype.removeAllListeners=function(e){var t=i.prototype.removeAllListeners.apply(this,arguments);return(e===`readable`||e===void 0)&&process.nextTick(I,this),t};function I(e){var t=e._readableState;t.readableListening=e.listenerCount(`readable`)>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount(`data`)>0&&e.resume()}function L(e){u(`readable nexttick read 0`),e.read(0)}E.prototype.resume=function(){var e=this._readableState;return e.flowing||(u(`resume`),e.flowing=!e.readableListening,R(this,e)),e.paused=!1,this};function R(e,t){t.resumeScheduled||(t.resumeScheduled=!0,process.nextTick(re,e,t))}function re(e,t){u(`resume`,t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit(`resume`),z(e),t.flowing&&!t.reading&&e.read(0)}E.prototype.pause=function(){return u(`call pause flowing=%j`,this._readableState.flowing),this._readableState.flowing!==!1&&(u(`pause`),this._readableState.flowing=!1,this.emit(`pause`)),this._readableState.paused=!0,this};function z(e){var t=e._readableState;for(u(`flow`,t.flowing);t.flowing&&e.read()!==null;);}E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on(`end`,function(){if(u(`wrapped end`),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on(`data`,function(i){u(`wrapped data`),n.decoder&&(i=n.decoder.write(i)),!(n.objectMode&&i==null)&&(!n.objectMode&&(!i||!i.length)||t.push(i)||(r=!0,e.pause()))}),e)this[i]===void 0&&typeof e[i]==`function`&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var a=0;a=t.length?(n=t.decoder?t.buffer.join(``):t.buffer.length===1?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):n=t.buffer.consume(e,t.decoder),n}function V(e){var t=e._readableState;u(`endReadable`,t.endEmitted),t.endEmitted||(t.ended=!0,process.nextTick(ie,t,e))}function ie(e,t){if(u(`endReadableNT`,e.endEmitted,e.length),!e.endEmitted&&e.length===0&&(e.endEmitted=!0,t.readable=!1,t.emit(`end`),e.autoDestroy)){var n=t._writableState;(!n||n.autoDestroy&&n.finished)&&t.destroy()}}typeof Symbol==`function`&&(E.from=function(e,t){return x===void 0&&(x=St()),x(E,e,t)});function H(e,t){for(var n=0,r=e.length;n{t.exports=l;var n=Q().codes,r=n.ERR_METHOD_NOT_IMPLEMENTED,i=n.ERR_MULTIPLE_CALLBACK,a=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,o=n.ERR_TRANSFORM_WITH_LENGTH_0,s=$();Z()(l,s);function c(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(r===null)return this.emit(`error`,new i);n.writechunk=null,n.writecb=null,t!=null&&this.push(t),r(e);var a=this._readableState;a.reading=!1,(a.needReadable||a.length{t.exports=r;var n=wt();Z()(r,n);function r(e){if(!(this instanceof r))return new r(e);n.call(this,e)}r.prototype._transform=function(e,t,n){n(null,e)}})),Et=e(((e,t)=>{var n;function r(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}var i=Q().codes,a=i.ERR_MISSING_ARGS,o=i.ERR_STREAM_DESTROYED;function s(e){if(e)throw e}function c(e){return e.setHeader&&typeof e.abort==`function`}function l(e,t,i,a){a=r(a);var s=!1;e.on(`close`,function(){s=!0}),n===void 0&&(n=bt()),n(e,{readable:t,writable:i},function(e){if(e)return a(e);s=!0,a()});var l=!1;return function(t){if(!s&&!l){if(l=!0,c(e))return e.abort();if(typeof e.destroy==`function`)return e.destroy();a(t||new o(`pipe`))}}}function u(e){e()}function d(e,t){return e.pipe(t)}function f(e){return!e.length||typeof e[e.length-1]!=`function`?s:e.pop()}function p(){var e=[...arguments],t=f(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new a(`streams`);var n,r=e.map(function(i,a){var o=a0,function(e){n||=e,e&&r.forEach(u),!o&&(r.forEach(u),t(n))})});return e.reduce(d)}t.exports=p})),Dt=e(((e,t)=>{t.exports=r;var n=at().EventEmitter;Z()(r,n),r.Readable=Ct(),r.Writable=_t(),r.Duplex=$(),r.Transform=wt(),r.PassThrough=Tt(),r.finished=bt(),r.pipeline=Et(),r.Stream=r;function r(){n.call(this)}r.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}r.on(`data`,i);function a(){r.readable&&r.resume&&r.resume()}e.on(`drain`,a),!e._isStdio&&(!t||t.end!==!1)&&(r.on(`end`,s),r.on(`close`,c));var o=!1;function s(){o||(o=!0,e.end())}function c(){o||(o=!0,typeof e.destroy==`function`&&e.destroy())}function l(e){if(u(),n.listenerCount(this,`error`)===0)throw e}r.on(`error`,l),e.on(`error`,l);function u(){r.removeListener(`data`,i),e.removeListener(`drain`,a),r.removeListener(`end`,s),r.removeListener(`close`,c),r.removeListener(`error`,l),e.removeListener(`error`,l),r.removeListener(`end`,u),r.removeListener(`close`,u),e.removeListener(`close`,u)}return r.on(`end`,u),r.on(`close`,u),e.on(`close`,u),e.emit(`pipe`,r),e}}));async function*Ot(e,t,n){let r=1,i={chunks:[],length:0};for await(let a of n(e))for(i.chunks.push(a),i.length+=a.byteLength;i.length>t;){let e=i.chunks.length>1?Y.Buffer.concat(i.chunks):i.chunks[0];yield{partNumber:r,data:e.subarray(0,t)},i.chunks=[e.subarray(t)],i.length=i.chunks[0].byteLength,r+=1}yield{partNumber:r,data:i.chunks.length===1?i.chunks[0]:Y.Buffer.concat(i.chunks),lastPart:!0}}async function*kt(e,t){let n=1,r=0,i=t;for(;i{if(e instanceof Uint8Array)return kt(e,t);if(e instanceof Mt.Readable)return Ot(e,t,At);if(e instanceof String||typeof e==`string`)return kt(Y.Buffer.from(e),t);if(typeof e.stream==`function`)return Ot(e.stream(),t,jt);if(e instanceof ReadableStream)return Ot(e,t,jt);throw Error(`Body Data is unsupported format, expected data to be one of: string | Uint8Array | Buffer | Readable | ReadableStream | Blob;.`)},Pt=at(),Ft=class e extends Pt.EventEmitter{static MIN_PART_SIZE=1024*1024*5;MAX_PARTS=1e4;queueSize=4;partSize;leavePartsOnError=!1;tags=[];client;params;totalBytes;totalBytesSource;bytesUploadedSoFar;abortController;concurrentUploaders=[];createMultiPartPromise;abortMultipartUploadCommand=null;uploadedParts=[];uploadEnqueuedPartsCount=0;expectedPartsCount;uploadId;uploadEvent;isMultiPart=!0;singleUploadResult;sent=!1;constructor(t){if(super(),this.queueSize=t.queueSize||this.queueSize,this.leavePartsOnError=t.leavePartsOnError||this.leavePartsOnError,this.tags=t.tags||this.tags,this.client=t.client,this.params=t.params,!this.params)throw Error(`InputError: Upload requires params to be passed to upload.`);this.totalBytes=this.params.ContentLength??lt(this.params.Body),this.totalBytesSource=ut(this.params.Body,this.params.ContentLength),this.bytesUploadedSoFar=0,this.abortController=t.abortController??new AbortController,this.partSize=t.partSize||Math.max(e.MIN_PART_SIZE,Math.floor((this.totalBytes||0)/this.MAX_PARTS)),this.totalBytes!==void 0&&(this.expectedPartsCount=Math.ceil(this.totalBytes/this.partSize)),this.__validateInput()}async abort(){this.abortController.abort()}async done(){if(this.sent)throw Error(`@aws-sdk/lib-storage: this instance of Upload has already executed .done(). Create a new instance.`);return this.sent=!0,await Promise.race([this.__doMultipartUpload(),this.__abortTimeout(this.abortController.signal)])}on(e,t){return this.uploadEvent=e,super.on(e,t)}async __uploadUsingPut(e){this.isMultiPart=!1;let t={...this.params,Body:e.data},n=this.client.config,r=n.requestHandler,i=r instanceof Pt.EventEmitter?r:null,o=t=>{this.bytesUploadedSoFar=t.loaded,this.totalBytes=t.total,this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:e.partNumber,Key:this.params.Key,Bucket:this.params.Bucket})};i!==null&&i.on(`xhr.upload.progress`,o);let s=await Promise.all([this.client.send(new tt(t)),n?.endpoint?.()]),c=s[0],u=s[1];if(u||=O(await l(t,tt,{...n})),!u)throw Error(`Could not resolve endpoint from S3 "client.config.endpoint()" nor EndpointsV2.`);i!==null&&i.off(`xhr.upload.progress`,o);let d=this.params.Key.split(`/`).map(e=>a(e)).join(`/`),f=a(this.params.Bucket),p=(()=>{let e=u.hostname.startsWith(`${f}.`),t=this.client.config.forcePathStyle,n=u.port?`:${u.port}`:``;return t?`${u.protocol}//${u.hostname}${n}/${f}/${d}`:e?`${u.protocol}//${u.hostname}${n}/${d}`:`${u.protocol}//${f}.${u.hostname}${n}/${d}`})();this.singleUploadResult={...c,Bucket:this.params.Bucket,Key:this.params.Key,Location:p};let m=lt(e.data);this.__notifyProgress({loaded:m,total:m,part:1,Key:this.params.Key,Bucket:this.params.Bucket})}async __createMultipartUpload(){let e=await this.client.config.requestChecksumCalculation();if(!this.createMultiPartPromise){let t={...this.params,Body:void 0};e===`WHEN_SUPPORTED`&&(t.ChecksumAlgorithm=this.params.ChecksumAlgorithm||it.CRC32),this.createMultiPartPromise=this.client.send(new $e(t)).then(e=>(this.abortMultipartUploadCommand=new We({Bucket:this.params.Bucket,Key:this.params.Key,UploadId:e.UploadId}),e))}return this.createMultiPartPromise}async __doConcurrentUpload(e){for await(let t of e){if(this.uploadEnqueuedPartsCount>this.MAX_PARTS)throw Error(`Exceeded ${this.MAX_PARTS} parts in multipart upload to Bucket: ${this.params.Bucket} Key: ${this.params.Key}.`);if(this.abortController.signal.aborted)return;if(t.partNumber===1&&t.lastPart)return await this.__uploadUsingPut(t);if(!this.uploadId){let{UploadId:e}=await this.__createMultipartUpload();if(this.uploadId=e,this.abortController.signal.aborted)return}let e=lt(t.data)||0,n=this.client.config.requestHandler,r=n instanceof Pt.EventEmitter?n:null,i=0,a=(n,r)=>{(Number(r.query.partNumber)||-1)===t.partNumber&&(n.total&&e&&(this.bytesUploadedSoFar+=n.loaded-i,i=n.loaded),this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:t.partNumber,Key:this.params.Key,Bucket:this.params.Bucket}))};r!==null&&r.on(`xhr.upload.progress`,a),this.uploadEnqueuedPartsCount+=1,this.__validateUploadPart(t);let o=await this.client.send(new rt({...this.params,ContentLength:void 0,UploadId:this.uploadId,Body:t.data,PartNumber:t.partNumber}));if(r!==null&&r.off(`xhr.upload.progress`,a),this.abortController.signal.aborted)return;if(!o.ETag)throw Error(`Part ${t.partNumber} is missing ETag in UploadPart response. Missing Bucket CORS configuration for ETag header?`);this.uploadedParts.push({PartNumber:t.partNumber,ETag:o.ETag,...o.ChecksumCRC32&&{ChecksumCRC32:o.ChecksumCRC32},...o.ChecksumCRC32C&&{ChecksumCRC32C:o.ChecksumCRC32C},...o.ChecksumSHA1&&{ChecksumSHA1:o.ChecksumSHA1},...o.ChecksumSHA256&&{ChecksumSHA256:o.ChecksumSHA256}}),r===null&&(this.bytesUploadedSoFar+=e),this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:t.partNumber,Key:this.params.Key,Bucket:this.params.Bucket})}}async __doMultipartUpload(){let e=Nt(this.params.Body,this.partSize),t=[];for(let n=0;n{t.push(e)});this.concurrentUploaders.push(n)}if(await Promise.all(this.concurrentUploaders),t.length>=1)throw await this.markUploadAsAborted(),t[0];if(this.abortController.signal.aborted)throw await this.markUploadAsAborted(),Object.assign(Error(`Upload aborted.`),{name:`AbortError`});let n;if(this.isMultiPart){let{expectedPartsCount:e,uploadedParts:t,totalBytes:r,totalBytesSource:i}=this;if(r!==void 0&&e!==void 0&&t.length!==e)throw Error(`Expected ${e} part(s) but uploaded ${t.length} part(s). +import{i as e,t}from"./compiler-runtime.js";import{n}from"./QueryClientProvider.js";import{n as r}from"./error-banner.js";import{Bt as i,Gt as a,Ht as o,Jt as s,Lt as c,Rt as l,S as u,Vt as d,_ as f,a as p,b as m,c as h,g,h as _,i as v,l as y,m as b,o as x,p as S,qt as C,s as w,v as T,x as E,y as D,zt as O}from"./awsClient.js";import{_ as ee,a as k,c as A,d as j,f as te,g as M,h as ne,i as N,p as P,v as F}from"./SignatureV4.js";var I=typeof ReadableStream==`function`?ReadableStream:function(){},L=class extends I{},R=({expectedChecksum:e,checksum:t,source:n,checksumSourceLocation:r,base64Encoder:i})=>{if(!C(n))throw Error(`@smithy/util-stream: unsupported source type ${n?.constructor?.name??n} in ChecksumStream.`);let a=i??s;if(typeof TransformStream!=`function`)throw Error(`@smithy/util-stream: unable to instantiate ChecksumStream because API unavailable: ReadableStream/TransformStream.`);let o=new TransformStream({start(){},async transform(e,n){t.update(e),n.enqueue(e)},async flush(n){let i=a(await t.digest());if(e!==i){let t=Error(`Checksum mismatch: expected "${e}" but received "${i}" in response header "${r}".`);n.error(t)}else n.terminate()}});n.pipeThrough(o);let c=o.readable;return Object.setPrototypeOf(c,L.prototype),c},re=class{allocByteArray;byteLength=0;byteArrays=[];constructor(e){this.allocByteArray=e}push(e){this.byteArrays.push(e),this.byteLength+=e.byteLength}flush(){if(this.byteArrays.length===1){let e=this.byteArrays[0];return this.reset(),e}let e=this.allocByteArray(this.byteLength),t=0;for(let n=0;nnew Uint8Array(e))],s=-1,c=async e=>{let{value:l,done:u}=await r.read(),d=l;if(u){if(s!==-1){let t=ie(o,s);H(t)>0&&e.enqueue(t)}e.close()}else{let r=U(d,!1);if(s!==r&&(s>=0&&e.enqueue(ie(o,s)),s=r),s===-1){e.enqueue(d);return}let l=H(d);a+=l;let u=H(o[s]);if(l>=t&&u===0)e.enqueue(d);else{let r=V(o,s,d);!i&&a>t*2&&(i=!0,n?.warn(`@smithy/util-stream - stream chunk size ${l} is below threshold of ${t}, automatically buffering.`)),r>=t?e.enqueue(ie(o,s)):await c(e)}}};return new ReadableStream({pull:c})}var B=z;function V(e,t,n){switch(t){case 0:return e[0]+=n,H(e[0]);case 1:case 2:return e[t].push(n),H(e[t])}}function ie(e,t){switch(t){case 0:let n=e[0];return e[0]=``,n;case 1:case 2:return e[t].flush()}throw Error(`@smithy/util-stream - invalid index ${t} given to flush()`)}function H(e){return e?.byteLength??e?.length??0}function U(e,t=!0){return t&&typeof Buffer<`u`&&e instanceof Buffer?2:e instanceof Uint8Array?1:typeof e==`string`?0:-1}var W=(e,{requestChecksumRequired:t,requestAlgorithmMember:n,requestChecksumCalculation:r})=>{if(!n)return r===E.WHEN_SUPPORTED||t?m:void 0;if(e[n])return e[n]},G=e=>e===D.MD5?`content-md5`:`x-amz-checksum-${e.toLowerCase()}`,ae=(e,t)=>{let n=e.toLowerCase();for(let e of Object.keys(t))if(n===e.toLowerCase())return!0;return!1},oe=(e,t)=>{let n=e.toLowerCase();for(let e of Object.keys(t))if(e.toLowerCase().startsWith(n))return!0;return!1},se=e=>e!==void 0&&typeof e!=`string`&&!ArrayBuffer.isView(e)&&!N(e),ce=function(){function e(){this.crc32c=new le}return e.prototype.update=function(e){ee(e)||this.crc32c.update(F(e))},e.prototype.digest=function(){return j(this,void 0,void 0,function(){return te(this,function(e){return[2,M(this.crc32c.digest())]})})},e.prototype.reset=function(){this.crc32c=new le},e}(),le=function(){function e(){this.checksum=4294967295}return e.prototype.update=function(e){var t,n;try{for(var r=P(e),i=r.next();!i.done;i=r.next()){var a=i.value;this.checksum=this.checksum>>>8^ue[(this.checksum^a)&255]}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}return this},e.prototype.digest=function(){return(this.checksum^4294967295)>>>0},e}(),ue=ne([0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697]),de=()=>{let e=Array(8);for(let t=0;t<8;t++){let n=Array(512);for(let e=0;e<256;e++){let r=BigInt(e);for(let e=0;e<8*(t+1);e++)r&1n?r=r>>1n^11127430586519243189n:r>>=1n;n[e*2]=Number(r>>32n&4294967295n),n[e*2+1]=Number(r&4294967295n)}e[t]=new Uint32Array(n)}return e},fe,K,pe,me,he,ge,_e,ve,ye,be=()=>{fe||(fe=de(),[K,pe,me,he,ge,_e,ve,ye]=fe)},xe=class{c1=0;c2=0;constructor(){be(),this.reset()}update(e){let t=e.length,n=0,r=this.c1,i=this.c2;for(;n+8<=t;){let t=((i^e[n++])&255)<<1,a=((i>>>8^e[n++])&255)<<1,o=((i>>>16^e[n++])&255)<<1,s=((i>>>24^e[n++])&255)<<1,c=((r^e[n++])&255)<<1,l=((r>>>8^e[n++])&255)<<1,u=((r>>>16^e[n++])&255)<<1,d=((r>>>24^e[n++])&255)<<1;r=ye[t]^ve[a]^_e[o]^ge[s]^he[c]^me[l]^pe[u]^K[d],i=ye[t+1]^ve[a+1]^_e[o+1]^ge[s+1]^he[c+1]^me[l+1]^pe[u+1]^K[d+1]}for(;n>>8|(r&255)<<24)>>>0,r=r>>>8^K[t],i^=K[t+1],n++}this.c1=r,this.c2=i}async digest(){let e=this.c1^4294967295,t=this.c2^4294967295;return new Uint8Array([e>>>24,e>>>16&255,e>>>8&255,e&255,t>>>24,t>>>16&255,t>>>8&255,t&255])}reset(){this.c1=4294967295,this.c2=4294967295}},Se={CrtCrc64Nvme:null},Ce=()=>T,we=[D.CRC32,D.CRC32C,D.CRC64NVME,D.SHA1,D.SHA256],Te=[D.SHA256,D.SHA1,D.CRC32,D.CRC32C,D.CRC64NVME],Ee=(e,t)=>{let{checksumAlgorithms:n={}}=t;switch(e){case D.MD5:return n?.MD5??t.md5;case D.CRC32:return n?.CRC32??Ce();case D.CRC32C:return n?.CRC32C??ce;case D.CRC64NVME:return typeof Se.CrtCrc64Nvme==`function`?n?.CRC64NVME??Se.CrtCrc64Nvme:n?.CRC64NVME??xe;case D.SHA1:return n?.SHA1??t.sha1;case D.SHA256:return n?.SHA256??t.sha256;default:if(n?.[e])return n[e];throw Error(`The checksum algorithm "${e}" is not supported by the client. Select one of ${we}, or provide an implementation to the client constructor checksums field.`)}},De=(e,t)=>{let n=new e;return n.update(k(t||``)),n.digest()},Oe={name:`flexibleChecksumsMiddleware`,step:`build`,tags:[`BODY_CHECKSUM`],override:!0},ke=(e,t)=>(n,r)=>async i=>{if(!A.isInstance(i.request)||oe(`x-amz-checksum-`,i.request.headers))return n(i);let{request:a,input:s}=i,{body:c,headers:l}=a,{base64Encoder:u,streamHasher:d}=e,{requestChecksumRequired:f,requestAlgorithmMember:p}=t,h=await e.requestChecksumCalculation(),g=p?.name,_=p?.httpHeader;g&&!s[g]&&(h===E.WHEN_SUPPORTED||f)&&(s[g]=m,_&&(l[_]=m));let v=W(s,{requestChecksumRequired:f,requestAlgorithmMember:p?.name,requestChecksumCalculation:h}),y=c,b=l;if(v){switch(v){case D.CRC32:o(r,`FLEXIBLE_CHECKSUMS_REQ_CRC32`,`U`);break;case D.CRC32C:o(r,`FLEXIBLE_CHECKSUMS_REQ_CRC32C`,`V`);break;case D.CRC64NVME:o(r,`FLEXIBLE_CHECKSUMS_REQ_CRC64`,`W`);break;case D.SHA1:o(r,`FLEXIBLE_CHECKSUMS_REQ_SHA1`,`X`);break;case D.SHA256:o(r,`FLEXIBLE_CHECKSUMS_REQ_SHA256`,`Y`);break}let t=G(v),n=Ee(v,e);if(se(c)){let{getAwsChunkedEncodingStream:i,bodyLengthChecker:a}=e;y=i(typeof e.requestStreamBufferSize==`number`&&e.requestStreamBufferSize>=8*1024?B(c,e.requestStreamBufferSize,r.logger):c,{base64Encoder:u,bodyLengthChecker:a,checksumLocationName:t,checksumAlgorithmFn:n,streamHasher:d}),b={...l,"content-encoding":l[`content-encoding`]?`${l[`content-encoding`]},aws-chunked`:`aws-chunked`,"transfer-encoding":`chunked`,"x-amz-decoded-content-length":l[`content-length`],"x-amz-content-sha256":`STREAMING-UNSIGNED-PAYLOAD-TRAILER`,"x-amz-trailer":t},delete b[`content-length`]}else if(!ae(t,l)){let e=await De(n,c);b={...l,[t]:u(e)}}}try{return await n({...i,request:{...a,headers:b,body:y}})}catch(e){if(e instanceof Error&&e.name===`InvalidChunkSizeError`)try{e.message.endsWith(`.`)||(e.message+=`.`),e.message+=` Set [requestStreamBufferSize=number e.g. 65_536] in client constructor to instruct AWS SDK to buffer your input stream.`}catch{}throw e}},Ae={name:`flexibleChecksumsInputMiddleware`,toMiddleware:`serializerMiddleware`,relation:`before`,tags:[`BODY_CHECKSUM`],override:!0},je=(e,t)=>(n,r)=>async i=>{let a=i.input,{requestValidationModeMember:s}=t,c=await e.requestChecksumCalculation(),l=await e.responseChecksumValidation();switch(c){case E.WHEN_REQUIRED:o(r,`FLEXIBLE_CHECKSUMS_REQ_WHEN_REQUIRED`,`a`);break;case E.WHEN_SUPPORTED:o(r,`FLEXIBLE_CHECKSUMS_REQ_WHEN_SUPPORTED`,`Z`);break}switch(l){case u.WHEN_REQUIRED:o(r,`FLEXIBLE_CHECKSUMS_RES_WHEN_REQUIRED`,`c`);break;case u.WHEN_SUPPORTED:o(r,`FLEXIBLE_CHECKSUMS_RES_WHEN_SUPPORTED`,`b`);break}return s&&!a[s]&&l===u.WHEN_SUPPORTED&&(a[s]=`ENABLED`),n(i)},Me=(e=[])=>{let t=[],n=Te.length;for(let r of e){let e=Te.indexOf(r);e===-1?t[n++]=r:t[e]=r}return t.filter(Boolean)},Ne=e=>{let t=e.lastIndexOf(`-`);if(t!==-1){let n=e.slice(t+1);if(!n.startsWith(`0`)){let e=parseInt(n,10);if(!isNaN(e)&&e>=1&&e<=1e4)return!0}}return!1},Pe=async(e,{checksumAlgorithmFn:t,base64Encoder:n})=>n(await De(t,e)),Fe=async(e,{config:t,responseAlgorithms:n,logger:r})=>{let i=Me(n),{body:a,headers:o}=e;for(let n of i){let i=G(n),s=o[i];if(s){let o;try{o=Ee(n,t)}catch(e){if(n===D.CRC64NVME){r?.warn(`Skipping ${D.CRC64NVME} checksum validation: ${e.message}`);continue}throw e}let{base64Encoder:c}=t;if(se(a)){e.body=R({expectedChecksum:s,checksumSourceLocation:i,checksum:new o,source:a,base64Encoder:c});return}let l=await Pe(a,{checksumAlgorithmFn:o,base64Encoder:c});if(l===s)break;throw Error(`Checksum mismatch: expected "${l}" but received "${s}" in response header "${i}".`)}}},Ie={name:`flexibleChecksumsResponseMiddleware`,toMiddleware:`deserializerMiddleware`,relation:`after`,tags:[`BODY_CHECKSUM`],override:!0},Le=(e,t)=>(n,r)=>async i=>{if(!A.isInstance(i.request))return n(i);let a=i.input,o=await n(i),s=o.response,{requestValidationModeMember:c,responseAlgorithms:l}=t;if(c&&a[c]===`ENABLED`){let{clientName:t,commandName:n}=r,i=Object.keys(e.checksumAlgorithms??{}).filter(e=>{let t=G(e);return s.headers[t]!==void 0}),a=Me([...l??[],...i]);if(t===`S3Client`&&n===`GetObjectCommand`&&a.every(e=>{let t=G(e),n=s.headers[t];return!n||Ne(n)}))return o;await Fe(s,{config:e,responseAlgorithms:a,logger:r.logger})}return o},Re=(e,t)=>({applyToStack:n=>{n.add(ke(e,t),Oe),n.addRelativeTo(je(e,t),Ae),n.addRelativeTo(Le(e,t),Ie)}}),ze=`content-length`,Be=`x-amz-decoded-content-length`;function Ve(){return(e,t)=>async n=>{let{request:r}=n;if(A.isInstance(r)&&!(ze in r.headers)&&!(Be in r.headers)){let e=`Are you using a Stream of unknown length as the Body of a PutObject request? Consider using Upload instead from @aws-sdk/lib-storage.`;typeof t?.logger?.warn==`function`&&!(t.logger instanceof c)?t.logger.warn(e):console.warn(e)}return e({...n})}}var He={step:`finalizeRequest`,tags:[`CHECK_CONTENT_LENGTH_HEADER`],name:`getCheckContentLengthHeaderPlugin`,override:!0},Ue=e=>({applyToStack:e=>{e.add(Ve(),He)}}),We=class extends l.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[O(n,e.getEndpointParameterInstructions()),f(n)]}).s(`AmazonS3`,`AbortMultipartUpload`,{}).n(`S3Client`,`AbortMultipartUploadCommand`).sc(p).build(){};function Ge(e){return t=>async n=>{let r={...n.input};for(let t of[{target:`SSECustomerKey`,hash:`SSECustomerKeyMD5`},{target:`CopySourceSSECustomerKey`,hash:`CopySourceSSECustomerKeyMD5`}]){let n=r[t.target];if(n){let i;typeof n==`string`?qe(n,e)?i=e.base64Decoder(n):(i=e.utf8Decoder(n),r[t.target]=e.base64Encoder(i)):(i=ArrayBuffer.isView(n)?new Uint8Array(n.buffer,n.byteOffset,n.byteLength):new Uint8Array(n),r[t.target]=e.base64Encoder(i));let a=new e.md5;a.update(i),r[t.hash]=e.base64Encoder(await a.digest())}}return t({...n,input:r})}}var Ke={name:`ssecMiddleware`,step:`initialize`,tags:[`SSE`],override:!0},q=e=>({applyToStack:t=>{t.add(Ge(e),Ke)}});function qe(e,t){if(!/^(?:[A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(e))return!1;try{return t.base64Decoder(e).length===32}catch{return!1}}var Je=class extends l.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[O(n,e.getEndpointParameterInstructions()),f(n),q(n)]}).s(`AmazonS3`,`CompleteMultipartUpload`,{}).n(`S3Client`,`CompleteMultipartUploadCommand`).sc(x).build(){};function Ye(e){return t=>async n=>{let{CreateBucketConfiguration:r}=n.input,i=await e.region();return!r?.LocationConstraint&&!r?.Location&&i!==`us-east-1`&&(n.input.CreateBucketConfiguration=n.input.CreateBucketConfiguration??{},n.input.CreateBucketConfiguration.LocationConstraint=i),t(n)}}var Xe={step:`initialize`,tags:[`LOCATION_CONSTRAINT`,`CREATE_BUCKET_CONFIGURATION`],name:`locationConstraintMiddleware`,override:!0},Ze=e=>({applyToStack:t=>{t.add(Ye(e),Xe)}}),Qe=class extends l.classBuilder().ep({...g,UseS3ExpressControlEndpoint:{type:`staticContextParams`,value:!0},DisableAccessPoints:{type:`staticContextParams`,value:!0},Bucket:{type:`contextParams`,name:`Bucket`}}).m(function(e,t,n,r){return[O(n,e.getEndpointParameterInstructions()),f(n),Ze(n)]}).s(`AmazonS3`,`CreateBucket`,{}).n(`S3Client`,`CreateBucketCommand`).sc(w).build(){},$e=class extends l.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[O(n,e.getEndpointParameterInstructions()),f(n),q(n)]}).s(`AmazonS3`,`CreateMultipartUpload`,{}).n(`S3Client`,`CreateMultipartUploadCommand`).sc(h).build(){},et=class extends l.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[O(n,e.getEndpointParameterInstructions()),f(n)]}).s(`AmazonS3`,`DeleteObject`,{}).n(`S3Client`,`DeleteObjectCommand`).sc(y).build(){},tt=class extends l.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[O(n,e.getEndpointParameterInstructions()),Re(n,{requestAlgorithmMember:{httpHeader:`x-amz-sdk-checksum-algorithm`,name:`ChecksumAlgorithm`},requestChecksumRequired:!1}),Ue(n),f(n),q(n)]}).s(`AmazonS3`,`PutObject`,{}).n(`S3Client`,`PutObjectCommand`).sc(S).build(){},nt=class extends l.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`}}).m(function(e,t,n,r){return[O(n,e.getEndpointParameterInstructions()),Re(n,{requestAlgorithmMember:{httpHeader:`x-amz-sdk-checksum-algorithm`,name:`ChecksumAlgorithm`},requestChecksumRequired:!0}),f(n)]}).s(`AmazonS3`,`PutObjectTagging`,{}).n(`S3Client`,`PutObjectTaggingCommand`).sc(b).build(){},rt=class extends l.classBuilder().ep({...g,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[O(n,e.getEndpointParameterInstructions()),Re(n,{requestAlgorithmMember:{httpHeader:`x-amz-sdk-checksum-algorithm`,name:`ChecksumAlgorithm`},requestChecksumRequired:!1}),f(n),q(n)]}).s(`AmazonS3`,`UploadPart`,{}).n(`S3Client`,`UploadPartCommand`).sc(_).build(){},it={CRC32:`CRC32`,CRC32C:`CRC32C`,CRC64NVME:`CRC64NVME`,SHA1:`SHA1`,SHA256:`SHA256`},at=e(((e,t)=>{var n=typeof Reflect==`object`?Reflect:null,r=n&&typeof n.apply==`function`?n.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)},i=n&&typeof n.ownKeys==`function`?n.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};function a(e){console&&console.warn&&console.warn(e)}var o=Number.isNaN||function(e){return e!==e};function s(){s.init.call(this)}t.exports=s,t.exports.once=y,s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var c=10;function l(e){if(typeof e!=`function`)throw TypeError(`The "listener" argument must be of type Function. Received type `+typeof e)}Object.defineProperty(s,`defaultMaxListeners`,{enumerable:!0,get:function(){return c},set:function(e){if(typeof e!=`number`||e<0||o(e))throw RangeError(`The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received `+e+`.`);c=e}}),s.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},s.prototype.setMaxListeners=function(e){if(typeof e!=`number`||e<0||o(e))throw RangeError(`The value of "n" is out of range. It must be a non-negative number. Received `+e+`.`);return this._maxListeners=e,this};function u(e){return e._maxListeners===void 0?s.defaultMaxListeners:e._maxListeners}s.prototype.getMaxListeners=function(){return u(this)},s.prototype.emit=function(e){for(var t=[],n=1;n0&&(o=t[0]),o instanceof Error)throw o;var s=Error(`Unhandled error.`+(o?` (`+o.message+`)`:``));throw s.context=o,s}var c=a[e];if(c===void 0)return!1;if(typeof c==`function`)r(c,this,t);else for(var l=c.length,u=g(c,l),n=0;n0&&s.length>i&&!s.warned){s.warned=!0;var c=Error(`Possible EventEmitter memory leak detected. `+s.length+` `+String(t)+` listeners added. Use emitter.setMaxListeners() to increase limit`);c.name=`MaxListenersExceededWarning`,c.emitter=e,c.type=t,c.count=s.length,a(c)}return e}s.prototype.addListener=function(e,t){return d(this,e,t,!1)},s.prototype.on=s.prototype.addListener,s.prototype.prependListener=function(e,t){return d(this,e,t,!0)};function f(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function p(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=f.bind(r);return i.listener=n,r.wrapFn=i,i}s.prototype.once=function(e,t){return l(t),this.on(e,p(this,e,t)),this},s.prototype.prependOnceListener=function(e,t){return l(t),this.prependListener(e,p(this,e,t)),this},s.prototype.removeListener=function(e,t){var n,r,i,a,o;if(l(t),r=this._events,r===void 0||(n=r[e],n===void 0))return this;if(n===t||n.listener===t)--this._eventsCount===0?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit(`removeListener`,e,n.listener||t));else if(typeof n!=`function`){for(i=-1,a=n.length-1;a>=0;a--)if(n[a]===t||n[a].listener===t){o=n[a].listener,i=a;break}if(i<0)return this;i===0?n.shift():_(n,i),n.length===1&&(r[e]=n[0]),r.removeListener!==void 0&&this.emit(`removeListener`,e,o||t)}return this},s.prototype.off=s.prototype.removeListener,s.prototype.removeAllListeners=function(e){var t,n=this._events,r;if(n===void 0)return this;if(n.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):n[e]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete n[e]),this;if(arguments.length===0){var i=Object.keys(n),a;for(r=0;r=0;r--)this.removeListener(e,t[r]);return this};function m(e,t,n){var r=e._events;if(r===void 0)return[];var i=r[t];return i===void 0?[]:typeof i==`function`?n?[i.listener||i]:[i]:n?v(i):g(i,i.length)}s.prototype.listeners=function(e){return m(this,e,!0)},s.prototype.rawListeners=function(e){return m(this,e,!1)},s.listenerCount=function(e,t){return typeof e.listenerCount==`function`?e.listenerCount(t):h.call(e,t)},s.prototype.listenerCount=h;function h(e){var t=this._events;if(t!==void 0){var n=t[e];if(typeof n==`function`)return 1;if(n!==void 0)return n.length}return 0}s.prototype.eventNames=function(){return this._eventsCount>0?i(this._events):[]};function g(e,t){for(var n=Array(t),r=0;r{e.byteLength=c,e.toByteArray=u,e.fromByteArray=p;for(var t=[],n=[],r=typeof Uint8Array<`u`?Uint8Array:Array,i=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/`,a=0,o=i.length;a0)throw Error(`Invalid string. Length must be a multiple of 4`);var n=e.indexOf(`=`);n===-1&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function c(e){var t=s(e),n=t[0],r=t[1];return(n+r)*3/4-r}function l(e,t,n){return(t+n)*3/4-n}function u(e){var t,i=s(e),a=i[0],o=i[1],c=new r(l(e,a,o)),u=0,d=o>0?a-4:a,f;for(f=0;f>16&255,c[u++]=t>>8&255,c[u++]=t&255;return o===2&&(t=n[e.charCodeAt(f)]<<2|n[e.charCodeAt(f+1)]>>4,c[u++]=t&255),o===1&&(t=n[e.charCodeAt(f)]<<10|n[e.charCodeAt(f+1)]<<4|n[e.charCodeAt(f+2)]>>2,c[u++]=t>>8&255,c[u++]=t&255),c}function d(e){return t[e>>18&63]+t[e>>12&63]+t[e>>6&63]+t[e&63]}function f(e,t,n){for(var r,i=[],a=t;ac?c:s+o));return i===1?(n=e[r-1],a.push(t[n>>2]+t[n<<4&63]+`==`)):i===2&&(n=(e[r-2]<<8)+e[r-1],a.push(t[n>>10]+t[n>>4&63]+t[n<<2&63]+`=`)),a.join(``)}})),st=e((e=>{e.read=function(e,t,n,r,i){var a,o,s=i*8-r-1,c=(1<>1,u=-7,d=n?i-1:0,f=n?-1:1,p=e[t+d];for(d+=f,a=p&(1<<-u)-1,p>>=-u,u+=s;u>0;a=a*256+e[t+d],d+=f,u-=8);for(o=a&(1<<-u)-1,a>>=-u,u+=r;u>0;o=o*256+e[t+d],d+=f,u-=8);if(a===0)a=1-l;else if(a===c)return o?NaN:(p?-1:1)*(1/0);else o+=2**r,a-=l;return(p?-1:1)*o*2**(a-r)},e.write=function(e,t,n,r,i,a){var o,s,c,l=a*8-i-1,u=(1<>1,f=i===23?2**-24-2**-77:0,p=r?0:a-1,m=r?1:-1,h=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,o=u):(o=Math.floor(Math.log(t)/Math.LN2),t*(c=2**-o)<1&&(o--,c*=2),o+d>=1?t+=f/c:t+=f*2**(1-d),t*c>=2&&(o++,c/=2),o+d>=u?(s=0,o=u):o+d>=1?(s=(t*c-1)*2**i,o+=d):(s=t*2**(d-1)*2**i,o=0));i>=8;e[n+p]=s&255,p+=m,s/=256,i-=8);for(o=o<0;e[n+p]=o&255,p+=m,o/=256,l-=8);e[n+p-m]|=h*128}})),J=e((e=>{var t=ot(),n=st(),r=typeof Symbol==`function`&&typeof Symbol.for==`function`?Symbol.for(`nodejs.util.inspect.custom`):null;e.Buffer=s,e.SlowBuffer=_,e.INSPECT_MAX_BYTES=50;var i=2147483647;e.kMaxLength=i,s.TYPED_ARRAY_SUPPORT=a(),!s.TYPED_ARRAY_SUPPORT&&typeof console<`u`&&typeof console.error==`function`&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function a(){try{var e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),e.foo()===42}catch{return!1}}Object.defineProperty(s.prototype,`parent`,{enumerable:!0,get:function(){if(s.isBuffer(this))return this.buffer}}),Object.defineProperty(s.prototype,`offset`,{enumerable:!0,get:function(){if(s.isBuffer(this))return this.byteOffset}});function o(e){if(e>i)throw RangeError(`The value "`+e+`" is invalid for option "size"`);var t=new Uint8Array(e);return Object.setPrototypeOf(t,s.prototype),t}function s(e,t,n){if(typeof e==`number`){if(typeof t==`string`)throw TypeError(`The "string" argument must be of type string. Received type number`);return d(e)}return c(e,t,n)}s.poolSize=8192;function c(e,t,n){if(typeof e==`string`)return f(e,t);if(ArrayBuffer.isView(e))return p(e);if(e==null)throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type `+typeof e);if(W(e,ArrayBuffer)||e&&W(e.buffer,ArrayBuffer)||typeof SharedArrayBuffer<`u`&&(W(e,SharedArrayBuffer)||e&&W(e.buffer,SharedArrayBuffer)))return m(e,t,n);if(typeof e==`number`)throw TypeError(`The "value" argument must not be of type number. Received type number`);var r=e.valueOf&&e.valueOf();if(r!=null&&r!==e)return s.from(r,t,n);var i=h(e);if(i)return i;if(typeof Symbol<`u`&&Symbol.toPrimitive!=null&&typeof e[Symbol.toPrimitive]==`function`)return s.from(e[Symbol.toPrimitive](`string`),t,n);throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type `+typeof e)}s.from=function(e,t,n){return c(e,t,n)},Object.setPrototypeOf(s.prototype,Uint8Array.prototype),Object.setPrototypeOf(s,Uint8Array);function l(e){if(typeof e!=`number`)throw TypeError(`"size" argument must be of type number`);if(e<0)throw RangeError(`The value "`+e+`" is invalid for option "size"`)}function u(e,t,n){return l(e),e<=0||t===void 0?o(e):typeof n==`string`?o(e).fill(t,n):o(e).fill(t)}s.alloc=function(e,t,n){return u(e,t,n)};function d(e){return l(e),o(e<0?0:g(e)|0)}s.allocUnsafe=function(e){return d(e)},s.allocUnsafeSlow=function(e){return d(e)};function f(e,t){if((typeof t!=`string`||t===``)&&(t=`utf8`),!s.isEncoding(t))throw TypeError(`Unknown encoding: `+t);var n=v(e,t)|0,r=o(n),i=r.write(e,t);return i!==n&&(r=r.slice(0,i)),r}function p(e){for(var t=e.length<0?0:g(e.length)|0,n=o(t),r=0;r=i)throw RangeError(`Attempt to allocate Buffer larger than maximum size: 0x`+i.toString(16)+` bytes`);return e|0}function _(e){return+e!=e&&(e=0),s.alloc(+e)}s.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==s.prototype},s.compare=function(e,t){if(W(e,Uint8Array)&&(e=s.from(e,e.offset,e.byteLength)),W(t,Uint8Array)&&(t=s.from(t,t.offset,t.byteLength)),!s.isBuffer(e)||!s.isBuffer(t))throw TypeError(`The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array`);if(e===t)return 0;for(var n=e.length,r=t.length,i=0,a=Math.min(n,r);i2&&arguments[2]===!0;if(!r&&n===0)return 0;for(var i=!1;;)switch(t){case`ascii`:case`latin1`:case`binary`:return n;case`utf8`:case`utf-8`:return B(e).length;case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return n*2;case`hex`:return n>>>1;case`base64`:return H(e).length;default:if(i)return r?-1:B(e).length;t=(``+t).toLowerCase(),i=!0}}s.byteLength=v;function y(e,t,n){var r=!1;if((t===void 0||t<0)&&(t=0),t>this.length||((n===void 0||n>this.length)&&(n=this.length),n<=0)||(n>>>=0,t>>>=0,n<=t))return``;for(e||=`utf8`;;)switch(e){case`hex`:return ne(this,t,n);case`utf8`:case`utf-8`:return k(this,t,n);case`ascii`:return te(this,t,n);case`latin1`:case`binary`:return M(this,t,n);case`base64`:return ee(this,t,n);case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return N(this,t,n);default:if(r)throw TypeError(`Unknown encoding: `+e);e=(e+``).toLowerCase(),r=!0}}s.prototype._isBuffer=!0;function b(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}s.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw RangeError(`Buffer size must be a multiple of 16-bits`);for(var t=0;tn&&(t+=` ... `),``},r&&(s.prototype[r]=s.prototype.inspect),s.prototype.compare=function(e,t,n,r,i){if(W(e,Uint8Array)&&(e=s.from(e,e.offset,e.byteLength)),!s.isBuffer(e))throw TypeError(`The "target" argument must be one of type Buffer or Uint8Array. Received type `+typeof e);if(t===void 0&&(t=0),n===void 0&&(n=e?e.length:0),r===void 0&&(r=0),i===void 0&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw RangeError(`out of range index`);if(r>=i&&t>=n)return 0;if(r>=i)return-1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;for(var a=i-r,o=n-t,c=Math.min(a,o),l=this.slice(r,i),u=e.slice(t,n),d=0;d2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,G(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0)if(i)n=0;else return-1;if(typeof t==`string`&&(t=s.from(t,r)),s.isBuffer(t))return t.length===0?-1:S(e,t,n,r,i);if(typeof t==`number`)return t&=255,typeof Uint8Array.prototype.indexOf==`function`?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):S(e,[t],n,r,i);throw TypeError(`val must be string, number or Buffer`)}function S(e,t,n,r,i){var a=1,o=e.length,s=t.length;if(r!==void 0&&(r=String(r).toLowerCase(),r===`ucs2`||r===`ucs-2`||r===`utf16le`||r===`utf-16le`)){if(e.length<2||t.length<2)return-1;a=2,o/=2,s/=2,n/=2}function c(e,t){return a===1?e[t]:e.readUInt16BE(t*a)}var l;if(i){var u=-1;for(l=n;lo&&(n=o-s),l=n;l>=0;l--){for(var d=!0,f=0;fi&&(r=i)):r=i;var a=t.length;r>a/2&&(r=a/2);for(var o=0;o>>=0,isFinite(n)?(n>>>=0,r===void 0&&(r=`utf8`)):(r=n,n=void 0);else throw Error(`Buffer.write(string, encoding, offset[, length]) is no longer supported`);var i=this.length-t;if((n===void 0||n>i)&&(n=i),e.length>0&&(n<0||t<0)||t>this.length)throw RangeError(`Attempt to write outside buffer bounds`);r||=`utf8`;for(var a=!1;;)switch(r){case`hex`:return C(this,e,t,n);case`utf8`:case`utf-8`:return w(this,e,t,n);case`ascii`:return T(this,e,t,n);case`latin1`:case`binary`:return E(this,e,t,n);case`base64`:return D(this,e,t,n);case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return O(this,e,t,n);default:if(a)throw TypeError(`Unknown encoding: `+r);r=(``+r).toLowerCase(),a=!0}},s.prototype.toJSON=function(){return{type:`Buffer`,data:Array.prototype.slice.call(this._arr||this,0)}};function ee(e,n,r){return n===0&&r===e.length?t.fromByteArray(e):t.fromByteArray(e.slice(n,r))}function k(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i239?4:a>223?3:a>191?2:1;if(i+s<=n){var c,l,u,d;switch(s){case 1:a<128&&(o=a);break;case 2:c=e[i+1],(c&192)==128&&(d=(a&31)<<6|c&63,d>127&&(o=d));break;case 3:c=e[i+1],l=e[i+2],(c&192)==128&&(l&192)==128&&(d=(a&15)<<12|(c&63)<<6|l&63,d>2047&&(d<55296||d>57343)&&(o=d));break;case 4:c=e[i+1],l=e[i+2],u=e[i+3],(c&192)==128&&(l&192)==128&&(u&192)==128&&(d=(a&15)<<18|(c&63)<<12|(l&63)<<6|u&63,d>65535&&d<1114112&&(o=d))}}o===null?(o=65533,s=1):o>65535&&(o-=65536,r.push(o>>>10&1023|55296),o=56320|o&1023),r.push(o),i+=s}return j(r)}var A=4096;function j(e){var t=e.length;if(t<=A)return String.fromCharCode.apply(String,e);for(var n=``,r=0;rr)&&(n=r);for(var i=``,a=t;an&&(e=n),t<0?(t+=n,t<0&&(t=0)):t>n&&(t=n),tn)throw RangeError(`Trying to access beyond buffer length`)}s.prototype.readUIntLE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e],i=1,a=0;++a>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e+--t],i=1;t>0&&(i*=256);)r+=this[e+--t]*i;return r},s.prototype.readUInt8=function(e,t){return e>>>=0,t||P(e,1,this.length),this[e]},s.prototype.readUInt16LE=function(e,t){return e>>>=0,t||P(e,2,this.length),this[e]|this[e+1]<<8},s.prototype.readUInt16BE=function(e,t){return e>>>=0,t||P(e,2,this.length),this[e]<<8|this[e+1]},s.prototype.readUInt32LE=function(e,t){return e>>>=0,t||P(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216},s.prototype.readUInt32BE=function(e,t){return e>>>=0,t||P(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])},s.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=this[e],i=1,a=0;++a=i&&(r-=2**(8*t)),r},s.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||P(e,t,this.length);for(var r=t,i=1,a=this[e+--r];r>0&&(i*=256);)a+=this[e+--r]*i;return i*=128,a>=i&&(a-=2**(8*t)),a},s.prototype.readInt8=function(e,t){return e>>>=0,t||P(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]},s.prototype.readInt16LE=function(e,t){e>>>=0,t||P(e,2,this.length);var n=this[e]|this[e+1]<<8;return n&32768?n|4294901760:n},s.prototype.readInt16BE=function(e,t){e>>>=0,t||P(e,2,this.length);var n=this[e+1]|this[e]<<8;return n&32768?n|4294901760:n},s.prototype.readInt32LE=function(e,t){return e>>>=0,t||P(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},s.prototype.readInt32BE=function(e,t){return e>>>=0,t||P(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},s.prototype.readFloatLE=function(e,t){return e>>>=0,t||P(e,4,this.length),n.read(this,e,!0,23,4)},s.prototype.readFloatBE=function(e,t){return e>>>=0,t||P(e,4,this.length),n.read(this,e,!1,23,4)},s.prototype.readDoubleLE=function(e,t){return e>>>=0,t||P(e,8,this.length),n.read(this,e,!0,52,8)},s.prototype.readDoubleBE=function(e,t){return e>>>=0,t||P(e,8,this.length),n.read(this,e,!1,52,8)};function F(e,t,n,r,i,a){if(!s.isBuffer(e))throw TypeError(`"buffer" argument must be a Buffer instance`);if(t>i||te.length)throw RangeError(`Index out of range`)}s.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){var i=2**(8*n)-1;F(this,e,t,n,i,0)}var a=1,o=0;for(this[t]=e&255;++o>>=0,n>>>=0,!r){var i=2**(8*n)-1;F(this,e,t,n,i,0)}var a=n-1,o=1;for(this[t+a]=e&255;--a>=0&&(o*=256);)this[t+a]=e/o&255;return t+n},s.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,1,255,0),this[t]=e&255,t+1},s.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,2,65535,0),this[t]=e&255,this[t+1]=e>>>8,t+2},s.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=e&255,t+2},s.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=e&255,t+4},s.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4},s.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=2**(8*n-1);F(this,e,t,n,i-1,-i)}var a=0,o=1,s=0;for(this[t]=e&255;++a>0)-s&255;return t+n},s.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=2**(8*n-1);F(this,e,t,n,i-1,-i)}var a=n-1,o=1,s=0;for(this[t+a]=e&255;--a>=0&&(o*=256);)e<0&&s===0&&this[t+a+1]!==0&&(s=1),this[t+a]=(e/o>>0)-s&255;return t+n},s.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=e&255,t+1},s.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,2,32767,-32768),this[t]=e&255,this[t+1]=e>>>8,t+2},s.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=e&255,t+2},s.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,4,2147483647,-2147483648),this[t]=e&255,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},s.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||F(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};function I(e,t,n,r,i,a){if(n+r>e.length||n<0)throw RangeError(`Index out of range`)}function L(e,t,r,i,a){return t=+t,r>>>=0,a||I(e,t,r,4,34028234663852886e22,-34028234663852886e22),n.write(e,t,r,i,23,4),r+4}s.prototype.writeFloatLE=function(e,t,n){return L(this,e,t,!0,n)},s.prototype.writeFloatBE=function(e,t,n){return L(this,e,t,!1,n)};function R(e,t,r,i,a){return t=+t,r>>>=0,a||I(e,t,r,8,17976931348623157e292,-17976931348623157e292),n.write(e,t,r,i,52,8),r+8}s.prototype.writeDoubleLE=function(e,t,n){return R(this,e,t,!0,n)},s.prototype.writeDoubleBE=function(e,t,n){return R(this,e,t,!1,n)},s.prototype.copy=function(e,t,n,r){if(!s.isBuffer(e))throw TypeError(`argument should be a Buffer`);if(n||=0,!r&&r!==0&&(r=this.length),t>=e.length&&(t=e.length),t||=0,r>0&&r=this.length)throw RangeError(`Index out of range`);if(r<0)throw RangeError(`sourceEnd out of bounds`);r>this.length&&(r=this.length),e.length-t=0;--a)e[a+t]=this[a+n];else Uint8Array.prototype.set.call(e,this.subarray(n,r),t);return i},s.prototype.fill=function(e,t,n,r){if(typeof e==`string`){if(typeof t==`string`?(r=t,t=0,n=this.length):typeof n==`string`&&(r=n,n=this.length),r!==void 0&&typeof r!=`string`)throw TypeError(`encoding must be a string`);if(typeof r==`string`&&!s.isEncoding(r))throw TypeError(`Unknown encoding: `+r);if(e.length===1){var i=e.charCodeAt(0);(r===`utf8`&&i<128||r===`latin1`)&&(e=i)}}else typeof e==`number`?e&=255:typeof e==`boolean`&&(e=Number(e));if(t<0||this.length>>=0,n=n===void 0?this.length:n>>>0,e||=0;var a;if(typeof e==`number`)for(a=t;a55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&a.push(239,191,189);continue}else if(o+1===r){(t-=3)>-1&&a.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&a.push(239,191,189),i=n;continue}n=(i-55296<<10|n-56320)+65536}else i&&(t-=3)>-1&&a.push(239,191,189);if(i=null,n<128){if(--t<0)break;a.push(n)}else if(n<2048){if((t-=2)<0)break;a.push(n>>6|192,n&63|128)}else if(n<65536){if((t-=3)<0)break;a.push(n>>12|224,n>>6&63|128,n&63|128)}else if(n<1114112){if((t-=4)<0)break;a.push(n>>18|240,n>>12&63|128,n>>6&63|128,n&63|128)}else throw Error(`Invalid code point`)}return a}function V(e){for(var t=[],n=0;n>8,i=n%256,a.push(i),a.push(r);return a}function H(e){return t.toByteArray(z(e))}function U(e,t,n,r){for(var i=0;i=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function W(e,t){return e instanceof t||e!=null&&e.constructor!=null&&e.constructor.name!=null&&e.constructor.name===t.name}function G(e){return e!==e}var ae=(function(){for(var e=`0123456789abcdef`,t=Array(256),n=0;n<16;++n)for(var r=n*16,i=0;i<16;++i)t[r+i]=e[n]+e[i];return t})()})),ct={lstatSync:()=>{},isFileReadStream(e){return!1},runtime:`browser`},Y=J(),lt=e=>{if(e==null)return 0;if(typeof e==`string`)return Y.Buffer.byteLength(e);if(typeof e.byteLength==`number`)return e.byteLength;if(typeof e.length==`number`)return e.length;if(typeof e.size==`number`)return e.size;if(typeof e.start==`number`&&typeof e.end==`number`)return e.end+1-e.start;if(ct.isFileReadStream(e))try{return ct.lstatSync(e.path).size}catch{return}},X;(function(e){e.EMPTY_INPUT=`a null or undefined Body`,e.CONTENT_LENGTH=`the ContentLength property of the params set by the caller`,e.STRING_LENGTH=`the encoded byte length of the Body string`,e.TYPED_ARRAY=`the byteLength of a typed byte array such as Uint8Array`,e.LENGTH=`the value of Body.length`,e.SIZE=`the value of Body.size`,e.START_END_DIFF=`the numeric difference between Body.start and Body.end`,e.LSTAT=`the size of the file given by Body.path on disk as reported by lstatSync`})(X||={});var ut=(e,t)=>{if(t!=null)return X.CONTENT_LENGTH;if(e==null)return X.EMPTY_INPUT;if(typeof e==`string`)return X.STRING_LENGTH;if(typeof e.byteLength==`number`)return X.TYPED_ARRAY;if(typeof e.length==`number`)return X.LENGTH;if(typeof e.size==`number`)return X.SIZE;if(typeof e.start==`number`&&typeof e.end==`number`)return X.START_END_DIFF;if(ct.isFileReadStream(e))try{return ct.lstatSync(e.path).size,X.LSTAT}catch{return}},Z=e(((e,t)=>{typeof Object.create==`function`?t.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(e,t){if(t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}}})),dt=e(((e,t)=>{t.exports=at().EventEmitter})),ft=e(((e,t)=>{t.exports={}})),pt=e(((e,t)=>{function n(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function r(e){for(var t=1;t0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:`unshift`,value:function(e){var t={data:e,next:this.head};this.length===0&&(this.tail=t),this.head=t,++this.length}},{key:`shift`,value:function(){if(this.length!==0){var e=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:`clear`,value:function(){this.head=this.tail=null,this.length=0}},{key:`join`,value:function(e){if(this.length===0)return``;for(var t=this.head,n=``+t.data;t=t.next;)n+=e+t.data;return n}},{key:`concat`,value:function(e){if(this.length===0)return u.alloc(0);for(var t=u.allocUnsafe(e>>>0),n=this.head,r=0;n;)p(n.data,t,r),r+=n.data.length,n=n.next;return t}},{key:`consume`,value:function(e,t){var n;return ei.length?i.length:e;if(a===i.length?r+=i:r+=i.slice(0,e),e-=a,e===0){a===i.length?(++n,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(a));break}++n}return this.length-=n,r}},{key:`_getBuffer`,value:function(e){var t=u.allocUnsafe(e),n=this.head,r=1;for(n.data.copy(t),e-=n.data.length;n=n.next;){var i=n.data,a=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,a),e-=a,e===0){a===i.length?(++r,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=i.slice(a));break}++r}return this.length-=r,t}},{key:f,value:function(e,t){return d(this,r(r({},t),{},{depth:0,customInspect:!1}))}}]),e}()})),mt=e(((e,t)=>{function n(e,t){var n=this,a=this._readableState&&this._readableState.destroyed,s=this._writableState&&this._writableState.destroyed;return a||s?(t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(o,this,e)):process.nextTick(o,this,e)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?n._writableState?n._writableState.errorEmitted?process.nextTick(i,n):(n._writableState.errorEmitted=!0,process.nextTick(r,n,e)):process.nextTick(r,n,e):t?(process.nextTick(i,n),t(e)):process.nextTick(i,n)}),this)}function r(e,t){o(e,t),i(e)}function i(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit(`close`)}function a(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function o(e,t){e.emit(`error`,t)}function s(e,t){var n=e._readableState,r=e._writableState;n&&n.autoDestroy||r&&r.autoDestroy?e.destroy(t):e.emit(`error`,t)}t.exports={destroy:n,undestroy:a,errorOrDestroy:s}})),Q=e(((e,t)=>{function n(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var r={};function i(e,t,i){i||=Error;function a(e,n,r){return typeof t==`string`?t:t(e,n,r)}var o=function(e){n(t,e);function t(t,n,r){return e.call(this,a(t,n,r))||this}return t}(i);o.prototype.name=i.name,o.prototype.code=e,r[e]=o}function a(e,t){if(Array.isArray(e)){var n=e.length;return e=e.map(function(e){return String(e)}),n>2?`one of ${t} ${e.slice(0,n-1).join(`, `)}, or `+e[n-1]:n===2?`one of ${t} ${e[0]} or ${e[1]}`:`of ${t} ${e[0]}`}else return`of ${t} ${String(e)}`}function o(e,t,n){return e.substr(!n||n<0?0:+n,t.length)===t}function s(e,t,n){return(n===void 0||n>e.length)&&(n=e.length),e.substring(n-t.length,n)===t}function c(e,t,n){return typeof n!=`number`&&(n=0),n+t.length>e.length?!1:e.indexOf(t,n)!==-1}i(`ERR_INVALID_OPT_VALUE`,function(e,t){return`The value "`+t+`" is invalid for option "`+e+`"`},TypeError),i(`ERR_INVALID_ARG_TYPE`,function(e,t,n){var r;typeof t==`string`&&o(t,`not `)?(r=`must not be`,t=t.replace(/^not /,``)):r=`must be`;var i=s(e,` argument`)?`The ${e} ${r} ${a(t,`type`)}`:`The "${e}" ${c(e,`.`)?`property`:`argument`} ${r} ${a(t,`type`)}`;return i+=`. Received type ${typeof n}`,i},TypeError),i(`ERR_STREAM_PUSH_AFTER_EOF`,`stream.push() after EOF`),i(`ERR_METHOD_NOT_IMPLEMENTED`,function(e){return`The `+e+` method is not implemented`}),i(`ERR_STREAM_PREMATURE_CLOSE`,`Premature close`),i(`ERR_STREAM_DESTROYED`,function(e){return`Cannot call `+e+` after a stream was destroyed`}),i(`ERR_MULTIPLE_CALLBACK`,`Callback called multiple times`),i(`ERR_STREAM_CANNOT_PIPE`,`Cannot pipe, not readable`),i(`ERR_STREAM_WRITE_AFTER_END`,`write after end`),i(`ERR_STREAM_NULL_VALUES`,`May not write null values to stream`,TypeError),i(`ERR_UNKNOWN_ENCODING`,function(e){return`Unknown encoding: `+e},TypeError),i(`ERR_STREAM_UNSHIFT_AFTER_END_EVENT`,`stream.unshift() after end event`),t.exports.codes=r})),ht=e(((e,t)=>{var n=Q().codes.ERR_INVALID_OPT_VALUE;function r(e,t,n){return e.highWaterMark==null?t?e[n]:null:e.highWaterMark}function i(e,t,i,a){var o=r(t,a,i);if(o!=null){if(!(isFinite(o)&&Math.floor(o)===o)||o<0)throw new n(a?i:`highWaterMark`,o);return Math.floor(o)}return e.objectMode?16:16*1024}t.exports={getHighWaterMark:i}})),gt=e(((e,t)=>{t.exports=n;function n(e,t){if(r(`noDeprecation`))return e;var n=!1;function i(){if(!n){if(r(`throwDeprecation`))throw Error(t);r(`traceDeprecation`)?console.trace(t):console.warn(t),n=!0}return e.apply(this,arguments)}return i}function r(e){try{if(!global.localStorage)return!1}catch{return!1}var t=global.localStorage[e];return t==null?!1:String(t).toLowerCase()===`true`}})),_t=e(((e,t)=>{t.exports=T;function n(e){var t=this;this.next=null,this.entry=null,this.finish=function(){re(t,e)}}var r;T.WritableState=C;var i={deprecate:gt()},a=dt(),o=J().Buffer,s=(typeof global<`u`?global:typeof window<`u`?window:typeof self<`u`?self:{}).Uint8Array||function(){};function c(e){return o.from(e)}function l(e){return o.isBuffer(e)||e instanceof s}var u=mt(),d=ht().getHighWaterMark,f=Q().codes,p=f.ERR_INVALID_ARG_TYPE,m=f.ERR_METHOD_NOT_IMPLEMENTED,h=f.ERR_MULTIPLE_CALLBACK,g=f.ERR_STREAM_CANNOT_PIPE,_=f.ERR_STREAM_DESTROYED,v=f.ERR_STREAM_NULL_VALUES,y=f.ERR_STREAM_WRITE_AFTER_END,b=f.ERR_UNKNOWN_ENCODING,x=u.errorOrDestroy;Z()(T,a);function S(){}function C(e,t,i){r||=$(),e||={},typeof i!=`boolean`&&(i=t instanceof r),this.objectMode=!!e.objectMode,i&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=d(this,e,`writableHighWaterMark`,i),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1,this.decodeStrings=e.decodeStrings!==!1,this.defaultEncoding=e.defaultEncoding||`utf8`,this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){te(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=e.emitClose!==!1,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new n(this)}C.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},(function(){try{Object.defineProperty(C.prototype,`buffer`,{get:i.deprecate(function(){return this.getBuffer()},`_writableState.buffer is deprecated. Use _writableState.getBuffer instead.`,`DEP0003`)})}catch{}})();var w;typeof Symbol==`function`&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]==`function`?(w=Function.prototype[Symbol.hasInstance],Object.defineProperty(T,Symbol.hasInstance,{value:function(e){return w.call(this,e)?!0:this===T?e&&e._writableState instanceof C:!1}})):w=function(e){return e instanceof this};function T(e){r||=$();var t=this instanceof r;if(!t&&!w.call(T,this))return new T(e);this._writableState=new C(e,this,t),this.writable=!0,e&&(typeof e.write==`function`&&(this._write=e.write),typeof e.writev==`function`&&(this._writev=e.writev),typeof e.destroy==`function`&&(this._destroy=e.destroy),typeof e.final==`function`&&(this._final=e.final)),a.call(this)}T.prototype.pipe=function(){x(this,new g)};function E(e,t){var n=new y;x(e,n),process.nextTick(t,n)}function D(e,t,n,r){var i;return n===null?i=new v:typeof n!=`string`&&!t.objectMode&&(i=new p(`chunk`,[`string`,`Buffer`],n)),i?(x(e,i),process.nextTick(r,i),!1):!0}T.prototype.write=function(e,t,n){var r=this._writableState,i=!1,a=!r.objectMode&&l(e);return a&&!o.isBuffer(e)&&(e=c(e)),typeof t==`function`&&(n=t,t=null),a?t=`buffer`:t||=r.defaultEncoding,typeof n!=`function`&&(n=S),r.ending?E(this,n):(a||D(this,r,e,n))&&(r.pendingcb++,i=ee(this,r,a,e,t,n)),i},T.prototype.cork=function(){this._writableState.corked++},T.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,!e.writing&&!e.corked&&!e.bufferProcessing&&e.bufferedRequest&&N(this,e))},T.prototype.setDefaultEncoding=function(e){if(typeof e==`string`&&(e=e.toLowerCase()),!([`hex`,`utf8`,`utf-8`,`ascii`,`binary`,`base64`,`ucs2`,`ucs-2`,`utf16le`,`utf-16le`,`raw`].indexOf((e+``).toLowerCase())>-1))throw new b(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(T.prototype,`writableBuffer`,{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function O(e,t,n){return!e.objectMode&&e.decodeStrings!==!1&&typeof t==`string`&&(t=o.from(t,n)),t}Object.defineProperty(T.prototype,`writableHighWaterMark`,{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function ee(e,t,n,r,i,a){if(!n){var o=O(t,r,i);r!==o&&(n=!0,i=`buffer`,r=o)}var s=t.objectMode?1:r.length;t.length+=s;var c=t.length{var n=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};t.exports=c;var r=Ct(),i=_t();Z()(c,r);for(var a=n(i.prototype),o=0;o{var n=J(),r=n.Buffer;function i(e,t){for(var n in e)t[n]=e[n]}r.from&&r.alloc&&r.allocUnsafe&&r.allocUnsafeSlow?t.exports=n:(i(n,e),e.Buffer=a);function a(e,t,n){return r(e,t,n)}a.prototype=Object.create(r.prototype),i(r,a),a.from=function(e,t,n){if(typeof e==`number`)throw TypeError(`Argument must not be a number`);return r(e,t,n)},a.alloc=function(e,t,n){if(typeof e!=`number`)throw TypeError(`Argument must be a number`);var i=r(e);return t===void 0?i.fill(0):typeof n==`string`?i.fill(t,n):i.fill(t),i},a.allocUnsafe=function(e){if(typeof e!=`number`)throw TypeError(`Argument must be a number`);return r(e)},a.allocUnsafeSlow=function(e){if(typeof e!=`number`)throw TypeError(`Argument must be a number`);return n.SlowBuffer(e)}})),yt=e((e=>{var t=vt().Buffer,n=t.isEncoding||function(e){switch(e=``+e,e&&e.toLowerCase()){case`hex`:case`utf8`:case`utf-8`:case`ascii`:case`binary`:case`base64`:case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:case`raw`:return!0;default:return!1}};function r(e){if(!e)return`utf8`;for(var t;;)switch(e){case`utf8`:case`utf-8`:return`utf8`;case`ucs2`:case`ucs-2`:case`utf16le`:case`utf-16le`:return`utf16le`;case`latin1`:case`binary`:return`latin1`;case`base64`:case`ascii`:case`hex`:return e;default:if(t)return;e=(``+e).toLowerCase(),t=!0}}function i(e){var i=r(e);if(typeof i!=`string`&&(t.isEncoding===n||!n(e)))throw Error(`Unknown encoding: `+e);return i||e}e.StringDecoder=a;function a(e){this.encoding=i(e);var n;switch(this.encoding){case`utf16le`:this.text=f,this.end=p,n=4;break;case`utf8`:this.fillLast=l,n=4;break;case`base64`:this.text=m,this.end=h,n=3;break;default:this.write=g,this.end=_;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=t.allocUnsafe(n)}a.prototype.write=function(e){if(e.length===0)return``;var t,n;if(this.lastNeed){if(t=this.fillLast(e),t===void 0)return``;n=this.lastNeed,this.lastNeed=0}else n=0;return n>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function s(e,t,n){var r=t.length-1;if(r=0?(i>0&&(e.lastNeed=i-1),i):--r=0?(i>0&&(e.lastNeed=i-2),i):--r=0?(i>0&&(i===2?i=0:e.lastNeed=i-3),i):0))}function c(e,t,n){if((t[0]&192)!=128)return e.lastNeed=0,`�`;if(e.lastNeed>1&&t.length>1){if((t[1]&192)!=128)return e.lastNeed=1,`�`;if(e.lastNeed>2&&t.length>2&&(t[2]&192)!=128)return e.lastNeed=2,`�`}}function l(e){var t=this.lastTotal-this.lastNeed,n=c(this,e,t);if(n!==void 0)return n;if(this.lastNeed<=e.length)return e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length}function u(e,t){var n=s(this,e,t);if(!this.lastNeed)return e.toString(`utf8`,t);this.lastTotal=n;var r=e.length-(n-this.lastNeed);return e.copy(this.lastChar,0,r),e.toString(`utf8`,t,r)}function d(e){var t=e&&e.length?this.write(e):``;return this.lastNeed?t+`�`:t}function f(e,t){if((e.length-t)%2==0){var n=e.toString(`utf16le`,t);if(n){var r=n.charCodeAt(n.length-1);if(r>=55296&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],n.slice(0,-1)}return n}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString(`utf16le`,t,e.length-1)}function p(e){var t=e&&e.length?this.write(e):``;if(this.lastNeed){var n=this.lastTotal-this.lastNeed;return t+this.lastChar.toString(`utf16le`,0,n)}return t}function m(e,t){var n=(e.length-t)%3;return n===0?e.toString(`base64`,t):(this.lastNeed=3-n,this.lastTotal=3,n===1?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString(`base64`,t,e.length-n))}function h(e){var t=e&&e.length?this.write(e):``;return this.lastNeed?t+this.lastChar.toString(`base64`,0,3-this.lastNeed):t}function g(e){return e.toString(this.encoding)}function _(e){return e&&e.length?this.write(e):``}})),bt=e(((e,t)=>{var n=Q().codes.ERR_STREAM_PREMATURE_CLOSE;function r(e){var t=!1;return function(){if(!t){t=!0;var n=[...arguments];e.apply(this,n)}}}function i(){}function a(e){return e.setHeader&&typeof e.abort==`function`}function o(e,t,s){if(typeof t==`function`)return o(e,null,t);t||={},s=r(s||i);var c=t.readable||t.readable!==!1&&e.readable,l=t.writable||t.writable!==!1&&e.writable,u=function(){e.writable||f()},d=e._writableState&&e._writableState.finished,f=function(){l=!1,d=!0,c||s.call(e)},p=e._readableState&&e._readableState.endEmitted,m=function(){c=!1,p=!0,l||s.call(e)},h=function(t){s.call(e,t)},g=function(){var t;if(c&&!p)return(!e._readableState||!e._readableState.ended)&&(t=new n),s.call(e,t);if(l&&!d)return(!e._writableState||!e._writableState.ended)&&(t=new n),s.call(e,t)},_=function(){e.req.on(`finish`,f)};return a(e)?(e.on(`complete`,f),e.on(`abort`,g),e.req?_():e.on(`request`,_)):l&&!e._writableState&&(e.on(`end`,u),e.on(`close`,u)),e.on(`end`,m),e.on(`finish`,f),t.error!==!1&&e.on(`error`,h),e.on(`close`,g),function(){e.removeListener(`complete`,f),e.removeListener(`abort`,g),e.removeListener(`request`,_),e.req&&e.req.removeListener(`finish`,f),e.removeListener(`end`,u),e.removeListener(`close`,u),e.removeListener(`finish`,f),e.removeListener(`end`,m),e.removeListener(`error`,h),e.removeListener(`close`,g)}}t.exports=o})),xt=e(((e,t)=>{var n;function r(e,t,n){return t=i(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){var t=a(e,`string`);return typeof t==`symbol`?t:String(t)}function a(e,t){if(typeof e!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(typeof r!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}var o=bt(),s=Symbol(`lastResolve`),c=Symbol(`lastReject`),l=Symbol(`error`),u=Symbol(`ended`),d=Symbol(`lastPromise`),f=Symbol(`handlePromise`),p=Symbol(`stream`);function m(e,t){return{value:e,done:t}}function h(e){var t=e[s];if(t!==null){var n=e[p].read();n!==null&&(e[d]=null,e[s]=null,e[c]=null,t(m(n,!1)))}}function g(e){process.nextTick(h,e)}function _(e,t){return function(n,r){e.then(function(){if(t[u]){n(m(void 0,!0));return}t[f](n,r)},r)}}var v=Object.getPrototypeOf(function(){}),y=Object.setPrototypeOf((n={get stream(){return this[p]},next:function(){var e=this,t=this[l];if(t!==null)return Promise.reject(t);if(this[u])return Promise.resolve(m(void 0,!0));if(this[p].destroyed)return new Promise(function(t,n){process.nextTick(function(){e[l]?n(e[l]):t(m(void 0,!0))})});var n=this[d],r;if(n)r=new Promise(_(n,this));else{var i=this[p].read();if(i!==null)return Promise.resolve(m(i,!1));r=new Promise(this[f])}return this[d]=r,r}},r(n,Symbol.asyncIterator,function(){return this}),r(n,`return`,function(){var e=this;return new Promise(function(t,n){e[p].destroy(null,function(e){if(e){n(e);return}t(m(void 0,!0))})})}),n),v);t.exports=function(e){var t,n=Object.create(y,(t={},r(t,p,{value:e,writable:!0}),r(t,s,{value:null,writable:!0}),r(t,c,{value:null,writable:!0}),r(t,l,{value:null,writable:!0}),r(t,u,{value:e._readableState.endEmitted,writable:!0}),r(t,f,{value:function(e,t){var r=n[p].read();r?(n[d]=null,n[s]=null,n[c]=null,e(m(r,!1))):(n[s]=e,n[c]=t)},writable:!0}),t));return n[d]=null,o(e,function(e){if(e&&e.code!==`ERR_STREAM_PREMATURE_CLOSE`){var t=n[c];t!==null&&(n[d]=null,n[s]=null,n[c]=null,t(e)),n[l]=e;return}var r=n[s];r!==null&&(n[d]=null,n[s]=null,n[c]=null,r(m(void 0,!0))),n[u]=!0}),e.on(`readable`,g.bind(null,n)),n}})),St=e(((e,t)=>{t.exports=function(){throw Error(`Readable.from is not available in the browser`)}})),Ct=e(((e,t)=>{t.exports=E;var n;E.ReadableState=T,at().EventEmitter;var r=function(e,t){return e.listeners(t).length},i=dt(),a=J().Buffer,o=(typeof global<`u`?global:typeof window<`u`?window:typeof self<`u`?self:{}).Uint8Array||function(){};function s(e){return a.from(e)}function c(e){return a.isBuffer(e)||e instanceof o}var l=ft(),u=l&&l.debuglog?l.debuglog(`stream`):function(){},d=pt(),f=mt(),p=ht().getHighWaterMark,m=Q().codes,h=m.ERR_INVALID_ARG_TYPE,g=m.ERR_STREAM_PUSH_AFTER_EOF,_=m.ERR_METHOD_NOT_IMPLEMENTED,v=m.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,y,b,x;Z()(E,i);var S=f.errorOrDestroy,C=[`error`,`close`,`destroy`,`pause`,`resume`];function w(e,t,n){if(typeof e.prependListener==`function`)return e.prependListener(t,n);!e._events||!e._events[t]?e.on(t,n):Array.isArray(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]}function T(e,t,r){n||=$(),e||={},typeof r!=`boolean`&&(r=t instanceof n),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=p(this,e,`readableHighWaterMark`,r),this.buffer=new d,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=e.emitClose!==!1,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||`utf8`,this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(y||=yt().StringDecoder,this.decoder=new y(e.encoding),this.encoding=e.encoding)}function E(e){if(n||=$(),!(this instanceof E))return new E(e);var t=this instanceof n;this._readableState=new T(e,this,t),this.readable=!0,e&&(typeof e.read==`function`&&(this._read=e.read),typeof e.destroy==`function`&&(this._destroy=e.destroy)),i.call(this)}Object.defineProperty(E.prototype,`destroyed`,{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=f.destroy,E.prototype._undestroy=f.undestroy,E.prototype._destroy=function(e,t){t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:typeof e==`string`&&(t||=n.defaultEncoding,t!==n.encoding&&(e=a.from(e,t),t=``),r=!0),D(this,e,t,!1,r)},E.prototype.unshift=function(e){return D(this,e,null,!0,!1)};function D(e,t,n,r,i){u(`readableAddChunk`,t);var o=e._readableState;if(t===null)o.reading=!1,te(e,o);else{var c;if(i||(c=ee(o,t)),c)S(e,c);else if(o.objectMode||t&&t.length>0)if(typeof t!=`string`&&!o.objectMode&&Object.getPrototypeOf(t)!==a.prototype&&(t=s(t)),r)o.endEmitted?S(e,new v):O(e,o,t,!0);else if(o.ended)S(e,new g);else if(o.destroyed)return!1;else o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||t.length!==0?O(e,o,t,!1):N(e,o)):O(e,o,t,!1);else r||(o.reading=!1,N(e,o))}return!o.ended&&(o.length=k?e=k:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||t.length===0&&t.ended?0:t.objectMode?1:e===e?(e>t.highWaterMark&&(t.highWaterMark=A(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0)):t.flowing&&t.length?t.buffer.head.data.length:t.length}E.prototype.read=function(e){u(`read`,e),e=parseInt(e,10);var t=this._readableState,n=e;if(e!==0&&(t.emittedReadable=!1),e===0&&t.needReadable&&((t.highWaterMark===0?t.length>0:t.length>=t.highWaterMark)||t.ended))return u(`read: emitReadable`,t.length,t.ended),t.length===0&&t.ended?V(this):M(this),null;if(e=j(e,t),e===0&&t.ended)return t.length===0&&V(this),null;var r=t.needReadable;u(`need readable`,r),(t.length===0||t.length-e0?B(e,t):null;return i===null?(t.needReadable=t.length<=t.highWaterMark,e=0):(t.length-=e,t.awaitDrain=0),t.length===0&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),i!==null&&this.emit(`data`,i),i};function te(e,t){if(u(`onEofChunk`),!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,t.sync?M(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,ne(e)))}}function M(e){var t=e._readableState;u(`emitReadable`,t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(u(`emitReadable`,t.flowing),t.emittedReadable=!0,process.nextTick(ne,e))}function ne(e){var t=e._readableState;u(`emitReadable_`,t.destroyed,t.length,t.ended),!t.destroyed&&(t.length||t.ended)&&(e.emit(`readable`),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,z(e)}function N(e,t){t.readingMore||(t.readingMore=!0,process.nextTick(P,e,t))}function P(e,t){for(;!t.reading&&!t.ended&&(t.length1&&H(i.pipes,e)!==-1)&&!l&&(u(`false write response, pause`,i.awaitDrain),i.awaitDrain++),n.pause())}function p(t){u(`onerror`,t),g(),e.removeListener(`error`,p),r(e,`error`)===0&&S(e,t)}w(e,`error`,p);function m(){e.removeListener(`finish`,h),g()}e.once(`close`,m);function h(){u(`onfinish`),e.removeListener(`close`,m),g()}e.once(`finish`,h);function g(){u(`unpipe`),n.unpipe(e)}return e.emit(`pipe`,n),i.flowing||(u(`pipe resume`),n.resume()),e};function F(e){return function(){var t=e._readableState;u(`pipeOnDrain`,t.awaitDrain),t.awaitDrain&&t.awaitDrain--,t.awaitDrain===0&&r(e,`data`)&&(t.flowing=!0,z(e))}}E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(t.pipesCount===0)return this;if(t.pipesCount===1)return e&&e!==t.pipes?this:(e||=t.pipes,t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit(`unpipe`,this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var a=0;a0,r.flowing!==!1&&this.resume()):e===`readable`&&!r.endEmitted&&!r.readableListening&&(r.readableListening=r.needReadable=!0,r.flowing=!1,r.emittedReadable=!1,u(`on readable`,r.length,r.reading),r.length?M(this):r.reading||process.nextTick(L,this)),n},E.prototype.addListener=E.prototype.on,E.prototype.removeListener=function(e,t){var n=i.prototype.removeListener.call(this,e,t);return e===`readable`&&process.nextTick(I,this),n},E.prototype.removeAllListeners=function(e){var t=i.prototype.removeAllListeners.apply(this,arguments);return(e===`readable`||e===void 0)&&process.nextTick(I,this),t};function I(e){var t=e._readableState;t.readableListening=e.listenerCount(`readable`)>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount(`data`)>0&&e.resume()}function L(e){u(`readable nexttick read 0`),e.read(0)}E.prototype.resume=function(){var e=this._readableState;return e.flowing||(u(`resume`),e.flowing=!e.readableListening,R(this,e)),e.paused=!1,this};function R(e,t){t.resumeScheduled||(t.resumeScheduled=!0,process.nextTick(re,e,t))}function re(e,t){u(`resume`,t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit(`resume`),z(e),t.flowing&&!t.reading&&e.read(0)}E.prototype.pause=function(){return u(`call pause flowing=%j`,this._readableState.flowing),this._readableState.flowing!==!1&&(u(`pause`),this._readableState.flowing=!1,this.emit(`pause`)),this._readableState.paused=!0,this};function z(e){var t=e._readableState;for(u(`flow`,t.flowing);t.flowing&&e.read()!==null;);}E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on(`end`,function(){if(u(`wrapped end`),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on(`data`,function(i){u(`wrapped data`),n.decoder&&(i=n.decoder.write(i)),!(n.objectMode&&i==null)&&(!n.objectMode&&(!i||!i.length)||t.push(i)||(r=!0,e.pause()))}),e)this[i]===void 0&&typeof e[i]==`function`&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var a=0;a=t.length?(n=t.decoder?t.buffer.join(``):t.buffer.length===1?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):n=t.buffer.consume(e,t.decoder),n}function V(e){var t=e._readableState;u(`endReadable`,t.endEmitted),t.endEmitted||(t.ended=!0,process.nextTick(ie,t,e))}function ie(e,t){if(u(`endReadableNT`,e.endEmitted,e.length),!e.endEmitted&&e.length===0&&(e.endEmitted=!0,t.readable=!1,t.emit(`end`),e.autoDestroy)){var n=t._writableState;(!n||n.autoDestroy&&n.finished)&&t.destroy()}}typeof Symbol==`function`&&(E.from=function(e,t){return x===void 0&&(x=St()),x(E,e,t)});function H(e,t){for(var n=0,r=e.length;n{t.exports=l;var n=Q().codes,r=n.ERR_METHOD_NOT_IMPLEMENTED,i=n.ERR_MULTIPLE_CALLBACK,a=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,o=n.ERR_TRANSFORM_WITH_LENGTH_0,s=$();Z()(l,s);function c(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(r===null)return this.emit(`error`,new i);n.writechunk=null,n.writecb=null,t!=null&&this.push(t),r(e);var a=this._readableState;a.reading=!1,(a.needReadable||a.length{t.exports=r;var n=wt();Z()(r,n);function r(e){if(!(this instanceof r))return new r(e);n.call(this,e)}r.prototype._transform=function(e,t,n){n(null,e)}})),Et=e(((e,t)=>{var n;function r(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}var i=Q().codes,a=i.ERR_MISSING_ARGS,o=i.ERR_STREAM_DESTROYED;function s(e){if(e)throw e}function c(e){return e.setHeader&&typeof e.abort==`function`}function l(e,t,i,a){a=r(a);var s=!1;e.on(`close`,function(){s=!0}),n===void 0&&(n=bt()),n(e,{readable:t,writable:i},function(e){if(e)return a(e);s=!0,a()});var l=!1;return function(t){if(!s&&!l){if(l=!0,c(e))return e.abort();if(typeof e.destroy==`function`)return e.destroy();a(t||new o(`pipe`))}}}function u(e){e()}function d(e,t){return e.pipe(t)}function f(e){return!e.length||typeof e[e.length-1]!=`function`?s:e.pop()}function p(){var e=[...arguments],t=f(e);if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new a(`streams`);var n,r=e.map(function(i,a){var o=a0,function(e){n||=e,e&&r.forEach(u),!o&&(r.forEach(u),t(n))})});return e.reduce(d)}t.exports=p})),Dt=e(((e,t)=>{t.exports=r;var n=at().EventEmitter;Z()(r,n),r.Readable=Ct(),r.Writable=_t(),r.Duplex=$(),r.Transform=wt(),r.PassThrough=Tt(),r.finished=bt(),r.pipeline=Et(),r.Stream=r;function r(){n.call(this)}r.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}r.on(`data`,i);function a(){r.readable&&r.resume&&r.resume()}e.on(`drain`,a),!e._isStdio&&(!t||t.end!==!1)&&(r.on(`end`,s),r.on(`close`,c));var o=!1;function s(){o||(o=!0,e.end())}function c(){o||(o=!0,typeof e.destroy==`function`&&e.destroy())}function l(e){if(u(),n.listenerCount(this,`error`)===0)throw e}r.on(`error`,l),e.on(`error`,l);function u(){r.removeListener(`data`,i),e.removeListener(`drain`,a),r.removeListener(`end`,s),r.removeListener(`close`,c),r.removeListener(`error`,l),e.removeListener(`error`,l),r.removeListener(`end`,u),r.removeListener(`close`,u),e.removeListener(`close`,u)}return r.on(`end`,u),r.on(`close`,u),e.on(`close`,u),e.emit(`pipe`,r),e}}));async function*Ot(e,t,n){let r=1,i={chunks:[],length:0};for await(let a of n(e))for(i.chunks.push(a),i.length+=a.byteLength;i.length>t;){let e=i.chunks.length>1?Y.Buffer.concat(i.chunks):i.chunks[0];yield{partNumber:r,data:e.subarray(0,t)},i.chunks=[e.subarray(t)],i.length=i.chunks[0].byteLength,r+=1}yield{partNumber:r,data:i.chunks.length===1?i.chunks[0]:Y.Buffer.concat(i.chunks),lastPart:!0}}async function*kt(e,t){let n=1,r=0,i=t;for(;i{if(e instanceof Uint8Array)return kt(e,t);if(e instanceof Mt.Readable)return Ot(e,t,At);if(e instanceof String||typeof e==`string`)return kt(Y.Buffer.from(e),t);if(typeof e.stream==`function`)return Ot(e.stream(),t,jt);if(e instanceof ReadableStream)return Ot(e,t,jt);throw Error(`Body Data is unsupported format, expected data to be one of: string | Uint8Array | Buffer | Readable | ReadableStream | Blob;.`)},Pt=at(),Ft=class e extends Pt.EventEmitter{static MIN_PART_SIZE=1024*1024*5;MAX_PARTS=1e4;queueSize=4;partSize;leavePartsOnError=!1;tags=[];client;params;totalBytes;totalBytesSource;bytesUploadedSoFar;abortController;concurrentUploaders=[];createMultiPartPromise;abortMultipartUploadCommand=null;uploadedParts=[];uploadEnqueuedPartsCount=0;expectedPartsCount;uploadId;uploadEvent;isMultiPart=!0;singleUploadResult;sent=!1;constructor(t){if(super(),this.queueSize=t.queueSize||this.queueSize,this.leavePartsOnError=t.leavePartsOnError||this.leavePartsOnError,this.tags=t.tags||this.tags,this.client=t.client,this.params=t.params,!this.params)throw Error(`InputError: Upload requires params to be passed to upload.`);this.totalBytes=this.params.ContentLength??lt(this.params.Body),this.totalBytesSource=ut(this.params.Body,this.params.ContentLength),this.bytesUploadedSoFar=0,this.abortController=t.abortController??new AbortController,this.partSize=t.partSize||Math.max(e.MIN_PART_SIZE,Math.floor((this.totalBytes||0)/this.MAX_PARTS)),this.totalBytes!==void 0&&(this.expectedPartsCount=Math.ceil(this.totalBytes/this.partSize)),this.__validateInput()}async abort(){this.abortController.abort()}async done(){if(this.sent)throw Error(`@aws-sdk/lib-storage: this instance of Upload has already executed .done(). Create a new instance.`);return this.sent=!0,await Promise.race([this.__doMultipartUpload(),this.__abortTimeout(this.abortController.signal)])}on(e,t){return this.uploadEvent=e,super.on(e,t)}async __uploadUsingPut(e){this.isMultiPart=!1;let t={...this.params,Body:e.data},n=this.client.config,r=n.requestHandler,o=r instanceof Pt.EventEmitter?r:null,s=t=>{this.bytesUploadedSoFar=t.loaded,this.totalBytes=t.total,this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:e.partNumber,Key:this.params.Key,Bucket:this.params.Bucket})};o!==null&&o.on(`xhr.upload.progress`,s);let c=await Promise.all([this.client.send(new tt(t)),n?.endpoint?.()]),l=c[0],u=c[1];if(u||=d(await i(t,tt,{...n})),!u)throw Error(`Could not resolve endpoint from S3 "client.config.endpoint()" nor EndpointsV2.`);o!==null&&o.off(`xhr.upload.progress`,s);let f=this.params.Key.split(`/`).map(e=>a(e)).join(`/`),p=a(this.params.Bucket),m=(()=>{let e=u.hostname.startsWith(`${p}.`),t=this.client.config.forcePathStyle,n=u.port?`:${u.port}`:``;return t?`${u.protocol}//${u.hostname}${n}/${p}/${f}`:e?`${u.protocol}//${u.hostname}${n}/${f}`:`${u.protocol}//${p}.${u.hostname}${n}/${f}`})();this.singleUploadResult={...l,Bucket:this.params.Bucket,Key:this.params.Key,Location:m};let h=lt(e.data);this.__notifyProgress({loaded:h,total:h,part:1,Key:this.params.Key,Bucket:this.params.Bucket})}async __createMultipartUpload(){let e=await this.client.config.requestChecksumCalculation();if(!this.createMultiPartPromise){let t={...this.params,Body:void 0};e===`WHEN_SUPPORTED`&&(t.ChecksumAlgorithm=this.params.ChecksumAlgorithm||it.CRC32),this.createMultiPartPromise=this.client.send(new $e(t)).then(e=>(this.abortMultipartUploadCommand=new We({Bucket:this.params.Bucket,Key:this.params.Key,UploadId:e.UploadId}),e))}return this.createMultiPartPromise}async __doConcurrentUpload(e){for await(let t of e){if(this.uploadEnqueuedPartsCount>this.MAX_PARTS)throw Error(`Exceeded ${this.MAX_PARTS} parts in multipart upload to Bucket: ${this.params.Bucket} Key: ${this.params.Key}.`);if(this.abortController.signal.aborted)return;if(t.partNumber===1&&t.lastPart)return await this.__uploadUsingPut(t);if(!this.uploadId){let{UploadId:e}=await this.__createMultipartUpload();if(this.uploadId=e,this.abortController.signal.aborted)return}let e=lt(t.data)||0,n=this.client.config.requestHandler,r=n instanceof Pt.EventEmitter?n:null,i=0,a=(n,r)=>{(Number(r.query.partNumber)||-1)===t.partNumber&&(n.total&&e&&(this.bytesUploadedSoFar+=n.loaded-i,i=n.loaded),this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:t.partNumber,Key:this.params.Key,Bucket:this.params.Bucket}))};r!==null&&r.on(`xhr.upload.progress`,a),this.uploadEnqueuedPartsCount+=1,this.__validateUploadPart(t);let o=await this.client.send(new rt({...this.params,ContentLength:void 0,UploadId:this.uploadId,Body:t.data,PartNumber:t.partNumber}));if(r!==null&&r.off(`xhr.upload.progress`,a),this.abortController.signal.aborted)return;if(!o.ETag)throw Error(`Part ${t.partNumber} is missing ETag in UploadPart response. Missing Bucket CORS configuration for ETag header?`);this.uploadedParts.push({PartNumber:t.partNumber,ETag:o.ETag,...o.ChecksumCRC32&&{ChecksumCRC32:o.ChecksumCRC32},...o.ChecksumCRC32C&&{ChecksumCRC32C:o.ChecksumCRC32C},...o.ChecksumSHA1&&{ChecksumSHA1:o.ChecksumSHA1},...o.ChecksumSHA256&&{ChecksumSHA256:o.ChecksumSHA256}}),r===null&&(this.bytesUploadedSoFar+=e),this.__notifyProgress({loaded:this.bytesUploadedSoFar,total:this.totalBytes,part:t.partNumber,Key:this.params.Key,Bucket:this.params.Bucket})}}async __doMultipartUpload(){let e=Nt(this.params.Body,this.partSize),t=[];for(let n=0;n{t.push(e)});this.concurrentUploaders.push(n)}if(await Promise.all(this.concurrentUploaders),t.length>=1)throw await this.markUploadAsAborted(),t[0];if(this.abortController.signal.aborted)throw await this.markUploadAsAborted(),Object.assign(Error(`Upload aborted.`),{name:`AbortError`});let n;if(this.isMultiPart){let{expectedPartsCount:e,uploadedParts:t,totalBytes:r,totalBytesSource:i}=this;if(r!==void 0&&e!==void 0&&t.length!==e)throw Error(`Expected ${e} part(s) but uploaded ${t.length} part(s). The expected part count is based on the byte-count of the input.params.Body, which was read from ${i} and is ${r}. If this is not correct, provide an override value by setting a number diff --git a/spinifex/services/spinifexui/frontend/dist/assets/s32.js b/spinifex/services/spinifexui/frontend/dist/assets/s32.js index 91bfb2219..b997b706b 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/s32.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/s32.js @@ -1 +1 @@ -import{t as e}from"./queryOptions.js";import{Lt as t,Vt as n,_ as r,d as i,f as a,g as o,i as s}from"./awsClient.js";var c=class extends n.classBuilder().ep(o).m(function(e,n,i,a){return[t(i,e.getEndpointParameterInstructions()),r(i)]}).s(`AmazonS3`,`ListBuckets`,{}).n(`S3Client`,`ListBucketsCommand`).sc(i).build(){},l=class extends n.classBuilder().ep({...o,Bucket:{type:`contextParams`,name:`Bucket`},Prefix:{type:`contextParams`,name:`Prefix`}}).m(function(e,n,i,a){return[t(i,e.getEndpointParameterInstructions()),r(i)]}).s(`AmazonS3`,`ListObjectsV2`,{}).n(`S3Client`,`ListObjectsV2Command`).sc(a).build(){},u=e({queryKey:[`s3`,`buckets`],queryFn:()=>{let e=new c({});return s().send(e)}}),d=(t,n)=>e({queryKey:[`s3`,`buckets`,t,`objects`,n??``],queryFn:()=>{let e=new l({Bucket:t,Prefix:n,Delimiter:`/`});return s().send(e)}});export{u as n,d as t}; \ No newline at end of file +import{t as e}from"./queryOptions.js";import{Rt as t,_ as n,d as r,f as i,g as a,i as o,zt as s}from"./awsClient.js";var c=class extends t.classBuilder().ep(a).m(function(e,t,r,i){return[s(r,e.getEndpointParameterInstructions()),n(r)]}).s(`AmazonS3`,`ListBuckets`,{}).n(`S3Client`,`ListBucketsCommand`).sc(r).build(){},l=class extends t.classBuilder().ep({...a,Bucket:{type:`contextParams`,name:`Bucket`},Prefix:{type:`contextParams`,name:`Prefix`}}).m(function(e,t,r,i){return[s(r,e.getEndpointParameterInstructions()),n(r)]}).s(`AmazonS3`,`ListObjectsV2`,{}).n(`S3Client`,`ListObjectsV2Command`).sc(i).build(){},u=e({queryKey:[`s3`,`buckets`],queryFn:()=>{let e=new c({});return o().send(e)}}),d=(t,n)=>e({queryKey:[`s3`,`buckets`,t,`objects`,n??``],queryFn:()=>{let e=new l({Bucket:t,Prefix:n,Delimiter:`/`});return o().send(e)}});export{u as n,d as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/upload-button.js b/spinifex/services/spinifexui/frontend/dist/assets/upload-button.js index 9a751c8f1..3ab5ef129 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/upload-button.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/upload-button.js @@ -1 +1 @@ -import{a as e,n as t,r as n,t as r}from"./compiler-runtime.js";import{t as i}from"./error-banner.js";import{t as a}from"./link.js";import{Lt as o,Vt as s,Wt as c,Yt as l,g as u,i as d,u as f}from"./awsClient.js";import{R as p,z as m}from"./SignatureV4.js";import{t as h}from"./createLucideIcon.js";import{t as g}from"./download.js";import{t as _}from"./trash-2.js";import{t as v}from"./button.js";import{a as y,i as b,n as x}from"./s3.js";import{t as S}from"./delete-confirmation-dialog.js";var C=h(`file`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}]]),w=h(`folder`,[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),T=h(`upload`,[[`path`,{d:`M12 3v12`,key:`1x0j5s`}],[`path`,{d:`m17 8-5-5-5 5`,key:`7q97r8`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}]]),E=e=>(e,t)=>async n=>{let r=await e(n),{response:i}=r;if(l.isInstance(i)&&i.headers.expires){i.headers.expiresstring=i.headers.expires;try{c(i.headers.expires)}catch(e){t.logger?.warn(`AWS SDK Warning for ${t.clientName}::${t.commandName} response parsing (${i.headers.expires}): ${e}`),delete i.headers.expires}}return r},D={tags:[`S3`],name:`s3ExpiresMiddleware`,override:!0,relation:`after`,toMiddleware:`deserializerMiddleware`},O=e=>({applyToStack:t=>{t.addRelativeTo(E(e),D)}}),k=class extends s.classBuilder().ep({...u,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[o(n,e.getEndpointParameterInstructions()),y(n,{requestChecksumRequired:!1,requestValidationModeMember:`ChecksumMode`,responseAlgorithms:[`CRC64NVME`,`CRC32`,`CRC32C`,`SHA256`,`SHA1`]}),b(n),O(n)]}).s(`AmazonS3`,`GetObject`,{}).n(`S3Client`,`GetObjectCommand`).sc(f).build(){},A=r(),j=t();function M(e){let t=(0,A.c)(9),{folderName:n,fullPrefix:r,bucketName:i}=e,o;t[0]!==i||t[1]!==r?(o={bucket:i,_splat:r},t[0]=i,t[1]=r,t[2]=o):o=t[2];let s;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,j.jsx)(w,{className:`size-5 text-muted-foreground`}),t[3]=s):s=t[3];let c;t[4]===n?c=t[5]:(c=(0,j.jsx)(`span`,{className:`font-medium`,children:n}),t[4]=n,t[5]=c);let l;return t[6]!==o||t[7]!==c?(l=(0,j.jsxs)(a,{className:`flex items-center gap-3 rounded-lg border bg-card p-4 transition-colors hover:bg-accent`,params:o,to:`/s3/ls/$bucket/$`,children:[s,c]}),t[6]=o,t[7]=c,t[8]=l):l=t[8],l}var N=e(n(),1);function P({object:e,bucketName:t,displayName:n,fullKey:r}){let[a,o]=(0,N.useState)(!1),s=x();async function c(){try{let e=new k({Bucket:t,Key:r}),i=await d().send(e);if(i.Body){let e=await i.Body.transformToByteArray(),t=URL.createObjectURL(new Blob([e])),r=document.createElement(`a`);r.href=t,r.download=n,document.body.append(r),r.click(),r.remove(),URL.revokeObjectURL(t)}}catch(e){throw Error(`Failed to download object`,{cause:e})}}async function l(){try{await s.mutateAsync({bucket:t,key:r})}finally{o(!1)}}return(0,j.jsxs)(`div`,{children:[s.error&&(0,j.jsx)(i,{error:s.error,msg:`Failed to delete object`}),(0,j.jsxs)(`div`,{className:`flex items-center justify-between rounded-lg border bg-card p-4`,children:[(0,j.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,j.jsx)(C,{className:`size-5 text-muted-foreground`}),(0,j.jsxs)(`div`,{children:[(0,j.jsx)(`h3`,{className:`font-medium`,children:n}),e.LastModified&&(0,j.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[`Last Modified: `,p(e.LastModified)]})]})]}),(0,j.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,j.jsx)(`div`,{className:`text-sm text-muted-foreground`,children:m(e.Size??0)}),(0,j.jsx)(`button`,{"aria-label":`Download ${n}`,className:`rounded-md p-2 transition-colors hover:bg-accent`,onClick:c,type:`button`,children:(0,j.jsx)(g,{className:`size-4`})}),(0,j.jsx)(`button`,{"aria-label":`Delete ${n}`,className:`rounded-md p-2 text-destructive transition-colors hover:bg-accent`,onClick:()=>o(!0),type:`button`,children:(0,j.jsx)(_,{className:`size-4`})})]}),(0,j.jsx)(S,{description:(0,j.jsxs)(j.Fragment,{children:[`Are you sure you want to delete `,(0,j.jsx)(`strong`,{children:n}),`? This action cannot be undone.`]}),isPending:s.isPending,onConfirm:l,onOpenChange:o,open:a,title:`Delete Object`})]})]},e.Key)}function F({bucket:e,prefix:t=``,isPending:n,onUpload:r}){let i=(0,N.useRef)(null);async function a(n){let a=n.target.files;if(!(!a||a.length===0))try{await Promise.all([...a].map(n=>r({bucket:e,key:`${t}${n.name}`,file:n})))}finally{i.current&&(i.current.value=``)}}return(0,j.jsxs)(j.Fragment,{children:[(0,j.jsx)(`input`,{accept:`*/*`,"aria-label":`Choose files to upload`,className:`hidden`,multiple:!0,onChange:a,ref:i,type:`file`}),(0,j.jsxs)(v,{disabled:n,onClick:()=>i.current?.click(),size:`sm`,children:[(0,j.jsx)(T,{className:`mr-2 size-4`}),n?`Uploading…`:`Upload Files`]})]})}export{P as n,M as r,F as t}; \ No newline at end of file +import{a as e,n as t,r as n,t as r}from"./compiler-runtime.js";import{t as i}from"./error-banner.js";import{t as a}from"./link.js";import{Rt as o,Wt as s,Yt as c,g as l,i as u,u as d,zt as f}from"./awsClient.js";import{R as p,z as m}from"./SignatureV4.js";import{t as h}from"./createLucideIcon.js";import{t as g}from"./download.js";import{t as _}from"./trash-2.js";import{t as v}from"./button.js";import{a as y,i as b,n as x}from"./s3.js";import{t as S}from"./delete-confirmation-dialog.js";var C=h(`file`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}]]),w=h(`folder`,[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),T=h(`upload`,[[`path`,{d:`M12 3v12`,key:`1x0j5s`}],[`path`,{d:`m17 8-5-5-5 5`,key:`7q97r8`}],[`path`,{d:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4`,key:`ih7n3h`}]]),E=e=>(e,t)=>async n=>{let r=await e(n),{response:i}=r;if(c.isInstance(i)&&i.headers.expires){i.headers.expiresstring=i.headers.expires;try{s(i.headers.expires)}catch(e){t.logger?.warn(`AWS SDK Warning for ${t.clientName}::${t.commandName} response parsing (${i.headers.expires}): ${e}`),delete i.headers.expires}}return r},D={tags:[`S3`],name:`s3ExpiresMiddleware`,override:!0,relation:`after`,toMiddleware:`deserializerMiddleware`},O=e=>({applyToStack:t=>{t.addRelativeTo(E(e),D)}}),k=class extends o.classBuilder().ep({...l,Bucket:{type:`contextParams`,name:`Bucket`},Key:{type:`contextParams`,name:`Key`}}).m(function(e,t,n,r){return[f(n,e.getEndpointParameterInstructions()),y(n,{requestChecksumRequired:!1,requestValidationModeMember:`ChecksumMode`,responseAlgorithms:[`CRC64NVME`,`CRC32`,`CRC32C`,`SHA256`,`SHA1`]}),b(n),O(n)]}).s(`AmazonS3`,`GetObject`,{}).n(`S3Client`,`GetObjectCommand`).sc(d).build(){},A=r(),j=t();function M(e){let t=(0,A.c)(9),{folderName:n,fullPrefix:r,bucketName:i}=e,o;t[0]!==i||t[1]!==r?(o={bucket:i,_splat:r},t[0]=i,t[1]=r,t[2]=o):o=t[2];let s;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,j.jsx)(w,{className:`size-5 text-muted-foreground`}),t[3]=s):s=t[3];let c;t[4]===n?c=t[5]:(c=(0,j.jsx)(`span`,{className:`font-medium`,children:n}),t[4]=n,t[5]=c);let l;return t[6]!==o||t[7]!==c?(l=(0,j.jsxs)(a,{className:`flex items-center gap-3 rounded-lg border bg-card p-4 transition-colors hover:bg-accent`,params:o,to:`/s3/ls/$bucket/$`,children:[s,c]}),t[6]=o,t[7]=c,t[8]=l):l=t[8],l}var N=e(n(),1);function P({object:e,bucketName:t,displayName:n,fullKey:r}){let[a,o]=(0,N.useState)(!1),s=x();async function c(){try{let e=new k({Bucket:t,Key:r}),i=await u().send(e);if(i.Body){let e=await i.Body.transformToByteArray(),t=URL.createObjectURL(new Blob([e])),r=document.createElement(`a`);r.href=t,r.download=n,document.body.append(r),r.click(),r.remove(),URL.revokeObjectURL(t)}}catch(e){throw Error(`Failed to download object`,{cause:e})}}async function l(){try{await s.mutateAsync({bucket:t,key:r})}finally{o(!1)}}return(0,j.jsxs)(`div`,{children:[s.error&&(0,j.jsx)(i,{error:s.error,msg:`Failed to delete object`}),(0,j.jsxs)(`div`,{className:`flex items-center justify-between rounded-lg border bg-card p-4`,children:[(0,j.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,j.jsx)(C,{className:`size-5 text-muted-foreground`}),(0,j.jsxs)(`div`,{children:[(0,j.jsx)(`h3`,{className:`font-medium`,children:n}),e.LastModified&&(0,j.jsxs)(`p`,{className:`text-sm text-muted-foreground`,children:[`Last Modified: `,p(e.LastModified)]})]})]}),(0,j.jsxs)(`div`,{className:`flex items-center gap-3`,children:[(0,j.jsx)(`div`,{className:`text-sm text-muted-foreground`,children:m(e.Size??0)}),(0,j.jsx)(`button`,{"aria-label":`Download ${n}`,className:`rounded-md p-2 transition-colors hover:bg-accent`,onClick:c,type:`button`,children:(0,j.jsx)(g,{className:`size-4`})}),(0,j.jsx)(`button`,{"aria-label":`Delete ${n}`,className:`rounded-md p-2 text-destructive transition-colors hover:bg-accent`,onClick:()=>o(!0),type:`button`,children:(0,j.jsx)(_,{className:`size-4`})})]}),(0,j.jsx)(S,{description:(0,j.jsxs)(j.Fragment,{children:[`Are you sure you want to delete `,(0,j.jsx)(`strong`,{children:n}),`? This action cannot be undone.`]}),isPending:s.isPending,onConfirm:l,onOpenChange:o,open:a,title:`Delete Object`})]})]},e.Key)}function F({bucket:e,prefix:t=``,isPending:n,onUpload:r}){let i=(0,N.useRef)(null);async function a(n){let a=n.target.files;if(!(!a||a.length===0))try{await Promise.all([...a].map(n=>r({bucket:e,key:`${t}${n.name}`,file:n})))}finally{i.current&&(i.current.value=``)}}return(0,j.jsxs)(j.Fragment,{children:[(0,j.jsx)(`input`,{accept:`*/*`,"aria-label":`Choose files to upload`,className:`hidden`,multiple:!0,onChange:a,ref:i,type:`file`}),(0,j.jsxs)(v,{disabled:n,onClick:()=>i.current?.click(),size:`sm`,children:[(0,j.jsx)(T,{className:`mr-2 size-4`}),n?`Uploading…`:`Upload Files`]})]})}export{P as n,M as r,F as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/useNavigate.js b/spinifex/services/spinifexui/frontend/dist/assets/useNavigate.js index b8a29217e..09209bd0a 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/useNavigate.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/useNavigate.js @@ -1 +1 @@ -import{a as e,r as t}from"./compiler-runtime.js";import{t as n}from"./useRouter.js";var r=e(t(),1);function i(e){let t=n();return r.useCallback(n=>t.navigate({...n,from:n.from??e?.from}),[e?.from,t])}export{i as t}; \ No newline at end of file +import{a as e,r as t}from"./compiler-runtime.js";import{i as n}from"./useStore.js";var r=e(t(),1);function i(e){let t=n();return r.useCallback(n=>t.navigate({...n,from:n.from??e?.from}),[e?.from,t])}export{i as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/useRouter.js b/spinifex/services/spinifexui/frontend/dist/assets/useRouter.js deleted file mode 100644 index d23d59c79..000000000 --- a/spinifex/services/spinifexui/frontend/dist/assets/useRouter.js +++ /dev/null @@ -1 +0,0 @@ -import{a as e,r as t}from"./compiler-runtime.js";var n=e(t(),1),r=n.use,i=typeof window<`u`?n.useLayoutEffect:n.useEffect;function a(e){let t=n.useRef({value:e,prev:null}),r=t.current.value;return e!==r&&(t.current={value:e,prev:r}),t.current.prev}function o(e,t,r={},i={}){n.useEffect(()=>{if(!e.current||i.disabled||typeof IntersectionObserver!=`function`)return;let n=new IntersectionObserver(([e])=>{t(e)},r);return n.observe(e.current),()=>{n.disconnect()}},[t,r,i.disabled,e])}function s(e){let t=n.useRef(null);return n.useImperativeHandle(e,()=>t.current,[]),t}var c=n.createContext(null);function l(e){return n.useContext(c)}export{o as a,s as i,c as n,i as o,r,a as s,l as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/useStore.js b/spinifex/services/spinifexui/frontend/dist/assets/useStore.js index a42b82121..8c05593cc 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/useStore.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/useStore.js @@ -1 +1 @@ -import{a as e,i as t,n,r}from"./compiler-runtime.js";function i(e){return e[e.length-1]}function a(e){return typeof e==`function`}function o(e,t){return a(e)?e(t):e}var s=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable,l=()=>Object.create(null),u=(e,t)=>d(e,t,l);function d(e,t,n=()=>({}),r=0){if(e===t)return e;if(r>500)return t;let i=t,a=h(e)&&h(i);if(!a&&!(p(e)&&p(i)))return i;let o=a?e:f(e);if(!o)return i;let c=a?i:f(i);if(!c)return i;let l=o.length,u=c.length,m=a?Array(u):n(),g=0;for(let t=0;ti||!g(e[o],t[o],n)))return!1;return i===a}return!1}function _(e){let t,n,r=new Promise((e,r)=>{t=e,n=r});return r.status=`pending`,r.resolve=n=>{r.status=`resolved`,r.value=n,t(n),e?.(n)},r.reject=e=>{r.status=`rejected`,n(e)},r}function v(e){return typeof e?.message==`string`?e.message.startsWith(`Failed to fetch dynamically imported module`)||e.message.startsWith(`error loading dynamically imported module`)||e.message.startsWith(`Importing a module script failed`):!1}function y(e){return!!(e&&typeof e==`object`&&typeof e.then==`function`)}function b(e){return e.replace(/[\x00-\x1f\x7f]/g,``)}function x(e){let t;try{t=decodeURI(e)}catch{t=e.replaceAll(/%[0-9A-F]{2}/gi,e=>{try{return decodeURI(e)}catch{return e}})}return b(t)}var S=[`http:`,`https:`,`mailto:`,`tel:`];function C(e,t){if(!e)return!1;try{let n=new URL(e);return!t.has(n.protocol)}catch{return!1}}var w={"&":`\\u0026`,">":`\\u003e`,"<":`\\u003c`,"\u2028":`\\u2028`,"\u2029":`\\u2029`},ee=/[&><\u2028\u2029]/g;function T(e){return e.replace(ee,e=>w[e])}function te(e){if(!e||!/[%\\\x00-\x1f\x7f]/.test(e)&&!e.startsWith(`//`))return{path:e,handledProtocolRelativeURL:!1};let t=/%25|%5C/gi,n=0,r=``,i;for(;(i=t.exec(e))!==null;)r+=x(e.slice(n,i.index))+i[0],n=t.lastIndex;r+=x(n?e.slice(n):e);let a=!1;return r.startsWith(`//`)&&(a=!0,r=`/`+r.replace(/^\/+/,``)),{path:r,handledProtocolRelativeURL:a}}function ne(e){return/\s|[^\u0000-\u007F]/.test(e)?e.replace(/\s|[^\u0000-\u007F]/gu,encodeURIComponent):e}function E(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n{e.next&&(e.prev?(e.prev.next=e.next,e.next.prev=e.prev,e.next=void 0,r&&(r.next=e,e.prev=r)):(e.next.prev=void 0,n=e.next,e.next=void 0,r&&(e.prev=r,r.next=e)),r=e)};return{get(e){let n=t.get(e);if(n)return i(n),n.value},set(a,o){if(t.size>=e&&n){let e=n;t.delete(e.key),e.next&&(n=e.next,e.next.prev=void 0),e===r&&(r=void 0)}let s=t.get(a);if(s)s.value=o,i(s);else{let e={key:a,value:o,prev:r};r&&(r.next=e),r=e,n||=e,t.set(a,e)}},clear(){t.clear(),n=void 0,r=void 0}}}var k=4,A=5;function re(e){let t=e.indexOf(`{`);if(t===-1)return null;let n=e.indexOf(`}`,t);return n===-1||t+1>=e.length?null:[t,n]}function j(e,t,n=new Uint16Array(6)){let r=e.indexOf(`/`,t),i=r===-1?e.length:r,a=e.substring(t,i);if(!a||!a.includes(`$`))return n[0]=0,n[1]=t,n[2]=t,n[3]=i,n[4]=i,n[5]=i,n;if(a===`$`){let r=e.length;return n[0]=2,n[1]=t,n[2]=t,n[3]=r,n[4]=r,n[5]=r,n}if(a.charCodeAt(0)===36)return n[0]=1,n[1]=t,n[2]=t+1,n[3]=i,n[4]=i,n[5]=i,n;let o=re(a);if(o){let[r,s]=o,c=a.charCodeAt(r+1);if(c===45){if(r+2!e.skipOnParamError&&e.caseSensitive===f&&e.prefix===p&&e.suffix===m);if(h)o=h;else{let e=I(1,n.fullPath??n.from,f,p,m);o=e,e.depth=a,e.parent=i,i.dynamic??=[],i.dynamic.push(e)}break}case 3:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),f=c&&!!(t||s),p=t?f?t:t.toLowerCase():void 0,m=s?f?s:s.toLowerCase():void 0,h=!l&&i.optional?.find(e=>!e.skipOnParamError&&e.caseSensitive===f&&e.prefix===p&&e.suffix===m);if(h)o=h;else{let e=I(3,n.fullPath??n.from,f,p,m);o=e,e.parent=i,e.depth=a,i.optional??=[],i.optional.push(e)}break}case 2:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),l=c&&!!(t||s),f=t?l?t:t.toLowerCase():void 0,p=s?l?s:s.toLowerCase():void 0,m=I(2,n.fullPath??n.from,l,f,p);o=m,m.parent=i,m.depth=a,i.wildcard??=[],i.wildcard.push(m)}}i=o}if(l&&n.children&&!n.isRoot&&n.id&&n.id.charCodeAt(n.id.lastIndexOf(`/`)+1)===95){let e=F(n.fullPath??n.from);e.kind=A,e.parent=i,a++,e.depth=a,i.pathless??=[],i.pathless.push(e),i=e}let u=(n.path||!n.children)&&!n.isRoot;if(u&&r.endsWith(`/`)){let e=F(n.fullPath??n.from);e.kind=k,e.parent=i,a++,e.depth=a,i.index=e,i=e}i.parse=n.options?.params?.parse??null,i.skipOnParamError=l,i.parsingPriority=n.options?.skipRouteOnParseError?.priority??0,u&&!i.route&&(i.route=n,i.fullPath=n.fullPath??n.from)}if(n.children)for(let r of n.children)M(e,t,r,s,i,a,o)}function N(e,t){if(e.skipOnParamError&&!t.skipOnParamError)return-1;if(!e.skipOnParamError&&t.skipOnParamError)return 1;if(e.skipOnParamError&&t.skipOnParamError&&(e.parsingPriority||t.parsingPriority))return t.parsingPriority-e.parsingPriority;if(e.prefix&&t.prefix&&e.prefix!==t.prefix){if(e.prefix.startsWith(t.prefix))return-1;if(t.prefix.startsWith(e.prefix))return 1}if(e.suffix&&t.suffix&&e.suffix!==t.suffix){if(e.suffix.endsWith(t.suffix))return-1;if(t.suffix.endsWith(e.suffix))return 1}return e.prefix&&!t.prefix?-1:!e.prefix&&t.prefix?1:e.suffix&&!t.suffix?-1:!e.suffix&&t.suffix?1:e.caseSensitive&&!t.caseSensitive?-1:!e.caseSensitive&&t.caseSensitive?1:0}function P(e){if(e.pathless)for(let t of e.pathless)P(t);if(e.static)for(let t of e.static.values())P(t);if(e.staticInsensitive)for(let t of e.staticInsensitive.values())P(t);if(e.dynamic?.length){e.dynamic.sort(N);for(let t of e.dynamic)P(t)}if(e.optional?.length){e.optional.sort(N);for(let t of e.optional)P(t)}if(e.wildcard?.length){e.wildcard.sort(N);for(let t of e.wildcard)P(t)}}function F(e){return{kind:0,depth:0,pathless:null,index:null,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:e,parent:null,parse:null,skipOnParamError:!1,parsingPriority:0}}function I(e,t,n,r,i){return{kind:e,depth:0,pathless:null,index:null,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:t,parent:null,parse:null,skipOnParamError:!1,parsingPriority:0,caseSensitive:n,prefix:r,suffix:i}}function ie(e,t){let n=F(`/`),r=new Uint16Array(6);for(let t of e)M(!1,r,t,1,n,0);P(n),t.masksTree=n,t.flatCache=O(1e3)}function ae(e,t){e||=`/`;let n=t.flatCache.get(e);if(n)return n;let r=L(e,t.masksTree);return t.flatCache.set(e,r),r}function oe(e,t,n,r,i){e||=`/`,r||=`/`;let a=t?`case\0${e}`:e,o=i.singleCache.get(a);return o||(o=F(`/`),M(t,new Uint16Array(6),{from:e},1,o,0),i.singleCache.set(a,o)),L(r,o,n)}function se(e,t,n=!1){let r=n?e:`nofuzz\0${e}`,i=t.matchCache.get(r);if(i!==void 0)return i;e||=`/`;let a;try{a=L(e,t.segmentTree,n)}catch(e){if(e instanceof URIError)a=null;else throw e}return a&&(a.branch=ue(a.route)),t.matchCache.set(r,a),a}function ce(e){return e===`/`?e:e.replace(/\/{1,}$/,``)}function le(e,t=!1,n){let r=F(e.fullPath),i=new Uint16Array(6),a={},o={},s=0;return M(t,i,e,1,r,0,e=>{if(n?.(e,s),e.id in a&&D(),a[e.id]=e,s!==0&&e.path){let t=ce(e.fullPath);(!o[t]||e.fullPath.endsWith(`/`))&&(o[t]=e)}s++}),P(r),{processedTree:{segmentTree:r,singleCache:O(1e3),matchCache:O(1e3),flatCache:null,masksTree:null},routesById:a,routesByPath:o}}function L(e,t,n=!1){let r=e.split(`/`),i=B(e,r,t,n);if(!i)return null;let[a]=R(e,r,i);return{route:i.node.route,rawParams:a,parsedParams:i.parsedParams}}function R(e,t,n){let r=z(n.node),i=null,a=Object.create(null),o=n.extract?.part??0,s=n.extract?.node??0,c=n.extract?.path??0,l=n.extract?.segment??0;for(;s=0;n--){let r=i.optional[n];c.push({node:r,index:a,skipped:e,depth:t,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b)for(let e=i.optional.length-1;e>=0;e--){let n=i.optional[e],{prefix:r,suffix:o}=n;if(r||o){let e=n.caseSensitive?x:S??=x.toLowerCase();if(r&&!e.startsWith(r)||o&&!e.endsWith(o))continue}c.push({node:n,index:a+1,skipped:f,depth:t,statics:m,dynamics:h,optionals:g+1,extract:_,rawParams:v,parsedParams:y})}}if(!b&&i.dynamic&&x)for(let e=i.dynamic.length-1;e>=0;e--){let t=i.dynamic[e],{prefix:n,suffix:r}=t;if(n||r){let e=t.caseSensitive?x:S??=x.toLowerCase();if(n&&!e.startsWith(n)||r&&!e.endsWith(r))continue}c.push({node:t,index:a+1,skipped:f,depth:p+1,statics:m,dynamics:h+1,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b&&i.staticInsensitive){let e=i.staticInsensitive.get(S??=x.toLowerCase());e&&c.push({node:e,index:a+1,skipped:f,depth:p+1,statics:m+1,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b&&i.static){let e=i.static.get(x);e&&c.push({node:e,index:a+1,skipped:f,depth:p+1,statics:m+1,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(i.pathless){let e=p+1;for(let t=i.pathless.length-1;t>=0;t--){let n=i.pathless[t];c.push({node:n,index:a,skipped:f,depth:e,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}}}if(d&&l)return H(l,d)?d:l;if(d)return d;if(l)return l;if(r&&u){let n=u.index;for(let e=0;ee.statics||t.statics===e.statics&&(t.dynamics>e.dynamics||t.dynamics===e.dynamics&&(t.optionals>e.optionals||t.optionals===e.optionals&&((t.node.kind===k)>(e.node.kind===k)||t.node.kind===k==(e.node.kind===k)&&t.depth>e.depth))):!0}function de(e){return U(e.filter(e=>e!==void 0).join(`/`))}function U(e){return e.replace(/\/{2,}/g,`/`)}function W(e){return e===`/`?e:e.replace(/^\/{1,}/,``)}function G(e){let t=e.length;return t>1&&e[t-1]===`/`?e.replace(/\/{1,}$/,``):e}function fe(e){return G(W(e))}function K(e,t){return e?.endsWith(`/`)&&e!==`/`&&e!==`${t}/`?e.slice(0,-1):e}function pe(e,t,n){return K(e,n)===K(t,n)}function me({base:e,to:t,trailingSlash:n=`never`,cache:r}){let a=t.startsWith(`/`),o=!a&&t===`.`,s;if(r){s=a?t:o?e:e+`\0`+t;let n=r.get(s);if(n)return n}let c;if(o)c=e.split(`/`);else if(a)c=t.split(`/`);else{for(c=e.split(`/`);c.length>1&&i(c)===``;)c.pop();let n=t.split(`/`);for(let e=0,t=n.length;e1&&(i(c)===``?n===`never`&&c.pop():n===`always`&&c.push(``));let l,u=``;for(let e=0;e0&&(u+=`/`);let t=c[e];if(!t)continue;l=j(t,0,l);let n=l[0];if(n===0){u+=t;continue}let r=l[5],i=t.substring(0,l[1]),a=t.substring(l[4],r),o=t.substring(l[2],l[3]);n===1?u+=i||a?`${i}{$${o}}${a}`:`$${o}`:n===2?u+=i||a?`${i}{$}${a}`:`$`:u+=`${i}{-$${o}}${a}`}u=U(u);let d=u||`/`;return s&&r&&r.set(s,d),d}function he(e){let t=new Map(e.map(e=>[encodeURIComponent(e),e])),n=Array.from(t.keys()).map(e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)).join(`|`),r=new RegExp(n,`g`);return e=>e.replace(r,e=>t.get(e)??e)}function q(e,t,n){let r=t[e];return typeof r==`string`?e===`_splat`?/^[a-zA-Z0-9\-._~!/]*$/.test(r)?r:r.split(`/`).map(e=>J(e,n)).join(`/`):J(r,n):r}function ge({path:e,params:t,decoder:n,...r}){let i=!1,a=Object.create(null);if(!e||e===`/`)return{interpolatedPath:`/`,usedParams:a,isMissingParams:i};if(!e.includes(`$`))return{interpolatedPath:e,usedParams:a,isMissingParams:i};let o=e.length,s=0,c,l=``;for(;s!0,()=>!1)}function ve(){return()=>{}}var ye=t((e=>{var t=r();function n(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var i=typeof Object.is==`function`?Object.is:n,a=t.useState,o=t.useEffect,s=t.useLayoutEffect,c=t.useDebugValue;function l(e,t){var n=t(),r=a({inst:{value:n,getSnapshot:t}}),i=r[0].inst,l=r[1];return s(function(){i.value=n,i.getSnapshot=t,u(i)&&l({inst:i})},[e,n,t]),o(function(){return u(i)&&l({inst:i}),e(function(){u(i)&&l({inst:i})})},[e]),c(n),n}function u(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!i(e,n)}catch{return!0}}function d(e,t){return t()}var f=typeof window>`u`||window.document===void 0||window.document.createElement===void 0?d:l;e.useSyncExternalStore=t.useSyncExternalStore===void 0?f:t.useSyncExternalStore})),Q=t(((e,t)=>{t.exports=ye()})),be=t((e=>{var t=r(),n=Q();function i(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var a=typeof Object.is==`function`?Object.is:i,o=n.useSyncExternalStore,s=t.useRef,c=t.useEffect,l=t.useMemo,u=t.useDebugValue;e.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var d=s(null);if(d.current===null){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=l(function(){function e(e){if(!o){if(o=!0,s=e,e=r(e),i!==void 0&&f.hasValue){var t=f.value;if(i(t,e))return c=t}return c=e}if(t=c,a(s,e))return t;var n=r(e);return i!==void 0&&i(t,n)?(s=e,t):(s=e,c=n)}var o=!1,s,c,l=n===void 0?null:n;return[function(){return e(t())},l===null?void 0:function(){return e(l())}]},[t,n,r,i]);var p=o(e,d[0],d[1]);return c(function(){f.hasValue=!0,f.value=p},[p]),u(p),p}})),$=t(((e,t)=>{t.exports=be()})),xe=$();function Se(e,t){return e===t}function Ce(e,t,n=Se){let r=(0,Y.useCallback)(t=>{if(!e)return()=>{};let{unsubscribe:n}=e.subscribe(t);return n},[e]),i=(0,Y.useCallback)(()=>e?.get(),[e]);return(0,xe.useSyncExternalStoreWithSelector)(r,i,i,t,n)}export{o as A,S as C,g as D,te as E,i as F,u as I,d as L,v as M,p as N,ne as O,y as P,D as S,_ as T,se as _,Z as a,le as b,pe as c,K as d,me as f,ae as g,G as h,_e as i,C as j,T as k,ge as l,W as m,$ as n,U as o,fe as p,Q as r,he as s,Ce as t,de as u,oe as v,E as w,O as x,ie as y}; \ No newline at end of file +import{a as e,i as t,n,r}from"./compiler-runtime.js";var i=e(r(),1),a=i.use,o=typeof window<`u`?i.useLayoutEffect:i.useEffect;function s(e){let t=i.useRef({value:e,prev:null}),n=t.current.value;return e!==n&&(t.current={value:e,prev:n}),t.current.prev}function c(e,t,n={},r={}){i.useEffect(()=>{if(!e.current||r.disabled||typeof IntersectionObserver!=`function`)return;let i=new IntersectionObserver(([e])=>{t(e)},n);return i.observe(e.current),()=>{i.disconnect()}},[t,n,r.disabled,e])}function l(e){let t=i.useRef(null);return i.useImperativeHandle(e,()=>t.current,[]),t}function u(e){return e[e.length-1]}function d(e){return typeof e==`function`}function f(e,t){return d(e)?e(t):e}var p=Object.prototype.hasOwnProperty,m=Object.prototype.propertyIsEnumerable,h=()=>Object.create(null),g=(e,t)=>_(e,t,h);function _(e,t,n=()=>({}),r=0){if(e===t)return e;if(r>500)return t;let i=t,a=x(e)&&x(i);if(!a&&!(y(e)&&y(i)))return i;let o=a?e:v(e);if(!o)return i;let s=a?i:v(i);if(!s)return i;let c=o.length,l=s.length,u=a?Array(l):n(),d=0;for(let t=0;ti||!S(e[o],t[o],n)))return!1;return i===a}return!1}function ee(e){let t,n,r=new Promise((e,r)=>{t=e,n=r});return r.status=`pending`,r.resolve=n=>{r.status=`resolved`,r.value=n,t(n),e?.(n)},r.reject=e=>{r.status=`rejected`,n(e)},r}function te(e){return typeof e?.message==`string`?e.message.startsWith(`Failed to fetch dynamically imported module`)||e.message.startsWith(`error loading dynamically imported module`)||e.message.startsWith(`Importing a module script failed`):!1}function ne(e){return!!(e&&typeof e==`object`&&typeof e.then==`function`)}function re(e){return e.replace(/[\x00-\x1f\x7f]/g,``)}function C(e){let t;try{t=decodeURI(e)}catch{t=e.replaceAll(/%[0-9A-F]{2}/gi,e=>{try{return decodeURI(e)}catch{return e}})}return re(t)}var ie=[`http:`,`https:`,`mailto:`,`tel:`];function ae(e,t){if(!e)return!1;try{let n=new URL(e);return!t.has(n.protocol)}catch{return!1}}var oe={"&":`\\u0026`,">":`\\u003e`,"<":`\\u003c`,"\u2028":`\\u2028`,"\u2029":`\\u2029`},se=/[&><\u2028\u2029]/g;function ce(e){return e.replace(se,e=>oe[e])}function le(e){if(!e||!/[%\\\x00-\x1f\x7f]/.test(e)&&!e.startsWith(`//`))return{path:e,handledProtocolRelativeURL:!1};let t=/%25|%5C/gi,n=0,r=``,i;for(;(i=t.exec(e))!==null;)r+=C(e.slice(n,i.index))+i[0],n=t.lastIndex;r+=C(n?e.slice(n):e);let a=!1;return r.startsWith(`//`)&&(a=!0,r=`/`+r.replace(/^\/+/,``)),{path:r,handledProtocolRelativeURL:a}}function w(e){return/\s|[^\u0000-\u007F]/.test(e)?e.replace(/\s|[^\u0000-\u007F]/gu,encodeURIComponent):e}function T(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n{e.next&&(e.prev?(e.prev.next=e.next,e.next.prev=e.prev,e.next=void 0,r&&(r.next=e,e.prev=r)):(e.next.prev=void 0,n=e.next,e.next=void 0,r&&(e.prev=r,r.next=e)),r=e)};return{get(e){let n=t.get(e);if(n)return i(n),n.value},set(a,o){if(t.size>=e&&n){let e=n;t.delete(e.key),e.next&&(n=e.next,e.next.prev=void 0),e===r&&(r=void 0)}let s=t.get(a);if(s)s.value=o,i(s);else{let e={key:a,value:o,prev:r};r&&(r.next=e),r=e,n||=e,t.set(a,e)}},clear(){t.clear(),n=void 0,r=void 0}}}var O=4,k=5;function ue(e){let t=e.indexOf(`{`);if(t===-1)return null;let n=e.indexOf(`}`,t);return n===-1||t+1>=e.length?null:[t,n]}function A(e,t,n=new Uint16Array(6)){let r=e.indexOf(`/`,t),i=r===-1?e.length:r,a=e.substring(t,i);if(!a||!a.includes(`$`))return n[0]=0,n[1]=t,n[2]=t,n[3]=i,n[4]=i,n[5]=i,n;if(a===`$`){let r=e.length;return n[0]=2,n[1]=t,n[2]=t,n[3]=r,n[4]=r,n[5]=r,n}if(a.charCodeAt(0)===36)return n[0]=1,n[1]=t,n[2]=t+1,n[3]=i,n[4]=i,n[5]=i,n;let o=ue(a);if(o){let[r,s]=o,c=a.charCodeAt(r+1);if(c===45){if(r+2!e.skipOnParamError&&e.caseSensitive===f&&e.prefix===p&&e.suffix===m);if(h)o=h;else{let e=F(1,n.fullPath??n.from,f,p,m);o=e,e.depth=a,e.parent=i,i.dynamic??=[],i.dynamic.push(e)}break}case 3:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),f=c&&!!(t||s),p=t?f?t:t.toLowerCase():void 0,m=s?f?s:s.toLowerCase():void 0,h=!l&&i.optional?.find(e=>!e.skipOnParamError&&e.caseSensitive===f&&e.prefix===p&&e.suffix===m);if(h)o=h;else{let e=F(3,n.fullPath??n.from,f,p,m);o=e,e.parent=i,e.depth=a,i.optional??=[],i.optional.push(e)}break}case 2:{let t=r.substring(u,e[1]),s=r.substring(e[4],d),l=c&&!!(t||s),f=t?l?t:t.toLowerCase():void 0,p=s?l?s:s.toLowerCase():void 0,m=F(2,n.fullPath??n.from,l,f,p);o=m,m.parent=i,m.depth=a,i.wildcard??=[],i.wildcard.push(m)}}i=o}if(l&&n.children&&!n.isRoot&&n.id&&n.id.charCodeAt(n.id.lastIndexOf(`/`)+1)===95){let e=P(n.fullPath??n.from);e.kind=k,e.parent=i,a++,e.depth=a,i.pathless??=[],i.pathless.push(e),i=e}let u=(n.path||!n.children)&&!n.isRoot;if(u&&r.endsWith(`/`)){let e=P(n.fullPath??n.from);e.kind=O,e.parent=i,a++,e.depth=a,i.index=e,i=e}i.parse=n.options?.params?.parse??null,i.skipOnParamError=l,i.parsingPriority=n.options?.skipRouteOnParseError?.priority??0,u&&!i.route&&(i.route=n,i.fullPath=n.fullPath??n.from)}if(n.children)for(let r of n.children)j(e,t,r,s,i,a,o)}function M(e,t){if(e.skipOnParamError&&!t.skipOnParamError)return-1;if(!e.skipOnParamError&&t.skipOnParamError)return 1;if(e.skipOnParamError&&t.skipOnParamError&&(e.parsingPriority||t.parsingPriority))return t.parsingPriority-e.parsingPriority;if(e.prefix&&t.prefix&&e.prefix!==t.prefix){if(e.prefix.startsWith(t.prefix))return-1;if(t.prefix.startsWith(e.prefix))return 1}if(e.suffix&&t.suffix&&e.suffix!==t.suffix){if(e.suffix.endsWith(t.suffix))return-1;if(t.suffix.endsWith(e.suffix))return 1}return e.prefix&&!t.prefix?-1:!e.prefix&&t.prefix?1:e.suffix&&!t.suffix?-1:!e.suffix&&t.suffix?1:e.caseSensitive&&!t.caseSensitive?-1:!e.caseSensitive&&t.caseSensitive?1:0}function N(e){if(e.pathless)for(let t of e.pathless)N(t);if(e.static)for(let t of e.static.values())N(t);if(e.staticInsensitive)for(let t of e.staticInsensitive.values())N(t);if(e.dynamic?.length){e.dynamic.sort(M);for(let t of e.dynamic)N(t)}if(e.optional?.length){e.optional.sort(M);for(let t of e.optional)N(t)}if(e.wildcard?.length){e.wildcard.sort(M);for(let t of e.wildcard)N(t)}}function P(e){return{kind:0,depth:0,pathless:null,index:null,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:e,parent:null,parse:null,skipOnParamError:!1,parsingPriority:0}}function F(e,t,n,r,i){return{kind:e,depth:0,pathless:null,index:null,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:t,parent:null,parse:null,skipOnParamError:!1,parsingPriority:0,caseSensitive:n,prefix:r,suffix:i}}function de(e,t){let n=P(`/`),r=new Uint16Array(6);for(let t of e)j(!1,r,t,1,n,0);N(n),t.masksTree=n,t.flatCache=D(1e3)}function fe(e,t){e||=`/`;let n=t.flatCache.get(e);if(n)return n;let r=R(e,t.masksTree);return t.flatCache.set(e,r),r}function pe(e,t,n,r,i){e||=`/`,r||=`/`;let a=t?`case\0${e}`:e,o=i.singleCache.get(a);return o||(o=P(`/`),j(t,new Uint16Array(6),{from:e},1,o,0),i.singleCache.set(a,o)),R(r,o,n)}function me(e,t,n=!1){let r=n?e:`nofuzz\0${e}`,i=t.matchCache.get(r);if(i!==void 0)return i;e||=`/`;let a;try{a=R(e,t.segmentTree,n)}catch(e){if(e instanceof URIError)a=null;else throw e}return a&&(a.branch=he(a.route)),t.matchCache.set(r,a),a}function I(e){return e===`/`?e:e.replace(/\/{1,}$/,``)}function L(e,t=!1,n){let r=P(e.fullPath),i=new Uint16Array(6),a={},o={},s=0;return j(t,i,e,1,r,0,e=>{if(n?.(e,s),e.id in a&&E(),a[e.id]=e,s!==0&&e.path){let t=I(e.fullPath);(!o[t]||e.fullPath.endsWith(`/`))&&(o[t]=e)}s++}),N(r),{processedTree:{segmentTree:r,singleCache:D(1e3),matchCache:D(1e3),flatCache:null,masksTree:null},routesById:a,routesByPath:o}}function R(e,t,n=!1){let r=e.split(`/`),i=_e(e,r,t,n);if(!i)return null;let[a]=z(e,r,i);return{route:i.node.route,rawParams:a,parsedParams:i.parsedParams}}function z(e,t,n){let r=ge(n.node),i=null,a=Object.create(null),o=n.extract?.part??0,s=n.extract?.node??0,c=n.extract?.path??0,l=n.extract?.segment??0;for(;s=0;n--){let r=i.optional[n];s.push({node:r,index:u,skipped:e,depth:t,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b)for(let e=i.optional.length-1;e>=0;e--){let n=i.optional[e],{prefix:r,suffix:a}=n;if(r||a){let e=n.caseSensitive?x:S??=x.toLowerCase();if(r&&!e.startsWith(r)||a&&!e.endsWith(a))continue}s.push({node:n,index:u+1,skipped:f,depth:t,statics:m,dynamics:h,optionals:g+1,extract:_,rawParams:v,parsedParams:y})}}if(!b&&i.dynamic&&x)for(let e=i.dynamic.length-1;e>=0;e--){let t=i.dynamic[e],{prefix:n,suffix:r}=t;if(n||r){let e=t.caseSensitive?x:S??=x.toLowerCase();if(n&&!e.startsWith(n)||r&&!e.endsWith(r))continue}s.push({node:t,index:u+1,skipped:f,depth:p+1,statics:m,dynamics:h+1,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b&&i.staticInsensitive){let e=i.staticInsensitive.get(S??=x.toLowerCase());e&&s.push({node:e,index:u+1,skipped:f,depth:p+1,statics:m+1,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(!b&&i.static){let e=i.static.get(x);e&&s.push({node:e,index:u+1,skipped:f,depth:p+1,statics:m+1,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}if(i.pathless){let e=p+1;for(let t=i.pathless.length-1;t>=0;t--){let n=i.pathless[t];s.push({node:n,index:u,skipped:f,depth:e,statics:m,dynamics:h,optionals:g,extract:_,rawParams:v,parsedParams:y})}}}if(d&&c)return V(c,d)?d:c;if(d)return d;if(c)return c;if(r&&l){let n=l.index;for(let e=0;ee.statics||t.statics===e.statics&&(t.dynamics>e.dynamics||t.dynamics===e.dynamics&&(t.optionals>e.optionals||t.optionals===e.optionals&&((t.node.kind===O)>(e.node.kind===O)||t.node.kind===O==(e.node.kind===O)&&t.depth>e.depth))):!0}function ve(e){return H(e.filter(e=>e!==void 0).join(`/`))}function H(e){return e.replace(/\/{2,}/g,`/`)}function U(e){return e===`/`?e:e.replace(/^\/{1,}/,``)}function W(e){let t=e.length;return t>1&&e[t-1]===`/`?e.replace(/\/{1,}$/,``):e}function ye(e){return W(U(e))}function G(e,t){return e?.endsWith(`/`)&&e!==`/`&&e!==`${t}/`?e.slice(0,-1):e}function be(e,t,n){return G(e,n)===G(t,n)}function xe({base:e,to:t,trailingSlash:n=`never`,cache:r}){let i=t.startsWith(`/`),a=!i&&t===`.`,o;if(r){o=i?t:a?e:e+`\0`+t;let n=r.get(o);if(n)return n}let s;if(a)s=e.split(`/`);else if(i)s=t.split(`/`);else{for(s=e.split(`/`);s.length>1&&u(s)===``;)s.pop();let n=t.split(`/`);for(let e=0,t=n.length;e1&&(u(s)===``?n===`never`&&s.pop():n===`always`&&s.push(``));let c,l=``;for(let e=0;e0&&(l+=`/`);let t=s[e];if(!t)continue;c=A(t,0,c);let n=c[0];if(n===0){l+=t;continue}let r=c[5],i=t.substring(0,c[1]),a=t.substring(c[4],r),o=t.substring(c[2],c[3]);n===1?l+=i||a?`${i}{$${o}}${a}`:`$${o}`:n===2?l+=i||a?`${i}{$}${a}`:`$`:l+=`${i}{-$${o}}${a}`}l=H(l);let d=l||`/`;return o&&r&&r.set(o,d),d}function Se(e){let t=new Map(e.map(e=>[encodeURIComponent(e),e])),n=Array.from(t.keys()).map(e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)).join(`|`),r=new RegExp(n,`g`);return e=>e.replace(r,e=>t.get(e)??e)}function K(e,t,n){let r=t[e];return typeof r==`string`?e===`_splat`?/^[a-zA-Z0-9\-._~!/]*$/.test(r)?r:r.split(`/`).map(e=>q(e,n)).join(`/`):q(r,n):r}function Ce({path:e,params:t,decoder:n,...r}){let i=!1,a=Object.create(null);if(!e||e===`/`)return{interpolatedPath:`/`,usedParams:a,isMissingParams:i};if(!e.includes(`$`))return{interpolatedPath:e,usedParams:a,isMissingParams:i};let o=e.length,s=0,c,l=``;for(;s!0,()=>!1)}function Te(){return()=>{}}var X=i.createContext(null);function Z(e){return i.useContext(X)}var Ee=t((e=>{var t=r();function n(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var i=typeof Object.is==`function`?Object.is:n,a=t.useState,o=t.useEffect,s=t.useLayoutEffect,c=t.useDebugValue;function l(e,t){var n=t(),r=a({inst:{value:n,getSnapshot:t}}),i=r[0].inst,l=r[1];return s(function(){i.value=n,i.getSnapshot=t,u(i)&&l({inst:i})},[e,n,t]),o(function(){return u(i)&&l({inst:i}),e(function(){u(i)&&l({inst:i})})},[e]),c(n),n}function u(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!i(e,n)}catch{return!0}}function d(e,t){return t()}var f=typeof window>`u`||window.document===void 0||window.document.createElement===void 0?d:l;e.useSyncExternalStore=t.useSyncExternalStore===void 0?f:t.useSyncExternalStore})),Q=t(((e,t)=>{t.exports=Ee()})),De=t((e=>{var t=r(),n=Q();function i(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var a=typeof Object.is==`function`?Object.is:i,o=n.useSyncExternalStore,s=t.useRef,c=t.useEffect,l=t.useMemo,u=t.useDebugValue;e.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var d=s(null);if(d.current===null){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=l(function(){function e(e){if(!o){if(o=!0,s=e,e=r(e),i!==void 0&&f.hasValue){var t=f.value;if(i(t,e))return c=t}return c=e}if(t=c,a(s,e))return t;var n=r(e);return i!==void 0&&i(t,n)?(s=e,t):(s=e,c=n)}var o=!1,s,c,l=n===void 0?null:n;return[function(){return e(t())},l===null?void 0:function(){return e(l())}]},[t,n,r,i]);var p=o(e,d[0],d[1]);return c(function(){f.hasValue=!0,f.value=p},[p]),u(p),p}})),$=t(((e,t)=>{t.exports=De()})),Oe=$();function ke(e,t){return e===t}function Ae(e,t,n=ke){let r=(0,i.useCallback)(t=>{if(!e)return()=>{};let{unsubscribe:n}=e.subscribe(t);return n},[e]),a=(0,i.useCallback)(()=>e?.get(),[e]);return(0,Oe.useSyncExternalStoreWithSelector)(r,a,a,t,n)}export{w as A,a as B,D as C,ee as D,T as E,y as F,c as H,ne as I,u as L,f as M,ae as N,le as O,te as P,g as R,L as S,ie as T,o as U,l as V,s as W,W as _,X as a,pe as b,H as c,Ce as d,ve as f,U as g,ye as h,Z as i,ce as j,S as k,Se as l,xe as m,$ as n,we as o,G as p,Q as r,Y as s,Ae as t,be as u,fe as v,E as w,de as x,me as y,_ as z}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/assets/zod.js b/spinifex/services/spinifexui/frontend/dist/assets/zod.js index da56275dd..34d9f5a62 100644 --- a/spinifex/services/spinifexui/frontend/dist/assets/zod.js +++ b/spinifex/services/spinifexui/frontend/dist/assets/zod.js @@ -1 +1 @@ -import{a as e,r as t}from"./compiler-runtime.js";import{M as n,N as r,j as i}from"./SignatureV4.js";var a=e(t(),1),o=e=>e.type===`checkbox`,s=e=>e instanceof Date,c=e=>e==null,l=e=>typeof e==`object`,u=e=>!c(e)&&!Array.isArray(e)&&l(e)&&!s(e),d=e=>u(e)&&e.target?o(e.target)?e.target.checked:e.target.value:e,f=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,p=(e,t)=>e.has(f(t)),m=e=>{let t=e.constructor&&e.constructor.prototype;return u(t)&&t.hasOwnProperty(`isPrototypeOf`)},h=typeof window<`u`&&window.HTMLElement!==void 0&&typeof document<`u`;function g(e){if(e instanceof Date)return new Date(e);let t=typeof FileList<`u`&&e instanceof FileList;if(h&&(e instanceof Blob||t))return e;let n=Array.isArray(e);if(!n&&!(u(e)&&m(e)))return e;let r=n?[]:Object.create(Object.getPrototypeOf(e));for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[t]=g(e[t]));return r}var _=e=>/^\w*$/.test(e),v=e=>e===void 0,y=e=>Array.isArray(e)?e.filter(Boolean):[],b=e=>y(e.replace(/["|']|\]/g,``).split(/\.|\[/)),x=(e,t,n)=>{if(!t||!u(e))return n;let r=(_(t)?[t]:b(t)).reduce((e,t)=>c(e)?e:e[t],e);return v(r)||r===e?v(e[t])?n:e[t]:r},S=e=>typeof e==`boolean`,C=e=>typeof e==`function`,w=(e,t,n)=>{let r=-1,i=_(t)?[t]:b(t),a=i.length,o=a-1;for(;++ra.useContext(A),M=(e,t,n,r=!0)=>{let i={defaultValues:t._defaultValues};for(let a in e)Object.defineProperty(i,a,{get:()=>{let i=a;return t._proxyFormState[i]!==E.all&&(t._proxyFormState[i]=!r||E.all),n&&(n[i]=!0),e[i]}});return i},N=typeof window<`u`?a.useLayoutEffect:a.useEffect;function P(e){let t=j(),{control:n=t,disabled:r,name:i,exact:o}=e||{},[s,c]=a.useState(n._formState),l=a.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return N(()=>n._subscribe({name:i,formState:l.current,exact:o,callback:e=>{!r&&c({...n._formState,...e})}}),[i,r,o]),a.useEffect(()=>{l.current.isValid&&n._setValid(!0)},[n]),a.useMemo(()=>M(s,n,l.current,!1),[s,n])}var F=e=>typeof e==`string`,I=(e,t,n,r,i)=>F(e)?(r&&t.watch.add(e),x(n,e,i)):Array.isArray(e)?e.map(e=>(r&&t.watch.add(e),x(n,e))):(r&&(t.watchAll=!0),n),ee=e=>c(e)||!l(e);function L(e,t,n=new WeakSet){if(ee(e)||ee(t))return Object.is(e,t);if(s(e)&&s(t))return Object.is(e.getTime(),t.getTime());let r=Object.keys(e),i=Object.keys(t);if(r.length!==i.length)return!1;if(n.has(e)||n.has(t))return!0;n.add(e),n.add(t);for(let a of r){let r=e[a];if(!i.includes(a))return!1;if(a!==`ref`){let e=t[a];if(s(r)&&s(e)||u(r)&&u(e)||Array.isArray(r)&&Array.isArray(e)?!L(r,e,n):!Object.is(r,e))return!1}}return!0}function R(e){let t=j(),{control:n=t,name:r,defaultValue:i,disabled:o,exact:s,compute:c}=e||{},l=a.useRef(i),u=a.useRef(c),d=a.useRef(void 0),f=a.useRef(n),p=a.useRef(r);u.current=c;let[m,h]=a.useState(()=>{let e=n._getWatch(r,l.current);return u.current?u.current(e):e}),g=a.useCallback(e=>{let t=I(r,n._names,e||n._formValues,!1,l.current);return u.current?u.current(t):t},[n._formValues,n._names,r]),_=a.useCallback(e=>{if(!o){let t=I(r,n._names,e||n._formValues,!1,l.current);if(u.current){let e=u.current(t);L(e,d.current)||(h(e),d.current=e)}else h(t)}},[n._formValues,n._names,o,r]);N(()=>((f.current!==n||!L(p.current,r))&&(f.current=n,p.current=r,_()),n._subscribe({name:r,formState:{values:!0},exact:s,callback:e=>{_(e.values)}})),[n,s,r,_]),a.useEffect(()=>n._removeUnmounted());let v=f.current!==n,y=p.current,b=a.useMemo(()=>{if(o)return null;let e=!v&&!L(y,r);return v||e?g():null},[o,v,r,y,g]);return b===null?m:b}function z(e){let t=j(),{name:n,disabled:r,control:i=t,shouldUnregister:o,defaultValue:s,exact:c=!0}=e,l=p(i._names.array,n),u=R({control:i,name:n,defaultValue:a.useMemo(()=>x(i._formValues,n,x(i._defaultValues,n,s)),[i,n,s]),exact:c}),f=P({control:i,name:n,exact:c}),m=a.useRef(e),h=a.useRef(void 0),_=a.useRef(i.register(n,{...e.rules,value:u,...S(e.disabled)?{disabled:e.disabled}:{}}));m.current=e;let y=a.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!x(f.errors,n)},isDirty:{enumerable:!0,get:()=>!!x(f.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!x(f.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!x(f.validatingFields,n)},error:{enumerable:!0,get:()=>x(f.errors,n)}}),[f,n]),b=a.useCallback(e=>_.current.onChange({target:{value:d(e),name:n},type:T.CHANGE}),[n]),E=a.useCallback(()=>_.current.onBlur({target:{value:x(i._formValues,n),name:n},type:T.BLUR}),[n,i._formValues]),D=a.useCallback(e=>{let t=x(i._fields,n);t&&t._f&&e&&(t._f.ref={focus:()=>C(e.focus)&&e.focus(),select:()=>C(e.select)&&e.select(),setCustomValidity:t=>C(e.setCustomValidity)&&e.setCustomValidity(t),reportValidity:()=>C(e.reportValidity)&&e.reportValidity()})},[i._fields,n]),O=a.useMemo(()=>({name:n,value:u,...S(r)||f.disabled?{disabled:f.disabled||r}:{},onChange:b,onBlur:E,ref:D}),[n,r,f.disabled,b,E,D,u]);return a.useEffect(()=>{let e=i._options.shouldUnregister||o,t=h.current;t&&t!==n&&!l&&i.unregister(t),i.register(n,{...m.current.rules,...S(m.current.disabled)?{disabled:m.current.disabled}:{}});let r=(e,t)=>{let n=x(i._fields,e);n&&n._f&&(n._f.mount=t)};if(r(n,!0),e){let e=g(x(i._options.defaultValues,n,m.current.defaultValue));w(i._defaultValues,n,e),v(x(i._formValues,n))&&w(i._formValues,n,e)}return!l&&i.register(n),h.current=n,()=>{(l?e&&!i._state.action:e)?i.unregister(n):r(n,!1)}},[n,i,l,o]),a.useEffect(()=>{i._setDisabledField({disabled:r,name:n})},[r,n,i]),a.useMemo(()=>({field:O,formState:f,fieldState:y}),[O,f,y])}var te=e=>e.render(z(e)),ne=a.createContext(null);ne.displayName=`HookFormContext`;var re=(e,t,n,r,i)=>t?{...n[e],types:{...n[e]&&n[e].types?n[e].types:{},[r]:i||!0}}:{},B=e=>Array.isArray(e)?e:[e],ie=()=>{let e=[];return{get observers(){return e},next:t=>{for(let n of e)n.next&&n.next(t)},subscribe:t=>(e.push(t),{unsubscribe:()=>{e=e.filter(e=>e!==t)}}),unsubscribe:()=>{e=[]}}};function ae(e,t){let n={};for(let r in e)if(e.hasOwnProperty(r)){let i=e[r],a=t[r];if(i&&u(i)&&a){let e=ae(i,a);u(e)&&(n[r]=e)}else e[r]&&(n[r]=a)}return n}var V=e=>u(e)&&!Object.keys(e).length,oe=e=>e.type===`file`,se=e=>{if(!h)return!1;let t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},ce=e=>e.type===`select-multiple`,H=e=>e.type===`radio`,le=e=>H(e)||o(e),ue=e=>se(e)&&e.isConnected;function de(e,t){let n=t.slice(0,-1).length,r=0;for(;r{for(let t in e)if(C(e[t]))return!0;return!1};function pe(e){return Array.isArray(e)||u(e)&&!W(e)}function G(e,t={}){for(let n in e){let r=e[n];pe(r)?(t[n]=Array.isArray(r)?[]:{},G(r,t[n])):v(r)||(t[n]=!0)}return t}function K(e,t,n){n||=G(t);for(let r in e){let i=e[r];if(pe(i))v(t)||ee(n[r])?n[r]=G(i,Array.isArray(i)?[]:{}):K(i,c(t)?{}:t[r],n[r]);else{let e=t[r];n[r]=!L(i,e)}}return n}var q={value:!1,isValid:!1},me={value:!0,isValid:!0},J=e=>{if(Array.isArray(e)){if(e.length>1){let t=e.filter(e=>e&&e.checked&&!e.disabled).map(e=>e.value);return{value:t,isValid:!!t.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!v(e[0].attributes.value)?v(e[0].value)||e[0].value===``?me:{value:e[0].value,isValid:!0}:me:q}return q},he=(e,{valueAsNumber:t,valueAsDate:n,setValueAs:r})=>v(e)?e:t?e===``?NaN:e&&+e:n&&F(e)?new Date(e):r?r(e):e,Y={isValid:!1,value:null},ge=e=>Array.isArray(e)?e.reduce((e,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:e,Y):Y;function _e(e){let t=e.ref;return oe(t)?t.files:H(t)?ge(e.refs).value:ce(t)?[...t.selectedOptions].map(({value:e})=>e):o(t)?J(e.refs).value:he(v(t.value)?e.ref.value:t.value,e)}var ve=(e,t,n,r)=>{let i={};for(let n of e){let e=x(t,n);e&&w(i,n,e._f)}return{criteriaMode:n,names:[...e],fields:i,shouldUseNativeValidation:r}},X=e=>e instanceof RegExp,Z=e=>v(e)?e:X(e)?e.source:u(e)?X(e.value)?e.value.source:e.value:e,ye=e=>({isOnSubmit:!e||e===E.onSubmit,isOnBlur:e===E.onBlur,isOnChange:e===E.onChange,isOnAll:e===E.all,isOnTouch:e===E.onTouched}),be=`AsyncFunction`,xe=e=>!!e&&!!e.validate&&!!(C(e.validate)&&e.validate.constructor.name===be||u(e.validate)&&Object.values(e.validate).find(e=>e.constructor.name===be)),Se=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),Ce=(e,t,n)=>!n&&(t.watchAll||t.watch.has(e)||[...t.watch].some(t=>e.startsWith(t)&&/^\.\w+/.test(e.slice(t.length)))),we=(e,t,n,r)=>{for(let i of n||Object.keys(e)){let n=x(e,i);if(n){let{_f:e,...a}=n;if(e){if(e.refs&&e.refs[0]&&t(e.refs[0],i)&&!r||e.ref&&t(e.ref,e.name)&&!r)return!0;if(we(a,t))break}else if(u(a)&&we(a,t))break}}};function Te(e,t,n){let r=x(e,n);if(r||_(n))return{error:r,name:n};let i=n.split(`.`);for(;i.length;){let r=i.join(`.`),a=x(t,r),o=x(e,r);if(a&&!Array.isArray(a)&&n!==r)return{name:n};if(o&&o.type)return{name:r,error:o};if(o&&o.root&&o.root.type)return{name:`${r}.root`,error:o.root};i.pop()}return{name:n}}var Ee=(e,t,n,r)=>{n(e);let{name:i,...a}=e;return V(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(e=>t[e]===(!r||E.all))},De=(e,t,n)=>!e||!t||e===t||B(e).some(e=>e&&(n?e===t:e.startsWith(t)||t.startsWith(e))),Oe=(e,t,n,r,i)=>i.isOnAll?!1:!n&&i.isOnTouch?!(t||e):(n?r.isOnBlur:i.isOnBlur)?!e:(n?r.isOnChange:i.isOnChange)?e:!0,ke=(e,t)=>!y(x(e,t)).length&&U(e,t),Ae=(e,t,n)=>{let r=B(x(e,n));return w(r,k,t[n]),w(e,n,r),e};function Q(e,t,n=`validate`){if(F(e)||Array.isArray(e)&&e.every(F)||S(e)&&!e)return{type:n,message:F(e)?e:``,ref:t}}var $=e=>u(e)&&!X(e)?e:{value:e,message:``},je=async(e,t,n,r,i,a)=>{let{ref:s,refs:l,required:d,maxLength:f,minLength:p,min:m,max:h,pattern:g,validate:_,name:y,valueAsNumber:b,mount:w}=e._f,T=x(n,y);if(!w||t.has(y))return{};let E=l?l[0]:s,O=e=>{i&&E.reportValidity&&(E.setCustomValidity(S(e)?``:e||``),E.reportValidity())},k={},A=H(s),j=o(s),M=A||j,N=(b||oe(s))&&v(s.value)&&v(T)||se(s)&&s.value===``||T===``||Array.isArray(T)&&!T.length,P=re.bind(null,y,r,k),I=(e,t,n,r=D.maxLength,i=D.minLength)=>{let a=e?t:n;k[y]={type:e?r:i,message:a,ref:s,...P(e?r:i,a)}};if(a?!Array.isArray(T)||!T.length:d&&(!M&&(N||c(T))||S(T)&&!T||j&&!J(l).isValid||A&&!ge(l).isValid)){let{value:e,message:t}=F(d)?{value:!!d,message:d}:$(d);if(e&&(k[y]={type:D.required,message:t,ref:E,...P(D.required,t)},!r))return O(t),k}if(!N&&(!c(m)||!c(h))){let e,t,n=$(h),i=$(m);if(!c(T)&&!isNaN(T)){let r=s.valueAsNumber||T&&+T;c(n.value)||(e=r>n.value),c(i.value)||(t=rnew Date(new Date().toDateString()+` `+e),o=s.type==`time`,c=s.type==`week`;F(n.value)&&T&&(e=o?a(T)>a(n.value):c?T>n.value:r>new Date(n.value)),F(i.value)&&T&&(t=o?a(T)+e.value,i=!c(t.value)&&T.length<+t.value;if((n||i)&&(I(n,e.message,t.message),!r))return O(k[y].message),k}if(g&&!N&&F(T)){let{value:e,message:t}=$(g);if(X(e)&&!T.match(e)&&(k[y]={type:D.pattern,message:t,ref:s,...P(D.pattern,t)},!r))return O(t),k}if(_){if(C(_)){let e=Q(await _(T,n),E);if(e&&(k[y]={...e,...P(D.validate,e.message)},!r))return O(e.message),k}else if(u(_)){let e={};for(let t in _){if(!V(e)&&!r)break;let i=Q(await _[t](T,n),E,t);i&&(e={...i,...P(t,i.message)},O(i.message),r&&(k[y]=e))}if(!V(e)&&(k[y]={ref:E,...e},!r))return k}}return O(!0),k},Me={mode:E.onSubmit,reValidateMode:E.onChange,shouldFocusError:!0};function Ne(e={}){let t={...Me,...e},n={submitCount:0,isDirty:!1,isReady:!1,isLoading:C(t.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1},r={},i=(u(t.defaultValues)||u(t.values))&&g(t.defaultValues||t.values)||{},a=t.shouldUnregister?{}:g(i),l={action:!1,mount:!1,watch:!1,keepIsValid:!1},m={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},_,b=0,A={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},j={...A},M={...j},N={array:ie(),state:ie()},P=t.criteriaMode===E.all,ee=e=>t=>{clearTimeout(b),b=setTimeout(e,t)},R=async e=>{if(!l.keepIsValid&&!t.disabled&&(j.isValid||M.isValid||e)){let e;t.resolver?(e=V((await W()).errors),z()):e=await q({fields:r,onlyCheckValid:!0,eventType:T.VALID}),e!==n.isValid&&N.state.next({isValid:e})}},z=(e,r)=>{!t.disabled&&(j.isValidating||j.validatingFields||M.isValidating||M.validatingFields)&&((e||Array.from(m.mount)).forEach(e=>{e&&(r?w(n.validatingFields,e,r):U(n.validatingFields,e))}),N.state.next({validatingFields:n.validatingFields,isValidating:!V(n.validatingFields)}))},te=(e,o=[],s,c,u=!0,d=!0)=>{if(c&&s&&!t.disabled){if(l.action=!0,d&&Array.isArray(x(r,e))){let t=s(x(r,e),c.argA,c.argB);u&&w(r,e,t)}if(d&&Array.isArray(x(n.errors,e))){let t=s(x(n.errors,e),c.argA,c.argB);u&&w(n.errors,e,t),ke(n.errors,e)}if((j.touchedFields||M.touchedFields)&&d&&Array.isArray(x(n.touchedFields,e))){let t=s(x(n.touchedFields,e),c.argA,c.argB);u&&w(n.touchedFields,e,t)}if(j.dirtyFields||M.dirtyFields){let t=K(i,a),r=f(e);w(n.dirtyFields,r,x(t,r))}N.state.next({name:e,isDirty:J(e,o),dirtyFields:n.dirtyFields,errors:n.errors,isValid:n.isValid})}else w(a,e,o)},ne=(e,t)=>{w(n.errors,e,t),N.state.next({errors:n.errors})},re=e=>{n.errors=e,N.state.next({errors:n.errors,isValid:!1})},H=(e,t,n,o)=>{let s=x(r,e);if(s){let r=x(a,e,v(n)?x(i,e):n);v(r)||o&&o.defaultChecked||t?w(a,e,t?r:_e(s._f)):X(e,r),l.mount&&!l.action&&R()}},de=(e,r,a,o,s)=>{let c=!1,l=!1,u={name:e};if(!t.disabled){if(!a||o){(j.isDirty||M.isDirty)&&(l=n.isDirty,n.isDirty=u.isDirty=J(),c=l!==u.isDirty);let t=L(x(i,e),r);l=!!x(n.dirtyFields,e),t?U(n.dirtyFields,e):w(n.dirtyFields,e,!0),u.dirtyFields=n.dirtyFields,c||=(j.dirtyFields||M.dirtyFields)&&l!==!t}if(a){let t=x(n.touchedFields,e);t||(w(n.touchedFields,e,a),u.touchedFields=n.touchedFields,c||=(j.touchedFields||M.touchedFields)&&t!==a)}c&&s&&N.state.next(u)}return c?u:{}},fe=(e,r,i,a)=>{let o=x(n.errors,e),s=(j.isValid||M.isValid)&&S(r)&&n.isValid!==r;if(t.delayError&&i?(_=ee(()=>ne(e,i)),_(t.delayError)):(clearTimeout(b),_=null,i?w(n.errors,e,i):U(n.errors,e)),(i?!L(o,i):o)||!V(a)||s){let t={...a,...s&&S(r)?{isValid:r}:{},errors:n.errors,name:e};n={...n,...t},N.state.next(t)}},W=async e=>(z(e,!0),await t.resolver(a,t.context,ve(e||m.mount,r,t.criteriaMode,t.shouldUseNativeValidation))),pe=async e=>{let{errors:t}=await W(e);if(z(e),e)for(let r of e){let e=x(t,r);e?w(n.errors,r,e):U(n.errors,r)}else n.errors=t;return t},G=async({name:t,eventType:r})=>{if(e.validate){let i=await e.validate({formValues:a,formState:n,name:t,eventType:r});if(u(i))for(let e in i)i[e]&&Re(`${O}.${e}`,{message:F(i.message)?i.message:``,type:D.validate});else F(i)||!i?Re(O,{message:i||``,type:D.validate}):Le(O);return i}return!0},q=async({fields:r,onlyCheckValid:i,name:o,eventType:s,context:c={valid:!0,runRootValidation:!1}})=>{if(e.validate&&(c.runRootValidation=!0,!await G({name:o,eventType:s})&&(c.valid=!1,i)))return c.valid;for(let o in r){let l=r[o];if(l){let{_f:r,...u}=l;if(r){let o=m.array.has(r.name),s=l._f&&xe(l._f);s&&j.validatingFields&&z([r.name],!0);let u=await je(l,m.disabled,a,P,t.shouldUseNativeValidation&&!i,o);if(s&&j.validatingFields&&z([r.name]),u[r.name]&&(c.valid=!1,i)||(!i&&(x(u,r.name)?o?Ae(n.errors,u,r.name):w(n.errors,r.name,u[r.name]):U(n.errors,r.name)),e.shouldUseNativeValidation&&u[r.name]))break}!V(u)&&await q({context:c,onlyCheckValid:i,fields:u,name:o,eventType:s})}}return c.valid},me=()=>{for(let e of m.unMount){let t=x(r,e);t&&(t._f.refs?t._f.refs.every(e=>!ue(e)):!ue(t._f.ref))&&He(e)}m.unMount=new Set},J=(e,n)=>!t.disabled&&(e&&n&&w(a,e,n),!L(Fe(),i)),Y=(e,t,n)=>I(e,m,{...l.mount?a:v(t)?i:F(e)?{[e]:t}:t},n,t),ge=e=>y(x(l.mount?a:i,e,t.shouldUnregister?x(i,e,[]):[])),X=(e,t,n={})=>{let i=x(r,e),s=t;if(i){let n=i._f;n&&(!n.disabled&&w(a,e,he(t,n)),s=se(n.ref)&&c(t)?``:t,ce(n.ref)?[...n.ref.options].forEach(e=>e.selected=s.includes(e.value)):n.refs?o(n.ref)?n.refs.forEach(e=>{(!e.defaultChecked||!e.disabled)&&(Array.isArray(s)?e.checked=!!s.find(t=>t===e.value):e.checked=s===e.value||!!s)}):n.refs.forEach(e=>e.checked=e.value===s):oe(n.ref)?n.ref.value=``:(n.ref.value=s,n.ref.type||N.state.next({name:e,values:g(a)})))}(n.shouldDirty||n.shouldTouch)&&de(e,s,n.shouldTouch,n.shouldDirty,!0),n.shouldValidate&&Pe(e)},be=(e,t,n)=>{for(let i in t){if(!t.hasOwnProperty(i))return;let a=t[i],o=e+`.`+i,c=x(r,o);(m.array.has(e)||u(a)||c&&!c._f)&&!s(a)?be(o,a,n):X(o,a,n)}},Q=(e,t,o={})=>{let s=x(r,e),u=m.array.has(e),d=g(t);w(a,e,d),u?(N.array.next({name:e,values:g(a)}),(j.isDirty||j.dirtyFields||M.isDirty||M.dirtyFields)&&o.shouldDirty&&N.state.next({name:e,dirtyFields:K(i,a),isDirty:J(e,d)})):s&&!s._f&&!c(d)?be(e,d,o):X(e,d,o),Ce(e,m)?N.state.next({...n,name:e,values:g(a)}):N.state.next({name:l.mount?e:void 0,values:g(a)})},$=async i=>{l.mount=!0;let o=i.target,c=o.name,u=!0,f=x(r,c),p=e=>{u=Number.isNaN(e)||s(e)&&isNaN(e.getTime())||L(e,x(a,c,e))},h=ye(t.mode),v=ye(t.reValidateMode);if(f){let s,l,y=o.type?_e(f._f):d(i),b=i.type===T.BLUR||i.type===T.FOCUS_OUT,S=!Se(f._f)&&!e.validate&&!t.resolver&&!x(n.errors,c)&&!f._f.deps||Oe(b,x(n.touchedFields,c),n.isSubmitted,v,h),C=Ce(c,m,b);w(a,c,y),b?(!o||!o.readOnly)&&(f._f.onBlur&&f._f.onBlur(i),_&&_(0)):f._f.onChange&&f._f.onChange(i);let E=de(c,y,b),D=!V(E)||C;if(!b&&N.state.next({name:c,type:i.type,values:g(a)}),S)return(j.isValid||M.isValid)&&(t.mode===`onBlur`?b&&R():b||R()),D&&N.state.next({name:c,...C?{}:E});if(!t.resolver&&e.validate&&await G({name:c,eventType:i.type}),!b&&C&&N.state.next({...n}),t.resolver){let{errors:e}=await W([c]);if(z([c]),p(y),u){let t=Te(n.errors,r,c),i=Te(e,r,t.name||c);s=i.error,c=i.name,l=V(e)}}else z([c],!0),s=(await je(f,m.disabled,a,P,t.shouldUseNativeValidation))[c],z([c]),p(y),u&&(s?l=!1:(j.isValid||M.isValid)&&(l=await q({fields:r,onlyCheckValid:!0,name:c,eventType:i.type})));u&&(f._f.deps&&(!Array.isArray(f._f.deps)||f._f.deps.length>0)&&Pe(f._f.deps),fe(c,l,s,E))}},Ne=(e,t)=>{if(x(n.errors,t)&&e.focus)return e.focus(),1},Pe=async(e,i={})=>{let a,o,s=B(e);if(t.resolver){let t=await pe(v(e)?e:s);a=V(t),o=e?!s.some(e=>x(t,e)):a}else e?(o=(await Promise.all(s.map(async e=>{let t=x(r,e);return await q({fields:t&&t._f?{[e]:t}:t,eventType:T.TRIGGER})}))).every(Boolean),!(!o&&!n.isValid)&&R()):o=a=await q({fields:r,name:e,eventType:T.TRIGGER});return N.state.next({...!F(e)||(j.isValid||M.isValid)&&a!==n.isValid?{}:{name:e},...t.resolver||!e?{isValid:a}:{},errors:n.errors}),i.shouldFocus&&!o&&we(r,Ne,e?s:m.mount),o},Fe=(e,t)=>{let r={...l.mount?a:i};return t&&(r=ae(t.dirtyFields?n.dirtyFields:n.touchedFields,r)),v(e)?r:F(e)?x(r,e):e.map(e=>x(r,e))},Ie=(e,t)=>({invalid:!!x((t||n).errors,e),isDirty:!!x((t||n).dirtyFields,e),error:x((t||n).errors,e),isValidating:!!x(n.validatingFields,e),isTouched:!!x((t||n).touchedFields,e)}),Le=e=>{let t=e?B(e):void 0;t?.forEach(e=>U(n.errors,e)),t?t.forEach(e=>{N.state.next({name:e,errors:n.errors})}):N.state.next({errors:{}})},Re=(e,t,i)=>{let a=(x(r,e,{_f:{}})._f||{}).ref,{ref:o,message:s,type:c,...l}=x(n.errors,e)||{};w(n.errors,e,{...l,...t,ref:a}),N.state.next({name:e,errors:n.errors,isValid:!1}),i&&i.shouldFocus&&a&&a.focus&&a.focus()},ze=(e,t)=>C(e)?N.state.subscribe({next:n=>`values`in n&&e(Y(void 0,t),n)}):Y(e,t,!0),Be=e=>N.state.subscribe({next:t=>{De(e.name,t.name,e.exact)&&Ee(t,e.formState||j,Qe,e.reRenderRoot)&&e.callback({values:{...a},...n,...t,defaultValues:i})}}).unsubscribe,Ve=e=>(l.mount=!0,M={...M,...e.formState},Be({...e,formState:{...A,...e.formState}})),He=(e,o={})=>{for(let s of e?B(e):m.mount)m.mount.delete(s),m.array.delete(s),o.keepValue||(U(r,s),U(a,s)),!o.keepError&&U(n.errors,s),!o.keepDirty&&U(n.dirtyFields,s),!o.keepTouched&&U(n.touchedFields,s),!o.keepIsValidating&&U(n.validatingFields,s),!t.shouldUnregister&&!o.keepDefaultValue&&U(i,s);N.state.next({values:g(a)}),N.state.next({...n,...o.keepDirty?{isDirty:J()}:{}}),!o.keepIsValid&&R()},Ue=({disabled:e,name:t})=>{if(S(e)&&l.mount||e||m.disabled.has(t)){let n=m.disabled.has(t)!==!!e;e?m.disabled.add(t):m.disabled.delete(t),n&&l.mount&&!l.action&&R()}},We=(e,n={})=>{let a=x(r,e),o=S(n.disabled)||S(t.disabled);return w(r,e,{...a||{},_f:{...a&&a._f?a._f:{ref:{name:e}},name:e,mount:!0,...n}}),m.mount.add(e),a?Ue({disabled:S(n.disabled)?n.disabled:t.disabled,name:e}):H(e,!0,n.value),{...o?{disabled:n.disabled||t.disabled}:{},...t.progressive?{required:!!n.required,min:Z(n.min),max:Z(n.max),minLength:Z(n.minLength),maxLength:Z(n.maxLength),pattern:Z(n.pattern)}:{},name:e,onChange:$,onBlur:$,ref:o=>{if(o){We(e,n),a=x(r,e);let t=v(o.value)&&o.querySelectorAll&&o.querySelectorAll(`input,select,textarea`)[0]||o,s=le(t),c=a._f.refs||[];if(s?c.find(e=>e===t):t===a._f.ref)return;w(r,e,{_f:{...a._f,...s?{refs:[...c.filter(ue),t,...Array.isArray(x(i,e))?[{}]:[]],ref:{type:t.type,name:e}}:{ref:t}}}),H(e,!1,void 0,t)}else a=x(r,e,{}),a._f&&(a._f.mount=!1),(t.shouldUnregister||n.shouldUnregister)&&!(p(m.array,e)&&l.action)&&m.unMount.add(e)}}},Ge=()=>t.shouldFocusError&&we(r,Ne,m.mount),Ke=e=>{S(e)&&(N.state.next({disabled:e}),we(r,(t,n)=>{let i=x(r,n);i&&(t.disabled=i._f.disabled||e,Array.isArray(i._f.refs)&&i._f.refs.forEach(t=>{t.disabled=i._f.disabled||e}))},0,!1))},qe=(e,i)=>async o=>{let s;o&&(o.preventDefault&&o.preventDefault(),o.persist&&o.persist());let c=g(a);if(N.state.next({isSubmitting:!0}),t.resolver){let{errors:e,values:t}=await W();z(),n.errors=e,c=g(t)}else await q({fields:r,eventType:T.SUBMIT});if(m.disabled.size)for(let e of m.disabled)U(c,e);if(U(n.errors,k),V(n.errors)){N.state.next({errors:{}});try{await e(c,o)}catch(e){s=e}}else i&&await i({...n.errors},o),Ge(),setTimeout(Ge);if(N.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:V(n.errors)&&!s,submitCount:n.submitCount+1,errors:n.errors}),s)throw s},Je=(e,t={})=>{x(r,e)&&(v(t.defaultValue)?Q(e,g(x(i,e))):(Q(e,t.defaultValue),w(i,e,g(t.defaultValue))),t.keepTouched||U(n.touchedFields,e),t.keepDirty||(U(n.dirtyFields,e),n.isDirty=t.defaultValue?J(e,g(x(i,e))):J()),t.keepError||(U(n.errors,e),j.isValid&&R()),N.state.next({...n}))},Ye=(e,o={})=>{let s=e?g(e):i,c=g(s),u=V(e),d=u?i:c;if(o.keepDefaultValues||(i=s),!o.keepValues){if(o.keepDirtyValues){let e=new Set([...m.mount,...Object.keys(K(i,a))]);for(let t of Array.from(e)){let e=x(n.dirtyFields,t),r=x(a,t),i=x(d,t);e&&!v(r)?w(d,t,r):!e&&!v(i)&&Q(t,i)}}else{if(h&&v(e))for(let e of m.mount){let t=x(r,e);if(t&&t._f){let e=Array.isArray(t._f.refs)?t._f.refs[0]:t._f.ref;if(se(e)){let t=e.closest(`form`);if(t){t.reset();break}}}}if(o.keepFieldsRef)for(let e of m.mount)Q(e,x(d,e));else r={}}a=t.shouldUnregister?o.keepDefaultValues?g(i):{}:g(d),N.array.next({values:{...d}}),N.state.next({values:{...d}})}m={mount:o.keepDirtyValues?m.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:``},l.mount=!j.isValid||!!o.keepIsValid||!!o.keepDirtyValues||!t.shouldUnregister&&!V(d),l.watch=!!t.shouldUnregister,l.keepIsValid=!!o.keepIsValid,l.action=!1,o.keepErrors||(n.errors={}),N.state.next({submitCount:o.keepSubmitCount?n.submitCount:0,isDirty:u?!1:o.keepDirty?n.isDirty:!!(o.keepDefaultValues&&!L(e,i)),isSubmitted:o.keepIsSubmitted?n.isSubmitted:!1,dirtyFields:u?{}:o.keepDirtyValues?o.keepDefaultValues&&a?K(i,a):n.dirtyFields:o.keepDefaultValues&&e?K(i,e):o.keepDirty?n.dirtyFields:{},touchedFields:o.keepTouched?n.touchedFields:{},errors:o.keepErrors?n.errors:{},isSubmitSuccessful:o.keepIsSubmitSuccessful?n.isSubmitSuccessful:!1,isSubmitting:!1,defaultValues:i})},Xe=(e,n)=>Ye(C(e)?e(a):e,{...t.resetOptions,...n}),Ze=(e,t={})=>{let n=x(r,e),i=n&&n._f;if(i){let e=i.refs?i.refs[0]:i.ref;e.focus&&setTimeout(()=>{e.focus(),t.shouldSelect&&C(e.select)&&e.select()})}},Qe=e=>{n={...n,...e}},$e={control:{register:We,unregister:He,getFieldState:Ie,handleSubmit:qe,setError:Re,_subscribe:Be,_runSchema:W,_updateIsValidating:z,_focusError:Ge,_getWatch:Y,_getDirty:J,_setValid:R,_setFieldArray:te,_setDisabledField:Ue,_setErrors:re,_getFieldArray:ge,_reset:Ye,_resetDefaultValues:()=>C(t.defaultValues)&&t.defaultValues().then(e=>{Xe(e,t.resetOptions),N.state.next({isLoading:!1})}),_removeUnmounted:me,_disableForm:Ke,_subjects:N,_proxyFormState:j,get _fields(){return r},get _formValues(){return a},get _state(){return l},set _state(e){l=e},get _defaultValues(){return i},get _names(){return m},set _names(e){m=e},get _formState(){return n},get _options(){return t},set _options(e){t={...t,...e}}},subscribe:Ve,trigger:Pe,register:We,handleSubmit:qe,watch:ze,setValue:Q,getValues:Fe,reset:Xe,resetField:Je,clearErrors:Le,unregister:He,setError:Re,setFocus:Ze,getFieldState:Ie};return{...$e,formControl:$e}}function Pe(e={}){let t=a.useRef(void 0),n=a.useRef(void 0),[r,i]=a.useState({isDirty:!1,isValidating:!1,isLoading:C(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:C(e.defaultValues)?void 0:e.defaultValues});if(!t.current)if(e.formControl)t.current={...e.formControl,formState:r},e.defaultValues&&!C(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{let{formControl:n,...i}=Ne(e);t.current={...i,formState:r}}let o=t.current.control;return o._options=e,N(()=>{let e=o._subscribe({formState:o._proxyFormState,callback:()=>i({...o._formState}),reRenderRoot:!0});return i(e=>({...e,isReady:!0})),o._formState.isReady=!0,e},[o]),a.useEffect(()=>o._disableForm(e.disabled),[o,e.disabled]),a.useEffect(()=>{e.mode&&(o._options.mode=e.mode),e.reValidateMode&&(o._options.reValidateMode=e.reValidateMode)},[o,e.mode,e.reValidateMode]),a.useEffect(()=>{e.errors&&(o._setErrors(e.errors),o._focusError())},[o,e.errors]),a.useEffect(()=>{e.shouldUnregister&&o._subjects.state.next({values:o._getWatch()})},[o,e.shouldUnregister]),a.useEffect(()=>{if(o._proxyFormState.isDirty){let e=o._getDirty();e!==r.isDirty&&o._subjects.state.next({isDirty:e})}},[o,r.isDirty]),a.useEffect(()=>{e.values&&!L(e.values,n.current)?(o._reset(e.values,{keepFieldsRef:!0,...o._options.resetOptions}),o._options.resetOptions?.keepIsValid||o._setValid(),n.current=e.values,i(e=>({...e}))):o._resetDefaultValues()},[o,e.values]),a.useEffect(()=>{o._state.mount||(o._setValid(),o._state.mount=!0),o._state.watch&&(o._state.watch=!1,o._subjects.state.next({...o._formState})),o._removeUnmounted()}),t.current.formState=a.useMemo(()=>M(r,o),[o,r]),t.current}var Fe=(e,t,n)=>{if(e&&`reportValidity`in e){let r=x(n,t);e.setCustomValidity(r&&r.message||``),e.reportValidity()}},Ie=(e,t)=>{for(let n in t.fields){let r=t.fields[n];r&&r.ref&&`reportValidity`in r.ref?Fe(r.ref,n,e):r&&r.refs&&r.refs.forEach(t=>Fe(t,n,e))}},Le=(e,t)=>{t.shouldUseNativeValidation&&Ie(e,t);let n={};for(let r in e){let i=x(t.fields,r),a=Object.assign(e[r]||{},{ref:i&&i.ref});if(Re(t.names||Object.keys(e),r)){let e=Object.assign({},x(n,r));w(e,`root`,a),w(n,r,e)}else w(n,r,a)}return n},Re=(e,t)=>{let n=ze(t);return e.some(e=>ze(e).match(`^${n}\\.\\d+`))};function ze(e){return e.replace(/\]|\[/g,``)}function Be(e,t){try{var n=e()}catch(e){return t(e)}return n&&n.then?n.then(void 0,t):n}function Ve(e,t){for(var n={};e.length;){var r=e[0],i=r.code,a=r.message,o=r.path.join(`.`);if(!n[o])if(`unionErrors`in r){var s=r.unionErrors[0].errors[0];n[o]={message:s.message,type:s.code}}else n[o]={message:a,type:i};if(`unionErrors`in r&&r.unionErrors.forEach(function(t){return t.errors.forEach(function(t){return e.push(t)})}),t){var c=n[o].types,l=c&&c[r.code];n[o]=re(o,t,n,i,l?[].concat(l,r.message):r.message)}e.shift()}return n}function He(e,t){for(var n={};e.length;){var r=e[0],i=r.code,a=r.message,o=r.path.join(`.`);if(!n[o])if(r.code===`invalid_union`&&r.errors.length>0){var s=r.errors[0][0];n[o]={message:s.message,type:s.code}}else n[o]={message:a,type:i};if(r.code===`invalid_union`&&r.errors.forEach(function(t){return t.forEach(function(t){return e.push(t)})}),t){var c=n[o].types,l=c&&c[r.code];n[o]=re(o,t,n,i,l?[].concat(l,r.message):r.message)}e.shift()}return n}function Ue(e,t,a){if(a===void 0&&(a={}),function(e){return`_def`in e&&typeof e._def==`object`&&`typeName`in e._def}(e))return function(n,r,i){try{return Promise.resolve(Be(function(){return Promise.resolve(e[a.mode===`sync`?`parse`:`parseAsync`](n,t)).then(function(e){return i.shouldUseNativeValidation&&Ie({},i),{errors:{},values:a.raw?Object.assign({},n):e}})},function(e){if(function(e){return Array.isArray(e?.issues)}(e))return{values:{},errors:Le(Ve(e.errors,!i.shouldUseNativeValidation&&i.criteriaMode===`all`),i)};throw e}))}catch(e){return Promise.reject(e)}};if(function(e){return`_zod`in e&&typeof e._zod==`object`}(e))return function(o,s,c){try{return Promise.resolve(Be(function(){return Promise.resolve((a.mode===`sync`?i:n)(e,o,t)).then(function(e){return c.shouldUseNativeValidation&&Ie({},c),{errors:{},values:a.raw?Object.assign({},o):e}})},function(e){if(function(e){return e instanceof r}(e))return{values:{},errors:Le(He(e.issues,!c.shouldUseNativeValidation&&c.criteriaMode===`all`),c)};throw e}))}catch(e){return Promise.reject(e)}};throw Error(`Invalid input: not a Zod schema`)}export{te as n,Pe as r,Ue as t}; \ No newline at end of file +import{a as e,r as t}from"./compiler-runtime.js";import{M as n,N as r,j as i}from"./SignatureV4.js";var a=e(t(),1),o=e=>e.type===`checkbox`,s=e=>e instanceof Date,c=e=>e==null,l=e=>typeof e==`object`,u=e=>!c(e)&&!Array.isArray(e)&&l(e)&&!s(e),d=e=>u(e)&&e.target?o(e.target)?e.target.checked:e.target.value:e,f=(e,t)=>t.split(`.`).some((t,n,r)=>!isNaN(Number(t))&&e.has(r.slice(0,n).join(`.`))),p=e=>{let t=e.constructor&&e.constructor.prototype;return u(t)&&t.hasOwnProperty(`isPrototypeOf`)},m=typeof window<`u`&&window.HTMLElement!==void 0&&typeof document<`u`;function h(e){if(e instanceof Date)return new Date(e);let t=typeof FileList<`u`&&e instanceof FileList;if(m&&(e instanceof Blob||t))return e;let n=Array.isArray(e);if(!n&&!(u(e)&&p(e)))return e;let r=n?[]:Object.create(Object.getPrototypeOf(e));for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(r[t]=h(e[t]));return r}var g=e=>/^\w*$/.test(e),_=e=>e===void 0,v=e=>Array.isArray(e)?e.filter(Boolean):[],y=e=>v(e.replace(/["|']|\]/g,``).split(/\.|\[/)),b=(e,t,n)=>{if(!t||!u(e))return n;let r=(g(t)?[t]:y(t)).reduce((e,t)=>c(e)?e:e[t],e);return _(r)||r===e?_(e[t])?n:e[t]:r},x=e=>typeof e==`boolean`,S=e=>typeof e==`function`,C=(e,t,n)=>{let r=-1,i=g(t)?[t]:y(t),a=i.length,o=a-1;for(;++ra.useContext(k),j=(e,t,n,r=!0)=>{let i={defaultValues:t._defaultValues};for(let a in e)Object.defineProperty(i,a,{get:()=>{let i=a;return t._proxyFormState[i]!==T.all&&(t._proxyFormState[i]=!r||T.all),n&&(n[i]=!0),e[i]}});return i},M=typeof window<`u`?a.useLayoutEffect:a.useEffect;function N(e){let t=A(),{control:n=t,disabled:r,name:i,exact:o}=e||{},[s,c]=a.useState(n._formState),l=a.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1});return M(()=>n._subscribe({name:i,formState:l.current,exact:o,callback:e=>{!r&&c({...n._formState,...e})}}),[i,r,o]),a.useEffect(()=>{l.current.isValid&&n._setValid(!0)},[n]),a.useMemo(()=>j(s,n,l.current,!1),[s,n])}var P=e=>typeof e==`string`,F=(e,t,n,r,i)=>P(e)?(r&&t.watch.add(e),b(n,e,i)):Array.isArray(e)?e.map(e=>(r&&t.watch.add(e),b(n,e))):(r&&(t.watchAll=!0),n),I=e=>c(e)||!l(e);function L(e,t,n=new WeakSet){if(I(e)||I(t))return Object.is(e,t);if(s(e)&&s(t))return Object.is(e.getTime(),t.getTime());let r=Object.keys(e),i=Object.keys(t);if(r.length!==i.length)return!1;if(n.has(e)||n.has(t))return!0;n.add(e),n.add(t);for(let a of r){let r=e[a];if(!i.includes(a))return!1;if(a!==`ref`){let e=t[a];if(s(r)&&s(e)||(u(r)||Array.isArray(r))&&(u(e)||Array.isArray(e))?!L(r,e,n):!Object.is(r,e))return!1}}return!0}function R(e){let t=A(),{control:n=t,name:r,defaultValue:i,disabled:o,exact:s,compute:c}=e||{},l=a.useRef(i),u=a.useRef(c),d=a.useRef(void 0),f=a.useRef(n),p=a.useRef(r);u.current=c;let[m,h]=a.useState(()=>{let e=n._getWatch(r,l.current);return u.current?u.current(e):e}),g=a.useCallback(e=>{let t=F(r,n._names,e||n._formValues,!1,l.current);return u.current?u.current(t):t},[n._formValues,n._names,r]),_=a.useCallback(e=>{if(!o){let t=F(r,n._names,e||n._formValues,!1,l.current);if(u.current){let e=u.current(t);L(e,d.current)||(h(e),d.current=e)}else h(t)}},[n._formValues,n._names,o,r]);M(()=>((f.current!==n||!L(p.current,r))&&(f.current=n,p.current=r,_()),n._subscribe({name:r,formState:{values:!0},exact:s,callback:e=>{_(e.values)}})),[n,s,r,_]),a.useEffect(()=>n._removeUnmounted());let v=f.current!==n,y=p.current,b=a.useMemo(()=>{if(o)return null;let e=!v&&!L(y,r);return v||e?g():null},[o,v,r,y,g]);return b===null?m:b}function z(e){let t=A(),{name:n,disabled:r,control:i=t,shouldUnregister:o,defaultValue:s,exact:c=!0}=e,l=f(i._names.array,n),u=R({control:i,name:n,defaultValue:a.useMemo(()=>b(i._formValues,n,b(i._defaultValues,n,s)),[i,n,s]),exact:c}),p=N({control:i,name:n,exact:c}),m=a.useRef(e),g=a.useRef(void 0),v=a.useRef(i.register(n,{...e.rules,value:u,...x(e.disabled)?{disabled:e.disabled}:{}}));m.current=e;let y=a.useMemo(()=>Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!b(p.errors,n)},isDirty:{enumerable:!0,get:()=>!!b(p.dirtyFields,n)},isTouched:{enumerable:!0,get:()=>!!b(p.touchedFields,n)},isValidating:{enumerable:!0,get:()=>!!b(p.validatingFields,n)},error:{enumerable:!0,get:()=>b(p.errors,n)}}),[p,n]),T=a.useCallback(e=>v.current.onChange({target:{value:d(e),name:n},type:w.CHANGE}),[n]),E=a.useCallback(()=>v.current.onBlur({target:{value:b(i._formValues,n),name:n},type:w.BLUR}),[n,i._formValues]),D=a.useCallback(e=>{let t=b(i._fields,n);t&&t._f&&e&&(t._f.ref={focus:()=>S(e.focus)&&e.focus(),select:()=>S(e.select)&&e.select(),setCustomValidity:t=>S(e.setCustomValidity)&&e.setCustomValidity(t),reportValidity:()=>S(e.reportValidity)&&e.reportValidity()})},[i._fields,n]),O=a.useMemo(()=>({name:n,value:u,...x(r)||p.disabled?{disabled:p.disabled||r}:{},onChange:T,onBlur:E,ref:D}),[n,r,p.disabled,T,E,D,u]);return a.useEffect(()=>{let e=i._options.shouldUnregister||o,t=g.current;t&&t!==n&&!l&&i.unregister(t),i.register(n,{...m.current.rules,...x(m.current.disabled)?{disabled:m.current.disabled}:{}});let r=(e,t)=>{let n=b(i._fields,e);n&&n._f&&(n._f.mount=t)};if(r(n,!0),e){let e=h(b(i._options.defaultValues,n,m.current.defaultValue));C(i._defaultValues,n,e),_(b(i._formValues,n))&&C(i._formValues,n,e)}return!l&&i.register(n),g.current=n,()=>{(l?e&&!i._state.action:e)?i.unregister(n):r(n,!1)}},[n,i,l,o]),a.useEffect(()=>{i._setDisabledField({disabled:r,name:n})},[r,n,i]),a.useMemo(()=>({field:O,formState:p,fieldState:y}),[O,p,y])}var ee=e=>e.render(z(e)),te=a.createContext(null);te.displayName=`HookFormContext`;var ne=(e,t,n,r,i)=>t?{...n[e],types:{...n[e]&&n[e].types?n[e].types:{},[r]:i||!0}}:{},B=e=>Array.isArray(e)?e:[e],re=()=>{let e=[];return{get observers(){return e},next:t=>{for(let n of e)n.next&&n.next(t)},subscribe:t=>(e.push(t),{unsubscribe:()=>{e=e.filter(e=>e!==t)}}),unsubscribe:()=>{e=[]}}};function ie(e,t){let n={};for(let r in e)if(e.hasOwnProperty(r)){let i=e[r],a=t[r];if(i&&u(i)&&a){let e=ie(i,a);u(e)&&(n[r]=e)}else e[r]&&(n[r]=a)}return n}var V=e=>u(e)&&!Object.keys(e).length,ae=e=>e.type===`file`,oe=e=>{if(!m)return!1;let t=e?e.ownerDocument:0;return e instanceof(t&&t.defaultView?t.defaultView.HTMLElement:HTMLElement)},se=e=>e.type===`select-multiple`,ce=e=>e.type===`radio`,le=e=>ce(e)||o(e),ue=e=>oe(e)&&e.isConnected;function de(e,t){let n=t.slice(0,-1).length,r=0;for(;r{for(let t in e)if(S(e[t]))return!0;return!1};function U(e){return Array.isArray(e)||u(e)&&!pe(e)}function me(e,t={}){for(let n in e){let r=e[n];U(r)?(t[n]=Array.isArray(r)?[]:{},me(r,t[n])):_(r)||(t[n]=!0)}return t}function W(e,t,n){n||=me(t);for(let r in e){let i=e[r];if(U(i))_(t)||I(n[r])?n[r]=me(i,Array.isArray(i)?[]:{}):W(i,c(t)?{}:t[r],n[r]);else{let e=t[r];n[r]=!L(i,e)}}return n}var he={value:!1,isValid:!1},G={value:!0,isValid:!0},ge=e=>{if(Array.isArray(e)){if(e.length>1){let t=e.filter(e=>e&&e.checked&&!e.disabled).map(e=>e.value);return{value:t,isValid:!!t.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!_(e[0].attributes.value)?_(e[0].value)||e[0].value===``?G:{value:e[0].value,isValid:!0}:G:he}return he},_e=(e,{valueAsNumber:t,valueAsDate:n,setValueAs:r})=>_(e)?e:t?e===``?NaN:e&&+e:n&&P(e)?new Date(e):r?r(e):e,K={isValid:!1,value:null},q=e=>Array.isArray(e)?e.reduce((e,t)=>t&&t.checked&&!t.disabled?{isValid:!0,value:t.value}:e,K):K;function ve(e){let t=e.ref;return ae(t)?t.files:ce(t)?q(e.refs).value:se(t)?[...t.selectedOptions].map(({value:e})=>e):o(t)?ge(e.refs).value:_e(_(t.value)?e.ref.value:t.value,e)}var ye=e=>e.substring(0,e.search(/\.\d+(\.|$)/))||e,be=(e,t,n,r)=>{let i={};for(let n of e){let e=b(t,n);e&&C(i,n,e._f)}return{criteriaMode:n,names:[...e],fields:i,shouldUseNativeValidation:r}},J=e=>e instanceof RegExp,Y=e=>_(e)?e:J(e)?e.source:u(e)?J(e.value)?e.value.source:e.value:e,xe=e=>({isOnSubmit:!e||e===T.onSubmit,isOnBlur:e===T.onBlur,isOnChange:e===T.onChange,isOnAll:e===T.all,isOnTouch:e===T.onTouched}),X=`AsyncFunction`,Se=e=>!!e&&!!e.validate&&!!(S(e.validate)&&e.validate.constructor.name===X||u(e.validate)&&Object.values(e.validate).find(e=>e.constructor.name===X)),Ce=e=>e.mount&&(e.required||e.min||e.max||e.maxLength||e.minLength||e.pattern||e.validate),we=(e,t,n)=>!n&&(t.watchAll||t.watch.has(e)||[...t.watch].some(t=>e.startsWith(t)&&/^\.\w+/.test(e.slice(t.length)))),Z=(e,t,n,r)=>{for(let i of n||Object.keys(e)){let n=b(e,i);if(n){let{_f:e,...a}=n;if(e){if(e.refs&&e.refs[0]&&t(e.refs[0],i)&&!r||e.ref&&t(e.ref,e.name)&&!r)return!0;if(Z(a,t))break}else if(u(a)&&Z(a,t))break}}};function Te(e,t,n){let r=b(e,n);if(r||g(n))return{error:r,name:n};let i=n.split(`.`);for(;i.length;){let r=i.join(`.`),a=b(t,r),o=b(e,r);if(a&&!Array.isArray(a)&&n!==r)return{name:n};if(o&&o.type)return{name:r,error:o};if(o&&o.root&&o.root.type)return{name:`${r}.root`,error:o.root};i.pop()}return{name:n}}var Ee=(e,t,n,r)=>{n(e);let{name:i,...a}=e;return V(a)||Object.keys(a).length>=Object.keys(t).length||Object.keys(a).find(e=>t[e]===(!r||T.all))},De=(e,t,n)=>!e||!t||e===t||B(e).some(e=>e&&(n?e===t:e.startsWith(t)||t.startsWith(e))),Oe=(e,t,n,r,i)=>i.isOnAll?!1:!n&&i.isOnTouch?!(t||e):(n?r.isOnBlur:i.isOnBlur)?!e:(n?r.isOnChange:i.isOnChange)?e:!0,ke=(e,t)=>!v(b(e,t)).length&&H(e,t),Ae=(e,t,n)=>{let r=B(b(e,n));return C(r,O,t[n]),C(e,n,r),e};function je(e,t,n=`validate`){if(P(e)||Array.isArray(e)&&e.every(P)||x(e)&&!e)return{type:n,message:P(e)?e:``,ref:t}}var Q=e=>u(e)&&!J(e)?e:{value:e,message:``},Me=async(e,t,n,r,i,a)=>{let{ref:s,refs:l,required:d,maxLength:f,minLength:p,min:m,max:h,pattern:g,validate:v,name:y,valueAsNumber:C,mount:w}=e._f,T=b(n,y);if(!w||t.has(y))return{};let D=l?l[0]:s,O=e=>{i&&D.reportValidity&&(D.setCustomValidity(x(e)?``:e||``),D.reportValidity())},k={},A=ce(s),j=o(s),M=A||j,N=(C||ae(s))&&_(s.value)&&_(T)||oe(s)&&s.value===``||T===``||Array.isArray(T)&&!T.length,F=ne.bind(null,y,r,k),I=(e,t,n,r=E.maxLength,i=E.minLength)=>{let a=e?t:n;k[y]={type:e?r:i,message:a,ref:s,...F(e?r:i,a)}};if(a?!Array.isArray(T)||!T.length:d&&(!M&&(N||c(T))||x(T)&&!T||j&&!ge(l).isValid||A&&!q(l).isValid)){let{value:e,message:t}=P(d)?{value:!!d,message:d}:Q(d);if(e&&(k[y]={type:E.required,message:t,ref:D,...F(E.required,t)},!r))return O(t),k}if(!N&&(!c(m)||!c(h))){let e,t,n=Q(h),i=Q(m);if(!c(T)&&!isNaN(T)){let r=s.valueAsNumber||T&&+T;c(n.value)||(e=r>n.value),c(i.value)||(t=rnew Date(new Date().toDateString()+` `+e),o=s.type==`time`,c=s.type==`week`;P(n.value)&&T&&(e=o?a(T)>a(n.value):c?T>n.value:r>new Date(n.value)),P(i.value)&&T&&(t=o?a(T)+e.value,i=!c(t.value)&&T.length<+t.value;if((n||i)&&(I(n,e.message,t.message),!r))return O(k[y].message),k}if(g&&!N&&P(T)){let{value:e,message:t}=Q(g);if(J(e)&&!T.match(e)&&(k[y]={type:E.pattern,message:t,ref:s,...F(E.pattern,t)},!r))return O(t),k}if(v){if(S(v)){let e=je(await v(T,n),D);if(e&&(k[y]={...e,...F(E.validate,e.message)},!r))return O(e.message),k}else if(u(v)){let e={};for(let t in v){if(!V(e)&&!r)break;let i=je(await v[t](T,n),D,t);i&&(e={...i,...F(t,i.message)},O(i.message),r&&(k[y]=e))}if(!V(e)&&(k[y]={ref:D,...e},!r))return k}}return O(!0),k},Ne={mode:T.onSubmit,reValidateMode:T.onChange,shouldFocusError:!0};function Pe(e={}){let t={...Ne,...e},n={submitCount:0,isDirty:!1,isReady:!1,isLoading:S(t.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1},r={},i=(u(t.defaultValues)||u(t.values))&&h(t.defaultValues||t.values)||{},a=t.shouldUnregister?{}:h(i),l={action:!1,mount:!1,watch:!1,keepIsValid:!1},p={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set,registerName:new Set},g,y=0,k={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},A={...k},j={...A},M={array:re(),state:re()},N=t.criteriaMode===T.all,I=e=>t=>{clearTimeout(y),y=setTimeout(e,t)},R=async e=>{if(!l.keepIsValid&&!t.disabled&&(A.isValid||j.isValid||e)){let e;t.resolver?(e=V((await U()).errors),z()):e=await G({fields:r,onlyCheckValid:!0,eventType:w.VALID}),e!==n.isValid&&M.state.next({isValid:e})}},z=(e,r)=>{!t.disabled&&(A.isValidating||A.validatingFields||j.isValidating||j.validatingFields)&&((e||Array.from(p.mount)).forEach(e=>{e&&(r?C(n.validatingFields,e,r):H(n.validatingFields,e))}),M.state.next({validatingFields:n.validatingFields,isValidating:!V(n.validatingFields)}))},ee=e=>{let t=W(i,a),r=ye(e);C(n.dirtyFields,r,b(t,r))},te=(e,i=[],o,s,c=!0,u=!0)=>{if(s&&o&&!t.disabled){if(l.action=!0,u&&Array.isArray(b(r,e))){let t=o(b(r,e),s.argA,s.argB);c&&C(r,e,t)}if(u&&Array.isArray(b(n.errors,e))){let t=o(b(n.errors,e),s.argA,s.argB);c&&C(n.errors,e,t),ke(n.errors,e)}if((A.touchedFields||j.touchedFields)&&u&&Array.isArray(b(n.touchedFields,e))){let t=o(b(n.touchedFields,e),s.argA,s.argB);c&&C(n.touchedFields,e,t)}(A.dirtyFields||j.dirtyFields)&&ee(e),M.state.next({name:e,isDirty:K(e,i),dirtyFields:n.dirtyFields,errors:n.errors,isValid:n.isValid})}else C(a,e,i)},ne=(e,t)=>{C(n.errors,e,t),M.state.next({errors:n.errors})},ce=e=>{n.errors=e,M.state.next({errors:n.errors,isValid:!1})},de=(e,t,n,o)=>{let s=b(r,e);if(s){let r=b(a,e,_(n)?b(i,e):n);_(r)||o&&o.defaultChecked||t?C(a,e,t?r:ve(s._f)):X(e,r),l.mount&&!l.action&&R()}},fe=(e,r,a,o,s)=>{let c=!1,l=!1,u={name:e};if(!t.disabled){if(!a||o){(A.isDirty||j.isDirty)&&(l=n.isDirty,n.isDirty=u.isDirty=K(),c=l!==u.isDirty);let t=L(b(i,e),r);l=!!b(n.dirtyFields,e),t?H(n.dirtyFields,e):C(n.dirtyFields,e,!0),u.dirtyFields=n.dirtyFields,c||=(A.dirtyFields||j.dirtyFields)&&l!==!t}if(a){let t=b(n.touchedFields,e);t||(C(n.touchedFields,e,a),u.touchedFields=n.touchedFields,c||=(A.touchedFields||j.touchedFields)&&t!==a)}c&&s&&M.state.next(u)}return c?u:{}},pe=(e,r,i,a)=>{let o=b(n.errors,e),s=(A.isValid||j.isValid)&&x(r)&&n.isValid!==r;if(t.delayError&&i?(g=I(()=>ne(e,i)),g(t.delayError)):(clearTimeout(y),g=null,i?C(n.errors,e,i):H(n.errors,e)),(i?!L(o,i):o)||!V(a)||s){let t={...a,...s&&x(r)?{isValid:r}:{},errors:n.errors,name:e};n={...n,...t},M.state.next(t)}},U=async e=>(z(e,!0),await t.resolver(a,t.context,be(e||p.mount,r,t.criteriaMode,t.shouldUseNativeValidation))),me=async e=>{let{errors:t}=await U(e);if(z(e),e)for(let r of e){let e=b(t,r);e?C(n.errors,r,e):H(n.errors,r)}else n.errors=t;return t},he=async({name:t,eventType:r})=>{if(e.validate){let i=await e.validate({formValues:a,formState:n,name:t,eventType:r});if(u(i))for(let e in i)i[e]&&$(`${D}.${e}`,{message:P(i.message)?i.message:``,type:E.validate});else P(i)||!i?$(D,{message:i||``,type:E.validate}):ze(D);return i}return!0},G=async({fields:r,onlyCheckValid:i,name:o,eventType:s,context:c={valid:!0,runRootValidation:!1}})=>{if(e.validate&&(c.runRootValidation=!0,!await he({name:o,eventType:s})&&(c.valid=!1,i)))return c.valid;for(let o in r){let l=r[o];if(l){let{_f:r,...u}=l;if(r){let o=p.array.has(r.name),s=l._f&&Se(l._f);s&&A.validatingFields&&z([r.name],!0);let u=await Me(l,p.disabled,a,N,t.shouldUseNativeValidation&&!i,o);if(s&&A.validatingFields&&z([r.name]),u[r.name]&&(c.valid=!1,i)||(!i&&(b(u,r.name)?o?Ae(n.errors,u,r.name):C(n.errors,r.name,u[r.name]):H(n.errors,r.name)),e.shouldUseNativeValidation&&u[r.name]))break}!V(u)&&await G({context:c,onlyCheckValid:i,fields:u,name:o,eventType:s})}}return c.valid},ge=()=>{for(let e of p.unMount){let t=b(r,e);t&&(t._f.refs?t._f.refs.every(e=>!ue(e)):!ue(t._f.ref))&&Ue(e)}p.unMount=new Set},K=(e,n)=>!t.disabled&&(e&&n&&C(a,e,n),!L(Le(),i)),q=(e,t,n)=>F(e,p,{...l.mount?a:_(t)?i:P(e)?{[e]:t}:t},n,t),J=e=>v(b(l.mount?a:i,e,t.shouldUnregister?b(i,e,[]):[])),X=(e,t,n={})=>{let i=b(r,e),s=t;if(i){let n=i._f;n&&(!n.disabled&&C(a,e,_e(t,n)),s=oe(n.ref)&&c(t)?``:t,se(n.ref)?[...n.ref.options].forEach(e=>e.selected=s.includes(e.value)):n.refs?o(n.ref)?n.refs.forEach(e=>{(!e.defaultChecked||!e.disabled)&&(Array.isArray(s)?e.checked=!!s.find(t=>t===e.value):e.checked=s===e.value||!!s)}):n.refs.forEach(e=>e.checked=e.value===s):ae(n.ref)?n.ref.value=``:(n.ref.value=s,n.ref.type||M.state.next({name:e,values:h(a)})))}(n.shouldDirty||n.shouldTouch)&&fe(e,s,n.shouldTouch,n.shouldDirty,!0),n.shouldValidate&&Ie(e)},je=(e,t,n)=>{for(let i in t){if(!t.hasOwnProperty(i))return;let a=t[i],o=e+`.`+i,c=b(r,o);(p.array.has(e)||u(a)||c&&!c._f)&&!s(a)?je(o,a,n):X(o,a,n)}},Q=(e,t,i={})=>{let o=b(r,e),s=p.array.has(e),u=h(t);C(a,e,u),s?(M.array.next({name:e,values:h(a)}),(A.isDirty||A.dirtyFields||j.isDirty||j.dirtyFields)&&i.shouldDirty&&(ee(e),M.state.next({name:e,dirtyFields:n.dirtyFields,isDirty:K(e,u)}))):o&&!o._f&&!c(u)?je(e,u,i):X(e,u,i),we(e,p)?M.state.next({...n,name:e,values:h(a)}):M.state.next({name:l.mount?e:void 0,values:h(a)})},Pe=async i=>{l.mount=!0;let o=i.target,c=o.name,u=!0,f=b(r,c),m=e=>{u=Number.isNaN(e)||s(e)&&isNaN(e.getTime())||L(e,b(a,c,e))},_=xe(t.mode),v=xe(t.reValidateMode);if(f){let s,l,y=o.type?ve(f._f):d(i),x=i.type===w.BLUR||i.type===w.FOCUS_OUT,S=!Ce(f._f)&&!e.validate&&!t.resolver&&!b(n.errors,c)&&!f._f.deps||Oe(x,b(n.touchedFields,c),n.isSubmitted,v,_),T=we(c,p,x);C(a,c,y),x?(!o||!o.readOnly)&&(f._f.onBlur&&f._f.onBlur(i),g&&g(0)):f._f.onChange&&f._f.onChange(i);let E=fe(c,y,x),D=!V(E)||T;if(!x&&M.state.next({name:c,type:i.type,values:h(a)}),S)return(A.isValid||j.isValid)&&(t.mode===`onBlur`?x&&R():x||R()),D&&M.state.next({name:c,...T?{}:E});if(!t.resolver&&e.validate&&await he({name:c,eventType:i.type}),!x&&T&&M.state.next({...n}),t.resolver){let{errors:e}=await U([c]);if(z([c]),m(y),u){let t=Te(n.errors,r,c),i=Te(e,r,t.name||c);s=i.error,c=i.name,l=V(e)}}else z([c],!0),s=(await Me(f,p.disabled,a,N,t.shouldUseNativeValidation))[c],z([c]),m(y),u&&(s?l=!1:(A.isValid||j.isValid)&&(l=await G({fields:r,onlyCheckValid:!0,name:c,eventType:i.type})));u&&(f._f.deps&&(!Array.isArray(f._f.deps)||f._f.deps.length>0)&&Ie(f._f.deps),pe(c,l,s,E))}},Fe=(e,t)=>{if(b(n.errors,t)&&e.focus)return e.focus(),1},Ie=async(e,i={})=>{let a,o,s=B(e);if(t.resolver){let t=await me(_(e)?e:s);a=V(t),o=e?!s.some(e=>b(t,e)):a}else e?(o=(await Promise.all(s.map(async e=>{let t=b(r,e);return await G({fields:t&&t._f?{[e]:t}:t,eventType:w.TRIGGER})}))).every(Boolean),!(!o&&!n.isValid)&&R()):o=a=await G({fields:r,name:e,eventType:w.TRIGGER});return M.state.next({...!P(e)||(A.isValid||j.isValid)&&a!==n.isValid?{}:{name:e},...t.resolver||!e?{isValid:a}:{},errors:n.errors}),i.shouldFocus&&!o&&Z(r,Fe,e?s:p.mount),o},Le=(e,t)=>{let r={...l.mount?a:i};return t&&(r=ie(t.dirtyFields?n.dirtyFields:n.touchedFields,r)),_(e)?r:P(e)?b(r,e):e.map(e=>b(r,e))},Re=(e,t)=>({invalid:!!b((t||n).errors,e),isDirty:!!b((t||n).dirtyFields,e),error:b((t||n).errors,e),isValidating:!!b(n.validatingFields,e),isTouched:!!b((t||n).touchedFields,e)}),ze=e=>{let t=e?B(e):void 0;t?.forEach(e=>H(n.errors,e)),t?t.forEach(e=>{M.state.next({name:e,errors:n.errors})}):M.state.next({errors:{}})},$=(e,t,i)=>{let a=(b(r,e,{_f:{}})._f||{}).ref,{ref:o,message:s,type:c,...l}=b(n.errors,e)||{};C(n.errors,e,{...l,...t,ref:a}),M.state.next({name:e,errors:n.errors,isValid:!1}),i&&i.shouldFocus&&a&&a.focus&&a.focus()},Be=(e,t)=>S(e)?M.state.subscribe({next:n=>`values`in n&&e(q(void 0,t),n)}):q(e,t,!0),Ve=e=>M.state.subscribe({next:t=>{De(e.name,t.name,e.exact)&&Ee(t,e.formState||A,$e,e.reRenderRoot)&&e.callback({values:{...a},...n,...t,defaultValues:i})}}).unsubscribe,He=e=>(l.mount=!0,j={...j,...e.formState},Ve({...e,formState:{...k,...e.formState}})),Ue=(e,o={})=>{for(let s of e?B(e):p.mount)p.mount.delete(s),p.array.delete(s),o.keepValue||(H(r,s),H(a,s)),!o.keepError&&H(n.errors,s),!o.keepDirty&&H(n.dirtyFields,s),!o.keepTouched&&H(n.touchedFields,s),!o.keepIsValidating&&H(n.validatingFields,s),!t.shouldUnregister&&!o.keepDefaultValue&&H(i,s);M.state.next({values:h(a)}),M.state.next({...n,...o.keepDirty?{isDirty:K()}:{}}),!o.keepIsValid&&R()},We=({disabled:e,name:t})=>{if(x(e)&&l.mount||e||p.disabled.has(t)){let n=p.disabled.has(t)!==!!e;e?p.disabled.add(t):p.disabled.delete(t),n&&l.mount&&!l.action&&R()}},Ge=(e,n={})=>{let a=b(r,e),o=x(n.disabled)||x(t.disabled),s=!p.registerName.has(e)&&a&&!a._f.mount;return C(r,e,{...a||{},_f:{...a&&a._f?a._f:{ref:{name:e}},name:e,mount:!0,...n}}),p.mount.add(e),a&&!s?We({disabled:x(n.disabled)?n.disabled:t.disabled,name:e}):de(e,!0,n.value),{...o?{disabled:n.disabled||t.disabled}:{},...t.progressive?{required:!!n.required,min:Y(n.min),max:Y(n.max),minLength:Y(n.minLength),maxLength:Y(n.maxLength),pattern:Y(n.pattern)}:{},name:e,onChange:Pe,onBlur:Pe,ref:o=>{if(o){p.registerName.add(e),Ge(e,n),p.registerName.delete(e),a=b(r,e);let t=_(o.value)&&o.querySelectorAll&&o.querySelectorAll(`input,select,textarea`)[0]||o,s=le(t),c=a._f.refs||[];if(s?c.find(e=>e===t):t===a._f.ref)return;C(r,e,{_f:{...a._f,...s?{refs:[...c.filter(ue),t,...Array.isArray(b(i,e))?[{}]:[]],ref:{type:t.type,name:e}}:{ref:t}}}),de(e,!1,void 0,t)}else a=b(r,e,{}),a._f&&(a._f.mount=!1),(t.shouldUnregister||n.shouldUnregister)&&!(f(p.array,e)&&l.action)&&p.unMount.add(e)}}},Ke=()=>t.shouldFocusError&&Z(r,Fe,p.mount),qe=e=>{x(e)&&(M.state.next({disabled:e}),Z(r,(t,n)=>{let i=b(r,n);i&&(t.disabled=i._f.disabled||e,Array.isArray(i._f.refs)&&i._f.refs.forEach(t=>{t.disabled=i._f.disabled||e}))},0,!1))},Je=(e,i)=>async o=>{let s;o&&(o.preventDefault&&o.preventDefault(),o.persist&&o.persist());let c=h(a);if(M.state.next({isSubmitting:!0}),t.resolver){let{errors:e,values:t}=await U();z(),n.errors=e,c=h(t)}else await G({fields:r,eventType:w.SUBMIT});if(p.disabled.size)for(let e of p.disabled)H(c,e);if(H(n.errors,O),V(n.errors)){M.state.next({errors:{}});try{await e(c,o)}catch(e){s=e}}else i&&await i({...n.errors},o),Ke(),setTimeout(Ke);if(M.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:V(n.errors)&&!s,submitCount:n.submitCount+1,errors:n.errors}),s)throw s},Ye=(e,t={})=>{b(r,e)&&(_(t.defaultValue)?Q(e,h(b(i,e))):(Q(e,t.defaultValue),C(i,e,h(t.defaultValue))),t.keepTouched||H(n.touchedFields,e),t.keepDirty||(H(n.dirtyFields,e),n.isDirty=t.defaultValue?K(e,h(b(i,e))):K()),t.keepError||(H(n.errors,e),A.isValid&&R()),M.state.next({...n}))},Xe=(e,o={})=>{let s=e?h(e):i,c=h(s),u=V(e),d=u?i:c;if(o.keepDefaultValues||(i=s),!o.keepValues){if(o.keepDirtyValues){let e=new Set([...p.mount,...Object.keys(W(i,a))]);for(let t of Array.from(e)){let e=b(n.dirtyFields,t),r=b(a,t),i=b(d,t);e&&!_(r)?C(d,t,r):!e&&!_(i)&&Q(t,i)}}else{if(m&&_(e))for(let e of p.mount){let t=b(r,e);if(t&&t._f){let e=Array.isArray(t._f.refs)?t._f.refs[0]:t._f.ref;if(oe(e)){let t=e.closest(`form`);if(t){t.reset();break}}}}if(o.keepFieldsRef)for(let e of p.mount)Q(e,b(d,e));else r={}}a=t.shouldUnregister?o.keepDefaultValues?h(i):{}:h(d),M.array.next({values:{...d}}),M.state.next({values:{...d}})}p={mount:o.keepDirtyValues?p.mount:new Set,unMount:new Set,array:new Set,registerName:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:``},l.mount=!A.isValid||!!o.keepIsValid||!!o.keepDirtyValues||!t.shouldUnregister&&!V(d),l.watch=!!t.shouldUnregister,l.keepIsValid=!!o.keepIsValid,l.action=!1,o.keepErrors||(n.errors={}),M.state.next({submitCount:o.keepSubmitCount?n.submitCount:0,isDirty:u?!1:o.keepDirty?n.isDirty:!!(o.keepDefaultValues&&!L(e,i)),isSubmitted:o.keepIsSubmitted?n.isSubmitted:!1,dirtyFields:u?{}:o.keepDirtyValues?o.keepDefaultValues&&a?W(i,a):n.dirtyFields:o.keepDefaultValues&&e?W(i,e):o.keepDirty?n.dirtyFields:{},touchedFields:o.keepTouched?n.touchedFields:{},errors:o.keepErrors?n.errors:{},isSubmitSuccessful:o.keepIsSubmitSuccessful?n.isSubmitSuccessful:!1,isSubmitting:!1,defaultValues:i})},Ze=(e,n)=>Xe(S(e)?e(a):e,{...t.resetOptions,...n}),Qe=(e,t={})=>{let n=b(r,e),i=n&&n._f;if(i){let e=i.refs?i.refs[0]:i.ref;e.focus&&setTimeout(()=>{e.focus(),t.shouldSelect&&S(e.select)&&e.select()})}},$e=e=>{n={...n,...e}},et={control:{register:Ge,unregister:Ue,getFieldState:Re,handleSubmit:Je,setError:$,_subscribe:Ve,_runSchema:U,_updateIsValidating:z,_focusError:Ke,_getWatch:q,_getDirty:K,_setValid:R,_setFieldArray:te,_setDisabledField:We,_setErrors:ce,_getFieldArray:J,_reset:Xe,_resetDefaultValues:()=>S(t.defaultValues)&&t.defaultValues().then(e=>{Ze(e,t.resetOptions),M.state.next({isLoading:!1})}),_removeUnmounted:ge,_disableForm:qe,_subjects:M,_proxyFormState:A,get _fields(){return r},get _formValues(){return a},get _state(){return l},set _state(e){l=e},get _defaultValues(){return i},get _names(){return p},set _names(e){p=e},get _formState(){return n},get _options(){return t},set _options(e){t={...t,...e}}},subscribe:He,trigger:Ie,register:Ge,handleSubmit:Je,watch:Be,setValue:Q,getValues:Le,reset:Ze,resetField:Ye,clearErrors:ze,unregister:Ue,setError:$,setFocus:Qe,getFieldState:Re};return{...et,formControl:et}}function Fe(e={}){let t=a.useRef(void 0),n=a.useRef(void 0),[r,i]=a.useState({isDirty:!1,isValidating:!1,isLoading:S(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:S(e.defaultValues)?void 0:e.defaultValues});if(!t.current)if(e.formControl)t.current={...e.formControl,formState:r},e.defaultValues&&!S(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{let{formControl:n,...i}=Pe(e);t.current={...i,formState:r}}let o=t.current.control;return o._options=e,M(()=>{let e=o._subscribe({formState:o._proxyFormState,callback:()=>i({...o._formState}),reRenderRoot:!0});return i(e=>({...e,isReady:!0})),o._formState.isReady=!0,e},[o]),a.useEffect(()=>o._disableForm(e.disabled),[o,e.disabled]),a.useEffect(()=>{e.mode&&(o._options.mode=e.mode),e.reValidateMode&&(o._options.reValidateMode=e.reValidateMode)},[o,e.mode,e.reValidateMode]),a.useEffect(()=>{e.errors&&(o._setErrors(e.errors),o._focusError())},[o,e.errors]),a.useEffect(()=>{e.shouldUnregister&&o._subjects.state.next({values:o._getWatch()})},[o,e.shouldUnregister]),a.useEffect(()=>{if(o._proxyFormState.isDirty){let e=o._getDirty();e!==r.isDirty&&o._subjects.state.next({isDirty:e})}},[o,r.isDirty]),a.useEffect(()=>{e.values&&!L(e.values,n.current)?(o._reset(e.values,{keepFieldsRef:!0,...o._options.resetOptions}),o._options.resetOptions?.keepIsValid||o._setValid(),n.current=e.values,i(e=>({...e}))):o._resetDefaultValues()},[o,e.values]),a.useEffect(()=>{o._state.mount||(o._setValid(),o._state.mount=!0),o._state.watch&&(o._state.watch=!1,o._subjects.state.next({...o._formState})),o._removeUnmounted()}),t.current.formState=a.useMemo(()=>j(r,o),[o,r]),t.current}var Ie=(e,t,n)=>{if(e&&`reportValidity`in e){let r=b(n,t);e.setCustomValidity(r&&r.message||``),e.reportValidity()}},Le=(e,t)=>{for(let n in t.fields){let r=t.fields[n];r&&r.ref&&`reportValidity`in r.ref?Ie(r.ref,n,e):r&&r.refs&&r.refs.forEach(t=>Ie(t,n,e))}},Re=(e,t)=>{t.shouldUseNativeValidation&&Le(e,t);let n={};for(let r in e){let i=b(t.fields,r),a=Object.assign(e[r]||{},{ref:i&&i.ref});if(ze(t.names||Object.keys(e),r)){let e=Object.assign({},b(n,r));C(e,`root`,a),C(n,r,e)}else C(n,r,a)}return n},ze=(e,t)=>{let n=$(t);return e.some(e=>$(e).match(`^${n}\\.\\d+`))};function $(e){return e.replace(/\]|\[/g,``)}function Be(e,t){try{var n=e()}catch(e){return t(e)}return n&&n.then?n.then(void 0,t):n}function Ve(e,t){for(var n={};e.length;){var r=e[0],i=r.code,a=r.message,o=r.path.join(`.`);if(!n[o])if(`unionErrors`in r){var s=r.unionErrors[0].errors[0];n[o]={message:s.message,type:s.code}}else n[o]={message:a,type:i};if(`unionErrors`in r&&r.unionErrors.forEach(function(t){return t.errors.forEach(function(t){return e.push(t)})}),t){var c=n[o].types,l=c&&c[r.code];n[o]=ne(o,t,n,i,l?[].concat(l,r.message):r.message)}e.shift()}return n}function He(e,t){for(var n={};e.length;){var r=e[0],i=r.code,a=r.message,o=r.path.join(`.`);if(!n[o])if(r.code===`invalid_union`&&r.errors.length>0){var s=r.errors[0][0];n[o]={message:s.message,type:s.code}}else n[o]={message:a,type:i};if(r.code===`invalid_union`&&r.errors.forEach(function(t){return t.forEach(function(t){return e.push(t)})}),t){var c=n[o].types,l=c&&c[r.code];n[o]=ne(o,t,n,i,l?[].concat(l,r.message):r.message)}e.shift()}return n}function Ue(e,t,a){if(a===void 0&&(a={}),function(e){return`_def`in e&&typeof e._def==`object`&&`typeName`in e._def}(e))return function(n,r,i){try{return Promise.resolve(Be(function(){return Promise.resolve(e[a.mode===`sync`?`parse`:`parseAsync`](n,t)).then(function(e){return i.shouldUseNativeValidation&&Le({},i),{errors:{},values:a.raw?Object.assign({},n):e}})},function(e){if(function(e){return Array.isArray(e?.issues)}(e))return{values:{},errors:Re(Ve(e.errors,!i.shouldUseNativeValidation&&i.criteriaMode===`all`),i)};throw e}))}catch(e){return Promise.reject(e)}};if(function(e){return`_zod`in e&&typeof e._zod==`object`}(e))return function(o,s,c){try{return Promise.resolve(Be(function(){return Promise.resolve((a.mode===`sync`?i:n)(e,o,t)).then(function(e){return c.shouldUseNativeValidation&&Le({},c),{errors:{},values:a.raw?Object.assign({},o):e}})},function(e){if(function(e){return e instanceof r}(e))return{values:{},errors:Re(He(e.issues,!c.shouldUseNativeValidation&&c.criteriaMode===`all`),c)};throw e}))}catch(e){return Promise.reject(e)}};throw Error(`Invalid input: not a Zod schema`)}export{ee as n,Fe as r,Ue as t}; \ No newline at end of file diff --git a/spinifex/services/spinifexui/frontend/dist/index.html b/spinifex/services/spinifexui/frontend/dist/index.html index f66173f3e..a9c7b4a1b 100644 --- a/spinifex/services/spinifexui/frontend/dist/index.html +++ b/spinifex/services/spinifexui/frontend/dist/index.html @@ -26,7 +26,6 @@ - diff --git a/spinifex/services/spinifexui/frontend/src/lib/awsClient.ts b/spinifex/services/spinifexui/frontend/src/lib/awsClient.ts index 2ec1a1c1d..af009fd51 100644 --- a/spinifex/services/spinifexui/frontend/src/lib/awsClient.ts +++ b/spinifex/services/spinifexui/frontend/src/lib/awsClient.ts @@ -1,12 +1,17 @@ import { EC2Client } from "@aws-sdk/client-ec2" import { IAMClient } from "@aws-sdk/client-iam" import { S3Client } from "@aws-sdk/client-s3" +import { HttpRequest } from "@smithy/protocol-http" import { getCredentials } from "./auth" const AWS_REGION = "ap-southeast-2" -const awsEndpoint = `${window.location.protocol}//${window.location.hostname}:9999` -const s3Endpoint = `${window.location.protocol}//${window.location.hostname}:8443` + +// SDK signs against the real backend host so the SigV4 signature includes +// the correct Host header value. Middleware rewrites the outgoing URL +// to route through the same-origin reverse proxy after signing is complete. +const AWSGW_SIGN_ENDPOINT = `${window.location.protocol}//localhost:9999` +const S3_SIGN_ENDPOINT = `${window.location.protocol}//localhost:8443` // Cached singleton clients let ec2Client: EC2Client | null = null @@ -20,13 +25,24 @@ export function getEc2Client(): EC2Client { throw new Error("AWS credentials not configured") } ec2Client = new EC2Client({ - endpoint: awsEndpoint, + endpoint: AWSGW_SIGN_ENDPOINT, region: AWS_REGION, credentials: { accessKeyId: credentials.accessKeyId, secretAccessKey: credentials.secretAccessKey, }, }) + ec2Client.middlewareStack.add( + (next) => (args) => { + if (HttpRequest.isInstance(args.request)) { + args.request.hostname = window.location.hostname + args.request.port = Number(window.location.port) || 443 + args.request.path = `/proxy/awsgw${args.request.path}` + } + return next(args) + }, + { step: "finalizeRequest", name: "proxyRewrite", override: true }, + ) } return ec2Client } @@ -38,13 +54,24 @@ export function getIamClient(): IAMClient { throw new Error("AWS credentials not configured") } iamClient = new IAMClient({ - endpoint: awsEndpoint, + endpoint: AWSGW_SIGN_ENDPOINT, region: AWS_REGION, credentials: { accessKeyId: credentials.accessKeyId, secretAccessKey: credentials.secretAccessKey, }, }) + iamClient.middlewareStack.add( + (next) => (args) => { + if (HttpRequest.isInstance(args.request)) { + args.request.hostname = window.location.hostname + args.request.port = Number(window.location.port) || 443 + args.request.path = `/proxy/awsgw${args.request.path}` + } + return next(args) + }, + { step: "finalizeRequest", name: "proxyRewrite", override: true }, + ) } return iamClient } @@ -56,7 +83,7 @@ export function getS3Client(): S3Client { throw new Error("AWS credentials not configured") } s3Client = new S3Client({ - endpoint: s3Endpoint, + endpoint: S3_SIGN_ENDPOINT, region: AWS_REGION, credentials: { accessKeyId: credentials.accessKeyId, @@ -67,21 +94,30 @@ export function getS3Client(): S3Client { // Remove trailing slashes from request paths to fix compatibility with // path-style S3 endpoints where a trailing slash causes the request to // be interpreted as GetObject instead of ListObjects - s3Client.middlewareStack.use({ - applyToStack: (stack) => { - stack.add( - (next) => (args) => { - // oxlint-disable-next-line typescript/no-unsafe-type-assertion -- smithy middleware args.request is typed as unknown - const request = (args as { request?: { path?: string } }).request - if (request?.path?.endsWith("/") && request.path !== "/") { - request.path = request.path.slice(0, -1) - } - return next(args) - }, - { step: "build", name: "removeTrailingSlash" }, - ) + s3Client.middlewareStack.add( + (next) => (args) => { + if ( + HttpRequest.isInstance(args.request) && + args.request.path.endsWith("/") && + args.request.path !== "/" + ) { + args.request.path = args.request.path.slice(0, -1) + } + return next(args) }, - }) + { step: "build", name: "removeTrailingSlash" }, + ) + s3Client.middlewareStack.add( + (next) => (args) => { + if (HttpRequest.isInstance(args.request)) { + args.request.hostname = window.location.hostname + args.request.port = Number(window.location.port) || 443 + args.request.path = `/proxy/s3${args.request.path}` + } + return next(args) + }, + { step: "finalizeRequest", name: "proxyRewrite", override: true }, + ) } return s3Client } diff --git a/spinifex/services/spinifexui/frontend/src/lib/signed-fetch.ts b/spinifex/services/spinifexui/frontend/src/lib/signed-fetch.ts index 0304a5283..663b423be 100644 --- a/spinifex/services/spinifexui/frontend/src/lib/signed-fetch.ts +++ b/spinifex/services/spinifexui/frontend/src/lib/signed-fetch.ts @@ -18,19 +18,19 @@ export async function signedFetch({ credentials, service = "spinifex", }: SignedFetchOptions): Promise { - const hostname = window.location.hostname - const port = GATEWAY_PORT const protocol = window.location.protocol.replace(":", "") const body = `Action=${action}` + // Sign the request against the real backend (localhost:9999) so the + // gateway's SigV4 verification sees the host value it expects. const request = new HttpRequest({ method: "POST", protocol, - hostname, - port, + hostname: "localhost", + port: GATEWAY_PORT, path: "/", headers: { - host: `${hostname}:${port}`, + host: `localhost:${GATEWAY_PORT}`, "content-type": "application/x-www-form-urlencoded", }, body, @@ -55,15 +55,20 @@ export async function signedFetch({ } } - const url = `${protocol}://${hostname}:${port}/` - const response = await fetch(url, { + // Send the request through the same-origin reverse proxy instead of + // directly to the gateway, eliminating cross-origin requests. + const proxyUrl = `${window.location.protocol}//${window.location.host}/proxy/awsgw/` + const response = await fetch(proxyUrl, { method: "POST", headers, body, }) if (!response.ok) { - throw new Error(`${action} failed: ${response.status}`) + const detail = await response.text().catch(() => "") + throw new Error( + `${action} failed: ${response.status}${detail ? ` - ${detail}` : ""}`, + ) } // oxlint-disable-next-line typescript/no-unsafe-type-assertion -- response.json() returns Promise diff --git a/spinifex/services/spinifexui/frontend/src/mutations/s3.test.tsx b/spinifex/services/spinifexui/frontend/src/mutations/s3.test.tsx index 3aec4b8af..516b2c5fb 100644 --- a/spinifex/services/spinifexui/frontend/src/mutations/s3.test.tsx +++ b/spinifex/services/spinifexui/frontend/src/mutations/s3.test.tsx @@ -11,7 +11,7 @@ vi.mock("@/lib/awsClient", () => ({ vi.mock("@aws-sdk/lib-storage", () => ({ Upload: class MockUpload { - private key: string + private readonly key: string constructor({ params }: { params: { Key: string } }) { this.key = params.Key } diff --git a/spinifex/services/spinifexui/frontend/src/routes/_auth/ec2/-components/private-key-modal.tsx b/spinifex/services/spinifexui/frontend/src/routes/_auth/ec2/-components/private-key-modal.tsx index 1c190ae1a..56cd68b33 100644 --- a/spinifex/services/spinifexui/frontend/src/routes/_auth/ec2/-components/private-key-modal.tsx +++ b/spinifex/services/spinifexui/frontend/src/routes/_auth/ec2/-components/private-key-modal.tsx @@ -12,7 +12,6 @@ import { AlertDialogTitle, } from "@/components/ui/alert-dialog" import { Button } from "@/components/ui/button" -import { Textarea } from "@/components/ui/textarea" import { useCopyToClipboard } from "@/hooks/use-copy-to-clipboard" interface PrivateKeyModalProps { @@ -59,10 +58,10 @@ export function PrivateKeyModal({
-