diff --git a/.audit/grokbot-0755-build.todo.md b/.audit/grokbot-0755-build.todo.md new file mode 100644 index 00000000..112e2c79 --- /dev/null +++ b/.audit/grokbot-0755-build.todo.md @@ -0,0 +1,9 @@ +# Grok Bot 0.75.5 build migration + +- [x] Migrate feature-extraction inputs from the obsolete 0.72.1 snapshot to the pinned 0.75.5 REA snapshot. +- [x] Regenerate Vault parser and renderer artifacts from 0.75.5 bytes; keep runtime-compatible 0721 output names. +- [x] Update 0.75.5 native pins, tests, and provenance expectations. +- [x] Run typechecks, focused tests, full build, packaging, and live Vault session acceptance. + - [x] Extract the shipped Simplified Chinese Vault catalog and title-bar create menu. + - [x] Verify the final QA bundle can open the Vault settings surface. +- [x] Commit the reviewable units, synchronize with GitHub, and push the branch. diff --git a/frontend/src/extensions/port-0750-packaged-hosts.tsx b/frontend/src/extensions/port-0750-packaged-hosts.tsx index 05a4cb14..b5063e63 100644 --- a/frontend/src/extensions/port-0750-packaged-hosts.tsx +++ b/frontend/src/extensions/port-0750-packaged-hosts.tsx @@ -1,9 +1,6 @@ import { useEffect, useState, type ReactNode } from "react"; -import { createCoordinatorClient } from "../production/coordinator-client"; -import type { CoordinatorPortBridge, DesktopBridge, EffectivePlugin } from "../recovered/contracts/desktop-bridge"; +import type { DesktopBridge, EffectivePlugin } from "../recovered/contracts/desktop-bridge"; import { PluginsPort0750Extras } from "../recovered/features/plugins/overlay/port-0750-extras"; -import { MemoryImportHost } from "../recovered/features/settings/overlay/memory-import-host"; -import { VaultCardDialogHost } from "./vault-card-dialog-host"; function desktopBridge(): Pick | null { const desktop = (window as Window & { desktop?: Pick }).desktop; @@ -11,22 +8,14 @@ function desktopBridge(): Pick | return desktop; } -function coordinatorFromWindow() { - const port = (window as Window & { coordinatorPort?: CoordinatorPortBridge }).coordinatorPort; - if (port == null || typeof port.claim !== "function") return null; - return createCoordinatorClient(port); -} - +/** + * Settings → 通用 no longer mounts anything. The memory-import card that lived here was the + * English 0.75 stopgap; the real import flow is its own Settings tab (memory-import entry), + * and the vault "New card" trigger was a development entry. Both showed up at the bottom of + * 通用. The export stays because the pinned settings chunk references it. + */ export function RPort0750SettingsPack(): ReactNode { - const [coordinator] = useState(coordinatorFromWindow); - const bridge = desktopBridge(); - if (bridge == null) return null; - return ( - <> - - - - ); + return null; } export function RPort0750PluginsPack(): ReactNode { diff --git a/frontend/src/extensions/vault-host-mount.tsx b/frontend/src/extensions/vault-host-mount.tsx index a91fa16c..7c6deed5 100644 --- a/frontend/src/extensions/vault-host-mount.tsx +++ b/frontend/src/extensions/vault-host-mount.tsx @@ -1,10 +1,12 @@ -import { useEffect, useMemo } from "react"; +import { useEffect, useMemo, useState } from "react"; import { createUpstreamVaultStore, createUpstreamVaultLinguiProvider, + createUpstreamVaultPaneHeaderProvider, default as UpstreamVaultSettings, } from "../recovered/features/vault/upstream-vault-settings.generated.mjs"; import { upstreamVaultMessages, type VaultCatalogEntry } from "../recovered/features/vault/upstream-vault-messages.generated.mjs"; +import { upstreamVaultMessages0755 } from "../recovered/features/vault/upstream-vault-messages-0755.mjs"; import type { VaultDesktop, VaultCredential } from "../recovered/features/vault/types"; import type { UpstreamVaultStore } from "../recovered/features/vault/upstream-vault-settings.generated.mjs"; @@ -17,6 +19,7 @@ type WindowWithVault = Window & { readonly desktop: VaultDesktop; readonly experiments: { readonly snapshots: { get(): unknown; subscribe(listener: () => void): () => void } }; readonly auth: { readonly snapshots: { get(): unknown; subscribe(listener: () => void): () => void } }; + readonly theme: { readonly snapshots: { get(): unknown; subscribe(listener: () => void): () => void } }; }; }; @@ -53,9 +56,39 @@ export function vaultDesktopFromWindow(candidate: Window | undefined = window): async function validateCredentialList(value: Awaited>): Promise { if (!Array.isArray(value)) throw new Error("Vault list returned a non-array value"); + if (!value.every(isVaultCredential)) throw new Error("Vault list returned an invalid item"); return value; } +function isString(value: unknown): value is string { + return typeof value === "string"; +} + +function isVaultAddress(value: unknown): boolean { + return isRecord(value) && ["line1", "line2", "city", "region", "postalCode", "country"].every((key) => isString(value[key])); +} + +function isVaultCredential(value: unknown): value is VaultCredential { + if (!isRecord(value)) return false; + if (!["id", "title", "username", "notes"].every((key) => isString(value[key])) + || !Array.isArray(value.sites) || !value.sites.every(isString) + || typeof value.createdAtMs !== "number" || typeof value.updatedAtMs !== "number") return false; + if (value.card !== undefined) { + const card = value.card; + if (!isRecord(card) + || !["brand", "last4", "holderName", "nickname", "billingAddressId"].every((key) => isString(card[key])) + || typeof card.expMonth !== "number" || typeof card.expYear !== "number" + || !isVaultAddress(card.billingAddress)) return false; + } + if (value.contact !== undefined) { + const contact = value.contact; + if (!isRecord(contact) + || !["name", "line1", "line2", "city", "region", "postalCode", "country", "phone", "email"].every((key) => isString(contact[key])) + || typeof contact.defaultShipping !== "boolean") return false; + } + return true; +} + function constantStore(value: T): { get(): T; subscribe(listener: () => void): () => void } { return { get: () => value, subscribe: () => () => undefined }; } @@ -103,7 +136,12 @@ const vaultI18n = { : idOrDescriptor; const merged = values ?? descriptor.values; const id = descriptor.id ?? ""; - const catalogEntry = id.length > 0 ? upstreamVaultMessages[vaultLocale][id] : undefined; + const catalogEntry = id.length > 0 + ? upstreamVaultMessages0755[vaultLocale][id] + ?? upstreamVaultMessages[vaultLocale]?.[id] + ?? upstreamVaultMessages0755.en[id] + ?? upstreamVaultMessages.en[id] + : undefined; if (catalogEntry !== undefined) { const rendered = renderCatalogEntry(catalogEntry, merged); if (rendered !== null) return rendered; @@ -121,8 +159,12 @@ const vaultI18n = { const UpstreamVaultLinguiProvider = createUpstreamVaultLinguiProvider as unknown as (props: { readonly i18n: unknown; readonly children?: React.ReactNode }) => React.ReactNode; +const UpstreamVaultPaneHeaderProvider = createUpstreamVaultPaneHeaderProvider as unknown as + (props: { readonly value: HTMLElement | null; readonly children?: React.ReactNode }) => React.ReactNode; + export function RVaultSettingsHost(props: { readonly focusSetting?: string | null }) { const desktop = useMemo(() => vaultDesktopFromWindow(), []); + const [paneActions, setPaneActions] = useState(null); const client = useMemo(() => { const list = async (): Promise => validateCredentialList(await desktop.listGrokBotVaultCredentials()); const healingDesktop = { ...desktop, heal: () => undefined, listGrokBotVaultCredentials: list }; @@ -136,6 +178,7 @@ export function RVaultSettingsHost(props: { readonly focusSetting?: string | nul }, alert: { alert: () => undefined }, auth: { snapshots: constantStore({ status: { kind: "logged-in" } }) }, + theme: { snapshots: constantStore({ resolved: "light" }) }, }; (globalThis as typeof globalThis & { __sandVault0721Client?: typeof value }).__sandVault0721Client = value; (window as WindowWithVault).__sandVault0721Client = value; @@ -147,11 +190,26 @@ export function RVaultSettingsHost(props: { readonly focusSetting?: string | nul return () => client.grokBotVault.dispose(); }, [client]); + useEffect(() => { + const header = document.querySelector("header.sand-settings-pane-header"); + if (header === null) return; + const target = document.createElement("div"); + target.setAttribute("data-sand-vault-actions", ""); + target.style.marginInlineStart = "auto"; + target.style.marginInlineEnd = "44px"; + header.insertBefore(target, header.lastElementChild); + setPaneActions(target); + return () => target.remove(); + }, []); + return ( -
- - - +
+
+ + + + +
); } diff --git a/frontend/src/recovered/contracts/desktop-bridge.ts b/frontend/src/recovered/contracts/desktop-bridge.ts index b11fc8de..48c15603 100644 --- a/frontend/src/recovered/contracts/desktop-bridge.ts +++ b/frontend/src/recovered/contracts/desktop-bridge.ts @@ -52,6 +52,12 @@ export type DesktopUpdateState = | { type: "staging"; version: string } | { type: "ready"; version: string; lastCheck?: { at: number; result: "up-to-date" | "error"; errorMessage?: string } }; +export interface DesktopGitHubReleaseInfo { + version: string; + releaseUrl: string; + downloadUrl: string; +} + export interface DesktopUpdateStatus { state: DesktopUpdateState; currentVersion: string; @@ -63,6 +69,9 @@ export interface DesktopUpdateStatus { isBelowMinimumVersion: boolean; autoUpdateWhenIdleOptIn: boolean; autoUpdateWhenIdleGateEnabled: boolean; + /** Reconstructed GitHub Releases feed metadata (absent until a check resolves an offer). */ + releasesUrl?: string; + githubRelease?: DesktopGitHubReleaseInfo | null; } export interface DesktopAutoReviewInstructions { diff --git a/frontend/src/recovered/features/settings/overlay/desktop-surface.tsx b/frontend/src/recovered/features/settings/overlay/desktop-surface.tsx index 212544ae..a8704e6f 100644 --- a/frontend/src/recovered/features/settings/overlay/desktop-surface.tsx +++ b/frontend/src/recovered/features/settings/overlay/desktop-surface.tsx @@ -293,7 +293,6 @@ export function SettingsDesktopSurface({ bridge, coordinatorClient = null, initi }), status: snapshot.egressTunnel.status }} - computer={computer} status={snapshot.update} /> ); diff --git a/frontend/src/recovered/features/settings/overlay/panels.tsx b/frontend/src/recovered/features/settings/overlay/panels.tsx index 21b131ea..d4667be7 100644 --- a/frontend/src/recovered/features/settings/overlay/panels.tsx +++ b/frontend/src/recovered/features/settings/overlay/panels.tsx @@ -3,10 +3,8 @@ import { useIntl } from "react-intl"; import type { CursorUsageSummary, CursorUsageUpgradeAction, DesktopTimeZoneState, LanguagePreference } from "../../../contracts/desktop-bridge"; import { egressTunnelStatusDescription, type EgressTunnelStatus, type UpdateStatus, type UpdateTrack } from "./updates"; // @evidence src/app/dist/renderer/assets/index-BlqerJhg.js#L1 -import { INTERNAL_RELEASE_TRACK_CONFIG_URL, UPDATE_TRACK_LABELS, updateStatusMessage } from "./updates"; +import { GITHUB_RELEASES_URL, INTERNAL_RELEASE_TRACK_CONFIG_URL, UPDATE_TRACK_LABELS, updateStatusMessage } from "./updates"; import { AutoReviewRulesPanel, type AutoReviewSettings } from "./auto-review"; -import { SettingsComputerPanel } from "./computer-view"; -import type { SettingsComputerMount } from "./computer"; import { useAsyncAction } from "../../../runtime/async-action"; import { SandButton } from "../../../ui/sand-kit-primitives"; import { SandSelect } from "../../../ui/sand-floating-primitives"; @@ -523,7 +521,6 @@ export interface UpdatesSettingsPanelProps { onInstall?(): void | Promise; onSetTrack(track: UpdateTrack): void | Promise; onSetAutoUpdateWhenIdle(enabled: boolean): void | Promise; - computer?: SettingsComputerMount; egressTunnel?: { available: boolean; enabled: boolean; @@ -541,7 +538,6 @@ export function UpdatesSettingsPanel({ onInstall, onSetTrack, onSetAutoUpdateWhenIdle, - computer, egressTunnel }: UpdatesSettingsPanelProps) { const [checkPending, setCheckPending] = useState(false); @@ -572,7 +568,6 @@ export function UpdatesSettingsPanel({ enabled={egressTunnel.enabled} onChange={egressTunnel.onChange} /> : null} - {computer ? : null}
); } @@ -619,9 +614,18 @@ export function UpdatesSettingsPanel({ )}
{message.text} + {/* Reconstructed GitHub Releases fallback: Squirrel.Mac auto-apply needs a Developer ID + signature, so ad-hoc builds may stage yet fail to install. The Releases link is the + reliable manual path and stays visible in every state. */} +
+ {status.githubRelease?.version != null && (status.state.type === "available" || status.state.type === "downloading" || status.state.type === "staging" || status.state.type === "ready") ? ( + Grok Bot {status.githubRelease.version} is available on GitHub Releases (download this version). If auto-install fails, download the zip manually. + ) : ( + Prefer manual updates? View/download on GitHub Releases + )} +
{egressVisible ? : null} - {computer ? : null} ); } diff --git a/frontend/src/recovered/features/settings/overlay/port-0750-extras.tsx b/frontend/src/recovered/features/settings/overlay/port-0750-extras.tsx index 15de2bd1..f2a1c682 100644 --- a/frontend/src/recovered/features/settings/overlay/port-0750-extras.tsx +++ b/frontend/src/recovered/features/settings/overlay/port-0750-extras.tsx @@ -1,19 +1,11 @@ import type { ReactNode } from "react"; import { TeamsOnboardingHost } from "../../../../extensions/teams-integration-onboarding"; -import { VaultCardDialogHost } from "../../../../extensions/vault-card-dialog-host"; import type { DesktopBridge } from "../../../contracts/desktop-bridge"; import type { ProductionCoordinatorClient } from "../../../../production/coordinator-client"; -import { MemoryImportHost } from "./memory-import-host"; -export function Port0750SettingsExtras(props: { +export function Port0750SettingsExtras(_props: { readonly bridge: Pick; readonly coordinator: Pick | null; }): ReactNode { - return ( - <> - - - - - ); + return ; } diff --git a/frontend/src/recovered/features/settings/overlay/updates.ts b/frontend/src/recovered/features/settings/overlay/updates.ts index 00c5d347..3b6156d6 100644 --- a/frontend/src/recovered/features/settings/overlay/updates.ts +++ b/frontend/src/recovered/features/settings/overlay/updates.ts @@ -14,6 +14,14 @@ export const UPDATE_TRACK_LABELS: Readonly> = { export const INTERNAL_RELEASE_TRACK_CONFIG_URL = "https://console.statsig.com/5oWaLs1Xr8U2ei9Hq2R45w/dynamic_configs/sand_internal_release_track_override"; +/** + * Reconstructed-build update feed: this repo's GitHub Releases. Hardcoded (not + * from the update status) so the Settings panel can always offer a manual + * download fallback, even before the first check resolves or when Squirrel.Mac + * staging cannot auto-apply an ad-hoc signature. + */ +export const GITHUB_RELEASES_URL = "https://github.com/tyonger-stack/GrokNode/releases"; + export type DisabledUpdateReason = | "not-packaged" | "lab-build" @@ -33,10 +41,18 @@ export type UpdateState = | { type: "ready"; version: string; lastCheck?: LastUpdateCheck | null } | { type: "idle"; lastCheck?: LastUpdateCheck | null }; +export interface GitHubReleaseInfo { + version: string; + releaseUrl: string; + downloadUrl: string; +} + export interface UpdateStatus { state: UpdateState; currentTrack: UpdateTrack; currentVersion: string; + releasesUrl?: string; + githubRelease?: GitHubReleaseInfo | null; isTrackManagedByPolicy?: boolean; autoUpdateWhenIdleOptIn?: boolean; autoUpdateWhenIdleGateEnabled?: boolean; diff --git a/frontend/src/recovered/features/vault/types.ts b/frontend/src/recovered/features/vault/types.ts index 9e8d28c0..dd30a973 100644 --- a/frontend/src/recovered/features/vault/types.ts +++ b/frontend/src/recovered/features/vault/types.ts @@ -13,6 +13,7 @@ export type VaultCard = { readonly expMonth: number; readonly expYear: number; readonly holderName: string; + readonly nickname: string; readonly billingAddressId: string; readonly billingAddress: VaultAddress; }; @@ -65,6 +66,7 @@ export type VaultDesktop = { readonly updateGrokBotVaultCard: (input: { readonly id: string; readonly holderName: string; + readonly nickname?: string; readonly expiry: string; readonly billingAddress: VaultAddress; readonly billingAddressId: string; diff --git a/frontend/src/recovered/features/vault/upstream-vault-messages-0755.d.mts b/frontend/src/recovered/features/vault/upstream-vault-messages-0755.d.mts new file mode 100644 index 00000000..1d38e042 --- /dev/null +++ b/frontend/src/recovered/features/vault/upstream-vault-messages-0755.d.mts @@ -0,0 +1,6 @@ +import type { VaultCatalogEntry } from "./upstream-vault-messages.generated.mjs"; + +export declare const upstreamVaultMessages0755: { + readonly en: Readonly>; + readonly "zh-CN": Readonly>; +}; diff --git a/frontend/src/recovered/features/vault/upstream-vault-messages-0755.mjs b/frontend/src/recovered/features/vault/upstream-vault-messages-0755.mjs new file mode 100644 index 00000000..c739ceb8 --- /dev/null +++ b/frontend/src/recovered/features/vault/upstream-vault-messages-0755.mjs @@ -0,0 +1,18 @@ +export const upstreamVaultMessages0755 = { + en: { + PgseLK: ["Grok Bot never sees a saved card's number or security code. It can see logins and contact info so it can type them in for you."], + J4YQOg: ["Grok Bot can see logins and contact info so it can type them in for you"], + "5a1TO9": ["Nothing saved yet. Add a login, card, or contact info with New item."], + mx2Qib: ["No logins yet. Add one with New item, or save one from a secure form."], + "1A2dM9": ["No saved cards yet. Add one with New item, or save one from a secure form."], + Fjs6To: ["No contact info yet. Add some with New item, or save it at checkout."], + }, + "zh-CN": { + PgseLK: ["Grok Bot 永远看不到已保存卡片的卡号或安全码。它可以查看登录信息和联系信息,以便替你填写。"], + J4YQOg: ["Grok Bot 可以看到登录信息和联系信息,以便替你填写"], + "5a1TO9": ["还没有保存任何内容。通过新项目添加登录信息、卡片或联系信息。"], + mx2Qib: ["还没有登录信息。通过新项目添加一条,或从安全表单中保存一条。"], + "1A2dM9": ["还没有保存的卡片。通过新项目添加一张,或从安全表单中保存一张。"], + Fjs6To: ["还没有联系信息。通过新项目添加,或在结账时保存。"], + }, +}; diff --git a/frontend/src/recovered/features/vault/upstream-vault-messages.generated.mjs b/frontend/src/recovered/features/vault/upstream-vault-messages.generated.mjs index 3298d309..52e684ba 100644 --- a/frontend/src/recovered/features/vault/upstream-vault-messages.generated.mjs +++ b/frontend/src/recovered/features/vault/upstream-vault-messages.generated.mjs @@ -1,3 +1,3 @@ -// Generated by scripts/lib/vault-renderer-patch.mjs from the pinned Grok Bot 0.72.1 ASAR. Do not edit. -// provenance={"upstream":{"version":"0.72.1","asarSha256":"b272ee13db0fb9106f9276a46a8e47baf688c8d5ac1b1dc400df6fcba9e76996"},"ids":224,"en":211,"zhCN":9} -export const upstreamVaultMessages = {"en":{"6V3Ea3":["Copied"],"CKGdoo":["Your computer"],"u8jZfN":["Manage devices"],"t7TeQU":["Messages"],"yGkA3X":["Bot's computer"],"AeXO77":["Account"],"59DMcs":["Manage your sign-in, team, and saved accounts"],"FEr96N":["Theme"],"rPsbnH":["Pick the light or dark look for Grok Bot"],"Eax/et":["Accent"],"eeSkqM":["Color 1:1 Bot messages and cards with the Bot's color, or keep them black"],"vXIe7J":["Language"],"uHzQat":["Choose the language Grok Bot uses for menus and messages"],"hzdQ0D":["Check Spelling While Typing"],"AQEPsg":["Underline misspelled words as you type"],"1iY5xv":["Microphone"],"ObLYJM":["Choose which microphone Grok Bot listens to when you talk to it"],"gkVAUt":["Use hardware acceleration"],"uGmpY+":["Let your graphics card draw the app, or turn it off if the window flickers or stays blank"],"ZFmUzi":["Restart to Apply"],"/7L0mm":["Restart Grok Bot so the graphics change takes effect"],"QVjG8n":["Network Debugger"],"vhgAB7":["Check Grok Bot's connection"],"6EhUT7":["Play Sound for Notifications"],"0+TImd":["Turn the sound that plays when Grok Bot sends you a message on or off"],"wm7RV4":["Notification Sound"],"KXGrZy":["Pick the sound that plays when Grok Bot sends you a message"],"scu3wk":["Model"],"2RPCms":["Choose which AI model Grok Bot thinks with"],"40Gx0U":["Timezone"],"TO/JdP":["Set the time zone Grok Bot uses for schedules and reminders"],"fuUvu2":["Execution on Local Computer"],"Hd1KB+":["Allow Grok Bot to run tasks on this computer, not only on its own computer"],"Q4Zdc3":["See and manage the computers Grok Bot can work on"],"1O0Zig":["Import cookies from Chrome"],"0DQ6h6":["Copy your Chrome logins to Grok Bot's computer so it can use the sites you are signed in to"],"ISQkak":["Use Messages"],"jusBAO":["Lets Grok Bot read and send texts on this Mac"],"jO0zrH":["Send Without Asking"],"H8ihay":["Choose whether Grok Bot asks before it sends a text"],"S+1Zzr":["Allowed recipients"],"qwAXC4":["Manage who Grok Bot can text without asking first"],"RkLueX":["Auto-review"],"SapxY4":["Choose how closely Grok Bot checks its own risky actions before it runs them"],"BKJ+TX":["Custom Rules"],"WhXxC0":["Set rules for which actions Grok Bot can take automatically"],"VUEkDl":["Use hardware security keys"],"Uzr0Jg":["Require a hardware security key, like a YubiKey, for sensitive actions"],"IgP+IC":["Clear connector preferences"],"FTN9h/":["Remove any preferences you have set with Team Bots which give them access to your personal connectors"],"lEemA0":["Slack account"],"bYJccz":["Link your Slack account to Cursor so Team Bots and Cloud Agents know who you are in Slack"],"UZKLEA":["Passkeys"],"D480N4":["Save a passkey so Grok Bot can confirm it's you before it approves a purchase"],"7FaY4u":["Usage"],"i7ZlV9":["See your included usage and when it resets"],"UDsdr3":["Manage Plan"],"N5p7gX":["See your plan, change it, or update billing"],"oV3urV":["Cancel Trial"],"JpChhx":["End your free trial early"],"dUyQn5":["On-Demand"],"sUOyeI":["Allow extra usage beyond your plan, billed as you go"],"53hao2":["Manage Billing"],"GwmYad":["Manage your billing on Cursor"],"OarWo6":["Route traffic through this computer"],"t5gE79":["Send Grok Bot's internet traffic through this desktop instead of its own computer"],"U+dVHJ":["Grok Bot Updates"],"ao3+bh":["See which version of Grok Bot you have and whether an update is ready"],"/IUA77":["Update Track"],"iRkm85":["Choose whether Grok Bot installs stable releases only or tries beta builds early"],"VmXinp":["Automatic Updates"],"Yia9RU":["Let Grok Bot install updates on its own"],"hydWk/":["Update Bot's Computer"],"mlZ6OJ":["Install the latest software on Grok Bot's computer and keep your files in place"],"sJUwbc":["Reset Bot's Computer"],"O+wR5I":["Restart Grok Bot's computer from your last saved snapshot if it gets stuck"],"ifXMoM":["That file can't be read. Choose a JPEG, PNG, GIF or WebP photo of the card."],"SIl8Cr":["You can add up to ",["maxCount","plural",{"one":["#"," photo"],"other":["#"," photos"]}]],"/j84aQ":["Those photos are too large together. Keep them under 20 MB in total."],"1TWWPH":["Couldn't read a card in the photos. Enter the details yourself."],"1u/HkJ":["Too many photos in a row. Wait a minute and try again."],"6XoriY":["Reading photos isn't available right now. Enter the details yourself."],"IelWbl":["Reading card photos isn't turned on for this account. Enter the details yourself."],"qM7vSa":["Those photos can't be read. Use JPEG, PNG, GIF or WebP photos of the card."],"MYVRIX":["Couldn't read the photos. Enter the details yourself."],"8Hi+X6":["Filled from the photos. Check each detail before you save."],"r46SKb":["Filled what the photos showed. Enter the rest, then check each detail before you save."],"iWnbNJ":["Reading the card…"],"y9b3+R":["Fill from photos of the card, such as its front and back. Choose them, or paste or drop them here."],"Iyyvds":["Add another photo, such as the back, to read the card again"],"KDw4GX":["Try again"],"Lx8S4X":["Add photo"],"v8D+Lv":["Choose photos"],"kpfgrc":["Card photos"],"1YHBDM":["Card photo ",["number"]],"e1AX3P":["Remove photo ",["number"]],"CfqzS2":["Card photo"],"xHIEQ5":["Card number"],"hwlSE2":["Expiry (MM/YY)"],"wLmRnI":["Security code"],"Mf9Gtf":["Name on card"],"gzEjAL":["Billing address"],"cormHa":["Address line 2"],"3wV73y":["City"],"BKTGoj":["State or region"],"XSEMno":["ZIP or postal code"],"JNCzPW":["Country"],"AUlTmE":["Use a saved address"],"sRag9r":["Enter a new address"],"Jeg176":["Copy link to the ",["setting"]," setting"],"i2K63W":["Found a 1Password export"],"7K3Gyf":["Found a Chrome or Edge export"],"w3F/28":["Found a Safari or Apple Passwords export"],"htpCxn":["Found a Firefox export"],"M8XZOv":["Found a Bitwarden export"],"fwTvs/":["Found a LastPass export"],"5QvEib":["Missing password"],"8sn99t":["Missing website"],"nLwGv6":["Website isn't https"],"OH8hLt":["Invalid website"],"70Usji":["A field is too long"],"0FSRiz":["Invalid card number"],"yUqfOJ":["Invalid expiry"],"yMg5R0":["Card has expired"],"7xaBoY":["Invalid security code"],"eBD04a":["Cards aren't available yet"],"lsUECU":["Not a login or card"],"ckH3fT":["Ready"],"WhRvk/":["Already in your vault"],"JeiswB":["Row ",["0"]],"uycY/T":["That file is too large. Choose a CSV under 5 MB."],"WYG9Bc":["Couldn't read that file. Try again"],"Uq6RAf":["This doesn't look like a password export. Choose a CSV exported from a supported app."],"rfbXwj":["CSV file"],"vmh1dn":["Import logins from a CSV file exported by 1Password, Chrome, Edge, Safari, Apple Passwords, Firefox, Bitwarden, or LastPass"],"NE09IK":["Cards come along from LastPass exports"],"yhT5K5":["The file is read on this device and never uploaded"],"dEgA5A":["Cancel"],"cKp8I8":["Choose CSV file"],"x2fZoE":["Import summary"],"GQignI":[["0"]," ready"],"bPYHMq":[["0"]," already in your vault"],"R15yqd":[["0","plural",{"one":["#"," with an error"],"other":["#"," with errors"]}]],"fAcGxw":[["0"]," skipped"],"Q1ylu5":["Items in this file"],"0KHIyx":["Choose another file"],"dF5m/c":[["0","plural",{"one":["Import ","#"," item"],"other":["Import ","#"," items"]}]],"YLKiRf":["Importing ",["done"]," of ",["total"],"…"],"5NjsW4":["Import progress"],"sqgQgy":["Stop import"],"wKV/qm":["Imported ",["logins","plural",{"one":["#"," login"],"other":["#"," logins"]}]," and ",["cards","plural",{"one":["#"," card"],"other":["#"," cards"]}]],"qj/uYG":["Imported ",["logins","plural",{"one":["#"," login"],"other":["#"," logins"]}]],"kof2re":["Skipped ",["duplicates","plural",{"one":["#"," item"],"other":["#"," items"]}]," already in your vault"],"9oQeTa":["The import stopped before every item was saved"],"DGFoI3":[["0","plural",{"one":["#"," item couldn't be imported"],"other":["#"," items couldn't be imported"]}]],"jfSsZr":["Items that couldn't be imported"],"DPfwMq":["Done"],"jJOolg":["Import from CSV"],"QqKsGg":["Couldn't save. Try again."],"br7Ace":["Save login"],"3UUCyn":["New login"],"6ixmzu":["Edit login for ",["name"]],"6YtxFj":["Name"],"On0aF2":["Website"],"5E4MzW":["Username or email"],"8ZsakT":["Password"],"6SNOki":["Leave blank to keep the saved password"],"1DBGsz":["Notes"],"CGtciJ":[["brand"]," ending ",["last4"]],"xGekty":["Save card"],"ja+MfM":["Edit ",["name"]],"AomB24":["The card number and security code can't be changed. To change them, remove this card and save it again."],"pnrmSP":["New card"],"z0t9bb":["Login"],"x5oYhz":["A username and password for a website"],"kryGs+":["Card"],"18LOMS":["A payment card Grok Bot can pay with"],"jfC/xh":["Contact"],"Corqen":["An address, phone, or email Grok Bot fills in at checkout"],"USnyM6":["New contact"],"KofAh0":["New item"],"iH8pgl":["Back"],"Du6bPw":["Address"],"PAx2Yh":["Save contact"],"87a/t/":["Label"],"0W0FHK":["Full name"],"zmwvG2":["Phone"],"ATGYL1":["Email address"],"6cXc68":["Use as my default shipping address"],"t/YqKh":["Remove"],"eWGcnp":["Couldn't remove it. Try again."],"Yk6n1o":["Remove this login?"],"Mm9cq/":["Grok Bot can no longer sign in to ",["name"]," with it"],"ePK91l":["Edit"],"Hi5XX+":["Remove login for ",["name"]],"DfnecK":["Remove “",["name"],"”?"],"mtX2At":["Grok Bot can no longer pay with this card"],"zBCQ3P":["Expires ",["expiry"]],"4dHPeH":[["holderName"]," · Expires ",["expiry"]],"HLazKQ":["Remove ",["name"]],"zJNxoa":["Grok Bot can no longer use this contact info"],"0k9c6p":["Default shipping · ",["summary"]],"NLLW52":["Logins"],"5MOY3C":["No logins yet. Add one, or save one from a secure form."],"PgseLK":["Grok Bot never sees a saved card's number or security code"],"Ccpbzh":["Cards"],"1A2dM9":["No saved cards yet. Add one with New item, or save one from a secure form."],"J4YQOg":["Grok Bot can see your saved contacts and types them in at checkout"],"gVfVfe":["Contacts"],"HzlckB":["No contacts yet. Add one, or save one at checkout."],"l3s5ri":["Import"]},"zh-CN":{"6V3Ea3":["已复制"],"AeXO77":["账户"],"vXIe7J":["语言"],"dEgA5A":["取消"],"QqKsGg":["无法保存。请重试。"],"6YtxFj":["名称"],"iH8pgl":["返回"],"t/YqKh":["移除"],"ePK91l":["编辑"]}}; +// Generated by scripts/lib/vault-renderer-patch.mjs from the pinned Grok Bot 0.75.5 ASAR. Do not edit. +// provenance={"upstream":{"version":"0.75.5","asarSha256":"12bba50ba6cf12b35132518788610677a3fdc65de4ad849628d757bc7b780e5a"},"ids":212,"en":205,"zhCN":110} +export const upstreamVaultMessages = {"en":{"cu6iol":["Close dialog"],"WyGyYp":["(Optional)"],"wDHlOl":["Visa"],"gPV2Ty":["Mastercard"],"k46uGm":["American Express"],"/XQgft":["Discover"],"Xcv4g4":["MM / YY"],"VeOI5z":["Hide security code"],"BqrHbB":["Show security code"],"i0qMbr":["Home"],"qRILxq":["Work"],"/IX/7x":["Other"],"wh9uml":["Add new address"],"MQKGE+":["No billing address"],"FSBogA":["Choose an address"],"JNCzPW":["Country"],"gzEjAL":["Billing address"],"C9VfWO":["Street address"],"cnJuer":["Apt, suite or unit"],"LH5rTq":["Apt, suite or unit (Optional)"],"3wV73y":["City"],"RS0o7b":["State"],"pVZUS0":["ZIP code"],"6PgkkY":["Add a billing address"],"AUlTmE":["Use a saved address"],"+zy2Nq":["Type"],"Z6JctO":["Contact name"],"h2nxQP":["Saved as a new contact in Contact info, linked to this card"],"ifXMoM":["That file can't be read. Choose a JPEG, PNG, GIF or WebP photo of the card."],"SIl8Cr":["You can add up to ",["maxCount","plural",{"one":["#"," photo"],"other":["#"," photos"]}]],"/j84aQ":["Those photos are too large together. Keep them under 20 MB in total."],"1TWWPH":["Couldn't read a card in the photos. Enter the details yourself."],"1u/HkJ":["Too many photos in a row. Wait a minute and try again."],"6XoriY":["Reading photos isn't available right now. Enter the details yourself."],"IelWbl":["Reading card photos isn't turned on for this account. Enter the details yourself."],"qM7vSa":["Those photos can't be read. Use JPEG, PNG, GIF or WebP photos of the card."],"MYVRIX":["Couldn't read the photos. Enter the details yourself."],"8Hi+X6":["Filled from the photos. Check each detail before you save."],"r46SKb":["Filled what the photos showed. Enter the rest, then check each detail before you save."],"4hfTrB":["Nickname"],"HptUxX":["Number"],"G2fuEb":["Locked"],"Mf9Gtf":["Name on card"],"KnN1Tu":["Expires"],"+7fBMP":["Built-in"],"NrMd9u":["USB camera"],"Ikf/KX":["Hold the front of the card inside the frame"],"GAK8qU":["If the number is on the back, flip the card"],"dgUkd2":["Hold the back of the card inside the frame"],"w2hLRY":["Hold still while it reads the card"],"W+e0Zq":["Hold still while it reads the back"],"r12mm7":["No number on the front. Flip it to scan the back."],"t4ThUL":["It's hard to see the card. Try more light."],"QPdeRz":["Hold the other side inside the frame for the security code"],"1wzE+F":["Hold the other side inside the frame for the name"],"OGNd+N":["Hold the other side for the security code and name"],"JVB7m7":["Couldn't read the card. Try more light."],"J0eoz+":["Too many tries. Wait a minute, then scan again."],"p+R6vr":["Scanning isn't available right now. Type it in."],"HRNsFh":["Card scanning isn't turned on for this account"],"zQUSik":["Couldn't read the card. Try again."],"rT2cV+":["Camera"],"18SLtg":["Camera access is off"],"b8Cn0n":["Open System Settings"],"UqAs69":["No camera found"],"1VK9fX":["Couldn't start the camera"],"irZYhR":["Camera preview"],"Qu/o3L":["Number's on the back"],"qqlsGD":["Scan the other side"],"CceMjR":["Flip the card for the security code"],"plTBeM":["Flip the card for the name"],"fl9w1f":["Flip the card for the security code and name"],"8/exSJ":["That file type isn't supported"],"RwE+6a":["Choose another photo"],"1wSjhH":["The number's on the other side"],"Hi4MsU":["Add the back"],"HXFmFy":["Couldn't read the card. Scan again, upload a photo, or type it in."],"wv9aWB":["Couldn't read that photo. Try another, scan with the camera, or type it in."],"VKTdOU":["Couldn't read it. Type it in."],"g7bjyf":["Edit ",["cardTitle"]," ending ",["last4"]],"DHIemU":["Scan the card"],"pnrmSP":["New card"],"wLmRnI":["Security code"],"gPftWF":["3 or 4 digits"],"9SZdi5":["To change the number, remove this card and add it again"],"2M55hZ":["Grok Bot never sees the number"],"mJqMSE":["Scan with camera"],"aZac5h":["Reading photo…"],"WnfuZ0":["Upload a photo"],"ciVOzZ":["or type it in"],"xHIEQ5":["Card number"],"w4wCgl":["Enter a valid card number"],"agO/T/":["Expiry"],"zy1TsH":["Scan again"],"xGekty":["Save card"],"KX57vb":["Type it in"],"uyHRvk":["Drop the photo to fill the card"],"CfqzS2":["Card photo"],"H+69ds":["e.g. Travel"],"t/YqKh":["Remove"],"ePK91l":["Edit"],"DPfwMq":["Done"],"QqKsGg":["Couldn't save. Try again."],"+5aaQX":[["title"]," ending ",["last4"]],"DfnecK":["Remove “",["name"],"”?"],"mtX2At":["Grok Bot can no longer pay with this card"],"dEgA5A":["Cancel"],"eWGcnp":["Couldn't remove it. Try again."],"i2K63W":["Found a 1Password export"],"7K3Gyf":["Found a Chrome or Edge export"],"w3F/28":["Found a Safari or Apple Passwords export"],"htpCxn":["Found a Firefox export"],"M8XZOv":["Found a Bitwarden export"],"fwTvs/":["Found a LastPass export"],"5QvEib":["Missing password"],"8sn99t":["Missing website"],"nLwGv6":["Website isn't https"],"OH8hLt":["Invalid website"],"70Usji":["A field is too long"],"0FSRiz":["Invalid card number"],"yUqfOJ":["Invalid expiry"],"yMg5R0":["Card has expired"],"7xaBoY":["Invalid security code"],"eBD04a":["Cards aren't available yet"],"lsUECU":["Not a login or card"],"ckH3fT":["Ready"],"WhRvk/":["Already in your vault"],"JeiswB":["Row ",["0"]],"uycY/T":["That file is too large. Choose a CSV under 5 MB."],"WYG9Bc":["Couldn't read that file. Try again"],"Uq6RAf":["This doesn't look like a password export. Choose a CSV exported from a supported app."],"rfbXwj":["CSV file"],"vmh1dn":["Import logins from a CSV file exported by 1Password, Chrome, Edge, Safari, Apple Passwords, Firefox, Bitwarden, or LastPass"],"NE09IK":["Cards come along from LastPass exports"],"yhT5K5":["The file is read on this device and never uploaded"],"cKp8I8":["Choose CSV file"],"x2fZoE":["Import summary"],"GQignI":[["0"]," ready"],"bPYHMq":[["0"]," already in your vault"],"R15yqd":[["0","plural",{"one":["#"," with an error"],"other":["#"," with errors"]}]],"fAcGxw":[["0"]," skipped"],"Q1ylu5":["Items in this file"],"0KHIyx":["Choose another file"],"dF5m/c":[["0","plural",{"one":["Import ","#"," item"],"other":["Import ","#"," items"]}]],"YLKiRf":["Importing ",["done"]," of ",["total"],"…"],"5NjsW4":["Import progress"],"sqgQgy":["Stop import"],"wKV/qm":["Imported ",["logins","plural",{"one":["#"," login"],"other":["#"," logins"]}]," and ",["cards","plural",{"one":["#"," card"],"other":["#"," cards"]}]],"qj/uYG":["Imported ",["logins","plural",{"one":["#"," login"],"other":["#"," logins"]}]],"kof2re":["Skipped ",["duplicates","plural",{"one":["#"," item"],"other":["#"," items"]}]," already in your vault"],"9oQeTa":["The import stopped before every item was saved"],"DGFoI3":[["0","plural",{"one":["#"," item couldn't be imported"],"other":["#"," items couldn't be imported"]}]],"jfSsZr":["Items that couldn't be imported"],"jJOolg":["Import from CSV"],"On0aF2":["Website"],"dz9oyW":["Open ",["domain"]],"7sNhEz":["Username"],"8ZsakT":["Password"],"HQJ8BO":["Saved password, hidden"],"1DBGsz":["Notes"],"3UUCyn":["New login"],"uvumiB":["Edit login for ",["editingDomain"]],"5E4MzW":["Username or email"],"6SNOki":["Leave blank to keep the saved password"],"P6suyj":["Grok Bot can use this login to sign in for you"],"aSajXj":["Grok Bot can use this login to sign in for you on ",["host"]],"br7Ace":["Save login"],"Yk6n1o":["Remove this login?"],"Mm9cq/":["Grok Bot can no longer sign in to ",["name"]," with it"],"NLLW52":["Logins"],"Ccpbzh":["Cards"],"OBRLoG":["Contact info"],"5a1TO9":["Nothing saved yet. Add a login, card, or contact info with New item."],"mx2Qib":["No logins yet. Add one with New item, or save one from a secure form."],"1A2dM9":["No saved cards yet. Add one with New item, or save one from a secure form."],"Fjs6To":["No contact info yet. Add some with New item, or save it at checkout."],"ycCSuD":["Note:"],"ZZ060Q":["Edit ",["title"]," ending ",["last4"]],"ja+MfM":["Edit ",["name"]],"HSllT+":["View login for ",["name"]],"R/b23j":["Search Vault"],"V8yTm6":["Clear search"],"N40H+G":["All"],"76H695":["Item type"],"kryGs+":["Card"],"PH2oLy":["Vault items"],"TBlG9c":["No matches for “",["0"],"”"],"2HFHfz":["Grok Bot never sees a saved card's number or security code. It can see logins and contact info so it can type them in for you."],"/iPSdc":["Grok Bot can see logins and contact info so it can type them in for you"],"cormHa":["Address line 2"],"BKTGoj":["State or region"],"XSEMno":["ZIP or postal code"],"z0t9bb":["Login"],"SJc6TB":["New contact info"],"Du6bPw":["Address"],"PAx2Yh":["Save contact"],"87a/t/":["Label"],"0W0FHK":["Full name"],"zmwvG2":["Phone"],"ATGYL1":["Email address"],"vcQwyD":["Edit contact info"],"zJNxoa":["Grok Bot can no longer use this contact info"],"HLazKQ":["Remove ",["name"]],"KofAh0":["New item"],"yrzweQ":["Import from CSV…"]},"zh-CN":{"cu6iol":["关闭对话框"],"WyGyYp":["(可选)"],"JNCzPW":["国家/地区"],"gzEjAL":["账单地址"],"3wV73y":["城市"],"pnrmSP":["新卡片"],"t/YqKh":["移除"],"ePK91l":["编辑"],"DPfwMq":["完成"],"QqKsGg":["无法保存。请重试。"],"DfnecK":["移除“",["name"],"”?"],"dEgA5A":["取消"],"eWGcnp":["无法移除。请重试。"],"i2K63W":["检测到 1Password 导出文件"],"7K3Gyf":["检测到 Chrome 或 Edge 导出文件"],"w3F/28":["检测到 Safari 或 Apple Passwords 导出文件"],"htpCxn":["检测到 Firefox 导出文件"],"M8XZOv":["检测到 Bitwarden 导出文件"],"fwTvs/":["检测到 LastPass 导出文件"],"5QvEib":["缺少密码"],"8sn99t":["缺少网站"],"nLwGv6":["网站未使用 https"],"OH8hLt":["网站无效"],"70Usji":["某个字段过长"],"0FSRiz":["卡号无效"],"yUqfOJ":["有效期无效"],"yMg5R0":["卡片已过期"],"7xaBoY":["安全码无效"],"eBD04a":["暂不支持卡片"],"lsUECU":["不是登录信息或卡片"],"ckH3fT":["就绪"],"WhRvk/":["已在你的保险库中"],"JeiswB":["第 ",["0"]," 行"],"uycY/T":["该文件过大。请选择小于 5 MB 的 CSV 文件。"],"WYG9Bc":["无法读取该文件。请重试"],"Uq6RAf":["这看起来不是密码导出文件。请选择从受支持的应用导出的 CSV 文件。"],"rfbXwj":["CSV 文件"],"vmh1dn":["从 1Password、Chrome、Edge、Safari、Apple Passwords、Firefox、Bitwarden 或 LastPass 导出的 CSV 文件导入登录信息"],"NE09IK":["从 LastPass 导出的文件会一并导入卡片"],"yhT5K5":["文件仅在此设备上读取,绝不会上传"],"cKp8I8":["选择 CSV 文件"],"x2fZoE":["导入摘要"],"GQignI":[["0"]," 项就绪"],"bPYHMq":[["0"]," 项已在你的保险库中"],"R15yqd":[["0","plural",{"other":["#"," 项有错误"]}]],"fAcGxw":["已跳过 ",["0"]," 项"],"Q1ylu5":["此文件中的项目"],"0KHIyx":["选择其他文件"],"dF5m/c":[["0","plural",{"other":["导入 ","#"," 项"]}]],"YLKiRf":["正在导入第 ",["done"]," 项,共 ",["total"]," 项…"],"5NjsW4":["导入进度"],"sqgQgy":["停止导入"],"wKV/qm":["已导入 ",["logins","plural",{"other":["#"," 条登录信息"]}],"和 ",["cards","plural",{"other":["#"," 张卡片"]}]],"qj/uYG":["已导入 ",["logins","plural",{"other":["#"," 条登录信息"]}]],"kof2re":["已跳过保险库中已有的 ",["duplicates","plural",{"other":["#"," 项"]}]],"9oQeTa":["导入在所有项目保存完成前已停止"],"DGFoI3":[["0","plural",{"other":["#"," 项无法导入"]}]],"jfSsZr":["无法导入的项目"],"jJOolg":["从 CSV 导入"],"On0aF2":["网站"],"dz9oyW":["打开 ",["domain"]],"7sNhEz":["用户名"],"8ZsakT":["密码"],"HQJ8BO":["已保存的密码,已隐藏"],"1DBGsz":["备注"],"3UUCyn":["新登录信息"],"uvumiB":["编辑 ",["editingDomain"]," 的登录信息"],"5E4MzW":["用户名或邮箱"],"6SNOki":["留空即可保留已保存的密码"],"P6suyj":["Grok Bot 可以使用此登录信息替你登录"],"aSajXj":["Grok Bot 可以使用此登录信息替你登录 ",["host"]],"br7Ace":["保存登录信息"],"Yk6n1o":["要移除此登录信息吗?"],"Mm9cq/":["Grok Bot 将无法再用它登录 ",["name"]],"NLLW52":["登录信息"],"Ccpbzh":["卡片"],"OBRLoG":["联系信息"],"5a1TO9":["还没有保存任何内容。通过新项目添加登录信息、卡片或联系信息。"],"mx2Qib":["还没有登录信息。通过新项目添加一条,或从安全表单中保存一条。"],"1A2dM9":["还没有保存的卡片。通过新项目添加一张,或从安全表单中保存一张。"],"Fjs6To":["还没有联系信息。通过新项目添加,或在结账时保存。"],"ycCSuD":["备注:"],"ZZ060Q":["编辑尾号 ",["last4"]," 的 ",["title"]],"ja+MfM":["编辑",["name"]],"HSllT+":["查看 ",["name"]," 的登录信息"],"R/b23j":["搜索保险库"],"V8yTm6":["清除搜索"],"N40H+G":["全部"],"76H695":["项目类型"],"kryGs+":["卡"],"PH2oLy":["保险库项目"],"TBlG9c":["未找到与“",["0"],"”匹配的结果"],"2HFHfz":["Grok Bot 永远看不到已保存卡片的卡号或安全码。它可以看到登录信息和联系信息,以便替你填写。"],"/iPSdc":["Grok Bot 可以看到登录信息和联系信息,以便替你填写"],"cormHa":["地址第 2 行"],"BKTGoj":["州/省或地区"],"XSEMno":["邮政编码"],"z0t9bb":["登录信息"],"SJc6TB":["新建联系信息"],"Du6bPw":["地址"],"PAx2Yh":["保存联系人"],"87a/t/":["标签"],"0W0FHK":["姓名"],"zmwvG2":["手机"],"ATGYL1":["邮箱地址"],"vcQwyD":["编辑联系信息"],"zJNxoa":["Grok Bot 将无法再使用此联系信息"],"HLazKQ":["移除 ",["name"]],"KofAh0":["新项目"],"yrzweQ":["从 CSV 导入…"]}}; diff --git a/frontend/src/recovered/features/vault/upstream-vault-settings.generated.d.mts b/frontend/src/recovered/features/vault/upstream-vault-settings.generated.d.mts index ee0fe0cb..6255255f 100644 --- a/frontend/src/recovered/features/vault/upstream-vault-settings.generated.d.mts +++ b/frontend/src/recovered/features/vault/upstream-vault-settings.generated.d.mts @@ -15,3 +15,8 @@ export declare function createUpstreamVaultLinguiProvider(props: { readonly defaultComponent?: unknown; readonly children?: React.ReactNode; }): React.ReactNode; + +export declare function createUpstreamVaultPaneHeaderProvider(props: { + readonly value: HTMLElement | null; + readonly children?: React.ReactNode; +}): React.ReactNode; diff --git a/frontend/src/recovered/features/vault/upstream-vault-settings.generated.mjs b/frontend/src/recovered/features/vault/upstream-vault-settings.generated.mjs index 331fdc4d..8e9074fe 100644 --- a/frontend/src/recovered/features/vault/upstream-vault-settings.generated.mjs +++ b/frontend/src/recovered/features/vault/upstream-vault-settings.generated.mjs @@ -1,49 +1,49 @@ -// Generated by scripts/lib/vault-renderer-patch.mjs from the pinned Grok Bot 0.72.1 ASAR. Do not edit.// provenance={"upstream":{"version":"0.72.1","asarSha256":"b272ee13db0fb9106f9276a46a8e47baf688c8d5ac1b1dc400df6fcba9e76996"},"modules":[{"path":"dist/renderer/assets/sand-vault-0721-entry.js","inputSha256":"47a7189da03c84bb981d8c24055013051bc605b7dfdb2ed51ec0c59def0a635e","exports":["default","createUpstreamVaultStore","createUpstreamVaultLinguiProvider"]},{"path":"dist/renderer/assets/chunk-view-Cwu5IFAB.js","inputSha256":"0768768d8d3a7bc4cbd834d59b047683ae3fad7367125ec22333be6664bd668a","exports":["sandVaultSettings"]},{"path":"dist/renderer/assets/index.eager-app-CG8Fw00L.js","inputSha256":"45a836d7d790e1835e5dab596fa90adfc4b0380aa547a4af5df636b4a4742171","exports":["sandVaultCreateStore","Cp","Dp","ES","Fp","J_","Jd","K_","Tp","Vw","X_","Y_","Z_","ap","cm","ev","jS","nf","nv","op","q_","rv","vS","zp","Ip","sm","$_","Ep","Gp","KC","Mp","Np","Pr","jp","mp","tv","wp","Fw","Hw","Jf","Lp","Zp","lm","ln","qf","um","zf"]},{"path":"dist/renderer/assets/index.eager-vendor-cR6BHVc-.js","inputSha256":"1fbe4cc235782785cd8d4552a8a3dfd4d8f39b3e8e668c524be2e5260595355f","exports":["F","I","L","O","Wr","Hn","Hr","Wn","vr","Gt","Ht","Kt","Qt","Rt","Vt","nn","qt","rn","tn"]},{"path":"dist/renderer/assets/chunk-rolldown-runtime-C0FnF6B9.js","inputSha256":"5a0137f4307856cf686fc05901a14fe0d51607b6bf221457a1f8e6d2ce743c7b","exports":["o","t"]},{"path":"dist/renderer/assets/index.eager-platform-BFGuCGzq.js","inputSha256":"2d5fb867435531b08a8c1b95e1befba7432464a7fed27768125259d2a75ea1e7","exports":["Gt","_r","Ni","ji","pi","ui","zi","Kt","Wt","mr","Ar","Bn","Ln","P","Rn","pr","zn"]},{"path":"dist/renderer/assets/index.eager-common-BH0hmUYG.js","inputSha256":"457a665c224045fedfca5ceb1c3aa44fe7c5e3d32c297cdbaa360d83234df691","exports":["H","T","V","L","et","pt","tt"]},{"path":"dist/renderer/assets/chunk-card-field-BSSPKMT3.js","inputSha256":"a018fac20b907a27b56d9a5c0fe94d16f7408e4645c1b1c2aff6f8a06f53abc8","exports":["i","n","o","r","t","a"]},{"path":"dist/renderer/assets/chunk-vault-card-fields-BBZgWwVF.js","inputSha256":"9afe50bc9af9bfb8cce0229c29f5103fda0ca55464d9c16db91c14a19016bdbe","exports":["a","f","h","m","o","p","r","s","t"]},{"path":"dist/renderer/assets/chunk-settings-row-C3cXt6xe.js","inputSha256":"0226a2e2e65205c88cb7b61a705214343e8984d968a0e0e134b49df087c3d933","exports":["a","c","r"]},{"path":"dist/renderer/assets/chunk-pane-header-CrSxprOO.js","inputSha256":"179557ab85d6c2cdf2f7631413b213d017d9572385c3f07bd850a8ac6a68d5b5","exports":["n"]},{"path":"dist/renderer/assets/chunk-scroll-pane-xfE80KzA.js","inputSha256":"f9d11dd19da1b0a561d702f1459bfd3f2c8fe3357641e0eeed353d4218b712e1","exports":["t"]},{"path":"dist/renderer/assets/chunk-csv-parse-C5LpQq5n.js","inputSha256":"959cb8ed05eb9fecc7f9f839b6d97dcb4631c4bd35b5e5dd63f7ed19452b49e8","exports":["r"]}],"styleSha256":"4997d6a6f63105c8dc555bfaaf8aa0bd47aa416e526f5b37e7323a6e693c725f"}export const upstreamVaultStyle = "#sand-vault-0721-root .sand-1xr8qbc{--sand-anchor-reveal:0}\n#sand-vault-0721-root .sand-u366gq{--sand-status-dot-ring:var(--sand-bg-elevated)}\n#sand-vault-0721-root .sand-pn37pp.sand-pn37pp:where(:has(.sand--default-marker[data-agent-thread-toggle]:focus-visible)){--sand-agent-item-avatar-opacity:0}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1h9t0qu.sand-1h9t0qu{--sand-mention-monogram-fill:color-mix(in srgb,currentColor 20%,transparent)}\n#sand-vault-0721-root .sand-jodmca:hover{--sand-anchor-reveal:1}\n#sand-vault-0721-root .sand-10a8y8t:not(#\\#){inset:0}\n#sand-vault-0721-root .sand-1ghz6dp:not(#\\#){margin:0}\n#sand-vault-0721-root .sand-1717udv:not(#\\#){padding:0}\n#sand-vault-0721-root .sand-c7ga6q:not(#\\#){padding:12px}\n#sand-vault-0721-root .sand-1tamke2:not(#\\#){padding:16px}\n#sand-vault-0721-root .sand-e8ttls:not(#\\#){padding:8px}\n#sand-vault-0721-root .sand-ihgi1t:not(#\\#):not(#\\#){border-color:color-mix(in srgb,currentcolor 30%,transparent)}\n#sand-vault-0721-root .sand-vd4qke:not(#\\#):not(#\\#){border-color:var(--sand-border-accent-primary)}\n#sand-vault-0721-root .sand-uw55gi:not(#\\#):not(#\\#){border-color:var(--sand-border-danger-primary)}\n#sand-vault-0721-root .sand-1x2x08a:not(#\\#):not(#\\#){border-color:var(--sand-border-primary-translucent)}\n#sand-vault-0721-root .sand-14ed0nm:not(#\\#):not(#\\#){border-color:var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-17tbahu:not(#\\#):not(#\\#){border-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-5fd6op:not(#\\#):not(#\\#){border-color:var(--sand-border-tertiary-translucent)}\n#sand-vault-0721-root .sand-j6k430:not(#\\#):not(#\\#){border-color:var(--sand-text-quaternary)}\n#sand-vault-0721-root .sand-1ctf4ec:not(#\\#):not(#\\#){border-radius:11px}\n#sand-vault-0721-root .sand-9h44rk:not(#\\#):not(#\\#){border-radius:13px}\n#sand-vault-0721-root .sand-ixl9f9:not(#\\#):not(#\\#){border-radius:14px}\n#sand-vault-0721-root .sand-n5hx6u:not(#\\#):not(#\\#){border-radius:15px}\n#sand-vault-0721-root .sand-gqmno8:not(#\\#):not(#\\#){border-radius:16px}\n#sand-vault-0721-root .sand-mf3hgm:not(#\\#):not(#\\#){border-radius:17px}\n#sand-vault-0721-root .sand-etvl1f:not(#\\#):not(#\\#){border-radius:19px}\n#sand-vault-0721-root .sand-16rqkct:not(#\\#):not(#\\#){border-radius:50%}\n#sand-vault-0721-root .sand-1kogg8i:not(#\\#):not(#\\#){border-radius:6px}\n#sand-vault-0721-root .sand-1i4c3av:not(#\\#):not(#\\#){border-radius:var(--cursor-radius-full)}\n#sand-vault-0721-root .sand-1m7fhj7:not(#\\#):not(#\\#){border-radius:var(--cursor-radius-lg)}\n#sand-vault-0721-root .sand-1e1y6u3:not(#\\#):not(#\\#){border-radius:var(--cursor-radius-sm)}\n#sand-vault-0721-root .sand-1pkpdue:not(#\\#):not(#\\#){border-radius:var(--cursor-radius-xl)}\n#sand-vault-0721-root .sand-1i6gnc1:not(#\\#):not(#\\#){border-radius:4px}\n#sand-vault-0721-root .sand-1qmwy7c:not(#\\#):not(#\\#){border-radius:8px}\n#sand-vault-0721-root .sand-1m1syzd:not(#\\#):not(#\\#),#sand-vault-0721-root .sand-lstp0r:not(#\\#):not(#\\#){border-radius:24px}\n#sand-vault-0721-root .sand-t9pb60:not(#\\#):not(#\\#){border-radius:6px}\n#sand-vault-0721-root .sand-1t6ttyj:not(#\\#):not(#\\#){border-radius:10px}\n#sand-vault-0721-root .sand-149ho13:not(#\\#):not(#\\#){border-radius:9999px}\n#sand-vault-0721-root .sand-bsl7fq:not(#\\#):not(#\\#){border-style:dashed}\n#sand-vault-0721-root .sand-ng3xce:not(#\\#):not(#\\#){border-style:none}\n#sand-vault-0721-root .sand-1y0btm7:not(#\\#):not(#\\#){border-style:solid}\n#sand-vault-0721-root .sand-4hv7ue:not(#\\#):not(#\\#){border-width:.5px}\n#sand-vault-0721-root .sand-c342km:not(#\\#):not(#\\#){border-width:0}\n#sand-vault-0721-root .sand-mkeg23:not(#\\#):not(#\\#){border-width:1px}\n#sand-vault-0721-root .sand-qjedn3:not(#\\#):not(#\\#){border-width:.5px}\n#sand-vault-0721-root .sand-xhr3t:not(#\\#):not(#\\#){gap:0}\n#sand-vault-0721-root .sand-883omv:not(#\\#):not(#\\#){gap:10px}\n#sand-vault-0721-root .sand-ou54vl:not(#\\#):not(#\\#){gap:16px}\n#sand-vault-0721-root .sand-12mrbbr:not(#\\#):not(#\\#){gap:1px}\n#sand-vault-0721-root .sand-1665zp3:not(#\\#):not(#\\#){gap:24px}\n#sand-vault-0721-root .sand-195vfkc:not(#\\#):not(#\\#){gap:2px}\n#sand-vault-0721-root .sand-1jnr06f:not(#\\#):not(#\\#){gap:4px}\n#sand-vault-0721-root .sand-17d4w8g:not(#\\#):not(#\\#){gap:6px}\n#sand-vault-0721-root .sand-167g77z:not(#\\#):not(#\\#){gap:8px}\n#sand-vault-0721-root .sand-137clkk:not(#\\#):not(#\\#){gap:var(--cursor-spacing-0-5)}\n#sand-vault-0721-root .sand-pkkfsy:not(#\\#):not(#\\#){gap:var(--cursor-spacing-1-5)}\n#sand-vault-0721-root .sand-11twubx:not(#\\#):not(#\\#){gap:var(--cursor-spacing-1)}\n#sand-vault-0721-root .sand-1dbef6d:not(#\\#):not(#\\#){gap:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-ehausa:not(#\\#):not(#\\#){gap:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-3qzy4x:not(#\\#):not(#\\#){gap:var(--cursor-spacing-7)}\n#sand-vault-0721-root .sand-e8uvvx:not(#\\#):not(#\\#){list-style:none}\n#sand-vault-0721-root .sand-10im51j:not(#\\#):not(#\\#){margin-block:0}\n#sand-vault-0721-root .sand-rxpjvj:not(#\\#):not(#\\#){margin-inline:0}\n#sand-vault-0721-root .sand-1a2a7pz:not(#\\#):not(#\\#){outline:none}\n#sand-vault-0721-root .sand-7giv3:not(#\\#):not(#\\#){overflow:clip}\n#sand-vault-0721-root .sand-b3r6kr:not(#\\#):not(#\\#){overflow:hidden}\n#sand-vault-0721-root .sand-t970qd:not(#\\#):not(#\\#){padding-block:0}\n#sand-vault-0721-root .sand-p59q4u:not(#\\#):not(#\\#){padding-block:10px}\n#sand-vault-0721-root .sand-j8oexa:not(#\\#):not(#\\#){padding-block:2px}\n#sand-vault-0721-root .sand-knfcqp:not(#\\#):not(#\\#){padding-block:7px}\n#sand-vault-0721-root .sand-1lqmthn:not(#\\#):not(#\\#){padding-block:var(--cursor-spacing-1-5)}\n#sand-vault-0721-root .sand-12ffz05:not(#\\#):not(#\\#){padding-block:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-y3j6vt:not(#\\#):not(#\\#){padding-block:var(--cursor-spacing-3)}\n#sand-vault-0721-root .sand-1awh872:not(#\\#):not(#\\#){padding-inline:10px}\n#sand-vault-0721-root .sand-aope02:not(#\\#):not(#\\#){padding-inline:12px}\n#sand-vault-0721-root .sand-fn1xvj:not(#\\#):not(#\\#){padding-inline:4px}\n#sand-vault-0721-root .sand-dqyycr:not(#\\#):not(#\\#){padding-inline:8px}\n#sand-vault-0721-root .sand-w3enoh:not(#\\#):not(#\\#){padding-inline:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-2f45yy:not(#\\#):not(#\\#){padding-inline:var(--cursor-spacing-3-5)}\n#sand-vault-0721-root .sand-139twnn.sand-139twnn:where(:has(.sand--default-marker[data-focus-held])):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-sb55g1:focus-within:not(#\\#):not(#\\#),#sand-vault-0721-root .sand-vk9egn:focus-visible:not(#\\#):not(#\\#){border-color:var(--sand-border-primary-translucent)}\n#sand-vault-0721-root :where(.sand--default-marker:is([data-pane-row-item]:hover,#sand-vault-0721-root [data-pane-row-item]:focus-within,#sand-vault-0721-root [data-pane-row-item]:has([aria-expanded=true]))) .sand-k8larj.sand-k8larj:not(#\\#):not(#\\#){overflow:visible}\n@media (hover:hover) and (pointer:fine){#sand-vault-0721-root :where(.sand--default-marker.sand-code-figure:hover) .sand-gh7kop.sand-gh7kop.sand-gh7kop:not(#\\#):not(#\\#){overflow:visible}}\n#sand-vault-0721-root .sand-1pha0wt:not(#\\#):not(#\\#):not(#\\#){align-items:baseline}\n#sand-vault-0721-root .sand-6s0dn4:not(#\\#):not(#\\#):not(#\\#){align-items:center}\n#sand-vault-0721-root .sand-pqajaz:not(#\\#):not(#\\#):not(#\\#){align-items:end}\n#sand-vault-0721-root .sand-uk3077:not(#\\#):not(#\\#):not(#\\#){align-items:flex-end}\n#sand-vault-0721-root .sand-1cy8zhl:not(#\\#):not(#\\#):not(#\\#){align-items:flex-start}\n#sand-vault-0721-root .sand-1qjc9v5:not(#\\#):not(#\\#):not(#\\#){align-items:stretch}\n#sand-vault-0721-root .sand-amitd3:not(#\\#):not(#\\#):not(#\\#){align-self:center}\n#sand-vault-0721-root .sand-kh2ocl:not(#\\#):not(#\\#):not(#\\#){align-self:stretch}\n#sand-vault-0721-root .sand-5orbwg:not(#\\#):not(#\\#):not(#\\#){animation-duration:.7s}\n#sand-vault-0721-root .sand-a4qsjk:not(#\\#):not(#\\#):not(#\\#){animation-iteration-count:infinite}\n#sand-vault-0721-root .sand-1a5igra:not(#\\#):not(#\\#):not(#\\#){animation-name:none}\n#sand-vault-0721-root .sand-r5sbw0:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-1wc8ddo-B}\n#sand-vault-0721-root .sand-1esw782:not(#\\#):not(#\\#):not(#\\#){animation-timing-function:linear}\n#sand-vault-0721-root .sand-jyslct:not(#\\#):not(#\\#):not(#\\#){appearance:none}\n#sand-vault-0721-root .sand-1r1mewj:not(#\\#):not(#\\#):not(#\\#){background-color:#000}\n#sand-vault-0721-root .sand-ukxp9i:not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,var(--sand-text-accent-primary) 20%,var(--sand-bg-active))}\n#sand-vault-0721-root .sand-jbqb8w:not(#\\#):not(#\\#):not(#\\#){background-color:#0000}\n#sand-vault-0721-root .sand-1cgqir:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-primary)}\n#sand-vault-0721-root .sand-a4e5b6:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary-hover)}\n#sand-vault-0721-root .sand-13jhjah:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary)}\n#sand-vault-0721-root .sand-kr7fhf:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-active)}\n#sand-vault-0721-root .sand-vopzge:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-primary)}\n#sand-vault-0721-root .sand-jt6epu:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-secondary)}\n#sand-vault-0721-root .sand-10e981r:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-elevated)}\n#sand-vault-0721-root .sand-8rotk8:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-primary)}\n#sand-vault-0721-root .sand-ptgcna:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-red-primary)}\n#sand-vault-0721-root .sand-azoy5u:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-scrim)}\n#sand-vault-0721-root .sand-18pe38m:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-hover)}\n#sand-vault-0721-root .sand-fwqdrz:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root .sand-105pnba:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-tertiary)}\n#sand-vault-0721-root .sand-7z33ko:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-primary)}\n#sand-vault-0721-root .sand-1ii9591:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-secondary)}\n#sand-vault-0721-root .sand-1uzf2l9:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-12ywq79:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-border-tertiary-translucent)}\n#sand-vault-0721-root .sand-1vh0fzo:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-text-accent-primary)}\n#sand-vault-0721-root .sand-1t716jg:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-text-primary)}\n#sand-vault-0721-root .sand-18rdzox:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-transcript-bubble-agent-fill)}\n#sand-vault-0721-root .sand-18o3ruo:not(#\\#):not(#\\#):not(#\\#){background-image:none}\n#sand-vault-0721-root .sand-16uus16:not(#\\#):not(#\\#):not(#\\#){border-end-end-radius:0}\n#sand-vault-0721-root .sand-pp8er5:not(#\\#):not(#\\#):not(#\\#){border-end-end-radius:16px}\n#sand-vault-0721-root .sand-biv7yw:not(#\\#):not(#\\#):not(#\\#){border-end-start-radius:0}\n#sand-vault-0721-root .sand-s9wviy:not(#\\#):not(#\\#):not(#\\#){border-end-start-radius:16px}\n#sand-vault-0721-root .sand-1o3jo1z:not(#\\#):not(#\\#):not(#\\#){border-inline-end-color:#0000}\n#sand-vault-0721-root .sand-bp68ws:not(#\\#):not(#\\#):not(#\\#){border-inline-end-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-18b5jzi:not(#\\#):not(#\\#):not(#\\#){border-inline-end-style:solid}\n#sand-vault-0721-root .sand-10w94by:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:0}\n#sand-vault-0721-root .sand-1c1dy35:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:10px}\n#sand-vault-0721-root .sand-odjb3w:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:11px}\n#sand-vault-0721-root .sand-1lun4ml:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:1px}\n#sand-vault-0721-root .sand-qm0940:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:.5px}\n#sand-vault-0721-root .sand-v5lvn5:not(#\\#):not(#\\#):not(#\\#){border-inline-start-color:#0000}\n#sand-vault-0721-root .sand-5x6ma4:not(#\\#):not(#\\#):not(#\\#){border-inline-start-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-1t7ytsu:not(#\\#):not(#\\#):not(#\\#){border-inline-start-style:solid}\n#sand-vault-0721-root .sand-14e42zd:not(#\\#):not(#\\#):not(#\\#){border-inline-start-width:0}\n#sand-vault-0721-root .sand-pilrb4:not(#\\#):not(#\\#):not(#\\#){border-inline-start-width:1px}\n#sand-vault-0721-root .sand-1sd92yl:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1p9ssgk:not(#\\#):not(#\\#):not(#\\#){border-inline-start-width:.5px}\n#sand-vault-0721-root .sand-1ga7v0g:not(#\\#):not(#\\#):not(#\\#){border-start-end-radius:0}\n#sand-vault-0721-root .sand-nlwouz:not(#\\#):not(#\\#):not(#\\#){border-start-end-radius:16px}\n#sand-vault-0721-root .sand-15mokao:not(#\\#):not(#\\#):not(#\\#){border-start-start-radius:0}\n#sand-vault-0721-root .sand-bjudin:not(#\\#):not(#\\#):not(#\\#){border-start-start-radius:16px}\n#sand-vault-0721-root .sand-124efjc:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-4bsmwh:not(#\\#):not(#\\#):not(#\\#){box-shadow:0 0 0 1px var(--sand-border-quaternary-translucent),0 2px 8px var(--sand-shadow-card)}\n#sand-vault-0721-root .sand-bwjx97:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 .5px color-mix(in srgb,currentColor 15%,transparent)}\n#sand-vault-0721-root .sand-pmb8bl:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 1px var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-19mzooj:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 .5px var(--sand-border-tertiary-translucent)}\n#sand-vault-0721-root .sand-9f619:not(#\\#):not(#\\#):not(#\\#){box-sizing:border-box}\n#sand-vault-0721-root .sand-1heor9g:not(#\\#):not(#\\#):not(#\\#){color:inherit}\n#sand-vault-0721-root .sand-1e6yr6a:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-primary)}\n#sand-vault-0721-root .sand-101qkwy:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-quaternary)}\n#sand-vault-0721-root .sand-nxsxl2:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-secondary)}\n#sand-vault-0721-root .sand-1gt6tda:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-tertiary)}\n#sand-vault-0721-root .sand-10kc733:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-accent-primary)}\n#sand-vault-0721-root .sand-i69oq4:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-danger-primary)}\n#sand-vault-0721-root .sand-sa7k8x:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-inverted)}\n#sand-vault-0721-root .sand-xcaa6e:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-on-primary)}\n#sand-vault-0721-root .sand-tyxrsu:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-primary)}\n#sand-vault-0721-root .sand-x1phaw:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-quaternary)}\n#sand-vault-0721-root .sand-1o0liin:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-secondary)}\n#sand-vault-0721-root .sand-169k319:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-tertiary)}\n#sand-vault-0721-root .sand-impobl:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-warn-primary)}\n#sand-vault-0721-root .sand-18hwk67:not(#\\#):not(#\\#):not(#\\#){column-gap:20px}\n#sand-vault-0721-root .sand-1qgv0r9:not(#\\#):not(#\\#):not(#\\#){column-gap:24px}\n#sand-vault-0721-root .sand-fex06f:not(#\\#):not(#\\#):not(#\\#){column-gap:8px}\n#sand-vault-0721-root .sand-1pzdu40:not(#\\#):not(#\\#):not(#\\#){column-gap:var(--cursor-spacing-5)}\n#sand-vault-0721-root .sand-1ypdohk:not(#\\#):not(#\\#):not(#\\#){cursor:pointer}\n#sand-vault-0721-root .sand-1ed109x:not(#\\#):not(#\\#):not(#\\#){cursor:text}\n#sand-vault-0721-root .sand-1lliihq:not(#\\#):not(#\\#):not(#\\#){display:block}\n#sand-vault-0721-root .sand-jp7ctv:not(#\\#):not(#\\#):not(#\\#){display:contents}\n#sand-vault-0721-root .sand-78zum5:not(#\\#):not(#\\#):not(#\\#){display:flex}\n#sand-vault-0721-root .sand-rvj5dj:not(#\\#):not(#\\#):not(#\\#){display:grid}\n#sand-vault-0721-root .sand-3nfvp2:not(#\\#):not(#\\#):not(#\\#){display:inline-flex}\n#sand-vault-0721-root .sand-1s85apg:not(#\\#):not(#\\#):not(#\\#){display:none}\n#sand-vault-0721-root .sand-5f5z56:not(#\\#):not(#\\#):not(#\\#){field-sizing:content}\n#sand-vault-0721-root .sand-1r8uery:not(#\\#):not(#\\#):not(#\\#){flex-basis:0}\n#sand-vault-0721-root .sand-1l7klhg:not(#\\#):not(#\\#):not(#\\#){flex-basis:100%}\n#sand-vault-0721-root .sand-dl72j9:not(#\\#):not(#\\#):not(#\\#){flex-basis:auto}\n#sand-vault-0721-root .sand-1fig6rf:not(#\\#):not(#\\#):not(#\\#){flex-basis:max-content}\n#sand-vault-0721-root .sand-1rnznto:not(#\\#):not(#\\#):not(#\\#){flex-basis:min-content}\n#sand-vault-0721-root .sand-dt5ytf:not(#\\#):not(#\\#):not(#\\#){flex-direction:column}\n#sand-vault-0721-root .sand-1c4vz4f:not(#\\#):not(#\\#):not(#\\#){flex-grow:0}\n#sand-vault-0721-root .sand-1iyjqo2:not(#\\#):not(#\\#):not(#\\#){flex-grow:1}\n#sand-vault-0721-root .sand-2lah0s:not(#\\#):not(#\\#):not(#\\#){flex-shrink:0}\n#sand-vault-0721-root .sand-s83m0k:not(#\\#):not(#\\#):not(#\\#){flex-shrink:1}\n#sand-vault-0721-root .sand-1a02dak:not(#\\#):not(#\\#):not(#\\#){flex-wrap:wrap}\n#sand-vault-0721-root .sand-jb2p0i:not(#\\#):not(#\\#):not(#\\#){font-family:inherit}\n#sand-vault-0721-root .sand-1jvydc1:not(#\\#):not(#\\#):not(#\\#){font-size:15px}\n#sand-vault-0721-root .sand-19d36u7:not(#\\#):not(#\\#):not(#\\#){font-size:17px}\n#sand-vault-0721-root .sand-1i1m3gp:not(#\\#):not(#\\#):not(#\\#){font-size:22px}\n#sand-vault-0721-root .sand-1ewwscv:not(#\\#):not(#\\#):not(#\\#){font-size:26px}\n#sand-vault-0721-root .sand-1qlqyl8:not(#\\#):not(#\\#):not(#\\#){font-size:inherit}\n#sand-vault-0721-root .sand-11wthnw:not(#\\#):not(#\\#):not(#\\#){font-size:var(--cursor-font-size-base)}\n#sand-vault-0721-root .sand-fc7y3v:not(#\\#):not(#\\#):not(#\\#){font-size:var(--cursor-font-size-lg)}\n#sand-vault-0721-root .sand-1wm8ruf:not(#\\#):not(#\\#):not(#\\#){font-size:var(--cursor-font-size-sm)}\n#sand-vault-0721-root .sand-y5h43f:not(#\\#):not(#\\#):not(#\\#){font-size:var(--cursor-font-size-xs)}\n#sand-vault-0721-root .sand-1yil2se:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-base)}\n#sand-vault-0721-root .sand-q1hgy8:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-lg)}\n#sand-vault-0721-root .sand-g2dot2:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-sm)}\n#sand-vault-0721-root .sand-79ao00:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xl)}\n#sand-vault-0721-root .sand-1ao5zh4:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xs)}\n#sand-vault-0721-root .sand-1mmermx:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xxl)}\n#sand-vault-0721-root .sand-7uqsge:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xxs)}\n#sand-vault-0721-root .sand-zdi6ij:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xxxl)}\n#sand-vault-0721-root .sand-1s688f:not(#\\#):not(#\\#):not(#\\#){font-weight:600}\n#sand-vault-0721-root .sand-1rhlpx6:not(#\\#):not(#\\#):not(#\\#){font-weight:var(--sand-font-weight-medium)}\n#sand-vault-0721-root .sand-1k6tqyu:not(#\\#):not(#\\#):not(#\\#){font-weight:var(--sand-font-weight-regular)}\n#sand-vault-0721-root .sand-xzm5a7:not(#\\#):not(#\\#):not(#\\#){font-weight:var(--sand-font-weight-semibold)}\n#sand-vault-0721-root .sand-cjjqqt:not(#\\#):not(#\\#):not(#\\#){grid-template-columns:minmax(0,1fr) minmax(0,1fr)}\n#sand-vault-0721-root .sand-1euzuty:not(#\\#):not(#\\#):not(#\\#){inset-inline-end:-6px}\n#sand-vault-0721-root .sand-tijo5x:not(#\\#):not(#\\#):not(#\\#){inset-inline-end:0}\n#sand-vault-0721-root .sand-1ro0b6g:not(#\\#):not(#\\#):not(#\\#){inset-inline-end:3px}\n#sand-vault-0721-root .sand-1o0tod:not(#\\#):not(#\\#):not(#\\#){inset-inline-start:0}\n#sand-vault-0721-root .sand-l56j7k:not(#\\#):not(#\\#):not(#\\#){justify-content:center}\n#sand-vault-0721-root .sand-13a6bvl:not(#\\#):not(#\\#):not(#\\#){justify-content:flex-end}\n#sand-vault-0721-root .sand-1nhvcw1:not(#\\#):not(#\\#):not(#\\#){justify-content:flex-start}\n#sand-vault-0721-root .sand-1qughib:not(#\\#):not(#\\#):not(#\\#){justify-content:space-between}\n#sand-vault-0721-root .sand-4gjf66:not(#\\#):not(#\\#):not(#\\#){letter-spacing:inherit}\n#sand-vault-0721-root .sand-ja3w2a:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-base)}\n#sand-vault-0721-root .sand-99smjr:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-lg)}\n#sand-vault-0721-root .sand-14gdtuo:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-sm)}\n#sand-vault-0721-root .sand-k0i524:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xl)}\n#sand-vault-0721-root .sand-b7p3tu:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xs)}\n#sand-vault-0721-root .sand-1ehaq9d:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xxl)}\n#sand-vault-0721-root .sand-1h1hs02:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xxs)}\n#sand-vault-0721-root .sand-lnf3q9:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xxxl)}\n#sand-vault-0721-root .sand-19v9tvf:not(#\\#):not(#\\#):not(#\\#){line-height:22px}\n#sand-vault-0721-root .sand-15bjb6t:not(#\\#):not(#\\#):not(#\\#){line-height:inherit}\n#sand-vault-0721-root .sand-1ja60sm:not(#\\#):not(#\\#):not(#\\#){line-height:var(--cursor-line-height-base)}\n#sand-vault-0721-root .sand-1yxxptd:not(#\\#):not(#\\#):not(#\\#){line-height:var(--cursor-line-height-lg)}\n#sand-vault-0721-root .sand-spwq11:not(#\\#):not(#\\#):not(#\\#){line-height:var(--cursor-line-height-sm)}\n#sand-vault-0721-root .sand-1lvvshy:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-base)}\n#sand-vault-0721-root .sand-1971ylj:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-lg)}\n#sand-vault-0721-root .sand-w8bs97:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-sm)}\n#sand-vault-0721-root .sand-10ux60h:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xl)}\n#sand-vault-0721-root .sand-10jubzo:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xs)}\n#sand-vault-0721-root .sand-vh7mc1:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xxl)}\n#sand-vault-0721-root .sand-19jnaw5:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xxs)}\n#sand-vault-0721-root .sand-1odv9bt:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xxxl)}\n#sand-vault-0721-root .sand-14z9mp:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:0}\n#sand-vault-0721-root .sand-1p8j9ns:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:3px}\n#sand-vault-0721-root .sand-2fvf9:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:4px}\n#sand-vault-0721-root .sand-1lziwak:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:0}\n#sand-vault-0721-root .sand-vc5jky:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:auto}\n#sand-vault-0721-root .sand-l1xv1r:not(#\\#):not(#\\#):not(#\\#){object-fit:cover}\n#sand-vault-0721-root .sand-p6acfy:not(#\\#):not(#\\#):not(#\\#){opacity:.58}\n#sand-vault-0721-root .sand-g01cxk:not(#\\#):not(#\\#):not(#\\#){opacity:0}\n#sand-vault-0721-root .sand-1hc1fzr:not(#\\#):not(#\\#):not(#\\#){opacity:1}\n#sand-vault-0721-root .sand-1t7ft1p:not(#\\#):not(#\\#):not(#\\#){opacity:var(--sand-anchor-reveal,1)}\n#sand-vault-0721-root .sand-1uczgqu:not(#\\#):not(#\\#):not(#\\#){outline-color:#0000}\n#sand-vault-0721-root .sand-1v39l1b:not(#\\#):not(#\\#):not(#\\#){outline-color:var(--sand-border-focus-primary)}\n#sand-vault-0721-root .sand-1m4v3n6:not(#\\#):not(#\\#):not(#\\#){outline-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-2ssjo2:not(#\\#):not(#\\#):not(#\\#){outline-offset:-2px}\n#sand-vault-0721-root .sand-1wfwxd8:not(#\\#):not(#\\#):not(#\\#){outline-offset:0}\n#sand-vault-0721-root .sand-1y3gkto:not(#\\#):not(#\\#):not(#\\#){outline-offset:1px}\n#sand-vault-0721-root .sand-gwnywf:not(#\\#):not(#\\#):not(#\\#){outline-offset:calc(-1*.5px)}\n#sand-vault-0721-root .sand-1t137rt:not(#\\#):not(#\\#):not(#\\#){outline-style:none}\n#sand-vault-0721-root .sand-aatb59:not(#\\#):not(#\\#):not(#\\#){outline-style:solid}\n#sand-vault-0721-root .sand-1k57tk5:not(#\\#):not(#\\#):not(#\\#){outline-width:0}\n#sand-vault-0721-root .sand-t08umf:not(#\\#):not(#\\#):not(#\\#){outline-width:.5px}\n#sand-vault-0721-root .sand-j0a0fe:not(#\\#):not(#\\#):not(#\\#){overflow-wrap:anywhere}\n#sand-vault-0721-root .sand-1mzt3pk:not(#\\#):not(#\\#):not(#\\#){overflow-wrap:break-word}\n#sand-vault-0721-root .sand-yri2b:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:0}\n#sand-vault-0721-root .sand-2vl965:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:10px}\n#sand-vault-0721-root .sand-pdmqnj:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:12px}\n#sand-vault-0721-root .sand-1hwfens:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:13px}\n#sand-vault-0721-root .sand-1pic42t:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:14px}\n#sand-vault-0721-root .sand-1q3ajuy:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:15px}\n#sand-vault-0721-root .sand-v54qhq:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:16px}\n#sand-vault-0721-root .sand-1ekh9h2:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:17px}\n#sand-vault-0721-root .sand-1x5flf6:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:18px}\n#sand-vault-0721-root .sand-1xnnf8n:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:20px}\n#sand-vault-0721-root .sand-1icxu4v:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:6px}\n#sand-vault-0721-root .sand-1bjonze:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:7px}\n#sand-vault-0721-root .sand-f159sx:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:8px}\n#sand-vault-0721-root .sand-rw5ot4:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:9px}\n#sand-vault-0721-root .sand-1tlft3r:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:var(--cursor-spacing-1)}\n#sand-vault-0721-root .sand-1n9uuka:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:var(--cursor-spacing-3-5)}\n#sand-vault-0721-root .sand-16mtmbo:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:var(--cursor-spacing-4)}\n#sand-vault-0721-root .sand-1bk0ktj:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:var(--cursor-spacing-5)}\n#sand-vault-0721-root .sand-1s169rl:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:32px}\n#sand-vault-0721-root .sand-1c1uobl:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:0}\n#sand-vault-0721-root .sand-e2zdcy:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:10px}\n#sand-vault-0721-root .sand-1g0dm76:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:12px}\n#sand-vault-0721-root .sand-bmws1g:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:13px}\n#sand-vault-0721-root .sand-1gx403c:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:15px}\n#sand-vault-0721-root .sand-f7dkkf:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:16px}\n#sand-vault-0721-root .sand-wn43p0:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:18px}\n#sand-vault-0721-root .sand-106a9eq:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:20px}\n#sand-vault-0721-root .sand-25sj25:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:6px}\n#sand-vault-0721-root .sand-1pixwil:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:7px}\n#sand-vault-0721-root .sand-mzvs34:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:8px}\n#sand-vault-0721-root .sand-7coems:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:9px}\n#sand-vault-0721-root .sand-22095l:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-cssynl:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:var(--cursor-spacing-3-5)}\n#sand-vault-0721-root .sand-92arao:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:var(--cursor-spacing-5)}\n#sand-vault-0721-root .sand-16mx7xq:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:32px}\n#sand-vault-0721-root .sand-67bb7w:not(#\\#):not(#\\#):not(#\\#){pointer-events:auto}\n#sand-vault-0721-root .sand-47corl:not(#\\#):not(#\\#):not(#\\#){pointer-events:none}\n#sand-vault-0721-root .sand-10l6tqk:not(#\\#):not(#\\#):not(#\\#){position:absolute}\n#sand-vault-0721-root .sand-1n2onr6:not(#\\#):not(#\\#):not(#\\#){position:relative}\n#sand-vault-0721-root .sand-tt52l0:not(#\\#):not(#\\#):not(#\\#){resize:none}\n#sand-vault-0721-root .sand-xs79tx:not(#\\#):not(#\\#):not(#\\#){row-gap:0}\n#sand-vault-0721-root .sand-3pnbk8:not(#\\#):not(#\\#):not(#\\#){row-gap:8px}\n#sand-vault-0721-root .sand-7h844e:not(#\\#):not(#\\#):not(#\\#){scrollbar-color:var(--sand-border-tertiary-translucent) transparent}\n#sand-vault-0721-root .sand-1597r2g:not(#\\#):not(#\\#):not(#\\#){scrollbar-width:thin}\n#sand-vault-0721-root .sand-2b8uid:not(#\\#):not(#\\#):not(#\\#){text-align:center}\n#sand-vault-0721-root .sand-p4054r:not(#\\#):not(#\\#):not(#\\#){text-align:end}\n#sand-vault-0721-root .sand-1yc453h:not(#\\#):not(#\\#):not(#\\#){text-align:start}\n#sand-vault-0721-root .sand-krqix3:not(#\\#):not(#\\#):not(#\\#){text-decoration-line:none}\n#sand-vault-0721-root .sand-lyipyv:not(#\\#):not(#\\#):not(#\\#){text-overflow:ellipsis}\n#sand-vault-0721-root .sand-ggy1nq:not(#\\#):not(#\\#):not(#\\#){touch-action:manipulation}\n#sand-vault-0721-root .sand-11lhmoz:not(#\\#):not(#\\#):not(#\\#){transform:translate(-50%,-50%)}\n#sand-vault-0721-root .sand-1kneoy4:not(#\\#):not(#\\#):not(#\\#){transition-duration:.14s}\n#sand-vault-0721-root .sand-1firant:not(#\\#):not(#\\#):not(#\\#){transition-duration:.12s}\n#sand-vault-0721-root .sand-1eaenvl:not(#\\#):not(#\\#):not(#\\#){transition-property:background-color,border-color,color}\n#sand-vault-0721-root .sand-s2xxs2:not(#\\#):not(#\\#):not(#\\#){transition-property:background-color,color}\n#sand-vault-0721-root .sand-15406qy:not(#\\#):not(#\\#):not(#\\#){transition-property:background-color}\n#sand-vault-0721-root .sand-shfolx:not(#\\#):not(#\\#):not(#\\#){transition-property:border-color}\n#sand-vault-0721-root .sand-19991ni:not(#\\#):not(#\\#):not(#\\#){transition-property:opacity}\n#sand-vault-0721-root .sand-xrbq2n:not(#\\#):not(#\\#):not(#\\#){transition-property:width}\n#sand-vault-0721-root .sand-1pbvl4h:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:cubic-bezier(.16,1,.3,1)}\n#sand-vault-0721-root .sand-9lcvmn:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:ease-out}\n#sand-vault-0721-root .sand-wji4o3:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:ease}\n#sand-vault-0721-root .sand-87ps6o:not(#\\#):not(#\\#):not(#\\#){-webkit-user-select:none;user-select:none}\n#sand-vault-0721-root .sand-eaf4i8:not(#\\#):not(#\\#):not(#\\#){white-space:normal}\n#sand-vault-0721-root .sand-uxw1ft:not(#\\#):not(#\\#):not(#\\#){white-space:nowrap}\n#sand-vault-0721-root .sand-126k92a:not(#\\#):not(#\\#):not(#\\#){white-space:pre-wrap}\n#sand-vault-0721-root .sand-1so62im:not(#\\#):not(#\\#):not(#\\#){will-change:transform}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-k2bhp9.sand-k2bhp9:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-r6vvh3.sand-r6vvh3:not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(var(--sand-bg-hover),var(--sand-bg-hover))}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-15c4utq.sand-15c4utq:not(#\\#):not(#\\#):not(#\\#){grid-template-columns:39px 1fr}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-1i7crgf.sand-1i7crgf:not(#\\#):not(#\\#):not(#\\#){opacity:1}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-f65yrc.sand-f65yrc:not(#\\#):not(#\\#):not(#\\#){outline-style:solid}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-1e3w1cx.sand-1e3w1cx:not(#\\#):not(#\\#):not(#\\#){outline-width:2px}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-1as79fp.sand-1as79fp:not(#\\#):not(#\\#):not(#\\#){transition-duration:.15s}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-117rllf.sand-117rllf:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:cubic-bezier(.2,0,0,1)}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-ksnpn0.sand-ksnpn0:not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(var(--sand-bg-hover),var(--sand-bg-hover))}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-18gcsbh.sand-18gcsbh:not(#\\#):not(#\\#):not(#\\#){-webkit-mask-image:linear-gradient(calc(90deg*var(--sand-inline-sign,1)),#000 calc(100% - 22px),transparent calc(100% - 8px));mask-image:linear-gradient(calc(90deg*var(--sand-inline-sign,1)),#000 calc(100% - 22px),transparent calc(100% - 8px))}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-1t642l6.sand-1t642l6:not(#\\#):not(#\\#):not(#\\#){opacity:1}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-1q77ly.sand-1q77ly:not(#\\#):not(#\\#):not(#\\#){transform:translateX(calc(-3px*var(--sand-inline-sign,1))) rotate(calc(-8deg*var(--sand-inline-sign,1)))}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-1rwtdfy.sand-1rwtdfy:not(#\\#):not(#\\#):not(#\\#){transform:translateX(calc(3px*var(--sand-inline-sign,1))) rotate(calc(8deg*var(--sand-inline-sign,1)))}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-1nbbp8h.sand-1nbbp8h:not(#\\#):not(#\\#):not(#\\#){transform:translateY(-1px)}\n#sand-vault-0721-root :where(.sand--default-marker:active) .sand-56zfcv.sand-56zfcv:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-hover)}\n#sand-vault-0721-root :where(.sand--default-marker:active) .sand-s4zcoc.sand-s4zcoc:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-primary)}\n#sand-vault-0721-root :where(.sand--default-marker:hover)~.sand-nzelb4.sand-nzelb4:not(#\\#):not(#\\#):not(#\\#){text-decoration-color:currentColor}\n#sand-vault-0721-root :where(.sand--default-marker.sand-info-pane[data-open]) .sand-xlogw.sand-xlogw:not(#\\#):not(#\\#):not(#\\#){-webkit-app-region:var(--sand-app-region)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-role=user]) .sand-1jy3azn.sand-1jy3azn:not(#\\#):not(#\\#):not(#\\#){align-self:flex-end}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-isi5sn.sand-isi5sn:not(#\\#):not(#\\#):not(#\\#){animation-delay:.38s}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-1n5cfva.sand-1n5cfva:not(#\\#):not(#\\#):not(#\\#){animation-duration:.32s}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-3yt3ym.sand-3yt3ym:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-ononfz.sand-ononfz:not(#\\#):not(#\\#):not(#\\#){animation-duration:.24s}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-1fmekgq.sand-1fmekgq:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-z7gpas.sand-z7gpas:not(#\\#):not(#\\#):not(#\\#){animation-fill-mode:backwards}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-1voxwag.sand-1voxwag:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-1im2lgs-B}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-1rtwpoi.sand-1rtwpoi:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-1rqlz9z-B}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-1ujtcca.sand-1ujtcca:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-aj6w25-B}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-j3mb0h.sand-j3mb0h:not(#\\#):not(#\\#):not(#\\#){animation-timing-function:cubic-bezier(.22,1,.36,1)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter]) .sand-1n1rhdv.sand-1n1rhdv:not(#\\#):not(#\\#):not(#\\#){animation-timing-function:cubic-bezier(.23,1,.32,1)}\n#sand-vault-0721-root .sand-yhpp14:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,var(--sand-bg-red-primary) 88%,black)}\n#sand-vault-0721-root .sand-b937un:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,var(--sand-bg-secondary) 76%,transparent)}\n#sand-vault-0721-root .sand-d5puqa:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,var(--sand-bg-secondary) 86%,transparent)}\n#sand-vault-0721-root .sand-qc45by:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,var(--sand-text-accent-primary) 20%,var(--sand-bg-active))}\n#sand-vault-0721-root .sand-14rb9jf:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1y6hg4:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-d2x0lb.sand-d2x0lb:not(#\\#):not(#\\#):not(#\\#){background-color:#0000}\n#sand-vault-0721-root .sand-1moagsb:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-primary-hover)}\n#sand-vault-0721-root .sand-dkb2vs:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary-hover)}\n#sand-vault-0721-root .sand-17cq1yh:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary)}\n#sand-vault-0721-root .sand-1us2tlb:active:not(:disabled):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-kf9261[data-highlighted]:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-n0wurk:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-active)}\n#sand-vault-0721-root .sand-a9ymcb:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-primary-hover)}\n#sand-vault-0721-root .sand-78epwt:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-secondary-hover)}\n#sand-vault-0721-root .sand-q63dn4:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-secondary)}\n#sand-vault-0721-root .sand-x20oqx:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-hover)}\n#sand-vault-0721-root .sand-1sxibbd:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-primary-hover)}\n#sand-vault-0721-root .sand-19jy9ex:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-hover)}\n#sand-vault-0721-root .sand-18ptgz8:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1ecwv3n:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1gwv8dp:focus-within:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-link-hover-card:focus-visible) .sand-t0g2ea.sand-t0g2ea:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root .sand-6bhftj:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-primary-hover)}\n#sand-vault-0721-root .sand-1ra2h21:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-secondary-hover)}\n#sand-vault-0721-root .sand-1swc454:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-secondary)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-task-thread__resize-handle:hover) .sand-4sg2tf.sand-4sg2tf:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-info-pane__resize-handle:hover) .sand-8pfldw.sand-8pfldw:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-border-primary-translucent)}\n#sand-vault-0721-root .sand-1kb7mvx:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-text-secondary)}\n#sand-vault-0721-root .sand-fxdvfh:active:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(color-mix(in srgb,currentcolor 12%,transparent),color-mix(in srgb,currentcolor 12%,transparent))}\n#sand-vault-0721-root .sand-101ryrv:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:hover:not(:disabled)) .sand-18n118r.sand-18n118r:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[aria-expanded=true]) .sand-w1w4u2.sand-w1w4u2:not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(var(--sand-bg-hover),var(--sand-bg-hover))}\n#sand-vault-0721-root .sand-18xb08s:focus-visible:not(#\\#):not(#\\#):not(#\\#){box-shadow:0 0 0 2px var(--sand-border-focus-primary)}\n#sand-vault-0721-root .sand-1538qzf:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1yfcfk6:focus-visible:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 2px var(--sand-border-focus-primary)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-dw34h5.sand-dw34h5:not(#\\#):not(#\\#):not(#\\#){color:currentColor}\n#sand-vault-0721-root .sand-13hlow9:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-primary)}\n#sand-vault-0721-root .sand-1fx2joi:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1gz2lq6:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-pane-row]:hover:not(:disabled),#sand-vault-0721-root [data-pane-row]:focus-visible)) .sand-vveekh.sand-vveekh:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-tasks-row]:hover,#sand-vault-0721-root [data-tasks-row]:focus-within)) .sand-zjsbb6.sand-zjsbb6:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-primary)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-atx30o.sand-atx30o:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-transcript-bubble-user-text)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1qk24ye.sand-1qk24ye:not(#\\#):not(#\\#):not(#\\#){color:var(--x-1021hmf)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-p4115m.sand-p4115m:not(#\\#):not(#\\#):not(#\\#){display:contents}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-15a73cx.sand-15a73cx:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-vgho8r[hidden]:not(#\\#):not(#\\#):not(#\\#){display:none}\n#sand-vault-0721-root :where(.sand--default-marker.sand-avatar-trigger__button:hover) .sand-1gwej17.sand-1gwej17:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-avatar-trigger__button:focus-visible) .sand-ckqdqq.sand-ckqdqq:not(#\\#):not(#\\#):not(#\\#){filter:brightness(.3)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1q0fwhs.sand-1q0fwhs:not(#\\#):not(#\\#):not(#\\#){font-weight:var(--sand-font-weight-semibold)}\n#sand-vault-0721-root :where(.sand--default-marker[aria-expanded=true]) .sand-834qxt.sand-834qxt:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:hover:not(:disabled)) .sand-rzebgi.sand-rzebgi:not(#\\#):not(#\\#):not(#\\#){grid-template-columns:39px 1fr}\n#sand-vault-0721-root :where(.sand--default-marker[data-standalone-emoji]) .sand-1w1fagr.sand-1w1fagr:not(#\\#):not(#\\#):not(#\\#){line-height:inherit}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-role=user]) .sand-1i19olc.sand-1i19olc:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:6px}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-role=user]) .sand-1fjjgpz.sand-1fjjgpz:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:0}\n#sand-vault-0721-root :where(.sand--default-marker:is([data-pane-row]:hover:not(:disabled),#sand-vault-0721-root [data-pane-row]:focus-visible)) .sand-lm0x5n.sand-lm0x5n:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:8px}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-role=user]) .sand-javwx2.sand-javwx2:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:auto}\n#sand-vault-0721-root :where(.sand--default-marker:has(:focus-visible)) .sand-4gar82.sand-4gar82:not(#\\#):not(#\\#):not(#\\#){-webkit-mask-image:linear-gradient(calc(90deg*var(--sand-inline-sign,1)),#000 calc(100% - 22px),transparent calc(100% - 8px));mask-image:linear-gradient(calc(90deg*var(--sand-inline-sign,1)),#000 calc(100% - 22px),transparent calc(100% - 8px))}\n#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-overflow]) .sand-z1ge0p.sand-z1ge0p:not(#\\#):not(#\\#):not(#\\#){-webkit-mask-image:linear-gradient(to bottom,#000 calc(100% - var(--sand-transcript-prose-line-height)),rgb(0 0 0/calc(1 - var(--sand-voice-memo-transcript-fade,0))) 100%);mask-image:linear-gradient(to bottom,#000 calc(100% - var(--sand-transcript-prose-line-height)),rgb(0 0 0/calc(1 - var(--sand-voice-memo-transcript-fade,0))) 100%)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-o77nbk.sand-o77nbk:not(#\\#):not(#\\#):not(#\\#){object-position:right center}\n#sand-vault-0721-root :where(.sand--default-marker:is([data-compact-cloud-agent]:hover,#sand-vault-0721-root [data-compact-cloud-agent]:focus-within)) .sand-cpvxhc.sand-cpvxhc:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-agent-thread-row-item]:hover,#sand-vault-0721-root [data-agent-thread-row-item]:has(:focus-visible))) .sand-hahzd8.sand-hahzd8:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-tasks-row]:hover,#sand-vault-0721-root [data-tasks-row]:focus-within)) .sand-ny05h.sand-ny05h:not(#\\#):not(#\\#):not(#\\#){opacity:0}\n#sand-vault-0721-root :where(.sand--default-marker.sand-agent-character__shape:focus-visible) .sand-15stfbk.sand-15stfbk:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-prompt-attachment:hover) .sand-18w85s.sand-18w85s:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1euntei:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-attachment-card]:hover,#sand-vault-0721-root [data-attachment-card]:focus-within)) .sand-1oayfmu.sand-1oayfmu:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-compact-cloud-agent]:hover,#sand-vault-0721-root [data-compact-cloud-agent]:focus-within)) .sand-1rgc5la.sand-1rgc5la:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is(.sand-group-member-row:hover,#sand-vault-0721-root .sand-group-member-row:focus-within)) .sand-1t2gufm.sand-1t2gufm:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-avatar-trigger__button:focus-visible) .sand-1v0snhv.sand-1v0snhv:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-pane-row-item]:hover,#sand-vault-0721-root [data-pane-row-item]:focus-within,#sand-vault-0721-root [data-pane-row-item]:has([aria-expanded=true]))) .sand-1wdpxdw.sand-1wdpxdw:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-agent-character__shape:hover) .sand-1x4ln44.sand-1x4ln44:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-agent-thread-head]:hover) .sand-1z2u0p.sand-1z2u0p:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-25t5g8:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-attachment-chip:hover) .sand-2s7snv.sand-2s7snv:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-tasks-row]:hover,#sand-vault-0721-root [data-tasks-row]:focus-within)) .sand-45ccpa.sand-45ccpa:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is(.sand-message-action-anchor:hover,#sand-vault-0721-root .sand-message-action-anchor:focus-visible,#sand-vault-0721-root .sand-message-action-anchor:has(:focus-visible),#sand-vault-0721-root .sand-message-action-anchor--menu-open,#sand-vault-0721-root .sand-message-action-anchor--keyboard):not([data-peeking] *)) .sand-ntvexo.sand-ntvexo:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-avatar-trigger__button:hover) .sand-qcwuys.sand-qcwuys:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-pane-row]:hover:not(:disabled),#sand-vault-0721-root [data-pane-row]:focus-visible)) .sand-wjyk70.sand-wjyk70:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-agent-thread-row-item]:hover,#sand-vault-0721-root [data-agent-thread-row-item]:has(:focus-visible))) .sand-xqvrja.sand-xqvrja:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-scrolled]) .sand-zaon2q.sand-zaon2q:not(#\\#):not(#\\#):not(#\\#){opacity:1}\n#sand-vault-0721-root .sand-1wpm9rq:focus-visible:not(#\\#):not(#\\#):not(#\\#){outline-color:var(--sand-border-focus-primary)}\n#sand-vault-0721-root .sand-7s97pk:focus-visible:not(#\\#):not(#\\#):not(#\\#){outline-offset:2px}\n#sand-vault-0721-root .sand-i5y0ii:focus-visible:not(#\\#):not(#\\#):not(#\\#){outline-style:none}\n#sand-vault-0721-root .sand-14xc8xn:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-54jfk2[data-keyboard-focus]:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-9v5kkp:focus-visible:not(#\\#):not(#\\#):not(#\\#){outline-style:solid}\n#sand-vault-0721-root .sand-16gxa91:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-784prv:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-yqzfj1[data-keyboard-focus]:focus-within:not(#\\#):not(#\\#):not(#\\#){outline-width:2px}\n#sand-vault-0721-root :where(.sand--default-marker:is([data-pane-row-item]:hover,#sand-vault-0721-root [data-pane-row-item]:focus-within,#sand-vault-0721-root [data-pane-row-item]:has([aria-expanded=true]))) .sand-1dyflec.sand-1dyflec:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:4px}\n#sand-vault-0721-root :where(.sand--default-marker:is(.sand-group-member-row:hover,#sand-vault-0721-root .sand-group-member-row:focus-within)) .sand-n1kj2s.sand-n1kj2s:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:76px}\n#sand-vault-0721-root :where(.sand--default-marker:is([data-tasks-row]:hover,#sand-vault-0721-root [data-tasks-row]:focus-within)) .sand-14yuvbd.sand-14yuvbd:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-compact-cloud-agent]:hover,#sand-vault-0721-root [data-compact-cloud-agent]:focus-within)) .sand-hi8cnw.sand-hi8cnw:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-agent-thread-row-item]:hover,#sand-vault-0721-root [data-agent-thread-row-item]:has(:focus-visible))) .sand-pptth6.sand-pptth6:not(#\\#):not(#\\#):not(#\\#){pointer-events:auto}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-1b582rm.sand-1b582rm:not(#\\#):not(#\\#):not(#\\#){pointer-events:none}\n#sand-vault-0721-root :where(.sand--default-marker[data-team-copy-created-name]:focus-visible) .sand-10m7oug.sand-10m7oug:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1f2jko9:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1xmi0w3.sand-1xmi0w3:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-team-copy-created-name]:hover) .sand-7b4gmp.sand-7b4gmp:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-pr-link]:hover) .sand-9n5ks.sand-9n5ks:not(#\\#):not(#\\#):not(#\\#){text-decoration-line:underline}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-1l77jpu.sand-1l77jpu:not(#\\#):not(#\\#):not(#\\#){transform-origin:calc(50% - 50%*var(--sand-inline-sign,1)) 100%}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-b3owv9.sand-b3owv9:not(#\\#):not(#\\#):not(#\\#){transform:translate3d(calc(-1*var(--sand-inline-sign,1) *var(--sand-ts-peek,0px)),0,0)}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-1i0kmyb.sand-1i0kmyb:not(#\\#):not(#\\#):not(#\\#){transform:translate3d(calc((1 - var(--sand-ts-progress,0)) * 100%*var(--sand-inline-sign,1)),0,0)}\n#sand-vault-0721-root :where(.sand--default-marker[aria-expanded=true]) .sand-1gvf1b.sand-1gvf1b:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:hover:not(:disabled)) .sand-s4fs6f.sand-s4fs6f:not(#\\#):not(#\\#):not(#\\#){transition-duration:.15s}\n#sand-vault-0721-root :where(.sand--default-marker[aria-expanded=true]) .sand-9rhndf.sand-9rhndf:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:hover:not(:disabled)) .sand-pzvu2h.sand-pzvu2h:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:cubic-bezier(.2,0,0,1)}\n#sand-vault-0721-root :where(.sand--default-marker:is(.sand-message-action-anchor:hover,#sand-vault-0721-root .sand-message-action-anchor:focus-visible,#sand-vault-0721-root .sand-message-action-anchor:has(:focus-visible),#sand-vault-0721-root .sand-message-action-anchor--menu-open,#sand-vault-0721-root .sand-message-action-anchor--keyboard):not([data-peeking] *)) .sand-fqa2nz.sand-fqa2nz:not(#\\#):not(#\\#):not(#\\#){visibility:visible}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-ba0exv.sand-ba0exv:not(#\\#):not(#\\#):not(#\\#){will-change:transform,opacity}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-euoelj.sand-euoelj:not(#\\#):not(#\\#):not(#\\#){will-change:transform}\n#sand-vault-0721-root .sand-1plbdn1:has(>div:empty):not(#\\#):not(#\\#):not(#\\#){display:none}\n#sand-vault-0721-root .sand-dim822:first-child:not(#\\#):not(#\\#):not(#\\#){border-start-end-radius:16px}\n#sand-vault-0721-root .sand-1xucafu:first-child:not(#\\#):not(#\\#):not(#\\#){border-start-end-radius:7.5px}\n#sand-vault-0721-root .sand-cs8yzb:first-child:not(#\\#):not(#\\#):not(#\\#){border-start-start-radius:16px}\n#sand-vault-0721-root .sand-1snnzrc:first-child:not(#\\#):not(#\\#):not(#\\#){border-start-start-radius:7.5px}\n#sand-vault-0721-root .sand-1g55tsu:last-child:not(#\\#):not(#\\#):not(#\\#){border-end-end-radius:16px}\n#sand-vault-0721-root .sand-1kkz68i:last-child:not(#\\#):not(#\\#):not(#\\#){border-end-end-radius:7.5px}\n#sand-vault-0721-root .sand-1sefpy4:last-child:not(#\\#):not(#\\#):not(#\\#){border-end-start-radius:16px}\n#sand-vault-0721-root .sand-pqz701:last-child:not(#\\#):not(#\\#):not(#\\#){border-end-start-radius:7.5px}\n#sand-vault-0721-root .sand-1oqui1x:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:#0000}\n#sand-vault-0721-root .sand-jhkic0:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-primary-disabled)}\n#sand-vault-0721-root .sand-15igvbc:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary-disabled)}\n#sand-vault-0721-root .sand-bmovrx:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-primary-disabled)}\n#sand-vault-0721-root .sand-rf7kli:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-secondary-disabled)}\n#sand-vault-0721-root .sand-1ialtwx:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-primary-disabled)}\n#sand-vault-0721-root .sand-1g6zli8:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-disabled)}\n#sand-vault-0721-root .sand-1a0yh0o:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-primary-disabled)}\n#sand-vault-0721-root .sand-a3pd6v:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-secondary-disabled)}\n#sand-vault-0721-root .sand-usva8a:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-accent-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-b5j4bo:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-accent-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-5zuve2:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-danger-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-11zc032:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-danger-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-1q1osl5:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-on-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-23x1m:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-on-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-g7klql:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-1xejm7d:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-1dim673:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-warn-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-1pdghxg:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-warn-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-xcn2h6:disabled:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-quaternary)}\n#sand-vault-0721-root .sand-zn6dba:disabled:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-quaternary)}\n#sand-vault-0721-root .sand-1tqez8e:disabled:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-secondary)}\n#sand-vault-0721-root .sand-1dl01wj:disabled:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-warn-primary)}\n#sand-vault-0721-root .sand-tgyt42:disabled:not(#\\#):not(#\\#):not(#\\#){cursor:default}\n#sand-vault-0721-root .sand-1s07b3s:disabled:not(#\\#):not(#\\#):not(#\\#){cursor:not-allowed}\n#sand-vault-0721-root .sand-uhm2yv:disabled:not(#\\#):not(#\\#):not(#\\#){opacity:.56}\n#sand-vault-0721-root .sand-aqnwrm:disabled:not(#\\#):not(#\\#):not(#\\#){pointer-events:none}\n#sand-vault-0721-root .sand-1sygd3j:hover:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-hover)}\n#sand-vault-0721-root .sand-11hyl0l:hover:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root .sand-n4ifyr:hover:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-primary)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1bo111n.sand-1bo111n:hover:not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,currentColor 20%,transparent)}\n#sand-vault-0721-root .sand-1t4e3jf:active:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-hover)}\n#sand-vault-0721-root .sand-1uodt95:active:not(#\\#):not(#\\#):not(#\\#){transition-duration:0s}\n@media (prefers-reduced-motion:reduce){#sand-vault-0721-root .sand-1aquc0h.sand-1aquc0h:not(#\\#):not(#\\#):not(#\\#){animation-name:none}}\n@media (prefers-reduced-motion:reduce){#sand-vault-0721-root .sand-11gebw9.sand-11gebw9:not(#\\#):not(#\\#):not(#\\#){opacity:.7}}\n@media (prefers-reduced-motion:reduce){#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-ahcu8d.sand-ahcu8d.sand-ahcu8d:not(#\\#):not(#\\#):not(#\\#){animation-delay:0s}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-aj85ph.sand-aj85ph.sand-aj85ph:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-jfxk63.sand-jfxk63.sand-jfxk63:not(#\\#):not(#\\#):not(#\\#){animation-duration:.12s}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-1q9hv78.sand-1q9hv78.sand-1q9hv78:not(#\\#):not(#\\#):not(#\\#){animation-name:none}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-1u7bc6y.sand-1u7bc6y.sand-1u7bc6y:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-xnp86f.sand-xnp86f.sand-xnp86f:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-18re5ia-B}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-t2y1co.sand-t2y1co.sand-t2y1co:not(#\\#):not(#\\#):not(#\\#){animation-timing-function:ease-out}}\n@media (hover:hover) and (pointer:fine){#sand-vault-0721-root :where(.sand--default-marker.sand-mermaid-figure:hover) .sand-11cn5f1.sand-11cn5f1.sand-11cn5f1:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1yas17b.sand-1yas17b:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-code-figure:hover) .sand-o8ljoj.sand-o8ljoj.sand-o8ljoj:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-visualization-frame-box:hover) .sand-ux0r15.sand-ux0r15.sand-ux0r15:not(#\\#):not(#\\#):not(#\\#){opacity:1}}\n#sand-vault-0721-root .sand-16stqrj:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-color:#0000}\n#sand-vault-0721-root .sand-1vu50b0:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-1q0q8m5:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-style:solid}\n#sand-vault-0721-root .sand-1co6499:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-width:.5px}\n#sand-vault-0721-root .sand-1qhh985:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-width:0}\n#sand-vault-0721-root .sand-so031l:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-width:1px}\n#sand-vault-0721-root .sand-1hkp6id:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-width:.5px}\n#sand-vault-0721-root .sand-9rovbz:not(#\\#):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1b4hy2t:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-color:currentColor}\n#sand-vault-0721-root .sand-1v8p93f:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-color:#0000}\n#sand-vault-0721-root .sand-13nz628:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-1gjmp7u:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-color:var(--sand-text-secondary)}\n#sand-vault-0721-root .sand-13fuv20:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-style:solid}\n#sand-vault-0721-root .sand-t8cgyo:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:.5px}\n#sand-vault-0721-root .sand-972fbf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:0}\n#sand-vault-0721-root .sand-178xt8z:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:1px}\n#sand-vault-0721-root .sand-1hc762m:not(#\\#):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-ugqeb2:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:.5px}\n#sand-vault-0721-root .sand-1ey2m1c:not(#\\#):not(#\\#):not(#\\#):not(#\\#){bottom:0}\n#sand-vault-0721-root .sand-28ko6u:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:.5px}\n#sand-vault-0721-root .sand-qtp20y:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:0}\n#sand-vault-0721-root .sand-5yr21d:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:100%}\n#sand-vault-0721-root .sand-1v9usgg:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:14px}\n#sand-vault-0721-root .sand-lup9mm:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:16px}\n#sand-vault-0721-root .sand-mix8c7:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:18px}\n#sand-vault-0721-root .sand-1qx5ct2:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:20px}\n#sand-vault-0721-root .sand-17rw0jw:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:22px}\n#sand-vault-0721-root .sand-xk0z11:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:24px}\n#sand-vault-0721-root .sand-d7y6wv:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:26px}\n#sand-vault-0721-root .sand-1fgtraw:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:28px}\n#sand-vault-0721-root .sand-1gnnpzl:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:30px}\n#sand-vault-0721-root .sand-10w6t97:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:32px}\n#sand-vault-0721-root .sand-90ne7k:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:34px}\n#sand-vault-0721-root .sand-16wdlz0:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:38px}\n#sand-vault-0721-root .sand-n3w4p2:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:44px}\n#sand-vault-0721-root .sand-ng8ra:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:60px}\n#sand-vault-0721-root .sand-ols6we:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:6px}\n#sand-vault-0721-root .sand-t7dq6l:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:auto}\n#sand-vault-0721-root .sand-t8t6p:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:var(--cursor-spacing-8)}\n#sand-vault-0721-root .sand-at24cr:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-bottom:0}\n#sand-vault-0721-root .sand-1kgmq87:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:-2px}\n#sand-vault-0721-root .sand-dj266r:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:0}\n#sand-vault-0721-root .sand-r9ek0c:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:2px}\n#sand-vault-0721-root .sand-sejjyr:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:calc(var(--cursor-spacing-1-5) - var(--cursor-spacing-2))}\n#sand-vault-0721-root .sand-q3t0pi:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-height:280px}\n#sand-vault-0721-root .sand-qyufaf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-height:calc(100vh - 2*max(16px,var(--sand-window-controls-block,0px)))}\n#sand-vault-0721-root .sand-193iq5w:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-width:100%}\n#sand-vault-0721-root .sand-1y8h3ww:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-width:45%}\n#sand-vault-0721-root .sand-1t8xbu:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-width:max-content}\n#sand-vault-0721-root .sand-2lwn1j:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:0}\n#sand-vault-0721-root .sand-21xpn4:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:32px}\n#sand-vault-0721-root .sand-phwom3:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:var(--cursor-spacing-8)}\n#sand-vault-0721-root .sand-euugli:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-width:0}\n#sand-vault-0721-root .sand-nei2rj:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-width:24px}\n#sand-vault-0721-root .sand-ma39wp:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-width:var(--cursor-spacing-8)}\n#sand-vault-0721-root .sand-1plvlek:not(#\\#):not(#\\#):not(#\\#):not(#\\#){overflow-x:visible}\n#sand-vault-0721-root .sand-1odjw0f:not(#\\#):not(#\\#):not(#\\#):not(#\\#){overflow-y:auto}\n#sand-vault-0721-root .sand-10wlt62:not(#\\#):not(#\\#):not(#\\#):not(#\\#){overflow-y:hidden}\n#sand-vault-0721-root .sand-ryxfnj:not(#\\#):not(#\\#):not(#\\#):not(#\\#){overflow-y:visible}\n#sand-vault-0721-root .sand-18d9i69:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:0}\n#sand-vault-0721-root .sand-sag5q8:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:12px}\n#sand-vault-0721-root .sand-1g2khh7:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:14px}\n#sand-vault-0721-root .sand-1l90r2v:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:16px}\n#sand-vault-0721-root .sand-1j85h84:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:1px}\n#sand-vault-0721-root .sand-84yb8i:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:28px}\n#sand-vault-0721-root .sand-jkvuk6:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:4px}\n#sand-vault-0721-root .sand-s9asl8:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:5px}\n#sand-vault-0721-root .sand-10b6aqq:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:6px}\n#sand-vault-0721-root .sand-1ykpatu:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:7px}\n#sand-vault-0721-root .sand-wib8y2:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:8px}\n#sand-vault-0721-root .sand-2lprc:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-1xlntvz:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-exx8yu:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:0}\n#sand-vault-0721-root .sand-889kno:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:10px}\n#sand-vault-0721-root .sand-z9dl7a:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:12px}\n#sand-vault-0721-root .sand-yinxu5:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:14px}\n#sand-vault-0721-root .sand-yamay9:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:16px}\n#sand-vault-0721-root .sand-4p5aij:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:1px}\n#sand-vault-0721-root .sand-1xy6bms:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:22px}\n#sand-vault-0721-root .sand-1nn3v0j:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:2px}\n#sand-vault-0721-root .sand-yqdw3p:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:3px}\n#sand-vault-0721-root .sand-1iorvi4:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:4px}\n#sand-vault-0721-root .sand-123j3cw:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:5px}\n#sand-vault-0721-root .sand-1yrsyyn:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:6px}\n#sand-vault-0721-root .sand-m7lytj:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:7px}\n#sand-vault-0721-root .sand-1y1aw1k:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:8px}\n#sand-vault-0721-root .sand-oyc9vk:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-13ly8rp:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-tu2xtp:not(#\\#):not(#\\#):not(#\\#):not(#\\#){top:-6px}\n#sand-vault-0721-root .sand-13vifvy:not(#\\#):not(#\\#):not(#\\#):not(#\\#){top:0}\n#sand-vault-0721-root .sand-xk6nc9:not(#\\#):not(#\\#):not(#\\#):not(#\\#){top:3px}\n#sand-vault-0721-root .sand-197jcof:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:.5px}\n#sand-vault-0721-root .sand-h8yej3:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:100%}\n#sand-vault-0721-root .sand-6jxa94:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:14px}\n#sand-vault-0721-root .sand-1kky2od:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:16px}\n#sand-vault-0721-root .sand-1xp8n7a:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:18px}\n#sand-vault-0721-root .sand-w4jnvo:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:20px}\n#sand-vault-0721-root .sand-17z2i9w:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:22px}\n#sand-vault-0721-root .sand-vy4d1p:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:24px}\n#sand-vault-0721-root .sand-gd8bvy:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:28px}\n#sand-vault-0721-root .sand-187nhsf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:44px}\n#sand-vault-0721-root .sand-1v4s8kt:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:6px}\n#sand-vault-0721-root .sand-13oubkp:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:96px}\n#sand-vault-0721-root .sand-1dxpara:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(320px,100vw - 32px)}\n#sand-vault-0721-root .sand-1ove4c:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(360px,100vw - 32px)}\n#sand-vault-0721-root .sand-11f3qql:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(380px,100vw - 32px)}\n#sand-vault-0721-root .sand-btpsn6:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(400px,100vw - 32px)}\n#sand-vault-0721-root .sand-8xl5fk:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(420px,100vw - 32px)}\n#sand-vault-0721-root .sand-glnbif:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(432px,100vw - 32px)}\n#sand-vault-0721-root .sand-cyy4kf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(440px,100vw - 32px)}\n#sand-vault-0721-root .sand-jbg27m:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(460px,100vw - 32px)}\n#sand-vault-0721-root .sand-sjcku0:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(480px,100vw - 32px)}\n#sand-vault-0721-root .sand-mk5fll:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(500px,100vw - 32px)}\n#sand-vault-0721-root .sand-v9tjks:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(520px,100vw - 32px)}\n#sand-vault-0721-root .sand-1xakwtq:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(529px,100vw - 32px)}\n#sand-vault-0721-root .sand-pf5iwd:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(608px,100vw - 32px)}\n#sand-vault-0721-root .sand-mjrt60:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:var(--cursor-spacing-8)}\n#sand-vault-0721-root .sand-5lhr3w:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:var(--x-width)}\n#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-overflow]) .sand-1aecepv.sand-1aecepv:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-bottom:0}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-has-reply]) .sand-1sl1sun.sand-1sl1sun:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:0}\n#sand-vault-0721-root :where(.sand--default-marker:is([data-pane-row]:hover:not(:disabled),#sand-vault-0721-root [data-pane-row]:focus-visible)) .sand-1fmn0os.sand-1fmn0os:not(#\\#):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-pane-row-item]:hover,#sand-vault-0721-root [data-pane-row-item]:focus-within,#sand-vault-0721-root [data-pane-row-item]:has([aria-expanded=true]))) .sand-1nbyhg0.sand-1nbyhg0:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-width:none}\n#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-overflow]) .sand-1k0tb1a.sand-1k0tb1a:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:8.25px}\n#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-overflow]) .sand-ki8jp5.sand-ki8jp5:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:8px}\n#sand-vault-0721-root .sand-1g31smg:first-child:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:0}\n#sand-vault-0721-root .sand-170u2dc:last-child:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:16px}\n#sand-vault-0721-root .sand-9xsh1y:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar-thumb{border-radius:var(--cursor-radius-full)}\n#sand-vault-0721-root .sand-122zoth:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar-track{background-color:#0000}\n#sand-vault-0721-root .sand-1htvni2:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar-thumb{background-color:var(--sand-border-tertiary-translucent)}\n#sand-vault-0721-root .sand-1gvdfu:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::placeholder,#sand-vault-0721-root .sand-1uevlnz:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{color:var(--sand-text-quaternary)}\n#sand-vault-0721-root .sand-1h7ufjq:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::placeholder{color:var(--sand-text-tertiary)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-highlighted]) .sand-8vq1ef.sand-8vq1ef:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{animation-name:sand-zzcn73-B}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-highlighted]) .sand-17i7h53.sand-17i7h53:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{content:\"\"}\n#sand-vault-0721-root .sand-1gb0fpc:hover:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar-thumb{background-color:var(--sand-border-secondary-translucent)}\n@media (prefers-reduced-motion:reduce){#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-highlighted]) .sand-1m7bgnx.sand-1m7bgnx.sand-1m7bgnx:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{animation-name:none}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-highlighted]) .sand-1nzs1mw.sand-1nzs1mw.sand-1nzs1mw:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{box-shadow:0 0 0 3px var(--sand-text-primary)}}\n#sand-vault-0721-root .sand-y2251v:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar{width:6px}\n#sand-vault-0721-root .sand-anchor-flash{border-radius:6px;animation:1.6s ease-out sand-anchor-flash}\n@keyframes sand-zzcn73-B{0%{box-shadow:0 0 0 0 var(--sand-text-primary)}8%{box-shadow:0 0 0 3px var(--sand-text-primary)}40%{box-shadow:0 0 0 3px var(--sand-text-primary)}to{box-shadow:0 0 0 3px #0000}}\n@keyframes sand-18re5ia-B{0%{opacity:0}to{opacity:1}}\n@keyframes sand-aj6w25-B{0%{opacity:0;transform:scale(.985)}to{opacity:1;transform:scale(1)}}\n@keyframes sand-1im2lgs-B{0%{opacity:0;transform:translateY(12px)scale(.94)}55%{opacity:1}to{opacity:1;transform:translateY(0)scale(1)}}\n@keyframes sand-1wc8ddo-B{0%{transform:rotate(0)}to{transform:rotate(360deg)}}\n@keyframes sand-1rqlz9z-B{0%{transform:translateY(12px)}to{transform:translateY(0)}}\n@keyframes sand-anchor-flash{0%,60%{background-color:color-mix(in srgb, var(--sand-bg-primary) 12%, transparent)}to{background-color:#0000}}";// ../../../../../private/dist/renderer/assets/chunk-rolldown-runtime-C0FnF6B9.js +// Generated by scripts/lib/vault-renderer-patch.mjs from the pinned Grok Bot 0.75.5 ASAR. Do not edit.// provenance={"upstream":{"version":"0.75.5","asarSha256":"12bba50ba6cf12b35132518788610677a3fdc65de4ad849628d757bc7b780e5a"},"modules":[{"path":"dist/renderer/assets/sand-vault-0721-entry.js","inputSha256":"eb50e776492898503f93201daa96f1b16c964fad51828afe0aa3231c94d85e07","exports":["default","createUpstreamVaultStore","createUpstreamVaultLinguiProvider","createUpstreamVaultPaneHeaderProvider"]},{"path":"dist/renderer/assets/chunk-view-CuYU9NOh.js","inputSha256":"93ab1ad53799b9824dec1e39aa25571aaa2d126992e98daa81cdf62434d2a294","exports":["sandVaultSettings"]},{"path":"dist/renderer/assets/index.eager-app-uZS5Ltig.js","inputSha256":"ba537692e9f60e12fa943432d05462dbfd4266cdac207776e45b2e69610f8833","exports":["sandVaultCreateStore","$y","AC","Aw","Bp","Ch","Gm","LD","Oh","Op","Rw","Uh","Wh","Xy","Zy","am","bp","dT","eb","hT","hh","ib","mh","ob","oh","pm","sb","so","tT","tb","th","vh","xh","Hh","Eh","ah","dh","fh","lh","uh","Mh","Gh","Cw","Mt","PE","Qp","Qy","ab","fx","ig","nh","oi","qw","rb"]},{"path":"dist/renderer/assets/index.eager-vendor-CRCbzhle.js","inputSha256":"ce4fcea348fd7f7a092bf824ddd8cfffa9fa0df3ae0cb4d13fd20364e89e2d36","exports":["et","S","gi","nt","tt","Wr","Ar","Bn","Bt","Fn","Ft","Gn","Hn","In","Ir","It","Jn","Kn","Ln","Lt","Mn","Mr","Nn","Nr","Pn","Qn","Rn","Rt","Un","Vn","Wn","Xn","Yn","Zn","_t","bt","dn","er","gr","gt","ht","jn","jr","jt","li","mi","mt","qn","un","vr","vt","yt","zn","zt","at","ct","dt","ft","ir","it","lt","ot","pt","rt","st","ut"]},{"path":"dist/renderer/assets/chunk-pane-header-BbJph3XZ.js","inputSha256":"e0a74933e3d3225ff27a3b37613f30487854c6f27b7b636d2d73656539e520d0","exports":["r","n"]},{"path":"dist/renderer/assets/chunk-rolldown-runtime-C0FnF6B9.js","inputSha256":"5104c10defb495ce4143cdbf03d5372abb331fb26360b8986f94b2016aeb5abd","exports":["o","t"]},{"path":"dist/renderer/assets/index.eager-platform-CVpWlQMj.js","inputSha256":"bcf50711d1d14f57b3fdb5def4d8704afc99212d4ff76fcdbd4668de9b580a91","exports":["Rt","sr","ur","$n","Ei","Oi","Pi","ii","or","wr","Lt","zt","Zn"]},{"path":"dist/renderer/assets/index.eager-common-F4Y1-gMW.js","inputSha256":"20bc557b8520050e7821cf707df1223033ba7c49ad63af706060b21c50206622","exports":["At","Z","jt","Et","Ut","Wt","nn"]},{"path":"dist/renderer/assets/chunk-card-field-CcWQrzle.js","inputSha256":"a4a132013659bb081bc2897ad89d14e6efb2698b58050f5954595b8cf4fddec3","exports":["i","n","o","r","t"]},{"path":"dist/renderer/assets/chunk-card-dialog-DCU9ThAn.js","inputSha256":"fab6559e25150151c082f1a6ffb52e08d58a2cf6bd40a900f6e84b80840676fc","exports":["t"]},{"path":"dist/renderer/assets/chunk-focus-rjDPGrRu.js","inputSha256":"93175e937f0981ea4adc5339559428ddb36b326133c4d3c978853950598e33fb","exports":["t"]},{"path":"dist/renderer/assets/chunk-scroll-pane-BRAIVu6E.js","inputSha256":"83bb79208cde933c8dcbaed573a03672a7b560b3006723a28fe6b2a7fd49568b","exports":["t"]},{"path":"dist/renderer/assets/chunk-vault-card-dialog-C8ioyi_k.js","inputSha256":"65d7d5cc57783168fe75f35b833c58900e1797505f0da7bc215d4743abb915cf","exports":["y","_","b","d","f","g","h","m","n","p","t","v"]},{"path":"dist/renderer/assets/chunk-vault-card-editor-D3knAB0V.js","inputSha256":"95bb9ed348f961639c0ff179450516bd0e2f8ff19212e4cb9f6bbd728af319a9","exports":["t"]},{"path":"dist/renderer/assets/chunk-csv-parse-C5LpQq5n.js","inputSha256":"15f0692ae6d5886fe37e9c0306841efe0e5523d6c6f590e9d12f02246e8f1f55","exports":["r"]}],"styleSha256":"978318b17434209554900893d505642a2dcb6d0117ae4648811c830c66e92ca8"}export const upstreamVaultStyle = "#sand-vault-0721-root .sand-a1rxjy{--cursor-bg-quaternary:var(--sand-bg-hover)}\n#sand-vault-0721-root .sand-1dbjpva{--cursor-bg-tertiary:var(--sand-bg-active)}\n#sand-vault-0721-root .sand-u366gq{--sand-status-dot-ring:var(--sand-bg-elevated)}\n#sand-vault-0721-root .sand-1fy7lmn{--ui-button-fg:var(--sand-text-primary)}\n#sand-vault-0721-root .sand-1pdmulj{--ui-menu-divider-color:var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-mm16iu{--ui-menu-divider-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-vw6kie{--ui-menu-divider-margin-block:4px}\n#sand-vault-0721-root .sand-rwcruc{--ui-menu-divider-margin-block:var(--cursor-spacing-1-5)}\n#sand-vault-0721-root .sand-y691vg{--ui-menu-divider-margin-block:var(--cursor-spacing-1)}\n#sand-vault-0721-root .sand-1p7q8zp{--ui-menu-divider-margin-inline:8px}\n#sand-vault-0721-root .sand-hvey4x{--ui-menu-divider-margin-inline:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-15f9hzj{--ui-menu-divider-margin-inline:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-1g4rvgt{--ui-menu-divider-width:.5px}\n#sand-vault-0721-root .sand-i28r7m{--ui-menu-inner-padding:6px}\n#sand-vault-0721-root .sand-1xv2y21{--ui-menu-inner-padding:var(--cursor-spacing-1-25)}\n#sand-vault-0721-root .sand-1xcwj57{--ui-menu-item-left-color:var(--sand-icon-secondary)}\n#sand-vault-0721-root .sand-1eaezr9{--ui-menu-item-left-height:16px}\n#sand-vault-0721-root .sand-4qng09{--ui-menu-item-left-height:18px}\n#sand-vault-0721-root .sand-2h970l{--ui-menu-item-left-width:16px}\n#sand-vault-0721-root .sand-hsgrze{--ui-menu-item-left-width:18px}\n#sand-vault-0721-root .sand-ugvh3{--ui-menu-list-gap:0px}\n#sand-vault-0721-root .sand-148pmdb{--ui-menu-list-gap:2px}\n#sand-vault-0721-root .sand-8ej7fl{--ui-menu-row-border-radius:var(--cursor-radius-lg)}\n#sand-vault-0721-root .sand-k5wqll{--ui-menu-row-border-radius:var(--sand-menu-row-radius)}\n#sand-vault-0721-root .sand-vzyzmz{--ui-menu-row-gap:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-1bm360g{--ui-menu-row-gap:var(--sand-menu-row-gap)}\n#sand-vault-0721-root .sand-1g4bt0a{--ui-menu-row-highlight-inset:0px}\n#sand-vault-0721-root .sand-3caj2g{--ui-menu-row-highlight-inset:6px}\n#sand-vault-0721-root .sand-inrsdt{--ui-menu-row-min-height:calc(var(--sand-line-height-sm) + 2*var(--cursor-spacing-0-5))}\n#sand-vault-0721-root .sand-199j77g{--ui-menu-row-min-height:calc(var(--sand-menu-line-height) + 2*var(--cursor-spacing-1-75))}\n#sand-vault-0721-root .sand-1icjr8n{--ui-menu-row-min-height:var(--sand-menu-row-height)}\n#sand-vault-0721-root .sand-fxzh7t{--ui-menu-row-padding-block:calc((var(--sand-menu-row-height) - var(--sand-menu-line-height)) / 2)}\n#sand-vault-0721-root .sand-19lclay{--ui-menu-row-padding-block:var(--cursor-spacing-0-5)}\n#sand-vault-0721-root .sand-5b0lb{--ui-menu-row-padding-block:var(--cursor-spacing-1-75)}\n#sand-vault-0721-root .sand-1y4gx8u{--ui-menu-row-padding-inline:8px}\n#sand-vault-0721-root .sand-1p3ha76{--ui-menu-row-padding-inline:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-18k90n9{--ui-menu-row-padding-inline:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-1kfdx4m{--ui-menu-section-title-padding-inline:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-mhevzc{--ui-menu-section-title-padding-inline:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-yc74mg{--ui-popup-box-shadow:var(--sand-shadow-popover)}\n#sand-vault-0721-root .sand-1dns7hp{--ui-select-inner-padding:6px}\n#sand-vault-0721-root .sand-14h2ojr{--ui-select-list-gap:2px}\n#sand-vault-0721-root .sand-19nwe76{--ui-select-row-gap:12px}\n#sand-vault-0721-root .sand-rqqy9p{--ui-select-row-gap:4px}\n#sand-vault-0721-root .sand-tp2p40{--ui-select-row-min-height:34px}\n#sand-vault-0721-root .sand-xeedxy{--ui-select-row-min-height:44px}\n#sand-vault-0721-root .sand-1n21ee9{--ui-select-row-min-height:30px}\n#sand-vault-0721-root .sand-1okjtpd{--ui-select-row-padding-block:6px}\n#sand-vault-0721-root .sand-1g5gzg9{--ui-select-row-padding-inline:12px}\n#sand-vault-0721-root .sand-1hrzgrd{--ui-select-row-padding-inline:14px}\n#sand-vault-0721-root .sand-1tpml9q{--ui-surface-hairline-width:.5px}\n#sand-vault-0721-root .sand-syfjwf.sand-syfjwf:where(:has(.sand--default-marker:is([data-pane-active] [data-panel-empty]))){--pane-empty-basis:0px}\n#sand-vault-0721-root .sand-1gidna4.sand-1gidna4:where(:has(.sand--default-marker:is([data-pane-active] [data-panel-empty]))){--pane-empty-panel-grow:3}\n#sand-vault-0721-root .sand-1a94j2n.sand-1a94j2n:where(:has(.sand--default-marker:is([data-pane-active] [data-panel-empty]))){--pane-empty-top-display:flex}\n#sand-vault-0721-root .sand-1dtujmv.sand-1dtujmv:where(:has(.sand--default-marker:is([data-pane-active] [data-panel-empty]))){--pane-empty-top-grow:2}\n#sand-vault-0721-root .sand-pn37pp.sand-pn37pp:where(:has(.sand--default-marker[data-agent-thread-toggle]:focus-visible)){--sand-agent-item-avatar-opacity:0}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1h9t0qu.sand-1h9t0qu{--sand-mention-monogram-fill:color-mix(in srgb,currentColor 20%,transparent)}\n#sand-vault-0721-root .sand-10a8y8t:not(#\\#){inset:0}\n#sand-vault-0721-root .sand-k92lsc:not(#\\#){inset:8px}\n#sand-vault-0721-root .sand-1ghz6dp:not(#\\#){margin:0}\n#sand-vault-0721-root .sand-1bpp3o7:not(#\\#){margin:auto}\n#sand-vault-0721-root .sand-1717udv:not(#\\#){padding:0}\n#sand-vault-0721-root .sand-c7ga6q:not(#\\#){padding:12px}\n#sand-vault-0721-root .sand-1tamke2:not(#\\#){padding:16px}\n#sand-vault-0721-root .sand-9ms5i6:not(#\\#){padding:3px}\n#sand-vault-0721-root .sand-1ruevkc:not(#\\#){padding:6px}\n#sand-vault-0721-root .sand-e8ttls:not(#\\#){padding:8px}\n#sand-vault-0721-root .sand-nzy186:not(#\\#):not(#\\#){border-color:#00c972}\n#sand-vault-0721-root .sand-g29ltk:not(#\\#):not(#\\#){border-color:#fff}\n#sand-vault-0721-root .sand-ihgi1t:not(#\\#):not(#\\#){border-color:color-mix(in srgb,currentcolor 30%,transparent)}\n#sand-vault-0721-root .sand-18kvpo9:not(#\\#):not(#\\#){border-color:#fff6}\n#sand-vault-0721-root .sand-9r1u3d:not(#\\#):not(#\\#){border-color:#0000}\n#sand-vault-0721-root .sand-vd4qke:not(#\\#):not(#\\#){border-color:var(--sand-border-accent-primary)}\n#sand-vault-0721-root .sand-uw55gi:not(#\\#):not(#\\#){border-color:var(--sand-border-danger-primary)}\n#sand-vault-0721-root .sand-14ed0nm:not(#\\#):not(#\\#){border-color:var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-17tbahu:not(#\\#):not(#\\#){border-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-5fd6op:not(#\\#):not(#\\#){border-color:var(--sand-border-tertiary-translucent)}\n#sand-vault-0721-root .sand-1370upb:not(#\\#):not(#\\#){border-color:var(--sand-border-warn-primary)}\n#sand-vault-0721-root .sand-j6k430:not(#\\#):not(#\\#){border-color:var(--sand-text-quaternary)}\n#sand-vault-0721-root .sand-uxrje7:not(#\\#):not(#\\#){border-inline-width:0}\n#sand-vault-0721-root .sand-1q4ynmn:not(#\\#):not(#\\#){border-radius:10px}\n#sand-vault-0721-root .sand-4pepcl:not(#\\#):not(#\\#){border-radius:12px}\n#sand-vault-0721-root .sand-ixl9f9:not(#\\#):not(#\\#){border-radius:14px}\n#sand-vault-0721-root .sand-gqmno8:not(#\\#):not(#\\#){border-radius:16px}\n#sand-vault-0721-root .sand-12oqio5:not(#\\#):not(#\\#){border-radius:4px}\n#sand-vault-0721-root .sand-16rqkct:not(#\\#):not(#\\#){border-radius:50%}\n#sand-vault-0721-root .sand-1kogg8i:not(#\\#):not(#\\#){border-radius:6px}\n#sand-vault-0721-root .sand-1i4c3av:not(#\\#):not(#\\#){border-radius:var(--cursor-radius-full)}\n#sand-vault-0721-root .sand-1m7fhj7:not(#\\#):not(#\\#){border-radius:var(--cursor-radius-lg)}\n#sand-vault-0721-root .sand-1e1y6u3:not(#\\#):not(#\\#){border-radius:var(--cursor-radius-sm)}\n#sand-vault-0721-root .sand-1pkpdue:not(#\\#):not(#\\#){border-radius:var(--cursor-radius-xl)}\n#sand-vault-0721-root .sand-1i6gnc1:not(#\\#):not(#\\#){border-radius:4px}\n#sand-vault-0721-root .sand-1qmwy7c:not(#\\#):not(#\\#){border-radius:8px}\n#sand-vault-0721-root .sand-1m1syzd:not(#\\#):not(#\\#),#sand-vault-0721-root .sand-lstp0r:not(#\\#):not(#\\#){border-radius:24px}\n#sand-vault-0721-root .sand-hojbe8:not(#\\#):not(#\\#){border-radius:12px}\n#sand-vault-0721-root .sand-13yp6sp:not(#\\#):not(#\\#){border-radius:var(--sand-menu-radius)}\n#sand-vault-0721-root .sand-t9pb60:not(#\\#):not(#\\#){border-radius:6px}\n#sand-vault-0721-root .sand-1t6ttyj:not(#\\#):not(#\\#){border-radius:10px}\n#sand-vault-0721-root .sand-149ho13:not(#\\#):not(#\\#){border-radius:9999px}\n#sand-vault-0721-root .sand-bsl7fq:not(#\\#):not(#\\#){border-style:dashed}\n#sand-vault-0721-root .sand-ng3xce:not(#\\#):not(#\\#){border-style:none}\n#sand-vault-0721-root .sand-1y0btm7:not(#\\#):not(#\\#){border-style:solid}\n#sand-vault-0721-root .sand-c342km:not(#\\#):not(#\\#){border-width:0}\n#sand-vault-0721-root .sand-vndefy:not(#\\#):not(#\\#){border-width:1.5px}\n#sand-vault-0721-root .sand-mkeg23:not(#\\#):not(#\\#){border-width:1px}\n#sand-vault-0721-root .sand-dh2fpr:not(#\\#):not(#\\#){border-width:2px}\n#sand-vault-0721-root .sand-qjedn3:not(#\\#):not(#\\#){border-width:.5px}\n#sand-vault-0721-root .sand-883omv:not(#\\#):not(#\\#){gap:10px}\n#sand-vault-0721-root .sand-1v2ro7d:not(#\\#):not(#\\#){gap:12px}\n#sand-vault-0721-root .sand-ou54vl:not(#\\#):not(#\\#){gap:16px}\n#sand-vault-0721-root .sand-1665zp3:not(#\\#):not(#\\#){gap:24px}\n#sand-vault-0721-root .sand-195vfkc:not(#\\#):not(#\\#){gap:2px}\n#sand-vault-0721-root .sand-1jnr06f:not(#\\#):not(#\\#){gap:4px}\n#sand-vault-0721-root .sand-17d4w8g:not(#\\#):not(#\\#){gap:6px}\n#sand-vault-0721-root .sand-167g77z:not(#\\#):not(#\\#){gap:8px}\n#sand-vault-0721-root .sand-pkkfsy:not(#\\#):not(#\\#){gap:var(--cursor-spacing-1-5)}\n#sand-vault-0721-root .sand-11twubx:not(#\\#):not(#\\#){gap:var(--cursor-spacing-1)}\n#sand-vault-0721-root .sand-1dbef6d:not(#\\#):not(#\\#){gap:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-ehausa:not(#\\#):not(#\\#){gap:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-3qzy4x:not(#\\#):not(#\\#){gap:var(--cursor-spacing-7)}\n#sand-vault-0721-root .sand-17y0mx6:not(#\\#):not(#\\#){inset-inline:0}\n#sand-vault-0721-root .sand-e8uvvx:not(#\\#):not(#\\#){list-style:none}\n#sand-vault-0721-root .sand-3tgyqv:not(#\\#):not(#\\#){margin-block:-10px}\n#sand-vault-0721-root .sand-10im51j:not(#\\#):not(#\\#){margin-block:0}\n#sand-vault-0721-root .sand-g9jes1:not(#\\#):not(#\\#){margin-block:4px}\n#sand-vault-0721-root .sand-rxpjvj:not(#\\#):not(#\\#){margin-inline:0}\n#sand-vault-0721-root .sand-vueqy4:not(#\\#):not(#\\#){margin-inline:auto}\n#sand-vault-0721-root .sand-1a2a7pz:not(#\\#):not(#\\#){outline:none}\n#sand-vault-0721-root .sand-b3r6kr:not(#\\#):not(#\\#){overflow:hidden}\n#sand-vault-0721-root .sand-t970qd:not(#\\#):not(#\\#){padding-block:0}\n#sand-vault-0721-root .sand-p59q4u:not(#\\#):not(#\\#){padding-block:10px}\n#sand-vault-0721-root .sand-10dr8xq:not(#\\#):not(#\\#){padding-block:12px}\n#sand-vault-0721-root .sand-j8oexa:not(#\\#):not(#\\#){padding-block:2px}\n#sand-vault-0721-root .sand-12ulsxz:not(#\\#):not(#\\#){padding-block:4px}\n#sand-vault-0721-root .sand-ifx94n:not(#\\#):not(#\\#){padding-block:5px}\n#sand-vault-0721-root .sand-1t0vds8:not(#\\#):not(#\\#){padding-block:6px}\n#sand-vault-0721-root .sand-knfcqp:not(#\\#):not(#\\#){padding-block:7px}\n#sand-vault-0721-root .sand-1lqmthn:not(#\\#):not(#\\#){padding-block:var(--cursor-spacing-1-5)}\n#sand-vault-0721-root .sand-y3j6vt:not(#\\#):not(#\\#){padding-block:var(--cursor-spacing-3)}\n#sand-vault-0721-root .sand-njsko4:not(#\\#):not(#\\#){padding-inline:0}\n#sand-vault-0721-root .sand-1awh872:not(#\\#):not(#\\#){padding-inline:10px}\n#sand-vault-0721-root .sand-aope02:not(#\\#):not(#\\#){padding-inline:12px}\n#sand-vault-0721-root .sand-1hr3lfm:not(#\\#):not(#\\#){padding-inline:16px}\n#sand-vault-0721-root .sand-fn1xvj:not(#\\#):not(#\\#){padding-inline:4px}\n#sand-vault-0721-root .sand-dqyycr:not(#\\#):not(#\\#){padding-inline:8px}\n#sand-vault-0721-root .sand-1q4txso:not(#\\#):not(#\\#){padding-inline:9px}\n#sand-vault-0721-root .sand-w3enoh:not(#\\#):not(#\\#){padding-inline:var(--cursor-spacing-2-5)}\n#sand-vault-0721-root .sand-2f45yy:not(#\\#):not(#\\#){padding-inline:var(--cursor-spacing-3-5)}\n#sand-vault-0721-root .sand-16chyoa:focus-visible:not(#\\#):not(#\\#){border-color:var(--sand-border-focus-primary)}\n#sand-vault-0721-root .sand-139twnn.sand-139twnn:where(:has(.sand--default-marker[data-focus-held])):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-sb55g1:focus-within:not(#\\#):not(#\\#),#sand-vault-0721-root .sand-vk9egn:focus-visible:not(#\\#):not(#\\#){border-color:var(--sand-border-primary-translucent)}\n#sand-vault-0721-root .sand-12mhxhr:focus-within:not(#\\#):not(#\\#){border-color:var(--sand-text-quaternary)}\n#sand-vault-0721-root{overflow:visible}\n@media (hover:hover) and (pointer:fine){#sand-vault-0721-root :where(.sand--default-marker.sand-code-figure:hover) .sand-gh7kop.sand-gh7kop.sand-gh7kop:not(#\\#):not(#\\#){overflow:visible}}\n#sand-vault-0721-root .sand-1ua5tub:not(#\\#):not(#\\#):not(#\\#){-webkit-box-orient:vertical}\n#sand-vault-0721-root .sand-h0615m:not(#\\#):not(#\\#):not(#\\#){-webkit-line-clamp:1}\n#sand-vault-0721-root .sand-1pha0wt:not(#\\#):not(#\\#):not(#\\#){align-items:baseline}\n#sand-vault-0721-root .sand-6s0dn4:not(#\\#):not(#\\#):not(#\\#){align-items:center}\n#sand-vault-0721-root .sand-pqajaz:not(#\\#):not(#\\#):not(#\\#){align-items:end}\n#sand-vault-0721-root .sand-1cy8zhl:not(#\\#):not(#\\#):not(#\\#){align-items:flex-start}\n#sand-vault-0721-root .sand-7a106z:not(#\\#):not(#\\#):not(#\\#){align-items:start}\n#sand-vault-0721-root .sand-1qjc9v5:not(#\\#):not(#\\#):not(#\\#){align-items:stretch}\n#sand-vault-0721-root .sand-amitd3:not(#\\#):not(#\\#):not(#\\#){align-self:center}\n#sand-vault-0721-root .sand-kh2ocl:not(#\\#):not(#\\#):not(#\\#){align-self:stretch}\n#sand-vault-0721-root .sand-5orbwg:not(#\\#):not(#\\#):not(#\\#){animation-duration:.7s}\n#sand-vault-0721-root .sand-a4qsjk:not(#\\#):not(#\\#):not(#\\#){animation-iteration-count:infinite}\n#sand-vault-0721-root .sand-1a5igra:not(#\\#):not(#\\#):not(#\\#){animation-name:none}\n#sand-vault-0721-root .sand-r5sbw0:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-1wc8ddo-B}\n#sand-vault-0721-root .sand-1esw782:not(#\\#):not(#\\#):not(#\\#){animation-timing-function:linear}\n#sand-vault-0721-root .sand-jyslct:not(#\\#):not(#\\#):not(#\\#){appearance:none}\n#sand-vault-0721-root .sand-1dmgsgi:not(#\\#):not(#\\#):not(#\\#){-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}\n#sand-vault-0721-root .sand-1r1mewj:not(#\\#):not(#\\#):not(#\\#){background-color:#000}\n#sand-vault-0721-root .sand-14hfbwc:not(#\\#):not(#\\#):not(#\\#){background-color:#016fd0}\n#sand-vault-0721-root .sand-83z2og:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1liytr5:not(#\\#):not(#\\#):not(#\\#){background-color:#fff}\n#sand-vault-0721-root .sand-tyo4xa:not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,var(--sand-bg-elevated) 92%,transparent)}\n#sand-vault-0721-root .sand-ukxp9i:not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,var(--sand-text-accent-primary) 20%,var(--sand-bg-active))}\n#sand-vault-0721-root .sand-150l7so:not(#\\#):not(#\\#):not(#\\#){background-color:#0000007a}\n#sand-vault-0721-root .sand-14zn8v5:not(#\\#):not(#\\#):not(#\\#){background-color:#282828c7}\n#sand-vault-0721-root .sand-jbqb8w:not(#\\#):not(#\\#):not(#\\#){background-color:#0000}\n#sand-vault-0721-root .sand-1cgqir:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-primary)}\n#sand-vault-0721-root .sand-13jhjah:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary)}\n#sand-vault-0721-root .sand-kr7fhf:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-active)}\n#sand-vault-0721-root .sand-vopzge:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-primary)}\n#sand-vault-0721-root .sand-jt6epu:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-secondary)}\n#sand-vault-0721-root .sand-10e981r:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-elevated)}\n#sand-vault-0721-root .sand-8rotk8:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-primary)}\n#sand-vault-0721-root .sand-si5pdb:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-quaternary)}\n#sand-vault-0721-root .sand-azoy5u:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-scrim)}\n#sand-vault-0721-root .sand-18pe38m:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-hover)}\n#sand-vault-0721-root .sand-fwqdrz:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root .sand-105pnba:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-tertiary)}\n#sand-vault-0721-root .sand-7z33ko:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-primary)}\n#sand-vault-0721-root .sand-1ii9591:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-secondary)}\n#sand-vault-0721-root .sand-1vh0fzo:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-text-accent-primary)}\n#sand-vault-0721-root .sand-18rdzox:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-transcript-bubble-agent-fill)}\n#sand-vault-0721-root .sand-1hk0rwa:not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(153deg,#5b544c 14.286%,#211f1d 85.714%)}\n#sand-vault-0721-root .sand-1bowyxn:not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(var(--sand-bg-accent-secondary),var(--sand-bg-accent-secondary))}\n#sand-vault-0721-root .sand-18o3ruo:not(#\\#):not(#\\#):not(#\\#){background-image:none}\n#sand-vault-0721-root .sand-16uus16:not(#\\#):not(#\\#):not(#\\#){border-end-end-radius:0}\n#sand-vault-0721-root .sand-biv7yw:not(#\\#):not(#\\#):not(#\\#){border-end-start-radius:0}\n#sand-vault-0721-root .sand-1o3jo1z:not(#\\#):not(#\\#):not(#\\#){border-inline-end-color:#0000}\n#sand-vault-0721-root .sand-12gt5l9:not(#\\#):not(#\\#):not(#\\#){border-inline-end-color:var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-bp68ws:not(#\\#):not(#\\#):not(#\\#){border-inline-end-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-18b5jzi:not(#\\#):not(#\\#):not(#\\#){border-inline-end-style:solid}\n#sand-vault-0721-root .sand-10w94by:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:0}\n#sand-vault-0721-root .sand-1c1dy35:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:10px}\n#sand-vault-0721-root .sand-odjb3w:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:11px}\n#sand-vault-0721-root .sand-qm0940:not(#\\#):not(#\\#):not(#\\#){border-inline-end-width:.5px}\n#sand-vault-0721-root .sand-1x5h272:not(#\\#):not(#\\#):not(#\\#){border-inline-start-color:var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-5x6ma4:not(#\\#):not(#\\#):not(#\\#){border-inline-start-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-1t7ytsu:not(#\\#):not(#\\#):not(#\\#){border-inline-start-style:solid}\n#sand-vault-0721-root .sand-14e42zd:not(#\\#):not(#\\#):not(#\\#){border-inline-start-width:0}\n#sand-vault-0721-root .sand-1sd92yl:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1p9ssgk:not(#\\#):not(#\\#):not(#\\#){border-inline-start-width:.5px}\n#sand-vault-0721-root .sand-1ga7v0g:not(#\\#):not(#\\#):not(#\\#){border-start-end-radius:0}\n#sand-vault-0721-root .sand-15mokao:not(#\\#):not(#\\#):not(#\\#){border-start-start-radius:0}\n#sand-vault-0721-root .sand-124efjc:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-4bsmwh:not(#\\#):not(#\\#):not(#\\#){box-shadow:0 0 0 1px var(--sand-border-quaternary-translucent),0 2px 8px var(--sand-shadow-card)}\n#sand-vault-0721-root .sand-1ubh17z:not(#\\#):not(#\\#):not(#\\#){box-shadow:0 0 0 999px #0006}\n#sand-vault-0721-root .sand-bwjx97:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 .5px color-mix(in srgb,currentColor 15%,transparent)}\n#sand-vault-0721-root .sand-pmb8bl:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 1px var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-19mzooj:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 .5px var(--sand-border-tertiary-translucent)}\n#sand-vault-0721-root .sand-w5uq4s:not(#\\#):not(#\\#):not(#\\#){box-shadow:var(--sand-shadow-modal)}\n#sand-vault-0721-root .sand-9f619:not(#\\#):not(#\\#):not(#\\#){box-sizing:border-box}\n#sand-vault-0721-root .sand-ed0x38:not(#\\#):not(#\\#):not(#\\#){color:#231f20}\n#sand-vault-0721-root .sand-5a26a2:not(#\\#):not(#\\#):not(#\\#){color:#fcfcfc}\n#sand-vault-0721-root .sand-fungia:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-mzmlnv:not(#\\#):not(#\\#):not(#\\#){color:#fff}\n#sand-vault-0721-root .sand-1heor9g:not(#\\#):not(#\\#):not(#\\#){color:inherit}\n#sand-vault-0721-root .sand-11w3uhm:not(#\\#):not(#\\#):not(#\\#){color:#fcfcfcb3}\n#sand-vault-0721-root .sand-1e6yr6a:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-primary)}\n#sand-vault-0721-root .sand-101qkwy:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-quaternary)}\n#sand-vault-0721-root .sand-nxsxl2:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-secondary)}\n#sand-vault-0721-root .sand-1gt6tda:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-tertiary)}\n#sand-vault-0721-root .sand-10kc733:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-accent-primary)}\n#sand-vault-0721-root .sand-i69oq4:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-danger-primary)}\n#sand-vault-0721-root .sand-sa7k8x:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-inverted)}\n#sand-vault-0721-root .sand-xcaa6e:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-on-primary)}\n#sand-vault-0721-root .sand-tyxrsu:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-primary)}\n#sand-vault-0721-root .sand-x1phaw:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-quaternary)}\n#sand-vault-0721-root .sand-1o0liin:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-secondary)}\n#sand-vault-0721-root .sand-169k319:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-tertiary)}\n#sand-vault-0721-root .sand-impobl:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-warn-primary)}\n#sand-vault-0721-root .sand-tqikln:not(#\\#):not(#\\#):not(#\\#){column-gap:12px}\n#sand-vault-0721-root .sand-18hwk67:not(#\\#):not(#\\#):not(#\\#){column-gap:20px}\n#sand-vault-0721-root .sand-17zd0t2:not(#\\#):not(#\\#):not(#\\#){column-gap:4px}\n#sand-vault-0721-root .sand-fex06f:not(#\\#):not(#\\#):not(#\\#){column-gap:8px}\n#sand-vault-0721-root .sand-t0e3qv:not(#\\#):not(#\\#):not(#\\#){cursor:default}\n#sand-vault-0721-root .sand-1ypdohk:not(#\\#):not(#\\#):not(#\\#){cursor:pointer}\n#sand-vault-0721-root .sand-104kibb:not(#\\#):not(#\\#):not(#\\#){display:-webkit-box}\n#sand-vault-0721-root .sand-1lliihq:not(#\\#):not(#\\#):not(#\\#){display:block}\n#sand-vault-0721-root .sand-jp7ctv:not(#\\#):not(#\\#):not(#\\#){display:contents}\n#sand-vault-0721-root .sand-78zum5:not(#\\#):not(#\\#):not(#\\#){display:flex}\n#sand-vault-0721-root .sand-rvj5dj:not(#\\#):not(#\\#):not(#\\#){display:grid}\n#sand-vault-0721-root .sand-3nfvp2:not(#\\#):not(#\\#):not(#\\#){display:inline-flex}\n#sand-vault-0721-root .sand-1s85apg:not(#\\#):not(#\\#):not(#\\#){display:none}\n#sand-vault-0721-root .sand-nyzrob:not(#\\#):not(#\\#):not(#\\#){filter:blur(1px)}\n#sand-vault-0721-root .sand-1dftt0s:not(#\\#):not(#\\#):not(#\\#){filter:invert()}\n#sand-vault-0721-root .sand-1r8uery:not(#\\#):not(#\\#):not(#\\#){flex-basis:0}\n#sand-vault-0721-root .sand-1l7klhg:not(#\\#):not(#\\#):not(#\\#){flex-basis:100%}\n#sand-vault-0721-root .sand-dl72j9:not(#\\#):not(#\\#):not(#\\#){flex-basis:auto}\n#sand-vault-0721-root .sand-dt5ytf:not(#\\#):not(#\\#):not(#\\#){flex-direction:column}\n#sand-vault-0721-root .sand-1c4vz4f:not(#\\#):not(#\\#):not(#\\#){flex-grow:0}\n#sand-vault-0721-root .sand-10icjm1:not(#\\#):not(#\\#):not(#\\#){flex-grow:1.4}\n#sand-vault-0721-root .sand-1iyjqo2:not(#\\#):not(#\\#):not(#\\#){flex-grow:1}\n#sand-vault-0721-root .sand-2lah0s:not(#\\#):not(#\\#):not(#\\#){flex-shrink:0}\n#sand-vault-0721-root .sand-s83m0k:not(#\\#):not(#\\#):not(#\\#){flex-shrink:1}\n#sand-vault-0721-root .sand-1a02dak:not(#\\#):not(#\\#):not(#\\#){flex-wrap:wrap}\n#sand-vault-0721-root .sand-jb2p0i:not(#\\#):not(#\\#):not(#\\#){font-family:inherit}\n#sand-vault-0721-root .sand-mpsg8l:not(#\\#):not(#\\#):not(#\\#){font-family:var(--cursor-font-family-mono)}\n#sand-vault-0721-root .sand-1jvydc1:not(#\\#):not(#\\#):not(#\\#){font-size:15px}\n#sand-vault-0721-root .sand-19d36u7:not(#\\#):not(#\\#):not(#\\#){font-size:17px}\n#sand-vault-0721-root .sand-1i1m3gp:not(#\\#):not(#\\#):not(#\\#){font-size:22px}\n#sand-vault-0721-root .sand-1ewwscv:not(#\\#):not(#\\#):not(#\\#){font-size:26px}\n#sand-vault-0721-root .sand-6ijxsv:not(#\\#):not(#\\#):not(#\\#){font-size:7px}\n#sand-vault-0721-root .sand-1qlqyl8:not(#\\#):not(#\\#):not(#\\#){font-size:inherit}\n#sand-vault-0721-root .sand-11wthnw:not(#\\#):not(#\\#):not(#\\#){font-size:var(--cursor-font-size-base)}\n#sand-vault-0721-root .sand-fc7y3v:not(#\\#):not(#\\#):not(#\\#){font-size:var(--cursor-font-size-lg)}\n#sand-vault-0721-root .sand-1wm8ruf:not(#\\#):not(#\\#):not(#\\#){font-size:var(--cursor-font-size-sm)}\n#sand-vault-0721-root .sand-y5h43f:not(#\\#):not(#\\#):not(#\\#){font-size:var(--cursor-font-size-xs)}\n#sand-vault-0721-root .sand-1yil2se:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-base)}\n#sand-vault-0721-root .sand-q1hgy8:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-lg)}\n#sand-vault-0721-root .sand-g2dot2:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-sm)}\n#sand-vault-0721-root .sand-79ao00:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xl)}\n#sand-vault-0721-root .sand-1ao5zh4:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xs)}\n#sand-vault-0721-root .sand-1mmermx:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xxl)}\n#sand-vault-0721-root .sand-7uqsge:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xxs)}\n#sand-vault-0721-root .sand-zdi6ij:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-font-size-xxxl)}\n#sand-vault-0721-root .sand-mjvtqz:not(#\\#):not(#\\#):not(#\\#){font-size:var(--sand-menu-font-size)}\n#sand-vault-0721-root .sand-ss6m8b:not(#\\#):not(#\\#):not(#\\#){font-variant-numeric:tabular-nums}\n#sand-vault-0721-root .sand-1xlr1w8:not(#\\#):not(#\\#):not(#\\#){font-weight:700}\n#sand-vault-0721-root .sand-1rhlpx6:not(#\\#):not(#\\#):not(#\\#){font-weight:var(--sand-font-weight-medium)}\n#sand-vault-0721-root .sand-1k6tqyu:not(#\\#):not(#\\#):not(#\\#){font-weight:var(--sand-font-weight-regular)}\n#sand-vault-0721-root .sand-xzm5a7:not(#\\#):not(#\\#):not(#\\#){font-weight:var(--sand-font-weight-semibold)}\n#sand-vault-0721-root .sand-1bd8qys:not(#\\#):not(#\\#):not(#\\#){grid-template-columns:104px minmax(0,1fr) auto}\n#sand-vault-0721-root .sand-cjjqqt:not(#\\#):not(#\\#):not(#\\#){grid-template-columns:minmax(0,1fr) minmax(0,1fr)}\n#sand-vault-0721-root .sand-o2ifbc:not(#\\#):not(#\\#):not(#\\#){inset-inline-end:10px}\n#sand-vault-0721-root .sand-1ro0b6g:not(#\\#):not(#\\#):not(#\\#){inset-inline-end:3px}\n#sand-vault-0721-root .sand-l56j7k:not(#\\#):not(#\\#):not(#\\#){justify-content:center}\n#sand-vault-0721-root .sand-13a6bvl:not(#\\#):not(#\\#):not(#\\#){justify-content:flex-end}\n#sand-vault-0721-root .sand-1qughib:not(#\\#):not(#\\#):not(#\\#){justify-content:space-between}\n#sand-vault-0721-root .sand-16q24ku:not(#\\#):not(#\\#):not(#\\#){letter-spacing:.02em}\n#sand-vault-0721-root .sand-1vyo3qp:not(#\\#):not(#\\#):not(#\\#){letter-spacing:.04em}\n#sand-vault-0721-root .sand-1dgsrnt:not(#\\#):not(#\\#):not(#\\#){letter-spacing:.06em}\n#sand-vault-0721-root .sand-12oo3zp:not(#\\#):not(#\\#):not(#\\#){letter-spacing:0}\n#sand-vault-0721-root .sand-4gjf66:not(#\\#):not(#\\#):not(#\\#){letter-spacing:inherit}\n#sand-vault-0721-root .sand-ja3w2a:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-base)}\n#sand-vault-0721-root .sand-99smjr:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-lg)}\n#sand-vault-0721-root .sand-14gdtuo:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-sm)}\n#sand-vault-0721-root .sand-k0i524:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xl)}\n#sand-vault-0721-root .sand-b7p3tu:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xs)}\n#sand-vault-0721-root .sand-1ehaq9d:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xxl)}\n#sand-vault-0721-root .sand-1h1hs02:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xxs)}\n#sand-vault-0721-root .sand-lnf3q9:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-letter-spacing-xxxl)}\n#sand-vault-0721-root .sand-19miikw:not(#\\#):not(#\\#):not(#\\#){letter-spacing:var(--sand-menu-letter-spacing)}\n#sand-vault-0721-root .sand-1fc57z9:not(#\\#):not(#\\#):not(#\\#){line-height:20px}\n#sand-vault-0721-root .sand-19v9tvf:not(#\\#):not(#\\#):not(#\\#){line-height:22px}\n#sand-vault-0721-root .sand-15bjb6t:not(#\\#):not(#\\#):not(#\\#){line-height:inherit}\n#sand-vault-0721-root .sand-1yxxptd:not(#\\#):not(#\\#):not(#\\#){line-height:var(--cursor-line-height-lg)}\n#sand-vault-0721-root .sand-1lvvshy:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-base)}\n#sand-vault-0721-root .sand-1971ylj:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-lg)}\n#sand-vault-0721-root .sand-w8bs97:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-sm)}\n#sand-vault-0721-root .sand-10ux60h:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xl)}\n#sand-vault-0721-root .sand-10jubzo:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xs)}\n#sand-vault-0721-root .sand-vh7mc1:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xxl)}\n#sand-vault-0721-root .sand-19jnaw5:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xxs)}\n#sand-vault-0721-root .sand-1odv9bt:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-line-height-xxxl)}\n#sand-vault-0721-root .sand-e9ffq4:not(#\\#):not(#\\#):not(#\\#){line-height:var(--sand-menu-line-height)}\n#sand-vault-0721-root .sand-14z9mp:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:0}\n#sand-vault-0721-root .sand-1p8j9ns:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:3px}\n#sand-vault-0721-root .sand-2fvf9:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:4px}\n#sand-vault-0721-root .sand-belrpt:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:6px}\n#sand-vault-0721-root .sand-1lziwak:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:0}\n#sand-vault-0721-root .sand-vc5jky:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:auto}\n#sand-vault-0721-root .sand-19kjcj4:not(#\\#):not(#\\#):not(#\\#){object-fit:contain}\n#sand-vault-0721-root .sand-l1xv1r:not(#\\#):not(#\\#):not(#\\#){object-fit:cover}\n#sand-vault-0721-root .sand-ti2d7y:not(#\\#):not(#\\#):not(#\\#){opacity:.4}\n#sand-vault-0721-root .sand-g01cxk:not(#\\#):not(#\\#):not(#\\#){opacity:0}\n#sand-vault-0721-root .sand-1hc1fzr:not(#\\#):not(#\\#):not(#\\#){opacity:1}\n#sand-vault-0721-root .sand-1v39l1b:not(#\\#):not(#\\#):not(#\\#){outline-color:var(--sand-border-focus-primary)}\n#sand-vault-0721-root .sand-1g40iwv:not(#\\#):not(#\\#):not(#\\#){outline-offset:-1px}\n#sand-vault-0721-root .sand-1y3gkto:not(#\\#):not(#\\#):not(#\\#){outline-offset:1px}\n#sand-vault-0721-root .sand-1t137rt:not(#\\#):not(#\\#):not(#\\#){outline-style:none}\n#sand-vault-0721-root .sand-1k57tk5:not(#\\#):not(#\\#):not(#\\#){outline-width:0}\n#sand-vault-0721-root .sand-1de99jn:not(#\\#):not(#\\#):not(#\\#){outline-width:2px}\n#sand-vault-0721-root .sand-t08umf:not(#\\#):not(#\\#):not(#\\#){outline-width:.5px}\n#sand-vault-0721-root .sand-j0a0fe:not(#\\#):not(#\\#):not(#\\#){overflow-wrap:anywhere}\n#sand-vault-0721-root .sand-1mzt3pk:not(#\\#):not(#\\#):not(#\\#){overflow-wrap:break-word}\n#sand-vault-0721-root .sand-yri2b:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:0}\n#sand-vault-0721-root .sand-2vl965:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:10px}\n#sand-vault-0721-root .sand-pdmqnj:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:12px}\n#sand-vault-0721-root .sand-1pic42t:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:14px}\n#sand-vault-0721-root .sand-v54qhq:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:16px}\n#sand-vault-0721-root .sand-1ekh9h2:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:17px}\n#sand-vault-0721-root .sand-1x5flf6:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:18px}\n#sand-vault-0721-root .sand-1xnnf8n:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:20px}\n#sand-vault-0721-root .sand-5zjp28:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:30px}\n#sand-vault-0721-root .sand-15zmtp0:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:48px}\n#sand-vault-0721-root .sand-11lfxj5:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:4px}\n#sand-vault-0721-root .sand-1icxu4v:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:6px}\n#sand-vault-0721-root .sand-f159sx:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:8px}\n#sand-vault-0721-root .sand-rw5ot4:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:9px}\n#sand-vault-0721-root .sand-1tlft3r:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:var(--cursor-spacing-1)}\n#sand-vault-0721-root .sand-16mtmbo:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:var(--cursor-spacing-4)}\n#sand-vault-0721-root .sand-1bk0ktj:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:var(--cursor-spacing-5)}\n#sand-vault-0721-root .sand-1s169rl:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:32px}\n#sand-vault-0721-root .sand-1c1uobl:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:0}\n#sand-vault-0721-root .sand-e2zdcy:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:10px}\n#sand-vault-0721-root .sand-1g0dm76:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:12px}\n#sand-vault-0721-root .sand-f7dkkf:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:16px}\n#sand-vault-0721-root .sand-106a9eq:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:20px}\n#sand-vault-0721-root .sand-1pixwil:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:7px}\n#sand-vault-0721-root .sand-mzvs34:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:8px}\n#sand-vault-0721-root .sand-7coems:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:9px}\n#sand-vault-0721-root .sand-22095l:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:var(--cursor-spacing-2)}\n#sand-vault-0721-root .sand-92arao:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:var(--cursor-spacing-5)}\n#sand-vault-0721-root .sand-16mx7xq:not(#\\#):not(#\\#):not(#\\#){padding-inline-start:32px}\n#sand-vault-0721-root .sand-47corl:not(#\\#):not(#\\#):not(#\\#){pointer-events:none}\n#sand-vault-0721-root .sand-10l6tqk:not(#\\#):not(#\\#):not(#\\#){position:absolute}\n#sand-vault-0721-root .sand-1n2onr6:not(#\\#):not(#\\#):not(#\\#){position:relative}\n#sand-vault-0721-root .sand-xs79tx:not(#\\#):not(#\\#):not(#\\#){row-gap:0}\n#sand-vault-0721-root .sand-7h844e:not(#\\#):not(#\\#):not(#\\#){scrollbar-color:var(--sand-border-tertiary-translucent) transparent}\n#sand-vault-0721-root .sand-1597r2g:not(#\\#):not(#\\#):not(#\\#){scrollbar-width:thin}\n#sand-vault-0721-root .sand-2b8uid:not(#\\#):not(#\\#):not(#\\#){text-align:center}\n#sand-vault-0721-root .sand-p4054r:not(#\\#):not(#\\#):not(#\\#){text-align:end}\n#sand-vault-0721-root .sand-1yc453h:not(#\\#):not(#\\#):not(#\\#){text-align:start}\n#sand-vault-0721-root .sand-lyipyv:not(#\\#):not(#\\#):not(#\\#){text-overflow:ellipsis}\n#sand-vault-0721-root .sand-tvhhri:not(#\\#):not(#\\#):not(#\\#){text-transform:uppercase}\n#sand-vault-0721-root .sand-sdcz8n:not(#\\#):not(#\\#):not(#\\#){text-wrap-mode:wrap}\n#sand-vault-0721-root .sand-11lhmoz:not(#\\#):not(#\\#):not(#\\#){transform:translate(-50%,-50%)}\n#sand-vault-0721-root .sand-1firant:not(#\\#):not(#\\#):not(#\\#){transition-duration:.12s}\n#sand-vault-0721-root .sand-15nzlfb:not(#\\#):not(#\\#):not(#\\#){transition-duration:.16s}\n#sand-vault-0721-root .sand-s2xxs2:not(#\\#):not(#\\#):not(#\\#){transition-property:background-color,color}\n#sand-vault-0721-root .sand-shfolx:not(#\\#):not(#\\#):not(#\\#){transition-property:border-color}\n#sand-vault-0721-root .sand-xrbq2n:not(#\\#):not(#\\#):not(#\\#){transition-property:width}\n#sand-vault-0721-root .sand-9lcvmn:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:ease-out}\n#sand-vault-0721-root .sand-wji4o3:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:ease}\n#sand-vault-0721-root .sand-87ps6o:not(#\\#):not(#\\#):not(#\\#){-webkit-user-select:none;user-select:none}\n#sand-vault-0721-root .sand-mziwt1:not(#\\#):not(#\\#):not(#\\#){vertical-align:-2px}\n#sand-vault-0721-root .sand-lshs6z:not(#\\#):not(#\\#):not(#\\#){visibility:hidden}\n#sand-vault-0721-root .sand-uxw1ft:not(#\\#):not(#\\#):not(#\\#){white-space:nowrap}\n#sand-vault-0721-root .sand-126k92a:not(#\\#):not(#\\#):not(#\\#){white-space:pre-wrap}\n#sand-vault-0721-root .sand-1so62im:not(#\\#):not(#\\#):not(#\\#){will-change:transform}\n#sand-vault-0721-root .sand-htitgo:not(#\\#):not(#\\#):not(#\\#){z-index:2}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-k2bhp9.sand-k2bhp9:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-r6vvh3.sand-r6vvh3:not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(var(--sand-bg-hover),var(--sand-bg-hover))}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-15c4utq.sand-15c4utq:not(#\\#):not(#\\#):not(#\\#){grid-template-columns:39px 1fr}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-1i7crgf.sand-1i7crgf:not(#\\#):not(#\\#):not(#\\#){opacity:1}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-f65yrc.sand-f65yrc:not(#\\#):not(#\\#):not(#\\#){outline-style:solid}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-1e3w1cx.sand-1e3w1cx:not(#\\#):not(#\\#):not(#\\#){outline-width:2px}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-1as79fp.sand-1as79fp:not(#\\#):not(#\\#):not(#\\#){transition-duration:.15s}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible) .sand-117rllf.sand-117rllf:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:cubic-bezier(.2,0,0,1)}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-ksnpn0.sand-ksnpn0:not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(var(--sand-bg-hover),var(--sand-bg-hover))}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-18gcsbh.sand-18gcsbh:not(#\\#):not(#\\#):not(#\\#){-webkit-mask-image:linear-gradient(calc(90deg*var(--sand-inline-sign,1)),#000 calc(100% - 22px),transparent calc(100% - 8px));mask-image:linear-gradient(calc(90deg*var(--sand-inline-sign,1)),#000 calc(100% - 22px),transparent calc(100% - 8px))}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-1t642l6.sand-1t642l6:not(#\\#):not(#\\#):not(#\\#){opacity:1}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-1q77ly.sand-1q77ly:not(#\\#):not(#\\#):not(#\\#){transform:translateX(calc(-3px*var(--sand-inline-sign,1))) rotate(calc(-8deg*var(--sand-inline-sign,1)))}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-1rwtdfy.sand-1rwtdfy:not(#\\#):not(#\\#):not(#\\#){transform:translateX(calc(3px*var(--sand-inline-sign,1))) rotate(calc(8deg*var(--sand-inline-sign,1)))}\n#sand-vault-0721-root :where(.sand--default-marker:hover) .sand-1nbbp8h.sand-1nbbp8h:not(#\\#):not(#\\#):not(#\\#){transform:translateY(-1px)}\n#sand-vault-0721-root :where(.sand--default-marker:active) .sand-56zfcv.sand-56zfcv:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-hover)}\n#sand-vault-0721-root :where(.sand--default-marker:active) .sand-s4zcoc.sand-s4zcoc:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-primary)}\n#sand-vault-0721-root :where(.sand--default-marker:focus-visible)~.sand-1lusupg.sand-1lusupg:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 2px var(--sand-border-focus-primary)}\n#sand-vault-0721-root :where(.sand--default-marker:hover)~.sand-nzelb4.sand-nzelb4:not(#\\#):not(#\\#):not(#\\#){text-decoration-color:currentColor}\n#sand-vault-0721-root :where(.sand--default-marker.sand-info-pane[data-open]) .sand-xlogw.sand-xlogw:not(#\\#):not(#\\#):not(#\\#){-webkit-app-region:var(--sand-app-region)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-role=user]) .sand-1jy3azn.sand-1jy3azn:not(#\\#):not(#\\#):not(#\\#){align-self:flex-end}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-isi5sn.sand-isi5sn:not(#\\#):not(#\\#):not(#\\#){animation-delay:.38s}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-1n5cfva.sand-1n5cfva:not(#\\#):not(#\\#):not(#\\#){animation-duration:.32s}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-3yt3ym.sand-3yt3ym:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-ononfz.sand-ononfz:not(#\\#):not(#\\#):not(#\\#){animation-duration:.24s}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-1fmekgq.sand-1fmekgq:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-z7gpas.sand-z7gpas:not(#\\#):not(#\\#):not(#\\#){animation-fill-mode:backwards}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-1voxwag.sand-1voxwag:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-1im2lgs-B}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-1rtwpoi.sand-1rtwpoi:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-1rqlz9z-B}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-1ujtcca.sand-1ujtcca:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-aj6w25-B}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-j3mb0h.sand-j3mb0h:not(#\\#):not(#\\#):not(#\\#){animation-timing-function:cubic-bezier(.22,1,.36,1)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter]) .sand-1n1rhdv.sand-1n1rhdv:not(#\\#):not(#\\#):not(#\\#){animation-timing-function:cubic-bezier(.23,1,.32,1)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-183fkvv.sand-183fkvv:not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,currentColor 18%,transparent)}\n#sand-vault-0721-root .sand-qc45by:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,var(--sand-text-accent-primary) 20%,var(--sand-bg-active))}\n#sand-vault-0721-root .sand-14rb9jf:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1y6hg4:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-d2x0lb.sand-d2x0lb:not(#\\#):not(#\\#):not(#\\#){background-color:#0000}\n#sand-vault-0721-root .sand-1moagsb:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-primary-hover)}\n#sand-vault-0721-root .sand-dkb2vs:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary-hover)}\n#sand-vault-0721-root .sand-17cq1yh:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary)}\n#sand-vault-0721-root .sand-1us2tlb:active:not(:disabled):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-kf9261[data-highlighted]:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-n0wurk:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-active)}\n#sand-vault-0721-root .sand-a9ymcb:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-primary-hover)}\n#sand-vault-0721-root .sand-78epwt:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-secondary-hover)}\n#sand-vault-0721-root .sand-q63dn4:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-secondary)}\n#sand-vault-0721-root .sand-1sxibbd:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-primary-hover)}\n#sand-vault-0721-root .sand-19jy9ex:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-hover)}\n#sand-vault-0721-root{background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-link-hover-card:focus-visible) .sand-t0g2ea.sand-t0g2ea:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root .sand-6bhftj:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-primary-hover)}\n#sand-vault-0721-root .sand-1ra2h21:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-secondary-hover)}\n#sand-vault-0721-root .sand-1swc454:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-secondary)}\n#sand-vault-0721-root :where(.sand--default-marker.sand-task-thread__resize-handle:hover) .sand-4sg2tf.sand-4sg2tf:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-info-pane__resize-handle:hover) .sand-8pfldw.sand-8pfldw:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-border-primary-translucent)}\n#sand-vault-0721-root .sand-fxdvfh:active:not(:disabled):not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(color-mix(in srgb,currentcolor 12%,transparent),color-mix(in srgb,currentcolor 12%,transparent))}\n#sand-vault-0721-root .sand-101ryrv:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:hover:not(:disabled)) .sand-18n118r.sand-18n118r:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[aria-expanded=true]) .sand-w1w4u2.sand-w1w4u2:not(#\\#):not(#\\#):not(#\\#){background-image:linear-gradient(var(--sand-bg-hover),var(--sand-bg-hover))}\n#sand-vault-0721-root .sand-e6bv58:focus-visible:not(#\\#):not(#\\#):not(#\\#){box-shadow:0 0 0 2px #fff9}\n#sand-vault-0721-root .sand-18xb08s:focus-visible:not(#\\#):not(#\\#):not(#\\#){box-shadow:0 0 0 2px var(--sand-border-focus-primary)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-108z0jl.sand-108z0jl:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 1px color-mix(in srgb,currentColor 35%,transparent)}\n#sand-vault-0721-root .sand-1538qzf:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1yfcfk6:focus-visible:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 2px var(--sand-border-focus-primary)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-cvygsx.sand-cvygsx:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,currentColor 65%,transparent)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1ko0bh5.sand-1ko0bh5:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,currentColor 70%,transparent)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-dw34h5.sand-dw34h5:not(#\\#):not(#\\#):not(#\\#){color:currentColor}\n#sand-vault-0721-root .sand-13hlow9:hover:not(:disabled):not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-primary)}\n#sand-vault-0721-root{color:var(--sand-text-primary)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-atx30o.sand-atx30o:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-transcript-bubble-user-text)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1qk24ye.sand-1qk24ye:not(#\\#):not(#\\#):not(#\\#){color:var(--x-1021hmf)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-p4115m.sand-p4115m:not(#\\#):not(#\\#):not(#\\#){display:contents}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-15a73cx.sand-15a73cx:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-vgho8r[hidden]:not(#\\#):not(#\\#):not(#\\#){display:none}\n#sand-vault-0721-root :where(.sand--default-marker.sand-avatar-trigger__button:hover) .sand-1gwej17.sand-1gwej17:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-avatar-trigger__button:focus-visible) .sand-ckqdqq.sand-ckqdqq:not(#\\#):not(#\\#):not(#\\#){filter:brightness(.3)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1q0fwhs.sand-1q0fwhs:not(#\\#):not(#\\#):not(#\\#){font-weight:var(--sand-font-weight-semibold)}\n#sand-vault-0721-root :where(.sand--default-marker[aria-expanded=true]) .sand-834qxt.sand-834qxt:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:hover:not(:disabled)) .sand-rzebgi.sand-rzebgi:not(#\\#):not(#\\#):not(#\\#){grid-template-columns:39px 1fr}\n#sand-vault-0721-root :where(.sand--default-marker[data-standalone-emoji]) .sand-1w1fagr.sand-1w1fagr:not(#\\#):not(#\\#):not(#\\#){line-height:inherit}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-role=user]) .sand-1i19olc.sand-1i19olc:not(#\\#):not(#\\#):not(#\\#){margin-inline-end:6px}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-role=user]) .sand-1fjjgpz.sand-1fjjgpz:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:0}\n#sand-vault-0721-root{margin-inline-start:8px}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-role=user]) .sand-javwx2.sand-javwx2:not(#\\#):not(#\\#):not(#\\#){margin-inline-start:auto}\n#sand-vault-0721-root :where(.sand--default-marker:has(:focus-visible)) .sand-4gar82.sand-4gar82:not(#\\#):not(#\\#):not(#\\#){-webkit-mask-image:linear-gradient(calc(90deg*var(--sand-inline-sign,1)),#000 calc(100% - 22px),transparent calc(100% - 8px));mask-image:linear-gradient(calc(90deg*var(--sand-inline-sign,1)),#000 calc(100% - 22px),transparent calc(100% - 8px))}\n#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-overflow]) .sand-1hm00o0.sand-1hm00o0:not(#\\#):not(#\\#):not(#\\#){-webkit-mask-image:linear-gradient(to bottom,#000 calc(100% - var(--sand-transcript-prose-line-height)),rgb(0 0 0/calc(1 - var(--sand-voice-memo-transcript-fade,0))) 100%);mask-image:linear-gradient(to bottom,#000 calc(100% - var(--sand-transcript-prose-line-height)),rgb(0 0 0/calc(1 - var(--sand-voice-memo-transcript-fade,0))) 100%)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-o77nbk.sand-o77nbk:not(#\\#):not(#\\#):not(#\\#){object-position:right center}\n#sand-vault-0721-root :where(.sand--default-marker[data-compact-cloud-agent]:hover:not(:has([data-pr-link]:focus-visible))) .sand-1mgon1j.sand-1mgon1j:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :is(button:hover)+.sand-4wfbrt:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-compact-cloud-agent]:hover,#sand-vault-0721-root [data-compact-cloud-agent]:focus-within)) .sand-cpvxhc.sand-cpvxhc:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-agent-thread-row-item]:hover,#sand-vault-0721-root [data-agent-thread-row-item]:has(:focus-visible))) .sand-hahzd8.sand-hahzd8:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-tasks-row]:hover,#sand-vault-0721-root [data-tasks-row]:focus-within)) .sand-ny05h.sand-ny05h:not(#\\#):not(#\\#):not(#\\#){opacity:0}\n#sand-vault-0721-root{opacity:1}\n#sand-vault-0721-root .sand-i5y0ii:focus-visible:not(#\\#):not(#\\#):not(#\\#){outline-style:none}\n#sand-vault-0721-root .sand-14xc8xn:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-54jfk2[data-keyboard-focus]:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-9v5kkp:focus-visible:not(#\\#):not(#\\#):not(#\\#){outline-style:solid}\n#sand-vault-0721-root .sand-16gxa91:focus-within:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-784prv:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-yqzfj1[data-keyboard-focus]:focus-within:not(#\\#):not(#\\#):not(#\\#){outline-width:2px}\n#sand-vault-0721-root{padding-inline-end:4px}\n#sand-vault-0721-root :where(.sand--default-marker:is(.sand-group-member-row:hover,#sand-vault-0721-root .sand-group-member-row:focus-within)) .sand-n1kj2s.sand-n1kj2s:not(#\\#):not(#\\#):not(#\\#){padding-inline-end:76px}\n#sand-vault-0721-root :where(.sand--default-marker:is([data-tasks-row]:hover,#sand-vault-0721-root [data-tasks-row]:focus-within)) .sand-14yuvbd.sand-14yuvbd:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-compact-cloud-agent]:hover,#sand-vault-0721-root [data-compact-cloud-agent]:focus-within)) .sand-hi8cnw.sand-hi8cnw:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:is([data-agent-thread-row-item]:hover,#sand-vault-0721-root [data-agent-thread-row-item]:has(:focus-visible))) .sand-pptth6.sand-pptth6:not(#\\#):not(#\\#):not(#\\#){pointer-events:auto}\n#sand-vault-0721-root :where(.sand--default-marker[data-compact-cloud-agent]:hover:not(:has([data-pr-link]:focus-visible))) .sand-1176dy9.sand-1176dy9:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-1b582rm.sand-1b582rm:not(#\\#):not(#\\#):not(#\\#){pointer-events:none}\n#sand-vault-0721-root :where(.sand--default-marker[data-team-copy-created-name]:focus-visible) .sand-10m7oug.sand-10m7oug:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1f2jko9:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1xmi0w3.sand-1xmi0w3:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-team-copy-created-name]:hover) .sand-7b4gmp.sand-7b4gmp:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker[data-pr-link]:hover) .sand-9n5ks.sand-9n5ks:not(#\\#):not(#\\#):not(#\\#){text-decoration-line:underline}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-1l77jpu.sand-1l77jpu:not(#\\#):not(#\\#):not(#\\#){transform-origin:calc(50% - 50%*var(--sand-inline-sign,1)) 100%}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-b3owv9.sand-b3owv9:not(#\\#):not(#\\#):not(#\\#){transform:translate3d(calc(-1*var(--sand-inline-sign,1) *var(--sand-ts-peek,0px)),0,0)}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-1i0kmyb.sand-1i0kmyb:not(#\\#):not(#\\#):not(#\\#){transform:translate3d(calc((1 - var(--sand-ts-progress,0)) * 100%*var(--sand-inline-sign,1)),0,0)}\n#sand-vault-0721-root :where(.sand--default-marker[aria-expanded=true]) .sand-1gvf1b.sand-1gvf1b:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:hover:not(:disabled)) .sand-s4fs6f.sand-s4fs6f:not(#\\#):not(#\\#):not(#\\#){transition-duration:.15s}\n#sand-vault-0721-root :where(.sand--default-marker[aria-expanded=true]) .sand-9rhndf.sand-9rhndf:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker:hover:not(:disabled)) .sand-pzvu2h.sand-pzvu2h:not(#\\#):not(#\\#):not(#\\#){transition-timing-function:cubic-bezier(.2,0,0,1)}\n#sand-vault-0721-root :where(.sand--default-marker:is(.sand-message-action-anchor:hover,#sand-vault-0721-root .sand-message-action-anchor:focus-visible,#sand-vault-0721-root .sand-message-action-anchor:has(:focus-visible),#sand-vault-0721-root .sand-message-action-anchor--menu-open,#sand-vault-0721-root .sand-message-action-anchor--keyboard):not([data-peeking] *)) .sand-fqa2nz.sand-fqa2nz:not(#\\#):not(#\\#):not(#\\#){visibility:visible}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-ba0exv.sand-ba0exv:not(#\\#):not(#\\#):not(#\\#){will-change:transform,opacity}\n#sand-vault-0721-root :where(.sand--default-marker[data-peeking]) .sand-euoelj.sand-euoelj:not(#\\#):not(#\\#):not(#\\#){will-change:transform}\n#sand-vault-0721-root .sand-nnj0qo:has(:focus-visible):not(#\\#):not(#\\#):not(#\\#){outline-style:solid}\n#sand-vault-0721-root .sand-1oqui1x:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:#0000}\n#sand-vault-0721-root .sand-jhkic0:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-primary-disabled)}\n#sand-vault-0721-root .sand-15igvbc:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-accent-secondary-disabled)}\n#sand-vault-0721-root .sand-bmovrx:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-primary-disabled)}\n#sand-vault-0721-root .sand-rf7kli:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-danger-secondary-disabled)}\n#sand-vault-0721-root .sand-1ialtwx:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-primary-disabled)}\n#sand-vault-0721-root .sand-1g6zli8:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-disabled)}\n#sand-vault-0721-root .sand-1a0yh0o:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-primary-disabled)}\n#sand-vault-0721-root .sand-a3pd6v:disabled:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-warn-secondary-disabled)}\n#sand-vault-0721-root .sand-usva8a:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-accent-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-b5j4bo:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-accent-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-5zuve2:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-danger-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-11zc032:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-danger-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-1q1osl5:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-on-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-23x1m:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-on-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-g7klql:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-1xejm7d:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-1dim673:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-warn-primary) 30%,transparent)}\n#sand-vault-0721-root .sand-1pdghxg:disabled:not(#\\#):not(#\\#):not(#\\#){color:color-mix(in srgb,var(--sand-text-warn-primary) 60%,transparent)}\n#sand-vault-0721-root .sand-xcn2h6:disabled:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-icon-quaternary)}\n#sand-vault-0721-root .sand-1ih6jyc:disabled:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-tertiary)}\n#sand-vault-0721-root .sand-1dl01wj:disabled:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-warn-primary)}\n#sand-vault-0721-root .sand-tgyt42:disabled:not(#\\#):not(#\\#):not(#\\#){cursor:default}\n#sand-vault-0721-root .sand-y1652t:hover:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-elevated-hover)}\n#sand-vault-0721-root .sand-1sygd3j:hover:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-hover)}\n#sand-vault-0721-root .sand-11hyl0l:hover:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary)}\n#sand-vault-0721-root .sand-n4ifyr:hover:not(#\\#):not(#\\#):not(#\\#){color:var(--sand-text-primary)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-x8e0mf.sand-x8e0mf:hover:not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,currentColor 18%,transparent)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1bo111n.sand-1bo111n:hover:not(#\\#):not(#\\#):not(#\\#){background-color:color-mix(in srgb,currentColor 20%,transparent)}\n#sand-vault-0721-root .sand-1t4e3jf:active:not(#\\#):not(#\\#):not(#\\#){background-color:var(--sand-bg-secondary-hover)}\n#sand-vault-0721-root :where(.sand--default-marker[data-role=user]) .sand-1eu2zcr.sand-1eu2zcr:hover:not(#\\#):not(#\\#):not(#\\#){box-shadow:inset 0 0 0 1px color-mix(in srgb,currentColor 35%,transparent)}\n@media (prefers-reduced-motion:reduce){#sand-vault-0721-root .sand-1aquc0h.sand-1aquc0h:not(#\\#):not(#\\#):not(#\\#){animation-name:none}}\n@media (prefers-reduced-motion:reduce){#sand-vault-0721-root .sand-11gebw9.sand-11gebw9:not(#\\#):not(#\\#):not(#\\#){opacity:.7}}\n@media (prefers-reduced-motion:reduce){#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-ahcu8d.sand-ahcu8d.sand-ahcu8d:not(#\\#):not(#\\#):not(#\\#){animation-delay:0s}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-aj85ph.sand-aj85ph.sand-aj85ph:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-jfxk63.sand-jfxk63.sand-jfxk63:not(#\\#):not(#\\#):not(#\\#){animation-duration:.12s}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-1q9hv78.sand-1q9hv78.sand-1q9hv78:not(#\\#):not(#\\#):not(#\\#){animation-name:none}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=after-collapse]) .sand-1u7bc6y.sand-1u7bc6y.sand-1u7bc6y:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-xnp86f.sand-xnp86f.sand-xnp86f:not(#\\#):not(#\\#):not(#\\#){animation-name:sand-18re5ia-B}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-enter=new]) .sand-t2y1co.sand-t2y1co.sand-t2y1co:not(#\\#):not(#\\#):not(#\\#){animation-timing-function:ease-out}}\n@media (hover:hover) and (pointer:fine){#sand-vault-0721-root :where(.sand--default-marker.sand-mermaid-figure:hover) .sand-11cn5f1.sand-11cn5f1.sand-11cn5f1:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1yas17b.sand-1yas17b:focus-visible:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-code-figure:hover) .sand-o8ljoj.sand-o8ljoj.sand-o8ljoj:not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root :where(.sand--default-marker.sand-visualization-frame-box:hover) .sand-ux0r15.sand-ux0r15.sand-ux0r15:not(#\\#):not(#\\#):not(#\\#){opacity:1}}\n#sand-vault-0721-root .sand-71tixx:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-color:var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-1vu50b0:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-1q0q8m5:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-style:solid}\n#sand-vault-0721-root .sand-1co6499:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-width:.5px}\n#sand-vault-0721-root .sand-1qhh985:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-width:0}\n#sand-vault-0721-root .sand-1hkp6id:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-width:.5px}\n#sand-vault-0721-root .sand-9rovbz:not(#\\#):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-1b4hy2t:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-color:currentColor}\n#sand-vault-0721-root .sand-1k01be8:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-color:var(--sand-border-quaternary-translucent)}\n#sand-vault-0721-root .sand-13nz628:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-1gjmp7u:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-color:var(--sand-text-secondary)}\n#sand-vault-0721-root .sand-13fuv20:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-style:solid}\n#sand-vault-0721-root .sand-t8cgyo:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:.5px}\n#sand-vault-0721-root .sand-972fbf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:0}\n#sand-vault-0721-root .sand-1hc762m:not(#\\#):not(#\\#):not(#\\#):not(#\\#),#sand-vault-0721-root .sand-ugqeb2:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:.5px}\n#sand-vault-0721-root .sand-qo3gd:not(#\\#):not(#\\#):not(#\\#):not(#\\#){bottom:8px}\n#sand-vault-0721-root .sand-qtp20y:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:0}\n#sand-vault-0721-root .sand-5yr21d:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:100%}\n#sand-vault-0721-root .sand-6w4g8m:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:11px}\n#sand-vault-0721-root .sand-1v9usgg:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:14px}\n#sand-vault-0721-root .sand-lup9mm:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:16px}\n#sand-vault-0721-root .sand-kq7avx:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:176px}\n#sand-vault-0721-root .sand-1ta3ar0:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:17px}\n#sand-vault-0721-root .sand-mix8c7:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:18px}\n#sand-vault-0721-root .sand-hvdbge:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:19px}\n#sand-vault-0721-root .sand-1qx5ct2:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:20px}\n#sand-vault-0721-root .sand-17rw0jw:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:22px}\n#sand-vault-0721-root .sand-xk0z11:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:24px}\n#sand-vault-0721-root .sand-1l76qip:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:264px}\n#sand-vault-0721-root .sand-1fgtraw:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:28px}\n#sand-vault-0721-root .sand-10w6t97:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:32px}\n#sand-vault-0721-root .sand-n3w4p2:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:44px}\n#sand-vault-0721-root .sand-wvwv9b:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:46px}\n#sand-vault-0721-root .sand-sdox4t:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:48px}\n#sand-vault-0721-root .sand-1ycjhwn:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:5px}\n#sand-vault-0721-root .sand-ols6we:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:6px}\n#sand-vault-0721-root .sand-1hagigm:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:7px}\n#sand-vault-0721-root .sand-t7dq6l:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:auto}\n#sand-vault-0721-root .sand-t8t6p:not(#\\#):not(#\\#):not(#\\#):not(#\\#){height:var(--cursor-spacing-8)}\n#sand-vault-0721-root .sand-1qxw02l:not(#\\#):not(#\\#):not(#\\#):not(#\\#){line-clamp:1}\n#sand-vault-0721-root .sand-at24cr:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-bottom:0}\n#sand-vault-0721-root .sand-1rdy4ex:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:-4px}\n#sand-vault-0721-root .sand-dj266r:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:0}\n#sand-vault-0721-root .sand-r9ek0c:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:2px}\n#sand-vault-0721-root .sand-q3t0pi:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-height:280px}\n#sand-vault-0721-root .sand-qyufaf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-height:calc(100vh - 2*max(16px,var(--sand-window-controls-block,0px)))}\n#sand-vault-0721-root .sand-9whfvc:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-height:min(560px,100vh - 200px)}\n#sand-vault-0721-root .sand-193iq5w:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-width:100%}\n#sand-vault-0721-root .sand-1y8h3ww:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-width:45%}\n#sand-vault-0721-root .sand-18b33ah:not(#\\#):not(#\\#):not(#\\#):not(#\\#){max-width:calc(100% - 24px)}\n#sand-vault-0721-root .sand-2lwn1j:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:0}\n#sand-vault-0721-root .sand-uxxueq:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:110px}\n#sand-vault-0721-root .sand-21xpn4:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:32px}\n#sand-vault-0721-root .sand-kd4jle:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:45.5px}\n#sand-vault-0721-root .sand-3sc9yq:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:46px}\n#sand-vault-0721-root .sand-phwom3:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-height:var(--cursor-spacing-8)}\n#sand-vault-0721-root .sand-euugli:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-width:0}\n#sand-vault-0721-root .sand-nei2rj:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-width:24px}\n#sand-vault-0721-root .sand-ma39wp:not(#\\#):not(#\\#):not(#\\#):not(#\\#){min-width:var(--cursor-spacing-8)}\n#sand-vault-0721-root .sand-1plvlek:not(#\\#):not(#\\#):not(#\\#):not(#\\#){overflow-x:visible}\n#sand-vault-0721-root .sand-1odjw0f:not(#\\#):not(#\\#):not(#\\#):not(#\\#){overflow-y:auto}\n#sand-vault-0721-root .sand-ryxfnj:not(#\\#):not(#\\#):not(#\\#):not(#\\#){overflow-y:visible}\n#sand-vault-0721-root .sand-18d9i69:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:0}\n#sand-vault-0721-root .sand-sag5q8:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:12px}\n#sand-vault-0721-root .sand-1g2khh7:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:14px}\n#sand-vault-0721-root .sand-1l90r2v:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:16px}\n#sand-vault-0721-root .sand-84yb8i:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:28px}\n#sand-vault-0721-root .sand-jkvuk6:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:4px}\n#sand-vault-0721-root .sand-s9asl8:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:5px}\n#sand-vault-0721-root .sand-10b6aqq:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:6px}\n#sand-vault-0721-root .sand-wib8y2:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:8px}\n#sand-vault-0721-root .sand-exx8yu:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:0}\n#sand-vault-0721-root .sand-889kno:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:10px}\n#sand-vault-0721-root .sand-z9dl7a:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:12px}\n#sand-vault-0721-root .sand-yinxu5:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:14px}\n#sand-vault-0721-root .sand-yamay9:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:16px}\n#sand-vault-0721-root .sand-1xy6bms:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:22px}\n#sand-vault-0721-root .sand-yqdw3p:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:3px}\n#sand-vault-0721-root .sand-1iorvi4:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:4px}\n#sand-vault-0721-root .sand-123j3cw:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:5px}\n#sand-vault-0721-root .sand-1yrsyyn:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:6px}\n#sand-vault-0721-root .sand-1y1aw1k:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-top:8px}\n#sand-vault-0721-root .sand-xk6nc9:not(#\\#):not(#\\#):not(#\\#):not(#\\#){top:3px}\n#sand-vault-0721-root .sand-fr5jun:not(#\\#):not(#\\#):not(#\\#):not(#\\#){top:8px}\n#sand-vault-0721-root .sand-h8yej3:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:100%}\n#sand-vault-0721-root .sand-6jxa94:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:14px}\n#sand-vault-0721-root .sand-1kky2od:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:16px}\n#sand-vault-0721-root .sand-zjbwwf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:180px}\n#sand-vault-0721-root .sand-1xp8n7a:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:18px}\n#sand-vault-0721-root .sand-w4jnvo:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:20px}\n#sand-vault-0721-root .sand-17z2i9w:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:22px}\n#sand-vault-0721-root .sand-vy4d1p:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:24px}\n#sand-vault-0721-root .sand-1dz1jew:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:280px}\n#sand-vault-0721-root .sand-gd8bvy:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:28px}\n#sand-vault-0721-root .sand-1849jeq:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:30px}\n#sand-vault-0721-root .sand-1td3qas:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:32px}\n#sand-vault-0721-root .sand-187nhsf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:44px}\n#sand-vault-0721-root .sand-3x2bpi:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:46px}\n#sand-vault-0721-root .sand-1useyqa:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:48px}\n#sand-vault-0721-root .sand-1v4s8kt:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:6px}\n#sand-vault-0721-root .sand-jzaux3:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:92px}\n#sand-vault-0721-root .sand-eq5yr9:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:fit-content}\n#sand-vault-0721-root .sand-1dxpara:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(320px,100vw - 32px)}\n#sand-vault-0721-root .sand-1ove4c:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(360px,100vw - 32px)}\n#sand-vault-0721-root .sand-11f3qql:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(380px,100vw - 32px)}\n#sand-vault-0721-root .sand-btpsn6:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(400px,100vw - 32px)}\n#sand-vault-0721-root .sand-8xl5fk:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(420px,100vw - 32px)}\n#sand-vault-0721-root .sand-glnbif:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(432px,100vw - 32px)}\n#sand-vault-0721-root .sand-cyy4kf:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(440px,100vw - 32px)}\n#sand-vault-0721-root .sand-jbg27m:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(460px,100vw - 32px)}\n#sand-vault-0721-root .sand-sjcku0:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(480px,100vw - 32px)}\n#sand-vault-0721-root .sand-mk5fll:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(500px,100vw - 32px)}\n#sand-vault-0721-root .sand-v9tjks:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(520px,100vw - 32px)}\n#sand-vault-0721-root .sand-1xakwtq:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(529px,100vw - 32px)}\n#sand-vault-0721-root .sand-pf5iwd:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:min(608px,100vw - 32px)}\n#sand-vault-0721-root .sand-mjrt60:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:var(--cursor-spacing-8)}\n#sand-vault-0721-root .sand-5lhr3w:not(#\\#):not(#\\#):not(#\\#):not(#\\#){width:var(--x-width)}\n#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-overflow]) .sand-1aecepv.sand-1aecepv:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-bottom:0}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-has-reply]) .sand-1sl1sun.sand-1sl1sun:not(#\\#):not(#\\#):not(#\\#):not(#\\#){margin-top:0}\n#sand-vault-0721-root{max-width:none}\n#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-overflow]) .sand-1k0tb1a.sand-1k0tb1a:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:8.25px}\n#sand-vault-0721-root :where(.sand--default-marker[data-voice-memo-transcript-overflow]) .sand-ki8jp5.sand-ki8jp5:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:8px}\n#sand-vault-0721-root .sand-1g31smg:first-child:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-top-width:0}\n#sand-vault-0721-root .sand-1t1lzn6:last-child:not(#\\#):not(#\\#):not(#\\#):not(#\\#){border-bottom-width:0}\n#sand-vault-0721-root .sand-170u2dc:last-child:not(#\\#):not(#\\#):not(#\\#):not(#\\#){padding-bottom:16px}\n#sand-vault-0721-root .sand-9xsh1y:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar-thumb{border-radius:var(--cursor-radius-full)}\n#sand-vault-0721-root .sand-122zoth:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar-track{background-color:#0000}\n#sand-vault-0721-root .sand-163ohqv:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before,#sand-vault-0721-root .sand-1n7skvc:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):after{background-color:var(--sand-border-secondary-translucent)}\n#sand-vault-0721-root .sand-1htvni2:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar-thumb{background-color:var(--sand-border-tertiary-translucent)}\n#sand-vault-0721-root .sand-1gvdfu:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::placeholder,#sand-vault-0721-root .sand-1uevlnz:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{color:var(--sand-text-quaternary)}\n#sand-vault-0721-root .sand-1b0dx11:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::placeholder{color:var(--sand-text-secondary)}\n#sand-vault-0721-root .sand-1h7ufjq:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::placeholder{color:var(--sand-text-tertiary)}\n#sand-vault-0721-root .sand-100rkj9:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):after,#sand-vault-0721-root .sand-1cpjm7i:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before,#sand-vault-0721-root .sand-1s928wv:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):after{content:\"\"}\n#sand-vault-0721-root .sand-1hcrkkg:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-search-cancel-button{display:none}\n#sand-vault-0721-root .sand-10bxx3s:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before,#sand-vault-0721-root .sand-71tlqn:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):after{flex-grow:1}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-highlighted]) .sand-8vq1ef.sand-8vq1ef:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{animation-name:sand-zzcn73-B}\n#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-highlighted]) .sand-17i7h53.sand-17i7h53:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{content:\"\"}\n#sand-vault-0721-root .sand-1gb0fpc:hover:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar-thumb{background-color:var(--sand-border-secondary-translucent)}\n@media (prefers-reduced-motion:reduce){#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-highlighted]) .sand-1m7bgnx.sand-1m7bgnx.sand-1m7bgnx:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{animation-name:none}#sand-vault-0721-root :where(.sand--default-marker.sand-transcript-row[data-highlighted]) .sand-1nzs1mw.sand-1nzs1mw.sand-1nzs1mw:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{box-shadow:0 0 0 3px var(--sand-text-primary)}}\n#sand-vault-0721-root .sand-1psy2a1:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):after,#sand-vault-0721-root .sand-cmm1j9:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):before{height:.5px}\n#sand-vault-0721-root .sand-y2251v:not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#):not(#\\#)::-webkit-scrollbar{width:6px}\n#sand-vault-0721-root .sand-anchor-flash{border-radius:6px;animation:1.6s ease-out sand-anchor-flash}\n@keyframes sand-zzcn73-B{0%{box-shadow:0 0 0 0 var(--sand-text-primary)}8%{box-shadow:0 0 0 3px var(--sand-text-primary)}40%{box-shadow:0 0 0 3px var(--sand-text-primary)}to{box-shadow:0 0 0 3px #0000}}\n@keyframes sand-18re5ia-B{0%{opacity:0}to{opacity:1}}\n@keyframes sand-aj6w25-B{0%{opacity:0;transform:scale(.985)}to{opacity:1;transform:scale(1)}}\n@keyframes sand-1im2lgs-B{0%{opacity:0;transform:translateY(12px)scale(.94)}55%{opacity:1}to{opacity:1;transform:translateY(0)scale(1)}}\n@keyframes sand-1wc8ddo-B{0%{transform:rotate(0)}to{transform:rotate(360deg)}}\n@keyframes sand-1rqlz9z-B{0%{transform:translateY(12px)}to{transform:translateY(0)}}\n@keyframes sand-anchor-flash{0%,60%{background-color:color-mix(in srgb, var(--sand-bg-primary) 12%, transparent)}to{background-color:#0000}}";// ../../../../../private/dist/renderer/assets/chunk-rolldown-runtime-C0FnF6B9.js var e = Object.create; var t = Object.defineProperty; var n = Object.getOwnPropertyDescriptor; var r = Object.getOwnPropertyNames; var i = Object.getPrototypeOf; var a = Object.prototype.hasOwnProperty; -var s = (e9, t2) => () => (t2 || (e9((t2 = { exports: {} }).exports, t2), e9 = null), t2.exports); -var l = (e9, i3, o3, s3) => { - if (i3 && typeof i3 == `object` || typeof i3 == `function`) for (var c2 = r(i3), l4 = 0, u3 = c2.length, d3; l4 < u3; l4++) d3 = c2[l4], !a.call(e9, d3) && d3 !== o3 && t(e9, d3, { get: ((e10) => i3[e10]).bind(null, d3), enumerable: !(s3 = n(i3, d3)) || s3.enumerable }); - return e9; +var s = (e38, t2) => () => (t2 || (e38((t2 = { exports: {} }).exports, t2), e38 = null), t2.exports); +var l = (e38, i3, o3, s3) => { + if (i3 && typeof i3 == `object` || typeof i3 == `function`) for (var c3 = r(i3), l5 = 0, u3 = c3.length, d3; l5 < u3; l5++) d3 = c3[l5], !a.call(e38, d3) && d3 !== o3 && t(e38, d3, { get: ((e39) => i3[e39]).bind(null, d3), enumerable: !(s3 = n(i3, d3)) || s3.enumerable }); + return e38; }; var u = (n2, r2, o3) => (o3 = n2 == null ? {} : e(i(n2)), l(r2 || !n2 || !n2.__esModule || !a.call(n2, `default`) ? t(o3, `default`, { value: n2, enumerable: true }) : o3, n2)); -// ../../../../../private/dist/renderer/assets/index.eager-common-BH0hmUYG.js +// ../../../../../private/dist/renderer/assets/index.eager-common-F4Y1-gMW.js function sandVaultReact() { return globalThis.__sandVaultReact; } var performance = globalThis.performance; -function o(e9) { - return e9; +function o(e38) { + return e38; } -var s2 = { now: () => Date.now(), monotonicNow: () => o(performance.now()), schedule(e9, t2, n2) { - l2(e9); +var s2 = { now: () => Date.now(), monotonicNow: () => o(performance.now()), schedule(e38, t2, n2) { + l2(e38); let r2 = true, i3 = globalThis.setTimeout(() => { r2 && (r2 = false, t2()); - }, e9); + }, e38); return n2?.keepEventLoopAlive !== true && c(i3) && i3.unref(), { dispose() { r2 && (r2 = false, globalThis.clearTimeout(i3)); } }; } }; -function c(e9) { - return typeof e9 == `object` && !!e9 && `unref` in e9 && typeof e9.unref == `function`; +function c(e38) { + return typeof e38 == `object` && !!e38 && `unref` in e38 && typeof e38.unref == `function`; } -function l2(e9) { - if (!Number.isFinite(e9) || e9 < 0) throw RangeError(`delayMs must be a finite non-negative number`); +function l2(e38) { + if (!Number.isFinite(e38) || e38 < 0) throw RangeError(`delayMs must be a finite non-negative number`); } -var R = (e9) => typeof e9 == `string`; -var re = (e9) => typeof e9 == `function`; -var ie = /* @__PURE__ */ new Map(); -var ae = `en`; -function oe(e9) { - return [...Array.isArray(e9) ? e9 : [e9], ae]; +var N = (e38) => typeof e38 == `string`; +var ce = (e38) => typeof e38 == `function`; +var le = /* @__PURE__ */ new Map(); +var ue = `en`; +function de(e38) { + return [...Array.isArray(e38) ? e38 : [e38], ue]; } -function se(e9, t2, n2) { - let r2 = oe(e9); +function fe(e38, t2, n2) { + let r2 = de(e38); n2 ||= `default`; let i3; if (typeof n2 == `string`) switch (i3 = { day: `numeric`, month: `short`, year: `numeric` }, n2) { @@ -56,9 +56,9 @@ function se(e9, t2, n2) { i3.month = `numeric`; } else i3 = n2; - return B(() => V(`date`, r2, n2), () => new Intl.DateTimeFormat(r2, i3)).format(R(t2) ? new Date(t2) : t2); + return ge(() => _e(`date`, r2, n2), () => new Intl.DateTimeFormat(r2, i3)).format(N(t2) ? new Date(t2) : t2); } -function ce(e9, t2, n2) { +function pe(e38, t2, n2) { let r2; if (n2 ||= `default`, typeof n2 == `string`) switch (r2 = { second: `numeric`, minute: `numeric`, hour: `numeric` }, n2) { case `full`: @@ -69,100 +69,100 @@ function ce(e9, t2, n2) { delete r2.second; } else r2 = n2; - return se(e9, t2, r2); + return fe(e38, t2, r2); } -function z(e9, t2, n2) { - let r2 = oe(e9); - return B(() => V(`number`, r2, n2), () => new Intl.NumberFormat(r2, n2)).format(t2); +function me(e38, t2, n2) { + let r2 = de(e38); + return ge(() => _e(`number`, r2, n2), () => new Intl.NumberFormat(r2, n2)).format(t2); } -function le(e9, t2, n2, { offset: r2 = 0, ...i3 }) { - let a3 = oe(e9), o3 = t2 ? B(() => V(`plural-ordinal`, a3), () => new Intl.PluralRules(a3, { type: `ordinal` })) : B(() => V(`plural-cardinal`, a3), () => new Intl.PluralRules(a3, { type: `cardinal` })); +function he(e38, t2, n2, { offset: r2 = 0, ...i3 }) { + let a3 = de(e38), o3 = t2 ? ge(() => _e(`plural-ordinal`, a3), () => new Intl.PluralRules(a3, { type: `ordinal` })) : ge(() => _e(`plural-cardinal`, a3), () => new Intl.PluralRules(a3, { type: `cardinal` })); return i3[n2] ?? i3[o3.select(n2 - r2)] ?? i3.other; } -function B(e9, t2) { - let n2 = e9(), r2 = ie.get(n2); - return r2 || (r2 = t2(), ie.set(n2, r2)), r2; +function ge(e38, t2) { + let n2 = e38(), r2 = le.get(n2); + return r2 || (r2 = t2(), le.set(n2, r2)), r2; } -function V(e9, t2, n2) { - return `${e9}-${t2.join(`-`)}-${JSON.stringify(n2)}`; +function _e(e38, t2, n2) { + return `${e38}-${t2.join(`-`)}-${JSON.stringify(n2)}`; } -var ue = /\\u[a-fA-F0-9]{4}|\\x[a-fA-F0-9]{2}/; -var de = (e9) => e9.replace(/\\u([a-fA-F0-9]{4})|\\x([a-fA-F0-9]{2})/g, (e10, t2, n2) => { +var ve = /\\u[a-fA-F0-9]{4}|\\x[a-fA-F0-9]{2}/; +var ye = (e38) => e38.replace(/\\u([a-fA-F0-9]{4})|\\x([a-fA-F0-9]{2})/g, (e39, t2, n2) => { if (t2) { - let e11 = parseInt(t2, 16); - return String.fromCharCode(e11); + let e40 = parseInt(t2, 16); + return String.fromCharCode(e40); } { - let e11 = parseInt(n2, 16); - return String.fromCharCode(e11); + let e40 = parseInt(n2, 16); + return String.fromCharCode(e40); } }); -var fe = `%__lingui_octothorpe__%`; -var pe = (e9, t2, n2 = {}) => { - let r2 = t2 || e9, i3 = (e10) => typeof e10 == `object` ? e10 : n2[e10], a3 = (e10, t3) => { - let a4 = Object.keys(n2).length ? i3(`number`) : void 0, o3 = z(r2, e10, a4); - return t3.replace(new RegExp(fe, `g`), o3); +var be = `%__lingui_octothorpe__%`; +var xe = (e38, t2, n2 = {}) => { + let r2 = t2 || e38, i3 = (e39) => typeof e39 == `object` ? e39 : n2[e39], a3 = (e39, t3) => { + let a4 = Object.keys(n2).length ? i3(`number`) : void 0, o3 = me(r2, e39, a4); + return t3.replace(new RegExp(be, `g`), o3); }; - return { plural: (e10, t3) => { - let { offset: n3 = 0 } = t3, i4 = le(r2, false, e10, t3); - return a3(e10 - n3, i4); - }, selectordinal: (e10, t3) => { - let { offset: n3 = 0 } = t3, i4 = le(r2, true, e10, t3); - return a3(e10 - n3, i4); - }, select: me, number: (e10, t3) => z(r2, e10, i3(t3) || { style: t3 }), date: (e10, t3) => se(r2, e10, i3(t3) || t3), time: (e10, t3) => ce(r2, e10, i3(t3) || t3) }; + return { plural: (e39, t3) => { + let { offset: n3 = 0 } = t3, i4 = he(r2, false, e39, t3); + return a3(e39 - n3, i4); + }, selectordinal: (e39, t3) => { + let { offset: n3 = 0 } = t3, i4 = he(r2, true, e39, t3); + return a3(e39 - n3, i4); + }, select: Se, number: (e39, t3) => me(r2, e39, i3(t3) || { style: t3 }), date: (e39, t3) => fe(r2, e39, i3(t3) || t3), time: (e39, t3) => pe(r2, e39, i3(t3) || t3) }; }; -var me = (e9, t2) => t2[e9] ?? t2.other; -function he(e9, t2, n2) { +var Se = (e38, t2) => t2[e38] ?? t2.other; +function Ce(e38, t2, n2) { return (r2 = {}, i3) => { - let a3 = pe(t2, n2, i3), o3 = (e10, t3 = false) => Array.isArray(e10) ? e10.reduce((e11, n3) => { - if (n3 === `#` && t3) return e11 + fe; - if (R(n3)) return e11 + n3; - let [i4, s4, c2] = n3, l4 = {}; - s4 === `plural` || s4 === `selectordinal` || s4 === `select` ? Object.entries(c2).forEach(([e12, t4]) => { - l4[e12] = o3(t4, s4 === `plural` || s4 === `selectordinal`); - }) : l4 = c2; + let a3 = xe(t2, n2, i3), o3 = (e39, t3 = false) => Array.isArray(e39) ? e39.reduce((e40, n3) => { + if (n3 === `#` && t3) return e40 + be; + if (N(n3)) return e40 + n3; + let [i4, s4, c3] = n3, l5 = {}; + s4 === `plural` || s4 === `selectordinal` || s4 === `select` ? Object.entries(c3).forEach(([e41, t4]) => { + l5[e41] = o3(t4, s4 === `plural` || s4 === `selectordinal`); + }) : l5 = c3; let u3; if (s4) { - let e12 = a3[s4]; - u3 = e12(r2[i4], l4); + let e41 = a3[s4]; + u3 = e41(r2[i4], l5); } else u3 = r2[i4]; - return u3 == null ? e11 : e11 + u3; - }, ``) : e10, s3 = o3(e9); - return R(s3) && ue.test(s3) ? de(s3) : R(s3) ? s3 : s3 ? String(s3) : ``; + return u3 == null ? e40 : e40 + u3; + }, ``) : e39, s3 = o3(e38); + return N(s3) && ve.test(s3) ? ye(s3) : N(s3) ? s3 : s3 ? String(s3) : ``; }; } -var ge = Object.defineProperty; -var _e = (e9, t2, n2) => t2 in e9 ? ge(e9, t2, { enumerable: true, configurable: true, writable: true, value: n2 }) : e9[t2] = n2; -var ve = (e9, t2, n2) => (_e(e9, typeof t2 == `symbol` ? t2 : t2 + ``, n2), n2); -var ye = class { +var we = Object.defineProperty; +var Te = (e38, t2, n2) => t2 in e38 ? we(e38, t2, { enumerable: true, configurable: true, writable: true, value: n2 }) : e38[t2] = n2; +var Ee = (e38, t2, n2) => (Te(e38, typeof t2 == `symbol` ? t2 : t2 + ``, n2), n2); +var De = class { constructor() { - ve(this, `_events`, {}); + Ee(this, `_events`, {}); } - on(e9, t2) { + on(e38, t2) { var n2; - return (n2 = this._events)[e9] ?? (n2[e9] = []), this._events[e9].push(t2), () => this.removeListener(e9, t2); + return (n2 = this._events)[e38] ?? (n2[e38] = []), this._events[e38].push(t2), () => this.removeListener(e38, t2); } - removeListener(e9, t2) { - let n2 = this._getListeners(e9); + removeListener(e38, t2) { + let n2 = this._getListeners(e38); if (!n2) return; let r2 = n2.indexOf(t2); ~r2 && n2.splice(r2, 1); } - emit(e9, ...t2) { - let n2 = this._getListeners(e9); - n2 && n2.map((e10) => e10.apply(this, t2)); + emit(e38, ...t2) { + let n2 = this._getListeners(e38); + n2 && n2.map((e39) => e39.apply(this, t2)); } - _getListeners(e9) { - let t2 = this._events[e9]; + _getListeners(e38) { + let t2 = this._events[e38]; return Array.isArray(t2) ? t2 : false; } }; -var be = Object.defineProperty; -var xe = (e9, t2, n2) => t2 in e9 ? be(e9, t2, { enumerable: true, configurable: true, writable: true, value: n2 }) : e9[t2] = n2; -var H = (e9, t2, n2) => (xe(e9, typeof t2 == `symbol` ? t2 : t2 + ``, n2), n2); -var Se = class extends ye { - constructor(e9) { - super(), H(this, `_locale`, ``), H(this, `_locales`), H(this, `_localeData`, {}), H(this, `_messages`, {}), H(this, `_missing`), H(this, `_messageCompiler`), H(this, `t`, this._.bind(this)), e9.missing != null && (this._missing = e9.missing), e9.messages != null && this.load(e9.messages), e9.localeData != null && this.loadLocaleData(e9.localeData), (typeof e9.locale == `string` || e9.locales) && this.activate(e9.locale ?? ae, e9.locales); +var Oe = Object.defineProperty; +var ke = (e38, t2, n2) => t2 in e38 ? Oe(e38, t2, { enumerable: true, configurable: true, writable: true, value: n2 }) : e38[t2] = n2; +var Ae = (e38, t2, n2) => (ke(e38, typeof t2 == `symbol` ? t2 : t2 + ``, n2), n2); +var je = class extends De { + constructor(e38) { + super(), Ae(this, `_locale`, ``), Ae(this, `_locales`), Ae(this, `_localeData`, {}), Ae(this, `_messages`, {}), Ae(this, `_missing`), Ae(this, `_messageCompiler`), Ae(this, `t`, this._.bind(this)), e38.missing != null && (this._missing = e38.missing), e38.messages != null && this.load(e38.messages), e38.localeData != null && this.loadLocaleData(e38.localeData), (typeof e38.locale == `string` || e38.locales) && this.activate(e38.locale ?? ue, e38.locales); } get locale() { return this._locale; @@ -176,40 +176,40 @@ var Se = class extends ye { get localeData() { return this._localeData[this._locale] ?? {}; } - _loadLocaleData(e9, t2) { - let n2 = this._localeData[e9]; - n2 ? Object.assign(n2, t2) : this._localeData[e9] = t2; + _loadLocaleData(e38, t2) { + let n2 = this._localeData[e38]; + n2 ? Object.assign(n2, t2) : this._localeData[e38] = t2; } - setMessagesCompiler(e9) { - return this._messageCompiler = e9, this; + setMessagesCompiler(e38) { + return this._messageCompiler = e38, this; } - loadLocaleData(e9, t2) { - typeof e9 == `string` ? this._loadLocaleData(e9, t2) : Object.keys(e9).forEach((t3) => this._loadLocaleData(t3, e9[t3])), this.emit(`change`); + loadLocaleData(e38, t2) { + typeof e38 == `string` ? this._loadLocaleData(e38, t2) : Object.keys(e38).forEach((t3) => this._loadLocaleData(t3, e38[t3])), this.emit(`change`); } - _load(e9, t2) { - let n2 = this._messages[e9]; - n2 ? Object.assign(n2, t2) : this._messages[e9] = t2; + _load(e38, t2) { + let n2 = this._messages[e38]; + n2 ? Object.assign(n2, t2) : this._messages[e38] = t2; } - load(e9, t2) { - typeof e9 == `string` && typeof t2 == `object` ? this._load(e9, t2) : Object.entries(e9).forEach(([e10, t3]) => this._load(e10, t3)), this.emit(`change`); + load(e38, t2) { + typeof e38 == `string` && typeof t2 == `object` ? this._load(e38, t2) : Object.entries(e38).forEach(([e39, t3]) => this._load(e39, t3)), this.emit(`change`); } - loadAndActivate({ locale: e9, locales: t2, messages: n2 }) { - this._locale = e9, this._locales = t2 || void 0, this._messages[this._locale] = n2, this.emit(`change`); + loadAndActivate({ locale: e38, locales: t2, messages: n2 }) { + this._locale = e38, this._locales = t2 || void 0, this._messages[this._locale] = n2, this.emit(`change`); } - activate(e9, t2) { - this._locale = e9, this._locales = t2, this.emit(`change`); + activate(e38, t2) { + this._locale = e38, this._locales = t2, this.emit(`change`); } - _(e9, t2, n2) { + _(e38, t2, n2) { if (!this.locale) throw Error(`Lingui: Attempted to call a translation function without setting a locale. Make sure to call \`i18n.activate(locale)\` before using Lingui functions. This issue may also occur due to a race condition in your initialization logic.`); let r2 = n2?.message; - e9 ||= ``, R(e9) || (t2 = e9.values || t2, r2 = e9.message, e9 = e9.id); - let i3 = this.messages[e9], a3 = i3 === void 0, o3 = this._missing; - if (o3 && a3) return re(o3) ? o3(this._locale, e9) : o3; - a3 && this.emit(`missing`, { id: e9, locale: this._locale }); - let s3 = i3 || r2 || e9; - return R(s3) && (this._messageCompiler ? s3 = this._messageCompiler(s3) : console.warn(`Uncompiled message detected! Message: + e38 ||= ``, N(e38) || (t2 = e38.values || t2, r2 = e38.message, e38 = e38.id); + let i3 = this.messages[e38], a3 = i3 === void 0, o3 = this._missing; + if (o3 && a3) return ce(o3) ? o3(this._locale, e38) : o3; + a3 && this.emit(`missing`, { id: e38, locale: this._locale }); + let s3 = i3 || r2 || e38; + return N(s3) && (this._messageCompiler ? s3 = this._messageCompiler(s3) : console.warn(`Uncompiled message detected! Message: > ${s3} @@ -217,80 +217,84 @@ That means you use raw catalog or your catalog doesn't have a translation for th ICU features such as interpolation and plurals will not work properly for that message. Please compile your catalog first. -`)), R(s3) && ue.test(s3) ? de(s3) : R(s3) ? s3 : he(s3, this._locale, this._locales)(t2, n2?.formats); +`)), N(s3) && ve.test(s3) ? ye(s3) : N(s3) ? s3 : Ce(s3, this._locale, this._locales)(t2, n2?.formats); } - date(e9, t2) { - return se(this._locales || this._locale, e9, t2); + date(e38, t2) { + return fe(this._locales || this._locale, e38, t2); } - number(e9, t2) { - return z(this._locales || this._locale, e9, t2); + number(e38, t2) { + return me(this._locales || this._locale, e38, t2); } }; -function Ce(e9 = {}) { - return new Se(e9); +function Me(e38 = {}) { + return new je(e38); } -var U = Ce(); -var we = class extends Error { - constructor(e9) { - super(e9), this.name = `SandInvariantViolation`; +var P = Me(); +var Ne = class extends Error { + constructor(e38) { + super(e38), this.name = `SandInvariantViolation`; } }; -var W = null; -var Ee = `Invariant violation (message stripped in packaged builds; the stack identifies the site)`; -function De() { +var Pe = null; +var Ie = `Invariant violation (message stripped in packaged builds; the stack identifies the site)`; +function Le() { return true; } -var Oe = /^at /; -function ke(e9) { - let t2 = e9.stack; - if (typeof t2 != `string` || !t2.startsWith(Ae(e9))) return null; - for (let n2 of t2.slice(Ae(e9).length).split(` +var Re = /^at /; +function ze(e38) { + let t2 = e38.stack; + if (typeof t2 != `string` || !t2.startsWith(Be(e38))) return null; + for (let n2 of t2.slice(Be(e38).length).split(` `)) { - let e10 = n2.trim(); - if (Oe.test(e10)) return e10; + let e39 = n2.trim(); + if (Re.test(e39)) return e39; } return null; } -function Ae(e9) { - return e9.message === `` ? e9.name : `${e9.name}: ${e9.message}`; +function Be(e38) { + return e38.message === `` ? e38.name : `${e38.name}: ${e38.message}`; } -function G(e9, t2) { - e9 || je(t2, G); +function Ve(e38, t2) { + e38 || He(t2, Ve); } -function je(e9, t2) { +function He(e38, t2) { let n2; - n2 = De() ? Ee : typeof e9 == `function` ? e9() : e9; - let r2 = new we(n2), i3 = null; - throw `captureStackTrace` in Error && typeof Error.captureStackTrace == `function` && (Error.captureStackTrace(r2, t2), W !== null && (i3 = ke(r2))), W?.({ name: r2.name, frame: i3 }), r2; + n2 = Le() ? Ie : typeof e38 == `function` ? e38() : e38; + let r2 = new Ne(n2), i3 = null; + throw `captureStackTrace` in Error && typeof Error.captureStackTrace == `function` && (Error.captureStackTrace(r2, t2), Pe !== null && (i3 = ze(r2))), Pe?.({ name: r2.name, frame: i3 }), r2; } -var Ge = s(((e9) => { +var rt = s(((e38) => { var t2 = /* @__PURE__ */ Symbol.for(`react.transitional.element`), n2 = /* @__PURE__ */ Symbol.for(`react.fragment`); - function r2(e10, n3, r3) { + function r2(e39, n3, r3) { var i3 = null; if (r3 !== void 0 && (i3 = `` + r3), n3.key !== void 0 && (i3 = `` + n3.key), `key` in n3) for (var a3 in r3 = {}, n3) a3 !== `key` && (r3[a3] = n3[a3]); else r3 = n3; - return n3 = r3.ref, { $$typeof: t2, type: e10, key: i3, ref: n3 === void 0 ? null : n3, props: r3 }; + return n3 = r3.ref, { $$typeof: t2, type: e39, key: i3, ref: n3 === void 0 ? null : n3, props: r3 }; } - e9.Fragment = n2, e9.jsx = r2, e9.jsxs = r2; + e38.Fragment = n2, e38.jsx = r2, e38.jsxs = r2; })); -var Ke = s(((e9, t2) => { - t2.exports = Ge(); +var it = s(((e38, t2) => { + t2.exports = rt(); })); -function nt(e9) { - return typeof e9 == `object` && !!e9 && !Array.isArray(e9); +function mt(e38) { + return typeof e38 == `object` && !!e38 && !Array.isArray(e38); } -function _t(e9) { +function fn(e38) { let t2; return () => { - let n2 = U.locale; - return (t2 == null || t2.locale !== n2) && (t2 = { locale: n2, value: e9(n2, t2?.value) }), t2.value; + let n2 = P.locale; + return (t2 == null || t2.locale !== n2) && (t2 = { locale: n2, value: e38(n2, t2?.value) }), t2.value; }; } -// ../../../../../private/dist/renderer/assets/index.eager-vendor-cR6BHVc-.js +// ../../../../../private/dist/renderer/assets/index.eager-vendor-CRCbzhle.js var window = globalThis.window; var document = globalThis.document; var HTMLElement = globalThis.HTMLElement; +var Event = globalThis.Event; +var KeyboardEvent = globalThis.KeyboardEvent; +var IntersectionObserver = globalThis.IntersectionObserver; +var MutationObserver = globalThis.MutationObserver; var ResizeObserver = globalThis.ResizeObserver; var cancelAnimationFrame = globalThis.cancelAnimationFrame; var getComputedStyle = globalThis.getComputedStyle; @@ -301,16 +305,17 @@ var CSS = globalThis.CSS; var Element = globalThis.Element; var Node = globalThis.Node; var ShadowRoot = globalThis.ShadowRoot; +var performance2 = globalThis.performance; var d = {}; var f; function p() { if (f) return d; f = 1, Object.defineProperty(d, "__esModule", { value: true }), d.styleq = void 0; - var e9 = /* @__PURE__ */ new WeakMap(), t2 = `$$css`; + var e38 = /* @__PURE__ */ new WeakMap(), t2 = `$$css`; function n2(n3) { var r3, i3, a3; return n3 != null && (r3 = n3.disableCache === true, i3 = n3.disableMix === true, a3 = n3.transform), function() { - for (var n4 = [], o3 = ``, s3 = null, c2 = ``, l4 = r3 ? null : e9, u3 = Array(arguments.length), d3 = 0; d3 < arguments.length; d3++) u3[d3] = arguments[d3]; + for (var n4 = [], o3 = ``, s3 = null, c3 = ``, l5 = r3 ? null : e38, u3 = Array(arguments.length), d3 = 0; d3 < arguments.length; d3++) u3[d3] = arguments[d3]; for (; u3.length > 0; ) { var f4 = u3.pop(); if (f4 != null && f4 !== false) { @@ -320,121 +325,121 @@ function p() { } var m3 = a3 == null ? f4 : a3(f4); if (m3.$$css != null) { - var h3 = ``; - if (l4 != null && l4.has(m3)) { - var g3 = l4.get(m3); - g3 != null && (h3 = g3[0], c2 = g3[2], n4.push.apply(n4, g3[1]), l4 = g3[3]); + var h4 = ``; + if (l5 != null && l5.has(m3)) { + var g5 = l5.get(m3); + g5 != null && (h4 = g5[0], c3 = g5[2], n4.push.apply(n4, g5[1]), l5 = g5[3]); } else { - var _2 = []; - for (var v3 in m3) { - var y3 = m3[v3]; - if (v3 === t2) { - var b3 = m3[v3]; - b3 !== true && (c2 = c2 ? b3 + `; ` + c2 : b3); + var _5 = []; + for (var v5 in m3) { + var y4 = m3[v5]; + if (v5 === t2) { + var b2 = m3[v5]; + b2 !== true && (c3 = c3 ? b2 + `; ` + c3 : b2); continue; } - typeof y3 == `string` || y3 === null ? n4.includes(v3) || (n4.push(v3), l4 != null && _2.push(v3), typeof y3 == `string` && (h3 += h3 ? ` ` + y3 : y3)) : console.error(`styleq: ${v3} typeof ${String(y3)} is not "string" or "null".`); + typeof y4 == `string` || y4 === null ? n4.includes(v5) || (n4.push(v5), l5 != null && _5.push(v5), typeof y4 == `string` && (h4 += h4 ? ` ` + y4 : y4)) : console.error(`styleq: ${v5} typeof ${String(y4)} is not "string" or "null".`); } - if (l4 != null) { - var x3 = /* @__PURE__ */ new WeakMap(); - l4.set(m3, [h3, _2, c2, x3]), l4 = x3; + if (l5 != null) { + var x2 = /* @__PURE__ */ new WeakMap(); + l5.set(m3, [h4, _5, c3, x2]), l5 = x2; } } - h3 && (o3 = o3 ? h3 + ` ` + o3 : h3); + h4 && (o3 = o3 ? h4 + ` ` + o3 : h4); } else if (i3) s3 ??= {}, s3 = Object.assign({}, m3, s3); else { - var S3 = null; + var S2 = null; for (var C2 in m3) { - var w3 = m3[C2]; - w3 !== void 0 && (n4.includes(C2) || (w3 != null && (s3 ??= {}, S3 ??= {}, S3[C2] = w3), n4.push(C2), l4 = null)); + var w2 = m3[C2]; + w2 !== void 0 && (n4.includes(C2) || (w2 != null && (s3 ??= {}, S2 ??= {}, S2[C2] = w2), n4.push(C2), l5 = null)); } - S3 != null && (s3 = Object.assign(S3, s3)); + S2 != null && (s3 = Object.assign(S2, s3)); } } } - return [o3, s3, c2]; + return [o3, s3, c3]; }; } var r2 = d.styleq = n2(); return r2.factory = n2, d; } var m = p(); -function h(...e9) { - let [t2, n2, r2] = m.styleq(e9), i3 = {}; +function h(...e38) { + let [t2, n2, r2] = m.styleq(e38), i3 = {}; return t2 != null && t2 !== `` && (i3.className = t2), n2 != null && Object.keys(n2).length > 0 && (i3.style = n2), r2 != null && r2 !== `` && (i3[`data-style-src`] = r2), i3; } -function v(e9) { +function v(e38) { var t2, n2, r2 = ``; - if (typeof e9 == `string` || typeof e9 == `number`) r2 += e9; - else if (typeof e9 == `object`) { - if (Array.isArray(e9)) { - var i3 = e9.length; - for (t2 = 0; t2 < i3; t2++) e9[t2] && (n2 = v(e9[t2])) && (r2 && (r2 += ` `), r2 += n2); - } else for (n2 in e9) e9[n2] && (r2 && (r2 += ` `), r2 += n2); + if (typeof e38 == `string` || typeof e38 == `number`) r2 += e38; + else if (typeof e38 == `object`) { + if (Array.isArray(e38)) { + var i3 = e38.length; + for (t2 = 0; t2 < i3; t2++) e38[t2] && (n2 = v(e38[t2])) && (r2 && (r2 += ` `), r2 += n2); + } else for (n2 in e38) e38[n2] && (r2 && (r2 += ` `), r2 += n2); } return r2; } function y() { - for (var e9, t2, n2 = 0, r2 = ``, i3 = arguments.length; n2 < i3; n2++) (e9 = arguments[n2]) && (t2 = v(e9)) && (r2 && (r2 += ` `), r2 += t2); + for (var e38, t2, n2 = 0, r2 = ``, i3 = arguments.length; n2 < i3; n2++) (e38 = arguments[n2]) && (t2 = v(e38)) && (r2 && (r2 += ` `), r2 += t2); return r2; } -var b = Ke(); +var b = it(); var x = u(sandVaultReact(), 1); -function S(e9, t2) { +function S(e38, t2) { return function(n2, ...r2) { - let i3 = new URL(e9); - return i3.searchParams.set(`code`, n2.toString()), r2.forEach((e10) => i3.searchParams.append(`args[]`, e10)), `${t2} error #${n2}; visit ${i3} for the full message.`; + let i3 = new URL(e38); + return i3.searchParams.set(`code`, n2.toString()), r2.forEach((e39) => i3.searchParams.append(`args[]`, e39)), `${t2} error #${n2}; visit ${i3} for the full message.`; }; } var C = S(`https://base-ui.com/production-error`, `Base UI`); var w = {}; -function T(e9, t2) { +function T(e38, t2) { let n2 = x.useRef(w); - return n2.current === w && (n2.current = e9(t2)), n2; + return n2.current === w && (n2.current = e38(t2)), n2; } -function E(e9, t2, n2, r2) { +function E(e38, t2, n2, r2) { let i3 = T(O).current; - return k(i3, e9, t2, n2, r2) && j(i3, [e9, t2, n2, r2]), i3.callback; + return k(i3, e38, t2, n2, r2) && j(i3, [e38, t2, n2, r2]), i3.callback; } -function D(e9) { +function D(e38) { let t2 = T(O).current; - return A(t2, e9) && j(t2, e9), t2.callback; + return A(t2, e38) && j(t2, e38), t2.callback; } function O() { return { callback: null, cleanup: null, refs: [] }; } -function k(e9, t2, n2, r2, i3) { - return e9.refs[0] !== t2 || e9.refs[1] !== n2 || e9.refs[2] !== r2 || e9.refs[3] !== i3; +function k(e38, t2, n2, r2, i3) { + return e38.refs[0] !== t2 || e38.refs[1] !== n2 || e38.refs[2] !== r2 || e38.refs[3] !== i3; } -function A(e9, t2) { - return e9.refs.length !== t2.length || e9.refs.some((e10, n2) => e10 !== t2[n2]); +function A(e38, t2) { + return e38.refs.length !== t2.length || e38.refs.some((e39, n2) => e39 !== t2[n2]); } -function j(e9, t2) { - if (e9.refs = t2, t2.every((e10) => e10 == null)) { - e9.callback = null; +function j(e38, t2) { + if (e38.refs = t2, t2.every((e39) => e39 == null)) { + e38.callback = null; return; } - e9.callback = (n2) => { - if (e9.cleanup &&= (e9.cleanup(), null), n2 != null) { + e38.callback = (n2) => { + if (e38.cleanup &&= (e38.cleanup(), null), n2 != null) { let r2 = Array(t2.length).fill(null); - for (let e10 = 0; e10 < t2.length; e10 += 1) { - let i3 = t2[e10]; + for (let e39 = 0; e39 < t2.length; e39 += 1) { + let i3 = t2[e39]; if (i3 != null) switch (typeof i3) { case `function`: { let t3 = i3(n2); - typeof t3 == `function` && (r2[e10] = t3); + typeof t3 == `function` && (r2[e39] = t3); break; } case `object`: i3.current = n2; } } - e9.cleanup = () => { - for (let e10 = 0; e10 < t2.length; e10 += 1) { - let n3 = t2[e10]; + e38.cleanup = () => { + for (let e39 = 0; e39 < t2.length; e39 += 1) { + let n3 = t2[e39]; if (n3 != null) switch (typeof n3) { case `function`: { - let t3 = r2[e10]; + let t3 = r2[e39]; typeof t3 == `function` ? t3() : n3(null); break; } @@ -447,774 +452,3593 @@ function j(e9, t2) { }; } var M = 19; -function N(e9) { - return M >= e9; +function N2(e38) { + return M >= e38; +} +function P2(e38) { + if (!x.isValidElement(e38)) return null; + let t2 = e38, n2 = t2.props; + return (N2(19) ? n2?.ref : t2.ref) ?? null; } -function P(e9) { - if (!x.isValidElement(e9)) return null; - let t2 = e9, n2 = t2.props; - return (N(19) ? n2?.ref : t2.ref) ?? null; +function F(e38, t2) { + if (e38 && !t2) return e38; + if (!e38 && t2) return t2; + if (e38 || t2) return { ...e38, ...t2 }; } -function F(e9, t2) { - if (e9 && !t2) return e9; - if (!e9 && t2) return t2; - if (e9 || t2) return { ...e9, ...t2 }; +function I() { } -var R2 = Object.freeze({}); -function z2(e9, t2) { +var L = Object.freeze([]); +var R = Object.freeze({}); +function z(e38, t2) { let n2 = {}; - for (let r2 in e9) { - let i3 = e9[r2]; + for (let r2 in e38) { + let i3 = e38[r2]; if (t2?.hasOwnProperty(r2)) { - let e10 = t2[r2](i3); - e10 != null && Object.assign(n2, e10); + let e39 = t2[r2](i3); + e39 != null && Object.assign(n2, e39); continue; } i3 === true ? n2[`data-${r2.toLowerCase()}`] = `` : i3 && (n2[`data-${r2.toLowerCase()}`] = i3.toString()); } return n2; } -function ee(e9, t2) { - return typeof e9 == `function` ? e9(t2) : e9; +function ee(e38, t2) { + return typeof e38 == `function` ? e38(t2) : e38; } -function B2(e9, t2) { - return typeof e9 == `function` ? e9(t2) : e9; +function B(e38, t2) { + return typeof e38 == `function` ? e38(t2) : e38; } -var V2 = {}; -function te(e9, t2, n2, r2, i3) { - if (!n2 && !r2 && !i3 && !e9) return U2(t2); - let a3 = U2(e9); - return t2 && (a3 = W2(a3, t2)), n2 && (a3 = W2(a3, n2)), r2 && (a3 = W2(a3, r2)), i3 && (a3 = W2(a3, i3)), a3; +var V = {}; +function H(e38, t2, n2, r2, i3) { + if (!n2 && !r2 && !i3 && !e38) return W(t2); + let a3 = W(e38); + return t2 && (a3 = G(a3, t2)), n2 && (a3 = G(a3, n2)), r2 && (a3 = G(a3, r2)), i3 && (a3 = G(a3, i3)), a3; } -function H2(e9) { - if (e9.length === 0) return V2; - if (e9.length === 1) return U2(e9[0]); - let t2 = U2(e9[0]); - for (let n2 = 1; n2 < e9.length; n2 += 1) t2 = W2(t2, e9[n2]); +function U(e38) { + if (e38.length === 0) return V; + if (e38.length === 1) return W(e38[0]); + let t2 = W(e38[0]); + for (let n2 = 1; n2 < e38.length; n2 += 1) t2 = G(t2, e38[n2]); return t2; } -function U2(e9) { - return K(e9) ? { ...ie2(e9, V2) } : ne(e9); +function W(e38) { + return q(e38) ? { ...e38(V) } : te(e38); } -function W2(e9, t2) { - return K(t2) ? ie2(t2, e9) : G2(e9, t2); +function G(e38, t2) { + return q(t2) ? t2(e38) : K(e38, t2); } -function ne(e9) { - let t2 = { ...e9 }; - for (let e10 in t2) { - let n2 = t2[e10]; - re2(e10, n2) && (t2[e10] = oe2(n2)); +function te(e38) { + let t2 = { ...e38 }; + for (let e39 in t2) { + let n2 = t2[e39]; + ne(e39, n2) && (t2[e39] = ie(n2)); } return t2; } -function G2(e9, t2) { - if (!t2) return e9; +function K(e38, t2) { + if (!t2) return e38; for (let n2 in t2) { let r2 = t2[n2]; switch (n2) { case `style`: - e9[n2] = F(e9.style, r2); + e38[n2] = F(e38.style, r2); break; case `className`: - e9[n2] = ce2(e9.className, r2); + e38[n2] = oe(e38.className, r2); break; default: - e9[n2] = re2(n2, r2) ? ae2(e9[n2], r2) : r2; + e38[n2] = ne(n2, r2) ? re(e38[n2], r2) : r2; } } - return e9; + return e38; } -function re2(e9, t2) { - let n2 = e9.charCodeAt(0), r2 = e9.charCodeAt(1), i3 = e9.charCodeAt(2); +function ne(e38, t2) { + let n2 = e38.charCodeAt(0), r2 = e38.charCodeAt(1), i3 = e38.charCodeAt(2); return n2 === 111 && r2 === 110 && i3 >= 65 && i3 <= 90 && (typeof t2 == `function` || t2 === void 0); } -function K(e9) { - return typeof e9 == `function`; +function q(e38) { + return typeof e38 == `function`; } -function ie2(e9, t2) { - return K(e9) ? e9(t2) : e9 ?? V2; -} -function ae2(e9, t2) { - return t2 ? e9 ? (...n2) => { +function re(e38, t2) { + return t2 ? e38 ? (...n2) => { let r2 = n2[0]; - if (le2(r2)) { + if (se(r2)) { let i4 = r2; - se2(i4); + ae(i4); let a3 = t2(...n2); - return i4.baseUIHandlerPrevented || e9?.(...n2), a3; + return i4.baseUIHandlerPrevented || e38?.(...n2), a3; } let i3 = t2(...n2); - return e9?.(...n2), i3; - } : oe2(t2) : e9; + return e38?.(...n2), i3; + } : ie(t2) : e38; } -function oe2(e9) { - return e9 && ((...t2) => { +function ie(e38) { + return e38 && ((...t2) => { let n2 = t2[0]; - return le2(n2) && se2(n2), e9(...t2); + return se(n2) && ae(n2), e38(...t2); }); } -function se2(e9) { - return e9.preventBaseUIHandler = () => { - e9.baseUIHandlerPrevented = true; - }, e9; +function ae(e38) { + return e38.preventBaseUIHandler = () => { + e38.baseUIHandlerPrevented = true; + }, e38; } -function ce2(e9, t2) { - return t2 ? e9 ? t2 + ` ` + e9 : t2 : e9; +function oe(e38, t2) { + return t2 ? e38 ? t2 + ` ` + e38 : t2 : e38; } -function le2(e9) { - return typeof e9 == `object` && !!e9 && `nativeEvent` in e9; +function se(e38) { + return typeof e38 == `object` && !!e38 && `nativeEvent` in e38; } -function q(e9, t2, n2 = {}) { +function J(e38, t2, n2 = {}) { let r2 = t2.render; - n2.enabled !== false && (r2 = pe2(r2)); - let i3 = ue2(t2, n2, r2); + n2.enabled !== false && (r2 = de2(r2)); + let i3 = ce2(t2, n2, r2); if (n2.enabled === false) return null; - let a3 = n2.state ?? R2; - return me2(e9, r2, i3, a3); + let a3 = n2.state ?? R; + return fe2(e38, r2, i3, a3); } -function ue2(e9, t2, n2) { - let { className: r2, style: i3 } = e9, { state: a3 = R2, ref: o3, props: s3, stateAttributesMapping: c2, enabled: l4 = true } = t2, u3 = l4 ? ee(r2, a3) : void 0, d3 = l4 ? B2(i3, a3) : void 0, f4 = l4 ? z2(a3, c2) : R2, p4 = l4 && s3 ? de2(s3) : void 0, m3 = l4 ? F(f4, p4) ?? {} : R2; - return typeof document < `u` && (l4 ? m3.ref = Array.isArray(o3) ? D([m3.ref, P(n2), ...o3]) : E(m3.ref, P(n2), o3) : E(null, null)), l4 ? (u3 !== void 0 && (m3.className = ce2(m3.className, u3)), d3 !== void 0 && (m3.style = F(m3.style, d3)), m3) : R2; +function ce2(e38, t2, n2) { + let { className: r2, style: i3 } = e38, { state: a3 = R, ref: o3, props: s3, stateAttributesMapping: c3, enabled: l5 = true } = t2, u3 = l5 ? ee(r2, a3) : void 0, d3 = l5 ? B(i3, a3) : void 0, f4 = l5 ? z(a3, c3) : R, p4 = l5 && s3 ? le2(s3) : void 0, m3 = l5 ? F(f4, p4) ?? {} : R; + return typeof document < `u` && (l5 ? m3.ref = Array.isArray(o3) ? D([m3.ref, P2(n2), ...o3]) : E(m3.ref, P2(n2), o3) : E(null, null)), l5 ? (u3 !== void 0 && (m3.className = oe(m3.className, u3)), d3 !== void 0 && (m3.style = F(m3.style, d3)), m3) : R; } -function de2(e9) { - return Array.isArray(e9) ? H2(e9) : te(void 0, e9); +function le2(e38) { + return Array.isArray(e38) ? U(e38) : H(void 0, e38); } -var fe2 = /* @__PURE__ */ Symbol.for(`react.lazy`); -function pe2(e9) { - if (e9?.$$typeof !== fe2) return e9; - let t2 = x.Children.toArray(e9)[0]; - return x.isValidElement(t2) ? t2 : e9; +var ue2 = /* @__PURE__ */ Symbol.for(`react.lazy`); +function de2(e38) { + if (e38?.$$typeof !== ue2) return e38; + let t2 = x.Children.toArray(e38)[0]; + return x.isValidElement(t2) ? t2 : e38; } -function me2(e9, t2, n2, r2) { +function fe2(e38, t2, n2, r2) { if (t2) { if (typeof t2 == `function`) return t2(n2, r2); - let e10 = te(n2, t2.props); - return e10.ref = n2.ref, x.cloneElement(t2, e10); + let e39 = H(n2, t2.props); + return e39.ref = n2.ref, x.cloneElement(t2, e39); } - if (e9 && typeof e9 == `string`) return he2(e9, n2); - throw Error(C(8)); + return pe2(e38, n2); } -function he2(e9, t2) { - return e9 === `button` ? (0, x.createElement)(`button`, { type: `button`, ...t2, key: t2.key }) : e9 === `img` ? (0, x.createElement)(`img`, { alt: ``, ...t2, key: t2.key }) : x.createElement(e9, t2); +function pe2(e38, t2) { + return e38 === `button` ? (0, x.createElement)(`button`, { type: `button`, ...t2, key: t2.key }) : e38 === `img` ? (0, x.createElement)(`img`, { alt: ``, ...t2, key: t2.key }) : x.createElement(e38, t2); } -function Fe() { +var me2 = `data-starting-style`; +var he2 = `data-ending-style`; +var ge2 = { [me2]: `` }; +var _e2 = { [he2]: `` }; +var ve2 = { transitionStatus(e38) { + return e38 === `starting` ? ge2 : e38 === `ending` ? _e2 : null; +} }; +var ye2 = `data-open`; +var be2 = `data-closed`; +var xe2 = `data-anchor-hidden`; +var Se2 = `data-popup-open`; +var Ce2 = `data-pressed`; +var we2 = { [Se2]: `` }; +var Te2 = { [Se2]: ``, [Ce2]: `` }; +var Ee2 = { [ye2]: `` }; +var De2 = { [be2]: `` }; +var Oe2 = { [xe2]: `` }; +var ke2 = { open(e38) { + return e38 ? we2 : null; +} }; +var Ae2 = { open(e38) { + return e38 ? Te2 : null; +} }; +var je2 = { open(e38) { + return e38 ? Ee2 : De2; +}, anchorHidden(e38) { + return e38 ? Oe2 : null; +} }; +var Me2 = { ...je2, ...ve2 }; +function Ne2() { return typeof window < `u`; } -function Ie(e9) { - return ze(e9) ? (e9.nodeName || ``).toLowerCase() : `#document`; +function Pe2(e38) { + return Le2(e38) ? (e38.nodeName || ``).toLowerCase() : `#document`; } -function Le(e9) { +function Fe(e38) { var t2; - return (e9 == null || (t2 = e9.ownerDocument) == null ? void 0 : t2.defaultView) || window; + return (e38 == null || (t2 = e38.ownerDocument) == null ? void 0 : t2.defaultView) || window; } -function Re(e9) { - return ((ze(e9) ? e9.ownerDocument : e9.document) || window.document)?.documentElement; +function Ie2(e38) { + return ((Le2(e38) ? e38.ownerDocument : e38.document) || window.document)?.documentElement; } -function ze(e9) { - return Fe() ? e9 instanceof Node || e9 instanceof Le(e9).Node : false; +function Le2(e38) { + return Ne2() ? e38 instanceof Node || e38 instanceof Fe(e38).Node : false; } -function J(e9) { - return Fe() ? e9 instanceof Element || e9 instanceof Le(e9).Element : false; +function Re2(e38) { + return Ne2() ? e38 instanceof Element || e38 instanceof Fe(e38).Element : false; } -function Be(e9) { - return Fe() ? e9 instanceof HTMLElement || e9 instanceof Le(e9).HTMLElement : false; +function ze2(e38) { + return Ne2() ? e38 instanceof HTMLElement || e38 instanceof Fe(e38).HTMLElement : false; } -function Ve(e9) { - return !Fe() || typeof ShadowRoot > `u` ? false : e9 instanceof ShadowRoot || e9 instanceof Le(e9).ShadowRoot; +function Be2(e38) { + return !Ne2() || typeof ShadowRoot > `u` ? false : e38 instanceof ShadowRoot || e38 instanceof Fe(e38).ShadowRoot; } -function He(e9) { - let { overflow: t2, overflowX: n2, overflowY: r2, display: i3 } = $e(e9); +function Ve2(e38) { + let { overflow: t2, overflowX: n2, overflowY: r2, display: i3 } = Qe(e38); return /auto|scroll|overlay|hidden|clip/.test(t2 + r2 + n2) && i3 !== `inline` && i3 !== `contents`; } -function Ue(e9) { - return /^(table|td|th)$/.test(Ie(e9)); +function He2(e38) { + return /^(table|td|th)$/.test(Pe2(e38)); } -function We(e9) { +function Ue(e38) { try { - if (e9.matches(`:popover-open`)) return true; + if (e38.matches(`:popover-open`)) return true; } catch { } try { - return e9.matches(`:modal`); + return e38.matches(`:modal`); } catch { return false; } } -var Ge2 = /transform|translate|scale|rotate|perspective|filter/; -var Ke2 = /paint|layout|strict|content/; -var qe = (e9) => !!e9 && e9 !== `none`; -var Je; -function Ye(e9) { - let t2 = J(e9) ? $e(e9) : e9; - return qe(t2.transform) || qe(t2.translate) || qe(t2.scale) || qe(t2.rotate) || qe(t2.perspective) || !Ze() && (qe(t2.backdropFilter) || qe(t2.filter)) || Ge2.test(t2.willChange || ``) || Ke2.test(t2.contain || ``); +var We = /transform|translate|scale|rotate|perspective|filter/; +var Ge = /paint|layout|strict|content/; +var Ke = (e38) => !!e38 && e38 !== `none`; +var qe; +function Je(e38) { + let t2 = Re2(e38) ? Qe(e38) : e38; + return Ke(t2.transform) || Ke(t2.translate) || Ke(t2.scale) || Ke(t2.rotate) || Ke(t2.perspective) || !Xe() && (Ke(t2.backdropFilter) || Ke(t2.filter)) || We.test(t2.willChange || ``) || Ge.test(t2.contain || ``); } -function Xe(e9) { - let t2 = tt(e9); - for (; Be(t2) && !Qe(t2); ) { - if (Ye(t2)) return t2; - if (We(t2)) return null; - t2 = tt(t2); +function Ye(e38) { + let t2 = et(e38); + for (; ze2(t2) && !Ze(t2); ) { + if (Je(t2)) return t2; + if (Ue(t2)) return null; + t2 = et(t2); } return null; } -function Ze() { - return Je ??= typeof CSS < `u` && CSS.supports && CSS.supports(`-webkit-backdrop-filter`, `none`), Je; +function Xe() { + return qe ??= typeof CSS < `u` && CSS.supports && CSS.supports(`-webkit-backdrop-filter`, `none`), qe; } -function Qe(e9) { - return /^(html|body|#document)$/.test(Ie(e9)); +function Ze(e38) { + return /^(html|body|#document)$/.test(Pe2(e38)); } -function $e(e9) { - return Le(e9).getComputedStyle(e9); +function Qe(e38) { + return Fe(e38).getComputedStyle(e38); } -function et(e9) { - return J(e9) ? { scrollLeft: e9.scrollLeft, scrollTop: e9.scrollTop } : { scrollLeft: e9.scrollX, scrollTop: e9.scrollY }; +function $e(e38) { + return Re2(e38) ? { scrollLeft: e38.scrollLeft, scrollTop: e38.scrollTop } : { scrollLeft: e38.scrollX, scrollTop: e38.scrollY }; } -function tt(e9) { - if (Ie(e9) === `html`) return e9; - let t2 = e9.assignedSlot || e9.parentNode || Ve(e9) && e9.host || Re(e9); - return Ve(t2) ? t2.host : t2; +function et(e38) { + if (Pe2(e38) === `html`) return e38; + let t2 = e38.assignedSlot || e38.parentNode || Be2(e38) && e38.host || Ie2(e38); + return Be2(t2) ? t2.host : t2; } -function nt2(e9) { - let t2 = tt(e9); - return Qe(t2) ? (e9.ownerDocument || e9).body : Be(t2) && He(t2) ? t2 : nt2(t2); +function tt(e38) { + let t2 = et(e38); + return Ze(t2) ? (e38.ownerDocument || e38).body : ze2(t2) && Ve2(t2) ? t2 : tt(t2); } -function rt(e9, t2, n2) { +function nt(e38, t2, n2) { t2 === void 0 && (t2 = []), n2 === void 0 && (n2 = true); - let r2 = nt2(e9), i3 = r2 === e9.ownerDocument?.body, a3 = Le(r2); + let r2 = tt(e38), i3 = r2 === e38.ownerDocument?.body, a3 = Fe(r2); if (i3) { - let e10 = it(a3); - return t2.concat(a3, a3.visualViewport || [], He(r2) ? r2 : [], e10 && n2 ? rt(e10) : []); + let e39 = rt2(a3); + return t2.concat(a3, a3.visualViewport || [], Ve2(r2) ? r2 : [], e39 && n2 ? nt(e39) : []); } - return t2.concat(r2, rt(r2, [], n2)); + return t2.concat(r2, nt(r2, [], n2)); } -function it(e9) { - return e9.parent && Object.getPrototypeOf(e9.parent) ? e9.frameElement : null; +function rt2(e38) { + return e38.parent && Object.getPrototypeOf(e38.parent) ? e38.frameElement : null; } -var at = { ...x }; -var ot = at.useInsertionEffect; -var st = ot && ot !== at.useLayoutEffect ? ot : (e9) => e9(); -function Y(e9) { - let t2 = T(ct).current; - return t2.next = e9, st(t2.effect), t2.trampoline; +var it2 = { ...x }; +var at = it2.useInsertionEffect; +var ot = at && at !== it2.useLayoutEffect ? at : (e38) => e38(); +function Y(e38) { + let t2 = T(st).current; + return t2.next = e38, ot(t2.effect), t2.trampoline; } -function ct() { - let e9 = { next: void 0, callback: lt, trampoline: (...t2) => e9.callback?.(...t2), effect: () => { - e9.callback = e9.next; +function st() { + let e38 = { next: void 0, callback: ct, trampoline: (...t2) => e38.callback?.(...t2), effect: () => { + e38.callback = e38.next; } }; - return e9; + return e38; } -function lt() { +function ct() { } var X = typeof document < `u` ? x.useLayoutEffect : () => { }; -var ut = x.createContext(void 0); -function dt(e9 = false) { - let t2 = x.useContext(ut); - if (t2 === void 0 && !e9) throw Error(C(16)); +var lt = x.createContext(void 0); +function ut(e38 = false) { + let t2 = x.useContext(lt); + if (t2 === void 0 && !e38) throw Error(C(16)); return t2; } -function ft(e9) { - let { focusableWhenDisabled: t2, disabled: n2, composite: r2 = false, tabIndex: i3 = 0, isNativeButton: a3 } = e9, o3 = r2 && t2 !== false, s3 = r2 && t2 === false; +function dt(e38) { + let { focusableWhenDisabled: t2, disabled: n2, composite: r2 = false, tabIndex: i3 = 0, isNativeButton: a3 } = e38, o3 = r2 && t2 !== false, s3 = r2 && t2 === false; return { props: x.useMemo(() => { - let e10 = { onKeyDown(e11) { - n2 && t2 && e11.key !== `Tab` && e11.preventDefault(); + let e39 = { onKeyDown(e40) { + n2 && t2 && e40.key !== `Tab` && e40.preventDefault(); } }; - return r2 || (e10.tabIndex = i3, !a3 && n2 && (e10.tabIndex = t2 ? i3 : -1)), (a3 && (t2 || o3) || !a3 && n2) && (e10[`aria-disabled`] = n2), a3 && (!t2 || s3) && (e10.disabled = n2), e10; + return r2 || (e39.tabIndex = i3, !a3 && n2 && (e39.tabIndex = t2 ? i3 : -1)), (a3 && (t2 || o3) || !a3 && n2) && (e39[`aria-disabled`] = n2), a3 && (!t2 || s3) && (e39.disabled = n2), e39; }, [r2, n2, t2, o3, s3, a3, i3]) }; } -function mt(e9, t2, { detail: n2 = 0 } = {}) { - e9.dispatchEvent(new (Le(e9)).PointerEvent(`click`, { bubbles: true, cancelable: true, composed: true, detail: n2, shiftKey: t2.shiftKey, ctrlKey: t2.ctrlKey, altKey: t2.altKey, metaKey: t2.metaKey })); -} -function Z(e9 = {}) { - let { disabled: t2 = false, focusableWhenDisabled: n2, tabIndex: r2 = 0, native: i3 = true, composite: a3 } = e9, o3 = x.useRef(null), s3 = dt(true), c2 = a3 ?? s3 !== void 0, { props: l4 } = ft({ focusableWhenDisabled: n2, disabled: t2, composite: c2, tabIndex: r2, isNativeButton: i3 }), u3 = x.useCallback(() => { - let e10 = o3.current; - ht(e10) && c2 && t2 && l4.disabled === void 0 && e10.disabled && (e10.disabled = false); - }, [t2, l4.disabled, c2]); - return X(u3, [u3]), { getButtonProps: x.useCallback((e10 = {}) => { - let { onClick: n3, onMouseDown: r3, onKeyUp: a4, onKeyDown: o4, onPointerDown: s4, ...u4 } = e10; - return te({ onClick(e11) { +function ft(e38) { + return e38?.ownerDocument || document; +} +function pt(e38, t2, { detail: n2 = 0, pointerType: r2 = `` } = {}) { + e38.dispatchEvent(new (Fe(e38)).PointerEvent(`click`, { bubbles: true, cancelable: true, composed: true, detail: n2, pointerType: r2, shiftKey: t2.shiftKey, ctrlKey: t2.ctrlKey, altKey: t2.altKey, metaKey: t2.metaKey })); +} +function Z(e38 = {}) { + let { disabled: t2 = false, focusableWhenDisabled: n2, tabIndex: r2 = 0, native: i3 = true, composite: a3 } = e38, o3 = x.useRef(null), s3 = ut(true), c3 = a3 ?? s3 !== void 0, { props: l5 } = dt({ focusableWhenDisabled: n2, disabled: t2, composite: c3, tabIndex: r2, isNativeButton: i3 }), u3 = x.useCallback(() => { + let e39 = o3.current; + mt2(e39) && c3 && t2 && l5.disabled === void 0 && e39.disabled && (e39.disabled = false); + }, [t2, l5.disabled, c3]); + return X(u3, [u3]), { getButtonProps: x.useCallback((e39 = {}) => { + let { onClick: n3, onMouseDown: r3, onKeyUp: a4, onKeyDown: o4, onPointerDown: s4, ...u4 } = e39; + return H({ onClick(e40) { if (t2) { - e11.preventDefault(); + e40.preventDefault(); return; } - n3?.(e11); - }, onMouseDown(e11) { - t2 || r3?.(e11); - }, onKeyDown(e11) { - if (t2 || (se2(e11), o4?.(e11), e11.baseUIHandlerPrevented)) return; - let n4 = e11.target === e11.currentTarget, r4 = e11.currentTarget, a5 = ht(r4), s5 = !i3 && gt(r4), l5 = n4 && (i3 ? a5 : !s5), u5 = e11.key === `Enter`, d3 = e11.key === ` `, f4 = r4.getAttribute(`role`), p4 = f4?.startsWith(`menuitem`) || f4 === `option` || f4 === `gridcell`; - if (n4 && c2 && d3) { - if (e11.defaultPrevented && p4) return; - e11.preventDefault(), (!i3 || a5) && (e11.preventBaseUIHandler(), mt(r4, e11)); + n3?.(e40); + }, onMouseDown(e40) { + t2 || r3?.(e40); + }, onKeyDown(e40) { + if (t2 || (ae(e40), o4?.(e40), e40.baseUIHandlerPrevented)) return; + let n4 = e40.target === e40.currentTarget, r4 = e40.currentTarget, a5 = mt2(r4), s5 = !i3 && ht(r4), l6 = n4 && (i3 ? a5 : !s5), u5 = e40.key === `Enter`, d3 = e40.key === ` `, f4 = r4.getAttribute(`role`), p4 = f4?.startsWith(`menuitem`) || f4 === `option` || f4 === `gridcell`; + if (n4 && c3 && d3) { + if (e40.defaultPrevented && p4) return; + e40.preventDefault(), (!i3 || a5) && (e40.preventBaseUIHandler(), pt(r4, e40)); return; } - if (!l5 || i3 || !d3 && !u5) { - n4 && s5 && d3 && e11.preventDefault(); + if (!l6 || i3 || !d3 && !u5) { + n4 && s5 && d3 && e40.preventDefault(); return; } - e11.defaultPrevented || (e11.preventDefault(), u5 && (e11.preventBaseUIHandler(), mt(r4, e11))); - }, onKeyUp(e11) { + e40.defaultPrevented || (e40.preventDefault(), u5 && (e40.preventBaseUIHandler(), pt(r4, e40))); + }, onKeyUp(e40) { if (!t2) { - if (se2(e11), a4?.(e11), e11.target === e11.currentTarget && i3 && c2 && ht(e11.currentTarget) && e11.key === ` `) { - e11.preventDefault(); + if (ae(e40), a4?.(e40), e40.target === e40.currentTarget && i3 && c3 && mt2(e40.currentTarget) && e40.key === ` `) { + e40.preventDefault(); return; } - e11.baseUIHandlerPrevented || e11.target === e11.currentTarget && !i3 && !c2 && !e11.defaultPrevented && e11.key === ` ` && (e11.preventBaseUIHandler(), mt(e11.currentTarget, e11)); + e40.baseUIHandlerPrevented || e40.target === e40.currentTarget && !i3 && !c3 && !e40.defaultPrevented && e40.key === ` ` && (e40.preventBaseUIHandler(), pt(e40.currentTarget, e40)); } - }, onPointerDown(e11) { + }, onPointerDown(e40) { if (t2) { - e11.preventDefault(); + e40.preventDefault(); return; } - s4?.(e11); - } }, i3 ? { type: `button` } : { role: `button` }, l4, u4); - }, [t2, l4, c2, i3]), buttonRef: Y((e10) => { - o3.current = e10, u3(); + s4?.(e40); + } }, i3 ? { type: `button` } : { role: `button` }, l5, u4); + }, [t2, l5, c3, i3]), buttonRef: Y((e39) => { + o3.current = e39, u3(); }) }; } -function ht(e9) { - return Be(e9) && e9.tagName === `BUTTON`; +function mt2(e38) { + return ze2(e38) && e38.tagName === `BUTTON`; +} +function ht(e38) { + return ze2(e38) && e38.tagName === `A` && !!e38.href; +} +function Q(e38, t2, n2, r2) { + let i3 = false, a3 = false, o3 = r2 ?? R; + return { reason: e38, event: t2 ?? new Event(`base-ui`), cancel() { + i3 = true; + }, allowPropagation() { + a3 = true; + }, get isCanceled() { + return i3; + }, get isPropagationAllowed() { + return a3; + }, trigger: n2, ...o3 }; +} +var _t = `none`; +var vt = `trigger-press`; +var yt = `trigger-hover`; +var bt = `trigger-focus`; +var xt = `outside-press`; +var St = `item-press`; +var Dt = `focus-out`; +var Ot = `escape-key`; +var kt = `list-navigation`; +var Mt = `cancel-open`; +var Pt = `disabled`; +var Ft = `imperative-action`; +var It = `window-resize`; +function Lt() { + let [, e38] = x.useState({}); + return x.useCallback(() => { + e38({}); + }, []); +} +var Rt = 0; +function zt(e38, t2 = `mui`) { + let n2 = x.useRef(void 0), r2 = Lt(), i3 = e38 ?? n2.current; + return x.useEffect(() => { + n2.current ?? (Rt += 1, n2.current = `${t2}-${Rt}`, e38 ?? r2()); + }, [e38, t2, r2]), i3; +} +var Bt = it2.useId; +function Vt(e38, t2) { + if (Bt !== void 0) { + let n2 = Bt(); + return e38 ?? (t2 ? `${t2}-${n2}` : n2); + } + return zt(e38, t2); +} +function Ht(e38) { + return Vt(e38, `base-ui`); +} +function Ut(e38) { + x.useEffect(e38, L); +} +var Wt = 0; +var Gt = class e2 { + static create() { + return new e2(); + } + currentId = Wt; + start(e38, t2) { + this.clear(), this.currentId = setTimeout(() => { + this.currentId = Wt, t2(); + }, e38); + } + isStarted() { + return this.currentId !== Wt; + } + clear = () => { + this.currentId !== Wt && (clearTimeout(this.currentId), this.currentId = Wt); + }; + disposeEffect = () => this.clear; +}; +function Kt() { + let e38 = T(Gt.create).current; + return Ut(e38.disposeEffect), e38; +} +function qt() { + return typeof navigator > `u` ? { userAgent: ``, platform: ``, maxTouchPoints: 0 } : { userAgent: navigator.userAgent, platform: navigator.platform ?? ``, maxTouchPoints: navigator.maxTouchPoints ?? 0 }; +} +var { userAgent: Jt, platform: Yt, maxTouchPoints: Xt } = qt(); +var Zt = Jt.toLowerCase(); +var Qt = Yt.toLowerCase(); +var $t = /^i(os$|p)/.test(Qt) || Qt === `macintel` && Xt > 1; +var en = `android`; +var tn = Qt === en || Zt.includes(en); +var nn = !$t && Qt.startsWith(`mac`); +var rn = nn || $t; +var an = typeof CSS < `u` && !!CSS.supports?.(`-webkit-backdrop-filter:none`); +var sn = rn; +var cn = /jsdom|happydom/.test(Zt); +function ln(e38) { + e38.preventDefault(), e38.stopPropagation(); +} +function un(e38) { + return `nativeEvent` in e38; +} +function dn(e38) { + return e38.pointerType === `` && e38.isTrusted ? true : tn && e38.pointerType ? e38.type === `click` && e38.buttons === 1 : e38.detail === 0 && !e38.pointerType; +} +function fn2(e38) { + return cn ? false : !tn && e38.width === 0 && e38.height === 0 || e38.type === `pointerdown` && e38.width === 1 && e38.height === 1 && e38.pressure === 0 && e38.detail === 0 && e38.pointerType === `mouse` && (tn || e38.buttons === 0) || e38.width < 1 && e38.height < 1 && e38.pressure === 0 && e38.detail === 0 && e38.pointerType === `touch`; +} +function pn(e38, t2) { + let n2 = [`mouse`, `pen`]; + return t2 || n2.push(``, void 0), n2.includes(e38); +} +function mn(e38) { + let t2 = e38.type; + return t2 === `click` || t2 === `mousedown` || t2 === `keydown` || t2 === `keyup`; +} +function hn(e38) { + let t2 = e38.activeElement; + for (; t2?.shadowRoot?.activeElement != null; ) t2 = t2.shadowRoot.activeElement; + return t2; +} +function $(e38, t2) { + if (!e38 || !t2) return false; + let n2 = t2.getRootNode?.(); + if (e38.contains(t2)) return true; + if (n2 && Be2(n2)) { + let n3 = t2; + for (; n3; ) { + if (e38 === n3) return true; + n3 = n3.parentNode || n3.host; + } + } + return false; +} +function gn(e38, t2) { + let n2 = e38; + for (; n2; ) { + if (Re2(n2) && n2.matches(t2)) return n2; + n2 = n2.assignedSlot ?? n2.parentNode ?? (Be2(n2) ? n2.host : null); + } + return null; +} +function _n(e38) { + return `composedPath` in e38 ? e38.composedPath()[0] ?? e38.target : e38.target; +} +var vn = `data-base-ui-focusable`; +var yn = `input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])`; +var bn = `ArrowLeft`; +var xn = `ArrowRight`; +var Sn = `ArrowUp`; +var Cn = `ArrowDown`; +var wn = `data-trigger-disabled`; +function Tn(e38, t2) { + if (!Re2(e38)) return false; + let n2 = e38; + if (t2.hasElement(n2)) return !n2.hasAttribute(wn); + for (let [, e39] of t2.entries()) if ($(e39, n2)) return !e39.hasAttribute(wn); + return false; +} +function En(e38, t2) { + if (t2 == null) return false; + if (`composedPath` in e38) return e38.composedPath().includes(t2); + let n2 = e38; + return n2.target != null && t2.contains(n2.target); +} +function Dn(e38) { + return e38.matches(`html,body`); +} +function On(e38) { + return ze2(e38) && e38.matches(`input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])`); +} +function kn(e38) { + return gn(e38, `button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${yn}`) != null; +} +function An(e38) { + return e38 ? e38.getAttribute(`role`) === `combobox` && On(e38) : false; +} +function jn(e38) { + if (!e38 || cn) return true; + try { + return e38.matches(`:focus-visible`); + } catch { + return true; + } +} +function Mn(e38) { + return e38 ? e38.hasAttribute(`data-base-ui-focusable`) ? e38 : e38.querySelector(`[data-base-ui-focusable]`) || e38 : null; +} +function Nn(e38, t2) { + return t2 != null && !pn(t2) ? 0 : typeof e38 == `function` ? e38() : e38; +} +function Pn(e38, t2, n2) { + let r2 = Nn(e38, n2); + return typeof r2 == `number` ? r2 : r2?.[t2]; +} +function Fn(e38) { + return typeof e38 == `function` ? e38() : e38; +} +function In(e38, t2) { + return t2 || e38 === `click` || e38 === `mousedown`; +} +function Ln(e38) { + return e38?.includes(`mouse`) && e38 !== `mousedown`; +} +var Rn = x.createContext({ hasProvider: false, timeoutMs: 0, delayRef: { current: 0 }, initialDelayRef: { current: 0 }, timeout: new Gt(), currentIdRef: { current: null }, currentContextRef: { current: null } }); +function zn(e38, t2) { + e38.current = t2.current; +} +function Bn(e38, t2 = { open: false }) { + let { open: n2 } = t2, r2 = e38.useState(`floatingId`), { currentIdRef: i3, delayRef: a3, timeoutMs: o3, initialDelayRef: s3, currentContextRef: c3, hasProvider: l5, timeout: u3 } = x.useContext(Rn), [d3, f4] = x.useState(false), p4 = x.useRef(n2); + return X(() => { + p4.current = n2; + }, [n2]), X(() => { + function t3() { + c3.current?.setIsInstantPhase(false), i3.current = null, c3.current = null, a3.current = s3.current, u3.clear(); + } + if (i3.current && !n2 && i3.current === r2) { + if (f4(false), o3) { + let n3 = r2; + return u3.start(o3, () => { + e38.select(`open`) || i3.current && i3.current !== n3 || t3(); + }), () => { + (p4.current || i3.current !== n3) && u3.clear(); + }; + } + t3(); + } + }, [n2, r2, i3, a3, o3, s3, c3, u3, e38]), X(() => { + if (!n2) return; + let t3 = c3.current, o4 = i3.current; + u3.clear(), c3.current = { onOpenChange: e38.setOpen, setIsInstantPhase: f4 }, i3.current = r2, a3.current = { open: 0, close: Pn(s3.current, `close`) }, o4 !== null && o4 !== r2 ? (f4(true), t3?.setIsInstantPhase(true), t3?.onOpenChange(false, Q(_t))) : (f4(false), t3?.setIsInstantPhase(false)); + }, [n2, r2, e38, i3, a3, s3, c3, u3]), X(() => () => { + if (i3.current === r2) { + if (c3.current = null, !p4.current) return; + i3.current = null, zn(a3, s3), u3.clear(); + } + }, [c3, i3, a3, r2, s3, u3]), x.useMemo(() => ({ activeIdRef: i3, hasProvider: l5, delayRef: a3, isInstantPhase: d3 }), [i3, l5, a3, d3]); +} +function Vn(e38, t2, n2, r2) { + return e38.addEventListener(t2, n2, r2), () => { + e38.removeEventListener(t2, n2, r2); + }; +} +function Hn(...e38) { + return () => { + for (let t2 = 0; t2 < e38.length; t2 += 1) { + let n2 = e38[t2]; + n2 && n2(); + } + }; +} +function Un(e38) { + let t2 = T(Wn, e38).current; + return t2.next = e38, X(t2.effect), t2; +} +function Wn(e38) { + let t2 = { current: e38, next: e38, effect: () => { + t2.current = t2.next; + } }; + return t2; } -function gt(e9) { - return Be(e9) && e9.tagName === `A` && !!e9.href; +var Gn = null; +var Kn = new class { + callbacks = []; + callbacksCount = 0; + nextId = 1; + startId = 1; + isScheduled = false; + tick = (e38) => { + this.isScheduled = false; + let t2 = this.callbacks, n2 = this.callbacksCount; + if (this.callbacks = [], this.callbacksCount = 0, this.startId = this.nextId, n2 > 0) for (let n3 = 0; n3 < t2.length; n3 += 1) t2[n3]?.(e38); + }; + request(e38) { + let t2 = this.nextId; + return this.nextId += 1, this.callbacks.push(e38), this.callbacksCount += 1, this.isScheduled ||= (requestAnimationFrame(this.tick), true), t2; + } + cancel(e38) { + let t2 = e38 - this.startId; + t2 < 0 || t2 >= this.callbacks.length || this.callbacks[t2] !== null && (this.callbacks[t2] = null, --this.callbacksCount); + } +}(); +var qn = class e3 { + static create() { + return new e3(); + } + static request(e38) { + return Kn.request(e38); + } + static cancel(e38) { + return Kn.cancel(e38); + } + currentId = Gn; + request(e38) { + this.cancel(), this.currentId = Kn.request(() => { + this.currentId = Gn, e38(); + }); + } + cancel = () => { + this.currentId !== Gn && (Kn.cancel(this.currentId), this.currentId = Gn); + }; + disposeEffect = () => this.cancel; +}; +function Jn() { + let e38 = T(qn.create).current; + return Ut(e38.disposeEffect), e38; +} +var Yn = { clipPath: `inset(50%)`, overflow: `hidden`, whiteSpace: `nowrap`, border: 0, padding: 0, width: 1, height: 1, margin: -1 }; +var Xn = { ...Yn, position: `fixed`, margin: 0, top: 0, left: 0 }; +var Zn = { ...Yn, position: `absolute` }; +var Qn = x.forwardRef(function e4(t2, n2) { + Reflect.set(e4, `d`, 168494239); + let [r2, i3] = x.useState(); + X(() => { + sn && an && i3(`button`); + }, []); + let a3 = { tabIndex: 0, role: r2 }; + return (0, b.jsx)(`span`, { ...t2, ref: n2, style: Xn, "aria-hidden": !r2 || void 0, ...a3, "data-base-ui-focus-guard": `` }); +}); +var nr = Math.min; +var rr = Math.max; +var ir = Math.round; +var ar = Math.floor; +var or = (e38) => ({ x: e38, y: e38 }); +var sr = { left: `right`, right: `left`, bottom: `top`, top: `bottom` }; +function cr(e38, t2, n2) { + return rr(e38, nr(t2, n2)); } -var tr = Math.min; -var nr = Math.max; -var rr = Math.round; -var ar = (e9) => ({ x: e9, y: e9 }); -function cr(e9, t2) { - return typeof e9 == `function` ? e9(t2) : e9; +function lr(e38, t2) { + return typeof e38 == `function` ? e38(t2) : e38; } -function lr(e9) { - return e9.split(`-`)[0]; +function ur(e38) { + return e38.split(`-`)[0]; } -function ur(e9) { - return e9.split(`-`)[1]; +function dr(e38) { + return e38.split(`-`)[1]; } -function dr(e9) { - return e9 === `x` ? `y` : `x`; +function fr(e38) { + return e38 === `x` ? `y` : `x`; } -function fr(e9) { - return e9 === `y` ? `height` : `width`; +function pr(e38) { + return e38 === `y` ? `height` : `width`; } -function pr(e9) { - let t2 = e9[0]; +function mr(e38) { + let t2 = e38[0]; return t2 === `t` || t2 === `b` ? `y` : `x`; } -function mr(e9) { - return dr(pr(e9)); +function hr(e38) { + return fr(mr(e38)); +} +function gr(e38, t2, n2) { + n2 === void 0 && (n2 = false); + let r2 = dr(e38), i3 = hr(e38), a3 = pr(i3), o3 = i3 === `x` ? r2 === (n2 ? `end` : `start`) ? `right` : `left` : r2 === `start` ? `bottom` : `top`; + return t2.reference[a3] > t2.floating[a3] && (o3 = Tr(o3)), [o3, Tr(o3)]; +} +function _r(e38) { + let t2 = Tr(e38); + return [vr(e38), t2, vr(t2)]; +} +function vr(e38) { + return e38.includes(`start`) ? e38.replace(`start`, `end`) : e38.replace(`end`, `start`); +} +var yr = [`left`, `right`]; +var br = [`right`, `left`]; +var xr = [`top`, `bottom`]; +var Sr = [`bottom`, `top`]; +function Cr(e38, t2, n2) { + switch (e38) { + case `top`: + case `bottom`: + return n2 ? t2 ? br : yr : t2 ? yr : br; + case `left`: + case `right`: + return t2 ? xr : Sr; + default: + return []; + } +} +function wr(e38, t2, n2, r2) { + let i3 = dr(e38), a3 = Cr(ur(e38), n2 === `start`, r2); + return i3 && (a3 = a3.map((e39) => e39 + `-` + i3), t2 && (a3 = a3.concat(a3.map(vr)))), a3; +} +function Tr(e38) { + let t2 = ur(e38); + return sr[t2] + e38.slice(t2.length); } -function Tr(e9) { - return { top: e9.top ?? 0, right: e9.right ?? 0, bottom: e9.bottom ?? 0, left: e9.left ?? 0 }; +function Er(e38) { + return { top: e38.top ?? 0, right: e38.right ?? 0, bottom: e38.bottom ?? 0, left: e38.left ?? 0 }; } -function Er(e9) { - return typeof e9 == `number` ? { top: e9, right: e9, bottom: e9, left: e9 } : Tr(e9); +function Dr(e38) { + return typeof e38 == `number` ? { top: e38, right: e38, bottom: e38, left: e38 } : Er(e38); } -function Dr(e9) { - let { x: t2, y: n2, width: r2, height: i3 } = e9; +function Or(e38) { + let { x: t2, y: n2, width: r2, height: i3 } = e38; return { width: r2, height: i3, top: n2, left: t2, right: t2 + r2, bottom: n2 + i3, x: t2, y: n2 }; } -var Ti = s(((e9) => { +function Ar(e38, t2) { + return t2 < 0 || t2 >= e38.length; +} +function jr(e38, t2) { + return Pr(e38.current, { disabledIndices: t2 }); +} +function Mr(e38, t2) { + return Pr(e38.current, { decrement: true, startingIndex: e38.current.length, disabledIndices: t2 }); +} +function Nr(e38, t2, n2) { + let { decrement: r2, loopFocus: i3, allowEscape: a3, disabledIndices: o3, minIndex: s3, maxIndex: c3 } = n2, l5 = () => Pr(e38, { startingIndex: t2, decrement: r2, disabledIndices: o3 }), u3, d3 = false; + if (!i3) u3 = r2 ? Math.max(s3, l5()) : Math.min(c3, l5()); + else if (r2 ? t2 <= s3 : t2 >= c3) { + let n3 = r2 ? -1 : e38.length; + a3 && t2 !== n3 ? u3 = -1 : (u3 = r2 ? c3 : s3, d3 = true); + } else u3 = l5(); + return { index: Ar(e38, u3) ? -1 : u3, wrapped: d3 }; +} +function Pr(e38, { startingIndex: t2 = -1, decrement: n2 = false, disabledIndices: r2, amount: i3 = 1 } = {}) { + let a3 = t2; + do + a3 += n2 ? -i3 : i3; + while (a3 >= 0 && a3 <= e38.length - 1 && Ir(e38, a3, r2)); + return a3; +} +function Ir(e38, t2, n2) { + if (typeof n2 == `function` ? n2(t2) : n2?.includes(t2) ?? false) return true; + let r2 = e38[t2]; + return r2 ? !Rr(r2) || r2.matches(`:disabled`) ? true : !n2 && (r2.hasAttribute(`disabled`) || r2.getAttribute(`aria-disabled`) === `true`) : false; +} +function Lr(e38) { + return e38.visibility === `hidden` || e38.visibility === `collapse`; +} +function Rr(e38, t2 = e38 ? Qe(e38) : null) { + return !e38 || !e38.isConnected || !t2 || Lr(t2) ? false : typeof e38.checkVisibility == `function` ? e38.checkVisibility() : t2.display !== `none` && t2.display !== `contents`; +} +var zr = `a[href],button,input,select,textarea,summary,details,iframe,object,embed,[tabindex],[contenteditable]:not([contenteditable="false"]),audio[controls],video[controls]`; +function Br(e38) { + let t2 = e38.assignedSlot; + if (t2) return t2; + if (e38.parentElement) return e38.parentElement; + let n2 = e38.getRootNode(); + return Be2(n2) ? n2.host : null; +} +function Vr(e38) { + for (let t2 of Array.from(e38.children)) if (Pe2(t2) === `summary`) return t2; + return null; +} +function Hr(e38, t2) { + let n2 = Vr(t2); + return !!n2 && (e38 === n2 || $(n2, e38)); +} +function Ur(e38) { + let t2 = e38 ? Pe2(e38) : ``; + return e38 != null && e38.matches(zr) && (t2 !== `summary` || e38.parentElement != null && Pe2(e38.parentElement) === `details` && Vr(e38.parentElement) === e38) && (t2 !== `details` || Vr(e38) == null) && (t2 !== `input` || e38.type !== `hidden`); +} +function Wr(e38) { + if (!Ur(e38) || !e38.isConnected || e38.matches(`:disabled`)) return false; + for (let t2 = e38; t2; t2 = Br(t2)) { + let n2 = t2 !== e38, r2 = Pe2(t2) === `slot`; + if (t2.hasAttribute(`inert`) || n2 && Pe2(t2) === `details` && !t2.open && !Hr(e38, t2) || t2.hasAttribute(`hidden`) || !r2 && !Gr(t2, n2)) return false; + } + return true; +} +function Gr(e38, t2) { + let n2 = Qe(e38); + return t2 ? n2.display !== `none` : Rr(e38, n2); +} +function Kr(e38) { + let t2 = e38.tabIndex; + if (t2 < 0) { + let t3 = Pe2(e38); + if (t3 === `details` || t3 === `audio` || t3 === `video` || ze2(e38) && e38.isContentEditable) return 0; + } + return t2; +} +function qr(e38) { + if (Pe2(e38) !== `input`) return null; + let t2 = e38; + return t2.type === `radio` && t2.name !== `` ? t2 : null; +} +function Jr(e38, t2) { + let n2 = qr(e38); + if (!n2) return true; + let r2 = t2.find((e39) => { + let t3 = qr(e39); + return t3?.name === n2.name && t3.form === n2.form && t3.checked; + }); + return r2 ? r2 === n2 : t2.find((e39) => { + let t3 = qr(e39); + return t3?.name === n2.name && t3.form === n2.form; + }) === n2; +} +function Yr(e38) { + if (ze2(e38) && Pe2(e38) === `slot`) { + let t2 = e38.assignedElements({ flatten: true }); + if (t2.length > 0) return t2; + } + return ze2(e38) && e38.shadowRoot ? Array.from(e38.shadowRoot.children) : Array.from(e38.children); +} +function Xr(e38, t2) { + Yr(e38).forEach((e39) => { + Ur(e39) && t2.push(e39), Xr(e39, t2); + }); +} +function Zr(e38, t2, n2) { + Yr(e38).forEach((e39) => { + ze2(e39) && e39.matches(t2) && n2.push(e39), Zr(e39, t2, n2); + }); +} +function Qr(e38) { + return Wr(e38) && Kr(e38) >= 0; +} +function $r(e38) { + let t2 = []; + return Xr(e38, t2), t2.filter(Wr); +} +function ei(e38) { + let t2 = $r(e38); + return t2.filter((e39) => Kr(e39) >= 0 && Jr(e39, t2)); +} +function ti(e38, t2) { + let n2 = ei(e38), r2 = n2.length; + if (r2 === 0) return; + let i3 = hn(ft(e38)), a3 = n2.indexOf(i3); + return n2[a3 === -1 ? t2 === 1 ? 0 : r2 - 1 : a3 + t2]; +} +function ni(e38) { + return ti(ft(e38).body, 1) || e38; +} +function ri(e38) { + return ti(ft(e38).body, -1) || e38; +} +function ai(e38, t2) { + let n2 = t2 || e38.currentTarget, r2 = e38.relatedTarget; + return !r2 || !$(n2, r2); +} +function oi(e38) { + ei(e38).forEach((e39) => { + e39.dataset.tabindex = e39.getAttribute(`tabindex`) || ``, e39.setAttribute(`tabindex`, `-1`); + }); +} +function si(e38) { + let t2 = []; + Zr(e38, `[data-tabindex]`, t2), t2.forEach((e39) => { + let t3 = e39.dataset.tabindex; + delete e39.dataset.tabindex, t3 ? e39.setAttribute(`tabindex`, t3) : e39.removeAttribute(`tabindex`); + }); +} +function ci(e38, t2, n2 = true) { + return e38.filter((e39) => e39.parentId === t2).flatMap((t3) => [...!n2 || t3.context?.open ? [t3] : [], ...ci(e38, t3.id, n2)]); +} +function li(e38, t2) { + let n2 = [], r2 = e38.find((e39) => e39.id === t2)?.parentId; + for (; r2; ) { + let t3 = e38.find((e39) => e39.id === r2); + r2 = t3?.parentId, t3 && (n2 = n2.concat(t3)); + } + return n2; +} +function ui(e38) { + return `data-base-ui-${e38}`; +} +var di = 0; +function fi(e38, t2 = {}) { + let { preventScroll: n2 = false, sync: r2 = false, shouldFocus: i3 } = t2; + cancelAnimationFrame(di); + function a3() { + (!i3 || i3()) && e38?.focus({ preventScroll: n2 }); + } + if (r2) return a3(), I; + let o3 = requestAnimationFrame(a3); + return di = o3, () => { + di === o3 && (cancelAnimationFrame(o3), di = 0); + }; +} +var pi = `data-base-ui-inert`; +var mi = /* @__PURE__ */ new WeakMap(); +var hi = /* @__PURE__ */ new WeakSet(); +var gi = /* @__PURE__ */ new WeakMap(); +var _i = 0; +function vi(e38) { + return e38 ? Be2(e38) ? e38.host : vi(e38.parentNode) : null; +} +var yi = (e38, t2) => t2.map((t3) => { + if (e38.contains(t3)) return t3; + let n2 = vi(t3); + return e38.contains(n2) ? n2 : null; +}).filter((e39) => e39 != null); +var bi = (e38) => { + let t2 = /* @__PURE__ */ new Set(); + return e38.forEach((e39) => { + let n2 = e39; + for (; n2 && !t2.has(n2); ) t2.add(n2), n2 = n2.parentNode; + }), t2; +}; +var xi = (e38, t2, n2) => { + let r2 = [], i3 = (e39) => { + e39 && !n2.has(e39) && Array.from(e39.children).forEach((e40) => { + Pe2(e40) !== `script` && (t2.has(e40) ? i3(e40) : r2.push(e40)); + }); + }; + return i3(e38), r2; +}; +function Si(e38, t2, n2, { mark: r2 = true }) { + let i3 = yi(t2, e38), a3 = r2 ? xi(t2, bi(i3), new Set(i3)) : [], o3 = [], s3 = []; + if (n2) { + let e39 = yi(t2, Array.from(t2.querySelectorAll(`[aria-live]`))), n3 = i3.concat(e39); + xi(t2, bi(n3), new Set(n3)).forEach((e40) => { + let t3 = e40.getAttribute(`aria-hidden`), n4 = t3 !== null && t3 !== `false`, r3 = (mi.get(e40) || 0) + 1; + mi.set(e40, r3), o3.push(e40), r3 === 1 && n4 && hi.add(e40), n4 || e40.setAttribute(`aria-hidden`, `true`); + }); + } + return r2 && a3.forEach((e39) => { + let t3 = (gi.get(e39) || 0) + 1; + gi.set(e39, t3), s3.push(e39), t3 === 1 && e39.setAttribute(pi, ``); + }), _i += 1, () => { + o3.forEach((e39) => { + let t3 = (mi.get(e39) || 0) - 1; + mi.set(e39, t3), t3 || (hi.has(e39) || e39.removeAttribute(`aria-hidden`), hi.delete(e39)); + }), r2 && s3.forEach((e39) => { + let t3 = (gi.get(e39) || 0) - 1; + gi.set(e39, t3), t3 || e39.removeAttribute(pi); + }), --_i, _i || (mi = /* @__PURE__ */ new WeakMap(), hi = /* @__PURE__ */ new WeakSet(), gi = /* @__PURE__ */ new WeakMap()); + }; +} +function Ci(e38, t2 = {}) { + let { ariaHidden: n2 = false, mark: r2 = true } = t2, i3 = ft(e38[0]).body; + return Si(e38, i3, n2, { mark: r2 }); +} +var wi = s(((e38) => { var t2 = sandVaultReact(); - function n2(e10) { - var t3 = `https://react.dev/errors/` + e10; + function n2(e39) { + var t3 = `https://react.dev/errors/` + e39; if (1 < arguments.length) { t3 += `?args[]=` + encodeURIComponent(arguments[1]); for (var n3 = 2; n3 < arguments.length; n3++) t3 += `&args[]=` + encodeURIComponent(arguments[n3]); } - return `Minified React error #` + e10 + `; visit ` + t3 + ` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`; + return `Minified React error #` + e39 + `; visit ` + t3 + ` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`; } function r2() { } var i3 = { d: { f: r2, r: function() { throw Error(n2(522)); - }, D: r2, C: r2, L: r2, m: r2, X: r2, S: r2, M: r2 }, p: 0, findDOMNode: null }, a3 = /* @__PURE__ */ Symbol.for(`react.portal`), s3 = /* @__PURE__ */ Symbol.for(`react.recoverable`), c2 = /* @__PURE__ */ Symbol.for(`react.optimistic_key`); - function l4(e10, t3, n3) { + }, D: r2, C: r2, L: r2, m: r2, X: r2, S: r2, M: r2 }, p: 0, findDOMNode: null }, o3 = /* @__PURE__ */ Symbol.for(`react.portal`), s3 = /* @__PURE__ */ Symbol.for(`react.recoverable`), c3 = /* @__PURE__ */ Symbol.for(`react.optimistic_key`); + function l5(e39, t3, n3) { var r3 = 3 < arguments.length && arguments[3] !== void 0 ? arguments[3] : null; - return { $$typeof: a3, key: r3 == null ? null : r3 === c2 ? c2 : `` + r3, children: e10, containerInfo: t3, implementation: n3 }; + return { $$typeof: o3, key: r3 == null ? null : r3 === c3 ? c3 : `` + r3, children: e39, containerInfo: t3, implementation: n3 }; } var u3 = t2.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; - function d3(e10, t3) { - if (e10 === `font`) return ``; + function d3(e39, t3) { + if (e39 === `font`) return ``; if (typeof t3 == `string`) return t3 === `use-credentials` ? t3 : ``; } - e9.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = i3, e9.browser = function(e10) { - return { $$typeof: s3, _reason: e10 }; - }, e9.createPortal = function(e10, t3) { + e38.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = i3, e38.browser = function(e39) { + return { $$typeof: s3, _reason: e39 }; + }, e38.createPortal = function(e39, t3) { var r3 = 2 < arguments.length && arguments[2] !== void 0 ? arguments[2] : null; if (!t3 || t3.nodeType !== 1 && t3.nodeType !== 9 && t3.nodeType !== 11) throw Error(n2(299)); - return l4(e10, t3, null, r3); - }, e9.flushSync = function(e10) { + return l5(e39, t3, null, r3); + }, e38.flushSync = function(e39) { var t3 = u3.T, n3 = i3.p; try { - if (u3.T = null, i3.p = 2, e10) return e10(); + if (u3.T = null, i3.p = 2, e39) return e39(); } finally { u3.T = t3, i3.p = n3, i3.d.f(); } - }, e9.preconnect = function(e10, t3) { - typeof e10 == `string` && (t3 ? (t3 = t3.crossOrigin, t3 = typeof t3 == `string` ? t3 === `use-credentials` ? t3 : `` : void 0) : t3 = null, i3.d.C(e10, t3)); - }, e9.prefetchDNS = function(e10) { - typeof e10 == `string` && i3.d.D(e10); - }, e9.preinit = function(e10, t3) { - if (typeof e10 == `string` && t3 && typeof t3.as == `string`) { - var n3 = t3.as, r3 = d3(n3, t3.crossOrigin), a4 = typeof t3.integrity == `string` ? t3.integrity : void 0, o3 = typeof t3.fetchPriority == `string` ? t3.fetchPriority : void 0; - n3 === `style` ? i3.d.S(e10, typeof t3.precedence == `string` ? t3.precedence : void 0, { crossOrigin: r3, integrity: a4, fetchPriority: o3 }) : n3 === `script` && i3.d.X(e10, { crossOrigin: r3, integrity: a4, fetchPriority: o3, nonce: typeof t3.nonce == `string` ? t3.nonce : void 0 }); - } - }, e9.preinitModule = function(e10, t3) { - if (typeof e10 == `string`) { + }, e38.preconnect = function(e39, t3) { + typeof e39 == `string` && (t3 ? (t3 = t3.crossOrigin, t3 = typeof t3 == `string` ? t3 === `use-credentials` ? t3 : `` : void 0) : t3 = null, i3.d.C(e39, t3)); + }, e38.prefetchDNS = function(e39) { + typeof e39 == `string` && i3.d.D(e39); + }, e38.preinit = function(e39, t3) { + if (typeof e39 == `string` && t3 && typeof t3.as == `string`) { + var n3 = t3.as, r3 = d3(n3, t3.crossOrigin), a3 = typeof t3.integrity == `string` ? t3.integrity : void 0, o4 = typeof t3.fetchPriority == `string` ? t3.fetchPriority : void 0; + n3 === `style` ? i3.d.S(e39, typeof t3.precedence == `string` ? t3.precedence : void 0, { crossOrigin: r3, integrity: a3, fetchPriority: o4 }) : n3 === `script` && i3.d.X(e39, { crossOrigin: r3, integrity: a3, fetchPriority: o4, nonce: typeof t3.nonce == `string` ? t3.nonce : void 0 }); + } + }, e38.preinitModule = function(e39, t3) { + if (typeof e39 == `string`) { if (typeof t3 == `object` && t3) { if (t3.as == null || t3.as === `script`) { var n3 = d3(t3.as, t3.crossOrigin); - i3.d.M(e10, { crossOrigin: n3, integrity: typeof t3.integrity == `string` ? t3.integrity : void 0, nonce: typeof t3.nonce == `string` ? t3.nonce : void 0, fetchPriority: typeof t3.fetchPriority == `string` ? t3.fetchPriority : void 0 }); + i3.d.M(e39, { crossOrigin: n3, integrity: typeof t3.integrity == `string` ? t3.integrity : void 0, nonce: typeof t3.nonce == `string` ? t3.nonce : void 0, fetchPriority: typeof t3.fetchPriority == `string` ? t3.fetchPriority : void 0 }); } - } else t3 ?? i3.d.M(e10); + } else t3 ?? i3.d.M(e39); } - }, e9.preload = function(e10, t3) { - if (typeof e10 == `string` && typeof t3 == `object` && t3 && typeof t3.as == `string`) { + }, e38.preload = function(e39, t3) { + if (typeof e39 == `string` && typeof t3 == `object` && t3 && typeof t3.as == `string`) { var n3 = t3.as, r3 = d3(n3, t3.crossOrigin); - i3.d.L(e10, n3, { crossOrigin: r3, integrity: typeof t3.integrity == `string` ? t3.integrity : void 0, nonce: typeof t3.nonce == `string` ? t3.nonce : void 0, type: typeof t3.type == `string` ? t3.type : void 0, fetchPriority: typeof t3.fetchPriority == `string` ? t3.fetchPriority : void 0, referrerPolicy: typeof t3.referrerPolicy == `string` ? t3.referrerPolicy : void 0, imageSrcSet: typeof t3.imageSrcSet == `string` ? t3.imageSrcSet : void 0, imageSizes: typeof t3.imageSizes == `string` ? t3.imageSizes : void 0, media: typeof t3.media == `string` ? t3.media : void 0 }); + i3.d.L(e39, n3, { crossOrigin: r3, integrity: typeof t3.integrity == `string` ? t3.integrity : void 0, nonce: typeof t3.nonce == `string` ? t3.nonce : void 0, type: typeof t3.type == `string` ? t3.type : void 0, fetchPriority: typeof t3.fetchPriority == `string` ? t3.fetchPriority : void 0, referrerPolicy: typeof t3.referrerPolicy == `string` ? t3.referrerPolicy : void 0, imageSrcSet: typeof t3.imageSrcSet == `string` ? t3.imageSrcSet : void 0, imageSizes: typeof t3.imageSizes == `string` ? t3.imageSizes : void 0, media: typeof t3.media == `string` ? t3.media : void 0 }); } - }, e9.preloadModule = function(e10, t3) { - if (typeof e10 == `string`) { + }, e38.preloadModule = function(e39, t3) { + if (typeof e39 == `string`) { if (t3) { var n3 = d3(t3.as, t3.crossOrigin); - i3.d.m(e10, { as: typeof t3.as == `string` && t3.as !== `script` ? t3.as : void 0, crossOrigin: n3, integrity: typeof t3.integrity == `string` ? t3.integrity : void 0, nonce: typeof t3.nonce == `string` ? t3.nonce : void 0, fetchPriority: typeof t3.fetchPriority == `string` ? t3.fetchPriority : void 0 }); - } else i3.d.m(e10); - } - }, e9.requestFormReset = function(e10) { - i3.d.r(e10); - }, e9.unstable_batchedUpdates = function(e10, t3) { - return e10(t3); - }, e9.useFormState = function(e10, t3, n3) { - return u3.H.useFormState(e10, t3, n3); - }, e9.useFormStatus = function() { + i3.d.m(e39, { as: typeof t3.as == `string` && t3.as !== `script` ? t3.as : void 0, crossOrigin: n3, integrity: typeof t3.integrity == `string` ? t3.integrity : void 0, nonce: typeof t3.nonce == `string` ? t3.nonce : void 0, fetchPriority: typeof t3.fetchPriority == `string` ? t3.fetchPriority : void 0 }); + } else i3.d.m(e39); + } + }, e38.requestFormReset = function(e39) { + i3.d.r(e39); + }, e38.unstable_batchedUpdates = function(e39, t3) { + return e39(t3); + }, e38.useFormState = function(e39, t3, n3) { + return u3.H.useFormState(e39, t3, n3); + }, e38.useFormStatus = function() { return u3.H.useHostTransitionStatus(); - }, e9.version = `19.3.0`; + }, e38.version = `19.3.0`; })); -var Ei = s(((e9, t2) => { +var Ti = s(((e38, t2) => { function n2() { if (typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < `u` && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE == `function`) try { __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n2); - } catch (e10) { - console.error(e10); + } catch (e39) { + console.error(e39); } } - n2(), t2.exports = Ti(); + n2(), t2.exports = wi(); })); -var Di = u(Ei(), 1); -function ua(e9, t2, n2) { - let { reference: r2, floating: i3 } = e9, a3 = pr(t2), o3 = mr(t2), s3 = fr(o3), c2 = lr(t2), l4 = a3 === `y`, u3 = r2.x + r2.width / 2 - i3.width / 2, d3 = r2.y + r2.height / 2 - i3.height / 2, f4 = r2[s3] / 2 - i3[s3] / 2, p4; - switch (c2) { - case `top`: - p4 = { x: u3, y: r2.y - i3.height }; - break; - case `bottom`: - p4 = { x: u3, y: r2.y + r2.height }; - break; - case `right`: - p4 = { x: r2.x + r2.width, y: d3 }; - break; - case `left`: - p4 = { x: r2.x - i3.width, y: d3 }; - break; - default: - p4 = { x: r2.x, y: r2.y }; - } - let m3 = ur(t2); - return m3 && (p4[o3] += f4 * (m3 === `end` ? 1 : -1) * (n2 && l4 ? -1 : 1)), p4; -} -async function da(e9, t2) { - t2 === void 0 && (t2 = {}); - let { x: n2, y: r2, platform: i3, rects: a3, elements: o3, strategy: s3 } = e9, { boundary: c2 = `clippingAncestors`, rootBoundary: l4 = `viewport`, elementContext: u3 = `floating`, altBoundary: d3 = false, padding: f4 = 0 } = cr(t2, e9), p4 = Er(f4), m3 = o3[d3 ? u3 === `floating` ? `reference` : `floating` : u3], h3 = Dr(await i3.getClippingRect({ element: await (i3.isElement == null ? void 0 : i3.isElement(m3)) ?? true ? m3 : m3.contextElement || await (i3.getDocumentElement == null ? void 0 : i3.getDocumentElement(o3.floating)), boundary: c2, rootBoundary: l4, strategy: s3 })), g3 = u3 === `floating` ? { x: n2, y: r2, width: a3.floating.width, height: a3.floating.height } : a3.reference, _2 = await (i3.getOffsetParent == null ? void 0 : i3.getOffsetParent(o3.floating)), v3 = await (i3.isElement == null ? void 0 : i3.isElement(_2)) && await (i3.getScale == null ? void 0 : i3.getScale(_2)) || { x: 1, y: 1 }, y3 = Dr(i3.convertOffsetParentRelativeRectToViewportRelativeRect ? await i3.convertOffsetParentRelativeRectToViewportRelativeRect({ elements: o3, rect: g3, offsetParent: _2, strategy: s3 }) : g3); - return { top: (h3.top - y3.top + p4.top) / v3.y, bottom: (y3.bottom - h3.bottom + p4.bottom) / v3.y, left: (h3.left - y3.left + p4.left) / v3.x, right: (y3.right - h3.right + p4.right) / v3.x }; -} -var fa = 50; -var pa = async (e9, t2, n2) => { - let { placement: r2 = `bottom`, strategy: i3 = `absolute`, middleware: a3 = [], platform: o3 } = n2, s3 = o3.detectOverflow ? o3 : { ...o3, detectOverflow: da }, c2 = await (o3.isRTL == null ? void 0 : o3.isRTL(t2)), l4 = await o3.getElementRects({ reference: e9, floating: t2, strategy: i3 }), { x: u3, y: d3 } = ua(l4, r2, c2), f4 = r2, p4 = 0, m3 = {}; - for (let n3 = 0; n3 < a3.length; n3++) { - let h3 = a3[n3]; - if (!h3) continue; - let { name: g3, fn: _2 } = h3, { x: v3, y: y3, data: b3, reset: x3 } = await _2({ x: u3, y: d3, initialPlacement: r2, placement: f4, strategy: i3, middlewareData: m3, rects: l4, platform: s3, elements: { reference: e9, floating: t2 } }); - u3 = v3 ?? u3, d3 = y3 ?? d3, m3[g3] = { ...m3[g3], ...b3 }, x3 && p4 < fa && (p4++, typeof x3 == `object` && (x3.placement && (f4 = x3.placement), x3.rects && (l4 = x3.rects === true ? await o3.getElementRects({ reference: e9, floating: t2, strategy: i3 }) : x3.rects), { x: u3, y: d3 } = ua(l4, f4, c2)), n3 = -1); - } - return { x: u3, y: d3, placement: f4, strategy: i3, middlewareData: m3 }; -}; -function Aa(e9) { - let t2 = $e(e9), n2 = parseFloat(t2.width) || 0, r2 = parseFloat(t2.height) || 0, i3 = Be(e9), a3 = i3 ? e9.offsetWidth : n2, o3 = i3 ? e9.offsetHeight : r2, s3 = rr(n2) !== a3 || rr(r2) !== o3; - return s3 && (n2 = a3, r2 = o3), { width: n2, height: r2, $: s3 }; -} -function ja(e9) { - return J(e9) ? e9 : e9.contextElement; -} -function Ma(e9) { - let t2 = ja(e9); - if (!Be(t2)) return ar(1); - let n2 = t2.getBoundingClientRect(), { width: r2, height: i3, $: a3 } = Aa(t2), o3 = (a3 ? rr(n2.width) : n2.width) / r2, s3 = (a3 ? rr(n2.height) : n2.height) / i3; - return (!o3 || !Number.isFinite(o3)) && (o3 = 1), (!s3 || !Number.isFinite(s3)) && (s3 = 1), { x: o3, y: s3 }; -} -var Na = ar(0); -function Pa(e9) { - let t2 = Le(e9); - return !Ze() || !t2.visualViewport ? Na : { x: t2.visualViewport.offsetLeft, y: t2.visualViewport.offsetTop }; -} -function Fa(e9, t2, n2) { - return t2 === void 0 && (t2 = false), !!n2 && t2 && n2 === Le(e9); -} -function Ia(e9, t2, n2, r2) { - t2 === void 0 && (t2 = false), n2 === void 0 && (n2 = false); - let i3 = e9.getBoundingClientRect(), a3 = ja(e9), o3 = ar(1); - t2 && (r2 ? J(r2) && (o3 = Ma(r2)) : o3 = Ma(e9)); - let s3 = Fa(a3, n2, r2) ? Pa(a3) : ar(0), c2 = (i3.left + s3.x) / o3.x, l4 = (i3.top + s3.y) / o3.y, u3 = i3.width / o3.x, d3 = i3.height / o3.y; - if (a3 && r2) { - let e10 = Le(a3), t3 = J(r2) ? Le(r2) : r2, n3 = e10, i4 = it(n3); - for (; i4 && t3 !== n3; ) { - let e11 = Ma(i4), t4 = i4.getBoundingClientRect(), r3 = $e(i4), a4 = t4.left + (i4.clientLeft + parseFloat(r3.paddingLeft)) * e11.x, o4 = t4.top + (i4.clientTop + parseFloat(r3.paddingTop)) * e11.y; - c2 *= e11.x, l4 *= e11.y, u3 *= e11.x, d3 *= e11.y, c2 += a4, l4 += o4, n3 = Le(i4), i4 = it(n3); +var Ei = u(Ti(), 1); +var Di = { style: { transition: `none` } }; +var ki = { fallbackAxisSide: `none` }; +var Ai = { fallbackAxisSide: `end` }; +var ji = { clipPath: `inset(50%)`, position: `fixed`, top: 0, left: 0 }; +var Mi = x.createContext(null); +var Ni = () => x.useContext(Mi); +var Pi = ui(`portal`); +function Fi(e38 = {}) { + let { ref: t2, container: n2, componentProps: r2 = R, elementProps: i3 } = e38, a3 = Vt(), o3 = Ni()?.portalNode, [s3, c3] = x.useState(null), [l5, u3] = x.useState(null), d3 = Y((e39) => { + e39 !== null && u3(e39); + }), f4 = x.useRef(null); + X(() => { + if (n2 === null) { + f4.current && (f4.current = null, u3(null), c3(null)); + return; } - } - return Dr({ width: u3, height: d3, x: c2, y: l4 }); -} -function La(e9, t2) { - let n2 = et(e9).scrollLeft; - return t2 ? t2.left + n2 : Ia(Re(e9)).left + n2; -} -function Ra(e9, t2) { - let n2 = e9.getBoundingClientRect(); - return { x: n2.left + t2.scrollLeft - La(e9, n2), y: n2.top + t2.scrollTop }; -} -function za(e9) { - let { elements: t2, rect: n2, offsetParent: r2, strategy: i3 } = e9, a3 = i3 === `fixed`, o3 = Re(r2), s3 = t2 ? We(t2.floating) : false; - if (r2 === o3 || s3 && a3) return n2; - let c2 = { scrollLeft: 0, scrollTop: 0 }, l4 = ar(1), u3 = ar(0), d3 = Be(r2); - if ((d3 || !a3) && ((Ie(r2) !== `body` || He(o3)) && (c2 = et(r2)), d3)) { - let e10 = Ia(r2); - l4 = Ma(r2), u3.x = e10.x + r2.clientLeft, u3.y = e10.y + r2.clientTop; - } - let f4 = o3 && !d3 && !a3 ? Ra(o3, c2) : ar(0); - return { width: n2.width * l4.x, height: n2.height * l4.y, x: n2.x * l4.x - c2.scrollLeft * l4.x + u3.x + f4.x, y: n2.y * l4.y - c2.scrollTop * l4.y + u3.y + f4.y }; -} -function Ba(e9) { - return e9.getClientRects ? Array.from(e9.getClientRects()) : []; -} -function Va(e9) { - let t2 = et(e9), n2 = e9.ownerDocument.body, r2 = nr(e9.scrollWidth, e9.clientWidth, n2.scrollWidth, n2.clientWidth), i3 = nr(e9.scrollHeight, e9.clientHeight, n2.scrollHeight, n2.clientHeight), a3 = -t2.scrollLeft + La(e9), o3 = -t2.scrollTop; - return $e(n2).direction === `rtl` && (a3 += nr(e9.clientWidth, n2.clientWidth) - r2), { width: r2, height: i3, x: a3, y: o3 }; -} -var Ha = 25; -function Ua(e9, t2, n2) { - n2 === void 0 && (n2 = `viewport`); - let r2 = n2 === `layoutViewport`, i3 = Le(e9), a3 = Re(e9), o3 = i3.visualViewport, s3 = a3.clientWidth, c2 = a3.clientHeight, l4 = 0, u3 = 0; - if (o3) { - let e10 = !Ze() || t2 === `fixed`; - r2 ? e10 || (l4 = -o3.offsetLeft, u3 = -o3.offsetTop) : (s3 = o3.width, c2 = o3.height, e10 && (l4 = o3.offsetLeft, u3 = o3.offsetTop)); - } - if (La(a3) <= 0) { - let e10 = a3.ownerDocument, t3 = e10.body, n3 = getComputedStyle(t3), r3 = e10.compatMode === `CSS1Compat` && parseFloat(n3.marginLeft) + parseFloat(n3.marginRight) || 0, i4 = Math.abs(a3.clientWidth - t3.clientWidth - r3), o4 = getComputedStyle(a3).scrollbarGutter === `stable both-edges` ? i4 / 2 : i4; - o4 <= Ha && (s3 -= o4); - } - return { width: s3, height: c2, x: l4, y: u3 }; -} -function Wa(e9, t2) { - let n2 = Ia(e9, true, t2 === `fixed`), r2 = n2.top + e9.clientTop, i3 = n2.left + e9.clientLeft, a3 = Ma(e9); - return { width: e9.clientWidth * a3.x, height: e9.clientHeight * a3.y, x: i3 * a3.x, y: r2 * a3.y }; -} -function Ga(e9, t2, n2) { - let r2; - if (t2 === `viewport` || t2 === `layoutViewport`) r2 = Ua(e9, n2, t2); - else if (t2 === `document`) r2 = Va(Re(e9)); - else if (J(t2)) r2 = Wa(t2, n2); - else { - let n3 = Pa(e9); - r2 = { x: t2.x - n3.x, y: t2.y - n3.y, width: t2.width, height: t2.height }; - } - return Dr(r2); -} -function Ka(e9, t2) { - let n2 = t2.get(e9); - if (n2) return n2; - let r2 = rt(e9, [], false).filter((e10) => J(e10) && Ie(e10) !== `body`), i3 = null, a3 = $e(e9).position === `fixed`, o3 = a3 ? tt(e9) : e9; - for (; J(o3) && !Qe(o3); ) { - let e10 = $e(o3), t3 = Ye(o3), n3 = i3 ? i3.position : a3 ? `fixed` : ``; - !t3 && (n3 === `fixed` || n3 === `absolute` && e10.position === `static`) ? r2 = r2.filter((e11) => e11 !== o3) : i3 = e10, o3 = tt(o3); - } - return t2.set(e9, r2), r2; + let e39 = (n2 && (Le2(n2) ? n2 : n2.current)) ?? o3 ?? document.body; + if (e39 == null) { + f4.current && (f4.current = null, u3(null), c3(null)); + return; + } + f4.current !== e39 && (f4.current = e39, u3(null), c3(e39)); + }, [n2, o3]); + let p4 = J(`div`, r2, { ref: [t2, d3], props: [{ id: a3, [Pi]: `` }, i3] }), m3 = s3 && p4 ? Ei.createPortal(p4, s3) : null; + return { node: l5, nodeId: x.isValidElement(p4) ? p4.props.id : void 0, subtree: m3 }; +} +var Ii = x.forwardRef(function e5(t2, n2) { + Reflect.set(e5, `d`, 1796052274); + let { render: r2, className: i3, style: a3, children: o3, container: s3, portalOwnerRole: c3, ...l5 } = t2, { node: u3, nodeId: d3, subtree: f4 } = Fi({ container: s3, ref: n2, componentProps: t2, elementProps: l5 }), p4 = x.useRef(null), m3 = x.useRef(null), h4 = x.useRef(null), g5 = x.useRef(null), [_5, v5] = x.useState(null), y4 = x.useRef(false), S2 = _5?.modal, C2 = _5?.open, w2 = !!_5 && !_5.modal && _5.open && !!u3; + x.useEffect(() => { + if (!u3 || S2) return; + function e38(e39) { + u3 && e39.relatedTarget && ai(e39) && (e39.type === `focusin` ? y4.current &&= (si(u3), false) : (oi(u3), y4.current = true)); + } + return Hn(Vn(u3, `focusin`, e38, true), Vn(u3, `focusout`, e38, true)); + }, [u3, S2]), X(() => { + u3 && C2 === true && y4.current && (si(u3), y4.current = false); + }, [C2, u3]); + let T2 = x.useMemo(() => ({ beforeOutsideRef: p4, afterOutsideRef: m3, beforeInsideRef: h4, afterInsideRef: g5, portalNode: u3, setFocusManagerState: v5 }), [u3]); + return (0, b.jsxs)(x.Fragment, { children: [f4, (0, b.jsxs)(Mi.Provider, { value: T2, children: [w2 && u3 && (0, b.jsx)(Qn, { "data-type": `outside`, ref: p4, onFocus: (e38) => { + ai(e38, u3) ? h4.current?.focus() : ri(_5 ? _5.domReference : null)?.focus(); + } }), w2 && u3 && (0, b.jsx)(`span`, { role: c3, "aria-owns": d3, style: ji }), u3 && Ei.createPortal(o3, u3), w2 && u3 && (0, b.jsx)(Qn, { "data-type": `outside`, ref: m3, onFocus: (e38) => { + ai(e38, u3) ? g5.current?.focus() : (ni(_5 ? _5.domReference : null)?.focus(), _5?.closeOnFocusOut && _5?.onOpenChange(false, Q(`focus-out`, e38.nativeEvent))); + } })] })] }); +}); +function Li() { + let e38 = /* @__PURE__ */ new Map(); + return { emit(t2, n2) { + e38.get(t2)?.forEach((e39) => e39(n2)); + }, on(t2, n2) { + e38.has(t2) || e38.set(t2, /* @__PURE__ */ new Set()), e38.get(t2).add(n2); + }, off(t2, n2) { + e38.get(t2)?.delete(n2); + } }; } -function qa(e9) { - let { element: t2, boundary: n2, rootBoundary: r2, strategy: i3 } = e9, a3 = [...n2 === `clippingAncestors` ? We(t2) ? [] : Ka(t2, this._c) : [].concat(n2), r2], o3 = Ga(t2, a3[0], i3), s3 = o3.top, c2 = o3.right, l4 = o3.bottom, u3 = o3.left; - for (let e10 = 1; e10 < a3.length; e10++) { - let n3 = Ga(t2, a3[e10], i3); - s3 = nr(n3.top, s3), c2 = tr(n3.right, c2), l4 = tr(n3.bottom, l4), u3 = nr(n3.left, u3); +var Ri = class { + nodesRef = { current: [] }; + events = Li(); + addNode(e38) { + this.nodesRef.current.push(e38); } - return { width: c2 - u3, height: l4 - s3, x: u3, y: s3 }; -} -function Ja(e9) { - let { width: t2, height: n2 } = Aa(e9); - return { width: t2, height: n2 }; -} -function Ya(e9, t2, n2) { - let r2 = Be(t2), i3 = Re(t2), a3 = n2 === `fixed`, o3 = Ia(e9, true, a3, t2), s3 = { scrollLeft: 0, scrollTop: 0 }, c2 = ar(0); - if ((r2 || !a3) && ((Ie(t2) !== `body` || He(i3)) && (s3 = et(t2)), r2)) { - let e10 = Ia(t2, true, a3, t2); - c2.x = e10.x + t2.clientLeft, c2.y = e10.y + t2.clientTop; - } - !r2 && i3 && (c2.x = La(i3)); - let l4 = i3 && !r2 && !a3 ? Ra(i3, s3) : ar(0); - return { x: o3.left + s3.scrollLeft - c2.x - l4.x, y: o3.top + s3.scrollTop - c2.y - l4.y, width: o3.width, height: o3.height }; -} -function Xa(e9) { - return $e(e9).position === `static`; -} -function Za(e9, t2) { - if (!Be(e9) || $e(e9).position === `fixed`) return null; - if (t2) return t2(e9); - let n2 = e9.offsetParent; - return Re(e9) === n2 && (n2 = n2.ownerDocument.body), n2; -} -function Qa(e9, t2) { - let n2 = Le(e9); - if (We(e9)) return n2; - if (!Be(e9)) { - let t3 = tt(e9); - for (; t3 && !Qe(t3); ) { - if (J(t3) && !Xa(t3)) return t3; - t3 = tt(t3); - } - return n2; + removeNode(e38) { + let t2 = this.nodesRef.current.findIndex((t3) => t3 === e38); + t2 !== -1 && this.nodesRef.current.splice(t2, 1); } - let r2 = Za(e9, t2); - for (; r2 && Ue(r2) && Xa(r2); ) r2 = Za(r2, t2); - return r2 && Qe(r2) && Xa(r2) && !Ye(r2) ? n2 : r2 || Xe(e9) || n2; -} -var $a = async function(e9) { - let t2 = this.getOffsetParent || Qa, n2 = this.getDimensions, r2 = await n2(e9.floating); - return { reference: Ya(e9.reference, await t2(e9.floating), e9.strategy), floating: { x: 0, y: 0, width: r2.width, height: r2.height } }; -}; -function eo(e9) { - return $e(e9).direction === `rtl`; -} -var to = { convertOffsetParentRelativeRectToViewportRelativeRect: za, getDocumentElement: Re, getClippingRect: qa, getOffsetParent: Qa, getElementRects: $a, getClientRects: Ba, getDimensions: Ja, getScale: Ma, isElement: J, isRTL: eo }; -var ho = (e9, t2, n2) => { - let r2 = /* @__PURE__ */ new Map(), i3 = n2 ?? {}, a3 = { ...to, ...i3.platform, _c: r2 }; - return pa(e9, t2, { ...i3, platform: a3 }); }; -var go = typeof document < `u` ? x.useLayoutEffect : function() { +var zi = x.createContext(null); +var Bi = x.createContext(null); +var Vi = () => x.useContext(zi)?.id || null; +var Hi = (e38) => { + let t2 = x.useContext(Bi); + return e38 ?? t2; }; -function _o(e9, t2) { - if (e9 === t2) return true; - if (typeof e9 != typeof t2) return false; - if (typeof e9 == `function` && e9.toString() === t2.toString()) return true; - let n2, r2, i3; - if (e9 && t2 && typeof e9 == `object`) { - if (Array.isArray(e9)) { - if (n2 = e9.length, n2 !== t2.length) return false; - for (r2 = n2; r2-- !== 0; ) if (!_o(e9[r2], t2[r2])) return false; - return true; +function Ui(e38) { + let t2 = Vt(), n2 = Hi(e38), r2 = Vi(); + return X(() => { + if (!t2) return; + let e39 = { id: t2, parentId: r2 }; + return n2?.addNode(e39), () => { + n2?.removeNode(e39); + }; + }, [n2, t2, r2]), t2; +} +function Wi(e38) { + Reflect.set(Wi, `d`, 3004782141); + let { children: t2, id: n2 } = e38, r2 = Vi(); + return (0, b.jsx)(zi.Provider, { value: x.useMemo(() => ({ id: n2, parentId: r2 }), [n2, r2]), children: t2 }); +} +function Gi(e38) { + Reflect.set(Gi, `d`, 399336081); + let { children: t2, externalTree: n2 } = e38, r2 = T(() => n2 ?? new Ri()).current; + return (0, b.jsx)(Bi.Provider, { value: r2, children: t2 }); +} +function Ki(e38) { + return e38 == null ? e38 : `current` in e38 ? e38.current : e38; +} +function qi(e38, t2) { + let n2 = Fe(_n(e38)); + return e38 instanceof n2.KeyboardEvent ? `keyboard` : e38 instanceof n2.FocusEvent ? t2 || `keyboard` : `pointerType` in e38 ? e38.pointerType || (dn(e38) ? `keyboard` : t2 || `mouse`) : `touches` in e38 ? `touch` : e38 instanceof n2.MouseEvent ? t2 || (e38.detail === 0 ? `keyboard` : `mouse`) : ``; +} +var Ji = 20; +var Yi = []; +function Xi() { + Yi = Yi.filter((e38) => e38.deref()?.isConnected); +} +function Zi(e38) { + Xi(), e38 && Pe2(e38) !== `body` && (Yi.push(new WeakRef(e38)), Yi.length > Ji && (Yi = Yi.slice(-20))); +} +function Qi() { + return Xi(), Yi[Yi.length - 1]?.deref(); +} +function $i(e38) { + return e38 ? Qr(e38) ? e38 : ei(e38)[0] || e38 : null; +} +function ea(e38) { + if (e38.hasAttribute(`tabindex`) && !e38.hasAttribute(`data-tabindex`) || !e38.getAttribute(`role`)?.includes(`dialog`)) return; + let t2 = $r(e38).filter((e39) => { + let t3 = e39.getAttribute(`data-tabindex`) || ``; + return Qr(e39) || e39.hasAttribute(`data-tabindex`) && !t3.startsWith(`-`); + }), n2 = e38.getAttribute(`tabindex`); + t2.length === 0 ? n2 !== `0` && (e38.setAttribute(`tabindex`, `0`), e38.setAttribute(`data-tabindex`, `0`)) : (n2 !== `-1` || e38.hasAttribute(`data-tabindex`) && e38.getAttribute(`data-tabindex`) !== `-1`) && (e38.setAttribute(`tabindex`, `-1`), e38.setAttribute(`data-tabindex`, `-1`)); +} +function ta(e38) { + Reflect.set(ta, `d`, 615083791); + let { context: t2, children: n2, disabled: r2 = false, initialFocus: i3 = true, returnFocus: a3 = true, explicitReturnFocus: o3, restoreFocus: s3 = false, modal: c3 = true, closeOnFocusOut: l5 = true, openInteractionType: u3 = ``, nextFocusableElement: d3, previousFocusableElement: f4, beforeContentFocusGuardRef: p4, externalTree: m3, getInsideElements: h4 } = e38, g5 = t2.useState(`open`), _5 = t2.useState(`domReferenceElement`), v5 = t2.useState(`floatingElement`), { events: y4, dataRef: S2 } = t2.context, C2 = Y(() => S2.current.floatingContext?.nodeId), w2 = i3 === false, T2 = An(_5) && w2, D2 = Un(i3), O2 = Un(a3), k2 = Un(o3), A2 = Un(u3), j2 = Un(g5), M2 = Hi(m3), N3 = Ni(), P3 = x.useRef(false), F2 = x.useRef(false), I2 = x.useRef(false), L3 = x.useRef(null), R3 = x.useRef(``), z2 = x.useRef(``), ee2 = x.useRef(null), B3 = x.useRef(null), V3 = E(ee2, p4, N3?.beforeInsideRef), H3 = E(B3, N3?.afterInsideRef), U3 = Kt(), W3 = Kt(), G2 = Jn(), te2 = N3 != null, K4 = Mn(v5), ne3 = Y((e39 = K4) => e39 ? ei(e39) : []), q4 = Y(() => h4?.().filter((e39) => e39 != null) ?? []); + x.useEffect(() => { + if (r2 || !c3) return; + function e39(e40) { + e40.key === `Tab` && $(K4, hn(ft(K4))) && ne3().length === 0 && !T2 && ln(e40); } - if (i3 = Object.keys(e9), n2 = i3.length, n2 !== Object.keys(t2).length) return false; - for (r2 = n2; r2-- !== 0; ) if (!{}.hasOwnProperty.call(t2, i3[r2])) return false; - for (r2 = n2; r2-- !== 0; ) { - let n3 = i3[r2]; - if (!(n3 === `_owner` && e9.$$typeof) && !_o(e9[n3], t2[n3])) return false; + return Vn(ft(K4), `keydown`, e39); + }, [r2, K4, c3, T2, ne3]), x.useEffect(() => { + if (r2 || !g5) return; + let e39 = ft(K4); + function t3() { + I2.current = false; } - return true; - } - return e9 !== e9 && t2 !== t2; -} -function vo(e9) { - return typeof window > `u` ? 1 : (e9.ownerDocument.defaultView || window).devicePixelRatio || 1; -} -function yo(e9, t2) { - let n2 = vo(e9); - return Math.round(t2 * n2) / n2; -} -function bo(e9) { - let t2 = x.useRef(e9); - return go(() => { - t2.current = e9; - }), t2; -} -function xo(e9) { - e9 === void 0 && (e9 = {}); - let { placement: t2 = `bottom`, strategy: n2 = `absolute`, middleware: r2 = [], platform: i3, elements: { reference: a3, floating: o3 } = {}, transform: s3 = true, whileElementsMounted: c2, open: l4 } = e9, [u3, d3] = x.useState({ x: 0, y: 0, strategy: n2, placement: t2, middlewareData: {}, isPositioned: false }), [f4, p4] = x.useState(r2); - _o(f4, r2) || p4(r2); - let [m3, h3] = x.useState(null), [g3, _2] = x.useState(null), v3 = x.useCallback((e10) => { - e10 !== C2.current && (C2.current = e10, h3(e10)); - }, []), y3 = x.useCallback((e10) => { - e10 !== w3.current && (w3.current = e10, _2(e10)); - }, []), b3 = a3 || m3, S3 = o3 || g3, C2 = x.useRef(null), w3 = x.useRef(null), T3 = x.useRef(u3), E3 = c2 != null, D2 = bo(c2), O3 = bo(i3), k4 = bo(l4), A3 = x.useCallback(() => { - if (!C2.current || !w3.current) return; - let e10 = { placement: t2, strategy: n2, middleware: f4 }; - O3.current && (e10.platform = O3.current), ho(C2.current, w3.current, e10).then((e11) => { - let t3 = { ...e11, isPositioned: k4.current !== false }; - j3.current && !_o(T3.current, t3) && (T3.current = t3, Di.flushSync(() => { - d3(t3); + function n3(e40) { + let t4 = _n(e40), n4 = q4(), r3 = $(v5, t4) || $(_5, t4) || $(N3?.portalNode, t4) || n4.some((e41) => e41 === t4 || $(e41, t4)); + I2.current = !r3, z2.current = e40.pointerType || `keyboard`, gn(t4, `[data-base-ui-click-trigger]`) && (F2.current = true, W3.start(0, () => { + F2.current = false; })); - }); - }, [f4, t2, n2, O3, k4]); - go(() => { - l4 === false && T3.current.isPositioned && (T3.current.isPositioned = false, d3((e10) => ({ ...e10, isPositioned: false }))); - }, [l4]); - let j3 = x.useRef(false); - go(() => (j3.current = true, () => { - j3.current = false; - }), []), go(() => { - if (b3 && (C2.current = b3), S3 && (w3.current = S3), b3 && S3) { - if (D2.current) return D2.current(b3, S3, A3); - A3(); - } - }, [b3, S3, A3, D2, E3]); - let M3 = x.useMemo(() => ({ reference: C2, floating: w3, setReference: v3, setFloating: y3 }), [v3, y3]), N2 = x.useMemo(() => ({ reference: b3, floating: S3 }), [b3, S3]), P2 = x.useMemo(() => { - let e10 = { position: n2, left: 0, top: 0 }; - if (!N2.floating) return e10; - let t3 = yo(N2.floating, u3.x), r3 = yo(N2.floating, u3.y); - return s3 ? { ...e10, transform: `translate(` + t3 + `px, ` + r3 + `px)`, ...vo(N2.floating) >= 1.5 && { willChange: `transform` } } : { position: n2, left: t3, top: r3 }; - }, [n2, s3, N2.floating, u3.x, u3.y]); - return x.useMemo(() => ({ ...u3, update: A3, refs: M3, elements: N2, floatingStyles: P2 }), [u3, A3, M3, N2, P2]); -} -var Uc = x.createContext(void 0); -function Wc() { - return x.useContext(Uc)?.direction ?? `ltr`; -} -var Kc = x.forwardRef(function e2(t2, n2) { - Reflect.set(e2, `d`, 1741033561); - let { render: r2, className: i3, disabled: a3 = false, focusableWhenDisabled: o3 = false, nativeButton: s3 = true, style: c2, ...l4 } = t2, { getButtonProps: u3, buttonRef: d3 } = Z({ disabled: a3, focusableWhenDisabled: o3, native: s3 }); - return q(`button`, t2, { state: { disabled: a3 }, ref: [n2, d3], props: [l4, u3] }); -}); -var ip = [`input:not([inert]):not([inert] *)`, `select:not([inert]):not([inert] *)`, `textarea:not([inert]):not([inert] *)`, `a[href]:not([inert]):not([inert] *)`, `button:not([inert]):not([inert] *)`, `[tabindex]:not(slot):not([inert]):not([inert] *)`, `audio[controls]:not([inert]):not([inert] *)`, `video[controls]:not([inert]):not([inert] *)`, `[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)`, `details>summary:first-of-type:not([inert]):not([inert] *)`, `details:not([inert]):not([inert] *)`].join(`,`); -var ap = typeof Element > `u`; -var op = ap ? function() { -} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector; -var sp = !ap && Element.prototype.getRootNode ? function(e9) { - return e9?.getRootNode?.call(e9); -} : function(e9) { - return e9?.ownerDocument; -}; -var cp = function(e9, t2) { - t2 === void 0 && (t2 = true); - var n2 = e9?.getAttribute?.call(e9, `inert`); - return n2 === `` || n2 === `true` || t2 && e9 && (typeof e9.closest == `function` ? e9.closest(`[inert]`) : cp(e9.parentNode)); -}; -var lp = function(e9) { - var t2 = e9?.getAttribute?.call(e9, `contenteditable`); - return t2 === `` || t2 === `true`; -}; -var up = function(e9, t2, n2) { - if (cp(e9)) return []; - var r2 = Array.prototype.slice.apply(e9.querySelectorAll(ip)); - return t2 && op.call(e9, ip) && r2.unshift(e9), r2 = r2.filter(n2), r2; -}; -var dp = function(e9, t2, n2) { - for (var r2 = [], i3 = Array.from(e9); i3.length; ) { + } + function i4() { + z2.current = `keyboard`; + } + return Hn(Vn(e39, `pointerdown`, n3, true), Vn(e39, `pointerup`, t3, true), Vn(e39, `pointercancel`, t3, true), Vn(e39, `keydown`, i4, true), t3); + }, [r2, v5, _5, K4, g5, N3, W3, q4]), x.useEffect(() => { + if (r2 || !l5) return; + let e39 = ft(K4); + function n3() { + F2.current = true, W3.start(0, () => { + F2.current = false; + }); + } + function i4(e40) { + let t3 = _n(e40); + Qr(t3) && (L3.current = t3); + } + function a4(n4) { + let r3 = n4.relatedTarget, i5 = n4.currentTarget, a5 = _n(n4); + c3 && r3 == null && a5 != null && $(v5, a5) && Zi(a5), queueMicrotask(() => { + let o5 = C2(), l6 = t2.context.triggerElements, u5 = q4(), p5 = r3?.hasAttribute(ui(`focus-guard`)) && [ee2.current, B3.current, N3?.beforeInsideRef.current, N3?.afterInsideRef.current, N3?.beforeOutsideRef.current, N3?.afterOutsideRef.current, Ki(f4), Ki(d3)].includes(r3), m4 = !($(_5, r3) || $(v5, r3) || $(r3, v5) || $(N3?.portalNode, r3) || u5.some((e40) => e40 === r3 || $(e40, r3)) || l6.hasMatchingElement((e40) => $(e40, r3)) || p5 || M2 && (ci(M2.nodesRef.current, o5).find((e40) => $(e40.context?.elements.floating, r3) || $(e40.context?.elements.domReference, r3)) || li(M2.nodesRef.current, o5).find((e40) => [e40.context?.elements.floating, Mn(e40.context?.elements.floating)].includes(r3) || e40.context?.elements.domReference === r3))); + if (i5 === _5 && K4 && ea(K4), s3 && i5 !== _5 && !Rr(a5) && hn(e39) === e39.body) { + if (ze2(K4) && (K4.focus(), s3 === `popup`)) { + G2.request(() => { + K4.focus(); + }); + return; + } + let e40 = ne3(), t3 = L3.current, n5 = (t3 && e40.includes(t3) ? t3 : null) || e40[e40.length - 1] || K4; + ze2(n5) && n5.focus(); + } + if (S2.current.insideReactTree) { + S2.current.insideReactTree = false; + return; + } + (T2 || !c3) && r3 && m4 && !F2.current && (T2 || r3 !== Qi()) && (P3.current = true, t2.setOpen(false, Q(Dt, n4))); + }); + } + function o4() { + I2.current || (S2.current.insideReactTree = true, U3.start(0, () => { + S2.current.insideReactTree = false; + })); + } + let u4 = ze2(_5) ? _5 : null; + if (v5 || u4) return Hn(u4 && Vn(u4, `focusout`, a4), u4 && Vn(u4, `pointerdown`, n3), v5 && Vn(v5, `focusin`, i4), v5 && Vn(v5, `focusout`, a4), v5 && N3 && Vn(v5, `focusout`, o4, true)); + }, [r2, _5, v5, K4, c3, M2, N3, t2, l5, s3, ne3, T2, C2, S2, U3, W3, G2, d3, f4, q4]), x.useEffect(() => { + if (r2 || !v5 || !g5) return; + let e39 = Array.from(N3?.portalNode?.querySelectorAll(`[${ui(`portal`)}]`) || []), t3 = (M2 ? li(M2.nodesRef.current, C2()) : []).find((e40) => An(e40.context?.elements.domReference || null))?.context?.elements.domReference, n3 = Ci([v5, ...e39, ee2.current, B3.current, N3?.beforeOutsideRef.current, N3?.afterOutsideRef.current, ...q4(), t3, Ki(f4), Ki(d3), T2 ? _5 : null].filter((e40) => e40 != null), { ariaHidden: c3 || T2, mark: false }), i4 = Ci([v5, ...e39].filter((e40) => e40 != null)); + return () => { + i4(), n3(); + }; + }, [g5, r2, _5, v5, c3, N3, T2, M2, C2, d3, f4, q4]), X(() => { + if (!g5 || r2 || !ze2(K4)) return; + R3.current = ``, z2.current = ``; + let e39 = ft(K4), t3 = hn(e39); + queueMicrotask(() => { + let n3 = D2.current, r3 = typeof n3 == `function` ? n3(A2.current || ``) : n3; + if (r3 === void 0 || r3 === false || $(K4, t3)) return; + let i4 = null, a4 = () => (i4 ??= ne3(K4), i4[0] || K4), o4; + o4 = r3 === true || r3 === null ? a4() : Ki(r3), o4 ||= a4(); + let s4 = $(K4, hn(e39)), c4 = S2.current.openEvent, l6 = c4?.type === `mousedown` && dn(c4); + fi(o4, { sync: l6, preventScroll: o4 === K4, shouldFocus() { + if (!j2.current) return false; + if (s4) return true; + let t4 = hn(e39); + return !(t4 !== o4 && $(K4, t4)); + } }); + }); + }, [r2, g5, K4, ne3, D2, A2, j2, S2]); + let re3 = x.useRef(null); + X(() => { + if (r2 || !K4) { + re3.current = null; + return; + } + re3.current &&= (re3.current.cancelled = true, null); + let e39 = ft(K4), t3 = hn(e39), n3 = A2.current == null; + Zi(t3); + function i4(e40) { + if (e40.open || (R3.current = qi(e40.nativeEvent, z2.current)), (e40.reason === `focus-out` && e40.triggerElement?.hasAttribute(ui(`focus-guard`)) || e40.reason === `trigger-hover` && e40.nativeEvent.type === `mouseleave`) && (P3.current = true), e40.reason === `outside-press`) { + if (e40.nested) P3.current = false; + else if (dn(e40.nativeEvent) || fn2(e40.nativeEvent)) P3.current = false; + else { + let e41 = false; + ft(K4).createElement(`div`).focus({ get preventScroll() { + return e41 = true, false; + } }), e41 ? P3.current = false : P3.current = true; + } + } + } + y4.on(`openchange`, i4); + function a4(e40) { + let r3 = O2.current, i5 = typeof r3 == `function` ? r3(e40) : r3; + if (i5 === void 0 || i5 === false) return null; + i5 === null && (i5 = true); + let a5 = _5?.isConnected ? _5 : null, o4 = t3?.isConnected && Pe2(t3) !== `body` ? t3 : null, s4 = n3 ? o4 || a5 : a5 || o4; + return s4 ||= Qi() || null, typeof i5 == `boolean` ? s4 : Ki(i5) || s4 || null; + } + return () => { + y4.off(`openchange`, i4); + let t4 = hn(e39), n4 = q4(), r3 = $(v5, t4) || n4.some((e40) => e40 === t4 || $(e40, t4)) || M2 && ci(M2.nodesRef.current, C2(), false).some((e40) => $(e40.context?.elements.floating, t4)), o4 = O2.current, s4 = R3.current, c4 = a4(s4), l6 = { cancelled: false }; + re3.current = l6, queueMicrotask(() => { + re3.current === l6 && (re3.current = null); + let n5 = $i(c4), i5 = k2.current ?? typeof o4 != `boolean`; + if (!l6.cancelled && o4 && !P3.current && ze2(n5) && (i5 || n5 === t4 || t4 === e39.body || r3)) { + let e40 = { preventScroll: true }; + s4 === `keyboard` && (e40.focusVisible = true), n5.focus(e40); + } + P3.current = false; + }); + }; + }, [r2, v5, K4, O2, k2, A2, y4, M2, _5, C2, q4]), X(() => { + if (!an || g5 || !v5) return; + let e39 = hn(ft(v5)); + ze2(e39) && On(e39) && $(v5, e39) && e39.blur(); + }, [g5, v5]), X(() => { + if (!r2 && N3) return N3.setFocusManagerState({ modal: c3, closeOnFocusOut: l5, open: g5, onOpenChange: t2.setOpen, domReference: _5 }), () => { + N3.setFocusManagerState(null); + }; + }, [r2, N3, c3, g5, t2, l5, _5]), X(() => { + if (!r2 && K4) return ea(K4), () => { + queueMicrotask(Xi); + }; + }, [r2, K4]); + let ie3 = !r2 && (!c3 || !T2) && (te2 || c3); + return (0, b.jsxs)(x.Fragment, { children: [ie3 && (0, b.jsx)(Qn, { "data-type": `inside`, ref: V3, onFocus: (e39) => { + if (c3) { + let e40 = ne3(); + fi(e40[e40.length - 1]); + } else N3?.portalNode && (P3.current = false, ai(e39, N3.portalNode) ? ni(_5)?.focus() : Ki(f4 ?? N3.beforeOutsideRef)?.focus()); + } }), n2, ie3 && (0, b.jsx)(Qn, { "data-type": `inside`, ref: H3, onFocus: (e39) => { + c3 ? fi(ne3()[0]) : N3?.portalNode && (l5 && (P3.current = true), ai(e39, N3.portalNode) ? ri(_5)?.focus() : Ki(d3 ?? N3.afterOutsideRef)?.focus()); + } })] }); +} +function na(e38, t2 = {}) { + let { enabled: n2 = true, event: r2 = `click`, toggle: i3 = true, ignoreMouse: a3 = false, stickIfOpen: o3 = true, touchOpenDelay: s3 = 0, reason: c3 = vt } = t2, l5 = e38.context.dataRef, u3 = x.useRef(void 0), d3 = Jn(), f4 = Kt(), p4 = x.useMemo(() => { + function t3(t4, n4, r3, i4) { + let a4 = Q(c3, n4, r3); + t4 && i4 === `touch` && s3 > 0 ? f4.start(s3, () => { + e38.setOpen(true, a4); + }) : e38.setOpen(t4, a4); + } + function n3(t4, n4, r3) { + let a4 = l5.current.openEvent, s4 = e38.select(`domReferenceElement`) !== n4; + return t4 && s4 || !t4 || !i3 ? true : a4 && (typeof o3 == `function` ? o3() : o3) ? !r3(a4.type) : false; + } + return { onPointerDown(e39) { + u3.current = pn(e39.pointerType, true) && fn2(e39.nativeEvent) ? `virtual` : e39.pointerType; + }, onMouseDown(i4) { + let o4 = u3.current, s4 = i4.nativeEvent, c4 = e38.select(`open`); + if (i4.button !== 0 || r2 === `click` || pn(o4, true) && a3) return; + let l6 = n3(c4, i4.currentTarget, (e39) => e39 === `click` || e39 === `mousedown`), f5 = _n(s4), p5 = On(f5); + if (p5 || o4 === `virtual`) { + t3(l6, s4, p5 ? f5 : i4.currentTarget, o4); + return; + } + let m3 = i4.currentTarget; + d3.request(() => { + t3(l6, s4, m3, o4); + }); + }, onClick(i4) { + if (r2 === `mousedown-only`) return; + let o4 = u3.current; + if (r2 === `mousedown` && o4) { + u3.current = void 0; + return; + } + pn(o4, true) && a3 || t3(n3(e38.select(`open`), i4.currentTarget, (e39) => e39 === `click` || e39 === `mousedown` || e39 === `keydown` || e39 === `keyup`), i4.nativeEvent, i4.currentTarget, o4); + }, onKeyDown() { + u3.current = void 0; + } }; + }, [l5, r2, a3, c3, e38, o3, i3, d3, f4, s3]); + return x.useMemo(() => n2 ? { reference: p4 } : R, [n2, p4]); +} +function ra(e38, t2) { + let n2 = null, r2 = null, i3 = false; + return { contextElement: e38 || void 0, getBoundingClientRect() { + let a3 = e38?.getBoundingClientRect() || { width: 0, height: 0, x: 0, y: 0 }, o3 = t2.axis === `x` || t2.axis === `both`, s3 = t2.axis === `y` || t2.axis === `both`, c3 = [`mouseenter`, `mousemove`].includes(t2.dataRef.current.openEvent?.type || ``) && t2.pointerType !== `touch`, l5 = t2.axis === `y` ? a3.width : 0, u3 = t2.axis === `x` ? a3.height : 0, d3 = a3.x, f4 = a3.y; + return n2 == null && t2.x && o3 && (n2 = a3.x - t2.x), r2 == null && t2.y && s3 && (r2 = a3.y - t2.y), d3 -= n2 || 0, f4 -= r2 || 0, (!i3 || c3) && (d3 = o3 && t2.x != null ? t2.x : d3, f4 = s3 && t2.y != null ? t2.y : f4), i3 = true, { width: l5, height: u3, x: d3, y: f4, top: f4, right: d3 + l5, bottom: f4 + u3, left: d3 }; + } }; +} +function ia(e38) { + return e38 != null && e38.clientX != null; +} +function aa(e38, t2 = {}) { + let { enabled: n2 = true, axis: r2 = `both` } = t2, i3 = e38.useState(`open`), a3 = e38.useState(`floatingElement`), o3 = e38.useState(`domReferenceElement`), s3 = e38.context.dataRef, c3 = x.useRef(false), l5 = x.useRef(null), [u3, d3] = x.useState(), [f4, p4] = x.useState([]), m3 = Y((t3) => { + e38.set(`positionReference`, t3); + }), h4 = Y((t3, n3, i4) => { + c3.current || (!s3.current.openEvent || ia(s3.current.openEvent)) && e38.set(`positionReference`, ra(i4 ?? o3, { x: t3, y: n3, axis: r2, dataRef: s3, pointerType: u3 })); + }), g5 = Y((e39) => { + i3 ? l5.current || (h4(e39.clientX, e39.clientY, e39.currentTarget), p4([])) : h4(e39.clientX, e39.clientY, e39.currentTarget); + }), _5 = pn(u3) ? a3 : i3; + x.useEffect(() => { + if (!n2) { + m3(o3); + return; + } + if (!_5) return; + function e39() { + l5.current?.(), l5.current = null; + } + let t3 = Fe(a3); + function r3(t4) { + let n3 = _n(t4); + $(a3, n3) ? e39() : h4(t4.clientX, t4.clientY); + } + return !s3.current.openEvent || ia(s3.current.openEvent) ? l5.current = Vn(t3, `mousemove`, r3) : m3(o3), e39; + }, [_5, n2, a3, s3, o3, e38, h4, m3, f4]), x.useEffect(() => () => { + e38.set(`positionReference`, null); + }, [e38]), x.useEffect(() => { + n2 && !a3 && (c3.current = false); + }, [n2, a3]), x.useEffect(() => { + !n2 && i3 && (c3.current = true); + }, [n2, i3]); + let v5 = x.useMemo(() => { + function e39(e40) { + d3(e40.pointerType); + } + return { onPointerDown: e39, onPointerEnter: e39, onMouseMove: g5, onMouseEnter: g5 }; + }, [g5]); + return x.useMemo(() => n2 ? { reference: v5, trigger: v5 } : {}, [n2, v5]); +} +function oa() { + return false; +} +function sa(e38) { + return { escapeKey: typeof e38 == `boolean` ? e38 : e38?.escapeKey ?? false, outsidePress: typeof e38 == `boolean` ? e38 : e38?.outsidePress ?? true }; +} +function ca(e38, t2 = {}) { + let { enabled: n2 = true, escapeKey: r2 = true, outsidePress: i3 = true, outsidePressEvent: a3 = `sloppy`, referencePress: o3 = oa, bubbles: s3, externalTree: c3 } = t2, l5 = e38.useState(`open`), u3 = e38.useState(`floatingElement`), { dataRef: d3, events: f4 } = e38.context, p4 = Hi(c3), m3 = Y(typeof i3 == `function` ? i3 : () => false), h4 = typeof i3 == `function` ? m3 : i3, g5 = h4 !== false, _5 = Y(() => a3), { escapeKey: v5, outsidePress: y4 } = sa(s3), b2 = x.useRef(false), S2 = x.useRef(false), C2 = x.useRef(false), w2 = x.useRef(false), T2 = x.useRef(false), E2 = x.useRef(``), D2 = x.useRef(null), O2 = Kt(), k2 = Kt(), A2 = Kt(), j2 = Y(() => { + k2.clear(), d3.current.insideReactTree = false; + }), M2 = Y((e39) => { + let t3 = d3.current.floatingContext?.nodeId; + return (p4 ? ci(p4.nodesRef.current, t3) : []).some((t4) => t4.context?.open && !t4.context.dataRef.current[e39]); + }), N3 = Y((t3) => En(t3, e38.select(`floatingElement`)) || En(t3, e38.select(`domReferenceElement`))), P3 = Y((t3) => { + o3() && e38.setOpen(false, Q(vt, t3.nativeEvent)); + }), F2 = Y((t3) => { + if (!l5 || !n2 || !r2 || t3.key !== `Escape`) return; + let i4 = un(t3) ? t3.nativeEvent : t3; + if (T2.current || i4.isComposing || !v5 && M2(`__escapeKeyBubbles`)) return; + let a4 = Q(Ot, i4); + e38.setOpen(false, a4), a4.isCanceled || t3.preventDefault(), !v5 && !a4.isPropagationAllowed && t3.stopPropagation(); + }), I2 = Y(() => { + d3.current.insideReactTree = true, k2.start(0, j2); + }), L3 = Y((t3) => { + if (!l5 || !n2 || t3.button !== 0) return; + let r3 = _n(t3.nativeEvent); + $(e38.select(`floatingElement`), r3) && (b2.current || (b2.current = true, S2.current = false)); + }), R3 = Y((e39) => { + l5 && n2 && (e39.defaultPrevented || e39.nativeEvent.defaultPrevented) && b2.current && (S2.current = true); + }); + x.useEffect(() => { + function e39(e40) { + e40.open || (w2.current = false); + } + return f4.on(`openchange`, e39), () => { + f4.off(`openchange`, e39); + }; + }, [f4]), x.useEffect(() => j2, [j2]), x.useEffect(() => { + if (!l5 || !n2) return l5 || (w2.current = false, T2.current = false, E2.current = ``, D2.current = null), j2; + d3.current.__escapeKeyBubbles = v5, d3.current.__outsidePressBubbles = y4; + let t3 = new Gt(), i4 = ft(u3); + function a4() { + A2.clear(), T2.current = true; + } + function o4() { + T2.current = true, A2.start(an ? 5 : 0, () => { + T2.current = false; + }); + } + function s4() { + C2.current = true, t3.start(0, () => { + C2.current = false; + }); + } + function c4() { + b2.current = false, S2.current = false; + } + function f5() { + let e39 = E2.current, t4 = e39 === `pen` || !e39 ? `mouse` : e39, n3 = _5(), r3 = typeof n3 == `function` ? n3() : n3; + return typeof r3 == `string` ? r3 : r3[t4]; + } + function m4(e39) { + let t4 = f5(); + return t4 === `intentional` && e39.type !== `click` || t4 === `sloppy` && e39.type === `click`; + } + function x2(e39) { + let t4 = d3.current.floatingContext?.nodeId, n3 = p4 && ci(p4.nodesRef.current, t4).some((t5) => En(e39, t5.context?.elements.floating)); + return N3(e39) || n3; + } + function k3(n3) { + if (m4(n3)) { + n3.type !== `click` && !N3(n3) && (t3.clear(), C2.current = false), j2(); + return; + } + if (d3.current.insideReactTree) { + j2(); + return; + } + let r3 = _n(n3), i5 = `[${ui(`inert`)}]`, a5 = Re2(r3) ? r3.getRootNode() : null, o5 = Array.from((Be2(a5) ? a5 : ft(e38.select(`floatingElement`))).querySelectorAll(i5)), s5 = e38.context.triggerElements; + if (r3 && (s5.hasElement(r3) || s5.hasMatchingElement((e39) => $(e39, r3)))) return; + let c5 = Re2(r3) ? r3 : null; + for (; c5 && !Ze(c5); ) { + let e39 = et(c5); + if (Ze(e39) || !Re2(e39)) break; + c5 = e39; + } + if (!(o5.length && Re2(r3) && !Dn(r3) && !$(r3, e38.select(`floatingElement`)) && o5.every((e39) => !$(c5, e39)))) { + if (ze2(r3) && !(`touches` in n3)) { + let e39 = Ze(r3), t4 = Qe(r3), i6 = /auto|scroll/, a6 = e39 || i6.test(t4.overflowX), o6 = e39 || i6.test(t4.overflowY), s6 = a6 && r3.clientWidth > 0 && r3.scrollWidth > r3.clientWidth, c6 = o6 && r3.clientHeight > 0 && r3.scrollHeight > r3.clientHeight, l6 = t4.direction === `rtl`, u4 = c6 && (l6 ? n3.offsetX <= r3.offsetWidth - r3.clientWidth : n3.offsetX > r3.clientWidth), d4 = s6 && n3.offsetY > r3.clientHeight; + if (u4 || d4) return; + } + if (!x2(n3)) { + if (f5() === `intentional`) { + if (n3.detail !== 0 && !dn(n3) && !w2.current) return; + if (C2.current) { + t3.clear(), C2.current = false; + return; + } + } + (typeof h4 != `function` || h4(n3)) && (M2(`__outsidePressBubbles`) || (e38.setOpen(false, Q(xt, n3)), j2())); + } + } + } + function P4(t4) { + f5() === `sloppy` && t4.pointerType !== `touch` && e38.select(`open`) && n2 && !N3(t4) && k3(t4); + } + function I3(t4) { + if (f5() !== `sloppy` || !e38.select(`open`) || !n2 || N3(t4)) return; + let r3 = t4.touches[0]; + r3 && (D2.current = { startTime: Date.now(), startX: r3.clientX, startY: r3.clientY, dismissOnTouchEnd: false, dismissOnMouseDown: true }, O2.start(1e3, () => { + D2.current && (D2.current.dismissOnTouchEnd = false, D2.current.dismissOnMouseDown = false); + })); + } + function L4(e39, t4) { + let n3 = _n(e39); + if (!n3) return; + let r3 = Vn(n3, e39.type, () => { + t4(e39), r3(); + }); + } + function R4(e39) { + E2.current = `touch`, L4(e39, I3); + } + function z3(e39) { + O2.clear(), e39.type === `pointerdown` && (e39.button === 0 && (w2.current = true), E2.current = e39.pointerType), (e39.type !== `mousedown` || !D2.current || D2.current.dismissOnMouseDown) && L4(e39, (e40) => { + e40.type === `pointerdown` ? P4(e40) : k3(e40); + }); + } + function ee3(e39) { + if (e39.type === `pointercancel` && (w2.current = false), !b2.current) return; + let n3 = S2.current; + if (c4(), f5() === `intentional`) { + if (e39.type === `pointercancel`) { + n3 && s4(); + return; + } + if (!x2(e39)) { + if (n3) { + s4(); + return; + } + (typeof h4 != `function` || h4(e39)) && (t3.clear(), C2.current = true, j2()); + } + } + } + function B3(e39) { + if (f5() !== `sloppy` || !D2.current || N3(e39)) return; + let t4 = e39.touches[0]; + if (!t4) return; + let n3 = Math.abs(t4.clientX - D2.current.startX), r3 = Math.abs(t4.clientY - D2.current.startY), i5 = Math.sqrt(n3 * n3 + r3 * r3); + i5 > 5 && (D2.current.dismissOnTouchEnd = true), i5 > 10 && (k3(e39), O2.clear(), D2.current = null); + } + function V3(e39) { + L4(e39, B3); + } + function H3(e39) { + f5() === `sloppy` && D2.current && !N3(e39) && (D2.current.dismissOnTouchEnd && k3(e39), O2.clear(), D2.current = null); + } + function U3(e39) { + L4(e39, H3); + } + let W3 = Hn(r2 && Hn(Vn(i4, `keydown`, F2), Vn(i4, `compositionstart`, a4), Vn(i4, `compositionend`, o4)), g5 && Hn(Vn(i4, `click`, z3, true), Vn(i4, `pointerdown`, z3, true), Vn(i4, `pointerup`, ee3, true), Vn(i4, `pointercancel`, ee3, true), Vn(i4, `mousedown`, z3, true), Vn(i4, `mouseup`, ee3, true), Vn(i4, `touchstart`, R4, { capture: true, passive: true }), Vn(i4, `touchmove`, V3, { capture: true, passive: true }), Vn(i4, `touchend`, U3, { capture: true, passive: true }))); + return () => { + W3(), t3.clear(), c4(), C2.current = false; + }; + }, [d3, u3, r2, g5, h4, l5, n2, v5, y4, F2, j2, _5, M2, N3, p4, e38, O2, A2]); + let z2 = x.useMemo(() => ({ onKeyDown: F2, onPointerDown: P3, onClick: P3 }), [F2, P3]), ee2 = x.useMemo(() => ({ onKeyDown: F2, onPointerDown: R3, onMouseDown: R3, onClickCapture: I2, onMouseDownCapture(e39) { + I2(), L3(e39); + }, onPointerDownCapture(e39) { + I2(), L3(e39); + }, onMouseUpCapture: I2, onTouchEndCapture: I2, onTouchMoveCapture: I2 }), [F2, I2, L3, R3]); + return x.useMemo(() => n2 ? { reference: z2, floating: ee2, trigger: z2 } : {}, [n2, z2, ee2]); +} +function la(e38, t2, n2, r2) { + return { left: e38, top: t2, right: n2, bottom: r2, x: e38, y: t2, width: n2 - e38, height: r2 - t2 }; +} +function ua(e38) { + return { left: e38.left, top: e38.top, right: e38.right, bottom: e38.bottom, width: e38.width, height: e38.height }; +} +function da(e38) { + let t2 = [], n2, r2 = 1 / 0, i3 = 1 / 0, a3 = -1 / 0, o3 = -1 / 0; + for (let s3 of Array.from(e38).sort((e39, t3) => e39.top - t3.top)) { + if (r2 = Math.min(r2, s3.left), i3 = Math.min(i3, s3.top), a3 = Math.max(a3, s3.right), o3 = Math.max(o3, s3.bottom), !n2 || s3.top - n2.top > n2.height / 2) t2.push(ua(s3)); + else { + let e39 = t2[t2.length - 1]; + e39.left = Math.min(e39.left, s3.left), e39.right = Math.max(e39.right, s3.right), e39.bottom = Math.max(e39.bottom, s3.bottom), e39.width = e39.right - e39.left, e39.height = e39.bottom - e39.top; + } + n2 = s3; + } + return { lines: t2, fallback: la(r2, i3, a3, o3) }; +} +function fa(e38, t2, n2) { + return e38.findIndex((e39) => t2 > e39.left - 2 && t2 < e39.right + 2 && n2 > e39.top - 2 && n2 < e39.bottom + 2); +} +function pa(e38) { + return la(e38.left, e38.top, e38.right, e38.bottom); +} +function ma(e38, t2, n2) { + let { lines: r2 } = da(e38.getClientRects()); + if (r2.length < 2) return; + let i3 = fa(r2, t2, n2); + return { x: t2, y: n2, lineIndex: i3 === -1 ? void 0 : i3, element: e38 }; +} +function ha(e38, t2, n2) { + let { lines: r2, fallback: i3 } = da(e38.getClientRects()); + if (r2.length < 2) return null; + let a3 = n2?.x, o3 = n2?.y, s3 = t2[0]; + if (n2?.lineIndex != null && r2[n2.lineIndex]) return pa(r2[n2.lineIndex]); + if (a3 != null && o3 != null) { + let e39 = fa(r2, a3, o3); + if (e39 !== -1) return pa(r2[e39]); + } + if (r2.length === 2 && r2[0].left > r2[1].right && a3 != null && o3 != null) return i3; + if (s3 === `t` || s3 === `b`) { + let e39 = r2[0], t3 = r2[r2.length - 1], n3 = s3 === `t` ? e39 : t3; + return la(n3.left, e39.top, n3.right, t3.bottom); + } + let c3 = s3 === `l`, l5 = r2[0].left, u3 = r2[0].right, d3 = c3 ? 1 / 0 : -1 / 0, f4 = r2[0], p4 = r2[0]; + for (let e39 of r2) { + l5 = Math.min(l5, e39.left), u3 = Math.max(u3, e39.right); + let t3 = c3 ? e39.left : e39.right; + c3 && t3 < d3 || !c3 && t3 > d3 ? (d3 = t3, f4 = e39, p4 = e39) : t3 === d3 && (p4 = e39); + } + return la(l5, f4.top, u3, p4.bottom); +} +function ga(e38) { + return `contextElement` in e38 && e38.contextElement ? e38.contextElement : Re2(e38) ? e38 : void 0; +} +function _a(e38, t2) { + function n2(t3) { + va(e38, t3.currentTarget, t3.clientX, t3.clientY); + } + function r2(e39) { + t2 || n2(e39); + } + return { onFocus() { + e38.current = void 0; + }, onMouseEnter: r2, onMouseMove: r2 }; +} +function va(e38, t2, n2, r2) { + let i3 = ma(t2, n2, r2); + return e38.current = i3, i3; +} +function ya(e38) { + return { name: `inline`, async fn(t2) { + let n2 = t2.elements.reference; + if (typeof n2?.getClientRects != `function`) return {}; + let r2 = ga(n2), i3 = e38.current, a3 = i3?.element === n2 || i3?.element === r2 ? i3 : void 0, o3 = ha(n2, t2.placement, a3); + if (!o3 || typeof t2.platform.getElementRects != `function`) return {}; + let s3 = await t2.platform.getElementRects({ reference: { contextElement: r2, getBoundingClientRect() { + return o3; + } }, floating: t2.elements.floating, strategy: t2.strategy }); + return t2.rects.reference.x === s3.reference.x && t2.rects.reference.y === s3.reference.y && t2.rects.reference.width === s3.reference.width && t2.rects.reference.height === s3.reference.height ? {} : { reset: { rects: s3 } }; + } }; +} +var ba = class { + attachedStores = []; + attachedStoreValue = null; + storeListeners = /* @__PURE__ */ new Set(); + constructor(e38, t2, n2 = true) { + this.fallbackStore = e38, this.componentName = t2, this.throwOnMissingTrigger = n2; + } + get attachedStore() { + return this.attachedStoreValue; + } + get store() { + return this.attachedStoreValue ?? this.fallbackStore; + } + get serverStore() { + return this.fallbackStore; + } + subscribeStore(e38) { + return this.storeListeners.add(e38), () => { + this.storeListeners.delete(e38); + }; + } + attachStore(e38) { + return this.attachedStores.push(e38), this.setActiveStore(e38), () => { + let t2 = this.attachedStores.lastIndexOf(e38); + t2 !== -1 && this.attachedStores.splice(t2, 1), this.setActiveStore(this.attachedStores[this.attachedStores.length - 1] ?? null); + }; + } + setActiveStore(e38) { + this.attachedStoreValue !== e38 && (this.attachedStoreValue = e38, this.storeListeners.forEach((e39) => { + e39(); + })); + } + openByTrigger(e38) { + let t2 = this.attachedStore; + if (t2 === null) return; + let n2; + if (e38) { + for (let t3 = this.attachedStores.length - 1; t3 >= 0 && !n2; --t3) n2 = this.attachedStores[t3].context.triggerElements.getById(e38); + n2 ??= this.fallbackStore.context.triggerElements.getById(e38); + } + if (e38 && !n2 && this.throwOnMissingTrigger) throw Error(C(99, this.componentName, e38, this.componentName)); + t2.setOpen(true, Q(Ft, void 0, n2)); + } + closePopup() { + let e38 = this.attachedStore; + e38 !== null && e38.setOpen(false, Q(Ft)); + } +}; +function xa(e38) { + let { popupStore: t2, treatPopupAsFloatingElement: n2 = false, floatingRootContext: r2, floatingId: i3, nested: a3, onOpenChange: o3 } = e38, s3 = t2.useState(`open`), c3 = t2.useState(`activeTriggerElement`), l5 = t2.useState(n2 ? `popupElement` : `positionerElement`), u3 = o3; + return t2.useSyncedValue(`floatingId`, i3), X(() => { + let e39 = { open: s3, floatingId: i3, referenceElement: c3, floatingElement: l5 }; + Re2(c3) && (e39.domReferenceElement = c3), r2.state.positionReference === r2.state.referenceElement && (e39.positionReference = c3), r2.update(e39); + }, [s3, i3, c3, l5, r2]), r2.context.onOpenChange = u3, r2.context.nested = a3, r2; +} +function Sa(e38, t2 = false, n2 = false, r2 = false) { + let [i3, a3] = x.useState(e38 && t2 ? `idle` : void 0), [o3, s3] = x.useState(e38 && !r2); + return e38 && !o3 && (s3(true), a3(`starting`)), !e38 && o3 && i3 !== `ending` && !n2 && a3(`ending`), !e38 && !o3 && i3 === `ending` && a3(void 0), X(() => { + if (!e38 && o3 && i3 !== `ending` && n2) { + let e39 = qn.request(() => { + a3(`ending`); + }); + return () => { + qn.cancel(e39); + }; + } + }, [e38, o3, i3, n2]), X(() => { + if (!e38 || t2 || i3 === void 0) return; + let n3 = qn.request(() => { + a3(void 0); + }); + return () => { + qn.cancel(n3); + }; + }, [t2, e38, i3]), X(() => { + if (!e38 || !t2) return; + e38 && o3 && i3 !== `idle` && a3(`starting`); + let n3 = qn.request(() => { + a3(`idle`); + }); + return () => { + qn.cancel(n3); + }; + }, [t2, e38, o3, i3]), { mounted: o3, setMounted: s3, transitionStatus: i3 }; +} +function Ca(e38, t2) { + return e38.getAnimations(t2).filter((e39) => { + let t3 = e39.effect?.getTiming(); + return t3?.duration !== 1 / 0 && t3?.iterations !== 1 / 0; + }); +} +var wa = null; +function Ta(e38) { + if (!wa) { + let e39 = []; + wa = e39, queueMicrotask(() => { + wa = null, Ei.flushSync(() => { + for (let t2 of e39) t2(); + }); + }); + } + wa.push(e38); +} +function Ea(e38, t2 = false, n2 = false) { + let r2 = Jn(); + return Y((i3, a3 = null) => { + r2.cancel(); + let o3 = Ki(e38); + if (o3 == null) return; + let s3 = o3, c3 = () => { + if (!n2) { + Ei.flushSync(i3); + return; + } + Ta(() => { + a3?.aborted || i3(); + }); + }; + if (typeof s3.getAnimations != `function` || globalThis.BASE_UI_ANIMATIONS_DISABLED) { + i3(); + return; + } + function l5() { + Promise.all(Ca(s3).map((e39) => e39.finished.then(I))).then(() => { + a3?.aborted || c3(); + }, () => { + if (!a3?.aborted) { + if (Ca(s3).some((e39) => e39.pending || e39.playState !== `finished`)) { + l5(); + return; + } + c3(); + } + }); + } + if (t2) { + let e39 = me2; + if (!s3.hasAttribute(e39)) { + r2.request(l5); + return; + } + let t3 = new MutationObserver(() => { + s3.hasAttribute(e39) || (t3.disconnect(), l5()); + }); + t3.observe(s3, { attributes: true, attributeFilter: [e39] }), a3?.addEventListener(`abort`, () => t3.disconnect(), { once: true }); + return; + } + r2.request(l5); + }); +} +function Da(e38) { + let { enabled: t2 = true, open: n2, ref: r2, batch: i3 = false, onComplete: a3 } = e38, o3 = Y(a3), s3 = Ea(r2, n2, i3); + x.useEffect(() => { + if (!t2) return; + let e39 = new AbortController(); + return s3(o3, e39.signal), () => { + e39.abort(); + }; + }, [t2, n2, o3, s3]); +} +function Oa(e38) { + let { open: t2, ref: n2, preventUnmountOnClose: r2, setPreventUnmountOnClose: i3, onUnmount: a3, animateInitialOpen: o3 } = e38, s3 = Y(i3), { mounted: c3, setMounted: l5, transitionStatus: u3 } = Sa(t2, false, false, o3), d3 = !t2 && r2; + X(() => { + t2 && s3(false); + }, [t2, s3]); + let f4 = x.useRef(c3), p4 = x.useRef(false), m3 = Lt(), h4 = () => { + f4.current = false, l5(false), a3(); + }; + X(() => { + f4.current = c3, p4.current && (p4.current = false, !t2 && c3 && h4()); + }); + let g5 = Y(() => { + if (f4.current) { + if (t2) { + p4.current = true, m3(); + return; + } + h4(); + } + }); + return Da({ enabled: c3 && !t2 && !d3, open: t2, ref: n2, onComplete() { + t2 || g5(); + } }), { mounted: c3, transitionStatus: u3, preventUnmountingOnClose: d3, forceUnmount: g5 }; +} +var ka = { tabIndex: -1, [vn]: `` }; +function ja(e38, t2 = false) { + let n2 = Vt(), r2 = Vi() != null, i3 = T(() => e38(n2, r2)).current; + return xa({ popupStore: i3, treatPopupAsFloatingElement: t2, floatingRootContext: i3.state.floatingRootContext, floatingId: n2, nested: r2, onOpenChange: i3.setOpen }), i3; +} +function Ma({ handle: e38, store: t2 }) { + return Reflect.set(Ma, `d`, 258546344), X(() => e38.attachStore(t2), [e38, t2]), null; +} +function Na(e38) { + let t2 = e38.context.triggerElements.size; + e38.select(`open`) && e38.state.triggerCount !== t2 && e38.set(`triggerCount`, t2); +} +function Pa(e38, t2) { + let n2 = x.useRef(null); + return Y((r2) => { + let i3 = n2.current; + if (i3 !== null) { + if (i3.element === r2 && i3.store === t2 && i3.id === e38) return; + n2.current = null; + let a3 = i3.store; + a3.context.triggerElements.getById(i3.id) === i3.element && (a3.context.triggerElements.delete(i3.id), Na(a3)); + } + r2 !== null && e38 !== void 0 && (n2.current = { store: t2, id: e38, element: r2 }, t2.context.triggerElements.add(e38, r2), Na(t2)); + }); +} +function Fa(e38, t2, n2, r2 = false) { + let i3 = e38.preventUnmountingOnClose; + t2 ? i3 = false : r2 && (i3 = true); + let a3 = n2?.id ?? null, o3 = e38.activeTriggerId, s3 = e38.activeTriggerElement; + return (a3 || t2) && (o3 = a3, s3 = n2 ?? null), { open: t2, preventUnmountingOnClose: i3, activeTriggerId: o3, activeTriggerElement: s3, openedWithoutTrigger: t2 ? n2 == null : e38.openedWithoutTrigger }; +} +function Ia(e38) { + let t2 = false; + return e38.preventUnmountOnClose = () => { + t2 = true; + }, () => t2; +} +function La(e38, t2, n2, r2 = {}) { + let i3 = n2.reason, a3 = i3 === yt, o3 = t2 && i3 === `trigger-focus`, s3 = !t2 && (i3 === `trigger-press` || i3 === `escape-key`), c3 = Ia(n2); + if (e38.context.onOpenChange?.(t2, n2), n2.isCanceled) return; + r2.onBeforeDispatch?.(), e38.state.floatingRootContext.dispatchOpenChange(t2, n2); + let l5 = () => { + let i4 = Fa(e38.state, t2, n2.trigger, c3()), l6 = { ...r2.extraState, ...i4 }; + o3 ? l6.instantType = `focus` : s3 ? l6.instantType = `dismiss` : a3 && (l6.instantType = void 0), e38.update(l6); + }; + a3 ? Ei.flushSync(l5) : l5(); +} +function Ra(e38, t2, n2, r2) { + let i3 = n2.useState(`isMountedByTrigger`, e38), a3 = Pa(e38, n2), o3 = Y((t3) => { + let i4 = n2.select(`open`), a4 = n2.select(`activeTriggerId`); + if (a4 === e38) { + let e39 = { activeTriggerElement: t3, ...i4 ? r2 : null }; + n2.update(e39); + return; + } + if (a4 == null && i4 && !n2.state.openedWithoutTrigger) { + let i5 = { activeTriggerId: e38 ?? null, activeTriggerElement: t3, ...r2 }; + n2.update(i5); + } + }), s3 = Y((e39) => { + a3(e39), e39 && o3(e39); + }); + return X(() => (s3(t2.current), () => s3(null)), [s3, t2, n2, e38]), X(() => { + if (i3) { + let e39 = { activeTriggerElement: t2.current, ...r2 }; + n2.update(e39); + } + }, [i3, n2, t2, ...Object.values(r2)]), { registerTrigger: s3, isMountedByThisTrigger: i3 }; +} +function za(e38, t2 = {}) { + let { closeOnActiveTriggerUnmount: n2 = false } = t2, r2 = x.useRef(null), i3 = e38.useState(`open`); + X(() => { + if (!i3) { + r2.current = null, e38.state.triggerCount !== 0 && e38.set(`triggerCount`, 0), e38.state.openedWithoutTrigger && e38.set(`openedWithoutTrigger`, false); + return; + } + let t3 = e38.context.triggerElements.size, a3 = {}; + e38.state.triggerCount !== t3 && (a3.triggerCount = t3); + let o3 = e38.select(`activeTriggerId`), s3 = null; + if (o3) { + let t4 = e38.context.triggerElements.getById(o3); + if (t4) r2.current = o3, t4 !== e38.state.activeTriggerElement && (a3.activeTriggerElement = t4); + else { + for (let [t5, n3] of e38.context.triggerElements.entries()) if (n3 === e38.state.activeTriggerElement) { + a3.activeTriggerId = t5, a3.activeTriggerElement = n3, r2.current = t5; + break; + } + a3.activeTriggerId === void 0 && (r2.current === o3 ? s3 = o3 : r2.current = null); + } + } else r2.current = null; + if (!s3 && !o3 && !e38.state.openedWithoutTrigger && t3 === 1) { + let t4 = e38.context.triggerElements.entries().next(); + if (!t4.done) { + let [e39, n3] = t4.value; + a3.activeTriggerId = e39, a3.activeTriggerElement = n3, r2.current = e39; + } + } + (a3.triggerCount !== void 0 || a3.activeTriggerId !== void 0 || a3.activeTriggerElement !== void 0) && e38.update(a3), s3 && n2 && queueMicrotask(() => { + if (e38.select(`open`) && e38.select(`activeTriggerId`) === s3 && !e38.context.triggerElements.getById(s3)) { + let t4 = Q(_t); + e38.setOpen(false, t4), t4.isCanceled || e38.update({ activeTriggerId: null, activeTriggerElement: null }); + } + }); + }, [i3, e38, e38.useState(`triggerCount`), e38.useState(`activeTriggerId`), e38.useState(`activeTriggerElement`), n2]); +} +function Ba(e38, t2, n2, r2) { + let { mounted: i3, transitionStatus: a3, forceUnmount: o3 } = Oa({ open: e38, ref: t2.context.popupRef, preventUnmountOnClose: t2.useState(`preventUnmountingOnClose`), setPreventUnmountOnClose: (e39) => t2.set(`preventUnmountingOnClose`, e39), animateInitialOpen: r2, onUnmount() { + t2.update({ activeTriggerId: null, activeTriggerElement: null, mounted: false, preventUnmountingOnClose: false }), n2?.(), t2.context.onOpenChangeComplete?.(false); + } }); + return T(() => (t2.set(`mounted`, i3), null)), t2.useSyncedValues({ mounted: i3, transitionStatus: a3 }), { forceUnmount: o3, transitionStatus: a3 }; +} +function Va(e38, t2) { + e38.useSyncedValues(t2), X(() => () => { + e38.update({ activeTriggerProps: R, inactiveTriggerProps: R, popupProps: R }); + }, [e38]); +} +var Ua = class { + idMap = /* @__PURE__ */ new Map(); + add(e38, t2) { + this.idMap.set(e38, t2); + } + delete(e38) { + this.idMap.delete(e38); + } + hasElement(e38) { + for (let t2 of this.idMap.values()) if (t2 === e38) return true; + return false; + } + hasMatchingElement(e38) { + for (let t2 of this.idMap.values()) if (e38(t2)) return true; + return false; + } + getById(e38) { + return this.idMap.get(e38); + } + entries() { + return this.idMap.entries(); + } + elements() { + return this.idMap.values(); + } + get size() { + return this.idMap.size; + } +}; +var Wa = s(((e38) => { + var t2 = sandVaultReact(); + function n2(e39, t3) { + return e39 === t3 && (e39 !== 0 || 1 / e39 == 1 / t3) || e39 !== e39 && t3 !== t3; + } + var r2 = typeof Object.is == `function` ? Object.is : n2, i3 = t2.useState, o3 = t2.useEffect, s3 = t2.useLayoutEffect, c3 = t2.useDebugValue; + function l5(e39, t3) { + var n3 = t3(), r3 = i3({ inst: { value: n3, getSnapshot: t3 } }), a3 = r3[0].inst, l6 = r3[1]; + return s3(function() { + a3.value = n3, a3.getSnapshot = t3, u3(a3) && l6({ inst: a3 }); + }, [e39, n3, t3]), o3(function() { + return u3(a3) && l6({ inst: a3 }), e39(function() { + u3(a3) && l6({ inst: a3 }); + }); + }, [e39]), c3(n3), n3; + } + function u3(e39) { + var t3 = e39.getSnapshot; + e39 = e39.value; + try { + var n3 = t3(); + return !r2(e39, n3); + } catch { + return true; + } + } + function d3(e39, t3) { + return t3(); + } + var f4 = typeof window > `u` || window.document === void 0 || window.document.createElement === void 0 ? d3 : l5; + e38.useSyncExternalStore = t2.useSyncExternalStore === void 0 ? f4 : t2.useSyncExternalStore; +})); +var Ga = s(((e38, t2) => { + t2.exports = Wa(); +})); +var Ka = s(((e38) => { + var t2 = sandVaultReact(), n2 = Ga(); + function r2(e39, t3) { + return e39 === t3 && (e39 !== 0 || 1 / e39 == 1 / t3) || e39 !== e39 && t3 !== t3; + } + var i3 = typeof Object.is == `function` ? Object.is : r2, o3 = n2.useSyncExternalStore, s3 = t2.useRef, c3 = t2.useEffect, l5 = t2.useMemo, u3 = t2.useDebugValue; + e38.useSyncExternalStoreWithSelector = function(e39, t3, n3, r3, a3) { + var d3 = s3(null); + if (d3.current === null) { + var f4 = { hasValue: false, value: null }; + d3.current = f4; + } else f4 = d3.current; + d3 = l5(function() { + function e40(e41) { + if (!o4) { + if (o4 = true, s4 = e41, e41 = r3(e41), a3 !== void 0 && f4.hasValue) { + var t4 = f4.value; + if (a3(t4, e41)) return c4 = t4; + } + return c4 = e41; + } + if (t4 = c4, i3(s4, e41)) return t4; + var n4 = r3(e41); + return a3 !== void 0 && a3(t4, n4) ? (s4 = e41, t4) : (s4 = e41, c4 = n4); + } + var o4 = false, s4, c4, l6 = n3 === void 0 ? null : n3; + return [function() { + return e40(t3()); + }, l6 === null ? void 0 : function() { + return e40(l6()); + }]; + }, [t3, n3, r3, a3]); + var p4 = o3(e39, d3[0], d3[1]); + return c3(function() { + f4.hasValue = true, f4.value = p4; + }, [p4]), u3(p4), p4; + }; +})); +var qa = s(((e38, t2) => { + t2.exports = Ka(); +})); +var Ja = Ga(); +var Ya = qa(); +var Xa = []; +var Za = void 0; +function Qa() { + return Za; +} +function eo(e38) { + let t2 = (t3, n2) => { + let r2 = T(no).current, i3; + try { + Za = r2; + for (let e39 of Xa) e39.before(r2); + i3 = e38(t3, n2); + for (let e39 of Xa) e39.after(r2); + r2.didInitialize = true; + } finally { + Za = void 0; + } + return i3; + }; + return t2.displayName = e38.displayName || e38.name, t2; +} +function to(e38) { + return x.forwardRef(eo(e38)); +} +function no() { + return { didInitialize: false }; +} +var ro = N2(19) ? oo : so; +function io(e38, t2, n2, r2, i3) { + return ro(e38, t2, n2, r2, i3); +} +function ao(e38, t2, n2, r2, i3) { + let a3 = x.useCallback(() => t2(e38.getSnapshot(), n2, r2, i3), [e38, t2, n2, r2, i3]); + return (0, Ja.useSyncExternalStore)(e38.subscribe, a3, a3); +} +function oo(e38, t2, n2, r2, i3) { + let a3 = Qa(); + if (!a3) return ao(e38, t2, n2, r2, i3); + let o3 = a3.syncIndex; + a3.syncIndex += 1; + let s3; + return a3.didInitialize ? (s3 = a3.syncHooks[o3], (s3.store !== e38 || s3.selector !== t2 || !Object.is(s3.a1, n2) || !Object.is(s3.a2, r2) || !Object.is(s3.a3, i3)) && (s3.store !== e38 && (a3.didChangeStore = true), s3.store = e38, s3.selector = t2, s3.a1 = n2, s3.a2 = r2, s3.a3 = i3, s3.value = t2(e38.getSnapshot(), n2, r2, i3))) : (s3 = { store: e38, selector: t2, a1: n2, a2: r2, a3: i3, value: t2(e38.getSnapshot(), n2, r2, i3) }, a3.syncHooks.push(s3)), s3.value; +} +function so(e38, t2, n2, r2, i3) { + return (0, Ya.useSyncExternalStoreWithSelector)(e38.subscribe, e38.getSnapshot, e38.getSnapshot, (e39) => t2(e39, n2, r2, i3)); +} +var co = class { + static create(e38) { + return new this(e38); + } + constructor(e38) { + this.state = e38, this.listeners = /* @__PURE__ */ new Set(), this.updateTick = 0; + } + subscribe = (e38) => (this.listeners.add(e38), () => { + this.listeners.delete(e38); + }); + getSnapshot = () => this.state; + setState(e38) { + if (this.state === e38) return; + this.state = e38, this.updateTick += 1; + let t2 = this.updateTick; + for (let n2 of this.listeners) { + if (t2 !== this.updateTick) return; + n2(e38); + } + } + update(e38) { + for (let t2 in e38) if (!Object.is(this.state[t2], e38[t2])) { + this.setState({ ...this.state, ...e38 }); + return; + } + } + set(e38, t2) { + Object.is(this.state[e38], t2) || this.setState({ ...this.state, [e38]: t2 }); + } + notifyAll() { + let e38 = { ...this.state }; + this.setState(e38); + } + use(e38, t2, n2, r2) { + return io(this, e38, t2, n2, r2); + } +}; +var lo = class extends co { + constructor(e38, t2 = {}, n2) { + super(e38), this.context = t2, this.selectors = n2; + } + useSyncedValue(e38, t2) { + x.useDebugValue(e38); + let n2 = this; + X(() => { + n2.state[e38] !== t2 && n2.set(e38, t2); + }, [n2, e38, t2]); + } + useSyncedValueWithCleanup(e38, t2) { + let n2 = this; + X(() => (n2.state[e38] !== t2 && n2.set(e38, t2), () => { + n2.set(e38, void 0); + }), [n2, e38, t2]); + } + useSyncedValues(e38) { + let t2 = this; + X(() => { + t2.update(e38); + }, [t2, ...Object.values(e38)]); + } + useControlledProp(e38, t2) { + x.useDebugValue(e38); + let n2 = this, r2 = t2 !== void 0; + X(() => { + r2 && !Object.is(n2.state[e38], t2) && n2.setState({ ...n2.state, [e38]: t2 }); + }, [n2, e38, t2, r2]); + } + select(e38, t2, n2, r2) { + let i3 = this.selectors[e38]; + return i3(this.state, t2, n2, r2); + } + useState(e38, t2, n2, r2) { + return x.useDebugValue(e38), io(this, this.selectors[e38], t2, n2, r2); + } + useContextCallback(e38, t2) { + x.useDebugValue(e38); + let n2 = Y(t2 ?? I); + this.context[e38] = n2; + } + useStateSetter(e38) { + let t2 = x.useRef(void 0); + return t2.current === void 0 && (t2.current = (t3) => { + this.set(e38, t3); + }), t2.current; + } + observe(e38, t2) { + let n2; + n2 = typeof e38 == `function` ? e38 : this.selectors[e38]; + let r2 = n2(this.state); + return t2(r2, r2, this), this.subscribe((e39) => { + let i3 = n2(e39); + if (!Object.is(r2, i3)) { + let e40 = r2; + r2 = i3, t2(i3, e40, this); + } + }); + } +}; +var uo = { open: (e38) => e38.open, transitionStatus: (e38) => e38.transitionStatus, domReferenceElement: (e38) => e38.domReferenceElement, referenceElement: (e38) => e38.positionReference ?? e38.referenceElement, floatingElement: (e38) => e38.floatingElement, floatingId: (e38) => e38.floatingId }; +var fo = class extends lo { + constructor(e38) { + let { syncOnly: t2, nested: n2, onOpenChange: r2, triggerElements: i3, ...a3 } = e38; + super({ ...a3, positionReference: a3.referenceElement, domReferenceElement: a3.referenceElement }, { onOpenChange: r2, dataRef: { current: {} }, events: Li(), nested: n2, triggerElements: i3 }, uo), this.syncOnly = t2; + } + syncOpenEvent = (e38, t2) => { + (!e38 || !this.state.open || t2 != null && mn(t2)) && (this.context.dataRef.current.openEvent = e38 ? t2 : void 0); + }; + dispatchOpenChange = (e38, t2) => { + this.syncOpenEvent(e38, t2.event); + let n2 = { open: e38, reason: t2.reason, nativeEvent: t2.event, nested: this.context.nested, triggerElement: t2.trigger }; + this.context.events.emit(`openchange`, n2); + }; + setOpen = (e38, t2) => { + if (this.syncOnly) { + this.context.onOpenChange?.(e38, t2); + return; + } + this.dispatchOpenChange(e38, t2), this.context.onOpenChange?.(e38, t2); + }; +}; +function po(e38, t2, n2 = false) { + return { open: false, openProp: void 0, mounted: false, transitionStatus: void 0, floatingRootContext: new fo({ open: false, transitionStatus: void 0, floatingElement: null, referenceElement: null, triggerElements: e38, floatingId: t2, syncOnly: true, nested: n2, onOpenChange: void 0 }), floatingId: t2, triggerCount: 0, preventUnmountingOnClose: false, payload: void 0, activeTriggerId: null, activeTriggerElement: null, openedWithoutTrigger: false, triggerIdProp: void 0, popupElement: null, positionerElement: null, activeTriggerProps: R, inactiveTriggerProps: R, popupProps: R }; +} +var mo = (e38) => e38.triggerIdProp ?? e38.activeTriggerId; +var ho = (e38) => e38.openProp ?? e38.open; +var go = (e38) => (e38.popupElement?.id ?? e38.floatingId) || void 0; +function _o(e38, t2) { + return t2 !== void 0 && ho(e38) && mo(e38) === t2; +} +function vo(e38, t2) { + return _o(e38, t2) ? true : t2 !== void 0 && ho(e38) && mo(e38) == null && !e38.openedWithoutTrigger && e38.triggerCount === 1; +} +var yo = { open: ho, mounted: (e38) => e38.mounted, transitionStatus: (e38) => ho(e38) && !e38.mounted ? `starting` : e38.transitionStatus, floatingRootContext: (e38) => e38.floatingRootContext, triggerCount: (e38) => e38.triggerCount, preventUnmountingOnClose: (e38) => e38.preventUnmountingOnClose, payload: (e38) => e38.payload, activeTriggerId: mo, activeTriggerElement: (e38) => e38.mounted ? e38.activeTriggerElement : null, popupId: go, isTriggerActive: (e38, t2) => t2 !== void 0 && mo(e38) === t2, isOpenedByTrigger: (e38, t2) => _o(e38, t2), isMountedByTrigger: (e38, t2) => t2 !== void 0 && mo(e38) === t2 && e38.mounted, triggerProps: (e38, t2) => t2 ? e38.activeTriggerProps : e38.inactiveTriggerProps, triggerPopupId: (e38, t2) => vo(e38, t2) ? go(e38) : void 0, popupProps: (e38) => e38.popupProps, popupElement: (e38) => e38.popupElement, positionerElement: (e38) => e38.positionerElement }; +function bo(e38) { + let t2 = x.useCallback((t3) => e38 === void 0 ? I : e38.subscribeStore(t3), [e38]), n2 = x.useCallback(() => e38 === void 0 ? void 0 : e38.store, [e38]); + return (0, Ja.useSyncExternalStore)(t2, n2, () => e38?.serverStore); +} +function xo(e38) { + let { open: t2 = false, onOpenChange: n2, elements: r2 = {} } = e38, i3 = Vt(), a3 = Vi() != null, o3 = T(() => new fo({ open: t2, transitionStatus: void 0, onOpenChange: n2, referenceElement: r2.reference ?? null, floatingElement: r2.floating ?? null, triggerElements: new Ua(), floatingId: i3, syncOnly: false, nested: a3 })).current; + return X(() => { + let e39 = { open: t2, floatingId: i3 }; + r2.reference !== void 0 && (e39.referenceElement = r2.reference, e39.domReferenceElement = Re2(r2.reference) ? r2.reference : null), r2.floating !== void 0 && (e39.floatingElement = r2.floating), o3.update(e39); + }, [t2, i3, r2.reference, r2.floating, o3]), o3.context.onOpenChange = n2, o3.context.nested = a3, o3; +} +var So = nn && an; +function Co(e38, t2 = {}) { + let { enabled: n2 = true, delay: r2 } = t2, { events: i3, dataRef: a3 } = e38.context, o3 = x.useRef(false), s3 = x.useRef(null), c3 = x.useRef(true), l5 = Kt(); + x.useEffect(() => { + let t3 = e38.select(`domReferenceElement`); + if (!n2) return; + let r3 = Fe(t3); + function i4() { + let t4 = e38.select(`domReferenceElement`); + !e38.select(`open`) && ze2(t4) && t4 === hn(ft(t4)) && (o3.current = true, s3.current = t4); + } + function a4() { + c3.current = true; + } + function l6() { + c3.current = false; + } + return Hn(Vn(r3, `blur`, i4), So && Vn(r3, `keydown`, a4, true), So && Vn(r3, `pointerdown`, l6, true)); + }, [e38, n2]), x.useEffect(() => { + if (!n2) return; + function t3(t4) { + if (t4.reason === `trigger-press` || t4.reason === `escape-key`) { + let t5 = e38.select(`domReferenceElement`); + Re2(t5) && (s3.current = t5, o3.current = true); + } + } + return i3.on(`openchange`, t3), () => { + i3.off(`openchange`, t3); + }; + }, [i3, n2, e38]); + let u3 = x.useMemo(() => { + function t3() { + o3.current = false, s3.current = null; + } + return { onMouseLeave() { + t3(); + }, onFocus(n3) { + let i4 = n3.currentTarget; + if (o3.current) { + if (s3.current === i4) return; + t3(); + } + let a4 = _n(n3.nativeEvent); + if (Re2(a4)) { + if (So && !n3.relatedTarget) { + if (!c3.current && !On(a4)) return; + } else if (!jn(a4)) return; + } + let u4 = Tn(n3.relatedTarget, e38.context.triggerElements), { nativeEvent: d3, currentTarget: f4 } = n3; + if (e38.select(`open`) && u4 || !r2) { + e38.setOpen(true, Q(bt, d3, f4)); + return; + } + l5.start(r2, () => { + o3.current || e38.setOpen(true, Q(bt, d3, f4)); + }); + }, onBlur(n3) { + t3(); + let r3 = n3.relatedTarget, i4 = n3.nativeEvent, o4 = Re2(r3) && r3.hasAttribute(ui(`focus-guard`)) && r3.getAttribute(`data-type`) === `outside`; + l5.start(0, () => { + let t4 = e38.select(`domReferenceElement`), n4 = hn(ft(t4)); + (r3 || n4 !== t4) && ($(a3.current.floatingContext?.refs.floating.current, n4) || $(t4, n4) || o4 || Tn(r3 ?? n4, e38.context.triggerElements) || e38.setOpen(false, Q(bt, i4))); + }); + } }; + }, [a3, r2, e38, l5]); + return x.useMemo(() => n2 ? { reference: u3, trigger: u3 } : {}, [n2, u3]); +} +var wo = class e6 { + pointerType = void 0; + interactedInside = false; + handler = void 0; + blockMouseMove = true; + performedPointerEventsMutation = false; + pointerEventsScopeElement = null; + pointerEventsReferenceElement = null; + pointerEventsFloatingElement = null; + restTimeoutPending = false; + openChangeTimeout = new Gt(); + restTimeout = new Gt(); + handleCloseOptions = void 0; + static create() { + return new e6(); + } + dispose = () => { + this.openChangeTimeout.clear(), this.restTimeout.clear(); + }; + disposeEffect = () => this.dispose; +}; +var To = /* @__PURE__ */ new WeakMap(); +function Eo(e38) { + if (!e38.performedPointerEventsMutation) return; + let t2 = e38.pointerEventsScopeElement; + t2 && To.get(t2) === e38 && (e38.pointerEventsScopeElement?.style.removeProperty(`pointer-events`), e38.pointerEventsReferenceElement?.style.removeProperty(`pointer-events`), e38.pointerEventsFloatingElement?.style.removeProperty(`pointer-events`), To.delete(t2)), e38.performedPointerEventsMutation = false, e38.pointerEventsScopeElement = null, e38.pointerEventsReferenceElement = null, e38.pointerEventsFloatingElement = null; +} +function Do(e38, t2) { + let { scopeElement: n2, referenceElement: r2, floatingElement: i3 } = t2, a3 = To.get(n2); + a3 && a3 !== e38 && Eo(a3), Eo(e38), e38.performedPointerEventsMutation = true, e38.pointerEventsScopeElement = n2, e38.pointerEventsReferenceElement = r2, e38.pointerEventsFloatingElement = i3, To.set(n2, e38), n2.style.pointerEvents = `none`, r2.style.pointerEvents = `auto`, i3.style.pointerEvents = `auto`; +} +function Oo(e38) { + let t2 = e38.context.dataRef.current, n2 = T(() => t2.hoverInteractionState ?? wo.create()).current; + return t2.hoverInteractionState ||= n2, Ut(t2.hoverInteractionState.disposeEffect), t2.hoverInteractionState; +} +function ko(e38, t2 = {}) { + let { enabled: n2 = true, closeDelay: r2 = 0, nodeId: i3 } = t2, a3 = e38.useState(`open`), o3 = e38.useState(`floatingElement`), s3 = e38.useState(`domReferenceElement`), { dataRef: c3 } = e38.context, l5 = Hi(), u3 = Vi(), d3 = Oo(e38), f4 = Kt(), p4 = Y(() => In(c3.current.openEvent?.type, d3.interactedInside)), m3 = Y(() => Ln(c3.current.openEvent?.type)), h4 = Y(() => { + Eo(d3); + }); + X(() => { + a3 || (d3.pointerType = void 0, d3.restTimeoutPending = false, d3.interactedInside = false, h4()); + }, [a3, d3, h4]), x.useEffect(() => h4, [h4]), X(() => { + if (n2 && a3 && d3.handleCloseOptions?.blockPointerEvents && m3() && Re2(s3) && o3) { + let e39 = s3, t3 = o3, n3 = ft(o3), r3 = l5?.nodesRef.current.find((e40) => e40.id === u3)?.context?.elements.floating; + r3 && (r3.style.pointerEvents = ``); + let i4 = d3.pointerEventsScopeElement === t3 ? null : d3.pointerEventsScopeElement, a4 = r3 === t3 ? null : r3, c4 = d3.handleCloseOptions?.getScope?.() ?? i4 ?? a4 ?? gn(e39, `[data-rootownerid]`) ?? n3.body; + return Do(d3, { scopeElement: c4, referenceElement: e39, floatingElement: t3 }), () => { + h4(); + }; + } + }, [n2, a3, s3, o3, d3, m3, l5, u3, h4]), x.useEffect(() => { + if (!n2) return; + function t3() { + return !!(l5 && u3 && ci(l5.nodesRef.current, u3).length > 0); + } + function a4(t4) { + let n3 = Pn(r2, `close`, d3.pointerType), i4 = () => { + e38.setOpen(false, Q(yt, t4)), l5?.events.emit(`floating.closed`, t4); + }; + n3 ? d3.openChangeTimeout.start(n3, i4) : (d3.openChangeTimeout.clear(), i4()); + } + function s4(e39) { + let t4 = _n(e39); + if (!kn(t4)) { + d3.interactedInside = false; + return; + } + d3.interactedInside = gn(t4, `[aria-haspopup]`) != null; + } + function g5() { + d3.openChangeTimeout.clear(), f4.clear(), l5?.events.off(`floating.closed`, v5), h4(); + } + function _5(n3) { + if (t3() && l5) { + l5.events.on(`floating.closed`, v5); + return; + } + if (Tn(n3.relatedTarget, e38.context.triggerElements)) return; + let r3 = c3.current.floatingContext?.nodeId ?? i3, o4 = n3.relatedTarget; + if (!(l5 && r3 && Re2(o4) && ci(l5.nodesRef.current, r3, false).some((e39) => $(e39.context?.elements.floating, o4)))) { + if (d3.handler) { + d3.handler(n3); + return; + } + h4(), m3() && !p4() && a4(n3); + } + } + function v5(n3) { + l5 && u3 && !t3() && f4.start(0, () => { + l5.events.off(`floating.closed`, v5), e38.setOpen(false, Q(yt, n3)), l5.events.emit(`floating.closed`, n3); + }); + } + let y4 = o3; + return Hn(y4 && Vn(y4, `mouseenter`, g5), y4 && Vn(y4, `mouseleave`, _5), y4 && Vn(y4, `pointerdown`, s4, true), () => { + l5?.events.off(`floating.closed`, v5); + }); + }, [n2, o3, e38, c3, r2, i3, m3, p4, h4, d3, l5, u3, f4]); +} +var Ao = { current: null }; +function jo(e38, t2 = {}) { + let { enabled: n2 = true, delay: r2 = 0, handleClose: i3 = null, mouseOnly: a3 = false, restMs: o3 = 0, move: s3 = true, triggerElementRef: c3 = Ao, externalTree: l5, isActiveTrigger: u3 = true, getHandleCloseContext: d3, isClosing: f4, shouldOpen: p4, guardStaleOpen: m3 = false } = t2, { dataRef: h4, events: g5 } = e38.context, _5 = Hi(l5), v5 = Oo(e38), y4 = x.useRef(false), b2 = Un(i3), S2 = Un(r2), C2 = Un(o3), w2 = Un(n2), T2 = Un(p4), E2 = Un(f4), D2 = Y(() => In(h4.current.openEvent?.type, v5.interactedInside)), O2 = Y(() => T2.current?.() !== false), k2 = Y((t3, n3, r3) => { + let i4 = e38.context.triggerElements; + if (i4.hasElement(n3)) return !t3 || !$(t3, n3); + if (!Re2(r3)) return false; + let a4 = r3; + return i4.hasMatchingElement((e39) => $(e39, a4)) && (!t3 || !$(t3, a4)); + }), A2 = Y(() => { + v5.handler &&= (ft(e38.select(`domReferenceElement`)).removeEventListener(`mousemove`, v5.handler), void 0); + }), j2 = Y(() => { + Eo(v5); + }); + return u3 && (v5.handleCloseOptions = i3?.__options), x.useEffect(() => A2, [A2]), x.useEffect(() => { + if (!n2) return; + function e39(e40) { + e40.open ? y4.current = false : (y4.current = e40.reason === yt, A2(), v5.openChangeTimeout.clear(), v5.restTimeout.clear(), v5.blockMouseMove = true, v5.restTimeoutPending = false); + } + return g5.on(`openchange`, e39), () => { + g5.off(`openchange`, e39); + }; + }, [n2, g5, v5, A2]), x.useEffect(() => { + if (!n2) return; + function t3(t4, n3 = true) { + let r4 = Pn(S2.current, `close`, v5.pointerType); + r4 ? v5.openChangeTimeout.start(r4, () => { + e38.setOpen(false, Q(yt, t4)), _5?.events.emit(`floating.closed`, t4); + }) : n3 && (v5.openChangeTimeout.clear(), e38.setOpen(false, Q(yt, t4)), _5?.events.emit(`floating.closed`, t4)); + } + let r3 = c3.current ?? (u3 ? e38.select(`domReferenceElement`) : null); + if (!Re2(r3)) return; + function i4(t4) { + if (v5.openChangeTimeout.clear(), v5.blockMouseMove = false, a3 && !pn(v5.pointerType)) return; + let n3 = Fn(C2.current), r4 = Pn(S2.current, `open`, v5.pointerType), i5 = _n(t4), o5 = t4.currentTarget ?? null, s4 = e38.select(`domReferenceElement`), c4 = o5; + if (Re2(i5) && !e38.context.triggerElements.hasElement(i5)) { + for (let t5 of e38.context.triggerElements.elements()) if ($(t5, i5)) { + c4 = t5; + break; + } + } + Re2(o5) && Re2(s4) && !e38.context.triggerElements.hasElement(o5) && $(o5, s4) && (c4 = s4); + let l7 = c4 != null && k2(s4, c4, i5), u4 = e38.select(`open`), d4 = E2.current?.() ?? e38.select(`transitionStatus`) === `ending`, f6 = !u4 && d4 && y4.current, p5 = !l7 && Re2(c4) && Re2(s4) && $(s4, c4) && f6, m4 = n3 > 0 && !r4, h5 = l7 && (u4 || f6) || p5, g6 = !u4 || l7; + if (h5) { + O2() && e38.setOpen(true, Q(yt, t4, c4)); + return; + } + m4 || (r4 ? v5.openChangeTimeout.start(r4, () => { + g6 && O2() && e38.setOpen(true, Q(yt, t4, c4)); + }) : g6 && O2() && e38.setOpen(true, Q(yt, t4, c4))); + } + function o4(n3) { + if (D2()) { + j2(); + return; + } + A2(); + let r4 = ft(e38.select(`domReferenceElement`)); + v5.restTimeout.clear(), v5.restTimeoutPending = false; + let i5 = h4.current.floatingContext ?? d3?.(); + if (!Tn(n3.relatedTarget, e38.context.triggerElements)) { + if (b2.current && i5) { + e38.select(`open`) || v5.openChangeTimeout.clear(); + let a4 = c3.current; + v5.handler = b2.current({ ...i5, tree: _5, x: n3.clientX, y: n3.clientY, onClose() { + j2(), A2(), w2.current && !D2() && a4 === e38.select(`domReferenceElement`) && t3(n3, true); + } }), r4.addEventListener(`mousemove`, v5.handler), v5.handler(n3); + return; + } + (v5.pointerType !== `touch` || !$(e38.select(`floatingElement`), n3.relatedTarget)) && t3(n3); + } + } + function l6(e39) { + $(r3, e39.relatedTarget) || (v5.openChangeTimeout.clear(), v5.restTimeout.clear(), v5.restTimeoutPending = false); + } + let f5 = m3 ? Vn(r3, `mouseout`, l6) : void 0; + return s3 ? Hn(Vn(r3, `mousemove`, i4, { once: true }), Vn(r3, `mouseenter`, i4), Vn(r3, `mouseleave`, o4), f5) : Hn(Vn(r3, `mouseenter`, i4), Vn(r3, `mouseleave`, o4), f5); + }, [A2, j2, h4, S2, e38, n2, b2, v5, u3, k2, D2, a3, s3, C2, c3, _5, w2, d3, E2, O2, m3]), x.useMemo(() => { + if (!n2) return; + function t3(e39) { + v5.pointerType = e39.pointerType; + } + return { onPointerDown: t3, onPointerEnter: t3, onMouseMove(t4) { + let { nativeEvent: n3 } = t4, r3 = t4.currentTarget, i4 = e38.select(`domReferenceElement`), o4 = e38.select(`open`), s4 = k2(i4, r3, t4.target); + if (a3 && !pn(v5.pointerType)) return; + if (o4 && s4 && v5.handleCloseOptions?.blockPointerEvents) { + let t5 = e38.select(`floatingElement`); + if (t5) { + let e39 = v5.handleCloseOptions?.getScope?.() ?? r3.ownerDocument.body; + Do(v5, { scopeElement: e39, referenceElement: r3, floatingElement: t5 }); + } + } + let c4 = Fn(C2.current); + if (o4 && !s4 || c4 === 0 || !s4 && v5.restTimeoutPending && t4.movementX ** 2 + t4.movementY ** 2 < 2) return; + v5.restTimeout.clear(); + function l6() { + if (v5.restTimeoutPending = false, D2()) return; + let t5 = e38.select(`open`); + !v5.blockMouseMove && (!t5 || s4) && O2() && e38.setOpen(true, Q(yt, n3, r3)); + } + v5.pointerType === `touch` ? Ei.flushSync(() => { + l6(); + }) : s4 && o4 ? l6() : (v5.restTimeoutPending = true, v5.restTimeout.start(c4, l6)); + } }; + }, [n2, v5, D2, k2, a3, e38, C2, O2]); +} +function Mo(e38) { + return an && e38.movementX === 0 && e38.movementY === 0; +} +function No(e38, t2, n2) { + switch (e38) { + case `vertical`: + return t2; + case `horizontal`: + return n2; + default: + return t2 || n2; + } +} +function Po(e38, t2) { + return No(t2, e38 === `ArrowUp` || e38 === `ArrowDown`, e38 === `ArrowLeft` || e38 === `ArrowRight`); +} +function Fo(e38, t2, n2) { + return No(t2, e38 === `ArrowDown`, n2 ? e38 === `ArrowLeft` : e38 === `ArrowRight`) || e38 === `Enter` || e38 === ` ` || e38 === ``; +} +function Io(e38, t2, n2) { + return No(t2, n2 ? e38 === bn : e38 === xn, e38 === Cn); +} +function Lo(e38, t2, n2, r2) { + return t2 === `both` || t2 === `horizontal` && r2 ? e38 === `Escape` : No(t2, n2 ? e38 === xn : e38 === bn, e38 === Sn); +} +function Ro(e38, t2) { + let { listRef: n2, activeIndex: r2, onNavigate: i3 = () => { + }, enabled: a3 = true, selectedIndex: o3 = null, allowEscape: s3 = false, loopFocus: c3 = false, nested: l5 = false, rtl: u3 = false, virtual: d3 = false, focusItemOnOpen: f4 = `auto`, focusItemOnHover: p4 = true, openOnArrowKeyDown: m3 = true, disabledIndices: h4 = void 0, orientation: g5 = `vertical`, triggerOrientation: _5 = g5, parentOrientation: v5, id: y4, resetOnPointerLeave: b2 = true, externalTree: S2, nestedReturnFocusRef: C2, grid: w2 } = t2, T2 = w2 != null, E2 = e38.useState(`open`), D2 = e38.useState(`floatingElement`), O2 = e38.useState(`domReferenceElement`), k2 = e38.context.dataRef, A2 = Mn(D2), j2 = An(O2), M2 = Un(A2), N3 = Vi(), P3 = Hi(S2), F2 = x.useRef(f4), I2 = x.useRef(o3 ?? -1), L3 = x.useRef(null), R3 = x.useRef(true), z2 = Y((e39) => { + i3(I2.current === -1 ? null : I2.current, e39); + }), ee2 = x.useRef(!!D2), B3 = x.useRef(E2), V3 = x.useRef(false), H3 = x.useRef(false), U3 = x.useRef(null), W3 = Un(h4), G2 = Un(E2), te2 = Un(o3), K4 = Un(b2), ne3 = Jn(), q4 = Jn(), re3 = Y(() => { + ne3.cancel(); + function e39(e40) { + d3 || (U3.current = fi(e40, { sync: V3.current, preventScroll: true })); + } + let t3 = n2.current[I2.current], r3 = H3.current; + t3 && e39(t3), (V3.current ? (e40) => e40() : (e40) => ne3.request(e40))(() => { + let i4 = n2.current[I2.current] || t3; + i4 && (t3 || e39(i4), ce6 && (r3 || !R3.current) && i4.scrollIntoView?.({ block: `nearest`, inline: `nearest` })); + }); + }); + X(() => { + k2.current.orientation = g5; + }, [k2, g5]), X(() => { + E2 || (L3.current = null), (!E2 || f4 !== `auto`) && (F2.current = f4); + }, [E2, f4]), X(() => { + a3 && (E2 && D2 ? (I2.current = o3 ?? -1, F2.current && o3 != null && (H3.current = true, z2())) : ee2.current && (I2.current = -1, z2())); + }, [a3, E2, D2, o3, z2]), X(() => { + if (a3) { + if (!E2) { + V3.current = false; + return; + } + if (D2) { + if (r2 == null) { + if (V3.current = false, te2.current != null) return; + if (ee2.current && (I2.current = -1, re3()), (!B3.current || !ee2.current) && F2.current && (L3.current != null || F2.current === true && L3.current == null)) { + let e39 = 0, t3 = () => { + n2.current[0] == null ? (e39 < 2 && (e39 ? (e40) => q4.request(e40) : queueMicrotask)(t3), e39 += 1) : (I2.current = L3.current == null || Fo(L3.current, _5, u3) || l5 ? jr(n2) : Mr(n2), L3.current = null, z2()); + }; + t3(); + } + } else Ar(n2.current, r2) || (I2.current = r2, re3(), H3.current = false); + } + } + }, [a3, E2, D2, r2, te2, l5, n2, _5, u3, z2, re3, q4]), X(() => { + if (!a3 || D2 || !P3 || d3 || !ee2.current) return; + let e39 = P3.nodesRef.current, t3 = e39.find((e40) => e40.id === N3)?.context?.elements.floating, n3 = hn(ft(O2 ?? t3 ?? null)), r3 = e39.some((e40) => e40.context && $(e40.context.elements.floating, n3)); + t3 && !r3 && R3.current && t3.focus({ preventScroll: true }); + }, [a3, D2, O2, P3, N3, d3]), X(() => { + B3.current = E2, ee2.current = !!D2; + }); + let ie3 = r2 != null, ae3 = Y((e39) => { + if (!G2.current) return; + let t3 = n2.current.indexOf(e39.currentTarget); + t3 !== -1 && (I2.current !== t3 || r2 !== t3) && (I2.current = t3, z2(e39)); + }), oe5 = Y(() => v5 ?? P3?.nodesRef.current.find((e39) => e39.id === N3)?.context?.dataRef?.current.orientation), se5 = Y(() => jr(n2, W3.current)), J4 = Y((t3) => { + if (R3.current = false, V3.current = true, t3.which === 229 || !G2.current && t3.currentTarget === M2.current) return; + if (l5 && Lo(t3.key, g5, u3, T2)) { + Po(t3.key, oe5()) || ln(t3), e38.setOpen(false, Q(kt, t3.nativeEvent)); + let n3 = C2?.current ?? O2; + ze2(n3) && n3.focus(); + return; + } + r2 != null && r2 !== I2.current && !Ar(n2.current, r2) && (I2.current = r2); + let i4 = I2.current, a4 = jr(n2, h4), o4 = Mr(n2, h4); + if (j2 || (t3.key === `Home` && (ln(t3), I2.current = a4, z2(t3)), t3.key === `End` && (ln(t3), I2.current = o4, z2(t3))), w2 != null) { + let e39 = w2(t3, I2.current, n2, g5, c3, u3, h4, a4, o4); + if (e39 != null && e39 !== I2.current && (I2.current = e39, z2(t3)), g5 === `both`) return; + } + if (Po(t3.key, g5)) { + ln(t3); + let e39 = hn(t3.currentTarget.ownerDocument); + if (E2 && !d3 && $(t3.currentTarget, e39) && !n2.current.some((t4) => t4 != null && $(t4, e39))) { + I2.current = Fo(t3.key, g5, u3) ? a4 : o4, z2(t3), r2 === I2.current && re3(); + return; + } + let { index: l6, wrapped: f5 } = Nr(n2.current, i4, { decrement: !Fo(t3.key, g5, u3), loopFocus: c3, allowEscape: s3, disabledIndices: h4, minIndex: a4, maxIndex: o4 }); + f5 && (V3.current = false), I2.current = l6, z2(t3); + } + }), ce6 = x.useMemo(() => ({ onFocus(e39) { + V3.current = true, ae3(e39); + }, onClick({ currentTarget: e39 }) { + d3 || e39.focus({ preventScroll: true }); + }, onMouseMove(e39) { + Mo(e39) || (V3.current = true, H3.current = false, p4 && ae3(e39)); + }, onPointerLeave(e39) { + if (!G2.current || !R3.current || e39.pointerType === `touch`) return; + V3.current = true; + let t3 = e39.relatedTarget; + if (p4 && !n2.current.includes(t3) && K4.current && (U3.current?.(), U3.current = null, I2.current = -1, z2(e39), !d3)) { + let e40 = M2.current, t4 = hn(ft(e40)); + e40 && $(e40, t4) && e40.focus({ preventScroll: true }); + } + } }), [ae3, G2, M2, p4, n2, z2, K4, d3]), le6 = x.useMemo(() => d3 && E2 && ie3 && { "aria-activedescendant": `${y4}-${r2}` }, [d3, E2, ie3, y4, r2]), ue6 = x.useMemo(() => ({ ...j2 ? {} : le6, onKeyDown(t3) { + if (t3.key === `Tab` && t3.shiftKey && E2 && !d3) { + let n3 = _n(t3.nativeEvent); + if (n3 && !$(M2.current, n3)) return; + ln(t3); + let r3 = Q(Dt, t3.nativeEvent); + e38.setOpen(false, r3); + let i4 = C2?.current ?? O2; + !r3.isCanceled && ze2(i4) && i4.focus(); + return; + } + J4(t3); + }, onPointerMove(e39) { + Mo(e39) || (R3.current = true); + } }), [le6, J4, M2, j2, e38, E2, d3, O2, C2]), de6 = x.useMemo(() => { + function t3(t4) { + e38.setOpen(true, Q(kt, t4.nativeEvent, t4.currentTarget)); + } + function n3(e39) { + f4 === `auto` && dn(e39.nativeEvent) && (F2.current = !d3); + } + function r3(e39) { + F2.current = f4, f4 === `auto` && fn2(e39.nativeEvent) && (F2.current = true); + } + return { onKeyDown(n4) { + let r4 = e38.select(`open`); + R3.current = false; + let i4 = n4.key.startsWith(`Arrow`), a4 = Io(n4.key, oe5(), u3), o4 = Po(n4.key, r4 ? g5 : _5), s4 = (l5 ? a4 : o4) || n4.key === `Enter` || n4.key.trim() === ``; + if (d3 && r4 && (!l5 || On(n4.currentTarget))) return J4(n4); + if (r4 || m3 || !i4) { + if (s4) { + let e39 = Po(n4.key, oe5()); + L3.current = l5 && e39 ? null : n4.key; + } + if (l5) { + a4 && (ln(n4), r4 ? (I2.current = se5(), z2(n4), d3 && M2.current?.focus()) : t3(n4)); + return; + } + o4 && (te2.current != null && (I2.current = te2.current), ln(n4), !r4 && m3 ? t3(n4) : J4(n4), r4 && z2(n4)); + } + }, onFocus(t4) { + t4.target === t4.currentTarget && e38.select(`open`) && !d3 && (I2.current = -1, z2(t4)); + }, onPointerDown: r3, onPointerEnter: r3, onMouseDown: n3, onClick: n3 }; + }, [J4, f4, se5, l5, z2, e38, m3, g5, _5, oe5, u3, te2, d3, M2]), fe5 = x.useMemo(() => ({ ...le6, ...de6 }), [le6, de6]); + return x.useMemo(() => a3 ? { reference: fe5, floating: ue6, item: ce6, trigger: de6 } : {}, [a3, fe5, ue6, de6, ce6]); +} +function zo(e38, t2) { + let { listRef: n2, elementsRef: r2, activeIndex: i3, onMatch: a3, disabledIndices: o3, onTyping: s3, enabled: c3 = true, resetMs: l5 = 750, selectedIndex: u3 = null } = t2, d3 = Y(s3), f4 = e38.useState(`open`), p4 = Kt(), m3 = x.useRef(``), h4 = x.useRef(u3 ?? i3 ?? -1), g5 = x.useRef(null), _5 = Y((e39) => { + function t3(e40) { + return r2?.current[e40]; + } + function s4(e40) { + let n3 = t3(e40); + return n3 && !Rr(n3) || n3?.matches(`:disabled`) ? false : o3 == null || !Ir(L, e40, o3); + } + function c4(e40, t4, n3 = 0) { + if (e40.length === 0) return -1; + let r3 = (n3 % e40.length + e40.length) % e40.length, i4 = t4.toLowerCase(); + for (let t5 = 0; t5 < e40.length; t5 += 1) { + let n4 = (r3 + t5) % e40.length; + if (e40[n4]?.toLowerCase().startsWith(i4) && s4(n4)) return n4; + } + return -1; + } + let _6 = n2.current; + if (m3.current.length > 0 && e39.key === ` ` && (ln(e39), d3?.(true)), m3.current.length > 0 && m3.current[0] !== ` ` && c4(_6, m3.current) === -1 && e39.key !== ` ` && d3?.(false), _6 == null || e39.key.length !== 1 || e39.ctrlKey || e39.metaKey || e39.altKey) return; + f4 && e39.key !== ` ` && (ln(e39), d3?.(true)); + let v6 = m3.current === ``; + v6 && (h4.current = u3 ?? i3 ?? -1), _6.every((e40, t4) => e40 && s4(t4) ? e40[0]?.toLowerCase() !== e40[1]?.toLowerCase() : true) && m3.current === e39.key && (m3.current = ``, h4.current = g5.current), m3.current += e39.key, p4.start(l5, () => { + m3.current = ``, h4.current = g5.current, d3?.(false); + }); + let y5 = ((v6 ? u3 ?? i3 ?? -1 : h4.current) ?? 0) + 1, b2 = c4(_6, m3.current, y5); + b2 === -1 ? e39.key !== ` ` && (m3.current = ``, d3?.(false)) : (a3?.(b2, e39), g5.current = b2); + }), v5 = Y((t3) => { + let n3 = t3.relatedTarget, r3 = e38.select(`domReferenceElement`), i4 = e38.select(`floatingElement`); + $(r3, n3) || $(i4, n3) || (p4.clear(), m3.current = ``, h4.current = g5.current, d3?.(false)); + }); + X(() => { + (f4 || u3 === null) && (p4.clear(), g5.current = null, m3.current !== `` && (m3.current = ``, d3?.(false))); + }, [f4, u3, p4, d3]); + let y4 = x.useMemo(() => ({ onKeyDown: _5, onBlur: v5 }), [_5, v5]); + return x.useMemo(() => c3 ? { reference: y4, floating: y4 } : {}, [c3, y4]); +} +var Bo = 0.1; +var Vo = Bo * Bo; +var Ho = 0.5; +function Uo(e38, t2, n2, r2, i3, a3) { + return r2 >= t2 != a3 >= t2 && e38 <= (i3 - n2) * (t2 - r2) / (a3 - r2) + n2; +} +function Wo(e38, t2, n2, r2, i3, a3, o3, s3, c3, l5) { + let u3 = false; + return Uo(e38, t2, n2, r2, i3, a3) && (u3 = !u3), Uo(e38, t2, i3, a3, o3, s3) && (u3 = !u3), Uo(e38, t2, o3, s3, c3, l5) && (u3 = !u3), Uo(e38, t2, c3, l5, n2, r2) && (u3 = !u3), u3; +} +function Go(e38, t2, n2) { + return e38 >= n2.x && e38 <= n2.x + n2.width && t2 >= n2.y && t2 <= n2.y + n2.height; +} +function Ko(e38, t2, n2, r2, i3, a3) { + return e38 >= Math.min(n2, i3) && e38 <= Math.max(n2, i3) && t2 >= Math.min(r2, a3) && t2 <= Math.max(r2, a3); +} +function qo(e38 = {}) { + let { blockPointerEvents: t2 = false } = e38, n2 = new Gt(), r2 = ({ x: e39, y: t3, placement: r3, elements: i3, onClose: a3, nodeId: o3, tree: s3 }) => { + let c3 = r3?.split(`-`)[0], l5 = false, u3 = null, d3 = null, f4 = typeof performance2 < `u` ? performance2.now() : 0; + function p4(e40, t4) { + let n3 = performance2.now(), r4 = n3 - f4; + if (u3 === null || d3 === null || r4 === 0) return u3 = e40, d3 = t4, f4 = n3, false; + let i4 = e40 - u3, a4 = t4 - d3, o4 = i4 * i4 + a4 * a4, s4 = r4 * r4 * Vo; + return u3 = e40, d3 = t4, f4 = n3, o4 < s4; + } + function m3() { + n2.clear(), a3(); + } + return function(r4) { + n2.clear(); + let a4 = i3.domReference, u4 = i3.floating; + if (!a4 || !u4 || c3 == null || e39 == null || t3 == null) return; + let { clientX: d4, clientY: f5 } = r4, h4 = _n(r4), g5 = r4.type === `mouseleave`, _5 = $(u4, h4), v5 = $(a4, h4); + if (_5 && (l5 = true, !g5)) return; + if (v5 && (l5 = false, !g5)) { + l5 = true; + return; + } + if (g5 && Re2(r4.relatedTarget) && $(u4, r4.relatedTarget)) return; + function y4() { + return !!(s3 && ci(s3.nodesRef.current, o3).length > 0); + } + function b2() { + y4() || m3(); + } + if (y4()) return; + let x2 = a4.getBoundingClientRect(), S2 = u4.getBoundingClientRect(), C2 = e39 > S2.right - S2.width / 2, w2 = t3 > S2.bottom - S2.height / 2, T2 = S2.width > x2.width, E2 = S2.height > x2.height, D2 = (T2 ? x2 : S2).left, O2 = (T2 ? x2 : S2).right, k2 = (E2 ? x2 : S2).top, A2 = (E2 ? x2 : S2).bottom; + if (c3 === `top` && t3 >= x2.bottom - 1 || c3 === `bottom` && t3 <= x2.top + 1 || c3 === `left` && e39 >= x2.right - 1 || c3 === `right` && e39 <= x2.left + 1) { + b2(); + return; + } + let j2 = false; + switch (c3) { + case `top`: + j2 = Ko(d4, f5, D2, x2.top + 1, O2, S2.bottom - 1); + break; + case `bottom`: + j2 = Ko(d4, f5, D2, S2.top + 1, O2, x2.bottom - 1); + break; + case `left`: + j2 = Ko(d4, f5, S2.right - 1, A2, x2.left + 1, k2); + break; + case `right`: + j2 = Ko(d4, f5, x2.right - 1, A2, S2.left + 1, k2); + } + if (j2) return; + if (l5 && !Go(d4, f5, x2)) { + b2(); + return; + } + if (!g5 && p4(d4, f5)) { + b2(); + return; + } + let M2 = false; + switch (c3) { + case `top`: { + let n3 = T2 ? Ho / 2 : Ho * 4, r5 = T2 || C2 ? e39 + n3 : e39 - n3, i4 = T2 ? e39 - n3 : C2 ? e39 + n3 : e39 - n3, a5 = t3 + Ho + 1, o4 = C2 || T2 ? S2.bottom - Ho : S2.top, s4 = C2 ? T2 ? S2.bottom - Ho : S2.top : S2.bottom - Ho; + M2 = Wo(d4, f5, r5, a5, i4, a5, S2.left, o4, S2.right, s4); + break; + } + case `bottom`: { + let n3 = T2 ? Ho / 2 : Ho * 4, r5 = T2 || C2 ? e39 + n3 : e39 - n3, i4 = T2 ? e39 - n3 : C2 ? e39 + n3 : e39 - n3, a5 = t3 - Ho, o4 = C2 || T2 ? S2.top + Ho : S2.bottom, s4 = C2 ? T2 ? S2.top + Ho : S2.bottom : S2.top + Ho; + M2 = Wo(d4, f5, r5, a5, i4, a5, S2.left, o4, S2.right, s4); + break; + } + case `left`: { + let n3 = E2 ? Ho / 2 : Ho * 4, r5 = E2 || w2 ? t3 + n3 : t3 - n3, i4 = E2 ? t3 - n3 : w2 ? t3 + n3 : t3 - n3, a5 = e39 + Ho + 1, o4 = w2 || E2 ? S2.right - Ho : S2.left, s4 = w2 ? E2 ? S2.right - Ho : S2.left : S2.right - Ho; + M2 = Wo(d4, f5, o4, S2.top, s4, S2.bottom, a5, r5, a5, i4); + break; + } + case `right`: { + let n3 = E2 ? Ho / 2 : Ho * 4, r5 = E2 || w2 ? t3 + n3 : t3 - n3, i4 = E2 ? t3 - n3 : w2 ? t3 + n3 : t3 - n3, a5 = e39 - Ho, o4 = w2 || E2 ? S2.left + Ho : S2.right, s4 = w2 ? E2 ? S2.left + Ho : S2.right : S2.left + Ho; + M2 = Wo(d4, f5, a5, r5, a5, i4, o4, S2.top, s4, S2.bottom); + break; + } + } + M2 ? l5 || n2.start(40, b2) : b2(); + }; + }; + return r2.__options = { ...e38, blockPointerEvents: t2 }, r2; +} +function Jo(e38, t2, n2) { + let { reference: r2, floating: i3 } = e38, a3 = mr(t2), o3 = hr(t2), s3 = pr(o3), c3 = ur(t2), l5 = a3 === `y`, u3 = r2.x + r2.width / 2 - i3.width / 2, d3 = r2.y + r2.height / 2 - i3.height / 2, f4 = r2[s3] / 2 - i3[s3] / 2, p4; + switch (c3) { + case `top`: + p4 = { x: u3, y: r2.y - i3.height }; + break; + case `bottom`: + p4 = { x: u3, y: r2.y + r2.height }; + break; + case `right`: + p4 = { x: r2.x + r2.width, y: d3 }; + break; + case `left`: + p4 = { x: r2.x - i3.width, y: d3 }; + break; + default: + p4 = { x: r2.x, y: r2.y }; + } + let m3 = dr(t2); + return m3 && (p4[o3] += f4 * (m3 === `end` ? 1 : -1) * (n2 && l5 ? -1 : 1)), p4; +} +async function Yo(e38, t2) { + t2 === void 0 && (t2 = {}); + let { x: n2, y: r2, platform: i3, rects: a3, elements: o3, strategy: s3 } = e38, { boundary: c3 = `clippingAncestors`, rootBoundary: l5 = `viewport`, elementContext: u3 = `floating`, altBoundary: d3 = false, padding: f4 = 0 } = lr(t2, e38), p4 = Dr(f4), m3 = o3[d3 ? u3 === `floating` ? `reference` : `floating` : u3], h4 = Or(await i3.getClippingRect({ element: await (i3.isElement == null ? void 0 : i3.isElement(m3)) ?? true ? m3 : m3.contextElement || await (i3.getDocumentElement == null ? void 0 : i3.getDocumentElement(o3.floating)), boundary: c3, rootBoundary: l5, strategy: s3 })), g5 = u3 === `floating` ? { x: n2, y: r2, width: a3.floating.width, height: a3.floating.height } : a3.reference, _5 = await (i3.getOffsetParent == null ? void 0 : i3.getOffsetParent(o3.floating)), v5 = await (i3.isElement == null ? void 0 : i3.isElement(_5)) && await (i3.getScale == null ? void 0 : i3.getScale(_5)) || { x: 1, y: 1 }, y4 = Or(i3.convertOffsetParentRelativeRectToViewportRelativeRect ? await i3.convertOffsetParentRelativeRectToViewportRelativeRect({ elements: o3, rect: g5, offsetParent: _5, strategy: s3 }) : g5); + return { top: (h4.top - y4.top + p4.top) / v5.y, bottom: (y4.bottom - h4.bottom + p4.bottom) / v5.y, left: (h4.left - y4.left + p4.left) / v5.x, right: (y4.right - h4.right + p4.right) / v5.x }; +} +var Xo = 50; +var Zo = async (e38, t2, n2) => { + let { placement: r2 = `bottom`, strategy: i3 = `absolute`, middleware: a3 = [], platform: o3 } = n2, s3 = o3.detectOverflow ? o3 : { ...o3, detectOverflow: Yo }, c3 = await (o3.isRTL == null ? void 0 : o3.isRTL(t2)), l5 = await o3.getElementRects({ reference: e38, floating: t2, strategy: i3 }), { x: u3, y: d3 } = Jo(l5, r2, c3), f4 = r2, p4 = 0, m3 = {}; + for (let n3 = 0; n3 < a3.length; n3++) { + let h4 = a3[n3]; + if (!h4) continue; + let { name: g5, fn: _5 } = h4, { x: v5, y: y4, data: b2, reset: x2 } = await _5({ x: u3, y: d3, initialPlacement: r2, placement: f4, strategy: i3, middlewareData: m3, rects: l5, platform: s3, elements: { reference: e38, floating: t2 } }); + u3 = v5 ?? u3, d3 = y4 ?? d3, m3[g5] = { ...m3[g5], ...b2 }, x2 && p4 < Xo && (p4++, typeof x2 == `object` && (x2.placement && (f4 = x2.placement), x2.rects && (l5 = x2.rects === true ? await o3.getElementRects({ reference: e38, floating: t2, strategy: i3 }) : x2.rects), { x: u3, y: d3 } = Jo(l5, f4, c3)), n3 = -1); + } + return { x: u3, y: d3, placement: f4, strategy: i3, middlewareData: m3 }; +}; +var ts = function(e38) { + return e38 === void 0 && (e38 = {}), { name: `flip`, options: e38, async fn(t2) { + var n2; + let { placement: r2, middlewareData: i3, rects: a3, initialPlacement: o3, platform: s3, elements: c3 } = t2, { mainAxis: l5 = true, crossAxis: u3 = true, fallbackPlacements: d3, fallbackStrategy: f4 = `bestFit`, fallbackAxisSideDirection: p4 = `none`, flipAlignment: m3 = true, ...h4 } = lr(e38, t2); + if ((n2 = i3.arrow) != null && n2.alignmentOffset) return {}; + let g5 = ur(r2), _5 = mr(o3), v5 = ur(o3) === o3, y4 = await (s3.isRTL == null ? void 0 : s3.isRTL(c3.floating)), b2 = d3 || (v5 || !m3 ? [Tr(o3)] : _r(o3)), x2 = p4 !== `none`; + !d3 && x2 && b2.push(...wr(o3, m3, p4, y4)); + let S2 = [o3, ...b2], C2 = await s3.detectOverflow(t2, h4), w2 = [], T2 = i3.flip?.overflows || []; + if (l5 && w2.push(C2[g5]), u3) { + let e39 = gr(r2, a3, y4); + w2.push(C2[e39[0]], C2[e39[1]]); + } + if (T2 = [...T2, { placement: r2, overflows: w2 }], !w2.every((e39) => e39 <= 0)) { + let e39 = (i3.flip?.index || 0) + 1, t3 = S2[e39]; + if (t3 && (u3 !== `alignment` || _5 === mr(t3) || T2.every((e40) => mr(e40.placement) !== _5 || e40.overflows[0] > 0))) return { data: { index: e39, overflows: T2 }, reset: { placement: t3 } }; + let n3 = T2.filter((e40) => e40.overflows[0] <= 0).sort((e40, t4) => e40.overflows[1] - t4.overflows[1])[0]?.placement; + if (!n3) switch (f4) { + case `bestFit`: { + let e40 = T2.filter((e41) => { + if (x2) { + let t4 = mr(e41.placement); + return t4 === _5 || t4 === `y`; + } + return true; + }).map((e41) => [e41.placement, e41.overflows.filter((e42) => e42 > 0).reduce((e42, t4) => e42 + t4, 0)]).sort((e41, t4) => e41[1] - t4[1])[0]?.[0]; + e40 && (n3 = e40); + break; + } + case `initialPlacement`: + n3 = o3; + } + if (r2 !== n3) return { reset: { placement: n3 } }; + } + return {}; + } }; +}; +var cs = /* @__PURE__ */ new Set([`left`, `top`]); +async function ls(e38, t2) { + let { placement: n2, platform: r2, elements: i3 } = e38, a3 = await (r2.isRTL == null ? void 0 : r2.isRTL(i3.floating)), o3 = ur(n2), s3 = dr(n2), c3 = mr(n2) === `y`, l5 = cs.has(o3) ? -1 : 1, u3 = a3 && c3 ? -1 : 1, d3 = lr(t2, e38), { mainAxis: f4, crossAxis: p4, alignmentAxis: m3 } = typeof d3 == `number` ? { mainAxis: d3, crossAxis: 0, alignmentAxis: null } : { mainAxis: d3.mainAxis || 0, crossAxis: d3.crossAxis || 0, alignmentAxis: d3.alignmentAxis }; + return s3 && typeof m3 == `number` && (p4 = s3 === `end` ? m3 * -1 : m3), c3 ? { x: p4 * u3, y: f4 * l5 } : { x: f4 * l5, y: p4 * u3 }; +} +var us = function(e38) { + return e38 === void 0 && (e38 = 0), { name: `offset`, options: e38, async fn(t2) { + var n2; + let { x: r2, y: i3, placement: a3, middlewareData: o3 } = t2, s3 = await ls(t2, e38); + return a3 === o3.offset?.placement && (n2 = o3.arrow) != null && n2.alignmentOffset ? {} : { x: r2 + s3.x, y: i3 + s3.y, data: { ...s3, placement: a3 } }; + } }; +}; +var ds = function(e38) { + return e38 === void 0 && (e38 = {}), { name: `shift`, options: e38, async fn(t2) { + let { x: n2, y: r2, placement: i3, platform: a3 } = t2, { mainAxis: o3 = true, crossAxis: s3 = false, limiter: c3 = { fn: (e39) => { + let { x: t3, y: n3 } = e39; + return { x: t3, y: n3 }; + } }, ...l5 } = lr(e38, t2), u3 = { x: n2, y: r2 }, d3 = await a3.detectOverflow(t2, l5), f4 = mr(i3), p4 = fr(f4), m3 = u3[p4], h4 = u3[f4], g5 = (e39, t3) => cr(t3 + d3[e39 === `y` ? `top` : `left`], t3, t3 - d3[e39 === `y` ? `bottom` : `right`]); + o3 && (m3 = g5(p4, m3)), s3 && (h4 = g5(f4, h4)); + let _5 = c3.fn({ ...t2, [p4]: m3, [f4]: h4 }); + return { ..._5, data: { x: _5.x - n2, y: _5.y - r2, enabled: { [p4]: o3, [f4]: s3 } } }; + } }; +}; +var fs = function(e38) { + return e38 === void 0 && (e38 = {}), { options: e38, fn(t2) { + let { x: n2, y: r2, placement: i3, rects: a3, middlewareData: o3 } = t2, { offset: s3 = 0, mainAxis: c3 = true, crossAxis: l5 = true } = lr(e38, t2), u3 = { x: n2, y: r2 }, d3 = mr(i3), f4 = fr(d3), p4 = u3[f4], m3 = u3[d3], h4 = lr(s3, t2), g5 = typeof h4 == `number` ? { mainAxis: h4, crossAxis: 0 } : { mainAxis: h4.mainAxis ?? 0, crossAxis: h4.crossAxis ?? 0 }; + if (c3) { + let e39 = f4 === `y` ? `height` : `width`, t3 = a3.reference[f4] - a3.floating[e39] + g5.mainAxis, n3 = a3.reference[f4] + a3.reference[e39] - g5.mainAxis; + p4 < t3 ? p4 = t3 : p4 > n3 && (p4 = n3); + } + if (l5) { + let e39 = f4 === `y` ? `width` : `height`, t3 = cs.has(ur(i3)), n3 = a3.reference[d3] - a3.floating[e39] + (t3 && o3.offset?.[d3] || 0) + (t3 ? 0 : g5.crossAxis), r3 = a3.reference[d3] + a3.reference[e39] + (t3 ? 0 : o3.offset?.[d3] || 0) - (t3 ? g5.crossAxis : 0); + m3 < n3 ? m3 = n3 : m3 > r3 && (m3 = r3); + } + return { [f4]: p4, [d3]: m3 }; + } }; +}; +var ps = function(e38) { + return e38 === void 0 && (e38 = {}), { name: `size`, options: e38, async fn(t2) { + let { placement: n2, rects: r2, platform: i3, elements: a3 } = t2, { apply: o3 = () => { + }, ...s3 } = lr(e38, t2), c3 = await i3.detectOverflow(t2, s3), l5 = ur(n2), u3 = dr(n2), d3 = mr(n2) === `y`, { width: f4, height: p4 } = r2.floating, m3, h4; + l5 === `top` || l5 === `bottom` ? (m3 = l5, h4 = u3 === (await (i3.isRTL == null ? void 0 : i3.isRTL(a3.floating)) ? `start` : `end`) ? `left` : `right`) : (h4 = l5, m3 = u3 === `end` ? `top` : `bottom`); + let g5 = p4 - c3.top - c3.bottom, _5 = f4 - c3.left - c3.right, v5 = nr(p4 - c3[m3], g5), y4 = nr(f4 - c3[h4], _5), b2 = t2.middlewareData.shift, x2 = !b2, S2 = v5, C2 = y4; + b2 != null && b2.enabled.x && (C2 = _5), b2 != null && b2.enabled.y && (S2 = g5), x2 && !u3 && (d3 ? C2 = f4 - 2 * rr(c3.left, c3.right) : S2 = p4 - 2 * rr(c3.top, c3.bottom)), await o3({ ...t2, availableWidth: C2, availableHeight: S2 }); + let w2 = await i3.getDimensions(a3.floating); + return f4 !== w2.width || p4 !== w2.height ? { reset: { rects: true } } : {}; + } }; +}; +function ms(e38) { + let t2 = Qe(e38), n2 = parseFloat(t2.width) || 0, r2 = parseFloat(t2.height) || 0, i3 = ze2(e38), a3 = i3 ? e38.offsetWidth : n2, o3 = i3 ? e38.offsetHeight : r2, s3 = ir(n2) !== a3 || ir(r2) !== o3; + return s3 && (n2 = a3, r2 = o3), { width: n2, height: r2, $: s3 }; +} +function hs(e38) { + return Re2(e38) ? e38 : e38.contextElement; +} +function gs(e38) { + let t2 = hs(e38); + if (!ze2(t2)) return or(1); + let n2 = t2.getBoundingClientRect(), { width: r2, height: i3, $: a3 } = ms(t2), o3 = (a3 ? ir(n2.width) : n2.width) / r2, s3 = (a3 ? ir(n2.height) : n2.height) / i3; + return (!o3 || !Number.isFinite(o3)) && (o3 = 1), (!s3 || !Number.isFinite(s3)) && (s3 = 1), { x: o3, y: s3 }; +} +var _s = or(0); +function vs(e38) { + let t2 = Fe(e38); + return !Xe() || !t2.visualViewport ? _s : { x: t2.visualViewport.offsetLeft, y: t2.visualViewport.offsetTop }; +} +function ys(e38, t2, n2) { + return t2 === void 0 && (t2 = false), !!n2 && t2 && n2 === Fe(e38); +} +function bs(e38, t2, n2, r2) { + t2 === void 0 && (t2 = false), n2 === void 0 && (n2 = false); + let i3 = e38.getBoundingClientRect(), a3 = hs(e38), o3 = or(1); + t2 && (r2 ? Re2(r2) && (o3 = gs(r2)) : o3 = gs(e38)); + let s3 = ys(a3, n2, r2) ? vs(a3) : or(0), c3 = (i3.left + s3.x) / o3.x, l5 = (i3.top + s3.y) / o3.y, u3 = i3.width / o3.x, d3 = i3.height / o3.y; + if (a3 && r2) { + let e39 = Fe(a3), t3 = Re2(r2) ? Fe(r2) : r2, n3 = e39, i4 = rt2(n3); + for (; i4 && t3 !== n3; ) { + let e40 = gs(i4), t4 = i4.getBoundingClientRect(), r3 = Qe(i4), a4 = t4.left + (i4.clientLeft + parseFloat(r3.paddingLeft)) * e40.x, o4 = t4.top + (i4.clientTop + parseFloat(r3.paddingTop)) * e40.y; + c3 *= e40.x, l5 *= e40.y, u3 *= e40.x, d3 *= e40.y, c3 += a4, l5 += o4, n3 = Fe(i4), i4 = rt2(n3); + } + } + return Or({ width: u3, height: d3, x: c3, y: l5 }); +} +function xs(e38, t2) { + let n2 = $e(e38).scrollLeft; + return t2 ? t2.left + n2 : bs(Ie2(e38)).left + n2; +} +function Ss(e38, t2) { + let n2 = e38.getBoundingClientRect(); + return { x: n2.left + t2.scrollLeft - xs(e38, n2), y: n2.top + t2.scrollTop }; +} +function Cs(e38) { + let { elements: t2, rect: n2, offsetParent: r2, strategy: i3 } = e38, a3 = i3 === `fixed`, o3 = Ie2(r2), s3 = t2 ? Ue(t2.floating) : false; + if (r2 === o3 || s3 && a3) return n2; + let c3 = { scrollLeft: 0, scrollTop: 0 }, l5 = or(1), u3 = or(0), d3 = ze2(r2); + if ((d3 || !a3) && ((Pe2(r2) !== `body` || Ve2(o3)) && (c3 = $e(r2)), d3)) { + let e39 = bs(r2); + l5 = gs(r2), u3.x = e39.x + r2.clientLeft, u3.y = e39.y + r2.clientTop; + } + let f4 = o3 && !d3 && !a3 ? Ss(o3, c3) : or(0); + return { width: n2.width * l5.x, height: n2.height * l5.y, x: n2.x * l5.x - c3.scrollLeft * l5.x + u3.x + f4.x, y: n2.y * l5.y - c3.scrollTop * l5.y + u3.y + f4.y }; +} +function ws(e38) { + return e38.getClientRects ? Array.from(e38.getClientRects()) : []; +} +function Ts(e38) { + let t2 = $e(e38), n2 = e38.ownerDocument.body, r2 = rr(e38.scrollWidth, e38.clientWidth, n2.scrollWidth, n2.clientWidth), i3 = rr(e38.scrollHeight, e38.clientHeight, n2.scrollHeight, n2.clientHeight), a3 = -t2.scrollLeft + xs(e38), o3 = -t2.scrollTop; + return Qe(n2).direction === `rtl` && (a3 += rr(e38.clientWidth, n2.clientWidth) - r2), { width: r2, height: i3, x: a3, y: o3 }; +} +var Es = 25; +function Ds(e38, t2, n2) { + n2 === void 0 && (n2 = `viewport`); + let r2 = n2 === `layoutViewport`, i3 = Fe(e38), a3 = Ie2(e38), o3 = i3.visualViewport, s3 = a3.clientWidth, c3 = a3.clientHeight, l5 = 0, u3 = 0; + if (o3) { + let e39 = !Xe() || t2 === `fixed`; + r2 ? e39 || (l5 = -o3.offsetLeft, u3 = -o3.offsetTop) : (s3 = o3.width, c3 = o3.height, e39 && (l5 = o3.offsetLeft, u3 = o3.offsetTop)); + } + if (xs(a3) <= 0) { + let e39 = a3.ownerDocument, t3 = e39.body, n3 = getComputedStyle(t3), r3 = e39.compatMode === `CSS1Compat` && parseFloat(n3.marginLeft) + parseFloat(n3.marginRight) || 0, i4 = Math.abs(a3.clientWidth - t3.clientWidth - r3), o4 = getComputedStyle(a3).scrollbarGutter === `stable both-edges` ? i4 / 2 : i4; + o4 <= Es && (s3 -= o4); + } + return { width: s3, height: c3, x: l5, y: u3 }; +} +function Os(e38, t2) { + let n2 = bs(e38, true, t2 === `fixed`), r2 = n2.top + e38.clientTop, i3 = n2.left + e38.clientLeft, a3 = gs(e38); + return { width: e38.clientWidth * a3.x, height: e38.clientHeight * a3.y, x: i3 * a3.x, y: r2 * a3.y }; +} +function ks(e38, t2, n2) { + let r2; + if (t2 === `viewport` || t2 === `layoutViewport`) r2 = Ds(e38, n2, t2); + else if (t2 === `document`) r2 = Ts(Ie2(e38)); + else if (Re2(t2)) r2 = Os(t2, n2); + else { + let n3 = vs(e38); + r2 = { x: t2.x - n3.x, y: t2.y - n3.y, width: t2.width, height: t2.height }; + } + return Or(r2); +} +function As(e38, t2) { + let n2 = t2.get(e38); + if (n2) return n2; + let r2 = nt(e38, [], false).filter((e39) => Re2(e39) && Pe2(e39) !== `body`), i3 = null, a3 = Qe(e38).position === `fixed`, o3 = a3 ? et(e38) : e38; + for (; Re2(o3) && !Ze(o3); ) { + let e39 = Qe(o3), t3 = Je(o3), n3 = i3 ? i3.position : a3 ? `fixed` : ``; + !t3 && (n3 === `fixed` || n3 === `absolute` && e39.position === `static`) ? r2 = r2.filter((e40) => e40 !== o3) : i3 = e39, o3 = et(o3); + } + return t2.set(e38, r2), r2; +} +function js(e38) { + let { element: t2, boundary: n2, rootBoundary: r2, strategy: i3 } = e38, a3 = [...n2 === `clippingAncestors` ? Ue(t2) ? [] : As(t2, this._c) : [].concat(n2), r2], o3 = ks(t2, a3[0], i3), s3 = o3.top, c3 = o3.right, l5 = o3.bottom, u3 = o3.left; + for (let e39 = 1; e39 < a3.length; e39++) { + let n3 = ks(t2, a3[e39], i3); + s3 = rr(n3.top, s3), c3 = nr(n3.right, c3), l5 = nr(n3.bottom, l5), u3 = rr(n3.left, u3); + } + return { width: c3 - u3, height: l5 - s3, x: u3, y: s3 }; +} +function Ms(e38) { + let { width: t2, height: n2 } = ms(e38); + return { width: t2, height: n2 }; +} +function Ns(e38, t2, n2) { + let r2 = ze2(t2), i3 = Ie2(t2), a3 = n2 === `fixed`, o3 = bs(e38, true, a3, t2), s3 = { scrollLeft: 0, scrollTop: 0 }, c3 = or(0); + if ((r2 || !a3) && ((Pe2(t2) !== `body` || Ve2(i3)) && (s3 = $e(t2)), r2)) { + let e39 = bs(t2, true, a3, t2); + c3.x = e39.x + t2.clientLeft, c3.y = e39.y + t2.clientTop; + } + !r2 && i3 && (c3.x = xs(i3)); + let l5 = i3 && !r2 && !a3 ? Ss(i3, s3) : or(0); + return { x: o3.left + s3.scrollLeft - c3.x - l5.x, y: o3.top + s3.scrollTop - c3.y - l5.y, width: o3.width, height: o3.height }; +} +function Ps(e38) { + return Qe(e38).position === `static`; +} +function Fs(e38, t2) { + if (!ze2(e38) || Qe(e38).position === `fixed`) return null; + if (t2) return t2(e38); + let n2 = e38.offsetParent; + return Ie2(e38) === n2 && (n2 = n2.ownerDocument.body), n2; +} +function Is(e38, t2) { + let n2 = Fe(e38); + if (Ue(e38)) return n2; + if (!ze2(e38)) { + let t3 = et(e38); + for (; t3 && !Ze(t3); ) { + if (Re2(t3) && !Ps(t3)) return t3; + t3 = et(t3); + } + return n2; + } + let r2 = Fs(e38, t2); + for (; r2 && He2(r2) && Ps(r2); ) r2 = Fs(r2, t2); + return r2 && Ze(r2) && Ps(r2) && !Je(r2) ? n2 : r2 || Ye(e38) || n2; +} +var Ls = async function(e38) { + let t2 = this.getOffsetParent || Is, n2 = this.getDimensions, r2 = await n2(e38.floating); + return { reference: Ns(e38.reference, await t2(e38.floating), e38.strategy), floating: { x: 0, y: 0, width: r2.width, height: r2.height } }; +}; +function Rs(e38) { + return Qe(e38).direction === `rtl`; +} +var zs = { convertOffsetParentRelativeRectToViewportRelativeRect: Cs, getDocumentElement: Ie2, getClippingRect: js, getOffsetParent: Is, getElementRects: Ls, getClientRects: ws, getDimensions: Ms, getScale: gs, isElement: Re2, isRTL: Rs }; +function Bs(e38, t2) { + return e38.x === t2.x && e38.y === t2.y && e38.width === t2.width && e38.height === t2.height; +} +function Vs(e38, t2, n2) { + let r2 = null, i3, a3 = Ie2(e38); + function o3() { + var e39; + clearTimeout(i3), (e39 = r2) == null || e39.disconnect(), r2 = null; + } + function s3(n3, c4) { + n3 === void 0 && (n3 = false), c4 === void 0 && (c4 = 1), o3(); + let l6 = e38.getBoundingClientRect(), { left: u3, top: d3, width: f4, height: p4 } = l6; + if (n3 || t2(), !f4 || !p4) return; + let m3 = ar(d3), h4 = ar(a3.clientWidth - (u3 + f4)), g5 = ar(a3.clientHeight - (d3 + p4)), _5 = ar(u3), v5 = { rootMargin: -m3 + `px ` + -h4 + `px ` + -g5 + `px ` + -_5 + `px`, threshold: rr(0, nr(1, c4)) || 1 }, y4 = true; + function b2(t3) { + let n4 = t3[0].intersectionRatio; + if (!Bs(l6, e38.getBoundingClientRect())) return s3(); + if (n4 !== c4) { + if (!y4) return s3(); + n4 ? s3(false, n4) : i3 = setTimeout(() => { + s3(false, 1e-7); + }, 1e3); + } + y4 = false; + } + try { + r2 = new IntersectionObserver(b2, { ...v5, root: a3.ownerDocument }); + } catch { + r2 = new IntersectionObserver(b2, v5); + } + r2.observe(e38); + } + let c3 = Fe(e38), l5 = () => s3(n2); + return c3.addEventListener(`resize`, l5), s3(true), () => { + c3.removeEventListener(`resize`, l5), o3(); + }; +} +function Hs(e38, t2, n2, r2) { + r2 === void 0 && (r2 = {}); + let { ancestorScroll: i3 = true, ancestorResize: a3 = true, elementResize: o3 = typeof ResizeObserver == `function`, layoutShift: s3 = typeof IntersectionObserver == `function`, animationFrame: c3 = false } = r2, l5 = hs(e38), u3 = i3 || a3 ? [...l5 ? nt(l5) : [], ...t2 ? nt(t2) : []] : []; + u3.forEach((e39) => { + i3 && e39.addEventListener(`scroll`, n2), a3 && e39.addEventListener(`resize`, n2); + }); + let d3 = l5 && s3 ? Vs(l5, n2, a3) : null, f4 = -1, p4 = null; + o3 && (p4 = new ResizeObserver((e39) => { + let [r3] = e39; + r3 && r3.target === l5 && p4 && t2 && (p4.unobserve(t2), cancelAnimationFrame(f4), f4 = requestAnimationFrame(() => { + var e40; + (e40 = p4) == null || e40.observe(t2); + })), n2(); + }), l5 && !c3 && p4.observe(l5), t2 && p4.observe(t2)); + let m3, h4 = c3 ? bs(e38) : null; + c3 && g5(); + function g5() { + let t3 = bs(e38); + h4 && !Bs(h4, t3) && n2(), h4 = t3, m3 = requestAnimationFrame(g5); + } + return n2(), () => { + var e39; + u3.forEach((e40) => { + i3 && e40.removeEventListener(`scroll`, n2), a3 && e40.removeEventListener(`resize`, n2); + }), d3?.(), (e39 = p4) == null || e39.disconnect(), p4 = null, c3 && cancelAnimationFrame(m3); + }; +} +var Us = us; +var Gs = ds; +var Ks = ts; +var qs = ps; +var Zs = fs; +var Qs = (e38, t2, n2) => { + let r2 = /* @__PURE__ */ new Map(), i3 = n2 ?? {}, a3 = { ...zs, ...i3.platform, _c: r2 }; + return Zo(e38, t2, { ...i3, platform: a3 }); +}; +var $s = typeof document < `u` ? x.useLayoutEffect : function() { +}; +function ec(e38, t2) { + if (e38 === t2) return true; + if (typeof e38 != typeof t2) return false; + if (typeof e38 == `function` && e38.toString() === t2.toString()) return true; + let n2, r2, i3; + if (e38 && t2 && typeof e38 == `object`) { + if (Array.isArray(e38)) { + if (n2 = e38.length, n2 !== t2.length) return false; + for (r2 = n2; r2-- !== 0; ) if (!ec(e38[r2], t2[r2])) return false; + return true; + } + if (i3 = Object.keys(e38), n2 = i3.length, n2 !== Object.keys(t2).length) return false; + for (r2 = n2; r2-- !== 0; ) if (!{}.hasOwnProperty.call(t2, i3[r2])) return false; + for (r2 = n2; r2-- !== 0; ) { + let n3 = i3[r2]; + if (!(n3 === `_owner` && e38.$$typeof) && !ec(e38[n3], t2[n3])) return false; + } + return true; + } + return e38 !== e38 && t2 !== t2; +} +function tc(e38) { + return typeof window > `u` ? 1 : (e38.ownerDocument.defaultView || window).devicePixelRatio || 1; +} +function nc(e38, t2) { + let n2 = tc(e38); + return Math.round(t2 * n2) / n2; +} +function rc(e38) { + let t2 = x.useRef(e38); + return $s(() => { + t2.current = e38; + }), t2; +} +function ic(e38) { + e38 === void 0 && (e38 = {}); + let { placement: t2 = `bottom`, strategy: n2 = `absolute`, middleware: r2 = [], platform: i3, elements: { reference: a3, floating: o3 } = {}, transform: s3 = true, whileElementsMounted: c3, open: l5 } = e38, [u3, d3] = x.useState({ x: 0, y: 0, strategy: n2, placement: t2, middlewareData: {}, isPositioned: false }), [f4, p4] = x.useState(r2); + ec(f4, r2) || p4(r2); + let [m3, h4] = x.useState(null), [g5, _5] = x.useState(null), v5 = x.useCallback((e39) => { + e39 !== C2.current && (C2.current = e39, h4(e39)); + }, []), y4 = x.useCallback((e39) => { + e39 !== w2.current && (w2.current = e39, _5(e39)); + }, []), b2 = a3 || m3, S2 = o3 || g5, C2 = x.useRef(null), w2 = x.useRef(null), T2 = x.useRef(u3), E2 = c3 != null, D2 = rc(c3), O2 = rc(i3), k2 = rc(l5), A2 = x.useCallback(() => { + if (!C2.current || !w2.current) return; + let e39 = { placement: t2, strategy: n2, middleware: f4 }; + O2.current && (e39.platform = O2.current), Qs(C2.current, w2.current, e39).then((e40) => { + let t3 = { ...e40, isPositioned: k2.current !== false }; + j2.current && !ec(T2.current, t3) && (T2.current = t3, Ei.flushSync(() => { + d3(t3); + })); + }); + }, [f4, t2, n2, O2, k2]); + $s(() => { + l5 === false && T2.current.isPositioned && (T2.current.isPositioned = false, d3((e39) => ({ ...e39, isPositioned: false }))); + }, [l5]); + let j2 = x.useRef(false); + $s(() => (j2.current = true, () => { + j2.current = false; + }), []), $s(() => { + if (b2 && (C2.current = b2), S2 && (w2.current = S2), b2 && S2) { + if (D2.current) return D2.current(b2, S2, A2); + A2(); + } + }, [b2, S2, A2, D2, E2]); + let M2 = x.useMemo(() => ({ reference: C2, floating: w2, setReference: v5, setFloating: y4 }), [v5, y4]), N3 = x.useMemo(() => ({ reference: b2, floating: S2 }), [b2, S2]), P3 = x.useMemo(() => { + let e39 = { position: n2, left: 0, top: 0 }; + if (!N3.floating) return e39; + let t3 = nc(N3.floating, u3.x), r3 = nc(N3.floating, u3.y); + return s3 ? { ...e39, transform: `translate(` + t3 + `px, ` + r3 + `px)`, ...tc(N3.floating) >= 1.5 && { willChange: `transform` } } : { position: n2, left: t3, top: r3 }; + }, [n2, s3, N3.floating, u3.x, u3.y]); + return x.useMemo(() => ({ ...u3, update: A2, refs: M2, elements: N3, floatingStyles: P3 }), [u3, A2, M2, N3, P3]); +} +var ac = (e38, t2) => { + let n2 = Us(e38); + return { name: n2.name, fn: n2.fn, options: [e38, t2] }; +}; +var oc = (e38, t2) => { + let n2 = Gs(e38); + return { name: n2.name, fn: n2.fn, options: [e38, t2] }; +}; +var sc = (e38, t2) => ({ fn: Zs(e38).fn, options: [e38, t2] }); +var cc = (e38, t2) => { + let n2 = Ks(e38); + return { name: n2.name, fn: n2.fn, options: [e38, t2] }; +}; +var lc = (e38, t2) => { + let n2 = qs(e38); + return { name: n2.name, fn: n2.fn, options: [e38, t2] }; +}; +var uc = `ArrowUp`; +var dc = `ArrowDown`; +var fc = `ArrowLeft`; +var pc = `ArrowRight`; +var mc = `Home`; +var hc = /* @__PURE__ */ new Set([uc, dc, fc, pc, mc, `End`]); +function Cc(e38) { + return N2(19) ? e38 : e38 ? `true` : void 0; +} +var wc = x.forwardRef(function e7(t2, n2) { + Reflect.set(e7, `d`, 2014653865); + let { cutout: r2, ...i3 } = t2, a3; + if (r2) { + let e38 = r2.getBoundingClientRect(); + a3 = `polygon(0% 0%,100% 0%,100% 100%,0% 100%,0% 0%,${e38.left}px ${e38.top}px,${e38.left}px ${e38.bottom}px,${e38.right}px ${e38.bottom}px,${e38.right}px ${e38.top}px,${e38.left}px ${e38.top}px)`; + } + return (0, b.jsx)(`div`, { ref: n2, role: `presentation`, "data-base-ui-inert": ``, ...i3, style: { position: `fixed`, inset: 0, userSelect: `none`, WebkitUserSelect: `none`, clipPath: a3 } }); +}); +var Tc = {}; +var Ec = {}; +var Dc = ``; +function Oc(e38, t2) { + return Ve2(e38) ? e38 : t2; +} +function kc(e38, t2, n2) { + return /hidden|clip/.test(e38.getComputedStyle(Oc(t2, n2)).overflowY); +} +function Ac(e38) { + if (typeof document > `u`) return false; + let t2 = ft(e38); + return Fe(t2).innerWidth - t2.documentElement.clientWidth > 0; +} +function jc(e38) { + if (!(typeof CSS < `u` && CSS.supports && CSS.supports(`scrollbar-gutter`, `stable`)) || typeof document > `u`) return false; + let t2 = ft(e38), n2 = t2.documentElement, r2 = t2.body, i3 = Oc(n2, r2), a3 = i3.style.overflowY, o3 = n2.style.scrollbarGutter; + n2.style.scrollbarGutter = `stable`, i3.style.overflowY = `scroll`; + let s3 = i3.offsetWidth; + i3.style.overflowY = `hidden`; + let c3 = i3.offsetWidth; + return i3.style.overflowY = a3, n2.style.scrollbarGutter = o3, s3 === c3; +} +function Mc(e38) { + let t2 = ft(e38), n2 = t2.documentElement, r2 = t2.body, i3 = Oc(n2, r2), a3 = { overflowY: i3.style.overflowY, overflowX: i3.style.overflowX }; + return Object.assign(i3.style, { overflowY: `hidden`, overflowX: `hidden` }), () => { + Object.assign(i3.style, a3); + }; +} +function Nc(e38) { + let t2 = ft(e38), n2 = t2.documentElement, r2 = t2.body, i3 = Fe(n2), a3 = 0, o3 = 0, s3 = false, c3 = qn.create(); + if (an && (i3.visualViewport?.scale ?? 1) !== 1) return () => { + }; + function l5() { + let t3 = i3.getComputedStyle(n2), c4 = i3.getComputedStyle(r2), l6 = (t3.scrollbarGutter || ``).includes(`both-edges`) ? `stable both-edges` : `stable`; + a3 = n2.scrollTop, o3 = n2.scrollLeft, Tc = { scrollbarGutter: n2.style.scrollbarGutter, overflowY: n2.style.overflowY, overflowX: n2.style.overflowX }, Dc = n2.style.scrollBehavior, Ec = { position: r2.style.position, height: r2.style.height, width: r2.style.width, boxSizing: r2.style.boxSizing, overflowY: r2.style.overflowY, overflowX: r2.style.overflowX, scrollBehavior: r2.style.scrollBehavior }; + let u4 = n2.scrollHeight > n2.clientHeight, d4 = n2.scrollWidth > n2.clientWidth, f5 = t3.overflowY === `scroll` || c4.overflowY === `scroll`, p4 = t3.overflowX === `scroll` || c4.overflowX === `scroll`, m3 = Math.max(0, i3.innerWidth - r2.clientWidth), h4 = Math.max(0, i3.innerHeight - r2.clientHeight), g5 = parseFloat(c4.marginTop) + parseFloat(c4.marginBottom), _5 = parseFloat(c4.marginLeft) + parseFloat(c4.marginRight), v5 = Oc(n2, r2); + if (s3 = jc(e38), s3) { + n2.style.scrollbarGutter = l6, v5.style.overflowY = `hidden`, v5.style.overflowX = `hidden`; + return; + } + Object.assign(n2.style, { scrollbarGutter: l6, overflowY: `hidden`, overflowX: `hidden` }), (u4 || f5) && (n2.style.overflowY = `scroll`), (d4 || p4) && (n2.style.overflowX = `scroll`), Object.assign(r2.style, { position: `relative`, height: g5 || h4 ? `calc(100dvh - ${g5 + h4}px)` : `100dvh`, width: _5 || m3 ? `calc(100vw - ${_5 + m3}px)` : `100vw`, boxSizing: `border-box`, overflowY: `hidden`, overflowX: `hidden`, scrollBehavior: `unset` }), r2.scrollTop = a3, r2.scrollLeft = o3, n2.setAttribute(`data-base-ui-scroll-locked`, ``), n2.style.scrollBehavior = `unset`; + } + function u3() { + Object.assign(n2.style, Tc), Object.assign(r2.style, Ec), s3 || (n2.scrollTop = a3, n2.scrollLeft = o3, n2.removeAttribute(`data-base-ui-scroll-locked`), n2.style.scrollBehavior = Dc); + } + function d3() { + u3(), c3.request(l5); + } + l5(); + let f4 = Vn(i3, `resize`, d3); + return () => { + c3.cancel(), u3(), typeof i3.removeEventListener == `function` && f4(); + }; +} +var Pc = new class { + lockCount = 0; + restore = null; + timeoutLock = Gt.create(); + timeoutUnlock = Gt.create(); + acquire(e38) { + return this.lockCount += 1, this.lockCount === 1 && this.restore === null && this.timeoutLock.start(0, () => this.lock(e38)), this.release; + } + release = () => { + --this.lockCount, this.lockCount === 0 && this.restore && this.timeoutUnlock.start(0, this.unlock); + }; + unlock = () => { + this.lockCount === 0 && this.restore && (this.restore?.(), this.restore = null); + }; + lock(e38) { + if (this.lockCount === 0 || this.restore !== null) return; + let t2 = ft(e38), n2 = t2.documentElement, r2 = t2.body, i3 = Fe(n2); + if (kc(i3, n2, r2)) { + let t3 = new i3.MutationObserver(() => { + kc(i3, n2, r2) || (t3.disconnect(), this.restore = null, this.lock(e38)); + }), a4 = { attributes: true }; + t3.observe(n2, a4), t3.observe(r2, a4), this.restore = () => t3.disconnect(); + return; + } + let a3 = $t || !Ac(e38); + this.restore = a3 ? Mc(e38) : Nc(e38); + } +}(); +function Fc(e38 = true, t2 = null) { + X(() => { + if (e38) return Pc.acquire(t2); + }, [e38, t2]); +} +var Ic = class extends lo { + setState(e38) { + } + update(e38) { + } + set(e38, t2) { + } + notifyAll() { + } +}; +function Lc(e38) { + let t2 = x.useRef(``), n2 = x.useCallback((n3) => { + n3.defaultPrevented || (t2.current = n3.pointerType, e38(n3, n3.pointerType)); + }, [e38]); + return { onClick: x.useCallback((n3) => { + if (n3.detail === 0) { + e38(n3, `keyboard`); + return; + } + `pointerType` in n3 ? e38(n3, n3.pointerType) : e38(n3, t2.current), t2.current = ``; + }, [e38]), onPointerDown: n2 }; +} +function Rc(e38, t2) { + let n2 = x.useRef(e38), r2 = Y(t2); + X(() => { + n2.current !== e38 && r2(n2.current), n2.current = e38; + }, [e38, r2]); +} +function zc(e38, t2) { + let { onClick: n2, onPointerDown: r2 } = Lc(Y((n3, r3) => { + (typeof e38 == `function` ? e38() : e38) || t2(r3 || ($t ? `touch` : ``)); + })); + return x.useMemo(() => ({ onClick: n2, onPointerDown: r2 }), [n2, r2]); +} +function Bc(e38) { + let [t2, n2] = x.useState(null), r2 = zc(e38, n2); + return Rc(e38, (t3) => { + t3 && !e38 && n2(null); + }), x.useMemo(() => ({ openMethod: t2, triggerProps: r2 }), [t2, r2]); +} +var Vc = x.createContext(void 0); +function Hc() { + return x.useContext(Vc)?.direction ?? `ltr`; +} +var Wc = x.forwardRef(function e8(t2, n2) { + Reflect.set(e8, `d`, 1741033561); + let { render: r2, className: i3, disabled: a3 = false, focusableWhenDisabled: o3 = false, nativeButton: s3 = true, style: c3, ...l5 } = t2, { getButtonProps: u3, buttonRef: d3 } = Z({ disabled: a3, focusableWhenDisabled: o3, native: s3 }); + return J(`button`, t2, { state: { disabled: a3 }, ref: [n2, d3], props: [l5, u3] }); +}); +function Gl({ controlled: e38, default: t2, name: n2, state: r2 = `value` }) { + let { current: i3 } = x.useRef(e38 !== void 0), [a3, o3] = x.useState(() => t2); + return [i3 && e38 !== void 0 ? e38 : a3, x.useCallback((e39) => { + i3 || o3(e39); + }, [])]; +} +var ql = `data-valid`; +var Jl = `data-invalid`; +var Yl = { badInput: false, customError: false, patternMismatch: false, rangeOverflow: false, rangeUnderflow: false, stepMismatch: false, tooLong: false, tooShort: false, typeMismatch: false, valid: null, valueMissing: false }; +var Xl = { valid: null, touched: false, dirty: false, filled: false, focused: false }; +var Zl = { disabled: false, ...Xl }; +var Ql = { valid(e38) { + return e38 === null ? null : e38 ? { [ql]: `` } : { [Jl]: `` }; +} }; +var $l = `data-checked`; +var eu = `data-unchecked`; +function tu(e38) { + return { checked(t2) { + return e38.indeterminate ? {} : t2 ? { [$l]: `` } : { [eu]: `` }; + }, ...Ql }; +} +var nu = { invalid: void 0, name: void 0, validityData: { state: Yl, errors: [], error: ``, value: ``, initialValue: null }, setValidityData: I, disabled: void 0, setTouched: I, setDirty: I, setFilled: I, setFocused: I, focusOwnerRef: { current: void 0 }, validationMode: `onSubmit`, shouldValidateOnChange: () => false, state: Zl, registerFieldControl: I, validation: { getValidationProps: (e38, t2 = R) => t2, inputRef: { current: null }, registeredInputs: /* @__PURE__ */ new Map(), registerInput: I, getInputControl: () => null, commit: async () => { +}, change: I } }; +var ru = x.createContext(nu); +function iu(e38 = true) { + let t2 = x.useContext(ru); + if (t2.setValidityData === I && !e38) throw Error(C(28)); + return t2; +} +function au(e38, t2, n2) { + let { setFocused: r2, focusOwnerRef: i3 } = iu(), a3 = Y((t3) => { + (t3 ? !e38 : i3.current === a3) && (i3.current = t3 && a3, n2?.(t3), r2(t3)); + }); + return X(() => { + let e39 = t2.current; + return e39?.getRootNode()?.activeElement === e39 && a3(true), () => a3(false); + }, [e38, t2, a3]), a3; +} +function ou(e38, t2, n2, r2, i3 = true, a3) { + let { registerFieldControl: o3 } = iu(), s3 = T(() => /* @__PURE__ */ Symbol()); + X(() => { + let c3 = s3.current; + if (!i3) { + o3(c3, void 0); + return; + } + o3(c3, { controlRef: e38, getValue: r2, id: t2, name: a3, value: n2 }); + }, [e38, i3, r2, t2, a3, o3, s3, n2]), X(() => { + let e39 = s3.current; + return () => { + o3(e39, void 0); + }; + }, [o3, s3]); +} +var lu = x.createContext({ elementRef: { current: null }, formRef: { current: { fields: /* @__PURE__ */ new Map() } }, errors: {}, clearErrors: I, validationMode: `onSubmit`, submitCountRef: { current: 0 } }); +function uu() { + return x.useContext(lu); +} +var du = x.createContext({ controlId: void 0, registerControlId: I, resetControlId: I, labelId: void 0, setLabelId: I, messageIds: [], setMessageIds: I, getDescriptionProps: (e38) => e38 }); +function fu() { + return x.useContext(du); +} +function gu(e38 = {}) { + let { id: t2, enabled: n2 = true } = e38, { controlId: r2, registerControlId: i3, resetControlId: a3 } = fu(), o3 = Ht(), s3 = T(() => /* @__PURE__ */ Symbol()), c3 = x.useRef(false), l5 = x.useRef(false), u3 = Y(() => { + c3.current && i3 !== I && (c3.current = false, i3(s3.current, void 0)); + }); + return X(() => { + if (!n2 || i3 === I) { + u3(); + return; + } + let e39; + if (t2 !== void 0) l5.current = true, e39 = t2; + else if (l5.current) e39 = o3; + else { + a3(); + return; + } + if (e39 === void 0) { + u3(); + return; + } + c3.current = true, i3(s3.current, e39); + }, [t2, n2, i3, a3, o3, s3, u3]), X(() => u3, [u3]), (n2 ? r2 : void 0) ?? t2 ?? o3; +} +var yu = x.createContext(void 0); +function bu() { + let e38 = x.useContext(yu); + if (e38 === void 0) throw Error(C(14)); + return e38; +} +var Cu = x.forwardRef(function e9(t2, n2) { + Reflect.set(e9, `d`, 894566609); + let { render: r2, className: i3, style: a3, keepMounted: o3 = false, ...s3 } = t2, c3 = bu(), l5 = c3.checked || c3.indeterminate, { mounted: u3, transitionStatus: d3, setMounted: f4 } = Sa(l5), p4 = x.useRef(null), m3 = { ...c3, transitionStatus: d3 }; + Da({ batch: true, enabled: !l5, open: l5, ref: p4, onComplete() { + l5 || f4(false); + } }); + let h4 = { ...tu(c3), ...ve2 }, g5 = o3 || u3, _5 = J(`span`, t2, { ref: [n2, p4], state: m3, stateAttributesMapping: h4, props: s3 }); + return g5 ? _5 : null; +}); +function wu(e38, t2, n2 = Object.is) { + let { length: r2 } = e38; + if (r2 !== t2.length) return false; + for (let i3 = 0; i3 < r2; i3 += 1) if (!n2(e38[i3], t2[i3])) return false; + return true; +} +var Mu = [`input:not([inert]):not([inert] *)`, `select:not([inert]):not([inert] *)`, `textarea:not([inert]):not([inert] *)`, `a[href]:not([inert]):not([inert] *)`, `button:not([inert]):not([inert] *)`, `[tabindex]:not(slot):not([inert]):not([inert] *)`, `audio[controls]:not([inert]):not([inert] *)`, `video[controls]:not([inert]):not([inert] *)`, `[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)`, `details>summary:first-of-type:not([inert]):not([inert] *)`, `details:not([inert]):not([inert] *)`].join(`,`); +var Nu = typeof Element > `u`; +var Pu = Nu ? function() { +} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector; +var Fu = !Nu && Element.prototype.getRootNode ? function(e38) { + return e38?.getRootNode?.call(e38); +} : function(e38) { + return e38?.ownerDocument; +}; +var Iu = function(e38, t2) { + t2 === void 0 && (t2 = true); + var n2 = e38?.getAttribute?.call(e38, `inert`); + return n2 === `` || n2 === `true` || t2 && e38 && (typeof e38.closest == `function` ? e38.closest(`[inert]`) : Iu(e38.parentNode)); +}; +var Lu = function(e38) { + var t2 = e38?.getAttribute?.call(e38, `contenteditable`); + return t2 === `` || t2 === `true`; +}; +var Ru = function(e38, t2, n2) { + if (Iu(e38)) return []; + var r2 = Array.prototype.slice.apply(e38.querySelectorAll(Mu)); + return t2 && Pu.call(e38, Mu) && r2.unshift(e38), r2 = r2.filter(n2), r2; +}; +var zu = function(e38, t2, n2) { + for (var r2 = [], i3 = Array.from(e38); i3.length; ) { var a3 = i3.shift(); - if (!cp(a3, false)) { + if (!Iu(a3, false)) { if (a3.tagName === `SLOT`) { - var o3 = a3.assignedElements(), s3 = dp(o3.length ? o3 : a3.children, true, n2); + var o3 = a3.assignedElements(), s3 = zu(o3.length ? o3 : a3.children, true, n2); n2.flatten ? r2.push.apply(r2, s3) : r2.push({ scopeParent: a3, candidates: s3 }); } else { - op.call(a3, ip) && n2.filter(a3) && (t2 || !e9.includes(a3)) && r2.push(a3); - var c2 = a3.shadowRoot || typeof n2.getShadowRoot == `function` && n2.getShadowRoot(a3), l4 = !cp(c2, false) && (!n2.shadowRootFilter || n2.shadowRootFilter(a3)); - if (c2 && l4) { - var u3 = dp(c2 === true ? a3.children : c2.children, true, n2); + Pu.call(a3, Mu) && n2.filter(a3) && (t2 || !e38.includes(a3)) && r2.push(a3); + var c3 = a3.shadowRoot || typeof n2.getShadowRoot == `function` && n2.getShadowRoot(a3), l5 = !Iu(c3, false) && (!n2.shadowRootFilter || n2.shadowRootFilter(a3)); + if (c3 && l5) { + var u3 = zu(c3 === true ? a3.children : c3.children, true, n2); n2.flatten ? r2.push.apply(r2, u3) : r2.push({ scopeParent: a3, candidates: u3 }); } else i3.unshift.apply(i3, a3.children); } @@ -1222,95 +4046,95 @@ var dp = function(e9, t2, n2) { } return r2; }; -var fp = function(e9) { - return !isNaN(parseInt(e9.getAttribute(`tabindex`), 10)); +var Bu = function(e38) { + return !isNaN(parseInt(e38.getAttribute(`tabindex`), 10)); }; -var pp = function(e9) { - if (!e9) throw Error(`No node provided`); - return e9.tabIndex < 0 && (/^(AUDIO|VIDEO|DETAILS)$/.test(e9.tagName) || lp(e9)) && !fp(e9) ? 0 : e9.tabIndex; +var Vu = function(e38) { + if (!e38) throw Error(`No node provided`); + return e38.tabIndex < 0 && (/^(AUDIO|VIDEO|DETAILS)$/.test(e38.tagName) || Lu(e38)) && !Bu(e38) ? 0 : e38.tabIndex; }; -var mp = function(e9, t2) { - var n2 = pp(e9); - return n2 < 0 && t2 && !fp(e9) ? 0 : n2; +var Hu = function(e38, t2) { + var n2 = Vu(e38); + return n2 < 0 && t2 && !Bu(e38) ? 0 : n2; }; -var hp = function(e9, t2) { - return e9.tabIndex === t2.tabIndex ? e9.documentOrder - t2.documentOrder : e9.tabIndex - t2.tabIndex; +var Uu = function(e38, t2) { + return e38.tabIndex === t2.tabIndex ? e38.documentOrder - t2.documentOrder : e38.tabIndex - t2.tabIndex; }; -var gp = function(e9) { - return e9.tagName === `INPUT`; +var Wu = function(e38) { + return e38.tagName === `INPUT`; }; -var _p = function(e9) { - return gp(e9) && e9.type === `hidden`; +var Gu = function(e38) { + return Wu(e38) && e38.type === `hidden`; }; -var vp = function(e9) { - return e9.tagName === `DETAILS` && Array.prototype.slice.apply(e9.children).some(function(e10) { - return e10.tagName === `SUMMARY`; +var Ku = function(e38) { + return e38.tagName === `DETAILS` && Array.prototype.slice.apply(e38.children).some(function(e39) { + return e39.tagName === `SUMMARY`; }); }; -var yp = function(e9, t2) { - for (var n2 = 0; n2 < e9.length; n2++) if (e9[n2].checked && e9[n2].form === t2) return e9[n2]; +var qu = function(e38, t2) { + for (var n2 = 0; n2 < e38.length; n2++) if (e38[n2].checked && e38[n2].form === t2) return e38[n2]; }; -var bp = function(e9) { - if (!e9.name) return true; - var t2 = e9.form || sp(e9), n2 = function(e10) { - return t2.querySelectorAll(`input[type="radio"][name="` + e10 + `"]`); +var Ju = function(e38) { + if (!e38.name) return true; + var t2 = e38.form || Fu(e38), n2 = function(e39) { + return t2.querySelectorAll(`input[type="radio"][name="` + e39 + `"]`); }, r2; - if (typeof window < `u` && window.CSS !== void 0 && typeof window.CSS.escape == `function`) r2 = n2(window.CSS.escape(e9.name)); + if (typeof window < `u` && window.CSS !== void 0 && typeof window.CSS.escape == `function`) r2 = n2(window.CSS.escape(e38.name)); else try { - r2 = n2(e9.name); - } catch (e10) { - return console.error(`Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s`, e10.message), false; + r2 = n2(e38.name); + } catch (e39) { + return console.error(`Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s`, e39.message), false; } - var i3 = yp(r2, e9.form); - return !i3 || i3 === e9; + var i3 = qu(r2, e38.form); + return !i3 || i3 === e38; }; -var xp = function(e9) { - return gp(e9) && e9.type === `radio`; +var Yu = function(e38) { + return Wu(e38) && e38.type === `radio`; }; -var Sp = function(e9) { - return xp(e9) && !bp(e9); +var Xu = function(e38) { + return Yu(e38) && !Ju(e38); }; -var Cp = function(e9) { - var t2 = e9 && sp(e9), n2 = t2?.host, r2 = false; - if (t2 && t2 !== e9) { +var Zu = function(e38) { + var t2 = e38 && Fu(e38), n2 = t2?.host, r2 = false; + if (t2 && t2 !== e38) { var i3, a3, o3; - for (r2 = !!((i3 = n2) != null && (a3 = i3.ownerDocument) != null && a3.contains(n2) || e9 != null && (o3 = e9.ownerDocument) != null && o3.contains(e9)); !r2 && n2; ) { - var s3, c2; - t2 = sp(n2), n2 = t2?.host, r2 = !!((s3 = n2) != null && (c2 = s3.ownerDocument) != null && c2.contains(n2)); + for (r2 = !!((i3 = n2) != null && (a3 = i3.ownerDocument) != null && a3.contains(n2) || e38 != null && (o3 = e38.ownerDocument) != null && o3.contains(e38)); !r2 && n2; ) { + var s3, c3; + t2 = Fu(n2), n2 = t2?.host, r2 = !!((s3 = n2) != null && (c3 = s3.ownerDocument) != null && c3.contains(n2)); } } return r2; }; -var wp = function(e9) { - var t2 = e9.getBoundingClientRect(), n2 = t2.width, r2 = t2.height; +var Qu = function(e38) { + var t2 = e38.getBoundingClientRect(), n2 = t2.width, r2 = t2.height; return n2 === 0 && r2 === 0; }; -var Tp = function(e9, t2) { +var $u = function(e38, t2) { var n2 = t2.displayCheck, r2 = t2.getShadowRoot; - if (n2 === `full-native` && `checkVisibility` in e9) return !e9.checkVisibility({ checkOpacity: false, opacityProperty: false, contentVisibilityAuto: true, visibilityProperty: true, checkVisibilityCSS: true }); - if (getComputedStyle(e9).visibility === `hidden`) return true; - var i3 = op.call(e9, `details>summary:first-of-type`) ? e9.parentElement : e9; - if (op.call(i3, `details:not([open]) *`)) return true; + if (n2 === `full-native` && `checkVisibility` in e38) return !e38.checkVisibility({ checkOpacity: false, opacityProperty: false, contentVisibilityAuto: true, visibilityProperty: true, checkVisibilityCSS: true }); + if (getComputedStyle(e38).visibility === `hidden`) return true; + var i3 = Pu.call(e38, `details>summary:first-of-type`) ? e38.parentElement : e38; + if (Pu.call(i3, `details:not([open]) *`)) return true; if (!n2 || n2 === `full` || n2 === `full-native` || n2 === `legacy-full`) { if (typeof r2 == `function`) { - for (var a3 = e9; e9; ) { - var o3 = e9.parentElement, s3 = sp(e9); - if (o3 && !o3.shadowRoot && r2(o3) === true) return wp(e9); - e9 = e9.assignedSlot ? e9.assignedSlot : !o3 && s3 !== e9.ownerDocument ? s3.host : o3; + for (var a3 = e38; e38; ) { + var o3 = e38.parentElement, s3 = Fu(e38); + if (o3 && !o3.shadowRoot && r2(o3) === true) return Qu(e38); + e38 = e38.assignedSlot ? e38.assignedSlot : !o3 && s3 !== e38.ownerDocument ? s3.host : o3; } - e9 = a3; + e38 = a3; } - if (Cp(e9)) return !e9.getClientRects().length; + if (Zu(e38)) return !e38.getClientRects().length; if (n2 !== `legacy-full`) return true; - } else if (n2 === `non-zero-area`) return wp(e9); + } else if (n2 === `non-zero-area`) return Qu(e38); return false; }; -var Ep = function(e9) { - if (/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e9.tagName)) for (var t2 = e9.parentElement; t2; ) { +var ed = function(e38) { + if (/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e38.tagName)) for (var t2 = e38.parentElement; t2; ) { if (t2.tagName === `FIELDSET` && t2.disabled) { for (var n2 = 0; n2 < t2.children.length; n2++) { var r2 = t2.children.item(n2); - if (r2.tagName === `LEGEND`) return op.call(t2, `fieldset[disabled] *`) ? true : !r2.contains(e9); + if (r2.tagName === `LEGEND`) return Pu.call(t2, `fieldset[disabled] *`) ? true : !r2.contains(e38); } return true; } @@ -1318,909 +4142,2792 @@ var Ep = function(e9) { } return false; }; -var Dp = function(e9, t2) { - return !(t2.disabled || _p(t2) || Tp(t2, e9) || vp(t2) || Ep(t2)); +var td = function(e38, t2) { + return !(t2.disabled || Gu(t2) || $u(t2, e38) || Ku(t2) || ed(t2)); }; -var Op = function(e9, t2) { - return !(Sp(t2) || pp(t2) < 0 || !Dp(e9, t2)); +var nd = function(e38, t2) { + return !(Xu(t2) || Vu(t2) < 0 || !td(e38, t2)); }; -var kp = function(e9) { - var t2 = parseInt(e9.getAttribute(`tabindex`), 10); +var rd = function(e38) { + var t2 = parseInt(e38.getAttribute(`tabindex`), 10); return !!(isNaN(t2) || t2 >= 0); }; -var Ap = function(e9) { +var id = function(e38) { var t2 = [], n2 = []; - return e9.forEach(function(e10, r2) { - var i3 = !!e10.scopeParent, a3 = i3 ? e10.scopeParent : e10, o3 = mp(a3, i3), s3 = i3 ? Ap(e10.candidates) : a3; - o3 === 0 ? i3 ? t2.push.apply(t2, s3) : t2.push(a3) : n2.push({ documentOrder: r2, tabIndex: o3, item: e10, isScope: i3, content: s3 }); - }), n2.sort(hp).reduce(function(e10, t3) { - return t3.isScope ? e10.push.apply(e10, t3.content) : e10.push(t3.content), e10; + return e38.forEach(function(e39, r2) { + var i3 = !!e39.scopeParent, a3 = i3 ? e39.scopeParent : e39, o3 = Hu(a3, i3), s3 = i3 ? id(e39.candidates) : a3; + o3 === 0 ? i3 ? t2.push.apply(t2, s3) : t2.push(a3) : n2.push({ documentOrder: r2, tabIndex: o3, item: e39, isScope: i3, content: s3 }); + }), n2.sort(Uu).reduce(function(e39, t3) { + return t3.isScope ? e39.push.apply(e39, t3.content) : e39.push(t3.content), e39; }, []).concat(t2); }; -var jp = function(e9, t2) { - return t2 ||= {}, Ap(t2.getShadowRoot ? dp([e9], t2.includeContainer, { filter: Op.bind(null, t2), flatten: false, getShadowRoot: t2.getShadowRoot, shadowRootFilter: kp }) : up(e9, t2.includeContainer, Op.bind(null, t2))); +var ad = function(e38, t2) { + return t2 ||= {}, id(t2.getShadowRoot ? zu([e38], t2.includeContainer, { filter: nd.bind(null, t2), flatten: false, getShadowRoot: t2.getShadowRoot, shadowRootFilter: rd }) : Ru(e38, t2.includeContainer, nd.bind(null, t2))); }; -var Mp = function(e9, t2) { - return t2 ||= {}, t2.getShadowRoot ? dp([e9], t2.includeContainer, { filter: Dp.bind(null, t2), flatten: true, getShadowRoot: t2.getShadowRoot }) : up(e9, t2.includeContainer, Dp.bind(null, t2)); +var od = function(e38, t2) { + return t2 ||= {}, t2.getShadowRoot ? zu([e38], t2.includeContainer, { filter: td.bind(null, t2), flatten: true, getShadowRoot: t2.getShadowRoot }) : Ru(e38, t2.includeContainer, td.bind(null, t2)); }; -var Np = function(e9, t2) { - if (t2 ||= {}, !e9) throw Error(`No node provided`); - return op.call(e9, ip) !== false && Op(t2, e9); +var sd = function(e38, t2) { + if (t2 ||= {}, !e38) throw Error(`No node provided`); + return Pu.call(e38, Mu) !== false && nd(t2, e38); }; -function Pp() { - let e9 = navigator.userAgentData; - return e9 != null && e9.platform ? e9.platform : navigator.platform; -} -function Fp() { - let e9 = navigator.userAgentData; - return e9 && Array.isArray(e9.brands) ? e9.brands.map((e10) => { - let { brand: t2, version: n2 } = e10; +function cd() { + let e38 = navigator.userAgentData; + return e38 != null && e38.platform ? e38.platform : navigator.platform; +} +function ld() { + let e38 = navigator.userAgentData; + return e38 && Array.isArray(e38.brands) ? e38.brands.map((e39) => { + let { brand: t2, version: n2 } = e39; return t2 + `/` + n2; }).join(` `) : navigator.userAgent; } -function Ip() { +function ud() { return /apple/i.test(navigator.vendor); } -function Lp() { - let e9 = /android/i; - return e9.test(Pp()) || e9.test(Fp()); -} -function Rp() { - return Fp().includes(`jsdom/`); -} -var zp = `data-floating-ui-focusable`; -var Bp = `input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])`; -function Gp(e9) { - let t2 = e9.activeElement; +function dd() { + let e38 = /android/i; + return e38.test(cd()) || e38.test(ld()); +} +function fd() { + return ld().includes(`jsdom/`); +} +var pd = `data-floating-ui-focusable`; +var md = `input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])`; +var hd = `ArrowLeft`; +var gd = `ArrowRight`; +var _d = `ArrowUp`; +var vd = `ArrowDown`; +function yd(e38) { + let t2 = e38.activeElement; for (; ((n2 = t2) == null || (n2 = n2.shadowRoot) == null ? void 0 : n2.activeElement) != null; ) { var n2; t2 = t2.shadowRoot.activeElement; } return t2; } -function Kp(e9, t2) { - if (!e9 || !t2) return false; +function bd(e38, t2) { + if (!e38 || !t2) return false; let n2 = t2.getRootNode == null ? void 0 : t2.getRootNode(); - if (e9.contains(t2)) return true; - if (n2 && Ve(n2)) { + if (e38.contains(t2)) return true; + if (n2 && Be2(n2)) { let n3 = t2; for (; n3; ) { - if (e9 === n3) return true; + if (e38 === n3) return true; n3 = n3.parentNode || n3.host; } } return false; } -function qp(e9) { - return `composedPath` in e9 ? e9.composedPath()[0] : e9.target; +function xd(e38) { + return `composedPath` in e38 ? e38.composedPath()[0] : e38.target; } -function Jp(e9, t2) { +function Sd(e38, t2) { if (t2 == null) return false; - if (`composedPath` in e9) return e9.composedPath().includes(t2); - let n2 = e9; + if (`composedPath` in e38) return e38.composedPath().includes(t2); + let n2 = e38; return n2.target != null && t2.contains(n2.target); } -function Yp(e9) { - return e9.matches(`html,body`); +function Cd(e38) { + return e38.matches(`html,body`); } -function Xp(e9) { - return e9?.ownerDocument || document; +function wd(e38) { + return e38?.ownerDocument || document; } -function Zp(e9) { - return Be(e9) && e9.matches(Bp); +function Td(e38) { + return ze2(e38) && e38.matches(md); } -function Qp(e9) { - return e9 ? e9.getAttribute(`role`) === `combobox` && Zp(e9) : false; +function Ed(e38) { + return e38 ? e38.getAttribute(`role`) === `combobox` && Td(e38) : false; } -function $p(e9) { - return e9 ? e9.hasAttribute(zp) ? e9 : e9.querySelector(`[` + zp + `]`) || e9 : null; +function Dd(e38) { + return e38 ? e38.hasAttribute(pd) ? e38 : e38.querySelector(`[` + pd + `]`) || e38 : null; } -function em(e9, t2, n2) { - return n2 === void 0 && (n2 = true), e9.filter((e10) => e10.parentId === t2 && (!n2 || e10.context?.open)).flatMap((t3) => [t3, ...em(e9, t3.id, n2)]); +function Od(e38, t2, n2) { + return n2 === void 0 && (n2 = true), e38.filter((e39) => e39.parentId === t2 && (!n2 || e39.context?.open)).flatMap((t3) => [t3, ...Od(e38, t3.id, n2)]); } -function nm(e9, t2) { - let n2 = [], r2 = e9.find((e10) => e10.id === t2)?.parentId; +function kd(e38, t2) { + let n2, r2 = -1; + function i3(t3, a3) { + a3 > r2 && (n2 = t3, r2 = a3), Od(e38, t3).forEach((e39) => { + i3(e39.id, a3 + 1); + }); + } + return i3(t2, 0), e38.find((e39) => e39.id === n2); +} +function Ad(e38, t2) { + let n2 = [], r2 = e38.find((e39) => e39.id === t2)?.parentId; for (; r2; ) { - let t3 = e9.find((e10) => e10.id === r2); + let t3 = e38.find((e39) => e39.id === r2); r2 = t3?.parentId, t3 && (n2 = n2.concat(t3)); } return n2; } -function rm(e9) { - e9.preventDefault(), e9.stopPropagation(); +function jd(e38) { + e38.preventDefault(), e38.stopPropagation(); } -function im(e9) { - return `nativeEvent` in e9; +function Md(e38) { + return `nativeEvent` in e38; } -function am(e9) { - return e9.mozInputSource === 0 && e9.isTrusted ? true : Lp() && e9.pointerType ? e9.type === `click` && e9.buttons === 1 : e9.detail === 0 && !e9.pointerType; +function Nd(e38) { + return e38.mozInputSource === 0 && e38.isTrusted ? true : dd() && e38.pointerType ? e38.type === `click` && e38.buttons === 1 : e38.detail === 0 && !e38.pointerType; } -function om(e9) { - return Rp() ? false : !Lp() && e9.width === 0 && e9.height === 0 || Lp() && e9.width === 1 && e9.height === 1 && e9.pressure === 0 && e9.detail === 0 && e9.pointerType === `mouse` || e9.width < 1 && e9.height < 1 && e9.pressure === 0 && e9.detail === 0 && e9.pointerType === `touch`; +function Pd(e38) { + return fd() ? false : !dd() && e38.width === 0 && e38.height === 0 || dd() && e38.width === 1 && e38.height === 1 && e38.pressure === 0 && e38.detail === 0 && e38.pointerType === `mouse` || e38.width < 1 && e38.height < 1 && e38.pressure === 0 && e38.detail === 0 && e38.pointerType === `touch`; } -function sm(e9, t2) { +function Fd(e38, t2) { let n2 = [`mouse`, `pen`]; - return t2 || n2.push(``, void 0), n2.includes(e9); + return t2 || n2.push(``, void 0), n2.includes(e38); } -var cm = typeof document < `u` ? x.useLayoutEffect : function() { +var Id = typeof document < `u` ? x.useLayoutEffect : function() { }; -var lm = { ...x }; -function um(e9) { - let t2 = x.useRef(e9); - return cm(() => { - t2.current = e9; +var Ld = { ...x }; +function Rd(e38) { + let t2 = x.useRef(e38); + return Id(() => { + t2.current = e38; }), t2; } -var dm = lm.useInsertionEffect || ((e9) => e9()); -function fm(e9) { +var zd = Ld.useInsertionEffect || ((e38) => e38()); +function Bd(e38) { let t2 = x.useRef(() => { }); - return dm(() => { - t2.current = e9; + return zd(() => { + t2.current = e38; }), x.useCallback(function() { - var e10 = [...arguments]; - return t2.current == null ? void 0 : t2.current(...e10); + var e39 = [...arguments]; + return t2.current == null ? void 0 : t2.current(...e39); }, []); } -var Cm = () => ({ getShadowRoot: true, displayCheck: typeof ResizeObserver == `function` && ResizeObserver.toString().includes(`[native code]`) ? `full` : `none` }); -function wm(e9, t2) { - let n2 = jp(e9, Cm()), r2 = n2.length; +function Vd(e38, t2, n2) { + return Math.floor(e38 / t2) !== n2; +} +function Hd(e38, t2) { + return t2 < 0 || t2 >= e38.current.length; +} +function Ud(e38, t2) { + return Gd(e38, { disabledIndices: t2 }); +} +function Wd(e38, t2) { + return Gd(e38, { decrement: true, startingIndex: e38.current.length, disabledIndices: t2 }); +} +function Gd(e38, t2) { + let { startingIndex: n2 = -1, decrement: r2 = false, disabledIndices: i3, amount: a3 = 1 } = t2 === void 0 ? {} : t2, o3 = n2; + do + o3 += r2 ? -a3 : a3; + while (o3 >= 0 && o3 <= e38.current.length - 1 && Xd(e38, o3, i3)); + return o3; +} +function Kd(e38, t2) { + let { event: n2, orientation: r2, loop: i3, rtl: a3, cols: o3, disabledIndices: s3, minIndex: c3, maxIndex: l5, prevIndex: u3, stopEvent: d3 = false } = t2, f4 = u3; + if (n2.key === _d) { + if (d3 && jd(n2), u3 === -1) f4 = l5; + else if (f4 = Gd(e38, { startingIndex: f4, amount: o3, decrement: true, disabledIndices: s3 }), i3 && (u3 - o3 < c3 || f4 < 0)) { + let e39 = u3 % o3, t3 = l5 % o3, n3 = l5 - (t3 - e39); + f4 = t3 === e39 ? l5 : t3 > e39 ? n3 : n3 - o3; + } + Hd(e38, f4) && (f4 = u3); + } + if (n2.key === vd && (d3 && jd(n2), u3 === -1 ? f4 = c3 : (f4 = Gd(e38, { startingIndex: u3, amount: o3, disabledIndices: s3 }), i3 && u3 + o3 > l5 && (f4 = Gd(e38, { startingIndex: u3 % o3 - o3, amount: o3, disabledIndices: s3 }))), Hd(e38, f4) && (f4 = u3)), r2 === `both`) { + let t3 = ar(u3 / o3); + n2.key === (a3 ? hd : gd) && (d3 && jd(n2), u3 % o3 === o3 - 1 ? i3 && (f4 = Gd(e38, { startingIndex: u3 - u3 % o3 - 1, disabledIndices: s3 })) : (f4 = Gd(e38, { startingIndex: u3, disabledIndices: s3 }), i3 && Vd(f4, o3, t3) && (f4 = Gd(e38, { startingIndex: u3 - u3 % o3 - 1, disabledIndices: s3 }))), Vd(f4, o3, t3) && (f4 = u3)), n2.key === (a3 ? gd : hd) && (d3 && jd(n2), u3 % o3 === 0 ? i3 && (f4 = Gd(e38, { startingIndex: u3 + (o3 - u3 % o3), decrement: true, disabledIndices: s3 })) : (f4 = Gd(e38, { startingIndex: u3, decrement: true, disabledIndices: s3 }), i3 && Vd(f4, o3, t3) && (f4 = Gd(e38, { startingIndex: u3 + (o3 - u3 % o3), decrement: true, disabledIndices: s3 }))), Vd(f4, o3, t3) && (f4 = u3)); + let r3 = ar(l5 / o3) === t3; + Hd(e38, f4) && (f4 = i3 && r3 ? n2.key === (a3 ? gd : hd) ? l5 : Gd(e38, { startingIndex: u3 - u3 % o3 - 1, disabledIndices: s3 }) : u3); + } + return f4; +} +function qd(e38, t2, n2) { + let r2 = [], i3 = 0; + return e38.forEach((e39, a3) => { + let { width: o3, height: s3 } = e39, c3 = false; + for (n2 && (i3 = 0); !c3; ) { + let e40 = []; + for (let n3 = 0; n3 < o3; n3++) for (let r3 = 0; r3 < s3; r3++) e40.push(i3 + n3 + r3 * t2); + i3 % t2 + o3 <= t2 && e40.every((e41) => r2[e41] == null) ? (e40.forEach((e41) => { + r2[e41] = a3; + }), c3 = true) : i3++; + } + }), [...r2]; +} +function Jd(e38, t2, n2, r2, i3) { + if (e38 === -1) return -1; + let a3 = n2.indexOf(e38), o3 = t2[e38]; + switch (i3) { + case `tl`: + return a3; + case `tr`: + return o3 ? a3 + o3.width - 1 : a3; + case `bl`: + return o3 ? a3 + (o3.height - 1) * r2 : a3; + case `br`: + return n2.lastIndexOf(e38); + } +} +function Yd(e38, t2) { + return t2.flatMap((t3, n2) => e38.includes(t3) ? [n2] : []); +} +function Xd(e38, t2, n2) { + if (typeof n2 == `function`) return n2(t2); + if (n2) return n2.includes(t2); + let r2 = e38.current[t2]; + return r2 == null || r2.hasAttribute(`disabled`) || r2.getAttribute(`aria-disabled`) === `true`; +} +var Zd = () => ({ getShadowRoot: true, displayCheck: typeof ResizeObserver == `function` && ResizeObserver.toString().includes(`[native code]`) ? `full` : `none` }); +function Qd(e38, t2) { + let n2 = ad(e38, Zd()), r2 = n2.length; if (r2 === 0) return; - let i3 = Gp(Xp(e9)), a3 = n2.indexOf(i3); + let i3 = yd(wd(e38)), a3 = n2.indexOf(i3); return n2[a3 === -1 ? t2 === 1 ? 0 : r2 - 1 : a3 + t2]; } -function Tm(e9) { - return wm(Xp(e9).body, 1) || e9; +function $d(e38) { + return Qd(wd(e38).body, 1) || e38; } -function Em(e9) { - return wm(Xp(e9).body, -1) || e9; +function ef(e38) { + return Qd(wd(e38).body, -1) || e38; } -function Dm(e9, t2) { - let n2 = t2 || e9.currentTarget, r2 = e9.relatedTarget; - return !r2 || !Kp(n2, r2); +function tf(e38, t2) { + let n2 = t2 || e38.currentTarget, r2 = e38.relatedTarget; + return !r2 || !bd(n2, r2); } -function Om(e9) { - jp(e9, Cm()).forEach((e10) => { - e10.dataset.tabindex = e10.getAttribute(`tabindex`) || ``, e10.setAttribute(`tabindex`, `-1`); +function nf(e38) { + ad(e38, Zd()).forEach((e39) => { + e39.dataset.tabindex = e39.getAttribute(`tabindex`) || ``, e39.setAttribute(`tabindex`, `-1`); }); } -function km(e9) { - e9.querySelectorAll(`[data-tabindex]`).forEach((e10) => { - let t2 = e10.dataset.tabindex; - delete e10.dataset.tabindex, t2 ? e10.setAttribute(`tabindex`, t2) : e10.removeAttribute(`tabindex`); +function rf(e38) { + e38.querySelectorAll(`[data-tabindex]`).forEach((e39) => { + let t2 = e39.dataset.tabindex; + delete e39.dataset.tabindex, t2 ? e39.setAttribute(`tabindex`, t2) : e39.removeAttribute(`tabindex`); }); } -function Am(e9) { +function af(e38) { let t2 = x.useRef(void 0), n2 = x.useCallback((t3) => { - let n3 = e9.map((e10) => { - if (e10 != null) { - if (typeof e10 == `function`) { - let n4 = e10, r2 = n4(t3); + let n3 = e38.map((e39) => { + if (e39 != null) { + if (typeof e39 == `function`) { + let n4 = e39, r2 = n4(t3); return typeof r2 == `function` ? r2 : () => { n4(null); }; } - return e10.current = t3, () => { - e10.current = null; + return e39.current = t3, () => { + e39.current = null; }; } }); return () => { - n3.forEach((e10) => e10?.()); + n3.forEach((e39) => e39?.()); + }; + }, e38); + return x.useMemo(() => e38.every((e39) => e39 == null) ? null : (e39) => { + t2.current &&= (t2.current(), void 0), e39 != null && (t2.current = n2(e39)); + }, e38); +} +function of(e38, t2) { + let n2 = e38.compareDocumentPosition(t2); + return n2 & Node.DOCUMENT_POSITION_FOLLOWING || n2 & Node.DOCUMENT_POSITION_CONTAINED_BY ? -1 : n2 & Node.DOCUMENT_POSITION_PRECEDING || n2 & Node.DOCUMENT_POSITION_CONTAINS ? 1 : 0; +} +var sf = x.createContext({ register: () => { +}, unregister: () => { +}, map: /* @__PURE__ */ new Map(), elementsRef: { current: [] } }); +function cf(e38) { + Reflect.set(cf, `d`, 774882326); + let { children: t2, elementsRef: n2, labelsRef: r2 } = e38, [i3, a3] = x.useState(() => /* @__PURE__ */ new Set()), o3 = x.useCallback((e39) => { + a3((t3) => new Set(t3).add(e39)); + }, []), s3 = x.useCallback((e39) => { + a3((t3) => { + let n3 = new Set(t3); + return n3.delete(e39), n3; + }); + }, []), c3 = x.useMemo(() => { + let e39 = /* @__PURE__ */ new Map(); + return Array.from(i3.keys()).sort(of).forEach((t3, n3) => { + e39.set(t3, n3); + }), e39; + }, [i3]); + return (0, b.jsx)(sf.Provider, { value: x.useMemo(() => ({ register: o3, unregister: s3, map: c3, elementsRef: n2, labelsRef: r2 }), [o3, s3, c3, n2, r2]), children: t2 }); +} +function lf(e38) { + e38 === void 0 && (e38 = {}); + let { label: t2 } = e38, { register: n2, unregister: r2, map: i3, elementsRef: a3, labelsRef: o3 } = x.useContext(sf), [s3, c3] = x.useState(null), l5 = x.useRef(null), u3 = x.useCallback((e39) => { + if (l5.current = e39, s3 !== null && (a3.current[s3] = e39, o3)) { + let n3 = t2 !== void 0; + o3.current[s3] = n3 ? t2 : e39?.textContent ?? null; + } + }, [s3, a3, o3, t2]); + return Id(() => { + let e39 = l5.current; + if (e39) return n2(e39), () => { + r2(e39); }; - }, e9); - return x.useMemo(() => e9.every((e10) => e10 == null) ? null : (e10) => { - t2.current &&= (t2.current(), void 0), e10 != null && (t2.current = n2(e10)); - }, e9); -} -var Fm = `data-floating-ui-focusable`; -var Im = `active`; -var Lm = `selected`; -var Wm = { ...x }; -var Gm = false; -var Km = 0; -var qm = () => `floating-ui-` + Math.random().toString(36).slice(2, 6) + Km++; -function Jm() { - let [e9, t2] = x.useState(() => Gm ? qm() : void 0); - return cm(() => { - e9 ?? t2(qm()); + }, [n2, r2]), Id(() => { + let e39 = l5.current ? i3.get(l5.current) : null; + e39 != null && c3(e39); + }, [i3]), x.useMemo(() => ({ ref: u3, index: s3 ?? -1 }), [s3, u3]); +} +var uf = `data-floating-ui-focusable`; +var df = `active`; +var ff = `selected`; +var pf = `ArrowLeft`; +var mf = `ArrowRight`; +var hf = `ArrowUp`; +var gf = `ArrowDown`; +var yf = { ...x }; +var bf = false; +var xf = 0; +var Sf = () => `floating-ui-` + Math.random().toString(36).slice(2, 6) + xf++; +function Cf() { + let [e38, t2] = x.useState(() => bf ? Sf() : void 0); + return Id(() => { + e38 ?? t2(Sf()); }, []), x.useEffect(() => { - Gm = true; - }, []), e9; + bf = true; + }, []), e38; } -var Ym = Wm.useId || Jm; -function Xm() { - let e9 = /* @__PURE__ */ new Map(); +var wf = yf.useId || Cf; +function Tf() { + let e38 = /* @__PURE__ */ new Map(); return { emit(t2, n2) { var r2; - (r2 = e9.get(t2)) == null || r2.forEach((e10) => e10(n2)); + (r2 = e38.get(t2)) == null || r2.forEach((e39) => e39(n2)); }, on(t2, n2) { - e9.has(t2) || e9.set(t2, /* @__PURE__ */ new Set()), e9.get(t2).add(n2); + e38.has(t2) || e38.set(t2, /* @__PURE__ */ new Set()), e38.get(t2).add(n2); }, off(t2, n2) { var r2; - (r2 = e9.get(t2)) == null || r2.delete(n2); + (r2 = e38.get(t2)) == null || r2.delete(n2); } }; } -var Zm = x.createContext(null); -var Qm = x.createContext(null); -var $m = () => x.useContext(Zm)?.id || null; -var eh = () => x.useContext(Qm); -function ih(e9) { - return `data-floating-ui-` + e9; -} -function ah(e9) { - e9.current !== -1 && (clearTimeout(e9.current), e9.current = -1); +var Ef = x.createContext(null); +var Df = x.createContext(null); +var Of = () => x.useContext(Ef)?.id || null; +var kf = () => x.useContext(Df); +function Af(e38) { + let t2 = wf(), n2 = kf(), r2 = Of(), i3 = e38 || r2; + return Id(() => { + if (!t2) return; + let e39 = { id: t2, parentId: i3 }; + return n2?.addNode(e39), () => { + n2?.removeNode(e39); + }; + }, [n2, t2, i3]), t2; +} +function jf(e38) { + Reflect.set(jf, `d`, 100258069); + let { children: t2, id: n2 } = e38, r2 = Of(); + return (0, b.jsx)(Ef.Provider, { value: x.useMemo(() => ({ id: n2, parentId: r2 }), [n2, r2]), children: t2 }); +} +function Mf(e38) { + Reflect.set(Mf, `d`, 3519337204); + let { children: t2 } = e38, n2 = x.useRef([]), r2 = x.useCallback((e39) => { + n2.current = [...n2.current, e39]; + }, []), i3 = x.useCallback((e39) => { + n2.current = n2.current.filter((t3) => t3 !== e39); + }, []), [a3] = x.useState(() => Tf()); + return (0, b.jsx)(Df.Provider, { value: x.useMemo(() => ({ nodesRef: n2, addNode: r2, removeNode: i3, events: a3 }), [r2, i3, a3]), children: t2 }); +} +function Nf(e38) { + return `data-floating-ui-` + e38; +} +function Pf(e38) { + e38.current !== -1 && (clearTimeout(e38.current), e38.current = -1); +} +var Ff = Nf(`safe-polygon`); +function If(e38, t2, n2) { + if (n2 && !Fd(n2)) return 0; + if (typeof e38 == `number`) return e38; + if (typeof e38 == `function`) { + let n3 = e38(); + return typeof n3 == `number` ? n3 : n3?.[t2]; + } + return e38?.[t2]; +} +function Lf(e38) { + return typeof e38 == `function` ? e38() : e38; +} +function Rf(e38, t2) { + t2 === void 0 && (t2 = {}); + let { open: n2, onOpenChange: r2, dataRef: i3, events: a3, elements: o3 } = e38, { enabled: s3 = true, delay: c3 = 0, handleClose: l5 = null, mouseOnly: u3 = false, restMs: d3 = 0, move: f4 = true } = t2, p4 = kf(), m3 = Of(), h4 = Rd(l5), g5 = Rd(c3), _5 = Rd(n2), v5 = Rd(d3), y4 = x.useRef(), b2 = x.useRef(-1), S2 = x.useRef(), C2 = x.useRef(-1), w2 = x.useRef(true), T2 = x.useRef(false), E2 = x.useRef(() => { + }), D2 = x.useRef(false), O2 = Bd(() => { + let e39 = i3.current.openEvent?.type; + return e39?.includes(`mouse`) && e39 !== `mousedown`; + }); + x.useEffect(() => { + if (!s3) return; + function e39(e40) { + let { open: t3 } = e40; + t3 || (Pf(b2), Pf(C2), w2.current = true, D2.current = false); + } + return a3.on(`openchange`, e39), () => { + a3.off(`openchange`, e39); + }; + }, [s3, a3]), x.useEffect(() => { + if (!s3 || !h4.current || !n2) return; + function e39(e40) { + O2() && r2(false, e40, `hover`); + } + let t3 = wd(o3.floating).documentElement; + return t3.addEventListener(`mouseleave`, e39), () => { + t3.removeEventListener(`mouseleave`, e39); + }; + }, [o3.floating, n2, r2, s3, h4, O2]); + let k2 = x.useCallback(function(e39, t3, n3) { + t3 === void 0 && (t3 = true), n3 === void 0 && (n3 = `hover`); + let i4 = If(g5.current, `close`, y4.current); + i4 && !S2.current ? (Pf(b2), b2.current = window.setTimeout(() => r2(false, e39, n3), i4)) : t3 && (Pf(b2), r2(false, e39, n3)); + }, [g5, r2]), A2 = Bd(() => { + E2.current(), S2.current = void 0; + }), j2 = Bd(() => { + if (T2.current) { + let e39 = wd(o3.floating).body; + e39.style.pointerEvents = ``, e39.removeAttribute(Ff), T2.current = false; + } + }), M2 = Bd(() => i3.current.openEvent ? [`click`, `mousedown`].includes(i3.current.openEvent.type) : false); + x.useEffect(() => { + if (!s3) return; + function e39(e40) { + if (Pf(b2), w2.current = false, u3 && !Fd(y4.current) || Lf(v5.current) > 0 && !If(g5.current, `open`)) return; + let t4 = If(g5.current, `open`, y4.current); + t4 ? b2.current = window.setTimeout(() => { + _5.current || r2(true, e40, `hover`); + }, t4) : n2 || r2(true, e40, `hover`); + } + function t3(e40) { + if (M2()) { + j2(); + return; + } + E2.current(); + let t4 = wd(o3.floating); + if (Pf(C2), D2.current = false, h4.current && i3.current.floatingContext) { + n2 || Pf(b2), S2.current = h4.current({ ...i3.current.floatingContext, tree: p4, x: e40.clientX, y: e40.clientY, onClose() { + j2(), A2(), M2() || k2(e40, true, `safe-polygon`); + } }); + let r3 = S2.current; + t4.addEventListener(`mousemove`, r3), E2.current = () => { + t4.removeEventListener(`mousemove`, r3); + }; + return; + } + (y4.current !== `touch` || !bd(o3.floating, e40.relatedTarget)) && k2(e40); + } + function a4(e40) { + M2() || i3.current.floatingContext && (h4.current == null || h4.current({ ...i3.current.floatingContext, tree: p4, x: e40.clientX, y: e40.clientY, onClose() { + j2(), A2(), M2() || k2(e40); + } })(e40)); + } + function c4() { + Pf(b2); + } + function l6(e40) { + M2() || k2(e40, false); + } + if (Re2(o3.domReference)) { + let r3 = o3.domReference, i4 = o3.floating; + return n2 && r3.addEventListener(`mouseleave`, a4), f4 && r3.addEventListener(`mousemove`, e39, { once: true }), r3.addEventListener(`mouseenter`, e39), r3.addEventListener(`mouseleave`, t3), i4 && (i4.addEventListener(`mouseleave`, a4), i4.addEventListener(`mouseenter`, c4), i4.addEventListener(`mouseleave`, l6)), () => { + n2 && r3.removeEventListener(`mouseleave`, a4), f4 && r3.removeEventListener(`mousemove`, e39), r3.removeEventListener(`mouseenter`, e39), r3.removeEventListener(`mouseleave`, t3), i4 && (i4.removeEventListener(`mouseleave`, a4), i4.removeEventListener(`mouseenter`, c4), i4.removeEventListener(`mouseleave`, l6)); + }; + } + }, [o3, s3, e38, u3, f4, k2, A2, j2, r2, n2, _5, p4, g5, h4, i3, M2, v5]), Id(() => { + var e39; + if (s3 && n2 && (e39 = h4.current) != null && (e39 = e39.__options) != null && e39.blockPointerEvents && O2()) { + T2.current = true; + let e40 = o3.floating; + if (Re2(o3.domReference) && e40) { + var t3; + let n3 = wd(o3.floating).body; + n3.setAttribute(Ff, ``); + let r3 = o3.domReference, i4 = p4 == null || (t3 = p4.nodesRef.current.find((e41) => e41.id === m3)) == null || (t3 = t3.context) == null ? void 0 : t3.elements.floating; + return i4 && (i4.style.pointerEvents = ``), n3.style.pointerEvents = `none`, r3.style.pointerEvents = `auto`, e40.style.pointerEvents = `auto`, () => { + n3.style.pointerEvents = ``, r3.style.pointerEvents = ``, e40.style.pointerEvents = ``; + }; + } + } + }, [s3, n2, m3, o3, p4, h4, O2]), Id(() => { + n2 || (y4.current = void 0, D2.current = false, A2(), j2()); + }, [n2, A2, j2]), x.useEffect(() => () => { + A2(), Pf(b2), Pf(C2), j2(); + }, [s3, o3.domReference, A2, j2]); + let N3 = x.useMemo(() => { + function e39(e40) { + y4.current = e40.pointerType; + } + return { onPointerDown: e39, onPointerEnter: e39, onMouseMove(e40) { + let { nativeEvent: t3 } = e40; + function i4() { + !w2.current && !_5.current && r2(true, t3, `hover`); + } + (!u3 || Fd(y4.current)) && (n2 || Lf(v5.current) === 0 || D2.current && e40.movementX ** 2 + e40.movementY ** 2 < 2 || (Pf(C2), y4.current === `touch` ? i4() : (D2.current = true, C2.current = window.setTimeout(i4, Lf(v5.current))))); + } }; + }, [u3, r2, n2, _5, v5]); + return x.useMemo(() => s3 ? { reference: N3 } : {}, [s3, N3]); } -var uh = 0; -function dh(e9, t2) { +var zf = 0; +function Bf(e38, t2) { t2 === void 0 && (t2 = {}); let { preventScroll: n2 = false, cancelPrevious: r2 = true, sync: i3 = false } = t2; - r2 && cancelAnimationFrame(uh); - let a3 = () => e9?.focus({ preventScroll: n2 }); - i3 ? a3() : uh = requestAnimationFrame(a3); -} -function mh(e9) { - return e9?.ownerDocument || document; -} -var hh = { inert: /* @__PURE__ */ new WeakMap(), "aria-hidden": /* @__PURE__ */ new WeakMap(), none: /* @__PURE__ */ new WeakMap() }; -function gh(e9) { - return e9 === `inert` ? hh.inert : e9 === `aria-hidden` ? hh[`aria-hidden`] : hh.none; -} -var _h = /* @__PURE__ */ new WeakSet(); -var vh = {}; -var yh = 0; -var bh = () => typeof HTMLElement < `u` && `inert` in HTMLElement.prototype; -var xh = (e9) => e9 && (e9.host || xh(e9.parentNode)); -var Sh = (e9, t2) => t2.map((t3) => { - if (e9.contains(t3)) return t3; - let n2 = xh(t3); - return e9.contains(n2) ? n2 : null; -}).filter((e10) => e10 != null); -function Ch(e9, t2, n2, r2) { - let i3 = `data-floating-ui-inert`, a3 = r2 ? `inert` : n2 ? `aria-hidden` : null, o3 = Sh(t2, e9), s3 = /* @__PURE__ */ new Set(), c2 = new Set(o3), l4 = []; - vh[i3] || (vh[i3] = /* @__PURE__ */ new WeakMap()); - let u3 = vh[i3]; + r2 && cancelAnimationFrame(zf); + let a3 = () => e38?.focus({ preventScroll: n2 }); + i3 ? a3() : zf = requestAnimationFrame(a3); +} +function Vf(e38, t2) { + if (!e38 || !t2) return false; + let n2 = t2.getRootNode == null ? void 0 : t2.getRootNode(); + if (e38.contains(t2)) return true; + if (n2 && Be2(n2)) { + let n3 = t2; + for (; n3; ) { + if (e38 === n3) return true; + n3 = n3.parentNode || n3.host; + } + } + return false; +} +function Hf(e38) { + return `composedPath` in e38 ? e38.composedPath()[0] : e38.target; +} +function Uf(e38) { + return e38?.ownerDocument || document; +} +var Wf = { inert: /* @__PURE__ */ new WeakMap(), "aria-hidden": /* @__PURE__ */ new WeakMap(), none: /* @__PURE__ */ new WeakMap() }; +function Gf(e38) { + return e38 === `inert` ? Wf.inert : e38 === `aria-hidden` ? Wf[`aria-hidden`] : Wf.none; +} +var Kf = /* @__PURE__ */ new WeakSet(); +var qf = {}; +var Jf = 0; +var Yf = () => typeof HTMLElement < `u` && `inert` in HTMLElement.prototype; +var Xf = (e38) => e38 && (e38.host || Xf(e38.parentNode)); +var Zf = (e38, t2) => t2.map((t3) => { + if (e38.contains(t3)) return t3; + let n2 = Xf(t3); + return e38.contains(n2) ? n2 : null; +}).filter((e39) => e39 != null); +function Qf(e38, t2, n2, r2) { + let i3 = `data-floating-ui-inert`, a3 = r2 ? `inert` : n2 ? `aria-hidden` : null, o3 = Zf(t2, e38), s3 = /* @__PURE__ */ new Set(), c3 = new Set(o3), l5 = []; + qf[i3] || (qf[i3] = /* @__PURE__ */ new WeakMap()); + let u3 = qf[i3]; o3.forEach(d3), f4(t2), s3.clear(); - function d3(e10) { - e10 && !s3.has(e10) && (s3.add(e10), e10.parentNode && d3(e10.parentNode)); + function d3(e39) { + e39 && !s3.has(e39) && (s3.add(e39), e39.parentNode && d3(e39.parentNode)); } - function f4(e10) { - e10 && !c2.has(e10) && [].forEach.call(e10.children, (e11) => { - if (Ie(e11) !== `script`) { - if (s3.has(e11)) f4(e11); + function f4(e39) { + e39 && !c3.has(e39) && [].forEach.call(e39.children, (e40) => { + if (Pe2(e40) !== `script`) { + if (s3.has(e40)) f4(e40); else { - let t3 = a3 ? e11.getAttribute(a3) : null, n3 = t3 !== null && t3 !== `false`, r3 = gh(a3), o4 = (r3.get(e11) || 0) + 1, s4 = (u3.get(e11) || 0) + 1; - r3.set(e11, o4), u3.set(e11, s4), l4.push(e11), o4 === 1 && n3 && _h.add(e11), s4 === 1 && e11.setAttribute(i3, ``), !n3 && a3 && e11.setAttribute(a3, a3 === `inert` ? `` : `true`); + let t3 = a3 ? e40.getAttribute(a3) : null, n3 = t3 !== null && t3 !== `false`, r3 = Gf(a3), o4 = (r3.get(e40) || 0) + 1, s4 = (u3.get(e40) || 0) + 1; + r3.set(e40, o4), u3.set(e40, s4), l5.push(e40), o4 === 1 && n3 && Kf.add(e40), s4 === 1 && e40.setAttribute(i3, ``), !n3 && a3 && e40.setAttribute(a3, a3 === `inert` ? `` : `true`); } } }); } - return yh++, () => { - l4.forEach((e10) => { - let t3 = gh(a3), n3 = (t3.get(e10) || 0) - 1, r3 = (u3.get(e10) || 0) - 1; - t3.set(e10, n3), u3.set(e10, r3), n3 || (!_h.has(e10) && a3 && e10.removeAttribute(a3), _h.delete(e10)), r3 || e10.removeAttribute(i3); - }), yh--, yh || (hh.inert = /* @__PURE__ */ new WeakMap(), hh[`aria-hidden`] = /* @__PURE__ */ new WeakMap(), hh.none = /* @__PURE__ */ new WeakMap(), _h = /* @__PURE__ */ new WeakSet(), vh = {}); + return Jf++, () => { + l5.forEach((e39) => { + let t3 = Gf(a3), n3 = (t3.get(e39) || 0) - 1, r3 = (u3.get(e39) || 0) - 1; + t3.set(e39, n3), u3.set(e39, r3), n3 || (!Kf.has(e39) && a3 && e39.removeAttribute(a3), Kf.delete(e39)), r3 || e39.removeAttribute(i3); + }), Jf--, Jf || (Wf.inert = /* @__PURE__ */ new WeakMap(), Wf[`aria-hidden`] = /* @__PURE__ */ new WeakMap(), Wf.none = /* @__PURE__ */ new WeakMap(), Kf = /* @__PURE__ */ new WeakSet(), qf = {}); }; } -function wh(e9, t2, n2) { +function $f(e38, t2, n2) { t2 === void 0 && (t2 = false), n2 === void 0 && (n2 = false); - let r2 = mh(e9[0]).body; - return Ch(e9.concat(Array.from(r2.querySelectorAll(`[aria-live],[role="status"],output`))), r2, t2, n2); + let r2 = Uf(e38[0]).body; + return Qf(e38.concat(Array.from(r2.querySelectorAll(`[aria-live],[role="status"],output`))), r2, t2, n2); } -var Th = { border: 0, clip: `rect(0 0 0 0)`, height: `1px`, margin: `-1px`, overflow: `hidden`, padding: 0, position: `fixed`, whiteSpace: `nowrap`, width: `1px`, top: 0, left: 0 }; -var Eh = x.forwardRef(function e3(t2, n2) { - Reflect.set(e3, `d`, 3644680804); +var ep = { border: 0, clip: `rect(0 0 0 0)`, height: `1px`, margin: `-1px`, overflow: `hidden`, padding: 0, position: `fixed`, whiteSpace: `nowrap`, width: `1px`, top: 0, left: 0 }; +var tp = x.forwardRef(function e10(t2, n2) { + Reflect.set(e10, `d`, 3644680804); let [r2, i3] = x.useState(); - cm(() => { - Ip() && i3(`button`); + Id(() => { + ud() && i3(`button`); }, []); - let a3 = { ref: n2, tabIndex: 0, role: r2, "aria-hidden": !r2 || void 0, [ih(`focus-guard`)]: ``, style: Th }; + let a3 = { ref: n2, tabIndex: 0, role: r2, "aria-hidden": !r2 || void 0, [Nf(`focus-guard`)]: ``, style: ep }; return (0, b.jsx)(`span`, { ...t2, ...a3 }); }); -var Dh = x.createContext(null); -var Oh = ih(`portal`); -function kh(e9) { - e9 === void 0 && (e9 = {}); - let { id: t2, root: n2 } = e9, r2 = Ym(), i3 = jh(), [a3, o3] = x.useState(null), s3 = x.useRef(null); - return cm(() => () => { +var np = x.createContext(null); +var rp = Nf(`portal`); +function ip(e38) { + e38 === void 0 && (e38 = {}); + let { id: t2, root: n2 } = e38, r2 = wf(), i3 = op(), [a3, o3] = x.useState(null), s3 = x.useRef(null); + return Id(() => () => { a3?.remove(), queueMicrotask(() => { s3.current = null; }); - }, [a3]), cm(() => { + }, [a3]), Id(() => { if (!r2 || s3.current) return; - let e10 = t2 ? document.getElementById(t2) : null; - if (!e10) return; + let e39 = t2 ? document.getElementById(t2) : null; + if (!e39) return; let n3 = document.createElement(`div`); - n3.id = r2, n3.setAttribute(Oh, ``), e10.appendChild(n3), s3.current = n3, o3(n3); - }, [t2, r2]), cm(() => { + n3.id = r2, n3.setAttribute(rp, ``), e39.appendChild(n3), s3.current = n3, o3(n3); + }, [t2, r2]), Id(() => { if (n2 === null || !r2 || s3.current) return; - let e10 = n2 || i3?.portalNode; - e10 && !ze(e10) && (e10 = e10.current), e10 ||= document.body; + let e39 = n2 || i3?.portalNode; + e39 && !Le2(e39) && (e39 = e39.current), e39 ||= document.body; let a4 = null; - t2 && (a4 = document.createElement(`div`), a4.id = t2, e10.appendChild(a4)); - let c2 = document.createElement(`div`); - c2.id = r2, c2.setAttribute(Oh, ``), e10 = a4 || e10, e10.appendChild(c2), s3.current = c2, o3(c2); + t2 && (a4 = document.createElement(`div`), a4.id = t2, e39.appendChild(a4)); + let c3 = document.createElement(`div`); + c3.id = r2, c3.setAttribute(rp, ``), e39 = a4 || e39, e39.appendChild(c3), s3.current = c3, o3(c3); }, [t2, n2, r2, i3]), a3; } -function Ah(e9) { - Reflect.set(Ah, `d`, 674325219); - let { children: t2, id: n2, root: r2, preserveTabOrder: i3 = true } = e9, a3 = kh({ id: n2, root: r2 }), [o3, s3] = x.useState(null), c2 = x.useRef(null), l4 = x.useRef(null), u3 = x.useRef(null), d3 = x.useRef(null), f4 = o3?.modal, p4 = o3?.open, m3 = !!o3 && !o3.modal && o3.open && i3 && !!(r2 || a3); +function ap(e38) { + Reflect.set(ap, `d`, 674325219); + let { children: t2, id: n2, root: r2, preserveTabOrder: i3 = true } = e38, a3 = ip({ id: n2, root: r2 }), [o3, s3] = x.useState(null), c3 = x.useRef(null), l5 = x.useRef(null), u3 = x.useRef(null), d3 = x.useRef(null), f4 = o3?.modal, p4 = o3?.open, m3 = !!o3 && !o3.modal && o3.open && i3 && !!(r2 || a3); return x.useEffect(() => { if (!a3 || !i3 || f4) return; - function e10(e11) { - a3 && Dm(e11) && (e11.type === `focusin` ? km : Om)(a3); + function e39(e40) { + a3 && tf(e40) && (e40.type === `focusin` ? rf : nf)(a3); } - return a3.addEventListener(`focusin`, e10, true), a3.addEventListener(`focusout`, e10, true), () => { - a3.removeEventListener(`focusin`, e10, true), a3.removeEventListener(`focusout`, e10, true); + return a3.addEventListener(`focusin`, e39, true), a3.addEventListener(`focusout`, e39, true), () => { + a3.removeEventListener(`focusin`, e39, true), a3.removeEventListener(`focusout`, e39, true); }; }, [a3, i3, f4]), x.useEffect(() => { - a3 && (p4 || km(a3)); - }, [p4, a3]), (0, b.jsxs)(Dh.Provider, { value: x.useMemo(() => ({ preserveTabOrder: i3, beforeOutsideRef: c2, afterOutsideRef: l4, beforeInsideRef: u3, afterInsideRef: d3, portalNode: a3, setFocusManagerState: s3 }), [i3, a3]), children: [m3 && a3 && (0, b.jsx)(Eh, { "data-type": `outside`, ref: c2, onFocus: (e10) => { - if (Dm(e10, a3)) { + a3 && (p4 || rf(a3)); + }, [p4, a3]), (0, b.jsxs)(np.Provider, { value: x.useMemo(() => ({ preserveTabOrder: i3, beforeOutsideRef: c3, afterOutsideRef: l5, beforeInsideRef: u3, afterInsideRef: d3, portalNode: a3, setFocusManagerState: s3 }), [i3, a3]), children: [m3 && a3 && (0, b.jsx)(tp, { "data-type": `outside`, ref: c3, onFocus: (e39) => { + if (tf(e39, a3)) { var t3; (t3 = u3.current) == null || t3.focus(); - } else Em(o3 ? o3.domReference : null)?.focus(); - } }), m3 && a3 && (0, b.jsx)(`span`, { "aria-owns": a3.id, style: Th }), a3 && Di.createPortal(t2, a3), m3 && a3 && (0, b.jsx)(Eh, { "data-type": `outside`, ref: l4, onFocus: (e10) => { - if (Dm(e10, a3)) { + } else ef(o3 ? o3.domReference : null)?.focus(); + } }), m3 && a3 && (0, b.jsx)(`span`, { "aria-owns": a3.id, style: ep }), a3 && Ei.createPortal(t2, a3), m3 && a3 && (0, b.jsx)(tp, { "data-type": `outside`, ref: l5, onFocus: (e39) => { + if (tf(e39, a3)) { var t3; (t3 = d3.current) == null || t3.focus(); - } else Tm(o3 ? o3.domReference : null)?.focus(), o3 != null && o3.closeOnFocusOut && o3?.onOpenChange(false, e10.nativeEvent, `focus-out`); + } else $d(o3 ? o3.domReference : null)?.focus(), o3 != null && o3.closeOnFocusOut && o3?.onOpenChange(false, e39.nativeEvent, `focus-out`); } })] }); } -var jh = () => x.useContext(Dh); -function Mh(e9) { +var op = () => x.useContext(np); +function sp(e38) { return x.useMemo(() => (t2) => { - e9.forEach((e10) => { - e10 && (e10.current = t2); + e38.forEach((e39) => { + e39 && (e39.current = t2); }); - }, e9); + }, e38); } -var Nh = 20; -var Ph = []; -function Fh() { - Ph = Ph.filter((e9) => e9.isConnected); +var cp = 20; +var lp = []; +function up() { + lp = lp.filter((e38) => e38.isConnected); } -function Ih(e9) { - Fh(), e9 && Ie(e9) !== `body` && (Ph.push(e9), Ph.length > Nh && (Ph = Ph.slice(-20))); +function dp(e38) { + up(), e38 && Pe2(e38) !== `body` && (lp.push(e38), lp.length > cp && (lp = lp.slice(-20))); } -function Lh() { - return Fh(), Ph[Ph.length - 1]; +function fp() { + return up(), lp[lp.length - 1]; } -function Rh(e9) { - let t2 = Cm(); - return Np(e9, t2) ? e9 : jp(e9, t2)[0] || e9; +function pp(e38) { + let t2 = Zd(); + return sd(e38, t2) ? e38 : ad(e38, t2)[0] || e38; } -function zh(e9, t2) { +function mp(e38, t2) { var n2; - if (!t2.current.includes(`floating`) && !((n2 = e9.getAttribute(`role`)) != null && n2.includes(`dialog`))) return; - let r2 = Cm(), i3 = Mp(e9, r2).filter((e10) => { - let t3 = e10.getAttribute(`data-tabindex`) || ``; - return Np(e10, r2) || e10.hasAttribute(`data-tabindex`) && !t3.startsWith(`-`); - }), a3 = e9.getAttribute(`tabindex`); - t2.current.includes(`floating`) || i3.length === 0 ? a3 !== `0` && e9.setAttribute(`tabindex`, `0`) : (a3 !== `-1` || e9.hasAttribute(`data-tabindex`) && e9.getAttribute(`data-tabindex`) !== `-1`) && (e9.setAttribute(`tabindex`, `-1`), e9.setAttribute(`data-tabindex`, `-1`)); -} -var Bh = x.forwardRef(function e4(t2, n2) { - return Reflect.set(e4, `d`, 2466225454), (0, b.jsx)(`button`, { ...t2, type: `button`, ref: n2, tabIndex: -1, style: Th }); + if (!t2.current.includes(`floating`) && !((n2 = e38.getAttribute(`role`)) != null && n2.includes(`dialog`))) return; + let r2 = Zd(), i3 = od(e38, r2).filter((e39) => { + let t3 = e39.getAttribute(`data-tabindex`) || ``; + return sd(e39, r2) || e39.hasAttribute(`data-tabindex`) && !t3.startsWith(`-`); + }), a3 = e38.getAttribute(`tabindex`); + t2.current.includes(`floating`) || i3.length === 0 ? a3 !== `0` && e38.setAttribute(`tabindex`, `0`) : (a3 !== `-1` || e38.hasAttribute(`data-tabindex`) && e38.getAttribute(`data-tabindex`) !== `-1`) && (e38.setAttribute(`tabindex`, `-1`), e38.setAttribute(`data-tabindex`, `-1`)); +} +var hp = x.forwardRef(function e11(t2, n2) { + return Reflect.set(e11, `d`, 2466225454), (0, b.jsx)(`button`, { ...t2, type: `button`, ref: n2, tabIndex: -1, style: ep }); }); -function Vh(e9) { - Reflect.set(Vh, `d`, 4212085392); - let { context: t2, children: n2, disabled: r2 = false, order: i3 = [`content`], guards: a3 = true, initialFocus: o3 = 0, returnFocus: s3 = true, restoreFocus: c2 = false, modal: l4 = true, visuallyHiddenDismiss: u3 = false, closeOnFocusOut: d3 = true, outsideElementsInert: f4 = false, getInsideElements: p4 = () => [] } = e9, { open: m3, onOpenChange: h3, events: g3, dataRef: _2, elements: { domReference: v3, floating: y3 } } = t2, S3 = fm(() => _2.current.floatingContext?.nodeId), C2 = fm(p4), w3 = typeof o3 == `number` && o3 < 0, T3 = Qp(v3) && w3, E3 = bh(), D2 = !E3 || a3, O3 = !D2 || E3 && f4, k4 = um(i3), A3 = um(o3), j3 = um(s3), M3 = eh(), N2 = jh(), P2 = x.useRef(null), F2 = x.useRef(null), I = x.useRef(false), L = x.useRef(false), R3 = x.useRef(-1), z4 = x.useRef(-1), ee2 = N2 != null, B4 = $p(y3), V4 = fm(function(e10) { - return e10 === void 0 && (e10 = B4), e10 ? jp(e10, Cm()) : []; - }), te3 = fm((e10) => { - let t3 = V4(e10); - return k4.current.map((e11) => v3 && e11 === `reference` ? v3 : B4 && e11 === `floating` ? B4 : t3).filter(Boolean).flat(); +function gp(e38) { + Reflect.set(gp, `d`, 4212085392); + let { context: t2, children: n2, disabled: r2 = false, order: i3 = [`content`], guards: a3 = true, initialFocus: o3 = 0, returnFocus: s3 = true, restoreFocus: c3 = false, modal: l5 = true, visuallyHiddenDismiss: u3 = false, closeOnFocusOut: d3 = true, outsideElementsInert: f4 = false, getInsideElements: p4 = () => [] } = e38, { open: m3, onOpenChange: h4, events: g5, dataRef: _5, elements: { domReference: v5, floating: y4 } } = t2, S2 = Bd(() => _5.current.floatingContext?.nodeId), C2 = Bd(p4), w2 = typeof o3 == `number` && o3 < 0, T2 = Ed(v5) && w2, E2 = Yf(), D2 = !E2 || a3, O2 = !D2 || E2 && f4, k2 = Rd(i3), A2 = Rd(o3), j2 = Rd(s3), M2 = kf(), N3 = op(), P3 = x.useRef(null), F2 = x.useRef(null), I2 = x.useRef(false), L3 = x.useRef(false), R3 = x.useRef(-1), z2 = x.useRef(-1), ee2 = N3 != null, B3 = Dd(y4), V3 = Bd(function(e39) { + return e39 === void 0 && (e39 = B3), e39 ? ad(e39, Zd()) : []; + }), H3 = Bd((e39) => { + let t3 = V3(e39); + return k2.current.map((e40) => v5 && e40 === `reference` ? v5 : B3 && e40 === `floating` ? B3 : t3).filter(Boolean).flat(); }); x.useEffect(() => { - if (r2 || !l4) return; - function e10(e11) { - if (e11.key === `Tab`) { - Kp(B4, Gp(Xp(B4))) && V4().length === 0 && !T3 && rm(e11); - let t4 = te3(), n3 = qp(e11); - k4.current[0] === `reference` && n3 === v3 && (rm(e11), e11.shiftKey ? dh(t4[t4.length - 1]) : dh(t4[1])), k4.current[1] === `floating` && n3 === B4 && e11.shiftKey && (rm(e11), dh(t4[0])); + if (r2 || !l5) return; + function e39(e40) { + if (e40.key === `Tab`) { + bd(B3, yd(wd(B3))) && V3().length === 0 && !T2 && jd(e40); + let t4 = H3(), n3 = xd(e40); + k2.current[0] === `reference` && n3 === v5 && (jd(e40), e40.shiftKey ? Bf(t4[t4.length - 1]) : Bf(t4[1])), k2.current[1] === `floating` && n3 === B3 && e40.shiftKey && (jd(e40), Bf(t4[0])); } } - let t3 = Xp(B4); - return t3.addEventListener(`keydown`, e10), () => { - t3.removeEventListener(`keydown`, e10); + let t3 = wd(B3); + return t3.addEventListener(`keydown`, e39), () => { + t3.removeEventListener(`keydown`, e39); }; - }, [r2, v3, B4, l4, k4, T3, V4, te3]), x.useEffect(() => { - if (r2 || !y3) return; - function e10(e11) { - let t3 = qp(e11), n3 = V4().indexOf(t3); + }, [r2, v5, B3, l5, k2, T2, V3, H3]), x.useEffect(() => { + if (r2 || !y4) return; + function e39(e40) { + let t3 = xd(e40), n3 = V3().indexOf(t3); n3 !== -1 && (R3.current = n3); } - return y3.addEventListener(`focusin`, e10), () => { - y3.removeEventListener(`focusin`, e10); + return y4.addEventListener(`focusin`, e39), () => { + y4.removeEventListener(`focusin`, e39); }; - }, [r2, y3, V4]), x.useEffect(() => { + }, [r2, y4, V3]), x.useEffect(() => { if (r2 || !d3) return; - function e10() { - L.current = true, setTimeout(() => { - L.current = false; + function e39() { + L3.current = true, setTimeout(() => { + L3.current = false; }); } - function t3(e11) { - let t4 = e11.relatedTarget, n4 = e11.currentTarget, r3 = qp(e11); + function t3(e40) { + let t4 = e40.relatedTarget, n4 = e40.currentTarget, r3 = xd(e40); queueMicrotask(() => { - let i5 = S3(), a4 = !(Kp(v3, t4) || Kp(y3, t4) || Kp(t4, y3) || Kp(N2?.portalNode, t4) || t4 != null && t4.hasAttribute(ih(`focus-guard`)) || M3 && (em(M3.nodesRef.current, i5).find((e12) => Kp(e12.context?.elements.floating, t4) || Kp(e12.context?.elements.domReference, t4)) || nm(M3.nodesRef.current, i5).find((e12) => [e12.context?.elements.floating, $p(e12.context?.elements.floating)].includes(t4) || e12.context?.elements.domReference === t4))); - if (n4 === v3 && B4 && zh(B4, k4), c2 && n4 !== v3 && !(r3 != null && r3.isConnected) && Gp(Xp(B4)) === Xp(B4).body) { - Be(B4) && B4.focus(); - let e12 = R3.current, t5 = V4(), n5 = t5[e12] || t5[t5.length - 1] || B4; - Be(n5) && n5.focus(); + let i5 = S2(), a4 = !(bd(v5, t4) || bd(y4, t4) || bd(t4, y4) || bd(N3?.portalNode, t4) || t4 != null && t4.hasAttribute(Nf(`focus-guard`)) || M2 && (Od(M2.nodesRef.current, i5).find((e41) => bd(e41.context?.elements.floating, t4) || bd(e41.context?.elements.domReference, t4)) || Ad(M2.nodesRef.current, i5).find((e41) => [e41.context?.elements.floating, Dd(e41.context?.elements.floating)].includes(t4) || e41.context?.elements.domReference === t4))); + if (n4 === v5 && B3 && mp(B3, k2), c3 && n4 !== v5 && !(r3 != null && r3.isConnected) && yd(wd(B3)) === wd(B3).body) { + ze2(B3) && B3.focus(); + let e41 = R3.current, t5 = V3(), n5 = t5[e41] || t5[t5.length - 1] || B3; + ze2(n5) && n5.focus(); } - if (_2.current.insideReactTree) { - _2.current.insideReactTree = false; + if (_5.current.insideReactTree) { + _5.current.insideReactTree = false; return; } - (T3 || !l4) && t4 && a4 && !L.current && t4 !== Lh() && (I.current = true, h3(false, e11, `focus-out`)); + (T2 || !l5) && t4 && a4 && !L3.current && t4 !== fp() && (I2.current = true, h4(false, e40, `focus-out`)); }); } - let n3 = !(M3 || !N2); + let n3 = !(M2 || !N3); function i4() { - ah(z4), _2.current.insideReactTree = true, z4.current = window.setTimeout(() => { - _2.current.insideReactTree = false; + Pf(z2), _5.current.insideReactTree = true, z2.current = window.setTimeout(() => { + _5.current.insideReactTree = false; }); } - if (y3 && Be(v3)) return v3.addEventListener(`focusout`, t3), v3.addEventListener(`pointerdown`, e10), y3.addEventListener(`focusout`, t3), n3 && y3.addEventListener(`focusout`, i4, true), () => { - v3.removeEventListener(`focusout`, t3), v3.removeEventListener(`pointerdown`, e10), y3.removeEventListener(`focusout`, t3), n3 && y3.removeEventListener(`focusout`, i4, true); + if (y4 && ze2(v5)) return v5.addEventListener(`focusout`, t3), v5.addEventListener(`pointerdown`, e39), y4.addEventListener(`focusout`, t3), n3 && y4.addEventListener(`focusout`, i4, true), () => { + v5.removeEventListener(`focusout`, t3), v5.removeEventListener(`pointerdown`, e39), y4.removeEventListener(`focusout`, t3), n3 && y4.removeEventListener(`focusout`, i4, true); }; - }, [r2, v3, y3, B4, l4, M3, N2, h3, d3, c2, V4, T3, S3, k4, _2]); - let H4 = x.useRef(null), U4 = x.useRef(null), W4 = Mh([H4, N2?.beforeInsideRef]), ne3 = Mh([U4, N2?.afterInsideRef]); + }, [r2, v5, y4, B3, l5, M2, N3, h4, d3, c3, V3, T2, S2, k2, _5]); + let U3 = x.useRef(null), W3 = x.useRef(null), G2 = sp([U3, N3?.beforeInsideRef]), te2 = sp([W3, N3?.afterInsideRef]); x.useEffect(() => { - var e10, t3; - if (r2 || !y3) return; - let n3 = Array.from((N2 == null || (e10 = N2.portalNode) == null ? void 0 : e10.querySelectorAll(`[` + ih(`portal`) + `]`)) || []), i4 = (t3 = (M3 ? nm(M3.nodesRef.current, S3()) : []).find((e11) => Qp(e11.context?.elements.domReference || null))) == null || (t3 = t3.context) == null ? void 0 : t3.elements.domReference, a4 = [y3, i4, ...n3, ...C2(), P2.current, F2.current, H4.current, U4.current, N2?.beforeOutsideRef.current, N2?.afterOutsideRef.current, k4.current.includes(`reference`) || T3 ? v3 : null].filter((e11) => e11 != null), o4 = l4 || T3 ? wh(a4, !O3, O3) : wh(a4); + var e39, t3; + if (r2 || !y4) return; + let n3 = Array.from((N3 == null || (e39 = N3.portalNode) == null ? void 0 : e39.querySelectorAll(`[` + Nf(`portal`) + `]`)) || []), i4 = (t3 = (M2 ? Ad(M2.nodesRef.current, S2()) : []).find((e40) => Ed(e40.context?.elements.domReference || null))) == null || (t3 = t3.context) == null ? void 0 : t3.elements.domReference, a4 = [y4, i4, ...n3, ...C2(), P3.current, F2.current, U3.current, W3.current, N3?.beforeOutsideRef.current, N3?.afterOutsideRef.current, k2.current.includes(`reference`) || T2 ? v5 : null].filter((e40) => e40 != null), o4 = l5 || T2 ? $f(a4, !O2, O2) : $f(a4); return () => { o4(); }; - }, [r2, v3, y3, l4, k4, N2, T3, D2, O3, M3, S3, C2]), cm(() => { - if (r2 || !Be(B4)) return; - let e10 = Gp(Xp(B4)); + }, [r2, v5, y4, l5, k2, N3, T2, D2, O2, M2, S2, C2]), Id(() => { + if (r2 || !ze2(B3)) return; + let e39 = yd(wd(B3)); queueMicrotask(() => { - let t3 = te3(B4), n3 = A3.current, r3 = (typeof n3 == `number` ? t3[n3] : n3.current) || B4, i4 = Kp(B4, e10); - !w3 && !i4 && m3 && dh(r3, { preventScroll: r3 === B4 }); + let t3 = H3(B3), n3 = A2.current, r3 = (typeof n3 == `number` ? t3[n3] : n3.current) || B3, i4 = bd(B3, e39); + !w2 && !i4 && m3 && Bf(r3, { preventScroll: r3 === B3 }); }); - }, [r2, m3, B4, w3, te3, A3]), cm(() => { - if (r2 || !B4) return; - let e10 = Xp(B4); - Ih(Gp(e10)); - function t3(e11) { - let { reason: t4, event: n4, nested: r3 } = e11; - if ([`hover`, `safe-polygon`].includes(t4) && n4.type === `mouseleave` && (I.current = true), t4 === `outside-press`) { - if (r3) I.current = false; - else if (am(n4) || om(n4)) I.current = false; + }, [r2, m3, B3, w2, H3, A2]), Id(() => { + if (r2 || !B3) return; + let e39 = wd(B3); + dp(yd(e39)); + function t3(e40) { + let { reason: t4, event: n4, nested: r3 } = e40; + if ([`hover`, `safe-polygon`].includes(t4) && n4.type === `mouseleave` && (I2.current = true), t4 === `outside-press`) { + if (r3) I2.current = false; + else if (Nd(n4) || Pd(n4)) I2.current = false; else { - let e12 = false; + let e41 = false; document.createElement(`div`).focus({ get preventScroll() { - return e12 = true, false; - } }), e12 ? I.current = false : I.current = true; + return e41 = true, false; + } }), e41 ? I2.current = false : I2.current = true; } } } - g3.on(`openchange`, t3); - let n3 = e10.createElement(`span`); - n3.setAttribute(`tabindex`, `-1`), n3.setAttribute(`aria-hidden`, `true`), Object.assign(n3.style, Th), ee2 && v3 && v3.insertAdjacentElement(`afterend`, n3); + g5.on(`openchange`, t3); + let n3 = e39.createElement(`span`); + n3.setAttribute(`tabindex`, `-1`), n3.setAttribute(`aria-hidden`, `true`), Object.assign(n3.style, ep), ee2 && v5 && v5.insertAdjacentElement(`afterend`, n3); function i4() { - if (typeof j3.current == `boolean`) { - let e11 = v3 || Lh(); - return e11 && e11.isConnected ? e11 : n3; + if (typeof j2.current == `boolean`) { + let e40 = v5 || fp(); + return e40 && e40.isConnected ? e40 : n3; } - return j3.current.current || n3; + return j2.current.current || n3; } return () => { - g3.off(`openchange`, t3); - let r3 = Gp(e10), a4 = Kp(y3, r3) || M3 && em(M3.nodesRef.current, S3(), false).some((e11) => Kp(e11.context?.elements.floating, r3)), o4 = i4(); + g5.off(`openchange`, t3); + let r3 = yd(e39), a4 = bd(y4, r3) || M2 && Od(M2.nodesRef.current, S2(), false).some((e40) => bd(e40.context?.elements.floating, r3)), o4 = i4(); queueMicrotask(() => { - let t4 = Rh(o4); - j3.current && !I.current && Be(t4) && (t4 === r3 || r3 === e10.body || a4) && t4.focus({ preventScroll: true }), n3.remove(); + let t4 = pp(o4); + j2.current && !I2.current && ze2(t4) && (t4 === r3 || r3 === e39.body || a4) && t4.focus({ preventScroll: true }), n3.remove(); }); }; - }, [r2, y3, B4, j3, _2, g3, M3, ee2, v3, S3]), x.useEffect(() => (queueMicrotask(() => { - I.current = false; + }, [r2, y4, B3, j2, _5, g5, M2, ee2, v5, S2]), x.useEffect(() => (queueMicrotask(() => { + I2.current = false; }), () => { - queueMicrotask(Fh); - }), [r2]), cm(() => { - if (!r2 && N2) return N2.setFocusManagerState({ modal: l4, closeOnFocusOut: d3, open: m3, onOpenChange: h3, domReference: v3 }), () => { - N2.setFocusManagerState(null); + queueMicrotask(up); + }), [r2]), Id(() => { + if (!r2 && N3) return N3.setFocusManagerState({ modal: l5, closeOnFocusOut: d3, open: m3, onOpenChange: h4, domReference: v5 }), () => { + N3.setFocusManagerState(null); }; - }, [r2, N2, l4, m3, h3, d3, v3]), cm(() => { - r2 || B4 && zh(B4, k4); - }, [r2, B4, k4]); - function G5(e10) { - return r2 || !u3 || !l4 ? null : (0, b.jsx)(Bh, { ref: e10 === `start` ? P2 : F2, onClick: (e11) => h3(false, e11.nativeEvent), children: typeof u3 == `string` ? u3 : `Dismiss` }); - } - let re4 = !r2 && D2 && (!l4 || !T3) && (ee2 || l4); - return (0, b.jsxs)(b.Fragment, { children: [re4 && (0, b.jsx)(Eh, { "data-type": `inside`, ref: W4, onFocus: (e10) => { - if (l4) { - let e11 = te3(); - dh(i3[0] === `reference` ? e11[0] : e11[e11.length - 1]); - } else if (N2 != null && N2.preserveTabOrder && N2.portalNode) { - if (I.current = false, Dm(e10, N2.portalNode)) Tm(v3)?.focus(); + }, [r2, N3, l5, m3, h4, d3, v5]), Id(() => { + r2 || B3 && mp(B3, k2); + }, [r2, B3, k2]); + function K4(e39) { + return r2 || !u3 || !l5 ? null : (0, b.jsx)(hp, { ref: e39 === `start` ? P3 : F2, onClick: (e40) => h4(false, e40.nativeEvent), children: typeof u3 == `string` ? u3 : `Dismiss` }); + } + let ne3 = !r2 && D2 && (!l5 || !T2) && (ee2 || l5); + return (0, b.jsxs)(b.Fragment, { children: [ne3 && (0, b.jsx)(tp, { "data-type": `inside`, ref: G2, onFocus: (e39) => { + if (l5) { + let e40 = H3(); + Bf(i3[0] === `reference` ? e40[0] : e40[e40.length - 1]); + } else if (N3 != null && N3.preserveTabOrder && N3.portalNode) { + if (I2.current = false, tf(e39, N3.portalNode)) $d(v5)?.focus(); else { var t3; - (t3 = N2.beforeOutsideRef.current) == null || t3.focus(); + (t3 = N3.beforeOutsideRef.current) == null || t3.focus(); } } - } }), !T3 && G5(`start`), n2, G5(`end`), re4 && (0, b.jsx)(Eh, { "data-type": `inside`, ref: ne3, onFocus: (e10) => { - if (l4) dh(te3()[0]); - else if (N2 != null && N2.preserveTabOrder && N2.portalNode) { - if (d3 && (I.current = true), Dm(e10, N2.portalNode)) Em(v3)?.focus(); + } }), !T2 && K4(`start`), n2, K4(`end`), ne3 && (0, b.jsx)(tp, { "data-type": `inside`, ref: te2, onFocus: (e39) => { + if (l5) Bf(H3()[0]); + else if (N3 != null && N3.preserveTabOrder && N3.portalNode) { + if (d3 && (I2.current = true), tf(e39, N3.portalNode)) ef(v5)?.focus(); else { var t3; - (t3 = N2.afterOutsideRef.current) == null || t3.focus(); + (t3 = N3.afterOutsideRef.current) == null || t3.focus(); } } } })] }); } -var Hh = 0; -var Uh = `--floating-ui-scrollbar-width`; -function Wh() { - let e9 = Pp(), t2 = /iP(hone|ad|od)|iOS/.test(e9) || e9 === `MacIntel` && navigator.maxTouchPoints > 1, n2 = document.body.style, r2 = Math.round(document.documentElement.getBoundingClientRect().left) + document.documentElement.scrollLeft ? `paddingLeft` : `paddingRight`, i3 = window.innerWidth - document.documentElement.clientWidth, a3 = n2.left ? parseFloat(n2.left) : window.scrollX, o3 = n2.top ? parseFloat(n2.top) : window.scrollY; - if (n2.overflow = `hidden`, n2.setProperty(Uh, i3 + `px`), i3 && (n2[r2] = i3 + `px`), t2) { - let e10 = window.visualViewport?.offsetLeft || 0, t3 = window.visualViewport?.offsetTop || 0; - Object.assign(n2, { position: `fixed`, top: -(o3 - Math.floor(t3)) + `px`, left: -(a3 - Math.floor(e10)) + `px`, right: `0` }); +var _p = 0; +var vp = `--floating-ui-scrollbar-width`; +function yp() { + let e38 = cd(), t2 = /iP(hone|ad|od)|iOS/.test(e38) || e38 === `MacIntel` && navigator.maxTouchPoints > 1, n2 = document.body.style, r2 = Math.round(document.documentElement.getBoundingClientRect().left) + document.documentElement.scrollLeft ? `paddingLeft` : `paddingRight`, i3 = window.innerWidth - document.documentElement.clientWidth, a3 = n2.left ? parseFloat(n2.left) : window.scrollX, o3 = n2.top ? parseFloat(n2.top) : window.scrollY; + if (n2.overflow = `hidden`, n2.setProperty(vp, i3 + `px`), i3 && (n2[r2] = i3 + `px`), t2) { + let e39 = window.visualViewport?.offsetLeft || 0, t3 = window.visualViewport?.offsetTop || 0; + Object.assign(n2, { position: `fixed`, top: -(o3 - Math.floor(t3)) + `px`, left: -(a3 - Math.floor(e39)) + `px`, right: `0` }); } return () => { - Object.assign(n2, { overflow: ``, [r2]: `` }), n2.removeProperty(Uh), t2 && (Object.assign(n2, { position: ``, top: ``, left: ``, right: `` }), window.scrollTo(a3, o3)); + Object.assign(n2, { overflow: ``, [r2]: `` }), n2.removeProperty(vp), t2 && (Object.assign(n2, { position: ``, top: ``, left: ``, right: `` }), window.scrollTo(a3, o3)); }; } -var Gh = () => { +var bp = () => { }; -var Kh = x.forwardRef(function e5(t2, n2) { - Reflect.set(e5, `d`, 3690129767); +var xp = x.forwardRef(function e12(t2, n2) { + Reflect.set(e12, `d`, 3690129767); let { lockScroll: r2 = false, ...i3 } = t2; - return cm(() => { - if (r2) return Hh++, Hh === 1 && (Gh = Wh()), () => { - Hh--, Hh === 0 && Gh(); + return Id(() => { + if (r2) return _p++, _p === 1 && (bp = yp()), () => { + _p--, _p === 0 && bp(); }; }, [r2]), (0, b.jsx)(`div`, { ref: n2, ...i3, style: { position: `fixed`, overflow: `auto`, top: 0, right: 0, bottom: 0, left: 0, ...i3.style } }); }); -function qh(e9) { - return Be(e9.target) && e9.target.tagName === `BUTTON`; +function Sp(e38) { + return ze2(e38.target) && e38.target.tagName === `BUTTON`; } -function Jh(e9) { - return Be(e9.target) && e9.target.tagName === `A`; +function Cp(e38) { + return ze2(e38.target) && e38.target.tagName === `A`; } -function Yh(e9) { - return Zp(e9); +function wp(e38) { + return Td(e38); } -function Xh(e9, t2) { +function Tp(e38, t2) { t2 === void 0 && (t2 = {}); - let { open: n2, onOpenChange: r2, dataRef: i3, elements: { domReference: a3 } } = e9, { enabled: o3 = true, event: s3 = `click`, toggle: c2 = true, ignoreMouse: l4 = false, keyboardHandlers: u3 = true, stickIfOpen: d3 = true } = t2, f4 = x.useRef(), p4 = x.useRef(false), m3 = x.useMemo(() => ({ onPointerDown(e10) { - f4.current = e10.pointerType; - }, onMouseDown(e10) { + let { open: n2, onOpenChange: r2, dataRef: i3, elements: { domReference: a3 } } = e38, { enabled: o3 = true, event: s3 = `click`, toggle: c3 = true, ignoreMouse: l5 = false, keyboardHandlers: u3 = true, stickIfOpen: d3 = true } = t2, f4 = x.useRef(), p4 = x.useRef(false), m3 = x.useMemo(() => ({ onPointerDown(e39) { + f4.current = e39.pointerType; + }, onMouseDown(e39) { let t3 = f4.current; - e10.button === 0 && s3 !== `click` && (sm(t3, true) && l4 || (n2 && c2 && (!(i3.current.openEvent && d3) || i3.current.openEvent.type === `mousedown`) ? r2(false, e10.nativeEvent, `click`) : (e10.preventDefault(), r2(true, e10.nativeEvent, `click`)))); - }, onClick(e10) { + e39.button === 0 && s3 !== `click` && (Fd(t3, true) && l5 || (n2 && c3 && (!(i3.current.openEvent && d3) || i3.current.openEvent.type === `mousedown`) ? r2(false, e39.nativeEvent, `click`) : (e39.preventDefault(), r2(true, e39.nativeEvent, `click`)))); + }, onClick(e39) { let t3 = f4.current; if (s3 === `mousedown` && f4.current) { f4.current = void 0; return; } - sm(t3, true) && l4 || (n2 && c2 && (!(i3.current.openEvent && d3) || i3.current.openEvent.type === `click`) ? r2(false, e10.nativeEvent, `click`) : r2(true, e10.nativeEvent, `click`)); - }, onKeyDown(e10) { - f4.current = void 0, !(e10.defaultPrevented || !u3 || qh(e10)) && (e10.key === ` ` && !Yh(a3) && (e10.preventDefault(), p4.current = true), !Jh(e10) && e10.key === `Enter` && r2(!(n2 && c2), e10.nativeEvent, `click`)); - }, onKeyUp(e10) { - e10.defaultPrevented || !u3 || qh(e10) || Yh(a3) || e10.key === ` ` && p4.current && (p4.current = false, r2(!(n2 && c2), e10.nativeEvent, `click`)); - } }), [i3, a3, s3, l4, u3, r2, n2, d3, c2]); + Fd(t3, true) && l5 || (n2 && c3 && (!(i3.current.openEvent && d3) || i3.current.openEvent.type === `click`) ? r2(false, e39.nativeEvent, `click`) : r2(true, e39.nativeEvent, `click`)); + }, onKeyDown(e39) { + f4.current = void 0, !(e39.defaultPrevented || !u3 || Sp(e39)) && (e39.key === ` ` && !wp(a3) && (e39.preventDefault(), p4.current = true), !Cp(e39) && e39.key === `Enter` && r2(!(n2 && c3), e39.nativeEvent, `click`)); + }, onKeyUp(e39) { + e39.defaultPrevented || !u3 || Sp(e39) || wp(a3) || e39.key === ` ` && p4.current && (p4.current = false, r2(!(n2 && c3), e39.nativeEvent, `click`)); + } }), [i3, a3, s3, l5, u3, r2, n2, d3, c3]); return x.useMemo(() => o3 ? { reference: m3 } : {}, [o3, m3]); } -var Zh = { pointerdown: `onPointerDown`, mousedown: `onMouseDown`, click: `onClick` }; -var Qh = { pointerdown: `onPointerDownCapture`, mousedown: `onMouseDownCapture`, click: `onClickCapture` }; -var $h = (e9) => ({ escapeKey: typeof e9 == `boolean` ? e9 : e9?.escapeKey ?? false, outsidePress: typeof e9 == `boolean` ? e9 : e9?.outsidePress ?? true }); -function eg(e9, t2) { +var Ep = { pointerdown: `onPointerDown`, mousedown: `onMouseDown`, click: `onClick` }; +var Dp = { pointerdown: `onPointerDownCapture`, mousedown: `onMouseDownCapture`, click: `onClickCapture` }; +var Op = (e38) => ({ escapeKey: typeof e38 == `boolean` ? e38 : e38?.escapeKey ?? false, outsidePress: typeof e38 == `boolean` ? e38 : e38?.outsidePress ?? true }); +function kp(e38, t2) { t2 === void 0 && (t2 = {}); - let { open: n2, onOpenChange: r2, elements: i3, dataRef: a3 } = e9, { enabled: o3 = true, escapeKey: s3 = true, outsidePress: c2 = true, outsidePressEvent: l4 = `pointerdown`, referencePress: u3 = false, referencePressEvent: d3 = `pointerdown`, ancestorScroll: f4 = false, bubbles: p4, capture: m3 } = t2, h3 = eh(), g3 = fm(typeof c2 == `function` ? c2 : () => false), _2 = typeof c2 == `function` ? g3 : c2, v3 = x.useRef(false), { escapeKey: y3, outsidePress: b3 } = $h(p4), { escapeKey: S3, outsidePress: C2 } = $h(m3), w3 = x.useRef(false), T3 = fm((e10) => { - if (!n2 || !o3 || !s3 || e10.key !== `Escape` || w3.current) return; - let t3 = a3.current.floatingContext?.nodeId, i4 = h3 ? em(h3.nodesRef.current, t3) : []; - if (!y3 && (e10.stopPropagation(), i4.length > 0)) { - let e11 = true; + let { open: n2, onOpenChange: r2, elements: i3, dataRef: a3 } = e38, { enabled: o3 = true, escapeKey: s3 = true, outsidePress: c3 = true, outsidePressEvent: l5 = `pointerdown`, referencePress: u3 = false, referencePressEvent: d3 = `pointerdown`, ancestorScroll: f4 = false, bubbles: p4, capture: m3 } = t2, h4 = kf(), g5 = Bd(typeof c3 == `function` ? c3 : () => false), _5 = typeof c3 == `function` ? g5 : c3, v5 = x.useRef(false), { escapeKey: y4, outsidePress: b2 } = Op(p4), { escapeKey: S2, outsidePress: C2 } = Op(m3), w2 = x.useRef(false), T2 = Bd((e39) => { + if (!n2 || !o3 || !s3 || e39.key !== `Escape` || w2.current) return; + let t3 = a3.current.floatingContext?.nodeId, i4 = h4 ? Od(h4.nodesRef.current, t3) : []; + if (!y4 && (e39.stopPropagation(), i4.length > 0)) { + let e40 = true; if (i4.forEach((t4) => { var n3; if ((n3 = t4.context) != null && n3.open && !t4.context.dataRef.current.__escapeKeyBubbles) { - e11 = false; + e40 = false; return; } - }), !e11) return; + }), !e40) return; } - r2(false, im(e10) ? e10.nativeEvent : e10, `escape-key`); - }), E3 = fm((e10) => { + r2(false, Md(e39) ? e39.nativeEvent : e39, `escape-key`); + }), E2 = Bd((e39) => { var t3; let n3 = () => { var t4; - T3(e10), (t4 = qp(e10)) == null || t4.removeEventListener(`keydown`, n3); + T2(e39), (t4 = xd(e39)) == null || t4.removeEventListener(`keydown`, n3); }; - (t3 = qp(e10)) == null || t3.addEventListener(`keydown`, n3); - }), D2 = fm((e10) => { + (t3 = xd(e39)) == null || t3.addEventListener(`keydown`, n3); + }), D2 = Bd((e39) => { let t3 = a3.current.insideReactTree; a3.current.insideReactTree = false; - let n3 = v3.current; - if (v3.current = false, l4 === `click` && n3 || t3 || typeof _2 == `function` && !_2(e10)) return; - let o4 = qp(e10), s4 = `[` + ih(`inert`) + `]`, c3 = Xp(i3.floating).querySelectorAll(s4), u4 = J(o4) ? o4 : null; - for (; u4 && !Qe(u4); ) { - let e11 = tt(u4); - if (Qe(e11) || !J(e11)) break; - u4 = e11; - } - if (c3.length && J(o4) && !Yp(o4) && !Kp(o4, i3.floating) && Array.from(c3).every((e11) => !Kp(u4, e11))) return; - if (Be(o4) && A3) { - let t4 = Qe(o4), n4 = $e(o4), r3 = /auto|scroll/, i4 = t4 || r3.test(n4.overflowX), a4 = t4 || r3.test(n4.overflowY), s5 = i4 && o4.clientWidth > 0 && o4.scrollWidth > o4.clientWidth, c4 = a4 && o4.clientHeight > 0 && o4.scrollHeight > o4.clientHeight, l5 = n4.direction === `rtl`, u5 = c4 && (l5 ? e10.offsetX <= o4.offsetWidth - o4.clientWidth : e10.offsetX > o4.clientWidth), d5 = s5 && e10.offsetY > o4.clientHeight; + let n3 = v5.current; + if (v5.current = false, l5 === `click` && n3 || t3 || typeof _5 == `function` && !_5(e39)) return; + let o4 = xd(e39), s4 = `[` + Nf(`inert`) + `]`, c4 = wd(i3.floating).querySelectorAll(s4), u4 = Re2(o4) ? o4 : null; + for (; u4 && !Ze(u4); ) { + let e40 = et(u4); + if (Ze(e40) || !Re2(e40)) break; + u4 = e40; + } + if (c4.length && Re2(o4) && !Cd(o4) && !bd(o4, i3.floating) && Array.from(c4).every((e40) => !bd(u4, e40))) return; + if (ze2(o4) && A2) { + let t4 = Ze(o4), n4 = Qe(o4), r3 = /auto|scroll/, i4 = t4 || r3.test(n4.overflowX), a4 = t4 || r3.test(n4.overflowY), s5 = i4 && o4.clientWidth > 0 && o4.scrollWidth > o4.clientWidth, c5 = a4 && o4.clientHeight > 0 && o4.scrollHeight > o4.clientHeight, l6 = n4.direction === `rtl`, u5 = c5 && (l6 ? e39.offsetX <= o4.offsetWidth - o4.clientWidth : e39.offsetX > o4.clientWidth), d5 = s5 && e39.offsetY > o4.clientHeight; if (u5 || d5) return; } - let d4 = a3.current.floatingContext?.nodeId, f5 = h3 && em(h3.nodesRef.current, d4).some((t4) => Jp(e10, t4.context?.elements.floating)); - if (Jp(e10, i3.floating) || Jp(e10, i3.domReference) || f5) return; - let p5 = h3 ? em(h3.nodesRef.current, d4) : []; + let d4 = a3.current.floatingContext?.nodeId, f5 = h4 && Od(h4.nodesRef.current, d4).some((t4) => Sd(e39, t4.context?.elements.floating)); + if (Sd(e39, i3.floating) || Sd(e39, i3.domReference) || f5) return; + let p5 = h4 ? Od(h4.nodesRef.current, d4) : []; if (p5.length > 0) { - let e11 = true; + let e40 = true; if (p5.forEach((t4) => { var n4; if ((n4 = t4.context) != null && n4.open && !t4.context.dataRef.current.__outsidePressBubbles) { - e11 = false; + e40 = false; return; } - }), !e11) return; + }), !e40) return; } - r2(false, e10, `outside-press`); - }), O3 = fm((e10) => { + r2(false, e39, `outside-press`); + }), O2 = Bd((e39) => { var t3; let n3 = () => { var t4; - D2(e10), (t4 = qp(e10)) == null || t4.removeEventListener(l4, n3); + D2(e39), (t4 = xd(e39)) == null || t4.removeEventListener(l5, n3); }; - (t3 = qp(e10)) == null || t3.addEventListener(l4, n3); + (t3 = xd(e39)) == null || t3.addEventListener(l5, n3); }); x.useEffect(() => { if (!n2 || !o3) return; - a3.current.__escapeKeyBubbles = y3, a3.current.__outsidePressBubbles = b3; - let e10 = -1; - function t3(e11) { - r2(false, e11, `ancestor-scroll`); + a3.current.__escapeKeyBubbles = y4, a3.current.__outsidePressBubbles = b2; + let e39 = -1; + function t3(e40) { + r2(false, e40, `ancestor-scroll`); } - function c3() { - window.clearTimeout(e10), w3.current = true; + function c4() { + window.clearTimeout(e39), w2.current = true; } function u4() { - e10 = window.setTimeout(() => { - w3.current = false; - }, Ze() ? 5 : 0); + e39 = window.setTimeout(() => { + w2.current = false; + }, Xe() ? 5 : 0); } - let d4 = Xp(i3.floating); - s3 && (d4.addEventListener(`keydown`, S3 ? E3 : T3, S3), d4.addEventListener(`compositionstart`, c3), d4.addEventListener(`compositionend`, u4)), _2 && d4.addEventListener(l4, C2 ? O3 : D2, C2); + let d4 = wd(i3.floating); + s3 && (d4.addEventListener(`keydown`, S2 ? E2 : T2, S2), d4.addEventListener(`compositionstart`, c4), d4.addEventListener(`compositionend`, u4)), _5 && d4.addEventListener(l5, C2 ? O2 : D2, C2); let p5 = []; - return f4 && (J(i3.domReference) && (p5 = rt(i3.domReference)), J(i3.floating) && (p5 = p5.concat(rt(i3.floating))), !J(i3.reference) && i3.reference && i3.reference.contextElement && (p5 = p5.concat(rt(i3.reference.contextElement)))), p5 = p5.filter((e11) => e11 !== d4.defaultView?.visualViewport), p5.forEach((e11) => { - e11.addEventListener(`scroll`, t3, { passive: true }); + return f4 && (Re2(i3.domReference) && (p5 = nt(i3.domReference)), Re2(i3.floating) && (p5 = p5.concat(nt(i3.floating))), !Re2(i3.reference) && i3.reference && i3.reference.contextElement && (p5 = p5.concat(nt(i3.reference.contextElement)))), p5 = p5.filter((e40) => e40 !== d4.defaultView?.visualViewport), p5.forEach((e40) => { + e40.addEventListener(`scroll`, t3, { passive: true }); }), () => { - s3 && (d4.removeEventListener(`keydown`, S3 ? E3 : T3, S3), d4.removeEventListener(`compositionstart`, c3), d4.removeEventListener(`compositionend`, u4)), _2 && d4.removeEventListener(l4, C2 ? O3 : D2, C2), p5.forEach((e11) => { - e11.removeEventListener(`scroll`, t3); - }), window.clearTimeout(e10); + s3 && (d4.removeEventListener(`keydown`, S2 ? E2 : T2, S2), d4.removeEventListener(`compositionstart`, c4), d4.removeEventListener(`compositionend`, u4)), _5 && d4.removeEventListener(l5, C2 ? O2 : D2, C2), p5.forEach((e40) => { + e40.removeEventListener(`scroll`, t3); + }), window.clearTimeout(e39); }; - }, [a3, i3, s3, _2, l4, n2, r2, f4, o3, y3, b3, T3, S3, E3, D2, C2, O3]), x.useEffect(() => { + }, [a3, i3, s3, _5, l5, n2, r2, f4, o3, y4, b2, T2, S2, E2, D2, C2, O2]), x.useEffect(() => { a3.current.insideReactTree = false; - }, [a3, _2, l4]); - let k4 = x.useMemo(() => ({ onKeyDown: T3, ...u3 && { [Zh[d3]]: (e10) => { - r2(false, e10.nativeEvent, `reference-press`); - }, ...d3 !== `click` && { onClick(e10) { - r2(false, e10.nativeEvent, `reference-press`); - } } } }), [T3, r2, u3, d3]), A3 = x.useMemo(() => ({ onKeyDown: T3, onMouseDown() { - v3.current = true; + }, [a3, _5, l5]); + let k2 = x.useMemo(() => ({ onKeyDown: T2, ...u3 && { [Ep[d3]]: (e39) => { + r2(false, e39.nativeEvent, `reference-press`); + }, ...d3 !== `click` && { onClick(e39) { + r2(false, e39.nativeEvent, `reference-press`); + } } } }), [T2, r2, u3, d3]), A2 = x.useMemo(() => ({ onKeyDown: T2, onMouseDown() { + v5.current = true; }, onMouseUp() { - v3.current = true; - }, [Qh[l4]]: () => { + v5.current = true; + }, [Dp[l5]]: () => { a3.current.insideReactTree = true; - } }), [T3, l4, a3]); - return x.useMemo(() => o3 ? { reference: k4, floating: A3 } : {}, [o3, k4, A3]); + } }), [T2, l5, a3]); + return x.useMemo(() => o3 ? { reference: k2, floating: A2 } : {}, [o3, k2, A2]); } -function tg(e9) { - let { open: t2 = false, onOpenChange: n2, elements: r2 } = e9, i3 = Ym(), a3 = x.useRef({}), [o3] = x.useState(() => Xm()), s3 = $m() != null, [c2, l4] = x.useState(r2.reference), u3 = fm((e10, t3, r3) => { - a3.current.openEvent = e10 ? t3 : void 0, o3.emit(`openchange`, { open: e10, event: t3, reason: r3, nested: s3 }), n2?.(e10, t3, r3); - }), d3 = x.useMemo(() => ({ setPositionReference: l4 }), []), f4 = x.useMemo(() => ({ reference: c2 || r2.reference || null, floating: r2.floating || null, domReference: r2.reference }), [c2, r2.reference, r2.floating]); +function Ap(e38) { + let { open: t2 = false, onOpenChange: n2, elements: r2 } = e38, i3 = wf(), a3 = x.useRef({}), [o3] = x.useState(() => Tf()), s3 = Of() != null, [c3, l5] = x.useState(r2.reference), u3 = Bd((e39, t3, r3) => { + a3.current.openEvent = e39 ? t3 : void 0, o3.emit(`openchange`, { open: e39, event: t3, reason: r3, nested: s3 }), n2?.(e39, t3, r3); + }), d3 = x.useMemo(() => ({ setPositionReference: l5 }), []), f4 = x.useMemo(() => ({ reference: c3 || r2.reference || null, floating: r2.floating || null, domReference: r2.reference }), [c3, r2.reference, r2.floating]); return x.useMemo(() => ({ dataRef: a3, open: t2, onOpenChange: u3, elements: f4, events: o3, floatingId: i3, refs: d3 }), [t2, u3, f4, o3, i3, d3]); } -function ng(e9) { - e9 === void 0 && (e9 = {}); - let { nodeId: t2 } = e9, n2 = tg({ ...e9, elements: { reference: null, floating: null, ...e9.elements } }), r2 = e9.rootContext || n2, i3 = r2.elements, [a3, o3] = x.useState(null), [s3, c2] = x.useState(null), l4 = i3?.domReference || a3, u3 = x.useRef(null), d3 = eh(); - cm(() => { - l4 && (u3.current = l4); - }, [l4]); - let f4 = xo({ ...e9, elements: { ...i3, ...s3 && { reference: s3 } } }), p4 = x.useCallback((e10) => { - let t3 = J(e10) ? { getBoundingClientRect: () => e10.getBoundingClientRect(), getClientRects: () => e10.getClientRects(), contextElement: e10 } : e10; - c2(t3), f4.refs.setReference(t3); - }, [f4.refs]), m3 = x.useCallback((e10) => { - (J(e10) || e10 === null) && (u3.current = e10, o3(e10)), (J(f4.refs.reference.current) || f4.refs.reference.current === null || e10 !== null && !J(e10)) && f4.refs.setReference(e10); - }, [f4.refs]), h3 = x.useMemo(() => ({ ...f4.refs, setReference: m3, setPositionReference: p4, domReference: u3 }), [f4.refs, m3, p4]), g3 = x.useMemo(() => ({ ...f4.elements, domReference: l4 }), [f4.elements, l4]), _2 = x.useMemo(() => ({ ...f4, ...r2, refs: h3, elements: g3, nodeId: t2 }), [f4, h3, g3, t2, r2]); - return cm(() => { - r2.dataRef.current.floatingContext = _2; - let e10 = d3?.nodesRef.current.find((e11) => e11.id === t2); - e10 && (e10.context = _2); - }), x.useMemo(() => ({ ...f4, context: _2, refs: h3, elements: g3 }), [f4, h3, g3, _2]); -} -function rg(e9, t2, n2) { - let r2 = /* @__PURE__ */ new Map(), i3 = n2 === `item`, a3 = e9; - if (i3 && e9) { - let { [Im]: t3, [Lm]: n3, ...r3 } = e9; +function jp(e38) { + e38 === void 0 && (e38 = {}); + let { nodeId: t2 } = e38, n2 = Ap({ ...e38, elements: { reference: null, floating: null, ...e38.elements } }), r2 = e38.rootContext || n2, i3 = r2.elements, [a3, o3] = x.useState(null), [s3, c3] = x.useState(null), l5 = i3?.domReference || a3, u3 = x.useRef(null), d3 = kf(); + Id(() => { + l5 && (u3.current = l5); + }, [l5]); + let f4 = ic({ ...e38, elements: { ...i3, ...s3 && { reference: s3 } } }), p4 = x.useCallback((e39) => { + let t3 = Re2(e39) ? { getBoundingClientRect: () => e39.getBoundingClientRect(), getClientRects: () => e39.getClientRects(), contextElement: e39 } : e39; + c3(t3), f4.refs.setReference(t3); + }, [f4.refs]), m3 = x.useCallback((e39) => { + (Re2(e39) || e39 === null) && (u3.current = e39, o3(e39)), (Re2(f4.refs.reference.current) || f4.refs.reference.current === null || e39 !== null && !Re2(e39)) && f4.refs.setReference(e39); + }, [f4.refs]), h4 = x.useMemo(() => ({ ...f4.refs, setReference: m3, setPositionReference: p4, domReference: u3 }), [f4.refs, m3, p4]), g5 = x.useMemo(() => ({ ...f4.elements, domReference: l5 }), [f4.elements, l5]), _5 = x.useMemo(() => ({ ...f4, ...r2, refs: h4, elements: g5, nodeId: t2 }), [f4, h4, g5, t2, r2]); + return Id(() => { + r2.dataRef.current.floatingContext = _5; + let e39 = d3?.nodesRef.current.find((e40) => e40.id === t2); + e39 && (e39.context = _5); + }), x.useMemo(() => ({ ...f4, context: _5, refs: h4, elements: g5 }), [f4, h4, g5, _5]); +} +function Mp(e38, t2, n2) { + let r2 = /* @__PURE__ */ new Map(), i3 = n2 === `item`, a3 = e38; + if (i3 && e38) { + let { [df]: t3, [ff]: n3, ...r3 } = e38; a3 = r3; } - return { ...n2 === `floating` && { tabIndex: -1, [Fm]: `` }, ...a3, ...t2.map((t3) => { + return { ...n2 === `floating` && { tabIndex: -1, [uf]: `` }, ...a3, ...t2.map((t3) => { let r3 = t3 ? t3[n2] : null; - return typeof r3 == `function` ? e9 ? r3(e9) : null : r3; - }).concat(e9).reduce((e10, t3) => (t3 && Object.entries(t3).forEach((t4) => { + return typeof r3 == `function` ? e38 ? r3(e38) : null : r3; + }).concat(e38).reduce((e39, t3) => (t3 && Object.entries(t3).forEach((t4) => { let [n3, a4] = t4; - if (!(i3 && [Im, Lm].includes(n3))) { + if (!(i3 && [df, ff].includes(n3))) { if (n3.indexOf(`on`) === 0) { if (r2.has(n3) || r2.set(n3, []), typeof a4 == `function`) { var o3; - (o3 = r2.get(n3)) == null || o3.push(a4), e10[n3] = function() { - var e11 = [...arguments]; - return r2.get(n3)?.map((t5) => t5(...e11)).find((e12) => e12 !== void 0); + (o3 = r2.get(n3)) == null || o3.push(a4), e39[n3] = function() { + var e40 = [...arguments]; + return r2.get(n3)?.map((t5) => t5(...e40)).find((e41) => e41 !== void 0); }; } - } else e10[n3] = a4; + } else e39[n3] = a4; } - }), e10), {}) }; + }), e39), {}) }; } -function ig(e9) { - e9 === void 0 && (e9 = []); - let t2 = e9.map((e10) => e10?.reference), n2 = e9.map((e10) => e10?.floating), r2 = e9.map((e10) => e10?.item), i3 = x.useCallback((t3) => rg(t3, e9, `reference`), t2), a3 = x.useCallback((t3) => rg(t3, e9, `floating`), n2), o3 = x.useCallback((t3) => rg(t3, e9, `item`), r2); +function Np(e38) { + e38 === void 0 && (e38 = []); + let t2 = e38.map((e39) => e39?.reference), n2 = e38.map((e39) => e39?.floating), r2 = e38.map((e39) => e39?.item), i3 = x.useCallback((t3) => Mp(t3, e38, `reference`), t2), a3 = x.useCallback((t3) => Mp(t3, e38, `floating`), n2), o3 = x.useCallback((t3) => Mp(t3, e38, `item`), r2); return x.useMemo(() => ({ getReferenceProps: i3, getFloatingProps: a3, getItemProps: o3 }), [i3, a3, o3]); } -var fg = /* @__PURE__ */ new Map([[`select`, `listbox`], [`combobox`, `listbox`], [`label`, false]]); -function pg(e9, t2) { +var Pp = `Escape`; +function Fp(e38, t2, n2) { + switch (e38) { + case `vertical`: + return t2; + case `horizontal`: + return n2; + default: + return t2 || n2; + } +} +function Ip(e38, t2) { + return Fp(t2, e38 === hf || e38 === gf, e38 === pf || e38 === mf); +} +function Lp(e38, t2, n2) { + return Fp(t2, e38 === gf, n2 ? e38 === pf : e38 === mf) || e38 === `Enter` || e38 === ` ` || e38 === ``; +} +function Rp(e38, t2, n2) { + return Fp(t2, n2 ? e38 === pf : e38 === mf, e38 === gf); +} +function zp(e38, t2, n2, r2) { + return t2 === `both` || t2 === `horizontal` && r2 && r2 > 1 ? e38 === Pp : Fp(t2, n2 ? e38 === mf : e38 === pf, e38 === hf); +} +function Bp(e38, t2) { + let { open: n2, onOpenChange: r2, elements: i3, floatingId: a3 } = e38, { listRef: o3, activeIndex: s3, onNavigate: c3 = () => { + }, enabled: l5 = true, selectedIndex: u3 = null, allowEscape: d3 = false, loop: f4 = false, nested: p4 = false, rtl: m3 = false, virtual: h4 = false, focusItemOnOpen: g5 = `auto`, focusItemOnHover: _5 = true, openOnArrowKeyDown: v5 = true, disabledIndices: y4 = void 0, orientation: b2 = `vertical`, parentOrientation: S2, cols: C2 = 1, scrollItemIntoView: w2 = true, virtualItemRef: T2, itemSizes: E2, dense: D2 = false } = t2, O2 = Rd(Dd(i3.floating)), k2 = Of(), A2 = kf(); + Id(() => { + e38.dataRef.current.orientation = b2; + }, [e38, b2]); + let j2 = Bd(() => { + c3(P3.current === -1 ? null : P3.current); + }), M2 = Ed(i3.domReference), N3 = x.useRef(g5), P3 = x.useRef(u3 ?? -1), F2 = x.useRef(null), I2 = x.useRef(true), L3 = x.useRef(j2), R3 = x.useRef(!!i3.floating), z2 = x.useRef(n2), ee2 = x.useRef(false), B3 = x.useRef(false), V3 = Rd(y4), H3 = Rd(n2), U3 = Rd(w2), W3 = Rd(u3), [G2, te2] = x.useState(), [K4, ne3] = x.useState(), q4 = Bd(() => { + function e39(e40) { + if (h4) { + var t4; + (t4 = e40.id) != null && t4.endsWith(`-fui-option`) && (e40.id = a3 + `-` + Math.random().toString(16).slice(2, 10)), te2(e40.id), A2?.events.emit(`virtualfocus`, e40), T2 && (T2.current = e40); + } else Bf(e40, { sync: ee2.current, preventScroll: true }); + } + let t3 = o3.current[P3.current], n3 = B3.current; + t3 && e39(t3), (ee2.current ? (e40) => e40() : requestAnimationFrame)(() => { + let r3 = o3.current[P3.current] || t3; + if (!r3) return; + t3 || e39(r3); + let i4 = U3.current; + i4 && ie3 && (n3 || !I2.current) && (r3.scrollIntoView == null || r3.scrollIntoView(typeof i4 == `boolean` ? { block: `nearest`, inline: `nearest` } : i4)); + }); + }); + Id(() => { + l5 && (n2 && i3.floating ? N3.current && u3 != null && (B3.current = true, P3.current = u3, j2()) : R3.current && (P3.current = -1, L3.current())); + }, [l5, n2, i3.floating, u3, j2]), Id(() => { + if (l5 && n2 && i3.floating) { + if (s3 == null) { + if (ee2.current = false, W3.current != null) return; + if (R3.current && (P3.current = -1, q4()), (!z2.current || !R3.current) && N3.current && (F2.current != null || N3.current === true && F2.current == null)) { + let e39 = 0, t3 = () => { + o3.current[0] == null ? (e39 < 2 && (e39 ? requestAnimationFrame : queueMicrotask)(t3), e39++) : (P3.current = F2.current == null || Lp(F2.current, b2, m3) || p4 ? Ud(o3, V3.current) : Wd(o3, V3.current), F2.current = null, j2()); + }; + t3(); + } + } else Hd(o3, s3) || (P3.current = s3, q4(), B3.current = false); + } + }, [l5, n2, i3.floating, s3, W3, p4, o3, b2, m3, j2, q4, V3]), Id(() => { + var e39; + if (!l5 || i3.floating || !A2 || h4 || !R3.current) return; + let t3 = A2.nodesRef.current, n3 = (e39 = t3.find((e40) => e40.id === k2)) == null || (e39 = e39.context) == null ? void 0 : e39.elements.floating, r3 = yd(wd(i3.floating)), a4 = t3.some((e40) => e40.context && bd(e40.context.elements.floating, r3)); + n3 && !a4 && I2.current && n3.focus({ preventScroll: true }); + }, [l5, i3.floating, A2, k2, h4]), Id(() => { + if (!l5 || !A2 || !h4 || k2) return; + function e39(e40) { + ne3(e40.id), T2 && (T2.current = e40); + } + return A2.events.on(`virtualfocus`, e39), () => { + A2.events.off(`virtualfocus`, e39); + }; + }, [l5, A2, h4, k2, T2]), Id(() => { + L3.current = j2, z2.current = n2, R3.current = !!i3.floating; + }), Id(() => { + n2 || (F2.current = null, N3.current = g5); + }, [n2, g5]); + let re3 = s3 != null, ie3 = x.useMemo(() => { + function e39(e40) { + if (!H3.current) return; + let t3 = o3.current.indexOf(e40); + t3 !== -1 && P3.current !== t3 && (P3.current = t3, j2()); + } + return { onFocus(t3) { + let { currentTarget: n3 } = t3; + ee2.current = true, e39(n3); + }, onClick: (e40) => { + let { currentTarget: t3 } = e40; + return t3.focus({ preventScroll: true }); + }, onMouseMove(t3) { + let { currentTarget: n3 } = t3; + ee2.current = true, B3.current = false, _5 && e39(n3); + }, onPointerLeave(e40) { + let { pointerType: t3 } = e40; + if (I2.current && t3 !== `touch` && (ee2.current = true, _5 && (P3.current = -1, j2(), !h4))) { + var n3; + (n3 = O2.current) == null || n3.focus({ preventScroll: true }); + } + } }; + }, [H3, O2, _5, o3, j2, h4]), ae3 = x.useCallback(() => { + var e39; + return S2 ?? (A2 == null || (e39 = A2.nodesRef.current.find((e40) => e40.id === k2)) == null || (e39 = e39.context) == null || (e39 = e39.dataRef) == null ? void 0 : e39.current.orientation); + }, [k2, A2, S2]), oe5 = Bd((e39) => { + if (I2.current = false, ee2.current = true, e39.which === 229 || !H3.current && e39.currentTarget === O2.current) return; + if (p4 && zp(e39.key, b2, m3, C2)) { + Ip(e39.key, ae3()) || jd(e39), r2(false, e39.nativeEvent, `list-navigation`), ze2(i3.domReference) && (h4 ? A2?.events.emit(`virtualfocus`, i3.domReference) : i3.domReference.focus()); + return; + } + let t3 = P3.current, a4 = Ud(o3, y4), s4 = Wd(o3, y4); + if (M2 || (e39.key === `Home` && (jd(e39), P3.current = a4, j2()), e39.key === `End` && (jd(e39), P3.current = s4, j2())), C2 > 1) { + let t4 = E2 || Array.from({ length: o3.current.length }, () => ({ width: 1, height: 1 })), n3 = qd(t4, C2, D2), r3 = n3.findIndex((e40) => e40 != null && !Xd(o3, e40, y4)), i4 = n3.reduce((e40, t5, n4) => t5 != null && !Xd(o3, t5, y4) ? n4 : e40, -1), c4 = n3[Kd({ current: n3.map((e40) => e40 == null ? null : o3.current[e40]) }, { event: e39, orientation: b2, loop: f4, rtl: m3, cols: C2, disabledIndices: Yd([...(typeof y4 == `function` ? null : y4) || o3.current.map((e40, t5) => Xd(o3, t5, y4) ? t5 : void 0), void 0], n3), minIndex: r3, maxIndex: i4, prevIndex: Jd(P3.current > s4 ? a4 : P3.current, t4, n3, C2, e39.key === gf ? `bl` : e39.key === (m3 ? pf : mf) ? `tr` : `tl`), stopEvent: true })]; + if (c4 != null && (P3.current = c4, j2()), b2 === `both`) return; + } + if (Ip(e39.key, b2)) { + if (jd(e39), n2 && !h4 && yd(e39.currentTarget.ownerDocument) === e39.currentTarget) { + P3.current = Lp(e39.key, b2, m3) ? a4 : s4, j2(); + return; + } + Lp(e39.key, b2, m3) ? f4 ? P3.current = t3 >= s4 ? d3 && t3 !== o3.current.length ? -1 : a4 : Gd(o3, { startingIndex: t3, disabledIndices: y4 }) : P3.current = Math.min(s4, Gd(o3, { startingIndex: t3, disabledIndices: y4 })) : f4 ? P3.current = t3 <= a4 ? d3 && t3 !== -1 ? o3.current.length : s4 : Gd(o3, { startingIndex: t3, decrement: true, disabledIndices: y4 }) : P3.current = Math.max(a4, Gd(o3, { startingIndex: t3, decrement: true, disabledIndices: y4 })), Hd(o3, P3.current) && (P3.current = -1), j2(); + } + }), se5 = x.useMemo(() => h4 && n2 && re3 && { "aria-activedescendant": K4 || G2 }, [h4, n2, re3, K4, G2]), J4 = x.useMemo(() => ({ "aria-orientation": b2 === `both` ? void 0 : b2, ...M2 ? {} : se5, onKeyDown: oe5, onPointerMove() { + I2.current = true; + } }), [se5, oe5, b2, M2]), ce6 = x.useMemo(() => { + function e39(e40) { + g5 === `auto` && Nd(e40.nativeEvent) && (N3.current = true); + } + function t3(e40) { + N3.current = g5, g5 === `auto` && Pd(e40.nativeEvent) && (N3.current = true); + } + return { ...se5, onKeyDown(e40) { + I2.current = false; + let t4 = e40.key.startsWith(`Arrow`), i4 = [`Home`, `End`].includes(e40.key), a4 = t4 || i4, s4 = Rp(e40.key, b2, m3), c4 = zp(e40.key, b2, m3, C2), l6 = Rp(e40.key, ae3(), m3), d4 = Ip(e40.key, b2), f5 = (p4 ? l6 : d4) || e40.key === `Enter` || e40.key.trim() === ``; + if (h4 && n2) { + let t5 = A2?.nodesRef.current.find((e41) => e41.parentId == null), n3 = A2 && t5 ? kd(A2.nodesRef.current, t5.id) : null; + if (a4 && n3 && T2) { + let t6 = new KeyboardEvent(`keydown`, { key: e40.key, bubbles: true }); + if (s4 || c4) { + let r3 = n3.context?.elements.domReference === e40.currentTarget, i5 = c4 && !r3 ? n3.context?.elements.domReference : s4 ? o3.current.find((e41) => e41?.id === G2) : null; + i5 && (jd(e40), i5.dispatchEvent(t6), ne3(void 0)); + } + if ((d4 || i4) && n3.context && n3.context.open && n3.parentId && e40.currentTarget !== n3.context.elements.domReference) { + var g6; + jd(e40), (g6 = n3.context.elements.domReference) == null || g6.dispatchEvent(t6); + return; + } + } + return oe5(e40); + } + if (n2 || v5 || !t4) { + if (f5) { + let t5 = Ip(e40.key, ae3()); + F2.current = p4 && t5 ? null : e40.key; + } + if (p4) { + l6 && (jd(e40), n2 ? (P3.current = Ud(o3, V3.current), j2()) : r2(true, e40.nativeEvent, `list-navigation`)); + return; + } + d4 && (u3 != null && (P3.current = u3), jd(e40), !n2 && v5 ? r2(true, e40.nativeEvent, `list-navigation`) : oe5(e40), n2 && j2()); + } + }, onFocus() { + n2 && !h4 && (P3.current = -1, j2()); + }, onPointerDown: t3, onPointerEnter: t3, onMouseDown: e39, onClick: e39 }; + }, [G2, se5, C2, oe5, V3, g5, o3, p4, j2, r2, n2, v5, b2, ae3, m3, u3, A2, h4, T2]); + return x.useMemo(() => l5 ? { reference: ce6, floating: J4, item: ie3 } : {}, [l5, ce6, J4, ie3]); +} +var Vp = /* @__PURE__ */ new Map([[`select`, `listbox`], [`combobox`, `listbox`], [`label`, false]]); +function Hp(e38, t2) { t2 === void 0 && (t2 = {}); - let { open: n2, elements: r2, floatingId: i3 } = e9, { enabled: a3 = true, role: o3 = `dialog` } = t2, s3 = Ym(), c2 = r2.domReference?.id || s3, l4 = x.useMemo(() => $p(r2.floating)?.id || i3, [r2.floating, i3]), u3 = fg.get(o3) ?? o3, d3 = $m() != null, f4 = x.useMemo(() => u3 === `tooltip` || o3 === `label` ? { [`aria-` + (o3 === `label` ? `labelledby` : `describedby`)]: n2 ? l4 : void 0 } : { "aria-expanded": n2 ? `true` : `false`, "aria-haspopup": u3 === `alertdialog` ? `dialog` : u3, "aria-controls": n2 ? l4 : void 0, ...u3 === `listbox` && { role: `combobox` }, ...u3 === `menu` && { id: c2 }, ...u3 === `menu` && d3 && { role: `menuitem` }, ...o3 === `select` && { "aria-autocomplete": `none` }, ...o3 === `combobox` && { "aria-autocomplete": `list` } }, [u3, l4, d3, n2, c2, o3]), p4 = x.useMemo(() => { - let e10 = { id: l4, ...u3 && { role: u3 } }; - return u3 === `tooltip` || o3 === `label` ? e10 : { ...e10, ...u3 === `menu` && { "aria-labelledby": c2 } }; - }, [u3, l4, c2, o3]), m3 = x.useCallback((e10) => { - let { active: t3, selected: n3 } = e10, r3 = { role: `option`, ...t3 && { id: l4 + `-fui-option` } }; + let { open: n2, elements: r2, floatingId: i3 } = e38, { enabled: a3 = true, role: o3 = `dialog` } = t2, s3 = wf(), c3 = r2.domReference?.id || s3, l5 = x.useMemo(() => Dd(r2.floating)?.id || i3, [r2.floating, i3]), u3 = Vp.get(o3) ?? o3, d3 = Of() != null, f4 = x.useMemo(() => u3 === `tooltip` || o3 === `label` ? { [`aria-` + (o3 === `label` ? `labelledby` : `describedby`)]: n2 ? l5 : void 0 } : { "aria-expanded": n2 ? `true` : `false`, "aria-haspopup": u3 === `alertdialog` ? `dialog` : u3, "aria-controls": n2 ? l5 : void 0, ...u3 === `listbox` && { role: `combobox` }, ...u3 === `menu` && { id: c3 }, ...u3 === `menu` && d3 && { role: `menuitem` }, ...o3 === `select` && { "aria-autocomplete": `none` }, ...o3 === `combobox` && { "aria-autocomplete": `list` } }, [u3, l5, d3, n2, c3, o3]), p4 = x.useMemo(() => { + let e39 = { id: l5, ...u3 && { role: u3 } }; + return u3 === `tooltip` || o3 === `label` ? e39 : { ...e39, ...u3 === `menu` && { "aria-labelledby": c3 } }; + }, [u3, l5, c3, o3]), m3 = x.useCallback((e39) => { + let { active: t3, selected: n3 } = e39, r3 = { role: `option`, ...t3 && { id: l5 + `-fui-option` } }; switch (o3) { case `select`: case `combobox`: return { ...r3, "aria-selected": n3 }; } return {}; - }, [l4, o3]); + }, [l5, o3]); return x.useMemo(() => a3 ? { reference: f4, floating: p4, item: m3 } : {}, [a3, f4, p4, m3]); } -function gg(e9, t2) { - let [n2, r2] = x.useState(e9); - return e9 && !n2 && r2(true), x.useEffect(() => { - if (!e9 && n2) { - let e10 = setTimeout(() => r2(false), t2); - return () => clearTimeout(e10); - } - }, [e9, n2, t2]), n2; +var Up = (e38) => e38.replace(/[A-Z]+(?![a-z])|[A-Z]/g, (e39, t2) => (t2 ? `-` : ``) + e39.toLowerCase()); +function Wp(e38, t2) { + return typeof e38 == `function` ? e38(t2) : e38; +} +function Gp(e38, t2) { + let [n2, r2] = x.useState(e38); + return e38 && !n2 && r2(true), x.useEffect(() => { + if (!e38 && n2) { + let e39 = setTimeout(() => r2(false), t2); + return () => clearTimeout(e39); + } + }, [e38, n2, t2]), n2; +} +function Kp(e38, t2) { + t2 === void 0 && (t2 = {}); + let { open: n2, elements: { floating: r2 } } = e38, { duration: i3 = 250 } = t2, a3 = (typeof i3 == `number` ? i3 : i3.close) || 0, [o3, s3] = x.useState(`unmounted`), c3 = Gp(n2, a3); + return !c3 && o3 === `close` && s3(`unmounted`), Id(() => { + if (r2) { + if (n2) { + s3(`initial`); + let e39 = requestAnimationFrame(() => { + Ei.flushSync(() => { + s3(`open`); + }); + }); + return () => { + cancelAnimationFrame(e39); + }; + } + s3(`close`); + } + }, [n2, r2]), { isMounted: c3, status: o3 }; +} +function qp(e38, t2) { + t2 === void 0 && (t2 = {}); + let { initial: n2 = { opacity: 0 }, open: r2, close: i3, common: a3, duration: o3 = 250 } = t2, s3 = e38.placement, c3 = s3.split(`-`)[0], l5 = x.useMemo(() => ({ side: c3, placement: s3 }), [c3, s3]), u3 = typeof o3 == `number`, d3 = (u3 ? o3 : o3.open) || 0, f4 = (u3 ? o3 : o3.close) || 0, [p4, m3] = x.useState(() => ({ ...Wp(a3, l5), ...Wp(n2, l5) })), { isMounted: h4, status: g5 } = Kp(e38, { duration: o3 }), _5 = Rd(n2), v5 = Rd(r2), y4 = Rd(i3), b2 = Rd(a3); + return Id(() => { + let e39 = Wp(_5.current, l5), t3 = Wp(y4.current, l5), n3 = Wp(b2.current, l5), r3 = Wp(v5.current, l5) || Object.keys(e39).reduce((e40, t4) => (e40[t4] = ``, e40), {}); + if (g5 === `initial` && m3((t4) => ({ transitionProperty: t4.transitionProperty, ...n3, ...e39 })), g5 === `open` && m3({ transitionProperty: Object.keys(r3).map(Up).join(`,`), transitionDuration: d3 + `ms`, ...n3, ...r3 }), g5 === `close`) { + let r4 = t3 || e39; + m3({ transitionProperty: Object.keys(r4).map(Up).join(`,`), transitionDuration: f4 + `ms`, ...n3, ...r4 }); + } + }, [f4, y4, _5, v5, b2, d3, g5, l5]), { isMounted: h4, styles: p4 }; +} +function Jp(e38, t2) { + let { open: n2, dataRef: r2 } = e38, { listRef: i3, activeIndex: a3, onMatch: o3, onTypingChange: s3, enabled: c3 = true, findMatch: l5 = null, resetMs: u3 = 750, ignoreKeys: d3 = [], selectedIndex: f4 = null } = t2, p4 = x.useRef(-1), m3 = x.useRef(``), h4 = x.useRef(f4 ?? a3 ?? -1), g5 = x.useRef(null), _5 = Bd(o3), v5 = Bd(s3), y4 = Rd(l5), b2 = Rd(d3); + Id(() => { + n2 && (Pf(p4), g5.current = null, m3.current = ``); + }, [n2]), Id(() => { + n2 && m3.current === `` && (h4.current = f4 ?? a3 ?? -1); + }, [n2, f4, a3]); + let S2 = Bd((e39) => { + e39 ? r2.current.typing || (r2.current.typing = e39, v5(e39)) : r2.current.typing && (r2.current.typing = e39, v5(e39)); + }), C2 = Bd((e39) => { + function t3(e40, t4, n3) { + let r4 = y4.current ? y4.current(t4, n3) : t4.find((e41) => e41?.toLocaleLowerCase().indexOf(n3.toLocaleLowerCase()) === 0); + return r4 ? e40.indexOf(r4) : -1; + } + let r3 = i3.current; + if (m3.current.length > 0 && m3.current[0] !== ` ` && (t3(r3, r3, m3.current) === -1 ? S2(false) : e39.key === ` ` && jd(e39)), r3 == null || b2.current.includes(e39.key) || e39.key.length !== 1 || e39.ctrlKey || e39.metaKey || e39.altKey) return; + n2 && e39.key !== ` ` && (jd(e39), S2(true)), r3.every((e40) => !e40 || e40[0]?.toLocaleLowerCase() !== e40[1]?.toLocaleLowerCase()) && m3.current === e39.key && (m3.current = ``, h4.current = g5.current), m3.current += e39.key, Pf(p4), p4.current = window.setTimeout(() => { + m3.current = ``, h4.current = g5.current, S2(false); + }, u3); + let a4 = h4.current, o4 = t3(r3, [...r3.slice((a4 || 0) + 1), ...r3.slice(0, (a4 || 0) + 1)], m3.current); + o4 === -1 ? e39.key !== ` ` && (m3.current = ``, S2(false)) : (_5(o4), g5.current = o4); + }), w2 = x.useMemo(() => ({ onKeyDown: C2 }), [C2]), T2 = x.useMemo(() => ({ onKeyDown: C2, onKeyUp(e39) { + e39.key === ` ` && S2(false); + } }), [C2, S2]); + return x.useMemo(() => c3 ? { reference: w2, floating: T2 } : {}, [c3, w2, T2]); +} +function Yp(e38, t2, n2) { + return n2 === void 0 && (n2 = true), e38.filter((e39) => e39.parentId === t2 && (!n2 || e39.context?.open)).flatMap((t3) => [t3, ...Yp(e38, t3.id, n2)]); +} +function Xp(e38, t2) { + let [n2, r2] = e38, i3 = false, a3 = t2.length; + for (let e39 = 0, o3 = a3 - 1; e39 < a3; o3 = e39++) { + let [a4, s3] = t2[e39] || [0, 0], [c3, l5] = t2[o3] || [0, 0]; + s3 >= r2 != l5 >= r2 && n2 <= (c3 - a4) * (r2 - s3) / (l5 - s3) + a4 && (i3 = !i3); + } + return i3; +} +function Zp(e38, t2) { + return e38[0] >= t2.x && e38[0] <= t2.x + t2.width && e38[1] >= t2.y && e38[1] <= t2.y + t2.height; +} +function Qp(e38) { + e38 === void 0 && (e38 = {}); + let { buffer: t2 = 0.5, blockPointerEvents: n2 = false, requireIntent: r2 = true } = e38, i3 = { current: -1 }, a3 = false, o3 = null, s3 = null, c3 = typeof performance2 < `u` ? performance2.now() : 0; + function l5(e39, t3) { + let n3 = performance2.now(), r3 = n3 - c3; + if (o3 === null || s3 === null || r3 === 0) return o3 = e39, s3 = t3, c3 = n3, null; + let i4 = e39 - o3, a4 = t3 - s3, l6 = Math.sqrt(i4 * i4 + a4 * a4) / r3; + return o3 = e39, s3 = t3, c3 = n3, l6; + } + let u3 = (e39) => { + let { x: n3, y: o4, placement: s4, elements: c4, onClose: u4, nodeId: d3, tree: f4 } = e39; + return function(e40) { + function p4() { + Pf(i3), u4(); + } + if (Pf(i3), !c4.domReference || !c4.floating || s4 == null || n3 == null || o4 == null) return; + let { clientX: m3, clientY: h4 } = e40, g5 = [m3, h4], _5 = Hf(e40), v5 = e40.type === `mouseleave`, y4 = Vf(c4.floating, _5), b2 = Vf(c4.domReference, _5), x2 = c4.domReference.getBoundingClientRect(), S2 = c4.floating.getBoundingClientRect(), C2 = s4.split(`-`)[0], w2 = n3 > S2.right - S2.width / 2, T2 = o4 > S2.bottom - S2.height / 2, E2 = Zp(g5, x2), D2 = S2.width > x2.width, O2 = S2.height > x2.height, k2 = (D2 ? x2 : S2).left, A2 = (D2 ? x2 : S2).right, j2 = (O2 ? x2 : S2).top, M2 = (O2 ? x2 : S2).bottom; + if (y4 && (a3 = true, !v5)) return; + if (b2 && (a3 = false), b2 && !v5) { + a3 = true; + return; + } + if (v5 && Re2(e40.relatedTarget) && Vf(c4.floating, e40.relatedTarget) || f4 && Yp(f4.nodesRef.current, d3).length) return; + if (C2 === `top` && o4 >= x2.bottom - 1 || C2 === `bottom` && o4 <= x2.top + 1 || C2 === `left` && n3 >= x2.right - 1 || C2 === `right` && n3 <= x2.left + 1) return p4(); + let N3 = []; + switch (C2) { + case `top`: + N3 = [[k2, x2.top + 1], [k2, S2.bottom - 1], [A2, S2.bottom - 1], [A2, x2.top + 1]]; + break; + case `bottom`: + N3 = [[k2, S2.top + 1], [k2, x2.bottom - 1], [A2, x2.bottom - 1], [A2, S2.top + 1]]; + break; + case `left`: + N3 = [[S2.right - 1, M2], [S2.right - 1, j2], [x2.left + 1, j2], [x2.left + 1, M2]]; + break; + case `right`: + N3 = [[x2.right - 1, M2], [x2.right - 1, j2], [S2.left + 1, j2], [S2.left + 1, M2]]; + } + function P3(e41) { + let [n4, r3] = e41; + switch (C2) { + case `top`: + return [[D2 ? n4 + t2 / 2 : w2 ? n4 + t2 * 4 : n4 - t2 * 4, r3 + t2 + 1], [D2 ? n4 - t2 / 2 : w2 ? n4 + t2 * 4 : n4 - t2 * 4, r3 + t2 + 1], [S2.left, w2 || D2 ? S2.bottom - t2 : S2.top], [S2.right, w2 ? D2 ? S2.bottom - t2 : S2.top : S2.bottom - t2]]; + case `bottom`: + return [[D2 ? n4 + t2 / 2 : w2 ? n4 + t2 * 4 : n4 - t2 * 4, r3 - t2], [D2 ? n4 - t2 / 2 : w2 ? n4 + t2 * 4 : n4 - t2 * 4, r3 - t2], [S2.left, w2 || D2 ? S2.top + t2 : S2.bottom], [S2.right, w2 ? D2 ? S2.top + t2 : S2.bottom : S2.top + t2]]; + case `left`: { + let e42 = [n4 + t2 + 1, O2 ? r3 + t2 / 2 : T2 ? r3 + t2 * 4 : r3 - t2 * 4], i4 = [n4 + t2 + 1, O2 ? r3 - t2 / 2 : T2 ? r3 + t2 * 4 : r3 - t2 * 4]; + return [[T2 || O2 ? S2.right - t2 : S2.left, S2.top], [T2 ? O2 ? S2.right - t2 : S2.left : S2.right - t2, S2.bottom], e42, i4]; + } + case `right`: + return [[n4 - t2, O2 ? r3 + t2 / 2 : T2 ? r3 + t2 * 4 : r3 - t2 * 4], [n4 - t2, O2 ? r3 - t2 / 2 : T2 ? r3 + t2 * 4 : r3 - t2 * 4], [T2 || O2 ? S2.left + t2 : S2.right, S2.top], [T2 ? O2 ? S2.left + t2 : S2.right : S2.left + t2, S2.bottom]]; + } + } + if (!Xp([m3, h4], N3)) { + if (a3 && !E2) return p4(); + if (!v5 && r2) { + let t3 = l5(e40.clientX, e40.clientY); + if (t3 !== null && t3 < 0.1) return p4(); + } + Xp([m3, h4], P3([n3, o4])) ? !a3 && r2 && (i3.current = window.setTimeout(p4, 40)) : p4(); + } + }; + }; + return u3.__options = { blockPointerEvents: n2 }, u3; +} +function $p(e38) { + let t2 = x.useRef(true); + t2.current && (t2.current = false, e38()); +} +var fm = (e38, t2) => Object.is(e38, t2); +function pm(e38, t2, n2) { + return e38 == null || t2 == null ? Object.is(e38, t2) : n2(e38, t2); +} +function mm(e38, t2, n2) { + return Array.isArray(e38) && Array.isArray(t2) ? !wu(e38, t2, (e39, t3) => pm(e39, t3, n2)) : e38 !== t2; +} +function hm(e38, t2, n2) { + return e38 ? e38.some((e39) => e39 !== void 0 && pm(t2, e39, n2)) : false; +} +function gm(e38, t2, n2) { + return e38 ? e38.findIndex((e39) => e39 !== void 0 && pm(e39, t2, n2)) : -1; +} +function _m(e38, t2) { + if (t2 !== fm) return (n3) => hm(e38, n3, t2); + let n2 = new Set(e38); + return n2.delete(void 0), (t3) => n2.has(t3) && (t3 !== 0 || e38.some((e39) => Object.is(t3, e39))); +} +function vm(e38, t2, n2, r2) { + let i3 = r2 && Array.isArray(t2) ? e38.findIndex(_m(t2, n2)) : gm(e38, t2, n2); + return i3 === -1 ? null : i3; +} +function ym(e38, t2, n2, r2, i3, a3) { + return hm(r2, t2, i3) ? a3 != null && e38 > a3 && hm(r2, n2[a3], i3) ? a3 : e38 : e38 === a3 ? vm(n2, r2, i3, true) : a3; +} +function bm(e38, t2, n2) { + return e38.filter((e39) => !pm(t2, e39, n2)); +} +function xm(e38) { + if (e38 == null) return ``; + if (typeof e38 == `string`) return e38; + try { + return JSON.stringify(e38); + } catch { + return String(e38); + } +} +function Sm(e38) { + return typeof e38 == `object` && !!e38 && Array.isArray(e38.items); +} +function Cm(e38) { + return Sm(e38?.[0]); +} +function wm(e38) { + return Cm(e38) ? e38.flatMap((e39) => e39.items) : e38; +} +function Tm(e38) { + if (!Array.isArray(e38)) return e38 != null && `null` in e38; + let t2 = e38; + if (Cm(t2)) { + for (let e39 of t2) for (let t3 of e39.items) if (t3 && t3.value == null && t3.label != null) return true; + return false; + } + for (let e39 of t2) if (e39 && e39.value == null && e39.label != null) return true; + return false; +} +function Em(e38, t2) { + if (t2 && e38 != null) return t2(e38) ?? ``; + if (e38 && typeof e38 == `object`) { + if (`label` in e38 && e38.label != null) return String(e38.label); + if (`value` in e38) return String(e38.value); + } + return xm(e38); +} +function Dm(e38, t2) { + return t2 && e38 != null ? t2(e38) ?? `` : e38 && typeof e38 == `object` && `value` in e38 && `label` in e38 ? xm(e38.value) : xm(e38); +} +function Om(e38, t2, n2) { + function r2() { + return Em(e38, n2); + } + if (n2 && e38 != null) return n2(e38); + if (e38 && typeof e38 == `object` && `label` in e38 && e38.label != null) return e38.label; + if (t2 && !Array.isArray(t2)) return (Object.hasOwn(t2, e38) ? t2[e38] : void 0) ?? r2(); + if (Array.isArray(t2)) { + let n3 = wm(t2); + if (typeof e38 != `object` || !e38) { + let t3 = n3.find((t4) => t4.value === e38); + return t3 && t3.label != null ? t3.label : r2(); + } + if (`value` in e38) { + let t3 = n3.find((t4) => t4 && t4.value === e38.value); + if (t3 && t3.label != null) return t3.label; + } + } + return r2(); +} +function km(e38, t2, n2) { + return e38.reduce((e39, r2, i3) => (i3 > 0 && e39.push(`, `), e39.push((0, b.jsx)(x.Fragment, { children: Om(r2, t2, n2) }, i3)), e39), []); +} +function Km(e38, t2) { + return e38 ?? t2; +} +var oh = 5; +function sh(e38, t2) { + let n2 = ch(t2); + return e38.clientX >= n2.left - oh && e38.clientX <= n2.right + oh && e38.clientY >= n2.top - oh && e38.clientY <= n2.bottom + oh; +} +function ch(e38) { + let t2 = e38.getBoundingClientRect(), n2 = Fe(e38); + if (cn) return t2; + let r2 = n2.getComputedStyle(e38, `::before`), i3 = n2.getComputedStyle(e38, `::after`); + if (r2.content === `none` && i3.content === `none`) return t2; + let a3 = parseFloat(r2.width) || 0, o3 = parseFloat(r2.height) || 0, s3 = parseFloat(i3.width) || 0, c3 = parseFloat(i3.height) || 0, l5 = Math.max(t2.width, a3, s3), u3 = Math.max(t2.height, o3, c3), d3 = l5 - t2.width, f4 = u3 - t2.height; + return { left: t2.left - d3 / 2, right: t2.right + d3 / 2, top: t2.top - f4 / 2, bottom: t2.bottom + f4 / 2 }; +} +var ph = x.createContext({ register: () => { +}, unregister: () => { +}, subscribeMapChange: () => () => { +}, nextIndexRef: { current: 0 } }); +function mh() { + return x.useContext(ph); +} +function hh(e38) { + Reflect.set(hh, `d`, 4160120707); + let { children: t2, elementsRef: n2, labelsRef: r2, onMapChange: i3 } = e38, a3 = Y(i3), [, o3] = x.useState(0), s3 = T(_h).current, c3 = T(gh).current, l5 = x.useRef(0), u3 = x.useRef(true), d3 = x.useRef(null), f4 = x.useRef(null), p4 = Y(() => { + u3.current || (u3.current = true, o3((e39) => e39 + 1)); + }), m3 = Y((e39, t3) => { + c3.set(e39, t3), p4(); + }), h4 = Y((e39) => { + c3.delete(e39), p4(); + }), g5 = Y((e39) => { + let t3 = /* @__PURE__ */ new Map(); + return n2.current.length = 0, r2 && (r2.current.length = 0), e39.forEach((e40) => { + t3.set(e40.element, { ...e40.registration.metadata ?? {}, index: e40.index }), n2.current[e40.index] = e40.element, r2 && (r2.current[e40.index] = e40.registration.label === void 0 ? e40.registration.textRef?.current?.textContent ?? e40.element.textContent : e40.registration.label); + }), l5.current = n2.current.length, t3; + }); + function _5(e39) { + if (f4.current?.disconnect(), f4.current = null, typeof MutationObserver != `function` || e39.length < 2) return; + let t3 = new MutationObserver((n4) => { + if (!bh(n4)) return; + let r3 = null; + for (let n5 of e39) if (n5.isConnected) { + if (r3 && xh(r3, n5) > 0) { + t3.disconnect(), p4(); + return; + } + r3 = n5; + } + }); + f4.current = t3; + let n3 = /* @__PURE__ */ new Set(); + for (let t4 = 1; t4 < e39.length; t4 += 1) { + let r3 = yh(e39[t4 - 1], e39[t4]); + r3 && n3.add(r3); + } + n3.forEach((e40) => t3.observe(e40, { childList: true })); + } + let v5 = Y(() => { + let [e39, t3] = vh(c3), n3 = g5(e39), r3 = d3.current, i4 = !r3 || r3.length !== e39.length || e39.some((e40, t4) => { + let n4 = r3[t4]; + return e40.index !== n4.index || e40.element !== n4.element || e40.registration.index !== n4.registration.index || e40.registration.metadata !== n4.registration.metadata; + }); + _5(t3), d3.current = e39, u3.current = false, i4 && (s3.forEach((e40) => e40(n3)), a3(n3)); + }); + X(() => (!u3.current && d3.current && g5(d3.current), () => { + n2.current = [], r2 && (r2.current = []); + }), [n2, r2, g5]), X(() => { + u3.current && v5(); + }), X(() => () => { + f4.current?.disconnect(), u3.current = true; + }, []); + let y4 = Y((e39) => (s3.add(e39), () => { + s3.delete(e39); + })), S2 = x.useMemo(() => ({ register: m3, unregister: h4, subscribeMapChange: y4, nextIndexRef: l5 }), [m3, h4, y4, l5]); + return (0, b.jsx)(ph.Provider, { value: S2, children: t2 }); +} +function gh() { + return /* @__PURE__ */ new Map(); +} +function _h() { + return /* @__PURE__ */ new Set(); +} +function vh(e38) { + let t2 = /* @__PURE__ */ new Set(), n2 = [], r2 = []; + e38.forEach((e39, i4) => { + if (!i4.isConnected) return; + let a3 = e39.index, o3 = { index: a3 ?? -1, element: i4, registration: e39 }; + a3 === null ? r2.push(o3) : a3 >= 0 && (t2.add(a3), n2.push(o3)); + }); + let i3 = 0; + return r2.sort((e39, t3) => xh(e39.element, t3.element)), r2.forEach((e39) => { + for (; t2.has(i3); ) i3 += 1; + e39.index = i3, n2.push(e39), i3 += 1; + }), t2.size > 0 && n2.sort((e39, t3) => e39.index - t3.index), [n2, r2.map((e39) => e39.element)]; +} +function yh(e38, t2) { + let n2 = e38.parentElement; + for (; n2 && !n2.contains(t2); ) n2 = n2.parentElement; + return n2; +} +function bh(e38) { + for (let t2 of e38) for (let e39 = 0; e39 < t2.removedNodes.length; e39 += 1) if (t2.removedNodes[e39].isConnected) return true; + return false; +} +function xh(e38, t2) { + return e38.nextElementSibling === t2 ? -1 : t2.nextElementSibling === e38 ? 1 : e38.compareDocumentPosition(t2) & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : 1; +} +function kh(e38) { + let { nodeId: t2, externalTree: n2, rootContext: r2 } = e38, i3 = r2.useState(`referenceElement`), a3 = r2.useState(`floatingElement`), o3 = r2.useState(`domReferenceElement`), s3 = r2.useState(`open`), c3 = r2.useState(`floatingId`), [l5, u3] = x.useState(null), d3 = x.useRef(null), f4 = Hi(n2), p4 = x.useMemo(() => ({ reference: i3, floating: a3, domReference: o3 }), [i3, a3, o3]), m3 = ic({ ...e38, elements: { ...p4, ...l5 && { reference: l5 } } }), h4 = x.useCallback((e39) => { + let t3 = Re2(e39) ? { getBoundingClientRect: () => e39.getBoundingClientRect(), getClientRects: () => e39.getClientRects(), contextElement: e39 } : e39; + u3(t3), m3.refs.setReference(t3); + }, [m3.refs]), g5 = x.useMemo(() => ({ ...m3.refs, setPositionReference: h4, domReference: d3 }), [m3.refs, h4]), _5 = x.useMemo(() => ({ ...m3.elements, domReference: o3 }), [m3.elements, o3]), v5 = x.useMemo(() => ({ ...m3, dataRef: r2.context.dataRef, open: s3, onOpenChange: r2.setOpen, events: r2.context.events, floatingId: c3, refs: g5, elements: _5, nodeId: t2, rootStore: r2 }), [m3, g5, _5, t2, r2, s3, c3]); + return X(() => { + o3 && (d3.current = o3); + }, [o3]), X(() => { + r2.context.dataRef.current.floatingContext = v5; + let e39 = f4?.nodesRef.current.find((e40) => e40.id === t2); + e39 && (e39.context = v5); + }), x.useMemo(() => ({ ...m3, context: v5, refs: g5, elements: _5, rootStore: r2 }), [m3, g5, _5, v5, r2]); +} +var Ah = (e38) => ({ name: `arrow`, options: e38, async fn(t2) { + let { x: n2, y: r2, placement: i3, rects: a3, platform: o3, elements: s3, middlewareData: c3 } = t2, { element: l5, padding: u3 = 0 } = lr(e38, t2) || {}; + if (l5 == null) return {}; + let d3 = Dr(u3), f4 = { x: n2, y: r2 }, p4 = hr(i3), m3 = pr(p4), h4 = await o3.getDimensions(l5), g5 = p4 === `y`, _5 = g5 ? `top` : `left`, v5 = g5 ? `bottom` : `right`, y4 = g5 ? `clientHeight` : `clientWidth`, b2 = a3.reference[m3] + a3.reference[p4] - f4[p4] - a3.floating[m3], x2 = f4[p4] - a3.reference[p4], S2 = s3.floating[y4] || a3.floating[m3], C2 = b2 / 2 - x2 / 2, w2 = S2 / 2 - h4[m3] / 2 - 1, T2 = Math.min(d3[_5], w2), E2 = Math.min(d3[v5], w2), D2 = T2, O2 = S2 - h4[m3] - E2, k2 = S2 / 2 - h4[m3] / 2 + C2, A2 = cr(D2, k2, O2), j2 = !c3.arrow && dr(i3) != null && k2 !== A2 && a3.reference[m3] / 2 - (k2 < D2 ? T2 : E2) - h4[m3] / 2 < 0, M2 = j2 ? k2 < D2 ? k2 - D2 : k2 - O2 : 0; + return { [p4]: f4[p4] + M2, data: { [p4]: A2, centerOffset: k2 - A2 - M2, ...j2 && { alignmentOffset: M2 } }, reset: j2 }; +} }); +var jh = (e38, t2) => { + let { name: n2, fn: r2 } = Ah(e38); + return { name: n2, fn: r2, options: [e38, t2] }; +}; +var Mh = { name: `hide`, async fn(e38) { + let { width: t2, height: n2, x: r2, y: i3 } = e38.rects.reference, a3 = t2 === 0 && n2 === 0 && r2 === 0 && i3 === 0, o3 = await e38.platform.detectOverflow(e38, { elementContext: `reference` }); + return { data: { referenceHidden: o3.top - n2 >= 0 || o3.right - t2 >= 0 || o3.bottom - n2 >= 0 || o3.left - t2 >= 0 || a3 } }; +} }; +var Nh = { sideX: `left`, sideY: `top` }; +var Ph = `--available-width`; +var Fh = `--available-height`; +var Ih = `--anchor-width`; +var Lh = `--anchor-height`; +var Rh = `--transform-origin`; +var zh = Ph; +var Bh = Fh; +function Vh(e38, t2, n2) { + let r2 = e38 === `inline-start` || e38 === `inline-end`; + return { top: `top`, right: r2 ? n2 ? `inline-start` : `inline-end` : `right`, bottom: `bottom`, left: r2 ? n2 ? `inline-end` : `inline-start` : `left` }[t2]; +} +function Hh(e38, t2, n2) { + let { rects: r2, placement: i3 } = e38; + return { side: Vh(t2, ur(i3), n2), align: dr(i3) || `center`, anchor: { width: r2.reference.width, height: r2.reference.height }, positioner: { width: r2.floating.width, height: r2.floating.height } }; +} +function Uh(e38) { + return Wh(e38, kh); +} +function Wh(e38, t2) { + let { anchor: n2, positionMethod: r2 = `absolute`, side: i3 = `bottom`, sideOffset: a3 = 0, align: o3 = `center`, alignOffset: s3 = 0, collisionBoundary: c3, collisionPadding: l5 = 5, sticky: u3 = false, arrowPadding: d3 = 5, disableAnchorTracking: f4 = false, inline: p4, keepMounted: m3 = false, floatingRootContext: h4, mounted: g5, collisionAvoidance: _5, shift: v5, nodeId: y4, adaptiveOrigin: b2, lazyFlip: S2 = false, externalTree: C2 } = e38, w2 = _5.side || `flip`, T2 = _5.align || `flip`, E2 = _5.fallbackAxisSide || `end`, D2 = v5?.crossAxis ?? false, O2 = v5?.rootBoundary, k2 = typeof n2 == `function` ? n2 : void 0, A2 = Y(k2), j2 = k2 ? A2 : n2, M2 = Un(n2), N3 = Un(g5), P3 = Hc() === `rtl`, [F2, I2] = x.useState(null); + !g5 && F2 !== null && I2(null); + let L3 = S2 === `placement`, R3 = F2 ? ur(F2) : null, z2 = F2 && L3 ? dr(F2) || `center` : null, ee2 = R3 || { top: `top`, right: `right`, bottom: `bottom`, left: `left`, "inline-end": P3 ? `left` : `right`, "inline-start": P3 ? `right` : `left` }[i3], B3 = z2 || o3, V3 = B3 === `center` ? ee2 : `${ee2}-${B3}`, H3 = l5; + typeof H3 == `number` ? H3 = { top: H3, right: H3, bottom: H3, left: H3 } : H3 &&= { top: H3.top || 0, right: H3.right || 0, bottom: H3.bottom || 0, left: H3.left || 0 }; + let U3 = +(i3 === `bottom`), W3 = +(i3 === `top`), G2 = +(i3 === `right`), te2 = +(i3 === `left`), K4 = { boundary: c3 === `clipping-ancestors` ? `clippingAncestors` : c3, padding: H3 }, ne3 = x.useRef(null), q4 = Un(a3), re3 = Un(s3), ie3 = typeof a3 == `function` ? 0 : a3, ae3 = typeof s3 == `function` ? 0 : s3, oe5 = []; + p4 && oe5.push(p4), oe5.push(ac((e39) => { + let t3 = Hh(e39, i3, P3), n3 = typeof q4.current == `function` ? q4.current(t3) : q4.current, r3 = typeof re3.current == `function` ? re3.current(t3) : re3.current; + return { mainAxis: n3, crossAxis: r3, alignmentAxis: r3 }; + }, [ie3, ae3, P3, i3])); + let se5 = T2 === `none` && w2 !== `shift`, J4 = !se5 && (u3 || D2 || w2 === `shift`), ce6 = w2 === `none` ? null : cc({ ...K4, padding: { top: H3.top + 1 + U3, right: H3.right + 1 + te2, bottom: H3.bottom + 1 + W3, left: H3.left + 1 + G2 }, mainAxis: !D2 && w2 === `flip`, crossAxis: T2 === `flip` && `alignment`, fallbackAxisSideDirection: E2 }), le6 = se5 ? null : oc({ ...K4, rootBoundary: O2, mainAxis: T2 !== `none`, crossAxis: J4, limiter: u3 || D2 ? void 0 : sc((e39) => { + if (!ne3.current) return {}; + let { width: t3, height: n3 } = ne3.current.getBoundingClientRect(), r3 = mr(ur(e39.placement)), i4 = r3 === `y` ? t3 : n3, a4 = r3 === `y` ? H3.left + H3.right : H3.top + H3.bottom; + return { offset: i4 / 2 + a4 / 2 }; + }) }, [K4, u3, D2, O2, H3, T2]); + w2 === `shift` || T2 === `shift` || B3 === `center` ? oe5.push(le6, ce6) : oe5.push(ce6, le6), oe5.push(lc({ ...K4, apply({ elements: { floating: e39 }, availableWidth: t3, availableHeight: n3, rects: r3 }) { + if (!N3.current) return; + let i4 = e39.style; + i4.setProperty(zh, `${t3}px`), i4.setProperty(Bh, `${n3}px`); + let a4 = Fe(e39).devicePixelRatio || 1, { x: o4, y: s4, width: c4, height: l6 } = r3.reference, u4 = (Math.round((o4 + c4) * a4) - Math.round(o4 * a4)) / a4, d4 = (Math.round((s4 + l6) * a4) - Math.round(s4 * a4)) / a4; + i4.setProperty(Ih, `${u4}px`), i4.setProperty(Lh, `${d4}px`); + } }), jh((e39) => ({ element: ne3.current || ft(e39.elements.floating).createElement(`div`), padding: ne3.current ? d3 : 0 }), [d3]), { name: `transformOrigin`, fn(e39) { + let { elements: { floating: t3 }, middlewareData: n3, placement: r3, platform: o4, rects: s4, y: c4 } = e39, l6 = ur(r3), u4 = dr(r3), d4 = mr(l6) === `y`, f5 = ne3.current, p5 = typeof a3 == `function` ? a3(Hh(e39, i3, P3)) : a3, m4; + m4 = !f5 && u4 && Math.abs(d4 ? n3.shift?.x || 0 : n3.shift?.y || 0) <= 1 ? u4 === `start` === (d4 && o4.isRTL?.(t3) === true) ? `100%` : `0%` : `${(d4 ? n3.arrow?.x || 0 : n3.arrow?.y || 0) + (d4 ? f5?.clientWidth || 0 : f5?.clientHeight || 0) / 2}px`; + let h5 = l6 === `top` || l6 === `left` ? `calc(100% + ${p5}px)` : `${-p5}px`; + return J4 && d4 && Math.abs(n3.shift?.y || 0) > p5 && (h5 = `${s4.reference.y + s4.reference.height / 2 - c4}px`), t3.style.setProperty(Rh, d4 ? `${m4} ${h5}` : `${h5} ${m4}`), {}; + } }, Mh, b2), X(() => { + !g5 && h4 && h4.update({ referenceElement: null, floatingElement: null, domReferenceElement: null, positionReference: null }); + }, [g5, h4]); + let ue6 = x.useMemo(() => ({ ancestorScroll: !f4, elementResize: !f4 && typeof ResizeObserver < `u`, layoutShift: !f4 && typeof IntersectionObserver < `u` }), [f4]), { refs: de6, elements: fe5, x: pe5, y: me5, middlewareData: he5, update: ge5, placement: _e5, context: ve5, isPositioned: ye5, floatingStyles: be5 } = t2({ rootContext: h4, open: m3 ? g5 : void 0, placement: V3, middleware: oe5, strategy: r2, whileElementsMounted: m3 ? void 0 : (...e39) => Hs(...e39, ue6), nodeId: y4, externalTree: C2 }), { sideX: xe5, sideY: Se5 } = he5.adaptiveOrigin || Nh, Ce5 = ye5 ? r2 : `fixed`, we5 = x.useMemo(() => { + let e39; + return e39 = ye5 ? b2 ? { position: Ce5, [xe5]: pe5, [Se5]: me5 } : { ...be5, position: Ce5 } : { position: Ce5, top: 0, left: 0 }, e39[zh] = `100vw`, e39[Bh] = `100vh`, ye5 || (e39.opacity = 0), e39; + }, [b2, Ce5, xe5, pe5, Se5, me5, be5, ye5]), Te5 = x.useRef(null); + X(() => { + if (!g5) return; + let e39 = M2.current, t3 = typeof e39 == `function` ? e39() : e39, n3 = (Gh(t3) ? t3.current : t3) || null; + n3 !== Te5.current && (de6.setPositionReference(n3), Te5.current = n3); + }, [g5, de6, j2, M2]), x.useEffect(() => { + if (!g5) return; + let e39 = M2.current; + typeof e39 != `function` && Gh(e39) && e39.current !== Te5.current && (de6.setPositionReference(e39.current), Te5.current = e39.current); + }, [g5, de6, j2, M2]), x.useEffect(() => { + if (m3 && g5 && fe5.reference && fe5.floating) return Hs(fe5.reference, fe5.floating, ge5, ue6); + }, [m3, g5, fe5, ge5, ue6]); + let Ee5 = ur(_e5), De5 = Vh(i3, Ee5, P3), Oe5 = dr(_e5) || `center`, ke5 = !!he5.hide?.referenceHidden; + X(() => { + S2 && g5 && ye5 && (Ee5 !== ee2 || L3 && Oe5 !== B3) && I2(_e5); + }, [S2, L3, g5, ye5, _e5, Ee5, Oe5, ee2, B3]); + let Ae5 = x.useMemo(() => ({ position: `absolute`, top: he5.arrow?.y, left: he5.arrow?.x }), [he5.arrow]), je5 = he5.arrow?.centerOffset !== 0; + return x.useMemo(() => ({ positionerStyles: we5, arrowStyles: Ae5, arrowRef: ne3, arrowUncentered: je5, side: De5, align: Oe5, physicalSide: Ee5, anchorHidden: ke5, refs: de6, context: ve5, isPositioned: ye5, update: ge5 }), [we5, Ae5, ne3, je5, De5, Oe5, Ee5, ke5, de6, ve5, ye5, ge5]); +} +function Gh(e38) { + return e38 != null && `current` in e38; +} +function Kh(e38) { + return e38 === `starting` ? Di : R; +} +function qh(e38, t2, { styles: n2, transitionStatus: r2, props: i3, refs: a3, hidden: o3, inert: s3 = false }) { + let c3 = { ...n2 }; + return s3 && (c3.pointerEvents = `none`), J(`div`, e38, { state: t2, ref: a3, props: [{ role: `presentation`, hidden: o3, style: c3 }, Kh(r2), i3], stateAttributesMapping: je2 }); +} +var Jh = 20; +function Yh(e38, t2, n2, r2) { + let [i3, a3] = x.useState(false); + X(() => { + if (!e38 || !t2 || n2 == null) { + a3(false); + return; + } + let r3 = ft(n2).documentElement.clientWidth, i4 = n2.offsetWidth; + a3(r3 > 0 && i4 > 0 && i4 >= r3 - Jh); + }, [e38, t2, n2]), Fc(e38 && (!t2 || i3), r2); +} +function rg(e38 = {}) { + let { guess: t2, label: n2, metadata: r2, textRef: i3, index: a3 } = e38, { register: o3, unregister: s3, subscribeMapChange: c3, nextIndexRef: l5 } = mh(), u3 = x.useRef(-1), [d3, f4] = x.useState(a3 == null && t2 ? () => { + if (u3.current === -1) { + let e39 = l5.current; + l5.current += 1, u3.current = e39; + } + return u3.current; + } : -1), p4 = a3 ?? d3, m3 = x.useRef(null), h4 = x.useCallback((e39) => { + let t3 = m3.current; + t3 && s3(t3), m3.current = e39, e39 && o3(e39, { metadata: r2 ?? null, index: a3 ?? null, label: n2, textRef: i3 }); + }, [a3, o3, s3, r2, n2, i3]); + return X(() => { + if (a3 == null) return c3((e39) => { + let t3 = m3.current ? e39.get(m3.current)?.index : null; + t3 != null && f4(t3); + }); + }, [a3, c3]), { ref: h4, index: p4 }; +} +var ug = x.memo(x.forwardRef(function e13(t2, n2) { + Reflect.set(e13, `d`, 3236863643); + let { render: r2, className: i3, style: a3, keepMounted: o3, selected: s3, ...c3 } = t2, l5 = x.useRef(null), { transitionStatus: u3, setMounted: d3 } = Sa(s3), f4 = J(`span`, t2, { ref: [n2, l5], state: { selected: s3, transitionStatus: u3 }, props: [{ "aria-hidden": true, children: `\u2714\uFE0F` }, c3], stateAttributesMapping: ve2 }); + return Da({ batch: true, enabled: !s3, open: s3, ref: l5, onComplete() { + s3 || d3(false); + } }), f4; +})); +var Sg = x.forwardRef(function e14(t2, n2) { + Reflect.set(e14, `d`, 1917059247); + let { render: r2, className: i3, id: a3, name: o3, value: s3, disabled: c3 = false, onValueChange: l5, defaultValue: u3, autoFocus: d3 = false, style: f4, ...p4 } = t2, { state: m3, name: h4, disabled: g5, setTouched: _5, setDirty: v5, validityData: y4, setFilled: b2, validationMode: S2, validation: C2 } = iu(), { clearErrors: w2, elementRef: T2, submitCountRef: E2 } = uu(), D2 = g5 || c3, O2 = h4 ?? o3, k2 = { ...m3, disabled: D2 }, { labelId: A2 } = fu(), j2 = gu({ id: a3 }), M2 = s3 !== void 0, N3 = s3 == null ? void 0 : String(s3), P3 = Y(() => C2.inputRef.current?.value); + ou(C2.inputRef, j2, N3, P3, !D2, o3), X(() => { + let e38 = N3 ?? C2.inputRef.current?.value; + e38 !== void 0 && b2(e38 !== ``); + }, [N3, u3, C2.inputRef, b2]), Rc(N3, () => { + N3 !== void 0 && (w2(O2), v5(N3 !== (y4.initialValue ?? ``)), C2.change(N3)); + }); + let F2 = x.useRef(null), I2 = au(D2, F2), L3 = Kt(); + return J(`input`, t2, { ref: [n2, F2], state: k2, props: [{ id: j2, disabled: D2, name: O2, ref: C2.inputRef, "aria-labelledby": A2, autoFocus: d3, ...M2 ? { value: s3 } : { defaultValue: u3 }, onChange(e38) { + let t3 = e38.currentTarget.value, n3 = Q(_t, e38.nativeEvent); + l5?.(t3, n3), !M2 && (v5(t3 !== (y4.initialValue ?? ``)), b2(t3 !== ``), !e38.nativeEvent.defaultPrevented && !n3.isCanceled && (w2(O2), C2.change(t3))); + }, onFocus() { + I2(true); + }, onBlur(e38) { + if (_5(true), I2(false), S2 === `onBlur`) { + let t3 = e38.currentTarget.value; + C2.commit(t3), M2 && queueMicrotask(() => { + let e39 = C2.inputRef.current?.value; + e39 !== void 0 && e39 !== t3 && e39 !== (y4.initialValue ?? ``) && C2.commit(e39); + }); + } + }, onKeyDown(e38) { + if (e38.currentTarget.tagName === `INPUT` && e38.key === `Enter`) { + _5(true); + let t3 = e38.currentTarget.value, n3 = e38.currentTarget.form; + if (n3 && n3 === T2.current && !e38.defaultPrevented) { + let t4 = e38.currentTarget, n4 = E2.current; + L3.start(0, () => { + E2.current === n4 && C2.commit(t4.value); + }); + } else C2.commit(t3); + } + } }, p4, (e38) => C2.getValidationProps(D2, e38)], stateAttributesMapping: Ql }); +}); +var Tg = x.forwardRef(function e15(t2, n2) { + return Reflect.set(e15, `d`, 946140937), (0, b.jsx)(Sg, { ref: n2, ...t2 }); +}); +function Eg(e38) { + return J(e38.defaultTagName ?? `div`, e38, e38); +} +var i_ = x.createContext(void 0); +function a_(e38) { + let t2 = x.useContext(i_); + if (t2 === void 0 && !e38) throw Error(C(69)); + return t2; +} +function Y_(e38) { + let [t2, n2] = x.useState({ current: e38, previous: null }); + return Object.is(e38, t2.current) || n2({ current: e38, previous: t2.current }), t2.previous; +} +function Z_(e38) { + return e38 == null || e38.hasAttribute(`disabled`) || e38.getAttribute(`aria-disabled`) === `true`; +} +var ov = x.createContext(void 0); +function sv(e38) { + let t2 = x.useContext(ov); + if (t2 === void 0 && !e38) throw Error(C(50)); + return t2; +} +var cv = { ...yo, instantType: (e38) => e38.instantType, adaptiveOrigin: (e38) => e38.adaptiveOrigin, closeDelay: (e38) => e38.closeDelay }; +var lv = class extends lo { + constructor(e38, t2, n2) { + let r2 = new Ua(); + super(dv(e38, r2, t2, n2), fv(r2), cv); + } + setOpen = (e38, t2) => { + let { inlineRectCoordsRef: n2 } = this.context; + La(this, e38, t2, { onBeforeDispatch() { + let r2 = t2.event; + e38 && t2.reason === `trigger-hover` && t2.trigger && `clientX` in r2 && `clientY` in r2 && n2.current?.element !== t2.trigger && va(n2, t2.trigger, r2.clientX, r2.clientY); + } }); + }; +}; +function uv() { + let e38 = new Ua(); + return new Ic(Object.freeze(dv(void 0, e38)), Object.freeze(fv(e38)), cv); +} +function dv(e38, t2, n2, r2 = false) { + return { ...po(t2, n2, r2), instantType: void 0, adaptiveOrigin: void 0, closeDelay: 300, ...e38 }; +} +function fv(e38) { + return { popupRef: x.createRef(), onOpenChange: void 0, onOpenChangeComplete: void 0, triggerElements: e38, inlineRectCoordsRef: { current: void 0 } }; +} +function pv(e38) { + Reflect.set(pv, `d`, 441979227); + let { open: t2, defaultOpen: n2 = false, onOpenChange: r2, onOpenChangeComplete: i3, actionsRef: a3, handle: o3, triggerId: s3, defaultTriggerId: c3 = null, children: l5 } = e38, u3 = ja((e39, r3) => new lv({ open: n2, openProp: t2, activeTriggerId: c3, triggerIdProp: s3 }, e39, r3)); + u3.useControlledProp(`openProp`, t2), u3.useControlledProp(`triggerIdProp`, s3), u3.useContextCallback(`onOpenChange`, r2), u3.useContextCallback(`onOpenChangeComplete`, i3); + let d3 = u3.useState(`open`), f4 = u3.useState(`activeTriggerId`), p4 = u3.useState(`mounted`), m3 = u3.useState(`payload`); + za(u3, { closeOnActiveTriggerUnmount: true }); + let { forceUnmount: h4 } = Ba(d3, u3, () => { + u3.context.inlineRectCoordsRef.current = void 0; + }); + X(() => { + d3 && (f4 ?? u3.set(`payload`, void 0)); + }, [u3, f4, d3]), x.useImperativeHandle(a3, () => ({ unmount: h4, close: () => u3.setOpen(false, Q(Ft)) }), [h4, u3]); + let g5 = d3 || p4 || o3 != null; + return (0, b.jsxs)(ov.Provider, { value: u3, children: [o3 && (0, b.jsx)(Ma, { handle: o3, store: u3 }), g5 && (0, b.jsx)(mv, { store: u3 }), typeof l5 == `function` ? l5({ payload: m3 }) : l5] }); +} +function mv({ store: e38 }) { + Reflect.set(mv, `d`, 4025016067); + let t2 = ca(e38.useState(`floatingRootContext`)); + return Va(e38, { activeTriggerProps: t2.reference, inactiveTriggerProps: t2.trigger, popupProps: t2.floating }), null; +} +var hv = eo(function(e38) { + return sv(true) ? (0, b.jsx)(pv, { ...e38 }) : (0, b.jsx)(Gi, { children: (0, b.jsx)(pv, { ...e38 }) }); +}); +var gv = x.createContext(void 0); +function _v() { + let e38 = x.useContext(gv); + if (e38 === void 0) throw Error(C(48)); + return e38; +} +var vv = x.forwardRef(function e16(t2, n2) { + Reflect.set(e16, `d`, 1811944093); + let { children: r2, container: i3, className: a3, render: o3, style: s3, ...c3 } = t2, { node: l5, subtree: u3 } = Fi({ container: i3, ref: n2, componentProps: t2, elementProps: c3 }); + return !u3 && !l5 ? null : (0, b.jsxs)(x.Fragment, { children: [u3, l5 && Ei.createPortal(r2, l5)] }); +}); +var yv = x.forwardRef(function e17(t2, n2) { + Reflect.set(e17, `d`, 2121183582); + let { keepMounted: r2 = false, ...i3 } = t2; + return sv().useState(`mounted`) || r2 ? (0, b.jsx)(gv.Provider, { value: r2, children: (0, b.jsx)(vv, { ref: n2, ...i3 }) }) : null; +}); +var bv = to(function(e38, t2) { + let { render: n2, className: r2, delay: i3, closeDelay: a3, id: o3, payload: s3, handle: c3, style: l5, ...u3 } = e38, d3 = sv(true), f4 = bo(c3) ?? d3; + if (!f4) throw Error(C(89)); + let p4 = Ht(o3), m3 = f4.useState(`isTriggerActive`, p4), h4 = f4.useState(`isOpenedByTrigger`, p4), g5 = f4.useState(`floatingRootContext`), _5 = f4.context.inlineRectCoordsRef, v5 = x.useRef(null), y4 = i3 ?? 600, b2 = a3 ?? 300, { registerTrigger: S2, isMountedByThisTrigger: w2 } = Ra(p4, v5, f4, { payload: s3, closeDelay: b2 }), T2 = jo(g5, { mouseOnly: true, move: false, handleClose: qo(), delay: () => ({ open: y4, close: b2 }), triggerElementRef: v5, isActiveTrigger: m3, isClosing: () => f4.select(`transitionStatus`) === `ending` }), E2 = Co(g5, { delay: y4 }), D2 = { open: h4 }, O2 = f4.useState(`triggerProps`, w2), k2 = _a(_5, h4); + return J(`a`, e38, { state: D2, ref: [t2, S2, v5], props: [T2, E2.reference, O2, k2, { id: p4 }, u3], stateAttributesMapping: ke2 }); +}); +var xv = x.createContext(void 0); +function Sv() { + let e38 = x.useContext(xv); + if (e38 === void 0) throw Error(C(49)); + return e38; +} +var Cv = x.forwardRef(function e18(t2, n2) { + Reflect.set(e18, `d`, 1215751890); + let { render: r2, className: i3, anchor: a3, positionMethod: o3 = `absolute`, side: s3 = `bottom`, align: c3 = `center`, sideOffset: l5 = 0, alignOffset: u3 = 0, collisionBoundary: d3 = `clipping-ancestors`, collisionPadding: f4 = 5, arrowPadding: p4 = 5, sticky: m3 = false, disableAnchorTracking: h4 = false, collisionAvoidance: g5 = Ai, style: _5, ...v5 } = t2, y4 = sv(), x2 = _v(), S2 = Ui(), C2 = y4.useState(`open`), w2 = y4.useState(`mounted`), T2 = y4.useState(`floatingRootContext`), E2 = y4.useState(`instantType`), D2 = y4.useState(`transitionStatus`), O2 = y4.useState(`adaptiveOrigin`), k2 = y4.context.inlineRectCoordsRef, A2 = Uh({ anchor: a3, floatingRootContext: T2, positionMethod: o3, mounted: w2, side: s3, sideOffset: l5, align: c3, alignOffset: u3, arrowPadding: p4, collisionBoundary: d3, collisionPadding: f4, sticky: m3, disableAnchorTracking: h4, keepMounted: x2, nodeId: S2, collisionAvoidance: g5, adaptiveOrigin: O2, inline: ya(k2) }), j2 = A2.update; + X(() => { + C2 && w2 && j2(); + }, [C2, w2, j2]); + let M2 = qh(t2, { open: C2, side: A2.side, align: A2.align, anchorHidden: A2.anchorHidden, instant: E2 }, { styles: A2.positionerStyles, transitionStatus: D2, props: v5, refs: [n2, y4.useStateSetter(`positionerElement`)], hidden: !w2, inert: !C2 }); + return (0, b.jsx)(xv.Provider, { value: A2, children: (0, b.jsx)(Wi, { id: S2, children: M2 }) }); +}); +var wv = x.forwardRef(function e19(t2, n2) { + Reflect.set(e19, `d`, 3736412037); + let { className: r2, render: i3, style: a3, ...o3 } = t2, s3 = sv(), { side: c3, align: l5 } = Sv(), u3 = s3.useState(`open`), d3 = s3.useState(`instantType`), f4 = s3.useState(`transitionStatus`), p4 = s3.useState(`popupProps`), m3 = s3.useState(`floatingRootContext`), h4 = s3.useState(`closeDelay`); + return Da({ open: u3, ref: s3.context.popupRef, onComplete() { + u3 && s3.context.onOpenChangeComplete?.(true); + } }), ko(m3, { closeDelay: h4 }), J(`div`, t2, { state: { open: u3, side: c3, align: l5, instant: d3, transitionStatus: f4 }, ref: [n2, s3.context.popupRef, s3.useStateSetter(`popupElement`)], props: [ka, p4, Kh(f4), o3], stateAttributesMapping: Me2 }); +}); +var Tv = class extends ba { + constructor() { + super(uv(), `PreviewCard`); + } + open(e38) { + this.openByTrigger(e38); + } + close() { + this.closePopup(); + } + get isOpen() { + return this.attachedStore?.select(`open`) ?? false; + } +}; +function Ev() { + return new Tv(); +} +var Nv = x.createContext(void 0); +function Pv() { + let e38 = x.useContext(Nv); + if (e38 === void 0) throw Error(C(63)); + return e38; +} +var Fv = `data-checked`; +var Iv = `data-unchecked`; +var Lv = { ...Ql, checked(e38) { + return e38 ? { [Fv]: `` } : { [Iv]: `` }; +} }; +var Rv = x.forwardRef(function e20(t2, n2) { + Reflect.set(e20, `d`, 1300529080); + let { render: r2, className: i3, style: a3, ...o3 } = t2; + return J(`span`, t2, { state: Pv(), ref: n2, stateAttributesMapping: Lv, props: o3 }); +}); +function Hv(e38, t2 = -(2 ** 53 - 1), n2 = 2 ** 53 - 1) { + return Math.max(t2, Math.min(e38, n2)); +} +var Sy = x.createContext(void 0); +function Cy(e38) { + let t2 = x.useContext(Sy); + if (t2 === void 0 && !e38) throw Error(C(72)); + return t2; +} +var wy = { ...yo, disabled: (e38) => e38.disabled, instantType: (e38) => e38.instantType, isInstantPhase: (e38) => e38.isInstantPhase, trackCursorAxis: (e38) => e38.trackCursorAxis, disableHoverablePopup: (e38) => e38.disableHoverablePopup, lastOpenChangeReason: (e38) => e38.openChangeReason, closeOnClick: (e38) => e38.closeOnClick, appliedTriggerProps: (e38, t2) => t2 ? e38.activeTriggerProps : void 0, closeDelay: (e38) => e38.closeDelay, adaptiveOrigin: (e38) => e38.adaptiveOrigin }; +var Ty = class extends lo { + constructor(e38, t2, n2) { + let r2 = new Ua(); + super(Dy(e38, r2, t2, n2), Oy(r2), wy); + } + setOpen = (e38, t2) => { + La(this, e38, t2, { extraState: { openChangeReason: t2.reason } }); + }; + cancelPendingOpen(e38) { + this.state.floatingRootContext.dispatchOpenChange(false, Q(vt, e38)); + } +}; +function Ey() { + let e38 = new Ua(), t2 = new Ic(Object.freeze(Dy(void 0, e38)), Object.freeze(Oy(e38)), wy); + return Object.assign(t2, { setOpen: I, cancelPendingOpen: I }); +} +function Dy(e38, t2, n2, r2 = false) { + return { ...po(t2, n2, r2), disabled: false, instantType: void 0, isInstantPhase: false, trackCursorAxis: `none`, disableHoverablePopup: false, openChangeReason: null, closeOnClick: true, closeDelay: 0, adaptiveOrigin: void 0, ...e38 }; +} +function Oy(e38) { + return { popupRef: x.createRef(), onOpenChange: void 0, onOpenChangeComplete: void 0, triggerElements: e38 }; +} +var ky = eo(function(e38) { + let { disabled: t2 = false, defaultOpen: n2 = false, open: r2, disableHoverablePopup: i3 = false, trackCursorAxis: a3 = `none`, actionsRef: o3, onOpenChange: s3, onOpenChangeComplete: c3, handle: l5, triggerId: u3, defaultTriggerId: d3 = null, children: f4 } = e38, p4 = ja((e39, t3) => new Ty({ open: n2, openProp: r2, activeTriggerId: d3, triggerIdProp: u3 }, e39, t3)); + p4.useControlledProp(`openProp`, r2), p4.useControlledProp(`triggerIdProp`, u3), p4.useContextCallback(`onOpenChange`, s3), p4.useContextCallback(`onOpenChangeComplete`, c3); + let m3 = p4.useState(`open`), h4 = !t2 && m3, g5 = p4.useState(`activeTriggerId`), _5 = p4.useState(`mounted`), v5 = p4.useState(`payload`); + p4.useSyncedValues({ trackCursorAxis: a3, disableHoverablePopup: i3, disabled: t2 }), za(p4, { closeOnActiveTriggerUnmount: true }); + let { forceUnmount: y4, transitionStatus: S2 } = Ba(h4, p4), C2 = p4.useState(`isInstantPhase`), w2 = p4.useState(`instantType`), T2 = p4.useState(`lastOpenChangeReason`), E2 = x.useRef(null); + X(() => { + m3 && t2 && p4.setOpen(false, Q(Pt)); + }, [m3, t2, p4]), X(() => { + S2 === `ending` && T2 === `none` || S2 !== `ending` && C2 ? (w2 !== `delay` && (E2.current = w2), p4.set(`instantType`, `delay`)) : E2.current !== null && (p4.set(`instantType`, E2.current), E2.current = null); + }, [S2, C2, T2, w2, p4]), X(() => { + h4 && (g5 ?? p4.set(`payload`, void 0)); + }, [p4, g5, h4]), x.useImperativeHandle(o3, () => ({ unmount: y4, close: () => p4.setOpen(false, Q(Ft)) }), [y4, p4]); + let D2 = h4 || _5 || !t2 && a3 !== `none`; + return (0, b.jsxs)(Sy.Provider, { value: p4, children: [l5 && (0, b.jsx)(Ma, { handle: l5, store: p4 }), D2 && (0, b.jsx)(Ay, { store: p4, disabled: t2, trackCursorAxis: a3 }), typeof f4 == `function` ? f4({ payload: v5 }) : f4] }); +}); +function Ay({ store: e38, disabled: t2, trackCursorAxis: n2 }) { + Reflect.set(Ay, `d`, 1575696699); + let r2 = e38.useState(`floatingRootContext`), i3 = ca(r2, { enabled: !t2, referencePress: () => e38.select(`closeOnClick`) }), a3 = aa(r2, { enabled: !t2 && n2 !== `none`, axis: n2 === `none` ? void 0 : n2 }), o3 = x.useMemo(() => H(a3.reference, i3.reference), [a3.reference, i3.reference]); + return Va(e38, { activeTriggerProps: o3, inactiveTriggerProps: o3, popupProps: i3.floating ?? R }), null; +} +var jy = x.createContext(void 0); +function My() { + return x.useContext(jy); +} +var Ny = `data-base-ui-tooltip-trigger`; +function Py(e38) { + let t2 = _n(e38); + return Re2(t2) ? t2 : null; +} +var Fy = to(function(e38, t2) { + let { render: n2, className: r2, style: i3, handle: a3, payload: o3, disabled: s3, delay: c3, closeOnClick: l5 = true, closeDelay: u3, id: d3, ...f4 } = e38, p4 = Cy(true), m3 = bo(a3) ?? p4; + if (!m3) throw Error(C(82)); + let h4 = Ht(d3), g5 = m3.useState(`isTriggerActive`, h4), _5 = m3.useState(`isOpenedByTrigger`, h4), v5 = m3.useState(`floatingRootContext`), y4 = x.useRef(null), b2 = u3 ?? 0, { registerTrigger: S2, isMountedByThisTrigger: w2 } = Ra(h4, y4, m3, { payload: o3, closeOnClick: l5, closeDelay: b2 }), T2 = My(), { activeIdRef: E2, delayRef: D2, isInstantPhase: O2, hasProvider: k2 } = Bn(v5, { open: _5 }), A2 = Oo(v5); + m3.useSyncedValue(`isInstantPhase`, O2); + let j2 = m3.useState(`disabled`), M2 = s3 ?? j2, N3 = Un(M2), P3 = m3.useState(`trackCursorAxis`), F2 = m3.useState(`disableHoverablePopup`), I2 = x.useRef(false), L3 = Kt(), R3 = x.useRef(void 0); + function z2() { + return k2 && E2.current != null ? 0 : c3 ?? T2 ?? 600; + } + function ee2(e39) { + let t3 = y4.current; + if (!t3 || !e39) return false; + let n3 = gn(e39, `[${Ny}]`); + return n3 !== null && n3 !== t3 && $(t3, n3); + } + function B3(e39) { + let t3 = ee2(e39); + return I2.current = t3, t3 && (A2.openChangeTimeout.clear(), A2.restTimeout.clear(), A2.restTimeoutPending = false, L3.clear()), t3; + } + let V3 = jo(v5, { enabled: !M2, mouseOnly: true, move: false, handleClose: !F2 && P3 !== `both` ? qo() : null, restMs: z2, delay() { + return u3 == null && k2 ? { close: Pn(D2.current, `close`) } : { close: b2 }; + }, triggerElementRef: y4, isActiveTrigger: g5, isClosing: () => m3.select(`transitionStatus`) === `ending`, shouldOpen() { + return !I2.current; + } }), H3 = Co(v5, { enabled: !M2 }).reference, U3 = (e39) => { + let t3 = I2.current, n3 = Py(e39), r3 = B3(n3), i4 = y4.current, a4 = i4 && n3 && $(i4, n3); + if (r3 && m3.select(`open`) && m3.select(`lastOpenChangeReason`) === `trigger-hover`) { + m3.setOpen(false, Q(yt, e39)); + return; + } + if (t3 && !r3 && a4 && !N3.current && !m3.select(`open`) && i4 && pn(R3.current)) { + let t4 = () => { + !I2.current && !N3.current && !m3.select(`open`) && m3.setOpen(true, Q(yt, e39, i4)); + }, n4 = z2(); + n4 === 0 ? (L3.clear(), t4()) : L3.start(n4, t4); + } + }, W3 = m3.useState(`appliedTriggerProps`, w2 || P3 !== `none`); + return J(`button`, e38, { state: { open: _5 }, ref: [t2, S2, y4], props: [V3, H3, W3, { onMouseOver(e39) { + U3(e39.nativeEvent); + }, onFocus(e39) { + ee2(Py(e39.nativeEvent)) && e39.preventBaseUIHandler(); + }, onMouseLeave() { + I2.current = false, L3.clear(), R3.current = void 0; + }, onPointerEnter(e39) { + R3.current = e39.pointerType; + }, onPointerDown(e39) { + R3.current = e39.pointerType, m3.set(`closeOnClick`, l5), l5 && !m3.select(`open`) && m3.cancelPendingOpen(e39.nativeEvent); + }, onClick(e39) { + l5 && !m3.select(`open`) && m3.cancelPendingOpen(e39.nativeEvent); + }, id: h4, [wn]: M2 ? `` : void 0, [Ny]: M2 ? void 0 : `` }, f4], stateAttributesMapping: ke2 }); +}); +var Iy = x.createContext(void 0); +function Ly() { + let e38 = x.useContext(Iy); + if (e38 === void 0) throw Error(C(70)); + return e38; +} +var Ry = x.forwardRef(function e21(t2, n2) { + Reflect.set(e21, `d`, 3518433408); + let { keepMounted: r2 = false, ...i3 } = t2; + return Cy().useState(`mounted`) || r2 ? (0, b.jsx)(Iy.Provider, { value: r2, children: (0, b.jsx)(vv, { ref: n2, ...i3 }) }) : null; +}); +var zy = x.createContext(void 0); +function By() { + let e38 = x.useContext(zy); + if (e38 === void 0) throw Error(C(71)); + return e38; +} +var Vy = x.forwardRef(function e22(t2, n2) { + Reflect.set(e22, `d`, 627419411); + let { render: r2, className: i3, anchor: a3, positionMethod: o3 = `absolute`, side: s3 = `top`, align: c3 = `center`, sideOffset: l5 = 0, alignOffset: u3 = 0, collisionBoundary: d3 = `clipping-ancestors`, collisionPadding: f4 = 5, arrowPadding: p4 = 5, sticky: m3 = false, disableAnchorTracking: h4 = false, collisionAvoidance: g5 = Ai, style: _5, ...v5 } = t2, y4 = Cy(), S2 = Ly(), C2 = y4.useState(`open`), w2 = y4.useState(`mounted`), T2 = y4.useState(`trackCursorAxis`), E2 = y4.useState(`disableHoverablePopup`), D2 = y4.useState(`floatingRootContext`), O2 = y4.useState(`instantType`), k2 = y4.useState(`transitionStatus`), A2 = Uh({ anchor: a3, positionMethod: o3, floatingRootContext: D2, mounted: w2, side: s3, sideOffset: l5, align: c3, alignOffset: u3, collisionBoundary: d3, collisionPadding: f4, sticky: m3, arrowPadding: p4, disableAnchorTracking: h4, keepMounted: S2, collisionAvoidance: g5, adaptiveOrigin: y4.useState(`adaptiveOrigin`) }), j2 = qh(t2, x.useMemo(() => ({ open: C2, side: A2.side, align: A2.align, anchorHidden: A2.anchorHidden, instant: T2 === `none` ? O2 : `tracking-cursor` }), [C2, A2.side, A2.align, A2.anchorHidden, T2, O2]), { styles: A2.positionerStyles, transitionStatus: k2, props: v5, refs: [n2, y4.useStateSetter(`positionerElement`)], hidden: !w2, inert: !C2 || T2 === `both` || E2 }); + return (0, b.jsx)(zy.Provider, { value: A2, children: j2 }); +}); +var Hy = x.forwardRef(function e23(t2, n2) { + Reflect.set(e23, `d`, 1172078345); + let { render: r2, className: i3, style: a3, ...o3 } = t2, s3 = Cy(), { side: c3, align: l5 } = By(), u3 = s3.useState(`open`), d3 = s3.useState(`instantType`), f4 = s3.useState(`transitionStatus`), p4 = s3.useState(`popupProps`), m3 = s3.useState(`floatingRootContext`), h4 = s3.useState(`disabled`), g5 = s3.useState(`closeDelay`); + Da({ open: u3, ref: s3.context.popupRef, onComplete() { + u3 && s3.context.onOpenChangeComplete?.(true); + } }), ko(m3, { enabled: !h4, closeDelay: g5 }); + let _5 = s3.useStateSetter(`popupElement`); + return J(`div`, t2, { state: { open: u3, side: c3, align: l5, instant: d3, transitionStatus: f4 }, ref: [n2, s3.context.popupRef, _5], props: [ka, p4, Kh(f4), o3], stateAttributesMapping: Me2 }); +}); +var Uy = class extends ba { + constructor() { + super(Ey(), `Tooltip`); + } + open(e38) { + this.openByTrigger(e38); + } + close() { + this.closePopup(); + } + get isOpen() { + return this.attachedStore?.select(`open`) ?? false; + } +}; +function Wy() { + return new Uy(); +} +var Gy = typeof window < `u` ? x.useLayoutEffect : x.useEffect; +function Ky(e38) { + if (e38 !== void 0) switch (typeof e38) { + case `number`: + return e38; + case `string`: + if (e38.endsWith(`px`)) return parseFloat(e38); + } +} +function qy({ box: e38, defaultHeight: t2, defaultWidth: n2, disabled: r2, element: i3, mode: a3, style: o3 }) { + let { styleHeight: s3, styleWidth: c3 } = (0, x.useMemo)(() => ({ styleHeight: Ky(o3?.height), styleWidth: Ky(o3?.width) }), [o3?.height, o3?.width]), [l5, u3] = (0, x.useState)({ height: t2, width: n2 }), d3 = r2 || a3 === `only-height` && s3 !== void 0 || a3 === `only-width` && c3 !== void 0 || s3 !== void 0 && c3 !== void 0; + return Gy(() => { + if (i3 === null || d3) return; + let t3 = new ResizeObserver((e39) => { + for (let t4 of e39) { + let { contentRect: e40, target: n3 } = t4; + i3 === n3 && u3((t5) => t5.height === e40.height && t5.width === e40.width ? t5 : { height: e40.height, width: e40.width }); + } + }); + return t3.observe(i3, { box: e38 }), () => { + t3?.unobserve(i3); + }; + }, [e38, d3, i3, s3, c3]), (0, x.useMemo)(() => ({ height: s3 ?? l5.height, width: c3 ?? l5.width }), [l5, s3, c3]); +} +function Jy(e38) { + let t2 = (0, x.useRef)(() => { + throw Error(`Cannot call during render.`); + }); + return Gy(() => { + t2.current = e38; + }, [e38]), (0, x.useCallback)((e39) => t2.current?.(e39), [t2]); +} +var Yy = null; +function Xy(e38 = false) { + if (Yy === null || e38) { + let e39 = document.createElement(`div`), t2 = e39.style; + t2.width = `50px`, t2.height = `50px`, t2.overflow = `scroll`, t2.direction = `rtl`; + let n2 = document.createElement(`div`), r2 = n2.style; + return r2.width = `100px`, r2.height = `100px`, e39.appendChild(n2), document.body.appendChild(e39), e39.scrollLeft > 0 ? Yy = `positive-descending` : (e39.scrollLeft = 1, Yy = e39.scrollLeft === 0 ? `negative` : `positive-ascending`), document.body.removeChild(e39), Yy; + } + return Yy; +} +function Zy({ containerElement: e38, direction: t2, isRtl: n2, scrollOffset: r2 }) { + if (t2 === `horizontal` && n2) switch (Xy()) { + case `negative`: + return -r2; + case `positive-descending`: + if (e38) { + let { clientWidth: t3, scrollLeft: n3, scrollWidth: r3 } = e38; + return r3 - t3 - n3; + } + } + return r2; +} +function Qy(e38, t2 = `Assertion error`) { + if (!e38) throw console.error(t2), Error(t2); +} +function $y(e38, t2) { + if (e38 === t2) return true; + if (!!e38 != !!t2 || (Qy(e38 !== void 0), Qy(t2 !== void 0), Object.keys(e38).length !== Object.keys(t2).length)) return false; + for (let n2 in e38) if (!Object.is(t2[n2], e38[n2])) return false; + return true; +} +function eb({ cachedBounds: e38, itemCount: t2, itemSize: n2 }) { + if (t2 === 0) return 0; + if (typeof n2 == `number`) return t2 * n2; + { + let n3 = e38.get(e38.size === 0 ? 0 : e38.size - 1); + return Qy(n3 !== void 0, `Unexpected bounds cache miss`), t2 * ((n3.scrollOffset + n3.size) / e38.size); + } +} +function tb({ align: e38, cachedBounds: t2, index: n2, itemCount: r2, itemSize: i3, containerScrollOffset: a3, containerSize: o3 }) { + if (n2 < 0 || n2 >= r2) throw RangeError(`Invalid index specified: ${n2}`, { cause: `Index ${n2} is not within the range of 0 - ${r2 - 1}` }); + let s3 = eb({ cachedBounds: t2, itemCount: r2, itemSize: i3 }), c3 = t2.get(n2), l5 = Math.max(0, Math.min(s3 - o3, c3.scrollOffset)), u3 = Math.max(0, c3.scrollOffset - o3 + c3.size); + switch (e38 === `smart` && (e38 = a3 >= u3 && a3 <= l5 ? `auto` : `center`), e38) { + case `start`: + return l5; + case `end`: + return u3; + case `center`: + return c3.scrollOffset <= o3 / 2 ? 0 : c3.scrollOffset + c3.size / 2 >= s3 - o3 / 2 ? s3 - o3 : c3.scrollOffset + c3.size / 2 - o3 / 2; + default: + return a3 >= u3 && a3 <= l5 ? a3 : a3 < u3 ? u3 : l5; + } +} +function nb({ cachedBounds: e38, containerScrollOffset: t2, containerSize: n2, itemCount: r2, overscanCount: i3 }) { + let a3 = r2 - 1, o3 = 0, s3 = -1, c3 = 0, l5 = -1, u3 = 0; + for (; u3 < a3; ) { + let n3 = e38.get(u3); + if (n3.scrollOffset + n3.size > t2) break; + u3++; + } + for (o3 = u3, c3 = Math.max(0, o3 - i3); u3 < a3; ) { + let r3 = e38.get(u3); + if (r3.scrollOffset + r3.size >= t2 + n2) break; + u3++; + } + return s3 = Math.min(a3, u3), l5 = Math.min(r2 - 1, s3 + i3), o3 < 0 && (o3 = 0, s3 = -1, c3 = 0, l5 = -1), { startIndexVisible: o3, stopIndexVisible: s3, startIndexOverscan: c3, stopIndexOverscan: l5 }; +} +function rb({ itemCount: e38, itemProps: t2, itemSize: n2 }) { + let r2 = /* @__PURE__ */ new Map(); + return { get(i3) { + for (Qy(i3 < e38, `Invalid index ${i3}`); r2.size - 1 < i3; ) { + let e39 = r2.size, a4; + switch (typeof n2) { + case `function`: + a4 = n2(e39, t2); + break; + case `number`: + a4 = n2; + } + if (e39 === 0) r2.set(e39, { size: a4, scrollOffset: 0 }); + else { + let t3 = r2.get(e39 - 1); + Qy(t3 !== void 0, `Unexpected bounds cache miss for index ${i3}`), r2.set(e39, { scrollOffset: t3.scrollOffset + t3.size, size: a4 }); + } + } + let a3 = r2.get(i3); + return Qy(a3 !== void 0, `Unexpected bounds cache miss for index ${i3}`), a3; + }, set(e39, t3) { + r2.set(e39, t3); + }, get size() { + return r2.size; + } }; +} +function ib({ itemCount: e38, itemProps: t2, itemSize: n2 }) { + return (0, x.useMemo)(() => rb({ itemCount: e38, itemProps: t2, itemSize: n2 }), [e38, t2, n2]); +} +function ab({ containerSize: e38, itemSize: t2 }) { + let n2; + switch (typeof t2) { + case `string`: + Qy(t2.endsWith(`%`), `Invalid item size: "${t2}"; string values must be percentages (e.g. "100%")`), Qy(e38 !== void 0, `Container size must be defined if a percentage item size is specified`), n2 = e38 * parseInt(t2) / 100; + break; + default: + n2 = t2; + } + return n2; +} +function ob({ containerElement: e38, containerStyle: t2, defaultContainerSize: n2 = 0, direction: r2, isRtl: i3 = false, itemCount: a3, itemProps: o3, itemSize: s3, onResize: c3, overscanCount: l5 }) { + let [u3, d3] = (0, x.useState)({ startIndexVisible: 0, startIndexOverscan: 0, stopIndexVisible: -1, stopIndexOverscan: -1 }), { startIndexVisible: f4, startIndexOverscan: p4, stopIndexVisible: m3, stopIndexOverscan: h4 } = { startIndexVisible: Math.min(a3 - 1, u3.startIndexVisible), startIndexOverscan: Math.min(a3 - 1, u3.startIndexOverscan), stopIndexVisible: Math.min(a3 - 1, u3.stopIndexVisible), stopIndexOverscan: Math.min(a3 - 1, u3.stopIndexOverscan) }, { height: g5 = n2, width: _5 = n2 } = qy({ defaultHeight: r2 === `vertical` ? n2 : void 0, defaultWidth: r2 === `horizontal` ? n2 : void 0, element: e38, mode: r2 === `vertical` ? `only-height` : `only-width`, style: t2 }), v5 = (0, x.useRef)({ height: 0, width: 0 }), y4 = r2 === `vertical` ? g5 : _5, b2 = ab({ containerSize: y4, itemSize: s3 }); + (0, x.useLayoutEffect)(() => { + if (typeof c3 == `function`) { + let e39 = v5.current; + (e39.height !== g5 || e39.width !== _5) && (c3({ height: g5, width: _5 }, { ...e39 }), e39.height = g5, e39.width = _5); + } + }, [g5, c3, _5]); + let S2 = ib({ itemCount: a3, itemProps: o3, itemSize: b2 }), C2 = (0, x.useCallback)((e39) => S2.get(e39), [S2]), w2 = (0, x.useCallback)(() => eb({ cachedBounds: S2, itemCount: a3, itemSize: b2 }), [S2, a3, b2]), T2 = (0, x.useCallback)((t3) => { + let n3 = Zy({ containerElement: e38, direction: r2, isRtl: i3, scrollOffset: t3 }); + return nb({ cachedBounds: S2, containerScrollOffset: n3, containerSize: y4, itemCount: a3, overscanCount: l5 }); + }, [S2, e38, y4, r2, i3, a3, l5]); + return Gy(() => { + let t3 = (r2 === `vertical` ? e38?.scrollTop : e38?.scrollLeft) ?? 0; + d3(T2(t3)); + }, [e38, r2, T2]), Gy(() => { + if (!e38) return; + let t3 = () => { + d3((t4) => { + let { scrollLeft: n3, scrollTop: o4 } = e38, s4 = Zy({ containerElement: e38, direction: r2, isRtl: i3, scrollOffset: r2 === `vertical` ? o4 : n3 }), c4 = nb({ cachedBounds: S2, containerScrollOffset: s4, containerSize: y4, itemCount: a3, overscanCount: l5 }); + return $y(c4, t4) ? t4 : c4; + }); + }; + return e38.addEventListener(`scroll`, t3), () => { + e38.removeEventListener(`scroll`, t3); + }; + }, [S2, e38, y4, r2, a3, l5]), { getCellBounds: C2, getEstimatedSize: w2, scrollToIndex: Jy(({ align: t3 = `auto`, containerScrollOffset: n3, index: o4 }) => { + let s4 = tb({ align: t3, cachedBounds: S2, containerScrollOffset: n3, containerSize: y4, index: o4, itemCount: a3, itemSize: b2 }); + if (e38) { + if (s4 = Zy({ containerElement: e38, direction: r2, isRtl: i3, scrollOffset: s4 }), typeof e38.scrollTo != `function`) { + let e39 = T2(s4); + $y(u3, e39) || d3(e39); + } + return s4; + } + }), startIndexOverscan: p4, startIndexVisible: f4, stopIndexOverscan: h4, stopIndexVisible: m3 }; +} +function sb(e38) { + return (0, x.useMemo)(() => e38, Object.values(e38)); +} +function cb(e38, t2) { + let { ariaAttributes: n2, style: r2, ...i3 } = e38, { ariaAttributes: a3, style: o3, ...s3 } = t2; + return $y(n2, a3) && $y(r2, o3) && $y(i3, s3); +} +function lb(e38) { + return typeof e38 == `object` && !!e38 && `getAverageRowHeight` in e38 && typeof e38.getAverageRowHeight == `function`; +} +var ub = `data-react-window-index`; +function db({ children: e38, className: t2, defaultHeight: n2 = 0, listRef: r2, onResize: i3, onRowsRendered: a3, overscanCount: o3 = 3, rowComponent: s3, rowCount: c3, rowHeight: l5, rowProps: u3, tagName: d3 = `div`, style: f4, ...p4 }) { + Reflect.set(db, `d`, 3252864834); + let m3 = sb(u3), h4 = (0, x.useMemo)(() => (0, x.memo)(s3, cb), [s3]), [g5, _5] = (0, x.useState)(null), v5 = lb(l5), { getCellBounds: y4, getEstimatedSize: S2, scrollToIndex: C2, startIndexOverscan: w2, startIndexVisible: T2, stopIndexOverscan: E2, stopIndexVisible: D2 } = ob({ containerElement: g5, containerStyle: f4, defaultContainerSize: n2, direction: `vertical`, itemCount: c3, itemProps: m3, itemSize: (0, x.useMemo)(() => v5 ? (e39) => l5.getRowHeight(e39) ?? l5.getAverageRowHeight() : l5, [v5, l5]), onResize: i3, overscanCount: o3 }); + (0, x.useImperativeHandle)(r2, () => ({ get element() { + return g5; + }, scrollToRow({ align: e39 = `auto`, behavior: t3 = `auto`, index: n3 }) { + let r3 = C2({ align: e39, containerScrollOffset: g5?.scrollTop ?? 0, index: n3 }); + typeof g5?.scrollTo == `function` && g5.scrollTo({ behavior: t3, top: r3 }); + } }), [g5, C2]), Gy(() => { + if (!g5) return; + let e39 = Array.from(g5.children).filter((e40, t3) => { + if (e40.hasAttribute(`aria-hidden`)) return false; + let n3 = `${w2 + t3}`; + return e40.setAttribute(ub, n3), true; + }); + if (v5) return l5.observeRowElements(e39); + }, [g5, v5, l5, w2, E2]), (0, x.useEffect)(() => { + w2 >= 0 && E2 >= 0 && a3 && a3({ startIndex: T2, stopIndex: D2 }, { startIndex: w2, stopIndex: E2 }); + }, [a3, w2, T2, E2, D2]); + let O2 = (0, x.useMemo)(() => { + let e39 = []; + if (c3 > 0) for (let t3 = w2; t3 <= E2; t3++) { + let n3 = y4(t3); + e39.push((0, x.createElement)(h4, { ...m3, ariaAttributes: { "aria-posinset": t3 + 1, "aria-setsize": c3, role: `listitem` }, key: t3, index: t3, style: { position: `absolute`, left: 0, transform: `translateY(${n3.scrollOffset}px)`, height: v5 ? void 0 : n3.size, width: `100%` } })); + } + return e39; + }, [h4, y4, v5, c3, m3, w2, E2]), k2 = (0, b.jsx)(`div`, { "aria-hidden": true, style: { height: S2(), width: `100%`, zIndex: -1 } }); + return (0, x.createElement)(d3, { role: `list`, ...p4, className: t2, ref: _5, style: { position: `relative`, maxHeight: `100%`, flexGrow: 1, overflowY: `auto`, ...f4 } }, O2, e38, k2); +} +var fb = x.createContext(void 0); +var pb = x.createContext(void 0); +function mb() { + let e38 = x.useContext(fb); + if (e38 === void 0) throw Error(C(60)); + return e38; +} +function hb() { + let e38 = x.useContext(pb); + if (e38 === void 0) throw Error(C(61)); + return e38; +} +var gb = { id: (e38) => e38.id, labelId: (e38) => e38.labelId, modal: (e38) => e38.modal, multiple: (e38) => e38.multiple, disabled: (e38) => e38.disabled, readOnly: (e38) => e38.readOnly, required: (e38) => e38.required, highlightItemOnHover: (e38) => e38.highlightItemOnHover, items: (e38) => e38.items, itemToStringLabel: (e38) => e38.itemToStringLabel, isItemEqualToValue: (e38) => e38.isItemEqualToValue, value: (e38) => e38.value, hasSelectedValue: (e38) => { + let { value: t2, multiple: n2, itemToStringValue: r2 } = e38; + return t2 == null ? false : n2 && Array.isArray(t2) ? t2.length > 0 : Dm(t2, r2) !== ``; +}, hasNullItemLabel: (e38, t2) => t2 ? Tm(e38.items) : false, open: (e38) => e38.open, mounted: (e38) => e38.mounted, forceMount: (e38) => e38.forceMount, transitionStatus: (e38) => e38.transitionStatus, openMethod: (e38) => e38.openMethod, activeIndex: (e38) => e38.activeIndex, selectedIndex: (e38) => e38.selectedIndex, isActive: (e38, t2) => e38.activeIndex === t2, isSelected: (e38, t2) => { + let n2 = e38.isItemEqualToValue, r2 = e38.value; + return e38.multiple ? Array.isArray(r2) && r2.some((e39) => pm(t2, e39, n2)) : pm(t2, r2, n2); +}, isSelectedByFocus: (e38, t2) => e38.selectedIndex === t2, popupProps: (e38) => e38.popupProps, triggerProps: (e38) => e38.triggerProps, itemRoot: (e38) => e38.itemRoot, triggerElement: (e38) => e38.triggerElement, positionerElement: (e38) => e38.positionerElement, listElement: (e38) => e38.listElement, popupSide: (e38) => e38.popupSide, scrollUpArrowVisible: (e38) => e38.scrollUpArrowVisible, scrollDownArrowVisible: (e38) => e38.scrollDownArrowVisible, hasScrollArrows: (e38) => e38.hasScrollArrows }; +function _b(e38, t2) { + return Math.max(0, e38 - t2); +} +function vb(e38, t2) { + if (t2 <= 0) return 0; + let n2 = Hv(e38, 0, t2), r2 = n2, i3 = t2 - n2, a3 = r2 <= 1, o3 = i3 <= 1; + return a3 && o3 ? r2 <= i3 ? 0 : t2 : a3 ? 0 : o3 ? t2 : n2; +} +function yb(e38) { + Reflect.set(yb, `d`, 2855003251); + let { id: t2, value: n2, defaultValue: r2 = null, onValueChange: i3, open: a3, defaultOpen: o3 = false, onOpenChange: s3, name: c3, form: l5, autoComplete: u3, disabled: d3 = false, readOnly: f4 = false, required: p4 = false, modal: m3 = true, actionsRef: h4, inputRef: g5, onOpenChangeComplete: _5, items: v5, multiple: y4 = false, itemToStringLabel: S2, itemToStringValue: C2, isItemEqualToValue: w2 = fm, highlightItemOnHover: D2 = true, children: O2 } = e38, { clearErrors: k2 } = uu(), { setDirty: A2, setTouched: j2, setFocused: M2, validityData: N3, setFilled: P3, name: F2, disabled: z2, validation: ee2, validationMode: B3 } = iu(), V3 = gu({ id: t2 }), U3 = z2 || d3, W3 = F2 ?? c3, [G2, te2] = Gl({ controlled: n2, default: y4 ? r2 ?? L : r2, name: `Select`, state: `value` }), [K4, ne3] = Gl({ controlled: a3, default: o3, name: `Select`, state: `open` }), q4 = x.useRef([]), re3 = x.useRef([]), ie3 = x.useRef(null), ae3 = x.useRef(null), oe5 = x.useRef(0), se5 = x.useRef(null), J4 = x.useRef([]), ce6 = x.useRef(false), le6 = x.useRef(null), ue6 = x.useRef(null), de6 = x.useRef({ allowSelectedMouseUp: false, allowUnselectedMouseUp: false, dragY: 0 }), fe5 = x.useRef(false), pe5 = x.useRef(G2), { openMethod: me5, triggerProps: he5 } = Bc(K4), ge5 = T(() => new lo({ id: V3, labelId: void 0, modal: m3, multiple: y4, disabled: U3, readOnly: f4, required: p4, highlightItemOnHover: D2, itemToStringLabel: S2, itemToStringValue: C2, isItemEqualToValue: w2, value: G2, open: K4, mounted: K4, transitionStatus: void 0, items: v5, forceMount: false, openMethod: null, activeIndex: null, selectedIndex: null, popupProps: R, triggerProps: R, itemRoot: { props: R, multiple: y4, disabled: U3, readOnly: f4, isItemEqualToValue: w2 }, triggerElement: null, positionerElement: null, listElement: null, popupSide: null, scrollUpArrowVisible: false, scrollDownArrowVisible: false, hasScrollArrows: false }, { setValue: I, setOpen: I, handleScrollArrowVisibility: I, onOpenChangeComplete: I, listRef: q4, popupRef: ie3, scrollHandlerRef: ae3, scrollArrowsMountedCountRef: oe5, valueRef: se5, valuesRef: J4, labelsRef: re3, typingRef: ce6, selectionRef: de6, firstItemTextRef: le6, selectedItemTextRef: ue6, alignItemWithTriggerActiveRef: fe5, initialValueRef: pe5 }, gb)).current, [_e5, ve5] = x.useState(false), { mounted: ye5, transitionStatus: be5, forceUnmount: xe5 } = Oa({ open: K4, ref: ie3, preventUnmountOnClose: _e5, setPreventUnmountOnClose: ve5, onUnmount() { + ge5.update({ activeIndex: null, openMethod: null, scrollUpArrowVisible: false, scrollDownArrowVisible: false }), _5?.(false); + } }), Se5 = ge5.useState(`activeIndex`), Ce5 = ge5.useState(`selectedIndex`), we5 = ge5.useState(`triggerElement`), Te5 = ge5.useState(`positionerElement`), Ee5 = Y_(me5), De5 = me5 ?? Ee5, Oe5 = x.useMemo(() => y4 ? `` : Dm(G2, C2), [y4, G2, C2]), ke5 = x.useMemo(() => y4 && Array.isArray(G2) ? G2.map((e39) => Dm(e39, C2)) : Dm(G2, C2), [y4, G2, C2]); + ou(Un(we5), V3, G2, Y(() => ke5), !U3, c3); + let Ae5 = y4 ? Array.isArray(G2) && G2.length > 0 : G2 != null && Oe5 !== ``; + X(() => { + P3(Ae5); + }, [Ae5, P3]), X(function() { + let e39 = vm(J4.current, G2, w2, y4); + e39 === null && (ue6.current = null), !K4 && ge5.set(`selectedIndex`, e39); + }, [y4, K4, G2, w2, ge5]), Rc(G2, () => { + k2(W3), A2(mm(G2, N3.initialValue, w2)), ee2.change(G2); + }); + let je5 = Y((e39, t3) => { + let n3 = t3, r3 = Ia(n3); + s3?.(e39, n3), !t3.isCanceled && (e39 || ve5(r3()), ne3(e39), !e39 && (t3.reason === `focus-out` || t3.reason === `outside-press`) && (j2(true), M2(false), B3 === `onBlur` && ee2.commit(G2))); + }); + x.useImperativeHandle(h4, () => ({ unmount: xe5, close: () => { + ge5.state.open && je5(false, Q(Ft)); + } }), [xe5, je5, ge5]); + let Me5 = Y((e39, t3) => { + i3?.(e39, t3), !t3.isCanceled && te2(e39); + }), Ne5 = Y((e39) => { + let t3 = _b(e39.scrollHeight, e39.clientHeight), n3 = vb(e39.scrollTop, t3), r3 = n3 > 0, i4 = n3 < t3; + ge5.set(`scrollUpArrowVisible`, r3), ge5.set(`scrollDownArrowVisible`, i4); + }), Pe5 = xo({ open: K4, onOpenChange: je5, elements: { reference: we5, floating: Te5 } }), Fe4 = na(Pe5, { enabled: !U3, event: `mousedown` }), Ie5 = ca(Pe5), Le5 = Ro(Pe5, { enabled: !U3, listRef: q4, activeIndex: Se5, selectedIndex: Ce5, disabledIndices: L, onNavigate(e39) { + (e39 !== null || K4) && ge5.set(`activeIndex`, e39); + }, focusItemOnHover: D2 }), Re5 = zo(Pe5, { enabled: !U3 && (K4 || !f4 && !y4), listRef: re3, activeIndex: Se5, selectedIndex: Ce5, disabledIndices: (e39) => Z_(q4.current[e39]), onMatch(e39) { + K4 ? ge5.set(`activeIndex`, e39) : Me5(J4.current[e39], Q(_t)); + }, onTyping(e39) { + ce6.current = e39; + } }), ze5 = x.useMemo(() => H(Re5.reference, Le5.reference, Ie5.reference, Fe4.reference, he5), [Fe4.reference, Re5.reference, Le5.reference, Ie5.reference, he5]), Be5 = x.useMemo(() => H(ka, Re5.floating, Le5.floating, Ie5.floating), [Re5.floating, Le5.floating, Ie5.floating]), Ve5 = Le5.item ?? R, He5 = x.useMemo(() => ({ props: Ve5, multiple: y4, disabled: U3, readOnly: f4, isItemEqualToValue: w2 }), [Ve5, y4, U3, f4, w2]); + ge5.useContextCallback(`setValue`, Me5), ge5.useContextCallback(`setOpen`, je5), ge5.useContextCallback(`handleScrollArrowVisibility`, Ne5), ge5.useContextCallback(`onOpenChangeComplete`, _5), $p(() => { + ge5.update({ popupProps: Be5, triggerProps: ze5, itemRoot: He5 }); + }), ge5.useSyncedValues({ id: V3, modal: m3, multiple: y4, disabled: U3, readOnly: f4, required: p4, highlightItemOnHover: D2, value: G2, open: K4, mounted: ye5, transitionStatus: be5, popupProps: Be5, triggerProps: ze5, itemRoot: He5, items: v5, itemToStringLabel: S2, itemToStringValue: C2, isItemEqualToValue: w2, openMethod: De5 }); + let Ue4 = E(g5, ee2.inputRef), We4 = y4 ? void 0 : W3, Ge4 = x.useMemo(() => !y4 || !Array.isArray(G2) || !W3 ? null : G2.map((e39) => { + let t3 = Dm(e39, C2); + return (0, b.jsx)(`input`, { type: `hidden`, form: l5, name: W3, value: t3, disabled: U3 }, t3); + }), [y4, G2, l5, W3, C2, U3]); + return (0, b.jsxs)(fb.Provider, { value: ge5, children: [(0, b.jsx)(pb.Provider, { value: Pe5, children: O2 }), (0, b.jsx)(`input`, { ...ee2.getValidationProps(U3, { onFocus() { + ge5.state.triggerElement?.focus({ focusVisible: true }); + }, onChange(e39) { + if (e39.nativeEvent.defaultPrevented || U3 || f4) return; + let t3 = e39.currentTarget.value, n3 = Q(_t, e39.nativeEvent); + function r3() { + if (y4) return; + let e40 = t3.toLowerCase(), r4 = J4.current.findIndex((t4) => Dm(t4, C2).toLowerCase() === e40 || Em(t4, S2).toLowerCase() === e40); + r4 === -1 && (r4 = J4.current.findIndex((t4, n4) => { + let r5 = re3.current[n4]; + return r5 != null && r5.toLowerCase() === e40; + })); + let i4 = J4.current[r4]; + i4 != null && Me5(i4, n3); + } + ge5.set(`forceMount`, true), queueMicrotask(r3); + } }), id: V3 && We4 == null ? `${V3}-hidden-input` : void 0, form: l5, name: We4, autoComplete: u3, value: Oe5, disabled: U3, required: p4 && !(y4 && Ae5), readOnly: f4, ref: Ue4, style: W3 ? Zn : Xn, tabIndex: -1, "aria-hidden": true, suppressHydrationWarning: true }), Ge4] }); +} +var bb = `data-popup-side`; +var xb = 400; +var Sb = { ...Ae2, ...Ql, popupSide: (e38) => e38 ? { [bb]: e38 } : null, value: () => null }; +var Cb = x.forwardRef(function e24(t2, n2) { + Reflect.set(e24, `d`, 2133586261); + let { render: r2, className: i3, id: a3, disabled: o3 = false, nativeButton: s3 = true, style: c3, ...l5 } = t2, { setTouched: u3, validationMode: d3, validation: f4, state: p4, disabled: m3 } = iu(), { labelId: h4 } = fu(), g5 = mb(), _5 = g5.useState(`readOnly`), v5 = g5.useState(`required`), y4 = g5.useState(`disabled`), b2 = m3 || y4 || o3, S2 = g5.useState(`open`), C2 = g5.useState(`mounted`), w2 = g5.useState(`value`), T2 = g5.useState(`triggerProps`), E2 = g5.useState(`positionerElement`), D2 = g5.useState(`listElement`), O2 = g5.useState(`popupSide`), k2 = g5.useState(`id`), A2 = g5.useState(`labelId`), j2 = g5.useState(`hasSelectedValue`), M2 = C2 && E2 ? O2 : null, N3 = a3 ?? k2, P3 = Km(h4, A2); + gu({ id: a3 }); + let F2 = Un(E2), I2 = x.useRef(null), L3 = au(b2, I2), { getButtonProps: R3, buttonRef: z2 } = Z({ disabled: b2, native: s3 }), ee2 = g5.useStateSetter(`triggerElement`), B3 = Kt(), V3 = Kt(), U3 = Kt(); + x.useEffect(() => { + if (S2) return U3.start(xb, () => { + g5.context.selectionRef.current.allowUnselectedMouseUp = true, g5.context.selectionRef.current.allowSelectedMouseUp = true; + }), () => { + U3.clear(); + }; + g5.context.selectionRef.current = { allowSelectedMouseUp: false, allowUnselectedMouseUp: false, dragY: 0 }, V3.clear(); + }, [S2, g5, V3, U3]); + let W3 = H(T2, { id: N3, role: `combobox`, "aria-expanded": S2, "aria-haspopup": `listbox`, "aria-controls": S2 ? D2?.id ?? Mn(E2)?.id : void 0, "aria-labelledby": P3, "aria-readonly": _5 || void 0, "aria-required": v5 || void 0, tabIndex: b2 ? -1 : 0, onFocus(e38) { + L3(true), S2 && g5.context.alignItemWithTriggerActiveRef.current && g5.context.setOpen(false, Q(_t, e38.nativeEvent)), B3.start(0, () => { + g5.set(`forceMount`, true); + }); + }, onBlur(e38) { + $(E2, e38.relatedTarget) || (u3(true), L3(false), d3 === `onBlur` && f4.commit(w2)); + }, onMouseDown(e38) { + if (S2) return; + let t3 = ft(e38.currentTarget); + function n3(e39) { + if (!I2.current) return; + let t4 = e39.target; + $(I2.current, t4) || $(F2.current, t4) || sh(e39, I2.current) || g5.context.setOpen(false, Q(Mt, e39)); + } + V3.start(0, () => { + t3.addEventListener(`mouseup`, n3, { once: true }); + }); + } }, l5, R3), G2 = f4.getValidationProps(b2, W3); + G2.role = `combobox`; + let te2 = { ...p4, open: S2, disabled: b2, value: w2, readOnly: _5, popupSide: M2, placeholder: !j2 }; + return J(`button`, t2, { ref: [n2, I2, z2, ee2], state: te2, stateAttributesMapping: Sb, props: G2 }); +}); +var wb = { value: () => null }; +var Tb = x.forwardRef(function e25(t2, n2) { + Reflect.set(e25, `d`, 1374957201); + let { className: r2, render: i3, children: a3, placeholder: o3, style: s3, ...c3 } = t2, l5 = mb(), u3 = l5.useState(`value`), d3 = l5.useState(`items`), f4 = l5.useState(`itemToStringLabel`), p4 = l5.useState(`hasSelectedValue`), m3 = !p4 && o3 != null && a3 == null, h4 = l5.useState(`hasNullItemLabel`, m3), g5 = { value: u3, placeholder: !p4 }, _5 = null; + return _5 = typeof a3 == `function` ? a3(u3) : a3 ?? (m3 && !h4 ? o3 : Array.isArray(u3) ? km(u3, d3, f4) : Om(u3, d3, f4)), J(`span`, t2, { state: g5, ref: [n2, l5.context.valueRef], props: [{ children: _5 }, c3], stateAttributesMapping: wb }); +}); +var Eb = x.forwardRef(function e26(t2, n2) { + Reflect.set(e26, `d`, 3089558108); + let r2 = mb(), i3 = r2.useState(`mounted`), a3 = r2.useState(`forceMount`); + return i3 || a3 ? (0, b.jsx)(Ii, { ref: n2, ...t2 }) : null; +}); +var Db = { ...je2, ...ve2 }; +var Ob = x.forwardRef(function e27(t2, n2) { + Reflect.set(e27, `d`, 2365726996); + let { render: r2, className: i3, style: a3, ...o3 } = t2, s3 = mb(), c3 = s3.useState(`open`), l5 = s3.useState(`mounted`); + return J(`div`, t2, { state: { open: c3, transitionStatus: s3.useState(`transitionStatus`) }, ref: n2, props: [{ role: `presentation`, hidden: !l5, style: { userSelect: `none`, WebkitUserSelect: `none` } }, o3], stateAttributesMapping: Db }); +}); +var kb = x.createContext(void 0); +function Ab() { + let e38 = x.useContext(kb); + if (!e38) throw Error(C(59)); + return e38; +} +function jb(e38, t2) { + e38 && Object.assign(e38.style, t2); +} +var Mb = { position: `relative`, maxHeight: `100%`, overflowX: `hidden`, overflowY: `auto` }; +var Nb = { position: `fixed` }; +var Pb = x.forwardRef(function e28(t2, n2) { + Reflect.set(e28, `d`, 683438690); + let { anchor: r2, className: i3, render: a3, positionMethod: o3, side: s3, align: c3, sideOffset: l5, alignOffset: u3, collisionBoundary: d3 = `clipping-ancestors`, collisionPadding: f4, arrowPadding: p4, sticky: m3, disableAnchorTracking: h4, alignItemWithTrigger: g5 = true, collisionAvoidance: _5 = ki, style: v5, ...y4 } = t2, S2 = mb(), C2 = hb(), w2 = S2.useState(`open`), T2 = S2.useState(`mounted`), E2 = S2.useState(`modal`), D2 = S2.useState(`value`), O2 = S2.useState(`openMethod`), k2 = S2.useState(`positionerElement`), A2 = S2.useState(`triggerElement`), j2 = S2.useState(`isItemEqualToValue`), M2 = S2.useState(`transitionStatus`), N3 = x.useRef(null), P3 = x.useRef(null), [F2, I2] = x.useState(g5), L3 = T2 && F2 && O2 !== `touch`; + !T2 && F2 !== g5 && I2(g5), x.useImperativeHandle(S2.context.alignItemWithTriggerActiveRef, () => L3), Yh((L3 || E2) && w2, O2 === `touch`, k2, A2); + let R3 = Uh({ anchor: r2, floatingRootContext: C2, positionMethod: o3, mounted: T2, side: s3, sideOffset: l5, align: c3, alignOffset: u3, arrowPadding: p4, collisionBoundary: d3, collisionPadding: f4, sticky: m3, disableAnchorTracking: h4 ?? L3, collisionAvoidance: _5, keepMounted: true }), z2 = L3 ? `none` : R3.side, ee2 = L3 ? Nb : R3.positionerStyles, B3 = { open: w2, side: z2, align: R3.align, anchorHidden: R3.anchorHidden }; + X(() => { + S2.set(`popupSide`, R3.side); + }, [S2, R3.side]); + let V3 = qh(t2, B3, { styles: ee2, transitionStatus: M2, props: y4, refs: [n2, S2.useStateSetter(`positionerElement`)], hidden: !T2, inert: !w2 }), H3 = x.useRef(0), U3 = Y((e38) => { + if (S2.context.valuesRef.current.length === 0) return; + let t3 = H3.current; + H3.current = e38.size; + let n3 = Q(_t); + if (t3 !== 0 && !S2.state.multiple && D2 !== null && gm(S2.context.valuesRef.current, D2, j2) === -1) { + let e39 = S2.context.initialValueRef.current, t4 = e39 != null && gm(S2.context.valuesRef.current, e39, j2) !== -1 ? e39 : null; + S2.context.setValue(t4, n3), t4 === null && (S2.set(`selectedIndex`, null), S2.context.selectedItemTextRef.current = null); + } + if (t3 !== 0 && S2.state.multiple && Array.isArray(D2)) { + let e39 = D2.filter((e40) => gm(S2.context.valuesRef.current, e40, j2) !== -1); + e39.length !== D2.length && (S2.context.setValue(e39, n3), e39.length === 0 && (S2.set(`selectedIndex`, null), S2.context.selectedItemTextRef.current = null)); + } + if (w2 && L3) { + S2.update({ scrollUpArrowVisible: false, scrollDownArrowVisible: false }); + let e39 = { height: `` }; + jb(k2, e39), jb(S2.context.popupRef.current, e39); + } + }), W3 = x.useMemo(() => ({ ...R3, side: z2, alignItemWithTriggerActive: L3, setControlledAlignItemWithTrigger: I2, scrollUpArrowRef: N3, scrollDownArrowRef: P3 }), [R3, z2, L3, I2]); + return (0, b.jsx)(hh, { elementsRef: S2.context.listRef, labelsRef: S2.context.labelsRef, onMapChange: U3, children: (0, b.jsxs)(kb.Provider, { value: W3, children: [T2 && E2 && (0, b.jsx)(wc, { inert: Cc(!w2), cutout: A2 }), V3] }) }); +}); +var Fb = `base-ui-disable-scrollbar`; +var Ib = { className: Fb, getElement(e38) { + return (0, b.jsx)(`style`, { nonce: e38, href: Fb, precedence: `base-ui:low`, children: `.${Fb}{scrollbar-width:none}.${Fb}::-webkit-scrollbar{display:none}` }); +} }; +var Lb = x.createContext(void 0); +var Rb = { disableStyleElements: false }; +function zb() { + return x.useContext(Lb) ?? Rb; +} +var Bb = `--transform-origin`; +var Vb = { ...je2, ...ve2 }; +var Hb = x.forwardRef(function e29(t2, n2) { + Reflect.set(e29, `d`, 208676454); + let { render: r2, className: i3, style: a3, finalFocus: o3, ...s3 } = t2, c3 = mb(), l5 = c3.useState(`multiple`), u3 = c3.useState(`readOnly`), d3 = c3.useState(`highlightItemOnHover`), f4 = hb(), { side: p4, align: m3, alignItemWithTriggerActive: h4, isPositioned: g5, setControlledAlignItemWithTrigger: _5 } = Ab(), v5 = a_(true) != null, y4 = Hc(), { nonce: S2, disableStyleElements: C2 } = zb(), w2 = c3.useState(`id`), T2 = c3.useState(`open`), E2 = c3.useState(`openMethod`), D2 = c3.useState(`mounted`), O2 = c3.useState(`popupProps`), k2 = c3.useState(`transitionStatus`), A2 = c3.useState(`triggerElement`), j2 = c3.useState(`positionerElement`), M2 = c3.useState(`listElement`), N3 = x.useRef(false), P3 = x.useRef(false), F2 = x.useRef({}), I2 = Jn(), L3 = Y((e38) => { + if (!j2 || !c3.context.popupRef.current || !P3.current) return; + let t3 = j2.style.top === `0px`, n3 = j2.style.bottom === `0px`; + if (N3.current || !h4 || !t3 && !n3) { + c3.context.handleScrollArrowVisibility(e38); + return; + } + let r3 = Gb(j2), i4 = Kb(j2.getBoundingClientRect().height, `y`, r3), a4 = ft(j2), o4 = Fe(j2), s4 = o4.getComputedStyle(j2), l6 = parseFloat(s4.marginTop), u4 = parseFloat(s4.marginBottom), d4 = Ub(o4.getComputedStyle(c3.context.popupRef.current)), f5 = Math.min(a4.documentElement.clientHeight - l6 - u4, d4), p5 = e38.scrollTop, m4 = Wb(e38), g6 = null, _6 = (e39) => { + j2.style.height = `${e39}px`; + }, v6 = t3 ? m4 - p5 : p5, y5 = Math.min(i4 + v6, f5); + if (v6 <= 1) { + let n4 = Hv(v6, 0, f5 - i4); + n4 > 0 && _6(i4 + n4), e38.scrollTop = t3 ? m4 : 0, f5 - (i4 + n4) <= 1 && (N3.current = true), c3.context.handleScrollArrowVisibility(e38); + return; + } + f5 - y5 > 1 ? g6 = t3 ? 1 / 0 : 0 : n3 && p5 < m4 && (g6 = p5 - (v6 - (i4 + v6 - f5))); + let b2 = Math.ceil(y5); + if (b2 !== 0 && _6(b2), g6 != null) { + let t4 = Hv(g6, 0, Wb(e38)); + Math.abs(e38.scrollTop - t4) > 1 && (e38.scrollTop = t4); + } + b2 >= f5 - 1 && (N3.current = true), c3.context.handleScrollArrowVisibility(e38); + }); + x.useImperativeHandle(c3.context.scrollHandlerRef, () => L3, [L3]), Da({ open: T2, ref: c3.context.popupRef, onComplete() { + T2 && c3.context.onOpenChangeComplete(true); + } }); + let R3 = { open: T2, transitionStatus: k2, side: p4, align: m3 }; + X(() => { + j2 && c3.context.popupRef.current && !Object.keys(F2.current).length && (F2.current = { top: j2.style.top || `0`, left: j2.style.left || `0`, right: j2.style.right, height: j2.style.height, bottom: j2.style.bottom, minHeight: j2.style.minHeight, maxHeight: j2.style.maxHeight, marginTop: j2.style.marginTop, marginBottom: j2.style.marginBottom }); + }, [c3, j2]), X(() => { + T2 || h4 || (P3.current = false, N3.current = false, jb(j2, F2.current)); + }, [T2, h4, j2]), X(() => { + let e38 = c3.context.popupRef.current; + if (!T2 || !A2 || !j2 || !e38 || h4 && !g5 || c3.state.transitionStatus === `ending`) return; + if (P3.current = true, e38.style.removeProperty(Bb), !h4) { + I2.request(() => c3.context.handleScrollArrowVisibility(M2 || e38)); + return; + } + let t3 = Yb(e38); + try { + let t4 = c3.context.selectedItemTextRef.current; + t4?.isConnected || (t4 = !c3.select(`hasSelectedValue`) && c3.context.firstItemTextRef.current?.isConnected ? c3.context.firstItemTextRef.current : null); + let n3 = c3.context.valueRef.current, r3 = Fe(j2), i4 = r3.getComputedStyle(j2), a4 = r3.getComputedStyle(e38), o4 = ft(A2), s4 = Gb(A2), l6 = qb(A2.getBoundingClientRect(), s4), u4 = qb(j2.getBoundingClientRect(), s4), f5 = l6.height, p5 = M2 || e38, m4 = p5.scrollHeight, h5 = parseFloat(a4.borderBottomWidth), g6 = parseFloat(i4.marginTop) || 10, v6 = parseFloat(i4.marginBottom) || 10, b2 = parseFloat(i4.minHeight) || 100, x2 = Ub(a4), S3 = o4.documentElement.clientHeight - g6 - v6, C3 = o4.documentElement.clientWidth, w3 = S3 - l6.bottom + f5, T3, E3 = y4 === `rtl` ? l6.right - u4.width : l6.left, D3 = 0; + if (t4 && n3) { + let e39 = qb(n3.getBoundingClientRect(), s4); + T3 = qb(t4.getBoundingClientRect(), s4), E3 = u4.left + (y4 === `rtl` ? e39.right - T3.right : e39.left - T3.left); + let r4 = e39.top - l6.top + e39.height / 2; + D3 = T3.top - u4.top + T3.height / 2 - r4; + } + let O3 = w3 + D3 + v6 + h5, k3 = Math.min(S3, O3), P4 = S3 - g6 - v6, I3 = O3 - k3, L4 = C3 - 5; + j2.style.left = `${Hv(E3, 5, L4 - u4.width)}px`, j2.style.height = `${k3}px`, j2.style.maxHeight = `none`, j2.style.marginTop = `${g6}px`, j2.style.marginBottom = `${v6}px`, e38.style.height = `100%`; + let R4 = Wb(p5), z3 = I3 >= R4 - 1; + z3 && (k3 = Math.min(S3, u4.height) - (I3 - R4)); + let ee3 = l6.top < 20 || l6.bottom > S3 - 20 || Math.ceil(k3) + 1 < Math.min(m4, b2), B3 = (r3.visualViewport?.scale ?? 1) !== 1 && an; + if (ee3 || B3) { + jb(j2, F2.current), _5(false); + return; + } + let V3 = Math.max(b2, k3); + if (z3) { + let e39 = Math.max(0, S3 - O3); + j2.style.top = u4.height >= P4 ? `0` : `${e39}px`, j2.style.height = `${k3}px`, p5.scrollTop = Wb(p5); + } else j2.style.bottom = `0`, p5.scrollTop = I3; + if (T3) { + let t5 = u4.top, n4 = u4.height, r4 = T3.top + T3.height / 2, i5 = Hv(n4 > 0 ? (r4 - t5) / n4 * 100 : 50, 0, 100); + e38.style.setProperty(Bb, `50% ${i5}%`); + } + (V3 === S3 || k3 >= x2) && (N3.current = true), c3.context.handleScrollArrowVisibility(p5), d3 && c3.state.selectedIndex === null && c3.state.activeIndex === null && c3.context.listRef.current[0] != null && c3.set(`activeIndex`, 0); + } finally { + t3(); + } + }, [c3, T2, j2, A2, h4, _5, I2, M2, d3, y4, g5]), x.useEffect(() => { + if (!h4 || !j2 || !T2) return; + let e38 = Fe(j2); + function t3(e39) { + c3.context.setOpen(false, Q(It, e39)); + } + return Vn(e38, `resize`, t3); + }, [c3, h4, j2, T2]); + let z2 = { ...M2 ? { role: `presentation` } : { role: `listbox`, "aria-multiselectable": l5 || void 0, "aria-readonly": u3 || void 0, id: `${w2}-list` }, onKeyDown(e38) { + v5 && hc.has(e38.key) && e38.stopPropagation(); + }, onScroll(e38) { + M2 || L3(e38.currentTarget); + }, ...h4 && { style: M2 ? { height: `100%` } : Mb }, className: !M2 && h4 ? Ib.className : void 0 }, ee2 = J(`div`, t2, { ref: [n2, c3.context.popupRef], state: R3, stateAttributesMapping: Vb, props: [O2, z2, Kh(k2), s3] }); + return (0, b.jsxs)(x.Fragment, { children: [!C2 && Ib.getElement(S2), (0, b.jsx)(ta, { context: f4, modal: false, disabled: !D2, openInteractionType: E2, returnFocus: o3, restoreFocus: true, children: ee2 })] }); +}); +function Ub(e38) { + let t2 = e38.maxHeight; + return t2.endsWith(`px`) && parseFloat(t2) || 1 / 0; +} +function Wb(e38) { + return _b(e38.scrollHeight, e38.clientHeight); +} +function Gb(e38) { + return zs.getScale(e38); } -function _g(e9, t2) { - t2 === void 0 && (t2 = {}); - let { open: n2, elements: { floating: r2 } } = e9, { duration: i3 = 250 } = t2, a3 = (typeof i3 == `number` ? i3 : i3.close) || 0, [o3, s3] = x.useState(`unmounted`), c2 = gg(n2, a3); - return !c2 && o3 === `close` && s3(`unmounted`), cm(() => { - if (r2) { - if (n2) { - s3(`initial`); - let e10 = requestAnimationFrame(() => { - Di.flushSync(() => { - s3(`open`); - }); - }); - return () => { - cancelAnimationFrame(e10); - }; - } - s3(`close`); +function Kb(e38, t2, n2) { + return e38 / n2[t2]; +} +function qb(e38, t2) { + return Or({ x: Kb(e38.x, `x`, t2), y: Kb(e38.y, `y`, t2), width: Kb(e38.width, `x`, t2), height: Kb(e38.height, `y`, t2) }); +} +var Jb = [[`transform`, `none`], [`scale`, `1`], [`translate`, `0 0`]]; +function Yb(e38) { + let { style: t2 } = e38, n2 = {}; + for (let [e39, r2] of Jb) n2[e39] = t2.getPropertyValue(e39), t2.setProperty(e39, r2, `important`); + return () => { + for (let [e39] of Jb) { + let r2 = n2[e39]; + r2 ? t2.setProperty(e39, r2) : t2.removeProperty(e39); } - }, [n2, r2]), { isMounted: c2, status: o3 }; + }; } -var ub = /<([a-zA-Z0-9]+)>([\s\S]*?)<\/\1>|<([a-zA-Z0-9]+)\/>/; -var db = { area: true, base: true, br: true, col: true, embed: true, hr: true, img: true, input: true, keygen: true, link: true, meta: true, param: true, source: true, track: true, wbr: true, menuitem: true }; -function fb(e9, t2 = {}) { - let n2 = e9.split(ub); - if (n2.length === 1) return e9; - let r2 = mb(0, `$lingui$`), i3 = [], a3 = n2.shift(); +var Xb = x.forwardRef(function e30(t2, n2) { + Reflect.set(e30, `d`, 2848138064); + let { render: r2, className: i3, style: a3, ...o3 } = t2, s3 = mb(), c3 = s3.useState(`multiple`), l5 = s3.useState(`readOnly`), { alignItemWithTriggerActive: u3 } = Ab(), d3 = s3.useState(`hasScrollArrows`), f4 = s3.useState(`openMethod`), p4 = { id: `${s3.useState(`id`)}-list`, role: `listbox`, "aria-multiselectable": c3 || void 0, "aria-readonly": l5 || void 0, onScroll(e38) { + s3.context.scrollHandlerRef.current?.(e38.currentTarget); + }, ...u3 && { style: Mb }, className: d3 && f4 !== `touch` ? Ib.className : void 0 }; + return J(`div`, t2, { ref: [n2, s3.useStateSetter(`listElement`)], props: [p4, o3] }); +}); +var Zb = x.createContext(void 0); +function Qb() { + let e38 = x.useContext(Zb); + if (!e38) throw Error(C(57)); + return e38; +} +var $b = x.memo(x.forwardRef(function e31(t2, n2) { + Reflect.set(e31, `d`, 435280251); + let { render: r2, className: i3, style: a3, value: o3 = null, label: s3, disabled: c3 = false, nativeButton: l5 = false, ...u3 } = t2, d3 = x.useRef(null), f4 = rg({ guess: true, label: s3, textRef: d3 }), p4 = mb(), { props: m3, multiple: h4, disabled: g5, readOnly: _5, isItemEqualToValue: v5 } = p4.useState(`itemRoot`), y4 = g5 || c3, S2 = p4.useState(`isActive`, f4.index), C2 = p4.useState(`open`), w2 = p4.useState(`isSelected`, o3), T2 = p4.useState(`isSelectedByFocus`, f4.index), E2 = f4.index, D2 = x.useRef(null); + X(() => { + let e38 = p4.context.valuesRef.current; + return e38[E2] = o3, () => { + delete e38[E2]; + }; + }, [E2, o3, p4]), X(() => { + let e38 = p4.state.value, t3 = p4.state.selectedIndex, n3 = t3, r3; + h4 && Array.isArray(e38) ? (n3 = ym(E2, o3, p4.context.valuesRef.current, e38, v5, t3), r3 = n3 === E2, E2 === t3 && !r3 && (p4.context.selectedItemTextRef.current = null)) : (r3 = e38 !== void 0 && pm(o3, e38, v5), r3 && (n3 = E2)), p4.set(`selectedIndex`, n3), r3 && d3.current && (p4.context.selectedItemTextRef.current = d3.current); + }, [E2, h4, v5, p4, o3]); + let O2 = x.useRef(`mouse`), k2 = x.useRef(false), { getButtonProps: A2, buttonRef: j2 } = Z({ disabled: y4, focusableWhenDisabled: true, native: l5, composite: true }), M2 = { disabled: y4, selected: w2, highlighted: S2 }; + function N3(e38) { + if (g5 || _5) return; + let t3 = p4.state.value; + if (h4) { + let n3 = Array.isArray(t3) ? t3 : [], r3 = w2 ? bm(n3, o3, v5) : [...n3, o3]; + p4.context.setValue(r3, Q(St, e38)); + } else p4.context.setValue(o3, Q(St, e38)), p4.context.setOpen(false, Q(St, e38)); + } + function P3() { + p4.context.selectionRef.current.dragY = 0; + } + let F2 = { role: `option`, "aria-selected": w2, tabIndex: C2 && S2 ? 0 : -1, onKeyDown(e38) { + p4.set(`activeIndex`, E2), e38.key === ` ` && p4.context.typingRef.current && e38.preventDefault(); + }, onClick(e38) { + let t3 = O2.current !== `touch`, n3 = e38.nativeEvent.pointerType, r3 = t3 && dn(e38.nativeEvent) && (n3 !== void 0 || S2), i4 = t3 && !r3 && !k2.current; + k2.current = false, !(y4 || i4) && N3(e38.nativeEvent); + }, onPointerEnter(e38) { + O2.current = e38.pointerType; + }, onPointerMove(e38) { + if (e38.pointerType === `mouse` && e38.buttons === 1) { + let t3 = p4.context.selectionRef.current; + t3.dragY += e38.movementY, t3.dragY ** 2 >= 64 && (t3.allowUnselectedMouseUp = true); + } + }, onPointerDown(e38) { + O2.current = e38.pointerType, k2.current = true, P3(); + }, onMouseUp() { + if (P3(), y4 || O2.current === `touch` || k2.current) return; + let e38 = !p4.context.selectionRef.current.allowSelectedMouseUp && w2, t3 = !p4.context.selectionRef.current.allowUnselectedMouseUp && !w2; + e38 || t3 || (k2.current = true, D2.current?.click(), k2.current = false); + } }, I2 = J(`div`, t2, { ref: [j2, n2, f4.ref, D2], state: M2, props: [m3, F2, u3, A2] }), L3 = x.useMemo(() => ({ selected: w2, index: E2, textRef: d3, selectedByFocus: T2 }), [w2, E2, d3, T2]); + return (0, b.jsx)(Zb.Provider, { value: L3, children: I2 }); +})); +var ex = x.forwardRef(function e32(t2, n2) { + Reflect.set(e32, `d`, 3900801053); + let { selected: r2 } = Qb(); + return t2.keepMounted || r2 ? (0, b.jsx)(ug, { ...t2, selected: r2, ref: n2 }) : null; +}); +var tx = x.memo(x.forwardRef(function e33(t2, n2) { + Reflect.set(e33, `d`, 2767128567); + let { index: r2, textRef: i3, selectedByFocus: a3 } = Qb(), o3 = mb(), { render: s3, className: c3, style: l5, ...u3 } = t2; + return J(`div`, t2, { ref: [x.useCallback((e38) => { + e38 && (r2 === 0 && (o3.context.firstItemTextRef.current = e38), a3 && (o3.context.selectedItemTextRef.current = e38)); + }, [o3, r2, a3]), n2, i3], props: u3 }); +})); +var nx = /<([a-zA-Z0-9]+)>([\s\S]*?)<\/\1>|<([a-zA-Z0-9]+)\/>/; +var rx = { area: true, base: true, br: true, col: true, embed: true, hr: true, img: true, input: true, keygen: true, link: true, meta: true, param: true, source: true, track: true, wbr: true, menuitem: true }; +function ix(e38, t2 = {}) { + let n2 = e38.split(nx); + if (n2.length === 1) return e38; + let r2 = ox(0, `$lingui$`), i3 = [], a3 = n2.shift(); a3 && i3.push(a3); - for (let [e10, a4, o3] of pb(n2)) { - let n3 = e10 === void 0 ? void 0 : t2[e10]; - (!n3 || db[n3.type] && a4) && (console.error(n3 ? `${n3.type} is a void element tag therefore it must have no children` : `Can't use element at index '${e10}' as it is not declared in the original translation`), n3 = (0, b.jsx)(b.Fragment, {})), Array.isArray(n3) && (n3 = (0, b.jsx)(b.Fragment, { children: n3 })), i3.push((0, x.cloneElement)(n3, { key: r2() }, a4 ? fb(a4, t2) : n3.props.children)), o3 && i3.push(o3); + for (let [e39, a4, o3] of ax(n2)) { + let n3 = e39 === void 0 ? void 0 : t2[e39]; + (!n3 || rx[n3.type] && a4) && (console.error(n3 ? `${n3.type} is a void element tag therefore it must have no children` : `Can't use element at index '${e39}' as it is not declared in the original translation`), n3 = (0, b.jsx)(b.Fragment, {})), Array.isArray(n3) && (n3 = (0, b.jsx)(b.Fragment, { children: n3 })), i3.push((0, x.cloneElement)(n3, { key: r2() }, a4 ? ix(a4, t2) : n3.props.children)), o3 && i3.push(o3); } return i3.length === 1 ? i3[0] : i3; } -function pb(e9) { - if (!e9.length) return []; - let [t2, n2, r2, i3] = e9.slice(0, 4); - return [[t2 || r2, n2 || ``, i3]].concat(pb(e9.slice(4, e9.length))); +function ax(e38) { + if (!e38.length) return []; + let [t2, n2, r2, i3] = e38.slice(0, 4); + return [[t2 || r2, n2 || ``, i3]].concat(ax(e38.slice(4, e38.length))); } -var mb = (e9 = 0, t2 = ``) => () => `${t2}_${e9++}`; -function hb(e9) { - Reflect.set(hb, `d`, 1951267697); - let { render: t2, component: n2, id: r2, message: i3, formats: a3, lingui: { i18n: o3, defaultComponent: s3 } } = e9, { values: c2, components: l4 } = _b(e9), u3 = o3 && typeof o3._ == `function` ? o3._(r2, c2, { message: i3, formats: a3 }) : r2, d3 = u3 ? fb(u3, l4) : null; +var ox = (e38 = 0, t2 = ``) => () => `${t2}_${e38++}`; +function sx(e38) { + Reflect.set(sx, `d`, 1951267697); + let { render: t2, component: n2, id: r2, message: i3, formats: a3, lingui: { i18n: o3, defaultComponent: s3 } } = e38, { values: c3, components: l5 } = lx(e38), u3 = o3 && typeof o3._ == `function` ? o3._(r2, c3, { message: i3, formats: a3 }) : r2, d3 = u3 ? ix(u3, l5) : null; if (t2 === null || n2 === null) return d3; - let f4 = s3 || gb, p4 = { id: r2, message: i3, translation: d3, children: d3 }; + let f4 = s3 || cx, p4 = { id: r2, message: i3, translation: d3, children: d3 }; if (t2 && n2) console.error("You can't use both `component` and `render` prop at the same time. `component` is ignored."); else if (t2 && typeof t2 != `function`) console.error(`Invalid value supplied to prop \`render\`. It must be a function, provided ${t2}`); else if (n2 && typeof n2 != `function`) return console.error(`Invalid value supplied to prop \`component\`. It must be a React component, provided ${n2}`), (0, b.jsx)(f4, { ...p4, children: d3 }); return typeof t2 == `function` ? t2(p4) : (0, b.jsx)(n2 || f4, { ...p4, children: d3 }); } -var gb = ({ children: e9 }) => e9; -var _b = (e9) => { - if (!e9.values) return { values: void 0, components: e9.components }; - let t2 = { ...e9.values }, n2 = { ...e9.components }; - return Object.entries(e9.values).forEach(([e10, r2]) => { +var cx = ({ children: e38 }) => e38; +var lx = (e38) => { + if (!e38.values) return { values: void 0, components: e38.components }; + let t2 = { ...e38.values }, n2 = { ...e38.components }; + return Object.entries(e38.values).forEach(([e39, r2]) => { if (typeof r2 == `string` || typeof r2 == `number`) return; let i3 = Object.keys(n2).length; - n2[i3] = (0, b.jsx)(b.Fragment, { children: r2 }), t2[e10] = `<${i3}/>`; + n2[i3] = (0, b.jsx)(b.Fragment, { children: r2 }), t2[e39] = `<${i3}/>`; }), { values: t2, components: n2 }; }; -var vb = (0, x.createContext)(null); -var yb = (e9) => (0, x.useContext)(vb); -function bb() { - return yb(); -} -var xb = ({ i18n: e9, defaultComponent: t2, children: n2 }) => { - Reflect.set(xb, `d`, 3228677160); - let r2 = (0, x.useRef)(e9.locale), i3 = (0, x.useCallback)(() => ({ i18n: e9, defaultComponent: t2, _: e9.t.bind(e9) }), [e9, t2]), [a3, o3] = (0, x.useState)(i3()); +var ux = (0, x.createContext)(null); +var dx = (e38) => (0, x.useContext)(ux); +function fx() { + return dx(); +} +var px = ({ i18n: e38, defaultComponent: t2, children: n2 }) => { + Reflect.set(px, `d`, 3228677160); + let r2 = (0, x.useRef)(e38.locale), i3 = (0, x.useCallback)(() => ({ i18n: e38, defaultComponent: t2, _: e38.t.bind(e38) }), [e38, t2]), [a3, o3] = (0, x.useState)(i3()); return (0, x.useEffect)(() => { let t3 = () => { - r2.current = e9.locale, o3(i3()); - }, n3 = e9.on(`change`, t3); - return r2.current !== e9.locale && t3(), n3; - }, [e9, i3]), r2.current ? (0, b.jsx)(vb.Provider, { value: a3, children: n2 }) : null; + r2.current = e38.locale, o3(i3()); + }, n3 = e38.on(`change`, t3); + return r2.current !== e38.locale && t3(), n3; + }, [e38, i3]), r2.current ? (0, b.jsx)(ux.Provider, { value: a3, children: n2 }) : null; }; -function Sb(e9) { - Reflect.set(Sb, `d`, 3182067861); - let t2 = yb(void 0); - return (0, b.jsx)(hb, { ...e9, lingui: t2 }); +function mx(e38) { + Reflect.set(mx, `d`, 3182067861); + let t2 = dx(void 0); + return (0, b.jsx)(sx, { ...e38, lingui: t2 }); } -var HA = s(((e9) => { +var Fj = s(((e38) => { var t2 = sandVaultReact().__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; - e9.c = function(e10) { - return t2.H.useMemoCache(e10); + e38.c = function(e39) { + return t2.H.useMemoCache(e39); }; })); -var UA = s(((e9, t2) => { - t2.exports = HA(); +var Ij = s(((e38, t2) => { + t2.exports = Fj(); })); -// ../../../../../private/dist/renderer/assets/index.eager-platform-BFGuCGzq.js +// ../../../../../private/dist/renderer/assets/index.eager-platform-CVpWlQMj.js var window2 = globalThis.window; var document2 = globalThis.document; +var HTMLElement2 = globalThis.HTMLElement; +var HTMLInputElement = globalThis.HTMLInputElement; +var HTMLTextAreaElement = globalThis.HTMLTextAreaElement; +var HTMLAnchorElement = globalThis.HTMLAnchorElement; +var Image = globalThis.Image; +var KeyboardEvent2 = globalThis.KeyboardEvent; +var FocusEvent = globalThis.FocusEvent; +var MouseEvent = globalThis.MouseEvent; +var MutationObserver2 = globalThis.MutationObserver; var ResizeObserver2 = globalThis.ResizeObserver; var cancelAnimationFrame2 = globalThis.cancelAnimationFrame; var getComputedStyle2 = globalThis.getComputedStyle; var requestAnimationFrame2 = globalThis.requestAnimationFrame; -function at2(e9) { - return typeof e9 == `object` && !!e9 && !Array.isArray(e9); -} -var Nt = class extends Error { +var navigator2 = globalThis.navigator; +var CSS2 = globalThis.CSS; +var Element2 = globalThis.Element; +var Node2 = globalThis.Node; +var Ht2 = class extends Error { failure; - constructor(e9, t2 = e9.code, n2) { - super(t2, n2), this.name = `ClassifiedFailure`, this.failure = e9; + constructor(e38, t2 = e38.code, n2) { + super(t2, n2), this.name = `ClassifiedFailure`, this.failure = e38; } }; -var Rt = { status: `loading` }; -var zt = { commit: `default` }; -var Bt = { commit: `transition` }; -var Vt = { retain: (e9) => e9 }; -var Ht = /* @__PURE__ */ Symbol(`dune.store.notInstalled`); -function Ut(e9) { - return (e9 ?? `transition`) === `transition` ? Bt : zt; -} -var Wt = class { +var qt2 = { status: `loading` }; +var Jt2 = { commit: `default` }; +var Yt2 = { commit: `transition` }; +var Xt2 = { retain: (e38) => e38 }; +var Zt2 = /* @__PURE__ */ Symbol(`dune.store.notInstalled`); +function Qt2(e38) { + return (e38 ?? `transition`) === `transition` ? Yt2 : Jt2; +} +var $t2 = class { #e = 0; #t = null; #n = false; - beforeRead(e9) { + beforeRead(e38) { } - installReadFailure(e9) { + installReadFailure(e38) { } - dispatchRead(e9 = `loud`) { + dispatchRead(e38 = `loud`) { if (this.#n) return Promise.resolve(); if (this.#t != null) return this.#t; let t2 = this.#e; - this.beforeRead(e9); - let n2 = this.readOnce().then((e10) => { - this.#n || t2 !== this.#e || this.installRead(e10); - }, (e10) => { + this.beforeRead(e38); + let n2 = this.readOnce().then((e39) => { + this.#n || t2 !== this.#e || this.installRead(e39); + }, (e39) => { if (!(this.#n || t2 !== this.#e)) { - if (!(e10 instanceof Nt)) throw e10; - this.installReadFailure(e10); + if (!(e39 instanceof Ht2)) throw e39; + this.installReadFailure(e39); } }).finally(() => { this.#t === n2 && (this.#t = null); @@ -2230,34 +6937,34 @@ var Wt = class { supersede() { this.#e += 1, this.#t = null; } - writeWith(e9, t2) { + writeWith(e38, t2) { this.#e += 1; let n2 = this.#e; - return Promise.resolve().then(e9).then((e10) => this.#n || n2 !== this.#e ? e10 : (this.supersede(), t2(e10), e10), (e10) => { - throw !this.#n && n2 === this.#e && (this.#t = null, this.dispatchRead()), e10; + return Promise.resolve().then(e38).then((e39) => this.#n || n2 !== this.#e ? e39 : (this.supersede(), t2(e39), e39), (e39) => { + throw !this.#n && n2 === this.#e && (this.#t = null, this.dispatchRead()), e39; }); } - settleWriteWith(e9, t2, n2) { + settleWriteWith(e38, t2, n2) { this.#e += 1; let r2 = this.#e; - return Promise.resolve().then(e9).then((e10) => { - this.#n || r2 !== this.#e || (this.supersede(), t2(e10)); - }, (e10) => { - if (!this.#n && r2 === this.#e && n2(e10)) { + return Promise.resolve().then(e38).then((e39) => { + this.#n || r2 !== this.#e || (this.supersede(), t2(e39)); + }, (e39) => { + if (!this.#n && r2 === this.#e && n2(e39)) { this.supersede(); return; } - throw e10; + throw e39; }); } - ingestWith(e9) { - this.#n || (this.supersede(), e9()); + ingestWith(e38) { + this.#n || (this.supersede(), e38()); } disposeEngine() { this.#n || (this.#n = true, this.supersede()); } }; -var Gt = class extends Wt { +var en2 = class extends $t2 { spec; snapshots; #e; @@ -2266,47 +6973,47 @@ var Gt = class extends Wt { #r; #i; #a = null; - #o = Ht; + #o = Zt2; #s = 0; - constructor(e9, t2, n2 = {}) { - super(), this.spec = e9, this.snapshots = t2, this.#e = Ut(n2.settle), this.#t = Ut(n2.ingest), this.#n = e9.readObserver ?? null, this.#r = e9.failurePolicy ?? Vt, this.#i = e9.clock ?? s2; + constructor(e38, t2, n2 = {}) { + super(), this.spec = e38, this.snapshots = t2, this.#e = Qt2(n2.settle), this.#t = Qt2(n2.ingest), this.#n = e38.readObserver ?? null, this.#r = e38.failurePolicy ?? Xt2, this.#i = e38.clock ?? s2; } - onSettle(e9) { + onSettle(e38) { let t2 = this.#a ??= /* @__PURE__ */ new Set(); - return t2.add(e9), () => { - t2.delete(e9); + return t2.add(e38), () => { + t2.delete(e38); }; } load() { - return this.#o === Ht ? this.dispatchRead() : this.spec.freshMs == null || this.#u() && this.snapshots.get().status === `ready` ? Promise.resolve() : this.dispatchRead(`quiet`); + return this.#o === Zt2 ? this.dispatchRead() : this.spec.freshMs == null || this.#u() && this.snapshots.get().status === `ready` ? Promise.resolve() : this.dispatchRead(`quiet`); } refresh() { return this.supersede(), this.dispatchRead(); } heal() { - let e9 = this.snapshots.get().status; - (this.#o !== Ht || e9 === `failed` || e9 === `empty`) && this.dispatchRead(); + let e38 = this.snapshots.get().status; + (this.#o !== Zt2 || e38 === `failed` || e38 === `empty`) && this.dispatchRead(); } expire() { - this.supersede(), this.#o !== Ht && (this.#s = -1 / 0); + this.supersede(), this.#o !== Zt2 && (this.#s = -1 / 0); } - write(e9) { - return this.writeWith(e9, (e10) => this.#d(e10, this.#e)); + write(e38) { + return this.writeWith(e38, (e39) => this.#d(e39, this.#e)); } - settleWrite(e9) { - return this.settleWriteWith(e9, (e10) => this.#d(e10, this.#e), (e10) => e10 instanceof Nt && (this.installReadFailure(e10), true)); + settleWrite(e38) { + return this.settleWriteWith(e38, (e39) => this.#d(e39, this.#e), (e39) => e39 instanceof Ht2 && (this.installReadFailure(e39), true)); } - ingest(e9) { + ingest(e38) { this.ingestWith(() => { - if (e9 == null) { + if (e38 == null) { this.#f(this.#t); return; } - this.#d(e9, this.#t); + this.#d(e38, this.#t); }); } reset() { - this.supersede(), this.#c(), this.snapshots.set(Rt, zt); + this.supersede(), this.#c(), this.snapshots.set(qt2, Jt2); } dispose() { this.#a?.clear(), this.disposeEngine(); @@ -2314,146 +7021,148 @@ var Gt = class extends Wt { readOnce() { return this.spec.read(); } - beforeRead(e9) { + beforeRead(e38) { let t2 = this.#o; - if (t2 !== Ht) { - e9 === `loud` && this.spec.quietRevalidation == null && this.snapshots.set({ status: `loading`, previous: t2 }, zt); + if (t2 !== Zt2) { + e38 === `loud` && this.spec.quietRevalidation == null && this.snapshots.set({ status: `loading`, previous: t2 }, Jt2); return; } - this.snapshots.get().status !== `empty` && this.snapshots.set(Rt, zt); + this.snapshots.get().status !== `empty` && this.snapshots.set(qt2, Jt2); } - installRead(e9) { - if (this.#n?.noteSuccess(), e9 == null) { + installRead(e38) { + if (this.#n?.noteSuccess(), e38 == null) { this.#f(this.#e); return; } - this.#d(e9, this.#e); + this.#d(e38, this.#e); } - installReadFailure(e9) { - if (this.spec.unavailableCodes?.includes(e9.failure.code)) { - this.#l({ status: `unavailable`, reason: e9.failure.code }, this.#e); + installReadFailure(e38) { + if (this.spec.unavailableCodes?.includes(e38.failure.code)) { + this.#l({ status: `unavailable`, reason: e38.failure.code }, this.#e); return; } - this.#n?.noteFailure(e9.failure); + this.#n?.noteFailure(e38.failure); let t2 = this.#o; - if (t2 !== Ht) { - let e10 = this.#r.retain(t2); - e10 == null ? this.#c() : this.#o = e10; + if (t2 !== Zt2) { + let e39 = this.#r.retain(t2); + e39 == null ? this.#c() : this.#o = e39; } let n2 = this.#o; - this.#l(n2 === Ht ? { status: `failed`, failure: e9.failure } : { status: `failed`, previous: n2, failure: e9.failure }, this.#e); + this.#l(n2 === Zt2 ? { status: `failed`, failure: e38.failure } : { status: `failed`, previous: n2, failure: e38.failure }, this.#e); } #c() { - this.#o = Ht, this.#s = 0; + this.#o = Zt2, this.#s = 0; } - #l(e9, t2) { - this.snapshots.set(e9, t2); + #l(e38, t2) { + this.snapshots.set(e38, t2); let n2 = this.#a; - if (n2 !== null && n2.size > 0) for (let t3 of [...n2]) t3(e9); + if (n2 !== null && n2.size > 0) for (let t3 of [...n2]) t3(e38); } #u() { - return this.spec.freshMs != null && this.#o !== Ht && this.#i.monotonicNow() - this.#s < this.spec.freshMs; + return this.spec.freshMs != null && this.#o !== Zt2 && this.#i.monotonicNow() - this.#s < this.spec.freshMs; } - #d(e9, t2) { + #d(e38, t2) { let n2 = this.#i.monotonicNow(), r2 = this.#o; - if (r2 !== Ht && this.spec.quietRevalidation?.isSameValue(r2, e9) === true) { + if (r2 !== Zt2 && this.spec.quietRevalidation?.isSameValue(r2, e38) === true) { this.#s = n2; - let e10 = this.snapshots.get(); - this.#l(e10.status === `ready` ? e10 : { status: `ready`, value: r2 }, t2); + let e39 = this.snapshots.get(); + this.#l(e39.status === `ready` ? e39 : { status: `ready`, value: r2 }, t2); return; } - this.#o = e9, this.#s = n2, this.#l({ status: `ready`, value: e9 }, t2); + this.#o = e38, this.#s = n2, this.#l({ status: `ready`, value: e38 }, t2); } - #f(e9) { - this.#c(), this.#l({ status: `empty` }, e9); + #f(e38) { + this.#c(), this.#l({ status: `empty` }, e38); } }; -function Kt(e9) { - return { onSettle: (t2) => e9.onSettle(t2), load: () => e9.load(), refresh: () => e9.refresh(), heal: () => e9.heal(), expire: () => e9.expire(), write: (t2) => e9.write(t2), settleWrite: (t2) => e9.settleWrite(t2), ingest: (t2) => e9.ingest(t2), reset: () => e9.reset(), dispose: () => e9.dispose() }; +function tn2(e38) { + return { onSettle: (t2) => e38.onSettle(t2), load: () => e38.load(), refresh: () => e38.refresh(), heal: () => e38.heal(), expire: () => e38.expire(), write: (t2) => e38.write(t2), settleWrite: (t2) => e38.settleWrite(t2), ingest: (t2) => e38.ingest(t2), reset: () => e38.reset(), dispose: () => e38.dispose() }; } -function qt(e9, t2, n2 = {}) { - return Kt(new Gt(e9, t2, n2)); +function nn2(e38, t2, n2 = {}) { + return tn2(new en2(e38, t2, n2)); } -function Rn(e9) { - let t2 = e9, n2 = /* @__PURE__ */ new Set(), r2 = (e10) => { - if (!Object.is(e10, t2)) { - t2 = e10; - for (let e11 of [...n2]) e11(); +function qn2(e38) { + let t2 = e38, n2 = /* @__PURE__ */ new Set(), r2 = (e39) => { + if (!Object.is(e39, t2)) { + t2 = e39; + for (let e40 of [...n2]) e40(); } }; - return { get: () => t2, subscribe: (e10) => (n2.add(e10), () => { - n2.delete(e10); - }), set: r2, update: (e10) => r2(e10(t2)) }; + return { get: () => t2, subscribe: (e39) => (n2.add(e39), () => { + n2.delete(e39); + }), set: r2, update: (e39) => r2(e39(t2)) }; } -function zn(e9) { - let t2 = Rn(Rt); - return { snapshots: t2, ...qt(e9, t2) }; +function Jn2(e38) { + let t2 = qn2(qt2); + return { snapshots: t2, ...nn2(e38, t2) }; } -function G3(...e9) { - return y(e9); +function K2(...e38) { + return y(e38); } -function K2({ rootClass: e9, stylexStyles: t2, className: n2, style: r2 }) { +function q2({ rootClass: e38, stylexStyles: t2, className: n2, style: r2 }) { let i3 = h(t2); - return { className: G3(e9, i3.className, n2), style: { ...i3.style, ...r2 } }; -} -var q2 = Ke(); -var J2 = u(sandVaultReact(), 1); -var sr = `0account 1dd 1gent 5-circle 6square 5s 6-swarm 1larm-clock 2ert 1rchive 2my-base 2row-bend-up-left eright 7lock-bend-up-left cdown cleft dine-down hleft hright hup cright cup 7racket-from-down jleft jright jup l-dashed eto-down hleft hright hup 6ccw 7ircle-down dleft dright dup 7w 6down 6elbow-down-left hright cup-left fright 6left a-down bup 6right b-down cup 6square-down dfrom-down ileft iright iup dleft h-down itop iup dright i-down jtop jup dto-down gleft gright gup dup 7wap 6u-up-left bright 7p 5s-both-horizontal cvertical 7ccw a-angular 8ontract f-simple 8w 7down-up 7elbow-up-left 8xpand d-simple 7left-right 7out-cardinal 1sterisk 1t 2om 0bandaid 3knote 8s-stack 2rbell 2sketball 1each-umbrella 3ker 6-stop 2ehouse 2ll 4-dot 5slash 1inary 3oculars 1luetooth 1oard-kanban 2ok 4-open 4mark 4s 2wtie 1racket 7-dot 8error 7s-curly e-dot fx 9square 3in 5-hourglass 6simple cst 7lash 2iefcase 2owser 7s 2ush 1ug 3bot 2ilding 8s 2llseye 0calculator 3endar 8-hourglass 2mera 2r 3dholder 2stle 1d 1hart-bars 6line 6pie 7yramid 6scatter 3t-bubble b-chevrons-left-right cdashed cellipsis dxclamation cpencil dlus g-center cquestion bs c-grid 4Bubble a-ellipsis cxclamation bquestion as 2eck 5-circle 6square 5s 3f-hat 3ss-king 6tower 3vron-circle-down fleft fright fup 8down c-small 8left c-small 8right d-small 8up a-small 7s-down d-up 9left d-right 9right e-dotted-left 9up b-down 2ip 4-simple 1ircle 6-circle 7dashed 6s 7-check 1lipboard 2ock 3ne 3se 3ud 5-arrow-down cup 6download 6laptop 6upload 1ode 4-brackets 5simple 2g 2llection a-plus 3or-mode 2mmand 4ent 7-dashed 9iscussion 9ot 7s 3pass 7-check 8dot 2nversation 2okie 2pilot 3y 2rners-in 8out b-check csparkle 2st-high 5low 5medium 1redit-card 2oss-medical 5hair 3wn 2ystal-ball 1ube 4-coordinates 5nodes 5transparent 2rrency-btc 9dollar 9eth 3sor-logo 7text 2tlery 1ylinder 0dashboard 2tabase 8-network 1ebug-pause 6restart 6start 8op 2ckchair-umbrella 2sktop-download 2vice-camera d-video 7desktop 7mobile 1iagram 2ff 4-added 5ignored 5modified 6ultiple 5removed 7named 5single b-arrow-right-up cdot 2scard 3play 7-check 9ircle 9onnect 8mobile 8play 8waves 7s 1ots-3-horizontal 7vertical 1rop 0easel 1dit 1lephant 2lipsis 1nvelope 8-open 1raser 2ror 1xclamation-circle ctriangle 2ecution-parallel asequential 2tensions 1ye 3-closed 4slash 0fast-backward 5forward 1eedback 1ile 4-add 6rrow-right-up 5binary 5chevrons-left-right 6ode 5directory e-create 5image 5list 6ock 5media 5pdf 6lus 5text 6ype-adobe-illustrator gphotoshop ababel czel bevy bicep comejs bower bun ac-plus-plus csharp blojure brystal buda adart bocker aejs blixir bslint af-sharp birebase ageckodriver bit-meta bo cdot brails dphql coovy cunt bulp ahaml cndlebars cskell aionic ajava escript bulia cpyter akarma botlin alatex biquid amaven bustache anpm bunjucks aocaml bdata apdf berl blatformio bowershell brettier cisma colog buppet bython areason cscript bollup bust asass bbt bcala blim btylus bublime bvelte bwift aterraform bypescript avala bite bsc bue aweb-assembly dpack bindows ayarn azig 5zip 4s 3m-reel 5strip 3ter 1lag 4-hill 3me 3sk 5-slash-circle 2oppy-disc 1ocus-window 2ld-dashed 4er 6-active 8rrow-right-up 7check 7dashed 7library 7open bed 7plus 6s 2rk 1unnel 6-simple 0game-controller f-retro 2uge 1ear 2m 1ift 2t-branch 4commit a-horizontal 7pare 4fetch 5ork 4merge 4pull 8-request g-closed ireate hdone iraft 6sh 3hub 6-actions 1lobe 1raduation-cap 3ph 5-line 6scatter 2id 4-plus 5sparkle 3pper 0hamburger 3mer 2sh 2t 1eadphones 4set 3rt 2xagon 1istory 1ome 2urglass 3se 0i-circle 1mage 5-square 1nbox 2finity 3o 2spect 1ssue 5-closed 6draft 5s 0joystick 1son 0kebab-horizontal 6vertical 2y 3board 8-tab 0laptop 2yers 3out-dialog 7empty 7floating-window 7panel-bottom j-dock kon kundock doff 7sidebar-left j-dock koff ln kundock fright k-dock loff mn lundock 8plit-horizontal n-dashed oright-dock uundock dvertical 1eaf 2go 1ibrary 2ghtbulb 9-sparkle 5ning 2nk 4-external 2st-bullets 5checks 5filter 5ordered 5todo 9-subtask 5x 1oading 2cation 3k 4-locked 5unlocked 2go-azure a-devops 5figma 5git 8hub 8lab 5jira 5linear 5markdown 6cp 6icrosoft-teams 5notion 5python 5sentry 6lack 5vscode b-insiders 5x 0mac-mini 2gic-wand 3net 4ifying-glass g-fuzzy hminus hplus hslash-circle iparkle aGlass f-minus gplus gslash-circle 2il 2p 3-pin 2rk-github 4down 2sk-happy 4s-happy 1cp 1egaphone 2ntion 3u 2rge 1ic 3-slash 3roscope 2nus 5-circle 6small 1obile 2on 4-sparkle 5z 2re 1usic 2te 0new-file 5older 3spaper 1ote 0one-circle 1rganization c-filled 1wl 0package 7-zipper 2int-roller 2lette 2perclip 5plane 2ragraph 2ss 2use 5-circle 2w 1en-nib 3cil 6-square 3tagon 2ople 6-3 2rcent 3son 6-add 7chat-bubble 8ircle 7follow 7minus 7plus 1hone-disconnect 1iano 2e-chart 2lcrow 2n 3-slash 2pe 1lan 4e 3y 4-bug 5circle 5slow 6uper-fast 4back-loop 4s-bug 2ug 4-slash 3s 4-circle 5minus 1ointer-arrow 1ug 2lse 2zzle-piece 0question 8-circle 2ote 0radar 3io-tower 1ect-magnifying-glass fGlass 2do 2fresh 2gex 2mote-control 4ve 6-close 2place 7-all 3ort 2turn 2view 1obot 5-plus 2cket 4ing-chair 1ss 1uler 4s 2n 0satellite 1cales 1eal 4-check 5question 3rch 6-stop 2nd 2rver 6s 2ttings 8-gear 1hapes-square-circle 3re 2ield 6-check 7question 7x 2oe-fast 3pping-bag bsket 1ignal 1kills 6-capability 1lash-circle 2iders 1martwatch 2iley-happy c-square 7neutral 7plus 7sad 1nowflake 1occer-ball 2rt-ascending 5descending 2urce-control 1parkle 7s 2eaker-hifi 8waves 8x 2inner 2lit 5-horizontal 6vertical 2rint 1quare 6-dashed 8ot 6s 7-minus 8plus 8x 1tack 3r 4-empty 5full 3tus-done 8raft 7needs-attention 2op 4-circle 4watch 3refront 1un 1watches 1ymbol-folder 2nc 0t-shirt 1able 3s 2g 3s-chevron-down dleft dright dup 2rget 1erminal 8-rectangle 2xt-aa 6b 5b 5c 5d 5italic 5j 5r 5s 6trikethrough 5t 6-square 6t 5underline 5y 1hinking-high 9low 9medium 2reads-parallel 8single 4e-bars 2umbs-down 7up 9-down 6down 6up 1raffic-cone 7Cone 3sh 5can 3y 2easure-chest 3nding-down 9up 2iangle-small-down fleft fright fup 1wig 0unfold-dashed 2lock 2mute 2verified 0vault 1erified 3sions 1ideo-camera 1m 1r 2-headset a-head 0wallet 2nd 2rning 2tch 2veform 1hole-word 1indow 6-pointer-arrow 6s 1rench 0x 1-circle 0yarn 0zap 1ipper 1oom-in 5out 1zz`; -var cr2 = `1ajd -8p 1wz t 1 1 -w ah -273 18 1wb a9 3 -6 -ke 1 iy 2 2 2 -j3 1 3s 1 a -1f5 -1 -1 1f6 -1 -1 -1ok 8a 1 1 1 -5k -4d 9c 1ww 1 1 -269 1m4 1 -1m4 1m5 -zs 10y 2q -1 -1ra 8u 1ft 7 -1 0 -7 6 -114 0 -k 145 -1r8 1r7 -2k -1ez c9 13u -1od -8 1m9 1x -1v 1w -1v -1na 1nb k4 -i9 -1u -1dw -4p il -a2 1jz 1 5n -5m 1 1 1 -1xc a0 1nd -1w8 6w 32 -80 3k 1qr -1sb 1r8 -1v4 1 6v 1ue -1yb 5y 1 -5z 5y 1 -9o l9 1bp 1 1 1 -1w3 2 39 i8 -lg bu 1k7 1 -1mx 1my -1w2 1ut -1tn 1ux 1 1 1 -1tv 67 2 1md -1me c2 -9q 1v6 -gt -1l6 ht 1k2 1 -oa 7o 5w -1an 14n -1l6 1dm 7o -1pa lk 108 -1ep 1p2 1 1 8d 2 2 2 -24o 1lr -1lq 1lr -1lq 1lr -1lq 1lr -1k3 2 kf zn 1y -11z -k2 k7 -c2 1kx -1np -e es -mc bb bf -9 -dw c6 -d4 -6g 1 -1 25i -25h 1vr -1xc 1xd -1ub 1lz c -1np 1le -1nx bn 1fm -1fq -8z 7i 2 -1 1h6 70 -1mk -1w -3j -1 1hq ab -1e 1 1 -1uc 1vp 1 6n -6m -1ac 1ad -1ah 103 af 1 1 -1a3 10r 9d 1 1 -1vt 1vu -70 -1oq 1oo -1it 1pw -1w7 o -1 -2n 2p 1tv -1tp -5 1 1 91 -90 1 8y -n 1 ae -lk 73 1 1b 1za -20k 1zf 1 -26j 44 1yc -4a -1yf 21u -21l 4g -1 hx -m1 mt -nk 1wk 1 -1t7 -3a 1qg -1n5 1tb 1 -5n -1qp lu -in -37 32 -32 8 -3 2y a1 -9l -g 1 iq 1ce 41 -2 28 -p 5 -16 46 -18 1a -5x 1 j 4 2x 2e -7a 58 -2m 1y -2j x r -3o 1 3v -s -32 4j 1e -y o -b -2z -2c 1 1 1 3e -3d 1 34 1f k -1x c r 1k -2t u 21 -1u -1m 4o -2y m -2m -24 4u -s -41 1 2q 24 -3m 3q -12 -x -2y 1 1 1 3f -3e 3c -3b 14 -13 1 3f p -24d 39 1v0 1 -1v0 9a -7z -1a -3d a0 -46 ij 3 -o6 37 -9 9 23b -1wu -6g -38 -3 30 1tf -1ta 42 1qz 1 -1w2 17 28 -27 jf -jc 1l3 -1l2 80 -ca 4b 1u -64 ae -u 3u -2z -4a -59 3f 2 w -u 67 1 1od 1 1 -1um 1un -1bs 1dm -1t 1 1 -1up 1xy -21l 3o jt -jt -42 de 1ae -1jn hx -m2 9p -5h j2 -dd df 1bf -1ug -43 44 1 ij -a8 ba -e8 1x9 1 1 -1w0 20 -2f 1d7 -1cs 1 20 -20 -f 18n -18a 23 -23 -c 18n -15r -1 1be 1 -1in 1sh 1 -1ql -8r bz be -id k1 -1t -ky 5s -31 je 191 -1uu ln -j4 -4l 0 73 2s g 1mq ad -26z 1wn 54 -53 -7n -1ci 1p9 -53 -1kk 1po -53 -1l1 1 -54 1rs -1p7 -x -8x bk -3v -1 -1f 76 -df 7p -1 -1f -1e 6h -6j -46 49 1u6 1 -1lx -89 8n -5d n 2v 1w9 -27m 5e 1ib b3 -1w2 1l0 b3 1 -1yr bj -6v h5 -lp 1yo -1u2 1ru -1wi 0 24k -1zt 1us -s 1 -1lq -1x 1ci -10n 142 -3e b5 -b4 -1o0 oa 1ds -21r 1yu -1mp -cs 9y -1j 3 1g 1yj -1yj 1yc -1w7 -1i -2v -2a 1r4 85 -gc b5 -7v -1jd l 1ob 1 -l -1m9 -4v -2l -34 1jm 5s -1bf 1sd -20j 1tx -b5 -1ir 1 1tw -1tv 1lp 0 -1lm 0 1 21d -21a g7 15b 0 -1lb 4o 1dp -1c7 1vx -221 1tg -1td -4x 1vi -56 7z -1uv 1jq -1gx -1 -7d 69 5d 1og -1tr 2 -2i 1vm -1n9 -5u 32 2 -1 1q1 1 1 1 -1ny 0 -9f 45 1hz -51 gb -ga -1ds 1dq gd 1 -bb 1 -113 -bo 0 1o2 -1sd -29 iu 19h -1jn -79 1qn -1x0 270 -a3 -1uw a 5s -5w 7l -a0 0 6n gx 1 1 13z -1iu 1o3 2z -ba bb -1z5 -c 1zi -1qm 1dz -1nc 26w 2 2 2 -1vw 1sm -22x 18 3h -3v 20b -2 -1xb 1yi -12 2b 1 -fr -19 -1g8 219 -5z -54 1 1 -r 1 -1ph fg 1 1l8 -1l9 1 14m 0 -1qk 0 3s 1vh 1 1 -1sq 1 1 1 1w2 -1ej -hg 1 1 1sj -1si 1 -4f -2n 1zk 60 1 -60 -1ob -bo 7k 1sg -1se 1 2a 1da -1g2 et -l7 230 -1s3 1od -1sc 1 1sc`; -var lr2 = `01070e0f0g0h0i0j0k0l0r0w0x0y0z11161718191a1b1c1h1i1j1k1l1m1n1o1t1x2c2d2q2t2v2w2y2z323c3d3f3n3r3u3x3y3z4043454648494b4c4d4e4f4k4l4m4n4o4p4q4r4s4t4u4v5657595c5d5e5f5j5n5o5p5q5r5s5v5y616263646c6f6h6j6k6m6n6o6t6v6x6y71727374767778797a7b7c7d7g7h7l7o7r7u7w7z8084858a8b8e8g8h8p8q8r8s8t8u8v8w8x8y8z909192939495969798999a9b9c9d9e9f9g9h9i9j9k9l9m9n9o9p9q9r9s9t9u9v9w9x9y9za0a1a2a3a4a5a6a7a8a9aaabacadaeafagahaiajakalamanaoapaqarasatauavawaxayazb1b3b8b9bbbibrbsbubvbwbxbzc0c1c2c3c4c5c6c7cacfcgclcpcqcvcwcxd0d2d3d5d7dcdddedidmdndpdsdudxe1e5e6e7e9eeeiejekelf7f9fafdfefffhfjflfqftfufwfxfzg0g4g5gdgegfghgjgkglgmgngsgwh1h3h5h7h9hahchehjhlhmhohphti2i3i4iaibihikilinipisitiuiwixiyizj4j5j6j7j9jbjdjijjjkjmjnjqjrjtjwjxjyjzk0k1k2k4k6k7k8kbkdkgkhkikjkkklkmkpkqktkukwkxl0l1l3l4lblclelfliljlslulvlylzm0m1m6m9mbmdmfmgmhmimjmkml`; -var ur2 = `1c6d br -fj 1 ep 2 2 2 -eu 1 ap -ao 1 1 1 1 3 -2 1 4 -2 1 2 3 -2 1 0 4 -2 1 0 2 1 1 93 4a -dc 1 1 aj 2q 0 -d8 1 1 1 8p -8o 4 -3 fg -ff fp -fo 2 -1 -2 1 2 3 -2 1 dv 2 2 2 -dy -1 3 -1 3 -1 3 -1 3 -1 2 1 8 34 -3b f5 -6q -8e 2 -1 2 1 -l m -m ac -76 -2j 1 bp -bm -2 1 8a -g -7s 1 -1qm 2j 1qq -3m 3t -2l 1e -1f -7 1 1 1 1 1 1 2r -2p eg -14 -43 -v -8d 2n -2m 1 1 -19 1a 0 0 5 7f 1c -2 28 -p 5 -16 46 -18 1a -3q 1 -1o 4 2x 2e -6p 4n -2m 1y -2j x r -33 50 -1p -s -2i 3z 1e -y o -b -2z -1s 28 2m -4t 2w -28 -n 2n 1f k -1x c r 1k -2t 2e h -1u -1m 4o -2y m -2m -1n 4d -s -3k 1 29 24 -3m 3q -12 -x 29 -4q 1 4o -1o -2z 2x -2w p -o 1 30 p -b0 1 7d -7c 1 1 1 0 -v w 1 2 -1 2 1 1 6 -1 -4 1 1 1 3 1 d8 1 -61 -77 7u -7t 2 -1 -1 3 -1v 13 bv -b2 2 1f -1e 0 1 0 1 0 1 1 8v -7t -11 -u v 6 -5 0 1 3 -2 1 1 -2 1 -17 19 av -dk 2q d1 -cz -1 2 1 1 q 99 -2p 34 -4a -63 6e -8w -1pu 1sd 74 -73 d6 -7 -fp 2r 9d -9c -1px 1py 1 2 -1 2 an -am bn -c1 1c -x cm -22q 1q6 -1 -k 8 j -2l 86 -5n -3 1 1 7 0 -5 1 1 1 1 -1r 1s 0 1 1 -15 1 15 4 -3 1 1 2 1 0 -3e 13 -17o 1a0 1 -25 7d 6d -bk an 2 2 2 -as 9l -3v -2 17 -12 -2 -5q c5 -5z 3k 1 -1 1 -9q 0 75 -8i z -c r 1 -2l 24 5s -5a 1 2 -1 7g -80 9q -am -1`; -var dr2 = 2; -function fr2(e9) { + return { className: K2(e38, i3.className, n2), style: { ...i3.style, ...r2 } }; +} +var fr2 = { "--ease": `var(--ease)`, "--ease-heavy": `var(--ease-heavy)`, "--ease-linear": `var(--ease-linear)`, "--ease-sharp": `var(--ease-sharp)`, __varGroupHash__: `ui-1nru5dy` }; +var J2 = it(); +var Y2 = u(sandVaultReact(), 1); +var br2 = u(Ti(), 1); +var xr2 = `0account 1dd 1gent 5-circle 6square 5s 6-swarm 1larm-clock 2ert 1rchive 2my-base 2row-bend-up-left eright 7lock-bend-up-left cdown cleft dine-down hleft hright hup cright cup 7racket-from-down jleft jright jup l-dashed eto-down hleft hright hup 6ccw 7ircle-down dleft dright dup 7w 6down 6elbow-down-left hright cup-left fright 6left a-down bup 6right b-down cup 6square-down dfrom-down ileft iright iup dleft h-down itop iup dright i-down jtop jup dto-down gleft gright gup dup 7wap 6u-up-left bright 7p 5s-both-horizontal cvertical 7ccw a-angular 8ontract f-simple 8w 7down-up 7elbow-up-left 8xpand d-simple 7left-right 7out-cardinal 1sterisk 1t 2om 0bandaid 3knote 8s-stack 2rbell 2sketball 1each-umbrella 3ker 6-stop 2ehouse 2ll 4-dot 5slash 1inary 3oculars 1luetooth 1oard-kanban 2ok 4-open 4mark 4s 2wtie 1racket 7-dot 8error 7s-curly e-dot fx 9square 3in 5-hourglass 6simple cst 7lash 2iefcase 2owser 7s 2ush 1ug 3bot 2ilding 8s 2llseye 0calculator 3endar 8-hourglass 2mera 2r 3dholder 2stle 1d 1hart-bars 6line 6pie 7yramid 6scatter 3t-bubble b-chevrons-left-right cdashed cellipsis dxclamation cpencil dlus g-center cquestion bs c-grid 4Bubble a-ellipsis cxclamation bquestion as 2eck 5-circle 6square 5s 3f-hat 3ss-king 6tower 3vron-circle-down fleft fright fup 8down c-small 8left c-small 8right d-small 8up a-small 7s-down d-up 9left d-right 9right e-dotted-left 9up b-down 2ip 4-simple 1ircle 6-circle 7dashed 6s 7-check 1lipboard 2ock 3ne 3se 3ud 5-arrow-down cup 6download 6laptop 6upload 1ode 4-block 6rackets 5simple 2g 2llection a-plus 3or-mode 2mmand 4ent 7-dashed 9iscussion 9ot 7s 3pass 7-check 8dot 2nversation 2okie 2pilot 3y 2rners-in 8out b-check csparkle 2st-high 5low 5medium 1redit-card 2oss-medical 5hair 3wn 2ystal-ball 1ube 4-coordinates 5nodes 5transparent 2rrency-btc 9dollar 9eth 3sor-logo 7text 2tlery 1ylinder 0dashboard 2tabase 8-network 1ebug-pause 6restart 6start 8op 2ckchair-umbrella 2sktop-download 2vice-camera d-video 7desktop 7mobile 1iagram 2ff 4-added 5ignored 5modified 6ultiple 5removed 7named 5single b-arrow-right-up cdot 2scard 3play 7-check 9ircle 9onnect 8mobile 8play 8waves 7s 1ots-3-horizontal 7vertical 1rop 0easel 1dit 1lephant 2lipsis 1nvelope 8-open 1raser 2ror 1xclamation-circle ctriangle 2ecution-parallel asequential 2tensions 1ye 3-closed 4slash 0fast-backward 5forward 1eedback 1ile 4-add 6rrow-right-up 5binary 5chevrons-left-right 6ode 5directory e-create 5image 5list 6ock 5media 5pdf 6lus 5text 6ype-adobe-illustrator gphotoshop ababel czel bevy bicep comejs bower bun ac-plus-plus csharp blojure brystal buda adart bocker aejs blixir bslint af-sharp birebase ageckodriver bit-meta bo cdot brails dphql coovy cunt bulp ahaml cndlebars cskell aionic ajava escript bulia cpyter akarma botlin alatex biquid amaven bustache anpm bunjucks aocaml bdata apdf berl blatformio bowershell brettier cisma colog buppet bython areason cscript bollup bust asass bbt bcala blim btylus bublime bvelte bwift aterraform bypescript avala bite bsc bue aweb-assembly dpack bindows ayarn azig 5zip 4s 3m-reel 5strip 3ter 1lag 4-hill 3me 3sk 5-slash-circle 2oppy-disc 1ocus-window 2ld-dashed 4er 6-active 8rrow-right-up 7check 7dashed 7library 7open bed 7plus 6s 2rk 1unnel 6-simple 0game-controller f-retro 2uge 1ear 2m 1ift 2t-branch 4commit a-horizontal 7pare 4fetch 5ork 4merge 4pull 8-request g-closed ireate hdone iraft 6sh 3hub 6-actions 1lobe 1raduation-cap 3ph 5-line 6scatter 2id 4-plus 5sparkle 3pper 0hamburger 3mer 2sh 2t 1eadphones 4set 3rt 2xagon 1istory 1ome 2urglass 3se 0i-circle 1mage 5-square 1nbox 2finity 3o 2spect 1ssue 5-closed 6draft 5s 0joystick 1son 0kebab-horizontal 6vertical 2y 3board 8-tab 0laptop 2yers 3out-dialog 7empty 7floating-window 7panel-bottom j-dock kon kundock doff 7sidebar-left j-dock koff ln kundock fright k-dock loff mn lundock 8plit-horizontal n-dashed oright-dock uundock dvertical 1eaf 2go 1ibrary 2ghtbulb 9-sparkle 5ning 2nk 4-external 2st-bullets 5checks 5filter 5numbers 5ordered 5todo 9-subtask 5x 1oading 2cation 3k 4-locked 5unlocked 2go-azure a-devops 5figma 5git 8hub 8lab 5jira 5linear 5markdown 6cp 6icrosoft-teams 5notion 5python 5sentry 6lack 5vscode b-insiders 5x 0mac-mini 2gic-wand 3net 4ifying-glass g-fuzzy hminus hplus hslash-circle iparkle aGlass f-minus gplus gslash-circle 2il 2p 3-pin 2rk-github 4down 2sk-happy 4s-happy 1cp 1egaphone 2ntion 3u 2rge 1ic 3-slash 3roscope 2nus 5-circle 6small 1obile 2on 4-sparkle 5z 2re 1usic 2te 0new-file 5older 3spaper 1ote 0one-circle 1rganization c-filled 1wl 0package 7-zipper 2int-roller 2lette 2perclip 5plane 2ragraph 2ss 2use 5-circle 2w 1en-nib 3cil 6-square 3tagon 2ople 6-3 2rcent 3son 6-add 7chat-bubble 8ircle 7follow 7minus 7plus 1hone-disconnect 1iano 2e-chart 2lcrow 2n 3-slash 2pe 1lan 4e 3y 4-bug 5circle 5slow 6uper-fast 4back-loop 4s-bug 2ug 4-slash 3s 4-circle 5minus 1ointer-arrow 1ug 2lse 2zzle-piece 0question 8-circle 2ote 5s 0radar 3io-tower 1ect-magnifying-glass fGlass 2do 2fresh 2gex 2mote-control 4ve 6-close 2place 7-all 3ort 2turn 2view 1obot 5-plus 2cket 4ing-chair 1ss 1uler 4s 2n 0satellite 1cales 1eal 4-check 5question 3rch 6-stop 2nd 2rver 6s 2ttings 8-gear 1hapes-square-circle 3re 2ield 6-check 7question 7x 2oe-fast 3pping-bag bsket 1ignal 1kills 6-capability 1lash-circle 2iders 1martwatch 2iley-happy c-square 7neutral 7plus 7sad 1nowflake 1occer-ball 2rt-ascending 5descending 2urce-control 1parkle 7s 2eaker-hifi 8waves 8x 2inner 2lit 5-horizontal 6vertical 2rint 1quare 6-dashed 8ot 6s 7-minus 8plus 8x 1tack 3r 4-empty 5full 3tus-done 8raft 7needs-attention 2op 4-circle 4watch 3refront 1un 1watches 1ymbol-folder 2nc 0t-shirt 1able 3s 2g 3s-chevron-down dleft dright dup 2rget 1erminal 8-rectangle 2xt-aa 6b 5b 5c 5d 5italic 5j 5r 5s 6trikethrough 5t 6-square 6t 5underline 5y 1hinking-high 9low 9medium 2reads-parallel 8single 4e-bars 2umbs-down 7up 9-down 6down 6up 1raffic-cone 7Cone 3sh 5can 3y 2easure-chest 3nding-down 9up 2iangle-small-down fleft fright fup 1wig 0unfold-dashed 2lock 2mute 2verified 0vault 1erified 3sions 1ideo-camera 1m 1r 2-headset a-head 0wallet 2nd 2rning 2tch 2veform 1hole-word 1indow 6-pointer-arrow 6s 1rench 0x 1-circle 0yarn 0zap 1ipper 1oom-in 5out 1zz`; +var Sr2 = `1ajd -8p 1wz t 1 1 -w ah -273 18 1wb a9 3 -6 -ke 1 iy 2 2 2 -j3 1 3s 1 a -1f5 -1 -1 1f6 -1 -1 -1ok 8a 1 1 1 -5k -4d 9c 1ww 1 1 -269 1m4 1 -1m4 1m5 -zs 10y 2q -1 -1ra 8u 1ft 7 -1 0 -7 6 -114 0 -k 145 -1r8 1r7 -2k -1ez c9 13u -1od -8 1m9 1x -1v 1w -1v -1na 1nb k4 -i9 -1u -1dw -4p il -a2 1jz 1 5n -5m 1 1 1 -1xc a0 1nd -1w8 6w 32 -80 3k 1qr -1sb 1r8 -1v4 1 6v 1ue -1yb 5y 1 -5z 5y 1 -9o l9 1bp 1 1 1 -1w3 2 39 i8 -lg bu 1k7 1 -1mx 1my -1w2 1ut -1tn 1ux 1 1 1 -1tv 67 2 1md -1me c2 -9q 1v6 -gt -1l6 ht 1k2 1 -oa 7o 5w -1an 14n -1l6 1dm 7o -1pa lk 108 -1ep 1p2 1 1 8d 2 2 2 -24o 1lr -1lq 1lr -1lq 1lr -1lq 1lr -1k3 2 kf zn 1y -11z -k2 k7 -c2 1kx -1np -e es -mc bb bf -9 -dw c6 -d4 -6g 1 -1 25i -25h 1vr a8 -27k 1xd -1ub 1lz c -1np 1le -1nx bn 1fm -1fq -8z 7i 2 -1 1h6 70 -1mk -1w -3j -1 1hq ab -1e 1 1 -1uc 1vp 1 6n -6m -1ac 1ad -1ah 103 af 1 1 -1a3 10r 9d 1 1 -1vt 1vu -70 -1oq 1oo -1it 1pw -1w7 o -1 -2n 2p 1tv -1tp -5 1 1 91 -90 1 8y -n 1 ae -lk 73 1 1b 1za -20k 1zf 1 -26j 44 1yc -4a -1yf 21u -21l 4g -1 hx -m1 mt -nk 1wk 1 -1t7 -3a 1qg -1n5 1tb 1 -5n -1qp lu -in -37 32 -32 8 -3 2y a1 -9l -g 1 iq 1ce 41 -2 28 -p 5 -16 46 -18 1a -5x 1 j 4 2x 2e -7a 58 -2m 1y -2j x r -3o 1 3v -s -32 4j 1e -y o -b -2z -2c 1 1 1 3e -3d 1 34 1f k -1x c r 1k -2t u 21 -1u -1m 4o -2y m -2m -24 4u -s -41 1 2q 24 -3m 3q -12 -x -2y 1 1 1 3f -3e 3c -3b 14 -13 1 3f p -24d 39 1v0 1 -1v0 9a -7z -1a -3d a0 -46 ij 3 -o6 37 -9 9 23b -1wu -6g -38 -3 30 1tf -1ta 42 1qz 1 -1w2 17 28 -27 jf -jc 1l3 -1l2 80 -ca 4b 1u -64 ae -u 3u -2z -4a -59 3f 2 w -u 67 1 1od 1 1 -1um 1un -1bs 1dm -1t 1 1 -1up 1xy -21l 3o jt -jt -42 de 1ae -1jn hx -m2 9p -5h j2 -dd df 1bf -1ug -43 44 1 ij -a8 ba -e8 1x9 1 1 -1w0 20 -2f 1d7 -1cs 1 20 -20 -f 18n -18a 23 -23 -c 18n -15r -1 1be 1 -1in 1sh 1 -1ql -8r bz be -id k1 -1t -ky 5s 20p -23q je 191 -1uu ln -j4 -4l 0 73 2s g 1mq ad -26z 1wn 54 -53 -7n -1ci 1p9 -53 -1kk 1po -53 -1l1 1 -54 1rs -1p7 -x -8x bk -3v -1 -1f 76 -df 7p -1 -1f -1e 6h -6j -46 49 1u6 1 -1lx -89 8n -5d n 2v 1w9 -27m 5e 1ib b3 -1w2 1l0 b3 1 -1yr bj -6v h5 -lp 1yo -1u2 1ru -1wi 0 24k -1zt 1us -s 1 -1lq -1x 1ci -10n 142 -3e b5 -b4 -1o0 oa 1ds -21r 1yu -1mp -cs 9y -1j 3 1g 1yj -1yj 1yc -1w7 -1i -2v -2a 1r4 85 -gc b5 -7v -1jd l 1ob 1 -l -1m9 -4v -2l -34 1jm 5s -1bf 1sd -20j 1tx -b5 -1ir 1 22z -93 -1tv 1lp 0 -1lm 0 1 21d -21a g7 15b 0 -1lb 4o 1dp -1c7 1vx -221 1tg -1td -4x 1vi -56 7z -1uv 1jq -1gx -1 -7d 69 5d 1og -1tr 2 -2i 1vm -1n9 -5u 32 2 -1 1q1 1 1 1 -1ny 0 -9f 45 1hz -51 gb -ga -1ds 1dq gd 1 -bb 1 -113 -bo 0 1o2 -1sd -29 iu 19h -1jn -79 1qn -1x0 270 -a3 -1uw a 5s -5w 7l -a0 0 6n gx 1 1 13z -1iu 1o3 2z -ba bb -1z5 -c 1zi -1qm 1dz -1nc 26w 2 2 2 -1vw 1sm -22x 18 3h -3v 20b -2 -1xb 1yi -12 2b 1 -fr -19 -1g8 219 -5z -54 1 1 -r 1 -1ph fg 1 1l8 -1l9 1 14m 0 -1qk 0 3s 1vh 1 1 -1sq 1 1 1 1w2 -1ej -hg 1 1 1sj -1si 1 -4f -2n 1zk 60 1 -60 -1ob -bo 7k 1sg -1se 1 2a 1da -1g2 et -l7 230 -1s3 1od -1sc 1 1sc`; +var Cr2 = `01070e0f0g0h0i0j0k0l0r0w0x0y0z11161718191a1b1c1h1i1j1k1l1m1n1o1t1x2c2d2q2t2v2w2y2z323c3d3f3n3r3u3x3y3z4043454648494b4c4d4e4f4k4l4m4n4o4p4q4r4s4t4u4v5657595c5d5e5f5j5m5o5p5q5r5s5t5w5z626364656d6g6i6k6l6n6o6p6u6w6y6z727374757778797a7b7c7d7e7h7i7m7p7s7v7x808185868b8c8f8h8i8q8r8s8t8u8v8w8x8y8z909192939495969798999a9b9c9d9e9f9g9h9i9j9k9l9m9n9o9p9q9r9s9t9u9v9w9x9y9za0a1a2a3a4a5a6a7a8a9aaabacadaeafagahaiajakalamanaoapaqarasatauavawaxayazb0b2b4b9babcbjbsbtbvbwbxbyc0c1c2c3c4c5c6c7c8cbcgchcmcqcrcwcxcyd1d3d4d6d8dddedfdjdndodqdtdvdye2e6e7e8eaeeegekelemenf9fbfcfffgfhfjflfnfsfvfwfyfzg1g2g6g7gfggghgjglgmgngogpgugyh3h5h7h9hbhchehghlhnhohqhrhvhxi5i6i7idieikinioiqisiviwixizj0j1j2j7j8j9jajcjejgjljmjnjpjqjtjujwjzk0k1k2k3k4k5k7k9kakbkekgkjkkklkmknkokpksktkwkxkzl0l3l4l6l7lelflhlilllmlvlxlym1m2m3m4m9mcmemgmimjmkmlmmmnmo`; +var wr2 = `1c6d br -fj 1 ep 2 2 2 -eu 1 ap -ao 1 1 1 1 3 -2 1 4 -2 1 2 3 -2 1 0 4 -2 1 0 2 1 1 93 4a -dc 1 1 aj 2q 0 -d8 1 1 1 8p -8o 4 -3 fg -ff fp -fo 2 -1 -2 1 2 3 -2 1 dv 2 2 2 -dy -1 3 -1 3 -1 3 -1 3 -1 2 1 8 34 -3b f5 8 -6y -8e 2 -1 2 1 -l m -m ac -76 -2j 1 bp -bm -2 1 8a -g -7s 1 -1qm 2j 1qq -3m 3t -2l 1e -1f -7 1 1 1 1 1 1 2r -2p eg -14 -43 -v -8d 2n -2m 1 1 -19 1a 0 0 5 7f 1c -2 28 -p 5 -16 46 -18 1a -3q 1 -1o 4 2x 2e -6p 4n -2m 1y -2j x r -33 50 -1p -s -2i 3z 1e -y o -b -2z -1s 28 2m -4t 2w -28 -n 2n 1f k -1x c r 1k -2t 2e h -1u -1m 4o -2y m -2m -1n 4d -s -3k 1 29 24 -3m 3q -12 -x 29 -4q 1 4o -1o -2z 2x -2w p -o 1 30 p -b0 1 7d -7c 1 1 1 0 -v w 1 2 -1 2 1 1 6 -1 -4 1 1 1 3 1 d8 1 -61 -77 7u -7t 2 -1 -1 3 -1v 13 bv -b2 2 1f -1e 0 1 0 1 0 1 1 8v -7t -11 -u ek -dp 6 -5 0 1 3 -2 1 1 -2 1 -17 19 av -dk 2q d1 -cz -1 2 1 1 q 99 -2p 34 -4a -63 6e -8w -1pu 1sd 74 -73 d6 -7 -fp 2r 9d -9c -1px 1py 1 2 -1 2 an -am d4 -1h -c1 1c -x cm -22q 1q6 -1 -k 8 j -2l 86 -5n -3 1 1 7 0 -5 1 1 1 1 -1r 1s 0 1 1 -15 1 15 4 -3 1 1 2 1 0 -3e 13 -17o 1a0 1 -25 7d 6d -bk an 2 2 2 -as 9l -3v -2 17 -12 -2 -5q c5 -5z 3k 1 -1 1 -9q 0 75 -8i z -c r 1 -2l 24 5s -5a 1 2 -1 7g -80 9q -am -1`; +var Tr2 = 2; +function Er2(e38) { let t2 = [], n2 = ``; - for (let r2 of e9.split(` `)) n2 = n2.slice(0, Number.parseInt(r2[0], 36)) + r2.slice(1), t2.push(n2); + for (let r2 of e38.split(` `)) n2 = n2.slice(0, Number.parseInt(r2[0], 36)) + r2.slice(1), t2.push(n2); return t2; } -function pr2(e9) { +function Dr2(e38) { let t2 = [], n2 = 0; - for (let r2 of e9.split(` `)) n2 += Number.parseInt(r2, 36), t2.push(String.fromCharCode(n2)); + for (let r2 of e38.split(` `)) n2 += Number.parseInt(r2, 36), t2.push(String.fromCharCode(n2)); return t2; } -var mr2 = fr2(sr); -function hr() { - let e9 = pr2(cr2), t2 = {}; - for (let n2 = 0; n2 < mr2.length; n2++) t2[mr2[n2]] = e9[n2]; +var Or2 = Er2(xr2); +function kr() { + let e38 = Dr2(Sr2), t2 = {}; + for (let n2 = 0; n2 < Or2.length; n2++) t2[Or2[n2]] = e38[n2]; return t2; } -function gr() { - let e9 = pr2(ur2), t2 = {}; - for (let n2 = 0; n2 < e9.length; n2++) { - let r2 = Number.parseInt(lr2.slice(n2 * dr2, (n2 + 1) * dr2), 36); - t2[mr2[r2]] = e9[n2]; +function Ar2() { + let e38 = Dr2(wr2), t2 = {}; + for (let n2 = 0; n2 < e38.length; n2++) { + let r2 = Number.parseInt(Cr2.slice(n2 * Tr2, (n2 + 1) * Tr2), 36); + t2[Or2[r2]] = e38[n2]; } return t2; } -var _r = hr(); -var vr = gr(); -var yr = { ..._r, ...vr }; -function br(e9, t2 = `outline`) { - return t2 === `filled` ? yr[e9] : _r[e9]; -} -var Er2 = { root: { km0Bbg: `ui-ngwomw`, $$css: true } }; -var Dr2 = { spin: { kKVMdj: `ui-138fvbv ui-19wobc1`, k44tkh: `ui-j9z2zm ui-tkjuqo`, kyAemX: `ui-1esw782 ui-1islxhi`, ko0y90: `ui-a4qsjk`, kKxzle: `ui-pvocbt`, $$css: true }, sweep: { kVAEAm: `ui-1n2onr6`, ktHQil: `ui-119n3hw ui-1hdkgjs`, kKVMdj: `ui-19wobc1`, k44tkh: `ui-tkjuqo`, kyAemX: `ui-1islxhi`, ko0y90: `ui-25wp3h`, kKxzle: `ui-yqzv00`, $$css: true }, sweepReduced: { ktHQil: `ui-11srvyv`, kKVMdj: `ui-1oqra75`, k44tkh: `ui-qg7g51`, kyAemX: `ui-rjyh25`, ko0y90: `ui-a4qsjk`, kKxzle: `ui-pvocbt`, $$css: true }, spoke: { kVAEAm: `ui-10l6tqk`, kpwlN0: `ui-10a8y8t`, k1xSpc: `ui-78zum5 ui-1exu0l6`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kgeoSG: `ui-1yj7g93`, kKVMdj: `ui-k9idh2`, k44tkh: `ui-j9z2zm`, kyAemX: `ui-1esw782`, ko0y90: `ui-a4qsjk`, $$css: true }, spoke0: { kX1K2I: `ui-13ezkzi`, kAExgp: `ui-lzwb1j`, kKxzle: `ui-16cf9d2`, $$css: true }, spoke1: { kX1K2I: `ui-i4psko`, kAExgp: `ui-d82sq`, kKxzle: `ui-11nsgkv`, $$css: true }, spoke2: { kX1K2I: `ui-n7gmq3`, kAExgp: `ui-124k67h`, kKxzle: `ui-sukks7`, $$css: true }, spoke3: { kX1K2I: `ui-hub3r8`, kAExgp: `ui-12bq6qt`, kKxzle: `ui-1pnb7fb`, $$css: true }, spoke4: { kX1K2I: `ui-zfkvjw`, kAExgp: `ui-1kpik2w`, kKxzle: `ui-pwfiqt`, $$css: true }, spoke5: { kX1K2I: `ui-s9yql1`, kAExgp: `ui-3ss5et`, kKxzle: `ui-5dknbk`, $$css: true }, spoke6: { kX1K2I: `ui-phepzq`, kAExgp: `ui-19zfhon`, kKxzle: `ui-c1re9y`, $$css: true }, spoke7: { kX1K2I: `ui-1o32pzs`, kAExgp: `ui-1qstbv1`, kKxzle: `ui-1isc9tx`, $$css: true }, spokeReduced: { k1xSpc: `ui-1s85apg`, $$css: true }, reduced: { kKVMdj: `ui-1oqra75`, k44tkh: `ui-qg7g51`, kyAemX: `ui-rjyh25`, $$css: true }, pulseWhenReduced: { kKVMdj: `ui-19wobc1`, k44tkh: `ui-tkjuqo`, kyAemX: `ui-1islxhi`, ko0y90: `ui-25wp3h`, kKxzle: `ui-yqzv00`, $$css: true }, pulse: { kKVMdj: `ui-1oqra75`, k44tkh: `ui-qg7g51`, kyAemX: `ui-rjyh25`, ko0y90: `ui-a4qsjk`, kKxzle: `ui-pvocbt`, $$css: true }, paused: { k5bvn2: `ui-orstpt`, $$css: true } }; -var Or = Dr2.spin; -var kr = Dr2.reduced; -var Ar = Dr2.sweep; -var jr = Dr2.sweepReduced; -var Mr = [{ angle: 0, style: [Dr2.spoke, Dr2.spoke0] }, { angle: 45, style: [Dr2.spoke, Dr2.spoke1] }, { angle: 90, style: [Dr2.spoke, Dr2.spoke2] }, { angle: 135, style: [Dr2.spoke, Dr2.spoke3] }, { angle: 180, style: [Dr2.spoke, Dr2.spoke4] }, { angle: 225, style: [Dr2.spoke, Dr2.spoke5] }, { angle: 270, style: [Dr2.spoke, Dr2.spoke6] }, { angle: 315, style: [Dr2.spoke, Dr2.spoke7] }]; -var Nr = Dr2.spokeReduced; -var Ir = Dr2.paused; -function Lr(e9) { +var jr2 = kr(); +var Mr2 = Ar2(); +var Nr2 = { ...jr2, ...Mr2 }; +function Pr2(e38, t2 = `outline`) { + return t2 === `filled` ? Nr2[e38] : jr2[e38]; +} +var Br2 = { root: { km0Bbg: `ui-ngwomw`, $$css: true } }; +var Vr2 = { spin: { kKVMdj: `ui-138fvbv ui-19wobc1`, k44tkh: `ui-j9z2zm ui-tkjuqo`, kyAemX: `ui-1esw782 ui-38oajo`, ko0y90: `ui-a4qsjk`, kKxzle: `ui-pvocbt`, $$css: true }, sweep: { kVAEAm: `ui-1n2onr6`, ktHQil: `ui-119n3hw ui-1hdkgjs`, kKVMdj: `ui-19wobc1`, k44tkh: `ui-tkjuqo`, kyAemX: `ui-38oajo`, ko0y90: `ui-25wp3h`, kKxzle: `ui-yqzv00`, $$css: true }, sweepReduced: { ktHQil: `ui-11srvyv`, kKVMdj: `ui-1oqra75`, k44tkh: `ui-qg7g51`, kyAemX: `ui-2cjhnf`, ko0y90: `ui-a4qsjk`, kKxzle: `ui-pvocbt`, $$css: true }, spoke: { kVAEAm: `ui-10l6tqk`, kpwlN0: `ui-10a8y8t`, k1xSpc: `ui-78zum5 ui-1exu0l6`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kgeoSG: `ui-1yj7g93`, kKVMdj: `ui-k9idh2`, k44tkh: `ui-j9z2zm`, kyAemX: `ui-1esw782`, ko0y90: `ui-a4qsjk`, $$css: true }, spoke0: { kX1K2I: `ui-13ezkzi`, kAExgp: `ui-lzwb1j`, kKxzle: `ui-16cf9d2`, $$css: true }, spoke1: { kX1K2I: `ui-i4psko`, kAExgp: `ui-d82sq`, kKxzle: `ui-11nsgkv`, $$css: true }, spoke2: { kX1K2I: `ui-n7gmq3`, kAExgp: `ui-124k67h`, kKxzle: `ui-sukks7`, $$css: true }, spoke3: { kX1K2I: `ui-hub3r8`, kAExgp: `ui-12bq6qt`, kKxzle: `ui-1pnb7fb`, $$css: true }, spoke4: { kX1K2I: `ui-zfkvjw`, kAExgp: `ui-1kpik2w`, kKxzle: `ui-pwfiqt`, $$css: true }, spoke5: { kX1K2I: `ui-s9yql1`, kAExgp: `ui-3ss5et`, kKxzle: `ui-5dknbk`, $$css: true }, spoke6: { kX1K2I: `ui-phepzq`, kAExgp: `ui-19zfhon`, kKxzle: `ui-c1re9y`, $$css: true }, spoke7: { kX1K2I: `ui-1o32pzs`, kAExgp: `ui-1qstbv1`, kKxzle: `ui-1isc9tx`, $$css: true }, spokeReduced: { k1xSpc: `ui-1s85apg`, $$css: true }, reduced: { kKVMdj: `ui-1oqra75`, k44tkh: `ui-qg7g51`, kyAemX: `ui-2cjhnf`, $$css: true }, pulseWhenReduced: { kKVMdj: `ui-19wobc1`, k44tkh: `ui-tkjuqo`, kyAemX: `ui-38oajo`, ko0y90: `ui-25wp3h`, kKxzle: `ui-yqzv00`, $$css: true }, pulse: { kKVMdj: `ui-1oqra75`, k44tkh: `ui-qg7g51`, kyAemX: `ui-2cjhnf`, ko0y90: `ui-a4qsjk`, kKxzle: `ui-pvocbt`, $$css: true }, paused: { k5bvn2: `ui-orstpt`, $$css: true } }; +var Hr2 = Vr2.spin; +var Ur2 = Vr2.reduced; +var Wr2 = Vr2.sweep; +var Gr2 = Vr2.sweepReduced; +var Kr2 = [{ angle: 0, style: [Vr2.spoke, Vr2.spoke0] }, { angle: 45, style: [Vr2.spoke, Vr2.spoke1] }, { angle: 90, style: [Vr2.spoke, Vr2.spoke2] }, { angle: 135, style: [Vr2.spoke, Vr2.spoke3] }, { angle: 180, style: [Vr2.spoke, Vr2.spoke4] }, { angle: 225, style: [Vr2.spoke, Vr2.spoke5] }, { angle: 270, style: [Vr2.spoke, Vr2.spoke6] }, { angle: 315, style: [Vr2.spoke, Vr2.spoke7] }]; +var qr2 = Vr2.spokeReduced; +var Xr2 = Vr2.paused; +function Zr2(e38) { let t2 = 5381; - for (let n2 = 0; n2 < e9.length; n2++) t2 = Math.imul(t2, 33) ^ e9.charCodeAt(n2); + for (let n2 = 0; n2 < e38.length; n2++) t2 = Math.imul(t2, 33) ^ e38.charCodeAt(n2); return (t2 >>> 0).toString(36); } -var Rr = typeof window2 < `u` ? J2.useLayoutEffect : J2.useEffect; -function zr({ enabled: e9, durationMs: t2, syncKey: n2, timestampMs: r2 }) { - if (!e9) return; - let i3 = t2 > 0 && n2 !== void 0 ? parseInt(Lr(n2), 36) % t2 : 0; +var Qr2 = typeof window2 < `u` ? Y2.useLayoutEffect : Y2.useEffect; +function $r2({ enabled: e38, durationMs: t2, syncKey: n2, timestampMs: r2 }) { + if (!e38) return; + let i3 = t2 > 0 && n2 !== void 0 ? parseInt(Zr2(n2), 36) % t2 : 0; return `-${t2 > 0 ? (r2 + i3) % t2 : 0}ms`; } -var Br = new class { +var ei2 = new class { constructor() { this.subscribers = /* @__PURE__ */ new Set(), this.emitCurrentSync = () => { this.emitSharedSync(this.getSharedTimestampMs()); @@ -2476,14 +7185,14 @@ var Br = new class { this.sharedTimestampMs = void 0; }), this.sharedTimestampMs) : this.sharedTimestampMs; } - subscribeAndSync(e9) { - return this.ensureGlobalSyncListeners(), this.subscribers.add(e9), e9(this.getSharedTimestampMs()), () => { - this.subscribers.delete(e9), this.subscribers.size === 0 && this.removeGlobalSyncListeners?.(); + subscribeAndSync(e38) { + return this.ensureGlobalSyncListeners(), this.subscribers.add(e38), e38(this.getSharedTimestampMs()), () => { + this.subscribers.delete(e38), this.subscribers.size === 0 && this.removeGlobalSyncListeners?.(); }; } - emitSharedSync(e9) { + emitSharedSync(e38) { this.subscribers.forEach((t2) => { - t2(e9); + t2(e38); }); } cancelPendingResync() { @@ -2495,281 +7204,432 @@ var Br = new class { }); } }(); -function Vr({ enabled: e9, durationMs: t2, syncKey: n2, resyncEpoch: r2 }) { - let [i3, a3] = (0, J2.useState)(void 0); - return Rr(() => { +function ti2({ enabled: e38, durationMs: t2, syncKey: n2, resyncEpoch: r2 }) { + let [i3, a3] = (0, Y2.useState)(void 0); + return Qr2(() => { let r3 = (r4) => { - let i4 = zr({ enabled: e9, durationMs: t2, syncKey: n2, timestampMs: r4 }); - a3((e10) => e10 === i4 ? e10 : i4); + let i4 = $r2({ enabled: e38, durationMs: t2, syncKey: n2, timestampMs: r4 }); + a3((e39) => e39 === i4 ? e39 : i4); }; - if (!e9) { + if (!e38) { a3(void 0); return; } - return Br.subscribeAndSync(r3); - }, [e9, t2, n2, r2]), i3; + return ei2.subscribeAndSync(r3); + }, [e38, t2, n2, r2]), i3; } -function Hr(e9) { +function ni2(e38) { if (typeof document2 > `u`) return () => void 0; let t2 = document2; - return t2.addEventListener(`visibilitychange`, e9), () => { - t2.removeEventListener(`visibilitychange`, e9); + return t2.addEventListener(`visibilitychange`, e38), () => { + t2.removeEventListener(`visibilitychange`, e38); }; } -function Ur() { +function ri2() { return typeof document2 > `u` ? false : document2.hidden; } -function Wr() { +function ii() { return false; } -function Gr() { - return (0, J2.useSyncExternalStore)(Hr, Ur, Wr); +function ai2() { + return (0, Y2.useSyncExternalStore)(ni2, ri2, ii); } -var Kr = `(prefers-reduced-motion: reduce)`; -var qr = (0, J2.createContext)(void 0); -function Jr(e9) { +var oi2 = `(prefers-reduced-motion: reduce)`; +var si2 = (0, Y2.createContext)(void 0); +function ci2(e38) { if (typeof window2 > `u` || typeof window2.matchMedia != `function`) return () => void 0; - let t2 = window2.matchMedia(Kr); - return typeof t2.addEventListener == `function` ? (t2.addEventListener(`change`, e9), () => { - t2.removeEventListener(`change`, e9); + let t2 = window2.matchMedia(oi2); + return typeof t2.addEventListener == `function` ? (t2.addEventListener(`change`, e38), () => { + t2.removeEventListener(`change`, e38); }) : () => void 0; } -function Yr() { - return typeof window2 > `u` || typeof window2.matchMedia != `function` ? false : window2.matchMedia(Kr).matches; +function li2() { + return typeof window2 > `u` || typeof window2.matchMedia != `function` ? false : window2.matchMedia(oi2).matches; } -function Xr() { +function ui2() { return false; } -function Zr() { - let e9 = (0, J2.useContext)(qr), t2 = (0, J2.useSyncExternalStore)(Jr, Yr, Xr); - return e9 ?? t2; -} -var Qr = 6e3; -var $r = { motionStyles: [], syncStyle: void 0, paused: false, reduced: false }; -function ei(e9, { sync: t2 = true, sweep: n2 = false } = {}) { - let r2 = Zr(), i3 = Gr(), a3 = Vr({ enabled: e9 && t2, durationMs: Qr }); - if (!e9) return $r; - let o3 = [n2 ? Ar : Or]; - return r2 && o3.push(n2 ? jr : kr), i3 && o3.push(Ir), { motionStyles: o3, syncStyle: a3 === void 0 ? void 0 : { "--cursor-spinner-sync-delay": a3 }, paused: i3, reduced: r2 }; -} -var ti = (0, J2.createContext)(void 0); -function ni({ iconSize: e9, iconButtonSize: t2, iconButtonFrame: n2, iconButtonVariant: r2, iconButtonTone: i3, iconButtonRootStyle: a3, iconButtonIconStyle: o3, iconButtonIconSize: s3, buttonSize: c2, buttonFrame: l4, buttonRootStyle: u3, buttonVariant: d3, buttonTone: f4, buttonPrimaryTone: p4, buttonIconSize: m3, buttonRounded: h3, buttonFullWidth: g3, menuSize: _2, disabled: v3, children: y3 }) { - ni.d = 2831495554; - let b3 = (0, J2.useContext)(ti), x3 = (0, J2.useMemo)(() => ({ iconSize: e9 ?? b3?.iconSize, iconButtonSize: t2 ?? b3?.iconButtonSize, iconButtonFrame: n2 ?? b3?.iconButtonFrame, iconButtonVariant: r2 ?? b3?.iconButtonVariant, iconButtonTone: i3 ?? b3?.iconButtonTone, iconButtonRootStyle: a3 ?? b3?.iconButtonRootStyle, iconButtonIconStyle: o3 ?? b3?.iconButtonIconStyle, iconButtonIconSize: s3 ?? b3?.iconButtonIconSize, buttonSize: c2 ?? b3?.buttonSize, buttonFrame: l4 ?? b3?.buttonFrame, buttonRootStyle: u3 ?? b3?.buttonRootStyle, buttonVariant: d3 ?? b3?.buttonVariant, buttonTone: f4 ?? b3?.buttonTone, buttonPrimaryTone: p4 ?? b3?.buttonPrimaryTone, buttonIconSize: m3 ?? b3?.buttonIconSize, buttonRounded: h3 ?? b3?.buttonRounded, buttonFullWidth: g3 ?? b3?.buttonFullWidth, menuSize: _2 ?? b3?.menuSize, disabled: v3 ?? b3?.disabled }), [l4, g3, p4, f4, m3, u3, h3, c2, d3, v3, n2, s3, o3, i3, a3, t2, r2, e9, _2, b3]); - return (0, q2.jsx)(ti.Provider, { value: x3, children: y3 }); -} -function ri() { - return (0, J2.useContext)(ti); -} -var ii = /(^|-)(left|right)(-|$)/; -var ai = /* @__PURE__ */ new Set([`history`, `link-external`, `list-bullets`, `list-ordered`, `quote`, `redo`, `return`]); -var oi = new Set(mr2.filter((e9) => ii.test(e9) || ai.has(e9))); -var si = { base: { kKX8nH: `ui-1j61x8r`, k63SB2: `ui-etm3q0`, kGuDYH: `ui-1tachi3`, kMv6JI: `ui-1qt6sjn`, kLWn49: `ui-o5v014`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kMwMTN: `ui-1heor9g`, kzqmXN: `ui-1oai4fc`, kZKoxP: `ui-higkf7`, kXLuUW: `ui-xymvpz`, kMnn75: `ui-krqix3`, kJwUce: `ui-1403hyl`, k9WMMc: `ui-2b8uid`, kP9fke: `ui-6mezaz`, khiITx: `ui-vmahel`, kTUp5R: `ui-lh3980`, kfSwDN: `ui-87ps6o`, kO7zv1: `ui-1winvzj`, "--icon-size": `ui-1u4itkb`, "--icon-weight": `ui-1q5xvfy`, keTefX: `ui-jb5y04`, k71WvV: `ui-1bxnb1t`, kQmYQc: `ui-1ehclkv`, kgeoSG: `ui-1yj7g93`, $$css: true }, noPresetSize: { $$css: true }, sizeXs: { "--icon-size": `ui-aiyo0p`, $$css: true }, sizeSm: { "--icon-size": `ui-1u4itkb`, $$css: true }, sizeBase: { "--icon-size": `ui-xfpx3u`, $$css: true }, sizeLg: { "--icon-size": `ui-1qxde8p`, $$css: true }, sizeXl: { "--icon-size": `ui-dyy2ci`, $$css: true }, size2xl: { "--icon-size": `ui-7lg4th`, $$css: true }, noColor: { $$css: true }, colorPrimary: { kMwMTN: `ui-1nqczng`, $$css: true }, colorSecondary: { kMwMTN: `ui-1mh7f6w`, $$css: true }, colorTertiary: { kMwMTN: `ui-1lbmi28`, $$css: true }, colorQuaternary: { kMwMTN: `ui-1qh17o`, $$css: true }, colorGitAdded: { kMwMTN: `ui-15wwr8d`, $$css: true }, colorGitModified: { kMwMTN: `ui-eedwss`, $$css: true }, colorGitRemoved: { kMwMTN: `ui-fowoju`, $$css: true }, colorGitUntracked: { kMwMTN: `ui-1p7vtww`, $$css: true }, colorCyan: { kMwMTN: `ui-1rbygr4`, $$css: true }, colorBlue: { kMwMTN: `ui-101qeuz`, $$css: true }, colorRed: { kMwMTN: `ui-ku4wcm`, $$css: true }, colorGreen: { kMwMTN: `ui-p6nzhx`, $$css: true }, colorSuccess: { kMwMTN: `ui-i75md2`, $$css: true }, colorDanger: { kMwMTN: `ui-3pdtkl`, $$css: true }, colorYellow: { kMwMTN: `ui-1hn9r2r`, $$css: true }, colorMagenta: { kMwMTN: `ui-pwp9en`, $$css: true }, colorOrange: { kMwMTN: `ui-4qtrdv`, $$css: true }, colorPurple: { kMwMTN: `ui-1b0hn6l`, $$css: true }, colorAccent: { kMwMTN: `ui-scuw3h`, $$css: true }, colorBrand: { kMwMTN: `ui-v3vxec`, $$css: true }, noModifier: { $$css: true }, modifierDisabled: { kSiTet: `ui-ti2d7y`, $$css: true }, modifierHidden: { k33iCy: `ui-lshs6z`, $$css: true }, capTrim: { kQypYc: `ui-13zi6q3`, $$css: true } }; -function ci(e9, t2, n2) { - return [si.base, ui(e9), di(t2), fi(n2)]; -} -function li(e9) { - return typeof e9 == `string` && !e9.startsWith(`var(`); -} -function ui(e9) { - if (!li(e9)) return si.noPresetSize; - switch (e9) { +function di2() { + let e38 = (0, Y2.useContext)(si2), t2 = (0, Y2.useSyncExternalStore)(ci2, li2, ui2); + return e38 ?? t2; +} +var fi2 = 6e3; +var pi2 = { motionStyles: [], syncStyle: void 0, paused: false, reduced: false }; +function mi2(e38, { sync: t2 = true, sweep: n2 = false } = {}) { + let r2 = di2(), i3 = ai2(), a3 = ti2({ enabled: e38 && t2, durationMs: fi2 }); + if (!e38) return pi2; + let o3 = [n2 ? Wr2 : Hr2]; + return r2 && o3.push(n2 ? Gr2 : Ur2), i3 && o3.push(Xr2), { motionStyles: o3, syncStyle: a3 === void 0 ? void 0 : { "--cursor-spinner-sync-delay": a3 }, paused: i3, reduced: r2 }; +} +var hi2 = (0, Y2.createContext)(void 0); +function gi2({ iconSize: e38, iconButtonSize: t2, iconButtonFrame: n2, iconButtonVariant: r2, iconButtonTone: i3, iconButtonRootStyle: a3, iconButtonIconStyle: o3, iconButtonIconSize: s3, buttonSize: c3, buttonFrame: l5, buttonRootStyle: u3, buttonVariant: d3, buttonTone: f4, buttonPrimaryTone: p4, buttonIconSize: m3, buttonRounded: h4, buttonFullWidth: g5, menuSize: _5, disabled: v5, children: y4 }) { + gi2.d = 2831495554; + let b2 = (0, Y2.useContext)(hi2), x2 = (0, Y2.useMemo)(() => ({ iconSize: e38 ?? b2?.iconSize, iconButtonSize: t2 ?? b2?.iconButtonSize, iconButtonFrame: n2 ?? b2?.iconButtonFrame, iconButtonVariant: r2 ?? b2?.iconButtonVariant, iconButtonTone: i3 ?? b2?.iconButtonTone, iconButtonRootStyle: a3 ?? b2?.iconButtonRootStyle, iconButtonIconStyle: o3 ?? b2?.iconButtonIconStyle, iconButtonIconSize: s3 ?? b2?.iconButtonIconSize, buttonSize: c3 ?? b2?.buttonSize, buttonFrame: l5 ?? b2?.buttonFrame, buttonRootStyle: u3 ?? b2?.buttonRootStyle, buttonVariant: d3 ?? b2?.buttonVariant, buttonTone: f4 ?? b2?.buttonTone, buttonPrimaryTone: p4 ?? b2?.buttonPrimaryTone, buttonIconSize: m3 ?? b2?.buttonIconSize, buttonRounded: h4 ?? b2?.buttonRounded, buttonFullWidth: g5 ?? b2?.buttonFullWidth, menuSize: _5 ?? b2?.menuSize, disabled: v5 ?? b2?.disabled }), [l5, g5, p4, f4, m3, u3, h4, c3, d3, v5, n2, s3, o3, i3, a3, t2, r2, e38, _5, b2]); + return (0, J2.jsx)(hi2.Provider, { value: x2, children: y4 }); +} +function _i2() { + return (0, Y2.useContext)(hi2); +} +var vi2 = /(^|-)(left|right)(-|$)/; +var yi2 = /* @__PURE__ */ new Set([`history`, `link-external`, `list-bullets`, `list-numbers`, `list-ordered`, `quote`, `quotes`, `redo`, `return`]); +var bi2 = new Set(Or2.filter((e38) => vi2.test(e38) || yi2.has(e38))); +var X2 = { base: { kKX8nH: `ui-1j61x8r`, k63SB2: `ui-etm3q0`, kGuDYH: `ui-1tachi3`, kMv6JI: `ui-1qt6sjn`, kLWn49: `ui-o5v014`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kMwMTN: `ui-1heor9g`, kzqmXN: `ui-1oai4fc`, kZKoxP: `ui-higkf7`, kXLuUW: `ui-xymvpz`, kMnn75: `ui-krqix3`, kJwUce: `ui-1403hyl`, k9WMMc: `ui-2b8uid`, kP9fke: `ui-6mezaz`, khiITx: `ui-vmahel`, kTUp5R: `ui-lh3980`, kfSwDN: `ui-87ps6o`, kO7zv1: `ui-1winvzj`, "--icon-size": `ui-1u4itkb`, "--icon-weight": `ui-1q5xvfy`, keTefX: `ui-jb5y04`, k71WvV: `ui-1bxnb1t`, kQmYQc: `ui-1ehclkv`, kgeoSG: `ui-1yj7g93`, $$css: true }, noPresetSize: { $$css: true }, sizeXs: { "--icon-size": `ui-aiyo0p`, $$css: true }, sizeSm: { "--icon-size": `ui-1u4itkb`, $$css: true }, sizeBase: { "--icon-size": `ui-xfpx3u`, $$css: true }, sizeLg: { "--icon-size": `ui-1qxde8p`, $$css: true }, sizeXl: { "--icon-size": `ui-dyy2ci`, $$css: true }, size2xl: { "--icon-size": `ui-7lg4th`, $$css: true }, noColor: { $$css: true }, colorPrimary: { kMwMTN: `ui-1nqczng`, $$css: true }, colorSecondary: { kMwMTN: `ui-1mh7f6w`, $$css: true }, colorTertiary: { kMwMTN: `ui-1lbmi28`, $$css: true }, colorQuaternary: { kMwMTN: `ui-1qh17o`, $$css: true }, colorGitAdded: { kMwMTN: `ui-15wwr8d`, $$css: true }, colorGitModified: { kMwMTN: `ui-eedwss`, $$css: true }, colorGitRemoved: { kMwMTN: `ui-fowoju`, $$css: true }, colorGitUntracked: { kMwMTN: `ui-1p7vtww`, $$css: true }, colorCyan: { kMwMTN: `ui-1rbygr4`, $$css: true }, colorBlue: { kMwMTN: `ui-101qeuz`, $$css: true }, colorRed: { kMwMTN: `ui-ku4wcm`, $$css: true }, colorGreen: { kMwMTN: `ui-p6nzhx`, $$css: true }, colorSuccess: { kMwMTN: `ui-i75md2`, $$css: true }, colorDanger: { kMwMTN: `ui-3pdtkl`, $$css: true }, colorYellow: { kMwMTN: `ui-1hn9r2r`, $$css: true }, colorMagenta: { kMwMTN: `ui-pwp9en`, $$css: true }, colorOrange: { kMwMTN: `ui-4qtrdv`, $$css: true }, colorPurple: { kMwMTN: `ui-1b0hn6l`, $$css: true }, colorAccent: { kMwMTN: `ui-scuw3h`, $$css: true }, colorBrand: { kMwMTN: `ui-v3vxec`, $$css: true }, noModifier: { $$css: true }, modifierDisabled: { kSiTet: `ui-ti2d7y`, $$css: true }, modifierHidden: { k33iCy: `ui-lshs6z`, $$css: true }, capTrim: { kQypYc: `ui-13zi6q3`, $$css: true } }; +function xi2(e38, t2, n2) { + return [X2.base, Ci2(e38), wi2(t2), Ti2(n2)]; +} +function Si2(e38) { + return typeof e38 == `string` && !e38.startsWith(`var(`); +} +function Ci2(e38) { + if (!Si2(e38)) return X2.noPresetSize; + switch (e38) { case `xs`: - return si.sizeXs; + return X2.sizeXs; case `sm`: - return si.sizeSm; + return X2.sizeSm; case `base`: - return si.sizeBase; + return X2.sizeBase; case `lg`: - return si.sizeLg; + return X2.sizeLg; case `xl`: - return si.sizeXl; + return X2.sizeXl; case `2xl`: - return si.size2xl; + return X2.size2xl; } } -function di(e9) { - switch (e9) { +function wi2(e38) { + switch (e38) { case `primary`: - return si.colorPrimary; + return X2.colorPrimary; case `secondary`: - return si.colorSecondary; + return X2.colorSecondary; case `tertiary`: - return si.colorTertiary; + return X2.colorTertiary; case `quaternary`: - return si.colorQuaternary; + return X2.colorQuaternary; case `git-added`: - return si.colorGitAdded; + return X2.colorGitAdded; case `git-modified`: - return si.colorGitModified; + return X2.colorGitModified; case `git-removed`: - return si.colorGitRemoved; + return X2.colorGitRemoved; case `git-untracked`: - return si.colorGitUntracked; + return X2.colorGitUntracked; case `cyan`: - return si.colorCyan; + return X2.colorCyan; case `blue`: - return si.colorBlue; + return X2.colorBlue; case `red`: - return si.colorRed; + return X2.colorRed; case `green`: - return si.colorGreen; + return X2.colorGreen; case `success`: - return si.colorSuccess; + return X2.colorSuccess; case `danger`: - return si.colorDanger; + return X2.colorDanger; case `yellow`: - return si.colorYellow; + return X2.colorYellow; case `magenta`: - return si.colorMagenta; + return X2.colorMagenta; case `orange`: - return si.colorOrange; + return X2.colorOrange; case `purple`: - return si.colorPurple; + return X2.colorPurple; case `accent`: - return si.colorAccent; + return X2.colorAccent; case `brand`: - return si.colorBrand; + return X2.colorBrand; case void 0: - return si.noColor; + return X2.noColor; } } -function fi(e9) { - switch (e9) { +function Ti2(e38) { + switch (e38) { case `spin`: - return Or; + return Hr2; case `disabled`: - return si.modifierDisabled; + return X2.modifierDisabled; case `hidden`: - return si.modifierHidden; + return X2.modifierHidden; case void 0: - return si.noModifier; + return X2.noModifier; } } -function pi(e9) { - if (typeof e9 == `string` && e9.length !== 0) return `"${e9}"`; +function Ei2(e38) { + if (typeof e38 == `string` && e38.length !== 0) return `"${e38}"`; } -var mi = /* @__PURE__ */ new Set([`loading`, `spinner`]); -function hi(e9) { - hi.d = 838994094; - let t2 = { enforcedSize: ri()?.iconSize, isRtl: Wc() === `rtl` }; - return e9.modifier === `spin` ? (0, q2.jsx)(gi, { ...e9, context: t2 }) : _i(e9, t2, void 0); +var Di2 = /* @__PURE__ */ new Set([`loading`, `spinner`]); +function Oi(e38) { + Oi.d = 838994094; + let t2 = { enforcedSize: _i2()?.iconSize, isRtl: Hc() === `rtl` }; + return e38.modifier === `spin` ? (0, J2.jsx)(ki2, { ...e38, context: t2 }) : Ai2(e38, t2, void 0); } -function gi({ context: e9, ...t2 }) { - return gi.d = 3966887796, _i(t2, e9, ei(true, { sync: t2.syncSpin ?? true, sweep: mi.has(t2.name) })); +function ki2({ context: e38, ...t2 }) { + return ki2.d = 3966887796, Ai2(t2, e38, mi2(true, { sync: t2.syncSpin ?? true, sweep: Di2.has(t2.name) })); } -function _i({ name: e9, modifier: t2, variant: n2 = `outline`, size: r2, color: i3, capTrim: a3 = false, className: o3, rootStyle: s3, style: c2, title: l4, "aria-label": u3, "aria-hidden": d3, ref: f4 }, { enforcedSize: p4, isRtl: m3 }, h3) { - let g3 = r2 ?? p4 ?? `sm`, _2 = li(g3), v3 = m3 && oi.has(e9), y3 = h3 !== void 0 && mi.has(e9), b3 = pi(br(e9, n2)), x3 = { ...b3 ? { "--cursor-icon-content": b3 } : {}, ..._2 ? {} : { "--icon-size": typeof g3 == `number` ? `${g3}px` : g3 }, ...h3?.syncStyle, ...c2 }, S3 = K2({ rootClass: `ui-icon`, stylexStyles: [ci(g3, i3, y3 ? void 0 : t2), h3?.motionStyles, v3 && Er2.root, a3 && si.capTrim, s3], className: G3(`cursor-icon`, o3), style: x3 }); - return (0, q2.jsx)(`i`, { ref: f4, className: S3.className, "data-icon-name": e9, "data-size": _2 ? g3 : void 0, "data-color": i3, style: S3.style, title: l4 ?? u3, role: u3 ? `img` : void 0, "aria-label": u3, "aria-hidden": d3 ?? (!u3 || void 0), children: y3 ? Mr.map((e10) => (0, q2.jsx)(`span`, { ...h(e10.style, h3?.reduced === true && Nr, h3?.paused === true && Ir, a3 && si.capTrim) }, e10.angle)) : null }); +function Ai2({ name: e38, modifier: t2, variant: n2 = `outline`, size: r2, color: i3, capTrim: a3 = false, className: o3, rootStyle: s3, style: c3, title: l5, "aria-label": u3, "aria-hidden": d3, ref: f4 }, { enforcedSize: p4, isRtl: m3 }, h4) { + let g5 = r2 ?? p4 ?? `sm`, _5 = Si2(g5), v5 = m3 && bi2.has(e38), y4 = h4 !== void 0 && Di2.has(e38), b2 = Ei2(Pr2(e38, n2)), x2 = { ...b2 ? { "--cursor-icon-content": b2 } : {}, ..._5 ? {} : { "--icon-size": typeof g5 == `number` ? `${g5}px` : g5 }, ...h4?.syncStyle, ...c3 }, S2 = q2({ rootClass: `ui-icon`, stylexStyles: [xi2(g5, i3, y4 ? void 0 : t2), h4?.motionStyles, v5 && Br2.root, a3 && X2.capTrim, s3], className: K2(`cursor-icon`, o3), style: x2 }); + return (0, J2.jsx)(`i`, { ref: f4, className: S2.className, "data-icon-name": e38, "data-size": _5 ? g5 : void 0, "data-color": i3, style: S2.style, title: l5 ?? u3, role: u3 ? `img` : void 0, "aria-label": u3, "aria-hidden": d3 ?? (!u3 || void 0), children: y4 ? Kr2.map((e39) => (0, J2.jsx)(`span`, { ...h(e39.style, h4?.reduced && qr2, h4?.paused && Xr2, a3 && X2.capTrim) }, e39.angle)) : null }); } -var vi = (0, J2.createContext)({ root: null }); -function bi() { - return (0, J2.useContext)(vi).root; +var ji2 = (0, Y2.createContext)({ root: null }); +function Ni2() { + return (0, Y2.useContext)(ji2).root; } -var Ci = { dropdown: `--ui-portal-layer-z-index-dropdown`, tooltip: `--ui-portal-layer-z-index-tooltip`, modal: `--ui-portal-layer-z-index-modal`, popover: `--ui-portal-layer-z-index-popover` }; -var wi = {}; -var Ti2 = 3e3; -var Ei2 = 10; -var Di2 = Ti2; -function Oi() { - let e9 = Di2; - return Di2 += Ei2, { zIndex: e9, release: () => { +var Ii2 = { dropdown: `--ui-portal-layer-z-index-dropdown`, tooltip: `--ui-portal-layer-z-index-tooltip`, modal: `--ui-portal-layer-z-index-modal`, popover: `--ui-portal-layer-z-index-popover` }; +var Li2 = {}; +var Ri2 = 3e3; +var zi2 = 10; +var Bi2 = Ri2; +function Vi2() { + let e38 = Bi2; + return Bi2 += zi2, { zIndex: e38, release: () => { } }; } -var ki = (0, J2.createContext)(null); -function ji() { - return (0, J2.useContext)(ki); +var Hi2 = (0, Y2.createContext)(null); +function Wi2() { + return (0, Y2.useContext)(Hi2); } -function Mi(e9, t2) { - let n2 = ji(), [r2, i3] = (0, J2.useState)(null); - (0, J2.useLayoutEffect)(() => { +function Gi2(e38, t2) { + let n2 = Wi2(), [r2, i3] = (0, Y2.useState)(null); + (0, Y2.useLayoutEffect)(() => { if (!t2) { i3(null); return; } - let e10 = n2?.claimZIndex() ?? Oi(); - return i3(e10.zIndex), () => { - e10.release(); + let e39 = n2?.claimZIndex() ?? Vi2(); + return i3(e39.zIndex), () => { + e39.release(); }; }, [t2, n2]); - let a3 = (0, J2.useMemo)(() => r2 === null ? wi : { [Ci[e9]]: String(r2) }, [r2, e9]); - return (0, J2.useMemo)(() => ({ zIndex: r2, portalLayerStyles: a3 }), [r2, a3]); -} -var Ni = { self: { "--ui-focus-ring-offset": `ui-fzsr76`, k3XXqK: `ui-1t137rt ui-9v5kkp`, kMeerF: `ui-1k57tk5 ui-1xm47i`, kjBf7l: `ui-1uczgqu ui-1yupr9i`, kInvED: `ui-1wfwxd8 ui-5q7enl`, $$css: true }, selfInset: { "--ui-focus-ring-offset": `ui-os3vqj`, k3XXqK: `ui-1t137rt ui-9v5kkp`, kMeerF: `ui-1k57tk5 ui-1xm47i`, kjBf7l: `ui-1uczgqu ui-1yupr9i`, kInvED: `ui-1wfwxd8 ui-5q7enl`, $$css: true }, part: { k3XXqK: `ui-1t137rt ui-173w15d`, kMeerF: `ui-1k57tk5 ui-1dsbooj`, kjBf7l: `ui-1uczgqu ui-89oa2v`, kInvED: `ui-1wfwxd8 ui-gzkrw1`, $$css: true }, hasFocusedInput: { k3XXqK: `ui-1t137rt`, kMeerF: `ui-1k57tk5`, kjBf7l: `ui-1uczgqu`, kInvED: `ui-1wfwxd8`, kjcrNO: `ui-1ae5oaz`, kEpxoN: `ui-qe9enz`, kQMcTO: `ui-6455tu`, k7SySk: `ui-w2pel2`, $$css: true }, focusedField: { k3XXqK: `ui-1t137rt ui-1ultt8f`, kMeerF: `ui-1k57tk5 ui-eehi8w`, kjBf7l: `ui-1uczgqu ui-7im0qn`, kInvED: `ui-1wfwxd8 ui-as25tf`, $$css: true }, parentInset: { k3XXqK: `ui-1t137rt`, kMeerF: `ui-1k57tk5`, kjBf7l: `ui-1uczgqu`, kInvED: `ui-1wfwxd8`, kBUUTA: `ui-17lkynp`, kRChEl: `ui-10i5z1m`, k2Q9yQ: `ui-o7e1f8`, ktzZqf: `ui-wmmgom`, $$css: true } }; -var Pi = { self: { "data-ui-focus-ring": `self` }, part: { "data-ui-focus-ring": `part` }, parent: { "data-ui-focus-ring": `parent` } }; -var ca = { root: { kGuDYH: `ui-y5h43f`, kLWn49: `ui-19ji09o`, kb6lSQ: `ui-t1j8c4`, $$css: true } }; -var la = { root: { kGuDYH: `ui-1wm8ruf`, kLWn49: `ui-spwq11`, kb6lSQ: `ui-14s4slr`, $$css: true } }; -var ua2 = { root: { kGuDYH: `ui-11wthnw`, kLWn49: `ui-1ja60sm`, kb6lSQ: `ui-vu1jfw`, $$css: true } }; -var da2 = { root: { kGuDYH: `ui-fc7y3v`, kLWn49: `ui-1yxxptd`, kb6lSQ: `ui-1bignsj`, $$css: true } }; -var fa2 = { root: { kGuDYH: `ui-19d36u7`, kLWn49: `ui-dod15v`, kb6lSQ: `ui-k22nv0`, $$css: true } }; -var pa2 = { root: { kGuDYH: `ui-wsyq91`, kLWn49: `ui-19v9tvf`, kb6lSQ: `ui-1h56xvc`, $$css: true } }; -var ma = { root: { kGuDYH: `ui-1i1m3gp`, kLWn49: `ui-eqr9p9`, kb6lSQ: `ui-qhv51x`, $$css: true } }; -var ha = { root: { kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kg5iWk: `ui-lyipyv`, k8aIck: `ui-jlip5`, kqG3fB: `ui-kyw5k8`, $$css: true } }; -var ga = { root: { khiITx: `ui-vmahel`, kTUp5R: `ui-lh3980`, $$css: true } }; -function Ls() { - let e9 = (0, J2.useRef)(void 0), t2 = (0, J2.useCallback)(() => { - let t3 = e9.current; - t3 !== void 0 && (e9.current = void 0, cancelAnimationFrame2(t3)); - }, []), n2 = (0, J2.useCallback)((n3) => { - t2(), e9.current = requestAnimationFrame2((t3) => { - e9.current = void 0, n3(t3); + let a3 = (0, Y2.useMemo)(() => r2 === null ? Li2 : { [Ii2[e38]]: String(r2) }, [r2, e38]); + return (0, Y2.useMemo)(() => ({ zIndex: r2, portalLayerStyles: a3 }), [r2, a3]); +} +var Ki2 = { self: { "--ui-focus-ring-offset": `ui-fzsr76`, k3XXqK: `ui-1t137rt ui-9v5kkp`, kMeerF: `ui-1k57tk5 ui-1xm47i`, kjBf7l: `ui-1uczgqu ui-1yupr9i`, kInvED: `ui-1wfwxd8 ui-5q7enl`, $$css: true }, selfInset: { "--ui-focus-ring-offset": `ui-os3vqj`, k3XXqK: `ui-1t137rt ui-9v5kkp`, kMeerF: `ui-1k57tk5 ui-1xm47i`, kjBf7l: `ui-1uczgqu ui-1yupr9i`, kInvED: `ui-1wfwxd8 ui-5q7enl`, $$css: true }, part: { k3XXqK: `ui-1t137rt ui-173w15d`, kMeerF: `ui-1k57tk5 ui-1dsbooj`, kjBf7l: `ui-1uczgqu ui-89oa2v`, kInvED: `ui-1wfwxd8 ui-gzkrw1`, $$css: true }, hasFocusedInput: { k3XXqK: `ui-1t137rt`, kMeerF: `ui-1k57tk5`, kjBf7l: `ui-1uczgqu`, kInvED: `ui-1wfwxd8`, kjcrNO: `ui-1ae5oaz`, kEpxoN: `ui-qe9enz`, kQMcTO: `ui-6455tu`, k7SySk: `ui-w2pel2`, $$css: true }, focusedField: { k3XXqK: `ui-1t137rt ui-1ultt8f`, kMeerF: `ui-1k57tk5 ui-eehi8w`, kjBf7l: `ui-1uczgqu ui-7im0qn`, kInvED: `ui-1wfwxd8 ui-as25tf`, $$css: true }, parentInset: { k3XXqK: `ui-1t137rt`, kMeerF: `ui-1k57tk5`, kjBf7l: `ui-1uczgqu`, kInvED: `ui-1wfwxd8`, kBUUTA: `ui-17lkynp`, kRChEl: `ui-10i5z1m`, k2Q9yQ: `ui-o7e1f8`, ktzZqf: `ui-wmmgom`, $$css: true } }; +var qi2 = { self: { "data-ui-focus-ring": `self` }, part: { "data-ui-focus-ring": `part` }, parent: { "data-ui-focus-ring": `parent` } }; +function Ji2(e38) { + return Array.isArray(e38); +} +function Yi2(e38, t2) { + let n2 = e38; + return Ji2(n2) ? n2.includes(t2) : n2.has(t2); +} +var Qi2 = { plan: `warning`, "git-added": `success`, "git-modified": `warning`, "git-removed": `danger` }; +var $i2 = [`accent`, `success`, `warning`, `danger`]; +var ea2 = new Set($i2); +function ta2(e38) { + return e38 !== void 0 && Object.hasOwn(Qi2, e38); +} +function na2(e38) { + return e38 !== void 0 && Yi2(ea2, e38); +} +function ra2(e38) { + if (e38 !== void 0) return ta2(e38) ? Qi2[e38] : e38; +} +var ia2 = [`primary`, `secondary`, `media`]; +var aa2 = [`outline`, `ghost`, `text`]; +var oa2 = new Set(ia2); +var sa2 = new Set(aa2); +function ca2(e38) { + return oa2.has(e38); +} +function la2(e38) { + return sa2.has(e38); +} +function ua2(e38, t2) { + let n2 = e38 === `secondary` && t2 !== void 0 && !na2(t2); + return { applyControlTone: e38 !== `secondary` || n2, applyFilledColors: ca2(e38) && !n2, applyNonFilledBackground: la2(e38) || n2 }; +} +var da2 = { foreground: { "--ui-button-fg": `ui-1h31wig ui-qalphj ui-alrmhx ui-1e1xjh9 ui-1eont2s ui-qygd40 ui-1ucl2ju ui-111ni6s ui-3id928 ui-wqjwyh ui-v6bjuk ui-17og37h ui-1mruliz ui-10ch5e ui-1xnt5ni ui-bcxwum`, "--ui-button-fg-hover": `ui-ve8a38 ui-572mpw ui-vp5bk3 ui-16shgaf ui-mjj3su ui-1v3oqsu ui-2ngaw7 ui-28dmf3`, $$css: true } }; +var fa2 = { secondary: { "--ui-button-fg": `ui-1j8p2m6`, "--ui-button-fg-hover": `ui-e6ovir`, $$css: true }, tertiary: { "--ui-button-fg": `ui-1fwx157`, "--ui-button-fg-hover": `ui-111fdx3`, $$css: true }, accent: { "--ui-button-fg": `ui-1f79f0m`, "--ui-button-fg-hover": `ui-1sd9hjt`, $$css: true }, monochrome: { "--ui-button-fg": `ui-4zyimg`, "--ui-button-fg-hover": `ui-l1tqj1`, $$css: true }, success: { "--ui-button-fg": `ui-1091cms`, "--ui-button-fg-hover": `ui-qejad5`, $$css: true }, warning: { "--ui-button-fg": `ui-90x234`, "--ui-button-fg-hover": `ui-v3sia6`, $$css: true }, danger: { "--ui-button-fg": `ui-1jtauhq`, "--ui-button-fg-hover": `ui-1iqdewe`, $$css: true } }; +var pa2 = { secondary: { "--ui-button-fg": `ui-zinbld`, "--ui-button-fg-hover": `ui-l1tqj1`, $$css: true }, tertiary: { "--ui-button-fg": `ui-1mn641q`, "--ui-button-fg-hover": `ui-17wn194`, $$css: true } }; +var ma2 = { appearance: { "--ui-button-bg-disabled": `ui-t2ps8i ui-1siydi6 ui-9mchb4 ui-b3sabi`, "--ui-button-fg-disabled": `ui-lxpv47 ui-1wzq4de`, kWkggS: `ui-elcf9h ui-g74ub2 ui-4vc931 ui-1twq3x9 ui-mzrycd`, kMwMTN: `ui-gl2jp8 ui-qfdz8i ui-zik83n ui-7mi40u`, kKMj4B: `ui-e1kniv ui-fq1cfh`, kSiTet: `ui-1x77wit`, k1ekBW: `ui-fvdr79`, kIyJzY: `ui-2krxs4 ui-6458p5`, kAMwcw: `ui-fl15g4`, $$css: true }, engaged: { kWkggS: `ui-1x1890e ui-mzrycd`, kMwMTN: `ui-8ech78 ui-7mi40u`, $$css: true }, media: { kSiTet: `ui-1szrgyu`, k6WDB: `ui-1hvsj6t`, kMzoRj: `ui-mkeg23`, ksu8eU: `ui-1y0btm7`, kVAM5u: `ui-1aml6k`, $$css: true }, colors: { "--ui-button-bg": `ui-afdq1a ui-125v35v ui-1olvpfz ui-oa62de ui-1chhnie ui-302ab4 ui-18o3eha ui-1qs2zoo ui-1g9fn2x ui-10rfvjz ui-18ab9qp`, "--ui-button-bg-hover": `ui-13v2mu8 ui-yt64w ui-e9ir63 ui-onvtd7 ui-1k8s92z ui-1kvkcw9 ui-43o616 ui-cs87t5 ui-197nqx8 ui-uudzfn ui-uontnf`, "--ui-button-bg-active": `ui-1f1zgjn ui-1nsurhp ui-11xudch ui-1f8rfv1 ui-ggai1r`, "--ui-button-fg": `ui-18rr0f6 ui-cdmvwo ui-1oum4wa ui-1yrx47c ui-1s3xcaz ui-2424zi ui-rwu1v7 ui-9sccad ui-hcepst ui-wvzk2y ui-gftpnt ui-pzfz8q`, "--ui-button-fg-hover": `ui-ve8a38 ui-lidx4s ui-f1csfx ui-10swf5o ui-2fu0p3`, "--ui-button-label-shadow": `ui-107xv6h ui-1fgkyrd ui-uxtdke ui-1lpoe4m ui-1mh6czn`, $$css: true } }; +var ha2 = { background: { "--ui-button-bg": `ui-1gwrc9l ui-302ab4 ui-1luhpj5 ui-14iu9ww`, "--ui-button-bg-hover": `ui-s16ggv ui-1kvkcw9 ui-hqa6pe ui-e032zu`, $$css: true }, outline: { kMzoRj: `ui-mkeg23`, ksu8eU: `ui-1y0btm7`, kVAM5u: `ui-13747pv ui-wm9d6`, $$css: true } }; +var ga2 = /* @__PURE__ */ new Set([`accent`, `success`, `warning`, `danger`]); +function _a2(e38) { + return e38 !== void 0 && ga2.has(e38); +} +var va2 = { accent: { "--ui-button-bg-hover": `ui-2qxk4j`, $$css: true }, success: { "--ui-button-bg-hover": `ui-11h7f69`, $$css: true }, warning: { "--ui-button-bg-hover": `ui-1donwlf`, $$css: true }, danger: { "--ui-button-bg-hover": `ui-x6ealz`, $$css: true } }; +var ya2 = { accent: { kVAM5u: `ui-5r2jki ui-wm9d6`, $$css: true }, success: { kVAM5u: `ui-1gvt79p ui-wm9d6`, $$css: true }, warning: { kVAM5u: `ui-1cucnr7 ui-wm9d6`, $$css: true }, danger: { kVAM5u: `ui-105evjg ui-wm9d6`, $$css: true } }; +var ba2 = { sm: `sm`, md: `sm`, lg: `base`, xl: `lg` }; +function xa2(e38) { + let t2 = e38.currentTarget; + e38.key === ` ` && t2 instanceof HTMLAnchorElement && t2.href !== `` && e38.preventBaseUIHandler(); +} +function Sa2(e38) { + return (t2) => { + e38?.(t2), xa2(t2); + }; +} +var Ca2 = { root: { kGuDYH: `ui-y5h43f`, kLWn49: `ui-19ji09o`, kb6lSQ: `ui-t1j8c4`, $$css: true } }; +var wa2 = { root: { kGuDYH: `ui-1wm8ruf`, kLWn49: `ui-spwq11`, kb6lSQ: `ui-14s4slr`, $$css: true } }; +var Ta2 = { root: { kGuDYH: `ui-11wthnw`, kLWn49: `ui-1ja60sm`, kb6lSQ: `ui-vu1jfw`, $$css: true } }; +var Ea2 = { root: { kGuDYH: `ui-fc7y3v`, kLWn49: `ui-1yxxptd`, kb6lSQ: `ui-1bignsj`, $$css: true } }; +var Da2 = { root: { kGuDYH: `ui-19d36u7`, kLWn49: `ui-dod15v`, kb6lSQ: `ui-k22nv0`, $$css: true } }; +var Oa2 = { root: { kGuDYH: `ui-wsyq91`, kLWn49: `ui-19v9tvf`, kb6lSQ: `ui-1h56xvc`, $$css: true } }; +var ka2 = { root: { kGuDYH: `ui-1i1m3gp`, kLWn49: `ui-eqr9p9`, kb6lSQ: `ui-qhv51x`, $$css: true } }; +var Aa = { root: { kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kg5iWk: `ui-lyipyv`, k8aIck: `ui-jlip5`, kqG3fB: `ui-kyw5k8`, $$css: true } }; +var ja2 = { root: { khiITx: `ui-vmahel`, kTUp5R: `ui-lh3980`, $$css: true } }; +var Ma2 = { content: { k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kOIVth: `ui-pkkfsy`, k63SB2: `ui-vxqr21`, khDVqt: `ui-uxw1ft`, kfSwDN: `ui-87ps6o`, k9WMMc: `ui-2b8uid`, $$css: true }, pill: { kaIpWk: `ui-1i4c3av`, kOIVth: `ui-11twubx`, $$css: true } }; +var Na2 = { content: Ma2.content, pill: Ma2.pill, size: { sm: { kLKAdn: `ui-exx8yu`, kwRFfy: `ui-19bzwdx`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-v853mj`, $$css: true }, md: { kLKAdn: `ui-exx8yu`, kwRFfy: `ui-196pc8s`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-22095l`, $$css: true }, lg: { kLKAdn: `ui-exx8yu`, kwRFfy: `ui-1fg0g13`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1tajz9i`, $$css: true }, xl: { kLKAdn: `ui-exx8yu`, kwRFfy: `ui-t1q3vd`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-8fiw5y`, $$css: true } }, pillSize: { sm: { kLKAdn: `ui-exx8yu`, kwRFfy: `ui-196pc8s`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-22095l`, $$css: true }, md: { kLKAdn: `ui-exx8yu`, kwRFfy: `ui-1fg0g13`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1tajz9i`, $$css: true }, lg: { kLKAdn: `ui-exx8yu`, kwRFfy: `ui-t1q3vd`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-8fiw5y`, $$css: true }, xl: { kLKAdn: `ui-exx8yu`, kwRFfy: `ui-1n9uuka`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-cssynl`, $$css: true } }, typography: { sm: Ta2.root, md: Ta2.root, lg: Ta2.root, xl: Ea2.root } }; +var Pa2 = { root: [{ root: { kFalU9: `ui-ggy1nq`, kSiTet: `ui-1szrgyu`, $$css: true } }.root, Ki2.self] }; +var Fa2 = { root: [{ root: { kB7OPa: `ui-9f619`, kMv6JI: `ui-jb2p0i`, kGuDYH: `ui-1qlqyl8`, kLWn49: `ui-15bjb6t`, kMzoRj: `ui-mkeg23`, ksu8eU: `ui-1y0btm7`, kVAM5u: `ui-9r1u3d`, kkrTdU: `ui-1ypdohk ui-1j1ks5o`, kSiTet: `ui-1hc1fzr`, kfzvcC: `ui-67bb7w ui-7gqb9v`, $$css: true } }.root, Pa2.root] }; +var Ia2 = { sm: { kaIpWk: `ui-1e1y6u3`, $$css: true }, md: { kaIpWk: `ui-1043rbw`, $$css: true }, lg: { kaIpWk: `ui-1m7fhj7`, $$css: true }, xl: { kaIpWk: `ui-1m7fhj7`, $$css: true } }; +var La2 = { sm: { kZKoxP: `ui-1a6rlst`, $$css: true }, md: { kZKoxP: `ui-1e94bgo`, $$css: true }, lg: { kZKoxP: `ui-170hpbr`, $$css: true }, xl: { kZKoxP: `ui-t8t6p`, $$css: true } }; +var Ra2 = { markdownHover: { "--ui-md-state-color": `ui-1w18epr`, $$css: true }, primaryWeight: { k63SB2: `ui-vxqr21 ui-1tpdiw2`, $$css: true }, alignLeft: { kjj79g: `ui-1nhvcw1`, $$css: true }, fullWidth: { kzqmXN: `ui-h8yej3`, $$css: true }, frameContent: { kZCmMZ: `ui-1c1uobl`, kwRFfy: `ui-yri2b`, $$css: true } }; +var za2 = { labelGroup: { k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kOIVth: `ui-pkkfsy`, k7Eaqz: `ui-euugli`, ks0D6T: `ui-193iq5w`, $$css: true }, kbs: { kmuXW: `ui-2lah0s`, kMv6JI: `ui-y1aii3`, k63SB2: `ui-vxqr21`, kSiTet: `ui-byyjgo ui-s6mkfk`, k33iCy: `ui-1go34h7`, $$css: true }, icon: { kmuXW: `ui-2lah0s`, $$css: true }, iconToneTertiary: { kMwMTN: `ui-4b2ntj ui-1s8h5yg`, $$css: true } }; +var Ba2 = { root: [Fa2.root, Na2.content, Ra2.markdownHover, Ra2.primaryWeight], fontSmoothing: ja2.root, align: { center: null, left: Ra2.alignLeft }, fullWidth: Ra2.fullWidth, frame: { container: null, content: Ra2.frameContent }, shape: { rounded: null, pill: Na2.pill }, size: { sm: [La2.sm, Ia2.sm, Na2.size.sm], md: [La2.md, Ia2.md, Na2.size.md], lg: [La2.lg, Ia2.lg, Na2.size.lg], xl: [La2.xl, Ia2.xl, Na2.size.xl] }, pillSize: Na2.pillSize, typography: Na2.typography, labelGroup: za2.labelGroup, kbs: [wa2.root, za2.kbs], icon: za2.icon, iconTone: { tertiary: za2.iconToneTertiary } }; +function Va2({ rounded: e38, variant: t2, enforcedRounded: n2 }) { + return e38 === void 0 ? t2 !== `text` && n2 === true : e38; +} +var Ha = { "ui--default-marker": `ui--default-marker`, $$css: true }; +function Ua2(e38, t2) { + if (e38 == null) return null; + let n2 = typeof e38 == `string` ? { name: e38 } : e38; + return (0, J2.jsx)(Oi, { "aria-hidden": `true`, modifier: n2.modifier, name: n2.name, rootStyle: [Ba2.icon, n2.tone !== void 0 && Ba2.iconTone[n2.tone]], size: n2.size ?? t2, variant: n2.variant }); +} +function Wa2({ variant: e38, tone: t2, size: n2, rounded: r2, frame: i3, align: a3, fullWidth: o3, disabled: s3, children: c3, leadingIcon: l5, trailingIcon: u3, kbs: d3, pressed: f4, className: p4, style: m3, rootStyle: h4, "aria-expanded": g5, "aria-pressed": _5, "aria-busy": v5, onKeyDown: y4, onKeyUp: b2, ...x2 }) { + Wa2.d = 2813386726; + let S2 = _i2(), C2 = e38 ?? S2?.buttonVariant ?? `secondary`, w2 = n2 ?? S2?.buttonSize ?? `md`, T2 = i3 ?? S2?.buttonFrame ?? `container`, E2 = Va2({ enforcedRounded: S2?.buttonRounded, rounded: r2, variant: C2 }), D2 = o3 ?? S2?.buttonFullWidth ?? false, O2 = s3 ?? S2?.disabled, k2 = ra2(t2 ?? (C2 === `primary` ? S2?.buttonPrimaryTone ?? S2?.buttonTone : C2 === `ghost` ? S2?.buttonTone : void 0) ?? (C2 === `primary` ? `accent` : void 0)), A2 = S2?.buttonIconSize ?? ba2[w2], j2 = `data-pressed` in x2 ? x2[`data-pressed`] : void 0, M2 = ua2(C2, k2), N3 = h(Ba2.root, Ba2.fontSmoothing, ma2.appearance, M2.applyControlTone && da2.foreground, M2.applyControlTone && k2 !== void 0 && fa2[k2], M2.applyFilledColors && ma2.colors, M2.applyNonFilledBackground && ha2.background, (C2 === `outline` || C2 === `ghost`) && _a2(k2) && va2[k2], C2 === `outline` && ha2.outline, C2 === `outline` && _a2(k2) && ya2[k2], C2 === `media` && ma2.media, f4 === true && ma2.engaged, Ba2.size[w2], Ba2.typography[w2], Ba2.align[a3 ?? `center`], D2 && Ba2.fullWidth, E2 && Ba2.shape.pill, E2 && Ba2.pillSize[w2], Ba2.frame[T2], S2?.buttonRootStyle, h4, Ha), P3 = Ua2(l5, A2), F2 = Ua2(u3, A2), I2 = c3; + if (d3 != null) { + let e39 = h(Ba2.labelGroup), t3 = h(Ba2.kbs); + I2 = (0, J2.jsxs)(`span`, { className: K2(`ui-button__label-group`, e39.className), style: e39.style, children: [P3, c3, F2, (0, J2.jsx)(`span`, { className: K2(`ui-button__kbs`, t3.className), style: t3.style, children: d3 })] }); + } else (P3 != null || F2 != null) && (I2 = (0, J2.jsxs)(J2.Fragment, { children: [P3, c3, F2] })); + return (0, J2.jsx)(Wc, { ...x2, ...qi2.self, onKeyDown: Sa2(y4), onKeyUp: Sa2(b2), "aria-busy": v5, "aria-expanded": g5, "aria-pressed": g5 === void 0 ? f4 === void 0 ? _5 : f4 : _5, className: K2(`ui-button`, N3.className, p4), style: { ...N3.style, ...m3 }, "data-variant": C2, "data-size": w2, "data-rounded": E2 || void 0, "data-frame": T2 === `container` ? void 0 : T2, "data-tone": k2, "data-align": a3 === `left` ? a3 : void 0, "data-full-width": D2 || void 0, "data-pressed": f4 === void 0 ? j2 : String(f4), "data-busy": v5 === true || v5 === `true` ? `` : void 0, "data-padded-label": T2 === `container` ? `` : void 0, disabled: O2, children: (0, J2.jsx)(gi2, { iconSize: A2, children: I2 }) }); +} +var _o2 = { self: { k3aq6I: `ui-3oybdh ui-1uf67wv`, k3nNDw: `ui-1g0ag68`, $$css: true }, part: { k3aq6I: `ui-3oybdh ui-5x4apn`, k3nNDw: `ui-1g0ag68`, $$css: true } }; +var yo2 = { root: { kVAEAm: `ui-1n2onr6`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kB7OPa: `ui-9f619`, kMzoRj: `ui-mkeg23`, ksu8eU: `ui-1y0btm7`, kaIpWk: `ui-1e1y6u3`, kMwMTN: `ui-1lriclw ui-m9a9xk`, kWkggS: `ui-i07v4r ui-1yow1yk ui-ff598k`, kVAM5u: `ui-1tjqsyf ui-1b3ufqo ui-1ch3k2o`, k1ekBW: `ui-1lxufdw`, kIyJzY: `ui-2krxs4 ui-6458p5`, kAMwcw: `ui-fl15g4`, $$css: true }, sm: { kzqmXN: `ui-2s4hoy`, kZKoxP: `ui-px1j5t`, $$css: true }, md: { kzqmXN: `ui-ek66a6`, kZKoxP: `ui-1q5geii`, $$css: true }, lg: { kzqmXN: `ui-1xx3ewh`, kZKoxP: `ui-14dyci`, $$css: true } }; +var bo2 = { primary: { "--ui-checkbox-bg": `ui-x0sf4j`, "--ui-checkbox-border": `ui-14p436a`, "--ui-checkbox-glyph": `ui-1d5945d`, $$css: true }, green: { "--ui-checkbox-bg": `ui-1g72fie`, "--ui-checkbox-border": `ui-165ap9x`, "--ui-checkbox-glyph": `ui-1d5945d`, $$css: true }, neutral: { "--ui-checkbox-bg": `ui-1rpsy8r`, "--ui-checkbox-border": `ui-mtpsoh`, "--ui-checkbox-glyph": `ui-qnctk6`, $$css: true } }; +var xo2 = { sm: 9, md: 10, lg: 11 }; +var So2 = { "--icon-weight": `700` }; +function Co2({ indeterminate: e38, interactive: t2, size: n2, variant: r2 }) { + Co2.d = 1152170032; + let i3 = h(yo2.root, _o2.part, yo2[n2], bo2[r2], t2 && Ki2.part), a3 = { className: `ui-10l6tqk ui-10a8y8t ui-3nfvp2 ui-6s0dn4 ui-l56j7k ui-1g0ag68 ui-n9if97 ui-7pq1vu ui-6458p5 ui-114a5dy ui-g01cxk ui-hhdk15 ui-nyzrob ui-h98lc ui-1nrvvgt ui-cntms` }, o3 = xo2[n2]; + return (0, J2.jsx)(`span`, { "aria-hidden": `true`, className: K2(`ui-checkbox__box`, i3.className), style: i3.style, children: t2 ? (0, J2.jsx)(Cu, { className: K2(`ui-checkbox__icon`, a3.className), keepMounted: true, render: (e39, t3) => (0, J2.jsx)(`span`, { ...e39, children: (0, J2.jsx)(Oi, { capTrim: true, name: t3.indeterminate ? `minus` : `check`, size: o3, style: So2 }) }), style: a3.style }) : (0, J2.jsx)(`span`, { className: K2(`ui-checkbox__icon`, a3.className), style: a3.style, children: (0, J2.jsx)(Oi, { capTrim: true, name: e38 ? `minus` : `check`, size: o3, style: So2 }) }) }); +} +function To2({ checked: e38, disabled: t2, indeterminate: n2 = false, size: r2 = `md`, variant: i3 = `primary` }) { + To2.d = 3597657624; + let a3 = { className: `ui-3nfvp2 ui-6s0dn4 ui-l56j7k ui-1c4vz4f ui-2lah0s ui-dl72j9 ui-xymvpz ui-47corl ui--default-marker` }; + return (0, J2.jsx)(`span`, { "aria-hidden": `true`, className: K2(`ui-checkbox`, a3.className), style: a3.style, "data-component": `checkbox`, "data-size": r2, "data-variant": i3, "data-checked": e38 || void 0, "data-disabled": t2 || void 0, "data-indeterminate": n2 || void 0, children: (0, J2.jsx)(Co2, { indeterminate: n2, interactive: false, size: r2, variant: i3 }) }); +} +var Mo2 = { popup: { "--ui-floating-anchor-offset-x": `ui-1j6m33m ui-ionq63 ui-l7rd01`, "--ui-floating-anchor-offset-y": `ui-14hk5xf ui-wyo6tf ui-17dzj2r`, k6sLGO: `ui-1so62im`, k3nNDw: `ui-ctpfpq`, kKVMdj: `ui-1yjmni4`, kyAemX: `ui-18ctxkd`, k44tkh: `ui-ykr0s4 ui-p0ivey ui-bm7srp`, k1ekBW: `ui-11xpdln`, kAMwcw: `ui-114a5dy`, kIyJzY: `ui-7pq1vu ui-1fdgx8g ui-6458p5`, k3aq6I: `ui-1c071of ui-dv15d5`, $$css: true }, positioner: { "--ui-floating-anchor-fade-duration": `ui-1kwwprx ui-5ece57 ui-az8sdw`, kSiTet: `ui-1hc1fzr ui-4itv7f ui-fwszop`, $$css: true } }; +var No2 = Mo2.popup; +var Po2 = Mo2.positioner; +var Fo2 = { transition: `opacity var(--ui-floating-anchor-fade-duration) ${fr2[`--ease-sharp`]}` }; +function Io2(...e38) { + let t2 = h(Po2, ...e38); + return { ...t2, style: { ...t2.style, ...Fo2 } }; +} +var Lo2 = { border: { k5JduY: `ui-1s928wv`, kwXMNM: `ui-1j6awrg`, k3foIR: `ui-1m1drc7`, kH8aOt: `ui-1unh1gc`, k8Iv0R: `ui-1xrz1ek`, kc1e00: `ui-1iygr5g`, kDVEDD: `ui-itxdhh`, kUfP38: `ui-1k48kgn`, kbMawA: `ui-1o7vem3`, kloYau: `ui-2q1x1w`, $$css: true } }; +var Ro2 = { positioner: { kY2c9j: `ui-2hst0z`, $$css: true }, popupPositioner: { kY2c9j: `ui-fc2p8`, $$css: true }, popupShadow: { kGVxlE: `ui-1x78n9t`, $$css: true }, tooltipShadow: { kGVxlE: `ui-4l6n3x`, $$css: true }, popupRadius: { kaIpWk: `ui-1pkpdue`, $$css: true }, tooltipRadius: { kaIpWk: `ui-15ujvgx`, $$css: true }, toolbarSurface: { "--ui-surface-hairline-width": `ui-10ssw4j`, kaIpWk: `ui-15ujvgx`, $$css: true }, surface: { kB7OPa: `ui-9f619`, kVAEAm: `ui-1n2onr6`, kWkggS: `ui-f1vpex`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kaIpWk: `ui-1pkpdue`, kMwMTN: `ui-1wd3ewq`, kMv6JI: `ui-1acoasx`, kGuDYH: `ui-11wthnw`, kLWn49: `ui-1ja60sm`, kb6lSQ: `ui-vu1jfw`, khiITx: `ui-vmahel`, kTUp5R: `ui-lh3980`, $$css: true }, popupLayout: { k1xSpc: `ui-1lliihq`, kzqmXN: `ui-ezivpi`, ks0D6T: `ui-w5ewwj`, kHjlTd: `ui-j0a0fe`, $$css: true }, popupInset: { kLKAdn: `ui-uve7l6`, kwRFfy: `ui-196pc8s`, kGO01o: `ui-1rgtt3y`, kZCmMZ: `ui-22095l`, $$css: true }, previewCardInset: { kLKAdn: `ui-oyc9vk`, kwRFfy: `ui-1fg0g13`, kGO01o: `ui-2lprc`, kZCmMZ: `ui-1tajz9i`, $$css: true }, popupInteractive: { kfzvcC: `ui-67bb7w`, kfSwDN: `ui-1hx0egp`, $$css: true }, popupSurfaceMd: { kaIpWk: `ui-1pkpdue`, $$css: true }, tooltipSurface: { "--ui-surface-hairline-width": `ui-10ssw4j`, kGuDYH: `ui-mppzg7`, kLWn49: `ui-l68z86`, kb6lSQ: `ui-55tv1j`, kLKAdn: `ui-3jsnqb`, kGO01o: `ui-1w5ico7`, kwRFfy: `ui-180w9kh`, kZCmMZ: `ui-1vs96pt`, $$css: true } }; +var zo2 = Ro2.positioner; +var Bo2 = [Ro2.surface, Lo2.border]; +var Vo2 = [zo2, Ro2.popupShadow, Ro2.popupRadius]; +var Ho2 = [zo2, Ro2.tooltipShadow, Ro2.tooltipRadius]; +var Wo2 = [Ro2.tooltipRadius, Ro2.tooltipSurface]; +var Go2 = Ro2.popupLayout; +var Ko2 = Ro2.popupInset; +var qo2 = Ro2.previewCardInset; +var Jo2 = [Go2, Ko2]; +var Xo2 = [Ro2.surface, Lo2.border]; +var Zo2 = Ro2.popupSurfaceMd; +var Qo = [Ro2.popupPositioner, Ro2.popupShadow, Ro2.popupRadius]; +var $o = { ks0D6T: `ui-13kvn80`, $$css: true }; +var es = { ks0D6T: `ui-f68679`, $$css: true }; +var ts2 = { kskxy: `ui-1jols5v`, $$css: true }; +var Z2 = { popupFrame: { kB7OPa: `ui-9f619`, k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kHBbk8: `ui-c8icb0`, kfSwDN: `ui-87ps6o`, kY4cRS: `ui-lvsv26`, $$css: true }, menuPopup: { k7Eaqz: `ui-1i9suas`, ks0D6T: `ui-13kvn80`, kskxy: `ui-1u4d8o5`, kaIpWk: `ui-1828qc5`, kMeerF: `ui-1k57tk5`, k3XXqK: `ui-1t137rt`, $$css: true }, menuPositionerRadius: { kaIpWk: `ui-1828qc5`, $$css: true }, menuPopupHideWhenAnchorHidden: { kV4ckA: `ui-2f5yyy`, kYLTpN: `ui-1hyz5x3`, $$css: true }, anchorReset: { "--available-width": `ui-1wd9z7n`, "--available-height": `ui-1px786n`, "--anchor-width": `ui-4m06ot`, "--anchor-height": `ui-1x9mm2a`, "--transform-origin": `ui-pmnpdm`, $$css: true }, menuPopupContent: { k1xSpc: `ui-jp7ctv`, $$css: true }, menuPopupWidth: (e38) => [$o, { kzqmXN: e38 == null ? e38 : `ui-5lhr3w`, $$css: true }, { "--x-width": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(e38) }], menuPopupDefaultWidth: { kzqmXN: `ui-ezivpi`, k7Eaqz: `ui-lopysa`, $$css: true }, menuPopupMinWidth: (e38) => [{ k7Eaqz: e38 == null ? e38 : `ui-kj4a21`, $$css: true }, { "--x-minWidth": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(e38) }], menuPopupMaxWidth: (e38) => [es, { "--x-maxWidth": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(`min(${typeof e38 == `number` ? `${e38}px` : e38}, var(--available-width))`) }], menuPopupHug: { kzqmXN: `ui-ezivpi`, $$css: true }, menuPopupMaxHeight: (e38) => [ts2, { "--x-maxHeight": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(`min(${typeof e38 == `number` ? `${e38}px` : e38}, var(--available-height, 100vh))`) }], list: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kAzted: `ui-2lwn1j`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-ryxfnj`, $$css: true }, menuList: { kOIVth: `ui-x00bh8`, kLKAdn: `ui-vxa9ti`, kwRFfy: `ui-1oqqsvb`, kGO01o: `ui-k1wcff`, kZCmMZ: `ui-6wvkkf`, $$css: true }, menuListWhenEmpty: { kLKAdn: `ui-vxa9ti ui-l6bsgv`, kGO01o: `ui-k1wcff ui-1tsmoef`, $$css: true }, menuFixedSlot: { kB7OPa: `ui-9f619`, kmuXW: `ui-2lah0s`, kLKAdn: `ui-vxa9ti`, kwRFfy: `ui-1oqqsvb`, kGO01o: `ui-k1wcff`, kZCmMZ: `ui-6wvkkf`, $$css: true }, menuHeader: { kt9PQ7: `ui-1mk49ma`, kfdmCh: `ui-1q0q8m5`, kL6WhQ: `ui-b6scco`, $$css: true }, menuFooter: { kEafiO: `ui-jpjugk`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-14av3n6`, $$css: true }, group: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kOIVth: `ui-x00bh8`, $$css: true }, groupLabel: { kzQI83: `ui-1iyjqo2`, k7Eaqz: `ui-euugli`, $$css: true }, divider: { kB7OPa: `ui-9f619`, kZKoxP: `ui-1ws4142`, kAzted: `ui-66wokv`, kWkggS: `ui-ry6dcj`, kEafiO: `ui-972fbf`, ke9TFa: `ui-10w94by`, kt9PQ7: `ui-1qhh985`, k2ei4v: `ui-14e42zd`, kPef9Z: `ui-1ejq31n`, k8ry5P: `ui-18oe1m7`, kfdmCh: `ui-1sy0etr`, kVhnKS: `ui-stzfhl`, keoZOQ: `ui-1x0km78`, k71WvV: `ui-k0f3xd`, k1K539: `ui-1j5pw3q`, keTefX: `ui-1a9zro7`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, kfzvcC: `ui-47corl`, $$css: true }, separatorLayout: { kSGwAc: `ui-kh2ocl`, kmuXW: `ui-2lah0s`, $$css: true }, row: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-1q0g3np`, kGNEyG: `ui-6s0dn4`, kMeerF: `ui-1k57tk5`, k3XXqK: `ui-1t137rt`, kkrTdU: `ui-1ypdohk ui-mh7c9n`, kMwMTN: `ui-1wd3ewq ui-1kosevp`, kWkggS: `ui-jbqb8w ui-1sbws7q`, $$css: true }, rowFrame: { kB7OPa: `ui-9f619`, kVAEAm: `ui-1n2onr6`, kOIVth: `ui-xhr3t`, kaIpWk: `ui-2u8bby`, "--ui-popup-list-row-highlighted-opacity": `ui-5i412e ui-1nlrr02`, kWkggS: `ui-jbqb8w ui-9wl9qz`, $$css: true }, menuRowMinHeight: { kAzted: `ui-1ff271z ui-1yrgodw`, $$css: true }, menuRowMetrics: { kLKAdn: `ui-1305i5w ui-c9dpsm`, kwRFfy: `ui-o6jljq`, kGO01o: `ui-1ioonqm ui-1t9sq64`, kZCmMZ: `ui-1d8gtjo`, $$css: true }, rowInsetHighlight: { kOEVvA: `ui-i4tjbf`, k5uj8I: `ui-66jpid`, kq4gsV: `ui-1kn4tos`, k4ymXE: `ui-1h1qzfg`, kF4oUt: `ui-15ommkv`, kPsB8K: `ui-6o5ikd`, keQWX6: `ui-vv2yia`, kqNwI3: `ui-1yj7zuh`, kSJm4H: `ui-1hezt85`, kVBs6H: `ui-1isuopv`, $$css: true }, menuRowPriority: { kMwMTN: `ui-acck0t ui-731v8i`, kSiTet: `ui-1szrgyu`, $$css: true }, menuRowLeading: { kmuXW: `ui-2lah0s`, kVAEAm: `ui-1n2onr6`, kY2c9j: `ui-1vjfegm`, kMwMTN: `ui-1lhgsel ui-qj52dh`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, k71WvV: `ui-1i7sqng`, $$css: true }, menuRowLeadingBox: { kzqmXN: `ui-1sdg1an`, kZKoxP: `ui-okyidv`, $$css: true }, rowText: { kUk6DE: `ui-98rzlu`, k7Eaqz: `ui-euugli`, $$css: true }, rowSection: { k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kmuXW: `ui-2lah0s`, kMwMTN: `ui-19aaqeu`, $$css: true }, rowSectionTrailing: { keTefX: `ui-kiyga0`, $$css: true }, rowSectionDescription: { kSGwAc: `ui-qcrz7y`, keoZOQ: `ui-1k5org8`, $$css: true }, popupBackdrop: { kVAEAm: `ui-ixxii4`, kpwlN0: `ui-10a8y8t`, kWkggS: `ui-jbqb8w`, kY4cRS: `ui-lvsv26`, $$css: true }, popupBackdropZIndex: (e38) => [{ kY2c9j: e38 == null ? e38 : `ui-r3buco`, $$css: true }, { "--x-zIndex": e38 ?? void 0 }] }; +var ns = Z2.list; +var rs = Z2.row; +var is = Z2.popupFrame; +var as = Z2.rowFrame; +var os = Z2.rowInsetHighlight; +var ls2 = Z2.rowSectionTrailing; +var us2 = Z2.rowSectionDescription; +var _s2 = Z2.menuPopupHideWhenAnchorHidden; +var vs2 = Z2.popupBackdrop; +var ys2 = Z2.popupBackdropZIndex; +var Ns2 = Z2.anchorReset; +var Ps2 = { popup: { k7Eaqz: `ui-1i9suas`, ks0D6T: `ui-13kvn80`, kskxy: `ui-2pj5ht`, $$css: true }, popupWidth: (e38) => [{ kzqmXN: e38 == null ? e38 : `ui-5lhr3w`, ks0D6T: e38 == null ? e38 : `ui-f68679`, $$css: true }, { "--x-width": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(e38), "--x-maxWidth": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(e38) }], popupDefaultWidth: { kzqmXN: `ui-ezivpi`, k7Eaqz: `ui-lopysa`, $$css: true }, list: { kOIVth: `ui-ihas45`, kLKAdn: `ui-9g4tyx`, kwRFfy: `ui-yri2b`, kGO01o: `ui-x776sp`, kZCmMZ: `ui-1c1uobl`, $$css: true }, row: { kAzted: `ui-14dnd5q ui-12uk8lx`, kLKAdn: `ui-p90ga9 ui-17apzky`, kwRFfy: `ui-mk9vl6`, kGO01o: `ui-1ep5yuf ui-zkc5ih`, kZCmMZ: `ui-vtdk6d`, $$css: true }, rowText: { kUk6DE: `ui-98rzlu`, k7Eaqz: `ui-euugli`, kVAEAm: `ui-1n2onr6`, kY2c9j: `ui-1vjfegm`, $$css: true }, rowLabel: { k1xSpc: `ui-1lliihq`, kzQI83: `ui-1iyjqo2`, kmuXW: `ui-s83m0k`, kCS8Yb: `ui-dl72j9`, k7Eaqz: `ui-euugli`, ks0D6T: `ui-193iq5w`, kVQacm: `ui-b3r6kr`, kg5iWk: `ui-lyipyv`, khDVqt: `ui-uxw1ft`, $$css: true }, itemTextWithMeta: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-1q0g3np`, kGNEyG: `ui-1pha0wt`, k7Eaqz: `ui-euugli`, ks0D6T: `ui-193iq5w`, $$css: true }, rowTextWithDescription: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kGNEyG: `ui-1cy8zhl`, kOIVth: `ui-137clkk`, $$css: true }, rowDescription: { k1xSpc: `ui-1lliihq`, ks0D6T: `ui-193iq5w`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kg5iWk: `ui-lyipyv`, khDVqt: `ui-uxw1ft`, kMwMTN: `ui-4b2ntj`, $$css: true }, rowMeta: { keTefX: `ui-1uokl23`, $$css: true }, rowSection: { k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kmuXW: `ui-2lah0s`, kVAEAm: `ui-1n2onr6`, kY2c9j: `ui-1vjfegm`, kMwMTN: `ui-19aaqeu`, $$css: true }, rowSectionLeading: { k71WvV: `ui-17adnql`, $$css: true }, rowSectionEnd: { kOIVth: `ui-1jcujwu`, $$css: true } }; +var Fs2 = [Xo2, is, Ps2.popup]; +var Is2 = { sm: null, md: Zo2 }; +var Ls2 = Ps2.popupWidth; +var Rs2 = Ps2.popupDefaultWidth; +var zs2 = [ns, Ps2.list]; +var Bs2 = [rs, as, Ps2.row, os, Ta2.root]; +var Vs2 = Ps2.rowText; +var Hs2 = Ps2.rowLabel; +var Us2 = Ps2.itemTextWithMeta; +var Ws = Ps2.rowTextWithDescription; +var Gs2 = Ps2.rowDescription; +var Ks2 = Ps2.rowMeta; +var qs2 = Ps2.rowSection; +var Js = Ps2.rowSectionLeading; +var Ys = ls2; +var Xs = Ps2.rowSectionEnd; +var Zs2 = us2; +function Qs2() { + let e38 = (0, Y2.useRef)(void 0), t2 = (0, Y2.useCallback)(() => { + let t3 = e38.current; + t3 !== void 0 && (e38.current = void 0, cancelAnimationFrame2(t3)); + }, []), n2 = (0, Y2.useCallback)((n3) => { + t2(), e38.current = requestAnimationFrame2((t3) => { + e38.current = void 0, n3(t3); }); }, [t2]); - return (0, J2.useEffect)(() => t2, [t2]), (0, J2.useMemo)(() => ({ dispose: t2, request: n2 }), [t2, n2]); + return (0, Y2.useEffect)(() => t2, [t2]), (0, Y2.useMemo)(() => ({ dispose: t2, request: n2 }), [t2, n2]); } -function Rs(e9) { - return typeof ResizeObserver2 > `u` ? null : new ResizeObserver2(e9); +function $s2(e38) { + return typeof ResizeObserver2 > `u` ? null : new ResizeObserver2(e38); } -function zs({ deltaX: e9, deltaY: t2, mapVerticalWheelToHorizontal: n2, axisBehavior: r2 = `dominant`, mappedBehavior: i3 = `dominant` }) { +function ec2({ deltaX: e38, deltaY: t2, mapVerticalWheelToHorizontal: n2, axisBehavior: r2 = `dominant`, mappedBehavior: i3 = `dominant` }) { if (n2) { let n3; - return n3 = i3 === `dominant` && Math.abs(t2) > Math.abs(e9) ? t2 : e9 || t2, n3 === 0 ? null : n3; + return n3 = i3 === `dominant` && Math.abs(t2) > Math.abs(e38) ? t2 : e38 || t2, n3 === 0 ? null : n3; } - return r2 === `raw` ? e9 === 0 ? null : e9 : e9 === 0 || Math.abs(e9) <= Math.abs(t2) ? null : e9; + return r2 === `raw` ? e38 === 0 ? null : e38 : e38 === 0 || Math.abs(e38) <= Math.abs(t2) ? null : e38; } -var Bs = `hover`; -function Vs(e9) { - let { scrollTop: t2, scrollHeight: n2, clientHeight: r2, threshold: i3 } = e9; +var tc2 = `hover`; +function nc2(e38) { + let { scrollTop: t2, scrollHeight: n2, clientHeight: r2, threshold: i3 } = e38; return { isAtTop: t2 <= i3, isAtBottom: t2 + r2 >= n2 - i3 }; } -function Hs(e9) { - let { scrollLeft: t2, scrollWidth: n2, clientWidth: r2, threshold: i3 } = e9, a3 = Math.abs(t2); +function rc2(e38) { + let { scrollLeft: t2, scrollWidth: n2, clientWidth: r2, threshold: i3 } = e38, a3 = Math.abs(t2); return { isAtStart: a3 <= i3, isAtEnd: a3 + r2 >= n2 - i3 }; } -var Us = [`mask-image`, `-webkit-mask-image`, `mask-size`, `mask-repeat`, `mask-composite`, `-webkit-mask-composite`]; -function Ws(e9, t2, n2) { - let r2 = e9.style, i3 = []; +var ic2 = [`mask-image`, `-webkit-mask-image`, `mask-size`, `mask-repeat`, `mask-composite`, `-webkit-mask-composite`]; +function ac2(e38, t2, n2) { + let r2 = e38.style, i3 = []; if (t2.top || t2.bottom || t2.start || t2.end) { if (n2.block) { - let e10 = t2.top ? `var(--scroll-fade-top-size)` : `0px`, n3 = t2.bottom ? `var(--scroll-fade-bottom-size)` : `0px`; - i3.push(`linear-gradient(to bottom, rgba(0, 0, 0, var(--scroll-fade-top-start-opacity)) 0px, black ${e10}, black calc(100% - ${n3}), rgba(0, 0, 0, var(--scroll-fade-bottom-start-opacity)) 100%)`); + let e39 = t2.top ? `var(--scroll-fade-top-size)` : `0px`, n3 = t2.bottom ? `var(--scroll-fade-bottom-size)` : `0px`; + i3.push(`linear-gradient(to bottom, rgba(0, 0, 0, var(--scroll-fade-top-start-opacity)) 0px, black ${e39}, black calc(100% - ${n3}), rgba(0, 0, 0, var(--scroll-fade-bottom-start-opacity)) 100%)`); } if (n2.inline) { - let e10 = t2.start ? `var(--scroll-fade-start-size)` : `0px`, n3 = t2.end ? `var(--scroll-fade-end-size)` : `0px`; - i3.push(`linear-gradient(to right, transparent 0px, black ${e10}, black calc(100% - ${n3}), transparent 100%)`); + let e39 = t2.start ? `var(--scroll-fade-start-size)` : `0px`, n3 = t2.end ? `var(--scroll-fade-end-size)` : `0px`; + i3.push(`linear-gradient(to right, transparent 0px, black ${e39}, black calc(100% - ${n3}), transparent 100%)`); } } if (i3.length === 0) { - for (let e10 of Us) r2.removeProperty(e10); + for (let e39 of ic2) r2.removeProperty(e39); return; } let a3 = i3.join(`, `); r2.setProperty(`mask-image`, a3), r2.setProperty(`-webkit-mask-image`, a3), r2.setProperty(`mask-size`, i3.map(() => `100% 100%`).join(`, `)), r2.setProperty(`mask-repeat`, `no-repeat`), i3.length > 1 && (r2.setProperty(`mask-composite`, `intersect`), r2.setProperty(`-webkit-mask-composite`, `source-in`)); } -function Gs({ block: e9, inline: t2 }) { - return { ...e9 && { "--scroll-fade-top-size": `${e9.topPx}px`, "--scroll-fade-bottom-size": `${e9.bottomPx}px`, "--scroll-fade-top-start-opacity": String(e9.topStartOpacity), "--scroll-fade-bottom-start-opacity": String(e9.bottomStartOpacity) }, ...t2 && { "--scroll-fade-start-size": `${t2.startPx}px`, "--scroll-fade-end-size": `${t2.endPx}px` } }; +function oc2({ block: e38, inline: t2 }) { + return { ...e38 && { "--scroll-fade-top-size": `${e38.topPx}px`, "--scroll-fade-bottom-size": `${e38.bottomPx}px`, "--scroll-fade-top-start-opacity": String(e38.topStartOpacity), "--scroll-fade-bottom-start-opacity": String(e38.bottomStartOpacity) }, ...t2 && { "--scroll-fade-start-size": `${t2.startPx}px`, "--scroll-fade-end-size": `${t2.endPx}px` } }; } -var Ks = 20; -var qs = class { +var sc2 = 20; +var cc2 = class { constructor() { this._trackSize = 0, this._viewportSize = 0, this._scrollSize = 0, this._scrollPosition = 0, this._isScrollable = false, this._thumbSize = 0, this._thumbPosition = 0, this._thumbRatio = 0; } - setDimensions(e9, t2, n2, r2) { - let i3 = Math.round(e9), a3 = Math.round(t2), o3 = Math.round(n2), s3 = Math.round(r2); + setDimensions(e38, t2, n2, r2) { + let i3 = Math.round(e38), a3 = Math.round(t2), o3 = Math.round(n2), s3 = Math.round(r2); return this._trackSize === i3 && this._viewportSize === a3 && this._scrollSize === o3 && this._scrollPosition === s3 ? false : (this._trackSize = i3, this._viewportSize = a3, this._scrollSize = o3, this._scrollPosition = s3, this._recompute(), true); } - setScrollPosition(e9) { - let t2 = Math.round(e9); + setScrollPosition(e38) { + let t2 = Math.round(e38); return this._scrollPosition !== t2 && (this._scrollPosition = t2, this._thumbPosition = this._computeThumbPosition(), true); } _recompute() { @@ -2777,8 +7637,8 @@ var qs = class { this._thumbSize = 0, this._thumbPosition = 0, this._thumbRatio = 0; return; } - let e9 = Math.floor(this._trackSize * this._viewportSize / this._scrollSize); - this._thumbSize = Math.min(this._trackSize, Math.max(Ks, e9)); + let e38 = Math.floor(this._trackSize * this._viewportSize / this._scrollSize); + this._thumbSize = Math.min(this._trackSize, Math.max(sc2, e38)); let t2 = this._trackSize - this._thumbSize, n2 = this._scrollSize - this._viewportSize; this._thumbRatio = n2 > 0 ? t2 / n2 : 0, this._thumbPosition = this._computeThumbPosition(); } @@ -2797,16 +7657,16 @@ var qs = class { getThumbPosition() { return this._thumbPosition; } - getScrollPositionFromThumbDelta(e9, t2) { - return !this._isScrollable || this._thumbRatio === 0 ? 0 : Math.round(t2 + e9 / this._thumbRatio); + getScrollPositionFromThumbDelta(e38, t2) { + return !this._isScrollable || this._thumbRatio === 0 ? 0 : Math.round(t2 + e38 / this._thumbRatio); } - getScrollPositionFromTrackOffset(e9) { + getScrollPositionFromTrackOffset(e38) { if (!this._isScrollable || this._thumbRatio === 0) return 0; - let t2 = Math.max(0, Math.min(this._trackSize - this._thumbSize, e9 - this._thumbSize / 2)); + let t2 = Math.max(0, Math.min(this._trackSize - this._thumbSize, e38 - this._thumbSize / 2)); return Math.round(t2 / this._thumbRatio); } }; -var Js = class e6 { +var lc2 = class e34 { static { this.VERTICAL_THUMB_OFFSET_CSS_VAR = `--scrollbar-thumb-top-offset`; } @@ -2819,15 +7679,17 @@ var Js = class e6 { static { this.thumbSyncFrame = null; } - static flushThumbSyncs() { - e6.thumbSyncFrame = null; - let t2 = [...e6.pendingThumbSyncs]; - e6.pendingThumbSyncs.clear(); - let n2 = t2.filter((e9) => e9.measureThumb()); - for (let e9 of n2) e9.applyThumbStyle(), e9.applyFadeEdges(); + static { + this.flushThumbSyncs = () => { + e34.thumbSyncFrame = null; + let t2 = [...e34.pendingThumbSyncs]; + e34.pendingThumbSyncs.clear(); + let n2 = t2.filter((e38) => e38.measureThumb()); + for (let e38 of n2) e38.applyThumbStyle(), e38.applyFadeEdges(); + }; } - constructor(e9) { - this.fadeEdges = [false, false], this.reportedScrollable = null, this.thumbInsetStart = 0, this.horizontalWheelAxisLock = null, this.horizontalWheelResetTimer = null, this.resizeObserver = null, this.boundOnScroll = null, this.boundOnThumbDown = null, this.boundOnTrackDown = null, this.boundOnWheel = null, this.dragCleanup = null, this.viewport = e9.viewport, this.content = e9.content, this.scrollbar = e9.scrollbar, this.thumb = e9.thumb, this.state = new qs(), this.direction = e9.direction, this.mapVerticalWheelToHorizontal = e9.mapVerticalWheelToHorizontal ?? false, this.onFadeEdgesChange = e9.onFadeEdgesChange, this.onScrollableChange = e9.onScrollableChange; + constructor(e38) { + this.fadeEdges = [false, false], this.reportedScrollable = null, this.thumbInsetStart = 0, this.horizontalWheelAxisLock = null, this.horizontalWheelResetTimer = null, this.resizeObserver = null, this.boundOnScroll = null, this.boundOnThumbDown = null, this.boundOnTrackDown = null, this.boundOnWheel = null, this.dragCleanup = null, this.viewport = e38.viewport, this.content = e38.content, this.scrollbar = e38.scrollbar, this.thumb = e38.thumb, this.state = new cc2(), this.direction = e38.direction, this.mapVerticalWheelToHorizontal = e38.mapVerticalWheelToHorizontal ?? false, this.onFadeEdgesChange = e38.onFadeEdgesChange, this.onScrollableChange = e38.onScrollableChange; } get horizontal() { return this.direction === `horizontal`; @@ -2837,8 +7699,8 @@ var Js = class e6 { } detach() { this.detachScrollListener(), this.detachResizeObserver(), this.detachPointerEvents(), this.detachWheelForwarding(); - let t2 = e6.pendingThumbSyncs; - t2.delete(this), t2.size === 0 && e6.thumbSyncFrame !== null && (cancelAnimationFrame2(e6.thumbSyncFrame), e6.thumbSyncFrame = null), this.horizontalWheelResetTimer &&= (clearTimeout(this.horizontalWheelResetTimer), null), this.horizontalWheelAxisLock = null; + let t2 = e34.pendingThumbSyncs; + t2.delete(this), t2.size === 0 && e34.thumbSyncFrame !== null && (cancelAnimationFrame2(e34.thumbSyncFrame), e34.thumbSyncFrame = null), this.horizontalWheelResetTimer &&= (clearTimeout(this.horizontalWheelResetTimer), null), this.horizontalWheelAxisLock = null; } refresh() { this.scheduleSyncThumb(); @@ -2850,1892 +7712,3768 @@ var Js = class e6 { this.boundOnScroll &&= (this.viewport.removeEventListener(`scroll`, this.boundOnScroll), null); } handleScroll() { - let e9 = this.horizontal ? this.viewport.scrollLeft : this.viewport.scrollTop; - if (this.state.setScrollPosition(e9)) { - let e10 = this.state.getThumbPosition(); - this.thumb.style.transform = this.getThumbTransform(e10), this.applyFadeEdges(); + let e38 = this.horizontal ? this.viewport.scrollLeft : this.viewport.scrollTop; + if (this.state.setScrollPosition(e38)) { + let e39 = this.state.getThumbPosition(); + this.thumb.style.transform = this.getThumbTransform(e39), this.applyFadeEdges(); } } attachResizeObserver() { - this.resizeObserver = Rs(() => this.scheduleSyncThumb()), this.resizeObserver !== null && (this.resizeObserver.observe(this.viewport), this.content !== void 0 && this.resizeObserver.observe(this.content), this.resizeObserver.observe(this.scrollbar)); + this.resizeObserver = $s2(() => this.scheduleSyncThumb()), this.resizeObserver !== null && (this.resizeObserver.observe(this.viewport), this.content !== void 0 && this.resizeObserver.observe(this.content), this.resizeObserver.observe(this.scrollbar)); } detachResizeObserver() { this.resizeObserver?.disconnect(), this.resizeObserver = null; } scheduleSyncThumb() { - e6.pendingThumbSyncs.add(this), e6.thumbSyncFrame === null && (e6.thumbSyncFrame = requestAnimationFrame2(e6.flushThumbSyncs)); + e34.pendingThumbSyncs.add(this), e34.thumbSyncFrame === null && (e34.thumbSyncFrame = requestAnimationFrame2(e34.flushThumbSyncs)); } measureThumb() { this.thumbInsetStart = this.getThumbInsetStart(); - let e9 = this.readDimensions(); - return this.state.setDimensions(e9.trackSize, e9.viewportSize, e9.scrollSize, e9.scrollPos); + let e38 = this.readDimensions(); + return this.state.setDimensions(e38.trackSize, e38.viewportSize, e38.scrollSize, e38.scrollPos); } applyFadeEdges() { if (!this.onFadeEdgesChange) return; - let { viewportSize: e9, scrollSize: t2, scrollPosition: n2 } = this.state.getScrollMetrics(), r2, i3; + let { viewportSize: e38, scrollSize: t2, scrollPosition: n2 } = this.state.getScrollMetrics(), r2, i3; if (this.horizontal) { - let { isAtStart: a3, isAtEnd: o3 } = Hs({ scrollLeft: n2, scrollWidth: t2, clientWidth: e9, threshold: 5 }); + let { isAtStart: a3, isAtEnd: o3 } = rc2({ scrollLeft: n2, scrollWidth: t2, clientWidth: e38, threshold: 5 }); r2 = !a3, i3 = !o3; } else { - let { isAtTop: a3, isAtBottom: o3 } = Vs({ scrollTop: n2, scrollHeight: t2, clientHeight: e9, threshold: 5 }); + let { isAtTop: a3, isAtBottom: o3 } = nc2({ scrollTop: n2, scrollHeight: t2, clientHeight: e38, threshold: 5 }); r2 = !a3, i3 = !o3; } (r2 !== this.fadeEdges[0] || i3 !== this.fadeEdges[1]) && (this.fadeEdges = [r2, i3], this.onFadeEdgesChange(r2, i3)); } - readDimensions() { - let e9 = Math.max(0, this.scrollbar.clientHeight - this.thumbInsetStart); - return { trackSize: this.horizontal ? this.scrollbar.clientWidth : e9, viewportSize: this.horizontal ? this.viewport.clientWidth : this.viewport.clientHeight, scrollSize: this.horizontal ? this.viewport.scrollWidth : this.viewport.scrollHeight, scrollPos: this.horizontal ? this.viewport.scrollLeft : this.viewport.scrollTop }; + readDimensions() { + let e38 = Math.max(0, this.scrollbar.clientHeight - this.thumbInsetStart); + return { trackSize: this.horizontal ? this.scrollbar.clientWidth : e38, viewportSize: this.horizontal ? this.viewport.clientWidth : this.viewport.clientHeight, scrollSize: this.horizontal ? this.viewport.scrollWidth : this.viewport.scrollHeight, scrollPos: this.horizontal ? this.viewport.scrollLeft : this.viewport.scrollTop }; + } + applyThumbStyle() { + let e38 = this.state.getThumbSize(), t2 = this.state.getThumbPosition(); + this.horizontal ? (this.thumb.style.width = `${e38}px`, this.thumb.style.height = ``, this.thumb.style.transform = this.getThumbTransform(t2)) : (this.thumb.style.height = `${e38}px`, this.thumb.style.width = ``, this.thumb.style.transform = this.getThumbTransform(t2)); + let n2 = this.state.isScrollable(); + this.scrollbar.dataset.scrollable = n2 ? `true` : `false`, this.onScrollableChange !== void 0 && this.reportedScrollable !== n2 && (this.reportedScrollable = n2, this.onScrollableChange(n2)); + } + attachPointerEvents() { + this.boundOnThumbDown = this.handleThumbDown.bind(this), this.boundOnTrackDown = this.handleTrackDown.bind(this), this.thumb.addEventListener(`pointerdown`, this.boundOnThumbDown), this.scrollbar.addEventListener(`pointerdown`, this.boundOnTrackDown); + } + detachPointerEvents() { + this.boundOnThumbDown &&= (this.thumb.removeEventListener(`pointerdown`, this.boundOnThumbDown), null), this.boundOnTrackDown &&= (this.scrollbar.removeEventListener(`pointerdown`, this.boundOnTrackDown), null), this.dragCleanup?.(), this.dragCleanup = null; + } + handleThumbDown(e38) { + if (e38.button !== 0) return; + e38.preventDefault(); + let t2 = this.horizontal ? e38.clientX : e38.clientY, n2 = this.horizontal ? this.viewport.scrollLeft : this.viewport.scrollTop, r2 = e38.pointerId; + this.thumb.setPointerCapture(r2), this.thumb.classList.add(`ui-scroll-area__thumb--active`); + let i3 = (e39) => { + let r3 = (this.horizontal ? e39.clientX : e39.clientY) - t2, i4 = this.state.getScrollPositionFromThumbDelta(r3, n2); + this.horizontal ? this.viewport.scrollLeft = i4 : this.viewport.scrollTop = i4; + }, a3 = () => { + this.thumb.classList.remove(`ui-scroll-area__thumb--active`); + try { + this.thumb.releasePointerCapture(r2); + } catch { + } + this.thumb.removeEventListener(`pointermove`, i3), this.thumb.removeEventListener(`pointerup`, a3), this.thumb.removeEventListener(`pointercancel`, a3), this.dragCleanup = null; + }; + this.thumb.addEventListener(`pointermove`, i3), this.thumb.addEventListener(`pointerup`, a3), this.thumb.addEventListener(`pointercancel`, a3), this.dragCleanup = a3; + } + handleTrackDown(e38) { + if (e38.button !== 0 || e38.target === this.thumb) return; + let t2 = this.scrollbar.getBoundingClientRect(); + if (!this.horizontal) { + this.viewport.scrollTop = this.state.getScrollPositionFromTrackOffset(e38.clientY - t2.top - this.thumbInsetStart); + return; + } + let n2 = getComputedStyle2(this.viewport).direction === `rtl`, r2 = n2 ? t2.right - e38.clientX : e38.clientX - t2.left, i3 = this.state.getScrollPositionFromTrackOffset(r2); + this.viewport.scrollLeft = n2 ? -i3 : i3; + } + attachWheelForwarding() { + this.boundOnWheel = (t2) => { + if (this.horizontal) { + let n2 = this.viewport.scrollWidth - this.viewport.clientWidth; + if (n2 <= 0) return; + let r2 = null; + if (this.mapVerticalWheelToHorizontal) r2 = ec2({ deltaX: t2.deltaX, deltaY: t2.deltaY, mapVerticalWheelToHorizontal: true, mappedBehavior: `prefer-horizontal` }); + else { + if (this.horizontalWheelAxisLock ||= Math.abs(t2.deltaX) > Math.abs(t2.deltaY) ? `x` : `y`, this.horizontalWheelResetTimer && clearTimeout(this.horizontalWheelResetTimer), this.horizontalWheelResetTimer = setTimeout(() => { + this.horizontalWheelAxisLock = null, this.horizontalWheelResetTimer = null; + }, e34.WHEEL_GESTURE_RESET_MS), this.horizontalWheelAxisLock !== `x`) return; + if (r2 = ec2({ deltaX: t2.deltaX, deltaY: t2.deltaY, mapVerticalWheelToHorizontal: false, axisBehavior: `raw` }), r2 === null) { + t2.preventDefault(), t2.stopPropagation(); + return; + } + } + if (r2 === null) return; + let i3 = Math.max(0, Math.min(n2, this.viewport.scrollLeft + r2)); + this.viewport.scrollLeft = i3, t2.preventDefault(), t2.stopPropagation(); + } else this.viewport.scrollTop += t2.deltaY; + }, this.scrollbar.addEventListener(`wheel`, this.boundOnWheel, { passive: false }); + } + detachWheelForwarding() { + this.boundOnWheel &&= (this.scrollbar.removeEventListener(`wheel`, this.boundOnWheel), null); + } + getThumbTransform(e38) { + return this.horizontal ? `translateX(${e38}px)` : `translateY(${e38 + this.thumbInsetStart}px)`; + } + getThumbInsetStart() { + if (this.horizontal) return 0; + let t2 = getComputedStyle2(this.scrollbar).getPropertyValue(e34.VERTICAL_THUMB_OFFSET_CSS_VAR), n2 = Number.parseFloat(t2); + return Number.isFinite(n2) ? Math.max(0, n2) : 0; + } +}; +var uc2 = { base: { "--scrollbar-size": `ui-1ekbvf6`, "--scrollbar-inset": `ui-1logqu4`, "--scrollbar-thumb-top-offset": `ui-1fx8caa`, "--scroll-area-scroll-padding": `ui-8ddqcf`, kVAEAm: `ui-1n2onr6`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, k1xSpc: `ui-rvj5dj`, k52YG4: `ui-n3lufb`, $$css: true } }; +var dc2 = { base: { kJuA4N: `ui-15r89dc`, kAzted: `ui-2lwn1j`, kskxy: `ui-mz0i5r`, kaIpWk: `ui-1pjcqnp`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-1odjw0f`, kaPefq: `ui-1fu52t7`, kC2sXz: `ui-1ufbpdf`, k9lH4S: `ui-3oazx1`, kphCe6: `ui-19l4kpp`, kvh3hx: `ui-1t1jukp`, kacamN: `ui-1e4zzel`, k5wCbM: `ui-1rohswg`, kAnDOJ: `ui-6ehuon`, kOuLrU: `ui-fk6m8`, $$css: true }, horizontal: { kXHlph: `ui-w2csxc`, kORKVm: `ui-10wlt62`, kaPefq: `ui-k8sdt9`, kC2sXz: `ui-1duton`, k9lH4S: `ui-101ixbw`, kphCe6: `ui-exgr1p`, kvh3hx: `ui-7p5m3t`, kacamN: `ui-y5w88m`, $$css: true }, both: { kXHlph: `ui-w2csxc`, kORKVm: `ui-1odjw0f`, kaPefq: `ui-k8sdt9`, kC2sXz: `ui-1duton`, k9lH4S: `ui-101ixbw`, kphCe6: `ui-exgr1p`, kZeWKH: `ui-ish69e`, $$css: true } }; +var fc2 = { base: { kB7OPa: `ui-9f619`, kzqmXN: `ui-eq5yr9`, k7Eaqz: `ui-gqtt45`, ks0D6T: `ui-193iq5w`, kAzted: `ui-1us19tq`, k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, $$css: true }, horizontal: { kzqmXN: `ui-14atkfc`, kZKoxP: `ui-g7h5cd`, kXwgrk: `ui-1q0g3np`, $$css: true }, both: { kzqmXN: `ui-ezivpi`, k7Eaqz: `ui-gqtt45`, ks0D6T: `ui-1x1rfll`, kZKoxP: `ui-t7dq6l`, kXwgrk: `ui-dt5ytf`, $$css: true }, reserveScrollbarSpace: { kwRFfy: `ui-w77ms1`, $$css: true } }; +var pc2 = { base: { kVAEAm: `ui-10l6tqk`, kY2c9j: `ui-1n327nk`, k87sOh: `ui-16271f3`, kt4wiu: `ui-1cdd6y0`, krVfgx: `ui-1c87l4o`, kLqNvP: `ui-hi6v0a`, kzqmXN: `ui-790ffn`, kfzvcC: `ui-67bb7w`, k1xSpc: `ui-1lliihq ui-y36ywk`, $$css: true }, horizontal: { k87sOh: `ui-80663w`, kt4wiu: `ui-1cdd6y0`, krVfgx: `ui-1gncbth`, kLqNvP: `ui-pl0nw1`, kzqmXN: `ui-14atkfc`, kZKoxP: `ui-a38mao`, $$css: true }, bothVertical: { krVfgx: `ui-1143y87`, $$css: true }, bothHorizontal: { kt4wiu: `ui-13kbk1n`, $$css: true }, visibilityNever: { k1xSpc: `ui-1s85apg`, $$css: true } }; +var mc2 = { base: { kVAEAm: `ui-10l6tqk`, k87sOh: `ui-13vifvy`, kt4wiu: `ui-tijo5x`, krVfgx: `ui-dd4er5`, kLqNvP: `ui-1o0tod`, kAzted: `ui-4jlmx6`, kzqmXN: `ui-790ffn`, kaIpWk: `ui-1i4c3av`, kWkggS: `ui-1m4ooaa ui-1kik0b9 ui-19p5jqy ui-gk890x`, kSiTet: `ui-1hc1fzr`, kfzvcC: `ui-67bb7w`, k3aq6I: `ui-oww4n8`, k1ekBW: `ui-1e8aii2`, kIyJzY: `ui-1vaoic9 ui-ykozbk`, kAMwcw: `ui-1cy6p2x`, $$css: true }, horizontal: { k87sOh: `ui-13vifvy`, kt4wiu: `ui-1woyocn`, krVfgx: `ui-1ey2m1c`, kLqNvP: `ui-1o0tod`, kzqmXN: `ui-14atkfc`, kZKoxP: `ui-a38mao`, kAzted: `ui-65nank`, k7Eaqz: `ui-cbmsab`, $$css: true }, hoverHidden: { kSiTet: `ui-g01cxk ui-4gyw5p ui-gorybd`, $$css: true } }; +function hc2() { + return uc2.base; +} +function gc({ direction: e38 }) { + return [dc2.base, e38 === `horizontal` ? dc2.horizontal : null, e38 === `both` ? dc2.both : null]; +} +function _c(e38, t2 = false) { + return [fc2.base, e38 === `horizontal` ? fc2.horizontal : null, e38 === `both` ? fc2.both : null, t2 ? fc2.reserveScrollbarSpace : null]; +} +function vc({ direction: e38, orientation: t2, visibility: n2 }) { + return [pc2.base, t2 === `horizontal` ? pc2.horizontal : null, e38 === `both` && t2 === `vertical` ? pc2.bothVertical : null, e38 === `both` && t2 === `horizontal` ? pc2.bothHorizontal : null, n2 === `never` ? pc2.visibilityNever : null]; +} +function yc(e38, t2) { + return [mc2.base, e38 === `horizontal` ? mc2.horizontal : null, t2 ? mc2.hoverHidden : null]; +} +function bc(e38, t2) { + t2 ? e38.dataset.scrollbarGutter = `reserved` : delete e38.dataset.scrollbarGutter; +} +var xc = 1e4; +var Sc = 5; +var Cc2 = (0, Y2.forwardRef)(function e35({ children: t2, height: n2, maxHeight: r2, width: i3, className: a3, viewportClassName: o3, viewportTabIndex: s3, viewportId: c3, viewportRole: l5, viewportAriaLabel: u3, rootStyle: d3, viewportStyle: f4, allowScrollChaining: p4 = false, contentStyle: m3, scrollbarStyle: h4, overlay: g5, style: _5, scrollbarVisibility: v5 = tc2, isScrollbarRevealed: y4 = false, direction: b2 = `vertical`, topFadeSize: x2, bottomFadeSize: S2, topFadeStartOpacity: C2 = 0, bottomFadeStartOpacity: w2 = 0, startFadeSize: T2, endFadeSize: E2, autoScrollToBottom: D2 = false, scrollTrigger: O2, autoScrollPauseTimeout: k2 = xc, onScrollStateChange: A2, mapVerticalWheelToHorizontal: j2 = false, scrollPadding: M2 = 4, scrollbarInset: N3, reserveScrollbarSpace: P3 = false, onPointerEnter: F2, onPointerLeave: I2, ...L3 }, R3) { + e35.d = 3647458370; + let z2 = (0, Y2.useRef)(null), B3 = (0, Y2.useRef)(null), ee2 = (0, Y2.useRef)(null), te2 = (0, Y2.useRef)(null), ne3 = (0, Y2.useRef)(null), re3 = (0, Y2.useRef)(null), ie3 = (0, Y2.useRef)(null), ae3 = b2 !== `horizontal`, V3 = b2 !== `vertical`, H3 = P3 && ae3 && v5 !== `never`, oe5 = j2 && !ae3, se5 = x2 !== void 0 || S2 !== void 0, ce6 = T2 !== void 0 || E2 !== void 0, le6 = se5 || ce6, ue6 = (0, Y2.useRef)(false), de6 = (0, Y2.useRef)(0), fe5 = (0, Y2.useRef)(0), U3 = (0, Y2.useRef)(null), pe5 = (0, Y2.useRef)(null); + (0, Y2.useLayoutEffect)(() => { + let e38 = B3.current, t3 = ee2.current; + if (!e38 || !t3) return; + let n3 = [], r3 = { top: false, bottom: false, start: false, end: false }, i4 = { block: se5, inline: ce6 }; + if (ae3) { + let a4 = te2.current, o4 = ne3.current; + a4 && o4 && n3.push(new lc2({ viewport: e38, content: t3, scrollbar: a4, thumb: o4, direction: `vertical`, mapVerticalWheelToHorizontal: oe5, onFadeEdgesChange: se5 ? (t4, n4) => { + r3.top = t4, r3.bottom = n4, ac2(e38, r3, i4); + } : void 0, onScrollableChange: H3 ? (e39) => bc(t3, e39) : void 0 })); + } + if (V3) { + let a4 = re3.current, o4 = ie3.current; + a4 && o4 && n3.push(new lc2({ viewport: e38, content: t3, scrollbar: a4, thumb: o4, direction: `horizontal`, mapVerticalWheelToHorizontal: oe5, onFadeEdgesChange: ce6 ? (t4, n4) => { + r3.start = t4, r3.end = n4, ac2(e38, r3, i4); + } : void 0 })); + } + if (n3.length !== 0) { + for (let e39 of n3) e39.attach(); + return () => { + for (let e39 of n3) e39.detach(); + bc(t3, false), ac2(e38, { top: false, bottom: false, start: false, end: false }, i4); + }; + } + }, [ae3, V3, oe5, se5, ce6, H3]); + let W3 = (0, Y2.useCallback)(() => { + let e38 = B3.current; + return e38 ? { scrollTop: e38.scrollTop, scrollHeight: e38.scrollHeight, clientHeight: e38.clientHeight } : { scrollTop: 0, scrollHeight: 0, clientHeight: 0 }; + }, []), me5 = (0, Y2.useCallback)((e38 = false) => { + let t3 = B3.current; + t3 && t3.scrollTo({ top: t3.scrollHeight, behavior: e38 ? `smooth` : `instant` }); + }, []), he5 = (0, Y2.useCallback)((e38 = false) => { + let t3 = B3.current; + t3 && t3.scrollTo({ top: 0, behavior: e38 ? `smooth` : `instant` }); + }, []), ge5 = (0, Y2.useCallback)(() => { + pe5.current === null && (pe5.current = requestAnimationFrame2(() => { + pe5.current = null, !ue6.current && me5(false); + })); + }, [me5]), _e5 = (0, Y2.useCallback)(() => { + D2 && (ue6.current || ge5()); + }, [D2, ge5]); + (0, Y2.useImperativeHandle)(R3, () => ({ scrollToBottom: me5, scrollToTop: he5, requestAutoScroll: _e5, getScrollPosition: W3, get rootElement() { + return z2.current; + }, get viewportElement() { + return B3.current; + } }), [me5, he5, _e5, W3]); + let ve5 = D2 || A2 !== void 0, ye5 = (0, Y2.useEffectEvent)(() => { + let e38 = B3.current; + if (!e38) return; + let { scrollTop: t3, scrollHeight: n3, clientHeight: r3 } = e38, { isAtTop: i4, isAtBottom: a4 } = nc2({ scrollTop: t3, scrollHeight: n3, clientHeight: r3, threshold: Sc }); + A2?.({ isAtBottom: a4, isAtTop: i4 }), a4 && ue6.current && (ue6.current = false, U3.current &&= (clearTimeout(U3.current), null)); + let o4 = n3 < fe5.current - Sc, s4 = n3 > fe5.current + Sc, c4 = t3 < de6.current - Sc; + c4 && !o4 && !a4 && D2 && !ue6.current && (ue6.current = true, U3.current && clearTimeout(U3.current), U3.current = setTimeout(() => { + ue6.current = false, U3.current = null; + }, k2)), s4 && D2 && !ue6.current && !a4 && !c4 && ge5(), o4 && D2 && !ue6.current && !a4 && ge5(), de6.current = t3, fe5.current = n3; + }), be5 = Qs2(); + (0, Y2.useEffect)(() => { + if (!ve5) return; + let e38 = B3.current, t3 = ee2.current; + if (!e38) return; + let n3 = () => { + be5.request(() => ye5()); + }; + e38.addEventListener(`scroll`, n3, { passive: true }); + let r3 = $s2(() => ye5()); + return r3 !== null && (r3.observe(e38), t3 && r3.observe(t3)), () => { + e38.removeEventListener(`scroll`, n3), r3?.disconnect(), be5.dispose(); + }; + }, [ve5, be5]), (0, Y2.useEffect)(() => { + O2 !== void 0 && D2 && (ue6.current || ge5()); + }, [O2, D2, ge5]), (0, Y2.useEffect)(() => { + if (!ae3) return; + let e38 = B3.current; + if (!e38) return; + let t3 = (t4) => { + let n3 = t4.deltaY; + if (n3 === 0) return; + let r3 = e38.scrollHeight - e38.clientHeight; + if (r3 <= 0) return; + let i4 = e38.scrollTop, a4 = i4 <= 0 && n3 < 0, o4 = i4 >= r3 - 0.5 && n3 > 0; + a4 || o4 || t4.stopPropagation(); + }; + return e38.addEventListener(`wheel`, t3, { passive: true }), () => e38.removeEventListener(`wheel`, t3); + }, [ae3]), (0, Y2.useEffect)(() => { + if (!V3) return; + let e38 = B3.current; + if (!e38) return; + let t3 = (t4) => { + let n4 = ec2({ deltaX: t4.deltaX, deltaY: t4.deltaY, mapVerticalWheelToHorizontal: oe5 }); + if (n4 === null) return; + let r3 = e38.scrollWidth - e38.clientWidth; + if (r3 <= 0) return; + let i4 = e38.scrollLeft; + if (!(n4 < 0 && i4 <= 0) && !(n4 > 0 && i4 >= r3 - 0.5)) { + if (!oe5) { + t4.stopPropagation(); + return; + } + t4.preventDefault(), e38.scrollLeft = i4 + n4; + } + }, n3 = oe5 ? { passive: false, capture: true } : { passive: true, capture: true }; + return e38.addEventListener(`wheel`, t3, n3), () => e38.removeEventListener(`wheel`, t3, n3); + }, [V3, oe5]); + let xe5 = v5 === `hover`, [Se5, Ce5] = (0, Y2.useState)(false); + (0, Y2.useLayoutEffect)(() => { + xe5 && Ce5(z2.current?.matches(`:hover`) ?? false); + }, [xe5]); + let we5 = (0, Y2.useCallback)((e38) => { + Ce5(true), F2?.(e38); + }, [F2]), Te5 = (0, Y2.useCallback)((e38) => { + Ce5(false), I2?.(e38); + }, [I2]), Ee5 = xe5 && !Se5 && !y4; + (0, Y2.useEffect)(() => () => { + U3.current && clearTimeout(U3.current), pe5.current !== null && (cancelAnimationFrame2(pe5.current), pe5.current = null); + }, []); + let De5 = { "--scroll-area-scroll-padding": `${M2}px`, ...N3 === void 0 ? void 0 : { "--scrollbar-inset": `${N3}px` } }, Oe5 = q2({ rootClass: `ui-scroll-area`, stylexStyles: [hc2(), d3], className: K2(le6 && `ui-scroll-area--masked`, a3), style: { height: n2, maxHeight: r2, width: i3, ...De5, ..._5 } }), ke5 = q2({ rootClass: `ui-scroll-area__viewport`, stylexStyles: [gc({ direction: b2 }), f4], className: o3, style: { ...oc2({ block: se5 ? { topPx: x2 ?? 24, bottomPx: S2 ?? 24, topStartOpacity: C2, bottomStartOpacity: w2 } : void 0, inline: ce6 ? { startPx: T2 ?? 24, endPx: E2 ?? 24 } : void 0 }), ...p4 ? { overscrollBehavior: `auto` } : void 0 } }), Ae5 = q2({ rootClass: `ui-scroll-area__content`, stylexStyles: [_c(b2, H3), m3] }), je5 = q2({ rootClass: `ui-scroll-area__scrollbar`, stylexStyles: [vc({ direction: b2, orientation: `vertical`, visibility: v5 }), h4] }), Me5 = h(yc(`vertical`, Ee5)), Ne5 = q2({ rootClass: `ui-scroll-area__scrollbar`, stylexStyles: [vc({ direction: b2, orientation: `horizontal`, visibility: v5 }), h4] }), Pe5 = h(yc(`horizontal`, Ee5)); + return (0, J2.jsxs)(`div`, { ref: z2, className: Oe5.className, style: Oe5.style, "data-scroll-padding": M2, "data-visibility": v5, "data-direction": b2, ...L3, onPointerEnter: xe5 ? we5 : F2, onPointerLeave: xe5 ? Te5 : I2, children: [(0, J2.jsx)(`div`, { ref: B3, className: ke5.className, style: ke5.style, "data-native-scrollbar": `none`, id: c3, role: l5, "aria-label": u3, tabIndex: s3, children: (0, J2.jsx)(`div`, { ref: ee2, className: Ae5.className, style: Ae5.style, children: t2 }) }), g5, ae3 && (0, J2.jsx)(`div`, { ref: te2, className: je5.className, style: je5.style, "data-orientation": `vertical`, "data-scrollable": `false`, role: `presentation`, "aria-hidden": `true`, children: (0, J2.jsx)(`div`, { ref: ne3, className: Me5.className, style: Me5.style, "data-orientation": `vertical` }) }), V3 && (0, J2.jsx)(`div`, { ref: re3, className: Ne5.className, style: Ne5.style, "data-orientation": `horizontal`, "data-scrollable": `false`, role: `presentation`, "aria-hidden": `true`, children: (0, J2.jsx)(`div`, { ref: ie3, className: Pe5.className, style: Pe5.style, "data-orientation": `horizontal` }) })] }); +}); +var wc2 = { root: { kzQI83: `ui-1iyjqo2`, kmuXW: `ui-s83m0k`, kCS8Yb: `ui-dl72j9`, kAzted: `ui-2lwn1j`, k7Eaqz: `ui-euugli`, $$css: true }, rootHidden: { k1xSpc: `ui-1s85apg`, $$css: true }, viewport: { kaPefq: `ui-1uzft2t`, k9lH4S: `ui-pt7jon`, $$css: true } }; +function Tc2({ children: e38, hidden: t2 = false, ref: n2 }) { + return Tc2.d = 2847816734, (0, J2.jsx)(Cc2, { ref: n2, "data-component": `list-popup-scroll`, maxHeight: `none`, reserveScrollbarSpace: true, rootStyle: [Ns2, wc2.root, t2 && wc2.rootHidden], viewportStyle: wc2.viewport, children: e38 }); +} +var Dc2 = { top: { side: `top`, align: `center` }, right: { side: `right`, align: `center` }, bottom: { side: `bottom`, align: `center` }, left: { side: `left`, align: `center` }, "top-start": { side: `top`, align: `start` }, "top-end": { side: `top`, align: `end` }, "right-start": { side: `right`, align: `start` }, "right-end": { side: `right`, align: `end` }, "bottom-start": { side: `bottom`, align: `start` }, "bottom-end": { side: `bottom`, align: `end` }, "left-start": { side: `left`, align: `start` }, "left-end": { side: `left`, align: `end` } }; +function Oc2(e38) { + return Object.hasOwn(Dc2, e38) ? Dc2[e38] : Dc2.top; +} +function kc2(e38) { + return typeof e38 == `number` ? { sideOffset: e38 } : { sideOffset: e38.mainAxis, alignOffset: e38.alignmentAxis }; +} +function Ac2(e38, t2) { + return { side: t2, align: `shift`, fallbackAxisSide: e38 ? `none` : `start` }; +} +function jc2(e38, t2, n2, r2 = `flip`) { + let { side: i3, align: a3 } = (0, Y2.useMemo)(() => Oc2(e38), [e38]), { sideOffset: o3, alignOffset: s3 } = (0, Y2.useMemo)(() => kc2(t2), [t2]); + return { side: i3, align: a3, sideOffset: o3, alignOffset: s3, collisionAvoidance: (0, Y2.useMemo)(() => Ac2(n2, r2), [n2, r2]), positionMethod: `fixed` }; +} +var Mc2 = (0, Y2.createContext)(void 0); +function Nc2() { + return (0, Y2.useContext)(Mc2); +} +var Pc2 = { base: { kVAEAm: `ui-10l6tqk`, krVfgx: `ui-r0fw0u`, kCIrl2: `ui-7zl9wm`, kzqmXN: `ui-jwey39`, kZKoxP: `ui-wbbb81`, kaIpWk: `ui-16rqkct`, kfzvcC: `ui-47corl`, $$css: true }, colorBlue: { kWkggS: `ui-1b558e3`, $$css: true }, colorGreen: { kWkggS: `ui-15xcjd2`, $$css: true } }; +function Fc2(e38) { + return [Pc2.base, e38 === `green` ? Pc2.colorGreen : Pc2.colorBlue]; +} +function Ic2({ color: e38 = `blue`, className: t2 }) { + Ic2.d = 1096593150; + let n2 = q2({ rootClass: `ui-indicator-dot`, stylexStyles: Fc2(e38), className: t2 }); + return (0, J2.jsx)(`span`, { "aria-hidden": true, className: n2.className, "data-color": e38, style: n2.style }); +} +var Lc2 = { root: { kysU6D: `ui-jyslct`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kmuXW: `ui-2lah0s`, kB7OPa: `ui-9f619`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kMzoRj: `ui-c342km`, ksu8eU: `ui-ng3xce`, kMv6JI: `ui-jb2p0i`, kGuDYH: `ui-1qlqyl8`, k63SB2: `ui-1pd3egz`, kLWn49: `ui-15bjb6t`, kkrTdU: `ui-1ypdohk ui-1j1ks5o`, kSiTet: null, kfzvcC: `ui-67bb7w ui-7gqb9v`, kVAEAm: `ui-1fxuinm`, $$css: true } }; +var Rc2 = { sm: { kzqmXN: `ui-16bvwqk`, $$css: true }, md: { kzqmXN: `ui-1eu7oa3`, $$css: true }, lg: { kzqmXN: `ui-jst10v`, $$css: true }, xl: { kzqmXN: `ui-mjrt60`, $$css: true } }; +var zc2 = { root: [Lc2.root, Pa2.root], size: { sm: [La2.sm, Ia2.sm, Rc2.sm], md: [La2.md, Ia2.md, Rc2.md], lg: [La2.lg, Ia2.lg, Rc2.lg], xl: [La2.xl, Ia2.xl, Rc2.xl] }, contentFrame: { sm: { keoZOQ: `ui-vqhhvk`, k71WvV: `ui-1bk7dnq`, k1K539: `ui-1dy9ubm`, keTefX: `ui-1fesk1l`, $$css: true }, md: { keoZOQ: `ui-kv60qn`, k71WvV: `ui-xku7nj`, k1K539: `ui-1hi8m59`, keTefX: `ui-13srazm`, $$css: true }, lg: { keoZOQ: `ui-4xtw7q`, k71WvV: `ui-7quaee`, k1K539: `ui-eci9o5`, keTefX: `ui-1na8g2l`, $$css: true }, xl: { keoZOQ: `ui-1fm9hdn`, k71WvV: `ui-tyhy2u`, k1K539: `ui-foffu7`, keTefX: `ui-1tnioq7`, $$css: true } }, rounded: { rounded: { kaIpWk: `ui-1i4c3av`, $$css: true } }.rounded }; +var Bc2 = { root: { k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kzqmXN: `ui-1oai4fc`, kZKoxP: `ui-higkf7`, kGuDYH: `ui-1tachi3`, kLWn49: `ui-o5v014`, $$css: true } }; +function Vc2(e38, t2) { + if (e38 !== void 0 && Si2(e38)) return h(Bc2.root, Ci2(e38), t2); + let n2 = h(Bc2.root, t2); + return e38 === void 0 ? n2 : { ...n2, style: { ...n2.style, "--icon-size": typeof e38 == `number` ? `${e38}px` : e38 } }; +} +function Uc({ variant: e38, rounded: t2, frame: n2, size: r2, tone: i3, indicatorDot: a3 }) { + return { "data-variant": e38, "data-rounded": t2 || void 0, "data-frame": n2, "data-size": r2, "data-tone": i3, "data-fg-channel": `icon`, "data-indicator-dot": a3 || void 0 }; +} +function Wc2({ enforcedRootStyle: e38, frame: t2, indicatorDot: n2, rootStyle: r2, rounded: i3, size: a3, tone: o3, variant: s3 }) { + let c3 = ua2(s3, o3); + return { dataAttrs: Uc({ frame: t2, indicatorDot: n2, rounded: i3, size: a3, tone: o3, variant: s3 }), rootAttrs: h(zc2.root, ma2.appearance, c3.applyControlTone && da2.foreground, c3.applyControlTone && o3 !== void 0 && fa2[o3], s3 === `ghost` && (o3 === `secondary` || o3 === `tertiary`) && pa2[o3], c3.applyFilledColors && ma2.colors, c3.applyNonFilledBackground && ha2.background, (s3 === `outline` || s3 === `ghost`) && _a2(o3) && va2[o3], s3 === `outline` && ha2.outline, s3 === `outline` && _a2(o3) && ya2[o3], s3 === `media` && ma2.media, _o2.self, a3 !== `xs` && zc2.size[a3], i3 && zc2.rounded, t2 === `content` && a3 !== `xs` && zc2.contentFrame[a3], e38, r2) }; +} +function Gc({ size: e38, iconSize: t2, disabled: n2, variant: r2, tone: i3, frame: a3, enforced: o3 }) { + let s3 = e38 ?? o3?.iconButtonSize ?? `md`, c3 = r2 ?? o3?.iconButtonVariant ?? `ghost`, l5 = s3 === `xs` ? void 0 : ba2[s3]; + return { size: s3, innerIconSize: t2 ?? o3?.iconButtonIconSize ?? l5, disabled: n2 ?? o3?.disabled, variant: c3, frame: a3 ?? o3?.iconButtonFrame ?? `container`, tone: ra2(i3 ?? o3?.iconButtonTone ?? (c3 === `primary` ? `accent` : void 0)) }; +} +var Kc = { glyph: { kVAEAm: `ui-1n2onr6`, k1xSpc: `ui-3nfvp2`, $$css: true }, count: { "--ui-icon-button-badge-height": `ui-1kyyedk`, "--ui-icon-button-badge-gap": `ui-1fyrpc2`, "--ui-icon-button-badge-outset": `ui-b7p1k1`, $$css: true }, dot: { "--ui-icon-button-badge-height": `ui-82jrga`, "--ui-icon-button-badge-gap": `ui-ehowfr`, "--ui-icon-button-badge-outset": `ui-13iyukj`, $$css: true }, chars: (e38) => [{ "--ui-icon-button-badge-chars": String(e38) == null ? String(e38) : `ui-1naywus`, $$css: true }, { "--x---ui-icon-button-badge-chars": String(e38) == null ? void 0 : String(e38) }], notched: { kX1K2I: `ui-1wq3i2t`, kn1fP1: `ui-6b3u3w`, k2A1W4: `ui-1ukwzbd`, kJcbqH: `ui-16fucec`, kQB4zb: `ui-1xf347a`, $$css: true }, badge: { kVAEAm: `ui-10l6tqk`, k87sOh: `ui-1df8gz1`, kCIrl2: `ui-14d9e37`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kB7OPa: `ui-9f619`, kzqmXN: `ui-1cs09ro`, kZKoxP: `ui-1b77v56`, kaIpWk: `ui-1i4c3av`, kMwMTN: `ui-70xvah`, kMv6JI: `ui-1acoasx`, kGuDYH: `ui-vwhms9`, k63SB2: `ui-h4fh7u`, kLWn49: `ui-o5v014`, kb6lSQ: `ui-o2cfqc`, khDVqt: `ui-uxw1ft`, kfzvcC: `ui-47corl`, $$css: true }, colorAccent: { kWkggS: `ui-1nawb4t`, $$css: true }, colorBlue: { kWkggS: `ui-1hnk832`, $$css: true } }; +var qc = Kc.notched; +function Jc(e38) { + switch (e38) { + case `accent`: + return Kc.colorAccent; + case `blue`: + return Kc.colorBlue; + default: + return e38; + } +} +function Yc({ badge: e38, color: t2, children: n2 }) { + Yc.d = 631274569; + let r2 = e38 === true ? void 0 : String(e38); + return (0, J2.jsxs)(`span`, { ...h(Kc.glyph, r2 === void 0 ? Kc.dot : Kc.count, Kc.chars(r2?.length ?? 1)), children: [n2, (0, J2.jsx)(`span`, { ...h(Kc.badge, Jc(t2)), "aria-hidden": `true`, "data-icon-button-badge": r2 === void 0 ? `dot` : `count`, children: r2 })] }); +} +function Xc({ icon: e38, iconVariant: t2 = `outline`, variant: n2, rounded: r2, frame: i3, size: a3, iconSize: o3, tone: s3, className: c3, style: l5, rootStyle: u3, iconStyle: d3, disabled: f4, indicatorDot: p4 = false, indicatorDotColor: m3 = `blue`, badge: h4, badgeColor: g5 = `accent`, "aria-label": _5, "aria-labelledby": v5, onKeyDown: y4, onKeyUp: b2, ...x2 }) { + Xc.d = 3001365109; + let S2 = _i2(), { size: C2, innerIconSize: w2, disabled: T2, variant: E2, tone: D2, frame: O2 } = Gc({ disabled: f4, enforced: S2, frame: i3, iconSize: o3, size: a3, tone: s3, variant: n2 }), k2 = Wc2({ enforcedRootStyle: S2?.iconButtonRootStyle, frame: O2, indicatorDot: p4, rootStyle: u3, rounded: r2, size: C2, tone: D2, variant: E2 }), A2 = h4 !== void 0 && h4 !== false, j2 = A2 ? qc : void 0, M2 = typeof e38 == `string` ? (0, J2.jsx)(Oi, { name: e38, rootStyle: [S2?.iconButtonIconStyle, d3, j2], variant: t2, size: w2, "aria-hidden": `true` }) : (0, J2.jsx)(`span`, { ...Vc2(w2, j2), "aria-hidden": `true`, children: e38 }); + return (0, J2.jsxs)(Wc, { ...x2, ...qi2.self, onKeyDown: Sa2(y4), onKeyUp: Sa2(b2), className: K2(`ui-icon-button`, k2.rootAttrs.className, c3), style: { ...k2.rootAttrs.style, ...l5 }, ...k2.dataAttrs, disabled: T2, "aria-label": _5, "aria-labelledby": v5, children: [A2 ? (0, J2.jsx)(Yc, { badge: h4, color: g5, children: M2 }) : M2, p4 ? (0, J2.jsx)(Ic2, { color: m3 }) : null] }); +} +function Zc() { + return typeof navigator2 < `u` && /Mac|iPod|iPhone|iPad/.test(navigator2.platform); +} +function Qc(e38) { + if (!(Zc() ? e38.metaKey : e38.ctrlKey) || e38.shiftKey || e38.altKey) return false; + switch (e38.key.toLowerCase()) { + case `a`: + return e38.preventDefault(), e38.nativeEvent.stopImmediatePropagation(), e38.currentTarget.select(), true; + case `c`: + case `v`: + case `x`: + case `z`: + return e38.nativeEvent.stopImmediatePropagation(), true; + default: + return false; + } +} +var $c = { base: { kMeerF: `ui-1k57tk5`, k3XXqK: `ui-1t137rt`, kInvED: `ui-1wfwxd8`, kjBf7l: `ui-1uczgqu`, kUk6DE: `ui-98rzlu`, k7Eaqz: `ui-euugli`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kWkggS: `ui-jbqb8w`, kMwMTN: `ui-1wd3ewq`, kMv6JI: `ui-jb2p0i`, kGuDYH: `ui-11wthnw`, kLWn49: `ui-1ja60sm`, kb6lSQ: `ui-12oo3zp`, k8Qsv1: `ui-19ovir5`, $$css: true }, disabled: { kkrTdU: `ui-1h6gzvc`, k8Qsv1: `ui-ompknl`, $$css: true }, mono: { kMv6JI: `ui-mpsg8l`, $$css: true }, monoInput: { kGuDYH: `ui-pr5cyi`, $$css: true } }; +function el({ className: e38, disabled: t2 = false, mono: n2 = false, ref: r2, rootStyle: i3, style: a3, onKeyDown: o3, ...s3 }) { + el.d = 1130410932; + let c3 = q2({ rootClass: `ui-input-group__input`, stylexStyles: [$c.base, t2 ? $c.disabled : null, n2 ? $c.mono : null, n2 ? $c.monoInput : null, i3], className: e38, style: a3 }), l5 = (0, Y2.useCallback)((e39) => { + o3?.(e39), !e39.defaultPrevented && Qc(e39); + }, [o3]); + return (0, J2.jsx)(`input`, { ref: r2, className: c3.className, style: c3.style, disabled: t2, onKeyDown: l5, ...s3 }); +} +var tl = { base: { "--ui-input-group-border-width": `ui-1cx02xk`, "--ui-input-group-padding-block": `ui-1we15r7`, "--ui-input-group-padding-inline": `ui-vnd6s4`, "--ui-input-group-button-edge-gap": `ui-13cine8`, "--input-group-button-inset": `ui-en7asl`, "--ui-input-group-stroke-rest": `ui-ja7v4d`, "--ui-input-group-stroke": `ui-10kn0w6 ui-1t42qcl ui-1oeqi0j`, "--ui-focus-ring-color": `ui-1c8wv37`, k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kB7OPa: `ui-9f619`, kzqmXN: `ui-h8yej3`, kEafiO: `ui-178xt8z`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-n2k5gv`, ke9TFa: `ui-1lun4ml`, k8ry5P: `ui-18b5jzi`, kBCPoo: `ui-rox06k`, kt9PQ7: `ui-so031l`, kfdmCh: `ui-1q0q8m5`, kL6WhQ: `ui-bxr889`, k2ei4v: `ui-pilrb4`, kVhnKS: `ui-1t7ytsu`, kGJrpR: `ui-50gvz2`, kaIpWk: `ui-1043rbw`, kLKAdn: `ui-e8kt42`, kwRFfy: `ui-n29lvp`, kGO01o: `ui-1ftrzfz`, kZCmMZ: `ui-1ecvjd7`, kWkggS: `ui-1gwrjia`, k1ekBW: `ui-1oy24xj`, kIyJzY: `ui-g3p6pi ui-6458p5`, kAMwcw: `ui-py3bvx`, khiITx: `ui-vmahel`, kTUp5R: `ui-lh3980`, $$css: true }, disabled: { kLZC3w: `ui-1aeic0j`, kBCPoo: `ui-5q6521`, kL6WhQ: `ui-17fyfba`, kGJrpR: `ui-4n2izg`, kkrTdU: `ui-1h6gzvc`, kSiTet: `ui-byyjgo`, $$css: true }, sizeMd: { "--ui-input-group-padding-block": `ui-174jhef`, "--ui-input-group-padding-inline": `ui-xlcw59`, kZKoxP: `ui-1e94bgo`, kOIVth: `ui-11twubx`, $$css: true }, sizeLg: { "--ui-input-group-padding-block": `ui-174jhef`, "--ui-input-group-padding-inline": `ui-cby3z1`, kZKoxP: `ui-170hpbr`, kOIVth: `ui-pkkfsy`, $$css: true }, sizeXl: { "--ui-input-group-padding-block": `ui-2cn54k`, "--ui-input-group-padding-inline": `ui-cby3z1`, kZKoxP: `ui-t8t6p`, kOIVth: `ui-ehausa`, kaIpWk: `ui-1m7fhj7`, $$css: true }, layoutTextarea: { kGNEyG: `ui-1cy8zhl`, kZKoxP: `ui-t7dq6l`, kAzted: `ui-16ry4p3`, $$css: true }, layoutTextareaMd: { kAzted: `ui-t6xkjb`, $$css: true }, layoutTextareaLg: { kAzted: `ui-16ry4p3`, $$css: true }, layoutTextareaXl: { "--ui-input-group-padding-block": `ui-17wxzvn`, kAzted: `ui-phwom3`, $$css: true }, frameContent: { kzqmXN: `ui-q8za26`, kqGvvJ: `ui-1k4kybs`, kUOVxO: `ui-d1nd0v`, $$css: true }, variantDefault: { "--ui-input-group-stroke-rest": `ui-l27skc`, $$css: true }, variantElevated: { kWkggS: `ui-f1vpex`, $$css: true }, variantGhost: { kWkggS: `ui-jbqb8w ui-qjnua1 ui-aig341`, kLZC3w: `ui-1v8p93f`, kBCPoo: `ui-1o3jo1z`, kL6WhQ: `ui-16stqrj`, kGJrpR: `ui-v5lvn5`, $$css: true }, variantUnfilled: { "--ui-input-group-border-width": `ui-qkl0tc`, "--ui-input-group-padding-block": `ui-1we15r7`, "--ui-input-group-padding-inline": `ui-vnd6s4`, "--ui-input-group-button-edge-gap": `ui-4owefe`, kWkggS: `ui-jbqb8w`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, kLZC3w: `ui-1b4hy2t`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kBCPoo: `ui-1273586`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, kL6WhQ: `ui-1tnzt7h`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kGJrpR: `ui-1mi4oqr`, kOIVth: `ui-137clkk`, kGVxlE: `ui-1gnnqk1 ui-15ysqaf`, $$css: true }, variantUnfilledSize: { kZKoxP: `ui-t7dq6l`, $$css: true }, shapePill: { kaIpWk: `ui-1i4c3av`, $$css: true } }; +var nl = { field: { kMeerF: `ui-1k57tk5`, k3XXqK: `ui-1t137rt`, kInvED: `ui-1wfwxd8`, kjBf7l: `ui-1uczgqu`, kUk6DE: `ui-98rzlu`, k7Eaqz: `ui-euugli`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kWkggS: `ui-jbqb8w`, kMwMTN: `ui-1wd3ewq`, kMv6JI: `ui-jb2p0i`, kGuDYH: `ui-11wthnw`, kLWn49: `ui-1ja60sm`, kb6lSQ: `ui-12oo3zp`, kAzted: `ui-10fesj9`, kHenm0: `ui-tt52l0`, kORKVm: `ui-10wlt62`, k8Qsv1: `ui-19ovir5`, $$css: true }, disabled: { kkrTdU: `ui-1h6gzvc`, k8Qsv1: `ui-ompknl`, $$css: true }, mono: { kMv6JI: `ui-mpsg8l`, $$css: true }, autoSizeContent: { kOwNse: `ui-i3vqlg`, kAzted: `ui-10fesj9 ui-1mcog50`, kORKVm: `ui-10wlt62 ui-n0h0yx`, $$css: true }, autoSizeContentMaxRows: { kskxy: `ui-17r4vdi`, $$css: true }, autoSizeRows: (e38, t2) => [{ "--ui-input-group-textarea-min-rows": String(e38) == null ? String(e38) : `ui-so4lmt`, "--ui-input-group-textarea-max-rows": String(t2) == null ? String(t2) : `ui-1554sew`, $$css: true }, { "--x---ui-input-group-textarea-min-rows": String(e38) == null ? void 0 : String(e38), "--x---ui-input-group-textarea-max-rows": String(t2) == null ? void 0 : String(t2) }], collapseBlur: { kskxy: `ui-1kxtfma ui-5u5ifr`, kORKVm: `ui-10wlt62`, $$css: true } }; +var rl = { base: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kmuXW: `ui-2lah0s`, kMwMTN: `ui-1mh7f6w`, keTefX: `ui-1lziwak ui-dve3mh`, k71WvV: `ui-14z9mp ui-rybaqh`, $$css: true }, textareaLayout: { kAzted: `ui-1tn5z8q`, $$css: true } }; +var il = { base: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kmuXW: `ui-2lah0s`, kMwMTN: `ui-19aaqeu`, kGuDYH: `ui-11wthnw`, kLWn49: `ui-1ja60sm`, kb6lSQ: `ui-12oo3zp`, $$css: true }, mono: { kMv6JI: `ui-mpsg8l`, $$css: true } }; +var al = { md: tl.sizeMd, lg: tl.sizeLg, xl: tl.sizeXl }; +var ol = { md: tl.layoutTextareaMd, lg: tl.layoutTextareaLg, xl: tl.layoutTextareaXl }; +var sl = { container: null, content: tl.frameContent }; +var cl = { default: tl.variantDefault, elevated: tl.variantElevated, ghost: tl.variantGhost, unfilled: tl.variantUnfilled }; +var ll = { rounded: null, pill: tl.shapePill }; +var ul = (0, Y2.createContext)(null); +function dl(e38) { + let t2 = (0, Y2.useContext)(ul); + if (!t2) throw Error(`${e38} must be used within InputGroup.Root`); + return t2; +} +function fl() { + return dl(`InputGroup.useContext`); +} +var pl = { md: `sm`, lg: `base`, xl: `lg` }; +var ml = { md: `sm`, lg: `md`, xl: `lg` }; +function hl(e38) { + return (e38.localName === `input` || e38.localName === `textarea`) && e38.matches(`:focus-visible`); +} +function gl() { + return typeof CSS2 < `u` && typeof CSS2.supports == `function` && CSS2.supports(`field-sizing`, `content`); +} +function _l({ variant: e38 = `default`, frame: t2 = `container`, size: n2 = `lg`, shape: r2 = `rounded`, layout: i3 = `default`, mono: a3 = false, disabled: o3 = false, rootStyle: s3, className: c3, children: l5 }) { + _l.d = 106102531; + let u3 = Nc2(), d3 = o3 || u3?.disabled === true, [f4, p4] = (0, Y2.useState)(false), m3 = (0, Y2.useCallback)((e39) => { + p4(hl(e39.target)); + }, []), h4 = (0, Y2.useCallback)(() => { + p4(false); + }, []), g5 = q2({ rootClass: `ui-input-group`, stylexStyles: [tl.base, al[n2], i3 === `textarea` ? tl.layoutTextarea : null, i3 === `textarea` ? ol[n2] : null, sl[t2], e38 === `unfilled` ? null : Ki2.focusedField, cl[e38], e38 === `unfilled` ? tl.variantUnfilledSize : null, ll[r2], d3 ? tl.disabled : null, s3], className: c3 }); + return (0, J2.jsx)(ul.Provider, { value: { disabled: d3, layout: i3, mono: a3 }, children: (0, J2.jsx)(gi2, { iconSize: pl[n2], iconButtonSize: ml[n2], buttonSize: ml[n2], disabled: d3 || void 0, children: (0, J2.jsx)(`div`, { className: g5.className, style: g5.style, "data-variant": e38, "data-frame": t2, "data-size": n2, "data-shape": r2 === `rounded` ? void 0 : r2, "data-layout": i3 === `textarea` ? `textarea` : void 0, "data-mono": a3 || void 0, "data-disabled": d3 || void 0, "data-ui-field-focus-visible": f4 || void 0, onFocus: m3, onBlur: h4, children: l5 }) }) }); +} +function vl({ className: e38, disabled: t2, ref: n2, rootStyle: r2, style: i3, ...a3 }) { + vl.d = 1013457737; + let o3 = dl(`InputGroup.Input`), s3 = o3.disabled || t2 === true; + return (0, J2.jsx)(Tg, { ...a3, className: e38, disabled: s3, ref: n2, render: (0, J2.jsx)(el, { mono: o3.mono, rootStyle: r2 }), style: i3 }); +} +function yl({ className: e38, disabled: t2, ref: n2, rootStyle: r2, style: i3, onKeyDown: a3, onInput: o3, onFocus: s3, onBlur: c3, minRows: l5 = 1, maxRows: u3, autoResize: d3 = true, collapseToSingleLineWhenBlurred: f4 = false, rows: p4, value: m3, placeholder: h4, focusedPlaceholder: g5, ..._5 }) { + yl.d = 500335838; + let v5 = dl(`InputGroup.Textarea`), y4 = v5.disabled || t2 === true, b2 = l5 < 1 ? 1 : l5, x2 = u3 === void 0 ? void 0 : u3 < b2 ? b2 : u3, S2 = d3 && !f4, C2 = Math.min(Math.max(p4 ?? b2, b2), x2 ?? 1 / 0), w2 = q2({ rootClass: `ui-input-group__textarea`, stylexStyles: [nl.field, y4 ? nl.disabled : null, v5.mono ? nl.mono : null, f4 ? nl.collapseBlur : null, S2 ? nl.autoSizeContent : null, S2 && x2 !== void 0 ? nl.autoSizeContentMaxRows : null, S2 ? nl.autoSizeRows(C2, x2 ?? C2) : null, r2], className: e38, style: i3 }), T2 = (0, Y2.useRef)(null), E2 = af([T2, n2]), [D2, O2] = (0, Y2.useState)(false), k2 = (0, Y2.useCallback)(() => { + if (!d3) return; + let e39 = T2.current; + if (!e39 || S2 && e39.style.height === `` && gl()) return; + if (x2 === b2 && (p4 === void 0 || p4 === b2)) { + e39.style.height = ``, e39.style.overflowY = `auto`; + return; + } + e39.style.height = `auto`; + let t3 = window2.getComputedStyle(e39), n3 = Number.parseFloat(t3.lineHeight), r3 = Number.parseFloat(t3.paddingTop) || 0, i4 = Number.parseFloat(t3.paddingBottom) || 0, a4 = Number.parseFloat(t3.borderTopWidth) || 0, o4 = Number.parseFloat(t3.borderBottomWidth) || 0, s4 = r3 + i4 + a4 + o4, c4 = Number.isFinite(n3) && n3 > 0 ? s4 + n3 * b2 : 0, l6 = x2 !== void 0 && Number.isFinite(n3) && n3 > 0 ? s4 + n3 * x2 : void 0, u4 = Math.max(e39.scrollHeight, c4), f5 = l6 === void 0 ? u4 : Math.min(u4, l6); + e39.style.height = `${f5}px`, e39.style.overflowY = l6 !== void 0 && e39.scrollHeight > l6 ? `auto` : `hidden`; + }, [d3, x2, b2, p4, S2]); + (0, Y2.useLayoutEffect)(() => { + k2(); + }, [m3, k2]); + let A2 = (0, Y2.useCallback)((e39) => { + a3?.(e39), !e39.defaultPrevented && Qc(e39); + }, [a3]), M2 = (0, Y2.useCallback)((e39) => { + o3?.(e39), e39.defaultPrevented || k2(); + }, [o3, k2]), N3 = (0, Y2.useCallback)((e39) => { + O2(true), s3?.(e39); + }, [s3]), P3 = (0, Y2.useCallback)((e39) => { + O2(false), c3?.(e39); + }, [c3]), F2 = p4 ?? b2, I2 = D2 && g5 !== void 0 ? g5 : h4; + return (0, J2.jsx)(`textarea`, { ref: E2, className: w2.className, style: w2.style, disabled: y4, onKeyDown: A2, rows: F2, value: m3, placeholder: I2, ..._5, "data-textarea-collapse-blur": f4 ? `` : void 0, onInput: M2, onFocus: N3, onBlur: P3 }); +} +function bl({ addonStyle: e38, className: t2, ref: n2, ...r2 }) { + bl.d = 1882381423; + let i3 = dl(`InputGroup.Icon`), a3 = q2({ rootClass: `ui-input-group__addon`, stylexStyles: [rl.base, i3.layout === `textarea` ? rl.textareaLayout : null, e38], className: t2 }); + return (0, J2.jsx)(`span`, { className: a3.className, style: a3.style, children: (0, J2.jsx)(Oi, { ref: n2, ...r2 }) }); +} +function xl({ addonStyle: e38, className: t2, disabled: n2, ref: r2, ...i3 }) { + xl.d = 3978508683; + let a3 = dl(`InputGroup.IconButton`), o3 = a3.disabled ? true : n2, s3 = q2({ rootClass: `ui-input-group__addon`, stylexStyles: [rl.base, a3.layout === `textarea` ? rl.textareaLayout : null, e38], className: t2 }); + return (0, J2.jsx)(`span`, { className: s3.className, style: s3.style, children: (0, J2.jsx)(Xc, { ref: r2, disabled: o3, ...i3 }) }); +} +function Sl({ addonStyle: e38, className: t2, disabled: n2, ref: r2, ...i3 }) { + Sl.d = 1981277399; + let a3 = dl(`InputGroup.Button`), o3 = a3.disabled ? true : n2, s3 = q2({ rootClass: `ui-input-group__addon`, stylexStyles: [rl.base, a3.layout === `textarea` ? rl.textareaLayout : null, e38], className: t2 }); + return (0, J2.jsx)(`span`, { className: s3.className, style: s3.style, children: (0, J2.jsx)(Wa2, { ref: r2, disabled: o3, ...i3 }) }); +} +function Cl({ className: e38, children: t2 }) { + Cl.d = 2742351246; + let n2 = dl(`InputGroup.Span`), r2 = q2({ rootClass: `ui-input-group__span`, stylexStyles: [il.base, n2.mono ? il.mono : null], className: e38 }); + return (0, J2.jsx)(`span`, { className: r2.className, style: r2.style, children: t2 }); +} +var wl = Object.assign(_l, { Root: _l, Input: vl, Textarea: yl, Icon: bl, IconButton: xl, Button: Sl, Span: Cl, useContext: fl }); +function Nl(e38) { + return typeof e38 == `function`; +} +function Pl(e38, t2, n2, r2) { + let [i3, a3] = (0, Y2.useState)(t2), o3 = (0, Y2.useRef)(n2), s3 = (0, Y2.useRef)(i3), c3 = e38 !== void 0, l5 = (0, Y2.useRef)(c3); + return (0, Y2.useLayoutEffect)(() => { + o3.current = n2; + }, [n2]), (0, Y2.useEffect)(() => { + s3.current !== i3 && o3.current?.(i3), s3.current = i3; + }, [i3]), (0, Y2.useEffect)(() => { + l5.current, l5.current = c3; + }, [r2, c3]), [c3 ? e38 : i3, (0, Y2.useCallback)((t3) => { + if (!c3) { + a3(t3); + return; + } + let n3 = Nl(t3) ? t3(e38) : t3; + n3 !== e38 && o3.current?.(n3); + }, [e38, c3])]; +} +function Fl(e38) { + return typeof e38 == `object` && !!e38; +} +var Il = Object.freeze({}); +function Ll(e38) { + let { props: t2 } = e38; + return Fl(t2) ? t2 : Il; +} +function Rl(e38, t2) { + return Ll(e38)[t2]; +} +function zl(e38) { + return typeof e38 == `function` || typeof e38 == `object` && !!e38 && `current` in e38; +} +function Bl(e38) { + let t2 = Rl(e38, `ref`); + return zl(t2) ? t2 : void 0; +} +var Vl = `never`; +var Hl = { base: { kVAEAm: `ui-1n2onr6`, kfSwDN: `ui-1hx0egp`, kfzvcC: `ui-67bb7w`, k3XXqK: `ui-1t137rt`, $$css: true }, width: (e38) => [{ kzqmXN: e38 == null ? e38 : `ui-5lhr3w`, $$css: true }, { "--x-width": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(e38) }], maxWidth: (e38) => [{ ks0D6T: e38 == null ? e38 : `ui-f68679`, $$css: true }, { "--x-maxWidth": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(e38) }] }; +var Ul = { base: { kB7OPa: `ui-9f619`, $$css: true } }; +var Wl = `a[href], button, input, select, textarea, [contenteditable="true"], [tabindex]`; +function Gl2(e38) { + return [...e38.querySelectorAll(Wl)].filter((e39) => e39.tabIndex >= 0 && !e39.hasAttribute(`disabled`) && e39.closest(`[inert]`) === null); +} +var Kl = `[role="menu"], [role="menubar"], [role="listbox"], [role="grid"], [role="tree"], [role="treegrid"], [role="toolbar"], [role="tablist"], [role="radiogroup"]`; +function ql2(e38) { + return typeof e38 == `object` && !!e38 && `nodeType` in e38 && typeof e38.nodeType == `number`; +} +function Jl2(e38, t2) { + if (t2 === null || !(`relatedTarget` in e38)) return false; + let { relatedTarget: n2 } = e38; + return ql2(n2) && t2.contains(n2); +} +function Yl2({ ariaLabel: e38, labelledBy: t2, close: n2, onKeyDown: r2, popupRef: i3, content: a3, contentStyle: o3, isOpen: s3, maxHeight: c3, maxWidth: l5, offset: u3, placement: d3, sameAxisOnly: f4, scrollbarVisibility: p4, surfaceClassName: m3, surfaceStyle: h4, width: g5 }) { + Yl2.d = 1284643092; + let { portalLayerStyles: _5 } = Gi2(`tooltip`, true), { side: v5, align: y4, sideOffset: b2, alignOffset: x2, collisionAvoidance: S2, positionMethod: C2 } = jc2(d3 ?? `top`, u3, f4), w2 = Io2(Vo2), T2 = h(Bo2, Hl.base, No2, Hl.width(g5), l5 !== void 0 && Hl.maxWidth(l5), h4), E2 = h(qo2, Ul.base, o3); + return (0, J2.jsx)(Cv, { align: y4, alignOffset: x2, className: w2.className, collisionAvoidance: S2, collisionPadding: 8, positionMethod: C2, side: v5, sideOffset: b2, style: { ...w2.style, ..._5 }, children: (0, J2.jsx)(wv, { "aria-label": e38, "aria-labelledby": t2, className: K2(`ui-preview-card`, m3, T2.className), "data-block-global-shortcuts": s3 ? `Escape` : void 0, onKeyDown: r2, ref: i3, role: `dialog`, style: T2.style, children: (0, J2.jsx)(Cc2, { maxHeight: c3, scrollbarVisibility: p4, children: (0, J2.jsx)(`div`, { className: K2(`ui-preview-card__content`, E2.className), style: E2.style, children: typeof a3 == `function` ? a3(n2) : a3 }) }) }) }); +} +function Xl2({ children: e38, content: t2, placement: n2 = `top`, sameAxisOnly: r2 = false, offset: i3 = 8, openDelay: a3 = 250, closeDelay: o3 = 100, disabled: s3 = false, maxHeight: c3 = 300, maxWidth: l5, scrollbarVisibility: u3 = Vl, width: d3 = 280, className: f4, surfaceStyle: p4, contentStyle: m3, "aria-label": h4, ref: g5, defaultOpen: _5 = false, open: v5, onOpenChange: b2, onOpenChangeComplete: x2, ...S2 }) { + Xl2.d = 430826307; + let C2 = (0, Y2.useRef)(null), w2 = (0, Y2.useRef)(null), T2 = (0, Y2.useRef)(false), [E2, D2] = Pl(v5, _5, void 0, `PreviewCard`), O2 = (0, Y2.useId)(), k2 = Y2.Children.only(e38), A2 = (0, Y2.isValidElement)(k2), j2 = A2 ? Rl(k2, `id`) : void 0, M2 = typeof j2 == `string` ? j2 : O2; + (0, Y2.useLayoutEffect)(() => { + s3 && (C2.current?.close(), v5 === void 0 && C2.current?.unmount()); + }, [s3, v5]); + let N3 = (0, Y2.useCallback)((e39) => { + if (typeof g5 == `function`) return g5(e39); + g5 != null && (g5.current = e39); + }, [g5]), P3 = Ni2(), F2 = (0, Y2.useCallback)((e39) => { + e39 !== null && (w2.current = e39); + }, []), I2 = (0, Y2.useCallback)(() => { + w2.current?.ownerDocument.getElementById(M2)?.focus({ preventScroll: true }); + }, [M2]), L3 = (0, Y2.useCallback)((e39, t3) => { + if (s3) { + e39 && t3.cancel(); + return; + } + if (t3.reason === `outside-press` || t3.reason === `trigger-press`) { + t3.cancel(); + return; + } + if (e39 && t3.reason === `trigger-focus` && Jl2(t3.event, w2.current)) { + t3.cancel(); + return; + } + if (b2?.(e39, t3), !t3.isCanceled) { + if (e39) T2.current = t3.reason === `trigger-focus` && t3.trigger?.closest(Kl) == null; + else { + T2.current = false; + let e40 = w2.current; + e40?.contains(e40.ownerDocument.activeElement) === true && I2(); + } + D2(e39); + } + }, [s3, I2, b2, D2]), R3 = (0, Y2.useCallback)((e39) => { + let t3 = w2.current; + e39 && T2.current && t3 !== null && t3.ownerDocument.activeElement === t3.ownerDocument.getElementById(M2) && Gl2(t3).length > 0 && t3.focus({ preventScroll: true }), x2?.(e39); + }, [x2, M2]), z2 = (0, Y2.useCallback)(() => C2.current?.close(), []), B3 = (0, Y2.useCallback)((e39) => { + if (e39.key !== `Tab` || e39.defaultPrevented) return; + let t3 = e39.currentTarget, n3 = t3.ownerDocument.activeElement, r3 = Gl2(t3); + (e39.shiftKey ? n3 === t3 || n3 === r3[0] : r3.length === 0 || n3 === r3[r3.length - 1]) && (e39.shiftKey && e39.preventDefault(), I2(), z2()); + }, [z2, I2]); + return A2 ? (0, J2.jsxs)(hv, { actionsRef: C2, defaultOpen: _5, onOpenChange: L3, onOpenChangeComplete: R3, open: v5, children: [(0, J2.jsx)(bv, { ...S2, closeDelay: o3, delay: a3, id: M2, ref: N3, render: k2 }), s3 ? null : (0, J2.jsx)(yv, { container: P3 ?? void 0, children: (0, J2.jsx)(Yl2, { ariaLabel: h4, labelledBy: h4 === void 0 ? M2 : void 0, close: z2, onKeyDown: B3, popupRef: F2, content: t2, contentStyle: m3, isOpen: E2, maxHeight: c3, maxWidth: l5, offset: i3, placement: n2, sameAxisOnly: r2, scrollbarVisibility: u3, surfaceClassName: f4, surfaceStyle: p4, width: d3 }) })] }) : (0, J2.jsx)(J2.Fragment, { children: e38 }); +} +function Zl2(e38) { + let t2 = (0, Y2.useRef)(e38); + return (0, Y2.useLayoutEffect)(() => { + t2.current = e38; + }, [e38]), t2; +} +var Ql2 = 1; +function $l2(e38) { + return e38 !== null && e38.nodeType === Ql2; +} +function eu2(e38, t2) { + let n2 = Zl2(e38), r2 = Zl2(t2); + return (0, Y2.useCallback)((e39) => { + if (e39 == null) return; + let { ownerDocument: t3 } = e39, i3 = (e40) => { + let i4 = e40.target; + if (!$l2(i4)) return; + let a3 = r2.current, o3 = typeof a3 == `function` ? a3() : a3 == null ? null : t3.getElementById(a3); + o3 != null && i4.contains(o3) && n2.current.close(); + }; + return t3.addEventListener(`scroll`, i3, { capture: true, passive: true }), () => { + t3.removeEventListener(`scroll`, i3, true); + }; + }, [n2, r2]); +} +var tu2 = (0, Y2.createContext)(false); +function nu2({ children: e38, dismiss: t2 }) { + nu2.d = 1104637168; + let n2 = (0, Y2.use)(tu2); + return (0, J2.jsx)(tu2.Provider, { value: n2 || t2, children: e38 }); +} +var ru2 = `data-preview-card-layer-trigger-pressed`; +var ou2 = /* @__PURE__ */ new WeakSet(); +var su = /* @__PURE__ */ new WeakSet(); +function cu(e38) { + return e38 instanceof FocusEvent && e38.relatedTarget === null && e38.target instanceof Element2 && su.has(e38.target); +} +var lu2 = (0, Y2.createContext)(null); +var uu2 = (0, Y2.createContext)(null); +var du2 = (0, Y2.createContext)(null); +function hu({ children: e38 }) { + hu.d = 3287981235; + let t2 = Af(); + return jp({ nodeId: t2, open: true }), (0, J2.jsx)(jf, { id: t2, children: e38 }); +} +function gu2({ children: e38, placement: t2 = `top`, offset: n2 = 8, sameAxisOnly: r2 = false, openDelay: i3 = 250, closeDelay: a3 = 100, controlledTargetId: o3, dismissOnScroll: s3 = true, triggerEscapeBubbles: c3 = false }) { + gu2.d = 3706367722; + let l5 = (0, Y2.useMemo)(() => Ev(), []), u3 = (0, Y2.useRef)(null), d3 = (0, Y2.useRef)(null), f4 = (0, Y2.useRef)(null), p4 = (0, Y2.useRef)(false), m3 = (0, Y2.useRef)(/* @__PURE__ */ new Map()), h4 = (0, Y2.useRef)(o3), [g5, _5] = (0, Y2.useState)(false), v5 = (0, Y2.useRef)(null), b2 = (0, Y2.useRef)(null), x2 = (0, Y2.use)(tu2), S2 = jc2(t2, n2, r2); + (0, Y2.useLayoutEffect)(() => { + g5 || v5.current?.unmount(); + }, [g5]); + let C2 = (0, Y2.useCallback)((e39) => { + u3.current === e39 && (u3.current = null, l5.close()); + }, [l5]), T2 = (0, Y2.useCallback)(() => { + let e39 = h4.current; + if (e39 === void 0) return; + let t3 = e39 === null ? void 0 : m3.current.get(e39); + if (e39 === null || t3 === void 0 || t3.suppressed) { + u3.current = null, l5.close(); + return; + } + u3.current = t3.triggerId, l5.open(t3.triggerId); + }, [l5]), E2 = (0, Y2.useCallback)(() => { + let e39 = p4.current; + p4.current = false; + let t3 = d3.current; + if (t3 === null) return; + let n3 = f4.current; + n3 !== null && n3.id === t3 && n3.isConnected && !n3.hasAttribute(`data-preview-card-layer-trigger-suppressed`) && (e39 || n3 === n3.ownerDocument.activeElement || n3.matches(`:hover`)) && (u3.current = t3, l5.open(t3)); + }, [l5]), D2 = (0, Y2.useCallback)((e39, t3) => (m3.current.set(e39, t3), T2(), () => { + m3.current.get(e39) === t3 && (m3.current.delete(e39), T2()); + }), [T2]); + (0, Y2.useLayoutEffect)(() => { + let e39 = h4.current; + if (e39 === void 0 && o3 !== void 0 && (d3.current = u3.current), h4.current = o3, o3 === void 0) { + e39 !== void 0 && E2(); + return; + } + e39 !== o3 && (p4.current = false), T2(); + }, [o3, T2, E2]); + let O2 = (0, Y2.useCallback)((e39, t3) => { + if (e39 && t3.reason === `trigger-focus` && (ou2.has(t3.event) || cu(t3.event))) { + t3.cancel(); + let e40 = u3.current, n3 = e40 === null ? null : t3.trigger?.ownerDocument.getElementById(e40) ?? null; + h4.current === void 0 && n3 !== null && n3 !== t3.trigger && !n3.matches(`:hover`) && b2.current?.matches(`:hover`) !== true && (u3.current = null, d3.current = null, l5.close()); + return; + } + if (h4.current !== void 0 && t3.reason !== `imperative-action`) { + e39 && t3.trigger !== void 0 && !t3.trigger.hasAttribute(`data-preview-card-layer-trigger-suppressed`) ? (d3.current = t3.trigger.id, f4.current = t3.trigger, p4.current = true) : !e39 && t3.trigger?.id === d3.current && (d3.current = null, f4.current = null, p4.current = false), t3.cancel(), T2(); + return; + } + if (e39 && t3.trigger?.hasAttribute(`data-preview-card-layer-trigger-suppressed`)) { + if (t3.cancel(), h4.current !== void 0) { + T2(); + return; + } + u3.current = null, d3.current = null, l5.close(); + return; + } + if (!e39 && c3 && t3.reason === `escape-key` && t3.event.target instanceof Element2 && t3.event.target.id === u3.current && !t3.event.target.matches(`:hover`) && b2.current?.matches(`:hover`) !== true && t3.allowPropagation(), !e39 && t3.reason === `trigger-focus` && t3.event instanceof FocusEvent && t3.event.relatedTarget === null && t3.event.target instanceof Element2 && t3.event.target.matches(`:hover`)) { + t3.cancel(); + return; + } + if (!e39 && t3.reason === `trigger-focus` && t3.event instanceof FocusEvent && t3.event.target instanceof Element2 && t3.event.target.closest(`[${ru2}]`) !== null) { + t3.cancel(); + return; + } + !e39 && t3.reason !== `imperative-action` && t3.trigger?.id === d3.current && (d3.current = null, f4.current = null, p4.current = false), u3.current = e39 ? t3.trigger?.id ?? u3.current : null, h4.current === void 0 && (d3.current = u3.current), _5(e39), h4.current === void 0 && t3.trigger !== void 0 && (f4.current = e39 ? t3.trigger : null); + }, [l5, T2, c3]), k2 = (0, Y2.useMemo)(() => ({ handle: l5, instantDismiss: x2, openDelay: i3, closeDelay: a3, dismissOnScroll: s3, positioner: S2, popupRef: b2, closeIfActive: C2, registerTarget: D2 }), [a3, C2, s3, l5, x2, i3, S2, D2]); + return (0, J2.jsxs)(lu2.Provider, { value: k2, children: [e38, (0, J2.jsx)(hv, { actionsRef: v5, handle: l5, onOpenChange: O2, children: ({ payload: e39 }) => !x2 && g5 && e39 !== void 0 ? (0, J2.jsx)(uu2.Provider, { value: e39.triggerId, children: (0, J2.jsx)(du2.Provider, { value: e39.contentKey, children: (0, J2.jsx)(hu, { children: e39.content }) }) }) : null })] }); +} +var yu2 = { itemPreview: { kzqmXN: `ui-1oysuqx`, kskxy: `ui-uyqlj2`, kORKVm: `ui-1odjw0f`, kfzvcC: `ui-67bb7w`, k5wCbM: `ui-1597r2g`, k6w4Gs: `ui-xkn5u1`, $$css: true }, itemPreviewMedium: { kzqmXN: `ui-ezivpi`, ks0D6T: `ui-w39y5m`, $$css: true }, itemPreviewWide: { kzqmXN: `ui-ezivpi`, ks0D6T: `ui-19q3ofy`, $$css: true } }; +function bu2(e38) { + switch (e38) { + case `default`: + return yu2.itemPreview; + case `medium`: + return [yu2.itemPreview, yu2.itemPreviewMedium]; + case `wide`: + return [yu2.itemPreview, yu2.itemPreviewWide]; + default: + return e38; + } +} +var qu2 = { root: { kVAEAm: `ui-1n2onr6`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kB7OPa: `ui-9f619`, kmuXW: `ui-2lah0s`, kaIpWk: `ui-1i4c3av`, kWkggS: `ui-59yu97 ui-fewc5l ui-dc3jbj`, k1ekBW: `ui-15406qy`, kIyJzY: `ui-7pq1vu`, kAMwcw: `ui-py3bvx`, $$css: true }, sm: { kzqmXN: `ui-23j0i4`, kZKoxP: `ui-1vatr1o`, "--ui-switch-thumb-travel": `ui-sc32xf`, $$css: true }, regular: { kzqmXN: `ui-1849jeq`, kZKoxP: `ui-mix8c7`, "--ui-switch-thumb-travel": `ui-9pb0k7`, kWkggS: `ui-3dhcaw ui-fewc5l ui-dc3jbj`, kGVxlE: `ui-1gnnqk1 ui-10yfhlr`, $$css: true }, md: { kzqmXN: `ui-1td3qas`, kZKoxP: `ui-1a6rlst`, "--ui-switch-thumb-travel": `ui-9pb0k7`, $$css: true }, lg: { kzqmXN: `ui-1guw455`, kZKoxP: `ui-1e94bgo`, "--ui-switch-thumb-travel": `ui-1c3f5sz`, $$css: true } }; +var Ju2 = { primary: { "--ui-switch-active-bg": `ui-i0s8m6`, $$css: true }, green: { "--ui-switch-active-bg": `ui-1g3p0vo`, $$css: true }, neutral: { "--ui-switch-active-bg": `ui-742exl`, $$css: true }, monochrome: { "--ui-switch-active-bg": `ui-1iuey4n`, "--ui-switch-thumb-bg": `ui-1bbrhsv`, $$css: true } }; +var Yu2 = { root: { k1xSpc: `ui-1lliihq`, kzqmXN: `ui-h8yej3`, kZKoxP: `ui-5yr21d`, kaIpWk: `ui-1i4c3av`, kWkggS: `ui-hwtojv ui-10mbuw1`, kGVxlE: `ui-10z6xd1 ui-19ule2h`, k1ekBW: `ui-11xpdln`, kIyJzY: `ui-622pbu ui-99dd5c ui-6458p5`, kAMwcw: `ui-114a5dy`, $$css: true } }; +function Xu2({ interactive: e38, size: t2, variant: n2 }) { + Xu2.d = 2843984227; + let r2 = (0, J2.jsx)(`span`, { ...h(Yu2.root, _o2.part) }), i3 = e38 ? (0, J2.jsx)(Rv, { className: `ui-10l6tqk ui-np7j22 ui-it89om ui-121ilyj ui-1plog1 ui-bryuvx ui-kkvxwt ui-11xpdln ui-1bqoo3p ui-6458p5 ui-1naimka`, children: r2 }) : (0, J2.jsx)(`span`, { className: `ui-10l6tqk ui-np7j22 ui-it89om ui-121ilyj ui-1plog1 ui-bryuvx ui-kkvxwt ui-11xpdln ui-1bqoo3p ui-6458p5 ui-1naimka`, children: r2 }); + return (0, J2.jsx)(`span`, { "aria-hidden": `true`, ...h(qu2.root, qu2[t2], Ju2[n2], e38 && Ki2.part), children: i3 }); +} +function Zu2({ checked: e38, disabled: t2, size: n2 = `md`, variant: r2 = `green` }) { + return Zu2.d = 3721908657, (0, J2.jsx)(`span`, { "aria-hidden": `true`, "data-component": `switch`, "data-size": n2, "data-variant": r2, "data-checked": e38 || void 0, "data-disabled": t2 || void 0, className: `ui-3nfvp2 ui-6s0dn4 ui-l56j7k ui-1c4vz4f ui-2lah0s ui-dl72j9 ui-xymvpz ui-47corl ui--default-marker`, children: (0, J2.jsx)(Xu2, { interactive: false, size: n2, variant: r2 }) }); +} +var xf2 = { base: { kMv6JI: `ui-1acoasx`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, $$css: true }, sizeInherit: { kGuDYH: `ui-1qlqyl8`, kLWn49: `ui-15bjb6t`, kb6lSQ: `ui-4gjf66`, $$css: true }, variantCode: { kMv6JI: `ui-mpsg8l`, $$css: true }, weightRegular: { k63SB2: `ui-vxqr21`, $$css: true }, weightMedium: { k63SB2: `ui-h4fh7u`, $$css: true }, weightSemibold: { k63SB2: `ui-1hohiyz`, $$css: true }, weightBold: { k63SB2: `ui-1y2bmg9`, $$css: true }, colorPrimary: { kMwMTN: `ui-1wd3ewq`, $$css: true }, colorSecondary: { kMwMTN: `ui-19aaqeu`, $$css: true }, colorTertiary: { kMwMTN: `ui-4b2ntj`, $$css: true }, colorQuaternary: { kMwMTN: `ui-1e4uaio`, $$css: true }, colorActive: { kMwMTN: `ui-7qsbfx`, $$css: true }, colorFocused: { kMwMTN: `ui-zlszhr`, $$css: true }, colorRed: { kMwMTN: `ui-1jh5svw`, $$css: true }, colorRedSecondary: { kMwMTN: `ui-o7cye4`, $$css: true }, colorYellow: { kMwMTN: `ui-1izesbo`, $$css: true }, colorYellowSecondary: { kMwMTN: `ui-14nh9a`, $$css: true }, colorGreen: { kMwMTN: `ui-1w5rjie`, $$css: true }, colorGreenSecondary: { kMwMTN: `ui-dki84f`, $$css: true }, colorMagenta: { kMwMTN: `ui-xjecij`, $$css: true }, colorMagentaSecondary: { kMwMTN: `ui-29qggb`, $$css: true }, colorCyan: { kMwMTN: `ui-1d0l12`, $$css: true }, colorCyanSecondary: { kMwMTN: `ui-l34bp`, $$css: true }, colorOrange: { kMwMTN: `ui-11pqmr`, $$css: true }, colorOrangeSecondary: { kMwMTN: `ui-11nfuof`, $$css: true }, numeric: { kcqcaj: `ui-ss6m8b`, $$css: true }, truncateStart: { k1xSpc: `ui-1lliihq`, kzqmXN: `ui-h8yej3`, k7Eaqz: `ui-euugli`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kg5iWk: `ui-lyipyv`, k8aIck: `ui-jlip5`, kqG3fB: `ui-kyw5k8`, ksoyAI: `ui-zyj77d`, k9WMMc: `ui-dpxx8g`, $$css: true } }; +var Sf2 = { xs: Ca2.root, sm: wa2.root, md: Ta2.root, lg: Ea2.root, xl: Da2.root, "2xl": Oa2.root, "3xl": ka2.root, inherit: xf2.sizeInherit }; +var Cf2 = { regular: xf2.weightRegular, medium: xf2.weightMedium, semibold: xf2.weightSemibold, bold: xf2.weightBold }; +var wf2 = { primary: xf2.colorPrimary, secondary: xf2.colorSecondary, tertiary: xf2.colorTertiary, quaternary: xf2.colorQuaternary, active: xf2.colorActive, focused: xf2.colorFocused, red: xf2.colorRed, "red-secondary": xf2.colorRedSecondary, yellow: xf2.colorYellow, "yellow-secondary": xf2.colorYellowSecondary, green: xf2.colorGreen, "green-secondary": xf2.colorGreenSecondary, magenta: xf2.colorMagenta, "magenta-secondary": xf2.colorMagentaSecondary, cyan: xf2.colorCyan, "cyan-secondary": xf2.colorCyanSecondary, orange: xf2.colorOrange, "orange-secondary": xf2.colorOrangeSecondary }; +function Tf2({ color: e38, numeric: t2, size: n2, truncate: r2, variant: i3, weight: a3 }) { + return [xf2.base, ja2.root, Sf2[n2], Cf2[a3], i3 === `code` ? xf2.variantCode : null, e38 ? wf2[e38] : null, t2 ? xf2.numeric : null, r2 === `start` ? xf2.truncateStart : null, r2 === `end` ? Aa.root : null]; +} +function Ef2({ as: e38 = `span`, variant: t2 = `default`, size: n2 = `md`, weight: r2 = `regular`, color: i3, truncate: a3, numeric: o3, children: s3, rootStyle: c3, className: l5, style: u3, ref: d3, ...f4 }) { + Ef2.d = 3219036596; + let p4 = a3 === true ? `end` : a3 === false ? void 0 : a3 ?? void 0, { className: m3, style: h4 } = h(Tf2({ color: i3, numeric: o3, size: n2, truncate: p4, variant: t2, weight: r2 }), c3), g5 = (0, Y2.useCallback)((e39) => { + if (typeof d3 == `function`) return d3(e39); + d3 != null && (d3.current = e39); + }, [d3]); + return (0, J2.jsx)(e38, { ref: g5, className: K2(`ui-text`, m3, l5), style: { ...h4, ...u3 }, "data-variant": t2, "data-size": n2, "data-weight": r2, "data-color": i3, "data-truncate": p4, "data-numeric": o3 || void 0, ...f4, children: p4 === `start` ? (0, J2.jsxs)(J2.Fragment, { children: [`\u2066`, s3, `\u2069`] }) : s3 }); +} +var rp2 = { instant: 50, fast: 100, normal: 150, slow: 200, slower: 300, "1s": 1e3, "2s": 2e3 }; +var ip2 = { ease: `ease`, sharp: `cubic-bezier(0.165, 0.84, 0.44, 1)`, heavy: `cubic-bezier(0.645, 0.045, 0.355, 1)`, linear: `linear` }; +var sp2 = { kzqmXN: `ui-5lhr3w`, $$css: true }; +var cp2 = { base: { kVAEAm: `ui-ixxii4`, k87sOh: `ui-13vifvy`, kt4wiu: `ui-tijo5x`, krVfgx: `ui-1ey2m1c`, kLqNvP: `ui-1o0tod`, kY2c9j: `ui-1q7zipb`, kWkggS: `ui-cpsgoo`, kKVMdj: `ui-16q0fa0`, k44tkh: `ui-gyzkii`, kyAemX: `ui-18ctxkd`, kWV6AL: `ui-10e4vud`, $$css: true }, closing: { kKVMdj: `ui-1h31r3a`, kSiTet: `ui-g01cxk`, $$css: true }, fullscreen: { kWkggS: `ui-679uo6`, k6WDB: `ui-pivpjv ui-v600co`, kKVMdj: `ui-1a5igra`, k1ekBW: `ui-13b0p5u`, $$css: true } }; +var lp2 = { base: { kVAEAm: `ui-ixxii4`, k87sOh: `ui-wa60dl`, kbCHJM: `ui-1nrll8i`, kY2c9j: `ui-3vbryh`, k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, ks0D6T: `ui-w7nakj`, kskxy: `ui-12ajvvl`, kWkggS: `ui-f1vpex`, kEafiO: `ui-178xt8z`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-2kampu`, ke9TFa: `ui-1lun4ml`, k8ry5P: `ui-18b5jzi`, kBCPoo: `ui-15nuqqu`, kt9PQ7: `ui-so031l`, kfdmCh: `ui-1q0q8m5`, kL6WhQ: `ui-1jfuf7k`, k2ei4v: `ui-pilrb4`, kVhnKS: `ui-1t7ytsu`, kGJrpR: `ui-19smxde`, kaIpWk: `ui-1pkpdue`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kMv6JI: `ui-1acoasx`, kGuDYH: `ui-11wthnw`, kMwMTN: `ui-1wd3ewq`, k3XXqK: `ui-1t137rt`, k3nNDw: `ui-chxttu`, k3aq6I: `ui-k5290g`, kKVMdj: `ui-oddupx ui-1i31srg`, k44tkh: `ui-gyzkii`, kyAemX: `ui-18ctxkd`, kWV6AL: `ui-10e4vud`, $$css: true }, closing: { kKVMdj: `ui-1pkqeq7 ui-16rl4iv`, kSiTet: `ui-g01cxk`, $$css: true }, sizeSm: { kzqmXN: `ui-1m258z3`, $$css: true }, sizeMd: { kzqmXN: `ui-1l2rt3b`, $$css: true }, sizeLg: { kzqmXN: `ui-ht4xr3`, $$css: true }, sizeXl: { kzqmXN: `ui-ewp6mh`, $$css: true }, sizeXxl: { kzqmXN: `ui-11i3ho8`, $$css: true }, fullscreen: { k87sOh: `ui-80663w`, kbCHJM: `ui-1t8mvi6`, kzqmXN: `ui-14atkfc`, ks0D6T: `ui-1x1rfll`, kskxy: `ui-7ab17h`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, kWkggS: `ui-jbqb8w`, kLZC3w: `ui-oe9jqj`, kBCPoo: `ui-1vf9p6h`, kL6WhQ: `ui-1ljce3w`, kGJrpR: `ui-1ej2chf`, kaIpWk: `ui-1043rbw`, kKVMdj: `ui-1a5igra`, k3nNDw: `ui-1jpgh95`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kLWn49: `ui-14ju556`, kgyCeQ: `ui-lp1x4z`, kdrBUz: `ui-7iibnf`, kHBbk8: `ui-c8icb0`, k1ekBW: `ui-13b0p5u`, k3aq6I: `ui-1c071of`, k9MlgS: `ui-1b4evyo`, kBJ8X: `ui-172d7oh`, khkr5k: `ui-1wlgkvo`, kUp1g7: `ui-12srh1u`, kenXb: `ui-8jwf0z`, $$css: true } }; +var up2 = { viewportCappedWidth: (e38) => [sp2, { "--x-width": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(`min(${e38}px, 90vw)`) }] }; +var dp2 = { base: { kVAEAm: `ui-1n2onr6`, k1xSpc: `ui-78zum5`, kGNEyG: `ui-1cy8zhl`, kjj79g: `ui-1qughib`, kOIVth: `ui-ehausa`, kLKAdn: `ui-1t8xvyj`, kwRFfy: `ui-16mtmbo`, kGO01o: `ui-usxwy5`, kZCmMZ: `ui-7ru5ko`, $$css: true }, beforeContent: { kGO01o: `ui-18d9i69`, $$css: true }, centered: { kjj79g: `ui-l56j7k`, k9WMMc: `ui-2b8uid`, $$css: true } }; +var fp2 = { base: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kOIVth: `ui-11twubx`, k7Eaqz: `ui-euugli`, $$css: true }, centered: { kGNEyG: `ui-6s0dn4`, $$css: true } }; +var pp2 = { base: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kGNEyG: `ui-1cy8zhl`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kOIVth: `ui-137clkk`, $$css: true }, centered: { kGNEyG: `ui-6s0dn4`, $$css: true } }; +var mp2 = { base: { k1xSpc: `ui-78zum5`, kwnvtZ: `ui-1a02dak`, kGNEyG: `ui-1pha0wt`, kOIVth: `ui-ehausa`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, $$css: true }, centered: { kjj79g: `ui-l56j7k`, $$css: true } }; +var hp2 = { base: { kMwMTN: `ui-1wd3ewq`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kHjlTd: `ui-1mzt3pk`, $$css: true } }; +var gp2 = { base: { kMwMTN: `ui-4b2ntj`, kGuDYH: `ui-11wthnw`, k63SB2: `ui-vxqr21`, kLWn49: `ui-1ja60sm`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kHjlTd: `ui-1mzt3pk`, $$css: true }, secondary: { kMwMTN: `ui-19aaqeu`, $$css: true }, stepper: { kHjlTd: `ui-j0a0fe`, kTgw9: `ui-13faqbe`, $$css: true } }; +var _p2 = { root: { kzqmXN: `ui-h8yej3`, kAzted: `ui-2lwn1j`, kskxy: `ui-lbh9wg`, $$css: true }, content: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kOIVth: `ui-5cdhqx`, kH6xsr: `ui-3ct3a4`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kg3NbH: `ui-1px5tkr`, $$css: true }, header: { kMwMTN: `ui-4b2ntj`, kg3NbH: `ui-njsko4`, k1K539: `ui-l018at`, keoZOQ: `ui-1fjfqqj ui-3pnz3v`, $$css: true }, rowItem: { k1K539: `ui-at24cr ui-h95wvw`, $$css: true }, row: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-1q0g3np`, kGNEyG: `ui-6s0dn4`, kOIVth: `ui-ehausa`, kzqmXN: `ui-ihbwum`, kZKoxP: `ui-170hpbr`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-196pc8s`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-22095l`, keoZOQ: `ui-dj266r`, k71WvV: `ui-1uioroh`, k1K539: `ui-at24cr`, keTefX: `ui-1cw70au`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, kLZC3w: `ui-1v8p93f`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kBCPoo: `ui-1o3jo1z`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, kL6WhQ: `ui-16stqrj`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kGJrpR: `ui-v5lvn5`, kaIpWk: `ui-1043rbw`, kWkggS: `ui-jbqb8w`, kMwMTN: `ui-1heor9g`, k9WMMc: `ui-1yc453h`, $$css: true }, rowMultiline: { kZKoxP: `ui-t7dq6l`, kAzted: `ui-11ooeo3`, kLKAdn: `ui-13ly8rp`, kGO01o: `ui-1xlntvz`, $$css: true }, rowInteractive: { kkrTdU: `ui-1ypdohk`, kWkggS: `ui-jbqb8w ui-1iuyybk ui-bc7umr ui-1oqui1x`, $$css: true }, rowSelected: { kWkggS: `ui-59yu97 ui-1kj6vsg ui-1o6fdlz`, $$css: true }, rowDisabled: { kkrTdU: `ui-1h6gzvc`, kSiTet: `ui-byyjgo`, $$css: true }, rowIcon: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kmuXW: `ui-2lah0s`, $$css: true }, rowLabel: { kUk6DE: `ui-1cqoux5`, k7Eaqz: `ui-euugli`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kg5iWk: `ui-lyipyv`, k8aIck: `ui-jlip5`, kqG3fB: `ui-kyw5k8`, kMwMTN: `ui-1wd3ewq`, $$css: true }, rowLabelMultiline: { kORKVm: `ui-ryxfnj`, k8aIck: `ui-sdcz8n`, khDVqt: `ui-eaf4i8`, $$css: true }, rowTrailing: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kOIVth: `ui-11twubx`, kmuXW: `ui-2lah0s`, k7Eaqz: `ui-euugli`, $$css: true } }; +var vp2 = { base: { kB7OPa: `ui-9f619`, kzqmXN: `ui-h8yej3`, kLKAdn: `ui-t9g0qb`, kwRFfy: `ui-16mtmbo`, kGO01o: `ui-20eq2h`, kZCmMZ: `ui-7ru5ko`, kORKVm: `ui-1odjw0f`, $$css: true }, afterHeader: { kLKAdn: `ui-1t8xvyj`, $$css: true }, scrollable: { kEafiO: `ui-178xt8z`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-1aeic0j`, $$css: true } }; +var yp2 = { base: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-13a6bvl`, kOIVth: `ui-ehausa`, kLKAdn: `ui-oyc9vk`, kwRFfy: `ui-1fg0g13`, kGO01o: `ui-2lprc`, kZCmMZ: `ui-1tajz9i`, kB7OPa: `ui-9f619`, kEafiO: `ui-178xt8z`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-1aeic0j`, $$css: true } }; +var bp2 = { root: { kysU6D: `ui-jyslct`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kmuXW: `ui-2lah0s`, kB7OPa: `ui-9f619`, kVAEAm: `ui-10l6tqk`, k87sOh: `ui-rge2pg`, kt4wiu: `ui-1wr5tk2`, kY2c9j: `ui-1vjfegm`, kzqmXN: `ui-16bvwqk`, kZKoxP: `ui-1a6rlst`, k7Eaqz: `ui-cbmsab`, kAzted: `ui-4jlmx6`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, kLZC3w: `ui-1b4hy2t`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kBCPoo: `ui-1273586`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, kL6WhQ: `ui-1tnzt7h`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kGJrpR: `ui-1mi4oqr`, kaIpWk: `ui-1i4c3av`, kMv6JI: `ui-jb2p0i`, kGuDYH: `ui-1qlqyl8`, k63SB2: `ui-1pd3egz`, kLWn49: `ui-15bjb6t`, kWkggS: `ui-jbqb8w ui-oli092`, kMwMTN: `ui-19aaqeu ui-1dsx48b`, kkrTdU: `ui-1ypdohk`, kFalU9: `ui-ggy1nq`, k1ekBW: `ui-1oy24xj`, kIyJzY: `ui-g3p6pi`, kAMwcw: `ui-py3bvx`, k3aq6I: `ui-1c071of`, $$css: true } }; +function xp2({ fullscreen: e38, status: t2 }) { + return [cp2.base, t2 === `close` ? cp2.closing : null, e38 ? cp2.fullscreen : null]; +} +function Sp2({ fullscreen: e38, size: t2, status: n2, width: r2 }) { + return [lp2.base, Bp2(t2), r2 !== void 0 && !e38 ? up2.viewportCappedWidth(r2) : null, n2 === `close` ? lp2.closing : null, e38 ? lp2.fullscreen : null]; +} +function Cp2({ alignment: e38, beforeContent: t2 }) { + return [dp2.base, t2 ? dp2.beforeContent : null, e38 === `center` ? dp2.centered : null]; +} +function wp2({ alignment: e38 }) { + return [fp2.base, e38 === `center` ? fp2.centered : null]; +} +function Tp2({ alignment: e38 }) { + return [pp2.base, e38 === `center` ? pp2.centered : null]; +} +function Ep2({ alignment: e38 }) { + return [mp2.base, e38 === `center` ? mp2.centered : null]; +} +function Dp2() { + return hp2.base; +} +function Op2({ stepper: e38, color: t2 = `tertiary`, fontSize: n2 = `lg` }) { + return [ja2.root, gp2.base, t2 === `secondary` ? gp2.secondary : null, e38 && n2 === `lg` ? Ea2.root : null, e38 ? gp2.stepper : null]; +} +function kp2() { + return _p2.root; +} +function Ap2() { + return _p2.content; +} +function jp2() { + return [wa2.root, _p2.header]; +} +function Mp2() { + return _p2.rowItem; +} +function Np2({ disabled: e38, interactive: t2, multiline: n2, selected: r2 }) { + return [_p2.row, Ta2.root, n2 ? _p2.rowMultiline : null, t2 ? _p2.rowInteractive : null, r2 ? _p2.rowSelected : null, e38 ? _p2.rowDisabled : null]; +} +function Pp2() { + return _p2.rowIcon; +} +function Fp2({ multiline: e38 }) { + return [Ta2.root, _p2.rowLabel, e38 ? _p2.rowLabelMultiline : null]; +} +function Ip2() { + return _p2.rowTrailing; +} +function Lp2({ afterHeader: e38, scrollable: t2 }) { + return [Ta2.root, vp2.base, e38 ? vp2.afterHeader : null, t2 ? vp2.scrollable : null]; +} +function Rp2() { + return yp2.base; +} +function zp2() { + return [bp2.root, Ki2.self]; +} +function Bp2(e38) { + switch (e38) { + case `sm`: + return lp2.sizeSm; + case `md`: + return lp2.sizeMd; + case `lg`: + return lp2.sizeLg; + case `xl`: + return lp2.sizeXl; + case `xxl`: + return lp2.sizeXxl; + case `fullscreen`: + return null; + } +} +var Vp2 = rp2.slower; +var Hp2 = ip2.sharp; +var Up2 = (0, Y2.createContext)(null); +function Wp2(e38) { + let t2 = (0, Y2.useContext)(Up2); + if (!t2) throw Error(`${e38} must be used within Dialog`); + return t2; +} +function Gp2() { + return Wp2(`useDialogContext`); +} +function Kp2() { + let e38 = (0, Y2.useId)(); + return { titleId: `${e38}-title`, descriptionId: `${e38}-description` }; +} +function qp2({ "aria-label": e38 = `Close`, iconSize: t2 = 12, rootStyle: n2, onClick: r2 }) { + qp2.d = 1048069076; + let { onOpenChange: i3 } = Wp2(`Dialog.Close`), a3 = () => { + r2?.(), i3(false); + }, o3 = q2({ rootClass: `ui-dialog-close`, stylexStyles: [zp2(), n2], className: `ui-icon-button` }); + return (0, J2.jsx)(`button`, { type: `button`, ...qi2.self, "aria-label": e38, className: o3.className, "data-frame": `container`, "data-size": `md`, "data-rounded": `true`, "data-variant": `ghost`, onClick: a3, style: o3.style, children: (0, J2.jsx)(Oi, { "aria-hidden": `true`, name: `close`, size: t2, variant: `outline` }) }); +} +function Jp2({ children: e38, rootStyle: t2, className: n2, style: r2, scrollable: i3 }) { + Jp2.d = 1993425269; + let { contentHasCompactTopPadding: a3 } = Wp2(`Dialog.Content`), o3 = i3 ?? r2?.maxHeight !== void 0; + return (0, J2.jsx)(Ef2, { as: `div`, size: `md`, weight: `regular`, color: `primary`, className: K2(`ui-dialog-content`, o3 && `ui-dialog-content--scrollable`, n2), style: r2, rootStyle: [Lp2({ afterHeader: a3, scrollable: o3 }), t2], children: e38 }); +} +function Yp2({ as: e38 = `p`, children: t2, style: n2, rootStyle: r2, ...i3 }) { + Yp2.d = 44863126; + let { descriptionId: a3 } = Wp2(`Dialog.Description`), o3 = q2({ rootClass: `ui-dialog-description`, stylexStyles: [Op2({ stepper: false }), r2], style: n2 }); + return (0, J2.jsx)(e38, { id: a3, ...i3, className: o3.className, style: o3.style, children: t2 }); +} +function Xp2({ children: e38, className: t2, rootStyle: n2, style: r2, ...i3 }) { + Xp2.d = 4197487865; + let a3 = q2({ rootClass: `ui-dialog-footer`, stylexStyles: [Rp2(), n2], className: t2, style: r2 }); + return (0, J2.jsx)(`div`, { className: a3.className, style: a3.style, ...i3, children: e38 }); +} +function Zp2({ children: e38, title: t2, stepLabel: n2, description: r2, alignment: i3 = `start`, titleSize: a3 = `lg`, titleWeight: o3 = `regular`, descriptionColor: s3 = `tertiary`, descriptionFontSize: c3 = `lg`, rootStyle: l5 }) { + Zp2.d = 1985259212; + let u3 = (0, Y2.useContext)(Up2), d3 = (0, Y2.useId)(), f4 = u3?.titleId ?? `${d3}-title`, p4 = u3?.descriptionId ?? `${d3}-description`, m3 = !!t2, h4 = !!n2, g5 = !!r2, _5 = m3 || h4 || g5, v5 = q2({ rootClass: `ui-dialog-header`, stylexStyles: [Cp2({ alignment: i3, beforeContent: u3?.headerBeforeContent ?? false }), l5] }), y4 = q2({ rootClass: `ui-dialog-header-lead`, stylexStyles: wp2({ alignment: i3 }) }), b2 = q2({ rootClass: `ui-dialog-header-stepper-head`, stylexStyles: Tp2({ alignment: i3 }) }), x2 = q2({ rootClass: `ui-dialog-header-stepper`, stylexStyles: Ep2({ alignment: i3 }) }), S2 = q2({ rootClass: `ui-dialog-title`, stylexStyles: Dp2() }), C2 = q2({ rootClass: `ui-dialog-description`, stylexStyles: Op2({ stepper: true, color: s3, fontSize: c3 }), className: `ui-dialog-header-stepper-description` }); + return (0, J2.jsxs)(`div`, { className: v5.className, "data-alignment": i3, style: v5.style, children: [_5 ? (0, J2.jsx)(`div`, { className: y4.className, style: y4.style, children: (0, J2.jsxs)(`div`, { className: b2.className, style: b2.style, children: [m3 || h4 ? (0, J2.jsxs)(`div`, { className: x2.className, style: x2.style, role: h4 ? `status` : void 0, children: [m3 ? (0, J2.jsx)(Ef2, { as: `h2`, className: S2.className, color: `primary`, id: f4, size: a3, style: S2.style, weight: o3, children: t2 }) : null, h4 ? (0, J2.jsx)(Ef2, { as: `span`, color: `quaternary`, size: `lg`, weight: `regular`, children: n2 }) : null] }) : null, g5 ? (0, J2.jsx)(`p`, { className: C2.className, id: p4, style: C2.style, children: r2 }) : null] }) }) : null, e38] }); +} +function Qp2({ children: e38 }) { + Qp2.d = 2404464051; + let t2 = q2({ rootClass: `ui-dialog-header-lead`, stylexStyles: wp2({ alignment: `start` }) }); + return (0, J2.jsx)(`div`, { className: t2.className, style: t2.style, children: e38 }); +} +var $p2 = (0, Y2.createContext)({ selectable: false }); +function em({ selectable: e38, children: t2 }) { + return em.d = 398133413, (0, J2.jsx)($p2.Provider, { value: { selectable: e38 }, children: t2 }); +} +function tm() { + return (0, Y2.useContext)($p2); +} +function nm({ children: e38, rootStyle: t2, selectable: n2 = false, "aria-label": r2, "aria-labelledby": i3 }) { + nm.d = 3355976881; + let a3 = h(Ap2()); + return (0, J2.jsx)(em, { selectable: n2, children: (0, J2.jsx)(Cc2, { "aria-label": r2, "aria-labelledby": i3, className: `ui-dialog-list`, role: n2 ? `listbox` : void 0, rootStyle: [kp2(), t2], children: (0, J2.jsx)(`ul`, { className: a3.className, style: a3.style, children: e38 }) }) }); +} +function rm({ children: e38 }) { + rm.d = 1660678637; + let t2 = q2({ rootClass: `ui-dialog-list-header`, stylexStyles: jp2() }); + return (0, J2.jsx)(`li`, { className: t2.className, style: t2.style, children: e38 }); +} +function im({ icon: e38, label: t2, trailing: n2, selected: r2 = false, multiline: i3 = false, onClick: a3, disabled: o3 }) { + im.d = 3646017287; + let { selectable: s3 } = tm(), c3 = s3 && a3 !== void 0, l5 = h(Mp2()), u3 = q2({ rootClass: `ui-dialog-list-row`, stylexStyles: Np2({ disabled: o3 === true, interactive: a3 !== void 0, multiline: i3, selected: r2 }) }), d3 = h(Pp2()), f4 = h(Fp2({ multiline: i3 })), p4 = h(Ip2()), m3 = (0, J2.jsxs)(J2.Fragment, { children: [e38 ? (0, J2.jsx)(`div`, { className: d3.className, style: d3.style, children: e38 }) : null, (0, J2.jsx)(`div`, { className: f4.className, style: f4.style, children: t2 }), n2 ? (0, J2.jsx)(`div`, { className: p4.className, style: p4.style, children: n2 }) : null] }), h4 = a3 === void 0 ? (0, J2.jsx)(`div`, { className: u3.className, style: u3.style, children: m3 }) : c3 ? (0, J2.jsx)(`button`, { "aria-selected": r2, className: u3.className, disabled: o3, onClick: a3, role: `option`, style: u3.style, type: `button`, children: m3 }) : (0, J2.jsx)(`button`, { className: u3.className, disabled: o3, onClick: a3, style: u3.style, type: `button`, children: m3 }); + return (0, J2.jsx)(`li`, { className: l5.className, role: c3 ? `presentation` : void 0, style: l5.style, children: h4 }); +} +function am({ children: e38, color: t2 = `primary`, rootStyle: n2, style: r2, ...i3 }) { + am.d = 435937055; + let { titleId: a3 } = Wp2(`Dialog.Title`); + return (0, J2.jsx)(Ef2, { as: `h2`, id: a3, size: `lg`, color: t2, ...i3, rootStyle: [Dp2(), n2], className: `ui-dialog-title`, style: r2, children: e38 }); +} +var om = (e38) => e38 === `hidden` || e38 === `clip`; +function sm() { + if (typeof document2 > `u` || document2.body === null) return true; + let e38 = getComputedStyle2(document2.documentElement), t2 = e38.overflowX === `visible` && e38.overflowY === `visible` ? getComputedStyle2(document2.body) : e38; + return !om(t2.overflowX) || !om(t2.overflowY); +} +function cm(e38) { + let t2 = Y2.Children.toArray(e38).filter(Y2.isValidElement), n2 = false, r2 = false; + for (let e39 = 0; e39 < t2.length; e39 += 1) t2[e39].type === Jp2 && (e39 === 0 && (r2 = true), e39 > 0 && t2[e39 - 1]?.type === Zp2 && (n2 = true, r2 = true)); + return { headerBeforeContent: n2, contentHasCompactTopPadding: r2 }; +} +function lm(e38) { + return e38 === void 0 ? { top: 40, right: 40, bottom: 40, left: 40 } : typeof e38 == `number` ? { top: e38, right: e38, bottom: e38, left: e38 } : { top: e38.top ?? 0, right: e38.right ?? 0, bottom: e38.bottom ?? 0, left: e38.left ?? 0 }; +} +function um(e38, t2, n2 = 1024, r2 = window2) { + let i3 = r2.innerWidth - t2.left - t2.right, a3 = n2 === null ? i3 : Math.min(i3, n2), o3 = r2.innerHeight - t2.top - t2.bottom, s3 = a3, c3 = a3 / e38; + c3 > o3 && (c3 = o3, s3 = o3 * e38); + let l5 = t2.left + (i3 - s3) / 2, u3 = t2.top + (o3 - c3) / 2; + return { width: s3, height: c3, top: u3, left: l5 }; +} +function dm(e38, t2, n2) { + return t2 <= 0 ? `none` : e38.map((e39) => `${e39} ${t2}ms ${n2}`).join(`, `); +} +function fm2(e38) { + return e38.button === 0 && !e38.ctrlKey; +} +var pm2 = [`[data-popup-open]`, `[data-component="select-positioner"][data-open]`, `[data-component="select-popup"][data-open]`, `[data-component="menu-popup"][data-open]`, `[role="listbox"][data-open]`, `[role="menu"][data-open]`].join(`, `); +function mm2(e38) { + return e38.querySelector(pm2) !== null; +} +var hm2 = `[data-component="menu-popup"], [data-component="search-menu-popup"]`; +function gm2(e38) { + let t2 = e38.closest(hm2); + if (t2 === null) return e38.closest(`[role="menu"],[role="listbox"]`) === null ? e38 : null; + let n2 = e38; + for (; t2 !== null; ) { + let r2 = t2, i3 = [r2.id, r2.querySelector(`[role="listbox"]`)?.id ?? ``].filter((e39) => e39 !== ``).map((e39) => `[aria-controls~="${e39.replace(/["\\]/g, `\\$&`)}"]`).join(`,`); + if (n2 = i3 === `` ? void 0 : Array.from(e38.ownerDocument.querySelectorAll(i3)).find((e39) => !r2.contains(e39)), n2 === void 0) return null; + t2 = n2.closest(hm2); + } + return n2; +} +function _m2(e38) { + let t2 = gm2(e38); + return t2 === null ? null : { element: e38, returnTarget: t2 }; +} +var vm2 = class { + #e = null; + track(e38) { + this.#e = e38; + } + get current() { + let e38 = this.#e; + return e38 === null ? null : e38.element.isConnected && e38.element.closest(`[hidden],[data-closed]`) === null ? e38.element : e38.returnTarget; + } + set current(e38) { + } +}; +function ym2(e38, t2) { + return e38?.ownerDocument ?? t2?.ownerDocument ?? (typeof document2 > `u` ? null : document2); +} +function bm2({ children: e38, size: t2 = `md`, width: n2, open: r2, defaultOpen: i3 = false, onOpenChange: a3, role: o3 = `dialog`, "aria-label": s3, "aria-labelledby": c3, "aria-describedby": l5, "data-presentation": u3, "data-block-global-shortcuts": d3, className: f4, backdropClassName: p4, rootStylexStyles: m3, backdropStylexStyles: h4, fullscreenTransition: g5, fullscreenBackdropTransition: _5, style: y4, closeOnBackdropClick: b2 = true, closeOnOutsidePress: x2 = true, closeOnEscape: S2 = true, disableFocusTrap: w2 = false, modal: E2 = true, lockScroll: D2 = true, ref: O2, animationSource: k2, fullscreenCloseInPlace: A2 = false, aspectRatio: M2, fullscreenViewportPadding: N3, fullscreenMaxWidth: P3, onAnimationComplete: F2, onTransitionStatusChange: I2, transitionDuration: L3, initialFocus: R3, returnFocus: z2, onKeyDown: B3, dialogRootTabIndex: ee2 = -1 }) { + bm2.d = 883096921; + let [ne3, re3] = (0, Y2.useState)(i3), ae3 = r2 !== void 0, V3 = ae3 ? r2 : ne3, H3 = Ni2(), [oe5, se5] = (0, Y2.useState)(null), [ce6, le6] = (0, Y2.useState)(true), [ue6, de6] = (0, Y2.useState)(false); + if (V3 !== ue6 && (de6(V3), V3)) { + le6(sm()); + let e39 = H3?.ownerDocument ?? (typeof document2 > `u` ? null : document2), t3 = e39?.activeElement ?? null, n3 = t3?.ownerDocument.defaultView ?? null; + se5(t3 !== null && n3 !== null && t3 instanceof n3.HTMLElement && t3 !== e39?.body ? _m2(t3) : null); + } + let [fe5] = (0, Y2.useState)(() => new vm2()); + (0, Y2.useLayoutEffect)(() => { + fe5.track(oe5); + }, [fe5, oe5]); + let U3 = t2 === `fullscreen`, W3 = di2(), he5 = g5?.durationMs ?? Vp2, ge5 = g5?.easing ?? Hp2, _e5 = _5?.durationMs ?? he5, ve5 = _5?.easing ?? ge5, [ye5, be5] = (0, Y2.useState)(`idle`), [xe5, Se5] = (0, Y2.useState)(false), [Ce5, we5] = (0, Y2.useState)(null), Te5 = k2 != null, Ee5 = (0, Y2.useRef)(null), De5 = (0, Y2.useRef)(null), Oe5 = (0, Y2.useRef)(F2); + (0, Y2.useEffect)(() => { + Oe5.current = F2; + }, [F2]); + let ke5 = (0, Y2.useRef)(I2); + (0, Y2.useEffect)(() => { + ke5.current = I2; + }, [I2]); + let Ae5 = (0, Y2.useCallback)((e39) => { + ae3 || re3(e39), a3?.(e39); + }, [ae3, a3]), G2 = (0, Y2.useRef)(null), je5 = (0, Y2.useCallback)(() => { + let e39 = ym2(H3, G2.current); + if (e39 === null) return true; + let t3 = (H3 ?? e39.body).querySelectorAll(`[data-ui-dialog-root]`); + return t3.item(t3.length - 1) === G2.current; + }, [H3]); + (0, Y2.useEffect)(() => { + if (!U3 || !V3 || !Te5) return; + De5.current &&= (clearTimeout(De5.current), null), be5(`expanding`), we5(null); + let e39 = null, t3 = null; + return e39 = requestAnimationFrame2(() => { + t3 = requestAnimationFrame2(() => { + Se5(true); + }); + }), Ee5.current = setTimeout(() => { + be5(`expanded`), Oe5.current?.(); + }, he5), () => { + e39 !== null && cancelAnimationFrame2(e39), t3 !== null && cancelAnimationFrame2(t3), Ee5.current && clearTimeout(Ee5.current); + }; + }, [U3, V3, Te5, he5]); + let Me5 = (0, Y2.useCallback)(() => { + U3 && ye5 !== `collapsing` && (Ee5.current &&= (clearTimeout(Ee5.current), null), be5(`collapsing`), we5(A2), Se5(false), De5.current = setTimeout(() => { + Ae5(false), be5(`idle`), De5.current = null, Oe5.current?.(); + }, he5)); + }, [U3, ye5, A2, Ae5, he5]); + (0, Y2.useEffect)(() => () => { + Ee5.current && clearTimeout(Ee5.current), De5.current && clearTimeout(De5.current); + }, []); + let { refs: Ne5, context: Pe5 } = jp({ open: V3, onOpenChange: U3 ? (e39) => { + e39 ? Ae5(true) : Me5(); + } : Ae5 }), Fe4 = af([Ne5.setFloating, G2, O2]), Ie5 = Tp(Pe5), Le5 = kp(Pe5, { outsidePressEvent: `mousedown`, outsidePress: b2 && x2 ? (e39) => fm2(e39) && je5() : false, escapeKey: false }), ze5 = Hp(Pe5, { role: o3 }), { getFloatingProps: Be5 } = Np([Ie5, Le5, ze5]), Ve5 = Be5(), He5 = L3 ?? rp2.slow, { isMounted: Ue4, status: We4 } = Kp(Pe5, { duration: U3 ? he5 : He5 }), Ge4 = (0, Y2.useRef)(We4); + (0, Y2.useLayoutEffect)(() => { + ke5.current?.(We4); + }, [We4]); + let { titleId: Ke4, descriptionId: qe4 } = Kp2(), [Je4, Ye4] = (0, Y2.useState)(false), [Xe4, Ze4] = (0, Y2.useState)(false); + (0, Y2.useLayoutEffect)(() => { + let e39 = G2.current; + Ye4(e39 !== null && e39.querySelector(`[id="${Ke4}"]`) !== null), Ze4(e39 !== null && e39.querySelector(`[id="${qe4}"]`) !== null); + }); + let Qe4 = (0, Y2.useMemo)(() => cm(e38), [e38]), $e4 = (0, Y2.useMemo)(() => ({ titleId: Ke4, descriptionId: qe4, onOpenChange: U3 ? (e39) => { + e39 || Me5(); + } : Ae5, headerBeforeContent: Qe4.headerBeforeContent, contentHasCompactTopPadding: Qe4.contentHasCompactTopPadding }), [Ke4, qe4, Ae5, U3, Me5, Qe4.headerBeforeContent, Qe4.contentHasCompactTopPadding]), et4 = lm(N3), tt4 = (0, Y2.useMemo)(() => ({ top: et4.top, right: et4.right, bottom: et4.bottom, left: et4.left }), [et4.top, et4.right, et4.bottom, et4.left]), nt4 = (0, Y2.useMemo)(() => { + if (!U3 || !k2) return; + let e39 = um(M2 ?? k2.width / k2.height, tt4, P3, ym2(H3, G2.current)?.defaultView ?? window2), t3 = k2.width / e39.width, n3 = k2.height / e39.height, r3 = k2.left + k2.width / 2, i4 = k2.top + k2.height / 2, a4 = e39.left + e39.width / 2, o4 = e39.top + e39.height / 2, s4 = r3 - a4, c4 = i4 - o4, l6 = !xe5, u4 = W3 || (ye5 === `collapsing` || We4 === `close`) && (Ce5 ?? A2), d4 = l6 && !u4, f5 = l6 || We4 === `close`, p5 = (k2.borderRadius ?? 8) / Math.max(t3, n3, 1e-3), m4 = d4 ? p5 : 8; + return { position: `fixed`, top: e39.top, left: e39.left, width: e39.width, height: e39.height, transform: d4 ? `translate(${s4}px, ${c4}px) scale(${t3}, ${n3})` : `translate(0, 0) scale(1, 1)`, ...u4 ? { opacity: +!f5 } : {}, transformOrigin: `center center`, borderRadius: `${m4}px`, overflow: `hidden`, transition: dm([`transform`, `border-radius`, `opacity`], he5, ge5), willChange: d4 ? `transform, border-radius` : `auto`, contain: `layout` }; + }, [U3, k2, A2, Ce5, ye5, M2, tt4, P3, xe5, We4, W3, he5, ge5, H3]); + (0, Y2.useEffect)(() => { + if (!U3 || ye5 !== `expanded` || !k2) return; + let e39 = G2.current; + if (!e39) return; + let t3 = M2 ?? k2.width / k2.height, n3 = null, r3 = e39.ownerDocument.defaultView ?? window2, i4 = () => { + n3 = null; + let i5 = um(t3, tt4, P3, r3); + e39.style.top = `${i5.top}px`, e39.style.left = `${i5.left}px`, e39.style.width = `${i5.width}px`, e39.style.height = `${i5.height}px`; + }, a4 = () => { + n3 === null && (n3 = r3.requestAnimationFrame(i4)); + }; + return r3.addEventListener(`resize`, a4), () => { + r3.removeEventListener(`resize`, a4), n3 !== null && r3.cancelAnimationFrame(n3); + }; + }, [U3, ye5, k2, M2, tt4, P3]); + let rt5 = U3 ? Ue4 || ye5 === `collapsing` : Ue4, { portalLayerStyles: it5 } = Gi2(`modal`, rt5); + if ((0, Y2.useEffect)(() => { + if (U3) { + Ge4.current = We4; + return; + } + let e39 = Ge4.current; + (We4 === `open` && e39 !== `open` || We4 === `unmounted` && e39 === `close`) && Oe5.current?.(), Ge4.current = We4; + }, [U3, We4]), (0, Y2.useEffect)(() => { + if (!rt5 || !S2) return; + let e39 = ym2(H3, G2.current); + if (e39 === null) return; + let t3 = /* @__PURE__ */ new WeakSet(), n3 = (n4) => { + n4.key === `Escape` && mm2(e39) && t3.add(n4); + }, r3 = (n4) => { + n4.key === `Escape` && (n4.defaultPrevented || n4.isComposing || !je5() || t3.has(n4) || mm2(e39) || (n4.preventDefault(), n4.stopPropagation(), n4.stopImmediatePropagation(), U3 ? Me5() : Ae5(false))); + }; + return e39.addEventListener(`keydown`, n3, true), e39.addEventListener(`keydown`, r3), () => { + e39.removeEventListener(`keydown`, n3, true), e39.removeEventListener(`keydown`, r3); + }; + }, [rt5, S2, je5, U3, Me5, H3, Ae5]), !rt5) return null; + let at4 = c3 ?? (!s3 && Je4 ? Ke4 : void 0), ot4 = We4, st3 = q2({ rootClass: `ui-dialog-backdrop`, stylexStyles: [xp2({ fullscreen: U3, status: ot4 }), h4], className: K2(U3 && `ui-dialog-backdrop--fullscreen`, p4), style: U3 ? { opacity: xe5 && ot4 !== `close` ? 1 : 0, transition: dm([`opacity`], _e5, ve5), willChange: xe5 ? `auto` : `opacity`, ...it5 } : it5 }), ct3 = q2({ rootClass: `ui-dialog`, stylexStyles: [Sp2({ fullscreen: U3, size: t2, status: ot4, width: n2 }), m3], className: K2(`ui-dialog--${t2}`, f4), style: U3 ? { ...nt4, ...it5, ...y4 } : { ...it5, ...y4 } }); + return (0, J2.jsx)(Up2.Provider, { value: $e4, children: (0, J2.jsxs)(ap, { ...H3 ? { root: H3 } : {}, children: [E2 && (0, J2.jsx)(xp, { className: st3.className, lockScroll: D2 && ce6, "data-status": We4, "data-expanded": U3 ? xe5 : void 0, style: st3.style, onClick: b2 ? (e39) => { + e39.ctrlKey || je5() && e39.target === e39.currentTarget && (U3 ? Me5() : Ae5(false)); + } : void 0 }), (0, J2.jsx)(gp, { context: Pe5, disabled: w2, modal: E2, ...R3 === void 0 ? {} : { initialFocus: R3 }, ...z2 === void 0 ? oe5 === null ? {} : { returnFocus: fe5 } : { returnFocus: z2 }, children: (0, J2.jsx)(`div`, { ref: Fe4, role: `dialog`, tabIndex: ee2, "data-ui-dialog-root": ``, className: ct3.className, style: ct3.style, "aria-label": s3, "aria-labelledby": at4, "aria-describedby": l5 ?? (Xe4 ? qe4 : void 0), "aria-modal": E2 ? `true` : void 0, "data-presentation": u3, "data-block-global-shortcuts": d3, "data-status": We4, "data-animation-phase": U3 ? ye5 : void 0, "data-expanded": U3 ? xe5 : void 0, ...Ve5, onKeyDown: (e39) => { + let t3 = Ve5.onKeyDown; + typeof t3 == `function` && t3(e39), e39.defaultPrevented || B3?.(e39); + }, children: e38 }) })] }) }); +} +var xm2 = Object.assign(bm2, { Header: Zp2, HeaderLead: Qp2, Title: am, Description: Yp2, List: nm, ListHeader: rm, ListRow: im, Content: Jp2, Footer: Xp2, Close: qp2 }); +function Bm({ className: e38, variant: t2 = `default`, size: n2 = `lg`, ref: r2, disabled: i3, startIcon: a3, endIcon: o3, inputGroupRootStyle: s3, ...c3 }) { + return Bm.d = 2748038522, (0, J2.jsxs)(wl.Root, { className: e38, rootStyle: s3, variant: t2, size: n2, disabled: i3, children: [a3 != null && (0, J2.jsx)(wl.Icon, { name: a3 }), (0, J2.jsx)(wl.Input, { ref: r2, ...c3 }), o3 != null && (0, J2.jsx)(wl.Icon, { name: o3 })] }); +} +var mh2 = (e38) => typeof e38 == `object` && !!e38 && !Array.isArray(e38); +var hh2 = { _zod: { output: {} }, safeParse: (e38) => mh2(e38) ? { success: true } : { success: false, error: TypeError(`drag payload must be an object`) } }; +function gh2(e38, t2) { + return e38 instanceof t2; +} +function _h2(e38, t2 = () => hh2) { + let n2 = null, r2 = () => (n2 === null && (n2 = t2()), n2); + return class { + static { + this.type = e38; + } + static get schema() { + return r2(); + } + constructor(t3) { + this.type = e38, this.payload = t3; + } + }; +} +var vh2 = class e36 { + static { + this.instance = null; + } + constructor() { + this.data = null, this.listeners = /* @__PURE__ */ new Set(); + } + static getInstance() { + return e36.instance ||= new e36(), e36.instance; + } + static { + this.subscribe = (t2) => e36.getInstance().subscribeToChanges(t2); + } + static { + this.isDragActive = () => e36.getInstance().hasData(); + } + notifyListeners() { + for (let e38 of this.listeners) e38(); + } + subscribeToChanges(e38) { + return this.listeners.add(e38), () => { + this.listeners.delete(e38); + }; + } + setData(e38) { + this.data !== e38 && (this.data = e38, this.notifyListeners()); + } + getData() { + return this.data; + } + getValidatedData(e38) { + let t2 = this.data; + if (!t2) return null; + for (let n2 of e38) if (gh2(t2, n2)) return n2.schema.safeParse(t2.payload).success ? t2 : null; + return null; + } + hasAnyClass(e38) { + return this.data ? e38.some((e39) => this.data instanceof e39) : false; + } + clearData() { + this.data !== null && (this.data = null, this.notifyListeners()); + } + hasData() { + return this.data !== null; + } +}; +var yh2 = { linear: [0, 0, 1, 1], ease: [0.25, 0.1, 0.25, 1], "ease-in": [0.42, 0, 1, 1], "ease-out": [0, 0, 0.58, 1], "ease-in-out": [0.42, 0, 0.58, 1] }; +var bh2 = /^cubic-bezier\(\s*([^,]+),\s*([^,]+),\s*([^,]+),\s*([^,)]+)\s*\)$/; +function xh2(e38) { + let t2 = yh2[e38]; + if (t2 !== void 0) return t2; + let n2 = bh2.exec(e38); + if (n2 === null) throw Error(`Not a cubic-bezier easing: ${e38}`); + return [Number(n2[1]), Number(n2[2]), Number(n2[3]), Number(n2[4])]; +} +function Sh(e38, t2) { + let n2 = rp2[e38], r2 = ip2[t2]; + return { durationMs: n2, durationS: n2 / 1e3, easing: r2, ease: xh2(r2) }; +} +var Ch = { ...Sh(`fast`, `sharp`), scale: 0.98, offsetPx: 2 }; +var wh = [`kind`, `type`, `case`]; +function Th(e38) { + switch (typeof e38) { + case `string`: + return JSON.stringify(e38); + case `number`: + case `boolean`: + case `bigint`: + return String(e38); + default: + return; + } +} +function Eh(e38) { + if (e38 == null) return String(e38); + if (typeof e38 != `object`) return Th(e38) ?? typeof e38; + for (let t2 of wh) { + let n2 = Th(Object.getOwnPropertyDescriptor(e38, t2)?.value); + if (n2 !== void 0) return `${t2} ${n2}`; + } + return Array.isArray(e38) ? `array` : `object`; +} +function Dh(e38, t2) { + throw Error(`${t2}: ${Eh(e38)}`); +} +var Oh = Ch.scale; +var kh2 = Ch.offsetPx; +var Ah2 = { open: Ch.durationMs, close: Ch.durationMs }; +var jh2 = Ch.easing; +function Mh2(e38) { + let [t2, n2] = e38.split(`-`); + switch (t2) { + case `top`: + case `right`: + case `bottom`: + case `left`: + return { side: t2, alignment: n2 === `start` || n2 === `end` ? n2 : void 0 }; + default: + throw Error(`Unsupported floating placement: ${e38}`); + } +} +function Nh2(e38) { + let { side: t2, alignment: n2 } = Mh2(e38); + switch (t2) { + case `top`: + return `${Rh2(n2)} bottom`; + case `right`: + return `left ${zh2(n2)}`; + case `bottom`: + return `${Rh2(n2)} top`; + case `left`: + return `right ${zh2(n2)}`; + default: + return Dh(t2, `Unsupported floating side`); } - applyThumbStyle() { - let e9 = this.state.getThumbSize(), t2 = this.state.getThumbPosition(); - this.horizontal ? (this.thumb.style.width = `${e9}px`, this.thumb.style.height = ``, this.thumb.style.transform = this.getThumbTransform(t2)) : (this.thumb.style.height = `${e9}px`, this.thumb.style.width = ``, this.thumb.style.transform = this.getThumbTransform(t2)); - let n2 = this.state.isScrollable(); - this.scrollbar.dataset.scrollable = n2 ? `true` : `false`, this.onScrollableChange !== void 0 && this.reportedScrollable !== n2 && (this.reportedScrollable = n2, this.onScrollableChange(n2)); +} +function Ph2(e38, t2 = {}) { + let { side: n2 } = Mh2(e38), r2 = t2.offset ?? kh2, i3 = t2.scale ?? Oh; + switch (n2) { + case `top`: + return `translate3d(0, ${r2}px, 0) scale(${i3})`; + case `right`: + return `translate3d(-${r2}px, 0, 0) scale(${i3})`; + case `bottom`: + return `translate3d(0, -${r2}px, 0) scale(${i3})`; + case `left`: + return `translate3d(${r2}px, 0, 0) scale(${i3})`; + default: + return Dh(n2, `Unsupported floating side`); } - attachPointerEvents() { - this.boundOnThumbDown = this.handleThumbDown.bind(this), this.boundOnTrackDown = this.handleTrackDown.bind(this), this.thumb.addEventListener(`pointerdown`, this.boundOnThumbDown), this.scrollbar.addEventListener(`pointerdown`, this.boundOnTrackDown); +} +function Fh2(e38, t2) { + return { opacity: 0, transform: Ph2(e38, t2) }; +} +function Ih2(e38) { + return { transformOrigin: Nh2(e38), transitionTimingFunction: jh2 }; +} +function Lh2({ closeDuration: e38 = Ah2.close, transform: t2, reducedMotion: n2 = false } = {}) { + return { duration: { open: Ah2.open, close: e38 }, initial: ({ placement: e39 }) => n2 ? { opacity: 0, transform: `none` } : Fh2(e39, t2), common: ({ placement: e39 }) => Ih2(e39) }; +} +function Rh2(e38) { + switch (e38) { + case `start`: + return `left`; + case `end`: + return `right`; + case void 0: + return `center`; + default: + return Dh(e38, `Unsupported floating alignment`); } - detachPointerEvents() { - this.boundOnThumbDown &&= (this.thumb.removeEventListener(`pointerdown`, this.boundOnThumbDown), null), this.boundOnTrackDown &&= (this.scrollbar.removeEventListener(`pointerdown`, this.boundOnTrackDown), null), this.dragCleanup?.(), this.dragCleanup = null; +} +function zh2(e38) { + switch (e38) { + case `start`: + return `top`; + case `end`: + return `bottom`; + case void 0: + return `center`; + default: + return Dh(e38, `Unsupported floating alignment`); } - handleThumbDown(e9) { - if (e9.button !== 0) return; - e9.preventDefault(); - let t2 = this.horizontal ? e9.clientX : e9.clientY, n2 = this.horizontal ? this.viewport.scrollLeft : this.viewport.scrollTop, r2 = e9.pointerId; - this.thumb.setPointerCapture(r2), this.thumb.classList.add(`ui-scroll-area__thumb--active`); - let i3 = (e10) => { - let r3 = (this.horizontal ? e10.clientX : e10.clientY) - t2, i4 = this.state.getScrollPositionFromThumbDelta(r3, n2); - this.horizontal ? this.viewport.scrollLeft = i4 : this.viewport.scrollTop = i4; - }, a3 = () => { - this.thumb.classList.remove(`ui-scroll-area__thumb--active`); - try { - this.thumb.releasePointerCapture(r2); - } catch { - } - this.thumb.removeEventListener(`pointermove`, i3), this.thumb.removeEventListener(`pointerup`, a3), this.thumb.removeEventListener(`pointercancel`, a3), this.dragCleanup = null; +} +var Bh2 = `data-ui-menu-item-region`; +var Vh2 = (0, Y2.createContext)(`body`); +function Hh2({ value: e38, children: t2 }) { + return Hh2.d = 2949884542, (0, J2.jsx)(Vh2.Provider, { value: e38, children: t2 }); +} +function Uh2() { + return (0, Y2.useContext)(Vh2); +} +var Wh2 = `[role="menuitem"]`; +var Gh2 = [`pointermove`, `mousemove`]; +function Kh2(e38) { + if (e38.key === `ArrowDown` || e38.key === `ArrowUp` || e38.key === `ArrowLeft` || e38.key === `ArrowRight` || e38.key === `Home` || e38.key === `End`) return true; + if (!e38.ctrlKey || e38.metaKey) return false; + let t2 = e38.key.toLowerCase(); + return t2 === `n` || t2 === `p` || t2 === `j` || t2 === `k`; +} +function qh2(e38, t2) { + if (!(e38 === void 0 || t2 === null || t2 < 0)) return `${e38}-item-${t2}`; +} +function Jh2(e38, t2) { + let n2 = qh2(e38, t2); + return n2 === void 0 ? {} : { id: n2 }; +} +function Yh2(e38) { + let { "aria-activedescendant": t2, ...n2 } = e38; + return n2; +} +function Xh(e38, t2) { + if (t2 == null) return null; + let n2 = e38.current[t2]; + return n2 instanceof HTMLElement2 ? n2 : null; +} +function Zh(e38, t2) { + let n2 = e38.current; + for (let e39 = 0; e39 < n2.length; e39++) if (n2[e39]?.getAttribute(`data-ui-menu-item-region`) === t2) return e39; + return null; +} +function Qh(e38, t2, n2) { + queueMicrotask(() => { + n2(Zh(e38, t2) ?? null); + }); +} +function $h(e38, t2) { + if (!(e38 instanceof Element2)) return null; + let n2 = e38.closest(Wh2); + if (!n2) return null; + let r2 = t2.current.indexOf(n2); + return r2 >= 0 ? r2 : null; +} +function eg(e38, t2) { + if (!e38) return () => { + }; + for (let n2 of Gh2) e38.addEventListener(n2, t2, { passive: true }); + return () => { + for (let n2 of Gh2) e38.removeEventListener(n2, t2); + }; +} +function tg({ event: e38, direction: t2, activeIndex: n2, listRef: r2, restoreFocus: i3 }) { + let a3 = Xh(r2, n2); + if (!a3) return false; + e38.preventDefault(), e38.stopPropagation(); + let o3 = document2.activeElement === e38.currentTarget; + return a3.focus(), a3.dispatchEvent(new KeyboardEvent2(`keydown`, { key: t2, bubbles: true, cancelable: true })), o3 && document2.activeElement === a3 && i3?.(), true; +} +function ng(e38, t2) { + return (0, Y2.useCallback)((n2) => { + let r2 = e38(n2); + if (t2) return r2; + let { onPointerLeave: i3, ...a3 } = r2; + return a3; + }, [e38, t2]); +} +function rg2() { + let [e38, t2] = (0, Y2.useState)(true); + return { focusItemOnHoverEnabled: e38, markKeyboardNavigation: (0, Y2.useCallback)(() => { + t2(false); + }, []), markPointerNavigation: (0, Y2.useCallback)(() => { + t2(true); + }, []), resetFocusItemOnHover: (0, Y2.useCallback)(() => { + t2(true); + }, []) }; +} +var ig = `--ui-menu-available-width`; +var ag = `--ui-menu-available-height`; +var og = /* @__PURE__ */ new Set([`none`, `auto`, `initial`, `inherit`, `unset`, `revert`, `revert-layer`, `min-content`, `max-content`, `fit-content`, `stretch`]); +function sg(e38) { + let t2 = `var(${ag}, 100vh)`; + return e38 == null || cg(e38) ? t2 : `min(${ug2(e38)}, ${t2})`; +} +function cg(e38) { + return typeof e38 == `string` && og.has(e38.trim().toLowerCase()); +} +var lg = `320px`; +function ug2(e38) { + return typeof e38 == `number` ? `${e38}px` : e38; +} +function dg(e38) { + return `min(${e38}, var(${ig}, 100vw))`; +} +function fg(e38) { + let { width: t2, minWidth: n2, maxWidth: r2, clampToAvailableWidth: i3 = false } = e38, a3 = t2 === void 0 && (n2 !== void 0 || r2 !== void 0) ? `max-content` : ug2(t2 ?? `200px`); + return i3 ? { width: a3 === `max-content` ? a3 : dg(a3), ...n2 != null && { minWidth: dg(ug2(n2)) }, maxWidth: dg(r2 == null ? lg : ug2(r2)) } : { width: a3, ...n2 != null && { minWidth: ug2(n2) }, ...r2 != null && { maxWidth: ug2(r2) } }; +} +function pg({ isOpen: e38, isPositioned: t2 }) { + return e38 && !t2 ? { opacity: 0 } : void 0; +} +function mg(e38, t2) { + (0, Y2.useLayoutEffect)(() => { + if (!e38) return; + let n2 = t2.current; + if (!(n2 instanceof HTMLElement2)) return; + let r2 = n2.closest(`[role="menu"]`); + if (r2 != null) return r2.style.pointerEvents = `none`, n2.style.pointerEvents = `auto`, () => { + r2.style.pointerEvents = ``, n2.style.pointerEvents = ``; }; - this.thumb.addEventListener(`pointermove`, i3), this.thumb.addEventListener(`pointerup`, a3), this.thumb.addEventListener(`pointercancel`, a3), this.dragCleanup = a3; + }, [e38, t2]); +} +function hg() { + return { name: `bottomAnchor`, fn({ y: e38, placement: t2, rects: n2, elements: r2 }) { + if (!t2.startsWith(`top`)) return {}; + let i3 = r2.floating.offsetParent, a3 = i3 === document2.body && window2.getComputedStyle(i3).position === `static`; + return { data: { bottom: (!i3 || i3 === document2.documentElement || a3 ? document2.documentElement.clientHeight || window2.innerHeight : i3.clientHeight) - e38 - n2.floating.height } }; + } }; +} +function gg(e38 = 200) { + let t2 = (0, Y2.useRef)(0); + return (0, Y2.useEffect)(() => { + let n2 = () => { + t2.current = Date.now() + e38; + }; + return window2.addEventListener(`focus`, n2), () => { + window2.removeEventListener(`focus`, n2); + }; + }, [e38]), (0, Y2.useCallback)((e39) => { + let n2 = e39.target, r2 = n2 instanceof Node2 ? n2.ownerDocument : document2, i3 = Date.now(), a3 = r2?.hasFocus() ?? document2.hasFocus(), o3 = i3 >= t2.current; + return a3 && o3; + }, []); +} +var _g = { open: 0, close: 0 }; +var vg = { opacity: 1, transform: `none` }; +var yg = (0, Y2.createContext)(null); +function bg(e38) { + let t2 = (0, Y2.useContext)(yg); + if (!t2) throw Error(`${e38} must be used within LegacyMenu`); + return t2; +} +function xg() { + return bg(`LegacyMenu.useContext`); +} +function Sg2({ children: e38, open: t2, defaultOpen: n2 = false, onOpenChange: r2, activeIndex: i3, onActiveIndexChange: a3, placement: o3 = `bottom-start`, offset: s3 = 4, flip: c3 = true, closeOnSelect: l5, instantClose: u3 = false, instantTransitions: d3 = false, returnFocusOnSelect: f4 = true, returnFocus: p4, focusItemOnOpen: m3 = false, virtualFocus: h4 = false, shouldKeepOpenDuringDrag: _5 = false, lockPositionWhileOpen: y4 = false, dismissOnReferenceScroll: b2 = false, enableClick: x2 = true, strategy: S2, shouldDismissOutsidePress: C2 }) { + Sg2.d = 3818803972; + let w2 = Af(), [E2, D2] = Pl(t2, n2, r2, `LegacyMenu.Root (open)`), [O2, A2] = (0, Y2.useState)(``), j2 = (0, Y2.useRef)(null), [M2, N3] = (0, Y2.useState)(false), [F2, I2] = (0, Y2.useState)(false), [R3, ee2] = Pl(i3, null, a3, `LegacyMenu.Root (activeIndex)`), { focusItemOnHoverEnabled: te2, markKeyboardNavigation: re3, markPointerNavigation: ae3, resetFocusItemOnHover: V3 } = rg2(), H3 = (0, Y2.useRef)([]), oe5 = (0, Y2.useRef)([]), se5 = (0, Y2.useRef)(null), ce6 = (0, Y2.useCallback)((e39) => { + D2(e39), e39 ? (A2(``), se5.current = null) : ee2(null), V3(); + }, [V3, D2, ee2]), ue6 = (0, Y2.useRef)(false); + (0, Y2.useLayoutEffect)(() => { + let e39 = ue6.current; + ue6.current = E2, !e39 && E2 && A2(``), e39 !== E2 && V3(); + }, [E2, V3]); + let { refs: fe5, floatingStyles: U3, middlewareData: pe5, context: W3, update: he5 } = jp({ nodeId: w2, open: E2, onOpenChange: ce6, placement: o3, strategy: S2, middleware: [ac(s3), ...c3 ? [cc()] : [], oc(), lc({ padding: 8, apply({ availableHeight: e39, elements: t3 }) { + t3.floating.style.setProperty(ag, `${Math.max(0, Math.floor(e39))}px`); + } }), hg()], whileElementsMounted: y4 ? void 0 : Hs, transform: false }), _e5 = Rf(W3, { enabled: F2, delay: { open: 75 }, handleClose: Qp({ blockPointerEvents: true, requireIntent: false }) }), ve5 = Tp(W3, { enabled: x2 && !F2 }), ye5 = gg(), be5 = (0, Y2.useCallback)((e39) => C2 !== void 0 && !C2(e39) || _5 && vh2.getInstance().hasData() ? false : ye5(e39), [C2, _5, ye5]), xe5 = kp(W3, { ancestorScroll: b2, outsidePressEvent: `click`, outsidePress: be5 }), Se5 = Hp(W3, { role: `menu` }), Ce5 = Bp(W3, { listRef: H3, activeIndex: R3, onNavigate: ee2, loop: false, virtual: h4 || M2, focusItemOnOpen: m3, focusItemOnHover: te2 }), we5 = Jp(W3, { listRef: oe5, activeIndex: R3, onMatch: M2 ? void 0 : ee2, enabled: !M2 }), { getReferenceProps: Te5, getFloatingProps: Ee5, getItemProps: De5 } = Np([_e5, ve5, xe5, Se5, Ce5, we5]), Oe5 = ng(De5, E2), ke5 = (0, Y2.useCallback)((e39) => ({ ...Yh2(Te5(e39)), ref: fe5.setReference, "aria-haspopup": `menu`, "aria-expanded": E2 }), [Te5, fe5.setReference, E2]), Ae5 = di2(), G2 = d3 ? { duration: _g, initial: vg } : Lh2({ reducedMotion: Ae5, ...u3 ? { closeDuration: 0 } : {} }), { isMounted: je5, styles: Me5 } = qp(W3, G2), Ne5 = (0, Y2.useMemo)(() => ({ isOpen: E2, isMounted: je5, setIsOpen: D2, activeIndex: R3, setActiveIndex: ee2, markKeyboardNavigation: re3, markPointerNavigation: ae3, virtualFocus: h4, searchValue: O2, setSearchValue: A2, hasSearchInput: M2, setHasSearchInput: N3, enableHover: F2, setHasHoverTrigger: I2, closeOnSelect: l5, returnFocusOnSelect: f4, returnFocus: p4, nodeId: w2, activeDescendantIdPrefix: M2 ? w2 : void 0, listRef: H3, labelsRef: oe5, searchInputRef: j2, refs: fe5, floatingStyles: U3, middlewareData: pe5, transitionStyles: Me5, context: W3, updateFloating: he5, getReferenceProps: Te5, getFloatingProps: Ee5, getItemProps: Oe5, getTriggerProps: ke5, dismissCauseRef: se5, shouldAllowPointerInteraction: be5 }), [E2, je5, D2, R3, ee2, re3, ae3, h4, O2, M2, F2, l5, f4, p4, w2, fe5, U3, pe5, Me5, W3, he5, Te5, Ee5, Oe5, ke5, be5]); + return (0, J2.jsx)(jf, { id: w2, children: (0, J2.jsx)(yg.Provider, { value: Ne5, children: e38 }) }); +} +function Dg(e38, t2) { + return (n2) => { + e38?.(n2), n2.defaultPrevented || t2(n2); + }; +} +function Og(e38, t2) { + switch (e38) { + case `ArrowLeft`: + return t2 === `rtl` ? `end` : `start`; + case `ArrowRight`: + return t2 === `rtl` ? `start` : `end`; + default: + return null; } - handleTrackDown(e9) { - if (e9.button !== 0 || e9.target === this.thumb) return; - let t2 = this.scrollbar.getBoundingClientRect(); - if (!this.horizontal) { - this.viewport.scrollTop = this.state.getScrollPositionFromTrackOffset(e9.clientY - t2.top - this.thumbInsetStart); +} +var kg = (0, Y2.createContext)(null); +function Ag() { + return (0, Y2.useContext)(kg); +} +var jg = (0, Y2.createContext)(`copy-with-plain-text`); +function Mg() { + return (0, Y2.useContext)(jg); +} +var Ng = `application/x-cursor-draggable`; +var Pg = Bg({ className: `ui-i9pz9s` }.className); +var Fg = `data-no-drag`; +var Ig = false; +var Lg = false; +var Rg = null; +function zg() { + return Rg ??= Object.assign(new Image(1, 1), { src: `data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==` }), Rg; +} +function Bg(e38) { + return e38?.split(/\s+/).filter(Boolean) ?? []; +} +function Vg(e38, t2, n2) { + for (let r2 of t2) e38.classList.toggle(r2, n2); +} +function Hg() { + if (Lg || typeof document2 > `u`) return; + Lg = true, document2.addEventListener(`pointerdown`, (e39) => { + if (e39.button !== 0 || !(e39.target instanceof Element2)) { + Ig = false; return; } - let n2 = getComputedStyle2(this.viewport).direction === `rtl`, r2 = n2 ? t2.right - e9.clientX : e9.clientX - t2.left, i3 = this.state.getScrollPositionFromTrackOffset(r2); - this.viewport.scrollLeft = n2 ? -i3 : i3; - } - attachWheelForwarding() { - this.boundOnWheel = (t2) => { - if (this.horizontal) { - let n2 = this.viewport.scrollWidth - this.viewport.clientWidth; - if (n2 <= 0) return; - let r2 = null; - if (this.mapVerticalWheelToHorizontal) r2 = zs({ deltaX: t2.deltaX, deltaY: t2.deltaY, mapVerticalWheelToHorizontal: true, mappedBehavior: `prefer-horizontal` }); - else { - if (this.horizontalWheelAxisLock ||= Math.abs(t2.deltaX) > Math.abs(t2.deltaY) ? `x` : `y`, this.horizontalWheelResetTimer && clearTimeout(this.horizontalWheelResetTimer), this.horizontalWheelResetTimer = setTimeout(() => { - this.horizontalWheelAxisLock = null, this.horizontalWheelResetTimer = null; - }, e6.WHEEL_GESTURE_RESET_MS), this.horizontalWheelAxisLock !== `x`) return; - if (r2 = zs({ deltaX: t2.deltaX, deltaY: t2.deltaY, mapVerticalWheelToHorizontal: false, axisBehavior: `raw` }), r2 === null) { - t2.preventDefault(), t2.stopPropagation(); - return; - } - } - if (r2 === null) return; - let i3 = Math.max(0, Math.min(n2, this.viewport.scrollLeft + r2)); - this.viewport.scrollLeft = i3, t2.preventDefault(), t2.stopPropagation(); - } else this.viewport.scrollTop += t2.deltaY; - }, this.scrollbar.addEventListener(`wheel`, this.boundOnWheel, { passive: false }); - } - detachWheelForwarding() { - this.boundOnWheel &&= (this.scrollbar.removeEventListener(`wheel`, this.boundOnWheel), null); - } - getThumbTransform(e9) { - return this.horizontal ? `translateX(${e9}px)` : `translateY(${e9 + this.thumbInsetStart}px)`; - } - getThumbInsetStart() { - if (this.horizontal) return 0; - let t2 = getComputedStyle2(this.scrollbar).getPropertyValue(e6.VERTICAL_THUMB_OFFSET_CSS_VAR), n2 = Number.parseFloat(t2); - return Number.isFinite(n2) ? Math.max(0, n2) : 0; - } -}; -var Ys = { base: { "--scrollbar-size": `ui-1ekbvf6`, "--scrollbar-inset": `ui-1logqu4`, "--scrollbar-thumb-top-offset": `ui-1fx8caa`, "--scroll-area-scroll-padding": `ui-8ddqcf`, kVAEAm: `ui-1n2onr6`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, k1xSpc: `ui-rvj5dj`, k52YG4: `ui-ypqxfk`, $$css: true } }; -var Xs = { base: { kJuA4N: `ui-175mniq`, kAzted: `ui-2lwn1j`, kskxy: `ui-mz0i5r`, kaIpWk: `ui-1pjcqnp`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-1odjw0f`, kaPefq: `ui-1fu52t7`, kC2sXz: `ui-1ufbpdf`, k9lH4S: `ui-3oazx1`, kphCe6: `ui-19l4kpp`, kvh3hx: `ui-1t1jukp`, kacamN: `ui-1e4zzel`, k5wCbM: `ui-1rohswg`, kAnDOJ: `ui-6ehuon`, kOuLrU: `ui-fk6m8`, $$css: true }, horizontal: { kXHlph: `ui-w2csxc`, kORKVm: `ui-10wlt62`, kaPefq: `ui-k8sdt9`, kC2sXz: `ui-1duton`, k9lH4S: `ui-101ixbw`, kphCe6: `ui-exgr1p`, kvh3hx: `ui-7p5m3t`, kacamN: `ui-y5w88m`, $$css: true }, both: { kXHlph: `ui-w2csxc`, kORKVm: `ui-1odjw0f`, kaPefq: `ui-k8sdt9`, kC2sXz: `ui-1duton`, k9lH4S: `ui-101ixbw`, kphCe6: `ui-exgr1p`, kZeWKH: `ui-ish69e`, $$css: true } }; -var Zs = { base: { kB7OPa: `ui-9f619`, kzqmXN: `ui-eq5yr9`, k7Eaqz: `ui-gqtt45`, ks0D6T: `ui-193iq5w`, kAzted: `ui-1us19tq`, k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, $$css: true }, horizontal: { kzqmXN: `ui-14atkfc`, kZKoxP: `ui-g7h5cd`, kXwgrk: `ui-1q0g3np`, $$css: true }, both: { kzqmXN: `ui-ezivpi`, k7Eaqz: `ui-gqtt45`, ks0D6T: `ui-1x1rfll`, kZKoxP: `ui-t7dq6l`, kXwgrk: `ui-dt5ytf`, $$css: true }, reserveScrollbarSpace: { kwRFfy: `ui-w77ms1`, $$css: true } }; -var Qs = { base: { kVAEAm: `ui-10l6tqk`, kY2c9j: `ui-1n327nk`, k87sOh: `ui-16271f3`, kt4wiu: `ui-1cdd6y0`, krVfgx: `ui-1c87l4o`, kLqNvP: `ui-hi6v0a`, kzqmXN: `ui-790ffn`, kfzvcC: `ui-67bb7w`, k1xSpc: `ui-1lliihq ui-y36ywk`, $$css: true }, horizontal: { k87sOh: `ui-80663w`, kt4wiu: `ui-1cdd6y0`, krVfgx: `ui-1gncbth`, kLqNvP: `ui-pl0nw1`, kzqmXN: `ui-14atkfc`, kZKoxP: `ui-a38mao`, $$css: true }, bothVertical: { krVfgx: `ui-1143y87`, $$css: true }, bothHorizontal: { kt4wiu: `ui-13kbk1n`, $$css: true }, visibilityNever: { k1xSpc: `ui-1s85apg`, $$css: true } }; -var $s = { base: { kVAEAm: `ui-10l6tqk`, k87sOh: `ui-13vifvy`, kt4wiu: `ui-tijo5x`, krVfgx: `ui-dd4er5`, kLqNvP: `ui-1o0tod`, kAzted: `ui-4jlmx6`, kzqmXN: `ui-790ffn`, kaIpWk: `ui-1i4c3av`, kWkggS: `ui-1m4ooaa ui-1kik0b9 ui-19p5jqy ui-gk890x`, kSiTet: `ui-1hc1fzr`, kfzvcC: `ui-67bb7w`, k3aq6I: `ui-oww4n8`, k1ekBW: `ui-1e8aii2`, kIyJzY: `ui-1vaoic9 ui-ykozbk`, kAMwcw: `ui-1aiz5cx`, $$css: true }, horizontal: { k87sOh: `ui-13vifvy`, kt4wiu: `ui-1woyocn`, krVfgx: `ui-1ey2m1c`, kLqNvP: `ui-1o0tod`, kzqmXN: `ui-14atkfc`, kZKoxP: `ui-a38mao`, kAzted: `ui-65nank`, k7Eaqz: `ui-cbmsab`, $$css: true }, hoverHidden: { kSiTet: `ui-g01cxk ui-4gyw5p ui-gorybd`, $$css: true } }; -function ec() { - return Ys.base; -} -function tc({ direction: e9 }) { - return [Xs.base, e9 === `horizontal` ? Xs.horizontal : null, e9 === `both` ? Xs.both : null]; -} -function nc(e9, t2 = false) { - return [Zs.base, e9 === `horizontal` ? Zs.horizontal : null, e9 === `both` ? Zs.both : null, t2 ? Zs.reserveScrollbarSpace : null]; -} -function rc({ direction: e9, orientation: t2, visibility: n2 }) { - return [Qs.base, t2 === `horizontal` ? Qs.horizontal : null, e9 === `both` && t2 === `vertical` ? Qs.bothVertical : null, e9 === `both` && t2 === `horizontal` ? Qs.bothHorizontal : null, n2 === `never` ? Qs.visibilityNever : null]; -} -function ic(e9, t2) { - return [$s.base, e9 === `horizontal` ? $s.horizontal : null, t2 ? $s.hoverHidden : null]; -} -function ac(e9, t2) { - t2 ? e9.dataset.scrollbarGutter = `reserved` : delete e9.dataset.scrollbarGutter; -} -var oc = 1e4; -var sc = 5; -var cc = (0, J2.forwardRef)(function e7({ children: t2, height: n2, maxHeight: r2, width: i3, className: a3, viewportClassName: o3, viewportTabIndex: s3, viewportId: c2, viewportRole: l4, viewportAriaLabel: u3, rootStyle: d3, viewportStyle: f4, allowScrollChaining: p4 = false, contentStyle: m3, scrollbarStyle: h3, overlay: g3, style: _2, scrollbarVisibility: v3 = Bs, isScrollbarRevealed: y3 = false, direction: b3 = `vertical`, topFadeSize: x3, bottomFadeSize: S3, topFadeStartOpacity: C2 = 0, bottomFadeStartOpacity: w3 = 0, startFadeSize: T3, endFadeSize: E3, autoScrollToBottom: D2 = false, scrollTrigger: O3, autoScrollPauseTimeout: k4 = oc, onScrollStateChange: A3, mapVerticalWheelToHorizontal: j3 = false, scrollPadding: M3 = 4, scrollbarInset: N2, reserveScrollbarSpace: P2 = false, onPointerEnter: F2, onPointerLeave: I, ...L }, R3) { - e7.d = 3647458370; - let ee2 = (0, J2.useRef)(null), z4 = (0, J2.useRef)(null), B4 = (0, J2.useRef)(null), te3 = (0, J2.useRef)(null), ne3 = (0, J2.useRef)(null), re4 = (0, J2.useRef)(null), ie4 = (0, J2.useRef)(null), ae4 = b3 !== `horizontal`, V4 = b3 !== `vertical`, H4 = P2 && ae4 && v3 !== `never`, oe5 = j3 && !ae4, se5 = x3 !== void 0 || S3 !== void 0, ce5 = T3 !== void 0 || E3 !== void 0, le4 = se5 || ce5, ue4 = (0, J2.useRef)(false), de5 = (0, J2.useRef)(0), W4 = (0, J2.useRef)(0), fe5 = (0, J2.useRef)(null), pe5 = (0, J2.useRef)(null); - (0, J2.useLayoutEffect)(() => { - let e9 = z4.current, t3 = B4.current; - if (!e9 || !t3) return; - let n3 = [], r3 = { top: false, bottom: false, start: false, end: false }, i4 = { block: se5, inline: ce5 }; - if (ae4) { - let a4 = te3.current, o4 = ne3.current; - a4 && o4 && n3.push(new Js({ viewport: e9, content: t3, scrollbar: a4, thumb: o4, direction: `vertical`, mapVerticalWheelToHorizontal: oe5, onFadeEdgesChange: se5 ? (t4, n4) => { - r3.top = t4, r3.bottom = n4, Ws(e9, r3, i4); - } : void 0, onScrollableChange: H4 ? (e10) => ac(t3, e10) : void 0 })); - } - if (V4) { - let a4 = re4.current, o4 = ie4.current; - a4 && o4 && n3.push(new Js({ viewport: e9, content: t3, scrollbar: a4, thumb: o4, direction: `horizontal`, mapVerticalWheelToHorizontal: oe5, onFadeEdgesChange: ce5 ? (t4, n4) => { - r3.start = t4, r3.end = n4, Ws(e9, r3, i4); - } : void 0 })); + Ig = e39.target.closest(`[${Fg}]`) !== null; + }, { capture: true }); + let e38 = () => { + Ig = false; + }; + document2.addEventListener(`pointerup`, e38, { capture: true }), document2.addEventListener(`pointercancel`, e38, { capture: true }); +} +function Ug({ id: e38, data: t2, disabled: n2 = false, dragImageOffset: r2, hideNativeDragImage: i3 = false, onDragStart: a3, onDragEnd: o3 }) { + let s3 = Ag(), c3 = Mg(), l5 = (0, Y2.useRef)(null), u3 = (0, Y2.useRef)({ onDragStart: a3, onDragEnd: o3 }); + u3.current = { onDragStart: a3, onDragEnd: o3 }; + let d3 = (0, Y2.useRef)(t2); + d3.current = t2; + let f4 = (0, Y2.useRef)(r2); + f4.current = r2; + let p4 = (0, Y2.useRef)(i3); + p4.current = i3, (0, Y2.useEffect)(() => { + i3 && zg(); + }, [i3]); + let m3 = (0, Y2.useRef)(s3); + m3.current = s3; + let h4 = s3?.activeDragId === e38, g5 = (0, Y2.useRef)(h4); + return g5.current = h4, (0, Y2.useEffect)(() => { + let e39 = l5.current; + if (e39) return Vg(e39, Pg, !n2 && h4), () => { + Vg(e39, Pg, false); + }; + }, [n2, h4]), (0, Y2.useEffect)(() => { + let e39 = l5.current; + if (!e39) return; + if (n2) { + e39.removeAttribute(`aria-grabbed`); + return; } - if (n3.length !== 0) { - for (let e10 of n3) e10.attach(); - return () => { - for (let e10 of n3) e10.detach(); - ac(t3, false), Ws(e9, { top: false, bottom: false, start: false, end: false }, i4); + let t3 = h4 ? `true` : `false`; + e39.getAttribute(`aria-grabbed`) !== t3 && e39.setAttribute(`aria-grabbed`, t3); + }, [n2, h4]), { ref: (0, Y2.useCallback)((t3) => { + if (l5.current = t3, !t3) return; + Vg(t3, Pg, !n2 && g5.current); + let r3 = !n2; + if (t3.draggable !== r3 && (t3.draggable = r3), n2) return; + Hg(); + let i4 = vh2.getInstance(), a4 = (n3) => { + if (Ig) { + Ig = false, n3.preventDefault(), n3.stopPropagation(); + return; + } + let r4 = d3.current; + i4.setData(r4); + let a5 = t3.ownerDocument, o5 = () => { + a5.removeEventListener(`dragend`, o5, true), a5.removeEventListener(`drop`, o5, true), a5.removeEventListener(`mousemove`, o5, true), setTimeout(() => { + i4.getData() === r4 && (i4.clearData(), Ig = false, m3.current?.setDragging(null, null)); + }, 0); }; - } - }, [ae4, V4, oe5, se5, ce5, H4]); - let me5 = (0, J2.useCallback)(() => { - let e9 = z4.current; - return e9 ? { scrollTop: e9.scrollTop, scrollHeight: e9.scrollHeight, clientHeight: e9.clientHeight } : { scrollTop: 0, scrollHeight: 0, clientHeight: 0 }; - }, []), he5 = (0, J2.useCallback)((e9 = false) => { - let t3 = z4.current; - t3 && t3.scrollTo({ top: t3.scrollHeight, behavior: e9 ? `smooth` : `instant` }); - }, []), ge4 = (0, J2.useCallback)((e9 = false) => { - let t3 = z4.current; - t3 && t3.scrollTo({ top: 0, behavior: e9 ? `smooth` : `instant` }); - }, []), _e4 = (0, J2.useCallback)(() => { - pe5.current === null && (pe5.current = requestAnimationFrame2(() => { - pe5.current = null, !ue4.current && he5(false); - })); - }, [he5]), ve4 = (0, J2.useCallback)(() => { - D2 && (ue4.current || _e4()); - }, [D2, _e4]); - (0, J2.useImperativeHandle)(R3, () => ({ scrollToBottom: he5, scrollToTop: ge4, requestAutoScroll: ve4, getScrollPosition: me5, get rootElement() { - return ee2.current; - }, get viewportElement() { - return z4.current; - } }), [he5, ge4, ve4, me5]); - let ye4 = D2 || A3 !== void 0, be4 = (0, J2.useEffectEvent)(() => { - let e9 = z4.current; - if (!e9) return; - let { scrollTop: t3, scrollHeight: n3, clientHeight: r3 } = e9, { isAtTop: i4, isAtBottom: a4 } = Vs({ scrollTop: t3, scrollHeight: n3, clientHeight: r3, threshold: sc }); - A3?.({ isAtBottom: a4, isAtTop: i4 }), a4 && ue4.current && (ue4.current = false, fe5.current &&= (clearTimeout(fe5.current), null)); - let o4 = n3 < W4.current - sc, s4 = n3 > W4.current + sc, c3 = t3 < de5.current - sc; - c3 && !o4 && !a4 && D2 && !ue4.current && (ue4.current = true, fe5.current && clearTimeout(fe5.current), fe5.current = setTimeout(() => { - ue4.current = false, fe5.current = null; - }, k4)), s4 && D2 && !ue4.current && !a4 && !c3 && _e4(), o4 && D2 && !ue4.current && !a4 && _e4(), de5.current = t3, W4.current = n3; - }), xe4 = Ls(); - (0, J2.useEffect)(() => { - if (!ye4) return; - let e9 = z4.current, t3 = B4.current; - if (!e9) return; - let n3 = () => { - xe4.request(() => be4()); - }; - e9.addEventListener(`scroll`, n3, { passive: true }); - let r3 = Rs(() => be4()); - return r3 !== null && (r3.observe(e9), t3 && r3.observe(t3)), () => { - e9.removeEventListener(`scroll`, n3), r3?.disconnect(), xe4.dispose(); + if (a5.addEventListener(`dragend`, o5, true), a5.addEventListener(`drop`, o5, true), a5.addEventListener(`mousemove`, o5, true), n3.dataTransfer) { + let e39 = c3 === `copy-with-plain-text`; + n3.dataTransfer.effectAllowed = e39 ? `copyMove` : `move`, n3.dataTransfer.setData(Ng, r4.type), e39 && n3.dataTransfer.setData(`text/plain`, r4.type); + let i5 = f4.current; + p4.current ? n3.dataTransfer.setDragImage(zg(), 0, 0) : i5 && n3.dataTransfer.setDragImage(t3, i5.x, i5.y); + } + m3.current?.setDragging(e38, r4, { x: n3.clientX, y: n3.clientY }), u3.current.onDragStart?.(n3); + }, o4 = (e39) => { + i4.clearData(), Ig = false, m3.current?.setDragging(null, null), u3.current.onDragEnd?.(e39); }; - }, [ye4, xe4]), (0, J2.useEffect)(() => { - O3 !== void 0 && D2 && (ue4.current || _e4()); - }, [O3, D2, _e4]), (0, J2.useEffect)(() => { - if (!ae4) return; - let e9 = z4.current; - if (!e9) return; - let t3 = (t4) => { - let n3 = t4.deltaY; - if (n3 === 0) return; - let r3 = e9.scrollHeight - e9.clientHeight; - if (r3 <= 0) return; - let i4 = e9.scrollTop, a4 = i4 <= 0 && n3 < 0, o4 = i4 >= r3 - 0.5 && n3 > 0; - a4 || o4 || t4.stopPropagation(); + return t3.addEventListener(`dragstart`, a4), t3.addEventListener(`dragend`, o4), () => { + t3.removeEventListener(`dragstart`, a4), t3.removeEventListener(`dragend`, o4), Vg(t3, Pg, false); }; - return e9.addEventListener(`wheel`, t3, { passive: true }), () => e9.removeEventListener(`wheel`, t3); - }, [ae4]), (0, J2.useEffect)(() => { - if (!V4) return; - let e9 = z4.current; - if (!e9) return; - let t3 = (t4) => { - let n4 = zs({ deltaX: t4.deltaX, deltaY: t4.deltaY, mapVerticalWheelToHorizontal: oe5 }); - if (n4 === null) return; - let r3 = e9.scrollWidth - e9.clientWidth; - if (r3 <= 0) return; - let i4 = e9.scrollLeft; - if (!(n4 < 0 && i4 <= 0) && !(n4 > 0 && i4 >= r3 - 0.5)) { - if (!oe5) { - t4.stopPropagation(); - return; - } - t4.preventDefault(), e9.scrollLeft = i4 + n4; - } - }, n3 = oe5 ? { passive: false, capture: true } : { passive: true, capture: true }; - return e9.addEventListener(`wheel`, t3, n3), () => e9.removeEventListener(`wheel`, t3, n3); - }, [V4, oe5]); - let Se4 = v3 === `hover`, [Ce4, we4] = (0, J2.useState)(false); - (0, J2.useLayoutEffect)(() => { - Se4 && we4(ee2.current?.matches(`:hover`) ?? false); - }, [Se4]); - let Te3 = (0, J2.useCallback)((e9) => { - we4(true), F2?.(e9); - }, [F2]), Ee4 = (0, J2.useCallback)((e9) => { - we4(false), I?.(e9); - }, [I]), De4 = Se4 && !Ce4 && !y3; - (0, J2.useEffect)(() => () => { - fe5.current && clearTimeout(fe5.current), pe5.current !== null && (cancelAnimationFrame2(pe5.current), pe5.current = null); - }, []); - let Oe4 = { "--scroll-area-scroll-padding": `${M3}px`, ...N2 === void 0 ? void 0 : { "--scrollbar-inset": `${N2}px` } }, ke4 = K2({ rootClass: `ui-scroll-area`, stylexStyles: [ec(), d3], className: G3(le4 && `ui-scroll-area--masked`, a3), style: { height: n2, maxHeight: r2, width: i3, ...Oe4, ..._2 } }), Ae4 = K2({ rootClass: `ui-scroll-area__viewport`, stylexStyles: [tc({ direction: b3 }), f4], className: o3, style: { ...Gs({ block: se5 ? { topPx: x3 ?? 24, bottomPx: S3 ?? 24, topStartOpacity: C2, bottomStartOpacity: w3 } : void 0, inline: ce5 ? { startPx: T3 ?? 24, endPx: E3 ?? 24 } : void 0 }), ...p4 ? { overscrollBehavior: `auto` } : void 0 } }), je4 = K2({ rootClass: `ui-scroll-area__content`, stylexStyles: [nc(b3, H4), m3] }), Me3 = K2({ rootClass: `ui-scroll-area__scrollbar`, stylexStyles: [rc({ direction: b3, orientation: `vertical`, visibility: v3 }), h3] }), Ne3 = h(ic(`vertical`, De4)), Pe3 = K2({ rootClass: `ui-scroll-area__scrollbar`, stylexStyles: [rc({ direction: b3, orientation: `horizontal`, visibility: v3 }), h3] }), Fe4 = h(ic(`horizontal`, De4)); - return (0, q2.jsxs)(`div`, { ref: ee2, className: ke4.className, style: ke4.style, "data-scroll-padding": M3, "data-visibility": v3, "data-direction": b3, ...L, onPointerEnter: Se4 ? Te3 : F2, onPointerLeave: Se4 ? Ee4 : I, children: [(0, q2.jsx)(`div`, { ref: z4, className: Ae4.className, style: Ae4.style, "data-native-scrollbar": `none`, id: c2, role: l4, "aria-label": u3, tabIndex: s3, children: (0, q2.jsx)(`div`, { ref: B4, className: je4.className, style: je4.style, children: t2 }) }), g3, ae4 && (0, q2.jsx)(`div`, { ref: te3, className: Me3.className, style: Me3.style, "data-orientation": `vertical`, "data-scrollable": `false`, role: `presentation`, "aria-hidden": `true`, children: (0, q2.jsx)(`div`, { ref: ne3, className: Ne3.className, style: Ne3.style, "data-orientation": `vertical` }) }), V4 && (0, q2.jsx)(`div`, { ref: re4, className: Pe3.className, style: Pe3.style, "data-orientation": `horizontal`, "data-scrollable": `false`, role: `presentation`, "aria-hidden": `true`, children: (0, q2.jsx)(`div`, { ref: ie4, className: Fe4.className, style: Fe4.style, "data-orientation": `horizontal` }) })] }); -}); -var Vd = { base: { kMv6JI: `ui-1acoasx`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, $$css: true }, sizeInherit: { kGuDYH: `ui-1qlqyl8`, kLWn49: `ui-15bjb6t`, kb6lSQ: `ui-4gjf66`, $$css: true }, variantCode: { kMv6JI: `ui-mpsg8l`, $$css: true }, weightRegular: { k63SB2: `ui-vxqr21`, $$css: true }, weightMedium: { k63SB2: `ui-h4fh7u`, $$css: true }, weightSemibold: { k63SB2: `ui-1hohiyz`, $$css: true }, weightBold: { k63SB2: `ui-1y2bmg9`, $$css: true }, colorPrimary: { kMwMTN: `ui-1wd3ewq`, $$css: true }, colorSecondary: { kMwMTN: `ui-19aaqeu`, $$css: true }, colorTertiary: { kMwMTN: `ui-4b2ntj`, $$css: true }, colorQuaternary: { kMwMTN: `ui-1e4uaio`, $$css: true }, colorActive: { kMwMTN: `ui-7qsbfx`, $$css: true }, colorFocused: { kMwMTN: `ui-zlszhr`, $$css: true }, colorRed: { kMwMTN: `ui-1jh5svw`, $$css: true }, colorRedSecondary: { kMwMTN: `ui-o7cye4`, $$css: true }, colorYellow: { kMwMTN: `ui-1izesbo`, $$css: true }, colorYellowSecondary: { kMwMTN: `ui-14nh9a`, $$css: true }, colorGreen: { kMwMTN: `ui-1w5rjie`, $$css: true }, colorGreenSecondary: { kMwMTN: `ui-dki84f`, $$css: true }, colorMagenta: { kMwMTN: `ui-xjecij`, $$css: true }, colorMagentaSecondary: { kMwMTN: `ui-29qggb`, $$css: true }, colorCyan: { kMwMTN: `ui-1d0l12`, $$css: true }, colorCyanSecondary: { kMwMTN: `ui-l34bp`, $$css: true }, colorOrange: { kMwMTN: `ui-11pqmr`, $$css: true }, colorOrangeSecondary: { kMwMTN: `ui-11nfuof`, $$css: true }, numeric: { kcqcaj: `ui-ss6m8b`, $$css: true }, truncateStart: { k1xSpc: `ui-1lliihq`, kzqmXN: `ui-h8yej3`, k7Eaqz: `ui-euugli`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kg5iWk: `ui-lyipyv`, k8aIck: `ui-jlip5`, kqG3fB: `ui-kyw5k8`, ksoyAI: `ui-zyj77d`, k9WMMc: `ui-dpxx8g`, $$css: true } }; -var Hd = { xs: ca.root, sm: la.root, md: ua2.root, lg: da2.root, xl: fa2.root, "2xl": pa2.root, "3xl": ma.root, inherit: Vd.sizeInherit }; -var Ud = { regular: Vd.weightRegular, medium: Vd.weightMedium, semibold: Vd.weightSemibold, bold: Vd.weightBold }; -var Wd = { primary: Vd.colorPrimary, secondary: Vd.colorSecondary, tertiary: Vd.colorTertiary, quaternary: Vd.colorQuaternary, active: Vd.colorActive, focused: Vd.colorFocused, red: Vd.colorRed, "red-secondary": Vd.colorRedSecondary, yellow: Vd.colorYellow, "yellow-secondary": Vd.colorYellowSecondary, green: Vd.colorGreen, "green-secondary": Vd.colorGreenSecondary, magenta: Vd.colorMagenta, "magenta-secondary": Vd.colorMagentaSecondary, cyan: Vd.colorCyan, "cyan-secondary": Vd.colorCyanSecondary, orange: Vd.colorOrange, "orange-secondary": Vd.colorOrangeSecondary }; -function Gd({ color: e9, numeric: t2, size: n2, truncate: r2, variant: i3, weight: a3 }) { - return [Vd.base, ga.root, Hd[n2], Ud[a3], i3 === `code` ? Vd.variantCode : null, e9 ? Wd[e9] : null, t2 ? Vd.numeric : null, r2 === `start` ? Vd.truncateStart : null, r2 === `end` ? ha.root : null]; + }, [e38, n2, c3]), isDragging: h4 }; } -function Kd({ as: e9 = `span`, variant: t2 = `default`, size: n2 = `md`, weight: r2 = `regular`, color: i3, truncate: a3, numeric: o3, children: s3, rootStyle: c2, className: l4, style: u3, ref: d3, ...f4 }) { - Kd.d = 3219036596; - let p4 = a3 === true ? `end` : a3 === false ? void 0 : a3 ?? void 0, { className: m3, style: h3 } = h(Gd({ color: i3, numeric: o3, size: n2, truncate: p4, variant: t2, weight: r2 }), c2); - return (0, q2.jsx)(e9, { ref: d3, className: G3(`ui-text`, m3, l4), style: { ...h3, ...u3 }, "data-variant": t2, "data-size": n2, "data-weight": r2, "data-color": i3, "data-truncate": p4, "data-numeric": o3 || void 0, ...f4, children: p4 === `start` ? (0, q2.jsxs)(q2.Fragment, { children: [`\u2066`, s3, `\u2069`] }) : s3 }); +var Wg = { base: { "--ui-menu-row-padding-block": `ui-kd6fbz`, "--ui-menu-row-padding-inline": `ui-1ucplye`, "--ui-menu-row-gap": `ui-1fi38xd`, "--ui-menu-row-border-radius": `ui-s7jddj`, "--ui-menu-item-left-width": `ui-1bm229x`, "--ui-menu-item-left-height": `ui-1eaezr9`, "--ui-menu-search-row-padding-top": `ui-so2ig8`, "--ui-menu-section-title-padding-inline": `ui-e020nh`, kMeerF: `ui-1k57tk5`, k3XXqK: `ui-1t137rt`, kInvED: `ui-1wfwxd8`, kjBf7l: `ui-1uczgqu`, kY2c9j: `ui-fc2p8`, kVAEAm: `ui-1n2onr6`, kGVxlE: `ui-1gnnqk1`, k7Eaqz: `ui-1i9suas`, ks0D6T: `ui-1va8c73`, kfSwDN: `ui-87ps6o`, kY4cRS: `ui-lvsv26`, k6sLGO: `ui-1q1rmc8`, k3aq6I: `ui-17dzmu4`, kgyCeQ: `ui-lp1x4z`, kdrBUz: `ui-7iibnf`, kHBbk8: `ui-c8icb0`, ktR8K2: `ui-awy1a7`, kgeoSG: `ui-1cpjm7i`, kEoFBp: `ui-1hmns74`, kFcpXp: `ui-xx281p`, kPB484: `ui-xyica1`, ktNmms: `ui-wfqmlb`, km8f2m: `ui-kk1bqk`, k5JduY: `ui-1s928wv`, kwXMNM: `ui-1j6awrg`, kv0HGH: `ui-arstr8`, kDVEDD: `ui-itxdhh`, kUfP38: `ui-1k48kgn`, kbMawA: `ui-1o7vem3`, kloYau: `ui-2q1x1w`, $$css: true }, sizeMd: { "--ui-menu-row-padding-block": `ui-1jjxvf6`, "--ui-menu-row-padding-inline": `ui-18k90n9`, "--ui-menu-row-gap": `ui-vzyzmz`, "--ui-menu-item-left-width": `ui-eurstk`, "--ui-menu-item-left-height": `ui-1eaezr9`, "--ui-menu-search-row-padding-top": `ui-14atyw8`, "--ui-menu-section-title-padding-inline": `ui-mhevzc`, kaIpWk: `ui-1pkpdue`, $$css: true }, hasAttachment: { kWkggS: `ui-jbqb8w`, k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, khm7nJ: `ui-3r2rup`, kP1sEF: `ui-15ozc13`, kc3QkE: `ui-1h1zc6f`, $$css: true }, dropIndicator: { kMeerF: `ui-1qgsegg`, k3XXqK: `ui-aatb59`, kjBf7l: `ui-pkz39j`, kInvED: `ui-1jn6s22`, k5JduY: `ui-1s928wv`, kwXMNM: `ui-1j6awrg`, kc1e00: `ui-cfinr5`, kH8aOt: `ui-14idyls`, k3foIR: `ui-17mrvg7`, k4zj60: `ui-1d1o5dh`, ks3ayO: `ui-1ssvodr`, kUfP38: `ui-gad8h8`, kloYau: `ui-2q1x1w`, kDVEDD: `ui-itxdhh`, $$css: true } }; +var Gg = { base: { kVAEAm: `ui-ixxii4`, kpwlN0: `ui-10a8y8t`, kY2c9j: `ui-cfsmg2`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, kLZC3w: `ui-1b4hy2t`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kBCPoo: `ui-1273586`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, kL6WhQ: `ui-1tnzt7h`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kGJrpR: `ui-1mi4oqr`, kysU6D: `ui-jyslct`, kkrTdU: `ui-t0e3qv`, kWkggS: `ui-jbqb8w`, kY4cRS: `ui-lvsv26`, $$css: true } }; +var Kg = { dropIndicatorSlot: { k1xSpc: `ui-jp7ctv`, kfzvcC: `ui-47corl`, $$css: true }, inner: { kLKAdn: `ui-12ryuzz`, kwRFfy: `ui-opxd5p`, kGO01o: `ui-ftabeb`, kZCmMZ: `ui-1bpcb8s`, k2VNRW: `ui-1aj3mmm`, $$css: true }, layout: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kAzted: `ui-2lwn1j`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, $$css: true }, bodyScroll: { kzQI83: `ui-1iyjqo2`, kmuXW: `ui-s83m0k`, kCS8Yb: `ui-dl72j9`, kAzted: `ui-2lwn1j`, $$css: true }, header: { kLKAdn: `ui-f6zju3`, kwRFfy: `ui-1tlft3r`, kGO01o: `ui-cnij5n`, kZCmMZ: `ui-tw3t59`, kt9PQ7: `ui-so031l`, kfdmCh: `ui-1q0q8m5`, kL6WhQ: `ui-17fyfba`, $$css: true }, footer: { kLKAdn: `ui-f6zju3`, kwRFfy: `ui-1tlft3r`, kGO01o: `ui-cnij5n`, kZCmMZ: `ui-tw3t59`, kEafiO: `ui-178xt8z`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-1aeic0j`, $$css: true }, layoutCard: { kVAEAm: `ui-1n2onr6`, kWkggS: `ui-f1vpex`, kaIpWk: `ui-1pjcqnp`, kGVxlE: `ui-1x78n9t`, $$css: true }, attachment: { kVAEAm: `ui-1n2onr6`, kmuXW: `ui-2lah0s`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kWkggS: `ui-f1vpex`, kaIpWk: `ui-1pjcqnp`, kGVxlE: `ui-1x78n9t`, $$css: true }, list: { kH6xsr: `ui-3ct3a4`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kOIVth: `ui-1374kml`, $$css: true }, virtualizedList: { kOIVth: `ui-xhr3t`, $$css: true }, virtualizedRow: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kGNEyG: `ui-1qjc9v5`, kB7OPa: `ui-9f619`, $$css: true }, virtualizedScroller: { kzqmXN: `ui-h8yej3`, kXHlph: `ui-6ikm8r`, k5wCbM: `ui-1rohswg`, kAnDOJ: `ui-6ehuon`, kOuLrU: `ui-fk6m8`, $$css: true } }; +var qg = { base: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-1q0g3np`, kGNEyG: `ui-1cy8zhl`, kB7OPa: `ui-9f619`, kAzted: `ui-bpgt9h`, kOIVth: `ui-1kk7d6x`, kMeerF: `ui-1k57tk5`, k3XXqK: `ui-1t137rt`, kInvED: `ui-1wfwxd8`, kjBf7l: `ui-1uczgqu`, kLKAdn: `ui-1xgckd`, kwRFfy: `ui-yupq46`, kGO01o: `ui-1mv37q2`, kZCmMZ: `ui-1xc7y5k`, kaIpWk: `ui-1w5zb4f`, kkrTdU: `ui-1ypdohk`, kWkggS: `ui-jbqb8w`, $$css: true }, focused: { kWkggS: `ui-flfp0o`, $$css: true }, submenuHover: { kWkggS: `ui-qjnua1`, $$css: true }, selected: { kWkggS: `ui-i07v4r`, $$css: true }, disabled: { kMwMTN: `ui-4b2ntj`, kkrTdU: `ui-t0e3qv`, $$css: true }, disabledFocused: { kWkggS: `ui-jbqb8w`, $$css: true }, muted: { kMwMTN: `ui-1e4uaio`, $$css: true }, mutedFocused: { kMwMTN: `ui-19aaqeu`, $$css: true }, indent: { kZCmMZ: `ui-bp56qb`, $$css: true }, expanded: { kWkggS: `ui-flfp0o`, $$css: true } }; +var Jg = { left: { kmuXW: `ui-2lah0s`, kMwMTN: `ui-r88yfa`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kzqmXN: `ui-1kvrb00`, kZKoxP: `ui-g2ss61`, $$css: true }, leftWide: { kzqmXN: `ui-1td3qas`, $$css: true }, content: { kUk6DE: `ui-98rzlu`, k7Eaqz: `ui-euugli`, k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-1qughib`, $$css: true }, right: { kmuXW: `ui-2lah0s`, k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kMwMTN: `ui-19aaqeu`, kZKoxP: `ui-g2ss61`, $$css: true }, rightDisabled: { kMwMTN: `ui-1e4uaio`, $$css: true }, rightHidden: { k33iCy: `ui-lshs6z`, $$css: true }, submenuRight: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kOIVth: `ui-11twubx`, k7Eaqz: `ui-euugli`, $$css: true }, wrapper: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, k7Eaqz: `ui-euugli`, kUk6DE: `ui-98rzlu`, kLWn49: `ui-1evy7pa`, $$css: true }, title: { kzqmXN: `ui-h8yej3`, kUk6DE: `ui-98rzlu`, k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kOIVth: `ui-11twubx`, $$css: true }, description: { k63SB2: `ui-vxqr21`, kMwMTN: `ui-4b2ntj`, $$css: true } }; +var Yg = { wrapper: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kUk6DE: `ui-98rzlu`, k7Eaqz: `ui-euugli`, $$css: true }, wrapperInline: { kXwgrk: `ui-1q0g3np`, kGNEyG: `ui-1pha0wt`, kOIVth: `ui-ehausa`, $$css: true }, title: { kMwMTN: `ui-1wd3ewq`, $$css: true }, titleInline: { kzQI83: `ui-1ikap7u`, kmuXW: `ui-2lah0s`, kCS8Yb: `ui-1r8uery`, k7Eaqz: `ui-euugli`, ks0D6T: `ui-1t8xbu`, $$css: true }, subtitle: { kMwMTN: `ui-4b2ntj`, $$css: true }, subtitleInline: { kzQI83: `ui-gyuaek`, kmuXW: `ui-2lah0s`, kCS8Yb: `ui-1r8uery`, k7Eaqz: `ui-euugli`, ks0D6T: `ui-1t8xbu`, $$css: true }, subtitleWrap: { khDVqt: `ui-eaf4i8`, kXHlph: `ui-1plvlek`, kORKVm: `ui-ryxfnj`, kg5iWk: `ui-brixnn`, $$css: true } }; +var Xg = { wrapper: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kOIVth: `ui-1374kml`, kEbPVU: `ui-g259vi`, kisVnR: `ui-141yacn`, kPhN0D: `ui-xacq05`, kCI4qJ: `ui-119sr6i`, kflGA3: `ui-144guhz`, kuQXTp: `ui-yhg72o`, k8KjL7: `ui-o6llqc`, k6ANuI: `ui-qapjow`, kzNLci: `ui-13cyfv6`, kvgbxY: `ui-449esf`, kSChS3: `ui-i7iayf`, kW5UhK: `ui-43qgld`, kIK0UP: `ui-16isvt`, kKhlpd: `ui-1s6a5gi`, kWPmei: `ui-f2yixb`, k1ZCP1: `ui-9ymq9g`, k8vVtf: `ui-8il1zj`, kXJ5VR: `ui-tv04z4`, kFqVbU: `ui-al8qud`, k3zOy0: `ui-bvt3p7`, kYzy8m: `ui-1b3rhy7`, k4QksK: `ui-azug9i`, kA8bO0: `ui-p35uty`, kOegPX: `ui-11nj3wz`, kMHwGy: `ui-1db8ipi`, kcy3WD: `ui-1xjs8pl`, k1e9jE: `ui-1lnrnqe`, kSTvrD: `ui-ejpia5`, kvV0by: `ui-6xymf4`, kysnry: `ui-1hw1hzy`, $$css: true }, title: { kLKAdn: `ui-f6zju3`, kwRFfy: `ui-fp2jl6`, kGO01o: `ui-cnij5n`, kZCmMZ: `ui-vc46pw`, kMwMTN: `ui-4b2ntj`, $$css: true }, titleAction: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-1qughib`, kOIVth: `ui-ehausa`, $$css: true }, textAction: { kmuXW: `ui-2lah0s`, kEafiO: `ui-972fbf`, ke9TFa: `ui-10w94by`, kt9PQ7: `ui-1qhh985`, k2ei4v: `ui-14e42zd`, kWkggS: `ui-jbqb8w`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, kMv6JI: `ui-jb2p0i`, kGuDYH: `ui-1qlqyl8`, k63SB2: `ui-1pd3egz`, kLWn49: `ui-15bjb6t`, kMwMTN: `ui-4b2ntj ui-7gh5u8`, kkrTdU: `ui-1ypdohk`, kaIpWk: `ui-1e1y6u3`, k1ekBW: `ui-1oy24xj`, kIyJzY: `ui-g3p6pi ui-6458p5`, kAMwcw: `ui-py3bvx`, $$css: true } }; +var Zg = { divider: { k1xSpc: `ui-1lliihq`, kEafiO: `ui-jpjugk`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-14av3n6`, keoZOQ: `ui-15lde7i`, k71WvV: `ui-1av4zx7`, k1K539: `ui-4qbr5s`, keTefX: `ui-3f5ixz`, kfzvcC: `ui-47corl`, $$css: true } }; +var Qg = { row: { kLKAdn: `ui-fs8kq3`, kwRFfy: `ui-yupq46`, kGO01o: `ui-b6dno7`, kZCmMZ: `ui-1xc7y5k`, $$css: true } }; +var $g = { surface: { kzqmXN: `ui-1oysuqx`, kskxy: `ui-uyqlj2`, kORKVm: `ui-1odjw0f`, kfzvcC: `ui-67bb7w`, k5wCbM: `ui-1597r2g`, k6w4Gs: `ui-xkn5u1`, $$css: true }, surfaceMedium: { kzqmXN: `ui-ezivpi`, ks0D6T: `ui-y2m5lo`, $$css: true }, surfaceWide: { kzqmXN: `ui-ezivpi`, ks0D6T: `ui-c74ic2`, $$css: true } }; +var e_ = { divider: { kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kZKoxP: `ui-1ws4142`, kWkggS: `ui-ry6dcj`, keoZOQ: `ui-1k5org8`, k71WvV: `ui-14z9mp`, k1K539: `ui-fynt6u`, keTefX: `ui-1lziwak`, kfzvcC: `ui-47corl`, $$css: true }, empty: { kLKAdn: `ui-f6zju3`, kwRFfy: `ui-t1q3vd`, kGO01o: `ui-cnij5n`, kZCmMZ: `ui-8fiw5y`, kMwMTN: `ui-4b2ntj`, k9WMMc: `ui-2b8uid`, $$css: true }, emptyIndent: { kZCmMZ: `ui-14o0yop`, $$css: true }, loading: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kOIVth: `ui-ehausa`, kLKAdn: `ui-13ly8rp`, kwRFfy: `ui-t1q3vd`, kGO01o: `ui-1xlntvz`, kZCmMZ: `ui-8fiw5y`, kMwMTN: `ui-4b2ntj`, $$css: true } }; +function t_(e38, t2 = false) { + return [Xo2, Wg.base, Ta2.root, e38 === `md` && Wg.sizeMd, t2 && Wg.hasAttachment]; } -var Cf = { instant: 50, fast: 100, normal: 150, slow: 200, slower: 300, "1s": 1e3, "2s": 2e3 }; -var wf = { default: `ease`, in: `ease-in`, out: `ease-out`, inOut: `ease-in-out`, outStrong: `cubic-bezier(0.165, 0.84, 0.44, 1)`, outCubic: `cubic-bezier(0.215, 0.61, 0.355, 1)`, outQuint: `cubic-bezier(0.16, 1, 0.3, 1)`, inOutStrong: `cubic-bezier(0.77, 0, 0.175, 1)` }; -var Tf = { kzqmXN: `ui-5lhr3w`, $$css: true }; -var Ef = { base: { kVAEAm: `ui-ixxii4`, k87sOh: `ui-13vifvy`, kt4wiu: `ui-tijo5x`, krVfgx: `ui-1ey2m1c`, kLqNvP: `ui-1o0tod`, kY2c9j: `ui-1q7zipb`, kWkggS: `ui-cpsgoo`, kKVMdj: `ui-16q0fa0`, k44tkh: `ui-gyzkii`, kyAemX: `ui-1hr7t8a`, kWV6AL: `ui-10e4vud`, $$css: true }, closing: { kKVMdj: `ui-1h31r3a`, kSiTet: `ui-g01cxk`, $$css: true }, fullscreen: { kWkggS: `ui-679uo6`, k6WDB: `ui-pivpjv ui-v600co`, kKVMdj: `ui-1a5igra`, k1ekBW: `ui-13b0p5u`, $$css: true } }; -var Df = { base: { kVAEAm: `ui-ixxii4`, k87sOh: `ui-wa60dl`, kbCHJM: `ui-1nrll8i`, kY2c9j: `ui-3vbryh`, k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, ks0D6T: `ui-w7nakj`, kskxy: `ui-12ajvvl`, kWkggS: `ui-f1vpex`, kEafiO: `ui-178xt8z`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-2kampu`, ke9TFa: `ui-1lun4ml`, k8ry5P: `ui-18b5jzi`, kBCPoo: `ui-15nuqqu`, kt9PQ7: `ui-so031l`, kfdmCh: `ui-1q0q8m5`, kL6WhQ: `ui-1jfuf7k`, k2ei4v: `ui-pilrb4`, kVhnKS: `ui-1t7ytsu`, kGJrpR: `ui-19smxde`, kaIpWk: `ui-1pkpdue`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kMv6JI: `ui-1acoasx`, kGuDYH: `ui-11wthnw`, kMwMTN: `ui-1wd3ewq`, k3XXqK: `ui-1t137rt`, k3nNDw: `ui-chxttu`, k3aq6I: `ui-k5290g`, kKVMdj: `ui-oddupx ui-1i31srg`, k44tkh: `ui-gyzkii`, kyAemX: `ui-1hr7t8a`, kWV6AL: `ui-10e4vud`, $$css: true }, closing: { kKVMdj: `ui-1pkqeq7 ui-16rl4iv`, kSiTet: `ui-g01cxk`, $$css: true }, sizeSm: { kzqmXN: `ui-1m258z3`, $$css: true }, sizeMd: { kzqmXN: `ui-1l2rt3b`, $$css: true }, sizeLg: { kzqmXN: `ui-ht4xr3`, $$css: true }, sizeXl: { kzqmXN: `ui-ewp6mh`, $$css: true }, sizeXxl: { kzqmXN: `ui-11i3ho8`, $$css: true }, fullscreen: { k87sOh: `ui-80663w`, kbCHJM: `ui-1t8mvi6`, kzqmXN: `ui-14atkfc`, ks0D6T: `ui-1x1rfll`, kskxy: `ui-7ab17h`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, kWkggS: `ui-jbqb8w`, kLZC3w: `ui-oe9jqj`, kBCPoo: `ui-1vf9p6h`, kL6WhQ: `ui-1ljce3w`, kGJrpR: `ui-1ej2chf`, kaIpWk: `ui-1043rbw`, kKVMdj: `ui-1a5igra`, k3nNDw: `ui-1jpgh95`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kLWn49: `ui-14ju556`, kgyCeQ: `ui-lp1x4z`, kdrBUz: `ui-7iibnf`, kHBbk8: `ui-c8icb0`, k1ekBW: `ui-13b0p5u`, k3aq6I: `ui-1c071of`, k9MlgS: `ui-1b4evyo`, kBJ8X: `ui-172d7oh`, khkr5k: `ui-1wlgkvo`, kUp1g7: `ui-12srh1u`, kenXb: `ui-8jwf0z`, $$css: true } }; -var Of = { viewportCappedWidth: (e9) => [Tf, { "--x-width": ((e10) => typeof e10 == `number` ? e10 + `px` : e10 ?? void 0)(`min(${e9}px, 90vw)`) }] }; -var kf = { base: { kVAEAm: `ui-1n2onr6`, k1xSpc: `ui-78zum5`, kGNEyG: `ui-1cy8zhl`, kjj79g: `ui-1qughib`, kOIVth: `ui-ehausa`, kLKAdn: `ui-1t8xvyj`, kwRFfy: `ui-16mtmbo`, kGO01o: `ui-usxwy5`, kZCmMZ: `ui-7ru5ko`, $$css: true }, beforeContent: { kGO01o: `ui-18d9i69`, $$css: true }, centered: { kjj79g: `ui-l56j7k`, k9WMMc: `ui-2b8uid`, $$css: true } }; -var Af = { base: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kOIVth: `ui-11twubx`, k7Eaqz: `ui-euugli`, $$css: true }, centered: { kGNEyG: `ui-6s0dn4`, $$css: true } }; -var jf = { base: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kGNEyG: `ui-1cy8zhl`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kOIVth: `ui-137clkk`, $$css: true }, centered: { kGNEyG: `ui-6s0dn4`, $$css: true } }; -var Mf = { base: { k1xSpc: `ui-78zum5`, kwnvtZ: `ui-1a02dak`, kGNEyG: `ui-1pha0wt`, kOIVth: `ui-ehausa`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, $$css: true }, centered: { kjj79g: `ui-l56j7k`, $$css: true } }; -var Nf = { base: { kMwMTN: `ui-1wd3ewq`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kHjlTd: `ui-1mzt3pk`, $$css: true } }; -var Pf = { base: { kMwMTN: `ui-4b2ntj`, kGuDYH: `ui-11wthnw`, k63SB2: `ui-vxqr21`, kLWn49: `ui-1ja60sm`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kHjlTd: `ui-1mzt3pk`, $$css: true }, secondary: { kMwMTN: `ui-19aaqeu`, $$css: true }, stepper: { kHjlTd: `ui-j0a0fe`, kTgw9: `ui-13faqbe`, $$css: true } }; -var Ff = { root: { kzqmXN: `ui-h8yej3`, kAzted: `ui-2lwn1j`, kskxy: `ui-lbh9wg`, $$css: true }, content: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-dt5ytf`, kOIVth: `ui-5cdhqx`, kH6xsr: `ui-3ct3a4`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kg3NbH: `ui-1px5tkr`, $$css: true }, header: { kMwMTN: `ui-4b2ntj`, kg3NbH: `ui-njsko4`, k1K539: `ui-l018at`, keoZOQ: `ui-1fjfqqj ui-3pnz3v`, $$css: true }, rowItem: { k1K539: `ui-at24cr ui-h95wvw`, $$css: true }, row: { k1xSpc: `ui-78zum5`, kXwgrk: `ui-1q0g3np`, kGNEyG: `ui-6s0dn4`, kOIVth: `ui-ehausa`, kzqmXN: `ui-ihbwum`, kZKoxP: `ui-170hpbr`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-196pc8s`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-22095l`, keoZOQ: `ui-dj266r`, k71WvV: `ui-1uioroh`, k1K539: `ui-at24cr`, keTefX: `ui-1cw70au`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, kLZC3w: `ui-1v8p93f`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kBCPoo: `ui-1o3jo1z`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, kL6WhQ: `ui-16stqrj`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kGJrpR: `ui-v5lvn5`, kaIpWk: `ui-1043rbw`, kWkggS: `ui-jbqb8w`, kMwMTN: `ui-1heor9g`, k9WMMc: `ui-1yc453h`, $$css: true }, rowMultiline: { kZKoxP: `ui-t7dq6l`, kAzted: `ui-11ooeo3`, kLKAdn: `ui-13ly8rp`, kGO01o: `ui-1xlntvz`, $$css: true }, rowInteractive: { kkrTdU: `ui-1ypdohk`, kWkggS: `ui-jbqb8w ui-1iuyybk ui-bc7umr ui-1oqui1x`, $$css: true }, rowSelected: { kWkggS: `ui-59yu97 ui-1kj6vsg ui-1o6fdlz`, $$css: true }, rowDisabled: { kkrTdU: `ui-1h6gzvc`, kSiTet: `ui-byyjgo`, $$css: true }, rowIcon: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kmuXW: `ui-2lah0s`, $$css: true }, rowLabel: { kUk6DE: `ui-1cqoux5`, k7Eaqz: `ui-euugli`, kXHlph: `ui-6ikm8r`, kORKVm: `ui-10wlt62`, kg5iWk: `ui-lyipyv`, k8aIck: `ui-jlip5`, kqG3fB: `ui-kyw5k8`, kMwMTN: `ui-1wd3ewq`, $$css: true }, rowLabelMultiline: { kORKVm: `ui-ryxfnj`, k8aIck: `ui-sdcz8n`, khDVqt: `ui-eaf4i8`, $$css: true }, rowTrailing: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kOIVth: `ui-11twubx`, kmuXW: `ui-2lah0s`, k7Eaqz: `ui-euugli`, $$css: true } }; -var If = { base: { kB7OPa: `ui-9f619`, kzqmXN: `ui-h8yej3`, kLKAdn: `ui-t9g0qb`, kwRFfy: `ui-16mtmbo`, kGO01o: `ui-20eq2h`, kZCmMZ: `ui-7ru5ko`, kORKVm: `ui-1odjw0f`, $$css: true }, afterHeader: { kLKAdn: `ui-1t8xvyj`, $$css: true }, scrollable: { kEafiO: `ui-178xt8z`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-1aeic0j`, $$css: true } }; -var Lf = { base: { k1xSpc: `ui-78zum5`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-13a6bvl`, kOIVth: `ui-ehausa`, kLKAdn: `ui-oyc9vk`, kwRFfy: `ui-1fg0g13`, kGO01o: `ui-2lprc`, kZCmMZ: `ui-1tajz9i`, kB7OPa: `ui-9f619`, kEafiO: `ui-178xt8z`, kPef9Z: `ui-13fuv20`, kLZC3w: `ui-1aeic0j`, $$css: true } }; -var Rf = { root: { kysU6D: `ui-jyslct`, k1xSpc: `ui-3nfvp2`, kGNEyG: `ui-6s0dn4`, kjj79g: `ui-l56j7k`, kmuXW: `ui-2lah0s`, kB7OPa: `ui-9f619`, kVAEAm: `ui-10l6tqk`, k87sOh: `ui-rge2pg`, kt4wiu: `ui-1wr5tk2`, kY2c9j: `ui-1vjfegm`, kzqmXN: `ui-16bvwqk`, kZKoxP: `ui-1a6rlst`, k7Eaqz: `ui-cbmsab`, kAzted: `ui-4jlmx6`, kLKAdn: `ui-exx8yu`, kwRFfy: `ui-yri2b`, kGO01o: `ui-18d9i69`, kZCmMZ: `ui-1c1uobl`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, kEafiO: `ui-972fbf`, kPef9Z: `ui-1ejq31n`, kLZC3w: `ui-1b4hy2t`, ke9TFa: `ui-10w94by`, k8ry5P: `ui-18oe1m7`, kBCPoo: `ui-1273586`, kt9PQ7: `ui-1qhh985`, kfdmCh: `ui-1sy0etr`, kL6WhQ: `ui-1tnzt7h`, k2ei4v: `ui-14e42zd`, kVhnKS: `ui-stzfhl`, kGJrpR: `ui-1mi4oqr`, kaIpWk: `ui-1i4c3av`, kMv6JI: `ui-jb2p0i`, kGuDYH: `ui-1qlqyl8`, k63SB2: `ui-1pd3egz`, kLWn49: `ui-15bjb6t`, kWkggS: `ui-jbqb8w ui-oli092`, kMwMTN: `ui-19aaqeu ui-1dsx48b`, kkrTdU: `ui-1ypdohk`, kFalU9: `ui-ggy1nq`, k1ekBW: `ui-1oy24xj`, kIyJzY: `ui-g3p6pi`, kAMwcw: `ui-6ekqhr`, k3aq6I: `ui-1c071of`, $$css: true } }; -function zf({ fullscreen: e9, status: t2 }) { - return [Ef.base, t2 === `close` ? Ef.closing : null, e9 ? Ef.fullscreen : null]; +function n_(e38 = false) { + return e38 && Wg.dropIndicator; } -function Bf({ fullscreen: e9, size: t2, status: n2, width: r2 }) { - return [Df.base, ip2(t2), r2 !== void 0 && !e9 ? Of.viewportCappedWidth(r2) : null, n2 === `close` ? Df.closing : null, e9 ? Df.fullscreen : null]; +function r_() { + return Gg.base; } -function Vf({ alignment: e9, beforeContent: t2 }) { - return [kf.base, t2 ? kf.beforeContent : null, e9 === `center` ? kf.centered : null]; +function i_2() { + return Kg.inner; } -function Hf({ alignment: e9 }) { - return [Af.base, e9 === `center` ? Af.centered : null]; +function a_2() { + return Kg.dropIndicatorSlot; } -function Uf({ alignment: e9 }) { - return [jf.base, e9 === `center` ? jf.centered : null]; +function o_(e38 = false) { + return [Kg.layout, e38 && Kg.layoutCard, e38 && Lo2.border]; } -function Wf({ alignment: e9 }) { - return [Mf.base, e9 === `center` ? Mf.centered : null]; +function s_() { + return [Kg.attachment, Lo2.border]; } -function Gf() { - return Nf.base; +function c_() { + return Kg.bodyScroll; } -function Kf({ stepper: e9, color: t2 = `tertiary`, fontSize: n2 = `lg` }) { - return [ga.root, Pf.base, t2 === `secondary` ? Pf.secondary : null, e9 && n2 === `lg` ? da2.root : null, e9 ? Pf.stepper : null]; +function l_() { + return Kg.header; } -function qf() { - return Ff.root; +function u_() { + return Kg.footer; } -function Jf() { - return Ff.content; +function d_(e38 = false) { + return [Kg.list, e38 && Kg.virtualizedList]; } -function Yf() { - return [la.root, Ff.header]; +function f_() { + return Kg.virtualizedRow; } -function Xf() { - return Ff.rowItem; +function p_() { + return Kg.virtualizedScroller; } -function Zf({ disabled: e9, interactive: t2, multiline: n2, selected: r2 }) { - return [Ff.row, ua2.root, n2 ? Ff.rowMultiline : null, t2 ? Ff.rowInteractive : null, r2 ? Ff.rowSelected : null, e9 ? Ff.rowDisabled : null]; +function m_(e38 = {}) { + return [qg.base, e38.selected && qg.selected, e38.inSubmenu && !e38.disabled && qg.submenuHover, e38.focused && qg.focused, e38.expanded && qg.expanded, e38.disabled && qg.disabled, e38.disabled && e38.focused && qg.disabledFocused, e38.variant === `muted` && qg.muted, e38.variant === `muted` && e38.focused && qg.mutedFocused, e38.indent && qg.indent]; } -function Qf() { - return Ff.rowIcon; +var h_ = { disabled: { kkrTdU: `ui-1h6gzvc`, $$css: true } }; +function g_() { + return h_.disabled; } -function $f({ multiline: e9 }) { - return [ua2.root, Ff.rowLabel, e9 ? Ff.rowLabelMultiline : null]; +function __(e38 = {}) { + return [Jg.left, e38.wideLeft && Jg.leftWide]; } -function ep() { - return Ff.rowTrailing; +function v_() { + return Jg.content; } -function tp({ afterHeader: e9, scrollable: t2 }) { - return [ua2.root, If.base, e9 ? If.afterHeader : null, t2 ? If.scrollable : null]; +function y_(e38 = {}) { + return [Jg.right, e38.disabled && Jg.rightDisabled, e38.trailingHidden && Jg.rightHidden]; } -function np() { - return Lf.base; +function b_() { + return Jg.submenuRight; } -function rp() { - return [Rf.root, Ni.self]; +function x_() { + return Jg.wrapper; } -function ip2(e9) { - switch (e9) { - case `sm`: - return Df.sizeSm; - case `md`: - return Df.sizeMd; - case `lg`: - return Df.sizeLg; - case `xl`: - return Df.sizeXl; - case `xxl`: - return Df.sizeXxl; - case `fullscreen`: - return null; +function S_() { + return [Aa.root, Jg.title]; +} +function C_() { + return [wa2.root, Aa.root, Jg.description]; +} +function w_(e38) { + return [Yg.wrapper, e38 && Yg.wrapperInline]; +} +function T_(e38) { + return [Aa.root, Yg.title, e38 && Yg.titleInline]; +} +function E_({ inline: e38, wrap: t2 }) { + return [wa2.root, Aa.root, Yg.subtitle, e38 && Yg.subtitleInline, t2 && Yg.subtitleWrap]; +} +function D_() { + return Qg.row; +} +function O_() { + return Xg.wrapper; +} +function k_(e38) { + return [wa2.root, Xg.title, e38 && Xg.titleAction]; +} +function A_() { + return [Xg.textAction, Ki2.self]; +} +function j_() { + return Zg.divider; +} +function M_() { + return $g.surface; +} +function N_(e38) { + switch (e38) { + case `default`: + return; + case `medium`: + return $g.surfaceMedium; + case `wide`: + return $g.surfaceWide; + default: + return e38; } } -var ap2 = Cf.slower; -var op2 = wf.outStrong; -var sp2 = (0, J2.createContext)(null); -function cp2(e9) { - let t2 = (0, J2.useContext)(sp2); - if (!t2) throw Error(`${e9} must be used within Dialog`); +function P_(e38) { + return [wa2.root, e_.empty, e38 && e_.emptyIndent]; +} +function F_() { + return [Ta2.root, e_.loading]; +} +function I_(e38) { + let t2 = e38, n2 = /* @__PURE__ */ new Set(); + return { get: () => t2, set: (e39) => { + if (e39 !== t2) { + t2 = e39; + for (let e40 of n2) e40(); + } + }, subscribe: (e39) => (n2.add(e39), () => { + n2.delete(e39); + }) }; +} +var L_ = (0, Y2.createContext)(null); +function R_(e38) { + let t2 = (0, Y2.useContext)(L_); + if (!t2) throw Error(`${e38} must be used within LegacyMenu.Content or LegacyMenu.SubMenuContent`); + return t2; +} +function z_(e38, t2) { + let n2 = () => e38.get() === t2; + return (0, Y2.useSyncExternalStore)(e38.subscribe, n2, n2); +} +function B_({ children: e38, activeIndex: t2, setIsOpen: n2, getItemProps: r2, searchValue: i3, closeOnSelect: a3, virtualFocus: o3 = false, activeDescendantIdPrefix: s3, shouldAllowPointerInteraction: c3, closeMenuLayersOnSelect: l5 }) { + B_.d = 4281094476; + let [u3] = (0, Y2.useState)(() => I_(t2)); + (0, Y2.useLayoutEffect)(() => { + u3.set(t2); + }, [u3, t2]); + let d3 = (0, Y2.useMemo)(() => ({ activeIndexStore: u3, setIsOpen: n2, getItemProps: r2, searchValue: i3, closeOnSelect: a3, virtualFocus: o3, activeDescendantIdPrefix: s3, shouldAllowPointerInteraction: c3, closeMenuLayersOnSelect: l5 }), [u3, n2, r2, i3, a3, o3, s3, c3, l5]); + return (0, J2.jsx)(L_.Provider, { value: d3, children: e38 }); +} +var V_ = (0, Y2.createContext)(null); +var H_ = { base: { kfSwDN: `ui-87ps6o`, kfzvcC: `ui-47corl`, $$css: true } }; +var U_ = /* @__PURE__ */ new WeakMap(); +var W_ = 0; +function G_() { + return W_ += 1, `ui-tooltip-${W_}`; +} +var K_ = (0, Y2.createContext)(null); +function q_(e38) { + let t2 = (0, Y2.use)(K_); + if (t2 === null) throw Error(`${e38} must be used within Tooltip.Root`); return t2; } -function lp2() { - return cp2(`useDialogContext`); +function J_({ open: e38, defaultOpen: t2 }) { + let [n2] = (0, Y2.useState)(() => e38 !== void 0 || t2 === true ? null : Wy()), [r2, i3] = (0, Y2.useState)(false); + n2 !== null && e38 !== void 0 && !r2 && i3(true); + let [a3, o3] = (0, Y2.useState)(false), s3 = (0, Y2.useRef)(false), c3 = (0, Y2.useRef)(false), l5 = (0, Y2.useRef)(null), u3 = (0, Y2.useCallback)(() => { + (0, br2.flushSync)(() => { + i3(true); + }); + }, []), d3 = (0, Y2.useCallback)((e39) => { + c3.current || (l5.current === null && !s3.current && u3(), c3.current || (l5.current = e39)); + }, [u3]), f4 = (0, Y2.useCallback)(() => { + s3.current = true, o3(true); + }, []); + return (0, Y2.useLayoutEffect)(() => { + if (!a3) return; + c3.current = true; + let e39 = l5.current; + if (l5.current = null, e39?.target.matches(`:focus`)) { + let t3 = new FocusEvent(`focusin`, { bubbles: true, relatedTarget: e39.relatedTarget }); + U_.set(t3, e39.trigger), e39.target.dispatchEvent(t3); + } + }, [a3]), (0, Y2.useMemo)(() => n2 === null ? null : { handle: n2, mountRoot: u3, mountRootOnFocus: d3, onRootCommit: f4, rootCommitted: a3, rootMounted: r2 }, [n2, u3, d3, f4, a3, r2]); +} +function Y_2({ children: e38, placement: t2 = `top`, offset: n2 = 8, openDelay: r2 = 300, closeDelay: i3 = 100, disabled: a3 = false, defaultOpen: o3, open: s3, sameAxisOnly: c3 = false, onOpenChange: l5, onOpenChangeComplete: u3 }) { + Y_2.d = 949447544; + let d3 = (0, Y2.use)(V_), f4 = (0, Y2.use)(tu2), p4 = a3 || f4, m3 = d3?.open ?? r2, h4 = d3?.close ?? i3, g5 = J_({ defaultOpen: o3, open: s3 }), _5 = g5 !== null && !g5.rootCommitted && s3 === true ? false : s3, v5 = (0, Y2.useRef)(null), y4 = (0, Y2.useMemo)(() => ({ close: () => { + v5.current?.close(); + } }), []), [b2, x2] = (0, Y2.useState)(), [S2] = (0, Y2.useState)(G_), C2 = (0, Y2.useRef)(o3 === true || s3 === true), w2 = (0, Y2.useCallback)((e39, t3) => { + l5?.(e39, t3), t3.isCanceled || (x2(e39 ? t3.trigger?.id : void 0), e39 && (C2.current = true)); + }, [l5]), T2 = (0, Y2.useCallback)((e39) => { + e39 || (C2.current = false), u3?.(e39); + }, [u3]); + (0, Y2.useLayoutEffect)(() => { + s3 === true && (C2.current = true); + }, [s3]), (0, Y2.useLayoutEffect)(() => { + f4 && C2.current && v5.current?.unmount(); + }, [f4]); + let E2 = (0, Y2.useMemo)(() => ({ actionsRef: v5, descriptionId: S2, disabled: p4, instantDismiss: f4, lazyRoot: g5, offset: n2, onOpenChange: w2, onOpenChangeComplete: T2, open: _5, openTriggerId: b2, placement: t2, sameAxisOnly: c3, scrollDismissHandle: y4, triggerCloseDelay: h4, triggerDelay: m3 }), [S2, p4, w2, T2, f4, g5, n2, b2, t2, _5, c3, y4, h4, m3]); + return (0, J2.jsx)(K_.Provider, { value: E2, children: g5 === null ? (0, J2.jsx)(ky, { actionsRef: v5, defaultOpen: o3, disabled: p4, disableHoverablePopup: true, onOpenChange: w2, onOpenChangeComplete: T2, open: s3, children: e38 }) : e38 }); +} +function X_({ children: e38, ref: t2, onFocus: n2, onFocusCapture: r2, ...i3 }) { + X_.d = 3451673097; + let { descriptionId: a3, disabled: o3, lazyRoot: s3, triggerCloseDelay: c3, triggerDelay: l5 } = q_(`Tooltip.Trigger`), u3 = s3?.mountRoot, d3 = s3?.mountRootOnFocus, f4 = (e39) => { + if (d3 !== void 0) { + let t3 = e39.target.closest(`[data-base-ui-tooltip-trigger]`); + !(t3 !== null && t3 !== e39.currentTarget && e39.currentTarget.contains(t3)) && e39.target.matches(`:focus`) && d3({ relatedTarget: e39.relatedTarget, target: e39.target, trigger: e39.currentTarget }); + } + r2?.(e39); + }, p4 = (e39) => { + let t3 = U_.get(e39.nativeEvent); + if (t3 === void 0) { + n2?.(e39); + return; + } + t3 === e39.currentTarget && e39.stopPropagation(); + }, m3 = Bl(e38), h4 = (0, Y2.useCallback)((e39) => { + if (e39 === null) return; + let n3 = Z_2(t2, e39), r3 = Z_2(m3, e39); + return u3 !== void 0 && e39.addEventListener(`mouseenter`, u3, { capture: true, once: true }), () => { + u3 !== void 0 && e39.removeEventListener(`mouseenter`, u3, { capture: true }), n3(), r3(); + }; + }, [m3, u3, t2]); + return (0, J2.jsx)(Fy, { ...i3, closeDelay: c3, delay: l5, disabled: o3, handle: s3?.handle, onFocus: p4, onFocusCapture: f4, ref: h4, render: (t3, n3) => { + let r3 = H(t3, Ll(e38)); + return r3.ref = t3.ref, n3.open && (r3[`aria-describedby`] = [r3[`aria-describedby`], a3].filter(Boolean).join(` `)), (0, Y2.cloneElement)(e38, r3); + } }); +} +function Z_2(e38, t2) { + if (typeof e38 == `function`) { + let n2 = e38(t2); + return typeof n2 == `function` ? n2 : () => e38(null); + } + return e38 == null ? () => { + } : (e38.current = t2, () => { + e38.current = null; + }); +} +function Q_(e38) { + Q_.d = 192733362; + let { lazyRoot: t2 } = q_(`Tooltip.Popup`); + return t2 === null ? (0, J2.jsx)(ev, { ...e38 }) : t2.rootMounted ? (0, J2.jsx)($_, { ...e38, lazyRoot: t2 }) : null; +} +function $_({ lazyRoot: e38, ...t2 }) { + $_.d = 2773792539; + let { actionsRef: n2, disabled: r2, onOpenChange: i3, onOpenChangeComplete: a3, open: o3 } = q_(`Tooltip.Popup`), { handle: s3, onRootCommit: c3 } = e38; + return (0, Y2.useLayoutEffect)(() => { + c3(); + }, [c3]), (0, J2.jsx)(ky, { actionsRef: n2, disabled: r2, disableHoverablePopup: true, handle: s3, onOpenChange: i3, onOpenChangeComplete: a3, open: o3, children: (0, J2.jsx)(ev, { ...t2 }) }); +} +function ev({ content: e38, anchor: t2, ariaLabel: n2, width: r2, minWidth: i3, maxWidth: a3 }) { + ev.d = 3680423543; + let { descriptionId: o3, instantDismiss: s3, offset: c3, openTriggerId: l5, placement: u3, sameAxisOnly: d3, scrollDismissHandle: f4 } = q_(`Tooltip.Popup`), p4 = Ni2(), m3 = eu2(f4, l5), { side: h4, align: g5, sideOffset: _5, alignOffset: v5, collisionAvoidance: y4, positionMethod: b2 } = jc2(u3, c3, d3), x2 = Io2(Ho2), S2 = h(Bo2, Jo2, Wo2, H_.base, No2); + return s3 ? null : (0, J2.jsx)(Ry, { container: p4 ?? void 0, children: (0, J2.jsx)(Vy, { align: g5, alignOffset: v5, anchor: t2, className: x2.className, collisionAvoidance: y4, collisionPadding: 8, positionMethod: b2, side: h4, sideOffset: _5, style: x2.style, children: (0, J2.jsx)(Hy, { "aria-label": n2, className: S2.className, "data-component": `tooltip-popup`, id: o3, ref: m3, role: `tooltip`, style: r2 === void 0 && i3 === void 0 && a3 === void 0 ? S2.style : { ...S2.style, width: r2, minWidth: i3, maxWidth: a3 }, children: typeof e38 == `function` ? e38() : e38 }) }) }); +} +function nv({ children: e38, content: t2, placement: n2, offset: r2, openDelay: i3, closeDelay: a3, disabled: o3, defaultOpen: s3, open: c3, "aria-label": l5, width: u3, minWidth: d3, maxWidth: f4, sameAxisOnly: p4, onOpenChange: m3, onOpenChangeComplete: h4, ref: g5, ..._5 }) { + nv.d = 2358871818; + let v5 = Y2.Children.only(e38); + return (0, Y2.isValidElement)(v5) ? (0, J2.jsxs)(Y_2, { closeDelay: a3, defaultOpen: s3, disabled: o3, offset: r2, onOpenChange: m3, onOpenChangeComplete: h4, open: c3, openDelay: i3, placement: n2, sameAxisOnly: p4, children: [(0, J2.jsx)(X_, { ..._5, ref: g5, children: v5 }), (0, J2.jsx)(Q_, { ariaLabel: l5, content: t2, maxWidth: f4, minWidth: d3, width: u3 })] }) : (0, J2.jsx)(J2.Fragment, { children: e38 }); +} +var ov2 = `ui-menu`; +var sv2 = `ui-menu__backdrop`; +var cv2 = `ui-menu__list`; +var lv2 = `ui-menu__content`; +var uv2 = `ui-menu__drop-indicator-slot`; +var dv2 = `ui-menu__layout`; +var fv2 = `ui-menu__body-scroll`; +var pv2 = `ui-menu__header`; +var mv2 = `ui-menu__footer`; +var hv2 = `ui-menu__attachment`; +var gv2 = `ui-menu__row`; +var _v2 = `ui-menu__item-left`; +var vv2 = `ui-menu__item-content`; +var yv2 = `ui-menu__item-right`; +var bv2 = `ui-menu__item-wrapper`; +var xv2 = `ui-menu__item-title`; +var Sv2 = `ui-menu__item-description`; +var Cv2 = `ui-menu__text-wrapper`; +var wv2 = `ui-menu__title`; +var Tv2 = `ui-menu__subtitle`; +var Ev2 = `ui-menu__search-row`; +var Dv = `ui-menu__section`; +var Ov = `ui-menu__section-title`; +var kv = `ui-menu__section-text-action`; +var Av = `ui-menu__virtualized-section-divider`; +var jv = `ui-menu__submenu-trigger`; +var Mv = `ui-menu__submenu-right-section`; +var Nv2 = `ui-menu__toggle-row`; +var Pv2 = `ui-menu__tooltip`; +var Fv2 = `ui-menu__empty`; +var Iv2 = `ui-menu__loading`; +var Lv2 = `ui-menu__virtualized-row`; +var Rv2 = `ui-menu__virtualized-scroller`; +function Q2(e38, t2, n2 = {}) { + return q2({ rootClass: e38, stylexStyles: t2, className: n2.className, style: n2.style }); +} +function zv({ className: e38, hasDropIndicator: t2 = false, size: n2, style: r2, hasAttachment: i3 = false, surfaceStyle: a3 }) { + return a3 = [n_(t2), a3], Q2(ov2, [t_(n2, i3), a3], { className: e38, style: r2 }); +} +function Bv(e38) { + return Q2(sv2, r_(), { style: e38 }); +} +function Vv(e38 = false, t2) { + return Q2(cv2, [d_(e38), t2], { className: e38 ? `ui-menu__list--virtualized` : void 0 }); +} +function Hv2(e38) { + return Q2(lv2, [i_2(), e38]); +} +function Uv() { + return Q2(uv2, a_2()); +} +function Wv(e38, t2 = false, n2) { + return Q2(dv2, [o_(t2), n2], { style: e38 }); +} +function Gv() { + return Q2(hv2, s_()); +} +function Kv() { + return Q2(pv2, l_()); +} +function qv() { + return Q2(mv2, u_()); +} +function Jv(e38 = {}, t2) { + return Q2(gv2, [{ "ui--default-marker": `ui--default-marker`, $$css: true }, m_(e38), t2], { className: e38.className }); +} +function Yv(e38 = {}, t2) { + return Q2(Nv2, [m_(e38), e38.disabled && g_(), t2], { className: e38.className }); +} +function Xv(e38 = {}) { + return Q2(jv, m_(e38), { className: e38.className }); +} +function Zv(e38 = {}, t2) { + return Q2(_v2, [__(e38), t2]); +} +function Qv(e38) { + return Q2(vv2, [v_(), e38]); +} +function $v(e38 = {}, t2) { + return Q2(yv2, [y_(e38), t2]); +} +function ey() { + return Q2(bv2, x_()); +} +function ty() { + return Q2(xv2, S_()); +} +function ny() { + return Q2(Sv2, C_()); +} +function ry(e38) { + return Q2(Cv2, w_(e38)); +} +function iy(e38) { + return Q2(wv2, T_(e38)); +} +function ay({ inline: e38, wrap: t2 }) { + return Q2(Tv2, E_({ inline: e38, wrap: t2 })); +} +function oy(e38, t2) { + return Q2(Ev2, [D_(), t2], { className: e38 }); +} +function sy(e38) { + return Q2(Dv, [O_(), e38]); +} +function cy(e38, t2) { + return Q2(Ov, [k_(e38), t2]); } -function up2() { - let e9 = (0, J2.useId)(); - return { titleId: `${e9}-title`, descriptionId: `${e9}-description` }; +function ly() { + return Q2(kv, A_()); } -function dp2({ "aria-label": e9 = `Close`, iconSize: t2 = 12, rootStyle: n2, onClick: r2 }) { - dp2.d = 1048069076; - let { onOpenChange: i3 } = cp2(`Dialog.Close`), a3 = () => { - r2?.(), i3(false); - }, o3 = K2({ rootClass: `ui-dialog-close`, stylexStyles: [rp(), n2], className: `ui-icon-button` }); - return (0, q2.jsx)(`button`, { type: `button`, ...Pi.self, "aria-label": e9, className: o3.className, "data-frame": `container`, "data-size": `md`, "data-rounded": `true`, "data-variant": `ghost`, onClick: a3, style: o3.style, children: (0, q2.jsx)(hi, { "aria-hidden": `true`, name: `close`, size: t2, variant: `outline` }) }); -} -function fp2({ children: e9, rootStyle: t2, className: n2, style: r2, scrollable: i3 }) { - fp2.d = 1993425269; - let { contentHasCompactTopPadding: a3 } = cp2(`Dialog.Content`), o3 = i3 ?? r2?.maxHeight !== void 0; - return (0, q2.jsx)(Kd, { as: `div`, size: `md`, weight: `regular`, color: `primary`, className: G3(`ui-dialog-content`, o3 && `ui-dialog-content--scrollable`, n2), style: r2, rootStyle: [tp({ afterHeader: a3, scrollable: o3 }), t2], children: e9 }); -} -function pp2({ as: e9 = `p`, children: t2, style: n2, rootStyle: r2, ...i3 }) { - pp2.d = 44863126; - let { descriptionId: a3 } = cp2(`Dialog.Description`), o3 = K2({ rootClass: `ui-dialog-description`, stylexStyles: [Kf({ stepper: false }), r2], style: n2 }); - return (0, q2.jsx)(e9, { id: a3, ...i3, className: o3.className, style: o3.style, children: t2 }); -} -function mp2({ children: e9, className: t2, rootStyle: n2, style: r2, ...i3 }) { - mp2.d = 4197487865; - let a3 = K2({ rootClass: `ui-dialog-footer`, stylexStyles: [np(), n2], className: t2, style: r2 }); - return (0, q2.jsx)(`div`, { className: a3.className, style: a3.style, ...i3, children: e9 }); -} -function hp2({ children: e9, title: t2, stepLabel: n2, description: r2, alignment: i3 = `start`, titleSize: a3 = `lg`, titleWeight: o3 = `regular`, descriptionColor: s3 = `tertiary`, descriptionFontSize: c2 = `lg`, rootStyle: l4 }) { - hp2.d = 1985259212; - let u3 = (0, J2.useContext)(sp2), d3 = (0, J2.useId)(), f4 = u3?.titleId ?? `${d3}-title`, p4 = u3?.descriptionId ?? `${d3}-description`, m3 = !!t2, h3 = !!n2, g3 = !!r2, _2 = m3 || h3 || g3, v3 = K2({ rootClass: `ui-dialog-header`, stylexStyles: [Vf({ alignment: i3, beforeContent: u3?.headerBeforeContent ?? false }), l4] }), y3 = K2({ rootClass: `ui-dialog-header-lead`, stylexStyles: Hf({ alignment: i3 }) }), b3 = K2({ rootClass: `ui-dialog-header-stepper-head`, stylexStyles: Uf({ alignment: i3 }) }), x3 = K2({ rootClass: `ui-dialog-header-stepper`, stylexStyles: Wf({ alignment: i3 }) }), S3 = K2({ rootClass: `ui-dialog-title`, stylexStyles: Gf() }), C2 = K2({ rootClass: `ui-dialog-description`, stylexStyles: Kf({ stepper: true, color: s3, fontSize: c2 }), className: `ui-dialog-header-stepper-description` }); - return (0, q2.jsxs)(`div`, { className: v3.className, "data-alignment": i3, style: v3.style, children: [_2 ? (0, q2.jsx)(`div`, { className: y3.className, style: y3.style, children: (0, q2.jsxs)(`div`, { className: b3.className, style: b3.style, children: [m3 || h3 ? (0, q2.jsxs)(`div`, { className: x3.className, style: x3.style, role: h3 ? `status` : void 0, children: [m3 ? (0, q2.jsx)(Kd, { as: `h2`, className: S3.className, color: `primary`, id: f4, size: a3, style: S3.style, weight: o3, children: t2 }) : null, h3 ? (0, q2.jsx)(Kd, { as: `span`, color: `quaternary`, size: `lg`, weight: `regular`, children: n2 }) : null] }) : null, g3 ? (0, q2.jsx)(`p`, { className: C2.className, id: p4, style: C2.style, children: r2 }) : null] }) }) : null, e9] }); -} -function gp2({ children: e9 }) { - gp2.d = 2404464051; - let t2 = K2({ rootClass: `ui-dialog-header-lead`, stylexStyles: Hf({ alignment: `start` }) }); - return (0, q2.jsx)(`div`, { className: t2.className, style: t2.style, children: e9 }); -} -var _p2 = (0, J2.createContext)({ selectable: false }); -function vp2({ selectable: e9, children: t2 }) { - return vp2.d = 398133413, (0, q2.jsx)(_p2.Provider, { value: { selectable: e9 }, children: t2 }); -} -function yp2() { - return (0, J2.useContext)(_p2); -} -function bp2({ children: e9, rootStyle: t2, selectable: n2 = false, "aria-label": r2, "aria-labelledby": i3 }) { - bp2.d = 3355976881; - let a3 = h(Jf()); - return (0, q2.jsx)(vp2, { selectable: n2, children: (0, q2.jsx)(cc, { "aria-label": r2, "aria-labelledby": i3, className: `ui-dialog-list`, role: n2 ? `listbox` : void 0, rootStyle: [qf(), t2], children: (0, q2.jsx)(`ul`, { className: a3.className, style: a3.style, children: e9 }) }) }); -} -function xp2({ children: e9 }) { - xp2.d = 1660678637; - let t2 = K2({ rootClass: `ui-dialog-list-header`, stylexStyles: Yf() }); - return (0, q2.jsx)(`li`, { className: t2.className, style: t2.style, children: e9 }); -} -function Sp2({ icon: e9, label: t2, trailing: n2, selected: r2 = false, multiline: i3 = false, onClick: a3, disabled: o3 }) { - Sp2.d = 3646017287; - let { selectable: s3 } = yp2(), c2 = s3 && a3 !== void 0, l4 = h(Xf()), u3 = K2({ rootClass: `ui-dialog-list-row`, stylexStyles: Zf({ disabled: o3 === true, interactive: a3 !== void 0, multiline: i3, selected: r2 }) }), d3 = h(Qf()), f4 = h($f({ multiline: i3 })), p4 = h(ep()), m3 = (0, q2.jsxs)(q2.Fragment, { children: [e9 ? (0, q2.jsx)(`div`, { className: d3.className, style: d3.style, children: e9 }) : null, (0, q2.jsx)(`div`, { className: f4.className, style: f4.style, children: t2 }), n2 ? (0, q2.jsx)(`div`, { className: p4.className, style: p4.style, children: n2 }) : null] }), h3 = a3 === void 0 ? (0, q2.jsx)(`div`, { className: u3.className, style: u3.style, children: m3 }) : c2 ? (0, q2.jsx)(`button`, { "aria-selected": r2, className: u3.className, disabled: o3, onClick: a3, role: `option`, style: u3.style, type: `button`, children: m3 }) : (0, q2.jsx)(`button`, { className: u3.className, disabled: o3, onClick: a3, style: u3.style, type: `button`, children: m3 }); - return (0, q2.jsx)(`li`, { className: l4.className, role: c2 ? `presentation` : void 0, style: l4.style, children: h3 }); -} -function Cp2({ children: e9, color: t2 = `primary`, rootStyle: n2, style: r2, ...i3 }) { - Cp2.d = 435937055; - let { titleId: a3 } = cp2(`Dialog.Title`); - return (0, q2.jsx)(Kd, { as: `h2`, id: a3, size: `lg`, color: t2, ...i3, rootStyle: [Gf(), n2], className: `ui-dialog-title`, style: r2, children: e9 }); -} -var wp2 = (e9) => e9 === `hidden` || e9 === `clip`; -function Tp2() { - if (typeof document2 > `u` || document2.body === null) return true; - let e9 = getComputedStyle2(document2.documentElement), t2 = e9.overflowX === `visible` && e9.overflowY === `visible` ? getComputedStyle2(document2.body) : e9; - return !wp2(t2.overflowX) || !wp2(t2.overflowY); +function uy() { + return Q2(Av, j_()); } -function Ep2(e9) { - let t2 = J2.Children.toArray(e9).filter(J2.isValidElement), n2 = false, r2 = false; - for (let e10 = 0; e10 < t2.length; e10 += 1) t2[e10].type === fp2 && (e10 === 0 && (r2 = true), e10 > 0 && t2[e10 - 1]?.type === hp2 && (n2 = true, r2 = true)); - return { headerBeforeContent: n2, contentHasCompactTopPadding: r2 }; +function dy() { + return Q2(Mv, b_()); } -function Dp2(e9) { - return e9 === void 0 ? { top: 40, right: 40, bottom: 40, left: 40 } : typeof e9 == `number` ? { top: e9, right: e9, bottom: e9, left: e9 } : { top: e9.top ?? 0, right: e9.right ?? 0, bottom: e9.bottom ?? 0, left: e9.left ?? 0 }; -} -function Op2(e9, t2, n2 = 1024, r2 = window2) { - let i3 = r2.innerWidth - t2.left - t2.right, a3 = n2 === null ? i3 : Math.min(i3, n2), o3 = r2.innerHeight - t2.top - t2.bottom, s3 = a3, c2 = a3 / e9; - c2 > o3 && (c2 = o3, s3 = o3 * e9); - let l4 = t2.left + (i3 - s3) / 2, u3 = t2.top + (o3 - c2) / 2; - return { width: s3, height: c2, top: u3, left: l4 }; -} -function kp2(e9, t2, n2) { - return t2 <= 0 ? `none` : e9.map((e10) => `${e10} ${t2}ms ${n2}`).join(`, `); -} -function Ap2(e9) { - return e9.button === 0 && !e9.ctrlKey; -} -var jp2 = [`[data-popup-open]`, `[data-component="select-positioner"][data-open]`, `[data-component="select-popup"][data-open]`, `[data-component="menu-popup"][data-open]`, `[role="listbox"][data-open]`, `[role="menu"][data-open]`].join(`, `); -function Mp2(e9) { - return e9.querySelector(jp2) !== null; -} -function Np2(e9, t2) { - return e9?.ownerDocument ?? t2?.ownerDocument ?? (typeof document2 > `u` ? null : document2); -} -function Pp2({ children: e9, size: t2 = `md`, width: n2, open: r2, defaultOpen: i3 = false, onOpenChange: a3, role: o3 = `dialog`, "aria-label": s3, "aria-labelledby": c2, "aria-describedby": l4, "data-presentation": u3, "data-block-global-shortcuts": d3, className: f4, backdropClassName: p4, rootStylexStyles: m3, backdropStylexStyles: h3, fullscreenTransition: g3, fullscreenBackdropTransition: v3, style: y3, closeOnBackdropClick: b3 = true, closeOnOutsidePress: S3 = true, closeOnEscape: C2 = true, disableFocusTrap: w3 = false, modal: T3 = true, lockScroll: D2 = true, ref: O3, animationSource: k4, fullscreenCloseInPlace: A3 = false, aspectRatio: j3, fullscreenViewportPadding: M3, fullscreenMaxWidth: N2, onAnimationComplete: P2, onTransitionStatusChange: F2, transitionDuration: L, initialFocus: R3, returnFocus: z4, onKeyDown: B4, dialogRootTabIndex: te3 = -1 }) { - Pp2.d = 883096921; - let [ne3, re4] = (0, J2.useState)(i3), ie4 = r2 !== void 0, V4 = ie4 ? r2 : ne3, H4 = bi(), [U4, oe5] = (0, J2.useState)(null), [se5, ce5] = (0, J2.useState)(true), [le4, ue4] = (0, J2.useState)(false); - if (V4 !== le4 && (ue4(V4), V4)) { - ce5(Tp2()); - let e10 = H4?.ownerDocument ?? (typeof document2 > `u` ? null : document2), t3 = e10?.activeElement ?? null, n3 = t3?.ownerDocument.defaultView ?? null; - oe5(t3 !== null && n3 !== null && t3 instanceof n3.HTMLElement && t3 !== e10?.body && t3.closest(`[role="menu"],[role="listbox"]`) === null ? t3 : null); - } - let de5 = (0, J2.useRef)(null); - (0, J2.useLayoutEffect)(() => { - de5.current = U4; - }, [U4]); - let W4 = t2 === `fullscreen`, fe5 = Zr(), pe5 = g3?.durationMs ?? ap2, me5 = g3?.easing ?? op2, he5 = v3?.durationMs ?? pe5, ge4 = v3?.easing ?? me5, [_e4, ve4] = (0, J2.useState)(`idle`), [ye4, be4] = (0, J2.useState)(false), [xe4, Se4] = (0, J2.useState)(null), Ce4 = k4 != null, we4 = (0, J2.useRef)(null), Te3 = (0, J2.useRef)(null), Ee4 = (0, J2.useRef)(P2); - (0, J2.useEffect)(() => { - Ee4.current = P2; - }, [P2]); - let De4 = (0, J2.useRef)(F2); - (0, J2.useEffect)(() => { - De4.current = F2; - }, [F2]); - let Oe4 = (0, J2.useCallback)((e10) => { - ie4 || re4(e10), a3?.(e10); - }, [ie4, a3]), ke4 = (0, J2.useRef)(null), Ae4 = (0, J2.useCallback)(() => { - let e10 = Np2(H4, ke4.current); - if (e10 === null) return true; - let t3 = (H4 ?? e10.body).querySelectorAll(`[data-ui-dialog-root]`); - return t3.item(t3.length - 1) === ke4.current; - }, [H4]); - (0, J2.useEffect)(() => { - if (!W4 || !V4 || !Ce4) return; - Te3.current &&= (clearTimeout(Te3.current), null), ve4(`expanding`), Se4(null); - let e10 = null, t3 = null; - return e10 = requestAnimationFrame2(() => { - t3 = requestAnimationFrame2(() => { - be4(true); +function fy(e38, t2) { + return Q2(Fv2, [P_(e38), t2]); +} +function py() { + return Q2(Iv2, F_()); +} +function my() { + return Q2(Lv2, f_()); +} +function hy() { + return Q2(Rv2, p_()); +} +var gy = `submenuOpenChange`; +var _y = (0, Y2.createContext)(null); +function vy(e38) { + return Math.max(e38, 100); +} +function yy() { + return (0, Y2.use)(_y); +} +function by({ children: e38, layerNodeId: t2, placement: n2 = `right-start`, controlledTargetId: r2 }) { + by.d = 3068902388; + let i3 = kf(), [a3, o3] = (0, Y2.useState)(/* @__PURE__ */ new Set()); + (0, Y2.useEffect)(() => { + if (!i3) return; + let e39 = (e40) => { + e40.parentId === t2 && o3((t3) => { + let n3 = new Set(t3); + return e40.isOpen ? n3.add(e40.nodeId) : n3.delete(e40.nodeId), n3; }); - }), we4.current = setTimeout(() => { - ve4(`expanded`), Ee4.current?.(); - }, pe5), () => { - e10 !== null && cancelAnimationFrame2(e10), t3 !== null && cancelAnimationFrame2(t3), we4.current && clearTimeout(we4.current); }; - }, [W4, V4, Ce4, pe5]); - let je4 = (0, J2.useCallback)(() => { - W4 && _e4 !== `collapsing` && (we4.current &&= (clearTimeout(we4.current), null), ve4(`collapsing`), Se4(A3), be4(false), Te3.current = setTimeout(() => { - Oe4(false), ve4(`idle`), Te3.current = null, Ee4.current?.(); - }, pe5)); - }, [W4, _e4, A3, Oe4, pe5]); - (0, J2.useEffect)(() => () => { - we4.current && clearTimeout(we4.current), Te3.current && clearTimeout(Te3.current); - }, []); - let { refs: Me3, context: Ne3 } = ng({ open: V4, onOpenChange: W4 ? (e10) => { - e10 ? Oe4(true) : je4(); - } : Oe4 }), Pe3 = Am([Me3.setFloating, ke4, O3]), Fe4 = Xh(Ne3), Le4 = eg(Ne3, { outsidePressEvent: `mousedown`, outsidePress: b3 && S3 ? (e10) => Ap2(e10) && Ae4() : false, escapeKey: false }), Re4 = pg(Ne3, { role: o3 }), { getFloatingProps: ze4 } = ig([Fe4, Le4, Re4]), Be4 = ze4(), Ve4 = L ?? Cf.slow, { isMounted: He4, status: We4 } = _g(Ne3, { duration: W4 ? pe5 : Ve4 }), Ke5 = (0, J2.useRef)(We4); - (0, J2.useLayoutEffect)(() => { - De4.current?.(We4); - }, [We4]); - let { titleId: qe4, descriptionId: Je4 } = up2(), [Xe4, Ze4] = (0, J2.useState)(false), [Qe4, $e4] = (0, J2.useState)(false); - (0, J2.useLayoutEffect)(() => { - let e10 = ke4.current; - Ze4(e10 !== null && e10.querySelector(`[id="${qe4}"]`) !== null), $e4(e10 !== null && e10.querySelector(`[id="${Je4}"]`) !== null); - }); - let et4 = (0, J2.useMemo)(() => Ep2(e9), [e9]), tt4 = (0, J2.useMemo)(() => ({ titleId: qe4, descriptionId: Je4, onOpenChange: W4 ? (e10) => { - e10 || je4(); - } : Oe4, headerBeforeContent: et4.headerBeforeContent, contentHasCompactTopPadding: et4.contentHasCompactTopPadding }), [qe4, Je4, Oe4, W4, je4, et4.headerBeforeContent, et4.contentHasCompactTopPadding]), nt5 = Dp2(M3), rt4 = (0, J2.useMemo)(() => ({ top: nt5.top, right: nt5.right, bottom: nt5.bottom, left: nt5.left }), [nt5.top, nt5.right, nt5.bottom, nt5.left]), it4 = (0, J2.useMemo)(() => { - if (!W4 || !k4) return; - let e10 = Op2(j3 ?? k4.width / k4.height, rt4, N2, Np2(H4, ke4.current)?.defaultView ?? window2), t3 = k4.width / e10.width, n3 = k4.height / e10.height, r3 = k4.left + k4.width / 2, i4 = k4.top + k4.height / 2, a4 = e10.left + e10.width / 2, o4 = e10.top + e10.height / 2, s4 = r3 - a4, c3 = i4 - o4, l5 = !ye4, u4 = fe5 || (_e4 === `collapsing` || We4 === `close`) && (xe4 ?? A3), d4 = l5 && !u4, f5 = l5 || We4 === `close`, p5 = (k4.borderRadius ?? 8) / Math.max(t3, n3, 1e-3), m4 = d4 ? p5 : 8; - return { position: `fixed`, top: e10.top, left: e10.left, width: e10.width, height: e10.height, transform: d4 ? `translate(${s4}px, ${c3}px) scale(${t3}, ${n3})` : `translate(0, 0) scale(1, 1)`, ...u4 ? { opacity: +!f5 } : {}, transformOrigin: `center center`, borderRadius: `${m4}px`, overflow: `hidden`, transition: kp2([`transform`, `border-radius`, `opacity`], pe5, me5), willChange: d4 ? `transform, border-radius` : `auto`, contain: `layout` }; - }, [W4, k4, A3, xe4, _e4, j3, rt4, N2, ye4, We4, fe5, pe5, me5, H4]); - (0, J2.useEffect)(() => { - if (!W4 || _e4 !== `expanded` || !k4) return; - let e10 = ke4.current; - if (!e10) return; - let t3 = j3 ?? k4.width / k4.height, n3 = null, r3 = e10.ownerDocument.defaultView ?? window2, i4 = () => { - n3 = null; - let i5 = Op2(t3, rt4, N2, r3); - e10.style.top = `${i5.top}px`, e10.style.left = `${i5.left}px`, e10.style.width = `${i5.width}px`, e10.style.height = `${i5.height}px`; - }, a4 = () => { - n3 === null && (n3 = r3.requestAnimationFrame(i4)); + return i3.events.on(gy, e39), () => { + i3.events.off(gy, e39); + }; + }, [i3, t2]); + let s3 = a3.size > 0, c3 = (0, Y2.useMemo)(() => ({ hasOpenChild: s3 }), [s3]); + return (0, J2.jsx)(_y.Provider, { value: c3, children: (0, J2.jsx)(gu2, { controlledTargetId: r2, dismissOnScroll: r2 === void 0, offset: 6, placement: n2, sameAxisOnly: true, children: e38 }) }); +} +function xy({ content: e38, surfaceStyle: t2 }) { + return xy.d = 4290948419, (0, J2.jsx)(gu2.Popup, { surfaceClassName: Pv2, surfaceStyle: [M_(), t2], children: typeof e38 == `function` ? e38() : e38 }); +} +function Sy2({ children: e38, content: t2, contentKey: n2, targetId: r2, disabled: i3 = false, openDelay: a3 = 0, closeDelay: o3 = 0, surfaceStyle: s3 }) { + Sy2.d = 2798500293; + let c3 = (0, Y2.use)(_y); + return c3 == null ? (0, J2.jsx)(J2.Fragment, { children: e38 }) : (0, J2.jsx)(gu2.Trigger, { closeDelay: vy(o3), content: (0, J2.jsx)(xy, { content: t2, surfaceStyle: s3 }), contentKey: n2, targetId: r2, openDelay: a3, disabled: i3 || c3.hasOpenChild, children: e38 }); +} +function Cy2(e38, t2) { + let n2 = kf(), r2 = Of(); + (0, Y2.useEffect)(() => { + if (!n2 || e38 === void 0) return; + let i3 = { nodeId: e38, parentId: r2, isOpen: t2 }; + return n2.events.emit(gy, i3), () => { + t2 && n2.events.emit(gy, { nodeId: e38, parentId: r2, isOpen: false }); + }; + }, [n2, e38, r2, t2]); +} +function wy2({ children: e38, content: t2, contentKey: n2, targetId: r2, disabled: i3 = false, openDelay: a3 = 0, closeDelay: o3 = 0, interactive: s3 = true, surfaceStyle: c3 }) { + return wy2.d = 142246133, yy() == null ? s3 ? (0, J2.jsx)(Xl2, { closeDelay: vy(o3), content: t2, disabled: i3, offset: 6, openDelay: a3, placement: `right`, sameAxisOnly: true, surfaceStyle: [M_(), c3], children: e38 }) : (0, J2.jsx)(nv, { closeDelay: o3, content: t2, disabled: i3, offset: 6, openDelay: a3, placement: `right`, sameAxisOnly: true, children: e38 }) : (0, J2.jsx)(Sy2, { closeDelay: o3, content: t2, contentKey: n2, targetId: r2, disabled: i3, openDelay: a3, surfaceStyle: c3, children: e38 }); +} +function Ty2({ children: e38, disabled: t2 = false, leading: n2, trailing: r2, rightFallback: i3, trailingAccessory: a3, trailingHidden: o3 = false, wideLeft: s3 = false, leadingStyle: c3, contentStyle: l5, trailingStyle: u3 }) { + Ty2.d = 1332170080; + let d3 = r2 ?? i3, f4 = d3 != null || a3 != null, p4 = Zv({ wideLeft: s3 }, c3), m3 = Qv(l5), h4 = $v({ disabled: t2, trailingHidden: o3 }, u3); + return (0, J2.jsxs)(gi2, { iconSize: `base`, children: [n2 == null ? null : (0, J2.jsx)(`span`, { className: p4.className, style: p4.style, "data-component": `menu-item-left`, children: n2 }), (0, J2.jsx)(`div`, { className: m3.className, style: m3.style, "data-component": `menu-item-content`, children: e38 }), f4 ? (0, J2.jsxs)(`span`, { className: h4.className, style: h4.style, "data-component": `menu-item-right`, children: [d3, a3] }) : null] }); +} +var Ey2 = (0, Y2.createContext)(false); +function Dy2() { + return (0, Y2.useContext)(Ey2); +} +function Oy2(e38, t2, n2) { + let { searchValue: r2 } = R_(n2); + return t2 || !r2 || !e38 ? true : e38.toLowerCase().includes(r2.toLowerCase()); +} +var ky2 = new (_h2(`@@menu-item-noop`))({}); +var Ay2 = (0, Y2.createContext)(null); +function jy2() { + return (0, Y2.useContext)(Ay2); +} +function My2({ children: e38, label: t2, ignoreSearch: n2 = false, ...r2 }) { + My2.d = 2827429621; + let i3 = t2 ?? (typeof e38 == `string` ? e38 : ``); + return Oy2(i3, n2, `LegacyMenu.Item`) ? (0, J2.jsx)(Ny2, { ...r2, contextPart: `LegacyMenu.Item`, itemLabel: i3, children: e38 }) : null; +} +function Ny2({ children: e38, "data-testid": t2, "aria-haspopup": n2, "aria-expanded": r2, mentionMenuFlatIndex: i3, disabled: a3 = false, onMouseDown: o3, onAuxClick: s3, onSelect: c3, onKeyDown: l5, leading: u3, trailing: d3, tooltip: f4, tooltipDisabled: p4 = false, tooltipOpenDelay: m3 = 0, tooltipCloseDelay: h4 = 0, tooltipSurface: g5 = `default`, closeOnSelect: _5, description: v5, rootStyle: y4, leadingStyle: b2, contentStyle: x2, trailingStyle: S2, variant: C2 = `default`, trailingVisibility: w2 = `always`, selected: T2 = false, radioChecked: E2, indent: D2 = false, wideLeftSection: O2 = false, draggable: k2, ref: A2, itemLabel: N3, referenceRef: P3, itemPropsTransform: F2, trailingAccessory: I2, contextPart: L3 }) { + Ny2.d = 1610458420; + let { activeIndexStore: R3, shouldAllowPointerInteraction: z2, closeMenuLayersOnSelect: B3, setIsOpen: ee2, getItemProps: te2, closeOnSelect: ne3, virtualFocus: re3, activeDescendantIdPrefix: ie3 } = R_(L3), ae3 = Dy2(), V3 = Uh2(), H3 = Hc(), oe5 = V3 === `body`, se5 = _5 ?? ne3 ?? true, { ref: ce6, index: le6 } = lf({ label: N3 || null }), ue6 = z_(R3, le6), [de6, fe5] = (0, Y2.useState)(false); + yy(); + let U3 = (0, Y2.useRef)(null), pe5 = (0, Y2.useId)(), W3 = k2 != null, me5 = k2?.mode === `pointer`, he5 = (0, Y2.useSyncExternalStore)(vh2.subscribe, vh2.isDragActive, vh2.isDragActive), ge5 = (0, Y2.useRef)(null), _e5 = (0, Y2.useRef)(null), ve5 = (0, Y2.useRef)(null), ye5 = (0, Y2.useRef)(null), be5 = (0, Y2.useRef)(false), [xe5, Se5] = (0, Y2.useState)(null), { ref: Ce5, isDragging: we5 } = Ug({ id: k2?.id ?? `menu-item-${pe5}`, data: k2?.data ?? ky2, disabled: !W3 || me5 || (k2?.disabled ?? false), dragImageOffset: k2?.dragImageOffset, onDragStart: k2?.onDragStart, onDragEnd: k2?.onDragEnd }), Te5 = af([ce6, P3, A2, W3 && !me5 ? Ce5 : null]), Ee5 = (0, Y2.useCallback)((e39) => { + U3.current = e39; + }, []), De5 = (0, Y2.useMemo)(() => ({ setSubMenuOpen: fe5, isSubMenuOpen: de6, registerSubMenuOpener: Ee5 }), [de6, Ee5]), Oe5 = N_(g5); + (0, Y2.useEffect)(() => () => { + ge5.current?.(), ve5.current != null && cancelAnimationFrame2(ve5.current); + }, []); + let ke5 = (0, Y2.useCallback)(() => { + ve5.current = null; + let e39 = _e5.current, t3 = ye5.current; + e39 && t3 && (e39.style.transform = `translate3d(${t3.x + 8}px, ${t3.y + 8}px, 0)`); + }, []), Ae5 = (0, Y2.useCallback)((e39) => { + ye5.current = e39, ve5.current ??= requestAnimationFrame2(ke5); + }, [ke5]), G2 = (0, Y2.useCallback)((e39) => { + _e5.current = e39, ke5(); + }, [ke5]), je5 = () => { + if (a3) return; + let e39 = { defaultPrevented: false, preventDefault: () => { + e39.defaultPrevented = true; + } }; + c3?.(e39), se5 && !e39.defaultPrevented && B3(ee2); + }, Me5 = (e39) => { + if (be5.current) { + be5.current = false, e39.preventDefault(), e39.stopPropagation(); + return; + } + if (!z2(e39.nativeEvent)) { + e39.preventDefault(), e39.stopPropagation(); + return; + } + je5(); + }, Ne5 = (0, Y2.useCallback)((e39) => { + if (!z2(e39.nativeEvent)) { + e39.preventDefault(), e39.stopPropagation(); + return; + } + if (o3?.(e39), !e39.defaultPrevented) { + if (me5 && k2 != null && !k2.disabled && e39.button === 0) { + ge5.current?.(); + let t3 = vh2.getInstance(), n3 = e39.currentTarget, r3 = { clientX: e39.clientX, clientY: e39.clientY, isDragging: false }, i4 = () => { + document2.removeEventListener(`mousemove`, a4, true), document2.removeEventListener(`mouseup`, o4, true), ve5.current != null && (cancelAnimationFrame2(ve5.current), ve5.current = null), ye5.current = null, ge5.current = null, t3.clearData(), setTimeout(() => { + be5.current = false; + }, 0); + }, a4 = (e40) => { + let i5 = e40.clientX - r3.clientX, a5 = e40.clientY - r3.clientY; + if (!(!r3.isDragging && Math.hypot(i5, a5) < 4)) { + if (!r3.isDragging) { + r3.isDragging = true, be5.current = true, t3.setData(k2.data); + let i6 = n3.getBoundingClientRect().width; + Ae5({ x: e40.clientX, y: e40.clientY }), Se5(i6), k2.onPointerDragStart?.(e40); + } + e40.preventDefault(), Ae5({ x: e40.clientX, y: e40.clientY }), k2.onPointerDragMove?.(e40); + } + }, o4 = (e40) => { + if (!r3.isDragging) { + i4(); + return; + } + e40.preventDefault(), Se5(null), k2.onPointerDragEnd?.(e40), i4(); + }; + ge5.current = i4, document2.addEventListener(`mousemove`, a4, true), document2.addEventListener(`mouseup`, o4, true); + } + re3 && !W3 && e39.preventDefault(); + } + }, [k2, W3, me5, o3, Ae5, z2, re3]), Pe5 = (0, Y2.useCallback)((e39) => { + if (!z2(e39.nativeEvent)) { + e39.preventDefault(), e39.stopPropagation(); + return; + } + s3?.(e39); + }, [s3, z2]), Fe4 = (e39) => { + a3 || (l5?.(e39), !e39.defaultPrevented && ((e39.key === `Enter` || e39.key === ` `) && (e39.preventDefault(), e39.stopPropagation(), je5()), Og(e39.key, H3) === `end` && U3.current && (e39.preventDefault(), e39.stopPropagation(), U3.current()))); + }, Ie5 = te2({ ...Jh2(ie3, le6), onClick: Me5, onKeyDown: Fe4, onMouseDown: Ne5, onAuxClick: Pe5 }), Le5 = F2?.(Ie5) ?? Ie5, Re5 = d3 == null ? void 0 : (0, J2.jsx)(Ay2.Provider, { value: De5, children: d3 }), ze5 = ey(), Be5 = ty(), Ve5 = ny(), He5 = v5 == null ? e38 : (0, J2.jsxs)(`div`, { className: ze5.className, style: ze5.style, children: [(0, J2.jsx)(`div`, { className: Be5.className, style: Be5.style, children: e38 }), (0, J2.jsx)(`div`, { className: Ve5.className, style: Ve5.style, "data-component": `menu-item-description`, children: v5 })] }), Ue4 = p4 || he5 || de6, We4 = w2 === `focused` && (he5 || !ue6), Ge4 = Jv({ disabled: a3, expanded: r2 === true, focused: !he5 && ue6, indent: D2, inSubmenu: ae3, selected: T2, variant: C2 }, y4), Ke4 = { role: E2 === void 0 ? `menuitem` : `menuitemradio`, tabIndex: ue6 ? 0 : -1, ...E2 === void 0 ? {} : { "aria-checked": E2 }, ...n2 === void 0 ? {} : { "aria-haspopup": n2 }, ...r2 === void 0 ? {} : { "aria-expanded": r2 }, "aria-disabled": a3 || void 0, "data-component": `menu-row`, "data-expanded": r2 === true || void 0, draggable: !me5 && void 0, "data-disabled": a3 || void 0, "data-focused": !he5 && ue6 ? true : void 0, "data-menu-draggable": W3 || void 0, "data-selected": T2 || void 0, "data-has-description": v5 != null || void 0, "data-variant": C2 === "default" ? void 0 : C2, "data-indent": D2 || void 0, "data-wide-left": O2 || void 0, "data-dragging": we5 || xe5 != null || void 0, ...t2 ? { "data-testid": t2 } : {}, ...i3 === void 0 ? {} : { "data-mention-menu-flat-index": String(i3) }, [Bh2]: V3, className: Ge4.className, style: Ge4.style, ...Le5 }, qe4 = { className: `ui-u96u03 ui-47corl ui-ixxii4 ui-13vifvy ui-u1ixa1 ui-1so62im ui-18ivbjn` }, Je4 = xe5 != null && k2?.preview != null ? (0, br2.createPortal)((0, J2.jsx)(`div`, { "aria-hidden": `true`, ref: G2, className: qe4.className, style: { ...qe4.style, width: xe5 }, children: k2.preview }), document2.body) : null, Ye4 = oe5 ? (0, J2.jsxs)(`li`, { ref: Te5, ...Ke4, children: [(0, J2.jsx)(Ty2, { disabled: a3, leading: u3, trailing: Re5, trailingAccessory: I2, trailingHidden: We4, wideLeft: O2, leadingStyle: b2, contentStyle: x2, trailingStyle: S2, children: He5 }), Je4] }) : (0, J2.jsxs)(`div`, { ref: Te5, ...Ke4, children: [(0, J2.jsx)(Ty2, { disabled: a3, leading: u3, trailing: Re5, trailingAccessory: I2, trailingHidden: We4, wideLeft: O2, leadingStyle: b2, contentStyle: x2, trailingStyle: S2, children: He5 }), Je4] }); + return f4 == null ? Ye4 : (0, J2.jsx)(wy2, { closeDelay: h4, content: Ue4 ? null : f4, disabled: Ue4, openDelay: m3, surfaceStyle: Oe5, children: Ye4 }); +} +var Py2 = (0, Y2.createContext)(null); +function Fy2(e38) { + let t2 = (0, Y2.useContext)(Py2); + if (!t2) throw Error(`${e38} must be used within LegacyMenu.ExpandableSection`); + return t2; +} +function Iy2({ children: e38, defaultExpanded: t2 = false, expanded: n2, onExpandedChange: r2 }) { + Iy2.d = 1066343140; + let [i3, a3] = (0, Y2.useState)(t2), o3 = n2 !== void 0, s3 = o3 ? n2 : i3, c3 = (e39) => { + o3 || a3(e39), r2?.(e39); + }; + return (0, J2.jsx)(Py2.Provider, { value: { expanded: s3, setExpanded: c3, toggle: () => c3(!s3) }, children: e38 }); +} +function Ly2({ children: e38, contentStyle: t2, leading: n2, leadingStyle: r2, rootStyle: i3, trailing: a3, trailingStyle: o3, label: s3 }) { + Ly2.d = 2319365689; + let { expanded: c3, setExpanded: l5, toggle: u3 } = Fy2(`LegacyMenu.ExpandableSectionTrigger`), d3 = Hc(), f4 = typeof n2 == `function` ? n2(c3) : n2; + return (0, J2.jsx)(My2, { closeOnSelect: false, contentStyle: t2, wideLeftSection: true, leading: f4, leadingStyle: r2, rootStyle: i3, trailing: a3, trailingStyle: o3, label: s3 ?? (typeof e38 == `string` ? e38 : void 0), onKeyDown: (e39) => { + let t3 = Og(e39.key, d3); + if (t3 === `end` && !c3) { + e39.preventDefault(), e39.stopPropagation(), l5(true); + return; + } + t3 === `start` && c3 && (e39.preventDefault(), e39.stopPropagation(), l5(false)); + }, onSelect: u3, children: e38 }); +} +function Ry2({ children: e38 }) { + Ry2.d = 4074756870; + let { expanded: t2 } = Fy2(`LegacyMenu.ExpandableSectionContent`); + return t2 ? (0, J2.jsx)(J2.Fragment, { children: e38 }) : null; +} +function zy2({ children: e38, label: t2, ignoreSearch: n2, ...r2 }) { + zy2.d = 1791708490; + let i3 = t2 ?? (typeof e38 == `string` ? e38 : ``); + return Oy2(i3, n2, `LegacyMenu.CheckboxItem`) ? (0, J2.jsx)(By2, { ...r2, itemLabel: i3, children: e38 }) : null; +} +function By2({ children: e38, "data-testid": t2, checked: n2, defaultChecked: r2 = false, onChange: i3, disabled: a3 = false, trailing: o3, description: s3, tooltip: c3, tooltipOpenDelay: l5 = 0, tooltipCloseDelay: u3 = 0, tooltipSurface: d3 = `default`, closeOnSelect: f4, itemLabel: p4, rootStyle: m3, contentStyle: h4, trailingStyle: g5 }) { + By2.d = 3759209987; + let { activeIndexStore: _5, shouldAllowPointerInteraction: v5, closeMenuLayersOnSelect: y4, getItemProps: b2, setIsOpen: x2, closeOnSelect: S2, activeDescendantIdPrefix: C2 } = R_(`LegacyMenu.CheckboxItem`), w2 = Dy2(), T2 = Uh2(), E2 = T2 === `body`, D2 = f4 ?? S2 ?? false, [O2, k2] = (0, Y2.useState)(r2), A2 = n2 !== void 0, j2 = A2 ? n2 : O2, { ref: N3, index: P3 } = lf({ label: p4 || null }), F2 = z_(_5, P3), I2 = yy(), L3 = N_(d3), R3 = (0, Y2.useCallback)(() => { + if (a3) return; + let e39 = !j2; + A2 || k2(e39); + let t3 = { defaultPrevented: false, preventDefault: () => { + t3.defaultPrevented = true; + } }; + i3?.(e39, t3), D2 && !t3.defaultPrevented && y4(x2); + }, [a3, j2, A2, i3, D2, x2, y4]), z2 = (0, Y2.useCallback)((e39) => { + if (!v5(e39.nativeEvent)) { + e39.preventDefault(), e39.stopPropagation(); + return; + } + e39.preventDefault(), e39.stopPropagation(), R3(); + }, [R3, v5]), B3 = (0, Y2.useCallback)((e39) => { + a3 || (e39.key === `Enter` || e39.key === ` `) && (e39.preventDefault(), e39.stopPropagation(), R3()); + }, [a3, R3]), ee2 = b2({ ...Jh2(C2, P3), onClick: z2, onKeyDown: B3 }), te2 = s3 != null, ne3 = Jv({ disabled: a3, focused: F2, inSubmenu: w2 }, m3), re3 = { role: `menuitemcheckbox`, "aria-checked": j2, tabIndex: F2 ? 0 : -1, "aria-disabled": a3 || void 0, "data-checked": j2 || void 0, "data-component": `menu-row`, "data-disabled": a3 || void 0, "data-focused": F2 || void 0, "data-has-description": te2 || void 0, ...t2 ? { "data-testid": t2 } : {}, [Bh2]: T2, className: ne3.className, style: ne3.style, ...ee2 }, ie3 = (0, J2.jsx)(To2, { checked: j2, disabled: a3 }), ae3 = ey(), V3 = ty(), H3 = ny(), oe5 = te2 ? (0, J2.jsxs)(`div`, { className: ae3.className, style: ae3.style, children: [(0, J2.jsx)(`div`, { className: V3.className, style: V3.style, children: e38 }), (0, J2.jsx)(`div`, { className: H3.className, style: H3.style, "data-component": `menu-item-description`, children: s3 })] }) : e38, se5 = (0, J2.jsx)(Ty2, { disabled: a3, leading: ie3, trailing: o3, contentStyle: h4, trailingStyle: g5, children: oe5 }), ce6 = c3 != null && I2 != null, le6 = E2 ? (0, J2.jsx)(`li`, { ref: N3, ...re3, children: se5 }) : (0, J2.jsx)(`div`, { ref: N3, ...re3, children: se5 }); + return ce6 ? (0, J2.jsx)(Sy2, { closeDelay: u3, content: c3, openDelay: l5, surfaceStyle: L3, children: le6 }) : c3 == null ? le6 : (0, J2.jsx)(Xl2, { content: c3, placement: `right`, offset: 6, openDelay: l5, closeDelay: vy(u3), sameAxisOnly: true, surfaceStyle: [M_(), L3], children: le6 }); +} +function Vy2(e38, t2) { + if (!t2?.length || !e38.dataTransfer) return false; + for (let n2 of e38.dataTransfer.types) for (let e39 of t2) if (n2.toLowerCase() === e39.toLowerCase()) return true; + return false; +} +function Hy2(e38) { + return e38 !== null && `nodeType` in e38; +} +function Uy2(e38, t2) { + let n2 = e38.relatedTarget; + if (Hy2(n2) && t2.contains(n2)) return false; + let r2 = t2.defaultView; + return !r2 || e38.clientX <= 0 || e38.clientY <= 0 || e38.clientX >= r2.innerWidth || e38.clientY >= r2.innerHeight; +} +function Wy2(e38) { + let { accept: t2, disabled: n2 = false, acceptData: r2, acceptNativeTypes: i3, onDragEnter: a3, onDragOver: o3, onDragLeave: s3, onDrop: c3 } = e38, l5 = (0, Y2.useRef)(null), u3 = (0, Y2.useRef)(null), d3 = (0, Y2.useRef)(0), f4 = (0, Y2.useRef)(null), [p4, m3] = (0, Y2.useState)(false), [h4, g5] = (0, Y2.useState)(false), _5 = (0, Y2.useRef)(p4); + _5.current = p4; + let v5 = (0, Y2.useCallback)(() => { + d3.current = 0, m3(false), g5(false); + }, []), y4 = (0, Y2.useCallback)(() => { + f4.current !== null && (cancelAnimationFrame2(f4.current), f4.current = null); + }, []); + (0, Y2.useEffect)(() => { + if (!p4) return; + let e39 = u3.current?.ownerDocument ?? document2, t3 = () => { + y4(), v5(); + }; + return e39.addEventListener(`mousemove`, t3, true), () => { + e39.removeEventListener(`mousemove`, t3, true); + }; + }, [p4, y4, v5]); + let b2 = (0, Y2.useRef)({ onDragEnter: a3, onDragOver: o3, onDragLeave: s3, onDrop: c3 }); + b2.current = { onDragEnter: a3, onDragOver: o3, onDragLeave: s3, onDrop: c3 }; + let x2 = (0, Y2.useRef)(i3); + x2.current = i3; + let S2 = (0, Y2.useRef)(Array.isArray(t2) ? t2 : [t2]); + S2.current = Array.isArray(t2) ? t2 : [t2]; + let C2 = (0, Y2.useRef)(r2); + C2.current = r2; + let w2 = (0, Y2.useCallback)((e39) => { + if (u3.current = e39, l5.current &&= (l5.current(), null), d3.current = 0, e39 !== null && (m3(false), g5(false)), !e39 || n2) return; + let t3 = vh2.getInstance(), r3 = () => { + if (n2) return null; + let e40 = t3.getValidatedData(S2.current); + return e40 && (C2.current?.(e40) ?? true) ? e40 : null; + }, i4 = (e40) => { + if (d3.current++, d3.current === 1) { + m3(true); + let t4 = r3(); + g5(t4 !== null || !n2 && Vy2(e40, x2.current)), b2.current.onDragEnter?.(e40, t4); + } + }, a4 = (e40) => { + d3.current = Math.max(0, d3.current - 1), d3.current === 0 && (y4(), v5(), b2.current.onDragLeave?.(e40)); + }, o4 = (e40) => { + let t4 = r3(), i5 = t4 !== null, a5 = !i5 && !n2 && Vy2(e40, x2.current); + (i5 || a5) && (e40.preventDefault(), e40.dataTransfer && (e40.dataTransfer.dropEffect = i5 ? `move` : `copy`), d3.current === 0 && (d3.current = 1, m3(true), g5(true), b2.current.onDragEnter?.(e40, t4)), b2.current.onDragOver && f4.current === null && (f4.current = requestAnimationFrame2(() => { + f4.current = null, b2.current.onDragOver?.(e40, t4); + }))); + }, s4 = (e40) => { + e40.preventDefault(), y4(), v5(); + let t4 = r3(); + if (t4) { + let { onDrop: n3 } = b2.current; + n3 && (n3(e40, t4), e40.stopPropagation()); + } else if (Vy2(e40, x2.current)) { + let { onDrop: t5 } = b2.current; + t5 && (t5(e40, null), e40.stopPropagation()); + } + }; + e39.addEventListener(`dragenter`, i4), e39.addEventListener(`dragleave`, a4), e39.addEventListener(`dragover`, o4), e39.addEventListener(`drop`, s4); + let c4 = e39.ownerDocument, p5 = () => { + (d3.current !== 0 || _5.current) && (y4(), v5()); + }, h5 = () => p5(), w3 = () => p5(), T2 = (e40) => { + Uy2(e40, c4) && p5(); + }; + c4.addEventListener(`drop`, h5, true), c4.addEventListener(`dragend`, w3, true), c4.addEventListener(`dragleave`, T2, true), l5.current = () => { + e39.removeEventListener(`dragenter`, i4), e39.removeEventListener(`dragleave`, a4), e39.removeEventListener(`dragover`, o4), e39.removeEventListener(`drop`, s4), c4.removeEventListener(`drop`, h5, true), c4.removeEventListener(`dragend`, w3, true), c4.removeEventListener(`dragleave`, T2, true), f4.current !== null && (cancelAnimationFrame2(f4.current), f4.current = null); + }; + }, [n2, v5, y4]); + return (0, Y2.useEffect)(() => () => { + l5.current &&= (l5.current(), null); + }, []), { ref: w2, isOver: p4, canDrop: h4, isDropBlocked: p4 && !h4 }; +} +function Gy2() { + let e38 = (0, Y2.useRef)(true), t2 = (0, Y2.useRef)(void 0), n2 = (0, Y2.useCallback)(() => { + t2.current !== void 0 && (clearTimeout(t2.current), t2.current = void 0); + }, []), r2 = (0, Y2.useCallback)((r3, i3) => { + e38.current && (n2(), t2.current = setTimeout(() => { + t2.current = void 0, r3(); + }, i3)); + }, [n2]); + return (0, Y2.useEffect)(() => (e38.current = true, () => { + e38.current = false, n2(); + }), [n2]), (0, Y2.useMemo)(() => ({ cancel: n2, schedule: r2 }), [n2, r2]); +} +var Ky2 = 300; +var qy2 = (0, Y2.createContext)(null); +function Jy2({ children: e38 }) { + Jy2.d = 2050389404; + let [t2, n2] = (0, Y2.useState)(null), r2 = Gy2(), i3 = (0, Y2.useCallback)((e39) => { + r2.cancel(), n2(e39); + }, [r2]), a3 = (0, Y2.useCallback)((e39) => { + r2.schedule(() => { + n2((t3) => t3 === e39 ? null : t3); + }, Ky2); + }, [r2]), o3 = (0, Y2.useMemo)(() => ({ activeId: t2, markOpen: i3, markClosed: a3 }), [t2, i3, a3]); + return (0, J2.jsx)(qy2.Provider, { value: o3, children: e38 }); +} +function Yy2(e38, t2) { + let n2 = (0, Y2.useContext)(qy2), r2 = n2?.markOpen, i3 = n2?.markClosed; + return (0, Y2.useEffect)(() => { + if (t2 && e38 != null && r2 != null && i3 != null) return r2(e38), () => i3(e38); + }, [t2, e38, r2, i3]), { activeId: n2?.activeId ?? null }; +} +var Xy2 = (0, Y2.createContext)(null); +function Zy2(e38) { + let t2 = (0, Y2.useContext)(Xy2); + if (!t2) throw Error(`${e38} must be used within LegacyMenu.SubMenu`); + return t2; +} +function Qy2() { + return Zy2(`LegacyMenu.SubMenu.useContext`); +} +function $y2() { + let e38 = (0, Y2.useContext)(Xy2) != null, { setIsOpen: t2, dismissCauseRef: n2 } = xg(); + return (0, Y2.useCallback)((r2) => { + n2.current = `selection`, r2(false), e38 && t2(false); + }, [e38, t2, n2]); +} +var eb2 = _h2(`@@menu-content-noop`); +function tb2({ children: e38, header: t2, footer: n2, attachment: r2, "aria-label": i3, popupRole: a3 = `menu`, "data-testid": o3, className: s3, surfaceStyle: c3, contentStyle: l5, layoutStyle: u3, listStyle: d3, scrollAreaStyles: f4, style: p4, dropIndicatorTop: m3, maxHeight: h4, width: g5, minWidth: _5, maxWidth: v5, tooltipPlacement: y4, size: b2, backdrop: x2, adaptiveHeight: S2 = true, returnFocus: w2, onKeyDownCapture: T2, onBodyPointerEnter: E2, droppable: D2, ref: O2 }) { + tb2.d = 2595077711; + let k2 = _i2(), { isOpen: A2, isMounted: M2, activeIndex: N3, setActiveIndex: P3, setIsOpen: F2, markKeyboardNavigation: L3, markPointerNavigation: R3, virtualFocus: z2, searchValue: B3, setSearchValue: ee2, hasSearchInput: te2, searchInputRef: ne3, enableHover: re3, closeOnSelect: ie3, nodeId: ae3, activeDescendantIdPrefix: V3, listRef: H3, labelsRef: oe5, refs: se5, floatingStyles: ce6, middlewareData: le6, transitionStyles: ue6, context: de6, getFloatingProps: fe5, getItemProps: U3, dismissCauseRef: pe5, returnFocusOnSelect: W3, returnFocus: me5, shouldAllowPointerInteraction: he5 } = bg(`LegacyMenu.Content`), ge5 = $y2(), _e5 = x2 ?? !re3, [ve5, ye5] = (0, Y2.useState)(null), be5 = z2 && !te2, xe5 = gg(), Se5 = (0, Y2.useSyncExternalStore)(vh2.subscribe, vh2.isDragActive, vh2.isDragActive), Ce5 = de6.placement.startsWith(`top`), we5 = le6.bottomAnchor?.bottom, Te5 = Ce5 && M2 && typeof we5 == `number` ? we5 : null, Ee5 = (0, Y2.useRef)(null), De5 = (0, Y2.useRef)(N3), Oe5 = (0, Y2.useRef)(false); + (0, Y2.useLayoutEffect)(() => { + De5.current = N3; + }, [N3]), (0, Y2.useLayoutEffect)(() => { + if (!A2) { + Oe5.current = false; + return; + } + let e39 = (e40) => { + Kh2(e40) && (Oe5.current = true, L3()); + }, t3 = (e40) => { + let t4 = $h(e40, H3); + t4 != null && t4 !== De5.current && P3(t4); + }, n3 = (e40) => { + let n4 = Oe5.current; + Oe5.current = false, R3(), n4 && t3(e40.target); + }; + document2.addEventListener(`keydown`, e39, true); + let r3 = eg(ve5, n3); + return () => { + document2.removeEventListener(`keydown`, e39, true), r3(); + }; + }, [A2, H3, L3, R3, ve5, P3]), (0, Y2.useLayoutEffect)(() => { + if (!A2) { + Ee5.current = null; + return; + } + if (!z2 || N3 == null || Ee5.current === N3 || (Ee5.current = N3, !Oe5.current)) return; + let e39 = H3.current[N3] ?? null; + if (!e39) return; + let t3 = requestAnimationFrame2(() => { + e39.scrollIntoView({ block: `nearest`, inline: `nearest` }); + }); + return () => cancelAnimationFrame2(t3); + }, [A2, z2, N3, H3]); + let ke5 = (0, Y2.useCallback)((e39) => { + if (e39.key === `Escape`) { + pe5.current = `escape`; + return; + } + if (e39.ctrlKey && !e39.metaKey) { + let t3 = e39.key.toLowerCase(), n3 = t3 === `n` || t3 === `j`; + if (n3 || t3 === `p` || t3 === `k`) { + e39.preventDefault(); + let t4 = H3.current, r3 = t4.length; + if (r3 === 0) return; + let i4 = De5.current, a4 = n3 ? 1 : -1, o4 = i4 == null ? n3 ? 0 : r3 - 1 : i4 + a4; + for (; o4 >= 0 && o4 < r3; ) { + if (t4[o4] != null) { + P3(o4); + return; + } + o4 += a4; + } + return; + } + } + if (te2 && e39.key.length === 1 && !e39.ctrlKey && !e39.metaKey && !e39.altKey) { + if (document2.activeElement === ne3.current) return; + e39.preventDefault(), e39.stopPropagation(), ne3.current?.focus(), ee2(B3 + e39.key), Qh(H3, `body`, P3); + } + }, [pe5, te2, H3, ne3, B3, P3, ee2]), Ae5 = (0, Y2.useCallback)((e39) => { + xe5(e39.nativeEvent) && (pe5.current = `backdrop`, F2(false)); + }, [pe5, F2, xe5]), G2 = (0, Y2.useCallback)((e39) => { + if (e39.stopPropagation(), !xe5(e39.nativeEvent)) return; + e39.preventDefault(), pe5.current = `backdrop`, F2(false); + let t3 = document2.elementsFromPoint(e39.clientX, e39.clientY).find((e40) => !e40.classList.contains(sv2)); + t3 && t3.dispatchEvent(new MouseEvent(`contextmenu`, { bubbles: true, cancelable: true, view: window2, clientX: e39.clientX, clientY: e39.clientY, screenX: e39.screenX, screenY: e39.screenY, button: e39.button, buttons: e39.buttons, ctrlKey: e39.ctrlKey, shiftKey: e39.shiftKey, altKey: e39.altKey, metaKey: e39.metaKey })); + }, [pe5, F2, xe5]), je5 = D2 != null, { ref: Me5, isOver: Ne5, isDropBlocked: Pe5 } = Wy2({ accept: D2?.accept ?? eb2, disabled: !je5 || (D2?.disabled ?? false), onDragEnter: D2?.onDragEnter, onDragOver: D2?.onDragOver, onDragLeave: D2?.onDragLeave, onDrop: D2?.onDrop }), Fe4 = af([se5.setFloating, ye5, O2, je5 ? Me5 : null]), Ie5 = Ni2(), { zIndex: Le5, portalLayerStyles: ze5 } = Gi2(`popover`, M2); + if (!M2) return null; + let Be5 = b2 ?? k2?.menuSize ?? `sm`, Ve5 = { ...ce6, ...ue6, ...ze5, ...Le5 === null ? {} : { zIndex: Le5 }, ...p4, ...m3 === void 0 ? {} : { "--ui-menu-drop-indicator-top": `${m3}px` }, ...fg({ width: g5, minWidth: _5, maxWidth: v5 }), ...Ce5 && Te5 !== null ? { top: `auto`, bottom: Te5 } : {}, ...pg({ isOpen: A2, isPositioned: de6.isPositioned }) }, He5 = { ...ze5, ...Le5 === null ? {} : { zIndex: Le5 - 1 }, pointerEvents: je5 && Se5 ? `none` : void 0 }, Ue4 = S2 ? sg(h4) : h4, We4 = r2 != null, Ge4 = a3 === `dialog`, Ke4 = Bv(He5), qe4 = zv({ className: s3, hasDropIndicator: m3 !== void 0, size: Be5, surfaceStyle: c3, style: We4 && Ue4 !== void 0 ? { ...Ve5, maxHeight: Ue4 } : Ve5, hasAttachment: We4 }), Je4 = Wv(We4 || Ue4 === void 0 ? void 0 : { maxHeight: Ue4 }, We4, u3), Ye4 = Kv(), Xe4 = Hv2(l5), Ze4 = Vv(false, d3), Qe4 = qv(), $e4 = Gv(), et4 = Uv(); + return (0, J2.jsxs)(ap, { ...Ie5 ? { root: Ie5 } : {}, children: [_e5 && (0, J2.jsx)(`div`, { className: Ke4.className, style: Ke4.style, "data-component": `menu-backdrop`, onClick: Ae5, onContextMenu: G2, role: `none` }), (0, J2.jsx)(gp, { context: de6, initialFocus: be5 ? -1 : ne3, returnFocus: w2 ?? me5 ?? (pe5.current !== `backdrop` && (pe5.current !== `selection` || W3)), modal: !be5, children: (0, J2.jsxs)(`div`, { ref: Fe4, className: qe4.className, style: qe4.style, tabIndex: -1, "data-component": `menu-popup`, "data-size": Be5, "data-drop-active": je5 && Ne5 && !Pe5 ? `` : void 0, "data-drop-blocked": je5 && Pe5 ? `` : void 0, ...o3 ? { "data-testid": o3 } : {}, ...We4 ? { "aria-label": i3 ?? `Menu` } : {}, ...fe5({ ...Ge4 ? { role: `dialog`, "aria-label": i3 ?? `Menu`, "aria-labelledby": void 0, "aria-orientation": void 0 } : {}, onKeyDown: ke5, onKeyDownCapture: T2, onMouseDown: z2 ? (e39) => { + e39.stopPropagation(); + } : void 0 }), children: [je5 && D2?.indicator != null ? (0, J2.jsx)(`div`, { "aria-hidden": `true`, className: et4.className, style: et4.style, children: D2.indicator }) : null, (0, J2.jsx)(gi2, { menuSize: Be5, children: (0, J2.jsx)(nu2, { dismiss: !A2, children: (0, J2.jsx)(by, { layerNodeId: ae3, placement: y4, children: (0, J2.jsx)(B_, { activeIndex: N3, setIsOpen: F2, getItemProps: U3, searchValue: B3, closeOnSelect: ie3, virtualFocus: z2, activeDescendantIdPrefix: V3, shouldAllowPointerInteraction: he5, closeMenuLayersOnSelect: ge5, children: (0, J2.jsx)(Jy2, { children: (0, J2.jsxs)(cf, { elementsRef: H3, labelsRef: oe5, children: [(0, J2.jsxs)(`div`, { className: Je4.className, style: Je4.style, "data-component": `menu-layout`, ...We4 || Ge4 ? {} : { role: `menu`, "aria-label": i3 ?? `Menu` }, children: [t2 == null ? null : (0, J2.jsx)(`div`, { className: Ye4.className, style: Ye4.style, "data-component": `menu-header`, children: (0, J2.jsx)(Hh2, { value: `header`, children: t2 }) }), (0, J2.jsx)(Cc2, { className: fv2, rootStyle: [c_(), f4?.root], viewportStyle: f4?.viewport, contentStyle: f4?.content, maxHeight: `none`, "data-component": `menu-body-scroll`, children: (0, J2.jsx)(`div`, { className: Xe4.className, style: Xe4.style, "data-component": `menu-content`, onPointerEnter: E2, children: (0, J2.jsx)(`ul`, { role: `presentation`, className: Ze4.className, style: Ze4.style, "data-component": `menu-list`, children: e38 }) }) }), n2 == null ? null : (0, J2.jsx)(`div`, { className: Qe4.className, style: Qe4.style, "data-component": `menu-footer`, children: (0, J2.jsx)(Hh2, { value: `footer`, children: n2 }) })] }), r2 == null ? null : (0, J2.jsx)(`div`, { className: $e4.className, style: $e4.style, "data-component": `menu-attachment`, children: (0, J2.jsx)(`div`, { className: Xe4.className, style: Xe4.style, "data-component": `menu-content`, children: (0, J2.jsx)(Hh2, { value: `footer`, children: r2 }) }) })] }) }) }) }) }) })] }) })] }); +} +function nb2({ children: e38, indent: t2 = false, rootStyle: n2 }) { + nb2.d = 1084404338; + let r2 = fy(t2, n2); + return (0, J2.jsx)(`div`, { className: r2.className, style: r2.style, "data-component": `menu-empty`, "data-indent": t2 || void 0, children: e38 }); +} +function rb2(e38) { + let t2 = (0, Y2.useContext)(Xy2), n2 = (0, Y2.useContext)(yg), r2 = t2 ?? n2; + if (!r2) throw Error(`${e38} must be used within LegacyMenu or LegacyMenu.SubMenu`); + return r2; +} +function ib2() { + return rb2(`LegacyMenu.useLayerContext`); +} +function ab2({ size: e38, color: t2, "aria-label": n2 }) { + ab2.d = 3050767407; + let r2 = (0, J2.jsx)(Oi, { name: `loading`, modifier: `spin`, size: e38, color: t2, "aria-hidden": true }); + return n2 === void 0 ? r2 : (0, J2.jsx)(`span`, { role: `progressbar`, "aria-label": n2, className: `ui-3nfvp2 ui-2lah0s`, children: r2 }); +} +function ob2({ children: e38 }) { + ob2.d = 2811417063; + let t2 = py(); + return (0, J2.jsxs)(`div`, { className: t2.className, style: t2.style, role: `status`, "aria-live": `polite`, "aria-busy": `true`, children: [(0, J2.jsx)(ab2, { size: `base` }), (0, J2.jsx)(`span`, { children: e38 ?? `Loading...` })] }); +} +function sb2({ placeholder: e38 = `Search...`, "aria-label": t2, className: n2, rootStyle: r2, inputGroupRootStyle: i3, value: a3, onValueChange: o3, autoFocus: s3 = false }) { + sb2.d = 2481134228; + let c3 = Uh2() === `body`, l5 = Dy2(), u3 = Hc(), { searchValue: d3, setSearchValue: f4, searchInputRef: p4, activeIndex: m3, setActiveIndex: h4, listRef: g5, setHasSearchInput: _5, activeDescendantIdPrefix: v5 } = rb2(`LegacyMenu.SearchInput`), y4 = (0, Y2.useRef)(null), b2 = a3 !== void 0 && o3 !== void 0, x2 = !b2 || s3 || l5 ? p4 : y4, S2 = b2 ? a3 : d3; + (0, Y2.useEffect)(() => { + if (!b2) return _5(true), () => _5(false); + }, [b2, _5]), (0, Y2.useLayoutEffect)(() => { + if (b2 && !s3) return; + let e39 = p4.current; + if (!e39) return; + e39.focus({ preventScroll: true }); + let t3 = requestAnimationFrame2(() => { + document2.activeElement !== e39 && e39.focus({ preventScroll: true }); + }); + return () => cancelAnimationFrame2(t3); + }, [b2, s3, p4]); + let C2 = (e39) => { + b2 ? o3(e39.target.value) : (f4(e39.target.value), Qh(g5, `body`, h4), o3?.(e39.target.value)); + }, w2 = (e39) => { + if (Qc(e39)) return; + if (e39.ctrlKey && !e39.metaKey) { + let t4 = e39.key.toLowerCase(); + if (t4 === `n` || t4 === `p` || t4 === `j` || t4 === `k`) { + e39.preventDefault(); + return; + } + } + if (![`ArrowUp`, `ArrowDown`, `ArrowLeft`, `ArrowRight`, `Tab`, `Escape`].includes(e39.key) && !e39.metaKey && !e39.ctrlKey && !e39.altKey && e39.stopPropagation(), b2 && e39.key === `Enter`) { + e39.preventDefault(), e39.stopPropagation(); + return; + } + if (!b2 && e39.key === `Enter` && m3 != null) { + e39.preventDefault(); + let t4 = g5.current[m3]; + t4 && (t4.click(), p4.current?.focus()); + } + if (e39.key !== `ArrowLeft` && e39.key !== `ArrowRight`) return; + let t3 = e39.currentTarget, n3 = Og(e39.key, u3) === `end` ? t3.value.length : 0; + if (t3.selectionStart !== n3 || t3.selectionEnd !== n3) { + e39.stopPropagation(); + return; + } + tg({ event: e39, direction: e39.key, activeIndex: m3, listRef: g5, restoreFocus: () => p4.current?.focus() }); + }, T2 = oy(n2, r2), E2 = (0, J2.jsx)(Bm, { ref: x2, type: `text`, variant: `unfilled`, size: `md`, inputGroupRootStyle: i3, value: S2, onChange: C2, onKeyDown: w2, placeholder: e38, "aria-label": t2 ?? `Search menu items`, "aria-activedescendant": qh2(v5, m3) }); + return c3 ? (0, J2.jsx)(`li`, { className: T2.className, style: T2.style, "data-component": `menu-search-row`, role: `none`, children: E2 }) : (0, J2.jsx)(`div`, { className: T2.className, style: T2.style, "data-component": `menu-search-row`, role: `none`, children: E2 }); +} +function cb2(e38) { + let [t2, n2] = (0, Y2.useState)(false); + return (0, Y2.useLayoutEffect)(() => { + let t3 = e38.current; + if (t3 === null || t3.parentElement === null) return; + let r2 = () => { + n2(t3.nextElementSibling?.hasAttribute(`data-menu-section`) ?? false); + }; + r2(); + let i3 = new MutationObserver2(r2); + return i3.observe(t3.parentElement, { childList: true }), () => i3.disconnect(); + }, [e38]), t2; +} +function lb2({ children: e38, title: t2, dividerVisibility: n2 = `default`, trailingDividerVisibility: r2 = `default`, textAction: i3, titleTrailing: a3, tooltip: o3, noDivider: s3, rootStyle: c3, titleStyle: l5 }) { + lb2.d = 3041651174; + let u3 = (0, Y2.useRef)(null), d3 = cb2(u3), f4 = sy(c3), p4 = i3 != null || a3 != null, m3 = cy(p4, l5), h4 = ly(), g5 = t2 != null && t2 !== false ? (0, J2.jsxs)(`div`, { role: `presentation`, className: m3.className, style: m3.style, "data-component": `menu-section-title`, "data-has-action": p4 || void 0, children: [(0, J2.jsx)(`span`, { children: t2 }), a3, i3 == null ? null : (0, J2.jsx)(`button`, { type: `button`, ...qi2.self, className: h4.className, style: h4.style, onClick: i3.onClick, children: i3.label })] }) : null, _5 = g5 != null && o3 != null ? (0, J2.jsx)(wy2, { content: o3, openDelay: 0, closeDelay: 0, children: g5 }) : g5; + return (0, J2.jsxs)(`div`, { ref: u3, role: `group`, "aria-label": typeof t2 == `string` ? t2 : void 0, className: f4.className, style: f4.style, "data-menu-section": true, "data-next-is-section": d3 || void 0, "data-divider-visibility": n2 === "default" ? void 0 : n2, "data-trailing-divider-visibility": r2 === "default" ? void 0 : r2, "data-no-divider": s3 || void 0, children: [_5, e38] }); +} +function ub2({ children: e38, trigger: t2 = `hover`, placement: n2, anchorRef: r2, offset: i3, keepHoverSubmenuInset: a3 = false, closeOnSelect: o3, open: s3, defaultOpen: c3 = false, onOpenChange: l5, hoverOpenDelay: u3, keepOpenOnHoverOut: d3 = false, dismissOnReferenceScroll: f4 = false, suppressSiblingPointerGuard: p4 = false, virtualFocus: m3 = false, focusItemOnOpen: h4 }) { + ub2.d = 1653658558; + let _5 = Af(), y4 = Hc(), [b2, x2] = Pl(s3, c3, l5, `LegacyMenu.SubMenu`), S2 = s3 !== void 0, C2 = t2 === `hover` && (!S2 || r2 == null), [w2, E2] = (0, Y2.useState)(null), { focusItemOnHoverEnabled: D2, markKeyboardNavigation: O2, markPointerNavigation: A2, resetFocusItemOnHover: j2 } = rg2(), [M2, N3] = (0, Y2.useState)(``), [F2, I2] = (0, Y2.useState)(false), R3 = (0, Y2.useRef)([]), ee2 = (0, Y2.useRef)([]), te2 = (0, Y2.useRef)(null), re3 = (0, Y2.useId)(), ae3 = (0, Y2.useRef)(null), V3 = (0, Y2.useRef)(/* @__PURE__ */ new Set()); + Cy2(_5, b2); + let H3 = jy2(); + (0, Y2.useEffect)(() => { + H3 && H3.setSubMenuOpen(b2); + }, [b2, H3]); + let oe5 = (0, Y2.useRef)(b2); + (0, Y2.useEffect)(() => { + let e39 = oe5.current; + oe5.current = b2, e39 !== b2 && (N3(``), b2 || E2(null), j2()); + }, [b2, j2]); + let se5 = (0, Y2.useCallback)((e39) => { + x2(e39); + }, [x2]); + (0, Y2.useEffect)(() => { + if (H3) return H3.registerSubMenuOpener(() => se5(true)), () => { + H3.registerSubMenuOpener(null); }; - return r3.addEventListener(`resize`, a4), () => { - r3.removeEventListener(`resize`, a4), n3 !== null && r3.cancelAnimationFrame(n3); + }, [H3, se5]); + let ce6 = (0, Y2.useCallback)((e39, n3, r3) => { + let i4 = te2.current; + (e39 || t2 !== `hover` || r3 !== `hover` && r3 !== `safe-polygon` || !d3 && (!i4?.value || i4.ownerDocument.activeElement !== i4)) && se5(e39); + }, [d3, se5, t2]), ue6 = (0, Y2.useCallback)(() => { + se5(false); + }, [se5]), fe5 = n2 ?? (t2 === `hover` ? y4 === `rtl` ? `left-start` : `right-start` : `bottom-start`), { refs: U3, floatingStyles: pe5, context: W3 } = jp({ nodeId: _5, open: b2, onOpenChange: ce6, placement: fe5, middleware: [ac(i3 ?? (a3 || t2 === `hover` ? { mainAxis: -2, alignmentAxis: -2 } : 4)), cc(), oc({ crossAxis: fe5.startsWith(`left`) || fe5.startsWith(`right`) }), lc({ padding: 8, apply({ availableWidth: e39, availableHeight: t3, elements: n3 }) { + n3.floating.style.setProperty(ig, `${Math.max(0, Math.floor(e39))}px`), n3.floating.style.setProperty(ag, `${Math.max(0, Math.floor(t3))}px`); + } })], whileElementsMounted: Hs, transform: false }); + (0, Y2.useLayoutEffect)(() => { + let e39 = r2?.current; + e39 && U3.setReference(e39); + }), mg(C2 && b2 && !p4, U3.domReference); + let { activeId: he5 } = Yy2(_5, b2), _e5 = Rf(W3, { enabled: C2, delay: { open: he5 == null ? u3 ?? 75 : 0 }, handleClose: Qp({ blockPointerEvents: false, requireIntent: false }) }), ve5 = Tp(W3, { enabled: t2 === `click` && !S2 }), ye5 = gg(), be5 = kp(W3, { ancestorScroll: f4, bubbles: true, outsidePressEvent: `click`, outsidePress: ye5 }), xe5 = Hp(W3, { role: `menu` }), Se5 = Bp(W3, { listRef: R3, activeIndex: w2, onNavigate: E2, nested: true, rtl: y4 === `rtl`, loop: true, focusItemOnOpen: m3 ? false : h4 ?? true, virtual: F2 || m3, focusItemOnHover: D2 && !m3 }), Ce5 = Jp(W3, { listRef: ee2, activeIndex: w2, onMatch: F2 ? void 0 : E2, enabled: !F2 && !m3 }), { getReferenceProps: we5, getFloatingProps: Te5, getItemProps: Ee5 } = Np([_e5, ve5, be5, xe5, Se5, Ce5]), De5 = ng(Ee5, b2), Oe5 = (0, Y2.useCallback)((e39) => { + let { role: t3, ...n3 } = Yh2(we5(e39)); + return n3; + }, [we5]), ke5 = (0, Y2.useCallback)((e39) => { + let t3 = V3.current; + return t3.add(e39), () => { + t3.delete(e39); }; - }, [W4, _e4, k4, j3, rt4, N2]); - let at5 = W4 ? He4 || _e4 === `collapsing` : He4, { portalLayerStyles: ot3 } = Mi(`modal`, at5); - if ((0, J2.useEffect)(() => { - if (W4) { - Ke5.current = We4; + }, []), Ae5 = (0, Y2.useCallback)(() => ae3.current !== null, []), G2 = (0, Y2.useCallback)((e39) => { + ae3.current = e39; + for (let e40 of V3.current) e40(); + r2 || U3.setReference(e39); + }, [r2, U3.setReference]), je5 = (0, Y2.useCallback)(() => ({ ...Oe5(), id: re3, ref: G2, "aria-haspopup": `menu`, "aria-expanded": b2 }), [Oe5, G2, re3, b2]), { isMounted: Me5, styles: Ne5 } = qp(W3, { duration: { open: 0, close: 50 }, initial: { opacity: 0, transform: `scale(1)` } }), Pe5 = (0, Y2.useMemo)(() => ({ isOpen: b2, isMounted: Me5, setIsOpen: se5, closeFromKeyboard: ue6, activeIndex: w2, setActiveIndex: E2, markKeyboardNavigation: O2, markPointerNavigation: A2, trigger: t2, closeOnSelect: o3, nodeId: _5, activeDescendantIdPrefix: F2 ? _5 : void 0, listRef: R3, labelsRef: ee2, searchInputRef: te2, searchValue: M2, setSearchValue: N3, hasSearchInput: F2, setHasSearchInput: I2, triggerId: re3, subscribeTriggerElement: ke5, hasTriggerElement: Ae5, refs: U3, floatingStyles: pe5, transitionStyles: Ne5, context: W3, getReferenceProps: Oe5, getFloatingProps: Te5, getItemProps: De5, getTriggerProps: je5, virtualFocus: m3 }), [b2, Me5, se5, ue6, w2, t2, O2, A2, o3, _5, M2, F2, re3, ke5, Ae5, m3, U3, pe5, Ne5, W3, Oe5, Te5, De5, je5]); + return (0, J2.jsx)(jf, { id: _5, children: (0, J2.jsx)(Xy2.Provider, { value: Pe5, children: e38 }) }); +} +function db2({ children: e38, disabled: t2 = false, label: n2, leading: r2, leadingStyle: i3, trailing: a3, contentStyle: o3, trailingStyle: s3 }) { + db2.d = 743251214; + let { activeIndexStore: c3, getItemProps: l5, activeDescendantIdPrefix: u3, shouldAllowPointerInteraction: d3 } = R_(`LegacyMenu.SubMenuTrigger`), f4 = Zy2(`LegacyMenu.SubMenuTrigger`), p4 = Uh2(), m3 = Hc(), h4 = p4 === `body`, { ref: g5, index: _5 } = lf({ label: (n2 ?? (typeof e38 == `string` ? e38 : ``)) || null }), v5 = z_(c3, _5), y4 = af([g5, f4.refs.setReference]), b2 = (0, J2.jsx)(Oi, { name: `chevron-right`, color: `tertiary` }), x2 = Xv({ disabled: t2, expanded: f4.isOpen, focused: v5 }), S2 = { role: `menuitem`, "aria-haspopup": `menu`, "aria-expanded": f4.isOpen, "data-component": `menu-submenu-trigger`, "data-expanded": f4.isOpen || void 0, tabIndex: v5 ? 0 : -1, "aria-disabled": t2 || void 0, "data-disabled": t2 || void 0, "data-focused": v5 || void 0, [Bh2]: p4, className: x2.className, style: x2.style, ...f4.getReferenceProps(l5({ ...Jh2(u3, _5), onMouseDown(e39) { + d3(e39.nativeEvent) || (e39.preventDefault(), e39.stopPropagation()); + }, onClick(e39) { + if (!d3(e39.nativeEvent)) { + e39.preventDefault(), e39.stopPropagation(); return; } - let e10 = Ke5.current; - (We4 === `open` && e10 !== `open` || We4 === `unmounted` && e10 === `close`) && Ee4.current?.(), Ke5.current = We4; - }, [W4, We4]), (0, J2.useEffect)(() => { - if (!at5 || !C2) return; - let e10 = Np2(H4, ke4.current); - if (e10 === null) return; - let t3 = /* @__PURE__ */ new WeakSet(), n3 = (n4) => { - n4.key === `Escape` && Mp2(e10) && t3.add(n4); - }, r3 = (n4) => { - n4.key === `Escape` && (n4.defaultPrevented || n4.isComposing || !Ae4() || t3.has(n4) || Mp2(e10) || (n4.preventDefault(), n4.stopPropagation(), n4.stopImmediatePropagation(), W4 ? je4() : Oe4(false))); - }; - return e10.addEventListener(`keydown`, n3, true), e10.addEventListener(`keydown`, r3), () => { - e10.removeEventListener(`keydown`, n3, true), e10.removeEventListener(`keydown`, r3); - }; - }, [at5, C2, Ae4, W4, je4, H4, Oe4]), !at5) return null; - let st3 = c2 ?? (!s3 && Xe4 ? qe4 : void 0), ct3 = We4, lt3 = K2({ rootClass: `ui-dialog-backdrop`, stylexStyles: [zf({ fullscreen: W4, status: ct3 }), h3], className: G3(W4 && `ui-dialog-backdrop--fullscreen`, p4), style: W4 ? { opacity: ye4 && ct3 !== `close` ? 1 : 0, transition: kp2([`opacity`], he5, ge4), willChange: ye4 ? `auto` : `opacity`, ...ot3 } : ot3 }), ut3 = K2({ rootClass: `ui-dialog`, stylexStyles: [Bf({ fullscreen: W4, size: t2, status: ct3, width: n2 }), m3], className: G3(`ui-dialog--${t2}`, f4), style: W4 ? { ...it4, ...ot3, ...y3 } : { ...ot3, ...y3 } }); - return (0, q2.jsx)(sp2.Provider, { value: tt4, children: (0, q2.jsxs)(Ah, { ...H4 ? { root: H4 } : {}, children: [T3 && (0, q2.jsx)(Kh, { className: lt3.className, lockScroll: D2 && se5, "data-status": We4, "data-expanded": W4 ? ye4 : void 0, style: lt3.style, onClick: b3 ? (e10) => { - e10.ctrlKey || Ae4() && e10.target === e10.currentTarget && (W4 ? je4() : Oe4(false)); - } : void 0 }), (0, q2.jsx)(Vh, { context: Ne3, disabled: w3, modal: T3, ...R3 === void 0 ? {} : { initialFocus: R3 }, ...z4 === void 0 ? U4 === null ? {} : { returnFocus: de5 } : { returnFocus: z4 }, children: (0, q2.jsx)(`div`, { ref: Pe3, role: `dialog`, tabIndex: te3, "data-ui-dialog-root": ``, className: ut3.className, style: ut3.style, "aria-label": s3, "aria-labelledby": st3, "aria-describedby": l4 ?? (Qe4 ? Je4 : void 0), "aria-modal": T3 ? `true` : void 0, "data-presentation": u3, "data-block-global-shortcuts": d3, "data-status": We4, "data-animation-phase": W4 ? _e4 : void 0, "data-expanded": W4 ? ye4 : void 0, ...Be4, onKeyDown: (e10) => { - let t3 = Be4.onKeyDown; - typeof t3 == `function` && t3(e10), e10.defaultPrevented || B4?.(e10); - }, children: e9 }) })] }) }); -} -var Fp2 = Object.assign(Pp2, { Header: hp2, HeaderLead: gp2, Title: Cp2, Description: pp2, List: bp2, ListHeader: xp2, ListRow: Sp2, Content: fp2, Footer: mp2, Close: dp2 }); -function zv() { - let e9 = (0, J2.useRef)(true), t2 = (0, J2.useRef)(void 0), n2 = (0, J2.useCallback)(() => { - t2.current !== void 0 && (clearTimeout(t2.current), t2.current = void 0); - }, []), r2 = (0, J2.useCallback)((r3, i3) => { - e9.current && (n2(), t2.current = setTimeout(() => { - t2.current = void 0, r3(); - }, i3)); - }, [n2]); - return (0, J2.useEffect)(() => (e9.current = true, () => { - e9.current = false, n2(); - }), [n2]), (0, J2.useMemo)(() => ({ cancel: n2, schedule: r2 }), [n2, r2]); -} -function bx(e9) { - for (let t2 = 0; t2 < e9.length; t2++) { - let n2 = e9.charCodeAt(t2); - if (n2 <= 31 || n2 >= 127 && n2 <= 159) return true; - } - return false; -} -var xx = class extends Error { - constructor(e9) { - super(e9), this.name = `DeepLinkDeclarationError`; - } -}; -var Sx = class extends Error { - constructor(e9) { - super(e9), this.name = `DeepLinkBuildError`; - } -}; -var Cx = /%(?![0-9A-Fa-f]{2})/; -var wx = /\/\.{1,2}(?:\/|$)/; -function Tx(e9, t2) { - return typeof t2 == `string` ? t2.length === 0 ? `empty` : bx(t2) ? `control` : e9.check(t2, []).ok ? `ok` : `invalid` : `not-a-string`; -} -function Ex(e9, t2) { - if (typeof t2 != `string`) return Mx(`not-a-string`); - if (t2.length === 0) return Mx(`empty`); - if (t2.length > e9.maxUrlLength) return Mx(`over-length`); - if (!jx(t2)) return Mx(`non-printable`); - if (t2.includes(`#`)) return Mx(`fragment`); - if (t2.includes(`\\`)) return Mx(`backslash`); - if (Cx.test(t2)) return Mx(`percent-encoding`); - let n2 = t2.indexOf(`?`), r2 = n2 === -1 ? t2 : t2.slice(0, n2); - if (r2.includes(`%`)) return Mx(`path-encoding`); - if (wx.test(r2)) return Mx(`dot-segment`); - if (!Ax(e9, t2.toLowerCase())) return Mx(`scheme`); - let i3; - try { - i3 = new URL(t2); - } catch { - return Mx(`unparseable`); - } - if (i3.username !== `` || i3.password !== ``) return Mx(`userinfo`); - if (i3.port !== ``) return Mx(`port`); - if (i3.host !== e9.authority) return Mx(`authority`); - let a3 = e9.routesByPath.get(i3.pathname); - if (a3 === void 0) return Mx(`path`); - let o3 = a3.declaration, s3 = /* @__PURE__ */ new Map(); - for (let [e10, t3] of i3.searchParams) { - if (!Object.hasOwn(o3.params, e10)) return Mx(`query-key`); - let n3 = o3.params[e10]; - if (n3 === void 0) return Mx(`query-key`); - if (s3.has(e10)) return Mx(`query-duplicate`); - let r3 = Tx(n3, t3); - if (r3 === `empty` || r3 === `control`) return Mx(`query-value`); - if (r3 !== `ok`) return Mx(`param-invalid`); - s3.set(e10, t3); - } - let c2 = []; - for (let [e10, t3] of Object.entries(o3.params)) { - let n3 = s3.get(e10); - if (n3 === void 0) { - if (t3.optional === true) continue; - return Mx(`query-missing`); - } - c2.push([e10, n3]); - } - let l4 = Object.freeze({ version: o3.version, route: a3.name, ...Object.fromEntries(c2) }), u3 = kx(e9, a3, c2); - return u3.length > e9.maxUrlLength ? Mx(`over-length`) : { ok: true, parsed: { link: l4, canonicalUrl: u3 } }; -} -function Dx(e9, t2) { - if (!at2(t2)) return false; - let n2 = (e10) => Object.hasOwn(t2, e10) ? t2[e10] : void 0, r2 = n2(`route`); - if (typeof r2 != `string`) return false; - let i3 = e9.routesByName.get(r2); - if (i3 === void 0) return false; - let a3 = i3.declaration; - if (n2(`version`) !== a3.version) return false; - for (let e10 of Object.keys(t2)) if (e10 !== `version` && e10 !== `route` && !Object.hasOwn(a3.params, e10)) return false; - for (let [e10, t3] of Object.entries(a3.params)) { - let r3 = n2(e10); - if (r3 === void 0) { - if (t3.optional === true) continue; - return false; + !t2 && f4.trigger === `hover` && f4.setIsOpen(true); + }, onKeyDown(e39) { + (Og(e39.key, m3) === `end` || e39.key === `Enter` || e39.key === ` `) && !t2 && (e39.preventDefault(), e39.stopPropagation(), f4.setIsOpen(true)); + } })) }, C2 = dy(), w2 = (0, J2.jsx)(Ty2, { disabled: t2, leading: r2, leadingStyle: i3, contentStyle: o3, trailing: a3 == null ? void 0 : (0, J2.jsx)(`div`, { className: C2.className, style: C2.style, "data-component": `menu-submenu-right-section`, children: a3 }), rightFallback: b2, trailingStyle: s3, children: e38 }); + return h4 ? (0, J2.jsx)(`li`, { ref: y4, ...S2, children: w2 }) : (0, J2.jsx)(`div`, { ref: y4, ...S2, children: w2 }); +} +function fb2({ children: e38, label: t2, showChevron: n2 = true, onKeyDown: r2, closeOnSelect: i3, ...a3 }) { + fb2.d = 3477810333; + let o3 = Zy2(`LegacyMenu.SubMenuItem`), s3 = Hc(), c3 = t2 ?? (typeof e38 == `string` ? e38 : ``), l5 = (e39) => { + a3.disabled || (r2?.(e39), !e39.defaultPrevented && Og(e39.key, s3) === `end` && (e39.preventDefault(), e39.stopPropagation(), o3.setIsOpen(true))); + }, u3 = n2 ? (0, J2.jsx)(Oi, { name: `chevron-right`, color: `tertiary` }) : void 0; + return (0, J2.jsx)(Ny2, { ...a3, contextPart: `LegacyMenu.SubMenuItem`, itemLabel: c3, closeOnSelect: i3 ?? o3.closeOnSelect, "aria-haspopup": `menu`, "aria-expanded": o3.isOpen, referenceRef: o3.refs.setReference, itemPropsTransform: o3.getReferenceProps, onKeyDown: l5, trailingAccessory: u3, children: e38 }); +} +function pb2({ children: e38, header: t2, footer: n2, "aria-label": r2, "data-testid": i3, onPointerEnter: a3, keepSearchFocus: o3 = false, className: s3, surfaceStyle: c3, contentStyle: l5, listStyle: u3, width: d3, minWidth: f4, maxWidth: p4, maxHeight: m3, size: h4, contentPadding: g5 }) { + pb2.d = 1557875606; + let _5 = _i2(), v5 = Zy2(`LegacyMenu.SubMenuContent`), { shouldAllowPointerInteraction: y4 } = bg(`LegacyMenu.SubMenuContent`), b2 = $y2(), x2 = Hc(), S2 = Ni2(), { portalLayerStyles: w2 } = Gi2(`popover`, v5.isMounted), T2 = h4 ?? _5?.menuSize ?? `sm`, { virtualFocus: E2 } = v5, D2 = (0, Y2.useSyncExternalStore)(v5.subscribeTriggerElement, v5.hasTriggerElement, () => false); + if (!v5.isMounted) return null; + let O2 = zv({ className: s3, size: T2, surfaceStyle: c3, style: { ...v5.floatingStyles, ...v5.transitionStyles, ...w2, ...fg({ width: d3, minWidth: f4, maxWidth: p4, clampToAvailableWidth: true }), ...pg({ isOpen: v5.isOpen, isPositioned: v5.context.isPositioned }) } }), k2 = Hv2(l5), A2 = Vv(false, u3), j2 = sg(m3), M2 = t2 != null || n2 != null, N3 = Wv(M2 ? { maxHeight: j2 } : void 0), P3 = Kv(), F2 = qv(), L3 = g5 === void 0 ? k2.style : { ...k2.style, padding: g5, scrollPaddingBlock: g5 }, R3 = (e39) => { + e39.stopPropagation(); + }, z2 = D2 ? v5.triggerId : void 0, B3 = (e39) => { + v5.markPointerNavigation(); + let t3 = $h(e39, v5.listRef); + if (t3 != null && t3 !== v5.activeIndex && v5.setActiveIndex(t3), !o3 || t3 == null) return; + let n3 = v5.searchInputRef.current; + if (n3 == null) return; + let r3 = n3.ownerDocument.activeElement; + r3 !== n3 && (r3 instanceof HTMLInputElement || r3 instanceof HTMLTextAreaElement || n3.focus({ preventScroll: true })); + }; + return (0, J2.jsx)(ap, { ...S2 ? { root: S2 } : {}, children: (0, J2.jsx)(gp, { context: v5.context, disabled: E2, initialFocus: v5.hasSearchInput ? v5.searchInputRef : -1, returnFocus: false, modal: false, closeOnFocusOut: v5.trigger === `click`, children: (0, J2.jsx)(`div`, { ref: v5.refs.setFloating, className: O2.className, style: O2.style, "data-component": `menu-popup`, "data-submenu": ``, "data-size": T2, ...i3 ? { "data-testid": i3 } : {}, ...v5.getFloatingProps({ ...z2 === void 0 ? {} : { "aria-labelledby": z2 }, onClick: R3, onPointerEnter: a3, onMouseMove(e39) { + B3(e39.target); + }, onPointerMove(e39) { + B3(e39.target); + }, onKeyDown(e39) { + if (Kh2(e39) && v5.markKeyboardNavigation(), Og(e39.key, x2) === `start` || e39.key === `Escape`) { + e39.preventDefault(), e39.stopPropagation(), v5.closeFromKeyboard(); + let t3 = v5.refs.domReference.current; + t3 instanceof HTMLElement2 && t3.focus(); } - if (Tx(t3, r3) !== `ok`) return false; - } - return true; -} -function Ox(e9, t2, n2) { - let r2 = e9.routesByName.get(t2); - if (r2 === void 0) throw new Sx(`route "${t2}" is not declared`); - let i3 = r2.declaration, a3 = n2 ?? {}; - for (let e10 of Object.keys(a3)) if (!Object.hasOwn(i3.params, e10)) throw new Sx(`route "${t2}" has no param "${e10}"`); - let o3 = []; - for (let [e10, n3] of Object.entries(i3.params)) { - let r3 = Object.hasOwn(a3, e10) ? a3[e10] : void 0; - if (r3 === void 0) { - if (n3.optional === true) continue; - throw new Sx(`route "${t2}" requires param "${e10}"`); - } - if (typeof r3 != `string` || Tx(n3, r3) !== `ok`) throw new Sx(`route "${t2}" param "${e10}" must be ${n3.expects}`); - o3.push([e10, r3]); - } - let s3 = kx(e9, r2, o3); - if (s3.length > e9.maxUrlLength) throw new Sx(`route "${t2}" builds a URL longer than ${e9.maxUrlLength} characters`); - return s3; -} -function kx(e9, t2, n2) { - let r2 = `${e9.canonicalScheme}://${e9.authority}${t2.declaration.path}`; - return n2.length === 0 ? r2 : `${r2}?${n2.map(([e10, t3]) => `${e10}=${encodeURIComponent(t3)}`).join(`&`)}`; -} -function Ax(e9, t2) { - for (let n2 of e9.schemeProtocols) if (t2.startsWith(n2)) return true; - return false; -} -function jx(e9) { - for (let t2 = 0; t2 < e9.length; t2++) { - let n2 = e9.charCodeAt(t2); - if (n2 < 33 || n2 > 126) return false; - } - return true; + } }), children: (0, J2.jsx)(Ey2.Provider, { value: true, children: (0, J2.jsx)(gi2, { menuSize: T2, children: (0, J2.jsx)(by, { layerNodeId: v5.nodeId, children: (0, J2.jsx)(B_, { activeIndex: v5.activeIndex, setIsOpen: v5.setIsOpen, getItemProps: v5.getItemProps, searchValue: v5.searchValue, closeOnSelect: v5.closeOnSelect, virtualFocus: E2, activeDescendantIdPrefix: v5.activeDescendantIdPrefix, shouldAllowPointerInteraction: y4, closeMenuLayersOnSelect: b2, children: (0, J2.jsx)(cf, { elementsRef: v5.listRef, labelsRef: v5.labelsRef, children: M2 ? (0, J2.jsxs)(`div`, { className: N3.className, style: N3.style, role: `menu`, "aria-label": r2 ?? `Submenu`, "data-component": `menu-layout`, children: [t2 == null ? null : (0, J2.jsx)(`div`, { className: P3.className, style: P3.style, "data-component": `menu-header`, children: (0, J2.jsx)(Hh2, { value: `header`, children: t2 }) }), (0, J2.jsx)(Cc2, { className: fv2, rootStyle: c_(), maxHeight: `none`, "data-component": `menu-body-scroll`, children: (0, J2.jsx)(`div`, { className: k2.className, style: L3, "data-component": `menu-content`, children: (0, J2.jsx)(`ul`, { role: `presentation`, className: A2.className, style: A2.style, "data-component": `menu-list`, children: (0, J2.jsx)(Hh2, { value: `body`, children: (0, J2.jsx)(Jy2, { children: e38 }) }) }) }) }), n2 == null ? null : (0, J2.jsx)(`div`, { className: F2.className, style: F2.style, "data-component": `menu-footer`, children: (0, J2.jsx)(Hh2, { value: `footer`, children: n2 }) })] }) : (0, J2.jsx)(Cc2, { maxHeight: j2, children: (0, J2.jsx)(`div`, { className: k2.className, style: L3, "data-component": `menu-content`, children: (0, J2.jsx)(`ul`, { role: `menu`, "aria-label": r2 ?? `Submenu`, className: A2.className, style: A2.style, "data-component": `menu-list`, children: (0, J2.jsx)(Hh2, { value: `body`, children: (0, J2.jsx)(Jy2, { children: e38 }) }) }) }) }) }) }) }) }) }) }) }) }); +} +function mb2({ children: e38, label: t2, ignoreSearch: n2, ...r2 }) { + mb2.d = 3179479718; + let i3 = t2 ?? (typeof e38 == `string` ? e38 : ``); + return Oy2(i3, n2, `LegacyMenu.SwitchItem`) ? (0, J2.jsx)(hb2, { ...r2, itemLabel: i3, children: e38 }) : null; +} +function hb2({ children: e38, "data-testid": t2, checked: n2, defaultChecked: r2 = false, onChange: i3, disabled: a3 = false, switchVariant: o3, leading: s3, leadingStyle: c3, trailing: l5, contentStyle: u3, trailingStyle: d3, rootStyle: f4, tooltip: p4, closeOnSelect: m3, itemLabel: h4 }) { + hb2.d = 1653949120; + let { activeIndexStore: g5, shouldAllowPointerInteraction: _5, closeMenuLayersOnSelect: v5, getItemProps: y4, setIsOpen: b2, closeOnSelect: x2, activeDescendantIdPrefix: S2 } = R_(`LegacyMenu.SwitchItem`), C2 = Dy2(), w2 = Uh2(), T2 = w2 === `body`, E2 = m3 ?? x2 ?? false, [D2, O2] = (0, Y2.useState)(r2), k2 = n2 !== void 0, A2 = k2 ? n2 : D2, { ref: j2, index: N3 } = lf({ label: h4 || null }), P3 = z_(g5, N3), F2 = (0, Y2.useCallback)(() => { + if (a3) return; + let e39 = !A2; + k2 || O2(e39); + let t3 = { defaultPrevented: false, preventDefault: () => { + t3.defaultPrevented = true; + } }; + i3?.(e39, t3), E2 && !t3.defaultPrevented && v5(b2); + }, [a3, A2, k2, i3, E2, b2, v5]), I2 = (0, Y2.useCallback)((e39) => { + if (!_5(e39.nativeEvent)) { + e39.preventDefault(), e39.stopPropagation(); + return; + } + e39.preventDefault(), e39.stopPropagation(), F2(); + }, [F2, _5]), L3 = (0, Y2.useCallback)((e39) => { + a3 || (e39.key === `Enter` || e39.key === ` `) && (e39.preventDefault(), e39.stopPropagation(), F2()); + }, [a3, F2]), R3 = y4({ ...Jh2(S2, N3), onClick: I2, onKeyDown: L3 }), z2 = Yv({ disabled: a3, focused: P3, inSubmenu: C2 }, f4), B3 = { role: `menuitemcheckbox`, "aria-checked": A2, tabIndex: P3 ? 0 : -1, "aria-disabled": a3 || void 0, "data-checked": A2 || void 0, "data-component": `menu-toggle-row`, "data-disabled": a3 || void 0, "data-focused": P3 || void 0, ...t2 ? { "data-testid": t2 } : {}, [Bh2]: w2, className: z2.className, style: z2.style, ...R3 }, ee2 = (0, J2.jsx)(Ty2, { disabled: a3, leading: s3, leadingStyle: c3, contentStyle: u3, trailing: l5, trailingStyle: d3, trailingAccessory: (0, J2.jsx)(Zu2, { checked: A2, disabled: a3, size: `sm`, variant: o3 }), children: e38 }), te2 = T2 ? (0, J2.jsx)(`li`, { ref: j2, ...B3, children: ee2 }) : (0, J2.jsx)(`div`, { ref: j2, ...B3, children: ee2 }); + return p4 == null ? te2 : (0, J2.jsx)(wy2, { content: p4, openDelay: 0, closeDelay: 0, children: te2 }); +} +function gb2({ title: e38, subtitle: t2, inline: n2 = false, wrapSubtitle: r2 = false }) { + gb2.d = 3802481006; + let i3 = ry(n2), a3 = iy(n2), o3 = ay({ inline: n2, wrap: r2 }); + return (0, J2.jsxs)(`div`, { className: i3.className, style: i3.style, "data-inline": n2 || void 0, children: [(0, J2.jsx)(Ef2, { size: `md`, weight: `regular`, color: `primary`, className: a3.className, style: a3.style, children: e38 }), t2 == null ? null : (0, J2.jsx)(Ef2, { size: `sm`, weight: `regular`, color: `tertiary`, className: o3.className, style: o3.style, "data-wrap": r2 || void 0, children: t2 })] }); +} +var _b2 = { title: { kZKoxP: `ui-xk0z11`, kB7OPa: `ui-9f619`, kVQacm: `ui-b3r6kr`, $$css: true } }; +function vb2({ title: e38, divider: t2 }) { + vb2.d = 892301846; + let n2 = cy(false, _b2.title), r2 = uy(); + return (0, J2.jsxs)(J2.Fragment, { children: [t2 ? (0, J2.jsx)(`div`, { role: `presentation`, "aria-hidden": `true`, className: r2.className, style: r2.style }) : null, e38 === void 0 ? null : (0, J2.jsx)(`div`, { role: `presentation`, className: n2.className, "data-component": `menu-section-title`, style: n2.style, children: (0, J2.jsx)(`span`, { children: e38 }) })] }); +} +var yb2 = (0, Y2.createContext)(null); +function bb2(e38) { + return String(e38); +} +function xb2(e38) { + let t2 = (0, Y2.useContext)(yb2); + if (!t2) throw Error(`${e38} must be used within LegacyMenu.VirtualizedContent`); + return t2; } -function Mx(e9) { - return { ok: false, reason: e9 }; -} -function Ix(e9, t2) { - return { expects: e9, check: t2, "~standard": { version: 1, vendor: `dune`, validate: (e10) => { - let n2 = t2(e10, []); - return n2.ok ? { value: n2.value } : { issues: [{ message: `must be ${n2.expected}, got ${n2.received}`, path: n2.path }] }; - } } }; -} -function Xx(e9) { - let t2 = e9 instanceof RegExp ? { pattern: e9 } : e9 ?? {}; - if (t2.pattern !== void 0 && t2.oneOf !== void 0) throw new xx(`routeString takes a pattern or a oneOf list, not both`); - if (t2.maxDecodedLength !== void 0 && (!Number.isSafeInteger(t2.maxDecodedLength) || t2.maxDecodedLength < 1)) throw new xx(`routeString maxDecodedLength must be a positive integer`); - if (t2.oneOf !== void 0) { - if (t2.oneOf.length === 0) throw new xx(`routeString oneOf must name at least one value`); - if (new Set(t2.oneOf).size !== t2.oneOf.length) throw new xx(`routeString oneOf values must be distinct`); - for (let e10 of t2.oneOf) if (e10.length === 0 || bx(e10)) throw new xx(`routeString oneOf values must be nonempty and control-character free`); - } - let n2 = t2.pattern === void 0 ? void 0 : Qx(t2.pattern), r2 = t2.oneOf === void 0 ? void 0 : new Set(t2.oneOf), i3 = $x(t2, n2); - return Ix(i3, (e10, a3) => typeof e10 != `string` || t2.maxDecodedLength !== void 0 && e10.length > t2.maxDecodedLength || r2 !== void 0 && !r2.has(e10) || n2 !== void 0 && !n2.test(e10) ? eS(a3, i3, e10) : { ok: true, value: e10 }); -} -function Zx(e9) { - return { ...e9, optional: true }; -} -function Qx(e9) { - let t2 = e9.flags.replace(/[gy]/g, ``); - return RegExp(`^(?:${e9.source})$`, t2); -} -function $x(e9, t2) { - let n2 = `string`; - return e9.oneOf === void 0 ? t2 !== void 0 && (n2 = `string matching /${e9.pattern?.source}/${t2.flags}`) : n2 = e9.oneOf.map((e10) => JSON.stringify(e10)).join(` | `), e9.maxDecodedLength === void 0 ? n2 : `${n2} of at most ${e9.maxDecodedLength} characters`; -} -function eS(e9, t2, n2) { - return { ok: false, path: e9, expected: t2, received: typeof n2 }; -} -var tS = /^\/v(0|[1-9]\d*)(?:\/[a-z0-9-]+)+$/; -var nS = /^[a-z][a-zA-Z0-9]*$/; -var rS = /* @__PURE__ */ new Set([`version`, `route`, `source`]); -var iS = /^[a-z][a-z0-9-]*$/; -var aS = /^[a-z][a-z0-9-]*$/; -var oS = /^[a-z][a-z0-9+.-]*$/; -var sS = /* @__PURE__ */ new Set([`file`, `ftp`, `http`, `https`, `ws`, `wss`]); -var cS = /* @__PURE__ */ new WeakSet(); -function lS(e9, t2) { - let n2 = tS.exec(e9); - if (n2?.[1] === void 0) throw new xx(`route path "${e9}" must be /v/ with lowercase kebab segments`); - let r2 = Number.parseInt(n2[1], 10); - for (let [n3, r3] of Object.entries(t2)) { - if (!nS.test(n3) || rS.has(n3)) throw new xx(`route path "${e9}" has an invalid param name "${n3}"`); - if (typeof r3?.check != `function` || typeof r3.expects != `string`) throw new xx(`route path "${e9}" param "${n3}" is not a validator`); - } - let i3 = Object.freeze({ ...t2 }), a3 = Object.freeze({ path: e9, version: r2, params: i3 }); - return cS.add(a3), a3; -} -function uS(e9) { - if (!aS.test(e9.authority)) throw new xx(`authority "${e9.authority}" must be a lowercase token`); - let t2 = e9.schemes[0]; - if (t2 === void 0) throw new xx(`schemes must name at least one scheme`); - if (new Set(e9.schemes).size !== e9.schemes.length) throw new xx(`schemes must be distinct`); - for (let t3 of e9.schemes) { - if (!oS.test(t3)) throw new xx(`scheme "${t3}" must be a lowercase URI scheme token`); - if (sS.has(t3)) throw new xx(`scheme "${t3}" is a reserved web scheme`); - } - if (!Number.isSafeInteger(e9.maxUrlLength) || e9.maxUrlLength < 1) throw new xx(`maxUrlLength must be a positive integer`); - let n2 = /* @__PURE__ */ new Map(), r2 = /* @__PURE__ */ new Map(); - for (let [t3, i4] of Object.entries(e9.routes)) { - if (!iS.test(t3)) throw new xx(`route name "${t3}" must be a lowercase kebab token`); - if (!cS.has(i4)) throw new xx(`route "${t3}" must come from deepLinkRoute(...)`); - if (r2.has(i4.path)) throw new xx(`route path "${i4.path}" is declared twice`); - let e10 = { name: t3, declaration: i4 }; - n2.set(t3, e10), r2.set(i4.path, e10); - } - let i3 = { authority: e9.authority, canonicalScheme: t2, schemeProtocols: new Set(e9.schemes.map((e10) => `${e10}:`)), maxUrlLength: e9.maxUrlLength, routesByName: n2, routesByPath: r2 }; - return Object.freeze({ authority: e9.authority, schemes: Object.freeze([...e9.schemes]), maxUrlLength: e9.maxUrlLength, routes: Object.freeze({ ...e9.routes }), parse: (e10) => Ex(i3, e10), buildUrl: (e10, ...t3) => Ox(i3, e10, t3[0]), isDeepLink: (e10) => Dx(i3, e10) }); -} -var bw = UA(); -function zw(e9) { - let t2 = (0, bw.c)(2), n2 = (0, J2.useEffectEvent)(e9), r2; +function Sb2({ children: e38, activeIndex: t2, setIsOpen: n2, getItemProps: r2, listRef: i3, closeOnSelect: a3, onRowElementChange: o3 }) { + Sb2.d = 3064988363; + let s3 = (0, Y2.useMemo)(() => ({ activeIndex: t2, setIsOpen: n2, getItemProps: r2, listRef: i3, closeOnSelect: a3, onRowElementChange: o3 }), [t2, n2, r2, i3, a3, o3]); + return (0, J2.jsx)(yb2.Provider, { value: s3, children: e38 }); +} +var Cb2 = `ui-menu--virtualized`; +function wb2({ index: e38, style: t2, items: n2, activeIndex: r2, renderItem: i3, onMouseMove: a3 }) { + wb2.d = 2327371953; + let o3 = n2[e38], s3 = r2 === e38, c3 = my(); + return (0, J2.jsx)(`div`, { className: c3.className, style: { ...t2, ...c3.style }, onMouseMove: (t3) => a3(e38, t3), children: i3(o3, e38, s3) }); +} +function Tb2({ items: e38, itemHeight: t2, renderItem: n2, getItemLabel: r2, header: i3, footer: a3, emptyState: o3, "aria-label": s3, className: c3, style: l5, surfaceStyle: u3, maxHeight: d3, width: f4 = `200px`, size: p4, backdrop: m3, closeOnSelect: h4 = true, overscanCount: g5 = 5, getItemKey: _5, onPreserveActiveIndex: v5, tooltipFollowsActiveIndex: y4 = false, renderActivePreview: b2, ref: x2 }) { + Tb2.d = 1417950340; + let S2 = _i2(), { isOpen: w2, isMounted: T2, activeIndex: E2, setActiveIndex: D2, setIsOpen: O2, virtualFocus: k2, enableHover: A2, nodeId: M2, listRef: N3, labelsRef: P3, searchValue: F2, refs: I2, floatingStyles: L3, middlewareData: R3, transitionStyles: z2, context: B3, getFloatingProps: ee2, getItemProps: te2, dismissCauseRef: ne3, returnFocusOnSelect: re3, returnFocus: ie3 } = bg(`LegacyMenu.VirtualizedContent`), ae3 = (0, Y2.useRef)(null), V3 = (0, Y2.useRef)(null), H3 = (0, Y2.useRef)(E2); + H3.current = E2; + let oe5 = (0, Y2.useRef)(null), [se5, ce6] = (0, Y2.useState)(null), [le6, ue6] = (0, Y2.useState)(null), de6 = m3 ?? !A2, fe5 = gg(), { portalLayerStyles: U3 } = Gi2(`popover`, T2), pe5 = (0, Y2.useRef)(null), W3 = (0, Y2.useRef)(void 0), me5 = (0, Y2.useRef)(e38), he5 = (0, Y2.useRef)(E2), ge5 = (0, Y2.useRef)(null); + (0, Y2.useEffect)(() => { + r2 ? P3.current = e38.map((e39) => r2(e39)) : P3.current = e38.map(() => null), N3.current.length !== e38.length && (N3.current.length = e38.length); + }, [e38, r2, P3, N3]), (0, Y2.useLayoutEffect)(() => { + let t3 = me5.current !== e38, n3 = he5.current !== E2; + if (me5.current = e38, he5.current = E2, _5 === void 0 || E2 == null) { + W3.current = void 0; + return; + } + let r3 = W3.current; + if (t3 && !n3 && r3 !== void 0) { + let t4 = e38.findIndex((e39) => _5(e39) === r3); + if (t4 >= 0 && t4 !== E2) { + ge5.current = t4, v5 === void 0 ? D2(t4) : v5(t4); + return; + } + } + let i4 = e38[E2]; + W3.current = i4 === void 0 ? void 0 : _5(i4); + }, [E2, _5, e38, v5, D2]); + let _e5 = B3.placement.startsWith(`top`), ve5 = R3.bottomAnchor?.bottom, ye5 = _e5 && T2 && typeof ve5 == `number` ? ve5 : null, be5 = (0, Y2.useRef)(null); + (0, Y2.useLayoutEffect)(() => { + if (!w2) { + be5.current = null, pe5.current = null; + return; + } + if (E2 == null || be5.current === E2) return; + be5.current = E2; + let t3 = ge5.current === E2; + if (ge5.current = null, t3) return; + let n3 = pe5.current === E2; + pe5.current = null, !n3 && (E2 < 0 || E2 >= e38.length || V3.current?.scrollToRow({ index: E2, align: `smart`, behavior: `instant` })); + }, [w2, E2, e38.length]); + let xe5 = (0, Y2.useRef)(F2), Se5 = (0, Y2.useRef)(w2); + (0, Y2.useEffect)(() => { + let t3 = xe5.current, n3 = Se5.current; + xe5.current = F2, Se5.current = w2, w2 && n3 && t3 !== F2 && (e38.length > 0 && V3.current?.scrollToRow({ index: 0, align: `start`, behavior: `instant` }), D2(e38.length > 0 ? 0 : null)); + }, [w2, e38.length, F2, D2]); + let Ce5 = (0, Y2.useCallback)((e39, t3) => { + oe5.current = e39, ce6((t4) => t4 === e39 ? t4 : e39), ue6((e40) => e40 === t3 ? e40 : t3); + }, []); + (0, Y2.useLayoutEffect)(() => { + if (!w2 || E2 == null || E2 < 0 || E2 >= e38.length) { + Ce5(null, null); + return; + } + let t3 = N3.current[E2]; + t3 != null && Ce5(t3, E2); + }, [E2, w2, e38.length, N3, Ce5]); + let we5 = (0, Y2.useCallback)((e39, t3) => { + e39 === H3.current && t3 != null && Ce5(t3, e39); + }, [Ce5]), Te5 = (0, Y2.useRef)(null), Ee5 = (0, Y2.useCallback)((e39, t3) => { + let n3 = Te5.current; + Te5.current = { x: t3.clientX, y: t3.clientY }, (n3 === null || n3.x !== t3.clientX || n3.y !== t3.clientY) && E2 !== e39 && (pe5.current = e39, D2(e39)); + }, [E2, D2]), De5 = (0, Y2.useCallback)((e39) => { + e39.key === `Escape` && (ne3.current = `escape`); + }, [ne3]), Oe5 = (0, Y2.useCallback)((e39) => { + fe5(e39.nativeEvent) && (ne3.current = `backdrop`, O2(false)); + }, [ne3, O2, fe5]), ke5 = (0, Y2.useCallback)((e39) => { + if (!fe5(e39.nativeEvent)) return; + e39.preventDefault(), ne3.current = `backdrop`, O2(false); + let t3 = document2.elementsFromPoint(e39.clientX, e39.clientY).find((e40) => !e40.classList.contains(sv2)); + t3 && t3.dispatchEvent(new MouseEvent(`contextmenu`, { bubbles: true, cancelable: true, view: window2, clientX: e39.clientX, clientY: e39.clientY, screenX: e39.screenX, screenY: e39.screenY, button: e39.button, buttons: e39.buttons, ctrlKey: e39.ctrlKey, shiftKey: e39.shiftKey, altKey: e39.altKey, metaKey: e39.metaKey })); + }, [ne3, O2, fe5]), Ae5 = af([I2.setFloating, ae3, x2]), G2 = Ni2(); + if (!T2) return null; + let je5 = d3 ?? 360, Me5 = typeof t2 == `number` ? e38.length * t2 : e38.reduce((e39, n3, r3) => e39 + t2(r3), 0), Ne5 = Math.min(Me5, Math.max(0, je5 - 8)), Pe5 = p4 ?? S2?.menuSize ?? `sm`, Fe4 = { ...L3, ...z2, ...l5, ...fg({ width: f4 }), ...U3, ..._e5 && ye5 !== null ? { top: `auto`, bottom: ye5 } : {}, ...pg({ isOpen: w2, isPositioned: B3.isPositioned }) }, Ie5 = Bv(U3), Le5 = zv({ className: c3 ? `${Cb2} ${c3}` : Cb2, size: Pe5, style: Fe4, surfaceStyle: u3 }), ze5 = Wv(), Be5 = Kv(), Ve5 = Hv2(), He5 = Vv(true), Ue4 = hy(), We4 = qv(), Ge4 = w2 && le6 != null && le6 >= 0 && le6 < e38.length && se5 != null && b2 != null ? b2(le6, { rowElement: se5, menuContentElement: ae3.current }) : null, Ke4 = Ge4 != null && se5 != null, Je4; + y4 && (Je4 = E2 == null ? null : bb2(E2)); + let Ye4 = { items: e38, activeIndex: E2, renderItem: n2, onMouseMove: Ee5 }; + return (0, J2.jsxs)(ap, { ...G2 ? { root: G2 } : {}, children: [de6 && (0, J2.jsx)(`div`, { className: Ie5.className, style: Ie5.style, "data-component": `menu-backdrop`, onClick: Oe5, onContextMenu: ke5, role: `none` }), (0, J2.jsx)(gp, { context: B3, initialFocus: -1, returnFocus: ie3 ?? (ne3.current !== `backdrop` && (ne3.current !== `selection` || re3)), modal: !k2 && w2, children: (0, J2.jsx)(`div`, { ref: Ae5, className: Le5.className, style: Le5.style, tabIndex: -1, "data-component": `menu-popup`, "data-virtualized": ``, "data-size": Pe5, ...ee2({ "aria-label": s3 ?? `Menu`, "aria-labelledby": void 0, onKeyDown: De5, onMouseDown: k2 ? (e39) => { + e39.stopPropagation(); + } : void 0 }), children: (0, J2.jsx)(gi2, { menuSize: Pe5, children: (0, J2.jsx)(`div`, { className: ze5.className, style: ze5.style, "data-component": `menu-layout`, role: `none`, children: (0, J2.jsx)(nu2, { dismiss: !w2, children: (0, J2.jsx)(by, { layerNodeId: M2, controlledTargetId: Je4, children: (0, J2.jsx)(Sb2, { activeIndex: E2, setIsOpen: O2, getItemProps: te2, listRef: N3, closeOnSelect: h4, onRowElementChange: we5, children: (0, J2.jsxs)(Jy2, { children: [i3 == null ? null : (0, J2.jsx)(`div`, { className: Be5.className, style: Be5.style, "data-component": `menu-header`, children: (0, J2.jsx)(Hh2, { value: `header`, children: i3 }) }), e38.length > 0 ? (0, J2.jsx)(`div`, { className: Ve5.className, style: Ve5.style, "data-component": `menu-content`, children: (0, J2.jsx)(`div`, { className: He5.className, style: He5.style, "data-component": `menu-list`, role: `presentation`, children: (0, J2.jsx)(db, { listRef: V3, className: Ue4.className, role: `none`, rowComponent: wb2, rowProps: Ye4, rowCount: e38.length, rowHeight: t2, overscanCount: g5, "data-native-scrollbar": `none`, style: { height: Ne5 } }) }) }) : o3, a3 == null ? null : (0, J2.jsx)(`div`, { className: We4.className, style: We4.style, "data-component": `menu-footer`, children: (0, J2.jsx)(Hh2, { value: `footer`, children: a3 }) }), b2 == null ? null : (0, J2.jsx)(ub2, { open: Ke4, placement: `right-start`, anchorRef: oe5, offset: 6, closeOnSelect: false, virtualFocus: true, children: Ke4 ? Ge4 : null })] }) }) }) }) }) }) }) })] }); +} +function Eb2({ index: e38, children: t2, disabled: n2 = false, onSelect: r2, onMouseDown: i3, leading: a3, leadingStyle: o3, contentStyle: s3, trailing: c3, trailingStyle: l5, wideLeftSection: u3 = false, tooltip: d3, tooltipContentKey: f4, closeOnSelect: p4, description: m3, variant: h4 = `default`, checked: g5, ref: _5 }) { + Eb2.d = 2202495291; + let { shouldAllowPointerInteraction: v5, virtualFocus: y4, activeDescendantIdPrefix: b2 } = bg(`LegacyMenu.VirtualizedItem`), x2 = Dy2(), { activeIndex: S2, setIsOpen: C2, getItemProps: w2, listRef: T2, closeOnSelect: E2, onRowElementChange: D2 } = xb2(`LegacyMenu.VirtualizedItem`), O2 = p4 ?? E2 ?? true, k2 = S2 === e38, A2 = (0, Y2.useCallback)((t3) => { + T2.current[e38] = t3, D2?.(e38, t3), typeof _5 == `function` ? _5(t3) : _5 && (_5.current = t3); + }, [e38, T2, D2, _5]), j2 = () => { + if (n2) return; + let e39 = { defaultPrevented: false, preventDefault: () => { + e39.defaultPrevented = true; + } }; + r2?.(e39), O2 && !e39.defaultPrevented && C2(false); + }, M2 = (e39) => { + if (!v5(e39.nativeEvent)) { + e39.preventDefault(), e39.stopPropagation(); + return; + } + j2(); + }, N3 = (e39) => { + n2 || (e39.key === `Enter` || e39.key === ` `) && (e39.preventDefault(), j2()); + }, P3 = (e39) => { + if (!v5(e39.nativeEvent)) { + e39.preventDefault(), e39.stopPropagation(); + return; + } + i3?.(e39), !e39.defaultPrevented && y4 && e39.preventDefault(); + }, { onMouseMove: F2, onPointerLeave: I2, ...L3 } = w2({ ...Jh2(b2, e38), onClick: M2, onKeyDown: N3, onMouseDown: P3 }), R3 = ey(), z2 = ty(), B3 = ny(), ee2 = m3 == null ? t2 : (0, J2.jsxs)(`div`, { className: R3.className, style: R3.style, children: [(0, J2.jsx)(`div`, { className: z2.className, style: z2.style, children: t2 }), (0, J2.jsx)(`div`, { className: B3.className, style: B3.style, "data-component": `menu-item-description`, children: m3 })] }), te2 = Jv({ disabled: n2, focused: k2, inSubmenu: x2, variant: h4 }), ne3 = g5 !== void 0, re3 = ne3 && a3 == null ? (0, J2.jsx)(To2, { checked: g5, disabled: n2 }) : a3, ie3 = (0, J2.jsx)(`li`, { ref: A2, ...ne3 ? { role: `menuitemcheckbox`, "aria-checked": g5, "data-checked": g5 || void 0 } : { role: `menuitem` }, tabIndex: k2 ? 0 : -1, "aria-disabled": n2 || void 0, "data-component": `menu-row`, "data-disabled": n2 || void 0, "data-focused": k2 || void 0, "data-has-description": m3 != null || void 0, "data-variant": h4 === "default" ? void 0 : h4, "data-wide-left": u3 || void 0, [Bh2]: `body`, className: te2.className, style: te2.style, ...L3, children: (0, J2.jsx)(Ty2, { disabled: n2, leading: re3, leadingStyle: o3, contentStyle: s3, trailing: c3, trailingStyle: l5, wideLeft: u3, children: ee2 }) }); + return d3 == null ? ie3 : (0, J2.jsx)(wy2, { content: d3, contentKey: f4, targetId: bb2(e38), children: ie3 }); +} +function Db2({ children: e38, open: t2, defaultOpen: n2, onOpenChange: r2, activeIndex: i3, onActiveIndexChange: a3, placement: o3, offset: s3, flip: c3, closeOnSelect: l5, instantClose: u3, instantTransitions: d3, returnFocusOnSelect: f4, returnFocus: p4, focusItemOnOpen: m3, virtualFocus: h4, shouldKeepOpenDuringDrag: g5, lockPositionWhileOpen: _5, dismissOnReferenceScroll: v5 }) { + return Db2.d = 3904991345, (0, J2.jsx)(Sg2, { open: t2, defaultOpen: n2, onOpenChange: r2, activeIndex: i3, onActiveIndexChange: a3, placement: o3, offset: s3, flip: c3, closeOnSelect: l5, instantClose: u3, instantTransitions: d3, returnFocusOnSelect: f4, returnFocus: p4, focusItemOnOpen: m3, virtualFocus: h4, shouldKeepOpenDuringDrag: g5, lockPositionWhileOpen: _5, dismissOnReferenceScroll: v5, children: e38 }); +} +function Ob2(e38) { + return Ob2.d = 2447090625, Of() === null ? (0, J2.jsx)(Mf, { children: (0, J2.jsx)(Db2, { ...e38 }) }) : (0, J2.jsx)(Db2, { ...e38 }); +} +function kb2(e38, t2, n2) { + let { ref: r2, ...i3 } = n2, a3 = Eg({ defaultTagName: `button`, props: i3, ref: r2, render: e38 }); + return t2 ? e38 : a3; +} +function Ab2({ children: e38, disabled: t2 = false }) { + Ab2.d = 261573304; + let { getTriggerProps: n2 } = bg(`LegacyMenu.Trigger`); + return kb2(e38, t2, n2()); +} +function jb2({ children: e38, onClick: t2, disabled: n2 = false }) { + jb2.d = 1399037718; + let { getTriggerProps: r2, setHasHoverTrigger: i3, setIsOpen: a3 } = bg(`LegacyMenu.HoverTrigger`); + (0, Y2.useEffect)(() => { + if (!n2) return i3(true), () => i3(false); + }, [n2, i3]); + let o3 = r2(); + return kb2(e38, n2, { ...o3, onPointerDown: Dg(void 0, Dg(o3.onPointerDown, (e39) => { + e39.button === 2 && a3(false); + })), onContextMenu: Dg(void 0, Dg(o3.onContextMenu, (e39) => { + a3(false), e39.stopPropagation(); + })), onClick: Dg(t2, (e39) => { + o3.onClick?.(e39); + }) }); +} +var Mb2 = Object.assign(ub2, { useContext: Qy2 }); +var Nb2 = Object.assign(Ob2, { useContext: xg, useLayerContext: ib2, Trigger: Ab2, HoverTrigger: jb2, Content: tb2, Item: My2, CheckboxItem: zy2, TextItem: gb2, SwitchItem: mb2, Section: lb2, SearchInput: sb2, EmptyState: nb2, LoadingState: ob2, ExpandableSection: Iy2, ExpandableSectionTrigger: Ly2, ExpandableSectionContent: Ry2, SubMenu: Mb2, SubMenuItem: fb2, SubMenuTrigger: db2, SubMenuContent: pb2, VirtualizedContent: Tb2, VirtualizedItem: Eb2, VirtualizedSectionHeader: vb2 }); +var Pb2 = `outline`; +var Fb2 = { "ui--default-marker": `ui--default-marker`, $$css: true }; +var Ib2 = { base: { kysU6D: `ui-jyslct`, keoZOQ: `ui-dj266r`, k71WvV: `ui-14z9mp`, k1K539: `ui-at24cr`, keTefX: `ui-1lziwak`, k63SB2: `ui-1pd3egz`, k1xSpc: `ui-78zum5`, kXwgrk: `ui-1q0g3np`, kGNEyG: `ui-6s0dn4`, kOIVth: `ui-11twubx`, $$css: true }, sizeLg: { kLKAdn: `ui-f6zju3`, kwRFfy: `ui-1msowdo`, kGO01o: `ui-cnij5n`, kZCmMZ: `ui-1uxnm1j`, $$css: true }, sizeMd: { kLKAdn: `ui-493x5y`, kwRFfy: `ui-1tlft3r`, kGO01o: `ui-b6dno7`, kZCmMZ: `ui-v853mj`, $$css: true }, shapeRounded: { kaIpWk: `ui-1043rbw`, $$css: true }, shapePill: { kaIpWk: `ui-1i4c3av`, $$css: true }, frameContentLg: { keoZOQ: `ui-1m79sar`, k1K539: `ui-1w4rq16`, keTefX: `ui-1t34h19`, k71WvV: `ui-u45m27`, $$css: true }, frameContentMd: { keoZOQ: `ui-lvyip8`, k1K539: `ui-b4cpfm`, keTefX: `ui-1hk7dha`, k71WvV: `ui-yy14hb`, $$css: true }, frameContentHugFalseLg: { kzqmXN: `ui-lai49p`, $$css: true }, frameContentHugFalseMd: { kzqmXN: `ui-u0r5jw`, $$css: true }, hugFalse: { kzqmXN: `ui-h8yej3`, kjj79g: `ui-13a6bvl`, $$css: true } }; +var Lb2 = { base: { kUk6DE: `ui-98rzlu`, k7Eaqz: `ui-euugli`, k9WMMc: `ui-1yc453h`, kMwMTN: `ui-15rks2t`, $$css: true }, placeholder: { kMwMTN: `ui-4b2ntj ui-1s8h5yg`, $$css: true } }; +var Rb2 = { md: Ib2.sizeMd, lg: Ib2.sizeLg }; +var zb2 = { md: Ib2.frameContentMd, lg: Ib2.frameContentLg }; +var Bb2 = { md: Ib2.frameContentHugFalseMd, lg: Ib2.frameContentHugFalseLg }; +function Vb2({ children: e38, variant: t2 = Pb2, frame: n2 = `container`, shape: r2 = `rounded`, size: i3 = `lg`, hug: a3 = true, className: o3, style: s3, rootStyle: c3, labelStyle: l5, disabled: u3 = false, id: d3, leading: f4, trailing: p4, open: m3, placeholder: h4, hideChevron: g5 = false, chevronTone: _5, ref: v5, "data-popup-open": y4, ...b2 }) { + Vb2.d = 144452612; + let x2 = e38 == null && h4 != null, S2 = m3 ?? (y4 !== void 0 && y4 !== false), C2 = m3 === void 0 ? y4 : m3 || void 0, w2 = ua2(t2, void 0), T2 = h(Fa2.root, Ib2.base, Ta2.root, La2[i3], Rb2[i3], ma2.appearance, w2.applyControlTone && da2.foreground, w2.applyFilledColors && ma2.colors, w2.applyNonFilledBackground && ha2.background, t2 === `outline` && ha2.outline, S2 && ma2.engaged, !a3 && Ib2.hugFalse, r2 === `pill` ? Ib2.shapePill : Ib2.shapeRounded, n2 === `content` && zb2[i3], n2 === `content` && !a3 && Bb2[i3], c3, Fb2), E2 = h(Aa.root, ja2.root, Lb2.base, x2 && Lb2.placeholder, l5), D2 = { className: `ui-78zum5 ui-6s0dn4 ui-2lah0s ui-1mh7f6w ui-1s8h5yg` }, O2 = { 0: { className: `ui-2lah0s ui-1mh7f6w ui-1s8h5yg` }, 2: { className: `ui-2lah0s ui-4b2ntj ui-1s8h5yg` }, 1: { className: `ui-2lah0s ui-7qsbfx` }, 3: { className: `ui-2lah0s ui-7qsbfx` } }[(_5 === `tertiary`) << 1 | !!S2 << 0]; + return (0, J2.jsxs)(Wc, { ...b2, ...qi2.self, ref: v5, id: d3, className: K2(`ui-select-trigger`, T2.className, o3), style: { ...T2.style, ...s3 }, "data-popup-open": C2, "data-variant": t2, "data-size": i3, disabled: u3, children: [f4 != null && (0, J2.jsx)(`span`, { className: D2.className, style: D2.style, children: f4 }), (0, J2.jsx)(`span`, { className: K2(`ui-select-label`, E2.className), style: E2.style, children: x2 ? h4 : e38 }), p4 != null && (0, J2.jsx)(`span`, { className: D2.className, style: D2.style, children: p4 }), g5 ? null : (0, J2.jsx)(Oi, { name: `chevron-down`, size: 10, className: K2(`ui-select-icon`, O2.className), style: O2.style })] }); +} +var Hb2 = (0, Y2.createContext)(null); +function Ub2() { + let e38 = (0, Y2.useContext)(Hb2); + if (!e38) throw Error(`Select internals must be used within Select`); + return e38; +} +function Wb2() { + Wb2.d = 630649109; + let e38 = Ub2(), t2 = e38.hasValue ? (0, J2.jsx)(Tb, {}) : void 0; + return (0, J2.jsx)(Cb, { disabled: e38.disabled, id: e38.id, ...e38.ariaLabel === void 0 ? {} : { "aria-label": e38.ariaLabel }, ...e38.ariaLabelledBy === void 0 ? {} : { "aria-labelledby": e38.ariaLabelledBy }, render: e38.renderTrigger ?? ((t3, n2) => (0, J2.jsx)(Vb2, { ...t3, className: K2(t3.className, e38.className), disabled: e38.disabled, frame: e38.frame, hug: e38.hug, hideChevron: e38.hideChevron, leading: e38.leading, labelStyle: e38.labelStyle, open: n2.open, placeholder: e38.placeholder, rootStyle: e38.rootStyle, trailing: e38.trailing, shape: e38.shape, size: e38.size, variant: e38.variant })), children: t2 }); +} +function Gb2({ children: e38 }) { + Gb2.d = 4067169765; + let t2 = Ub2(), { labelId: n2 } = fu(), r2 = t2.ariaLabelledBy ?? n2, i3 = Ni2(), { zIndex: a3, portalLayerStyles: o3 } = Gi2(`popover`, t2.open), s3 = jc2(t2.placement, t2.offset, false, t2.collisionSide), c3 = t2.matchAnchorWidth ? `var(--anchor-width)` : t2.contentWidth; + return (0, J2.jsxs)(Eb, { container: i3 ?? void 0, style: o3, children: [(0, J2.jsx)(Ob, { "data-component": `select-backdrop`, ...h(vs2, a3 !== null && ys2(a3 - 1)) }), (0, J2.jsx)(Pb, { align: s3.align, alignItemWithTrigger: false, alignOffset: s3.alignOffset, collisionAvoidance: s3.collisionAvoidance, "data-component": `select-positioner`, positionMethod: s3.positionMethod, side: s3.side, sideOffset: s3.sideOffset, ...Io2(Qo, _s2), children: (0, J2.jsx)(Hb, { "data-block-global-shortcuts": t2.open ? `Escape` : void 0, "data-component": `select-popup`, "data-size": t2.menuSize, ...h(Fs2, No2, Is2[t2.menuSize], c3 === void 0 ? Rs2 : Ls2(c3), t2.contentStyle), children: (0, J2.jsx)(gi2, { menuSize: t2.menuSize, children: (0, J2.jsx)(Tc2, { children: (0, J2.jsx)(Xb, { "aria-label": t2.ariaLabel ?? (r2 === void 0 ? `Select an option` : void 0), "aria-labelledby": r2, ...h(zs2), children: e38 }) }) }) }) })] }); +} +function Kb2({ option: e38 }) { + Kb2.d = 3704735812, Ub2(); + let t2 = e38.description !== void 0, n2 = (0, Y2.useId)(), r2 = `${n2}-label`, i3 = `${n2}-description`, a3 = (0, J2.jsxs)($b, { "aria-labelledby": t2 ? r2 : void 0, "aria-describedby": t2 ? i3 : void 0, disabled: e38.disabled, label: typeof e38.label == `string` ? e38.label : void 0, value: e38.value, "data-component": `select-item`, "data-has-description": t2 || void 0, ...h(Bs2), children: [e38.leading == null ? null : (0, J2.jsx)(`span`, { ...h(qs2, Js, t2 && Zs2), children: e38.leading }), (0, J2.jsxs)(`span`, { ...h(Vs2, t2 && Ws), children: [(0, J2.jsxs)(tx, { id: r2, ...h(e38.labelMeta != null && Us2), children: [(0, J2.jsx)(`span`, { ...h(Hs2), children: e38.label }), e38.labelMeta == null ? null : (0, J2.jsx)(`span`, { ...h(Ks2), children: e38.labelMeta })] }), t2 ? (0, J2.jsx)(`span`, { id: i3, "data-component": `select-item-description`, ...h(Gs2, wa2.root), children: e38.description }) : null] }), e38.trailing == null ? (0, J2.jsx)(ex, { "data-component": `select-item-indicator`, ...h(qs2, Ys, t2 && Zs2), children: (0, J2.jsx)(Oi, { color: `primary`, name: `check`, "aria-hidden": true }) }) : (0, J2.jsxs)(`span`, { "data-component": `select-item-end`, ...h(qs2, Ys, Xs, t2 && Zs2), children: [e38.trailing, (0, J2.jsx)(ex, { "data-component": `select-item-indicator`, children: (0, J2.jsx)(Oi, { color: `primary`, name: `check`, "aria-hidden": true }) })] })] }); + return e38.tooltip == null ? a3 : (0, J2.jsx)(Xl2, { closeDelay: Math.max(e38.tooltipCloseDelay ?? 0, 100), content: e38.tooltip, offset: 6, openDelay: e38.tooltipOpenDelay ?? 0, placement: `right`, sameAxisOnly: true, surfaceStyle: bu2(`default`), children: a3 }); +} +function qb2({ value: e38, defaultValue: t2, onValueChange: n2, open: r2, defaultOpen: i3, onOpenChange: a3, options: o3, placeholder: s3, variant: c3 = Pb2, frame: l5 = `container`, shape: u3 = `rounded`, size: d3 = `lg`, menuSize: f4, contentWidth: p4, matchAnchorWidth: m3 = false, hug: h4 = true, disabled: g5 = false, className: _5, renderTrigger: v5, placement: y4 = `bottom-start`, offset: b2 = 4, collisionSide: x2 = `flip`, "aria-label": S2, "aria-labelledby": C2, id: w2, leading: T2, trailing: E2, labelStyle: D2, rootStyle: O2, hideChevron: k2 = false, contentStyle: A2, ...j2 }) { + qb2.d = 219863591; + let [M2, N3] = Pl(e38, t2, void 0, `Select.Root (value)`), P3 = M2 != null && o3.some((e39) => e39.value === M2), [F2, I2] = Pl(r2, i3 ?? false, void 0, `Select.Root (open)`), L3 = f4 ?? `sm`, R3 = (0, Y2.useCallback)((e39, t3) => { + n2?.(e39, t3), !t3.isCanceled && N3(e39); + }, [n2, N3]), z2 = (0, Y2.useCallback)((e39, t3) => { + a3?.(e39, t3), !t3.isCanceled && I2(e39); + }, [a3, I2]), B3 = (0, Y2.useMemo)(() => ({ hasValue: P3, variant: c3, frame: l5, shape: u3, size: d3, menuSize: L3, hug: h4, disabled: g5, open: F2, placement: y4, offset: b2, collisionSide: x2, id: w2, ariaLabel: S2, ariaLabelledBy: C2, placeholder: s3, leading: T2, trailing: E2, labelStyle: D2, rootStyle: O2, hideChevron: k2, contentStyle: A2, className: _5, renderTrigger: v5, contentWidth: p4, matchAnchorWidth: m3 }), [S2, C2, _5, x2, A2, p4, g5, l5, h4, P3, k2, w2, F2, D2, T2, m3, b2, y4, s3, L3, O2, E2, v5, u3, d3, c3]), ee2 = o3.map((e39) => ({ label: e39.label, value: e39.value })); + return (0, J2.jsx)(Hb2.Provider, { value: B3, children: (0, J2.jsx)(gi2, { iconSize: `sm`, children: (0, J2.jsxs)(yb, { ...j2, defaultOpen: i3, defaultValue: t2, disabled: g5, id: w2, items: ee2, onOpenChange: z2, onValueChange: R3, open: r2, value: e38, children: [(0, J2.jsx)(Wb2, {}), (0, J2.jsx)(Gb2, { children: o3.map((e39, t3) => (0, J2.jsx)(Kb2, { option: e39 }, typeof e39.value == `string` || typeof e39.value == `number` ? String(e39.value) : t3)) })] }) }) }); +} +var sE = Ij(); +function EE(e38) { + let t2 = (0, sE.c)(2), n2 = (0, Y2.useEffectEvent)(e38), r2; t2[0] === n2 ? r2 = t2[1] : (r2 = () => n2, t2[0] = n2, t2[1] = r2); - let [i3] = (0, J2.useState)(r2); + let [i3] = (0, Y2.useState)(r2); return i3; } -function Bw(e9) { - let t2 = (0, bw.c)(2), n2; - t2[0] === e9 ? n2 = t2[1] : (n2 = [e9], t2[0] = e9, t2[1] = n2), (0, J2.useEffect)(e9, n2); -} -function Vw(e9) { - let t2 = (0, bw.c)(2), n2; - t2[0] === e9 ? n2 = t2[1] : (n2 = () => { - e9(); - }, t2[0] = e9, t2[1] = n2), (0, J2.useLayoutEffect)(n2); -} -var ZG = 2e3; -function QG({ durationMs: e9 = ZG } = {}) { - let [t2, n2] = (0, J2.useState)(false), { schedule: r2 } = zv(); - return [t2, (0, J2.useCallback)(() => { - n2(true), r2(() => { - n2(false); - }, e9); - }, [e9, r2])]; +function DE(e38) { + let t2 = (0, sE.c)(2), n2; + t2[0] === e38 ? n2 = t2[1] : (n2 = [e38], t2[0] = e38, t2[1] = n2), (0, Y2.useEffect)(e38, n2); +} +function OE(e38) { + let t2 = (0, sE.c)(2), n2; + t2[0] === e38 ? n2 = t2[1] : (n2 = () => { + e38(); + }, t2[0] = e38, t2[1] = n2), (0, Y2.useLayoutEffect)(n2); } -// ../../../../../private/dist/renderer/assets/index.eager-app-CG8Fw00L.js -function Q() { +// ../../../../../private/dist/renderer/assets/index.eager-app-uZS5Ltig.js +function Q3() { return globalThis.__sandVault0721Client; } -function Ip2() { - return { status: { kind: "logged-in" } }; -} var document3 = globalThis.document; -var navigator2 = globalThis.navigator; -var performance2 = globalThis.performance; -var Y2 = Ke(); -var X2 = u(sandVaultReact(), 1); -var Oa = /^[a-z0-9][a-z0-9-]{0,63}$/; -var Ia2 = /^[A-Za-z0-9_-]{21}$/; -var La2 = { schemes: [`grokbot`, `sand`], authority: `app`, httpsOrigin: `https://cursor.com`, httpsPathPrefixes: [`/grok-bot/link`, `/sand/link`], path: `/v1/bot-template`, maxLength: 2048 }; -var Ua2 = [`onepassword`, `email`]; -var $a2 = [[`account`, `general`], [`theme`, `general`], [`accent`, `general`], [`language`, `general`], [`spell-check`, `general`], [`microphone`, `general`], [`hardware-acceleration`, `general`], [`hardware-acceleration-restart`, `general`], [`network-debugger`, `general`], [`notification-sound-enabled`, `general`], [`notification-sound`, `general`], [`model`, `general`], [`timezone`, `general`], [`local-execution`, `computer`], [`computers`, `computer`], [`chrome-cookie-import`, `computer`], [`messages`, `computer`], [`messages-send-without-asking`, `computer`], [`messages-allowed-recipients`, `computer`], [`auto-review`, `general`], [`auto-review-rules`, `general`], [`security-keys`, `general`], [`team-bot-connector-preferences`, `general`], [`team-bot-slack-link`, `general`], [`passkeys`, `general`], [`usage`, `usage`], [`plan`, `usage`], [`cancel-trial`, `usage`], [`on-demand`, `usage`], [`billing`, `usage`], [`egress`, `computer`], [`update-status`, `updates`], [`update-channel`, `updates`], [`automatic-updates`, `updates`], [`update-computer`, `computer`], [`reset-computer`, `computer`]]; -var eo2 = $a2.map(([e9]) => e9); -function ao(e9) { - return `sand-setting-${e9}`; -} -var oo = `repeated-row`; -var so = [`overview`, `routines`, `media`, `computer`, `meetings`, `members`]; -var co = [`webhook-url`, `webhook-key`, `webhook-header`]; -var po = La2.schemes[0]; -var mo = La2.schemes[1]; -var ho2 = La2.authority; -var go2 = La2.maxLength; -var _o2 = [`plugins`, `bots`]; -var vo2 = /[a-z0-9](?:[a-z0-9.-]*[a-z0-9])?/; -var yo2 = /[A-Za-z0-9_-]{1,128}/; -var bo2 = /[0-9a-f]{10}/; -var xo2 = uS({ authority: ho2, schemes: [po, mo], maxUrlLength: go2, routes: { agent: lS(`/v1/agent`, { id: Xx(yo2) }), "bot-template": lS(La2.path, { id: Xx(Ia2), open: Zx(Xx({ oneOf: [`1`] })) }), marketplace: lS(`/v1/marketplace`, { tab: Zx(Xx({ oneOf: _o2 })), id: Zx(Xx({ pattern: vo2, maxDecodedLength: 128 })) }), "plugin-add": lS(`/v1/plugin/add`, { id: Xx(/[0-9]{1,19}/) }), "plugin-native": lS(`/v1/plugin/native`, { id: Xx({ oneOf: Ua2 }) }), "github-connect-callback": lS(`/v1/github-connect-callback`, { state: Xx(/cursor_grok_bot_github_v1\.[0-9a-f]{32}\.[0-9a-f]{32}/), code: Zx(Xx(/[A-Za-z0-9_-]{1,200}/)), installationId: Zx(Xx(/[1-9][0-9]{0,18}/)), setupAction: Zx(Xx({ oneOf: [`install`, `update`, `request`] })), error: Zx(Xx(/[a-z_]{1,64}/)) }), "gitlab-connect-callback": lS(`/v1/gitlab-connect-callback`, { state: Xx(/cursor_grok_bot_gitlab_v1\.[0-9a-f]{32}\.[0-9a-f]{32}/), code: Zx(Xx(/[A-Za-z0-9_-]{1,200}/)), error: Zx(Xx(/[a-z_]{1,64}/)) }), "bitbucket-connect-callback": lS(`/v1/bitbucket-connect-callback`, { state: Xx(/cursor_grok_bot_bitbucket_v1\.[0-9a-f]{32}\.[0-9a-f]{32}/), code: Zx(Xx(/[A-Za-z0-9._-]{1,1800}/)), error: Zx(Xx(/[a-z_]{1,64}/)) }), "azure-devops-connect-callback": lS(`/v1/azure-devops-connect-callback`, { state: Xx(/cursor_grok_bot_azure_devops_v1\.[0-9a-f]{32}\.[0-9a-f]{32}/), code: Zx(Xx(/[A-Za-z0-9._-]{1,1800}/)), error: Zx(Xx(/[a-z_]{1,64}/)) }), "onepassword-oauth-callback": lS(`/v1/onepassword-oauth-callback`, { state: Xx(/[A-Za-z0-9_-]{32,64}/), code: Zx(Xx({ maxDecodedLength: 1024 })), error: Zx(Xx(/[a-z_]{1,64}/)), integrationKey: Zx(Xx(/ops_[A-Za-z0-9_=-]{1,1536}/)) }), "onepassword-approval-callback": lS(`/v1/onepassword-approval-callback`, { accessRequestId: Xx({ maxDecodedLength: 256 }), status: Xx({ oneOf: [`authorized`, `denied`, `cancelled`, `error`] }), error: Zx(Xx(/[a-z_]{1,64}/)) }), open: lS(`/v1/open`, {}), prompt: lS(`/v1/prompt`, { id: Zx(Xx(yo2)), text: Xx({ pattern: /\s*\S[\s\S]*/, maxDecodedLength: 1e3 }) }), "create-team-bot": lS(`/v1/create-team-bot`, {}), settings: lS(`/v1/settings`, { id: Xx({ oneOf: eo2 }) }), thread: lS(`/v1/thread`, { agent: Zx(Xx(yo2)), id: Xx(bo2) }), task: lS(`/v1/task`, { agent: Zx(Xx(yo2)), id: Xx(bo2) }), vault: lS(`/v1/vault`, { id: Xx(/[0-9]{1,19}/) }), sidebar: lS(`/v1/sidebar`, { target: Zx(Xx({ oneOf: co })), automation: Zx(Xx(Oa)), agent: Zx(Xx(yo2)), tab: Zx(Xx({ oneOf: so })) }) } }); -function jo(e9) { - return xo2.buildUrl(`settings`, { id: e9 }); -} -function Go(e9) { - return e9 === `SAND_AWAY_PARK` || e9 === `SAND_PRESENT_PARK`; -} -var Z2 = UA(); -var Qs2 = class extends Nt { - constructor(e9, t2 = e9.code, n2) { - super(e9, t2, n2), this.name = `SourceFailure`; +var HTMLElement3 = globalThis.HTMLElement; +var performance3 = globalThis.performance; +var Y3 = it(); +var X3 = u(sandVaultReact(), 1); +function Bo3(e38) { + return `sand-setting-${e38}`; +} +function ns2(e38) { + return e38 === `SAND_AWAY_PARK` || e38 === `SAND_PRESENT_PARK`; +} +var Z3 = Ij(); +var ec3 = class extends Ht2 { + constructor(e38, t2 = e38.code, n2) { + super(e38, t2, n2), this.name = `SourceFailure`; } }; -function ec2(e9) { - let t2 = e9?.sandBoxBlockReason; - return Go(t2) || t2 === `SAND_CLIENT_PAUSE`; +function nc3(e38) { + let t2 = e38?.sandBoxBlockReason; + return ns2(t2) || t2 === `SAND_CLIENT_PAUSE`; } -function ic2(e9) { - return e9 === `away` || e9 === `asleep`; +function oc3(e38) { + return e38 === `away` || e38 === `asleep`; } -function sc2(e9, t2) { - return Object.freeze({ name: e9, copy: t2 }); +function lc3(e38, t2) { + return Object.freeze({ name: e38, copy: t2 }); } -var { cc: cc2, lc } = __sandVaultFactory155305(); -function __sandVaultFactory155305() { - let cc3, lc2; - (class e9 { +var { uc: uc3, dc: dc3 } = __sandVaultFactory171959(); +function __sandVaultFactory171959() { + let uc4, dc4; + (class e38 { #e; - constructor(e10) { - this.#e = e10; + constructor(e39) { + this.#e = e39; } static { - cc3 = (e10) => e10.#e, lc2 = (t2) => new e9(t2); + uc4 = (e39) => e39.#e, dc4 = (t2) => new e38(t2); } - panel(e10) { - return (0, X2.createElement)(Tc, { ...e10, read: this, size: `panel` }); + panel(e39) { + return (0, X3.createElement)(xc2, { ...e39, read: this, size: `panel` }); } - row(e10) { - return (0, X2.createElement)(Tc, { ...e10, read: this, size: `row` }); + row(e39) { + return (0, X3.createElement)(xc2, { ...e39, read: this, size: `row` }); } - inline(e10) { - return (0, X2.createElement)(Tc, { ...e10, read: this, size: `inline` }); + inline(e39) { + return (0, X3.createElement)(xc2, { ...e39, read: this, size: `inline` }); } map(t2) { let n2 = this.#e; - return new e9({ settle: () => { - let { definition: e10, state: r2 } = n2.settle(); - return { definition: e10, state: hne(r2, t2) }; + return new e38({ settle: () => { + let { definition: e39, state: r2 } = n2.settle(); + return { definition: e39, state: vre(r2, t2) }; }, retry: n2.retry, force: n2.force, isBoxParked: n2.isBoxParked }); } emptyAs(t2) { let n2 = this.#e; - return new e9({ settle: () => { - let e10 = n2.settle(); - return e10.state.status === `empty` ? { definition: e10.definition, state: { status: `ready`, value: t2 } } : e10; + return new e38({ settle: () => { + let e39 = n2.settle(); + return e39.state.status === `empty` ? { definition: e39.definition, state: { status: `ready`, value: t2 } } : e39; }, retry: n2.retry, force: n2.force, isBoxParked: n2.isBoxParked }); } }); ; - return { cc: cc3, lc: lc2 }; + return { uc: uc4, dc: dc4 }; } -function uc(e9, t2) { - let n2 = (0, Z2.c)(3), r2; - n2[0] !== t2 || n2[1] !== e9 ? (r2 = () => t2(e9.get()), n2[0] = t2, n2[1] = e9, n2[2] = r2) : r2 = n2[2]; +function fc3(e38, t2) { + let n2 = (0, Z3.c)(3), r2; + n2[0] !== t2 || n2[1] !== e38 ? (r2 = () => t2(e38.get()), n2[0] = t2, n2[1] = e38, n2[2] = r2) : r2 = n2[2]; let i3 = r2; - return (0, X2.useSyncExternalStore)(e9.subscribe, i3, i3); -} -var une = Rn(null); -var dc = Rn({ status: `unavailable`, reason: `no-key` }); -var dne = Rn(`settled`); -var fc = (0, X2.createContext)(null); -var pc = (0, X2.createContext)(null); -var mc = (0, X2.createContext)(dne); -function hc(e9, t2) { - let n2 = (0, Z2.c)(3), r2; - return n2[0] !== e9 || n2[1] !== t2 ? (r2 = e9 === null ? une : e9.forceOn(t2), n2[0] = e9, n2[1] = t2, n2[2] = r2) : r2 = n2[2], uc(r2, fne); -} -function fne(e9) { - return e9; -} -function _c(e9, t2, n2) { - let r2 = (0, Z2.c)(13), i3 = (0, X2.useContext)(fc), a3 = uc(t2 ?? dc, pne), o3 = hc(i3, e9.name), s3 = uc((0, X2.useContext)(mc), ic2), c2; - r2[0] !== e9 || r2[1] !== a3 ? (c2 = () => ({ definition: e9, state: a3 }), r2[0] = e9, r2[1] = a3, r2[2] = c2) : c2 = r2[2]; - let l4; - r2[3] !== e9.name || r2[4] !== i3 || r2[5] !== o3 || r2[6] !== n2 ? (l4 = o3 === null ? n2 : () => { - i3?.clear(e9.name), n2(); - }, r2[3] = e9.name, r2[4] = i3, r2[5] = o3, r2[6] = n2, r2[7] = l4) : l4 = r2[7]; + return (0, X3.useSyncExternalStore)(e38.subscribe, i3, i3); +} +var cre = qn2(null); +var lre = qn2({ status: `unavailable`, reason: `no-key` }); +var ure = qn2(`settled`); +var pc3 = (0, X3.createContext)(null); +var mc3 = (0, X3.createContext)(null); +var dre = (0, X3.createContext)(ure); +function fre(e38, t2) { + let n2 = (0, Z3.c)(3), r2; + return n2[0] !== e38 || n2[1] !== t2 ? (r2 = e38 === null ? cre : e38.forceOn(t2), n2[0] = e38, n2[1] = t2, n2[2] = r2) : r2 = n2[2], fc3(r2, pre); +} +function pre(e38) { + return e38; +} +function hc3(e38, t2, n2) { + let r2 = (0, Z3.c)(13), i3 = (0, X3.useContext)(pc3), a3 = fc3(t2 ?? lre, hre), o3 = fre(i3, e38.name), s3 = fc3((0, X3.useContext)(dre), oc3), c3; + r2[0] !== e38 || r2[1] !== a3 ? (c3 = () => ({ definition: e38, state: a3 }), r2[0] = e38, r2[1] = a3, r2[2] = c3) : c3 = r2[2]; + let l5; + r2[3] !== e38.name || r2[4] !== i3 || r2[5] !== o3 || r2[6] !== n2 ? (l5 = o3 === null ? n2 : () => { + i3?.clear(e38.name), n2(); + }, r2[3] = e38.name, r2[4] = i3, r2[5] = o3, r2[6] = n2, r2[7] = l5) : l5 = r2[7]; let u3; - return r2[8] !== o3 || r2[9] !== s3 || r2[10] !== c2 || r2[11] !== l4 ? (u3 = lc({ settle: c2, retry: l4, force: o3, isBoxParked: s3 }), r2[8] = o3, r2[9] = s3, r2[10] = c2, r2[11] = l4, r2[12] = u3) : u3 = r2[12], u3; + return r2[8] !== o3 || r2[9] !== s3 || r2[10] !== c3 || r2[11] !== l5 ? (u3 = dc3({ settle: c3, retry: l5, force: o3, isBoxParked: s3 }), r2[8] = o3, r2[9] = s3, r2[10] = c3, r2[11] = l5, r2[12] = u3) : u3 = r2[12], u3; } -function pne(e9) { - return e9; +function hre(e38) { + return e38; } -function yc(e9, t2, n2, r2, i3) { - let a3 = (0, Z2.c)(5), o3 = hc((0, X2.useContext)(fc), e9.name), s3 = t2 ?? dc, c2; - return a3[0] !== o3 || a3[1] !== i3?.emptyAs || a3[2] !== i3?.freshOnly || a3[3] !== n2 ? (c2 = (e10) => { - let t3 = o3 === null ? e10 : Cc(e10, o3), r3; - return r3 = t3.status === `empty` ? i3?.emptyAs : i3?.freshOnly === true && t3.status !== `ready` ? void 0 : Sc(t3), r3 === void 0 ? void 0 : n2(r3); - }, a3[0] = o3, a3[1] = i3?.emptyAs, a3[2] = i3?.freshOnly, a3[3] = n2, a3[4] = c2) : c2 = a3[4], uc(s3, c2); +function _c2(e38, t2, n2, r2, i3) { + let a3 = (0, Z3.c)(5), o3 = fre((0, X3.useContext)(pc3), e38.name), s3 = t2 ?? lre, c3; + return a3[0] !== o3 || a3[1] !== i3?.emptyAs || a3[2] !== i3?.freshOnly || a3[3] !== n2 ? (c3 = (e39) => { + let t3 = o3 === null ? e39 : yre(e39, o3), r3; + return r3 = t3.status === `empty` ? i3?.emptyAs : i3?.freshOnly === true && t3.status !== `ready` ? void 0 : yc2(t3), r3 === void 0 ? void 0 : n2(r3); + }, a3[0] = o3, a3[1] = i3?.emptyAs, a3[2] = i3?.freshOnly, a3[3] = n2, a3[4] = c3) : c3 = a3[4], fc3(s3, c3); } -function hne(e9, t2) { - switch (e9.status) { +function vre(e38, t2) { + switch (e38.status) { case `ready`: - return { status: `ready`, value: t2(e9.value) }; + return { status: `ready`, value: t2(e38.value) }; case `loading`: - return e9.previous === void 0 ? { status: `loading` } : { status: `loading`, previous: t2(e9.previous) }; + return e38.previous === void 0 ? { status: `loading` } : { status: `loading`, previous: t2(e38.previous) }; case `failed`: - return e9.previous === void 0 ? { status: `failed`, failure: e9.failure } : { status: `failed`, failure: e9.failure, previous: t2(e9.previous) }; + return e38.previous === void 0 ? { status: `failed`, failure: e38.failure } : { status: `failed`, failure: e38.failure, previous: t2(e38.previous) }; case `empty`: case `unavailable`: - return e9; + return e38; } - return e9; + return e38; } -function Sc(e9) { - switch (e9.status) { +function yc2(e38) { + switch (e38.status) { case `ready`: - return e9.value; + return e38.value; case `loading`: case `failed`: - return e9.previous; + return e38.previous; case `empty`: case `unavailable`: return; } - return e9; + return e38; } -function Cc(e9, t2) { - let n2 = t2.cold ? void 0 : Sc(e9); +function yre(e38, t2) { + let n2 = t2.cold ? void 0 : yc2(e38); return t2.kind === `hold` ? n2 === void 0 ? { status: `loading` } : { status: `loading`, previous: n2 } : n2 === void 0 ? { status: `failed`, failure: t2.failure } : { status: `failed`, failure: t2.failure, previous: n2 }; } -function wc(e9) { - let t2 = e9.settle(); - return e9.force === null ? t2 : { definition: t2.definition, state: Cc(t2.state, e9.force) }; +function bc2(e38) { + let t2 = e38.settle(); + return e38.force === null ? t2 : { definition: t2.definition, state: yre(t2.state, e38.force) }; } -var gne = { id: `lHVuBQ` }; -function Tc(e9) { - Tc.d = 63; - let t2 = cc2(e9.read), { definition: n2, state: r2 } = wc(t2); +var bre = { id: `lHVuBQ` }; +function xc2(e38) { + xc2.d = 63; + let t2 = uc3(e38.read), { definition: n2, state: r2 } = bc2(t2); switch (r2.status) { case `ready`: - return Dc(e9.size, e9.value(r2.value, `ready`), null); + return Sc2(e38.size, e38.value(r2.value, `ready`), null); case `loading`: - return r2.previous === void 0 ? Dc(e9.size, e9.loading === void 0 ? (0, X2.createElement)(Oc, { name: n2.name, size: e9.size }) : e9.loading, null) : Dc(e9.size, e9.value(r2.previous, `refreshing`), null); + return r2.previous === void 0 ? Sc2(e38.size, e38.loading === void 0 ? (0, X3.createElement)(Cc3, { name: n2.name, size: e38.size }) : e38.loading, null) : Sc2(e38.size, e38.value(r2.previous, `refreshing`), null); case `empty`: - return e9.empty ?? null; + return e38.empty ?? null; case `unavailable`: - return e9.unavailable ?? null; + return e38.unavailable ?? null; case `failed`: { let i3 = r2.previous !== void 0; - if (e9.asleep !== void 0 && Ec(r2.failure, i3, t2.isBoxParked)) return e9.asleep; - let a3 = (0, X2.createElement)(kc, { definition: n2, size: e9.size, failure: r2.failure, isStale: i3, retry: t2.retry }); - return r2.previous === void 0 ? a3 : Dc(e9.size, e9.value(r2.previous, `stale`), a3); + if (e38.asleep !== void 0 && xre(r2.failure, i3, t2.isBoxParked)) return e38.asleep; + let a3 = (0, X3.createElement)(wc3, { definition: n2, size: e38.size, failure: r2.failure, isStale: i3, retry: t2.retry }); + return r2.previous === void 0 ? a3 : Sc2(e38.size, e38.value(r2.previous, `stale`), a3); } } return r2; } -function Ec(e9, t2, n2) { - return n2 && !t2 && Go(e9.sandBoxBlockReason); +function xre(e38, t2, n2) { + return n2 && !t2 && ns2(e38.sandBoxBlockReason); } -function Dc(e9, t2, n2) { - return e9 === `panel` ? (0, X2.createElement)(X2.Fragment, null, n2, t2) : (0, X2.createElement)(X2.Fragment, null, t2, n2); +function Sc2(e38, t2, n2) { + return e38 === `panel` ? (0, X3.createElement)(X3.Fragment, null, n2, t2) : (0, X3.createElement)(X3.Fragment, null, t2, n2); } -function Oc(e9) { - Oc.d = 60; - let t2 = (0, Z2.c)(4), n2 = (0, X2.useContext)(pc), r2; - return t2[0] !== n2 || t2[1] !== e9.name || t2[2] !== e9.size ? (r2 = n2 === null ? null : (0, X2.createElement)(n2, { read: e9.name, size: e9.size, state: `loading` }), t2[0] = n2, t2[1] = e9.name, t2[2] = e9.size, t2[3] = r2) : r2 = t2[3], r2; +function Cc3(e38) { + Cc3.d = 60; + let t2 = (0, Z3.c)(4), n2 = (0, X3.useContext)(mc3), r2; + return t2[0] !== n2 || t2[1] !== e38.name || t2[2] !== e38.size ? (r2 = n2 === null ? null : (0, X3.createElement)(n2, { read: e38.name, size: e38.size, state: `loading` }), t2[0] = n2, t2[1] = e38.name, t2[2] = e38.size, t2[3] = r2) : r2 = t2[3], r2; } -function kc(e9) { - kc.d = 59; - let t2 = (0, Z2.c)(10), { definition: n2, size: r2, failure: i3, isStale: a3, retry: o3 } = e9, s3 = (0, X2.useContext)(pc), [c2, l4] = (0, X2.useState)(null); - if (G(s3 !== null, () => `"${n2.name}" failed under a SandClientProvider with no readStatus`), ec2(i3)) return null; - let u3 = a3 ? `stale` : `failed`, d3 = a3 ? gne : n2.copy, f4 = i3.display?.detail ?? null, p4; - return t2[0] !== s3 || t2[1] !== n2.name || t2[2] !== i3 || t2[3] !== c2 || t2[4] !== o3 || t2[5] !== r2 || t2[6] !== u3 || t2[7] !== d3 || t2[8] !== f4 ? (p4 = (0, X2.createElement)(s3, { read: n2.name, size: r2, state: u3, copy: { message: d3, detail: f4 }, retry: i3.retry === null ? null : { owner: i3.retry.owner, command: i3.retry.command, isPending: c2 === i3, run: () => { - l4(i3), o3(); - } } }), t2[0] = s3, t2[1] = n2.name, t2[2] = i3, t2[3] = c2, t2[4] = o3, t2[5] = r2, t2[6] = u3, t2[7] = d3, t2[8] = f4, t2[9] = p4) : p4 = t2[9], p4; +function wc3(e38) { + wc3.d = 59; + let t2 = (0, Z3.c)(10), { definition: n2, size: r2, failure: i3, isStale: a3, retry: o3 } = e38, s3 = (0, X3.useContext)(mc3), [c3, l5] = (0, X3.useState)(null); + if (Ve(s3 !== null, () => `"${n2.name}" failed under a SandClientProvider with no readStatus`), nc3(i3)) return null; + let u3 = a3 ? `stale` : `failed`, d3 = a3 ? bre : n2.copy, f4 = i3.display?.detail ?? null, p4; + return t2[0] !== s3 || t2[1] !== n2.name || t2[2] !== i3 || t2[3] !== c3 || t2[4] !== o3 || t2[5] !== r2 || t2[6] !== u3 || t2[7] !== d3 || t2[8] !== f4 ? (p4 = (0, X3.createElement)(s3, { read: n2.name, size: r2, state: u3, copy: { message: d3, detail: f4 }, retry: i3.retry === null ? null : { owner: i3.retry.owner, command: i3.retry.command, isPending: c3 === i3, run: () => { + l5(i3), o3(); + } } }), t2[0] = s3, t2[1] = n2.name, t2[2] = i3, t2[3] = c3, t2[4] = o3, t2[5] = r2, t2[6] = u3, t2[7] = d3, t2[8] = f4, t2[9] = p4) : p4 = t2[9], p4; } -function Uc2(e9) { - return Gc(e9, bne); +function Lc3(e38) { + return zc3(e38, Ere); } -function bne(e9) { - return e9; +function Ere(e38) { + return e38; } -function Gc(e9, t2) { - let n2 = (0, Z2.c)(3), r2; - n2[0] !== t2 || n2[1] !== e9 ? (r2 = () => t2(e9.get()), n2[0] = t2, n2[1] = e9, n2[2] = r2) : r2 = n2[2]; +function zc3(e38, t2) { + let n2 = (0, Z3.c)(3), r2; + n2[0] !== t2 || n2[1] !== e38 ? (r2 = () => t2(e38.get()), n2[0] = t2, n2[1] = e38, n2[2] = r2) : r2 = n2[2]; let i3 = r2; - return (0, X2.useSyncExternalStore)(e9.subscribe, i3, i3); -} -var nl = /* @__PURE__ */ new Set(); -var rl = []; -var il = 0; -function al(e9) { - if (rl.length >= 64) { - il += 1; + return (0, X3.useSyncExternalStore)(e38.subscribe, i3, i3); +} +var Are = `client/command-failed`; +function jre(e38) { + return e38 instanceof ec3 ? e38.failure : { code: Are, boundary: `client`, retry: null }; +} +async function Mre(e38, t2, n2) { + n2.newestRun.current += 1; + let r2 = n2.newestRun.current; + n2.setFailure(null), n2.setPendingCount((e39) => e39 + 1); + try { + return { ok: true, value: await e38(...t2) }; + } catch (e39) { + return r2 === n2.newestRun.current && n2.setFailure(jre(e39)), { ok: false, error: e39 }; + } finally { + n2.setPendingCount((e39) => e39 - 1); + } +} +function Hc2(e38) { + let t2 = (0, Z3.c)(14), [n2, r2] = (0, X3.useState)(0), [i3, a3] = (0, X3.useState)(null), o3 = (0, X3.useRef)(0), s3; + t2[0] === e38 ? s3 = t2[1] : (s3 = (...t3) => Mre(e38, t3, { newestRun: o3, setFailure: a3, setPendingCount: r2 }), t2[0] = e38, t2[1] = s3); + let c3 = s3, l5; + t2[2] === c3 ? l5 = t2[3] : (l5 = async (...e39) => { + let t3 = await c3(...e39); + if (t3.ok) return t3.value; + throw t3.error; + }, t2[2] = c3, t2[3] = l5); + let u3 = l5, d3; + t2[4] === c3 ? d3 = t2[5] : (d3 = (...e39) => { + c3(...e39); + }, t2[4] = c3, t2[5] = d3); + let f4 = d3, p4; + t2[6] === c3 ? p4 = t2[7] : (p4 = async (...e39) => (await c3(...e39)).ok, t2[6] = c3, t2[7] = p4); + let m3 = p4, h4 = n2 > 0, g5; + return t2[8] !== m3 || t2[9] !== f4 || t2[10] !== i3 || t2[11] !== u3 || t2[12] !== h4 ? (g5 = { run: u3, dispatch: f4, attempt: m3, isPending: h4, failure: i3 }, t2[8] = m3, t2[9] = f4, t2[10] = i3, t2[11] = u3, t2[12] = h4, t2[13] = g5) : g5 = t2[13], g5; +} +var Xc2 = /* @__PURE__ */ new Set(); +var Zc2 = []; +var Qc2 = 0; +function $c2(e38) { + if (Zc2.length >= 64) { + Qc2 += 1; return; } - rl.push(e9); + Zc2.push(e38); } -var ol = (...e9) => { - if (nl.size === 0) { - al({ kind: `exception`, args: e9 }); +var el2 = (...e38) => { + if (Xc2.size === 0) { + $c2({ kind: `exception`, args: e38 }); return; } - for (let t2 of nl) t2.captureException(...e9); + for (let t2 of Xc2) t2.captureException(...e38); }; -var $ne = 100; -var fl = []; -var pl = null; -function ml(e9) { - if (pl != null) { - e9(pl); +var sie = 100; +var il2 = []; +var al2 = null; +function ol2(e38) { + if (al2 != null) { + e38(al2); return; } - fl.length >= $ne || fl.push(e9); + il2.length >= sie || il2.push(e38); } -function hl(e9) { - ml((t2) => t2.reportClientResourceEdge(e9)); +function lie(e38) { + ol2((t2) => t2.reportClientResourceEdge(e38)); } -function gl(e9, t2) { - ml((n2) => n2.reportRendererBoundaryCaught(e9, t2)); +function sl2(e38, t2) { + ol2((n2) => n2.reportRendererBoundaryCaught(e38, t2)); } -function _l(e9) { - gl(`other`, e9); +function cl2(e38) { + sl2(`other`, e38); } -function wu(e9) { - return Uc2(Q().experiments.snapshots)?.featureGates?.[e9] ?? false; +function Au(e38) { + return Lc3(Q3().experiments.snapshots)?.featureGates?.[e38] ?? false; } -function Ou() { - return Q().experiments.expose; +function Nu2() { + return Q3().experiments.expose; } -function nd() { - let e9 = (0, Z2.c)(2), { alert: t2 } = Q(), n2; - return e9[0] === t2 ? n2 = e9[1] : (n2 = (e10) => t2.alert(e10), e9[0] = t2, e9[1] = n2), n2; +function Yu3() { + let e38 = (0, Z3.c)(2), { alert: t2 } = Q3(), n2; + return e38[0] === t2 ? n2 = e38[1] : (n2 = (e39) => t2.alert(e39), e38[0] = t2, e38[1] = n2), n2; } -var _d = `source/cancelled`; -var vd = `source/capability-unavailable`; -var voe = /* @__PURE__ */ new Set([_d, vd]); -function Od(e9, t2 = () => performance2.now()) { - let n2 = /* @__PURE__ */ new Map(), r2 = (e10, t3) => ({ domain: e10.domain, operation: e10.operation, failureCode: t3.failureCode, boundary: t3.boundary, retryOwner: t3.retryOwner, ...t3.transportKind === void 0 ? {} : { transportKind: t3.transportKind } }); +var kse = `source/cancelled`; +var td2 = `source/capability-unavailable`; +var Vse = /* @__PURE__ */ new Set([kse, td2]); +function Hse(e38, t2 = () => performance3.now()) { + let n2 = /* @__PURE__ */ new Map(), r2 = (e39, t3) => ({ domain: e39.domain, operation: e39.operation, failureCode: t3.failureCode, boundary: t3.boundary, retryOwner: t3.retryOwner, ...t3.transportKind === void 0 ? {} : { transportKind: t3.transportKind } }); return { noteSuccess(i3) { let a3 = `${i3.domain}|${i3.operation}`, o3 = n2.get(a3); - o3 != null && (n2.delete(a3), e9({ ...r2(i3, o3), state: `recovered`, failedMs: Math.max(0, t2() - o3.failedAtMs) })); + o3 != null && (n2.delete(a3), e38({ ...r2(i3, o3), state: `recovered`, failedMs: Math.max(0, t2() - o3.failedAtMs) })); }, noteFailure(i3, a3) { - if (voe.has(a3.code) || a3.transportKind === `pre_port_settle`) return; + if (Vse.has(a3.code) || a3.transportKind === `pre_port_settle`) return; let o3 = `${i3.domain}|${i3.operation}`, s3 = n2.get(o3); if (s3 != null && s3.failureCode === a3.code) return; - let c2 = s3?.failedAtMs ?? t2(), l4 = { failureCode: a3.code, boundary: a3.boundary, retryOwner: a3.retry?.owner ?? `none`, transportKind: a3.transportKind, failedAtMs: c2 }; - n2.set(o3, l4), e9({ ...r2(i3, l4), state: `failed` }); + let c3 = s3?.failedAtMs ?? t2(), l5 = { failureCode: a3.code, boundary: a3.boundary, retryOwner: a3.retry?.owner ?? `none`, transportKind: a3.transportKind, failedAtMs: c3 }; + n2.set(o3, l5), e38({ ...r2(i3, l5), state: `failed` }); } }; } -function kd(e9) { - let t2 = Od(hl); - return { noteSuccess: () => t2.noteSuccess(e9), noteFailure: (n2) => t2.noteFailure(e9, n2) }; +function sd2(e38) { + let t2 = Hse(lie); + return { noteSuccess: () => t2.noteSuccess(e38), noteFailure: (n2) => t2.noteFailure(e38, n2) }; } -var _ge = /* @__PURE__ */ new Set([`image/png`, `image/jpeg`, `image/gif`, `image/webp`]); -var y_ = `grok_bot_vault`; -var yge = `grok_bot_vault_cards`; -var bge = new Set(`AC.AN.BU.CP.CQ.CS.DD.DG.DY.EA.EU.EZ.FX.HV.IC.NH.QO.RH.SU.TA.TP.UK.UN.VD.XA.XB.YD.YU.ZR.ZZ`.split(`.`)); -var xge = /* @__PURE__ */ new Map([[`DY`, `BJ`], [`HV`, `BF`], [`NH`, `VU`], [`RH`, `ZW`], [`UK`, `GB`], [`VD`, `VN`]]); -function Sge(e9) { - return bge.has(e9); +function Md2() { + let e38 = (0, Z3.c)(2), { desktop: t2 } = Q3(), n2; + return e38[0] === t2 ? n2 = e38[1] : (n2 = (e39) => t2.openExternal({ url: e39 }), e38[0] = t2, e38[1] = n2), n2; } -function Cge(e9) { - let t2 = e9.trim().toUpperCase(); - return xge.get(t2) ?? t2; +function of2() { + return Q3().desktopWindow.environment; } -function wge(e9) { - if (!/^[A-Z]{2}$/.test(e9) || Sge(e9)) return false; - let t2 = new Intl.DisplayNames([`en`], { type: `region` }).of(e9); - return t2 !== void 0 && t2 !== e9 && t2 !== `Unknown Region`; +function lf2() { + return Q3().desktopWindow.subscribeWindowFocus; } -var Tge = sc2(`grok-bot-vault-logins`, { id: `wX2bQb` }); -function Ege() { - let e9 = wu(y_); - return Ip2().status.kind === `logged-in` && e9; +function df2() { + return Lc3(Q3().theme.snapshots); } -function Dge() { - let e9 = (0, Z2.c)(2), { grokBotVault: t2 } = Q(), n2; - return e9[0] === t2 ? n2 = e9[1] : (n2 = () => t2.retry(), e9[0] = t2, e9[1] = n2), _c(Tge, t2.snapshots, n2); +function up3() { + return { status: { kind: "logged-in" } }; +} +function Ep3(e38, t2) { + let n2 = e38.toLocaleLowerCase(t2).replaceAll(`\u03C2`, `\u03C3`); + return t2 === `tr` ? n2.replaceAll(`\u0131`, `i`) : n2; +} +function N_e() { + return Hc2(Q3().deviceToolPermissions.openSettings); +} +var f_2 = /* @__PURE__ */ new Set([`image/png`, `image/jpeg`, `image/gif`, `image/webp`]); +var m_2 = `grok_bot_vault`; +var h_2 = `grok_bot_vault_cards`; +var Yve = new Set(`AC.AN.BU.CP.CQ.CS.DD.DG.DY.EA.EU.EZ.FX.HV.IC.NH.QO.RH.SU.TA.TP.UK.UN.VD.XA.XB.YD.YU.ZR.ZZ`.split(`.`)); +var Xve = /* @__PURE__ */ new Map([[`DY`, `BJ`], [`HV`, `BF`], [`NH`, `VU`], [`RH`, `ZW`], [`UK`, `GB`], [`VD`, `VN`]]); +function Zve(e38) { + return Yve.has(e38); +} +function Qve(e38) { + let t2 = e38.trim().toUpperCase(); + return Xve.get(t2) ?? t2; +} +function $ve(e38) { + if (!/^[A-Z]{2}$/.test(e38) || Zve(e38)) return false; + let t2 = new Intl.DisplayNames([`en`], { type: `region` }).of(e38); + return t2 !== void 0 && t2 !== e38 && t2 !== `Unknown Region`; +} +var g_2 = lc3(`grok-bot-vault-logins`, { id: `wX2bQb` }); +function __2() { + let e38 = Au(m_2); + return up3().status.kind === `logged-in` && e38; +} +function eye() { + let e38 = (0, Z3.c)(2), { grokBotVault: t2 } = Q3(), n2; + return e38[0] === t2 ? n2 = e38[1] : (n2 = () => t2.retry(), e38[0] = t2, e38[1] = n2), hc3(g_2, t2.snapshots, n2); +} +function tye(e38) { + let t2 = (0, Z3.c)(3), n2; + t2[0] === e38 ? n2 = t2[1] : (n2 = (t3) => t3.some((t4) => t4.id === e38 && (t4.contact?.line1.trim() ?? ``) !== ``) ? e38 ?? `` : ``, t2[0] = e38, t2[1] = n2); + let r2; + return t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { emptyAs: [], freshOnly: true }, t2[2] = r2) : r2 = t2[2], _c2(g_2, Q3().grokBotVault.snapshots, n2, `id`, r2); } -function Oge(e9) { - let t2 = (0, Z2.c)(2), n2; - return t2[0] === e9 ? n2 = t2[1] : (n2 = (t3) => t3.find((t4) => t4.id === e9), t2[0] = e9, t2[1] = n2), yc(Tge, Q().grokBotVault.snapshots, n2, `entity`); +function nye(e38) { + let t2 = (0, Z3.c)(2), n2; + return t2[0] === e38 ? n2 = t2[1] : (n2 = (t3) => t3.find((t4) => t4.id === e38), t2[0] = e38, t2[1] = n2), _c2(g_2, Q3().grokBotVault.snapshots, n2, `entity`); } -function kge() { - return Q().grokBotVault; +function v_2() { + return Q3().grokBotVault; } -function Age() { - return Uc2(Q().grokBotVault.cardPhotoHandoff); +function aye(e38) { + return e38 instanceof ec3 && e38.failure.code === `grok-bot-vault/refused` ? e38.message : null; } -function Mge(e9) { - return e9 instanceof Qs2 && e9.failure.code === `grok-bot-vault/refused` ? e9.message : null; +var Ny3 = `desktop-source/capability-unavailable`; +function aPe() { + return Q3().clock; } -var Gv = `desktop-source/capability-unavailable`; -function $(...e9) { +function $2(...e38) { let t2 = ``; - for (let n2 of e9) n2 && (t2 = t2.length > 0 ? `${t2} ${n2}` : n2); + for (let n2 of e38) n2 && (t2 = t2.length > 0 ? `${t2} ${n2}` : n2); return t2; } -var sx = { xxs: { kGuDYH: `sand-7uqsge`, kLWn49: `sand-19jnaw5`, kb6lSQ: `sand-1h1hs02`, $$css: true }, xs: { kGuDYH: `sand-1ao5zh4`, kLWn49: `sand-10jubzo`, kb6lSQ: `sand-b7p3tu`, $$css: true }, sm: { kGuDYH: `sand-g2dot2`, kLWn49: `sand-w8bs97`, kb6lSQ: `sand-14gdtuo`, $$css: true }, base: { kGuDYH: `sand-1yil2se`, kLWn49: `sand-1lvvshy`, kb6lSQ: `sand-ja3w2a`, $$css: true }, lg: { kGuDYH: `sand-q1hgy8`, kLWn49: `sand-1971ylj`, kb6lSQ: `sand-99smjr`, $$css: true }, xl: { kGuDYH: `sand-79ao00`, kLWn49: `sand-10ux60h`, kb6lSQ: `sand-k0i524`, $$css: true }, xxl: { kGuDYH: `sand-1mmermx`, kLWn49: `sand-vh7mc1`, kb6lSQ: `sand-1ehaq9d`, $$css: true }, xxxl: { kGuDYH: `sand-zdi6ij`, kLWn49: `sand-1odv9bt`, kb6lSQ: `sand-lnf3q9`, $$css: true }, heading1: { kGuDYH: `sand-1ewwscv`, kLWn49: `sand-1odv9bt`, kb6lSQ: `sand-lnf3q9`, $$css: true }, heading2: { kGuDYH: `sand-1i1m3gp`, kLWn49: `sand-vh7mc1`, kb6lSQ: `sand-1ehaq9d`, $$css: true }, heading3: { kGuDYH: `sand-19d36u7`, kLWn49: `sand-10ux60h`, kb6lSQ: `sand-k0i524`, $$css: true }, body1: { kGuDYH: `sand-fc7y3v`, kLWn49: `sand-1lvvshy`, kb6lSQ: `sand-ja3w2a`, $$css: true }, body2: { kGuDYH: `sand-11wthnw`, kLWn49: `sand-w8bs97`, kb6lSQ: `sand-14gdtuo`, $$css: true }, label: { kGuDYH: `sand-1wm8ruf`, kLWn49: `sand-10jubzo`, kb6lSQ: `sand-b7p3tu`, $$css: true }, caption: { kGuDYH: `sand-y5h43f`, kLWn49: `sand-19jnaw5`, kb6lSQ: `sand-1h1hs02`, $$css: true } }; -var cx = { regular: { k63SB2: `sand-1k6tqyu`, $$css: true }, medium: { k63SB2: `sand-1rhlpx6`, $$css: true }, semibold: { k63SB2: `sand-xzm5a7`, $$css: true } }; -function lx(e9) { - lx.d = 2185; - let t2 = (0, Z2.c)(28), n2, r2, i3, a3, o3, s3, c2, l4; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c2 = t2[7], l4 = t2[8]) : ({ children: n2, level: s3, weight: c2, as: l4, className: r2, style: o3, ref: i3, ...a3 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c2, t2[8] = l4); - let u3 = s3 === void 0 ? `body1` : s3, d3 = c2 === void 0 ? `regular` : c2, f4 = l4 === void 0 ? `span` : l4, p4, m3, h3, g3; - t2[9] !== f4 || t2[10] !== r2 || t2[11] !== u3 || t2[12] !== a3 || t2[13] !== o3 || t2[14] !== d3 ? (m3 = h(sx[u3], cx[d3], o3), p4 = f4, h3 = a3, g3 = $(`sand-kit-text`, m3.className, r2), t2[9] = f4, t2[10] = r2, t2[11] = u3, t2[12] = a3, t2[13] = o3, t2[14] = d3, t2[15] = p4, t2[16] = m3, t2[17] = h3, t2[18] = g3) : (p4 = t2[15], m3 = t2[16], h3 = t2[17], g3 = t2[18]); - let _2 = i3, v3; - return t2[19] !== p4 || t2[20] !== m3.style || t2[21] !== n2 || t2[22] !== u3 || t2[23] !== h3 || t2[24] !== g3 || t2[25] !== _2 || t2[26] !== d3 ? (v3 = (0, Y2.jsx)(p4, { ...h3, className: g3, "data-level": u3, "data-weight": d3, ref: _2, style: m3.style, children: n2 }), t2[19] = p4, t2[20] = m3.style, t2[21] = n2, t2[22] = u3, t2[23] = h3, t2[24] = g3, t2[25] = _2, t2[26] = d3, t2[27] = v3) : v3 = t2[27], v3; -} -var Kje = 8e3; -var ES = `sand-anchor-flash`; -function DS(e9) { - let t2 = (0, X2.createContext)(null); - function n2(e10) { - e10.scrollIntoView({ block: `center` }), e10.classList.remove(ES), e10.offsetWidth, e10.classList.add(ES); +var Jb2 = { xxs: { kGuDYH: `sand-7uqsge`, kLWn49: `sand-19jnaw5`, kb6lSQ: `sand-1h1hs02`, $$css: true }, xs: { kGuDYH: `sand-1ao5zh4`, kLWn49: `sand-10jubzo`, kb6lSQ: `sand-b7p3tu`, $$css: true }, sm: { kGuDYH: `sand-g2dot2`, kLWn49: `sand-w8bs97`, kb6lSQ: `sand-14gdtuo`, $$css: true }, base: { kGuDYH: `sand-1yil2se`, kLWn49: `sand-1lvvshy`, kb6lSQ: `sand-ja3w2a`, $$css: true }, lg: { kGuDYH: `sand-q1hgy8`, kLWn49: `sand-1971ylj`, kb6lSQ: `sand-99smjr`, $$css: true }, xl: { kGuDYH: `sand-79ao00`, kLWn49: `sand-10ux60h`, kb6lSQ: `sand-k0i524`, $$css: true }, xxl: { kGuDYH: `sand-1mmermx`, kLWn49: `sand-vh7mc1`, kb6lSQ: `sand-1ehaq9d`, $$css: true }, xxxl: { kGuDYH: `sand-zdi6ij`, kLWn49: `sand-1odv9bt`, kb6lSQ: `sand-lnf3q9`, $$css: true }, heading1: { kGuDYH: `sand-1ewwscv`, kLWn49: `sand-1odv9bt`, kb6lSQ: `sand-lnf3q9`, $$css: true }, heading2: { kGuDYH: `sand-1i1m3gp`, kLWn49: `sand-vh7mc1`, kb6lSQ: `sand-1ehaq9d`, $$css: true }, heading3: { kGuDYH: `sand-19d36u7`, kLWn49: `sand-10ux60h`, kb6lSQ: `sand-k0i524`, $$css: true }, body1: { kGuDYH: `sand-fc7y3v`, kLWn49: `sand-1lvvshy`, kb6lSQ: `sand-ja3w2a`, $$css: true }, body2: { kGuDYH: `sand-11wthnw`, kLWn49: `sand-w8bs97`, kb6lSQ: `sand-14gdtuo`, $$css: true }, label: { kGuDYH: `sand-1wm8ruf`, kLWn49: `sand-10jubzo`, kb6lSQ: `sand-b7p3tu`, $$css: true }, caption: { kGuDYH: `sand-y5h43f`, kLWn49: `sand-19jnaw5`, kb6lSQ: `sand-1h1hs02`, $$css: true } }; +var Yb2 = { regular: { k63SB2: `sand-1k6tqyu`, $$css: true }, medium: { k63SB2: `sand-1rhlpx6`, $$css: true }, semibold: { k63SB2: `sand-xzm5a7`, $$css: true } }; +function Xb2(e38) { + Xb2.d = 2469; + let t2 = (0, Z3.c)(28), n2, r2, i3, a3, o3, s3, c3, l5; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c3 = t2[7], l5 = t2[8]) : ({ children: n2, level: s3, weight: c3, as: l5, className: r2, style: o3, ref: i3, ...a3 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c3, t2[8] = l5); + let u3 = s3 === void 0 ? `body1` : s3, d3 = c3 === void 0 ? `regular` : c3, f4 = l5 === void 0 ? `span` : l5, p4, m3, h4, g5; + t2[9] !== f4 || t2[10] !== r2 || t2[11] !== u3 || t2[12] !== a3 || t2[13] !== o3 || t2[14] !== d3 ? (m3 = h(Jb2[u3], Yb2[d3], o3), p4 = f4, h4 = a3, g5 = $2(`sand-kit-text`, m3.className, r2), t2[9] = f4, t2[10] = r2, t2[11] = u3, t2[12] = a3, t2[13] = o3, t2[14] = d3, t2[15] = p4, t2[16] = m3, t2[17] = h4, t2[18] = g5) : (p4 = t2[15], m3 = t2[16], h4 = t2[17], g5 = t2[18]); + let _5 = i3, v5; + return t2[19] !== p4 || t2[20] !== m3.style || t2[21] !== n2 || t2[22] !== u3 || t2[23] !== h4 || t2[24] !== g5 || t2[25] !== _5 || t2[26] !== d3 ? (v5 = (0, Y3.jsx)(p4, { ...h4, className: g5, "data-level": u3, "data-weight": d3, ref: _5, style: m3.style, children: n2 }), t2[19] = p4, t2[20] = m3.style, t2[21] = n2, t2[22] = u3, t2[23] = h4, t2[24] = g5, t2[25] = _5, t2[26] = d3, t2[27] = v5) : v5 = t2[27], v5; +} +var aIe = 8e3; +var kx = `sand-anchor-flash`; +function Ax(e38) { + let t2 = (0, X3.createContext)(null); + function n2(e39) { + e39.scrollIntoView({ block: `center` }), e39.classList.remove(kx), e39.offsetWidth, e39.classList.add(kx); } function r2(r3) { - let i4 = (0, Z2.c)(14), { focus: a4, children: o3 } = r3, s3 = a4?.anchor ?? null, c2 = a4?.arrival ?? 0, l4 = (0, X2.useRef)(null), u3 = (0, X2.useRef)(0), d3; - i4[0] !== s3 || i4[1] !== c2 ? (d3 = s3 == null ? null : { anchor: s3, arrival: c2 }, i4[0] = s3, i4[1] = c2, i4[2] = d3) : d3 = i4[2]; + let i4 = (0, Z3.c)(14), { focus: a4, children: o3 } = r3, s3 = a4?.anchor ?? null, c3 = a4?.arrival ?? 0, l5 = (0, X3.useRef)(null), u3 = (0, X3.useRef)(0), d3; + i4[0] !== s3 || i4[1] !== c3 ? (d3 = s3 == null ? null : { anchor: s3, arrival: c3 }, i4[0] = s3, i4[1] = c3, i4[2] = d3) : d3 = i4[2]; let f4 = d3, p4; - i4[3] === c2 ? p4 = i4[4] : (p4 = () => { - let e10 = l4.current; - return e10?.arrival === c2 && Date.now() >= e10.expiresAt; - }, i4[3] = c2, i4[4] = p4); - let m3 = p4, h3; - i4[5] !== f4 || i4[6] !== m3 ? (h3 = { applyIfClaimed: (t3) => { + i4[3] === c3 ? p4 = i4[4] : (p4 = () => { + let e39 = l5.current; + return e39?.arrival === c3 && Date.now() >= e39.expiresAt; + }, i4[3] = c3, i4[4] = p4); + let m3 = p4, h4; + i4[5] !== f4 || i4[6] !== m3 ? (h4 = { applyIfClaimed: (t3) => { if (f4 == null || t3 !== f4.anchor || u3.current === f4.arrival || m3()) return; - let r4 = document3.getElementById(e9(t3)); + let r4 = document3.getElementById(e38(t3)); r4 != null && (u3.current = f4.arrival, n2(r4)); - }, liveClaim: () => f4 == null || m3() ? null : f4 }, i4[5] = f4, i4[6] = m3, i4[7] = h3) : h3 = i4[7]; - let g3 = h3, _2; - i4[8] !== s3 || i4[9] !== c2 ? (_2 = () => { - s3 != null && l4.current?.arrival !== c2 && (l4.current = { arrival: c2, expiresAt: Date.now() + Kje }); - }, i4[8] = s3, i4[9] = c2, i4[10] = _2) : _2 = i4[10], Vw(_2); - let v3; - return i4[11] !== o3 || i4[12] !== g3 ? (v3 = (0, Y2.jsx)(t2.Provider, { value: g3, children: o3 }), i4[11] = o3, i4[12] = g3, i4[13] = v3) : v3 = i4[13], v3; - } - function i3(e10) { - let n3 = (0, Z2.c)(3), r3 = (0, X2.useContext)(t2), i4; - n3[0] !== e10 || n3[1] !== r3 ? (i4 = () => { - e10 != null && r3 != null && r3.applyIfClaimed(e10); - }, n3[0] = e10, n3[1] = r3, n3[2] = i4) : i4 = n3[2], Vw(i4); - } - function a3(e10) { - let n3 = (0, Z2.c)(3), r3 = (0, X2.useContext)(t2), i4 = (0, X2.useRef)(0), a4; - n3[0] !== e10 || n3[1] !== r3 ? (a4 = () => { + }, liveClaim: () => f4 == null || m3() ? null : f4 }, i4[5] = f4, i4[6] = m3, i4[7] = h4) : h4 = i4[7]; + let g5 = h4, _5; + i4[8] !== s3 || i4[9] !== c3 ? (_5 = () => { + s3 != null && l5.current?.arrival !== c3 && (l5.current = { arrival: c3, expiresAt: Date.now() + aIe }); + }, i4[8] = s3, i4[9] = c3, i4[10] = _5) : _5 = i4[10], OE(_5); + let v5; + return i4[11] !== o3 || i4[12] !== g5 ? (v5 = (0, Y3.jsx)(t2.Provider, { value: g5, children: o3 }), i4[11] = o3, i4[12] = g5, i4[13] = v5) : v5 = i4[13], v5; + } + function i3(e39) { + let n3 = (0, Z3.c)(3), r3 = (0, X3.useContext)(t2), i4; + n3[0] !== e39 || n3[1] !== r3 ? (i4 = () => { + e39 != null && r3 != null && r3.applyIfClaimed(e39); + }, n3[0] = e39, n3[1] = r3, n3[2] = i4) : i4 = n3[2], OE(i4); + } + function a3(e39) { + let n3 = (0, Z3.c)(3), r3 = (0, X3.useContext)(t2), i4 = (0, X3.useRef)(0), a4; + n3[0] !== e39 || n3[1] !== r3 ? (a4 = () => { let t3 = r3?.liveClaim() ?? null; - t3 != null && i4.current !== t3.arrival && (i4.current = t3.arrival, e10(t3.anchor)); - }, n3[0] = e10, n3[1] = r3, n3[2] = a4) : a4 = n3[2], Vw(a4); + t3 != null && i4.current !== t3.arrival && (i4.current = t3.arrival, e39(t3.anchor)); + }, n3[0] = e39, n3[1] = r3, n3[2] = a4) : a4 = n3[2], OE(a4); } return { Scope: r2, useRowFocus: i3, useClaimOnce: a3 }; } -var OS = { message: ``, tick: 0 }; -var kS = Rn({ polite: OS, assertive: OS }); -function AS(e9, t2) { - let n2 = t2?.assertive === true ? `assertive` : `polite`, r2 = { message: e9, tick: kS.get()[n2].tick + 1 }; - return kS.update((e10) => ({ ...e10, [n2]: r2 })), () => { - kS.update((e10) => e10[n2] === r2 ? { ...e10, [n2]: { ...r2, message: `` } } : e10); - }; -} -var FS = (0, X2.createContext)(null); -function IS(e9) { - let t2 = (0, Z2.c)(3), n2 = (0, X2.useContext)(FS), r2; - return t2[0] !== n2 || t2[1] !== e9 ? (r2 = (t3) => { - if (n2 != null && t3 != null && e9 != null) return n2((t4) => [...t4, e9]), () => n2((t4) => t4.filter((t5) => t5 !== e9)); - }, t2[0] = n2, t2[1] = e9, t2[2] = r2) : r2 = t2[2], r2; -} -var XS = { xs: `sm`, sm: `base`, md: `sm`, lg: `base`, xl: `lg` }; -var ZS = { root: { kB7OPa: `sand-9f619`, k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, kOIVth: `sand-17d4w8g`, kEafiO: `sand-178xt8z`, ke9TFa: `sand-1lun4ml`, kt9PQ7: `sand-so031l`, k2ei4v: `sand-pilrb4`, kPef9Z: `sand-13fuv20`, k8ry5P: `sand-18b5jzi`, kfdmCh: `sand-1q0q8m5`, kVhnKS: `sand-1t7ytsu`, kLZC3w: `sand-1v8p93f`, kBCPoo: `sand-1o3jo1z`, kL6WhQ: `sand-16stqrj`, kGJrpR: `sand-v5lvn5`, kMv6JI: `sand-jb2p0i`, k63SB2: `sand-1k6tqyu`, khDVqt: `sand-uxw1ft`, k9WMMc: `sand-2b8uid`, kMnn75: `sand-krqix3`, kfSwDN: `sand-87ps6o`, kFalU9: `sand-ggy1nq`, kkrTdU: `sand-1ypdohk sand-1s07b3s`, kSiTet: `sand-1hc1fzr sand-uhm2yv`, kfzvcC: `sand-67bb7w sand-aqnwrm`, kMeerF: `sand-1k57tk5 sand-784prv`, k3XXqK: `sand-1t137rt sand-9v5kkp`, kjBf7l: `sand-1uczgqu sand-1wpm9rq`, kInvED: `sand-1wfwxd8 sand-7s97pk`, k1ekBW: `sand-1eaenvl`, kIyJzY: `sand-1kneoy4`, kAMwcw: `sand-1pbvl4h`, $$css: true }, focusAppearanceNone: { k3XXqK: `sand-i5y0ii`, $$css: true }, alignLeft: { kjj79g: `sand-1nhvcw1`, $$css: true }, frameContent: { kwRFfy: `sand-yri2b`, kZCmMZ: `sand-1c1uobl`, $$css: true }, sizeXs: { kZKoxP: `sand-17rw0jw`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-f159sx`, kGO01o: `sand-18d9i69`, kZCmMZ: `sand-mzvs34`, kaIpWk: `sand-1ctf4ec`, kGuDYH: `sand-1wm8ruf`, kLWn49: `sand-spwq11`, $$css: true }, sizeSm: { kZKoxP: `sand-d7y6wv`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-2vl965`, kGO01o: `sand-18d9i69`, kZCmMZ: `sand-e2zdcy`, kaIpWk: `sand-9h44rk`, kGuDYH: `sand-1wm8ruf`, kLWn49: `sand-spwq11`, $$css: true }, sizeMd: { kZKoxP: `sand-1gnnpzl`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-1hwfens`, kGO01o: `sand-18d9i69`, kZCmMZ: `sand-bmws1g`, kaIpWk: `sand-n5hx6u`, kGuDYH: `sand-11wthnw`, kLWn49: `sand-1ja60sm`, $$css: true }, sizeLg: { kZKoxP: `sand-90ne7k`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-1q3ajuy`, kGO01o: `sand-18d9i69`, kZCmMZ: `sand-1gx403c`, kaIpWk: `sand-mf3hgm`, kGuDYH: `sand-11wthnw`, kLWn49: `sand-1ja60sm`, $$css: true }, sizeXl: { kZKoxP: `sand-16wdlz0`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-1x5flf6`, kGO01o: `sand-18d9i69`, kZCmMZ: `sand-wn43p0`, kaIpWk: `sand-etvl1f`, kGuDYH: `sand-fc7y3v`, kLWn49: `sand-1yxxptd`, $$css: true }, shapePill: { kaIpWk: `sand-149ho13`, $$css: true }, primary: { kWkggS: `sand-8rotk8 sand-1sxibbd`, kMwMTN: `sand-sa7k8x`, $$css: true }, primaryMonochrome: { kWkggS: `sand-1t716jg sand-1kb7mvx`, kMwMTN: `sand-sa7k8x`, $$css: true }, primaryRed: { kWkggS: `sand-ptgcna sand-yhpp14`, kMwMTN: `sand-xcaa6e`, $$css: true }, secondary: { kWkggS: `sand-fwqdrz sand-19jy9ex`, kMwMTN: `sand-tyxrsu`, $$css: true }, outline: { kWkggS: `sand-jbqb8w sand-b937un`, kMwMTN: `sand-tyxrsu`, kLZC3w: `sand-13nz628`, kBCPoo: `sand-bp68ws`, kL6WhQ: `sand-1vu50b0`, kGJrpR: `sand-5x6ma4`, $$css: true }, ghost: { kWkggS: `sand-jbqb8w sand-d5puqa`, kMwMTN: `sand-1o0liin sand-1fx2joi`, $$css: true }, text: { kWkggS: `sand-jbqb8w`, kLZC3w: `sand-1v8p93f`, kBCPoo: `sand-1o3jo1z`, kL6WhQ: `sand-16stqrj`, kGJrpR: `sand-v5lvn5`, kMwMTN: `sand-1o0liin sand-1fx2joi`, $$css: true } }; -function QS(e9) { - QS.d = 2086; - let t2 = (0, Z2.c)(80), n2, r2, i3, a3, o3, s3, c2, l4, u3, d3, f4, p4, m3, h3, g3, _2, v3, y3, b3, x3; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c2 = t2[7], l4 = t2[8], u3 = t2[9], d3 = t2[10], f4 = t2[11], p4 = t2[12], m3 = t2[13], h3 = t2[14], g3 = t2[15], _2 = t2[16], v3 = t2[17], y3 = t2[18], b3 = t2[19], x3 = t2[20]) : ({ align: n2, children: r2, className: i3, tone: b3, disabled: a3, focusAppearance: h3, focusableWhenDisabled: o3, frame: g3, kbs: s3, leadingIcon: c2, trailingIcon: x3, nativeButton: l4, ref: d3, render: f4, rootStyle: p4, shape: _2, size: v3, style: m3, variant: y3, ...u3 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c2, t2[8] = l4, t2[9] = u3, t2[10] = d3, t2[11] = f4, t2[12] = p4, t2[13] = m3, t2[14] = h3, t2[15] = g3, t2[16] = _2, t2[17] = v3, t2[18] = y3, t2[19] = b3, t2[20] = x3); - let S3 = h3 === void 0 ? `default` : h3, C2 = g3 === void 0 ? `container` : g3, w3 = _2 === void 0 ? `rounded` : _2, T3 = v3 === void 0 ? `md` : v3, E3 = y3 === void 0 ? `secondary` : y3, D2, O3, k4, A3; - if (t2[21] !== n2 || t2[22] !== r2 || t2[23] !== i3 || t2[24] !== S3 || t2[25] !== C2 || t2[26] !== s3 || t2[27] !== c2 || t2[28] !== p4 || t2[29] !== w3 || t2[30] !== T3 || t2[31] !== b3 || t2[32] !== x3 || t2[33] !== E3) { - O3 = h(ZS.root, UMe(T3), WMe(E3, b3), n2 === `left` && ZS.alignLeft, C2 === `content` && ZS.frameContent, S3 === `none` && ZS.focusAppearanceNone, p4, w3 === `pill` && ZS.shapePill); - let e10 = XS[T3], a4; - t2[38] !== e10 || t2[39] !== c2 ? (a4 = $S(c2, e10), t2[38] = e10, t2[39] = c2, t2[40] = a4) : a4 = t2[40]; - let o4 = a4, l5; - t2[41] !== e10 || t2[42] !== x3 ? (l5 = $S(x3, e10), t2[41] = e10, t2[42] = x3, t2[43] = l5) : l5 = t2[43]; - let u4 = l5; - if (k4 = r2, s3 != null) { - let e11; - t2[44] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e11 = { className: `sand-3nfvp2 sand-6s0dn4 sand-17d4w8g` }, t2[44] = e11) : e11 = t2[44]; - let n3 = e11.className, i4; - t2[45] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i4 = { className: `sand-p6acfy sand-1k6tqyu` }, t2[45] = i4) : i4 = t2[45]; - let a5; - t2[46] === s3 ? a5 = t2[47] : (a5 = (0, Y2.jsx)(`span`, { className: i4.className, children: s3 }), t2[46] = s3, t2[47] = a5); - let c3; - t2[48] !== r2 || t2[49] !== o4 || t2[50] !== a5 || t2[51] !== u4 ? (c3 = (0, Y2.jsxs)(`span`, { className: n3, children: [o4, r2, u4, a5] }), t2[48] = r2, t2[49] = o4, t2[50] = a5, t2[51] = u4, t2[52] = c3) : c3 = t2[52], k4 = c3; - } else if (o4 != null || u4 != null) { - let e11; - t2[53] !== r2 || t2[54] !== o4 || t2[55] !== u4 ? (e11 = (0, Y2.jsxs)(Y2.Fragment, { children: [o4, r2, u4] }), t2[53] = r2, t2[54] = o4, t2[55] = u4, t2[56] = e11) : e11 = t2[56], k4 = e11; - } - D2 = Kc, A3 = $(`sand-button`, O3.className, i3), t2[21] = n2, t2[22] = r2, t2[23] = i3, t2[24] = S3, t2[25] = C2, t2[26] = s3, t2[27] = c2, t2[28] = p4, t2[29] = w3, t2[30] = T3, t2[31] = b3, t2[32] = x3, t2[33] = E3, t2[34] = D2, t2[35] = O3, t2[36] = k4, t2[37] = A3; - } else D2 = t2[34], O3 = t2[35], k4 = t2[36], A3 = t2[37]; - let j3 = n2 === `center` ? void 0 : n2, M3 = C2 === `container` ? void 0 : C2, N2 = w3 === `rounded` ? void 0 : w3, P2; - t2[57] !== O3.style || t2[58] !== m3 ? (P2 = { ...O3.style, ...m3 }, t2[57] = O3.style, t2[58] = m3, t2[59] = P2) : P2 = t2[59]; - let F2 = XS[T3], I; - t2[60] !== k4 || t2[61] !== F2 ? (I = (0, Y2.jsx)(ni, { iconSize: F2, children: k4 }), t2[60] = k4, t2[61] = F2, t2[62] = I) : I = t2[62]; - let L; - return t2[63] !== D2 || t2[64] !== a3 || t2[65] !== o3 || t2[66] !== l4 || t2[67] !== u3 || t2[68] !== d3 || t2[69] !== f4 || t2[70] !== T3 || t2[71] !== P2 || t2[72] !== I || t2[73] !== A3 || t2[74] !== j3 || t2[75] !== M3 || t2[76] !== N2 || t2[77] !== b3 || t2[78] !== E3 ? (L = (0, Y2.jsx)(D2, { className: A3, "data-align": j3, "data-tone": b3, "data-frame": M3, "data-shape": N2, "data-size": T3, "data-variant": E3, disabled: a3, focusableWhenDisabled: o3, nativeButton: l4, ref: d3, render: f4, style: P2, ...u3, children: I }), t2[63] = D2, t2[64] = a3, t2[65] = o3, t2[66] = l4, t2[67] = u3, t2[68] = d3, t2[69] = f4, t2[70] = T3, t2[71] = P2, t2[72] = I, t2[73] = A3, t2[74] = j3, t2[75] = M3, t2[76] = N2, t2[77] = b3, t2[78] = E3, t2[79] = L) : L = t2[79], L; -} -function UMe(e9) { - switch (e9) { - case `xs`: - return ZS.sizeXs; - case `sm`: - return ZS.sizeSm; - case `md`: - return ZS.sizeMd; - case `lg`: - return ZS.sizeLg; - case `xl`: - return ZS.sizeXl; - } -} -function WMe(e9, t2) { - switch (e9) { - case `primary`: - return [ZS.primary, GMe(t2)]; - case `secondary`: - return ZS.secondary; - case `outline`: - return ZS.outline; - case `ghost`: - return ZS.ghost; - case `text`: - return ZS.text; - case `media`: - return null; - } -} -function GMe(e9) { - switch (e9) { - case `monochrome`: - return ZS.primaryMonochrome; - case `danger`: - return ZS.primaryRed; - default: - return null; - } -} -function $S(e9, t2) { - return e9 == null ? null : (0, Y2.jsx)(hi, { ...typeof e9 == `string` ? { name: e9 } : e9, "aria-hidden": `true`, size: t2 }); -} -var eC = { root: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, kMwMTN: `sand-1heor9g`, $$css: true }, xs: { kzqmXN: `sand-6jxa94`, kZKoxP: `sand-1v9usgg`, $$css: true }, sm: { kzqmXN: `sand-1kky2od`, kZKoxP: `sand-lup9mm`, $$css: true }, md: { kzqmXN: `sand-1xp8n7a`, kZKoxP: `sand-mix8c7`, $$css: true }, lg: { kzqmXN: `sand-w4jnvo`, kZKoxP: `sand-1qx5ct2`, $$css: true }, xl: { kzqmXN: `sand-17z2i9w`, kZKoxP: `sand-17rw0jw`, $$css: true }, primary: { kMwMTN: `sand-1e6yr6a`, $$css: true }, secondary: { kMwMTN: `sand-nxsxl2`, $$css: true }, tertiary: { kMwMTN: `sand-1gt6tda`, $$css: true }, quaternary: { kMwMTN: `sand-101qkwy`, $$css: true } }; -var KMe = { xs: 10, sm: 12, md: 14, lg: 16, xl: 18 }; -var qMe = { xs: eC.xs, sm: eC.sm, md: eC.md, lg: eC.lg, xl: eC.xl }; -var JMe = { primary: eC.primary, secondary: eC.secondary, tertiary: eC.tertiary, quaternary: eC.quaternary }; -function tC(e9) { - tC.d = 2135; - let t2 = (0, Z2.c)(42), n2, r2, i3, a3, o3, s3, c2, l4, u3, d3, f4; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c2 = t2[7], l4 = t2[8], u3 = t2[9], d3 = t2[10], f4 = t2[11]) : ({ name: o3, size: u3, color: i3, variant: f4, modifier: a3, capTrim: d3, className: r2, style: l4, ref: s3, "aria-label": n2, ...c2 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c2, t2[8] = l4, t2[9] = u3, t2[10] = d3, t2[11] = f4); - let p4 = u3 === void 0 ? `lg` : u3, m3 = d3 !== void 0 && d3, h3, g3, _2, v3, y3; - t2[12] !== n2 || t2[13] !== r2 || t2[14] !== i3 || t2[15] !== c2 || t2[16] !== p4 || t2[17] !== l4 ? (h3 = h(eC.root, qMe[p4], i3 != null && JMe[i3], l4), g3 = c2, _2 = n2 == null || void 0, v3 = n2, y3 = $(`sand-kit-icon`, h3.className, r2), t2[12] = n2, t2[13] = r2, t2[14] = i3, t2[15] = c2, t2[16] = p4, t2[17] = l4, t2[18] = h3, t2[19] = g3, t2[20] = _2, t2[21] = v3, t2[22] = y3) : (h3 = t2[18], g3 = t2[19], _2 = t2[20], v3 = t2[21], y3 = t2[22]); - let b3 = KMe[p4], x3; - t2[23] === f4 ? x3 = t2[24] : (x3 = f4 === void 0 ? {} : { variant: f4 }, t2[23] = f4, t2[24] = x3); - let S3; - t2[25] === a3 ? S3 = t2[26] : (S3 = a3 === void 0 ? {} : { modifier: a3 }, t2[25] = a3, t2[26] = S3); +function Ix(e38) { + Ix.d = 2314; + let t2 = (0, Z3.c)(3), { children: n2 } = e38, r2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { className: `sand-jp7ctv` }, t2[0] = r2) : r2 = t2[0]; + let i3; + return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, Y3.jsx)(`div`, { ...r2, role: `status`, children: n2 }), t2[1] = n2, t2[2] = i3), i3; +} +var Rx = (0, X3.createContext)(null); +function zx(e38) { + let t2 = (0, Z3.c)(3), n2 = (0, X3.useContext)(Rx), r2; + return t2[0] !== n2 || t2[1] !== e38 ? (r2 = (t3) => { + if (n2 != null && t3 != null && e38 != null) return n2((t4) => [...t4, e38]), () => n2((t4) => t4.filter((t5) => t5 !== e38)); + }, t2[0] = n2, t2[1] = e38, t2[2] = r2) : r2 = t2[2], r2; +} +var Bx = `data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='-121.4%20-88.4%20709.16%20709.16'%3e%3cpath%20fill='%23000000'%20d='M457.43%20125.94%20244.42%202.96a22.14%2022.14%200%200%200-22.12%200L9.3%20125.94A18.61%2018.61%200%200%200%200%20142.05v247.99c0%206.65%203.55%2012.79%209.3%2016.11l213.01%20122.98a22.14%2022.14%200%200%200%2022.12%200l213.01-122.98a18.61%2018.61%200%200%200%209.3-16.11V142.05c0-6.65-3.55-12.79-9.3-16.11Zm-13.38%2026.05L238.42%20508.15c-1.39%202.4-5.06%201.42-5.06-1.36V273.58c0-4.66-2.49-8.97-6.53-11.31L24.87%20145.67c-2.4-1.39-1.42-5.06%201.36-5.06h411.26c5.84%200%209.49%206.33%206.56%2011.38Z'%20/%3e%3c/svg%3e`; +var Vx = `data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3csvg%20x='8.000'%20y='20.000'%20width='8.000'%20height='8.000'%20viewBox='0%200%208%208'%20preserveAspectRatio='none'%3e%3cpath%20id='path0_fill_p22'%20d='M4%208C6.208%208%208%206.208%208%204V0H4C1.792%200%200%201.792%200%204C0%206.208%201.792%208%204%208Z'%20fill='%230ACF83'/%3e%3c/svg%3e%3csvg%20x='8.000'%20y='12.000'%20width='8.000'%20height='8.000'%20viewBox='0%200%208%208'%20preserveAspectRatio='none'%3e%3cpath%20id='path1_fill_p23'%20d='M0%204C0%201.792%201.792%200%204%200H8V8H4C1.792%208%200%206.208%200%204Z'%20fill='%23A259FF'/%3e%3c/svg%3e%3csvg%20x='8.000'%20y='4.000'%20width='8.000'%20height='8.000'%20viewBox='0%200%208%208'%20preserveAspectRatio='none'%3e%3cpath%20id='path1_fill_1__p24'%20d='M0%204C0%201.792%201.792%200%204%200H8V8H4C1.792%208%200%206.208%200%204Z'%20fill='%23F24E1E'/%3e%3c/svg%3e%3csvg%20x='16.000'%20y='4.000'%20width='8.000'%20height='8.000'%20viewBox='0%200%208%208'%20preserveAspectRatio='none'%3e%3cpath%20id='path2_fill_p25'%20d='M0%200H4C6.208%200%208%201.792%208%204C8%206.208%206.208%208%204%208H0V0Z'%20fill='%23FF7262'/%3e%3c/svg%3e%3csvg%20x='16.000'%20y='12.000'%20width='8.000'%20height='8.000'%20viewBox='0%200%208%208'%20preserveAspectRatio='none'%3e%3cpath%20id='path3_fill_p26'%20d='M8%204C8%206.208%206.208%208%204%208C1.792%208%200%206.208%200%204C0%201.792%201.792%200%204%200C6.208%200%208%201.792%208%204Z'%20fill='%231ABCFE'/%3e%3c/svg%3e%3c/svg%3e`; +var Hx = `data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3csvg%20x='4.000'%20y='4.298'%20width='24.000'%20height='23.405'%20viewBox='0%200%2024%2023.4079'%20preserveAspectRatio='none'%3e%3cpath%20id='Vector_p18'%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M12%200C5.37%200%200%205.37%200%2012C0%2017.31%203.435%2021.795%208.205%2023.385C8.805%2023.49%209.03%2023.13%209.03%2022.815C9.03%2022.53%209.015%2021.585%209.015%2020.58C6%2021.135%205.22%2019.845%204.98%2019.17C4.845%2018.825%204.26%2017.76%203.75%2017.475C3.33%2017.25%202.73%2016.695%203.735%2016.68C4.68%2016.665%205.355%2017.55%205.58%2017.91C6.66%2019.725%208.385%2019.215%209.075%2018.9C9.18%2018.12%209.495%2017.595%209.84%2017.295C7.17%2016.995%204.38%2015.96%204.38%2011.37C4.38%2010.065%204.845%208.985%205.61%208.145C5.49%207.845%205.07%206.615%205.73%204.965C5.73%204.965%206.735%204.65%209.03%206.195C9.99%205.925%2011.01%205.79%2012.03%205.79C13.05%205.79%2014.07%205.925%2015.03%206.195C17.325%204.635%2018.33%204.965%2018.33%204.965C18.99%206.615%2018.57%207.845%2018.45%208.145C19.215%208.985%2019.68%2010.05%2019.68%2011.37C19.68%2015.975%2016.875%2016.995%2014.205%2017.295C14.64%2017.67%2015.015%2018.39%2015.015%2019.515C15.015%2021.12%2015%2022.41%2015%2022.815C15%2023.13%2015.225%2023.505%2015.825%2023.385C20.565%2021.795%2024%2017.295%2024%2012C24%205.37%2018.63%200%2012%200Z'%20fill='%231B1F23'/%3e%3c/svg%3e%3c/svg%3e`; +var Ux = `data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3csvg%20x='4.547'%20y='4.061'%20width='22.906'%20height='23.878'%20viewBox='0%200%2022.9045%2023.8766'%20preserveAspectRatio='none'%3e%3cpath%20id='Vector_p9'%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M3.94965%204.18607C4.69228%204.78943%204.97088%204.7434%206.36543%204.65034L19.5124%203.86093C19.7912%203.86093%2019.5593%203.58276%2019.4663%203.53654L17.2829%201.95809C16.8646%201.63328%2016.3072%201.2613%2015.2389%201.35435L2.50869%202.28285C2.04442%202.32889%201.95169%202.56102%202.13658%202.74708L3.94965%204.18607ZM4.73897%207.24997V21.0828C4.73897%2021.8263%205.11048%2022.1044%205.94663%2022.0584L20.3951%2021.2224C21.2317%2021.1764%2021.3249%2020.665%2021.3249%2020.0611V6.32105C21.3249%205.71812%2021.0929%205.39297%2020.5808%205.43938L5.48203%206.32105C4.9248%206.36788%204.73893%206.64661%204.73893%207.24997H4.73897ZM19.0025%207.99199C19.0951%208.41018%2019.0025%208.828%2018.5835%208.87502L17.8874%209.01373V19.226C17.2829%2019.5509%2016.7256%2019.7366%2016.2611%2019.7366C15.5175%2019.7366%2015.3312%2019.5043%2014.7742%2018.8085L10.2206%2011.6598V18.5763L11.6615%2018.9015C11.6615%2018.9015%2011.6615%2019.7366%2010.499%2019.7366L7.29407%2019.9225C7.20097%2019.7366%207.29407%2019.2728%207.61917%2019.1799L8.4555%2018.9481V9.8031L7.29431%209.71004C7.20116%209.29185%207.43311%208.68887%208.084%208.64208L11.5221%208.41032L16.2611%2015.6521V9.24582L15.0528%209.10716C14.9601%208.59591%2015.3312%208.22469%2015.7959%208.17866L19.0025%207.99199ZM1.43984%201.02959L14.6813%200.0544474C16.3074%20-0.0850129%2016.7258%200.00841469%2017.7478%200.75081L21.9746%203.72166C22.672%204.23253%2022.9045%204.37161%2022.9045%204.92851V21.2224C22.9045%2022.2435%2022.5325%2022.8475%2021.2319%2022.9398L5.85461%2023.8684C4.87829%2023.915%204.41364%2023.7759%203.90235%2023.1256L0.789649%2019.087C0.231949%2018.3436%200%2017.7874%200%2017.1368V2.6537C0%201.81863%200.372113%201.12203%201.43984%201.02959V1.02959Z'%20fill='black'/%3e%3c/svg%3e%3c/svg%3e`; +var Wx = `data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3csvg%20x='4.141'%20y='16.643'%20width='11.226'%20height='11.226'%20viewBox='0%200%2011.2252%2011.2252'%20preserveAspectRatio='none'%3e%3cpath%20id='Vector_p5'%20d='M4.98898%202.49449C4.98898%203.87402%203.87402%204.98898%202.49449%204.98898C1.11496%204.98898%200%203.87402%200%202.49449C0%201.11496%201.11496%200%202.49449%200H4.98898V2.49449ZM6.23622%202.49449C6.23622%201.11496%207.35118%200%208.73071%200C10.1102%200%2011.2252%201.11496%2011.2252%202.49449V8.73071C11.2252%2010.1102%2010.1102%2011.2252%208.73071%2011.2252C7.35118%2011.2252%206.23622%2010.1102%206.23622%208.73071V2.49449Z'%20fill='%23E01E5A'/%3e%3c/svg%3e%3csvg%20x='4.122'%20y='4.131'%20width='11.245'%20height='11.245'%20viewBox='0%200%2011.2441%2011.2441'%20preserveAspectRatio='none'%3e%3cpath%20id='Vector_p6'%20d='M8.74961%204.98898C7.37008%204.98898%206.25512%203.87402%206.25512%202.49449C6.25512%201.11496%207.37008%200%208.74961%200C10.1291%200%2011.2441%201.11496%2011.2441%202.49449V4.98898H8.74961ZM8.74961%206.25512C10.1291%206.25512%2011.2441%207.37008%2011.2441%208.74961C11.2441%2010.1291%2010.1291%2011.2441%208.74961%2011.2441H2.49449C1.11496%2011.2441%200%2010.1291%200%208.74961C0%207.37008%201.11496%206.25512%202.49449%206.25512H8.74961Z'%20fill='%2336C5F0'/%3e%3c/svg%3e%3csvg%20x='16.634'%20y='4.131'%20width='11.226'%20height='11.245'%20viewBox='0%200%2011.2252%2011.2441'%20preserveAspectRatio='none'%3e%3cpath%20id='Vector_p7'%20d='M6.23622%208.74961C6.23622%207.37008%207.35118%206.25512%208.73071%206.25512C10.1102%206.25512%2011.2252%207.37008%2011.2252%208.74961C11.2252%2010.1291%2010.1102%2011.2441%208.73071%2011.2441H6.23622V8.74961ZM4.98898%208.74961C4.98898%2010.1291%203.87402%2011.2441%202.49449%2011.2441C1.11496%2011.2441%200%2010.1291%200%208.74961V2.49449C0%201.11496%201.11496%200%202.49449%200C3.87402%200%204.98898%201.11496%204.98898%202.49449V8.74961V8.74961Z'%20fill='%232EB67D'/%3e%3c/svg%3e%3csvg%20x='16.634'%20y='16.643'%20width='11.245'%20height='11.226'%20viewBox='0%200%2011.2441%2011.2252'%20preserveAspectRatio='none'%3e%3cpath%20id='Vector_p8'%20d='M2.49449%206.23622C3.87402%206.23622%204.98898%207.35118%204.98898%208.73071C4.98898%2010.1102%203.87402%2011.2252%202.49449%2011.2252C1.11496%2011.2252%200%2010.1102%200%208.73071V6.23622H2.49449ZM2.49449%204.98898C1.11496%204.98898%200%203.87402%200%202.49449C0%201.11496%201.11496%200%202.49449%200H8.74961C10.1291%200%2011.2441%201.11496%2011.2441%202.49449C11.2441%203.87402%2010.1291%204.98898%208.74961%204.98898H2.49449Z'%20fill='%23ECB22E'/%3e%3c/svg%3e%3c/svg%3e`; +var qx = [[`github.com`, Hx], [`notion.so`, Ux], [`notion.site`, Ux], [`notion.com`, Ux], [`slack.com`, Wx], [`figma.com`, Vx]]; +var ZIe = [[`cursor.com`, Bx], ...qx]; +var QIe = /* @__PURE__ */ new Set([Bx, Hx, Ux]); +function $Ie(e38, t2) { + return e38 === t2 || e38.endsWith(`.${t2}`); +} +function Jx(e38, t2) { + let n2 = e38.find(([e39]) => $Ie(t2, e39)); + return n2 == null ? null : n2[1]; +} +function Xx(e38) { + return Jx(ZIe, e38); +} +function Zx(e38) { + return QIe.has(e38); +} +var iS = { root: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, kMwMTN: `sand-1heor9g`, $$css: true }, xs: { kzqmXN: `sand-6jxa94`, kZKoxP: `sand-1v9usgg`, $$css: true }, sm: { kzqmXN: `sand-1kky2od`, kZKoxP: `sand-lup9mm`, $$css: true }, md: { kzqmXN: `sand-1xp8n7a`, kZKoxP: `sand-mix8c7`, $$css: true }, lg: { kzqmXN: `sand-w4jnvo`, kZKoxP: `sand-1qx5ct2`, $$css: true }, xl: { kzqmXN: `sand-17z2i9w`, kZKoxP: `sand-17rw0jw`, $$css: true }, primary: { kMwMTN: `sand-1e6yr6a`, $$css: true }, secondary: { kMwMTN: `sand-nxsxl2`, $$css: true }, tertiary: { kMwMTN: `sand-1gt6tda`, $$css: true }, quaternary: { kMwMTN: `sand-101qkwy`, $$css: true } }; +var iLe = { xs: 10, sm: 12, md: 14, lg: 16, xl: 18 }; +var aLe = { xs: iS.xs, sm: iS.sm, md: iS.md, lg: iS.lg, xl: iS.xl }; +var oLe = { primary: iS.primary, secondary: iS.secondary, tertiary: iS.tertiary, quaternary: iS.quaternary }; +function aS(e38) { + aS.d = 2410; + let t2 = (0, Z3.c)(42), n2, r2, i3, a3, o3, s3, c3, l5, u3, d3, f4; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c3 = t2[7], l5 = t2[8], u3 = t2[9], d3 = t2[10], f4 = t2[11]) : ({ name: o3, size: u3, color: i3, variant: f4, modifier: a3, capTrim: d3, className: r2, style: l5, ref: s3, "aria-label": n2, ...c3 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c3, t2[8] = l5, t2[9] = u3, t2[10] = d3, t2[11] = f4); + let p4 = u3 === void 0 ? `lg` : u3, m3 = d3 !== void 0 && d3, h4, g5, _5, v5, y4; + t2[12] !== n2 || t2[13] !== r2 || t2[14] !== i3 || t2[15] !== c3 || t2[16] !== p4 || t2[17] !== l5 ? (h4 = h(iS.root, aLe[p4], i3 != null && oLe[i3], l5), g5 = c3, _5 = n2 == null || void 0, v5 = n2, y4 = $2(`sand-kit-icon`, h4.className, r2), t2[12] = n2, t2[13] = r2, t2[14] = i3, t2[15] = c3, t2[16] = p4, t2[17] = l5, t2[18] = h4, t2[19] = g5, t2[20] = _5, t2[21] = v5, t2[22] = y4) : (h4 = t2[18], g5 = t2[19], _5 = t2[20], v5 = t2[21], y4 = t2[22]); + let b2 = iLe[p4], x2; + t2[23] === f4 ? x2 = t2[24] : (x2 = f4 === void 0 ? {} : { variant: f4 }, t2[23] = f4, t2[24] = x2); + let S2; + t2[25] === a3 ? S2 = t2[26] : (S2 = a3 === void 0 ? {} : { modifier: a3 }, t2[25] = a3, t2[26] = S2); let C2; - t2[27] !== m3 || t2[28] !== o3 || t2[29] !== b3 || t2[30] !== x3 || t2[31] !== S3 ? (C2 = (0, Y2.jsx)(hi, { capTrim: m3, name: o3, size: b3, ...x3, ...S3 }), t2[27] = m3, t2[28] = o3, t2[29] = b3, t2[30] = x3, t2[31] = S3, t2[32] = C2) : C2 = t2[32]; - let w3; - return t2[33] !== h3.style || t2[34] !== s3 || t2[35] !== p4 || t2[36] !== C2 || t2[37] !== g3 || t2[38] !== _2 || t2[39] !== v3 || t2[40] !== y3 ? (w3 = (0, Y2.jsx)(`span`, { ...g3, "aria-hidden": _2, "aria-label": v3, className: y3, "data-size": p4, ref: s3, style: h3.style, children: C2 }), t2[33] = h3.style, t2[34] = s3, t2[35] = p4, t2[36] = C2, t2[37] = g3, t2[38] = _2, t2[39] = v3, t2[40] = y3, t2[41] = w3) : w3 = t2[41], w3; -} -var rC = { interactive: { kWkggS: `sand-jbqb8w sand-1ecwv3n`, $$css: true }, selected: { kWkggS: `sand-kr7fhf sand-n0wurk`, $$css: true }, accentSelected: { kWkggS: `sand-ukxp9i sand-qc45by`, $$css: true }, controlEdge: { kGVxlE: `sand-bwjx97`, $$css: true }, searchField: { kZKoxP: `sand-t8t6p`, k8WAf4: `sand-t970qd`, kZCmMZ: `sand-22095l`, kwRFfy: `sand-1tlft3r`, kysU6D: `sand-jyslct`, ksu8eU: `sand-ng3xce`, kaIpWk: `sand-1qmwy7c`, kGVxlE: `sand-19mzooj`, kWkggS: `sand-10e981r`, kMwMTN: `sand-tyxrsu`, kMv6JI: `sand-jb2p0i`, $$css: true }, controlRing: { kMeerF: `sand-1k57tk5 sand-784prv`, k3XXqK: `sand-1t137rt sand-9v5kkp`, kjBf7l: `sand-1v39l1b`, kInvED: `sand-1y3gkto`, $$css: true }, keyboardFocus: { k3XXqK: `sand-1t137rt`, kGVxlE: `sand-18xb08s`, $$css: true }, buttonRadius: { kaIpWk: `sand-1m7fhj7`, $$css: true }, transcriptWidget: { kWkggS: `sand-18rdzox`, $$css: true }, askCardButton: { kmuXW: `sand-2lah0s`, kZKoxP: `sand-10w6t97`, kaIpWk: `sand-149ho13`, kwRFfy: `sand-pdmqnj`, kZCmMZ: `sand-1g0dm76`, kGuDYH: `sand-fc7y3v`, kLWn49: `sand-1yxxptd`, $$css: true }, askCardButtonTinted: { kVAM5u: `sand-5fd6op`, kWkggS: `sand-fwqdrz sand-19jy9ex`, kMwMTN: `sand-tyxrsu`, $$css: true }, splitControl: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-1qjc9v5`, kmuXW: `sand-2lah0s`, $$css: true }, splitControlLeading: { ke9TFa: `sand-10w94by`, kfmiAY: `sand-1ga7v0g`, kT0f0o: `sand-16uus16`, $$css: true }, splitControlTrailing: { krdFHd: `sand-15mokao`, kVL7Gh: `sand-biv7yw`, $$css: true }, thinScrollbar: { k5wCbM: `sand-1597r2g`, k6w4Gs: `sand-7h844e`, kBDiHx: `sand-y2251v`, krhWos: `sand-122zoth`, kAWW7O: `sand-1htvni2 sand-1gb0fpc`, kFaAu4: `sand-9xsh1y`, $$css: true } }; -var iC = { root: { kVAEAm: `sand-1n2onr6`, k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, kB7OPa: `sand-9f619`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-yri2b`, kGO01o: `sand-18d9i69`, kZCmMZ: `sand-1c1uobl`, kMzoRj: `sand-c342km`, ksu8eU: `sand-ng3xce`, kWkggS: `sand-jbqb8w`, kkrTdU: `sand-1ypdohk sand-tgyt42`, k1ekBW: `sand-s2xxs2`, kIyJzY: `sand-1firant`, kAMwcw: `sand-9lcvmn`, $$css: true }, focusAppearanceNone: { k3XXqK: `sand-i5y0ii`, $$css: true }, sizeLg: { kzqmXN: `sand-187nhsf`, kZKoxP: `sand-n3w4p2`, $$css: true }, sizeMd: { kzqmXN: `sand-gd8bvy`, kZKoxP: `sand-1fgtraw`, $$css: true }, sizeSm: { kzqmXN: `sand-vy4d1p`, kZKoxP: `sand-xk0z11`, $$css: true }, sizeXs: { kzqmXN: `sand-w4jnvo`, kZKoxP: `sand-1qx5ct2`, $$css: true }, shapeSquare: { kaIpWk: `sand-1kogg8i`, $$css: true }, shapeCircle: { kaIpWk: `sand-149ho13`, $$css: true }, ghost: { kWkggS: `sand-jbqb8w sand-1ecwv3n`, kMwMTN: `sand-nxsxl2 sand-13hlow9 sand-xcn2h6`, $$css: true }, ghostSelected: { kWkggS: `sand-18pe38m sand-19jy9ex`, $$css: true }, primary: { kWkggS: `sand-8rotk8 sand-1sxibbd sand-1ialtwx`, kMwMTN: `sand-sa7k8x sand-xcn2h6`, $$css: true }, secondary: { kWkggS: `sand-fwqdrz sand-19jy9ex sand-1g6zli8`, kMwMTN: `sand-nxsxl2 sand-xcn2h6`, $$css: true }, elevated: { kMzoRj: `sand-mkeg23`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-5fd6op`, kWkggS: `sand-10e981r`, kKwaWg: `sand-18o3ruo sand-101ryrv`, kMwMTN: `sand-1e6yr6a sand-xcn2h6`, $$css: true }, dangerGhost: { kWkggS: `sand-jbqb8w sand-q63dn4`, kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true }, dangerPrimary: { kWkggS: `sand-vopzge sand-a9ymcb sand-bmovrx`, kMwMTN: `sand-xcaa6e sand-5zuve2`, $$css: true }, dangerSecondary: { kWkggS: `sand-jt6epu sand-78epwt sand-rf7kli`, kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true }, dangerElevated: { kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true } }; -var YMe = { neutral: { ghost: iC.ghost, primary: iC.primary, secondary: iC.secondary, elevated: iC.elevated }, danger: { ghost: iC.dangerGhost, primary: iC.dangerPrimary, secondary: iC.dangerSecondary, elevated: [iC.elevated, iC.dangerElevated] } }; -var aC = { xs: iC.sizeXs, sm: iC.sizeSm, md: iC.sizeMd, lg: iC.sizeLg }; -var XMe = { xs: `sm`, sm: `md`, md: `lg`, lg: `xl` }; -function oC(e9) { - oC.d = 2090; - let t2 = (0, Z2.c)(60), n2, r2, i3, a3, o3, s3, c2, l4, u3, d3, f4, p4, m3, h3, g3, _2, v3, y3, b3, x3; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c2 = t2[7], l4 = t2[8], u3 = t2[9], d3 = t2[10], f4 = t2[11], p4 = t2[12], m3 = t2[13], h3 = t2[14], g3 = t2[15], _2 = t2[16], v3 = t2[17], y3 = t2[18], b3 = t2[19], x3 = t2[20]) : ({ icon: o3, glyph: a3, "aria-label": n2, "aria-pressed": r2, variant: p4, sentiment: m3, size: h3, iconSize: s3, iconVariant: l4, iconStyle: c2, iconCapTrim: g3, shape: _2, isSelected: v3, hasIndicatorDot: y3, focusAppearance: b3, className: i3, ref: u3, style: f4, type: x3, ...d3 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c2, t2[8] = l4, t2[9] = u3, t2[10] = d3, t2[11] = f4, t2[12] = p4, t2[13] = m3, t2[14] = h3, t2[15] = g3, t2[16] = _2, t2[17] = v3, t2[18] = y3, t2[19] = b3, t2[20] = x3); - let S3 = p4 === void 0 ? `ghost` : p4, C2 = m3 === void 0 ? `neutral` : m3, w3 = h3 === void 0 ? `md` : h3, T3 = g3 !== void 0 && g3, E3 = _2 === void 0 ? `square` : _2, D2 = v3 !== void 0 && v3, O3 = y3 !== void 0 && y3, k4 = b3 === void 0 ? `default` : b3, A3 = x3 === void 0 ? `button` : x3, j3, M3, N2, P2, F2; - t2[21] !== n2 || t2[22] !== r2 || t2[23] !== i3 || t2[24] !== k4 || t2[25] !== D2 || t2[26] !== d3 || t2[27] !== C2 || t2[28] !== E3 || t2[29] !== w3 || t2[30] !== f4 || t2[31] !== S3 ? (j3 = h(iC.root, rC.controlRing, aC[w3], E3 === `square` ? iC.shapeSquare : iC.shapeCircle, YMe[C2][S3], S3 === `ghost` && D2 && iC.ghostSelected, k4 === `none` && iC.focusAppearanceNone, f4), M3 = d3, N2 = n2, P2 = r2 ?? (S3 === `ghost` && D2 ? true : void 0), F2 = $(`sand-kit-icon-button`, j3.className, i3), t2[21] = n2, t2[22] = r2, t2[23] = i3, t2[24] = k4, t2[25] = D2, t2[26] = d3, t2[27] = C2, t2[28] = E3, t2[29] = w3, t2[30] = f4, t2[31] = S3, t2[32] = j3, t2[33] = M3, t2[34] = N2, t2[35] = P2, t2[36] = F2) : (j3 = t2[32], M3 = t2[33], N2 = t2[34], P2 = t2[35], F2 = t2[36]); - let I; - t2[37] !== a3 || t2[38] !== o3 || t2[39] !== T3 || t2[40] !== s3 || t2[41] !== c2 || t2[42] !== l4 || t2[43] !== w3 ? (I = a3 ?? (0, Y2.jsx)(tC, { capTrim: T3, name: o3, size: s3 ?? XMe[w3], style: c2, variant: l4 }), t2[37] = a3, t2[38] = o3, t2[39] = T3, t2[40] = s3, t2[41] = c2, t2[42] = l4, t2[43] = w3, t2[44] = I) : I = t2[44]; - let L; - t2[45] === O3 ? L = t2[46] : (L = O3 ? (0, Y2.jsx)(`span`, { "aria-hidden": true, className: { className: `sand-10l6tqk sand-xk6nc9 sand-1ro0b6g sand-1v4s8kt sand-ols6we sand-149ho13 sand-1vh0fzo sand-47corl` }.className }) : null, t2[45] = O3, t2[46] = L); + t2[27] !== m3 || t2[28] !== o3 || t2[29] !== b2 || t2[30] !== x2 || t2[31] !== S2 ? (C2 = (0, Y3.jsx)(Oi, { capTrim: m3, name: o3, size: b2, ...x2, ...S2 }), t2[27] = m3, t2[28] = o3, t2[29] = b2, t2[30] = x2, t2[31] = S2, t2[32] = C2) : C2 = t2[32]; + let w2; + return t2[33] !== h4.style || t2[34] !== s3 || t2[35] !== p4 || t2[36] !== C2 || t2[37] !== g5 || t2[38] !== _5 || t2[39] !== v5 || t2[40] !== y4 ? (w2 = (0, Y3.jsx)(`span`, { ...g5, "aria-hidden": _5, "aria-label": v5, className: y4, "data-size": p4, ref: s3, style: h4.style, children: C2 }), t2[33] = h4.style, t2[34] = s3, t2[35] = p4, t2[36] = C2, t2[37] = g5, t2[38] = _5, t2[39] = v5, t2[40] = y4, t2[41] = w2) : w2 = t2[41], w2; +} +var sS = { interactive: { kWkggS: `sand-jbqb8w sand-1ecwv3n`, $$css: true }, selected: { kWkggS: `sand-kr7fhf sand-n0wurk`, $$css: true }, accentSelected: { kWkggS: `sand-ukxp9i sand-qc45by`, $$css: true }, controlEdge: { kGVxlE: `sand-bwjx97`, $$css: true }, searchField: { kZKoxP: `sand-t8t6p`, k8WAf4: `sand-t970qd`, kZCmMZ: `sand-22095l`, kwRFfy: `sand-1tlft3r`, kysU6D: `sand-jyslct`, ksu8eU: `sand-ng3xce`, kaIpWk: `sand-1qmwy7c`, kGVxlE: `sand-19mzooj`, kWkggS: `sand-10e981r`, kMwMTN: `sand-tyxrsu`, kMv6JI: `sand-jb2p0i`, $$css: true }, controlRing: { kMeerF: `sand-1k57tk5 sand-784prv`, k3XXqK: `sand-1t137rt sand-9v5kkp`, kjBf7l: `sand-1v39l1b`, kInvED: `sand-1y3gkto`, $$css: true }, keyboardFocus: { k3XXqK: `sand-1t137rt`, kGVxlE: `sand-18xb08s`, $$css: true }, buttonRadius: { kaIpWk: `sand-1m7fhj7`, $$css: true }, transcriptWidget: { kWkggS: `sand-18rdzox`, $$css: true }, askCardButton: { kmuXW: `sand-2lah0s`, kZKoxP: `sand-10w6t97`, kaIpWk: `sand-149ho13`, kwRFfy: `sand-pdmqnj`, kZCmMZ: `sand-1g0dm76`, kGuDYH: `sand-fc7y3v`, kLWn49: `sand-1yxxptd`, $$css: true }, askCardButtonTinted: { kVAM5u: `sand-5fd6op`, kWkggS: `sand-fwqdrz sand-19jy9ex`, kMwMTN: `sand-tyxrsu`, $$css: true }, splitControl: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-1qjc9v5`, kmuXW: `sand-2lah0s`, $$css: true }, splitControlLeading: { ke9TFa: `sand-10w94by`, kfmiAY: `sand-1ga7v0g`, kT0f0o: `sand-16uus16`, $$css: true }, splitControlTrailing: { krdFHd: `sand-15mokao`, kVL7Gh: `sand-biv7yw`, $$css: true }, thinScrollbar: { k5wCbM: `sand-1597r2g`, k6w4Gs: `sand-7h844e`, kBDiHx: `sand-y2251v`, krhWos: `sand-122zoth`, kAWW7O: `sand-1htvni2 sand-1gb0fpc`, kFaAu4: `sand-9xsh1y`, $$css: true } }; +var cS = { root: { kVAEAm: `sand-1n2onr6`, k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, kB7OPa: `sand-9f619`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-yri2b`, kGO01o: `sand-18d9i69`, kZCmMZ: `sand-1c1uobl`, kMzoRj: `sand-c342km`, ksu8eU: `sand-ng3xce`, kWkggS: `sand-jbqb8w`, kkrTdU: `sand-1ypdohk sand-tgyt42`, k1ekBW: `sand-s2xxs2`, kIyJzY: `sand-1firant`, kAMwcw: `sand-9lcvmn`, $$css: true }, focusAppearanceNone: { k3XXqK: `sand-i5y0ii`, $$css: true }, sizeLg: { kzqmXN: `sand-187nhsf`, kZKoxP: `sand-n3w4p2`, $$css: true }, sizeMd: { kzqmXN: `sand-gd8bvy`, kZKoxP: `sand-1fgtraw`, $$css: true }, sizeSm: { kzqmXN: `sand-vy4d1p`, kZKoxP: `sand-xk0z11`, $$css: true }, sizeXs: { kzqmXN: `sand-w4jnvo`, kZKoxP: `sand-1qx5ct2`, $$css: true }, shapeSquare: { kaIpWk: `sand-1kogg8i`, $$css: true }, shapeCircle: { kaIpWk: `sand-149ho13`, $$css: true }, ghost: { kWkggS: `sand-jbqb8w sand-1ecwv3n`, kMwMTN: `sand-nxsxl2 sand-13hlow9 sand-xcn2h6`, $$css: true }, ghostSelected: { kWkggS: `sand-18pe38m sand-19jy9ex`, $$css: true }, primary: { kWkggS: `sand-8rotk8 sand-1sxibbd sand-1ialtwx`, kMwMTN: `sand-sa7k8x sand-xcn2h6`, $$css: true }, secondary: { kWkggS: `sand-fwqdrz sand-19jy9ex sand-1g6zli8`, kMwMTN: `sand-nxsxl2 sand-xcn2h6`, $$css: true }, elevated: { kMzoRj: `sand-mkeg23`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-5fd6op`, kWkggS: `sand-10e981r`, kKwaWg: `sand-18o3ruo sand-101ryrv`, kMwMTN: `sand-1e6yr6a sand-xcn2h6`, $$css: true }, dangerGhost: { kWkggS: `sand-jbqb8w sand-q63dn4`, kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true }, dangerPrimary: { kWkggS: `sand-vopzge sand-a9ymcb sand-bmovrx`, kMwMTN: `sand-xcaa6e sand-5zuve2`, $$css: true }, dangerSecondary: { kWkggS: `sand-jt6epu sand-78epwt sand-rf7kli`, kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true }, dangerElevated: { kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true } }; +var sLe = { neutral: { ghost: cS.ghost, primary: cS.primary, secondary: cS.secondary, elevated: cS.elevated }, danger: { ghost: cS.dangerGhost, primary: cS.dangerPrimary, secondary: cS.dangerSecondary, elevated: [cS.elevated, cS.dangerElevated] } }; +var lS = { xs: cS.sizeXs, sm: cS.sizeSm, md: cS.sizeMd, lg: cS.sizeLg }; +var cLe = { xs: `sm`, sm: `md`, md: `lg`, lg: `xl` }; +function uS(e38) { + uS.d = 2365; + let t2 = (0, Z3.c)(60), n2, r2, i3, a3, o3, s3, c3, l5, u3, d3, f4, p4, m3, h4, g5, _5, v5, y4, b2, x2; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c3 = t2[7], l5 = t2[8], u3 = t2[9], d3 = t2[10], f4 = t2[11], p4 = t2[12], m3 = t2[13], h4 = t2[14], g5 = t2[15], _5 = t2[16], v5 = t2[17], y4 = t2[18], b2 = t2[19], x2 = t2[20]) : ({ icon: o3, glyph: a3, "aria-label": n2, "aria-pressed": r2, variant: p4, sentiment: m3, size: h4, iconSize: s3, iconVariant: l5, iconStyle: c3, iconCapTrim: g5, shape: _5, isSelected: v5, hasIndicatorDot: y4, focusAppearance: b2, className: i3, ref: u3, style: f4, type: x2, ...d3 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c3, t2[8] = l5, t2[9] = u3, t2[10] = d3, t2[11] = f4, t2[12] = p4, t2[13] = m3, t2[14] = h4, t2[15] = g5, t2[16] = _5, t2[17] = v5, t2[18] = y4, t2[19] = b2, t2[20] = x2); + let S2 = p4 === void 0 ? `ghost` : p4, C2 = m3 === void 0 ? `neutral` : m3, w2 = h4 === void 0 ? `md` : h4, T2 = g5 !== void 0 && g5, E2 = _5 === void 0 ? `square` : _5, D2 = v5 !== void 0 && v5, O2 = y4 !== void 0 && y4, k2 = b2 === void 0 ? `default` : b2, A2 = x2 === void 0 ? `button` : x2, j2, M2, N3, P3, F2; + t2[21] !== n2 || t2[22] !== r2 || t2[23] !== i3 || t2[24] !== k2 || t2[25] !== D2 || t2[26] !== d3 || t2[27] !== C2 || t2[28] !== E2 || t2[29] !== w2 || t2[30] !== f4 || t2[31] !== S2 ? (j2 = h(cS.root, sS.controlRing, lS[w2], E2 === `square` ? cS.shapeSquare : cS.shapeCircle, sLe[C2][S2], S2 === `ghost` && D2 && cS.ghostSelected, k2 === `none` && cS.focusAppearanceNone, f4), M2 = d3, N3 = n2, P3 = r2 ?? (S2 === `ghost` && D2 ? true : void 0), F2 = $2(`sand-kit-icon-button`, j2.className, i3), t2[21] = n2, t2[22] = r2, t2[23] = i3, t2[24] = k2, t2[25] = D2, t2[26] = d3, t2[27] = C2, t2[28] = E2, t2[29] = w2, t2[30] = f4, t2[31] = S2, t2[32] = j2, t2[33] = M2, t2[34] = N3, t2[35] = P3, t2[36] = F2) : (j2 = t2[32], M2 = t2[33], N3 = t2[34], P3 = t2[35], F2 = t2[36]); + let I2; + t2[37] !== a3 || t2[38] !== o3 || t2[39] !== T2 || t2[40] !== s3 || t2[41] !== c3 || t2[42] !== l5 || t2[43] !== w2 ? (I2 = a3 ?? (0, Y3.jsx)(aS, { capTrim: T2, name: o3, size: s3 ?? cLe[w2], style: c3, variant: l5 }), t2[37] = a3, t2[38] = o3, t2[39] = T2, t2[40] = s3, t2[41] = c3, t2[42] = l5, t2[43] = w2, t2[44] = I2) : I2 = t2[44]; + let L3; + t2[45] === O2 ? L3 = t2[46] : (L3 = O2 ? (0, Y3.jsx)(`span`, { "aria-hidden": true, className: { className: `sand-10l6tqk sand-xk6nc9 sand-1ro0b6g sand-1v4s8kt sand-ols6we sand-149ho13 sand-1vh0fzo sand-47corl` }.className }) : null, t2[45] = O2, t2[46] = L3); let R3; - return t2[47] !== j3.style || t2[48] !== u3 || t2[49] !== C2 || t2[50] !== w3 || t2[51] !== M3 || t2[52] !== N2 || t2[53] !== P2 || t2[54] !== F2 || t2[55] !== I || t2[56] !== L || t2[57] !== A3 || t2[58] !== S3 ? (R3 = (0, Y2.jsxs)(`button`, { ...M3, "aria-label": N2, "aria-pressed": P2, className: F2, "data-sentiment": C2, "data-size": w3, "data-variant": S3, ref: u3, style: j3.style, type: A3, children: [I, L] }), t2[47] = j3.style, t2[48] = u3, t2[49] = C2, t2[50] = w3, t2[51] = M3, t2[52] = N2, t2[53] = P2, t2[54] = F2, t2[55] = I, t2[56] = L, t2[57] = A3, t2[58] = S3, t2[59] = R3) : R3 = t2[59], R3; -} -var sC = `sm`; -var ZMe = `md`; -var QMe = `xl`; -var cC = `md`; -var lC = (0, X2.createContext)(`bubble`); -var uC = (0, X2.createContext)(false); -var dC = (0, X2.createContext)(`standard`); -function fC() { - return (0, X2.useContext)(lC); -} -var pC = { root: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kB7OPa: `sand-9f619`, kzqmXN: `sand-h8yej3`, k7Eaqz: `sand-euugli`, kVQacm: `sand-b3r6kr`, kHjlTd: `sand-j0a0fe`, kMwMTN: `sand-tyxrsu`, $$css: true }, bubble: { kOIVth: `sand-883omv`, kmVPX3: `sand-c7ga6q`, kaIpWk: `sand-gqmno8`, $$css: true }, elevated: { kaIpWk: `sand-1m1syzd`, kWkggS: `sand-10e981r`, kGVxlE: `sand-124efjc`, $$css: true }, titlebarDisclosure: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, kaIpWk: `sand-149ho13`, kWkggS: `sand-jbqb8w sand-11hyl0l sand-1t4e3jf sand-k2bhp9 sand-56zfcv`, kMwMTN: `sand-1o0liin sand-n4ifyr sand-s4zcoc`, k1ekBW: `sand-s2xxs2`, kIyJzY: `sand-1firant`, kAMwcw: `sand-9lcvmn`, $$css: true }, titlebarLabel: { kmuXW: `sand-2lah0s`, $$css: true }, titlebarSummary: { k7Eaqz: `sand-euugli`, kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, kMwMTN: `sand-169k319`, $$css: true }, titlebarSummaryDanger: { kMwMTN: `sand-i69oq4`, $$css: true }, controlFootprint: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, $$css: true }, iconButtonFill: { kWkggS: `sand-jbqb8w sand-1ecwv3n sand-18ptgz8`, $$css: true }, title: { kqGvvJ: `sand-10im51j`, kUOVxO: `sand-rxpjvj`, k7Eaqz: `sand-euugli`, kMwMTN: `sand-1heor9g`, $$css: true }, titleElevated: { kGuDYH: `sand-1jvydc1`, kLWn49: `sand-19v9tvf`, kb6lSQ: `sand-99smjr`, $$css: true }, singleLine: { kVQacm: `sand-b3r6kr`, khDVqt: `sand-uxw1ft`, kg5iWk: `sand-lyipyv`, $$css: true }, subtitle: { kqGvvJ: `sand-10im51j`, kUOVxO: `sand-rxpjvj`, kMwMTN: `sand-1o0liin`, $$css: true }, subtitleDanger: { kMwMTN: `sand-i69oq4`, $$css: true } }; -var $Me = { bubble: pC.bubble, elevated: pC.elevated }; -function mC(e9, t2) { - return h(e9 === `bubble` && rC.transcriptWidget, pC.root, $Me[e9], t2); -} -function hC(e9) { - hC.d = 2072; - let t2 = (0, Z2.c)(9), { surface: n2, hasTitlebar: r2, inset: i3, children: a3 } = e9, o3; - t2[0] !== a3 || t2[1] !== i3 ? (o3 = (0, Y2.jsx)(dC.Provider, { value: i3, children: a3 }), t2[0] = a3, t2[1] = i3, t2[2] = o3) : o3 = t2[2]; + return t2[47] !== j2.style || t2[48] !== u3 || t2[49] !== C2 || t2[50] !== w2 || t2[51] !== M2 || t2[52] !== N3 || t2[53] !== P3 || t2[54] !== F2 || t2[55] !== I2 || t2[56] !== L3 || t2[57] !== A2 || t2[58] !== S2 ? (R3 = (0, Y3.jsxs)(`button`, { ...M2, "aria-label": N3, "aria-pressed": P3, className: F2, "data-sentiment": C2, "data-size": w2, "data-variant": S2, ref: u3, style: j2.style, type: A2, children: [I2, L3] }), t2[47] = j2.style, t2[48] = u3, t2[49] = C2, t2[50] = w2, t2[51] = M2, t2[52] = N3, t2[53] = P3, t2[54] = F2, t2[55] = I2, t2[56] = L3, t2[57] = A2, t2[58] = S2, t2[59] = R3) : R3 = t2[59], R3; +} +var dS = `sm`; +var lLe = `md`; +var uLe = `xl`; +var fS = `md`; +var pS = (0, X3.createContext)(`bubble`); +var mS = (0, X3.createContext)(false); +var hS = (0, X3.createContext)(`standard`); +function gS() { + return (0, X3.useContext)(pS); +} +var _S = { root: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kB7OPa: `sand-9f619`, kzqmXN: `sand-h8yej3`, k7Eaqz: `sand-euugli`, kVQacm: `sand-b3r6kr`, kHjlTd: `sand-j0a0fe`, kMwMTN: `sand-tyxrsu`, $$css: true }, bubble: { kOIVth: `sand-883omv`, kmVPX3: `sand-c7ga6q`, kaIpWk: `sand-gqmno8`, $$css: true }, elevated: { kaIpWk: `sand-1m1syzd`, kWkggS: `sand-10e981r`, kGVxlE: `sand-124efjc`, $$css: true }, titlebarDisclosure: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, kaIpWk: `sand-149ho13`, kWkggS: `sand-jbqb8w sand-11hyl0l sand-1t4e3jf sand-k2bhp9 sand-56zfcv`, kMwMTN: `sand-1o0liin sand-n4ifyr sand-s4zcoc`, k1ekBW: `sand-s2xxs2`, kIyJzY: `sand-1firant`, kAMwcw: `sand-9lcvmn`, $$css: true }, titlebarLabel: { kmuXW: `sand-2lah0s`, $$css: true }, titlebarSummary: { k7Eaqz: `sand-euugli`, kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, kMwMTN: `sand-169k319`, $$css: true }, titlebarSummaryDanger: { kMwMTN: `sand-i69oq4`, $$css: true }, controlFootprint: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kmuXW: `sand-2lah0s`, $$css: true }, iconButtonFill: { kWkggS: `sand-jbqb8w sand-1ecwv3n sand-18ptgz8`, $$css: true }, title: { kqGvvJ: `sand-10im51j`, kUOVxO: `sand-rxpjvj`, k7Eaqz: `sand-euugli`, kMwMTN: `sand-1heor9g`, $$css: true }, titleElevated: { kGuDYH: `sand-1jvydc1`, kLWn49: `sand-19v9tvf`, kb6lSQ: `sand-99smjr`, $$css: true }, singleLine: { kVQacm: `sand-b3r6kr`, khDVqt: `sand-uxw1ft`, kg5iWk: `sand-lyipyv`, $$css: true }, subtitle: { kqGvvJ: `sand-10im51j`, kUOVxO: `sand-rxpjvj`, kMwMTN: `sand-1o0liin`, $$css: true }, subtitleDanger: { kMwMTN: `sand-i69oq4`, $$css: true } }; +var dLe = { bubble: _S.bubble, elevated: _S.elevated }; +function vS(e38, t2) { + return h(e38 === `bubble` && sS.transcriptWidget, _S.root, dLe[e38], t2); +} +function yS(e38) { + yS.d = 2340; + let t2 = (0, Z3.c)(9), { surface: n2, hasTitlebar: r2, inset: i3, children: a3 } = e38, o3; + t2[0] !== a3 || t2[1] !== i3 ? (o3 = (0, Y3.jsx)(hS.Provider, { value: i3, children: a3 }), t2[0] = a3, t2[1] = i3, t2[2] = o3) : o3 = t2[2]; let s3; - t2[3] !== r2 || t2[4] !== o3 ? (s3 = (0, Y2.jsx)(uC.Provider, { value: r2, children: o3 }), t2[3] = r2, t2[4] = o3, t2[5] = s3) : s3 = t2[5]; - let c2; - return t2[6] !== n2 || t2[7] !== s3 ? (c2 = (0, Y2.jsx)(lC.Provider, { value: n2, children: s3 }), t2[6] = n2, t2[7] = s3, t2[8] = c2) : c2 = t2[8], c2; -} -function gC(e9) { - gC.d = 2065; - let t2 = (0, Z2.c)(20), n2, r2, i3, a3, o3, s3; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6]) : ({ surface: a3, titlebar: s3, inset: o3, style: i3, children: n2, ...r2 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3); - let c2 = a3 === void 0 ? `bubble` : a3, l4 = o3 === void 0 ? `standard` : o3, u3 = s3 != null, d3; - t2[7] !== i3 || t2[8] !== c2 ? (d3 = mC(c2, i3), t2[7] = i3, t2[8] = c2, t2[9] = d3) : d3 = t2[9]; + t2[3] !== r2 || t2[4] !== o3 ? (s3 = (0, Y3.jsx)(mS.Provider, { value: r2, children: o3 }), t2[3] = r2, t2[4] = o3, t2[5] = s3) : s3 = t2[5]; + let c3; + return t2[6] !== n2 || t2[7] !== s3 ? (c3 = (0, Y3.jsx)(pS.Provider, { value: n2, children: s3 }), t2[6] = n2, t2[7] = s3, t2[8] = c3) : c3 = t2[8], c3; +} +function bS(e38) { + bS.d = 2333; + let t2 = (0, Z3.c)(20), n2, r2, i3, a3, o3, s3; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6]) : ({ surface: a3, titlebar: s3, inset: o3, style: i3, children: n2, ...r2 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3); + let c3 = a3 === void 0 ? `bubble` : a3, l5 = o3 === void 0 ? `standard` : o3, u3 = s3 != null, d3; + t2[7] !== i3 || t2[8] !== c3 ? (d3 = vS(c3, i3), t2[7] = i3, t2[8] = c3, t2[9] = d3) : d3 = t2[9]; let f4; - t2[10] !== n2 || t2[11] !== r2 || t2[12] !== d3 || t2[13] !== s3 ? (f4 = (0, Y2.jsxs)(`section`, { ...r2, ...d3, children: [s3, n2] }), t2[10] = n2, t2[11] = r2, t2[12] = d3, t2[13] = s3, t2[14] = f4) : f4 = t2[14]; + t2[10] !== n2 || t2[11] !== r2 || t2[12] !== d3 || t2[13] !== s3 ? (f4 = (0, Y3.jsxs)(`section`, { ...r2, ...d3, children: [s3, n2] }), t2[10] = n2, t2[11] = r2, t2[12] = d3, t2[13] = s3, t2[14] = f4) : f4 = t2[14]; let p4; - return t2[15] !== u3 || t2[16] !== l4 || t2[17] !== c2 || t2[18] !== f4 ? (p4 = (0, Y2.jsx)(hC, { hasTitlebar: u3, inset: l4, surface: c2, children: f4 }), t2[15] = u3, t2[16] = l4, t2[17] = c2, t2[18] = f4, t2[19] = p4) : p4 = t2[19], p4; + return t2[15] !== u3 || t2[16] !== l5 || t2[17] !== c3 || t2[18] !== f4 ? (p4 = (0, Y3.jsx)(yS, { hasTitlebar: u3, inset: l5, surface: c3, children: f4 }), t2[15] = u3, t2[16] = l5, t2[17] = c3, t2[18] = f4, t2[19] = p4) : p4 = t2[19], p4; } -function vC(e9) { - vC.d = 2073; - let t2 = (0, Z2.c)(33), { icon: n2, label: r2, summary: i3, detail: a3, isSummaryDanger: o3, disclosure: s3, trailing: c2 } = e9, l4 = o3 !== void 0 && o3, u3; +function SS(e38) { + SS.d = 2341; + let t2 = (0, Z3.c)(33), { icon: n2, label: r2, summary: i3, detail: a3, isSummaryDanger: o3, disclosure: s3, trailing: c3 } = e38, l5 = o3 !== void 0 && o3, u3; t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u3 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-9f619 sand-w4jnvo sand-1qx5ct2 sand-r9ek0c sand-b3r6kr sand-qjedn3 sand-1y0btm7 sand-14ed0nm sand-t9pb60 sand-fwqdrz sand-1o0liin` }, t2[0] = u3) : u3 = t2[0]; let d3; - t2[1] === n2 ? d3 = t2[2] : (d3 = (0, Y2.jsx)(`span`, { "aria-hidden": true, ...u3, children: n2 }), t2[1] = n2, t2[2] = d3); + t2[1] === n2 ? d3 = t2[2] : (d3 = (0, Y3.jsx)(`span`, { "aria-hidden": true, ...u3, children: n2 }), t2[1] = n2, t2[2] = d3); let f4; t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f4 = { className: `sand-78zum5 sand-1pha0wt sand-1jnr06f sand-1iyjqo2 sand-euugli sand-yqdw3p sand-b3r6kr sand-uxw1ft` }, t2[3] = f4) : f4 = t2[3]; let p4; - t2[4] === r2 ? p4 = t2[5] : (p4 = (0, Y2.jsx)(lx, { as: `span`, level: `body2`, style: pC.titlebarLabel, weight: `medium`, children: r2 }), t2[4] = r2, t2[5] = p4); + t2[4] === r2 ? p4 = t2[5] : (p4 = (0, Y3.jsx)(Xb2, { as: `span`, level: `body2`, style: _S.titlebarLabel, weight: `medium`, children: r2 }), t2[4] = r2, t2[5] = p4); let m3; - t2[6] !== a3 || t2[7] !== l4 || t2[8] !== i3 ? (m3 = i3 == null ? null : (0, Y2.jsxs)(lx, { as: `span`, level: `body2`, style: [pC.titlebarSummary, l4 && pC.titlebarSummaryDanger], children: [i3, a3 == null ? null : (0, Y2.jsxs)(Y2.Fragment, { children: [` \xB7 `, a3] })] }), t2[6] = a3, t2[7] = l4, t2[8] = i3, t2[9] = m3) : m3 = t2[9]; - let h3; - t2[10] !== p4 || t2[11] !== m3 ? (h3 = (0, Y2.jsxs)(`span`, { ...f4, children: [p4, m3] }), t2[10] = p4, t2[11] = m3, t2[12] = h3) : h3 = t2[12]; - let g3; - t2[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g3 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-nei2rj sand-xk0z11 sand-1o0liin` }, t2[13] = g3) : g3 = t2[13]; - let _2; - t2[14] !== s3 || t2[15] !== c2 ? (_2 = s3 == null ? c2 : (0, Y2.jsx)(`span`, { ...h(pC.titlebarDisclosure, aC[sC]), children: (0, Y2.jsx)(tC, { "aria-hidden": true, name: `chevrons-up-down`, size: cC }) }), t2[14] = s3, t2[15] = c2, t2[16] = _2) : _2 = t2[16]; - let v3; - t2[17] === _2 ? v3 = t2[18] : (v3 = (0, Y2.jsx)(`span`, { ...g3, children: _2 }), t2[17] = _2, t2[18] = v3); - let y3; - t2[19] !== v3 || t2[20] !== d3 || t2[21] !== h3 ? (y3 = (0, Y2.jsxs)(Y2.Fragment, { children: [d3, h3, v3] }), t2[19] = v3, t2[20] = d3, t2[21] = h3, t2[22] = y3) : y3 = t2[22]; - let b3 = y3; + t2[6] !== a3 || t2[7] !== l5 || t2[8] !== i3 ? (m3 = i3 == null ? null : (0, Y3.jsxs)(Xb2, { as: `span`, level: `body2`, style: [_S.titlebarSummary, l5 && _S.titlebarSummaryDanger], children: [i3, a3 == null ? null : (0, Y3.jsxs)(Y3.Fragment, { children: [` \xB7 `, a3] })] }), t2[6] = a3, t2[7] = l5, t2[8] = i3, t2[9] = m3) : m3 = t2[9]; + let h4; + t2[10] !== p4 || t2[11] !== m3 ? (h4 = (0, Y3.jsxs)(`span`, { ...f4, children: [p4, m3] }), t2[10] = p4, t2[11] = m3, t2[12] = h4) : h4 = t2[12]; + let g5; + t2[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g5 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-nei2rj sand-xk0z11 sand-1o0liin` }, t2[13] = g5) : g5 = t2[13]; + let _5; + t2[14] !== s3 || t2[15] !== c3 ? (_5 = s3 == null ? c3 : (0, Y3.jsx)(`span`, { ...h(_S.titlebarDisclosure, lS[dS]), children: (0, Y3.jsx)(aS, { "aria-hidden": true, name: `chevrons-up-down`, size: fS }) }), t2[14] = s3, t2[15] = c3, t2[16] = _5) : _5 = t2[16]; + let v5; + t2[17] === _5 ? v5 = t2[18] : (v5 = (0, Y3.jsx)(`span`, { ...g5, children: _5 }), t2[17] = _5, t2[18] = v5); + let y4; + t2[19] !== v5 || t2[20] !== d3 || t2[21] !== h4 ? (y4 = (0, Y3.jsxs)(Y3.Fragment, { children: [d3, h4, v5] }), t2[19] = v5, t2[20] = d3, t2[21] = h4, t2[22] = y4) : y4 = t2[22]; + let b2 = y4; if (s3 == null) { - let e10; - t2[23] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e10 = { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-9f619 sand-h8yej3 sand-euugli sand-yinxu5 sand-1pic42t sand-1g2khh7 sand-f7dkkf sand-tyxrsu` }, t2[23] = e10) : e10 = t2[23]; + let e39; + t2[23] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-9f619 sand-h8yej3 sand-euugli sand-yinxu5 sand-1pic42t sand-1g2khh7 sand-f7dkkf sand-tyxrsu` }, t2[23] = e39) : e39 = t2[23]; let n3; - return t2[24] === b3 ? n3 = t2[25] : (n3 = (0, Y2.jsx)(`div`, { ...e10, children: b3 }), t2[24] = b3, t2[25] = n3), n3; - } - let x3 = s3.controlsId, S3 = s3.isExpanded, C2 = s3.onToggle, w3; - t2[26] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (w3 = { className: `sand--default-marker sand-78zum5 sand-1cy8zhl sand-167g77z sand-9f619 sand-h8yej3 sand-euugli sand-yinxu5 sand-1pic42t sand-1g2khh7 sand-f7dkkf sand-tyxrsu sand-10im51j sand-rxpjvj sand-c342km sand-ng3xce sand-jbqb8w sand-jb2p0i sand-1yc453h sand-1ypdohk sand-1t137rt sand-1yfcfk6` }, t2[26] = w3) : w3 = t2[26]; - let T3; - return t2[27] !== b3 || t2[28] !== s3.controlsId || t2[29] !== s3.isExpanded || t2[30] !== s3.onToggle || t2[31] !== w3 ? (T3 = (0, Y2.jsx)(`button`, { "aria-controls": x3, "aria-expanded": S3, onClick: C2, type: `button`, ...w3, children: b3 }), t2[27] = b3, t2[28] = s3.controlsId, t2[29] = s3.isExpanded, t2[30] = s3.onToggle, t2[31] = w3, t2[32] = T3) : T3 = t2[32], T3; -} -function bC(e9) { - bC.d = 2071; - let t2 = (0, Z2.c)(3), n2; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n2 = h(pC.controlFootprint, aC[sC]), t2[0] = n2) : n2 = t2[0]; + return t2[24] === b2 ? n3 = t2[25] : (n3 = (0, Y3.jsx)(`div`, { ...e39, children: b2 }), t2[24] = b2, t2[25] = n3), n3; + } + let x2 = s3.controlsId, S2 = s3.isExpanded, C2 = s3.onToggle, w2; + t2[26] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (w2 = { className: `sand--default-marker sand-78zum5 sand-1cy8zhl sand-167g77z sand-9f619 sand-h8yej3 sand-euugli sand-yinxu5 sand-1pic42t sand-1g2khh7 sand-f7dkkf sand-tyxrsu sand-10im51j sand-rxpjvj sand-c342km sand-ng3xce sand-jbqb8w sand-jb2p0i sand-1yc453h sand-1ypdohk sand-1t137rt sand-1yfcfk6` }, t2[26] = w2) : w2 = t2[26]; + let T2; + return t2[27] !== b2 || t2[28] !== s3.controlsId || t2[29] !== s3.isExpanded || t2[30] !== s3.onToggle || t2[31] !== w2 ? (T2 = (0, Y3.jsx)(`button`, { "aria-controls": x2, "aria-expanded": S2, onClick: C2, type: `button`, ...w2, children: b2 }), t2[27] = b2, t2[28] = s3.controlsId, t2[29] = s3.isExpanded, t2[30] = s3.onToggle, t2[31] = w2, t2[32] = T2) : T2 = t2[32], T2; +} +function wS(e38) { + wS.d = 2342; + let t2 = (0, Z3.c)(2), n2; + return t2[0] === e38 ? n2 = t2[1] : (n2 = (0, Y3.jsx)(uS, { ...e38, iconSize: fS, shape: `circle`, size: dS, style: _S.iconButtonFill }), t2[0] = e38, t2[1] = n2), n2; +} +function TS(e38) { + TS.d = 2339; + let t2 = (0, Z3.c)(3), n2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n2 = h(_S.controlFootprint, lS[dS]), t2[0] = n2) : n2 = t2[0]; let r2; - return t2[1] === e9 ? r2 = t2[2] : (r2 = (0, Y2.jsx)(`span`, { ...n2, children: (0, Y2.jsx)(oC, { ...e9, iconSize: QMe, shape: `circle`, size: ZMe, style: pC.iconButtonFill }) }), t2[1] = e9, t2[2] = r2), r2; + return t2[1] === e38 ? r2 = t2[2] : (r2 = (0, Y3.jsx)(`span`, { ...n2, children: (0, Y3.jsx)(uS, { ...e38, iconSize: uLe, shape: `circle`, size: lLe, style: _S.iconButtonFill }) }), t2[1] = e38, t2[2] = r2), r2; } -function xC(e9) { - xC.d = 2070; - let t2 = (0, Z2.c)(25), { title: n2, titleId: r2, subtitle: i3, subtitleId: a3, leading: o3, trailing: s3 } = e9, c2 = IS(r2), l4 = fC() === `elevated`, u3 = (0, X2.useContext)(uC), d3 = (0, X2.useContext)(dC) === `compact`, f4; - t2[0] !== u3 || t2[1] !== d3 || t2[2] !== l4 ? (f4 = { 0: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli` }, 4: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-yinxu5 sand-1xnnf8n sand-jkvuk6 sand-170u2dc sand-106a9eq` }, 2: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-1iorvi4` }, 6: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-1xnnf8n sand-jkvuk6 sand-170u2dc sand-106a9eq sand-1iorvi4` }, 1: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-v54qhq sand-f7dkkf` }, 5: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-yinxu5 sand-jkvuk6 sand-170u2dc sand-v54qhq sand-f7dkkf` }, 3: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-1iorvi4 sand-v54qhq sand-f7dkkf` }, 7: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-jkvuk6 sand-170u2dc sand-1iorvi4 sand-v54qhq sand-f7dkkf` } }[!!l4 << 2 | !!(l4 && u3) << 1 | !!(l4 && d3) << 0], t2[0] = u3, t2[1] = d3, t2[2] = l4, t2[3] = f4) : f4 = t2[3]; +function ES(e38) { + ES.d = 2338; + let t2 = (0, Z3.c)(25), { title: n2, titleId: r2, subtitle: i3, subtitleId: a3, leading: o3, trailing: s3 } = e38, c3 = zx(r2), l5 = gS() === `elevated`, u3 = (0, X3.useContext)(mS), d3 = (0, X3.useContext)(hS) === `compact`, f4; + t2[0] !== u3 || t2[1] !== d3 || t2[2] !== l5 ? (f4 = { 0: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli` }, 4: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-yinxu5 sand-1xnnf8n sand-jkvuk6 sand-170u2dc sand-106a9eq` }, 2: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-1iorvi4` }, 6: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-1xnnf8n sand-jkvuk6 sand-170u2dc sand-106a9eq sand-1iorvi4` }, 1: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-v54qhq sand-f7dkkf` }, 5: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-yinxu5 sand-jkvuk6 sand-170u2dc sand-v54qhq sand-f7dkkf` }, 3: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-1iorvi4 sand-v54qhq sand-f7dkkf` }, 7: { className: `sand-78zum5 sand-1cy8zhl sand-167g77z sand-euugli sand-jkvuk6 sand-170u2dc sand-1iorvi4 sand-v54qhq sand-f7dkkf` } }[!!l5 << 2 | !!(l5 && u3) << 1 | !!(l5 && d3) << 0], t2[0] = u3, t2[1] = d3, t2[2] = l5, t2[3] = f4) : f4 = t2[3]; let p4; - t2[4] === o3 ? p4 = t2[5] : (p4 = o3 == null ? null : (0, Y2.jsx)(`span`, { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-1qx5ct2 sand-1o0liin`, children: o3 }), t2[4] = o3, t2[5] = p4); + t2[4] === o3 ? p4 = t2[5] : (p4 = o3 == null ? null : (0, Y3.jsx)(`span`, { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-1qx5ct2 sand-1o0liin`, children: o3 }), t2[4] = o3, t2[5] = p4); let m3; - t2[6] === l4 ? m3 = t2[7] : (m3 = { 0: { className: `sand-78zum5 sand-1iyjqo2 sand-s83m0k sand-dt5ytf sand-euugli` }, 1: { className: `sand-78zum5 sand-1iyjqo2 sand-s83m0k sand-dt5ytf sand-euugli sand-195vfkc` } }[!!l4 << 0], t2[6] = l4, t2[7] = m3); - let h3; - t2[8] !== c2 || t2[9] !== l4 || t2[10] !== n2 || t2[11] !== r2 ? (h3 = n2 == null ? null : (0, Y2.jsx)(lx, { as: `p`, id: r2, ref: c2, style: [pC.title, l4 && pC.titleElevated], weight: l4 ? `semibold` : `medium`, children: n2 }), t2[8] = c2, t2[9] = l4, t2[10] = n2, t2[11] = r2, t2[12] = h3) : h3 = t2[12]; - let g3; - t2[13] !== i3 || t2[14] !== a3 ? (g3 = i3 == null ? null : (0, Y2.jsx)(lx, { as: `div`, id: a3, style: pC.subtitle, children: i3 }), t2[13] = i3, t2[14] = a3, t2[15] = g3) : g3 = t2[15]; - let _2; - t2[16] !== m3 || t2[17] !== h3 || t2[18] !== g3 ? (_2 = (0, Y2.jsxs)(`div`, { ...m3, children: [h3, g3] }), t2[16] = m3, t2[17] = h3, t2[18] = g3, t2[19] = _2) : _2 = t2[19]; - let v3; - return t2[20] !== f4 || t2[21] !== p4 || t2[22] !== _2 || t2[23] !== s3 ? (v3 = (0, Y2.jsxs)(`div`, { ...f4, children: [p4, _2, s3] }), t2[20] = f4, t2[21] = p4, t2[22] = _2, t2[23] = s3, t2[24] = v3) : v3 = t2[24], v3; -} -function TC(e9) { - TC.d = 2066; - let t2 = (0, Z2.c)(9), { leading: n2, children: r2, trailing: i3 } = e9, a3 = fC() === `elevated`, o3; + t2[6] === l5 ? m3 = t2[7] : (m3 = { 0: { className: `sand-78zum5 sand-1iyjqo2 sand-s83m0k sand-dt5ytf sand-euugli` }, 1: { className: `sand-78zum5 sand-1iyjqo2 sand-s83m0k sand-dt5ytf sand-euugli sand-195vfkc` } }[!!l5 << 0], t2[6] = l5, t2[7] = m3); + let h4; + t2[8] !== c3 || t2[9] !== l5 || t2[10] !== n2 || t2[11] !== r2 ? (h4 = n2 == null ? null : (0, Y3.jsx)(Xb2, { as: `p`, id: r2, ref: c3, style: [_S.title, l5 && _S.titleElevated], weight: l5 ? `semibold` : `medium`, children: n2 }), t2[8] = c3, t2[9] = l5, t2[10] = n2, t2[11] = r2, t2[12] = h4) : h4 = t2[12]; + let g5; + t2[13] !== i3 || t2[14] !== a3 ? (g5 = i3 == null ? null : (0, Y3.jsx)(Xb2, { as: `div`, id: a3, style: _S.subtitle, children: i3 }), t2[13] = i3, t2[14] = a3, t2[15] = g5) : g5 = t2[15]; + let _5; + t2[16] !== m3 || t2[17] !== h4 || t2[18] !== g5 ? (_5 = (0, Y3.jsxs)(`div`, { ...m3, children: [h4, g5] }), t2[16] = m3, t2[17] = h4, t2[18] = g5, t2[19] = _5) : _5 = t2[19]; + let v5; + return t2[20] !== f4 || t2[21] !== p4 || t2[22] !== _5 || t2[23] !== s3 ? (v5 = (0, Y3.jsxs)(`div`, { ...f4, children: [p4, _5, s3] }), t2[20] = f4, t2[21] = p4, t2[22] = _5, t2[23] = s3, t2[24] = v5) : v5 = t2[24], v5; +} +function AS(e38) { + AS.d = 2334; + let t2 = (0, Z3.c)(9), { leading: n2, children: r2, trailing: i3 } = e38, a3 = gS() === `elevated`, o3; t2[0] === a3 ? o3 = t2[1] : (o3 = { 0: { className: `sand-78zum5 sand-1a02dak sand-6s0dn4 sand-167g77z sand-h8yej3 sand-euugli` }, 1: { className: `sand-78zum5 sand-1a02dak sand-6s0dn4 sand-167g77z sand-h8yej3 sand-euugli sand-9f619 sand-889kno sand-v54qhq sand-1l90r2v sand-f7dkkf` } }[!!a3 << 0], t2[0] = a3, t2[1] = o3); let s3; - t2[2] === i3 ? s3 = t2[3] : (s3 = i3 == null ? null : (0, Y2.jsx)(`div`, { className: `sand-3nfvp2 sand-1a02dak sand-6s0dn4 sand-13a6bvl sand-167g77z sand-euugli sand-vc5jky`, children: i3 }), t2[2] = i3, t2[3] = s3); - let c2; - return t2[4] !== r2 || t2[5] !== n2 || t2[6] !== o3 || t2[7] !== s3 ? (c2 = (0, Y2.jsxs)(`div`, { ...o3, children: [n2, r2, s3] }), t2[4] = r2, t2[5] = n2, t2[6] = o3, t2[7] = s3, t2[8] = c2) : c2 = t2[8], c2; -} -function OC(e9) { - OC.d = 2087; - let t2 = (0, Z2.c)(23), { id: n2, name: r2, isChecked: i3, isIndeterminate: a3, isDisabled: o3, isRequired: s3, ref: c2, onChange: l4 } = e9, u3 = a3 !== void 0 && a3, d3 = o3 !== void 0 && o3, f4 = s3 !== void 0 && s3, p4 = i3 || u3, m3; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m3 = { className: `sand-1n2onr6 sand-3nfvp2 sand-2lah0s` }, t2[0] = m3) : m3 = t2[0]; - let h3 = f4 || void 0, g3; - t2[1] === l4 ? g3 = t2[2] : (g3 = (e10) => l4(e10.target.checked), t2[1] = l4, t2[2] = g3); - let _2; - t2[3] !== u3 || t2[4] !== c2 ? (_2 = (e10) => (e10 !== null && (e10.indeterminate = u3), c2?.(e10)), t2[3] = u3, t2[4] = c2, t2[5] = _2) : _2 = t2[5]; - let v3; - t2[6] === p4 ? v3 = t2[7] : (v3 = { 0: { className: `sand-jyslct sand-9f619 sand-1kky2od sand-lup9mm sand-dj266r sand-14z9mp sand-at24cr sand-1lziwak sand-mkeg23 sand-1y0btm7 sand-1x2x08a sand-1i6gnc1 sand-10e981r sand-1ypdohk sand-1s07b3s sand-15406qy sand-1firant sand-wji4o3` }, 1: { className: `sand-jyslct sand-9f619 sand-1kky2od sand-lup9mm sand-dj266r sand-14z9mp sand-at24cr sand-1lziwak sand-1y0btm7 sand-1i6gnc1 sand-1ypdohk sand-1s07b3s sand-15406qy sand-1firant sand-wji4o3 sand-qjedn3 sand-14ed0nm sand-1cgqir sand-1moagsb sand-jhkic0` } }[!!p4 << 0], t2[6] = p4, t2[7] = v3); - let y3; - t2[8] !== n2 || t2[9] !== i3 || t2[10] !== d3 || t2[11] !== r2 || t2[12] !== h3 || t2[13] !== g3 || t2[14] !== _2 || t2[15] !== v3 ? (y3 = (0, Y2.jsx)(`input`, { "aria-required": h3, id: n2, name: r2, checked: i3, disabled: d3, onChange: g3, ref: _2, type: `checkbox`, ...v3 }), t2[8] = n2, t2[9] = i3, t2[10] = d3, t2[11] = r2, t2[12] = h3, t2[13] = g3, t2[14] = _2, t2[15] = v3, t2[16] = y3) : y3 = t2[16]; - let b3; - t2[17] !== i3 || t2[18] !== p4 ? (b3 = p4 ? (0, Y2.jsx)(`span`, { "aria-hidden": true, className: `sand-10l6tqk sand-13vifvy sand-tijo5x sand-1ey2m1c sand-1o0tod sand-78zum5 sand-6s0dn4 sand-l56j7k sand-xcaa6e sand-47corl`, children: (0, Y2.jsx)(tC, { name: i3 ? `check` : `minus`, size: `xs`, variant: `filled` }) }) : null, t2[17] = i3, t2[18] = p4, t2[19] = b3) : b3 = t2[19]; - let x3; - return t2[20] !== b3 || t2[21] !== y3 ? (x3 = (0, Y2.jsxs)(`span`, { ...m3, children: [y3, b3] }), t2[20] = b3, t2[21] = y3, t2[22] = x3) : x3 = t2[22], x3; -} -function kC(e9) { - kC.d = 2118; - let t2 = (0, Z2.c)(12), { size: n2, borderWidth: r2, inheritColor: i3, paused: a3, className: o3 } = e9, s3 = n2 === void 0 ? 24 : n2, c2 = r2 === void 0 ? 2 : r2, l4 = i3 !== void 0 && i3, u3 = a3 !== void 0 && a3 ? `paused` : void 0, d3; - t2[0] !== c2 || t2[1] !== s3 || t2[2] !== u3 ? (d3 = { width: s3, height: s3, borderWidth: c2, animationPlayState: u3 }, t2[0] = c2, t2[1] = s3, t2[2] = u3, t2[3] = d3) : d3 = t2[3]; + t2[2] === i3 ? s3 = t2[3] : (s3 = i3 == null ? null : (0, Y3.jsx)(`div`, { className: `sand-3nfvp2 sand-1a02dak sand-6s0dn4 sand-13a6bvl sand-167g77z sand-euugli sand-vc5jky`, children: i3 }), t2[2] = i3, t2[3] = s3); + let c3; + return t2[4] !== r2 || t2[5] !== n2 || t2[6] !== o3 || t2[7] !== s3 ? (c3 = (0, Y3.jsxs)(`div`, { ...o3, children: [n2, r2, s3] }), t2[4] = r2, t2[5] = n2, t2[6] = o3, t2[7] = s3, t2[8] = c3) : c3 = t2[8], c3; +} +function PS(e38) { + PS.d = 2393; + let t2 = (0, Z3.c)(12), { size: n2, borderWidth: r2, inheritColor: i3, paused: a3, className: o3 } = e38, s3 = n2 === void 0 ? 24 : n2, c3 = r2 === void 0 ? 2 : r2, l5 = i3 !== void 0 && i3, u3 = a3 !== void 0 && a3 ? `paused` : void 0, d3; + t2[0] !== c3 || t2[1] !== s3 || t2[2] !== u3 ? (d3 = { width: s3, height: s3, borderWidth: c3, animationPlayState: u3 }, t2[0] = c3, t2[1] = s3, t2[2] = u3, t2[3] = d3) : d3 = t2[3]; let f4 = d3, p4, m3; - if (t2[4] !== o3 || t2[5] !== l4) { - let e10 = { 0: { className: `sand-16rqkct sand-1y0btm7 sand-j6k430 sand-1gjmp7u sand-1so62im sand-r5sbw0 sand-1aquc0h sand-5orbwg sand-1esw782 sand-a4qsjk sand-1hc1fzr sand-11gebw9` }, 1: { className: `sand-16rqkct sand-1y0btm7 sand-1so62im sand-r5sbw0 sand-1aquc0h sand-5orbwg sand-1esw782 sand-a4qsjk sand-1hc1fzr sand-11gebw9 sand-ihgi1t sand-9rovbz` } }[!!l4 << 0]; - p4 = true, m3 = $(o3, e10.className), t2[4] = o3, t2[5] = l4, t2[6] = p4, t2[7] = m3; + if (t2[4] !== o3 || t2[5] !== l5) { + let e39 = { 0: { className: `sand-16rqkct sand-1y0btm7 sand-j6k430 sand-1gjmp7u sand-1so62im sand-r5sbw0 sand-1aquc0h sand-5orbwg sand-1esw782 sand-a4qsjk sand-1hc1fzr sand-11gebw9` }, 1: { className: `sand-16rqkct sand-1y0btm7 sand-1so62im sand-r5sbw0 sand-1aquc0h sand-5orbwg sand-1esw782 sand-a4qsjk sand-1hc1fzr sand-11gebw9 sand-ihgi1t sand-9rovbz` } }[!!l5 << 0]; + p4 = true, m3 = $2(o3, e39.className), t2[4] = o3, t2[5] = l5, t2[6] = p4, t2[7] = m3; } else p4 = t2[6], m3 = t2[7]; - let h3; - return t2[8] !== f4 || t2[9] !== p4 || t2[10] !== m3 ? (h3 = (0, Y2.jsx)(`span`, { "aria-hidden": p4, className: m3, style: f4 }), t2[8] = f4, t2[9] = p4, t2[10] = m3, t2[11] = h3) : h3 = t2[11], h3; -} -var AC = { root: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kOIVth: `sand-1jnr06f`, kmuXW: `sand-2lah0s`, kB7OPa: `sand-9f619`, kMzoRj: `sand-c342km`, ksu8eU: `sand-ng3xce`, kMv6JI: `sand-jb2p0i`, khDVqt: `sand-uxw1ft`, kkrTdU: `sand-1ypdohk sand-tgyt42`, k1ekBW: `sand-s2xxs2`, kIyJzY: `sand-1firant`, kAMwcw: `sand-9lcvmn`, $$css: true }, sizeMd: { kLKAdn: `sand-1yrsyyn`, kwRFfy: `sand-pdmqnj`, kGO01o: `sand-10b6aqq`, kZCmMZ: `sand-1g0dm76`, kaIpWk: `sand-149ho13`, $$css: true }, sizeSm: { kLKAdn: `sand-1iorvi4`, kwRFfy: `sand-f159sx`, kGO01o: `sand-jkvuk6`, kZCmMZ: `sand-mzvs34`, kaIpWk: `sand-149ho13`, $$css: true }, sizeLg: { kLKAdn: `sand-1y1aw1k`, kwRFfy: `sand-v54qhq`, kGO01o: `sand-wib8y2`, kZCmMZ: `sand-f7dkkf`, kaIpWk: `sand-149ho13`, $$css: true }, neutralPrimary: { kWkggS: `sand-8rotk8 sand-1sxibbd sand-1ialtwx`, kMwMTN: `sand-sa7k8x sand-g7klql`, $$css: true }, neutralSecondary: { kWkggS: `sand-fwqdrz sand-19jy9ex sand-1g6zli8`, kMwMTN: `sand-tyxrsu sand-g7klql`, $$css: true }, neutralTertiary: { kWkggS: `sand-jbqb8w sand-1ecwv3n sand-1oqui1x`, kMwMTN: `sand-tyxrsu sand-g7klql`, $$css: true }, accentPrimary: { kWkggS: `sand-1cgqir sand-1moagsb sand-jhkic0`, kMwMTN: `sand-xcaa6e sand-1q1osl5`, $$css: true }, accentSecondary: { kWkggS: `sand-13jhjah sand-dkb2vs sand-15igvbc`, kMwMTN: `sand-10kc733 sand-usva8a`, $$css: true }, accentTertiary: { kWkggS: `sand-jbqb8w sand-17cq1yh sand-1oqui1x`, kMwMTN: `sand-10kc733 sand-usva8a`, $$css: true }, dangerPrimary: { kWkggS: `sand-vopzge sand-a9ymcb sand-bmovrx`, kMwMTN: `sand-xcaa6e sand-5zuve2`, $$css: true }, dangerSecondary: { kWkggS: `sand-jt6epu sand-78epwt sand-rf7kli`, kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true }, dangerTertiary: { kWkggS: `sand-jbqb8w sand-q63dn4 sand-1oqui1x`, kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true }, warningPrimary: { kWkggS: `sand-7z33ko sand-6bhftj sand-1a0yh0o`, kMwMTN: `sand-xcaa6e sand-1dim673`, $$css: true }, warningSecondary: { kWkggS: `sand-1ii9591 sand-1ra2h21 sand-a3pd6v`, kMwMTN: `sand-impobl sand-1dim673`, $$css: true }, warningTertiary: { kWkggS: `sand-jbqb8w sand-1swc454 sand-1oqui1x`, kMwMTN: `sand-impobl sand-1dim673`, $$css: true }, pendingNeutralInk: { kMwMTN: `sand-1xejm7d`, $$css: true }, pendingAccentInk: { kMwMTN: `sand-b5j4bo`, $$css: true }, pendingOnAccentInk: { kMwMTN: `sand-23x1m`, $$css: true }, pendingDangerInk: { kMwMTN: `sand-11zc032`, $$css: true }, pendingWarningInk: { kMwMTN: `sand-1pdghxg`, $$css: true }, pendingWarningPrimaryInk: { kMwMTN: `sand-1dl01wj`, $$css: true }, cardLabel: { k63SB2: `sand-1rhlpx6`, $$css: true }, cardPrimaryDisabled: { kMwMTN: `sand-sa7k8x`, kGVxlE: `sand-pmb8bl`, $$css: true }, cardPrimaryPending: { kGVxlE: `sand-pmb8bl`, $$css: true }, cardPress: { kKwaWg: `sand-fxdvfh`, $$css: true }, cardPendingFrame: { kVAEAm: `sand-1n2onr6`, $$css: true }, cardPendingContent: { kSiTet: `sand-g01cxk`, $$css: true } }; -var eNe = { neutral: { primary: AC.neutralPrimary, secondary: AC.neutralSecondary, tertiary: AC.neutralTertiary }, accent: { primary: AC.accentPrimary, secondary: AC.accentSecondary, tertiary: AC.accentTertiary }, danger: { primary: AC.dangerPrimary, secondary: AC.dangerSecondary, tertiary: AC.dangerTertiary }, warning: { primary: AC.warningPrimary, secondary: AC.warningSecondary, tertiary: AC.warningTertiary } }; -var tNe = { sm: AC.sizeSm, md: AC.sizeMd, lg: AC.sizeLg }; -var nNe = { sm: 12, md: 12, lg: 14 }; -var rNe = 1.5; -var iNe = { className: `sand-10l6tqk sand-10a8y8t sand-78zum5 sand-6s0dn4 sand-l56j7k` }; -var aNe = { neutral: AC.pendingNeutralInk, accent: AC.pendingAccentInk, danger: AC.pendingDangerInk, warning: AC.pendingWarningInk }; -function oNe(e9, t2) { - return e9 === `accent` && t2 === `primary` ? AC.pendingOnAccentInk : e9 === `warning` && t2 === `primary` ? AC.pendingWarningPrimaryInk : aNe[e9]; -} -function jC(e9, t2, n2, r2) { - return e9 == null ? null : (0, Y2.jsx)(tC, { ...typeof e9 == `string` ? { name: e9 } : e9, size: n2 ?? (t2 === `lg` ? `md` : `sm`), style: r2 && AC.cardPendingContent }); -} -function MC(e9) { - MC.d = 2092; - let t2 = (0, Z2.c)(63), n2, r2, i3, a3, o3, s3, c2, l4, u3, d3, f4, p4, m3, h3; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c2 = t2[7], l4 = t2[8], u3 = t2[9], d3 = t2[10], f4 = t2[11], p4 = t2[12], m3 = t2[13], h3 = t2[14]) : ({ children: n2, sentiment: l4, variant: u3, size: d3, pending: f4, leadingIcon: a3, trailingIcon: h3, iconSize: i3, className: r2, style: c2, ref: o3, type: p4, disabled: m3, ...s3 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c2, t2[8] = l4, t2[9] = u3, t2[10] = d3, t2[11] = f4, t2[12] = p4, t2[13] = m3, t2[14] = h3); - let g3 = l4 === void 0 ? `neutral` : l4, _2 = u3 === void 0 ? `primary` : u3, v3 = d3 === void 0 ? `md` : d3, y3 = f4 !== void 0 && f4, b3 = p4 === void 0 ? `button` : p4, x3 = m3 !== void 0 && m3, S3 = fC() === `elevated`, C2 = S3 && g3 === `neutral` && _2 === `primary`, w3 = S3 && y3, T3, E3, D2, O3; - t2[15] !== r2 || t2[16] !== x3 || t2[17] !== C2 || t2[18] !== S3 || t2[19] !== w3 || t2[20] !== y3 || t2[21] !== s3 || t2[22] !== g3 || t2[23] !== v3 || t2[24] !== c2 || t2[25] !== _2 ? (T3 = h(AC.root, rC.controlRing, v3 === `sm` ? sx.label : sx.body1, tNe[v3], eNe[g3][_2], y3 && oNe(g3, _2), S3 && _2 !== `tertiary` && AC.cardLabel, C2 && x3 && !y3 && AC.cardPrimaryDisabled, C2 && y3 && AC.cardPrimaryPending, S3 && AC.cardPress, w3 && AC.cardPendingFrame, c2), E3 = s3, D2 = y3 || void 0, O3 = $(`sand-kit-button`, T3.className, r2), t2[15] = r2, t2[16] = x3, t2[17] = C2, t2[18] = S3, t2[19] = w3, t2[20] = y3, t2[21] = s3, t2[22] = g3, t2[23] = v3, t2[24] = c2, t2[25] = _2, t2[26] = T3, t2[27] = E3, t2[28] = D2, t2[29] = O3) : (T3 = t2[26], E3 = t2[27], D2 = t2[28], O3 = t2[29]); - let k4 = x3 || y3, A3 = T3.style, j3; - t2[30] !== i3 || t2[31] !== w3 || t2[32] !== a3 || t2[33] !== v3 ? (j3 = jC(a3, v3, i3, w3), t2[30] = i3, t2[31] = w3, t2[32] = a3, t2[33] = v3, t2[34] = j3) : j3 = t2[34]; - let M3; - t2[35] === w3 ? M3 = t2[36] : (M3 = { 0: { className: `sand-euugli sand-b3r6kr sand-lyipyv` }, 1: { className: `sand-euugli sand-b3r6kr sand-lyipyv sand-g01cxk` } }[!!w3 << 0], t2[35] = w3, t2[36] = M3); - let N2; - t2[37] !== n2 || t2[38] !== M3.className ? (N2 = (0, Y2.jsx)(`span`, { className: M3.className, children: n2 }), t2[37] = n2, t2[38] = M3.className, t2[39] = N2) : N2 = t2[39]; - let P2; - t2[40] !== i3 || t2[41] !== w3 || t2[42] !== v3 || t2[43] !== h3 ? (P2 = jC(h3, v3, i3, w3), t2[40] = i3, t2[41] = w3, t2[42] = v3, t2[43] = h3, t2[44] = P2) : P2 = t2[44]; + let h4; + return t2[8] !== f4 || t2[9] !== p4 || t2[10] !== m3 ? (h4 = (0, Y3.jsx)(`span`, { "aria-hidden": p4, className: m3, style: f4 }), t2[8] = f4, t2[9] = p4, t2[10] = m3, t2[11] = h4) : h4 = t2[11], h4; +} +var FS = { root: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kOIVth: `sand-1jnr06f`, kmuXW: `sand-2lah0s`, kB7OPa: `sand-9f619`, kMzoRj: `sand-c342km`, ksu8eU: `sand-ng3xce`, kMv6JI: `sand-jb2p0i`, khDVqt: `sand-uxw1ft`, kkrTdU: `sand-1ypdohk sand-tgyt42`, k1ekBW: `sand-s2xxs2`, kIyJzY: `sand-1firant`, kAMwcw: `sand-9lcvmn`, $$css: true }, sizeMd: { kLKAdn: `sand-1yrsyyn`, kwRFfy: `sand-pdmqnj`, kGO01o: `sand-10b6aqq`, kZCmMZ: `sand-1g0dm76`, kaIpWk: `sand-149ho13`, $$css: true }, sizeSm: { kLKAdn: `sand-1iorvi4`, kwRFfy: `sand-f159sx`, kGO01o: `sand-jkvuk6`, kZCmMZ: `sand-mzvs34`, kaIpWk: `sand-149ho13`, $$css: true }, sizeLg: { kLKAdn: `sand-1y1aw1k`, kwRFfy: `sand-v54qhq`, kGO01o: `sand-wib8y2`, kZCmMZ: `sand-f7dkkf`, kaIpWk: `sand-149ho13`, $$css: true }, neutralPrimary: { kWkggS: `sand-8rotk8 sand-1sxibbd sand-1ialtwx`, kMwMTN: `sand-sa7k8x sand-g7klql`, $$css: true }, neutralSecondary: { kWkggS: `sand-fwqdrz sand-19jy9ex sand-1g6zli8`, kMwMTN: `sand-tyxrsu sand-g7klql`, $$css: true }, neutralTertiary: { kWkggS: `sand-jbqb8w sand-1ecwv3n sand-1oqui1x`, kMwMTN: `sand-tyxrsu sand-g7klql`, $$css: true }, accentPrimary: { kWkggS: `sand-1cgqir sand-1moagsb sand-jhkic0`, kMwMTN: `sand-xcaa6e sand-1q1osl5`, $$css: true }, accentSecondary: { kWkggS: `sand-13jhjah sand-dkb2vs sand-15igvbc`, kMwMTN: `sand-10kc733 sand-usva8a`, $$css: true }, accentTertiary: { kWkggS: `sand-jbqb8w sand-17cq1yh sand-1oqui1x`, kMwMTN: `sand-10kc733 sand-usva8a`, $$css: true }, dangerPrimary: { kWkggS: `sand-vopzge sand-a9ymcb sand-bmovrx`, kMwMTN: `sand-xcaa6e sand-5zuve2`, $$css: true }, dangerSecondary: { kWkggS: `sand-jt6epu sand-78epwt sand-rf7kli`, kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true }, dangerTertiary: { kWkggS: `sand-jbqb8w sand-q63dn4 sand-1oqui1x`, kMwMTN: `sand-i69oq4 sand-5zuve2`, $$css: true }, warningPrimary: { kWkggS: `sand-7z33ko sand-6bhftj sand-1a0yh0o`, kMwMTN: `sand-xcaa6e sand-1dim673`, $$css: true }, warningSecondary: { kWkggS: `sand-1ii9591 sand-1ra2h21 sand-a3pd6v`, kMwMTN: `sand-impobl sand-1dim673`, $$css: true }, warningTertiary: { kWkggS: `sand-jbqb8w sand-1swc454 sand-1oqui1x`, kMwMTN: `sand-impobl sand-1dim673`, $$css: true }, pendingNeutralInk: { kMwMTN: `sand-1xejm7d`, $$css: true }, pendingAccentInk: { kMwMTN: `sand-b5j4bo`, $$css: true }, pendingOnAccentInk: { kMwMTN: `sand-23x1m`, $$css: true }, pendingDangerInk: { kMwMTN: `sand-11zc032`, $$css: true }, pendingWarningInk: { kMwMTN: `sand-1pdghxg`, $$css: true }, pendingWarningPrimaryInk: { kMwMTN: `sand-1dl01wj`, $$css: true }, cardLabel: { k63SB2: `sand-1rhlpx6`, $$css: true }, cardPrimaryDisabled: { kMwMTN: `sand-sa7k8x`, kGVxlE: `sand-pmb8bl`, $$css: true }, cardPrimaryPending: { kGVxlE: `sand-pmb8bl`, $$css: true }, cardPress: { kKwaWg: `sand-fxdvfh`, $$css: true }, cardPendingFrame: { kVAEAm: `sand-1n2onr6`, $$css: true }, cardPendingContent: { kSiTet: `sand-g01cxk`, $$css: true } }; +var fLe = { neutral: { primary: FS.neutralPrimary, secondary: FS.neutralSecondary, tertiary: FS.neutralTertiary }, accent: { primary: FS.accentPrimary, secondary: FS.accentSecondary, tertiary: FS.accentTertiary }, danger: { primary: FS.dangerPrimary, secondary: FS.dangerSecondary, tertiary: FS.dangerTertiary }, warning: { primary: FS.warningPrimary, secondary: FS.warningSecondary, tertiary: FS.warningTertiary } }; +var pLe = { sm: FS.sizeSm, md: FS.sizeMd, lg: FS.sizeLg }; +var mLe = { sm: 12, md: 12, lg: 14 }; +var hLe = 1.5; +var gLe = { className: `sand-10l6tqk sand-10a8y8t sand-78zum5 sand-6s0dn4 sand-l56j7k` }; +var _Le = { neutral: FS.pendingNeutralInk, accent: FS.pendingAccentInk, danger: FS.pendingDangerInk, warning: FS.pendingWarningInk }; +function vLe(e38, t2) { + return e38 === `accent` && t2 === `primary` ? FS.pendingOnAccentInk : e38 === `warning` && t2 === `primary` ? FS.pendingWarningPrimaryInk : _Le[e38]; +} +function IS(e38, t2, n2, r2) { + return e38 == null ? null : (0, Y3.jsx)(aS, { ...typeof e38 == `string` ? { name: e38 } : e38, size: n2 ?? (t2 === `lg` ? `md` : `sm`), style: r2 && FS.cardPendingContent }); +} +function LS(e38) { + LS.d = 2367; + let t2 = (0, Z3.c)(63), n2, r2, i3, a3, o3, s3, c3, l5, u3, d3, f4, p4, m3, h4; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c3 = t2[7], l5 = t2[8], u3 = t2[9], d3 = t2[10], f4 = t2[11], p4 = t2[12], m3 = t2[13], h4 = t2[14]) : ({ children: n2, sentiment: l5, variant: u3, size: d3, pending: f4, leadingIcon: a3, trailingIcon: h4, iconSize: i3, className: r2, style: c3, ref: o3, type: p4, disabled: m3, ...s3 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c3, t2[8] = l5, t2[9] = u3, t2[10] = d3, t2[11] = f4, t2[12] = p4, t2[13] = m3, t2[14] = h4); + let g5 = l5 === void 0 ? `neutral` : l5, _5 = u3 === void 0 ? `primary` : u3, v5 = d3 === void 0 ? `md` : d3, y4 = f4 !== void 0 && f4, b2 = p4 === void 0 ? `button` : p4, x2 = m3 !== void 0 && m3, S2 = gS() === `elevated`, C2 = S2 && g5 === `neutral` && _5 === `primary`, w2 = S2 && y4, T2, E2, D2, O2; + t2[15] !== r2 || t2[16] !== x2 || t2[17] !== C2 || t2[18] !== S2 || t2[19] !== w2 || t2[20] !== y4 || t2[21] !== s3 || t2[22] !== g5 || t2[23] !== v5 || t2[24] !== c3 || t2[25] !== _5 ? (T2 = h(FS.root, sS.controlRing, v5 === `sm` ? Jb2.label : Jb2.body1, pLe[v5], fLe[g5][_5], y4 && vLe(g5, _5), S2 && _5 !== `tertiary` && FS.cardLabel, C2 && x2 && !y4 && FS.cardPrimaryDisabled, C2 && y4 && FS.cardPrimaryPending, S2 && FS.cardPress, w2 && FS.cardPendingFrame, c3), E2 = s3, D2 = y4 || void 0, O2 = $2(`sand-kit-button`, T2.className, r2), t2[15] = r2, t2[16] = x2, t2[17] = C2, t2[18] = S2, t2[19] = w2, t2[20] = y4, t2[21] = s3, t2[22] = g5, t2[23] = v5, t2[24] = c3, t2[25] = _5, t2[26] = T2, t2[27] = E2, t2[28] = D2, t2[29] = O2) : (T2 = t2[26], E2 = t2[27], D2 = t2[28], O2 = t2[29]); + let k2 = x2 || y4, A2 = T2.style, j2; + t2[30] !== i3 || t2[31] !== w2 || t2[32] !== a3 || t2[33] !== v5 ? (j2 = IS(a3, v5, i3, w2), t2[30] = i3, t2[31] = w2, t2[32] = a3, t2[33] = v5, t2[34] = j2) : j2 = t2[34]; + let M2; + t2[35] === w2 ? M2 = t2[36] : (M2 = { 0: { className: `sand-euugli sand-b3r6kr sand-lyipyv` }, 1: { className: `sand-euugli sand-b3r6kr sand-lyipyv sand-g01cxk` } }[!!w2 << 0], t2[35] = w2, t2[36] = M2); + let N3; + t2[37] !== n2 || t2[38] !== M2.className ? (N3 = (0, Y3.jsx)(`span`, { className: M2.className, children: n2 }), t2[37] = n2, t2[38] = M2.className, t2[39] = N3) : N3 = t2[39]; + let P3; + t2[40] !== i3 || t2[41] !== w2 || t2[42] !== v5 || t2[43] !== h4 ? (P3 = IS(h4, v5, i3, w2), t2[40] = i3, t2[41] = w2, t2[42] = v5, t2[43] = h4, t2[44] = P3) : P3 = t2[44]; let F2; - t2[45] !== w3 || t2[46] !== v3 ? (F2 = w3 ? (0, Y2.jsx)(`span`, { className: iNe.className, children: (0, Y2.jsx)(kC, { borderWidth: rNe, inheritColor: true, size: nNe[v3] }) }) : null, t2[45] = w3, t2[46] = v3, t2[47] = F2) : F2 = t2[47]; - let I; - return t2[48] !== T3.style || t2[49] !== o3 || t2[50] !== g3 || t2[51] !== v3 || t2[52] !== k4 || t2[53] !== j3 || t2[54] !== N2 || t2[55] !== P2 || t2[56] !== F2 || t2[57] !== E3 || t2[58] !== D2 || t2[59] !== O3 || t2[60] !== b3 || t2[61] !== _2 ? (I = (0, Y2.jsxs)(`button`, { ...E3, "aria-busy": D2, className: O3, "data-sentiment": g3, "data-size": v3, "data-variant": _2, disabled: k4, ref: o3, style: A3, type: b3, children: [j3, N2, P2, F2] }), t2[48] = T3.style, t2[49] = o3, t2[50] = g3, t2[51] = v3, t2[52] = k4, t2[53] = j3, t2[54] = N2, t2[55] = P2, t2[56] = F2, t2[57] = E3, t2[58] = D2, t2[59] = O3, t2[60] = b3, t2[61] = _2, t2[62] = I) : I = t2[62], I; + t2[45] !== w2 || t2[46] !== v5 ? (F2 = w2 ? (0, Y3.jsx)(`span`, { className: gLe.className, children: (0, Y3.jsx)(PS, { borderWidth: hLe, inheritColor: true, size: mLe[v5] }) }) : null, t2[45] = w2, t2[46] = v5, t2[47] = F2) : F2 = t2[47]; + let I2; + return t2[48] !== T2.style || t2[49] !== o3 || t2[50] !== g5 || t2[51] !== v5 || t2[52] !== k2 || t2[53] !== j2 || t2[54] !== N3 || t2[55] !== P3 || t2[56] !== F2 || t2[57] !== E2 || t2[58] !== D2 || t2[59] !== O2 || t2[60] !== b2 || t2[61] !== _5 ? (I2 = (0, Y3.jsxs)(`button`, { ...E2, "aria-busy": D2, className: O2, "data-sentiment": g5, "data-size": v5, "data-variant": _5, disabled: k2, ref: o3, style: A2, type: b2, children: [j2, N3, P3, F2] }), t2[48] = T2.style, t2[49] = o3, t2[50] = g5, t2[51] = v5, t2[52] = k2, t2[53] = j2, t2[54] = N3, t2[55] = P3, t2[56] = F2, t2[57] = E2, t2[58] = D2, t2[59] = O2, t2[60] = b2, t2[61] = _5, t2[62] = I2) : I2 = t2[62], I2; } -function NC(e9, t2) { +function RS(e38, t2) { let n2 = t2.map((t3) => { if (typeof t3 == `function`) { - let n3 = t3(e9); + let n3 = t3(e38); return typeof n3 == `function` ? n3 : () => t3(null); } return t3 == null ? () => { - } : (t3.current = e9, () => { + } : (t3.current = e38, () => { t3.current = null; }); }); return () => { - for (let e10 of n2) e10(); + for (let e39 of n2) e39(); }; } -var PC = []; -function FC(e9) { - let t2 = PC.indexOf(e9); - t2 >= 0 && PC.splice(t2, 1); +var zS = []; +function BS(e38) { + let t2 = zS.indexOf(e38); + t2 >= 0 && zS.splice(t2, 1); } -function IC() { - let e9 = {}; - return PC.push(e9), () => FC(e9); +function VS() { + let e38 = {}; + return zS.push(e38), () => BS(e38); } -var zC = [`sidebar`, `main`, `info-pane`]; -var uNe = /* @__PURE__ */ new Set(); -function dNe(e9, t2) { - if (e9.size !== t2.size) return false; - for (let n2 of e9) if (!t2.has(n2)) return false; +var WS = [`sidebar`, `main`, `info-pane`]; +var SLe = /* @__PURE__ */ new Set(); +function CLe(e38, t2) { + if (e38.size !== t2.size) return false; + for (let n2 of e38) if (!t2.has(n2)) return false; return true; } -var BC = new class { +var GS = new class { covers = /* @__PURE__ */ new Map(); - regions = Rn(uNe); + regions = qn2(SLe); hidden = /* @__PURE__ */ new Set(); interactiveWaiters = /* @__PURE__ */ new Map(); - cover(e9) { - let t2 = Symbol(e9.surface); - return this.covers.set(t2, e9), this.recompute(), () => { + cover(e38) { + let t2 = Symbol(e38.surface); + return this.covers.set(t2, e38), this.recompute(), () => { this.covers.delete(t2), this.recompute(); }; } covered() { return this.regions.get(); } - coveringSurfaces(e9) { - return Array.from(this.covers.values()).filter((t2) => t2.regions.has(e9)).map((e10) => e10.surface); + coveringSurfaces(e38) { + return Array.from(this.covers.values()).filter((t2) => t2.regions.has(e38)).map((e39) => e39.surface); } - subscribe(e9) { - return this.regions.subscribe(e9); + subscribe(e38) { + return this.regions.subscribe(e38); } - settle(e9, t2) { + settle(e38, t2) { if (t2) { - this.hidden.add(e9); + this.hidden.add(e38); return; } - this.hidden.delete(e9); - let n2 = this.interactiveWaiters.get(e9); + this.hidden.delete(e38); + let n2 = this.interactiveWaiters.get(e38); if (n2 != null) { - this.interactiveWaiters.delete(e9); - for (let e10 of n2) e10(); + this.interactiveWaiters.delete(e38); + for (let e39 of n2) e39(); } } - isHidden(e9) { - return this.hidden.has(e9); + isHidden(e38) { + return this.hidden.has(e38); } - whenInteractive(e9) { - return this.hidden.has(e9) ? new Promise((t2) => { - let n2 = this.interactiveWaiters.get(e9); - n2 == null ? this.interactiveWaiters.set(e9, [t2]) : n2.push(t2); + whenInteractive(e38) { + return this.hidden.has(e38) ? new Promise((t2) => { + let n2 = this.interactiveWaiters.get(e38); + n2 == null ? this.interactiveWaiters.set(e38, [t2]) : n2.push(t2); }) : Promise.resolve(); } recompute() { - let e9 = /* @__PURE__ */ new Set(); - for (let t2 of this.covers.values()) for (let n2 of t2.regions) e9.add(n2); - dNe(e9, this.regions.get()) || this.regions.set(e9); + let e38 = /* @__PURE__ */ new Set(); + for (let t2 of this.covers.values()) for (let n2 of t2.regions) e38.add(n2); + CLe(e38, this.regions.get()) || this.regions.set(e38); } }(); -var $C = { surface: { k3aq6I: `sand-11lhmoz`, kB7OPa: `sand-9f619`, kskxy: `sand-qyufaf`, "--sand-status-dot-ring": `sand-u366gq`, $$css: true }, backdrop: { kWkggS: `sand-azoy5u`, $$css: true }, still: { kKVMdj: `sand-1a5igra`, $$css: true } }; -function ew(e9, t2) { - if (typeof e9 == `function`) { - let n2 = e9(t2); +var aC = { surface: { k3aq6I: `sand-11lhmoz`, kB7OPa: `sand-9f619`, kskxy: `sand-qyufaf`, "--sand-status-dot-ring": `sand-u366gq`, $$css: true }, backdrop: { kWkggS: `sand-azoy5u`, $$css: true }, still: { kKVMdj: `sand-1a5igra`, $$css: true } }; +function oC(e38, t2) { + if (typeof e38 == `function`) { + let n2 = e38(t2); return typeof n2 == `function` ? n2 : void 0; } - e9 != null && (e9.current = t2); -} -var CNe = new Set(zC); -function tw(e9) { - tw.d = 2159; - let t2 = (0, Z2.c)(26), n2, r2, i3, a3, o3; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5]) : ({ backdropStylexStyles: n2, rootStylexStyles: a3, isAnimated: o3, ref: r2, ...i3 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3); - let s3 = o3 !== void 0 && o3, c2 = i3.modal !== false, l4; - t2[6] === i3 ? l4 = t2[7] : (l4 = () => i3.className ?? i3[`aria-label`] ?? `dialog`, t2[6] = i3, t2[7] = l4); - let [u3] = (0, X2.useState)(l4), d3; - t2[8] !== c2 || t2[9] !== r2 || t2[10] !== u3 ? (d3 = (e10) => { - if (e10 == null) { - ew(r2, null); + e38 != null && (e38.current = t2); +} +var ILe = new Set(WS); +function sC(e38) { + sC.d = 2442; + let t2 = (0, Z3.c)(26), n2, r2, i3, a3, o3; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5]) : ({ backdropStylexStyles: n2, rootStylexStyles: a3, isAnimated: o3, ref: r2, ...i3 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3); + let s3 = o3 !== void 0 && o3, c3 = i3.modal !== false, l5; + t2[6] === i3 ? l5 = t2[7] : (l5 = () => i3.className ?? i3[`aria-label`] ?? `dialog`, t2[6] = i3, t2[7] = l5); + let [u3] = (0, X3.useState)(l5), d3; + t2[8] !== c3 || t2[9] !== r2 || t2[10] !== u3 ? (d3 = (e39) => { + if (e39 == null) { + oC(r2, null); return; } - let t3 = IC(), n3 = c2 ? BC.cover({ surface: u3, regions: CNe }) : void 0, i4 = ew(r2, e10); + let t3 = VS(), n3 = c3 ? GS.cover({ surface: u3, regions: ILe }) : void 0, i4 = oC(r2, e39); return () => { - n3?.(), t3(), i4 == null ? ew(r2, null) : i4(); + n3?.(), t3(), i4 == null ? oC(r2, null) : i4(); }; - }, t2[8] = c2, t2[9] = r2, t2[10] = u3, t2[11] = d3) : d3 = t2[11]; - let f4 = d3, p4 = !s3 && $C.still, m3; - t2[12] !== n2 || t2[13] !== p4 ? (m3 = [$C.backdrop, p4, n2], t2[12] = n2, t2[13] = p4, t2[14] = m3) : m3 = t2[14]; - let h3 = !s3 && $C.still, g3; - t2[15] !== a3 || t2[16] !== h3 ? (g3 = [$C.surface, h3, a3], t2[15] = a3, t2[16] = h3, t2[17] = g3) : g3 = t2[17]; - let _2; - t2[18] === s3 ? _2 = t2[19] : (_2 = s3 ? {} : { transitionDuration: 0 }, t2[18] = s3, t2[19] = _2); - let v3; - return t2[20] !== f4 || t2[21] !== i3 || t2[22] !== m3 || t2[23] !== g3 || t2[24] !== _2 ? (v3 = (0, Y2.jsx)(Fp2, { ...i3, backdropStylexStyles: m3, lockScroll: false, ref: f4, rootStylexStyles: g3, ..._2 }), t2[20] = f4, t2[21] = i3, t2[22] = m3, t2[23] = g3, t2[24] = _2, t2[25] = v3) : v3 = t2[25], v3; -} -var nw = Object.assign(tw, Fp2); -var rw = (0, X2.createContext)(`simple`); -var iw = (0, X2.createContext)(false); -var aw = (0, X2.createContext)(false); -var ow = (0, X2.createContext)(null); -var sw = { surface: { kaIpWk: `sand-ixl9f9`, kEafiO: `sand-1hc762m`, kPef9Z: `sand-13fuv20`, kLZC3w: `sand-13nz628`, ke9TFa: `sand-qm0940`, k8ry5P: `sand-18b5jzi`, kBCPoo: `sand-bp68ws`, kt9PQ7: `sand-1hkp6id`, kfdmCh: `sand-1q0q8m5`, kL6WhQ: `sand-1vu50b0`, k2ei4v: `sand-1sd92yl`, kVhnKS: `sand-1t7ytsu`, kGJrpR: `sand-5x6ma4`, $$css: true }, scrim: { kWkggS: `sand-azoy5u`, $$css: true }, scrimSolid: { kWkggS: `sand-1r1mewj`, $$css: true }, width320: { kzqmXN: `sand-1dxpara`, $$css: true }, width360: { kzqmXN: `sand-1ove4c`, $$css: true }, width380: { kzqmXN: `sand-11f3qql`, $$css: true }, width400: { kzqmXN: `sand-btpsn6`, $$css: true }, width420: { kzqmXN: `sand-8xl5fk`, $$css: true }, width432: { kzqmXN: `sand-glnbif`, $$css: true }, width440: { kzqmXN: `sand-cyy4kf`, $$css: true }, width460: { kzqmXN: `sand-jbg27m`, $$css: true }, width480: { kzqmXN: `sand-sjcku0`, $$css: true }, width500: { kzqmXN: `sand-mk5fll`, $$css: true }, width520: { kzqmXN: `sand-v9tjks`, $$css: true }, width608: { kzqmXN: `sand-pf5iwd`, $$css: true }, widthWide: { kzqmXN: `sand-1xakwtq`, $$css: true }, header: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kGNEyG: `sand-1cy8zhl`, kOIVth: `sand-1jnr06f`, kmuXW: `sand-2lah0s`, kB7OPa: `sand-9f619`, kLKAdn: `sand-z9dl7a`, kwRFfy: `sand-v54qhq`, kGO01o: `sand-sag5q8`, kZCmMZ: `sand-f7dkkf`, $$css: true }, headerRich: { kLKAdn: `sand-yamay9`, kGO01o: `sand-1l90r2v`, kt9PQ7: `sand-1co6499`, kfdmCh: `sand-1q0q8m5`, kL6WhQ: `sand-1vu50b0`, $$css: true }, insetWide: { kZCmMZ: `sand-92arao`, kwRFfy: `sand-1bk0ktj`, $$css: true }, actionsWide: { kZCmMZ: `sand-92arao`, kwRFfy: `sand-16mtmbo`, $$css: true }, textBlock: { keoZOQ: `sand-dj266r`, k71WvV: `sand-14z9mp`, k1K539: `sand-at24cr`, keTefX: `sand-1lziwak`, kHjlTd: `sand-1mzt3pk`, $$css: true }, body: { kAzted: `sand-2lwn1j`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-v54qhq`, kGO01o: `sand-1l90r2v`, kZCmMZ: `sand-f7dkkf`, $$css: true }, bodyRich: { kLKAdn: `sand-yamay9`, $$css: true }, actions: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-13a6bvl`, kOIVth: `sand-167g77z`, kmuXW: `sand-2lah0s`, kB7OPa: `sand-9f619`, kLKAdn: `sand-z9dl7a`, kwRFfy: `sand-pdmqnj`, kGO01o: `sand-sag5q8`, kZCmMZ: `sand-f7dkkf`, $$css: true }, actionsRich: { kEafiO: `sand-t8cgyo`, kPef9Z: `sand-13fuv20`, kLZC3w: `sand-13nz628`, $$css: true }, actionResponsive: { kzQI83: `sand-1iyjqo2`, kmuXW: `sand-2lah0s`, $$css: true }, close: { kzqmXN: `sand-mjrt60`, kZKoxP: `sand-t8t6p`, k7Eaqz: `sand-ma39wp`, kAzted: `sand-phwom3`, $$css: true } }; -var wNe = { 320: sw.width320, 360: sw.width360, 380: sw.width380, 400: sw.width400, 420: sw.width420, 432: sw.width432, 440: sw.width440, 460: sw.width460, 480: sw.width480, 500: sw.width500, 520: sw.width520, 608: sw.width608, wide: sw.widthWide }; -function cw(e9) { - cw.d = 2177; - let t2 = (0, Z2.c)(41), n2, r2, i3, a3, o3, s3, c2, l4, u3, d3; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c2 = t2[7], l4 = t2[8], u3 = t2[9], d3 = t2[10]) : ({ variant: l4, scrim: u3, width: d3, initialFocus: o3, surfaceStyle: c2, backdropStyle: r2, children: i3, className: a3, backdropClassName: n2, ...s3 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c2, t2[8] = l4, t2[9] = u3, t2[10] = d3); - let f4 = l4 === void 0 ? `simple` : l4, p4 = u3 === void 0 ? `default` : u3, m3 = (0, X2.useRef)(null), h3 = o3 === `primary-action`, g3 = h3 ? m3 : o3, _2; - t2[11] === g3 ? _2 = t2[12] : (_2 = g3 == null ? {} : { initialFocus: g3 }, t2[11] = g3, t2[12] = _2); - let v3; - t2[13] === n2 ? v3 = t2[14] : (v3 = $(`sand-dialog__scrim`, n2), t2[13] = n2, t2[14] = v3); - let y3 = p4 === `solid` && sw.scrimSolid, b3; - t2[15] !== r2 || t2[16] !== y3 ? (b3 = [r2, sw.scrim, y3], t2[15] = r2, t2[16] = y3, t2[17] = b3) : b3 = t2[17]; - let x3; - t2[18] === a3 ? x3 = t2[19] : (x3 = $(`sand-dialog`, a3), t2[18] = a3, t2[19] = x3); - let S3 = wNe[d3], C2; - t2[20] !== c2 || t2[21] !== S3 ? (C2 = [sw.surface, S3, c2], t2[20] = c2, t2[21] = S3, t2[22] = C2) : C2 = t2[22]; - let w3 = d3 === `wide`, T3 = h3 ? m3 : null, E3; - t2[23] !== i3 || t2[24] !== T3 ? (E3 = (0, Y2.jsx)(ow.Provider, { value: T3, children: i3 }), t2[23] = i3, t2[24] = T3, t2[25] = E3) : E3 = t2[25]; + }, t2[8] = c3, t2[9] = r2, t2[10] = u3, t2[11] = d3) : d3 = t2[11]; + let f4 = d3, p4 = !s3 && aC.still, m3; + t2[12] !== n2 || t2[13] !== p4 ? (m3 = [aC.backdrop, p4, n2], t2[12] = n2, t2[13] = p4, t2[14] = m3) : m3 = t2[14]; + let h4 = !s3 && aC.still, g5; + t2[15] !== a3 || t2[16] !== h4 ? (g5 = [aC.surface, h4, a3], t2[15] = a3, t2[16] = h4, t2[17] = g5) : g5 = t2[17]; + let _5; + t2[18] === s3 ? _5 = t2[19] : (_5 = s3 ? {} : { transitionDuration: 0 }, t2[18] = s3, t2[19] = _5); + let v5; + return t2[20] !== f4 || t2[21] !== i3 || t2[22] !== m3 || t2[23] !== g5 || t2[24] !== _5 ? (v5 = (0, Y3.jsx)(xm2, { ...i3, backdropStylexStyles: m3, lockScroll: false, ref: f4, rootStylexStyles: g5, ..._5 }), t2[20] = f4, t2[21] = i3, t2[22] = m3, t2[23] = g5, t2[24] = _5, t2[25] = v5) : v5 = t2[25], v5; +} +var cC = Object.assign(sC, xm2); +var lC = (0, X3.createContext)(`simple`); +var uC = (0, X3.createContext)(false); +var dC = (0, X3.createContext)(false); +var fC = (0, X3.createContext)(null); +var pC = { surface: { kaIpWk: `sand-ixl9f9`, kEafiO: `sand-1hc762m`, kPef9Z: `sand-13fuv20`, kLZC3w: `sand-13nz628`, ke9TFa: `sand-qm0940`, k8ry5P: `sand-18b5jzi`, kBCPoo: `sand-bp68ws`, kt9PQ7: `sand-1hkp6id`, kfdmCh: `sand-1q0q8m5`, kL6WhQ: `sand-1vu50b0`, k2ei4v: `sand-1sd92yl`, kVhnKS: `sand-1t7ytsu`, kGJrpR: `sand-5x6ma4`, $$css: true }, scrim: { kWkggS: `sand-azoy5u`, $$css: true }, scrimSolid: { kWkggS: `sand-1r1mewj`, $$css: true }, width320: { kzqmXN: `sand-1dxpara`, $$css: true }, width360: { kzqmXN: `sand-1ove4c`, $$css: true }, width380: { kzqmXN: `sand-11f3qql`, $$css: true }, width400: { kzqmXN: `sand-btpsn6`, $$css: true }, width420: { kzqmXN: `sand-8xl5fk`, $$css: true }, width432: { kzqmXN: `sand-glnbif`, $$css: true }, width440: { kzqmXN: `sand-cyy4kf`, $$css: true }, width460: { kzqmXN: `sand-jbg27m`, $$css: true }, width480: { kzqmXN: `sand-sjcku0`, $$css: true }, width500: { kzqmXN: `sand-mk5fll`, $$css: true }, width520: { kzqmXN: `sand-v9tjks`, $$css: true }, width608: { kzqmXN: `sand-pf5iwd`, $$css: true }, widthWide: { kzqmXN: `sand-1xakwtq`, $$css: true }, header: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kGNEyG: `sand-1cy8zhl`, kOIVth: `sand-1jnr06f`, kmuXW: `sand-2lah0s`, kB7OPa: `sand-9f619`, kLKAdn: `sand-z9dl7a`, kwRFfy: `sand-v54qhq`, kGO01o: `sand-sag5q8`, kZCmMZ: `sand-f7dkkf`, $$css: true }, headerRich: { kLKAdn: `sand-yamay9`, kGO01o: `sand-1l90r2v`, kt9PQ7: `sand-1co6499`, kfdmCh: `sand-1q0q8m5`, kL6WhQ: `sand-1vu50b0`, $$css: true }, insetWide: { kZCmMZ: `sand-92arao`, kwRFfy: `sand-1bk0ktj`, $$css: true }, actionsWide: { kZCmMZ: `sand-92arao`, kwRFfy: `sand-16mtmbo`, $$css: true }, textBlock: { keoZOQ: `sand-dj266r`, k71WvV: `sand-14z9mp`, k1K539: `sand-at24cr`, keTefX: `sand-1lziwak`, kHjlTd: `sand-1mzt3pk`, $$css: true }, body: { kAzted: `sand-2lwn1j`, kLKAdn: `sand-exx8yu`, kwRFfy: `sand-v54qhq`, kGO01o: `sand-1l90r2v`, kZCmMZ: `sand-f7dkkf`, $$css: true }, bodyRich: { kLKAdn: `sand-yamay9`, $$css: true }, actions: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-13a6bvl`, kOIVth: `sand-167g77z`, kmuXW: `sand-2lah0s`, kB7OPa: `sand-9f619`, kLKAdn: `sand-z9dl7a`, kwRFfy: `sand-pdmqnj`, kGO01o: `sand-sag5q8`, kZCmMZ: `sand-f7dkkf`, $$css: true }, actionsRich: { kEafiO: `sand-t8cgyo`, kPef9Z: `sand-13fuv20`, kLZC3w: `sand-13nz628`, $$css: true }, actionResponsive: { kzQI83: `sand-1iyjqo2`, kmuXW: `sand-2lah0s`, $$css: true }, close: { kzqmXN: `sand-mjrt60`, kZKoxP: `sand-t8t6p`, k7Eaqz: `sand-ma39wp`, kAzted: `sand-phwom3`, $$css: true } }; +var LLe = { 320: pC.width320, 360: pC.width360, 380: pC.width380, 400: pC.width400, 420: pC.width420, 432: pC.width432, 440: pC.width440, 460: pC.width460, 480: pC.width480, 500: pC.width500, 520: pC.width520, 608: pC.width608, wide: pC.widthWide }; +function mC(e38) { + mC.d = 2461; + let t2 = (0, Z3.c)(41), n2, r2, i3, a3, o3, s3, c3, l5, u3, d3; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c3 = t2[7], l5 = t2[8], u3 = t2[9], d3 = t2[10]) : ({ variant: l5, scrim: u3, width: d3, initialFocus: o3, surfaceStyle: c3, backdropStyle: r2, children: i3, className: a3, backdropClassName: n2, ...s3 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c3, t2[8] = l5, t2[9] = u3, t2[10] = d3); + let f4 = l5 === void 0 ? `simple` : l5, p4 = u3 === void 0 ? `default` : u3, m3 = (0, X3.useRef)(null), h4 = o3 === `primary-action`, g5 = h4 ? m3 : o3, _5; + t2[11] === g5 ? _5 = t2[12] : (_5 = g5 == null ? {} : { initialFocus: g5 }, t2[11] = g5, t2[12] = _5); + let v5; + t2[13] === n2 ? v5 = t2[14] : (v5 = $2(`sand-dialog__scrim`, n2), t2[13] = n2, t2[14] = v5); + let y4 = p4 === `solid` && pC.scrimSolid, b2; + t2[15] !== r2 || t2[16] !== y4 ? (b2 = [r2, pC.scrim, y4], t2[15] = r2, t2[16] = y4, t2[17] = b2) : b2 = t2[17]; + let x2; + t2[18] === a3 ? x2 = t2[19] : (x2 = $2(`sand-dialog`, a3), t2[18] = a3, t2[19] = x2); + let S2 = LLe[d3], C2; + t2[20] !== c3 || t2[21] !== S2 ? (C2 = [pC.surface, S2, c3], t2[20] = c3, t2[21] = S2, t2[22] = C2) : C2 = t2[22]; + let w2 = d3 === `wide`, T2 = h4 ? m3 : null, E2; + t2[23] !== i3 || t2[24] !== T2 ? (E2 = (0, Y3.jsx)(fC.Provider, { value: T2, children: i3 }), t2[23] = i3, t2[24] = T2, t2[25] = E2) : E2 = t2[25]; let D2; - t2[26] !== w3 || t2[27] !== E3 ? (D2 = (0, Y2.jsx)(iw.Provider, { value: w3, children: E3 }), t2[26] = w3, t2[27] = E3, t2[28] = D2) : D2 = t2[28]; - let O3; - t2[29] !== D2 || t2[30] !== f4 ? (O3 = (0, Y2.jsx)(rw.Provider, { value: f4, children: D2 }), t2[29] = D2, t2[30] = f4, t2[31] = O3) : O3 = t2[31]; - let k4; - return t2[32] !== s3 || t2[33] !== O3 || t2[34] !== _2 || t2[35] !== v3 || t2[36] !== b3 || t2[37] !== x3 || t2[38] !== C2 || t2[39] !== f4 ? (k4 = (0, Y2.jsx)(nw, { ...s3, ..._2, backdropClassName: v3, backdropStylexStyles: b3, className: x3, "data-presentation": f4, rootStylexStyles: C2, children: O3 }), t2[32] = s3, t2[33] = O3, t2[34] = _2, t2[35] = v3, t2[36] = b3, t2[37] = x3, t2[38] = C2, t2[39] = f4, t2[40] = k4) : k4 = t2[40], k4; -} -function lw(e9) { - lw.d = 2176; - let t2 = (0, Z2.c)(7), { children: n2, style: r2 } = e9, i3 = (0, X2.useContext)(rw), a3 = (0, X2.useContext)(iw), o3; - t2[0] !== a3 || t2[1] !== r2 || t2[2] !== i3 ? (o3 = h(sw.header, i3 === `rich` && sw.headerRich, a3 && sw.insetWide, r2), t2[0] = a3, t2[1] = r2, t2[2] = i3, t2[3] = o3) : o3 = t2[3]; + t2[26] !== w2 || t2[27] !== E2 ? (D2 = (0, Y3.jsx)(uC.Provider, { value: w2, children: E2 }), t2[26] = w2, t2[27] = E2, t2[28] = D2) : D2 = t2[28]; + let O2; + t2[29] !== D2 || t2[30] !== f4 ? (O2 = (0, Y3.jsx)(lC.Provider, { value: f4, children: D2 }), t2[29] = D2, t2[30] = f4, t2[31] = O2) : O2 = t2[31]; + let k2; + return t2[32] !== s3 || t2[33] !== O2 || t2[34] !== _5 || t2[35] !== v5 || t2[36] !== b2 || t2[37] !== x2 || t2[38] !== C2 || t2[39] !== f4 ? (k2 = (0, Y3.jsx)(cC, { ...s3, ..._5, backdropClassName: v5, backdropStylexStyles: b2, className: x2, "data-presentation": f4, rootStylexStyles: C2, children: O2 }), t2[32] = s3, t2[33] = O2, t2[34] = _5, t2[35] = v5, t2[36] = b2, t2[37] = x2, t2[38] = C2, t2[39] = f4, t2[40] = k2) : k2 = t2[40], k2; +} +function hC(e38) { + hC.d = 2460; + let t2 = (0, Z3.c)(7), { children: n2, style: r2 } = e38, i3 = (0, X3.useContext)(lC), a3 = (0, X3.useContext)(uC), o3; + t2[0] !== a3 || t2[1] !== r2 || t2[2] !== i3 ? (o3 = h(pC.header, i3 === `rich` && pC.headerRich, a3 && pC.insetWide, r2), t2[0] = a3, t2[1] = r2, t2[2] = i3, t2[3] = o3) : o3 = t2[3]; let s3; - return t2[4] !== n2 || t2[5] !== o3 ? (s3 = (0, Y2.jsx)(`div`, { ...o3, children: n2 }), t2[4] = n2, t2[5] = o3, t2[6] = s3) : s3 = t2[6], s3; + return t2[4] !== n2 || t2[5] !== o3 ? (s3 = (0, Y3.jsx)(`div`, { ...o3, children: n2 }), t2[4] = n2, t2[5] = o3, t2[6] = s3) : s3 = t2[6], s3; } -function uw(e9) { - uw.d = 2178; - let t2 = (0, Z2.c)(8), { children: n2, style: r2, size: i3, weight: a3 } = e9, o3 = i3 === void 0 ? `lg` : i3, s3 = a3 === void 0 ? `semibold` : a3, { titleId: c2 } = lp2(), l4; - t2[0] === r2 ? l4 = t2[1] : (l4 = [sw.textBlock, r2], t2[0] = r2, t2[1] = l4); +function gC(e38) { + gC.d = 2462; + let t2 = (0, Z3.c)(8), { children: n2, style: r2, size: i3, weight: a3 } = e38, o3 = i3 === void 0 ? `lg` : i3, s3 = a3 === void 0 ? `semibold` : a3, { titleId: c3 } = Gp2(), l5; + t2[0] === r2 ? l5 = t2[1] : (l5 = [pC.textBlock, r2], t2[0] = r2, t2[1] = l5); let u3; - return t2[2] !== n2 || t2[3] !== o3 || t2[4] !== l4 || t2[5] !== c2 || t2[6] !== s3 ? (u3 = (0, Y2.jsx)(Kd, { as: `h2`, className: `sand-dialog__title`, color: `primary`, id: c2, rootStyle: l4, size: o3, weight: s3, children: n2 }), t2[2] = n2, t2[3] = o3, t2[4] = l4, t2[5] = c2, t2[6] = s3, t2[7] = u3) : u3 = t2[7], u3; + return t2[2] !== n2 || t2[3] !== o3 || t2[4] !== l5 || t2[5] !== c3 || t2[6] !== s3 ? (u3 = (0, Y3.jsx)(Ef2, { as: `h2`, className: `sand-dialog__title`, color: `primary`, id: c3, rootStyle: l5, size: o3, weight: s3, children: n2 }), t2[2] = n2, t2[3] = o3, t2[4] = l5, t2[5] = c3, t2[6] = s3, t2[7] = u3) : u3 = t2[7], u3; } -function dw(e9) { - dw.d = 2175; - let t2 = (0, Z2.c)(11), { children: n2, style: r2, color: i3, size: a3, dir: o3 } = e9, s3 = i3 === void 0 ? `tertiary` : i3, c2 = a3 === void 0 ? `lg` : a3, { descriptionId: l4 } = lp2(), u3; +function _C(e38) { + _C.d = 2459; + let t2 = (0, Z3.c)(11), { children: n2, style: r2, color: i3, size: a3, dir: o3 } = e38, s3 = i3 === void 0 ? `tertiary` : i3, c3 = a3 === void 0 ? `lg` : a3, { descriptionId: l5 } = Gp2(), u3; t2[0] === o3 ? u3 = t2[1] : (u3 = o3 == null ? {} : { dir: o3 }, t2[0] = o3, t2[1] = u3); let d3; - t2[2] === r2 ? d3 = t2[3] : (d3 = [sw.textBlock, r2], t2[2] = r2, t2[3] = d3); + t2[2] === r2 ? d3 = t2[3] : (d3 = [pC.textBlock, r2], t2[2] = r2, t2[3] = d3); let f4; - return t2[4] !== n2 || t2[5] !== s3 || t2[6] !== l4 || t2[7] !== c2 || t2[8] !== u3 || t2[9] !== d3 ? (f4 = (0, Y2.jsx)(Kd, { as: `p`, className: `sand-dialog__description`, color: s3, ...u3, id: l4, rootStyle: d3, size: c2, children: n2 }), t2[4] = n2, t2[5] = s3, t2[6] = l4, t2[7] = c2, t2[8] = u3, t2[9] = d3, t2[10] = f4) : f4 = t2[10], f4; -} -function fw(e9) { - fw.d = 2173; - let t2 = (0, Z2.c)(7), { children: n2, style: r2 } = e9, i3 = (0, X2.useContext)(rw), a3 = (0, X2.useContext)(iw), o3 = i3 === `rich` && sw.bodyRich, s3 = a3 && sw.insetWide, c2; - t2[0] !== r2 || t2[1] !== o3 || t2[2] !== s3 ? (c2 = [sw.body, o3, s3, r2], t2[0] = r2, t2[1] = o3, t2[2] = s3, t2[3] = c2) : c2 = t2[3]; - let l4; - return t2[4] !== n2 || t2[5] !== c2 ? (l4 = (0, Y2.jsx)(Fp2.Content, { rootStyle: c2, children: n2 }), t2[4] = n2, t2[5] = c2, t2[6] = l4) : l4 = t2[6], l4; -} -function pw(e9) { - pw.d = 2171; - let t2 = (0, Z2.c)(13), { children: n2, style: r2, layout: i3 } = e9, a3 = i3 === void 0 ? `horizontal` : i3, o3 = (0, X2.useContext)(rw), s3 = (0, X2.useContext)(iw), c2; - t2[0] !== s3 || t2[1] !== r2 || t2[2] !== o3 ? (c2 = h(sw.actions, o3 === `rich` && sw.actionsRich, s3 && sw.actionsWide, r2), t2[0] = s3, t2[1] = r2, t2[2] = o3, t2[3] = c2) : c2 = t2[3]; - let l4 = a3 === `responsive-stack`, u3; - t2[4] !== n2 || t2[5] !== a3 ? (u3 = a3 === `responsive-stack` ? (0, Y2.jsx)(`div`, { className: `sand-78zum5 sand-1a02dak sand-6s0dn4 sand-13a6bvl sand-167g77z sand-1iyjqo2 sand-euugli`, children: n2 }) : n2, t2[4] = n2, t2[5] = a3, t2[6] = u3) : u3 = t2[6]; + return t2[4] !== n2 || t2[5] !== s3 || t2[6] !== l5 || t2[7] !== c3 || t2[8] !== u3 || t2[9] !== d3 ? (f4 = (0, Y3.jsx)(Ef2, { as: `p`, className: `sand-dialog__description`, color: s3, ...u3, id: l5, rootStyle: d3, size: c3, children: n2 }), t2[4] = n2, t2[5] = s3, t2[6] = l5, t2[7] = c3, t2[8] = u3, t2[9] = d3, t2[10] = f4) : f4 = t2[10], f4; +} +function vC(e38) { + vC.d = 2457; + let t2 = (0, Z3.c)(7), { children: n2, style: r2 } = e38, i3 = (0, X3.useContext)(lC), a3 = (0, X3.useContext)(uC), o3 = i3 === `rich` && pC.bodyRich, s3 = a3 && pC.insetWide, c3; + t2[0] !== r2 || t2[1] !== o3 || t2[2] !== s3 ? (c3 = [pC.body, o3, s3, r2], t2[0] = r2, t2[1] = o3, t2[2] = s3, t2[3] = c3) : c3 = t2[3]; + let l5; + return t2[4] !== n2 || t2[5] !== c3 ? (l5 = (0, Y3.jsx)(xm2.Content, { rootStyle: c3, children: n2 }), t2[4] = n2, t2[5] = c3, t2[6] = l5) : l5 = t2[6], l5; +} +function yC(e38) { + yC.d = 2455; + let t2 = (0, Z3.c)(13), { children: n2, style: r2, layout: i3 } = e38, a3 = i3 === void 0 ? `horizontal` : i3, o3 = (0, X3.useContext)(lC), s3 = (0, X3.useContext)(uC), c3; + t2[0] !== s3 || t2[1] !== r2 || t2[2] !== o3 ? (c3 = h(pC.actions, o3 === `rich` && pC.actionsRich, s3 && pC.actionsWide, r2), t2[0] = s3, t2[1] = r2, t2[2] = o3, t2[3] = c3) : c3 = t2[3]; + let l5 = a3 === `responsive-stack`, u3; + t2[4] !== n2 || t2[5] !== a3 ? (u3 = a3 === `responsive-stack` ? (0, Y3.jsx)(`div`, { className: `sand-78zum5 sand-1a02dak sand-6s0dn4 sand-13a6bvl sand-167g77z sand-1iyjqo2 sand-euugli`, children: n2 }) : n2, t2[4] = n2, t2[5] = a3, t2[6] = u3) : u3 = t2[6]; let d3; - t2[7] !== l4 || t2[8] !== u3 ? (d3 = (0, Y2.jsx)(aw.Provider, { value: l4, children: u3 }), t2[7] = l4, t2[8] = u3, t2[9] = d3) : d3 = t2[9]; + t2[7] !== l5 || t2[8] !== u3 ? (d3 = (0, Y3.jsx)(dC.Provider, { value: l5, children: u3 }), t2[7] = l5, t2[8] = u3, t2[9] = d3) : d3 = t2[9]; let f4; - return t2[10] !== c2 || t2[11] !== d3 ? (f4 = (0, Y2.jsx)(`div`, { ...c2, children: d3 }), t2[10] = c2, t2[11] = d3, t2[12] = f4) : f4 = t2[12], f4; + return t2[10] !== c3 || t2[11] !== d3 ? (f4 = (0, Y3.jsx)(`div`, { ...c3, children: d3 }), t2[10] = c3, t2[11] = d3, t2[12] = f4) : f4 = t2[12], f4; } -function mw() { - mw.d = 2172; - let e9 = (0, Z2.c)(4), t2 = (0, X2.useContext)(aw), n2; - e9[0] === t2 ? n2 = e9[1] : (n2 = { 0: { className: `sand-euugli sand-1iyjqo2 sand-s83m0k sand-1r8uery` }, 1: { className: `sand-euugli sand-1l7klhg sand-1c4vz4f sand-2lah0s sand-qtp20y` } }[!!t2 << 0], e9[0] = t2, e9[1] = n2); +function bC() { + bC.d = 2456; + let e38 = (0, Z3.c)(4), t2 = (0, X3.useContext)(dC), n2; + e38[0] === t2 ? n2 = e38[1] : (n2 = { 0: { className: `sand-euugli sand-1iyjqo2 sand-s83m0k sand-1r8uery` }, 1: { className: `sand-euugli sand-1l7klhg sand-1c4vz4f sand-2lah0s sand-qtp20y` } }[!!t2 << 0], e38[0] = t2, e38[1] = n2); let r2; - return e9[2] === n2 ? r2 = e9[3] : (r2 = (0, Y2.jsx)(`div`, { ...n2 }), e9[2] = n2, e9[3] = r2), r2; + return e38[2] === n2 ? r2 = e38[3] : (r2 = (0, Y3.jsx)(`div`, { ...n2 }), e38[2] = n2, e38[3] = r2), r2; } -function hw(e9) { - hw.d = 2174; - let t2 = (0, Z2.c)(4), { _: n2 } = bb(), r2; +function xC(e38) { + xC.d = 2458; + let t2 = (0, Z3.c)(4), { _: n2 } = fx(), r2; t2[0] === n2 ? r2 = t2[1] : (r2 = n2({ id: `cu6iol` }), t2[0] = n2, t2[1] = r2); let i3; - return t2[2] === r2 ? i3 = t2[3] : (i3 = (0, Y2.jsx)(Fp2.Close, { "aria-label": r2, iconSize: 14, rootStyle: sw.close }), t2[2] = r2, t2[3] = i3), i3; -} -function gw(e9) { - gw.d = 2170; - let t2 = (0, Z2.c)(24), n2, r2, i3, a3, o3, s3, c2, l4; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c2 = t2[7], l4 = t2[8]) : ({ variant: a3, destructive: o3, disabled: s3, pending: c2, ref: l4, style: i3, children: n2, ...r2 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c2, t2[8] = l4); - let u3 = a3 === void 0 ? `secondary` : a3, d3 = o3 !== void 0 && o3, f4 = s3 !== void 0 && s3, p4 = c2 !== void 0 && c2, m3 = l4 === void 0 ? null : l4, h3 = (0, X2.useContext)(aw), g3 = (0, X2.useContext)(ow), _2 = g3 != null && u3 === `primary` && !f4 && !p4, v3; - t2[9] !== g3 || t2[10] !== m3 ? (v3 = (e10) => e10 == null ? void 0 : NC(e10, [g3, m3]), t2[9] = g3, t2[10] = m3, t2[11] = v3) : v3 = t2[11]; - let y3 = _2 ? v3 : m3, b3 = d3 ? `danger` : `neutral`, x3 = h3 && sw.actionResponsive, S3; - t2[12] !== i3 || t2[13] !== x3 ? (S3 = [rC.controlEdge, x3, i3], t2[12] = i3, t2[13] = x3, t2[14] = S3) : S3 = t2[14]; + return t2[2] === r2 ? i3 = t2[3] : (i3 = (0, Y3.jsx)(xm2.Close, { "aria-label": r2, iconSize: 14, rootStyle: pC.close }), t2[2] = r2, t2[3] = i3), i3; +} +function SC(e38) { + SC.d = 2454; + let t2 = (0, Z3.c)(24), n2, r2, i3, a3, o3, s3, c3, l5; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c3 = t2[7], l5 = t2[8]) : ({ variant: a3, destructive: o3, disabled: s3, pending: c3, ref: l5, style: i3, children: n2, ...r2 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c3, t2[8] = l5); + let u3 = a3 === void 0 ? `secondary` : a3, d3 = o3 !== void 0 && o3, f4 = s3 !== void 0 && s3, p4 = c3 !== void 0 && c3, m3 = l5 === void 0 ? null : l5, h4 = (0, X3.useContext)(dC), g5 = (0, X3.useContext)(fC), _5 = g5 != null && u3 === `primary` && !f4 && !p4, v5; + t2[9] !== g5 || t2[10] !== m3 ? (v5 = (e39) => e39 == null ? void 0 : RS(e39, [g5, m3]), t2[9] = g5, t2[10] = m3, t2[11] = v5) : v5 = t2[11]; + let y4 = _5 ? v5 : m3, b2 = d3 ? `danger` : `neutral`, x2 = h4 && pC.actionResponsive, S2; + t2[12] !== i3 || t2[13] !== x2 ? (S2 = [sS.controlEdge, x2, i3], t2[12] = i3, t2[13] = x2, t2[14] = S2) : S2 = t2[14]; let C2; - return t2[15] !== n2 || t2[16] !== f4 || t2[17] !== p4 || t2[18] !== r2 || t2[19] !== S3 || t2[20] !== y3 || t2[21] !== b3 || t2[22] !== u3 ? (C2 = (0, Y2.jsx)(MC, { ...r2, disabled: f4, pending: p4, ref: y3, sentiment: b3, size: `md`, style: S3, variant: u3, children: n2 }), t2[15] = n2, t2[16] = f4, t2[17] = p4, t2[18] = r2, t2[19] = S3, t2[20] = y3, t2[21] = b3, t2[22] = u3, t2[23] = C2) : C2 = t2[23], C2; -} -var _w = { Root: cw, Action: gw, ActionSpacer: mw, Header: lw, Title: uw, Description: dw, Body: fw, ActionBar: pw, CloseButton: hw }; -var Dw = { root: { kmuXW: `sand-2lah0s`, kWkggS: `sand-1uzf2l9`, $$css: true }, horizontal: { kzqmXN: `sand-h8yej3`, kZKoxP: `sand-28ko6u`, $$css: true }, vertical: { kzqmXN: `sand-197jcof`, kSGwAc: `sand-kh2ocl`, $$css: true } }; -function Ow(e9) { - Ow.d = 2142; - let t2 = (0, Z2.c)(20), n2, r2, i3, a3, o3; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5]) : ({ orientation: o3, className: n2, style: a3, ref: r2, ...i3 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3); - let s3 = o3 === void 0 ? `horizontal` : o3, c2, l4, u3, d3; - t2[6] !== n2 || t2[7] !== s3 || t2[8] !== i3 || t2[9] !== a3 ? (c2 = h(Dw.root, s3 === `horizontal` ? Dw.horizontal : Dw.vertical, a3), l4 = i3, u3 = s3, d3 = $(`sand-kit-divider`, c2.className, n2), t2[6] = n2, t2[7] = s3, t2[8] = i3, t2[9] = a3, t2[10] = c2, t2[11] = l4, t2[12] = u3, t2[13] = d3) : (c2 = t2[10], l4 = t2[11], u3 = t2[12], d3 = t2[13]); + return t2[15] !== n2 || t2[16] !== f4 || t2[17] !== p4 || t2[18] !== r2 || t2[19] !== S2 || t2[20] !== y4 || t2[21] !== b2 || t2[22] !== u3 ? (C2 = (0, Y3.jsx)(LS, { ...r2, disabled: f4, pending: p4, ref: y4, sentiment: b2, size: `md`, style: S2, variant: u3, children: n2 }), t2[15] = n2, t2[16] = f4, t2[17] = p4, t2[18] = r2, t2[19] = S2, t2[20] = y4, t2[21] = b2, t2[22] = u3, t2[23] = C2) : C2 = t2[23], C2; +} +var CC = { Root: mC, Action: SC, ActionSpacer: bC, Header: hC, Title: gC, Description: _C, Body: vC, ActionBar: yC, CloseButton: xC }; +var cT = { surface: { "--sand-status-dot-ring": `sand-u366gq`, kaIpWk: `sand-13yp6sp`, kGuDYH: `sand-mjvtqz`, kLWn49: `sand-e9ffq4`, kb6lSQ: `sand-19miikw`, "--ui-menu-inner-padding": `sand-i28r7m`, "--ui-menu-list-gap": `sand-148pmdb`, "--ui-menu-row-border-radius": `sand-k5wqll`, "--ui-menu-row-min-height": `sand-1icjr8n`, "--ui-menu-row-padding-block": `sand-fxzh7t`, "--ui-menu-row-padding-inline": `sand-1y4gx8u`, "--ui-menu-row-highlight-inset": `sand-1g4bt0a`, "--ui-menu-row-gap": `sand-1bm360g`, "--ui-menu-item-left-width": `sand-hsgrze`, "--ui-menu-item-left-height": `sand-4qng09`, "--ui-menu-item-left-color": `sand-1xcwj57`, "--ui-surface-hairline-width": `sand-1tpml9q`, "--ui-menu-divider-width": `sand-1g4rvgt`, "--ui-menu-divider-color": `sand-mm16iu`, "--ui-menu-divider-margin-inline": `sand-1p7q8zp`, "--ui-menu-divider-margin-block": `sand-vw6kie`, "--cursor-bg-quaternary": `sand-a1rxjy`, "--cursor-bg-tertiary": `sand-1dbjpva`, $$css: true }, sidePanel: { kaIpWk: `sand-1pkpdue`, "--ui-popup-box-shadow": `sand-yc74mg`, "--ui-menu-inner-padding": `sand-1xv2y21`, "--ui-menu-list-gap": `sand-ugvh3`, "--ui-menu-row-border-radius": `sand-8ej7fl`, "--ui-menu-row-min-height": `sand-199j77g`, "--ui-menu-row-padding-block": `sand-5b0lb`, "--ui-menu-row-padding-inline": `sand-1p3ha76`, "--ui-menu-row-gap": `sand-vzyzmz`, "--ui-menu-section-title-padding-inline": `sand-1kfdx4m`, "--ui-menu-item-left-width": `sand-2h970l`, "--ui-menu-item-left-height": `sand-1eaezr9`, "--ui-menu-divider-color": `sand-1pdmulj`, "--ui-menu-divider-margin-inline": `sand-hvey4x`, "--ui-menu-divider-margin-block": `sand-rwcruc`, $$css: true } }; +var $Re = { details: { kkrTdU: `sand-t0e3qv`, kGuDYH: `sand-11wthnw`, kLWn49: `sand-w8bs97`, kb6lSQ: `sand-14gdtuo`, "--ui-menu-row-min-height": `sand-inrsdt`, "--ui-menu-row-padding-block": `sand-19lclay`, "--ui-menu-row-padding-inline": `sand-18k90n9`, "--ui-menu-section-title-padding-inline": `sand-mhevzc`, "--ui-menu-divider-margin-inline": `sand-15f9hzj`, "--ui-menu-divider-margin-block": `sand-y691vg`, $$css: true } }; +var lT = (0, X3.createContext)(`default`); +function dT(e38) { + return [cT.surface, (0, X3.use)(lT) === `sidePanel` && cT.sidePanel, e38 === `details` && $Re.details]; +} +function pT(e38) { + pT.d = 2447; + let t2 = (0, Z3.c)(14), n2, i3, a3, o3, s3; + t2[0] === e38 ? (n2 = t2[1], i3 = t2[2], a3 = t2[3], o3 = t2[4], s3 = t2[5]) : ({ surfaceStyle: i3, size: a3, minWidth: o3, variant: s3, ...n2 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = i3, t2[3] = a3, t2[4] = o3, t2[5] = s3); + let c3 = a3 === void 0 ? `md` : a3, l5 = o3 === void 0 ? 200 : o3, u3 = dT(s3), d3; + t2[6] !== u3 || t2[7] !== i3 ? (d3 = [u3, i3], t2[6] = u3, t2[7] = i3, t2[8] = d3) : d3 = t2[8]; let f4; - return t2[14] !== c2.style || t2[15] !== r2 || t2[16] !== l4 || t2[17] !== u3 || t2[18] !== d3 ? (f4 = (0, Y2.jsx)(`div`, { ...l4, "aria-orientation": u3, className: d3, ref: r2, role: `separator`, style: c2.style }), t2[14] = c2.style, t2[15] = r2, t2[16] = l4, t2[17] = u3, t2[18] = d3, t2[19] = f4) : f4 = t2[19], f4; -} -var kw = { group: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kzqmXN: `sand-h8yej3`, k7Eaqz: `sand-euugli`, kMzoRj: `sand-qjedn3`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-5fd6op`, kaIpWk: `sand-1qmwy7c`, kVQacm: `sand-b3r6kr`, kWkggS: `sand-10e981r`, $$css: true }, groupFlat: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kOIVth: `sand-12mrbbr`, kzqmXN: `sand-h8yej3`, k7Eaqz: `sand-euugli`, kB7OPa: `sand-9f619`, kmVPX3: `sand-e8ttls`, $$css: true }, divider: { kWkggS: `sand-12ywq79`, $$css: true }, row: { kzqmXN: `sand-h8yej3`, k7Eaqz: `sand-euugli`, kZKoxP: `sand-t7dq6l`, kmuXW: `sand-s83m0k`, kGNEyG: `sand-6s0dn4`, kLKAdn: `sand-1y1aw1k`, kwRFfy: `sand-f159sx`, kGO01o: `sand-wib8y2`, kZCmMZ: `sand-mzvs34`, kOIVth: `sand-167g77z`, kjj79g: `sand-1nhvcw1`, khDVqt: `sand-eaf4i8`, kHjlTd: `sand-j0a0fe`, krdFHd: `sand-15mokao sand-1snnzrc`, kfmiAY: `sand-1ga7v0g sand-1xucafu`, kVL7Gh: `sand-biv7yw sand-pqz701`, kT0f0o: `sand-16uus16 sand-1kkz68i`, kInvED: `sand-2ssjo2`, kMwMTN: `sand-tyxrsu`, kWkggS: `sand-jbqb8w sand-x20oqx`, $$css: true }, rowSelected: { kWkggS: `sand-a4e5b6`, $$css: true }, rowFlat: { kGNEyG: `sand-1cy8zhl`, kLKAdn: `sand-m7lytj`, kwRFfy: `sand-1bjonze`, kGO01o: `sand-1ykpatu`, kZCmMZ: `sand-1pixwil`, kOIVth: `sand-1jnr06f`, krdFHd: `sand-bjudin sand-cs8yzb`, kfmiAY: `sand-nlwouz sand-dim822`, kVL7Gh: `sand-s9wviy sand-1sefpy4`, kT0f0o: `sand-pp8er5 sand-1g55tsu`, kSiTet: `sand-1hc1fzr`, kjBf7l: `sand-1v39l1b`, kMwMTN: `sand-tyxrsu sand-1gz2lq6 sand-zn6dba`, kWkggS: `sand-jbqb8w sand-x20oqx sand-1us2tlb`, kIyJzY: `sand-1kneoy4 sand-1uodt95`, $$css: true }, rowFlatDescribed: { kGNEyG: `sand-6s0dn4`, $$css: true }, rowFlatSelected: { kMwMTN: `sand-tyxrsu sand-1tqez8e`, $$css: true }, rowBody: { k1xSpc: `sand-78zum5`, kzQI83: `sand-1iyjqo2`, kmuXW: `sand-s83m0k`, kXwgrk: `sand-dt5ytf`, kGNEyG: `sand-1cy8zhl`, k7Eaqz: `sand-euugli`, $$css: true }, rowBodyFlat: { kLKAdn: `sand-1nn3v0j`, kwRFfy: `sand-1icxu4v`, kZCmMZ: `sand-25sj25`, $$css: true }, rowLabelGroup: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-1jnr06f`, k7Eaqz: `sand-euugli`, $$css: true }, rowLabel: { kMwMTN: `sand-1heor9g`, k7Eaqz: `sand-euugli`, khDVqt: `sand-eaf4i8`, kHjlTd: `sand-j0a0fe`, k9WMMc: `sand-1yc453h`, $$css: true }, rowDescription: { k7Eaqz: `sand-euugli`, khDVqt: `sand-eaf4i8`, kHjlTd: `sand-j0a0fe`, k9WMMc: `sand-1yc453h`, kMwMTN: `sand-1o0liin`, $$css: true }, rowDescriptionFlat: { kMwMTN: `sand-169k319`, $$css: true }, disabledInk: { kMwMTN: `sand-x1phaw`, $$css: true }, inputRow: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-1cy8zhl`, kOIVth: `sand-1jnr06f`, kB7OPa: `sand-9f619`, kzqmXN: `sand-h8yej3`, k7Eaqz: `sand-euugli`, kmVPX3: `sand-e8ttls`, kaIpWk: `sand-gqmno8`, kkrTdU: `sand-1ed109x`, $$css: true }, inputRowEnabled: { kWkggS: `sand-jbqb8w sand-1sygd3j`, $$css: true }, inputRowControl: { kzQI83: `sand-1iyjqo2`, kmuXW: `sand-s83m0k`, kCS8Yb: `sand-1r8uery`, k7Eaqz: `sand-euugli`, kB7OPa: `sand-9f619`, kqGvvJ: `sand-10im51j`, kUOVxO: `sand-rxpjvj`, kLKAdn: `sand-4p5aij`, kwRFfy: `sand-1icxu4v`, kGO01o: `sand-1j85h84`, kZCmMZ: `sand-25sj25`, ksu8eU: `sand-ng3xce`, kWkggS: `sand-jbqb8w`, kMwMTN: `sand-tyxrsu`, kMv6JI: `sand-jb2p0i`, k3XXqK: `sand-1t137rt`, kHenm0: `sand-tt52l0`, kOwNse: `sand-5f5z56`, kORKVm: `sand-10wlt62`, khDVqt: `sand-126k92a`, kHjlTd: `sand-j0a0fe`, k8Qsv1: `sand-1gvdfu`, $$css: true }, rowTrailing: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kmuXW: `sand-2lah0s`, kOIVth: `sand-1jnr06f`, kMwMTN: `sand-1o0liin`, $$css: true }, rowLeading: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kmuXW: `sand-2lah0s`, $$css: true } }; -function Aw(e9) { - Aw.d = 2147; - let t2 = (0, Z2.c)(9), { children: n2, label: r2, role: i3 } = e9, a3 = n2.filter(jNe), o3 = fC() === `elevated`, s3; - t2[0] === o3 ? s3 = t2[1] : (s3 = { 0: { className: `sand-78zum5 sand-dt5ytf sand-h8yej3 sand-euugli sand-qjedn3 sand-1y0btm7 sand-5fd6op sand-1qmwy7c sand-b3r6kr sand-10e981r` }, 1: { className: `sand-78zum5 sand-dt5ytf sand-12mrbbr sand-h8yej3 sand-euugli sand-9f619 sand-e8ttls` } }[!!o3 << 0], t2[0] = o3, t2[1] = s3); - let c2; - t2[2] === o3 ? c2 = t2[3] : (c2 = (e10, t3) => (0, Y2.jsxs)(X2.Fragment, { children: [t3 > 0 && !o3 ? (0, Y2.jsx)(Ow, { style: kw.divider }) : null, e10] }, t3), t2[2] = o3, t2[3] = c2); - let l4 = a3.map(c2), u3; - return t2[4] !== r2 || t2[5] !== i3 || t2[6] !== s3 || t2[7] !== l4 ? (u3 = (0, Y2.jsx)(`div`, { "aria-label": r2, role: i3, ...s3, children: l4 }), t2[4] = r2, t2[5] = i3, t2[6] = s3, t2[7] = l4, t2[8] = u3) : u3 = t2[8], u3; -} -function jNe(e9) { - return e9 != null && e9 !== false; -} -function jw(e9) { - jw.d = 2146; - let t2 = (0, Z2.c)(28), { label: n2, badge: r2, description: i3, leading: a3, trailing: o3, onClick: s3, disabled: c2, selected: l4, pressed: u3, keyShortcut: d3 } = e9, f4 = fC() === `elevated`, p4 = l4 === true, m3 = c2 === true, h3; - t2[0] === n2 ? h3 = t2[1] : (h3 = (0, Y2.jsx)(lx, { style: kw.rowLabel, children: n2 }), t2[0] = n2, t2[1] = h3); - let g3 = h3, _2 = f4 && kw.rowFlat, v3 = f4 && i3 != null && kw.rowFlatDescribed, y3 = p4 && (f4 ? kw.rowFlatSelected : kw.rowSelected), b3; - t2[2] !== _2 || t2[3] !== v3 || t2[4] !== y3 ? (b3 = [kw.row, _2, v3, y3], t2[2] = _2, t2[3] = v3, t2[4] = y3, t2[5] = b3) : b3 = t2[5]; - let x3; - t2[6] === f4 ? x3 = t2[7] : (x3 = { 0: { className: `sand-78zum5 sand-1iyjqo2 sand-s83m0k sand-dt5ytf sand-1cy8zhl sand-euugli` }, 1: { className: `sand-78zum5 sand-1iyjqo2 sand-s83m0k sand-dt5ytf sand-1cy8zhl sand-euugli sand-1nn3v0j sand-1icxu4v sand-25sj25` } }[!!f4 << 0], t2[6] = f4, t2[7] = x3); - let S3; - t2[8] !== r2 || t2[9] !== g3 ? (S3 = r2 == null ? g3 : (0, Y2.jsxs)(`span`, { className: `sand-78zum5 sand-6s0dn4 sand-1jnr06f sand-euugli`, children: [g3, r2] }), t2[8] = r2, t2[9] = g3, t2[10] = S3) : S3 = t2[10]; - let C2; - t2[11] !== i3 || t2[12] !== m3 || t2[13] !== f4 ? (C2 = i3 == null ? null : (0, Y2.jsx)(lx, { style: [kw.rowDescription, f4 && kw.rowDescriptionFlat, f4 && m3 && kw.disabledInk], children: i3 }), t2[11] = i3, t2[12] = m3, t2[13] = f4, t2[14] = C2) : C2 = t2[14]; - let w3; - t2[15] !== x3 || t2[16] !== S3 || t2[17] !== C2 ? (w3 = (0, Y2.jsxs)(`span`, { ...x3, children: [S3, C2] }), t2[15] = x3, t2[16] = S3, t2[17] = C2, t2[18] = w3) : w3 = t2[18]; - let T3; - return t2[19] !== c2 || t2[20] !== d3 || t2[21] !== a3 || t2[22] !== s3 || t2[23] !== u3 || t2[24] !== b3 || t2[25] !== w3 || t2[26] !== o3 ? (T3 = (0, Y2.jsxs)(QS, { align: `left`, "aria-keyshortcuts": d3, "aria-pressed": u3, disabled: c2, onClick: s3, rootStyle: b3, type: `button`, variant: `ghost`, children: [a3, w3, o3] }), t2[19] = c2, t2[20] = d3, t2[21] = a3, t2[22] = s3, t2[23] = u3, t2[24] = b3, t2[25] = w3, t2[26] = o3, t2[27] = T3) : T3 = t2[27], T3; -} -var MNe = 1200; -function Nw() { - let e9 = (0, Z2.c)(6), t2; - e9[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (t2 = { durationMs: MNe }, e9[0] = t2) : t2 = e9[0]; - let [n2, r2] = QG(t2), i3; - e9[1] === r2 ? i3 = e9[2] : (i3 = (e10) => { - navigator2.clipboard.writeText(e10).then(() => { - r2(), AS(U._({ id: `6V3Ea3` })); - }, NNe); - }, e9[1] = r2, e9[2] = i3); - let a3 = i3, o3; - return e9[3] !== a3 || e9[4] !== n2 ? (o3 = [n2, a3], e9[3] = a3, e9[4] = n2, e9[5] = o3) : o3 = e9[5], o3; -} -function NNe() { -} -var fT = { reveal: { kSiTet: `sand-1t7ft1p sand-25t5g8`, k1ekBW: `sand-19991ni`, kIyJzY: `sand-1firant`, kAMwcw: `sand-9lcvmn`, $$css: true } }; -function pT(e9) { - pT.d = 2082; - let t2 = (0, Z2.c)(8), { url: n2, label: r2, variant: i3 } = e9, a3 = i3 === void 0 ? `ghost` : i3, [o3, s3] = Nw(), c2 = o3 ? `check` : `link`, l4; - t2[0] !== s3 || t2[1] !== n2 ? (l4 = () => s3(n2), t2[0] = s3, t2[1] = n2, t2[2] = l4) : l4 = t2[2]; - let u3; - return t2[3] !== r2 || t2[4] !== c2 || t2[5] !== l4 || t2[6] !== a3 ? (u3 = (0, Y2.jsx)(oC, { "aria-label": r2, icon: c2, onClick: l4, size: `xs`, style: fT.reveal, title: r2, variant: a3 }), t2[3] = r2, t2[4] = c2, t2[5] = l4, t2[6] = a3, t2[7] = u3) : u3 = t2[7], u3; -} -function mT(e9) { - mT.d = 2083; - let t2 = (0, Z2.c)(7), { text: n2, label: r2 } = e9, [i3, a3] = Nw(), o3 = i3 ? `check` : `copy`, s3; - t2[0] !== a3 || t2[1] !== n2 ? (s3 = () => a3(n2), t2[0] = a3, t2[1] = n2, t2[2] = s3) : s3 = t2[2]; - let c2; - return t2[3] !== r2 || t2[4] !== o3 || t2[5] !== s3 ? (c2 = (0, Y2.jsx)(oC, { "aria-label": r2, icon: o3, onClick: s3, size: `xs`, style: fT.reveal, title: r2 }), t2[3] = r2, t2[4] = o3, t2[5] = s3, t2[6] = c2) : c2 = t2[6], c2; -} -function XT(e9) { - XT.d = 2183; - let t2 = (0, Z2.c)(16), { text: n2, token: r2, dir: i3 } = e9, a3, o3, s3; - if (t2[0] !== n2 || t2[1] !== r2) { - s3 = /* @__PURE__ */ Symbol.for(`react.early_return_sentinel`); - bb0: { - if (a3 = r2.length > 0 ? n2.indexOf(r2) : -1, a3 < 0) { - s3 = n2; - break bb0; - } - o3 = n2.slice(0, a3); - } - t2[0] = n2, t2[1] = r2, t2[2] = a3, t2[3] = o3, t2[4] = s3; - } else a3 = t2[2], o3 = t2[3], s3 = t2[4]; - if (s3 !== /* @__PURE__ */ Symbol.for(`react.early_return_sentinel`)) return s3; - let c2; - t2[5] !== i3 || t2[6] !== r2 ? (c2 = (0, Y2.jsx)(`bdi`, { dir: i3, children: r2 }), t2[5] = i3, t2[6] = r2, t2[7] = c2) : c2 = t2[7]; - let l4; - t2[8] !== a3 || t2[9] !== n2 || t2[10] !== r2.length ? (l4 = n2.slice(a3 + r2.length), t2[8] = a3, t2[9] = n2, t2[10] = r2.length, t2[11] = l4) : l4 = t2[11]; + return t2[9] !== l5 || t2[10] !== n2 || t2[11] !== c3 || t2[12] !== d3 ? (f4 = (0, Y3.jsx)(Nb2.Content, { minWidth: l5, size: c3, ...n2, surfaceStyle: d3 }), t2[9] = l5, t2[10] = n2, t2[11] = c3, t2[12] = d3, t2[13] = f4) : f4 = t2[13], f4; +} +function mT(e38) { + mT.d = 2449; + let t2 = (0, Z3.c)(11), n2, i3, a3; + t2[0] === e38 ? (n2 = t2[1], i3 = t2[2], a3 = t2[3]) : ({ surfaceStyle: i3, size: a3, ...n2 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = i3, t2[3] = a3); + let o3 = a3 === void 0 ? `md` : a3, s3 = dT(), c3; + t2[4] !== s3 || t2[5] !== i3 ? (c3 = [s3, i3], t2[4] = s3, t2[5] = i3, t2[6] = c3) : c3 = t2[6]; + let l5; + return t2[7] !== n2 || t2[8] !== o3 || t2[9] !== c3 ? (l5 = (0, Y3.jsx)(Nb2.VirtualizedContent, { size: o3, ...n2, surfaceStyle: c3 }), t2[7] = n2, t2[8] = o3, t2[9] = c3, t2[10] = l5) : l5 = t2[10], l5; +} +function gT(e38) { + gT.d = 2448; + let t2 = (0, Z3.c)(11), n2, i3, a3; + t2[0] === e38 ? (n2 = t2[1], i3 = t2[2], a3 = t2[3]) : ({ surfaceStyle: i3, size: a3, ...n2 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = i3, t2[3] = a3); + let o3 = a3 === void 0 ? `md` : a3, s3 = dT(), c3; + t2[4] !== s3 || t2[5] !== i3 ? (c3 = [s3, i3], t2[4] = s3, t2[5] = i3, t2[6] = c3) : c3 = t2[6]; + let l5; + return t2[7] !== n2 || t2[8] !== o3 || t2[9] !== c3 ? (l5 = (0, Y3.jsx)(Nb2.SubMenuContent, { size: o3, ...n2, surfaceStyle: c3 }), t2[7] = n2, t2[8] = o3, t2[9] = c3, t2[10] = l5) : l5 = t2[10], l5; +} +function vT(e38) { + vT.d = 2446; + let t2 = (0, Z3.c)(2), n2; + return t2[0] === e38 ? n2 = t2[1] : (n2 = (0, Y3.jsx)(Nb2, { ...e38 }), t2[0] = e38, t2[1] = n2), n2; +} +var bT = Object.assign(vT, Nb2, { Content: pT, SubMenuContent: gT, VirtualizedContent: mT }); +function DT() { + return document3.documentElement.dir === `rtl` ? `rtl` : `ltr`; +} +function kT(e38, t2) { + return e38 !== `ArrowLeft` && e38 !== `ArrowRight` ? null : e38 === `ArrowRight` == (t2 === `ltr`) ? 1 : -1; +} +function NT(e38) { + if (e38.altKey || e38.ctrlKey || e38.metaKey || e38.shiftKey) return; + let t2 = kT(e38.key, DT()); + if (t2 == null || !(e38.target instanceof HTMLElement3)) return; + let n2 = [...e38.currentTarget.querySelectorAll(`[role="tab"]`)], r2 = n2.indexOf(e38.target); + r2 < 0 || (e38.preventDefault(), n2[(r2 + t2 + n2.length) % n2.length]?.focus({ preventScroll: true })); +} +var GT = { surface: { kaIpWk: `sand-13yp6sp`, "--ui-select-inner-padding": `sand-1dns7hp`, "--ui-select-list-gap": `sand-14h2ojr`, "--ui-select-row-min-height": `sand-1n21ee9`, "--ui-select-row-padding-block": `sand-1okjtpd`, "--ui-select-row-padding-inline": `sand-1hrzgrd`, "--ui-select-row-gap": `sand-rqqy9p`, "--ui-menu-row-border-radius": `sand-k5wqll`, "--ui-menu-row-highlight-inset": `sand-3caj2g`, "--ui-surface-hairline-width": `sand-1tpml9q`, $$css: true }, weakBorder: { kLZC3w: `sand-1k01be8`, kBCPoo: `sand-12gt5l9`, kL6WhQ: `sand-71tixx`, kGJrpR: `sand-1x5h272`, $$css: true }, ghostPrimaryInk: { "--ui-button-fg": `sand-1fy7lmn`, $$css: true }, valueLabel: { k1xSpc: `sand-104kibb`, kgKLqz: `sand-1ua5tub`, kJFfOR: `sand-h0615m`, kdZRtv: `sand-1qxw02l`, k8aIck: `sand-sdcz8n`, kHjlTd: `sand-j0a0fe`, $$css: true } }; +function KT(e38) { + return e38 === `secondary` ? GT.weakBorder : e38 === `ghost` ? [GT.weakBorder, GT.ghostPrimaryInk] : null; +} +function qT(e38) { + qT.d = 2369; + let t2 = (0, Z3.c)(27), n2, r2, i3, a3, o3, s3, c3, l5; + if (t2[0] !== e38) { + let { contentStyle: u4, labelStyle: d4, rootStyle: f5, ...p4 } = e38; + r2 = f5; + let m3 = p4.value != null && p4.itemToStringLabel !== void 0 ? p4.itemToStringLabel(p4.value) : p4.options.find((e39) => e39.value === p4.value)?.label; + t2[9] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (c3 = { className: `sand-jp7ctv` }, t2[9] = c3) : c3 = t2[9], l5 = typeof m3 == `string` ? m3 : void 0, n2 = qb2, a3 = p4, t2[10] === u4 ? o3 = t2[11] : (o3 = [GT.surface, u4], t2[10] = u4, t2[11] = o3), t2[12] === d4 ? s3 = t2[13] : (s3 = [GT.valueLabel, d4], t2[12] = d4, t2[13] = s3), i3 = KT(p4.variant), t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3, t2[7] = c3, t2[8] = l5; + } else n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6], c3 = t2[7], l5 = t2[8]; let u3; - return t2[12] !== o3 || t2[13] !== c2 || t2[14] !== l4 ? (u3 = (0, Y2.jsxs)(Y2.Fragment, { children: [o3, c2, l4] }), t2[12] = o3, t2[13] = c2, t2[14] = l4, t2[15] = u3) : u3 = t2[15], u3; + t2[14] !== r2 || t2[15] !== i3 ? (u3 = [i3, r2], t2[14] = r2, t2[15] = i3, t2[16] = u3) : u3 = t2[16]; + let d3; + t2[17] !== n2 || t2[18] !== a3 || t2[19] !== o3 || t2[20] !== s3 || t2[21] !== u3 ? (d3 = (0, Y3.jsx)(n2, { ...a3, contentStyle: o3, labelStyle: s3, rootStyle: u3 }), t2[17] = n2, t2[18] = a3, t2[19] = o3, t2[20] = s3, t2[21] = u3, t2[22] = d3) : d3 = t2[22]; + let f4; + return t2[23] !== c3 || t2[24] !== l5 || t2[25] !== d3 ? (f4 = (0, Y3.jsx)(`span`, { ...c3, title: l5, children: d3 }), t2[23] = c3, t2[24] = l5, t2[25] = d3, t2[26] = f4) : f4 = t2[26], f4; +} +function YE() { + return P.locale; } -var iO = /* @__PURE__ */ new WeakMap(); -function aO(e9) { - let t2 = (0, Z2.c)(4), n2; - t2[0] === e9 ? n2 = t2[1] : (n2 = iO.get(e9), t2[0] = e9, t2[1] = n2); +var CD = /* @__PURE__ */ new WeakMap(); +function wD(e38) { + let t2 = (0, Z3.c)(4), n2; + t2[0] === e38 ? n2 = t2[1] : (n2 = CD.get(e38), t2[0] = e38, t2[1] = n2); let r2 = n2; if (r2 === void 0) { let n3; - t2[2] === e9 ? n3 = t2[3] : (n3 = () => (e9(), oIe), t2[2] = e9, t2[3] = n3), r2 = n3, iO.set(e9, r2); + t2[2] === e38 ? n3 = t2[3] : (n3 = () => (e38(), NBe), t2[2] = e38, t2[3] = n3), r2 = n3, CD.set(e38, r2); } - Bw(r2); + DE(r2); } -function oIe() { +function NBe() { } -function PO(e9) { - return { ...e9, destructive: true }; +function tO(e38) { + return { ...e38, destructive: true }; } -function k2(e9) { - let t2 = e9?.items; +var Abt = `sand-favicon`; +function jbt(e38, t2) { + if (!URL.canParse(e38)) return null; + let n2 = new URL(e38); + return t2.includes(n2.protocol) && n2.hostname.length > 0 ? n2.hostname.toLowerCase() : null; +} +function Mbt(e38) { + let t2 = jbt(e38, [`https:`, `http:`]); + return t2 == null ? null : `${Abt}://${t2}/`; +} +function P0(e38) { + let t2 = e38?.items; if (t2 == null || t2.length === 0) return []; let n2 = []; - for (let e10 of Array.from(t2)) { - if (e10.kind !== `file`) continue; - let t3 = e10.getAsFile(); + for (let e39 of Array.from(t2)) { + if (e39.kind !== `file`) continue; + let t3 = e39.getAsFile(); t3 != null && n2.push(t3); } return n2; } -var AKt = { yourComputer: { id: `CKGdoo` }, manageDevices: { id: `u8jZfN` }, messages: { id: `t7TeQU` }, botComputer: { id: `yGkA3X` } }; -var b6 = { account: { label: { id: `AeXO77` }, description: { id: `59DMcs` } }, theme: { label: { id: `FEr96N` }, description: { id: `rPsbnH` } }, accent: { label: { id: `Eax/et` }, description: { id: `eeSkqM` } }, language: { label: { id: `vXIe7J` }, description: { id: `uHzQat` } }, "spell-check": { label: { id: `hzdQ0D` }, description: { id: `AQEPsg` } }, microphone: { label: { id: `1iY5xv` }, description: { id: `ObLYJM` } }, "hardware-acceleration": { label: { id: `gkVAUt` }, description: { id: `uGmpY+` } }, "hardware-acceleration-restart": { label: { id: `ZFmUzi` }, description: { id: `/7L0mm` } }, "network-debugger": { label: { id: `QVjG8n` }, description: { id: `vhgAB7` } }, "notification-sound-enabled": { label: { id: `6EhUT7` }, description: { id: `0+TImd` } }, "notification-sound": { label: { id: `wm7RV4` }, description: { id: `KXGrZy` } }, model: { label: { id: `scu3wk` }, description: { id: `2RPCms` } }, timezone: { label: { id: `40Gx0U` }, description: { id: `TO/JdP` } }, "local-execution": { label: { id: `fuUvu2` }, description: { id: `Hd1KB+` } }, computers: { label: AKt.yourComputer, description: { id: `Q4Zdc3` } }, "chrome-cookie-import": { label: { id: `1O0Zig` }, description: { id: `0DQ6h6` } }, messages: { label: { id: `ISQkak` }, description: { id: `jusBAO` } }, "messages-send-without-asking": { label: { id: `jO0zrH` }, description: { id: `H8ihay` } }, "messages-allowed-recipients": { label: { id: `S+1Zzr` }, description: { id: `qwAXC4` } }, "auto-review": { label: { id: `RkLueX` }, description: { id: `SapxY4` } }, "auto-review-rules": { label: { id: `BKJ+TX` }, description: { id: `WhXxC0` } }, "security-keys": { label: { id: `VUEkDl` }, description: { id: `Uzr0Jg` } }, "team-bot-connector-preferences": { label: { id: `IgP+IC` }, description: { id: `FTN9h/` } }, "team-bot-slack-link": { label: { id: `lEemA0` }, description: { id: `bYJccz` } }, passkeys: { label: { id: `UZKLEA` }, description: { id: `D480N4` } }, usage: { label: { id: `7FaY4u` }, description: { id: `i7ZlV9` } }, plan: { label: { id: `UDsdr3` }, description: { id: `N5p7gX` } }, "cancel-trial": { label: { id: `oV3urV` }, description: { id: `JpChhx` } }, "on-demand": { label: { id: `dUyQn5` }, description: { id: `sUOyeI` } }, billing: { label: { id: `53hao2` }, description: { id: `GwmYad` } }, egress: { label: { id: `OarWo6` }, description: { id: `t5gE79` } }, "update-status": { label: { id: `U+dVHJ` }, description: { id: `ao3+bh` } }, "update-channel": { label: { id: `/IUA77` }, description: { id: `iRkm85` } }, "automatic-updates": { label: { id: `VmXinp` }, description: { id: `Yia9RU` } }, "update-computer": { label: { id: `hydWk/` }, description: { id: `mlZ6OJ` } }, "reset-computer": { label: { id: `sJUwbc` }, description: { id: `O+wR5I` } } }; -function x6(e9) { - return b6[e9].label; -} -function MKt(e9) { - let t2 = (0, Z2.c)(3), { _: n2 } = bb(), r2; - return t2[0] !== n2 || t2[1] !== e9 ? (r2 = n2(x6(e9)), t2[0] = n2, t2[1] = e9, t2[2] = r2) : r2 = t2[2], r2; -} -function qen(e9) { - let t2 = zn({ read: () => e9.listGrokBotVaultCredentials(), unavailableCodes: [Gv], freshMs: 0, readObserver: kd({ domain: `secrets`, operation: `listGrokBotVaultCredentials` }) }), n2 = () => t2.write(() => e9.listGrokBotVaultCredentials()).then(void 0, (e10) => { - if (!(e10 instanceof Qs2)) throw e10; - _l(e10); +var l7t = `camera`; +function Gmn(e38) { + let t2 = Jn2({ read: () => e38.listGrokBotVaultCredentials(), unavailableCodes: [Ny3], freshMs: 0, readObserver: sd2({ domain: `secrets`, operation: `listGrokBotVaultCredentials` }) }), n2 = () => t2.write(() => e38.listGrokBotVaultCredentials()).then(void 0, (e39) => { + if (!(e39 instanceof ec3)) throw e39; + cl2(e39); }), r2 = async (t3) => { try { - return t3.kind === `logins` ? await e9.createGrokBotVaultLogins({ logins: t3.logins }) : (await e9.createGrokBotVaultCard(t3.card), [{ kind: `imported` }]); - } catch (e10) { - if (!(e10 instanceof Qs2) || e10.failure.code !== `grok-bot-vault/refused`) throw e10; - let n3 = { kind: `refused`, message: e10.message }; + return t3.kind === `logins` ? await e38.createGrokBotVaultLogins({ logins: t3.logins }) : (await e38.createGrokBotVaultCard(t3.card), [{ kind: `imported` }]); + } catch (e39) { + if (!(e39 instanceof ec3) || e39.failure.code !== `grok-bot-vault/refused`) throw e39; + let n3 = { kind: `refused`, message: e39.message }; return t3.kind === `logins` ? t3.logins.map(() => n3) : [n3]; } - }, i3 = Rn(null), a3 = Rn(/* @__PURE__ */ new Map()), o3 = () => { + }, i3 = qn2(null), a3 = qn2(/* @__PURE__ */ new Map()), o3 = () => { i3.set(null), a3.set(/* @__PURE__ */ new Map()); }; return { snapshots: t2.snapshots, cardPhotoHandoff: i3, flaggedCardPhotos: a3, load: t2.load, retry: () => { t2.refresh(); }, put: async (t3) => { - let r3 = await e9.putGrokBotVaultCredential(t3); + let r3 = await e38.putGrokBotVaultCredential(t3); return await n2(), r3; }, updateCard: async (t3) => { - let r3 = await e9.updateGrokBotVaultCard(t3); + let r3 = await e38.updateGrokBotVaultCard(t3); return await n2(), r3; }, putContact: async (t3) => { - let r3 = await e9.putGrokBotVaultContact(t3); + let r3 = await e38.putGrokBotVaultContact(t3); return await n2(), r3; }, createCard: async (t3) => { - let r3 = await e9.createGrokBotVaultCard(t3); + let r3 = await e38.createGrokBotVaultCard(t3); return await n2(), r3; }, remove: async (t3) => { - await e9.deleteGrokBotVaultCredential({ id: t3 }), await n2(); + await e38.deleteGrokBotVaultCredential({ id: t3 }), await n2(); }, readCardPhoto: async (t3, { signal: n3 }) => { - let r3 = Yen(), i4 = () => { - e9.cancelGrokBotCardPhotoRead({ readId: r3 }).catch((e10) => { - if (!(e10 instanceof Qs2)) throw e10; - _l(e10); + let r3 = qmn(), i4 = () => { + e38.cancelGrokBotCardPhotoRead({ readId: r3 }).catch((e39) => { + if (!(e39 instanceof ec3)) throw e39; + cl2(e39); }); }; n3.addEventListener(`abort`, i4, { once: true }); try { - return await e9.readGrokBotCardPhoto({ ...t3, readId: r3 }, { signal: n3 }); + return await e38.readGrokBotCardPhoto({ ...t3, readId: r3 }, { signal: n3 }); } finally { n3.removeEventListener(`abort`, i4); } - }, screenCardImage: (t3) => e9.screenGrokBotCardImage(t3), handOffCardPhotos: (e10) => i3.get() === null && (i3.set({ files: e10 }), true), flagCardPhoto: (e10, t3) => { - a3.update((n3) => new Map(n3).set(e10, t3)); - }, unflagCardPhotos: (e10) => { + }, screenCardImage: (t3) => e38.screenGrokBotCardImage(t3), handOffCardPhotos: (e39) => i3.get() === null && (i3.set({ files: e39 }), true), flagCardPhoto: (e39, t3) => { + a3.update((n3) => new Map(n3).set(e39, t3)); + }, unflagCardPhotos: (e39) => { let t3 = a3.get(); - if (!e10.some((e11) => t3.has(e11))) return; + if (!e39.some((e40) => t3.has(e40))) return; let n3 = new Map(t3); - for (let t4 of e10) n3.delete(t4); + for (let t4 of e39) n3.delete(t4); a3.set(n3); - }, clearCardPhotoHandoff: () => i3.set(null), importItems: async (e10, { signal: t3, onSettled: i4 }) => { + }, clearCardPhotoHandoff: () => i3.set(null), importItems: async (e39, { signal: t3, onSettled: i4 }) => { try { - for (let n3 of Jen(e10)) { + for (let n3 of Kmn(e39)) { if (t3.aborted) break; - for (let e11 of await r2(n3)) i4(e11); + for (let e40 of await r2(n3)) i4(e40); } } finally { await n2(); @@ -4746,190 +11484,649 @@ function qen(e9) { o3(), t2.dispose(); } }; } -function Jen(e9) { +function Kmn(e38) { let t2 = [], n2 = [], r2 = () => { n2.length !== 0 && (t2.push({ kind: `logins`, logins: n2 }), n2 = []); }; - for (let i3 of e9) { + for (let i3 of e38) { if (i3.kind === `card`) { r2(), t2.push({ kind: `card`, card: i3.card }); continue; } - let { id: e10, ...a3 } = i3.login; + let { id: e39, ...a3 } = i3.login; n2.push(a3), n2.length === 50 && r2(); } return r2(), t2; } -function Yen() { - let e9 = globalThis.crypto, t2 = nt(e9) ? e9.randomUUID : void 0; - return G(typeof t2 == `function`, `grok-bot-vault-store: main cancels a card photo read by its id, so it needs crypto.randomUUID`), String(t2.call(e9)); +function qmn() { + let e38 = globalThis.crypto, t2 = mt(e38) ? e38.randomUUID : void 0; + return Ve(typeof t2 == `function`, `grok-bot-vault-store: main cancels a card photo read by its id, so it needs crypto.randomUUID`), String(t2.call(e38)); } -// ../../../../../private/dist/renderer/assets/chunk-card-field-BSSPKMT3.js -var l3 = UA(); -var u2 = Ke(); +// ../../../../../private/dist/renderer/assets/chunk-card-field-CcWQrzle.js +var l3 = Ij(); +var u2 = it(); var d2 = { control: { k1xSpc: `sand-1lliihq`, kzQI83: `sand-1iyjqo2`, kmuXW: `sand-s83m0k`, kCS8Yb: `sand-1r8uery`, k7Eaqz: `sand-euugli`, ks0D6T: `sand-193iq5w`, kB7OPa: `sand-9f619`, kLKAdn: `sand-123j3cw`, kwRFfy: `sand-2vl965`, kGO01o: `sand-s9asl8`, kZCmMZ: `sand-e2zdcy`, ksu8eU: `sand-ng3xce`, kaIpWk: `sand-1qmwy7c`, kWkggS: `sand-jbqb8w`, kMwMTN: `sand-tyxrsu`, kMv6JI: `sand-jb2p0i`, kGuDYH: `sand-1qlqyl8`, kLWn49: `sand-15bjb6t`, kb6lSQ: `sand-4gjf66`, k3XXqK: `sand-1t137rt`, k8Qsv1: `sand-1h7ufjq`, $$css: true }, controlElevated: { kwRFfy: `sand-rw5ot4`, kZCmMZ: `sand-7coems`, k8Qsv1: `sand-1gvdfu`, $$css: true }, select: { kwRFfy: `sand-1ekh9h2`, ke9TFa: `sand-odjb3w`, k8ry5P: `sand-18b5jzi`, kBCPoo: `sand-1o3jo1z`, kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, khDVqt: `sand-uxw1ft`, $$css: true }, selectElevated: { kwRFfy: `sand-1x5flf6`, ke9TFa: `sand-1c1dy35`, $$css: true }, option: { kWkggS: `sand-10e981r`, kMwMTN: `sand-tyxrsu`, $$css: true } }; var f2 = { root: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-1qjc9v5`, k7Eaqz: `sand-euugli`, ks0D6T: `sand-193iq5w`, kAzted: `sand-21xpn4`, kB7OPa: `sand-9f619`, kMzoRj: `sand-mkeg23`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-17tbahu sand-sb55g1`, kaIpWk: `sand-1qmwy7c`, kWkggS: `sand-10e981r`, k1ekBW: `sand-shfolx`, kIyJzY: `sand-1firant`, kAMwcw: `sand-wji4o3`, $$css: true }, rootElevated: { kaIpWk: `sand-1t6ttyj`, kWkggS: `sand-jbqb8w`, $$css: true }, rootDisabled: { kVAM5u: `sand-5fd6op`, $$css: true }, rootInvalid: { kVAM5u: `sand-uw55gi`, $$css: true }, label: { kMwMTN: `sand-1o0liin`, $$css: true }, labelElevated: { kg3NbH: `sand-fn1xvj`, $$css: true }, labelDisabled: { kMwMTN: `sand-x1phaw`, $$css: true }, revealButton: { kSGwAc: `sand-amitd3`, kmuXW: `sand-2lah0s`, k71WvV: `sand-2fvf9`, $$css: true }, revealButtonElevated: { k71WvV: `sand-1p8j9ns`, kaIpWk: `sand-1i6gnc1`, $$css: true } }; -function p2(e9) { - p2.d = 2057; - let n2 = (0, l3.c)(8), { children: i3, isDisabled: a3, isInvalid: o3, style: s3 } = e9, d3 = a3 !== void 0 && a3, m3 = o3 !== void 0 && o3, h3 = fC() === `elevated`, g3; - n2[0] !== d3 || n2[1] !== h3 || n2[2] !== m3 || n2[3] !== s3 ? (g3 = h(f2.root, h3 && f2.rootElevated, d3 && f2.rootDisabled, m3 && f2.rootInvalid, sx.body1, s3), n2[0] = d3, n2[1] = h3, n2[2] = m3, n2[3] = s3, n2[4] = g3) : g3 = n2[4]; - let _2; - return n2[5] !== i3 || n2[6] !== g3 ? (_2 = (0, u2.jsx)(`div`, { ...g3, children: i3 }), n2[5] = i3, n2[6] = g3, n2[7] = _2) : _2 = n2[7], _2; -} -function m2(e9) { - m2.d = 2058; - let r2 = (0, l3.c)(13), { label: i3, isRevealed: a3, isDisabled: s3, onToggle: c2 } = e9, d3 = s3 !== void 0 && s3, { _: p4 } = bb(), h3 = fC() === `elevated`, g3; - r2[0] !== p4 || r2[1] !== a3 || r2[2] !== i3 ? (g3 = p4(a3 ? { id: `FUGQxr`, values: { label: i3 } } : { id: `yynT8E`, values: { label: i3 } }), r2[0] = p4, r2[1] = a3, r2[2] = i3, r2[3] = g3) : g3 = r2[3]; - let _2 = a3 ? `eye-slash` : `eye`, v3 = h3 ? `lg` : `md`, y3 = h3 && f2.revealButtonElevated, b3; - r2[4] === y3 ? b3 = r2[5] : (b3 = [f2.revealButton, y3], r2[4] = y3, r2[5] = b3); - let x3; - return r2[6] !== d3 || r2[7] !== c2 || r2[8] !== g3 || r2[9] !== _2 || r2[10] !== v3 || r2[11] !== b3 ? (x3 = (0, u2.jsx)(oC, { "aria-label": g3, disabled: d3, icon: _2, iconSize: v3, onClick: c2, size: `sm`, style: b3, type: `button`, variant: `ghost` }), r2[6] = d3, r2[7] = c2, r2[8] = g3, r2[9] = _2, r2[10] = v3, r2[11] = b3, r2[12] = x3) : x3 = r2[12], x3; -} -function h2(e9) { - h2.d = 2061; - let n2 = (0, l3.c)(3), { isRequired: r2, markerStyle: i3 } = e9, o3 = i3 === void 0 ? `optional` : i3; - if (fC() !== `elevated` || o3 === `asterisk`) { - let e10; - return n2[0] === r2 ? e10 = n2[1] : (e10 = r2 ? (0, u2.jsx)(`span`, { "aria-hidden": true, children: `*` }) : null, n2[0] = r2, n2[1] = e10), e10; - } - if (r2) return null; +function p2(e38) { + p2.d = 2325; + let t2 = (0, l3.c)(8), { children: r2, isDisabled: a3, isInvalid: s3, style: c3 } = e38, d3 = a3 !== void 0 && a3, m3 = s3 !== void 0 && s3, h4 = gS() === `elevated`, g5; + t2[0] !== d3 || t2[1] !== h4 || t2[2] !== m3 || t2[3] !== c3 ? (g5 = h(f2.root, h4 && f2.rootElevated, d3 && f2.rootDisabled, m3 && f2.rootInvalid, Jb2.body1, c3), t2[0] = d3, t2[1] = h4, t2[2] = m3, t2[3] = c3, t2[4] = g5) : g5 = t2[4]; + let _5; + return t2[5] !== r2 || t2[6] !== g5 ? (_5 = (0, u2.jsx)(`div`, { ...g5, children: r2 }), t2[5] = r2, t2[6] = g5, t2[7] = _5) : _5 = t2[7], _5; +} +function m2(e38) { + m2.d = 2326; + let t2 = (0, l3.c)(13), { label: n2, isRevealed: a3, isDisabled: o3, onToggle: c3 } = e38, d3 = o3 !== void 0 && o3, { _: p4 } = fx(), h4 = gS() === `elevated`, g5; + t2[0] !== p4 || t2[1] !== a3 || t2[2] !== n2 ? (g5 = p4(a3 ? { id: `FUGQxr`, values: { label: n2 } } : { id: `yynT8E`, values: { label: n2 } }), t2[0] = p4, t2[1] = a3, t2[2] = n2, t2[3] = g5) : g5 = t2[3]; + let _5 = a3 ? `eye-slash` : `eye`, v5 = h4 ? `lg` : `md`, y4 = h4 && f2.revealButtonElevated, b2; + t2[4] === y4 ? b2 = t2[5] : (b2 = [f2.revealButton, y4], t2[4] = y4, t2[5] = b2); + let x2; + return t2[6] !== d3 || t2[7] !== c3 || t2[8] !== g5 || t2[9] !== _5 || t2[10] !== v5 || t2[11] !== b2 ? (x2 = (0, u2.jsx)(uS, { "aria-label": g5, disabled: d3, icon: _5, iconSize: v5, onClick: c3, size: `sm`, style: b2, type: `button`, variant: `ghost` }), t2[6] = d3, t2[7] = c3, t2[8] = g5, t2[9] = _5, t2[10] = v5, t2[11] = b2, t2[12] = x2) : x2 = t2[12], x2; +} +function h2(e38) { + h2.d = 2329; + let t2 = (0, l3.c)(3), { isRequired: n2, markerStyle: r2 } = e38, a3 = r2 === void 0 ? `optional` : r2, o3 = gS() === `elevated`; + if (a3 === `none`) return null; + if (!o3 || a3 === `asterisk`) { + let e39; + return t2[0] === n2 ? e39 = t2[1] : (e39 = n2 ? (0, u2.jsx)(`span`, { "aria-hidden": true, children: `*` }) : null, t2[0] = n2, t2[1] = e39), e39; + } + if (n2) return null; let s3; - return n2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = (0, u2.jsxs)(u2.Fragment, { children: [` `, (0, u2.jsx)(`span`, { className: `sand-x1phaw`, children: (0, u2.jsx)(Sb, { id: `WyGyYp` }) })] }), n2[2] = s3) : s3 = n2[2], s3; -} -function g(e9) { - g.d = 2060; - let n2 = (0, l3.c)(23), { label: a3, htmlFor: o3, isRequired: s3, isDisabled: d3, requirementMarker: p4, children: m3 } = e9, _2 = s3 !== void 0 && s3, v3 = d3 !== void 0 && d3, y3 = fC() === `elevated`, b3; - n2[0] === y3 ? b3 = n2[1] : (b3 = { 0: { className: `sand-78zum5 sand-dt5ytf sand-1jnr06f sand-euugli` }, 1: { className: `sand-78zum5 sand-dt5ytf sand-euugli sand-17d4w8g` } }[!!y3 << 0], n2[0] = y3, n2[1] = b3); - let x3; - n2[2] === y3 ? x3 = n2[3] : (x3 = h(sx.body2, y3 && f2.labelElevated), n2[2] = y3, n2[3] = x3); - let S3 = v3 && f2.labelDisabled, C2; - n2[4] === S3 ? C2 = n2[5] : (C2 = [f2.label, S3], n2[4] = S3, n2[5] = C2); - let w3; - n2[6] === p4 ? w3 = n2[7] : (w3 = p4 == null ? {} : { markerStyle: p4 }, n2[6] = p4, n2[7] = w3); - let T3; - n2[8] !== _2 || n2[9] !== w3 ? (T3 = (0, u2.jsx)(h2, { isRequired: _2, ...w3 }), n2[8] = _2, n2[9] = w3, n2[10] = T3) : T3 = n2[10]; - let E3; - n2[11] !== a3 || n2[12] !== C2 || n2[13] !== T3 ? (E3 = (0, u2.jsxs)(lx, { dir: `auto`, level: `body2`, style: C2, children: [a3, T3] }), n2[11] = a3, n2[12] = C2, n2[13] = T3, n2[14] = E3) : E3 = n2[14]; + return t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = (0, u2.jsxs)(u2.Fragment, { children: [` `, (0, u2.jsx)(`span`, { className: `sand-x1phaw`, children: (0, u2.jsx)(mx, { id: `WyGyYp` }) })] }), t2[2] = s3) : s3 = t2[2], s3; +} +function g(e38) { + g.d = 2328; + let r2 = (0, l3.c)(23), { label: a3, htmlFor: s3, isRequired: c3, isDisabled: d3, requirementMarker: p4, children: m3 } = e38, _5 = c3 !== void 0 && c3, v5 = d3 !== void 0 && d3, y4 = gS() === `elevated`, b2; + r2[0] === y4 ? b2 = r2[1] : (b2 = { 0: { className: `sand-78zum5 sand-dt5ytf sand-1jnr06f sand-euugli` }, 1: { className: `sand-78zum5 sand-dt5ytf sand-euugli sand-17d4w8g` } }[!!y4 << 0], r2[0] = y4, r2[1] = b2); + let x2; + r2[2] === y4 ? x2 = r2[3] : (x2 = h(Jb2.body2, y4 && f2.labelElevated), r2[2] = y4, r2[3] = x2); + let S2 = v5 && f2.labelDisabled, C2; + r2[4] === S2 ? C2 = r2[5] : (C2 = [f2.label, S2], r2[4] = S2, r2[5] = C2); + let w2; + r2[6] === p4 ? w2 = r2[7] : (w2 = p4 == null ? {} : { markerStyle: p4 }, r2[6] = p4, r2[7] = w2); + let T2; + r2[8] !== _5 || r2[9] !== w2 ? (T2 = (0, u2.jsx)(h2, { isRequired: _5, ...w2 }), r2[8] = _5, r2[9] = w2, r2[10] = T2) : T2 = r2[10]; + let E2; + r2[11] !== a3 || r2[12] !== C2 || r2[13] !== T2 ? (E2 = (0, u2.jsxs)(Xb2, { dir: `auto`, level: `body2`, style: C2, children: [a3, T2] }), r2[11] = a3, r2[12] = C2, r2[13] = T2, r2[14] = E2) : E2 = r2[14]; let D2; - n2[15] !== o3 || n2[16] !== x3 || n2[17] !== E3 ? (D2 = (0, u2.jsx)(`label`, { htmlFor: o3, ...x3, children: E3 }), n2[15] = o3, n2[16] = x3, n2[17] = E3, n2[18] = D2) : D2 = n2[18]; - let O3; - return n2[19] !== m3 || n2[20] !== D2 || n2[21] !== b3 ? (O3 = (0, u2.jsxs)(`div`, { ...b3, children: [D2, m3] }), n2[19] = m3, n2[20] = D2, n2[21] = b3, n2[22] = O3) : O3 = n2[22], O3; + r2[15] !== s3 || r2[16] !== x2 || r2[17] !== E2 ? (D2 = (0, u2.jsx)(`label`, { htmlFor: s3, ...x2, children: E2 }), r2[15] = s3, r2[16] = x2, r2[17] = E2, r2[18] = D2) : D2 = r2[18]; + let O2; + return r2[19] !== m3 || r2[20] !== D2 || r2[21] !== b2 ? (O2 = (0, u2.jsxs)(`div`, { ...b2, children: [D2, m3] }), r2[19] = m3, r2[20] = D2, r2[21] = b2, r2[22] = O2) : O2 = r2[22], O2; } -function _(e9) { - _.d = 2059; - let t2 = (0, l3.c)(3), { children: n2 } = e9, r2; +function _(e38) { + _.d = 2327; + let t2 = (0, l3.c)(3), { children: n2 } = e38, r2; t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { className: `sand-78zum5 sand-dt5ytf sand-1665zp3 sand-9f619 sand-h8yej3 sand-euugli sand-1tamke2` }, t2[0] = r2) : r2 = t2[0]; let i3; return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, u2.jsx)(`div`, { ...r2, children: n2 }), t2[1] = n2, t2[2] = i3), i3; } -// ../../../../../private/dist/renderer/assets/chunk-vault-card-fields-BBZgWwVF.js -var HTMLInputElement = globalThis.HTMLInputElement; -var z3 = UA(); -var B3 = Ke(); -function V3(e9) { - V3.d = 2054; - let t2 = (0, z3.c)(18), { id: n2, name: r2, label: i3, isChecked: a3, isDisabled: o3, isRequired: s3, requirementMarker: c2, ref: l4, onChange: u3 } = e9, d3 = o3 !== void 0 && o3, f4 = s3 !== void 0 && s3, p4 = c2 === void 0 ? `optional` : c2, m3; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m3 = { className: `sand-78zum5 sand-6s0dn4 sand-167g77z sand-euugli` }, t2[0] = m3) : m3 = t2[0]; - let h3; - t2[1] !== n2 || t2[2] !== a3 || t2[3] !== d3 || t2[4] !== f4 || t2[5] !== r2 || t2[6] !== u3 || t2[7] !== l4 ? (h3 = (0, B3.jsx)(OC, { id: n2, isChecked: a3, isDisabled: d3, isRequired: f4, name: r2, onChange: u3, ref: l4 }), t2[1] = n2, t2[2] = a3, t2[3] = d3, t2[4] = f4, t2[5] = r2, t2[6] = u3, t2[7] = l4, t2[8] = h3) : h3 = t2[8]; - let g3; - t2[9] !== f4 || t2[10] !== p4 ? (g3 = (0, B3.jsx)(h2, { isRequired: f4, markerStyle: p4 }), t2[9] = f4, t2[10] = p4, t2[11] = g3) : g3 = t2[11]; - let _2; - t2[12] !== i3 || t2[13] !== g3 ? (_2 = (0, B3.jsxs)(lx, { dir: `auto`, children: [i3, g3] }), t2[12] = i3, t2[13] = g3, t2[14] = _2) : _2 = t2[14]; - let y3; - return t2[15] !== h3 || t2[16] !== _2 ? (y3 = (0, B3.jsxs)(`label`, { ...m3, children: [h3, _2] }), t2[15] = h3, t2[16] = _2, t2[17] = y3) : y3 = t2[17], y3; -} -var H3 = { shell: { kXHlph: `sand-1plvlek`, kORKVm: `sand-ryxfnj`, kEafiO: `sand-972fbf`, ke9TFa: `sand-10w94by`, kt9PQ7: `sand-1qhh985`, k2ei4v: `sand-14e42zd`, kWkggS: `sand-jbqb8w`, $$css: true }, card: { kAzted: `sand-2lwn1j`, $$css: true } }; -function U3(e9) { - U3.d = 2055; - let t2 = (0, z3.c)(17), n2, r2, i3, a3; - t2[0] === e9 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4]) : ({ width: a3, initialFocus: n2, onClose: r2, ...i3 } = e9, t2[0] = e9, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3); - let o3; - t2[5] === n2 ? o3 = t2[6] : (o3 = n2 == null ? {} : { initialFocus: n2 }, t2[5] = n2, t2[6] = o3); +// ../../../../../private/dist/renderer/assets/chunk-card-dialog-DCU9ThAn.js +var h3 = Ij(); +var g2 = it(); +var _2 = { shell: { kXHlph: `sand-1plvlek`, kORKVm: `sand-ryxfnj`, kEafiO: `sand-972fbf`, ke9TFa: `sand-10w94by`, kt9PQ7: `sand-1qhh985`, k2ei4v: `sand-14e42zd`, kWkggS: `sand-jbqb8w`, $$css: true }, card: { kAzted: `sand-2lwn1j`, $$css: true }, title: { kzQI83: `sand-1iyjqo2`, k7Eaqz: `sand-euugli`, kogj98: `sand-1ghz6dp`, kHjlTd: `sand-j0a0fe`, $$css: true }, close: { kMwMTN: `sand-1o0liin`, $$css: true } }; +function v2(e38) { + v2.d = 2323; + let t2 = (0, h3.c)(17), n2, i3, a3, o3; + t2[0] === e38 ? (n2 = t2[1], i3 = t2[2], a3 = t2[3], o3 = t2[4]) : ({ width: o3, initialFocus: n2, onClose: i3, ...a3 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = i3, t2[3] = a3, t2[4] = o3); let s3; - t2[7] === r2 ? s3 = t2[8] : (s3 = (e10) => { - e10 || r2(); - }, t2[7] = r2, t2[8] = s3); - let c2; - t2[9] !== r2 || t2[10] !== i3 ? (c2 = (0, B3.jsx)(W3, { ...i3, onClose: r2 }), t2[9] = r2, t2[10] = i3, t2[11] = c2) : c2 = t2[11]; - let l4; - return t2[12] !== o3 || t2[13] !== s3 || t2[14] !== c2 || t2[15] !== a3 ? (l4 = (0, B3.jsx)(_w.Root, { ...o3, onOpenChange: s3, open: true, surfaceStyle: H3.shell, width: a3, children: c2 }), t2[12] = o3, t2[13] = s3, t2[14] = c2, t2[15] = a3, t2[16] = l4) : l4 = t2[16], l4; -} -function W3(e9) { - W3.d = 2056; - let t2 = (0, z3.c)(27), { icon: n2, label: r2, title: a3, titleInTitlebar: o3, subtitle: s3, onClose: c2, children: l4 } = e9, f4 = o3 !== void 0 && o3, { _: p4 } = bb(), { titleId: m3, descriptionId: _2 } = lp2(), v3; - t2[0] !== r2 || t2[1] !== a3 || t2[2] !== m3 || t2[3] !== f4 ? (v3 = f4 ? (0, B3.jsx)(`span`, { id: m3, children: a3 }) : r2, t2[0] = r2, t2[1] = a3, t2[2] = m3, t2[3] = f4, t2[4] = v3) : v3 = t2[4]; - let y3; - t2[5] === p4 ? y3 = t2[6] : (y3 = p4({ id: `cu6iol` }), t2[5] = p4, t2[6] = y3); - let b3; - t2[7] !== c2 || t2[8] !== y3 ? (b3 = (0, B3.jsx)(bC, { "aria-label": y3, icon: `close`, onClick: c2 }), t2[7] = c2, t2[8] = y3, t2[9] = b3) : b3 = t2[9]; - let x3; - t2[10] !== n2 || t2[11] !== v3 || t2[12] !== b3 ? (x3 = (0, B3.jsx)(vC, { icon: n2, label: v3, trailing: b3 }), t2[10] = n2, t2[11] = v3, t2[12] = b3, t2[13] = x3) : x3 = t2[13]; - let C2; - t2[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (C2 = { className: `sand-78zum5 sand-dt5ytf sand-2lwn1j sand-1odjw0f` }, t2[14] = C2) : C2 = t2[14]; - let w3; - t2[15] !== _2 || t2[16] !== s3 || t2[17] !== a3 || t2[18] !== m3 || t2[19] !== f4 ? (w3 = f4 && s3 == null ? null : (0, B3.jsx)(xC, { subtitle: s3, subtitleId: s3 == null ? void 0 : _2, title: f4 ? void 0 : a3, titleId: f4 ? void 0 : m3 }), t2[15] = _2, t2[16] = s3, t2[17] = a3, t2[18] = m3, t2[19] = f4, t2[20] = w3) : w3 = t2[20]; - let T3; - t2[21] !== l4 || t2[22] !== w3 ? (T3 = (0, B3.jsxs)(`div`, { ...C2, children: [w3, l4] }), t2[21] = l4, t2[22] = w3, t2[23] = T3) : T3 = t2[23]; - let E3; - return t2[24] !== x3 || t2[25] !== T3 ? (E3 = (0, B3.jsx)(FS.Provider, { value: null, children: (0, B3.jsx)(gC, { style: H3.card, surface: `elevated`, titlebar: x3, children: T3 }) }), t2[24] = x3, t2[25] = T3, t2[26] = E3) : E3 = t2[26], E3; -} -var G4 = u(sandVaultReact(), 1); -var te2 = /[\s-]/g; -var ne2 = /^\d{13,19}$/; -function re3(e9) { - let t2 = e9.replace(te2, ``); - if (!ne2.test(t2)) return false; + t2[5] === n2 ? s3 = t2[6] : (s3 = n2 == null ? {} : { initialFocus: n2 }, t2[5] = n2, t2[6] = s3); + let c3; + t2[7] === i3 ? c3 = t2[8] : (c3 = (e39) => { + e39 || i3(); + }, t2[7] = i3, t2[8] = c3); + let l5; + t2[9] !== i3 || t2[10] !== a3 ? (l5 = (0, g2.jsx)(y2, { ...a3, onClose: i3 }), t2[9] = i3, t2[10] = a3, t2[11] = l5) : l5 = t2[11]; + let u3; + return t2[12] !== s3 || t2[13] !== c3 || t2[14] !== l5 || t2[15] !== o3 ? (u3 = (0, g2.jsx)(CC.Root, { ...s3, onOpenChange: c3, open: true, surfaceStyle: _2.shell, width: o3, children: l5 }), t2[12] = s3, t2[13] = c3, t2[14] = l5, t2[15] = o3, t2[16] = u3) : u3 = t2[16], u3; +} +function y2(t2) { + y2.d = 2324; + let r2 = (0, h3.c)(22), { icon: f4, label: v5, title: b2, titleInTitlebar: x2, subtitle: S2, isWidget: C2, onClose: w2, children: T2 } = t2, E2 = x2 !== void 0 && x2, D2 = C2 !== void 0 && C2, { _: O2 } = fx(), { titleId: k2, descriptionId: A2 } = Gp2(), j2 = D2 ? wS : TS, M2; + r2[0] !== j2 || r2[1] !== O2 || r2[2] !== f4 || r2[3] !== v5 || r2[4] !== w2 || r2[5] !== b2 || r2[6] !== k2 || r2[7] !== E2 ? (M2 = E2 && f4 == null ? (0, g2.jsxs)(`div`, { className: `sand-78zum5 sand-6s0dn4 sand-167g77z sand-euugli sand-10dr8xq sand-f7dkkf sand-pdmqnj`, children: [(0, g2.jsx)(`h2`, { id: k2, ...h(Jb2.body1, Yb2.semibold, _2.title), children: b2 }), (0, g2.jsx)(uS, { "aria-label": O2({ id: `cu6iol` }), icon: `close`, iconSize: `lg`, onClick: w2, shape: `square`, size: `sm`, style: _2.close, variant: `ghost` })] }) : (0, g2.jsx)(SS, { icon: f4, label: E2 ? (0, g2.jsx)(`span`, { id: k2, children: b2 }) : v5, trailing: (0, g2.jsx)(j2, { "aria-label": O2({ id: `cu6iol` }), icon: `close`, onClick: w2 }) }), r2[0] = j2, r2[1] = O2, r2[2] = f4, r2[3] = v5, r2[4] = w2, r2[5] = b2, r2[6] = k2, r2[7] = E2, r2[8] = M2) : M2 = r2[8]; + let N3; + r2[9] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (N3 = { className: `sand-78zum5 sand-dt5ytf sand-2lwn1j sand-1odjw0f` }, r2[9] = N3) : N3 = r2[9]; + let P3; + r2[10] !== A2 || r2[11] !== S2 || r2[12] !== b2 || r2[13] !== k2 || r2[14] !== E2 ? (P3 = E2 && S2 == null ? null : (0, g2.jsx)(ES, { subtitle: S2, subtitleId: S2 == null ? void 0 : A2, title: E2 ? void 0 : b2, titleId: E2 ? void 0 : k2 }), r2[10] = A2, r2[11] = S2, r2[12] = b2, r2[13] = k2, r2[14] = E2, r2[15] = P3) : P3 = r2[15]; + let F2; + r2[16] !== T2 || r2[17] !== P3 ? (F2 = (0, g2.jsxs)(`div`, { ...N3, children: [P3, T2] }), r2[16] = T2, r2[17] = P3, r2[18] = F2) : F2 = r2[18]; + let I2; + return r2[19] !== M2 || r2[20] !== F2 ? (I2 = (0, g2.jsx)(Rx.Provider, { value: null, children: (0, g2.jsx)(bS, { style: _2.card, surface: `elevated`, titlebar: M2, children: F2 }) }), r2[19] = M2, r2[20] = F2, r2[21] = I2) : I2 = r2[21], I2; +} + +// ../../../../../private/dist/renderer/assets/chunk-focus-rjDPGrRu.js +var c2 = Ax(Bo3); +var l4 = c2.Scope; + +// ../../../../../private/dist/renderer/assets/chunk-pane-header-BbJph3XZ.js +var f3 = u(sandVaultReact(), 1); +var p3 = u(Ti(), 1); +var g3 = (0, f3.createContext)(null); +var _3 = g3.Provider; +function v3({ children: e38 }) { + v3.d = 2015; + let t2 = (0, f3.use)(g3); + return t2 === null ? null : (0, p3.createPortal)(e38, t2); +} + +// ../../../../../private/dist/renderer/assets/chunk-scroll-pane-BRAIVu6E.js +var i2 = Ij(); +var a2 = it(); +function o2(t2) { + o2.d = 2018; + let r2 = (0, i2.c)(18), { children: s3, ref: c3 } = t2, l5, u3, d3, f4, p4, m3; + r2[0] === c3 ? (l5 = r2[1], u3 = r2[2], d3 = r2[3], f4 = r2[4], p4 = r2[5], m3 = r2[6]) : (u3 = { className: `sand-9f619 sand-1xy6bms sand-1s169rl sand-84yb8i sand-16mx7xq` }, l5 = Cc2, r2[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f4 = $2(`sand-settings-scroll`, { className: `sand-9f619 sand-1iyjqo2 sand-s83m0k sand-dl72j9 sand-2lwn1j` }.className), r2[7] = f4) : f4 = r2[7], p4 = c3, m3 = `hover`, d3 = $2(`sand-settings-pane`, u3.className), r2[0] = c3, r2[1] = l5, r2[2] = u3, r2[3] = d3, r2[4] = f4, r2[5] = p4, r2[6] = m3); + let h4; + r2[8] !== s3 || r2[9] !== u3.style || r2[10] !== d3 ? (h4 = (0, a2.jsx)(`div`, { className: d3, style: u3.style, children: s3 }), r2[8] = s3, r2[9] = u3.style, r2[10] = d3, r2[11] = h4) : h4 = r2[11]; + let g5; + return r2[12] !== l5 || r2[13] !== f4 || r2[14] !== p4 || r2[15] !== m3 || r2[16] !== h4 ? (g5 = (0, a2.jsx)(l5, { className: f4, ref: p4, scrollbarVisibility: m3, children: h4 }), r2[12] = l5, r2[13] = f4, r2[14] = p4, r2[15] = m3, r2[16] = h4, r2[17] = g5) : g5 = r2[17], g5; +} + +// ../../../../../private/dist/renderer/assets/chunk-vault-card-dialog-C8ioyi_k.js +var document4 = globalThis.document; +var DOMException = globalThis.DOMException; +var navigator3 = globalThis.navigator; +var L2 = u(sandVaultReact(), 1); +var R2 = Ij(); +var B2 = { groupStarts: [0, 4, 10], lengths: [15] }; +var V2 = { groupStarts: [0, 4, 8, 12, 16], lengths: [13, 14, 15, 16, 17, 18, 19] }; +function H2(e38) { + return /^3[47]/.test(e38); +} +function U2(e38) { + return H2(e38) ? B2 : V2; +} +function W2(e38) { + let t2 = 0; + for (let n2 = 0; n2 < e38.length; n2++) { + let r2 = Number(e38[e38.length - 1 - n2]); + n2 % 2 == 1 && (r2 *= 2, r2 > 9 && (r2 -= 9)), t2 += r2; + } + return t2 % 10 == 0; +} +function ne2(e38) { + let t2 = e38.replace(/\D/g, ``); + return t2.length === 0 ? null : U2(t2).lengths.includes(t2.length) ? W2(t2) ? null : `luhn` : `length`; +} +var K3 = /[/\-.\s]+/; +function re2({ value: e38, previous: t2 = `` }) { + let n2 = e38.length < t2.length, [r2 = ``, ...i3] = e38.trim().split(K3), a3 = i3.length > 0, o3 = r2.replace(/\D/g, ``), s3 = o3.slice(0, 2), c3 = a3 ? i3.join(``).replace(/\D/g, ``) : o3.slice(2); + !a3 && s3.length === 2 && Number(s3) > 12 && (c3 = s3.slice(1) + c3, s3 = `0${s3.slice(0, 1)}`); + let l5 = K3.test(t2), u3 = a3 ? !l5 : s3 > `1` && !n2; + return s3.length === 1 && u3 && (s3 = `0${s3}`), c3 = c3.length === 4 ? c3.slice(2) : c3.slice(0, 2), s3.length < 2 ? a3 && l5 ? `${s3}/${c3}` : s3 : c3.length > 0 ? `${s3}/${c3}` : n2 && !a3 ? s3 : `${s3}/`; +} +var q3 = it(); +var ie2 = new URL(`amex-AaP9BS1g.svg`, import.meta.url).href; +var ae2 = `data:image/svg+xml,%3csvg%20width='35.5987'%20height='22'%20viewBox='0%200%2035.5987%2022'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Logo/Mastercard'%3e%3cpath%20id='Vector'%20d='M10.9644%200C8.05012%200.00943138%205.25868%201.17495%203.20297%203.24067C1.14726%205.30639%20-0.00470128%208.10345%201.44214e-05%2011.0177C0.00473012%2013.932%201.16573%2016.7254%203.22812%2018.7844C5.29051%2020.8435%208.0857%2021.9999%2011%2021.9999C13.9143%2021.9999%2016.7095%2020.8435%2018.7719%2018.7844C20.8343%2016.7254%2021.9953%2013.932%2022%2011.0177C22.0047%208.10345%2020.8527%205.30639%2018.797%203.24067C16.7413%201.17495%2013.9499%200.00943138%2011.0356%200L10.9644%200Z'%20fill='%23EB001B'/%3e%3cpath%20id='Vector_2'%20d='M24.5631%200C21.6488%200.00943138%2018.8574%201.17495%2016.8017%203.24067C14.746%205.30639%2013.594%208.10345%2013.5987%2011.0177C13.6034%2013.932%2014.7644%2016.7254%2016.8268%2018.7844C18.8892%2020.8435%2021.6844%2021.9999%2024.5987%2021.9999C27.513%2021.9999%2030.3082%2020.8435%2032.3706%2018.7844C34.433%2016.7254%2035.594%2013.932%2035.5987%2011.0177C35.6034%208.10345%2034.4514%205.30639%2032.3957%203.24067C30.34%201.17495%2027.5486%200.00943138%2024.6343%200L24.5631%200Z'%20fill='%23F79E1B'/%3e%3cpath%20id='Vector_3'%20d='M17.7993%202.34951C16.489%203.37876%2015.4296%204.69223%2014.7011%206.19077C13.9726%207.68931%2013.5941%209.33377%2013.5941%2011C13.5941%2012.6662%2013.9726%2014.3107%2014.7011%2015.8092C15.4296%2017.3078%2016.489%2018.6212%2017.7993%2019.6505C19.1097%2018.6212%2020.1691%2017.3078%2020.8975%2015.8092C21.626%2014.3107%2022.0045%2012.6662%2022.0045%2011C22.0045%209.33377%2021.626%207.68931%2020.8975%206.19077C20.1691%204.69223%2019.1097%203.37876%2017.7993%202.34951Z'%20fill='%23FF5F00'/%3e%3c/g%3e%3c/svg%3e`; +var oe2 = `data:image/svg+xml,%3csvg%20width='40'%20height='12.9872'%20viewBox='0%200%2040%2012.9872'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Logo/Visa'%3e%3cpath%20id='Vector'%20d='M26.0476%200.02C23.2104%200.02%2020.6748%201.4908%2020.6748%204.2076C20.6748%207.3236%2025.1716%207.5388%2025.1716%209.1044C25.1716%209.7636%2024.4164%2010.3536%2023.126%2010.3536C21.2952%2010.3536%2019.9268%209.5292%2019.9268%209.5292L19.3412%2012.2712C19.3412%2012.2712%2020.9176%2012.9676%2023.0104%2012.9676C26.1124%2012.9676%2028.5536%2011.4248%2028.5536%208.6612C28.5536%205.3684%2024.038%205.1596%2024.038%203.7068C24.038%203.1904%2024.658%202.6248%2025.9444%202.6248C27.396%202.6248%2028.58%203.2244%2028.58%203.2244L29.1532%200.5764C29.1532%200.5764%2027.8644%200.02%2026.0472%200.02H26.0476ZM0.0888%200.22L0.02%200.6196C0.02%200.6196%201.2136%200.838%202.2888%201.274C3.6732%201.7736%203.7716%202.0648%204.0048%202.968L6.5452%2012.7612H9.9508L15.1972%200.22H11.7996L8.4284%208.7468L7.0528%201.5188C6.9268%200.6916%206.2876%200.2196%205.5056%200.2196H0.0892L0.0888%200.22ZM16.5636%200.22L13.8984%2012.7612H17.1384L19.794%200.22H16.5636ZM34.634%200.22C33.8528%200.22%2033.4388%200.6384%2033.1352%201.3692L28.3884%2012.7612H31.786L32.4432%2010.8624H36.5824L36.982%2012.7612H39.98L37.3648%200.22H34.634ZM35.076%203.6084L36.0832%208.3144H33.3852L35.0764%203.6084H35.076Z'%20fill='%231434CB'/%3e%3c/g%3e%3c/svg%3e`; +var se2 = { visa: { id: `wDHlOl` }, mastercard: { id: `gPV2Ty` }, amex: { id: `k46uGm` }, discover: { id: `/XQgft` } }; +function ce3(e38) { + ce3.d = 1286; + let t2 = (0, R2.c)(22), { brand: n2 } = e38, { _: r2 } = fx(), i3 = se2[n2], a3; + t2[0] !== r2 || t2[1] !== i3 ? (a3 = r2(i3), t2[0] = r2, t2[1] = i3, t2[2] = a3) : a3 = t2[2]; + let o3 = a3; + switch (n2) { + case `visa`: { + let e39; + t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-9f619 sand-1td3qas sand-1qx5ct2 sand-b3r6kr sand-12oqio5 sand-qjedn3 sand-1y0btm7 sand-5fd6op sand-83z2og` }, t2[3] = e39) : e39 = t2[3]; + let n3; + t2[4] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n3 = { className: `sand-vy4d1p sand-t7dq6l` }, t2[4] = n3) : n3 = t2[4]; + let r3; + return t2[5] === o3 ? r3 = t2[6] : (r3 = (0, q3.jsx)(`span`, { ...e39, children: (0, q3.jsx)(`img`, { alt: o3, src: oe2, ...n3 }) }), t2[5] = o3, t2[6] = r3), r3; + } + case `mastercard`: { + let e39; + t2[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-9f619 sand-1td3qas sand-1qx5ct2 sand-b3r6kr sand-12oqio5 sand-qjedn3 sand-1y0btm7 sand-5fd6op sand-83z2og` }, t2[7] = e39) : e39 = t2[7]; + let n3; + t2[8] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n3 = { className: `sand-17z2i9w sand-t7dq6l` }, t2[8] = n3) : n3 = t2[8]; + let r3; + return t2[9] === o3 ? r3 = t2[10] : (r3 = (0, q3.jsx)(`span`, { ...e39, children: (0, q3.jsx)(`img`, { alt: o3, src: ae2, ...n3 }) }), t2[9] = o3, t2[10] = r3), r3; + } + case `amex`: { + let e39; + t2[11] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-9f619 sand-1td3qas sand-1qx5ct2 sand-b3r6kr sand-12oqio5 sand-qjedn3 sand-1y0btm7 sand-9r1u3d sand-14hfbwc` }, t2[11] = e39) : e39 = t2[11]; + let n3; + t2[12] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n3 = { className: `sand-h8yej3 sand-5yr21d sand-l1xv1r` }, t2[12] = n3) : n3 = t2[12]; + let r3; + return t2[13] === o3 ? r3 = t2[14] : (r3 = (0, q3.jsx)(`span`, { ...e39, children: (0, q3.jsx)(`img`, { alt: o3, src: ie2, ...n3 }) }), t2[13] = o3, t2[14] = r3), r3; + } + case `discover`: { + let e39; + t2[15] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-9f619 sand-1td3qas sand-1qx5ct2 sand-b3r6kr sand-12oqio5 sand-qjedn3 sand-1y0btm7 sand-5fd6op sand-83z2og` }, t2[15] = e39) : e39 = t2[15]; + let n3; + t2[16] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n3 = { className: `sand-6ijxsv sand-1xlr1w8 sand-16q24ku sand-ed0x38 sand-tvhhri` }, t2[16] = n3) : n3 = t2[16]; + let r3; + t2[17] === o3 ? r3 = t2[18] : (r3 = (0, q3.jsx)(`span`, { "aria-hidden": true, ...n3, children: o3 }), t2[17] = o3, t2[18] = r3); + let i4; + return t2[19] !== o3 || t2[20] !== r3 ? (i4 = (0, q3.jsx)(`span`, { "aria-label": o3, role: `img`, ...e39, children: r3 }), t2[19] = o3, t2[20] = r3, t2[21] = i4) : i4 = t2[21], i4; + } + } +} +var J3 = /[\s-]/g; +var le3 = /^\d{13,19}$/; +function Y4(e38) { + let t2 = e38.replace(J3, ``); + if (!le3.test(t2)) return false; let n2 = 0; - for (let e10 = 0; e10 < t2.length; e10++) { - let r2 = t2.charCodeAt(t2.length - 1 - e10) - 48; - e10 % 2 == 1 && (r2 *= 2, r2 > 9 && (r2 -= 9)), n2 += r2; + for (let e39 = 0; e39 < t2.length; e39++) { + let r2 = t2.charCodeAt(t2.length - 1 - e39) - 48; + e39 % 2 == 1 && (r2 *= 2, r2 > 9 && (r2 -= 9)), n2 += r2; } return n2 % 10 == 0; } -var K3 = [{ id: `cc_number`, label: `Card number`, type: `text`, required: true, secret: true }, { id: `cc_exp`, label: `Expiry (MM/YY)`, type: `text`, required: true }, { id: `cc_csc`, label: `Security code`, type: `text`, required: false, secret: true }, { id: `cc_name`, label: `Name on card`, type: `text`, required: false }, ...[[`billing_line1`, `Billing address`], [`billing_line2`, `Address line 2`], [`billing_city`, `City`], [`billing_region`, `State or region`], [`billing_postal_code`, `ZIP or postal code`], [`billing_country`, `Country`]].map(([e9, t2]) => ({ id: e9, label: t2, type: `text`, required: false }))]; -var q3 = /[/\-.\s]+/; -function J3({ value: e9, previous: t2 = `` }) { - let n2 = e9.length < t2.length, [r2 = ``, ...i3] = e9.trim().split(q3), a3 = i3.length > 0, o3 = r2.replace(/\D/g, ``), s3 = o3.slice(0, 2), c2 = a3 ? i3.join(``).replace(/\D/g, ``) : o3.slice(2); - !a3 && s3.length === 2 && Number(s3) > 12 && (c2 = s3.slice(1) + c2, s3 = `0${s3.slice(0, 1)}`); - let l4 = q3.test(t2), u3 = a3 ? !l4 : s3 > `1` && !n2; - return s3.length === 1 && u3 && (s3 = `0${s3}`), c2 = c2.length === 4 ? c2.slice(2) : c2.slice(0, 2), s3.length < 2 ? a3 && l4 ? `${s3}/${c2}` : s3 : c2.length > 0 ? `${s3}/${c2}` : n2 && !a3 ? s3 : `${s3}/`; -} -var $2 = [`cc_number`, `cc_exp`, `cc_name`, `cc_csc`]; -var oe3 = 200; -function se3(e9) { - return String(e9 % 100).padStart(2, `0`); -} -function ce3(e9) { - if (e9.outcome !== `read`) return {}; +var X4 = [`billing_line1`, `billing_line2`, `billing_city`, `billing_region`, `billing_postal_code`, `billing_country`]; +var ue3 = 19; +function de3(e38) { + return e38.replace(/\D/g, ``).slice(0, ue3); +} +function Z4(e38) { + let t2 = de3(e38); + return /^3[47]/.test(t2) ? `amex` : /^4/.test(t2) ? `visa` : /^(5[1-5]|2(2[2-9]|[3-6]\d|7[01]|720))/.test(t2) ? `mastercard` : /^(6011|65|64[4-9])/.test(t2) ? `discover` : null; +} +function fe3(e38) { + let t2 = e38.trim().toLowerCase().replace(/[\s_-]+/g, ``); + return t2 === `visa` ? `visa` : t2 === `mastercard` ? `mastercard` : t2 === `amex` || t2 === `americanexpress` ? `amex` : t2 === `discover` ? `discover` : null; +} +function pe3(e38, t2) { + let n2 = [], r2 = 0; + for (let i3 of t2) { + if (r2 >= e38.length) break; + n2.push(e38.slice(r2, r2 + i3)), r2 += i3; + } + return r2 < e38.length && n2.push(e38.slice(r2)), n2.join(` `); +} +function me3(e38) { + let t2 = de3(e38); + return Z4(t2) === `amex` ? pe3(t2, [4, 6, 5]) : pe3(t2, [4, 4, 4, 4]); +} +function he3(e38) { + let t2 = de3(e38), n2 = t2.slice(-4); + return Z4(t2) === `amex` ? `\u2022\u2022\u2022\u2022 \u2022\u2022\u2022\u2022\u2022\u2022 \u2022${n2}` : `\u2022\u2022\u2022\u2022 \u2022\u2022\u2022\u2022 \u2022\u2022\u2022\u2022 ${n2}`; +} +function ge3(e38) { + return Y4(de3(e38)); +} +function _e3(e38) { + return e38.replace(`/`, ` / `); +} +function ve3(e38, t2) { + let n2 = re2({ value: e38.replace(/\s+/g, ``), previous: t2 }); + if (n2 !== t2 || e38.length >= _e3(t2).length) return n2; + if (t2.endsWith(`/`)) return t2.slice(0, -1); + let r2 = t2.replace(/\D/g, ``).slice(0, -1); + return r2.length <= 2 ? r2 : `${r2.slice(0, 2)}/${r2.slice(2)}`; +} +var ye3 = [`cc_name`, `cc_nickname`, ...X4]; +function be3(e38, t2 = /* @__PURE__ */ new Date()) { + let n2 = /^(\d{2})\/(\d{2})$/.exec(e38.trim()); + if (n2 === null) return false; + let r2 = Number(n2[1]), i3 = 2e3 + Number(n2[2]); + return r2 < 1 || r2 > 12 ? false : i3 * 12 + r2 >= t2.getUTCFullYear() * 12 + t2.getUTCMonth() + 1; +} +function xe3(e38) { + return e38.replace(/\D/g, ``).slice(0, 4); +} +function Se3(e38, t2 = {}) { + let n2 = (e38.cc_exp ?? ``).trim(); + return (n2.length > 0 && n2 === (t2.cc_exp ?? ``).trim() || be3(n2)) && ye3.every((t3) => (e38[t3] ?? ``).trim().length <= 200); +} +function Ce3(e38) { + let t2 = (e38.cc_csc ?? ``).trim(); + return ge3(e38.cc_number ?? ``) && (t2.length === 0 || /^\d{3,4}$/.test(t2)) && Se3(e38); +} +function we3(e38) { + return e38.flatMap(({ id: e39, title: t2, contact: n2 }) => n2 === void 0 || n2.line1.trim().length === 0 ? [] : [{ id: e39, title: t2, contact: n2 }]).toSorted((e39, t2) => e39.title.localeCompare(t2.title)); +} +function Te3(e38) { + let t2 = Qve(e38); + return $ve(t2) ? t2 : ``; +} +function Ee3(e38) { + let t2 = new Intl.Locale(e38).maximize().region; + return Te3(t2 ?? ``) || `US`; +} +function De3(e38) { + return { billing_line1: e38.line1, billing_line2: e38.line2, billing_city: e38.city, billing_region: e38.region, billing_postal_code: e38.postalCode, billing_country: Te3(e38.country) }; +} +function Oe3(e38) { + return X4.some((t2) => t2 !== `billing_country` && (e38[t2] ?? ``).trim().length > 0); +} +function ke3(e38) { + return { line1: (e38.billing_line1 ?? ``).trim(), line2: (e38.billing_line2 ?? ``).trim(), city: (e38.billing_city ?? ``).trim(), region: (e38.billing_region ?? ``).trim(), postalCode: (e38.billing_postal_code ?? ``).trim(), country: Qve((e38.billing_country ?? ``).trim()) }; +} +function Ae3(e38, t2) { + let n2 = (e39) => e39.trim().toLowerCase().replace(/\s+/g, ` `), r2 = Qve(e38.country), i3 = Qve(t2.country); + return [`line1`, `line2`, `city`, `region`, `postalCode`].every((r3) => n2(e38[r3]) === n2(t2[r3])) && (i3 === `` || r2 === i3); +} +function je3(e38) { + let t2 = [e38.contact.line1, e38.contact.city].map((e39) => e39.trim()).filter((e39) => e39.length > 0).join(`, `); + return t2.length === 0 ? e38.title : `${e38.title} \xB7 ${t2}`; +} +function Me3(e38, t2) { + return e38 === `cc_number` ? de3(t2) : e38 === `cc_exp` ? re2({ value: t2 }) : t2; +} +function Ne3(e38) { + let t2 = {}; + for (let [n2, r2] of Object.entries(e38)) { + let e39 = Me3(n2, r2.trim()); + e39.length > 0 && (t2[n2] = e39); + } + return t2; +} +var Pe3 = { field: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kOIVth: `sand-17d4w8g`, k7Eaqz: `sand-euugli`, $$css: true }, labelRow: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-1pha0wt`, kjj79g: `sand-1qughib`, kOIVth: `sand-167g77z`, $$css: true }, label: { kMwMTN: `sand-1o0liin`, $$css: true }, optional: { kMwMTN: `sand-169k319`, $$css: true }, pair: { k1xSpc: `sand-rvj5dj`, kumcoG: `sand-cjjqqt`, k1C7PZ: `sand-tqikln`, $$css: true }, frame: { kVAEAm: `sand-1n2onr6`, k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kB7OPa: `sand-9f619`, k7Eaqz: `sand-euugli`, kZKoxP: `sand-10w6t97`, kMzoRj: `sand-qjedn3`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-17tbahu`, kaIpWk: `sand-1qmwy7c`, kWkggS: `sand-10e981r`, kYcSvW: `sand-sb55g1`, $$css: true }, frameLocked: { kWkggS: `sand-fwqdrz`, $$css: true }, frameInvalid: { kVAM5u: `sand-1370upb`, $$css: true }, input: { kzQI83: `sand-1iyjqo2`, kSGwAc: `sand-kh2ocl`, k7Eaqz: `sand-euugli`, kogj98: `sand-1ghz6dp`, k8WAf4: `sand-t970qd`, kg3NbH: `sand-1awh872`, ksu8eU: `sand-ng3xce`, kI3sdo: `sand-1a2a7pz`, kWkggS: `sand-jbqb8w`, kMv6JI: `sand-jb2p0i`, kMwMTN: `sand-tyxrsu`, k8Qsv1: `sand-1h7ufjq`, kWC4TW: `sand-1ih6jyc`, $$css: true }, inputLocked: { kMwMTN: `sand-1o0liin`, $$css: true }, digits: { kcqcaj: `sand-ss6m8b`, kb6lSQ: `sand-1dgsrnt`, $$css: true }, trailing: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kmuXW: `sand-2lah0s`, kwRFfy: `sand-1icxu4v`, $$css: true }, hint: { kMwMTN: `sand-1o0liin`, $$css: true }, warning: { kMwMTN: `sand-impobl`, $$css: true } }; +var Fe2 = Pe3; +function Ie3(e38) { + return `${e38}-warning`; +} +function Le3(e38) { + Le3.d = 1290; + let t2 = (0, R2.c)(23), { label: n2, htmlFor: r2, isOptional: i3, accessory: a3, hint: o3, warning: s3, children: c3 } = e38, u3 = i3 !== void 0 && i3, d3, f4; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (d3 = { className: `sand-78zum5 sand-dt5ytf sand-17d4w8g sand-euugli` }, f4 = { className: `sand-78zum5 sand-1pha0wt sand-1qughib sand-167g77z` }, t2[0] = d3, t2[1] = f4) : (d3 = t2[0], f4 = t2[1]); + let p4; + t2[2] === u3 ? p4 = t2[3] : (p4 = u3 ? (0, q3.jsxs)(Xb2, { level: `label`, style: Fe2.optional, children: [` `, (0, q3.jsx)(mx, { id: `WyGyYp` })] }) : null, t2[2] = u3, t2[3] = p4); + let m3; + t2[4] !== n2 || t2[5] !== p4 ? (m3 = (0, q3.jsxs)(Xb2, { level: `label`, style: Fe2.label, children: [n2, p4] }), t2[4] = n2, t2[5] = p4, t2[6] = m3) : m3 = t2[6]; + let h4; + t2[7] !== r2 || t2[8] !== m3 ? (h4 = (0, q3.jsx)(`label`, { htmlFor: r2, children: m3 }), t2[7] = r2, t2[8] = m3, t2[9] = h4) : h4 = t2[9]; + let g5; + t2[10] !== a3 || t2[11] !== h4 ? (g5 = (0, q3.jsxs)(`div`, { ...f4, children: [h4, a3] }), t2[10] = a3, t2[11] = h4, t2[12] = g5) : g5 = t2[12]; + let _5; + t2[13] !== r2 || t2[14] !== s3 ? (_5 = s3 == null ? null : (0, q3.jsx)(Xb2, { id: r2 === void 0 ? void 0 : Ie3(r2), level: `label`, role: `alert`, style: Fe2.warning, children: s3 }), t2[13] = r2, t2[14] = s3, t2[15] = _5) : _5 = t2[15]; + let v5; + t2[16] === o3 ? v5 = t2[17] : (v5 = o3 == null ? null : (0, q3.jsx)(Xb2, { level: `label`, style: Fe2.hint, children: o3 }), t2[16] = o3, t2[17] = v5); + let y4; + return t2[18] !== c3 || t2[19] !== g5 || t2[20] !== _5 || t2[21] !== v5 ? (y4 = (0, q3.jsxs)(`div`, { ...d3, children: [g5, c3, _5, v5] }), t2[18] = c3, t2[19] = g5, t2[20] = _5, t2[21] = v5, t2[22] = y4) : y4 = t2[22], y4; +} +function Re3(e38) { + Re3.d = 1293; + let t2 = (0, R2.c)(3), { children: n2 } = e38, r2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { className: `sand-rvj5dj sand-cjjqqt sand-tqikln` }, t2[0] = r2) : r2 = t2[0]; + let i3; + return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, q3.jsx)(`div`, { ...r2, children: n2 }), t2[1] = n2, t2[2] = i3), i3; +} +function ze3(e38) { + ze3.d = 1291; + let t2 = (0, R2.c)(27), n2, r2, i3, a3, o3, s3; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4], o3 = t2[5], s3 = t2[6]) : ({ trailing: s3, isLocked: i3, isInvalid: a3, isDigits: o3, onValueChange: n2, ...r2 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3, t2[5] = o3, t2[6] = s3); + let c3 = i3 !== void 0 && i3, l5 = a3 !== void 0 && a3, u3 = o3 !== void 0 && o3, d3; + t2[7] !== u3 || t2[8] !== c3 ? (d3 = h(Fe2.input, Jb2.body1, u3 && Fe2.digits, c3 && Fe2.inputLocked), t2[7] = u3, t2[8] = c3, t2[9] = d3) : d3 = t2[9]; + let f4 = d3, p4; + t2[10] !== l5 || t2[11] !== c3 ? (p4 = { 0: { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-9f619 sand-euugli sand-10w6t97 sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1qmwy7c sand-10e981r sand-sb55g1` }, 2: { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-9f619 sand-euugli sand-10w6t97 sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1qmwy7c sand-sb55g1 sand-fwqdrz` }, 1: { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-9f619 sand-euugli sand-10w6t97 sand-qjedn3 sand-1y0btm7 sand-1qmwy7c sand-10e981r sand-sb55g1 sand-1370upb` }, 3: { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-9f619 sand-euugli sand-10w6t97 sand-qjedn3 sand-1y0btm7 sand-1qmwy7c sand-sb55g1 sand-fwqdrz sand-1370upb` } }[!!c3 << 1 | !!l5 << 0], t2[10] = l5, t2[11] = c3, t2[12] = p4) : p4 = t2[12]; + let m3 = l5 || void 0, g5; + t2[13] === n2 ? g5 = t2[14] : (g5 = (e39) => n2?.(e39.currentTarget.value), t2[13] = n2, t2[14] = g5); + let _5 = c3 || r2.readOnly, v5; + t2[15] !== f4 || t2[16] !== r2 || t2[17] !== m3 || t2[18] !== g5 || t2[19] !== _5 ? (v5 = (0, q3.jsx)(`input`, { ...r2, ...f4, "aria-invalid": m3, onChange: g5, readOnly: _5 }), t2[15] = f4, t2[16] = r2, t2[17] = m3, t2[18] = g5, t2[19] = _5, t2[20] = v5) : v5 = t2[20]; + let y4; + t2[21] === s3 ? y4 = t2[22] : (y4 = s3 == null ? null : (0, q3.jsx)(`span`, { className: `sand-78zum5 sand-6s0dn4 sand-2lah0s sand-1icxu4v`, children: s3 }), t2[21] = s3, t2[22] = y4); + let b2; + return t2[23] !== y4 || t2[24] !== p4 || t2[25] !== v5 ? (b2 = (0, q3.jsxs)(`div`, { ...p4, children: [v5, y4] }), t2[23] = y4, t2[24] = p4, t2[25] = v5, t2[26] = b2) : b2 = t2[26], b2; +} +function Be3(e38) { + Be3.d = 1289; + let t2 = (0, R2.c)(20), { id: n2, value: r2, isMasked: i3, isDisabled: a3, isInvalid: o3, inputRef: s3, onValueChange: c3, onReveal: l5, onBlur: u3 } = e38, d3; + t2[0] === r2 ? d3 = t2[1] : (d3 = Z4(r2), t2[0] = r2, t2[1] = d3); + let f4 = d3, p4; + if (t2[2] !== f4 || t2[3] !== n2 || t2[4] !== s3 || t2[5] !== a3 || t2[6] !== o3 || t2[7] !== i3 || t2[8] !== u3 || t2[9] !== l5 || t2[10] !== c3 || t2[11] !== r2) { + let e39 = de3(r2), d4; + t2[13] !== n2 || t2[14] !== o3 ? (d4 = o3 ? Ie3(n2) : void 0, t2[13] = n2, t2[14] = o3, t2[15] = d4) : d4 = t2[15]; + let m3; + t2[16] === c3 ? m3 = t2[17] : (m3 = (e40) => c3(de3(e40)), t2[16] = c3, t2[17] = m3); + let h4; + t2[18] === f4 ? h4 = t2[19] : (h4 = f4 === null ? null : (0, q3.jsx)(ce3, { brand: f4 }), t2[18] = f4, t2[19] = h4), p4 = (0, q3.jsx)(ze3, { "aria-describedby": d4, autoComplete: `off`, disabled: a3, id: n2, inputMode: `numeric`, isDigits: true, isInvalid: o3, name: `cc_number`, onBlur: u3, onFocus: i3 ? l5 : void 0, onValueChange: m3, ref: s3, spellCheck: false, trailing: h4, value: i3 && e39.length > 4 ? he3(e39) : me3(e39) }), t2[2] = f4, t2[3] = n2, t2[4] = s3, t2[5] = a3, t2[6] = o3, t2[7] = i3, t2[8] = u3, t2[9] = l5, t2[10] = c3, t2[11] = r2, t2[12] = p4; + } else p4 = t2[12]; + return p4; +} +function Ve3(e38) { + Ve3.d = 1294; + let t2 = (0, R2.c)(6), { id: n2, brand: r2, last4: i3 } = e38, a3; + t2[0] === r2 ? a3 = t2[1] : (a3 = r2 === null ? null : (0, q3.jsx)(ce3, { brand: r2 }), t2[0] = r2, t2[1] = a3); + let o3 = `\u2022\u2022\u2022\u2022 ${i3}`, s3; + return t2[2] !== n2 || t2[3] !== a3 || t2[4] !== o3 ? (s3 = (0, q3.jsx)(ze3, { id: n2, isDigits: true, isLocked: true, tabIndex: -1, trailing: a3, value: o3 }), t2[2] = n2, t2[3] = a3, t2[4] = o3, t2[5] = s3) : s3 = t2[5], s3; +} +function He3(e38) { + He3.d = 1292; + let t2 = (0, R2.c)(14), { id: n2, value: r2, isDisabled: i3, isInvalid: a3, onValueChange: o3 } = e38, s3 = a3 !== void 0 && a3, { _: c3 } = fx(), l5; + t2[0] !== o3 || t2[1] !== r2 ? (l5 = (e39) => o3(ve3(e39, r2)), t2[0] = o3, t2[1] = r2, t2[2] = l5) : l5 = t2[2]; + let u3; + t2[3] === c3 ? u3 = t2[4] : (u3 = c3({ id: `Xcv4g4` }), t2[3] = c3, t2[4] = u3); + let d3; + t2[5] === r2 ? d3 = t2[6] : (d3 = _e3(r2), t2[5] = r2, t2[6] = d3); + let f4; + return t2[7] !== n2 || t2[8] !== i3 || t2[9] !== s3 || t2[10] !== l5 || t2[11] !== u3 || t2[12] !== d3 ? (f4 = (0, q3.jsx)(ze3, { autoComplete: `off`, disabled: i3, id: n2, inputMode: `numeric`, isInvalid: s3, name: `cc_exp`, onValueChange: l5, placeholder: u3, value: d3 }), t2[7] = n2, t2[8] = i3, t2[9] = s3, t2[10] = l5, t2[11] = u3, t2[12] = d3, t2[13] = f4) : f4 = t2[13], f4; +} +function Ue2(e38) { + Ue2.d = 1295; + let t2 = (0, R2.c)(21), { id: n2, value: r2, isDisabled: i3, placeholder: a3, onValueChange: o3 } = e38, { _: s3 } = fx(), [c3, l5] = (0, L2.useState)(false), u3; + t2[0] === o3 ? u3 = t2[1] : (u3 = (e39) => o3(xe3(e39)), t2[0] = o3, t2[1] = u3); + let d3; + t2[2] !== s3 || t2[3] !== c3 ? (d3 = s3(c3 ? { id: `VeOI5z` } : { id: `BqrHbB` }), t2[2] = s3, t2[3] = c3, t2[4] = d3) : d3 = t2[4]; + let f4 = c3 ? `eye-slash` : `eye`, p4; + t2[5] === c3 ? p4 = t2[6] : (p4 = () => l5(!c3), t2[5] = c3, t2[6] = p4); + let m3; + t2[7] !== i3 || t2[8] !== c3 || t2[9] !== d3 || t2[10] !== f4 || t2[11] !== p4 ? (m3 = (0, q3.jsx)(uS, { "aria-label": d3, "aria-pressed": c3, disabled: i3, icon: f4, onClick: p4, size: `xs`, variant: `ghost` }), t2[7] = i3, t2[8] = c3, t2[9] = d3, t2[10] = f4, t2[11] = p4, t2[12] = m3) : m3 = t2[12]; + let h4 = c3 ? `text` : `password`, g5; + return t2[13] !== n2 || t2[14] !== i3 || t2[15] !== a3 || t2[16] !== u3 || t2[17] !== m3 || t2[18] !== h4 || t2[19] !== r2 ? (g5 = (0, q3.jsx)(ze3, { autoComplete: `off`, disabled: i3, id: n2, inputMode: `numeric`, name: `cc_csc`, onValueChange: u3, placeholder: a3, trailing: m3, type: h4, value: r2 }), t2[13] = n2, t2[14] = i3, t2[15] = a3, t2[16] = u3, t2[17] = m3, t2[18] = h4, t2[19] = r2, t2[20] = g5) : g5 = t2[20], g5; +} +var We2 = `ABCDEFGHIJKLMNOPQRSTUVWXYZ`; +var Ge2 = fn((e38) => { + let t2 = new Intl.DisplayNames([e38], { type: `region`, fallback: `none` }), n2 = new Intl.Collator(e38); + return [...We2].flatMap((e39) => [...We2].map((t3) => `${e39}${t3}`)).filter($ve).map((e39) => ({ code: e39, label: t2.of(e39) ?? e39 })).toSorted((e39, t3) => n2.compare(e39.label, t3.label)); +}); +var Ke2 = { trigger: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-167g77z`, kB7OPa: `sand-9f619`, kzqmXN: `sand-h8yej3`, kZKoxP: `sand-10w6t97`, kogj98: `sand-1ghz6dp`, k8WAf4: `sand-t970qd`, kZCmMZ: `sand-e2zdcy`, kwRFfy: `sand-2vl965`, kMzoRj: `sand-qjedn3`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-17tbahu`, kaIpWk: `sand-1qmwy7c`, kWkggS: `sand-10e981r`, kMwMTN: `sand-tyxrsu`, k9WMMc: `sand-1yc453h`, kkrTdU: `sand-1ypdohk`, kI3sdo: `sand-1a2a7pz`, kOJeXU: `sand-16chyoa`, kYPGJ8: `sand-tgyt42`, kWC4TW: `sand-1ih6jyc`, $$css: true }, placeholder: { kMwMTN: `sand-169k319`, $$css: true }, chevron: { kmuXW: `sand-2lah0s`, kMwMTN: `sand-nxsxl2`, $$css: true }, addButton: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-167g77z`, kB7OPa: `sand-9f619`, kzqmXN: `sand-h8yej3`, kZKoxP: `sand-10w6t97`, kogj98: `sand-1ghz6dp`, k8WAf4: `sand-t970qd`, kg3NbH: `sand-1awh872`, kMzoRj: `sand-qjedn3`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-17tbahu`, kaIpWk: `sand-1qmwy7c`, kWkggS: `sand-10e981r`, kMwMTN: `sand-tyxrsu`, kkrTdU: `sand-1ypdohk`, kI3sdo: `sand-1a2a7pz`, kGzVvX: `sand-y1652t`, kOJeXU: `sand-16chyoa`, $$css: true }, linkButton: { kogj98: `sand-1ghz6dp`, k8WAf4: `sand-t970qd`, kg3NbH: `sand-njsko4`, ksu8eU: `sand-ng3xce`, kWkggS: `sand-jbqb8w`, kMwMTN: `sand-1o0liin`, kkrTdU: `sand-1ypdohk`, kDPRdz: `sand-n4ifyr`, $$css: true }, groupInput: { kzqmXN: `sand-h8yej3`, $$css: true }, select: { kysU6D: `sand-jyslct`, kwRFfy: `sand-5zjp28`, kkrTdU: `sand-1ypdohk`, $$css: true }, selectChevron: { kVAEAm: `sand-10l6tqk`, kt4wiu: `sand-o2ifbc`, kfzvcC: `sand-47corl`, kMwMTN: `sand-nxsxl2`, $$css: true }, caption: { kMwMTN: `sand-1o0liin`, $$css: true }, menu: { "--ui-select-row-min-height": `sand-tp2p40`, "--ui-select-row-padding-inline": `sand-1g5gzg9`, "--ui-select-row-gap": `sand-19nwe76`, $$css: true } }; +var qe2 = [`home`, `work`, `other`]; +var Je2 = { home: { id: `i0qMbr` }, work: { id: `qRILxq` }, other: { id: `/IX/7x` } }; +var Q4 = { home: `house`, work: `building`, other: `map-pin` }; +function Ye2(e38, t2) { + return t2(Je2[e38]); +} +function Xe2(e38, t2) { + let n2 = e38.trim().toLowerCase(); + return n2 === `office` ? `building` : Q4[qe2.find((e39) => n2 === e39 || n2 === Ye2(e39, t2).toLowerCase()) ?? `other`]; +} +var Ze2 = `add-new`; +var Qe2 = `no-address`; +function $e2(e38) { + $e2.d = 1282; + let t2 = (0, R2.c)(22), n2, r2, i3, a3; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4]) : ({ children: n2, isPlaceholder: r2, leading: i3, ...a3 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3); + let o3; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (o3 = h(Ke2.trigger, Jb2.body1), t2[5] = o3) : o3 = t2[5]; + let s3 = o3, c3; + t2[6] === a3.className ? c3 = t2[7] : (c3 = [a3.className, s3.className].filter(Boolean), t2[6] = a3.className, t2[7] = c3); + let l5 = c3.join(` `), u3; + t2[8] === a3.style ? u3 = t2[9] : (u3 = { ...a3.style, ...s3.style }, t2[8] = a3.style, t2[9] = u3); + let d3; + t2[10] === r2 ? d3 = t2[11] : (d3 = { 0: { className: `sand-1iyjqo2 sand-euugli sand-b3r6kr sand-lyipyv sand-uxw1ft` }, 1: { className: `sand-1iyjqo2 sand-euugli sand-b3r6kr sand-lyipyv sand-uxw1ft sand-169k319` } }[!!r2 << 0], t2[10] = r2, t2[11] = d3); + let f4; + t2[12] !== n2 || t2[13] !== d3 ? (f4 = (0, q3.jsx)(`span`, { ...d3, children: n2 }), t2[12] = n2, t2[13] = d3, t2[14] = f4) : f4 = t2[14]; + let p4; + t2[15] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = (0, q3.jsx)(aS, { "aria-hidden": true, name: `chevron-down`, size: `sm`, style: Ke2.chevron }), t2[15] = p4) : p4 = t2[15]; + let m3; + return t2[16] !== i3 || t2[17] !== a3 || t2[18] !== l5 || t2[19] !== u3 || t2[20] !== f4 ? (m3 = (0, q3.jsxs)(`button`, { ...a3, className: l5, style: u3, type: `button`, children: [i3, f4, p4] }), t2[16] = i3, t2[17] = a3, t2[18] = l5, t2[19] = u3, t2[20] = f4, t2[21] = m3) : m3 = t2[21], m3; +} +function et2(e38) { + et2.d = 1285; + let t2 = (0, R2.c)(34), { id: n2, contacts: r2, value: i3, isDisabled: a3, onPick: o3, onAddNew: s3, onClear: c3 } = e38, { _: l5 } = fx(), u3; + if (t2[0] !== r2 || t2[1] !== i3) { + let e39; + t2[3] === i3 ? e39 = t2[4] : (e39 = (e40) => e40.id === i3, t2[3] = i3, t2[4] = e39), u3 = r2.find(e39), t2[0] = r2, t2[1] = i3, t2[2] = u3; + } else u3 = t2[2]; + let d3 = u3, f4; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f4 = [Ke2.menu, Jb2.body1], t2[5] = f4) : f4 = t2[5]; + let m3; + t2[6] !== s3 || t2[7] !== c3 || t2[8] !== o3 ? (m3 = (e39) => { + e39 === Ze2 ? s3() : e39 === Qe2 ? c3() : e39 !== null && o3(e39); + }, t2[6] = s3, t2[7] = c3, t2[8] = o3, t2[9] = m3) : m3 = t2[9]; + let g5; + if (t2[10] !== l5 || t2[11] !== r2 || t2[12] !== d3) { + let e39; + t2[14] === l5 ? e39 = t2[15] : (e39 = (e40) => ({ value: e40.id, label: e40.title, leading: (0, q3.jsx)(aS, { "aria-hidden": true, name: Xe2(e40.title, l5), size: `lg` }) }), t2[14] = l5, t2[15] = e39); + let n3 = r2.map(e39), i4; + t2[16] === l5 ? i4 = t2[17] : (i4 = l5({ id: `wh9uml` }), t2[16] = l5, t2[17] = i4); + let a4; + t2[18] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (a4 = (0, q3.jsx)(aS, { "aria-hidden": true, name: `plus`, size: `lg` }), t2[18] = a4) : a4 = t2[18]; + let o4; + t2[19] === i4 ? o4 = t2[20] : (o4 = { value: Ze2, label: i4, leading: a4 }, t2[19] = i4, t2[20] = o4); + let s4; + t2[21] !== l5 || t2[22] !== d3 ? (s4 = d3 === void 0 ? [] : [{ value: Qe2, label: l5({ id: `MQKGE+` }), leading: (0, q3.jsx)(aS, { "aria-hidden": true, name: `close`, size: `lg` }) }], t2[21] = l5, t2[22] = d3, t2[23] = s4) : s4 = t2[23], g5 = [...n3, o4, ...s4], t2[10] = l5, t2[11] = r2, t2[12] = d3, t2[13] = g5; + } else g5 = t2[13]; + let _5; + t2[24] !== l5 || t2[25] !== d3 ? (_5 = (e39) => (0, q3.jsx)($e2, { ...e39, isPlaceholder: d3 === void 0, children: d3 === void 0 ? l5({ id: `FSBogA` }) : je3(d3) }), t2[24] = l5, t2[25] = d3, t2[26] = _5) : _5 = t2[26]; + let v5 = d3?.id ?? null, y4; + return t2[27] !== n2 || t2[28] !== a3 || t2[29] !== m3 || t2[30] !== g5 || t2[31] !== _5 || t2[32] !== v5 ? (y4 = (0, q3.jsx)(qT, { contentStyle: f4, disabled: a3, id: n2, matchAnchorWidth: true, menuSize: `md`, placement: `top-start`, onValueChange: m3, options: g5, renderTrigger: _5, value: v5 }), t2[27] = n2, t2[28] = a3, t2[29] = m3, t2[30] = g5, t2[31] = _5, t2[32] = v5, t2[33] = y4) : y4 = t2[33], y4; +} +function tt2(e38) { + tt2.d = 1281; + let t2 = (0, R2.c)(19), { value: n2, isDisabled: r2, onChange: i3 } = e38, { _: a3 } = fx(), o3; + if (t2[0] !== a3 || t2[1] !== r2 || t2[2] !== i3 || t2[3] !== n2) { + let e39 = Ge2(), s4 = n2.length === 0 || e39.some((e40) => e40.code === n2), c4; + t2[5] === a3 ? c4 = t2[6] : (c4 = a3({ id: `JNCzPW` }), t2[5] = a3, t2[6] = c4); + let l5; + t2[7] === i3 ? l5 = t2[8] : (l5 = (e40) => i3(e40.currentTarget.value), t2[7] = i3, t2[8] = l5); + let u3; + t2[9] === n2.length ? u3 = t2[10] : (u3 = h(Pe3.input, Jb2.body1, Ke2.select, n2.length === 0 && Ke2.placeholder), t2[9] = n2.length, t2[10] = u3); + let d3; + t2[11] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (d3 = h(d2.option), t2[11] = d3) : d3 = t2[11]; + let f4; + t2[12] === a3 ? f4 = t2[13] : (f4 = a3({ id: `JNCzPW` }), t2[12] = a3, t2[13] = f4); + let p4; + t2[14] === f4 ? p4 = t2[15] : (p4 = (0, q3.jsx)(`option`, { value: ``, ...d3, children: f4 }), t2[14] = f4, t2[15] = p4), o3 = (0, q3.jsxs)(`select`, { "aria-label": c4, autoComplete: `country`, disabled: r2, name: `billing_country`, onChange: l5, value: n2, ...u3, children: [p4, s4 ? null : (0, q3.jsx)(`option`, { value: n2, ...h(d2.option), children: n2 }), e39.map(nt2)] }), t2[0] = a3, t2[1] = r2, t2[2] = i3, t2[3] = n2, t2[4] = o3; + } else o3 = t2[4]; + let s3; + t2[16] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = (0, q3.jsx)(aS, { "aria-hidden": true, name: `chevron-down`, size: `sm`, style: Ke2.selectChevron }), t2[16] = s3) : s3 = t2[16]; + let c3; + return t2[17] === o3 ? c3 = t2[18] : (c3 = (0, q3.jsxs)(q3.Fragment, { children: [o3, s3] }), t2[17] = o3, t2[18] = c3), c3; +} +function nt2(e38) { + return (0, q3.jsx)(`option`, { value: e38.code, ...h(d2.option), children: e38.label }, e38.code); +} +function rt3(e38) { + rt3.d = 1283; + let t2 = (0, R2.c)(11), { name: n2, value: r2, label: i3, placeholder: a3, autoComplete: o3, isDisabled: s3, onChange: c3 } = e38, l5; + t2[0] === c3 ? l5 = t2[1] : (l5 = (e39) => c3(e39.currentTarget.value), t2[0] = c3, t2[1] = l5); + let u3; + t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u3 = h(Pe3.input, Jb2.body1, Ke2.groupInput), t2[2] = u3) : u3 = t2[2]; + let d3; + return t2[3] !== o3 || t2[4] !== s3 || t2[5] !== i3 || t2[6] !== n2 || t2[7] !== a3 || t2[8] !== l5 || t2[9] !== r2 ? (d3 = (0, q3.jsx)(`input`, { "aria-label": i3, autoComplete: o3, disabled: s3, name: n2, onChange: l5, placeholder: a3, value: r2, ...u3 }), t2[3] = o3, t2[4] = s3, t2[5] = i3, t2[6] = n2, t2[7] = a3, t2[8] = l5, t2[9] = r2, t2[10] = d3) : d3 = t2[10], d3; +} +function it3(e38) { + it3.d = 1284; + let t2 = (0, R2.c)(45), { address: n2, isDisabled: r2, onAddressChange: i3 } = e38, { _: a3 } = fx(), o3; + t2[0] !== n2 || t2[1] !== r2 || t2[2] !== i3 ? (o3 = (e39, t3, a4, o4) => (0, q3.jsx)(rt3, { autoComplete: o4, isDisabled: r2, label: t3, name: e39, onChange: (t4) => i3(e39, t4), placeholder: a4, value: n2[e39] }), t2[0] = n2, t2[1] = r2, t2[2] = i3, t2[3] = o3) : o3 = t2[3]; + let s3 = o3, c3; + t2[4] === a3 ? c3 = t2[5] : (c3 = a3({ id: `gzEjAL` }), t2[4] = a3, t2[5] = c3); + let l5, u3; + t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = { className: `sand-78zum5 sand-dt5ytf sand-b3r6kr sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1qmwy7c sand-10e981r` }, u3 = { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-10w6t97 sand-euugli` }, t2[6] = l5, t2[7] = u3) : (l5 = t2[6], u3 = t2[7]); + let d3; + t2[8] === i3 ? d3 = t2[9] : (d3 = (e39) => i3(`billing_country`, e39), t2[8] = i3, t2[9] = d3); + let f4; + t2[10] !== n2.billing_country || t2[11] !== r2 || t2[12] !== d3 ? (f4 = (0, q3.jsx)(`div`, { ...u3, children: (0, q3.jsx)(tt2, { isDisabled: r2, onChange: d3, value: n2.billing_country }) }), t2[10] = n2.billing_country, t2[11] = r2, t2[12] = d3, t2[13] = f4) : f4 = t2[13]; + let p4; + t2[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-10w6t97 sand-euugli sand-1hc762m sand-13fuv20 sand-13nz628` }, t2[14] = p4) : p4 = t2[14]; + let m3; + t2[15] !== a3 || t2[16] !== s3 ? (m3 = (0, q3.jsx)(`div`, { ...p4, children: s3(`billing_line1`, a3({ id: `C9VfWO` }), a3({ id: `C9VfWO` }), `address-line1`) }), t2[15] = a3, t2[16] = s3, t2[17] = m3) : m3 = t2[17]; + let h4; + t2[18] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h4 = { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-10w6t97 sand-euugli sand-1hc762m sand-13fuv20 sand-13nz628` }, t2[18] = h4) : h4 = t2[18]; + let g5; + t2[19] !== a3 || t2[20] !== s3 ? (g5 = (0, q3.jsx)(`div`, { ...h4, children: s3(`billing_line2`, a3({ id: `cnJuer` }), a3({ id: `LH5rTq` }), `address-line2`) }), t2[19] = a3, t2[20] = s3, t2[21] = g5) : g5 = t2[21]; + let _5, v5; + t2[22] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (_5 = { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-10w6t97 sand-euugli sand-1hc762m sand-13fuv20 sand-13nz628` }, v5 = { className: `sand-78zum5 sand-6s0dn4 sand-kh2ocl sand-euugli sand-10icjm1 sand-1r8uery` }, t2[22] = _5, t2[23] = v5) : (_5 = t2[22], v5 = t2[23]); + let y4; + t2[24] !== a3 || t2[25] !== s3 ? (y4 = (0, q3.jsx)(`div`, { ...v5, children: s3(`billing_city`, a3({ id: `3wV73y` }), a3({ id: `3wV73y` }), `address-level2`) }), t2[24] = a3, t2[25] = s3, t2[26] = y4) : y4 = t2[26]; + let b2; + t2[27] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (b2 = { className: `sand-78zum5 sand-6s0dn4 sand-kh2ocl sand-euugli sand-1iyjqo2 sand-1r8uery sand-1sd92yl sand-1t7ytsu sand-5x6ma4` }, t2[27] = b2) : b2 = t2[27]; + let x2; + t2[28] !== a3 || t2[29] !== s3 ? (x2 = (0, q3.jsx)(`div`, { ...b2, children: s3(`billing_region`, a3({ id: `RS0o7b` }), a3({ id: `RS0o7b` }), `address-level1`) }), t2[28] = a3, t2[29] = s3, t2[30] = x2) : x2 = t2[30]; + let S2; + t2[31] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (S2 = { className: `sand-78zum5 sand-6s0dn4 sand-kh2ocl sand-euugli sand-1iyjqo2 sand-1r8uery sand-1sd92yl sand-1t7ytsu sand-5x6ma4` }, t2[31] = S2) : S2 = t2[31]; + let C2; + t2[32] !== a3 || t2[33] !== s3 ? (C2 = (0, q3.jsx)(`div`, { ...S2, children: s3(`billing_postal_code`, a3({ id: `pVZUS0` }), a3({ id: `pVZUS0` }), `postal-code`) }), t2[32] = a3, t2[33] = s3, t2[34] = C2) : C2 = t2[34]; + let w2; + t2[35] !== y4 || t2[36] !== x2 || t2[37] !== C2 ? (w2 = (0, q3.jsxs)(`div`, { ..._5, children: [y4, x2, C2] }), t2[35] = y4, t2[36] = x2, t2[37] = C2, t2[38] = w2) : w2 = t2[38]; + let T2; + return t2[39] !== g5 || t2[40] !== w2 || t2[41] !== c3 || t2[42] !== f4 || t2[43] !== m3 ? (T2 = (0, q3.jsxs)(`div`, { role: `group`, "aria-label": c3, ...l5, children: [f4, m3, g5, w2] }), t2[39] = g5, t2[40] = w2, t2[41] = c3, t2[42] = f4, t2[43] = m3, t2[44] = T2) : T2 = t2[44], T2; +} +function at2(e38) { + at2.d = 1280; + let t2 = (0, R2.c)(15), { id: n2, value: r2, isDisabled: i3, onChange: a3 } = e38, { _: o3 } = fx(), s3; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = [Ke2.menu, Jb2.body1], t2[0] = s3) : s3 = t2[0]; + let c3; + t2[1] === a3 ? c3 = t2[2] : (c3 = (e39) => { + e39 !== null && a3(e39); + }, t2[1] = a3, t2[2] = c3); + let l5; + t2[3] === o3 ? l5 = t2[4] : (l5 = qe2.map((e39) => ({ value: e39, label: o3(Je2[e39]), leading: (0, q3.jsx)(aS, { "aria-hidden": true, name: Q4[e39], size: `lg` }) })), t2[3] = o3, t2[4] = l5); + let u3; + t2[5] !== o3 || t2[6] !== r2 ? (u3 = (e39) => (0, q3.jsx)($e2, { ...e39, isPlaceholder: false, leading: (0, q3.jsx)(aS, { "aria-hidden": true, name: Q4[r2], size: `lg` }), children: o3(Je2[r2]) }), t2[5] = o3, t2[6] = r2, t2[7] = u3) : u3 = t2[7]; + let d3; + return t2[8] !== n2 || t2[9] !== i3 || t2[10] !== c3 || t2[11] !== l5 || t2[12] !== u3 || t2[13] !== r2 ? (d3 = (0, q3.jsx)(qT, { contentStyle: s3, disabled: i3, id: n2, matchAnchorWidth: true, menuSize: `md`, onValueChange: c3, options: l5, renderTrigger: u3, value: r2 }), t2[8] = n2, t2[9] = i3, t2[10] = c3, t2[11] = l5, t2[12] = u3, t2[13] = r2, t2[14] = d3) : d3 = t2[14], d3; +} +function ot2(e38) { + ot2.d = 1279; + let t2 = (0, R2.c)(43), { contacts: n2, choice: r2, address: i3, contact: a3, isDisabled: o3, onPickSaved: s3, onStartNew: c3, onUseSaved: u3, onClear: d3, onAddressChange: f4, onContactChange: p4 } = e38, { _: m3 } = fx(), g5 = (0, L2.useId)(), _5 = (0, L2.useId)(), v5 = (0, L2.useId)(), y4; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (y4 = (0, q3.jsx)(mx, { id: `gzEjAL` }), t2[0] = y4) : y4 = t2[0]; + let b2 = y4; + if (r2.kind !== `new`) { + if (n2.length === 0) { + let e40, n3, r3; + t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e40 = h(Ke2.addButton, Jb2.body1), n3 = (0, q3.jsx)(aS, { "aria-hidden": true, color: `secondary`, name: `plus`, size: `sm` }), r3 = (0, q3.jsx)(mx, { id: `6PgkkY` }), t2[1] = e40, t2[2] = n3, t2[3] = r3) : (e40 = t2[1], n3 = t2[2], r3 = t2[3]); + let i5; + t2[4] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i5 = (0, q3.jsxs)(`span`, { children: [r3, ` `, (0, q3.jsx)(Xb2, { style: Pe3.optional, children: (0, q3.jsx)(mx, { id: `WyGyYp` }) })] }), t2[4] = i5) : i5 = t2[4]; + let a5; + return t2[5] !== o3 || t2[6] !== c3 ? (a5 = (0, q3.jsxs)(`button`, { disabled: o3, onClick: c3, type: `button`, ...e40, children: [n3, i5] }), t2[5] = o3, t2[6] = c3, t2[7] = a5) : a5 = t2[7], a5; + } + let e39 = r2.kind === `saved` ? r2.id : null, i4; + t2[8] !== n2 || t2[9] !== o3 || t2[10] !== d3 || t2[11] !== s3 || t2[12] !== c3 || t2[13] !== g5 || t2[14] !== e39 ? (i4 = (0, q3.jsx)(et2, { contacts: n2, id: g5, isDisabled: o3, onAddNew: c3, onClear: d3, onPick: s3, value: e39 }), t2[8] = n2, t2[9] = o3, t2[10] = d3, t2[11] = s3, t2[12] = c3, t2[13] = g5, t2[14] = e39, t2[15] = i4) : i4 = t2[15]; + let a4; + return t2[16] !== g5 || t2[17] !== i4 ? (a4 = (0, q3.jsx)(Le3, { htmlFor: g5, isOptional: true, label: b2, children: i4 }), t2[16] = g5, t2[17] = i4, t2[18] = a4) : a4 = t2[18], a4; + } + let x2; + t2[19] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (x2 = { className: `sand-78zum5 sand-dt5ytf sand-ou54vl` }, t2[19] = x2) : x2 = t2[19]; + let S2; + t2[20] !== n2.length || t2[21] !== o3 || t2[22] !== u3 ? (S2 = n2.length === 0 ? null : (0, q3.jsx)(`button`, { disabled: o3, onClick: u3, type: `button`, ...h(Ke2.linkButton, Jb2.label), children: (0, q3.jsx)(mx, { id: `AUlTmE` }) }), t2[20] = n2.length, t2[21] = o3, t2[22] = u3, t2[23] = S2) : S2 = t2[23]; + let C2; + t2[24] !== i3 || t2[25] !== o3 || t2[26] !== f4 ? (C2 = (0, q3.jsx)(it3, { address: i3, isDisabled: o3, onAddressChange: f4 }), t2[24] = i3, t2[25] = o3, t2[26] = f4, t2[27] = C2) : C2 = t2[27]; + let w2; + t2[28] !== S2 || t2[29] !== C2 ? (w2 = (0, q3.jsx)(Le3, { accessory: S2, isOptional: true, label: b2, children: C2 }), t2[28] = S2, t2[29] = C2, t2[30] = w2) : w2 = t2[30]; + let T2; + t2[31] !== m3 || t2[32] !== i3 || t2[33] !== r2.savesContact || t2[34] !== a3 || t2[35] !== o3 || t2[36] !== v5 || t2[37] !== p4 || t2[38] !== _5 ? (T2 = r2.savesContact && i3.billing_line1.trim().length > 0 ? (0, q3.jsxs)(q3.Fragment, { children: [(0, q3.jsxs)(`div`, { ...h(Pe3.pair), children: [(0, q3.jsx)(Le3, { htmlFor: _5, label: (0, q3.jsx)(mx, { id: `+zy2Nq` }), children: (0, q3.jsx)(at2, { id: _5, isDisabled: o3, onChange: (e39) => p4({ ...a3, type: e39 }), value: a3.type }) }), (0, q3.jsx)(Le3, { htmlFor: v5, label: (0, q3.jsx)(mx, { id: `Z6JctO` }), children: (0, q3.jsx)(ze3, { autoComplete: `name`, disabled: o3, id: v5, onValueChange: (e39) => p4({ ...a3, name: e39 }), value: a3.name }) })] }), (0, q3.jsx)(Xb2, { level: `label`, style: Ke2.caption, children: m3({ id: `h2nxQP` }) })] }) : null, t2[31] = m3, t2[32] = i3, t2[33] = r2.savesContact, t2[34] = a3, t2[35] = o3, t2[36] = v5, t2[37] = p4, t2[38] = _5, t2[39] = T2) : T2 = t2[39]; + let E2; + return t2[40] !== w2 || t2[41] !== T2 ? (E2 = (0, q3.jsxs)(`div`, { ...x2, children: [w2, T2] }), t2[40] = w2, t2[41] = T2, t2[42] = E2) : E2 = t2[42], E2; +} +var pt2 = [`cc_number`, `cc_exp`, `cc_name`, `cc_csc`]; +var mt3 = 200; +function ht2(e38) { + return String(e38 % 100).padStart(2, `0`); +} +function gt(e38) { + if (e38.outcome !== `read`) return {}; let t2 = {}; - re3(e9.number) && (t2.cc_number = e9.number); - let n2 = e9.expYear > 0 && e9.expYear < 100 ? 2e3 + e9.expYear : e9.expYear; - Number.isInteger(e9.expMonth) && e9.expMonth >= 1 && e9.expMonth <= 12 && Number.isInteger(n2) && n2 >= 2e3 && n2 <= 2099 && (t2.cc_exp = `${se3(e9.expMonth)}/${se3(n2)}`); - let r2 = e9.cardholderName.trim(); - r2.length > 0 && r2.length <= oe3 && !/\d/.test(r2) && (t2.cc_name = r2); - let i3 = e9.securityCode; + Y4(e38.number) && (t2.cc_number = e38.number); + let n2 = e38.expYear > 0 && e38.expYear < 100 ? 2e3 + e38.expYear : e38.expYear; + Number.isInteger(e38.expMonth) && e38.expMonth >= 1 && e38.expMonth <= 12 && Number.isInteger(n2) && n2 >= 2e3 && n2 <= 2099 && (t2.cc_exp = `${ht2(e38.expMonth)}/${ht2(n2)}`); + let r2 = e38.cardholderName.trim(); + r2.length > 0 && r2.length <= mt3 && !/\d/.test(r2) && (t2.cc_name = r2); + let i3 = e38.securityCode; if (t2.cc_number !== void 0 && i3 !== void 0) { - let e10 = t2.cc_number.replace(/[\s-]/g, ``), n3 = /^3[47][0-9]{13}$/.test(e10) ? 4 : 3; + let e39 = t2.cc_number.replace(/[\s-]/g, ``), n3 = /^3[47][0-9]{13}$/.test(e39) ? 4 : 3; i3.length === n3 && /^[0-9]+$/.test(i3) && (t2.cc_csc = i3); } return t2; } -function de3(e9, t2) { - let n2 = [...e9], r2 = e9.reduce((e10, t3) => e10 + t3.size, 0), i3 = null; - for (let e10 of t2) !_ge.has(e10.type) || e10.size === 0 ? i3 ??= `not_image` : n2.length >= 4 ? i3 ??= `too_many` : r2 + e10.size > 20971520 ? i3 ??= `too_large` : (n2.push(e10), r2 += e10.size); +function yt2(e38, t2) { + let n2 = [...e38], r2 = e38.reduce((e39, t3) => e39 + t3.size, 0), i3 = null; + for (let e39 of t2) !f_2.has(e39.type) || e39.size === 0 ? i3 ??= `not_image` : n2.length >= 4 ? i3 ??= `too_many` : r2 + e39.size > 20971520 ? i3 ??= `too_large` : (n2.push(e39), r2 += e39.size); return { photos: n2, refusal: i3 }; } -function fe3(e9) { - if (e9 === void 0) return false; - for (let t2 of e9) if (t2 === `Files`) return true; +function bt2(e38) { + if (e38 === void 0) return false; + for (let t2 of e38) if (t2 === `Files`) return true; return false; } -var pe3 = { hint: { kMwMTN: `sand-1o0liin`, $$css: true }, retry: { kLKAdn: `sand-exx8yu`, kwRFfy: `sand-yri2b`, kGO01o: `sand-18d9i69`, kZCmMZ: `sand-1c1uobl`, $$css: true }, thumbnailRemove: { kVAEAm: `sand-10l6tqk`, k87sOh: `sand-tu2xtp`, kt4wiu: `sand-1euzuty`, $$css: true } }; -function me3(e9) { - switch (e9) { +function St2(e38) { + switch (e38) { case `not_image`: return { id: `ifXMoM` }; case `too_many`: @@ -4938,539 +12135,1145 @@ function me3(e9) { return { id: `/j84aQ` }; } } -var he3 = { id: `1TWWPH` }; -var ge2 = { id: `1u/HkJ` }; -var _e2 = { id: `6XoriY` }; -var ve2 = { id: `IelWbl` }; -var ye2 = { id: `qM7vSa` }; -var be2 = { id: `MYVRIX` }; -var xe2 = { id: `8Hi+X6` }; -var Se2 = { id: `r46SKb` }; -async function Ce2(e9, t2, n2) { +var Ct = { id: `1TWWPH` }; +var wt = { id: `1u/HkJ` }; +var Tt = { id: `6XoriY` }; +var Et = { id: `IelWbl` }; +var Dt2 = { id: `qM7vSa` }; +var Ot2 = { id: `MYVRIX` }; +var kt2 = { id: `8Hi+X6` }; +var At = { id: `r46SKb` }; +async function jt(e38, t2, n2) { try { - let r2 = await e9({ photos: await Promise.all(t2.map(async (e10) => ({ image: new Uint8Array(await e10.arrayBuffer()), mimeType: e10.type }))) }, { signal: n2 }); + let r2 = await e38({ photos: await Promise.all(t2.map(async (e39) => ({ image: new Uint8Array(await e39.arrayBuffer()), mimeType: e39.type }))) }, { signal: n2 }); switch (r2.outcome) { case `rate_limited`: - return { message: ge2, values: null, canRetry: true }; + return { message: wt, values: null, canRetry: true }; case `unavailable`: - return { message: _e2, values: null, canRetry: true }; + return { message: Tt, values: null, canRetry: true }; case `refused`: - return { message: ve2, values: null, canRetry: false }; + return { message: Et, values: null, canRetry: false }; case `invalid_photo`: - return { message: ye2, values: null, canRetry: false }; + return { message: Dt2, values: null, canRetry: false }; case `not_found`: - return { message: he3, values: null, canRetry: true }; + return { message: Ct, values: null, canRetry: true }; case `read`: { - let e10 = ce3(r2); - return Object.keys(e10).length === 0 ? { message: he3, values: null, canRetry: true } : { message: e10.cc_number !== void 0 && e10.cc_exp !== void 0 ? xe2 : Se2, values: e10, canRetry: false }; + let e39 = gt(r2); + return Object.keys(e39).length === 0 ? { message: Ct, values: null, canRetry: true } : { message: e39.cc_number !== void 0 && e39.cc_exp !== void 0 ? kt2 : At, values: e39, canRetry: false }; } } - } catch (e10) { - return n2.aborted ? null : (ol(e10, { tags: { sand_area: `card-photo-fill` } }), { message: be2, values: null, canRetry: true }); + } catch (e39) { + return n2.aborted ? null : (el2(e39, { tags: { sand_area: `card-photo-fill` } }), { message: Ot2, values: null, canRetry: true }); } } -function we2({ values: e9, before: t2, after: n2, filled: r2 }) { +function Mt2({ values: e38, before: t2, after: n2, filled: r2 }) { let i3 = {}; - for (let a3 of $2) { - let o3 = e9[a3], s3 = n2[a3] ?? ``; + for (let a3 of pt2) { + let o3 = e38[a3], s3 = n2[a3] ?? ``; o3 !== void 0 && (t2[a3] ?? ``) === s3 && s3 === (r2[a3] ?? ``) && (i3[a3] = o3); } - return i3; -} -function Te() { - let e9 = null; - return { start() { - return e9?.abort(), e9 = new AbortController(), e9.signal; - }, arm: () => () => { - e9?.abort(), e9 = null; + return i3; +} +function Nt() { + let e38 = null; + return { start() { + return e38?.abort(), e38 = new AbortController(), e38.signal; + }, arm: () => () => { + e38?.abort(), e38 = null; + } }; +} +function Pt2(e38) { + return (e38.metaKey || e38.ctrlKey) && !e38.altKey && e38.key.toLowerCase() === `v`; +} +function It2(e38) { + let { photos: t2, refusal: n2 } = yt2([], e38), r2 = t2.map((e39, t3) => ({ key: t3 + 1, file: e39 })); + return n2 === null || r2.length > 0 ? { photos: r2, refusal: n2, status: { kind: `idle` } } : { photos: r2, refusal: n2, status: { kind: `settled`, message: St2(n2), notice: null, isFilled: false, canRetry: false, refusal: n2, isUnreadable: false } }; +} +function Lt2(e38) { + let t2 = (0, R2.c)(63), { canAct: i3, currentValues: a3, onFill: o3, onPhotosOffered: s3, initialFiles: c3 } = e38, l5 = s3 === void 0 ? Ut2 : s3, u3; + t2[0] === c3 ? u3 = t2[1] : (u3 = c3 === void 0 ? [] : c3, t2[0] = c3, t2[1] = u3); + let d3 = u3, f4 = v_2(), p4 = Au(m_2), m3 = Au(h_2), h4 = p4 && m3, g5 = Nu2(), b2; + t2[2] === g5 ? b2 = t2[3] : (b2 = () => (g5(m_2), g5(h_2), Ht3), t2[2] = g5, t2[3] = b2), DE(b2); + let x2 = EE(a3), C2 = EE(o3), T2 = EE(l5), [E2] = (0, L2.useState)(Nt); + DE(E2.arm); + let D2; + t2[4] !== d3 || t2[5] !== h4 ? (D2 = () => It2(h4 ? d3 : []), t2[4] = d3, t2[5] = h4, t2[6] = D2) : D2 = t2[6]; + let [k2] = (0, L2.useState)(D2), [A2, j2] = (0, L2.useState)(k2.status), [M2, N3] = (0, L2.useState)(k2.photos), [ee2, P3] = (0, L2.useState)(false), F2 = (0, L2.useRef)(0), I2 = (0, L2.useRef)(k2.photos.length), te2; + t2[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (te2 = {}, t2[7] = te2) : te2 = t2[7]; + let z2 = (0, L2.useRef)(te2), B3 = (0, L2.useRef)(null), V3 = h4 && i3, H3 = A2.kind === `reading`, U3; + t2[8] !== C2 || t2[9] !== x2 || t2[10] !== E2 || t2[11] !== f4.readCardPhoto ? (U3 = async function(e39) { + let t3 = E2.start(), n2 = x2(); + j2({ kind: `reading` }); + let r2 = await jt(f4.readCardPhoto, e39.map(Vt2), t3); + if (r2 === null || t3.aborted) return; + if (r2.values !== null) { + let e40 = Mt2({ values: r2.values, before: n2, after: x2(), filled: z2.current }); + z2.current = { ...z2.current, ...e40 }, C2(e40); + } + let i4 = B3.current; + B3.current = null, j2({ kind: `settled`, message: r2.message, notice: i4, isFilled: r2.values !== null, canRetry: r2.canRetry, refusal: null, isUnreadable: r2.message === Ct || r2.message === Ot2 || r2.message === Dt2 }); + }, t2[8] = C2, t2[9] = x2, t2[10] = E2, t2[11] = f4.readCardPhoto, t2[12] = U3) : U3 = t2[12]; + let W3 = U3, G2; + t2[13] !== V3 || t2[14] !== H3 || t2[15] !== M2 || t2[16] !== W3 || t2[17] !== T2 ? (G2 = function(e39) { + if (!V3 || e39.length === 0) return; + T2(); + let { photos: t3, refusal: n2 } = yt2(M2.map(Bt2), e39), r2 = t3.slice(M2.length).map((e40) => ({ key: I2.current += 1, file: e40 })); + if (B3.current = n2 === null ? null : St2(n2), r2.length > 0) { + let e40 = [...M2, ...r2]; + N3(e40), W3(e40); + return; + } + n2 !== null && !H3 && (B3.current = null, j2({ kind: `settled`, message: St2(n2), notice: null, isFilled: false, canRetry: false, refusal: n2, isUnreadable: false })); + }, t2[13] = V3, t2[14] = H3, t2[15] = M2, t2[16] = W3, t2[17] = T2, t2[18] = G2) : G2 = t2[18]; + let ne3 = G2, K4; + t2[19] !== V3 || t2[20] !== H3 || t2[21] !== W3 || t2[22] !== T2 ? (K4 = function(e39) { + if (!V3 || e39.length === 0) return; + T2(); + let { photos: t3, refusal: n2 } = yt2([], e39); + if (t3.length === 0) { + n2 !== null && H3 ? B3.current = St2(n2) : n2 !== null && j2({ kind: `settled`, message: St2(n2), notice: null, isFilled: false, canRetry: false, refusal: n2, isUnreadable: false }); + return; + } + let r2 = t3.map((e40) => ({ key: I2.current += 1, file: e40 })); + B3.current = n2 === null ? null : St2(n2), N3(r2), W3(r2); + }, t2[19] = V3, t2[20] = H3, t2[21] = W3, t2[22] = T2, t2[23] = K4) : K4 = t2[23]; + let re3 = K4, q4; + t2[24] !== V3 || t2[25] !== H3 || t2[26] !== M2 || t2[27] !== W3 ? (q4 = function() { + V3 && !H3 && M2.length !== 0 && (B3.current = null, W3(M2)); + }, t2[24] = V3, t2[25] = H3, t2[26] = M2, t2[27] = W3, t2[28] = q4) : q4 = t2[28]; + let ie3 = q4, ae3; + t2[29] !== H3 || t2[30] !== M2 ? (ae3 = function(e39) { + if (H3) return; + let t3 = M2.find((t4) => t4.key === e39); + t3 !== void 0 && (N3(M2.filter((e40) => e40 !== t3)), B3.current = null, j2({ kind: `idle` })); + }, t2[29] = H3, t2[30] = M2, t2[31] = ae3) : ae3 = t2[31]; + let oe5 = ae3, se5; + t2[32] !== k2.photos || t2[33] !== k2.refusal || t2[34] !== V3 || t2[35] !== W3 ? (se5 = () => (V3 && k2.photos.length > 0 && (B3.current = k2.refusal === null ? null : St2(k2.refusal), W3(k2.photos)), zt2), t2[32] = k2.photos, t2[33] = k2.refusal, t2[34] = V3, t2[35] = W3, t2[36] = se5) : se5 = t2[36], DE(EE(se5)); + let ce6; + t2[37] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (ce6 = function(e39) { + return bt2(e39.dataTransfer?.types); + }, t2[37] = ce6) : ce6 = t2[37]; + let J4 = ce6, le6 = V3 && A2.kind === `settled` && A2.canRetry && M2.length > 0, Y6; + t2[38] === ne3 ? Y6 = t2[39] : (Y6 = (e39) => { + e39.stopPropagation(); + let t3 = P0(e39.clipboardData); + t3.length !== 0 && (e39.preventDefault(), ne3(t3)); + }, t2[38] = ne3, t2[39] = Y6); + let X6, ue6; + t2[40] === V3 ? (X6 = t2[41], ue6 = t2[42]) : (X6 = (e39) => { + J4(e39) && (e39.preventDefault(), e39.stopPropagation(), F2.current += 1, V3 && P3(true)); + }, ue6 = (e39) => { + J4(e39) && (e39.preventDefault(), e39.stopPropagation(), e39.dataTransfer != null && (e39.dataTransfer.dropEffect = V3 ? `copy` : `none`)); + }, t2[40] = V3, t2[41] = X6, t2[42] = ue6); + let de6; + t2[43] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (de6 = (e39) => { + J4(e39) && (e39.stopPropagation(), F2.current = Math.max(0, F2.current - 1), F2.current === 0 && P3(false)); + }, t2[43] = de6) : de6 = t2[43]; + let Z6; + t2[44] === ne3 ? Z6 = t2[45] : (Z6 = (e39) => { + J4(e39) && (e39.preventDefault(), e39.stopPropagation(), F2.current = 0, P3(false), ne3(Array.from(e39.dataTransfer?.files ?? []))); + }, t2[44] = ne3, t2[45] = Z6); + let fe5; + t2[46] !== Y6 || t2[47] !== X6 || t2[48] !== ue6 || t2[49] !== Z6 ? (fe5 = { onKeyDown: Rt2, onPaste: Y6, onDragEnter: X6, onDragOver: ue6, onDragLeave: de6, onDrop: Z6 }, t2[46] = Y6, t2[47] = X6, t2[48] = ue6, t2[49] = Z6, t2[50] = fe5) : fe5 = t2[50]; + let pe5; + return t2[51] !== ne3 || t2[52] !== V3 || t2[53] !== ee2 || t2[54] !== h4 || t2[55] !== M2 || t2[56] !== oe5 || t2[57] !== re3 || t2[58] !== ie3 || t2[59] !== A2 || t2[60] !== le6 || t2[61] !== fe5 ? (pe5 = { isEnabled: h4, isActive: V3, status: A2, isDragOver: ee2, photos: M2, addFiles: ne3, replaceFiles: re3, removePhoto: oe5, canRetry: le6, retry: ie3, boundaryProps: fe5 }, t2[51] = ne3, t2[52] = V3, t2[53] = ee2, t2[54] = h4, t2[55] = M2, t2[56] = oe5, t2[57] = re3, t2[58] = ie3, t2[59] = A2, t2[60] = le6, t2[61] = fe5, t2[62] = pe5) : pe5 = t2[62], pe5; +} +function Rt2(e38) { + Pt2(e38) && e38.stopPropagation(); +} +function zt2() { +} +function Bt2(e38) { + return e38.file; +} +function Vt2(e38) { + return e38.file; +} +function Ht3() { +} +function Ut2() { +} +function Wt2(e38) { + Wt2.d = 980; + let t2 = (0, R2.c)(7), { fill: n2, isEnabled: r2, children: i3 } = e38, a3 = r2 === void 0 || r2, o3; + t2[0] !== n2 || t2[1] !== a3 ? (o3 = a3 ? n2.boundaryProps : {}, t2[0] = n2, t2[1] = a3, t2[2] = o3) : o3 = t2[2]; + let s3; + t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = { className: `sand-jp7ctv` }, t2[3] = s3) : s3 = t2[3]; + let c3; + return t2[4] !== i3 || t2[5] !== o3 ? (c3 = (0, q3.jsx)(`div`, { ...o3, ...s3, children: i3 }), t2[4] = i3, t2[5] = o3, t2[6] = c3) : c3 = t2[6], c3; +} +var Jt3 = { label: { kMwMTN: `sand-1o0liin`, $$css: true }, value: { k7Eaqz: `sand-euugli`, kMwMTN: `sand-tyxrsu`, kHjlTd: `sand-j0a0fe`, $$css: true }, address: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kOIVth: `sand-195vfkc`, k7Eaqz: `sand-euugli`, $$css: true } }; +function Yt3(e38) { + Yt3.d = 1288; + let t2 = (0, R2.c)(16), { label: n2, isFirst: r2, isTop: i3, trailing: a3, children: o3 } = e38, s3 = i3 !== void 0 && i3, c3 = a3 === void 0 ? null : a3, u3; + t2[0] !== r2 || t2[1] !== s3 ? (u3 = { 0: { className: `sand-rvj5dj sand-1bd8qys sand-6s0dn4 sand-tqikln sand-3sc9yq sand-9f619 sand-10dr8xq sand-aope02` }, 2: { className: `sand-rvj5dj sand-1bd8qys sand-6s0dn4 sand-tqikln sand-3sc9yq sand-9f619 sand-10dr8xq sand-aope02 sand-1hc762m sand-13fuv20 sand-13nz628` }, 1: { className: `sand-rvj5dj sand-1bd8qys sand-tqikln sand-3sc9yq sand-9f619 sand-10dr8xq sand-aope02 sand-7a106z` }, 3: { className: `sand-rvj5dj sand-1bd8qys sand-tqikln sand-3sc9yq sand-9f619 sand-10dr8xq sand-aope02 sand-1hc762m sand-13fuv20 sand-13nz628 sand-7a106z` } }[!r2 << 1 | !!s3 << 0], t2[0] = r2, t2[1] = s3, t2[2] = u3) : u3 = t2[2]; + let d3; + t2[3] === n2 ? d3 = t2[4] : (d3 = (0, q3.jsx)(Xb2, { level: `label`, style: Jt3.label, children: n2 }), t2[3] = n2, t2[4] = d3); + let f4; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f4 = h(Jt3.value, Jb2.body1), t2[5] = f4) : f4 = t2[5]; + let p4; + t2[6] === o3 ? p4 = t2[7] : (p4 = (0, q3.jsx)(`span`, { ...f4, children: o3 }), t2[6] = o3, t2[7] = p4); + let m3; + t2[8] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m3 = { className: `sand-78zum5 sand-169k319` }, t2[8] = m3) : m3 = t2[8]; + let g5; + t2[9] === c3 ? g5 = t2[10] : (g5 = (0, q3.jsx)(`span`, { ...m3, children: c3 }), t2[9] = c3, t2[10] = g5); + let _5; + return t2[11] !== u3 || t2[12] !== d3 || t2[13] !== p4 || t2[14] !== g5 ? (_5 = (0, q3.jsxs)(`div`, { ...u3, children: [d3, p4, g5] }), t2[11] = u3, t2[12] = d3, t2[13] = p4, t2[14] = g5, t2[15] = _5) : _5 = t2[15], _5; +} +function Xt3(e38) { + let { line1: t2, city: n2 } = e38.billingAddress; + return [t2, n2].filter((e39) => e39.trim().length > 0).join(`, `); +} +function Zt3(e38) { + Zt3.d = 1287; + let t2 = (0, R2.c)(17), { card: n2, contact: r2, isDisabled: i3, onOpenBilling: a3 } = e38, { _: o3 } = fx(), s3 = String(n2.expMonth), c3; + t2[0] === s3 ? c3 = t2[1] : (c3 = s3.padStart(2, `0`), t2[0] = s3, t2[1] = c3); + let u3 = String(n2.expYear % 100), d3; + t2[2] === u3 ? d3 = t2[3] : (d3 = u3.padStart(2, `0`), t2[2] = u3, t2[3] = d3); + let f4 = `${c3}/${d3}`, p4; + t2[4] === n2 ? p4 = t2[5] : (p4 = Xt3(n2), t2[4] = n2, t2[5] = p4); + let m3 = p4, g5; + if (t2[6] !== o3 || t2[7] !== m3 || t2[8] !== n2.holderName || t2[9] !== n2.last4 || t2[10] !== n2.nickname || t2[11] !== r2 || t2[12] !== f4 || t2[13] !== i3 || t2[14] !== a3) { + let e39 = []; + n2.nickname.length > 0 && e39.push({ key: `nickname`, render: (e40) => (0, q3.jsx)(Yt3, { isFirst: e40, label: (0, q3.jsx)(mx, { id: `4hfTrB` }), children: n2.nickname }) }), e39.push({ key: `number`, render: (e40) => (0, q3.jsx)(Yt3, { isFirst: e40, label: (0, q3.jsx)(mx, { id: `HptUxX` }), trailing: (0, q3.jsx)(aS, { "aria-label": o3({ id: `G2fuEb` }), name: `lock`, size: `sm` }), children: (0, q3.jsx)(`span`, { className: `sand-ss6m8b sand-1dgsrnt`, children: `\u2022\u2022\u2022\u2022 ${n2.last4}` }) }) }), n2.holderName.length > 0 && e39.push({ key: `holder`, render: (e40) => (0, q3.jsx)(Yt3, { isFirst: e40, label: (0, q3.jsx)(mx, { id: `Mf9Gtf` }), children: n2.holderName }) }), e39.push({ key: `expiry`, render: (e40) => (0, q3.jsx)(Yt3, { isFirst: e40, label: (0, q3.jsx)(mx, { id: `KnN1Tu` }), children: (0, q3.jsx)(`span`, { className: `sand-ss6m8b sand-1dgsrnt`, children: f4 }) }) }), m3.length > 0 && e39.push({ key: `billing`, render: (e40) => (0, q3.jsxs)(`button`, { disabled: i3, onClick: a3, type: `button`, ...{ 0: { className: `sand-rvj5dj sand-1bd8qys sand-tqikln sand-3sc9yq sand-9f619 sand-10dr8xq sand-aope02 sand-7a106z sand-h8yej3 sand-1ghz6dp sand-1yc453h sand-uxrje7 sand-1qhh985 sand-jbqb8w sand-1heor9g sand-jb2p0i sand-1ypdohk sand-tgyt42` }, 1: { className: `sand-rvj5dj sand-1bd8qys sand-tqikln sand-3sc9yq sand-9f619 sand-10dr8xq sand-aope02 sand-7a106z sand-h8yej3 sand-1ghz6dp sand-1yc453h sand-uxrje7 sand-1qhh985 sand-jbqb8w sand-1heor9g sand-jb2p0i sand-1ypdohk sand-tgyt42 sand-1hc762m sand-13fuv20 sand-13nz628` } }[!e40 << 0], children: [(0, q3.jsx)(Xb2, { level: `label`, style: Jt3.label, children: (0, q3.jsx)(mx, { id: `gzEjAL` }) }), (0, q3.jsxs)(`span`, { ...h(Jt3.address, Jb2.body1), children: [r2 === void 0 ? null : (0, q3.jsxs)(`span`, { className: `sand-78zum5 sand-6s0dn4 sand-17d4w8g`, children: [(0, q3.jsx)(aS, { "aria-hidden": true, color: `secondary`, name: `person`, size: `sm` }), (0, q3.jsx)(`span`, { children: r2.title })] }), (0, q3.jsx)(`span`, { ...{ 0: { className: `sand-1o0liin` }, 1: {} }[(r2 === void 0) << 0], children: m3 })] }), (0, q3.jsx)(`span`, { className: `sand-78zum5 sand-169k319 sand-amitd3`, children: (0, q3.jsx)(aS, { "aria-hidden": true, name: `chevron-right`, size: `sm` }) })] }) }); + let s4; + t2[16] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s4 = { className: `sand-78zum5 sand-dt5ytf sand-1ghz6dp sand-1717udv sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1q4ynmn` }, t2[16] = s4) : s4 = t2[16], g5 = (0, q3.jsx)(`div`, { ...s4, children: e39.map(Qt3) }), t2[6] = o3, t2[7] = m3, t2[8] = n2.holderName, t2[9] = n2.last4, t2[10] = n2.nickname, t2[11] = r2, t2[12] = f4, t2[13] = i3, t2[14] = a3, t2[15] = g5; + } else g5 = t2[15]; + return g5; +} +function Qt3(e38, t2) { + return (0, q3.jsx)(L2.Fragment, { children: e38.render(t2 === 0) }, e38.key); +} +function $t3({ hasCaptured: e38, sidesRead: t2, values: n2, asks: r2 }) { + if (!e38 || t2 !== 1) return null; + let i3 = r2.securityCode && (n2.cc_csc ?? ``).trim().length === 0, a3 = r2.holderName && (n2.cc_name ?? ``).trim().length === 0; + return i3 && a3 ? `both` : i3 ? `security_code` : a3 ? `name` : null; +} +function en3(e38) { + return e38 === `both` ? [`cc_csc`, `cc_name`] : e38 === `security_code` ? [`cc_csc`] : [`cc_name`]; +} +function tn3({ current: e38, read: t2 }) { + let n2 = {}; + for (let r2 of pt2) { + let i3 = t2[r2]; + i3 !== void 0 && (e38[r2] ?? ``).trim().length === 0 && (n2[r2] = i3); + } + return n2; +} +function nn3(e38, t2 = false) { + return t2 ? `flip-missing` : e38 === `back` ? `back` : `line-up`; +} +function rn2({ clock: e38, side: t2 = `front`, sidesRead: n2 = [], wants: r2 = [], capture: i3, screen: a3, read: o3, onPhase: s3, onEnd: c3, onError: l5, tickMs: u3 = 900, readEveryTicks: d3 = 3, dimAfterMisses: f4 = 2, giveUpAfterMisses: p4 = 5, giveUpAfterWrongSideReads: m3 = 10, hintBackAfterTicks: h4 = 5 }) { + let g5 = false, _5 = 0, v5 = -1 / 0, y4 = 0, b2 = 0, x2 = a3 !== null, S2 = null, C2 = n2.length > 0, w2 = nn3(t2, C2), T2 = null, E2 = new AbortController(); + function D2(e39) { + g5 || e39 === w2 || (w2 = e39, s3(e39)); + } + function O2(e39) { + g5 || (g5 = true, S2 = null, T2?.dispose(), T2 = null, c3(e39)); + } + function k2() { + return C2 ? y4 >= f4 ? `dim` : `flip-missing` : S2 === null ? t2 === `back` ? y4 >= f4 ? `dim` : `back` : b2 > 0 ? `back-hint` : y4 >= f4 ? `dim` : _5 >= h4 ? `back-hint` : `line-up` : `flip`; + } + function A2() { + y4 += 1, y4 >= p4 ? O2({ kind: `failed`, reason: `not_found` }) : D2(k2()); + } + async function j2(e39) { + v5 = _5, D2(S2 === null && t2 === `front` ? `hold-still` : `hold-still-back`); + let n3 = await o3(e39, E2.signal); + if (g5) return; + if (n3.outcome === `not_found`) { + A2(); + return; + } + if (n3.outcome !== `read`) { + O2({ kind: `failed`, reason: n3.outcome }); + return; + } + let i4 = gt(n3); + if (C2) { + r2.some((e40) => i4[e40] !== void 0) ? O2({ kind: `read`, values: i4, photos: e39 }) : A2(); + return; + } + if (i4.cc_number !== void 0) { + O2({ kind: `read`, values: i4, photos: e39 }); + return; + } + if (S2 !== null || i4.cc_exp === void 0 && i4.cc_name === void 0) { + A2(); + return; + } + if (t2 === `front` && i4.cc_exp !== void 0 && e39[0] !== void 0) { + S2 = e39[0], D2(`flip`); + return; + } + b2 += 1, b2 >= m3 ? O2({ kind: `failed`, reason: `not_found` }) : D2(k2()); + } + function M2(e39) { + return C2 ? [...n2, e39] : S2 === null ? [e39] : [S2, e39]; + } + async function N3() { + let e39 = await i3(); + if (e39 === null || g5) return; + _5 += 1; + let n3 = _5 - v5 >= d3; + if (S2 === null && !C2 && x2 && a3 !== null) { + let r3 = await a3({ image: e39.image.slice(), mimeType: e39.mimeType }); + if (g5) return; + if (r3.outcome === `clear` || t2 === `back` && r3.outcome === `card_without_number`) { + D2(k2()); + return; + } + if (r3.outcome === `unavailable`) x2 = false; + else { + D2(t2 === `back` ? `hold-still-back` : `hold-still`), n3 && await j2(M2(e39)); + return; + } + } + if (!n3) { + S2 === null && D2(k2()); + return; + } + await j2(M2(e39)); + } + function ee2() { + T2 = e38.schedule(u3, () => { + T2 = null, !g5 && N3().catch((e39) => { + g5 || (l5?.(e39), O2({ kind: `failed`, reason: `error` })); + }).finally(() => { + g5 || ee2(); + }); + }); + } + return ee2(), { dispose() { + g5 = true, S2 = null, E2.abort(), T2?.dispose(), T2 = null; } }; } -function Ee2(e9) { - return (e9.metaKey || e9.ctrlKey) && !e9.altKey && e9.key.toLowerCase() === `v`; -} -function De2(e9) { - De2.d = 903; - let t2 = (0, z3.c)(6), { file: n2, alt: r2 } = e9, i3; - t2[0] === n2 ? i3 = t2[1] : (i3 = (e10) => { - if (e10 === null) return; - let t3 = URL.createObjectURL(n2); - return e10.src = t3, () => URL.revokeObjectURL(t3); - }, t2[0] = n2, t2[1] = i3); - let a3 = i3, o3; - t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (o3 = { className: `sand-1lliihq sand-h8yej3 sand-5yr21d sand-l1xv1r sand-1qmwy7c sand-qjedn3 sand-1y0btm7 sand-5fd6op` }, t2[2] = o3) : o3 = t2[2]; - let s3; - return t2[3] !== r2 || t2[4] !== a3 ? (s3 = (0, B3.jsx)(`img`, { alt: r2, ref: a3, ...o3 }), t2[3] = r2, t2[4] = a3, t2[5] = s3) : s3 = t2[5], s3; -} -function Oe2(e9) { - let { photos: t2, refusal: n2 } = de3([], e9), r2 = t2.map((e10, t3) => ({ key: t3 + 1, file: e10 })); - return n2 === null || r2.length > 0 ? { photos: r2, refusal: n2, status: { kind: `idle` } } : { photos: r2, refusal: n2, status: { kind: `settled`, message: me3(n2), notice: null, isFilled: false, canRetry: false } }; -} -function ke2(e9) { - let r2 = (0, z3.c)(56), { canAct: i3, currentValues: a3, onFill: o3, initialFiles: s3 } = e9, c2; - r2[0] === s3 ? c2 = r2[1] : (c2 = s3 === void 0 ? [] : s3, r2[0] = s3, r2[1] = c2); - let u3 = c2, d3 = kge(), f4 = wu(y_), m3 = wu(yge), h3 = f4 && m3, g3 = Ou(), v3; - r2[2] === g3 ? v3 = r2[3] : (v3 = () => (g3(y_), g3(yge), Pe), r2[2] = g3, r2[3] = v3), Bw(v3); - let y3 = zw(a3), S3 = zw(o3), [C2] = (0, G4.useState)(Te); - Bw(C2.arm); - let w3; - r2[4] !== u3 || r2[5] !== h3 ? (w3 = () => Oe2(h3 ? u3 : []), r2[4] = u3, r2[5] = h3, r2[6] = w3) : w3 = r2[6]; - let [T3] = (0, G4.useState)(w3), [E3, D2] = (0, G4.useState)(T3.status), [k4, ee2] = (0, G4.useState)(T3.photos), [A3, j3] = (0, G4.useState)(false), M3 = (0, G4.useRef)(0), N2 = (0, G4.useRef)(T3.photos.length), P2; - r2[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (P2 = {}, r2[7] = P2) : P2 = r2[7]; - let F2 = (0, G4.useRef)(P2), I = (0, G4.useRef)(null), L = h3 && i3, R3 = E3.kind === `reading`, B4; - r2[8] !== S3 || r2[9] !== y3 || r2[10] !== C2 || r2[11] !== d3.readCardPhoto ? (B4 = async function(e10) { - let t2 = C2.start(), n2 = y3(); - D2({ kind: `reading` }); - let r3 = await Ce2(d3.readCardPhoto, e10.map(Ne), t2); - if (r3 === null || t2.aborted) return; - if (r3.values !== null) { - let e11 = we2({ values: r3.values, before: n2, after: y3(), filled: F2.current }); - F2.current = { ...F2.current, ...e11 }, S3(e11); - } - let i4 = I.current; - I.current = null, D2({ kind: `settled`, message: r3.message, notice: i4, isFilled: r3.values !== null, canRetry: r3.canRetry }); - }, r2[8] = S3, r2[9] = y3, r2[10] = C2, r2[11] = d3.readCardPhoto, r2[12] = B4) : B4 = r2[12]; - let V4 = B4, H4; - r2[13] !== L || r2[14] !== R3 || r2[15] !== k4 || r2[16] !== V4 ? (H4 = function(e10) { - if (!L || e10.length === 0) return; - let { photos: t2, refusal: n2 } = de3(k4.map(Me), e10), r3 = t2.slice(k4.length).map((e11) => ({ key: N2.current += 1, file: e11 })); - if (I.current = n2 === null ? null : me3(n2), r3.length > 0) { - let e11 = [...k4, ...r3]; - ee2(e11), V4(e11); - return; - } - n2 !== null && !R3 && (I.current = null, D2({ kind: `settled`, message: me3(n2), notice: null, isFilled: false, canRetry: false })); - }, r2[13] = L, r2[14] = R3, r2[15] = k4, r2[16] = V4, r2[17] = H4) : H4 = r2[17]; - let U4 = H4, W4; - r2[18] !== L || r2[19] !== R3 || r2[20] !== k4 || r2[21] !== V4 ? (W4 = function() { - L && !R3 && k4.length !== 0 && (I.current = null, V4(k4)); - }, r2[18] = L, r2[19] = R3, r2[20] = k4, r2[21] = V4, r2[22] = W4) : W4 = r2[22]; - let te3 = W4, ne3; - r2[23] !== R3 || r2[24] !== k4 ? (ne3 = function(e10) { - if (R3) return; - let t2 = k4.find((t3) => t3.key === e10); - t2 !== void 0 && (ee2(k4.filter((e11) => e11 !== t2)), I.current = null, D2({ kind: `idle` })); - }, r2[23] = R3, r2[24] = k4, r2[25] = ne3) : ne3 = r2[25]; - let re4 = ne3, K4; - r2[26] !== T3.photos || r2[27] !== T3.refusal || r2[28] !== L || r2[29] !== V4 ? (K4 = () => (L && T3.photos.length > 0 && (I.current = T3.refusal === null ? null : me3(T3.refusal), V4(T3.photos)), je2), r2[26] = T3.photos, r2[27] = T3.refusal, r2[28] = L, r2[29] = V4, r2[30] = K4) : K4 = r2[30], Bw(zw(K4)); - let q4; - r2[31] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (q4 = function(e10) { - return fe3(e10.dataTransfer?.types); - }, r2[31] = q4) : q4 = r2[31]; - let J4 = q4, ie4 = L && E3.kind === `settled` && E3.canRetry && k4.length > 0, Y4; - r2[32] === U4 ? Y4 = r2[33] : (Y4 = (e10) => { - e10.stopPropagation(); - let t2 = k2(e10.clipboardData); - t2.length !== 0 && (e10.preventDefault(), U4(t2)); - }, r2[32] = U4, r2[33] = Y4); - let X4, Z4; - r2[34] === L ? (X4 = r2[35], Z4 = r2[36]) : (X4 = (e10) => { - J4(e10) && (e10.preventDefault(), e10.stopPropagation(), M3.current += 1, L && j3(true)); - }, Z4 = (e10) => { - J4(e10) && (e10.preventDefault(), e10.stopPropagation(), e10.dataTransfer != null && (e10.dataTransfer.dropEffect = L ? `copy` : `none`)); - }, r2[34] = L, r2[35] = X4, r2[36] = Z4); - let ae4; - r2[37] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (ae4 = (e10) => { - J4(e10) && (e10.stopPropagation(), M3.current = Math.max(0, M3.current - 1), M3.current === 0 && j3(false)); - }, r2[37] = ae4) : ae4 = r2[37]; - let Q3; - r2[38] === U4 ? Q3 = r2[39] : (Q3 = (e10) => { - J4(e10) && (e10.preventDefault(), e10.stopPropagation(), M3.current = 0, j3(false), U4(Array.from(e10.dataTransfer?.files ?? []))); - }, r2[38] = U4, r2[39] = Q3); - let $4; - r2[40] !== Y4 || r2[41] !== X4 || r2[42] !== Z4 || r2[43] !== Q3 ? ($4 = { onKeyDown: Ae2, onPaste: Y4, onDragEnter: X4, onDragOver: Z4, onDragLeave: ae4, onDrop: Q3 }, r2[40] = Y4, r2[41] = X4, r2[42] = Z4, r2[43] = Q3, r2[44] = $4) : $4 = r2[44]; - let oe5; - return r2[45] !== U4 || r2[46] !== L || r2[47] !== A3 || r2[48] !== h3 || r2[49] !== k4 || r2[50] !== re4 || r2[51] !== te3 || r2[52] !== E3 || r2[53] !== ie4 || r2[54] !== $4 ? (oe5 = { isEnabled: h3, isActive: L, status: E3, isDragOver: A3, photos: k4, addFiles: U4, removePhoto: re4, canRetry: ie4, retry: te3, boundaryProps: $4 }, r2[45] = U4, r2[46] = L, r2[47] = A3, r2[48] = h3, r2[49] = k4, r2[50] = re4, r2[51] = te3, r2[52] = E3, r2[53] = ie4, r2[54] = $4, r2[55] = oe5) : oe5 = r2[55], oe5; +var an2 = 1200; +var on = 1280; +var sn2 = 0.86; +var cn2 = `M40.6667 11.1667C41 10.8333 41.4444 10.6667 42 10.6667C42.5556 10.6667 43 10.8889 43.3333 11.3333C43.7778 11.6667 44 12.1111 44 12.6667C44 13.1111 43.7778 13.5556 43.3333 14L21 36.3333C20.3333 37 19.5 37.3333 18.5 37.3333C17.5 37.3333 16.6667 37 16 36.3333L4.66667 24.8333C4.22222 24.5 4 24.0556 4 23.5C4 22.9444 4.16667 22.5 4.5 22.1667C4.94444 21.7222 5.44444 21.5 6 21.5C6.55556 21.5 7 21.7222 7.33333 22.1667L18.5 33.1667L40.6667 11.1667Z`; +var ln2 = { blankText: { kMwMTN: `sand-1o0liin`, $$css: true }, settingsButton: { kogj98: `sand-1ghz6dp`, k8WAf4: `sand-12ulsxz`, kg3NbH: `sand-1awh872`, ksu8eU: `sand-ng3xce`, kaIpWk: `sand-149ho13`, kWkggS: `sand-10e981r`, kMwMTN: `sand-tyxrsu`, kkrTdU: `sand-1ypdohk`, kGzVvX: `sand-y1652t`, $$css: true }, pill: { kVAEAm: `sand-10l6tqk`, kkqhue: `sand-17y0mx6`, k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kzqmXN: `sand-eq5yr9`, ks0D6T: `sand-18b33ah`, kB7OPa: `sand-9f619`, kUOVxO: `sand-vueqy4`, kaIpWk: `sand-149ho13`, kWkggS: `sand-150l7so`, k6WDB: `sand-1dmgsgi`, kMwMTN: `sand-5a26a2`, khDVqt: `sand-uxw1ft`, $$css: true }, hint: { krVfgx: `sand-qo3gd`, k8WAf4: `sand-ifx94n`, kg3NbH: `sand-1awh872`, $$css: true }, backButton: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kSGwAc: `sand-amitd3`, kOIVth: `sand-1jnr06f`, kogj98: `sand-1ghz6dp`, k8WAf4: `sand-12ulsxz`, kg3NbH: `sand-1awh872`, ksu8eU: `sand-ng3xce`, kaIpWk: `sand-149ho13`, kWkggS: `sand-jbqb8w`, kMwMTN: `sand-1o0liin`, kkrTdU: `sand-1ypdohk`, kGzVvX: `sand-11hyl0l`, kDPRdz: `sand-n4ifyr`, $$css: true }, backButtonHidden: { k33iCy: `sand-lshs6z`, $$css: true }, camera: { k87sOh: `sand-fr5jun`, kOIVth: `sand-1jnr06f`, kqGvvJ: `sand-10im51j`, k8WAf4: `sand-1t0vds8`, kg3NbH: `sand-dqyycr`, ksu8eU: `sand-ng3xce`, kkrTdU: `sand-1ypdohk`, kI3sdo: `sand-1a2a7pz`, kEtg5x: `sand-e6bv58`, $$css: true }, cameraMenu: { "--ui-select-row-min-height": `sand-xeedxy`, "--ui-select-row-padding-inline": `sand-1g5gzg9`, "--ui-select-row-gap": `sand-19nwe76`, $$css: true }, cameraChevron: { kMwMTN: `sand-11w3uhm`, $$css: true } }; +var un2 = /\s*\(built-in\)\s*$/i; +var dn2 = /\s*\([0-9a-f]{4}:[0-9a-f]{4}\)\s*$/i; +function fn3(e38) { + return un2.test(e38) || /facetime|integrated/i.test(e38) ? { name: e38.replace(un2, ``), icon: `laptop`, description: { id: `+7fBMP` } } : /iphone|ipad/i.test(e38) ? { name: e38, icon: `mobile`, description: null } : dn2.test(e38) ? { name: e38.replace(dn2, ``), icon: `video-camera`, description: { id: `NrMd9u` } } : { name: e38, icon: `video-camera`, description: null }; +} +var pn2 = { "line-up": { id: `Ikf/KX` }, "back-hint": { id: `GAK8qU` }, back: { id: `dgUkd2` }, "hold-still": { id: `w2hLRY` }, "hold-still-back": { id: `W+e0Zq` }, flip: { id: `r12mm7` }, dim: { id: `t4ThUL` } }; +var mn2 = { security_code: { id: `QPdeRz` }, name: { id: `1wzE+F` }, both: { id: `OGNd+N` } }; +var hn2 = { not_found: { id: `JVB7m7` }, rate_limited: { id: `J0eoz+` }, unavailable: { id: `p+R6vr` }, refused: { id: `HRNsFh` }, invalid_photo: { id: `zQUSik` }, error: { id: `zQUSik` } }; +function gn2(e38) { + let t2 = e38 instanceof DOMException || e38 instanceof Error ? e38.name : ``; + return t2 === `NotAllowedError` || t2 === `SecurityError` ? { kind: `denied` } : t2 === `NotFoundError` || t2 === `OverconstrainedError` ? { kind: `none` } : { kind: `error` }; +} +function _n2(e38) { + return document4.addEventListener(`visibilitychange`, e38), () => document4.removeEventListener(`visibilitychange`, e38); +} +function vn2() { + return document4.visibilityState === `visible`; +} +async function yn2(e38) { + if (e38 === null || e38.readyState < 2 || e38.videoWidth === 0) return null; + let t2 = Math.min(1, on / e38.videoWidth), n2 = document4.createElement(`canvas`); + n2.width = Math.round(e38.videoWidth * t2), n2.height = Math.round(e38.videoHeight * t2); + let r2 = n2.getContext(`2d`); + if (r2 === null) return null; + r2.drawImage(e38, 0, 0, n2.width, n2.height); + let i3 = await new Promise((e39) => n2.toBlob(e39, `image/jpeg`, sn2)); + return i3 === null ? null : { image: new Uint8Array(await i3.arrayBuffer()), mimeType: `image/jpeg` }; +} +function bn2(e38) { + let t2 = {}; + for (let n2 of [`cc_number`, `cc_exp`, `cc_name`]) { + let r2 = e38[n2]; + r2 !== void 0 && r2.trim().length > 0 && (t2[n2] = r2); + } + return t2; } -function Ae2(e9) { - Ee2(e9) && e9.stopPropagation(); +function xn2(e38) { + xn2.d = 1300; + let t2 = (0, R2.c)(10), { values: n2 } = e38, r2; + t2[0] === n2.cc_number ? r2 = t2[1] : (r2 = n2.cc_number === void 0 ? null : `\u2022\u2022\u2022\u2022 ${n2.cc_number.slice(-4)}`, t2[0] = n2.cc_number, t2[1] = r2); + let i3 = r2, a3; + t2[2] !== n2.cc_exp || t2[3] !== n2.cc_name ? (a3 = [n2.cc_exp, n2.cc_name].filter(Sn2), t2[2] = n2.cc_exp, t2[3] = n2.cc_name, t2[4] = a3) : a3 = t2[4]; + let o3 = a3, s3; + t2[5] === i3 ? s3 = t2[6] : (s3 = i3 === null ? null : (0, q3.jsx)(`span`, { className: `sand-1wm8ruf sand-ss6m8b sand-1vyo3qp`, children: i3 }), t2[5] = i3, t2[6] = s3); + let c3 = o3.length === 0 ? null : (i3 === null ? `` : ` \xB7 `) + o3.join(` \xB7 `), l5; + return t2[7] !== s3 || t2[8] !== c3 ? (l5 = (0, q3.jsxs)(`span`, { children: [s3, c3] }), t2[7] = s3, t2[8] = c3, t2[9] = l5) : l5 = t2[9], l5; +} +function Sn2(e38) { + return e38 !== void 0 && e38.length > 0; +} +function Cn2() { + Cn2.d = 1299; + let e38 = (0, R2.c)(1), t2; + return e38[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (t2 = (0, q3.jsxs)(`svg`, { "aria-hidden": true, fill: `none`, viewBox: `0 0 48 48`, className: `sand-10l6tqk sand-10a8y8t sand-1useyqa sand-sdox4t sand-1bpp3o7`, children: [(0, q3.jsx)(`path`, { d: cn2, fill: `#ffffff`, stroke: `#ffffff`, strokeLinecap: `round`, strokeLinejoin: `round`, strokeWidth: 7 }), (0, q3.jsx)(`path`, { d: cn2, fill: `#00c972`, stroke: `#00c972`, strokeLinecap: `round`, strokeLinejoin: `round`, strokeWidth: 2 })] }), e38[0] = t2) : t2 = e38[0], t2; +} +function wn2({ scan: e38, flipping: t2, translate: n2 }) { + return e38.kind === `read` ? (0, q3.jsx)(xn2, { values: e38.shown }) : e38.kind === `failed` ? n2(hn2[e38.reason]) : e38.phase === `flip-missing` ? n2(mn2[t2 ?? `both`]) : n2(pn2[e38.phase]); +} +function Tn2(e38) { + Tn2.d = 1297; + let t2 = (0, R2.c)(24), { devices: n2, deviceId: r2, onPick: i3 } = e38, { _: a3 } = fx(), o3; + t2[0] !== r2 || t2[1] !== n2 ? (o3 = n2.find((e39) => e39.deviceId === r2) ?? n2[0], t2[0] = r2, t2[1] = n2, t2[2] = o3) : o3 = t2[2]; + let s3 = o3; + if (s3 === void 0) return null; + let c3; + t2[3] === s3.label ? c3 = t2[4] : (c3 = fn3(s3.label), t2[3] = s3.label, t2[4] = c3); + let l5 = c3.name, u3; + t2[5] === a3 ? u3 = t2[6] : (u3 = a3({ id: `rT2cV+` }), t2[5] = a3, t2[6] = u3); + let d3; + t2[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (d3 = [ln2.cameraMenu, Jb2.body1], t2[7] = d3) : d3 = t2[7]; + let f4; + t2[8] === i3 ? f4 = t2[9] : (f4 = (e39) => { + e39 !== null && i3(e39); + }, t2[8] = i3, t2[9] = f4); + let m3; + if (t2[10] !== a3 || t2[11] !== n2) { + let e39; + t2[13] === a3 ? e39 = t2[14] : (e39 = (e40) => { + let { name: t3, icon: n3, description: r3 } = fn3(e40.label); + return { value: e40.deviceId, label: t3.length > 0 ? t3 : a3({ id: `rT2cV+` }), leading: (0, q3.jsx)(aS, { "aria-hidden": true, name: n3, size: `lg` }), ...r3 === null ? {} : { description: a3(r3) } }; + }, t2[13] = a3, t2[14] = e39), m3 = n2.map(e39), t2[10] = a3, t2[11] = n2, t2[12] = m3; + } else m3 = t2[12]; + let _5; + t2[15] !== a3 || t2[16] !== l5 ? (_5 = (e39) => { + let t3 = h(ln2.pill, ln2.camera, Jb2.label, Yb2.medium); + return (0, q3.jsxs)(`button`, { ...e39, className: [e39.className, t3.className].filter(Boolean).join(` `), style: { ...e39.style, ...t3.style }, type: `button`, children: [(0, q3.jsx)(aS, { "aria-hidden": true, name: `camera`, size: `lg` }), (0, q3.jsx)(`span`, { children: l5.length > 0 ? l5 : a3({ id: `rT2cV+` }) }), (0, q3.jsx)(aS, { "aria-hidden": true, name: `chevron-down`, size: `lg`, style: ln2.cameraChevron })] }); + }, t2[15] = a3, t2[16] = l5, t2[17] = _5) : _5 = t2[17]; + let v5; + return t2[18] !== s3.deviceId || t2[19] !== u3 || t2[20] !== f4 || t2[21] !== m3 || t2[22] !== _5 ? (v5 = (0, q3.jsx)(qT, { "aria-label": u3, contentStyle: d3, menuSize: `md`, contentWidth: 264, onValueChange: f4, options: m3, placement: `bottom`, renderTrigger: _5, value: s3.deviceId }), t2[18] = s3.deviceId, t2[19] = u3, t2[20] = f4, t2[21] = m3, t2[22] = _5, t2[23] = v5) : v5 = t2[23], v5; +} +function En2(e38) { + En2.d = 1296; + let t2 = (0, R2.c)(10), { camera: n2 } = e38, { platform: r2 } = of2(), i3 = N_e(); + if (n2.kind === `denied`) { + let e39; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-l56j7k sand-1l76qip sand-b3r6kr sand-4pepcl sand-dt5ytf sand-167g77z sand-18o3ruo sand-fwqdrz` }, t2[0] = e39) : e39 = t2[0]; + let n3; + t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n3 = (0, q3.jsx)(Xb2, { level: `body2`, style: ln2.blankText, children: (0, q3.jsx)(mx, { id: `18SLtg` }) }), t2[1] = n3) : n3 = t2[1]; + let a4; + t2[2] !== i3 || t2[3] !== r2 ? (a4 = r2 === `darwin` ? (0, q3.jsx)(`button`, { disabled: i3.isPending, onClick: () => i3.dispatch(l7t), type: `button`, ...h(ln2.settingsButton, Jb2.body2), children: (0, q3.jsx)(mx, { id: `b8Cn0n` }) }) : null, t2[2] = i3, t2[3] = r2, t2[4] = a4) : a4 = t2[4]; + let o4; + return t2[5] === a4 ? o4 = t2[6] : (o4 = (0, q3.jsxs)(`div`, { ...e39, children: [n3, a4] }), t2[5] = a4, t2[6] = o4), o4; + } + let a3; + t2[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (a3 = { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-l56j7k sand-1l76qip sand-b3r6kr sand-4pepcl sand-dt5ytf sand-167g77z sand-18o3ruo sand-fwqdrz` }, t2[7] = a3) : a3 = t2[7]; + let o3; + return t2[8] === n2.kind ? o3 = t2[9] : (o3 = (0, q3.jsx)(`div`, { ...a3, children: (0, q3.jsx)(Xb2, { level: `body2`, style: ln2.blankText, children: n2.kind === `none` ? (0, q3.jsx)(mx, { id: `UqAs69` }) : (0, q3.jsx)(mx, { id: `1VK9fX` }) }) }), t2[8] = n2.kind, t2[9] = o3), o3; +} +function Dn2(e38) { + Dn2.d = 1298; + let t2 = (0, R2.c)(81), { flip: i3, onCaptured: a3, onRead: o3, onFailed: c3 } = e38, l5 = i3 === void 0 ? null : i3, { _: u3 } = fx(), d3 = aPe(), p4 = v_2(), { platform: m3 } = of2(), g5 = (0, L2.useRef)(null), [v5, y4] = (0, L2.useState)(null), [b2, x2] = (0, L2.useState)(null), [S2, C2] = (0, L2.useState)(false), w2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (w2 = [], t2[0] = w2) : w2 = t2[0]; + let [E2, D2] = (0, L2.useState)(w2), O2; + t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (O2 = { kind: `starting` }, t2[1] = O2) : O2 = t2[1]; + let [A2, j2] = (0, L2.useState)(O2), M2 = typeof navigator3 > `u` ? void 0 : navigator3.mediaDevices, ee2 = M2?.getUserMedia !== void 0, te2; + t2[2] === A2 ? te2 = t2[3] : (te2 = ee2 ? A2 : { kind: `none` }, t2[2] = A2, t2[3] = te2); + let z2 = te2, [B3] = (0, L2.useState)(l5), V3 = B3 !== null, [H3, U3] = (0, L2.useState)(`front`), W3; + t2[4] !== V3 || t2[5] !== H3 ? (W3 = () => ({ kind: `scanning`, phase: nn3(H3, V3) }), t2[4] = V3, t2[5] = H3, t2[6] = W3) : W3 = t2[6]; + let [G2, ne3] = (0, L2.useState)(W3), K4 = EE(a3), re3 = EE(o3), ie3 = EE(c3), ae3 = m3 === `darwin`, oe5 = lf2(), [se5, ce6] = (0, L2.useState)(vn2), [J4, le6] = (0, L2.useState)(null); + J4 !== null && (le6(null), J4 === v5 && S2 && b2 !== J4 && (y4(b2), j2({ kind: `starting` }))); + let Y6 = se5 && (z2.kind === `starting` || z2.kind === `live`), X6; + t2[7] !== V3 || t2[8] !== H3 ? (X6 = () => _n2(() => { + let e39 = vn2(); + ce6(e39), e39 || ne3((e40) => e40.kind === `scanning` ? { kind: `scanning`, phase: nn3(H3, V3) } : e40); + }), t2[7] = V3, t2[8] = H3, t2[9] = X6) : X6 = t2[9], DE(X6); + let ue6; + t2[10] !== z2.kind || t2[11] !== oe5 ? (ue6 = () => z2.kind === `denied` ? oe5(() => j2({ kind: `starting` })) : Ln2, t2[10] = z2.kind, t2[11] = oe5, t2[12] = ue6) : ue6 = t2[12], DE(ue6); + let de6; + t2[13] !== v5 || t2[14] !== Y6 ? (de6 = () => { + if (M2 === void 0 || !ee2 || !Y6) return In2; + let e39 = false, t3 = null, n2 = v5; + return M2.getUserMedia({ video: n2 === null ? { width: { ideal: 1920 }, height: { ideal: 1080 } } : { deviceId: { exact: n2 }, width: { ideal: 1920 }, height: { ideal: 1080 } }, audio: false }).then(async (r2) => { + if (e39) { + for (let e40 of r2.getTracks()) e40.stop(); + return; + } + t3 = r2; + let i4 = g5.current; + if (i4 !== null) { + i4.srcObject = r2; + let a5 = await i4.play().then(Fn2, Pn2); + if (e39) return; + if (a5 !== null) { + i4.srcObject = null; + for (let e41 of r2.getTracks()) e41.stop(); + t3 = null; + let e40 = gn2(a5); + e40.kind !== `denied` && n2 !== null && le6(n2), e40.kind === `error` && el2(a5, { tags: { sand_area: `vault-card-scan` } }), j2(e40); + return; + } + } + if (e39) return; + j2({ kind: `live` }); + let a4 = await M2.enumerateDevices().catch(Nn2); + if (e39) return; + D2(a4.filter(Mn2).map(jn2)); + let o4 = r2.getVideoTracks()[0]?.getSettings().deviceId; + x2(o4 ?? n2), C2(true); + }).catch((t4) => { + if (e39) return; + let r2 = gn2(t4); + r2.kind !== `denied` && n2 !== null && le6(n2), r2.kind === `error` && el2(t4, { tags: { sand_area: `vault-card-scan` } }), j2(r2); + }), () => { + e39 = true; + let n3 = g5.current; + n3 !== null && (n3.srcObject = null); + for (let e40 of t3?.getTracks() ?? []) e40.stop(); + }; + }, t2[13] = v5, t2[14] = Y6, t2[15] = de6) : de6 = t2[15], DE(de6); + let Z6 = z2.kind === `live`, fe5 = se5 && Z6 && G2.kind === `scanning`, pe5; + t2[16] !== d3 || t2[17] !== B3 || t2[18] !== fe5 || t2[19] !== K4 || t2[20] !== ie3 || t2[21] !== ae3 || t2[22] !== H3 || t2[23] !== p4 ? (pe5 = () => { + if (!fe5) return An2; + let e39 = rn2({ clock: d3, side: H3, ...B3 === null ? {} : { sidesRead: B3.sidesRead, wants: en3(B3.missing) }, capture: () => yn2(g5.current), screen: ae3 ? (e40) => p4.screenCardImage(e40) : null, read: (e40, t3) => p4.readCardPhoto({ photos: e40 }, { signal: t3 }), onPhase: (e40) => ne3({ kind: `scanning`, phase: e40 }), onEnd: (e40) => { + if (e40.kind === `read`) { + if (B3 === null) ne3({ kind: `read`, values: e40.values, shown: e40.values, photos: e40.photos }); + else { + let t3 = tn3({ current: B3.current, read: e40.values }); + ne3({ kind: `read`, values: t3, shown: { ...bn2(B3.current), ...t3 }, photos: e40.photos }); + } + K4(); + } else ne3({ kind: `failed`, reason: e40.reason }), ie3(e40.reason); + }, onError: kn2 }); + return () => e39.dispose(); + }, t2[16] = d3, t2[17] = B3, t2[18] = fe5, t2[19] = K4, t2[20] = ie3, t2[21] = ae3, t2[22] = H3, t2[23] = p4, t2[24] = pe5) : pe5 = t2[24], DE(pe5); + let me5 = G2.kind === `read` ? G2 : null, he5; + if (t2[25] !== d3 || t2[26] !== re3 || t2[27] !== me5 ? (he5 = () => { + if (me5 === null) return On2; + let e39 = d3.schedule(an2, () => re3(me5.values, me5.photos)); + return () => e39.dispose(); + }, t2[25] = d3, t2[26] = re3, t2[27] = me5, t2[28] = he5) : he5 = t2[28], DE(he5), z2.kind === `denied` || z2.kind === `none` || z2.kind === `error`) { + let e39; + return t2[29] === z2 ? e39 = t2[30] : (e39 = (0, q3.jsx)(En2, { camera: z2 }), t2[29] = z2, t2[30] = e39), e39; + } + let ge5 = G2.kind === `scanning` ? G2.phase : null, _e5 = ge5 === `hold-still` || ge5 === `hold-still-back` || G2.kind === `read`, ve5 = B3?.missing ?? null, ye5; + t2[31] !== u3 || t2[32] !== G2 || t2[33] !== ve5 ? (ye5 = wn2({ scan: G2, flipping: ve5, translate: u3 }), t2[31] = u3, t2[32] = G2, t2[33] = ve5, t2[34] = ye5) : ye5 = t2[34]; + let be5 = ye5, xe5 = Z6 && !V3 && H3 === `front` && (ge5 === `line-up` || ge5 === `back-hint` || ge5 === `dim` || ge5 === `hold-still`), Se5; + t2[35] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (Se5 = { className: `sand-1n2onr6 sand-78zum5 sand-6s0dn4 sand-l56j7k sand-1l76qip sand-b3r6kr sand-4pepcl sand-1hk0rwa` }, t2[35] = Se5) : Se5 = t2[35]; + let Ce5; + t2[36] === u3 ? Ce5 = t2[37] : (Ce5 = u3({ id: `irZYhR` }), t2[36] = u3, t2[37] = Ce5); + let we5; + t2[38] !== Z6 || t2[39] !== G2.kind ? (we5 = { 0: { className: `sand-10l6tqk sand-10a8y8t sand-h8yej3 sand-5yr21d sand-l1xv1r` }, 2: { className: `sand-10l6tqk sand-10a8y8t sand-h8yej3 sand-5yr21d sand-l1xv1r sand-lshs6z` }, 1: { className: `sand-10l6tqk sand-10a8y8t sand-h8yej3 sand-5yr21d sand-l1xv1r sand-nyzrob` }, 3: { className: `sand-10l6tqk sand-10a8y8t sand-h8yej3 sand-5yr21d sand-l1xv1r sand-lshs6z sand-nyzrob` } }[!Z6 << 1 | (G2.kind === `failed`) << 0], t2[38] = Z6, t2[39] = G2.kind, t2[40] = we5) : we5 = t2[40]; + let Te5; + t2[41] !== Ce5 || t2[42] !== we5 ? (Te5 = (0, q3.jsx)(`video`, { "aria-label": Ce5, muted: true, playsInline: true, ref: g5, ...we5 }), t2[41] = Ce5, t2[42] = we5, t2[43] = Te5) : Te5 = t2[43]; + let Ee5; + t2[44] !== _e5 || t2[45] !== G2.kind ? (Ee5 = { 0: { className: `sand-1n2onr6 sand-9f619 sand-1dz1jew sand-kq7avx sand-dh2fpr sand-1y0btm7 sand-g29ltk sand-1q4ynmn sand-1ubh17z sand-shfolx sand-15nzlfb` }, 2: { className: `sand-1n2onr6 sand-9f619 sand-1dz1jew sand-kq7avx sand-dh2fpr sand-1y0btm7 sand-1q4ynmn sand-1ubh17z sand-shfolx sand-15nzlfb sand-nzy186` }, 1: { className: `sand-1n2onr6 sand-9f619 sand-1dz1jew sand-kq7avx sand-dh2fpr sand-1y0btm7 sand-1q4ynmn sand-1ubh17z sand-shfolx sand-15nzlfb sand-18kvpo9` }, 3: { className: `sand-1n2onr6 sand-9f619 sand-1dz1jew sand-kq7avx sand-dh2fpr sand-1y0btm7 sand-1q4ynmn sand-1ubh17z sand-shfolx sand-15nzlfb sand-18kvpo9` } }[!!_e5 << 1 | (G2.kind === `failed`) << 0], t2[44] = _e5, t2[45] = G2.kind, t2[46] = Ee5) : Ee5 = t2[46]; + let De5; + t2[47] === ge5 ? De5 = t2[48] : (De5 = ge5 === `flip` || ge5 === `flip-missing` ? (0, q3.jsx)(`span`, { className: `sand-10l6tqk sand-10a8y8t sand-78zum5 sand-6s0dn4 sand-l56j7k sand-3x2bpi sand-wvwv9b sand-1bpp3o7 sand-149ho13 sand-14zn8v5 sand-fungia`, children: (0, q3.jsx)(aS, { "aria-hidden": true, name: `refresh`, size: `lg` }) }) : null, t2[47] = ge5, t2[48] = De5); + let Oe5; + t2[49] === G2.kind ? Oe5 = t2[50] : (Oe5 = G2.kind === `read` ? (0, q3.jsx)(Cn2, {}) : null, t2[49] = G2.kind, t2[50] = Oe5); + let ke5; + t2[51] !== Ee5 || t2[52] !== De5 || t2[53] !== Oe5 ? (ke5 = (0, q3.jsxs)(`div`, { ...Ee5, children: [De5, Oe5] }), t2[51] = Ee5, t2[52] = De5, t2[53] = Oe5, t2[54] = ke5) : ke5 = t2[54]; + let Ae5; + t2[55] !== b2 || t2[56] !== E2 || t2[57] !== V3 || t2[58] !== Z6 || t2[59] !== G2.kind || t2[60] !== H3 ? (Ae5 = Z6 && E2.length > 0 && G2.kind !== `read` ? (0, q3.jsx)(Tn2, { deviceId: b2, devices: E2, onPick: (e39) => { + e39 !== b2 && (j2({ kind: `starting` }), ne3({ kind: `scanning`, phase: nn3(H3, V3) }), y4(e39)); + } }) : null, t2[55] = b2, t2[56] = E2, t2[57] = V3, t2[58] = Z6, t2[59] = G2.kind, t2[60] = H3, t2[61] = Ae5) : Ae5 = t2[61]; + let je5; + t2[62] !== be5 || t2[63] !== Z6 ? (je5 = Z6 ? (0, q3.jsx)(`span`, { "aria-live": `polite`, role: `status`, ...h(ln2.pill, ln2.hint, Jb2.body2), children: be5 }) : null, t2[62] = be5, t2[63] = Z6, t2[64] = je5) : je5 = t2[64]; + let Me5; + t2[65] !== Te5 || t2[66] !== ke5 || t2[67] !== Ae5 || t2[68] !== je5 ? (Me5 = (0, q3.jsxs)(`div`, { ...Se5, children: [Te5, ke5, Ae5, je5] }), t2[65] = Te5, t2[66] = ke5, t2[67] = Ae5, t2[68] = je5, t2[69] = Me5) : Me5 = t2[69]; + let Ne5 = !xe5, Pe5; + t2[70] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (Pe5 = () => { + U3(`back`), ne3({ kind: `scanning`, phase: `back` }); + }, t2[70] = Pe5) : Pe5 = t2[70]; + let Fe4; + t2[71] === xe5 ? Fe4 = t2[72] : (Fe4 = h(ln2.backButton, !xe5 && ln2.backButtonHidden, Jb2.body2), t2[71] = xe5, t2[72] = Fe4); + let Ie5, Le5; + t2[73] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (Ie5 = (0, q3.jsx)(aS, { "aria-hidden": true, name: `refresh`, size: `lg` }), Le5 = (0, q3.jsx)(mx, { id: `Qu/o3L` }), t2[73] = Ie5, t2[74] = Le5) : (Ie5 = t2[73], Le5 = t2[74]); + let Re5; + t2[75] !== Ne5 || t2[76] !== Fe4 ? (Re5 = (0, q3.jsxs)(`button`, { disabled: Ne5, onClick: Pe5, type: `button`, ...Fe4, children: [Ie5, Le5] }), t2[75] = Ne5, t2[76] = Fe4, t2[77] = Re5) : Re5 = t2[77]; + let ze5; + return t2[78] !== Me5 || t2[79] !== Re5 ? (ze5 = (0, q3.jsxs)(q3.Fragment, { children: [Me5, Re5] }), t2[78] = Me5, t2[79] = Re5, t2[80] = ze5) : ze5 = t2[80], ze5; +} +function On2() { +} +function kn2(e38) { + return el2(e38, { tags: { sand_area: `vault-card-scan` } }); +} +function An2() { +} +function jn2(e38) { + return { deviceId: e38.deviceId, label: e38.label }; +} +function Mn2(e38) { + return e38.kind === `videoinput`; +} +function Nn2() { + return []; +} +function Pn2(e38) { + return e38 instanceof DOMException && e38.name === `AbortError` ? null : e38; +} +function Fn2() { + return null; } -function je2() { +function In2() { } -function Me(e9) { - return e9.file; +function Ln2() { } -function Ne(e9) { - return e9.file; +var $3 = { surface: { kVQacm: `sand-b3r6kr`, $$css: true }, header: { kVAEAm: `sand-1n2onr6`, kOIVth: `sand-195vfkc`, kwRFfy: `sand-15zmtp0`, $$css: true }, headerPlain: { kGO01o: `sand-18d9i69`, kt9PQ7: `sand-1qhh985`, $$css: true }, title: { kogj98: `sand-1ghz6dp`, kMwMTN: `sand-tyxrsu`, $$css: true }, headerWarning: { k1xSpc: `sand-78zum5`, kwnvtZ: `sand-1a02dak`, kGNEyG: `sand-6s0dn4`, k1C7PZ: `sand-17zd0t2`, kMwMTN: `sand-impobl`, $$css: true }, headerWarningAction: { kogj98: `sand-1ghz6dp`, kmVPX3: `sand-1717udv`, kMzoRj: `sand-c342km`, kWkggS: `sand-jbqb8w`, kMwMTN: `sand-10kc733`, kMv6JI: `sand-jb2p0i`, kkrTdU: `sand-1ypdohk`, $$css: true }, body: { k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kOIVth: `sand-1v2ro7d`, kskxy: `sand-9whfvc`, kORKVm: `sand-1odjw0f`, $$css: true }, bodyScan: { kGO01o: `sand-1l90r2v`, $$css: true }, captureButton: { kzqmXN: `sand-h8yej3`, $$css: true }, captureWarning: { keoZOQ: `sand-1rdy4ex`, kMwMTN: `sand-impobl`, $$css: true }, divider: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-1v2ro7d`, kqGvvJ: `sand-g9jes1`, kMwMTN: `sand-1o0liin`, kgeoSG: `sand-1cpjm7i`, kzvCdC: `sand-10bxx3s`, kgzTxl: `sand-cmm1j9`, kLkRvE: `sand-163ohqv`, k5JduY: `sand-1s928wv`, khUdH9: `sand-71tlqn`, k4zj60: `sand-1psy2a1`, ks3ayO: `sand-1n7skvc`, $$css: true }, footer: { kOIVth: `sand-167g77z`, $$css: true }, removeAction: { kWkggS: `sand-fwqdrz sand-19jy9ex sand-1g6zli8`, $$css: true }, footerPlain: { kEafiO: `sand-972fbf`, $$css: true }, footerNote: { kzQI83: `sand-1iyjqo2`, k7Eaqz: `sand-euugli`, kMwMTN: `sand-1o0liin`, $$css: true }, footerError: { kzQI83: `sand-1iyjqo2`, k7Eaqz: `sand-euugli`, kMwMTN: `sand-i69oq4`, $$css: true }, footerSplit: { k1xSpc: `sand-rvj5dj`, kumcoG: `sand-cjjqqt`, k1C7PZ: `sand-fex06f`, kg3NbH: `sand-1hr3lfm`, $$css: true }, drop: { kVAEAm: `sand-10l6tqk`, kpwlN0: `sand-k92lsc`, kY2c9j: `sand-htitgo`, k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kOIVth: `sand-167g77z`, kMzoRj: `sand-vndefy`, ksu8eU: `sand-bsl7fq`, kVAM5u: `sand-vd4qke`, kaIpWk: `sand-1q4ynmn`, kWkggS: `sand-tyo4xa`, kKwaWg: `sand-1bowyxn`, kMwMTN: `sand-10kc733`, kfzvcC: `sand-47corl`, $$css: true } }; +var Rn2 = { holderName: true, securityCode: true, nickname: true, billing: `address-or-contact` }; +function zn2(e38) { + let t2 = {}; + for (let n2 of pt2) t2[n2] = e38[n2] ?? ``; + return t2; } -function Pe() { +function Bn2(e38) { + return Oe3(e38) ? { kind: `new`, savesContact: false } : { kind: `none` }; } -function Fe2(e9) { - Fe2.d = 899; - let t2 = (0, z3.c)(4), { fill: n2, children: r2 } = e9, i3 = n2.boundaryProps, a3; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (a3 = { className: `sand-jp7ctv` }, t2[0] = a3) : a3 = t2[0]; - let o3; - return t2[1] !== r2 || t2[2] !== n2.boundaryProps ? (o3 = (0, B3.jsx)(`div`, { ...i3, ...a3, children: r2 }), t2[1] = r2, t2[2] = n2.boundaryProps, t2[3] = o3) : o3 = t2[3], o3; -} -function Ie2(e9) { - Ie2.d = 902; - let t2 = (0, z3.c)(14), { fill: n2 } = e9, { _: r2 } = bb(); - switch (n2.status.kind) { - case `reading`: { - let e10; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e10 = (0, B3.jsx)(kC, { borderWidth: 2, inheritColor: true, size: 12 }), t2[0] = e10) : e10 = t2[0]; - let n3; - return t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n3 = (0, B3.jsxs)(B3.Fragment, { children: [e10, (0, B3.jsx)(lx, { level: `label`, children: (0, B3.jsx)(Sb, { id: `iWnbNJ` }) })] }), t2[1] = n3) : n3 = t2[1], n3; - } - case `settled`: { - let e10; - t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e10 = { className: `sand-78zum5 sand-dt5ytf sand-195vfkc sand-euugli` }, t2[2] = e10) : e10 = t2[2]; - let i3; - t2[3] !== r2 || t2[4] !== n2.status.message ? (i3 = r2(n2.status.message), t2[3] = r2, t2[4] = n2.status.message, t2[5] = i3) : i3 = t2[5]; - let a3; - t2[6] === i3 ? a3 = t2[7] : (a3 = (0, B3.jsx)(lx, { level: `label`, children: i3 }), t2[6] = i3, t2[7] = a3); - let o3; - t2[8] !== r2 || t2[9] !== n2.status.notice ? (o3 = n2.status.notice === null ? null : (0, B3.jsx)(lx, { level: `label`, children: r2(n2.status.notice) }), t2[8] = r2, t2[9] = n2.status.notice, t2[10] = o3) : o3 = t2[10]; - let s3; - return t2[11] !== a3 || t2[12] !== o3 ? (s3 = (0, B3.jsxs)(`span`, { ...e10, children: [a3, o3] }), t2[11] = a3, t2[12] = o3, t2[13] = s3) : s3 = t2[13], s3; - } - case `idle`: - return null; - } +function Vn2(e38) { + return { billing_line1: e38.billing_line1 ?? ``, billing_line2: e38.billing_line2 ?? ``, billing_city: e38.billing_city ?? ``, billing_region: e38.billing_region ?? ``, billing_postal_code: e38.billing_postal_code ?? ``, billing_country: e38.billing_country ?? `` }; } -function Le2(e9) { - Le2.d = 900; - let t2 = (0, z3.c)(5), { fill: n2, id: r2 } = e9; - if (n2.status.kind !== `idle`) return null; - let i3; - t2[0] === n2.photos.length ? i3 = t2[1] : (i3 = n2.photos.length === 0 ? (0, B3.jsx)(Sb, { id: `y9b3+R` }) : (0, B3.jsx)(Sb, { id: `Iyyvds` }), t2[0] = n2.photos.length, t2[1] = i3); - let a3; - return t2[2] !== r2 || t2[3] !== i3 ? (a3 = (0, B3.jsx)(lx, { id: r2, level: `label`, style: pe3.hint, children: i3 }), t2[2] = r2, t2[3] = i3, t2[4] = a3) : a3 = t2[4], a3; -} -function Re2(e9) { - Re2.d = 901; - let t2 = (0, z3.c)(58), { fill: n2 } = e9, { _: i3 } = bb(), a3 = (0, G4.useId)(), o3 = (0, G4.useRef)(null), l4 = (0, G4.useRef)(null), u3; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u3 = [], t2[0] = u3) : u3 = t2[0]; - let d3 = (0, G4.useRef)(u3), p4 = (0, G4.useRef)(null), m3 = (0, G4.useRef)(null), h3 = n2.status.kind === `reading`, g3 = n2.photos.length > 0, _2; - if (t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (_2 = () => { - let e10 = m3.current; - e10 !== null && (m3.current = null, e10.kind === `remove` ? d3.current[e10.index]?.focus() : e10.kind === `status` ? p4.current?.focus() : l4.current?.focus()); - }, t2[1] = _2) : _2 = t2[1], Vw(_2), !n2.isEnabled) return null; - let v3 = n2.isActive && n2.photos.length < 4, y3; - t2[2] === n2 ? y3 = t2[3] : (y3 = function(e10) { - let t3 = Array.from(e10.currentTarget.files ?? []); - e10.currentTarget.value = ``, n2.addFiles(t3); - }, t2[2] = n2, t2[3] = y3); - let b3 = y3, x3, S3, C2; - if (t2[4] !== i3 || t2[5] !== v3 || t2[6] !== n2 || t2[7] !== g3 || t2[8] !== a3 || t2[9] !== h3) { - let e10 = function(e11, t3) { - let r3 = n2.photos.length - 1; - m3.current = r3 === 0 ? { kind: `choose` } : { kind: `remove`, index: Math.min(t3, r3 - 1) }, n2.removePhoto(e11); - }, r2; - t2[13] === n2 ? r2 = t2[14] : (r2 = function() { - m3.current = { kind: `status` }, n2.retry(); - }, t2[13] = n2, t2[14] = r2); - let s3 = r2; - t2[15] === n2.isDragOver ? x3 = t2[16] : (x3 = { 0: { className: `sand-78zum5 sand-dt5ytf sand-883omv sand-p59q4u sand-aope02 sand-1qmwy7c sand-qjedn3 sand-bsl7fq sand-5fd6op` }, 1: { className: `sand-78zum5 sand-dt5ytf sand-883omv sand-p59q4u sand-aope02 sand-1qmwy7c sand-qjedn3 sand-1y0btm7 sand-vd4qke sand-fwqdrz` } }[!!n2.isDragOver << 0], t2[15] = n2.isDragOver, t2[16] = x3); - let u4, _3, y4; - t2[17] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (_3 = { className: `sand-78zum5 sand-6s0dn4 sand-883omv` }, y4 = (0, B3.jsx)(tC, { "aria-hidden": true, color: `secondary`, name: `credit-card`, size: `lg` }), u4 = { className: `sand-78zum5 sand-dt5ytf sand-1iyjqo2 sand-euugli` }, t2[17] = u4, t2[18] = _3, t2[19] = y4) : (u4 = t2[17], _3 = t2[18], y4 = t2[19]); - let b4; - t2[20] !== n2 || t2[21] !== a3 ? (b4 = (0, B3.jsx)(Le2, { fill: n2, id: a3 }), t2[20] = n2, t2[21] = a3, t2[22] = b4) : b4 = t2[22]; - let w4; - t2[23] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (w4 = { className: `sand-78zum5 sand-1a02dak sand-6s0dn4 sand-fex06f` }, t2[23] = w4) : w4 = t2[23]; - let T4; - t2[24] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (T4 = { className: `sand-78zum5 sand-6s0dn4 sand-17d4w8g sand-1o0liin sand-1a2a7pz` }, t2[24] = T4) : T4 = t2[24]; - let E4; - t2[25] === n2 ? E4 = t2[26] : (E4 = (0, B3.jsx)(`span`, { "aria-live": `polite`, ref: p4, role: `status`, tabIndex: -1, ...T4, children: (0, B3.jsx)(Ie2, { fill: n2 }) }), t2[25] = n2, t2[26] = E4); - let D3; - t2[27] !== n2.canRetry || t2[28] !== s3 ? (D3 = n2.canRetry ? (0, B3.jsx)(MC, { onClick: s3, sentiment: `accent`, size: `sm`, style: pe3.retry, type: `button`, variant: `tertiary`, children: (0, B3.jsx)(Sb, { id: `KDw4GX` }) }) : null, t2[27] = n2.canRetry, t2[28] = s3, t2[29] = D3) : D3 = t2[29]; - let O4; - t2[30] !== E4 || t2[31] !== D3 ? (O4 = (0, B3.jsxs)(`div`, { ...w4, children: [E4, D3] }), t2[30] = E4, t2[31] = D3, t2[32] = O4) : O4 = t2[32]; - let k5; - t2[33] !== b4 || t2[34] !== O4 ? (k5 = (0, B3.jsxs)(`div`, { ...u4, children: [b4, O4] }), t2[33] = b4, t2[34] = O4, t2[35] = k5) : k5 = t2[35]; - let j3 = n2.status.kind === `idle` ? a3 : void 0, M3 = !v3, N2; - t2[36] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (N2 = () => o3.current?.click(), t2[36] = N2) : N2 = t2[36]; - let P2; - t2[37] === g3 ? P2 = t2[38] : (P2 = g3 ? (0, B3.jsx)(Sb, { id: `Lx8S4X` }) : (0, B3.jsx)(Sb, { id: `v8D+Lv` }), t2[37] = g3, t2[38] = P2); - let F2; - t2[39] !== j3 || t2[40] !== M3 || t2[41] !== P2 ? (F2 = (0, B3.jsx)(MC, { "aria-describedby": j3, disabled: M3, onClick: N2, ref: l4, size: `sm`, type: `button`, variant: `secondary`, children: P2 }), t2[39] = j3, t2[40] = M3, t2[41] = P2, t2[42] = F2) : F2 = t2[42], t2[43] !== k5 || t2[44] !== F2 ? (S3 = (0, B3.jsxs)(`div`, { ..._3, children: [y4, k5, F2] }), t2[43] = k5, t2[44] = F2, t2[45] = S3) : S3 = t2[45], C2 = g3 ? (0, B3.jsx)(`ul`, { "aria-label": i3({ id: `kpfgrc` }), className: `sand-78zum5 sand-1a02dak sand-167g77z sand-1ghz6dp sand-1717udv sand-e8uvvx`, children: n2.photos.map((t3, n3) => { - let r3 = n3 + 1; - return (0, B3.jsxs)(`li`, { className: `sand-1n2onr6 sand-13oubkp sand-ng8ra`, children: [(0, B3.jsx)(De2, { alt: i3({ id: `1YHBDM`, values: { number: r3 } }), file: t3.file }), (0, B3.jsx)(oC, { "aria-label": i3({ id: `e1AX3P`, values: { number: r3 } }), disabled: h3, icon: `close`, onClick: () => e10(t3.key, n3), ref: (e11) => { - d3.current[n3] = e11; - }, shape: `circle`, size: `xs`, style: pe3.thumbnailRemove, variant: `elevated` })] }, t3.key); - }) }) : null, t2[4] = i3, t2[5] = v3, t2[6] = n2, t2[7] = g3, t2[8] = a3, t2[9] = h3, t2[10] = x3, t2[11] = S3, t2[12] = C2; - } else x3 = t2[10], S3 = t2[11], C2 = t2[12]; - let w3; - t2[46] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (w3 = [..._ge], t2[46] = w3) : w3 = t2[46]; - let T3 = w3.join(`,`), E3; - t2[47] === i3 ? E3 = t2[48] : (E3 = i3({ id: `CfqzS2` }), t2[47] = i3, t2[48] = E3); - let D2; - t2[49] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (D2 = { className: `sand-1s85apg` }, t2[49] = D2) : D2 = t2[49]; - let O3; - t2[50] !== b3 || t2[51] !== E3 ? (O3 = (0, B3.jsx)(`input`, { accept: T3, "aria-label": E3, multiple: true, onChange: b3, ref: o3, tabIndex: -1, type: `file`, ...D2 }), t2[50] = b3, t2[51] = E3, t2[52] = O3) : O3 = t2[52]; - let k4; - return t2[53] !== O3 || t2[54] !== x3 || t2[55] !== S3 || t2[56] !== C2 ? (k4 = (0, B3.jsxs)(`div`, { ...x3, children: [S3, C2, O3] }), t2[53] = O3, t2[54] = x3, t2[55] = S3, t2[56] = C2, t2[57] = k4) : k4 = t2[57], k4; +function Hn2() { + Hn2.d = 1308; + let e38 = (0, R2.c)(1), t2; + return e38[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (t2 = (0, q3.jsx)(mx, { id: `qqlsGD` }), e38[0] = t2) : t2 = e38[0], t2; } -function ze2(e9) { - let t2 = {}; - if (e9 === null) return t2; - for (let n2 of $2) { - let r2 = e9.elements.namedItem(n2); - r2 instanceof HTMLInputElement && (t2[n2] = r2.value); +function Un2(e38) { + Un2.d = 1304; + let t2 = (0, R2.c)(3), { missing: n2 } = e38; + if (n2 === `security_code`) { + let e39; + return t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = (0, q3.jsx)(mx, { id: `CceMjR` }), t2[0] = e39) : e39 = t2[0], e39; } - return t2; -} -function Be2(e9, t2) { - for (let [n2, r2] of Object.entries(t2)) { - let t3 = e9.elements.namedItem(n2); - t3 instanceof HTMLInputElement && r2 !== void 0 && (t3.value = r2); + if (n2 === `name`) { + let e39; + return t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = (0, q3.jsx)(mx, { id: `plTBeM` }), t2[1] = e39) : e39 = t2[1], e39; } + let r2; + return t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = (0, q3.jsx)(mx, { id: `fl9w1f` }), t2[2] = r2) : r2 = t2[2], r2; } -var Ve2 = { cc_number: { id: `xHIEQ5` }, cc_exp: { id: `hwlSE2` }, cc_csc: { id: `wLmRnI` }, cc_name: { id: `Mf9Gtf` }, billing_line1: { id: `gzEjAL` }, billing_line2: { id: `cormHa` }, billing_city: { id: `3wV73y` }, billing_region: { id: `BKTGoj` }, billing_postal_code: { id: `XSEMno` }, billing_country: { id: `JNCzPW` } }; -var He2 = [[`cc_exp`, `cc_csc`], [`billing_city`, `billing_region`], [`billing_postal_code`, `billing_country`]]; -function Ue2(e9) { - return Object.hasOwn(Ve2, e9); +function Wn2({ view: e38, status: t2, hasNumber: n2, scanFlip: r2, photoFlip: i3 }) { + return e38 === `form` && r2 !== null ? { message: (0, q3.jsx)(Un2, { missing: r2.missing }), action: (0, q3.jsx)(Hn2, {}), mode: `scan-back` } : e38 !== `form` || t2.kind !== `settled` ? null : t2.refusal === `not_image` ? { message: (0, q3.jsx)(mx, { id: `8/exSJ` }), action: (0, q3.jsx)(mx, { id: `RwE+6a` }), mode: `replace` } : t2.isFilled && !n2 ? { message: (0, q3.jsx)(mx, { id: `1wSjhH` }), action: (0, q3.jsx)(mx, { id: `Hi4MsU` }), mode: `add` } : t2.isFilled && i3 !== null ? { message: (0, q3.jsx)(Un2, { missing: i3 }), action: (0, q3.jsx)(mx, { id: `Hi4MsU` }), mode: `add` } : null; } -function We2(e9) { - let t2 = []; - for (let n2 of e9) { - let e10 = t2.at(-1), r2 = e10?.length === 1 ? e10[0]?.id : void 0; - e10 !== void 0 && He2.some((e11) => e11[0] === r2 && e11[1] === n2.id) ? e10.push(n2) : t2.push([n2]); - } - return t2; +function Gn2(e38, t2, n2) { + return e38?.kind === `failed` ? n2({ id: `HXFmFy` }) : t2.kind !== `settled` || t2.isFilled ? null : t2.isUnreadable ? n2({ id: `wv9aWB` }) : n2(t2.message); +} +function Kn2(e38) { + Kn2.d = 1303; + let t2 = (0, R2.c)(3), { children: n2 } = e38, r2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = [$3.title, Jb2.body1, Yb2.semibold], t2[0] = r2) : r2 = t2[0]; + let i3; + return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, q3.jsx)(CC.Title, { style: r2, children: n2 }), t2[1] = n2, t2[2] = i3), i3; +} +function qn3(e38) { + qn3.d = 1305; + let t2 = (0, R2.c)(12), { message: n2, action: r2, onAction: i3 } = e38, a3, o3; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (a3 = h($3.headerWarning, Jb2.body2), o3 = (0, q3.jsx)(aS, { "aria-hidden": true, name: `warning`, size: `sm` }), t2[0] = a3, t2[1] = o3) : (a3 = t2[0], o3 = t2[1]); + let s3; + t2[2] === n2 ? s3 = t2[3] : (s3 = (0, q3.jsx)(`span`, { children: n2 }), t2[2] = n2, t2[3] = s3); + let c3; + t2[4] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (c3 = (0, q3.jsx)(`span`, { "aria-hidden": true, children: `\xB7` }), t2[4] = c3) : c3 = t2[4]; + let l5; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = h($3.headerWarningAction, Jb2.body2), t2[5] = l5) : l5 = t2[5]; + let u3; + t2[6] !== r2 || t2[7] !== i3 ? (u3 = (0, q3.jsx)(`button`, { onClick: i3, type: `button`, ...l5, children: r2 }), t2[6] = r2, t2[7] = i3, t2[8] = u3) : u3 = t2[8]; + let d3; + return t2[9] !== s3 || t2[10] !== u3 ? (d3 = (0, q3.jsxs)(`span`, { role: `alert`, ...a3, children: [o3, s3, c3, u3] }), t2[9] = s3, t2[10] = u3, t2[11] = d3) : d3 = t2[11], d3; } -function Ge3(e9) { - Ge3.d = 906; - let t2 = (0, z3.c)(32), { field: n2, label: r2, value: i3, isDisabled: a3, onChange: o3, ref: s3 } = e9, c2 = (0, G4.useId)(), [l4, u3] = (0, G4.useState)(false), d3 = n2.secret === true, f4 = n2.required === true, p4 = n2.id, m3; - t2[0] !== n2.required || t2[1] !== o3 ? (m3 = (e10) => { - let t3 = e10.currentTarget; - n2.required === true && t3.value.trim().length === 0 && (t3.value = ``), o3(t3.value); - }, t2[0] = n2.required, t2[1] = o3, t2[2] = m3) : m3 = t2[2]; - let h3 = n2.placeholder, g3 = n2.required === true, _2 = d3 && !l4 ? `password` : `text`, v3; - t2[3] === n2.id ? v3 = t2[4] : (v3 = n2.id === `cc_exp` ? { inputMode: `numeric` } : {}, t2[3] = n2.id, t2[4] = v3); - let y3; - t2[5] === i3 ? y3 = t2[6] : (y3 = i3 === void 0 ? {} : { value: i3 }, t2[5] = i3, t2[6] = y3); - let b3; - t2[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (b3 = h(d2.control, d2.controlElevated), t2[7] = b3) : b3 = t2[7]; - let x3; - t2[8] !== n2.id || t2[9] !== n2.placeholder || t2[10] !== c2 || t2[11] !== a3 || t2[12] !== s3 || t2[13] !== m3 || t2[14] !== g3 || t2[15] !== _2 || t2[16] !== v3 || t2[17] !== y3 ? (x3 = (0, B3.jsx)(`input`, { autoComplete: `off`, disabled: a3, id: c2, name: p4, onChange: m3, placeholder: h3, ref: s3, required: g3, spellCheck: false, type: _2, ...v3, ...y3, ...b3 }), t2[8] = n2.id, t2[9] = n2.placeholder, t2[10] = c2, t2[11] = a3, t2[12] = s3, t2[13] = m3, t2[14] = g3, t2[15] = _2, t2[16] = v3, t2[17] = y3, t2[18] = x3) : x3 = t2[18]; - let S3; - t2[19] !== a3 || t2[20] !== d3 || t2[21] !== l4 || t2[22] !== r2 ? (S3 = d3 ? (0, B3.jsx)(m2, { isDisabled: a3, isRevealed: l4, label: r2, onToggle: () => u3(Ke3) }) : null, t2[19] = a3, t2[20] = d3, t2[21] = l4, t2[22] = r2, t2[23] = S3) : S3 = t2[23]; +function Jn3(e38) { + Jn3.d = 1301; + let t2 = (0, R2.c)(22), { choice: n2, lastSavedId: r2, values: i3, contact: a3, isDisabled: o3, savesNewAddress: s3, onChoiceChange: c3, onContactChange: l5, onValueChange: u3 } = e38, f4 = v_2(); + wD(f4.load); + let p4; + t2[0] === u3 ? p4 = t2[1] : (p4 = () => { + for (let e39 of X4) u3(e39, ``); + }, t2[0] = u3, t2[1] = p4); + let m3 = p4, h4; + t2[2] !== c3 || t2[3] !== u3 ? (h4 = (e39, t3) => { + let n3 = e39.find((e40) => e40.id === t3); + if (n3 === void 0) return false; + for (let [e40, t4] of Object.entries(De3(n3.contact))) u3(e40, t4); + return c3({ kind: `saved`, id: t3 }), true; + }, t2[2] = c3, t2[3] = u3, t2[4] = h4) : h4 = t2[4]; + let g5 = h4, v5; + t2[5] !== n2 || t2[6] !== m3 || t2[7] !== a3 || t2[8] !== o3 || t2[9] !== r2 || t2[10] !== c3 || t2[11] !== l5 || t2[12] !== u3 || t2[13] !== g5 || t2[14] !== s3 || t2[15] !== i3 ? (v5 = (e39, t3) => { + let d3 = t3 === void 0 || t3; + return (0, q3.jsx)(ot2, { address: Vn2(i3), choice: n2, contact: a3, contacts: e39, isDisabled: o3 || !d3 && n2.kind === `saved`, onAddressChange: (e40, t4) => u3(e40, t4), onClear: () => { + m3(), c3({ kind: `none` }); + }, onContactChange: l5, onPickSaved: (t4) => void g5(e39, t4), onStartNew: () => { + let e40 = n2.kind === `none` ? Te3(i3.billing_country ?? ``) : ``; + m3(), u3(`billing_country`, e40 || Ee3(navigator3.language)), c3({ kind: `new`, savesContact: s3 }); + }, onUseSaved: () => { + r2 !== null && g5(e39, r2) || (m3(), c3({ kind: `none` })); + } }); + }, t2[5] = n2, t2[6] = m3, t2[7] = a3, t2[8] = o3, t2[9] = r2, t2[10] = c3, t2[11] = l5, t2[12] = u3, t2[13] = g5, t2[14] = s3, t2[15] = i3, t2[16] = v5) : v5 = t2[16]; + let y4 = v5, x2 = eye(), S2; + if (t2[17] !== y4 || t2[18] !== x2) { + let e39; + t2[20] === y4 ? e39 = t2[21] : (e39 = (e40) => y4(e40), t2[20] = y4, t2[21] = e39), S2 = x2.map(we3).emptyAs([]).inline({ value: e39, loading: y4([], false), unavailable: y4([], false) }), t2[17] = y4, t2[18] = x2, t2[19] = S2; + } else S2 = t2[19]; + return S2; +} +function Yn2(e38) { + Yn2.d = 1309; + let n2 = (0, R2.c)(363), { mode: r2, values: i3, savedValues: a3, fields: o3, initialBilling: s3, initialFiles: u3, offersCapture: d3, detail: f4, status: p4, error: g5, formProps: _5, extraFields: v5, addTitle: y4, submitLabel: b2, onValueChange: x2, onBillingChange: S2, onSubmit: C2, onDiscardEdits: w2, onClose: T2 } = e38, D2; + n2[0] === u3 ? D2 = n2[1] : (D2 = u3 === void 0 ? [] : u3, n2[0] = u3, n2[1] = D2); + let O2 = D2, k2 = d3 === void 0 || d3, { _: j2 } = fx(), ee2 = (0, L2.useId)(), te2 = (0, L2.useId)(), z2 = (0, L2.useId)(), B3 = (0, L2.useId)(), V3 = (0, L2.useId)(), H3; + n2[2] !== ee2 || n2[3] !== te2 || n2[4] !== z2 || n2[5] !== B3 || n2[6] !== V3 ? (H3 = { number: ee2, expiry: te2, securityCode: z2, holderName: B3, nickname: V3 }, n2[2] = ee2, n2[3] = te2, n2[4] = z2, n2[5] = B3, n2[6] = V3, n2[7] = H3) : H3 = n2[7]; + let U3 = H3, W3 = r2.kind === `add`, G2 = W3 && k2, [K4, re3] = (0, L2.useState)(f4 === void 0 ? `form` : `detail`), [ie3, ae3] = (0, L2.useState)(false), [oe5, se5] = (0, L2.useState)(null), [J4, le6] = (0, L2.useState)(null), [Y6, X6] = (0, L2.useState)(false), [ue6, de6] = (0, L2.useState)(false), Z6; + n2[8] !== s3 || n2[9] !== i3 ? (Z6 = () => s3 ?? Bn2(i3), n2[8] = s3, n2[9] = i3, n2[10] = Z6) : Z6 = n2[10]; + let [pe5, me5] = (0, L2.useState)(Z6), [he5, ge5] = (0, L2.useState)(s3?.kind === `saved` ? s3.id : null), _e5 = tye(pe5.kind === `saved` ? pe5.id : null), ve5; + n2[11] !== pe5 || n2[12] !== _e5 ? (ve5 = pe5.kind === `saved` && _e5 === `` ? { kind: `new`, savesContact: false } : pe5, n2[11] = pe5, n2[12] = _e5, n2[13] = ve5) : ve5 = n2[13]; + let ye5 = ve5, be5; + n2[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (be5 = { type: `home`, name: null }, n2[14] = be5) : be5 = n2[14]; + let [xe5, we5] = (0, L2.useState)(be5), Te5 = xe5.name ?? i3.cc_name ?? ``, Ee5; + n2[15] !== xe5.type || n2[16] !== Te5 ? (Ee5 = { type: xe5.type, name: Te5 }, n2[15] = xe5.type, n2[16] = Te5, n2[17] = Ee5) : Ee5 = n2[17]; + let De5 = Ee5, Oe5 = (0, L2.useRef)(null), ke5 = (0, L2.useRef)(null), Ae5 = (0, L2.useRef)(`replace`), je5 = (0, L2.useRef)(null), Me5 = p4 === `submitting`, Ne5 = Me5 || p4 === `disabled`, Pe5 = Me5 || f4?.isRemoving === true, Fe4 = G2 && !Ne5 && !(K4 === `scan` && ue6), Ie5; + n2[18] !== G2 || n2[19] !== O2 ? (Ie5 = G2 ? O2 : [], n2[18] = G2, n2[19] = O2, n2[20] = Ie5) : Ie5 = n2[20]; + let ze5; + n2[21] === i3 ? ze5 = n2[22] : (ze5 = () => zn2(i3), n2[21] = i3, n2[22] = ze5); + let We4; + n2[23] === x2 ? We4 = n2[24] : (We4 = (e39) => { + for (let [t2, n3] of Object.entries(e39)) n3 !== void 0 && x2(t2, n3); + e39.cc_number !== void 0 && ae3(true); + }, n2[23] = x2, n2[24] = We4); + let Ge4; + n2[25] === K4 ? Ge4 = n2[26] : (Ge4 = () => { + K4 === `scan` && (le6(null), X6(false), re3(`form`)); + }, n2[25] = K4, n2[26] = Ge4); + let Ke4; + n2[27] !== Fe4 || n2[28] !== Ie5 || n2[29] !== ze5 || n2[30] !== We4 || n2[31] !== Ge4 ? (Ke4 = { canAct: Fe4, initialFiles: Ie5, currentValues: ze5, onFill: We4, onPhotosOffered: Ge4 }, n2[27] = Fe4, n2[28] = Ie5, n2[29] = ze5, n2[30] = We4, n2[31] = Ge4, n2[32] = Ke4) : Ke4 = n2[32]; + let qe4 = Lt2(Ke4), Je4; + n2[33] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (Je4 = () => { + je5.current !== null && (je5.current = null, Oe5.current?.focus()); + }, n2[33] = Je4) : Je4 = n2[33], OE(Je4); + let Q6 = qe4.status, Ye4 = G2 && qe4.isEnabled, Xe4 = Q6.kind === `reading`, Ze4 = Q6.kind === `settled` && Q6.isFilled, Qe4 = (i3.cc_number ?? ``).length > 0, $e4 = J4?.kind === `read`, et4, tt4; + if (n2[34] !== Ye4 || n2[35] !== o3.holderName || n2[36] !== o3.securityCode || n2[37] !== Qe4 || n2[38] !== Ze4 || n2[39] !== qe4.photos || n2[40] !== J4 || n2[41] !== Q6 || n2[42] !== i3 || n2[43] !== K4) { + let e39 = { securityCode: o3.securityCode, holderName: o3.holderName }, t2 = Ye4 && J4?.kind === `read` ? $t3({ hasCaptured: Object.values(J4.values).some(Xn2), sidesRead: J4.sidesRead, values: i3, asks: e39 }) : null; + et4 = t2 === null ? null : { missing: t2 }; + let r3 = Ze4 && Qe4 ? $t3({ hasCaptured: true, sidesRead: qe4.photos.length, values: i3, asks: e39 }) : null; + tt4 = Wn2({ view: K4, status: Q6, hasNumber: Qe4, scanFlip: et4, photoFlip: r3 }), n2[34] = Ye4, n2[35] = o3.holderName, n2[36] = o3.securityCode, n2[37] = Qe4, n2[38] = Ze4, n2[39] = qe4.photos, n2[40] = J4, n2[41] = Q6, n2[42] = i3, n2[43] = K4, n2[44] = et4, n2[45] = tt4; + } else et4 = n2[44], tt4 = n2[45]; + let nt4 = tt4, rt5 = Ye4 && (nt4 !== null || Ze4 || $e4), it5; + n2[46] !== j2 || n2[47] !== rt5 || n2[48] !== J4 || n2[49] !== Q6 ? (it5 = rt5 ? null : Gn2(J4, Q6, j2), n2[46] = j2, n2[47] = rt5, n2[48] = J4, n2[49] = Q6, n2[50] = it5) : it5 = n2[50]; + let at4 = it5, ot4; + n2[51] !== j2 || n2[52] !== Q6.kind || n2[53] !== Q6.notice || n2[54] !== K4 ? (ot4 = K4 === `form` && Q6.kind === `settled` && Q6.notice !== null ? j2(Q6.notice) : null, n2[51] = j2, n2[52] = Q6.kind, n2[53] = Q6.notice, n2[54] = K4, n2[55] = ot4) : ot4 = n2[55]; + let st3 = ot4, ct3 = Ze4 && Qe4 && ie3, lt3; + n2[56] !== j2 || n2[57] !== rt5 || n2[58] !== Ze4 || n2[59] !== $e4 || n2[60] !== i3.cc_exp ? (lt3 = rt5 && (Ze4 || $e4) && (i3.cc_exp ?? ``).length === 0 ? j2({ id: `VKTdOU` }) : null, n2[56] = j2, n2[57] = rt5, n2[58] = Ze4, n2[59] = $e4, n2[60] = i3.cc_exp, n2[61] = lt3) : lt3 = n2[61]; + let ut3 = lt3, dt3, ft3, pt4, mt5, ht4, gt3, _t3, vt3, yt4, bt4, xt3, St4, Ct3; + if (n2[62] !== j2 || n2[63] !== y4 || n2[64] !== pe5.kind || n2[65] !== Ye4 || n2[66] !== at4 || n2[67] !== De5 || n2[68] !== xe5.name || n2[69] !== f4 || n2[70] !== p4 || n2[71] !== g5 || n2[72] !== ut3 || n2[73] !== v5 || n2[74] !== o3.billing || n2[75] !== o3.holderName || n2[76] !== o3.nickname || n2[77] !== o3.securityCode || n2[78] !== oe5 || n2[79] !== _5 || n2[80] !== U3.expiry || n2[81] !== U3.holderName || n2[82] !== U3.nickname || n2[83] !== U3.number || n2[84] !== U3.securityCode || n2[85] !== s3 || n2[86] !== W3 || n2[87] !== Ne5 || n2[88] !== rt5 || n2[89] !== ue6 || n2[90] !== ie3 || n2[91] !== Ze4 || n2[92] !== Xe4 || n2[93] !== $e4 || n2[94] !== Pe5 || n2[95] !== he5 || n2[96] !== r2.brand || n2[97] !== r2.kind || n2[98] !== r2.last4 || n2[99] !== r2.title || n2[100] !== S2 || n2[101] !== T2 || n2[102] !== w2 || n2[103] !== C2 || n2[104] !== x2 || n2[105] !== qe4 || n2[106] !== st3 || n2[107] !== _e5 || n2[108] !== a3 || n2[109] !== et4 || n2[110] !== J4 || n2[111] !== ye5 || n2[112] !== ct3 || n2[113] !== i3 || n2[114] !== K4) { + let e39 = W3 ? Ce3(i3) : Se3(i3, a3), t2 = pe5.kind === `saved` && _e5 === void 0; + dt3 = p4 === `ready` && e39 && !Xe4 && !t2; + let u4; + n2[128] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u4 = function(e40) { + Ae5.current = e40, ke5.current?.click(); + }, n2[128] = u4) : u4 = n2[128], bt4 = u4; + let d4; + n2[129] === qe4 ? d4 = n2[130] : (d4 = function(e40) { + let t3 = Array.from(e40.currentTarget.files ?? []); + e40.currentTarget.value = ``, t3.length !== 0 && (le6(null), re3(`form`), Ae5.current === `add` ? qe4.addFiles(t3) : qe4.replaceFiles(t3)); + }, n2[129] = qe4, n2[130] = d4), _t3 = d4, vt3 = function(e40) { + e40.preventDefault(), dt3 && C2?.({ billing: ye5, contact: De5 }); + }; + let m3; + n2[131] !== f4 || n2[132] !== s3 || n2[133] !== Pe5 || n2[134] !== T2 || n2[135] !== w2 || n2[136] !== i3 || n2[137] !== K4 ? (m3 = function() { + if (Pe5) return; + if (K4 === `detail` || f4 === void 0) { + T2(); + return; + } + w2?.(); + let e40 = s3 ?? Bn2(i3); + me5(e40), ge5(e40.kind === `saved` ? e40.id : null), we5({ type: `home`, name: null }), re3(`detail`); + }, n2[131] = f4, n2[132] = s3, n2[133] = Pe5, n2[134] = T2, n2[135] = w2, n2[136] = i3, n2[137] = K4, n2[138] = m3) : m3 = n2[138], pt4 = m3; + let b3 = r2.kind === `edit` ? r2.title : ``, D3 = r2.kind === `edit` ? r2.last4 : ``, O3; + n2[139] !== b3 || n2[140] !== D3 ? (O3 = (0, q3.jsx)(mx, { id: `g7bjyf`, values: { cardTitle: b3, last4: D3 } }), n2[139] = b3, n2[140] = D3, n2[141] = O3) : O3 = n2[141], Ct3 = O3; + let k3; + if (n2[142] !== ue6 || n2[143] !== et4 || n2[144] !== J4 || n2[145] !== i3 || n2[146] !== K4 ? (k3 = K4 === `scan` && ue6 && et4 !== null && J4?.kind === `read` ? { ...et4, sidesRead: J4.flipFront, current: i3 } : null, n2[142] = ue6, n2[143] = et4, n2[144] = J4, n2[145] = i3, n2[146] = K4, n2[147] = k3) : k3 = n2[147], mt5 = k3, mt5 !== null) { + let e40; + n2[148] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e40 = (0, q3.jsx)(Hn2, {}), n2[148] = e40) : e40 = n2[148], Ct3 = e40; + } else if (K4 === `scan`) { + let e40; + n2[149] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e40 = (0, q3.jsx)(mx, { id: `DHIemU` }), n2[149] = e40) : e40 = n2[149], Ct3 = e40; + } else if (K4 === `detail` && f4 !== void 0) Ct3 = f4.title; + else if (W3) { + let e40; + n2[150] === y4 ? e40 = n2[151] : (e40 = y4 ?? (0, q3.jsx)(mx, { id: `pnrmSP` }), n2[150] = y4, n2[151] = e40), Ct3 = e40; + } + let A2; + n2[152] !== f4?.card || n2[153] !== r2.brand || n2[154] !== r2.kind ? (A2 = r2.kind === `edit` ? r2.brand : fe3(f4?.card.brand ?? ``), n2[152] = f4?.card, n2[153] = r2.brand, n2[154] = r2.kind, n2[155] = A2) : A2 = n2[155], ft3 = A2, yt4 = r2.kind === `edit` && K4 !== `scan`; + let N3 = Ne5 || Xe4, ee3; + n2[156] !== o3.holderName || n2[157] !== N3 || n2[158] !== U3.holderName || n2[159] !== x2 || n2[160] !== i3.cc_name ? (ee3 = o3.holderName ? (0, q3.jsx)(Zn2, { id: U3.holderName, isDisabled: N3, onValueChange: x2, value: i3.cc_name ?? `` }) : null, n2[156] = o3.holderName, n2[157] = N3, n2[158] = U3.holderName, n2[159] = x2, n2[160] = i3.cc_name, n2[161] = ee3) : ee3 = n2[161]; + let P3 = ee3, F2; + n2[162] !== o3.nickname || n2[163] !== N3 || n2[164] !== U3.nickname || n2[165] !== x2 || n2[166] !== i3.cc_nickname ? (F2 = o3.nickname ? (0, q3.jsx)(Qn2, { id: U3.nickname, isDisabled: N3, onValueChange: x2, value: i3.cc_nickname ?? `` }) : null, n2[162] = o3.nickname, n2[163] = N3, n2[164] = U3.nickname, n2[165] = x2, n2[166] = i3.cc_nickname, n2[167] = F2) : F2 = n2[167]; + let te3 = F2, L3; + n2[168] !== j2 || n2[169] !== o3.securityCode || n2[170] !== N3 || n2[171] !== U3.securityCode || n2[172] !== rt5 || n2[173] !== x2 || n2[174] !== i3.cc_csc ? (L3 = o3.securityCode ? (0, q3.jsx)(Le3, { htmlFor: U3.securityCode, isOptional: true, label: (0, q3.jsx)(mx, { id: `wLmRnI` }), children: (0, q3.jsx)(Ue2, { id: U3.securityCode, isDisabled: N3, onValueChange: (e40) => x2(`cc_csc`, e40), ...rt5 ? { placeholder: j2({ id: `gPftWF` }) } : {}, value: i3.cc_csc ?? `` }) }) : null, n2[168] = j2, n2[169] = o3.securityCode, n2[170] = N3, n2[171] = U3.securityCode, n2[172] = rt5, n2[173] = x2, n2[174] = i3.cc_csc, n2[175] = L3) : L3 = n2[175]; + let R3 = L3, z3 = r2.kind === `edit` ? te3 : R3, B4 = null; + if (r2.kind === `edit`) B4 = P3; + else if (o3.holderName || o3.nickname) { + let e40; + n2[176] !== P3 || n2[177] !== te3 ? (e40 = (0, q3.jsxs)(Re3, { children: [P3, te3] }), n2[176] = P3, n2[177] = te3, n2[178] = e40) : e40 = n2[178], B4 = e40; + } + let V4 = oe5 !== null && oe5 === (i3.cc_number ?? ``), H4; + if (r2.kind === `edit`) { + let e40; + n2[179] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e40 = (0, q3.jsx)(mx, { id: `9SZdi5` }), n2[179] = e40) : e40 = n2[179], H4 = e40; + } else if (ct3) { + let e40; + n2[180] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e40 = (0, q3.jsx)(mx, { id: `2M55hZ` }), n2[180] = e40) : e40 = n2[180], H4 = e40; + } + let G3; + n2[181] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (G3 = (0, q3.jsx)(Xb2, { level: `label`, style: $3.footerNote, children: (0, q3.jsx)(mx, { id: `2M55hZ` }) }), n2[181] = G3) : G3 = n2[181]; + let ce6 = G3, Y7; + n2[182] !== Ye4 || n2[183] !== at4 || n2[184] !== Ne5 || n2[185] !== rt5 || n2[186] !== Xe4 ? (Y7 = Ye4 && !rt5 ? (0, q3.jsxs)(q3.Fragment, { children: [(0, q3.jsxs)(`div`, { className: `sand-rvj5dj sand-cjjqqt sand-tqikln`, children: [(0, q3.jsx)(LS, { disabled: Ne5 || Xe4, leadingIcon: `camera`, onClick: () => { + le6(null), de6(false), re3(`scan`); + }, size: `md`, style: [$3.captureButton, Jb2.body1], type: `button`, variant: `secondary`, children: (0, q3.jsx)(mx, { id: `mJqMSE` }) }), (0, q3.jsx)(LS, { "aria-disabled": Xe4 || void 0, disabled: Ne5, ...Xe4 ? {} : { leadingIcon: `credit-card` }, onClick: () => { + Xe4 || bt4(`replace`); + }, size: `md`, style: [$3.captureButton, Jb2.body1], type: `button`, variant: `secondary`, children: Xe4 ? (0, q3.jsxs)(q3.Fragment, { children: [(0, q3.jsx)(`span`, { className: `sand-3nfvp2 sand-belrpt sand-mziwt1`, children: (0, q3.jsx)(PS, { borderWidth: 2, inheritColor: true, size: 14 }) }), (0, q3.jsx)(mx, { id: `aZac5h` })] }) : (0, q3.jsx)(mx, { id: `WnfuZ0` }) })] }), at4 === null ? null : (0, q3.jsx)(Xb2, { level: `label`, role: `alert`, style: $3.captureWarning, children: at4 }), (0, q3.jsx)(Xb2, { level: `body2`, style: $3.divider, children: (0, q3.jsx)(mx, { id: `ciVOzZ` }) })] }) : null, n2[182] = Ye4, n2[183] = at4, n2[184] = Ne5, n2[185] = rt5, n2[186] = Xe4, n2[187] = Y7) : Y7 = n2[187]; + let X7; + n2[188] === st3 ? X7 = n2[189] : (X7 = st3 === null ? null : (0, q3.jsx)(Xb2, { level: `label`, role: `status`, style: $3.captureWarning, children: st3 }), n2[188] = st3, n2[189] = X7); + let Z7; + n2[190] === Xe4 ? Z7 = n2[191] : (Z7 = { 0: { className: `sand-78zum5 sand-dt5ytf sand-1v2ro7d` }, 1: { className: `sand-78zum5 sand-dt5ytf sand-1v2ro7d sand-ti2d7y` } }[!!Xe4 << 0], n2[190] = Xe4, n2[191] = Z7); + let ve6; + n2[192] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (ve6 = (0, q3.jsx)(mx, { id: `xHIEQ5` }), n2[192] = ve6) : ve6 = n2[192]; + let be6; + n2[193] === V4 ? be6 = n2[194] : (be6 = V4 ? (0, q3.jsx)(mx, { id: `w4wCgl` }) : void 0, n2[193] = V4, n2[194] = be6); + let Te6; + n2[195] !== N3 || n2[196] !== U3.number || n2[197] !== V4 || n2[198] !== ie3 || n2[199] !== r2.brand || n2[200] !== r2.kind || n2[201] !== r2.last4 || n2[202] !== x2 || n2[203] !== i3.cc_number ? (Te6 = r2.kind === `edit` ? (0, q3.jsx)(Ve3, { brand: r2.brand, id: U3.number, last4: r2.last4 }) : (0, q3.jsx)(Be3, { id: U3.number, inputRef: Oe5, isDisabled: N3, isInvalid: V4, isMasked: ie3, onBlur: () => { + let e40 = i3.cc_number ?? ``; + se5(ne2(e40) === null ? null : e40); + }, onReveal: () => ae3(false), onValueChange: (e40) => x2(`cc_number`, e40), value: i3.cc_number ?? `` }), n2[195] = N3, n2[196] = U3.number, n2[197] = V4, n2[198] = ie3, n2[199] = r2.brand, n2[200] = r2.kind, n2[201] = r2.last4, n2[202] = x2, n2[203] = i3.cc_number, n2[204] = Te6) : Te6 = n2[204]; + let Ee6; + n2[205] !== U3.number || n2[206] !== H4 || n2[207] !== be6 || n2[208] !== Te6 ? (Ee6 = (0, q3.jsx)(Le3, { hint: H4, htmlFor: U3.number, label: ve6, warning: be6, children: Te6 }), n2[205] = U3.number, n2[206] = H4, n2[207] = be6, n2[208] = Te6, n2[209] = Ee6) : Ee6 = n2[209]; + let je6; + n2[210] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (je6 = (0, q3.jsx)(mx, { id: `agO/T/` }), n2[210] = je6) : je6 = n2[210]; + let Me6 = ut3 ?? void 0, Fe5 = ut3 !== null, Ie6; + n2[211] === x2 ? Ie6 = n2[212] : (Ie6 = (e40) => x2(`cc_exp`, e40), n2[211] = x2, n2[212] = Ie6); + let ze6 = i3.cc_exp ?? ``, We5; + n2[213] !== N3 || n2[214] !== U3.expiry || n2[215] !== Fe5 || n2[216] !== Ie6 || n2[217] !== ze6 ? (We5 = (0, q3.jsx)(He3, { id: U3.expiry, isDisabled: N3, isInvalid: Fe5, onValueChange: Ie6, value: ze6 }), n2[213] = N3, n2[214] = U3.expiry, n2[215] = Fe5, n2[216] = Ie6, n2[217] = ze6, n2[218] = We5) : We5 = n2[218]; + let Ge5; + n2[219] !== U3.expiry || n2[220] !== Me6 || n2[221] !== We5 ? (Ge5 = (0, q3.jsx)(Le3, { htmlFor: U3.expiry, label: je6, warning: Me6, children: We5 }), n2[219] = U3.expiry, n2[220] = Me6, n2[221] = We5, n2[222] = Ge5) : Ge5 = n2[222]; + let Ke5; + n2[223] !== z3 || n2[224] !== Ge5 ? (Ke5 = (0, q3.jsxs)(Re3, { children: [Ge5, z3] }), n2[223] = z3, n2[224] = Ge5, n2[225] = Ke5) : Ke5 = n2[225]; + let Je5; + n2[226] !== B4 || n2[227] !== Z7 || n2[228] !== Ee6 || n2[229] !== Ke5 ? (Je5 = (0, q3.jsxs)(`div`, { ...Z7, children: [Ee6, Ke5, B4] }), n2[226] = B4, n2[227] = Z7, n2[228] = Ee6, n2[229] = Ke5, n2[230] = Je5) : Je5 = n2[230]; + let Q7; + n2[231] !== De5 || n2[232] !== xe5.name || n2[233] !== o3.billing || n2[234] !== N3 || n2[235] !== Xe4 || n2[236] !== he5 || n2[237] !== S2 || n2[238] !== x2 || n2[239] !== ye5 || n2[240] !== i3 ? (Q7 = o3.billing === `off` ? null : (0, q3.jsx)(`div`, { ...{ 0: {}, 1: { className: `sand-ti2d7y` } }[!!Xe4 << 0], children: (0, q3.jsx)(Jn3, { choice: ye5, contact: De5, lastSavedId: he5, isDisabled: N3, onChoiceChange: (e40) => { + me5(e40), e40.kind === `saved` && ge5(e40.id), S2?.(e40); + }, onContactChange: (e40) => we5({ type: e40.type, name: e40.name === De5.name ? xe5.name : e40.name }), onValueChange: x2, savesNewAddress: o3.billing === `address-or-contact`, values: i3 }) }), n2[231] = De5, n2[232] = xe5.name, n2[233] = o3.billing, n2[234] = N3, n2[235] = Xe4, n2[236] = he5, n2[237] = S2, n2[238] = x2, n2[239] = ye5, n2[240] = i3, n2[241] = Q7) : Q7 = n2[241]; + let Qe5; + if (n2[242] !== v5 || n2[243] !== Y7 || n2[244] !== X7 || n2[245] !== Je5 || n2[246] !== Q7 ? (Qe5 = (0, q3.jsxs)(q3.Fragment, { children: [Y7, X7, Je5, Q7, v5] }), n2[242] = v5, n2[243] = Y7, n2[244] = X7, n2[245] = Je5, n2[246] = Q7, n2[247] = Qe5) : Qe5 = n2[247], gt3 = Qe5, xt3 = null, K4 === `form` && W3 && Ze4) { + let e40; + n2[248] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e40 = () => bt4(`replace`), n2[248] = e40) : e40 = n2[248]; + let t3; + n2[249] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (t3 = (0, q3.jsx)(mx, { id: `RwE+6a` }), n2[249] = t3) : t3 = n2[249]; + let r3; + n2[250] === Ne5 ? r3 = n2[251] : (r3 = (0, q3.jsx)(CC.Action, { disabled: Ne5, onClick: e40, style: Jb2.body1, type: `button`, children: t3 }), n2[250] = Ne5, n2[251] = r3), xt3 = r3; + } else if (K4 === `form` && W3 && $e4) { + let e40; + n2[252] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e40 = () => { + le6(null), de6(false), re3(`scan`); + }, n2[252] = e40) : e40 = n2[252]; + let t3; + n2[253] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (t3 = (0, q3.jsx)(mx, { id: `zy1TsH` }), n2[253] = t3) : t3 = n2[253]; + let r3; + n2[254] === Ne5 ? r3 = n2[255] : (r3 = (0, q3.jsx)(CC.Action, { disabled: Ne5, onClick: e40, style: Jb2.body1, type: `button`, children: t3 }), n2[254] = Ne5, n2[255] = r3), xt3 = r3; + } + if (ht4 = ce6, g5 != null) { + let e40; + n2[256] === g5 ? e40 = n2[257] : (e40 = (0, q3.jsx)(Xb2, { level: `label`, role: `alert`, style: $3.footerError, children: g5 }), n2[256] = g5, n2[257] = e40), ht4 = e40; + } else if (ct3 || Ze4 && W3) { + let e40; + n2[258] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e40 = (0, q3.jsx)(`span`, { className: `sand-1iyjqo2 sand-euugli sand-1o0liin` }), n2[258] = e40) : e40 = n2[258], ht4 = e40; + } + St4 = _5?.(dt3), n2[62] = j2, n2[63] = y4, n2[64] = pe5.kind, n2[65] = Ye4, n2[66] = at4, n2[67] = De5, n2[68] = xe5.name, n2[69] = f4, n2[70] = p4, n2[71] = g5, n2[72] = ut3, n2[73] = v5, n2[74] = o3.billing, n2[75] = o3.holderName, n2[76] = o3.nickname, n2[77] = o3.securityCode, n2[78] = oe5, n2[79] = _5, n2[80] = U3.expiry, n2[81] = U3.holderName, n2[82] = U3.nickname, n2[83] = U3.number, n2[84] = U3.securityCode, n2[85] = s3, n2[86] = W3, n2[87] = Ne5, n2[88] = rt5, n2[89] = ue6, n2[90] = ie3, n2[91] = Ze4, n2[92] = Xe4, n2[93] = $e4, n2[94] = Pe5, n2[95] = he5, n2[96] = r2.brand, n2[97] = r2.kind, n2[98] = r2.last4, n2[99] = r2.title, n2[100] = S2, n2[101] = T2, n2[102] = w2, n2[103] = C2, n2[104] = x2, n2[105] = qe4, n2[106] = st3, n2[107] = _e5, n2[108] = a3, n2[109] = et4, n2[110] = J4, n2[111] = ye5, n2[112] = ct3, n2[113] = i3, n2[114] = K4, n2[115] = dt3, n2[116] = ft3, n2[117] = pt4, n2[118] = mt5, n2[119] = ht4, n2[120] = gt3, n2[121] = _t3, n2[122] = vt3, n2[123] = yt4, n2[124] = bt4, n2[125] = xt3, n2[126] = St4, n2[127] = Ct3; + } else dt3 = n2[115], ft3 = n2[116], pt4 = n2[117], mt5 = n2[118], ht4 = n2[119], gt3 = n2[120], _t3 = n2[121], vt3 = n2[122], yt4 = n2[123], bt4 = n2[124], xt3 = n2[125], St4 = n2[126], Ct3 = n2[127]; + let wt3 = St4, Tt3; + n2[259] !== dt3 || n2[260] !== vt3 || n2[261] !== wt3 ? (Tt3 = (e39) => { + if (wt3?.onSubmit !== void 0) { + dt3 ? wt3.onSubmit(e39) : e39.preventDefault(); + return; + } + vt3(e39); + }, n2[259] = dt3, n2[260] = vt3, n2[261] = wt3, n2[262] = Tt3) : Tt3 = n2[262]; + let Et3; + n2[263] === gt3 ? Et3 = n2[264] : (Et3 = (0, q3.jsx)(CC.Body, { style: $3.body, children: gt3 }), n2[263] = gt3, n2[264] = Et3); + let Dt4 = yt4 && $3.footerPlain, Ot4; + n2[265] === Dt4 ? Ot4 = n2[266] : (Ot4 = [$3.footer, Dt4], n2[265] = Dt4, n2[266] = Ot4); + let kt4 = !dt3, At3; + n2[267] === b2 ? At3 = n2[268] : (At3 = b2 ?? (0, q3.jsx)(mx, { id: `xGekty` }), n2[267] = b2, n2[268] = At3); + let jt3; + n2[269] !== Me5 || n2[270] !== kt4 || n2[271] !== At3 ? (jt3 = (0, q3.jsx)(CC.Action, { disabled: kt4, pending: Me5, style: Jb2.body1, type: `submit`, variant: `primary`, children: At3 }), n2[269] = Me5, n2[270] = kt4, n2[271] = At3, n2[272] = jt3) : jt3 = n2[272]; + let Mt4; + n2[273] !== ht4 || n2[274] !== xt3 || n2[275] !== Ot4 || n2[276] !== jt3 ? (Mt4 = (0, q3.jsxs)(CC.ActionBar, { style: Ot4, children: [ht4, xt3, jt3] }), n2[273] = ht4, n2[274] = xt3, n2[275] = Ot4, n2[276] = jt3, n2[277] = Mt4) : Mt4 = n2[277]; + let Nt3; + n2[278] !== wt3 || n2[279] !== Tt3 || n2[280] !== Et3 || n2[281] !== Mt4 ? (Nt3 = (0, q3.jsxs)(`form`, { noValidate: true, ...wt3, onSubmit: Tt3, children: [Et3, Mt4] }), n2[278] = wt3, n2[279] = Tt3, n2[280] = Et3, n2[281] = Mt4, n2[282] = Nt3) : Nt3 = n2[282]; + let Pt4 = Nt3; + if (K4 === `detail` && f4 !== void 0) { + let e39; + n2[283] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = () => re3(`form`), n2[283] = e39) : e39 = n2[283]; + let t2; + n2[284] !== f4 || n2[285] !== g5 || n2[286] !== Ne5 || n2[287] !== T2 ? (t2 = (0, q3.jsx)($n, { detail: f4, error: g5, isBusy: Ne5, onEdit: e39, onClose: T2 }), n2[284] = f4, n2[285] = g5, n2[286] = Ne5, n2[287] = T2, n2[288] = t2) : t2 = n2[288], Pt4 = t2; + } else if (K4 === `scan`) { + let e39; + n2[289] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = [$3.body, $3.bodyScan], n2[289] = e39) : e39 = n2[289]; + let t2; + n2[290] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (t2 = () => X6(true), n2[290] = t2) : t2 = n2[290]; + let r3; + n2[291] === mt5 ? r3 = n2[292] : (r3 = () => { + mt5 === null && le6({ kind: `failed` }); + }, n2[291] = mt5, n2[292] = r3); + let a4; + n2[293] !== mt5 || n2[294] !== x2 || n2[295] !== J4 || n2[296] !== i3 ? (a4 = (e40, t3) => { + if (X6(false), mt5 !== null && J4?.kind === `read`) { + for (let [t4, n3] of Object.entries(tn3({ current: i3, read: e40 }))) x2(t4, n3); + le6({ kind: `read`, values: { ...J4.values, ...e40 }, sidesRead: t3.length, flipFront: [] }); + } else { + for (let [t4, n3] of Object.entries(e40)) n3 !== void 0 && x2(t4, n3); + ae3(e40.cc_number !== void 0), le6({ kind: `read`, values: e40, sidesRead: t3.length, flipFront: t3.length === 1 ? t3 : [] }); + } + de6(false), re3(`form`); + }, n2[293] = mt5, n2[294] = x2, n2[295] = J4, n2[296] = i3, n2[297] = a4) : a4 = n2[297]; + let o4; + n2[298] !== mt5 || n2[299] !== r3 || n2[300] !== a4 ? (o4 = (0, q3.jsx)(CC.Body, { style: e39, children: (0, q3.jsx)(Dn2, { flip: mt5, onCaptured: t2, onFailed: r3, onRead: a4 }) }), n2[298] = mt5, n2[299] = r3, n2[300] = a4, n2[301] = o4) : o4 = n2[301]; + let s4; + n2[302] === mt5 ? s4 = n2[303] : (s4 = mt5 === null ? [$3.footer, $3.footerSplit] : $3.footer, n2[302] = mt5, n2[303] = s4); + let l5; + n2[304] !== mt5 || n2[305] !== Y6 || n2[306] !== bt4 ? (l5 = mt5 === null ? (0, q3.jsx)(CC.Action, { disabled: Y6, leadingIcon: `credit-card`, onClick: () => bt4(`replace`), style: Jb2.body1, type: `button`, children: (0, q3.jsx)(mx, { id: `WnfuZ0` }) }) : null, n2[304] = mt5, n2[305] = Y6, n2[306] = bt4, n2[307] = l5) : l5 = n2[307]; + let u4; + n2[308] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u4 = () => { + je5.current = `number`, re3(`form`); + }, n2[308] = u4) : u4 = n2[308]; + let d4; + n2[309] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (d4 = (0, q3.jsx)(mx, { id: `KX57vb` }), n2[309] = d4) : d4 = n2[309]; + let f5; + n2[310] === Y6 ? f5 = n2[311] : (f5 = (0, q3.jsx)(CC.Action, { disabled: Y6, leadingIcon: `keyboard`, onClick: u4, style: Jb2.body1, type: `button`, children: d4 }), n2[310] = Y6, n2[311] = f5); + let p5; + n2[312] !== s4 || n2[313] !== l5 || n2[314] !== f5 ? (p5 = (0, q3.jsxs)(CC.ActionBar, { style: s4, children: [l5, f5] }), n2[312] = s4, n2[313] = l5, n2[314] = f5, n2[315] = p5) : p5 = n2[315]; + let m3; + n2[316] !== o4 || n2[317] !== p5 ? (m3 = (0, q3.jsxs)(q3.Fragment, { children: [o4, p5] }), n2[316] = o4, n2[317] = p5, n2[318] = m3) : m3 = n2[318], Pt4 = m3; + } + let Ft3; + n2[319] === pt4 ? Ft3 = n2[320] : (Ft3 = (e39) => { + e39 || pt4(); + }, n2[319] = pt4, n2[320] = Ft3); + let It4; + n2[321] !== W3 || n2[322] !== K4 ? (It4 = K4 === `form` && W3 ? { initialFocus: Oe5 } : {}, n2[321] = W3, n2[322] = K4, n2[323] = It4) : It4 = n2[323]; + let Rt4 = yt4 && $3.headerPlain, zt4; + n2[324] === Rt4 ? zt4 = n2[325] : (zt4 = [$3.header, Rt4], n2[324] = Rt4, n2[325] = zt4); + let Bt4; + n2[326] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (Bt4 = { className: `sand-78zum5 sand-6s0dn4 sand-167g77z sand-euugli` }, n2[326] = Bt4) : Bt4 = n2[326]; + let Vt4; + n2[327] !== ft3 || n2[328] !== K4 ? (Vt4 = K4 === `detail` && ft3 !== null ? (0, q3.jsx)(ce3, { brand: ft3 }) : null, n2[327] = ft3, n2[328] = K4, n2[329] = Vt4) : Vt4 = n2[329]; + let Ht5; + n2[330] === Ct3 ? Ht5 = n2[331] : (Ht5 = (0, q3.jsx)(Kn2, { children: Ct3 }), n2[330] = Ct3, n2[331] = Ht5); + let Ut4; + n2[332] !== Vt4 || n2[333] !== Ht5 ? (Ut4 = (0, q3.jsxs)(`span`, { ...Bt4, children: [Vt4, Ht5] }), n2[332] = Vt4, n2[333] = Ht5, n2[334] = Ut4) : Ut4 = n2[334]; + let Gt3; + n2[335] !== nt4 || n2[336] !== bt4 ? (Gt3 = nt4 === null ? null : (0, q3.jsx)(qn3, { action: nt4.action, message: nt4.message, onAction: () => { + if (nt4.mode !== `scan-back`) { + bt4(nt4.mode); + return; + } + de6(true), re3(`scan`); + } }), n2[335] = nt4, n2[336] = bt4, n2[337] = Gt3) : Gt3 = n2[337]; + let Kt3; + n2[338] === Pe5 ? Kt3 = n2[339] : (Kt3 = Pe5 ? null : (0, q3.jsx)(CC.CloseButton, {}), n2[338] = Pe5, n2[339] = Kt3); + let qt4; + n2[340] !== zt4 || n2[341] !== Ut4 || n2[342] !== Gt3 || n2[343] !== Kt3 ? (qt4 = (0, q3.jsxs)(CC.Header, { style: zt4, children: [Ut4, Gt3, Kt3] }), n2[340] = zt4, n2[341] = Ut4, n2[342] = Gt3, n2[343] = Kt3, n2[344] = qt4) : qt4 = n2[344]; + let Jt5; + n2[345] !== Ye4 || n2[346] !== qe4.isDragOver ? (Jt5 = Ye4 && qe4.isDragOver ? (0, q3.jsxs)(`div`, { "aria-hidden": true, ...h($3.drop, Jb2.body1), children: [(0, q3.jsx)(aS, { name: `image`, size: `sm` }), (0, q3.jsx)(mx, { id: `uyHRvk` })] }) : null, n2[345] = Ye4, n2[346] = qe4.isDragOver, n2[347] = Jt5) : Jt5 = n2[347]; + let Yt5; + n2[348] !== j2 || n2[349] !== Ye4 || n2[350] !== _t3 ? (Yt5 = Ye4 ? (0, q3.jsx)(`input`, { accept: [...f_2].join(`,`), "aria-label": j2({ id: `CfqzS2` }), multiple: true, onChange: _t3, ref: ke5, tabIndex: -1, type: `file`, className: `sand-1s85apg` }) : null, n2[348] = j2, n2[349] = Ye4, n2[350] = _t3, n2[351] = Yt5) : Yt5 = n2[351]; + let Xt5; + n2[352] !== Pt4 || n2[353] !== Ft3 || n2[354] !== It4 || n2[355] !== qt4 || n2[356] !== Jt5 || n2[357] !== Yt5 ? (Xt5 = (0, q3.jsxs)(CC.Root, { onOpenChange: Ft3, open: true, variant: `rich`, width: 420, ...It4, surfaceStyle: $3.surface, children: [qt4, Pt4, Jt5, Yt5] }), n2[352] = Pt4, n2[353] = Ft3, n2[354] = It4, n2[355] = qt4, n2[356] = Jt5, n2[357] = Yt5, n2[358] = Xt5) : Xt5 = n2[358]; + let Zt5 = Xt5, Qt5; + return n2[359] !== Ye4 || n2[360] !== Zt5 || n2[361] !== qe4 ? (Qt5 = (0, q3.jsx)(Wt2, { fill: qe4, isEnabled: Ye4, children: Zt5 }), n2[359] = Ye4, n2[360] = Zt5, n2[361] = qe4, n2[362] = Qt5) : Qt5 = n2[362], Qt5; +} +function Xn2(e38) { + return e38 !== void 0; +} +function Zn2(e38) { + Zn2.d = 1306; + let t2 = (0, R2.c)(11), { id: n2, value: r2, isDisabled: i3, onValueChange: a3 } = e38, o3; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (o3 = (0, q3.jsx)(mx, { id: `Mf9Gtf` }), t2[0] = o3) : o3 = t2[0]; + let s3; + t2[1] === a3 ? s3 = t2[2] : (s3 = (e39) => a3(`cc_name`, e39), t2[1] = a3, t2[2] = s3); + let c3; + t2[3] !== n2 || t2[4] !== i3 || t2[5] !== s3 || t2[6] !== r2 ? (c3 = (0, q3.jsx)(ze3, { autoComplete: `off`, disabled: i3, id: n2, name: `cc_name`, onValueChange: s3, value: r2 }), t2[3] = n2, t2[4] = i3, t2[5] = s3, t2[6] = r2, t2[7] = c3) : c3 = t2[7]; + let l5; + return t2[8] !== n2 || t2[9] !== c3 ? (l5 = (0, q3.jsx)(Le3, { htmlFor: n2, isOptional: true, label: o3, children: c3 }), t2[8] = n2, t2[9] = c3, t2[10] = l5) : l5 = t2[10], l5; +} +function Qn2(e38) { + Qn2.d = 1307; + let t2 = (0, R2.c)(14), { id: n2, value: r2, isDisabled: i3, onValueChange: a3 } = e38, { _: o3 } = fx(), s3; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = (0, q3.jsx)(mx, { id: `4hfTrB` }), t2[0] = s3) : s3 = t2[0]; + let c3; + t2[1] === a3 ? c3 = t2[2] : (c3 = (e39) => a3(`cc_nickname`, e39), t2[1] = a3, t2[2] = c3); + let l5; + t2[3] === o3 ? l5 = t2[4] : (l5 = o3({ id: `H+69ds` }), t2[3] = o3, t2[4] = l5); + let u3; + t2[5] !== n2 || t2[6] !== i3 || t2[7] !== c3 || t2[8] !== l5 || t2[9] !== r2 ? (u3 = (0, q3.jsx)(ze3, { autoComplete: `off`, disabled: i3, id: n2, name: `cc_nickname`, onValueChange: c3, placeholder: l5, value: r2 }), t2[5] = n2, t2[6] = i3, t2[7] = c3, t2[8] = l5, t2[9] = r2, t2[10] = u3) : u3 = t2[10]; + let d3; + return t2[11] !== n2 || t2[12] !== u3 ? (d3 = (0, q3.jsx)(Le3, { htmlFor: n2, isOptional: true, label: s3, children: u3 }), t2[11] = n2, t2[12] = u3, t2[13] = d3) : d3 = t2[13], d3; +} +function $n(e38) { + $n.d = 1302; + let t2 = (0, R2.c)(37), { detail: n2, error: r2, isBusy: i3, onEdit: a3, onClose: o3 } = e38, s3 = v_2(); + wD(s3.load); + let { card: u3 } = n2, f4; + t2[0] !== u3 || t2[1] !== n2.canEdit || t2[2] !== n2.isRemoving || t2[3] !== i3 || t2[4] !== a3 ? (f4 = (e39) => (0, q3.jsx)(Zt3, { card: u3, contact: e39.find((e40) => e40.id === u3.billingAddressId), isDisabled: i3 || n2.isRemoving || !n2.canEdit, onOpenBilling: a3 }), t2[0] = u3, t2[1] = n2.canEdit, t2[2] = n2.isRemoving, t2[3] = i3, t2[4] = a3, t2[5] = f4) : f4 = t2[5]; + let p4 = f4, m3 = eye(), g5; + t2[6] !== p4 || t2[7] !== m3 ? (g5 = m3.map(we3).emptyAs([]).inline({ value: p4, loading: p4([]), unavailable: p4([]) }), t2[6] = p4, t2[7] = m3, t2[8] = g5) : g5 = t2[8]; + let v5; + t2[9] === g5 ? v5 = t2[10] : (v5 = (0, q3.jsx)(CC.Body, { style: $3.body, children: g5 }), t2[9] = g5, t2[10] = v5); + let y4; + t2[11] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (y4 = [$3.footer, $3.footerPlain], t2[11] = y4) : y4 = t2[11]; + let x2; + t2[12] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (x2 = [$3.removeAction, Jb2.body1], t2[12] = x2) : x2 = t2[12]; + let S2; + t2[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (S2 = (0, q3.jsx)(mx, { id: `t/YqKh` }), t2[13] = S2) : S2 = t2[13]; let C2; - t2[24] !== x3 || t2[25] !== S3 ? (C2 = (0, B3.jsxs)(p2, { children: [x3, S3] }), t2[24] = x3, t2[25] = S3, t2[26] = C2) : C2 = t2[26]; - let w3; - return t2[27] !== c2 || t2[28] !== r2 || t2[29] !== f4 || t2[30] !== C2 ? (w3 = (0, B3.jsx)(g, { htmlFor: c2, isRequired: f4, label: r2, requirementMarker: `asterisk`, children: C2 }), t2[27] = c2, t2[28] = r2, t2[29] = f4, t2[30] = C2, t2[31] = w3) : w3 = t2[31], w3; -} -function Ke3(e9) { - return !e9; -} -function qe2(e9) { - qe2.d = 905; - let t2 = (0, z3.c)(26), { field: n2, label: r2, value: i3, isDisabled: a3, onChange: o3, ref: s3 } = e9, c2 = (0, G4.useId)(), l4; - t2[0] === n2.options ? l4 = t2[1] : (l4 = n2.options ?? [], t2[0] = n2.options, t2[1] = l4); - let u3 = l4, d3 = n2.required === true, f4 = n2.id, p4; - t2[2] === o3 ? p4 = t2[3] : (p4 = (e10) => o3(e10.currentTarget.value), t2[2] = o3, t2[3] = p4); - let m3 = n2.required === true, h3; - t2[4] === i3 ? h3 = t2[5] : (h3 = i3 === void 0 ? {} : { value: i3 }, t2[4] = i3, t2[5] = h3); - let g3; - t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g3 = h(d2.control, d2.controlElevated, d2.select, d2.selectElevated), t2[6] = g3) : g3 = t2[6]; - let _2; - t2[7] === u3 ? _2 = t2[8] : (_2 = u3.some(Ye2) ? null : (0, B3.jsx)(`option`, { value: ``, ...h(d2.option) }), t2[7] = u3, t2[8] = _2); - let v3; - t2[9] === u3 ? v3 = t2[10] : (v3 = u3.map(Je2), t2[9] = u3, t2[10] = v3); - let y3; - t2[11] !== n2.id || t2[12] !== c2 || t2[13] !== a3 || t2[14] !== s3 || t2[15] !== p4 || t2[16] !== m3 || t2[17] !== h3 || t2[18] !== _2 || t2[19] !== v3 ? (y3 = (0, B3.jsx)(p2, { children: (0, B3.jsxs)(`select`, { disabled: a3, id: c2, name: f4, onChange: p4, ref: s3, required: m3, ...h3, ...g3, children: [_2, v3] }) }), t2[11] = n2.id, t2[12] = c2, t2[13] = a3, t2[14] = s3, t2[15] = p4, t2[16] = m3, t2[17] = h3, t2[18] = _2, t2[19] = v3, t2[20] = y3) : y3 = t2[20]; - let b3; - return t2[21] !== c2 || t2[22] !== r2 || t2[23] !== y3 || t2[24] !== d3 ? (b3 = (0, B3.jsx)(g, { htmlFor: c2, isRequired: d3, label: r2, requirementMarker: `asterisk`, children: y3 }), t2[21] = c2, t2[22] = r2, t2[23] = y3, t2[24] = d3, t2[25] = b3) : b3 = t2[25], b3; -} -function Je2(e9) { - return (0, B3.jsx)(`option`, { value: e9.value, ...h(d2.option), children: e9.label }, e9.value); -} -function Ye2(e9) { - return e9.value === ``; -} -function Xe2(e9) { - let t2 = Cge(e9); - return wge(t2) ? t2 : ``; -} -var Ze2 = { billing_line1: `line1`, billing_line2: `line2`, billing_city: `city`, billing_region: `region`, billing_postal_code: `postalCode`, billing_country: `country` }; -function Qe2(e9) { - Qe2.d = 904; - let t2 = (0, z3.c)(9), { isDisabled: n2, picked: r2, onPick: i3, onValueChange: a3 } = e9, { _: o3 } = bb(), s3 = kge(); - aO(s3.load); - let c2; - t2[0] !== o3 || t2[1] !== n2 || t2[2] !== i3 || t2[3] !== a3 || t2[4] !== r2 ? (c2 = (e10) => { - if (e10.length === 0) return null; - let t3 = { id: `saved_billing_address`, label: o3({ id: `AUlTmE` }), type: `select`, options: [{ label: o3({ id: `sRag9r` }), value: `` }, ...e10.map(tt2)] }; - return (0, B3.jsx)(qe2, { field: t3, isDisabled: n2, label: t3.label, onChange: (t4) => { - i3(t4); - let n3 = e10.find((e11) => e11.id === t4); - if (n3 !== void 0) for (let [e11, t5] of Object.entries(Ze2)) a3(e11, t5 === `country` ? Xe2(n3.contact.country) : n3.contact[t5]); - }, ref: void 0, value: r2 }); - }, t2[0] = o3, t2[1] = n2, t2[2] = i3, t2[3] = a3, t2[4] = r2, t2[5] = c2) : c2 = t2[5]; - let l4 = c2, u3 = Dge(), d3; - return t2[6] !== l4 || t2[7] !== u3 ? (d3 = u3.map($e2).emptyAs([]).inline({ value: l4, loading: null, unavailable: null }), t2[6] = l4, t2[7] = u3, t2[8] = d3) : d3 = t2[8], d3; -} -function $e2(e9) { - return e9.flatMap(et2); -} -function et2(e9) { - let { id: t2, title: n2, contact: r2 } = e9; - return r2 === void 0 || Object.values(Ze2).every((e10) => r2[e10].trim().length === 0) ? [] : [{ id: t2, title: n2, contact: r2 }]; -} -function tt2(e9) { - let { id: t2, title: n2 } = e9; - return { label: n2, value: t2 }; -} -function nt3(e9) { - nt3.d = 907; - let t2 = (0, z3.c)(33), { fields: n2, valueOf: r2, onValueChange: i3, photoFill: a3, isDisabled: o3, firstFieldRef: s3 } = e9, c2 = o3 !== void 0 && o3, { _: l4 } = bb(), [u3, d3] = (0, G4.useState)(``), f4, p4, m3; - if (t2[0] !== l4 || t2[1] !== n2 || t2[2] !== s3 || t2[3] !== c2 || t2[4] !== i3 || t2[5] !== a3 || t2[6] !== u3 || t2[7] !== r2) { - let e10 = n2.filter(at3), o4 = n2.filter(it2), h4 = e10[0] ?? o4[0], g3 = (e11) => e11 === h4 ? s3 : void 0, _2; - t2[11] !== l4 || t2[12] !== c2 || t2[13] !== i3 || t2[14] !== g3 || t2[15] !== r2 ? (_2 = (e11) => { - let t3 = r2(e11.id), n3 = { field: e11, label: Ue2(e11.id) ? l4(Ve2[e11.id]) : e11.label, value: t3, isDisabled: c2, onChange: (n4) => { - Object.hasOwn(Ze2, e11.id) && d3(``), t3 !== void 0 && i3(e11.id, e11.id === `cc_exp` ? J3({ value: n4, previous: t3 }) : n4); - }, ref: g3(e11) }; - return e11.type === `select` ? (0, B3.jsx)(qe2, { ...n3 }, e11.id) : (0, B3.jsx)(Ge3, { ...n3 }, e11.id); - }, t2[11] = l4, t2[12] = c2, t2[13] = i3, t2[14] = g3, t2[15] = r2, t2[16] = _2) : _2 = t2[16]; - let v3 = _2; - t2[17] === a3 ? f4 = t2[18] : (f4 = a3 === void 0 ? null : (0, B3.jsx)(Re2, { fill: a3 }), t2[17] = a3, t2[18] = f4); - let y3; - t2[19] !== v3 || t2[20] !== c2 || t2[21] !== i3 || t2[22] !== u3 ? (y3 = (e11) => { - let t3 = e11.map(rt2).join(); - return (0, B3.jsxs)(G4.Fragment, { children: [e11[0]?.id === `billing_line1` ? (0, B3.jsx)(Qe2, { isDisabled: c2, onPick: d3, onValueChange: i3, picked: u3 }) : null, e11.length === 1 ? e11.map(v3) : (0, B3.jsx)(`div`, { className: `sand-rvj5dj sand-cjjqqt sand-pqajaz sand-18hwk67 sand-xs79tx`, children: e11.map(v3) })] }, t3); - }, t2[19] = v3, t2[20] = c2, t2[21] = i3, t2[22] = u3, t2[23] = y3) : y3 = t2[23], p4 = We2(e10).map(y3); - let b3; - t2[24] !== c2 || t2[25] !== i3 || t2[26] !== g3 || t2[27] !== r2 ? (b3 = (e11) => (0, B3.jsx)(V3, { id: e11.id, isChecked: r2(e11.id) === `true`, isDisabled: c2, isRequired: e11.required === true, label: e11.label, name: e11.id, onChange: (t3) => i3(e11.id, t3 ? `true` : `false`), ref: g3(e11), requirementMarker: `asterisk` }, e11.id), t2[24] = c2, t2[25] = i3, t2[26] = g3, t2[27] = r2, t2[28] = b3) : b3 = t2[28], m3 = o4.map(b3), t2[0] = l4, t2[1] = n2, t2[2] = s3, t2[3] = c2, t2[4] = i3, t2[5] = a3, t2[6] = u3, t2[7] = r2, t2[8] = f4, t2[9] = p4, t2[10] = m3; - } else f4 = t2[8], p4 = t2[9], m3 = t2[10]; - let h3; - return t2[29] !== f4 || t2[30] !== p4 || t2[31] !== m3 ? (h3 = (0, B3.jsxs)(B3.Fragment, { children: [f4, p4, m3] }), t2[29] = f4, t2[30] = p4, t2[31] = m3, t2[32] = h3) : h3 = t2[32], h3; -} -function rt2(e9) { - return e9.id; -} -function it2(e9) { - return e9.type === `checkbox`; -} -function at3(e9) { - return e9.type !== `checkbox`; + t2[14] !== n2.isRemoving || t2[15] !== n2.onRemove || t2[16] !== i3 ? (C2 = (0, q3.jsx)(CC.Action, { destructive: true, disabled: i3, onClick: n2.onRemove, pending: n2.isRemoving, style: x2, type: `button`, children: S2 }), t2[14] = n2.isRemoving, t2[15] = n2.onRemove, t2[16] = i3, t2[17] = C2) : C2 = t2[17]; + let w2; + t2[18] === r2 ? w2 = t2[19] : (w2 = r2 == null ? null : (0, q3.jsx)(Xb2, { level: `label`, role: `alert`, style: $3.footerError, children: r2 }), t2[18] = r2, t2[19] = w2); + let T2; + t2[20] !== n2.canEdit || t2[21] !== n2.isRemoving || t2[22] !== i3 || t2[23] !== a3 ? (T2 = n2.canEdit ? (0, q3.jsx)(CC.Action, { disabled: i3 || n2.isRemoving, onClick: a3, style: Jb2.body1, type: `button`, children: (0, q3.jsx)(mx, { id: `ePK91l` }) }) : null, t2[20] = n2.canEdit, t2[21] = n2.isRemoving, t2[22] = i3, t2[23] = a3, t2[24] = T2) : T2 = t2[24]; + let E2; + t2[25] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (E2 = (0, q3.jsx)(mx, { id: `DPfwMq` }), t2[25] = E2) : E2 = t2[25]; + let D2; + t2[26] !== n2.isRemoving || t2[27] !== o3 ? (D2 = (0, q3.jsx)(CC.Action, { disabled: n2.isRemoving, onClick: o3, style: Jb2.body1, type: `button`, variant: `primary`, children: E2 }), t2[26] = n2.isRemoving, t2[27] = o3, t2[28] = D2) : D2 = t2[28]; + let O2; + t2[29] !== T2 || t2[30] !== D2 || t2[31] !== C2 || t2[32] !== w2 ? (O2 = (0, q3.jsxs)(CC.ActionBar, { style: y4, children: [C2, w2, T2, D2] }), t2[29] = T2, t2[30] = D2, t2[31] = C2, t2[32] = w2, t2[33] = O2) : O2 = t2[33]; + let k2; + return t2[34] !== O2 || t2[35] !== v5 ? (k2 = (0, q3.jsxs)(q3.Fragment, { children: [v5, O2] }), t2[34] = O2, t2[35] = v5, t2[36] = k2) : k2 = t2[36], k2; } -// ../../../../../private/dist/renderer/assets/chunk-settings-row-C3cXt6xe.js -var y2 = UA(); -var b2 = Ke(); -var x2 = { title: { keoZOQ: `sand-dj266r`, k71WvV: `sand-14z9mp`, k1K539: `sand-at24cr`, keTefX: `sand-1lziwak`, kwRFfy: `sand-1tlft3r`, kZCmMZ: `sand-22095l`, kMwMTN: `sand-1o0liin`, $$css: true }, footer: { keoZOQ: `sand-sejjyr`, k71WvV: `sand-14z9mp`, k1K539: `sand-at24cr`, keTefX: `sand-1lziwak`, kwRFfy: `sand-1tlft3r`, kZCmMZ: `sand-22095l`, kMwMTN: `sand-x1phaw`, $$css: true } }; -function S2(e9) { - S2.d = 1879; - let t2 = (0, y2.c)(19), { title: n2, titleAccessory: r2, children: i3, surface: a3, footer: o3, flushCard: s3 } = e9, c2 = a3 === void 0 ? `card` : a3, l4 = o3 === void 0 ? null : o3, f4 = s3 !== void 0 && s3, p4; - t2[0] === n2 ? p4 = t2[1] : (p4 = n2 == null ? null : (0, b2.jsx)(`h3`, { className: h(x2.title, sx.label, cx.regular).className, children: n2 }), t2[0] = n2, t2[1] = p4); - let m3 = p4, h3; - t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h3 = { className: `sand-78zum5 sand-1plbdn1 sand-dt5ytf sand-1qjc9v5 sand-ehausa` }, t2[2] = h3) : h3 = t2[2]; - let g3 = h3.className, _2; - t2[3] !== m3 || t2[4] !== r2 ? (_2 = r2 == null ? m3 : (0, b2.jsxs)(`div`, { className: `sand-78zum5 sand-6s0dn4 sand-pkkfsy`, children: [m3, r2] }), t2[3] = m3, t2[4] = r2, t2[5] = _2) : _2 = t2[5]; - let C2; - t2[6] !== f4 || t2[7] !== c2 || t2[8] !== n2 ? (C2 = { 0: { className: `sand-78zum5 sand-dt5ytf sand-ehausa sand-1tlft3r sand-22095l` }, 4: { className: `sand-78zum5 sand-dt5ytf sand-7giv3 sand-13ly8rp sand-1xlntvz sand-4hv7ue sand-1y0btm7 sand-5fd6op sand-1pkpdue sand-10e981r` }, 2: { className: `sand-78zum5 sand-dt5ytf sand-ehausa sand-1tlft3r sand-22095l sand-exx8yu sand-18d9i69 sand-c342km sand-t08umf sand-aatb59 sand-1m4v3n6 sand-gwnywf` }, 6: { className: `sand-78zum5 sand-dt5ytf sand-7giv3 sand-1y0btm7 sand-5fd6op sand-1pkpdue sand-10e981r sand-exx8yu sand-18d9i69 sand-c342km sand-t08umf sand-aatb59 sand-1m4v3n6 sand-gwnywf` }, 1: { className: `sand-78zum5 sand-dt5ytf sand-ehausa sand-yri2b sand-1c1uobl` }, 5: { className: `sand-78zum5 sand-dt5ytf sand-7giv3 sand-13ly8rp sand-1xlntvz sand-4hv7ue sand-1y0btm7 sand-5fd6op sand-1pkpdue sand-10e981r sand-yri2b sand-1c1uobl` }, 3: { className: `sand-78zum5 sand-dt5ytf sand-ehausa sand-exx8yu sand-18d9i69 sand-c342km sand-t08umf sand-aatb59 sand-1m4v3n6 sand-gwnywf sand-yri2b sand-1c1uobl` }, 7: { className: `sand-78zum5 sand-dt5ytf sand-7giv3 sand-1y0btm7 sand-5fd6op sand-1pkpdue sand-10e981r sand-exx8yu sand-18d9i69 sand-c342km sand-t08umf sand-aatb59 sand-1m4v3n6 sand-gwnywf sand-yri2b sand-1c1uobl` } }[(c2 === `card`) << 2 | !!(c2 === `card` && f4) << 1 | (c2 === `plain` && n2 == null) << 0], t2[6] = f4, t2[7] = c2, t2[8] = n2, t2[9] = C2) : C2 = t2[9]; - let w3; - t2[10] !== i3 || t2[11] !== C2.className ? (w3 = (0, b2.jsx)(`div`, { className: C2.className, children: i3 }), t2[10] = i3, t2[11] = C2.className, t2[12] = w3) : w3 = t2[12]; - let T3; - t2[13] === l4 ? T3 = t2[14] : (T3 = l4 == null ? null : (0, b2.jsx)(`p`, { ...h(x2.footer, sx.caption, cx.regular), "data-sand-settings-section-footer": true, children: l4 }), t2[13] = l4, t2[14] = T3); - let E3; - return t2[15] !== T3 || t2[16] !== _2 || t2[17] !== w3 ? (E3 = (0, b2.jsxs)(`section`, { className: g3, children: [_2, w3, T3] }), t2[15] = T3, t2[16] = _2, t2[17] = w3, t2[18] = E3) : E3 = t2[18], E3; -} -var w2 = DS(ao); -var T2 = w2.Scope; -var E2 = w2.useRowFocus; -var O2 = { section: { kB7OPa: `sand-9f619`, k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kOIVth: `sand-ou54vl`, $$css: true }, row: { kB7OPa: `sand-9f619`, k1xSpc: `sand-78zum5`, kwnvtZ: `sand-1a02dak`, kGNEyG: `sand-1cy8zhl`, kjj79g: `sand-1qughib`, k1C7PZ: `sand-1qgv0r9`, khm7nJ: `sand-3pnbk8`, "--sand-anchor-reveal": `sand-1xr8qbc sand-jodmca`, $$css: true }, cardRow: { kVAEAm: `sand-1n2onr6`, kGNEyG: `sand-6s0dn4`, k1C7PZ: `sand-1pzdu40`, kLKAdn: `sand-oyc9vk`, kwRFfy: `sand-1n9uuka`, kGO01o: `sand-2lprc`, kZCmMZ: `sand-cssynl`, $$css: true }, copy: { kB7OPa: `sand-9f619`, k1xSpc: `sand-78zum5`, kzQI83: `sand-1iyjqo2`, kmuXW: `sand-s83m0k`, kCS8Yb: `sand-1rnznto`, kXwgrk: `sand-dt5ytf`, kOIVth: `sand-17d4w8g`, k7Eaqz: `sand-euugli`, ks0D6T: `sand-1t8xbu`, kHjlTd: `sand-1mzt3pk`, $$css: true }, cardCopy: { kOIVth: `sand-137clkk`, $$css: true }, control: { kB7OPa: `sand-9f619`, k1xSpc: `sand-78zum5`, kXwgrk: `sand-dt5ytf`, kGNEyG: `sand-uk3077`, kzQI83: `sand-1iyjqo2`, kCS8Yb: `sand-1fig6rf`, ks0D6T: `sand-1t8xbu`, keTefX: `sand-vc5jky`, kOIVth: `sand-xhr3t`, $$css: true }, hint: { kB7OPa: `sand-9f619`, keoZOQ: `sand-1kgmq87`, $$css: true }, labelRow: { kB7OPa: `sand-9f619`, k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-1jnr06f`, k7Eaqz: `sand-euugli`, $$css: true }, label: { k7Eaqz: `sand-euugli`, $$css: true } }; -function k3(e9) { - k3.d = 1946; - let t2 = (0, y2.c)(3), { children: r2 } = e9, i3; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i3 = $(`sand-settings-field__hint`, { className: `sand-9f619 sand-1kgmq87` }.className), t2[0] = i3) : i3 = t2[0]; - let a3; - return t2[1] === r2 ? a3 = t2[2] : (a3 = (0, b2.jsx)(Kd, { as: `span`, className: i3, color: `secondary`, size: `md`, children: r2 }), t2[1] = r2, t2[2] = a3), a3; -} -function A2(e9) { - A2.d = 1944; - let { anchor: t2 } = e9; - return MKt(t2); -} -function j2(e9) { - j2.d = 1945; - let t2 = (0, y2.c)(8), { anchor: n2, label: r2 } = e9, { _: i3 } = bb(), o3 = MKt(n2), s3 = r2 ?? o3, c2; - t2[0] !== i3 || t2[1] !== s3 ? (c2 = i3({ id: `Jeg176`, values: { setting: s3 } }), t2[0] = i3, t2[1] = s3, t2[2] = c2) : c2 = t2[2]; - let l4; - t2[3] === n2 ? l4 = t2[4] : (l4 = jo(n2), t2[3] = n2, t2[4] = l4); +// ../../../../../private/dist/renderer/assets/chunk-vault-card-editor-D3knAB0V.js +var oe3 = Ij(); +var g4 = u(sandVaultReact(), 1); +var se3 = it(); +function _4(e38) { + return `${String(e38.expMonth).padStart(2, `0`)}/${String(e38.expYear % 100).padStart(2, `0`)}`; +} +function ce4(e38) { + return { cc_exp: _4(e38), cc_name: e38.holderName, cc_nickname: e38.nickname, ...De3(e38.billingAddress) }; +} +function le4(e38, t2) { + let n2 = we3(t2).find((t3) => t3.id === e38.billingAddressId && Ae3(ke3(De3(t3.contact)), e38.billingAddress)); + return n2 === void 0 ? Oe3(De3(e38.billingAddress)) ? { kind: `new`, savesContact: false } : { kind: `none` } : { kind: `saved`, id: n2.id }; +} +function ue4(e38, t2) { + return e38 ? `submitting` : t2 ? `disabled` : `ready`; +} +function de4() { + let e38 = (0, oe3.c)(5), [t2, n2] = (0, g4.useState)(null), [r2, a3] = (0, g4.useState)(false), o3 = (0, g4.useRef)(false), s3; + e38[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = async (e39, t3) => { + if (o3.current) return false; + o3.current = true, n2(null), a3(true); + let r3 = await e39().then(v4, (e40) => (n2(aye(e40) ?? t3), false)); + return o3.current = false, a3(false), r3; + }, e38[0] = s3) : s3 = e38[0]; + let c3 = s3, l5; + e38[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = () => n2(null), e38[1] = l5) : l5 = e38[1]; let u3; - return t2[5] !== c2 || t2[6] !== l4 ? (u3 = (0, b2.jsx)(pT, { label: c2, url: l4 }), t2[5] = c2, t2[6] = l4, t2[7] = u3) : u3 = t2[7], u3; -} -function M2(e9) { - M2.d = 1947; - let t2 = (0, y2.c)(47), { label: r2, description: i3, extraCopy: a3, children: l4, variant: u3, anchorId: d3, copyText: f4, labelToken: p4, settingName: g3, labelFocusRef: _2, rootStyle: x3, highlighted: S3 } = e9, C2 = u3 === void 0 ? `default` : u3, w3 = S3 !== void 0 && S3, T3 = C2 === `card`, D2 = d3 === `repeated-row` ? null : d3, N2; - t2[0] !== r2 || t2[1] !== p4 ? (N2 = r2 == null || p4 == null ? r2 : (0, b2.jsx)(XT, { dir: p4.dir, text: r2, token: p4.text }), t2[0] = r2, t2[1] = p4, t2[2] = N2) : N2 = t2[2]; - let P2 = N2, F2; - t2[3] !== D2 || t2[4] !== P2 ? (F2 = P2 ?? (D2 == null ? null : (0, b2.jsx)(A2, { anchor: D2 })), t2[3] = D2, t2[4] = P2, t2[5] = F2) : F2 = t2[5]; - let I = F2; - E2(D2); - let L; - t2[6] !== T3 || t2[7] !== x3 ? (L = $(`sand-settings-row`, h(O2.row, T3 && O2.cardRow, x3).className), t2[6] = T3, t2[7] = x3, t2[8] = L) : L = t2[8]; - let R3 = w3 ? `true` : void 0, z4; - t2[9] === D2 ? z4 = t2[10] : (z4 = D2 == null ? void 0 : ao(D2), t2[9] = D2, t2[10] = z4); - let B4; - t2[11] === T3 ? B4 = t2[12] : (B4 = $(`sand-settings-copy`, { 0: { className: `sand-9f619 sand-78zum5 sand-1iyjqo2 sand-s83m0k sand-1rnznto sand-dt5ytf sand-17d4w8g sand-euugli sand-1t8xbu sand-1mzt3pk` }, 1: { className: `sand-9f619 sand-78zum5 sand-1iyjqo2 sand-s83m0k sand-1rnznto sand-dt5ytf sand-euugli sand-1t8xbu sand-1mzt3pk sand-137clkk` } }[!!T3 << 0].className), t2[11] = T3, t2[12] = B4); - let V4; - t2[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (V4 = { className: `sand-9f619 sand-78zum5 sand-6s0dn4 sand-1jnr06f sand-euugli` }, t2[13] = V4) : V4 = t2[13]; - let H4 = T3 ? `primary` : `secondary`, U4 = T3 ? `md` : `sm`, W4; - t2[14] !== I || t2[15] !== _2 ? (W4 = _2 == null ? I : (0, b2.jsx)(`span`, { ref: _2, ...h(rC.controlRing), children: I }), t2[14] = I, t2[15] = _2, t2[16] = W4) : W4 = t2[16]; - let G5; - t2[17] !== H4 || t2[18] !== U4 || t2[19] !== W4 ? (G5 = (0, b2.jsx)(Kd, { as: `span`, color: H4, rootStyle: O2.label, size: U4, children: W4 }), t2[17] = H4, t2[18] = U4, t2[19] = W4, t2[20] = G5) : G5 = t2[20]; - let K4; - t2[21] === f4 ? K4 = t2[22] : (K4 = f4 == null ? null : (0, b2.jsx)(mT, { label: f4.label, text: f4.value }), t2[21] = f4, t2[22] = K4); - let q4; - t2[23] !== r2 || t2[24] !== D2 || t2[25] !== g3 ? (q4 = D2 == null ? null : (0, b2.jsx)(j2, { anchor: D2, label: g3 ?? r2 }), t2[23] = r2, t2[24] = D2, t2[25] = g3, t2[26] = q4) : q4 = t2[26]; - let J4; - t2[27] !== G5 || t2[28] !== K4 || t2[29] !== q4 ? (J4 = (0, b2.jsxs)(`div`, { className: V4.className, children: [G5, K4, q4] }), t2[27] = G5, t2[28] = K4, t2[29] = q4, t2[30] = J4) : J4 = t2[30]; - let Y4; - t2[31] === i3 ? Y4 = t2[32] : (Y4 = i3 == null ? null : (0, b2.jsx)(k3, { children: i3 }), t2[31] = i3, t2[32] = Y4); - let X4; - t2[33] !== a3 || t2[34] !== J4 || t2[35] !== Y4 || t2[36] !== B4 ? (X4 = (0, b2.jsxs)(`div`, { className: B4, children: [J4, Y4, a3] }), t2[33] = a3, t2[34] = J4, t2[35] = Y4, t2[36] = B4, t2[37] = X4) : X4 = t2[37]; - let Z4; - t2[38] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (Z4 = $(`sand-settings-control`, { className: `sand-9f619 sand-78zum5 sand-dt5ytf sand-uk3077 sand-1iyjqo2 sand-1fig6rf sand-1t8xbu sand-vc5jky sand-xhr3t` }.className), t2[38] = Z4) : Z4 = t2[38]; - let Q3; - t2[39] === l4 ? Q3 = t2[40] : (Q3 = (0, b2.jsx)(`div`, { className: Z4, children: l4 }), t2[39] = l4, t2[40] = Q3); - let $4; - return t2[41] !== X4 || t2[42] !== Q3 || t2[43] !== L || t2[44] !== R3 || t2[45] !== z4 ? ($4 = (0, b2.jsxs)(`div`, { className: L, "data-sand-highlighted": R3, id: z4, children: [X4, Q3] }), t2[41] = X4, t2[42] = Q3, t2[43] = L, t2[44] = R3, t2[45] = z4, t2[46] = $4) : $4 = t2[46], $4; + return e38[2] !== t2 || e38[3] !== r2 ? (u3 = { error: t2, isSaving: r2, run: c3, clearError: l5 }, e38[2] = t2, e38[3] = r2, e38[4] = u3) : u3 = e38[4], u3; } - -// ../../../../../private/dist/renderer/assets/chunk-pane-header-CrSxprOO.js -var f3 = u(sandVaultReact(), 1); -var p3 = u(Ei(), 1); -var g2 = (0, f3.createContext)(null); -function v2({ children: e9 }) { - v2.d = 1810; - let t2 = (0, f3.use)(g2); - return t2 === null ? null : (0, p3.createPortal)(e9, t2); +function v4() { + return true; } - -// ../../../../../private/dist/renderer/assets/chunk-scroll-pane-xfE80KzA.js -var i2 = UA(); -var a2 = Ke(); -function o2(t2) { - o2.d = 1813; - let r2 = (0, i2.c)(18), { children: s3, ref: c2 } = t2, l4, u3, d3, f4, p4, m3; - r2[0] === c2 ? (l4 = r2[1], u3 = r2[2], d3 = r2[3], f4 = r2[4], p4 = r2[5], m3 = r2[6]) : (u3 = { className: `sand-9f619 sand-1xy6bms sand-1s169rl sand-84yb8i sand-16mx7xq` }, l4 = cc, r2[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f4 = $(`sand-settings-scroll`, { className: `sand-9f619 sand-1iyjqo2 sand-s83m0k sand-dl72j9 sand-2lwn1j` }.className), r2[7] = f4) : f4 = r2[7], p4 = c2, m3 = `hover`, d3 = $(`sand-settings-pane`, u3.className), r2[0] = c2, r2[1] = l4, r2[2] = u3, r2[3] = d3, r2[4] = f4, r2[5] = p4, r2[6] = m3); - let h3; - r2[8] !== s3 || r2[9] !== u3.style || r2[10] !== d3 ? (h3 = (0, a2.jsx)(`div`, { className: d3, style: u3.style, children: s3 }), r2[8] = s3, r2[9] = u3.style, r2[10] = d3, r2[11] = h3) : h3 = r2[11]; - let g3; - return r2[12] !== l4 || r2[13] !== f4 || r2[14] !== p4 || r2[15] !== m3 || r2[16] !== h3 ? (g3 = (0, a2.jsx)(l4, { className: f4, ref: p4, scrollbarVisibility: m3, children: h3 }), r2[12] = l4, r2[13] = f4, r2[14] = p4, r2[15] = m3, r2[16] = h3, r2[17] = g3) : g3 = r2[17], g3; +function y3(e38) { + y3.d = 1310; + let t2 = (0, oe3.c)(94), { target: n2, onClose: r2 } = e38, { _: i3 } = fx(), c3 = v_2(), f4 = Yu3(), p4 = de4(), h4 = de4(), _5; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (_5 = {}, t2[0] = _5) : _5 = t2[0]; + let [v5, fe5] = (0, g4.useState)(_5), b2; + t2[1] !== v5 || t2[2] !== n2.card || t2[3] !== n2.kind ? (b2 = n2.kind === `edit` ? { ...ce4(n2.card), ...v5 } : v5, t2[1] = v5, t2[2] = n2.card, t2[3] = n2.kind, t2[4] = b2) : b2 = t2[4]; + let x2 = b2, S2 = (0, g4.useRef)(null), [C2, pe5] = (0, g4.useState)(null), w2; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (w2 = (e39, t3) => fe5((n3) => ({ ...n3, [e39]: t3 })), t2[5] = w2) : w2 = t2[5]; + let me5 = w2, T2; + t2[6] !== n2.items || t2[7] !== n2.kind ? (T2 = (e39) => e39.kind === `saved` && n2.kind === `edit` ? we3(n2.items).find((t3) => t3.id === e39.id) : void 0, t2[6] = n2.items, t2[7] = n2.kind, t2[8] = T2) : T2 = t2[8]; + let E2 = T2, D2; + t2[9] !== x2 || t2[10] !== E2 ? (D2 = function(e39) { + if (e39.kind === `none`) return ke3({}); + let t3 = E2(e39); + return ke3(t3 === void 0 ? x2 : De3(t3.contact)); + }, t2[9] = x2, t2[10] = E2, t2[11] = D2) : D2 = t2[11]; + let he5 = D2, O2; + t2[12] !== i3 || t2[13] !== x2 || t2[14] !== c3 ? (O2 = async function(e39) { + let { billing: t3, contact: n3 } = e39; + if (t3.kind === `saved`) return t3.id; + if (t3.kind !== `new` || !t3.savesContact) return ``; + let r3 = ke3(x2); + return r3.line1.length === 0 ? `` : (await c3.putContact({ id: ``, title: Ye2(n3.type, i3), contact: { ...r3, name: n3.name.trim(), phone: ``, email: `` } })).id; + }, t2[12] = i3, t2[13] = x2, t2[14] = c3, t2[15] = O2) : O2 = t2[15]; + let ge5 = O2, k2; + t2[16] === c3 ? k2 = t2[17] : (k2 = function(e39) { + let t3 = S2.current; + if (t3 !== null) return t3; + let n3 = c3.createCard({ values: e39 }).then((e40) => (pe5(e40.card ?? null), e40.id)); + return S2.current = n3, n3.catch(() => { + S2.current === n3 && (S2.current = null); + }), n3; + }, t2[16] = c3, t2[17] = k2); + let _e5 = k2, A2; + t2[18] !== i3 || t2[19] !== he5 || t2[20] !== _e5 || t2[21] !== x2 || t2[22] !== r2 || t2[23] !== ge5 || t2[24] !== n2.credential || t2[25] !== n2.kind || t2[26] !== c3 || t2[27] !== p4 ? (A2 = async function(e39) { + let t3 = Ne3(x2), a3 = S2.current !== null; + await p4.run(async () => { + let r3 = n2.kind === `edit` ? n2.credential.id : await _e5(t3), i4 = await ge5(e39); + (n2.kind !== `add` || a3 || i4.length !== 0) && await c3.updateCard({ id: r3, holderName: t3.cc_name ?? ``, nickname: t3.cc_nickname ?? ``, expiry: re2({ value: t3.cc_exp ?? `` }), billingAddress: he5(e39.billing), billingAddressId: i4 }); + }, i3({ id: `QqKsGg` })) && r2(); + }, t2[18] = i3, t2[19] = he5, t2[20] = _e5, t2[21] = x2, t2[22] = r2, t2[23] = ge5, t2[24] = n2.credential, t2[25] = n2.kind, t2[26] = c3, t2[27] = p4, t2[28] = A2) : A2 = t2[28]; + let j2 = A2; + if (n2.kind === `add`) { + let e39; + t2[29] === n2.initialFiles ? e39 = t2[30] : (e39 = n2.initialFiles ?? [], t2[29] = n2.initialFiles, t2[30] = e39); + let i4, a3; + t2[31] === C2 ? (i4 = t2[32], a3 = t2[33]) : (i4 = C2 === null ? { kind: `add` } : { kind: `edit`, brand: fe3(C2.brand), title: C2.brand, last4: C2.last4 }, a3 = C2 === null ? {} : { savedValues: ce4(C2) }, t2[31] = C2, t2[32] = i4, t2[33] = a3); + let o3; + t2[34] === j2 ? o3 = t2[35] : (o3 = (e40) => void j2(e40), t2[34] = j2, t2[35] = o3); + let s3 = p4.isSaving ? `submitting` : `ready`, c4; + return t2[36] !== x2 || t2[37] !== r2 || t2[38] !== i4 || t2[39] !== a3 || t2[40] !== o3 || t2[41] !== s3 || t2[42] !== e39 || t2[43] !== p4.error ? (c4 = (0, se3.jsx)(Yn2, { error: p4.error, fields: Rn2, initialFiles: e39, mode: i4, ...a3, onClose: r2, onSubmit: o3, onValueChange: me5, status: s3, values: x2 }), t2[36] = x2, t2[37] = r2, t2[38] = i4, t2[39] = a3, t2[40] = o3, t2[41] = s3, t2[42] = e39, t2[43] = p4.error, t2[44] = c4) : c4 = t2[44], c4; + } + let { card: M2, credential: N3, items: P3, title: F2, canEdit: I2 } = n2, L3; + t2[45] === M2.brand ? L3 = t2[46] : (L3 = fe3(M2.brand), t2[45] = M2.brand, t2[46] = L3); + let R3 = L3, z2 = M2.last4, B3; + t2[47] !== i3 || t2[48] !== z2 || t2[49] !== F2 ? (B3 = i3({ id: `+5aaQX`, values: { title: F2, last4: z2 } }), t2[47] = i3, t2[48] = z2, t2[49] = F2, t2[50] = B3) : B3 = t2[50]; + let V3 = B3, H3; + t2[51] !== i3 || t2[52] !== f4 || t2[53] !== N3 || t2[54] !== V3 || t2[55] !== r2 || t2[56] !== h4 || t2[57] !== c3 ? (H3 = async () => { + await f4(tO({ title: i3({ id: `DfnecK`, values: { name: V3 } }), description: i3({ id: `mtX2At` }), confirmLabel: i3({ id: `t/YqKh` }), cancelLabel: i3({ id: `dEgA5A` }) })) && await h4.run(() => c3.remove(N3.id), i3({ id: `eWGcnp` })) && r2(); + }, t2[51] = i3, t2[52] = f4, t2[53] = N3, t2[54] = V3, t2[55] = r2, t2[56] = h4, t2[57] = c3, t2[58] = H3) : H3 = t2[58]; + let U3 = H3, W3; + t2[59] === U3 ? W3 = t2[60] : (W3 = () => void U3(), t2[59] = U3, t2[60] = W3); + let G2; + t2[61] !== I2 || t2[62] !== M2 || t2[63] !== V3 || t2[64] !== h4.isSaving || t2[65] !== W3 ? (G2 = { card: M2, title: V3, canEdit: I2, isRemoving: h4.isSaving, onRemove: W3 }, t2[61] = I2, t2[62] = M2, t2[63] = V3, t2[64] = h4.isSaving, t2[65] = W3, t2[66] = G2) : G2 = t2[66]; + let K4 = p4.error ?? h4.error, q4; + t2[67] !== M2 || t2[68] !== P3 ? (q4 = le4(M2, P3), t2[67] = M2, t2[68] = P3, t2[69] = q4) : q4 = t2[69]; + let J4; + t2[70] !== R3 || t2[71] !== z2 || t2[72] !== F2 ? (J4 = { kind: `edit`, brand: R3, title: F2, last4: z2 }, t2[70] = R3, t2[71] = z2, t2[72] = F2, t2[73] = J4) : J4 = t2[73]; + let Y6; + t2[74] === M2 ? Y6 = t2[75] : (Y6 = ce4(M2), t2[74] = M2, t2[75] = Y6); + let X6; + t2[76] === p4 ? X6 = t2[77] : (X6 = () => { + fe5({}), p4.clearError(); + }, t2[76] = p4, t2[77] = X6); + let Z6; + t2[78] === j2 ? Z6 = t2[79] : (Z6 = (e39) => void j2(e39), t2[78] = j2, t2[79] = Z6); + let Q6; + t2[80] !== h4.isSaving || t2[81] !== p4.isSaving ? (Q6 = ue4(p4.isSaving, h4.isSaving), t2[80] = h4.isSaving, t2[81] = p4.isSaving, t2[82] = Q6) : Q6 = t2[82]; + let $5; + return t2[83] !== x2 || t2[84] !== r2 || t2[85] !== G2 || t2[86] !== K4 || t2[87] !== q4 || t2[88] !== J4 || t2[89] !== Y6 || t2[90] !== X6 || t2[91] !== Z6 || t2[92] !== Q6 ? ($5 = (0, se3.jsx)(Yn2, { detail: G2, error: K4, fields: Rn2, initialBilling: q4, mode: J4, onClose: r2, savedValues: Y6, onDiscardEdits: X6, onSubmit: Z6, onValueChange: me5, status: Q6, values: x2 }), t2[83] = x2, t2[84] = r2, t2[85] = G2, t2[86] = K4, t2[87] = q4, t2[88] = J4, t2[89] = Y6, t2[90] = X6, t2[91] = Z6, t2[92] = Q6, t2[93] = $5) : $5 = t2[93], $5; } // ../../../../../private/dist/renderer/assets/chunk-csv-parse-C5LpQq5n.js -function e8(e9, t2 = {}) { - let n2 = t2.delimiter ?? `,`, r2 = t2.maxRows ?? 1 / 0, i3 = [], a3 = ``, o3 = [], s3 = false, c2 = false, l4 = () => { +function e37(e38, t2 = {}) { + let n2 = t2.delimiter ?? `,`, r2 = t2.maxRows ?? 1 / 0, i3 = [], a3 = ``, o3 = [], s3 = false, c3 = false, l5 = () => { o3.push(a3), a3 = ``; }, u3 = () => { - l4(), i3.push(o3), o3 = [], c2 = false; + l5(), i3.push(o3), o3 = [], c3 = false; }; - for (let t3 = 0; t3 < e9.length && !(i3.length >= r2); t3 += 1) { - let r3 = e9[t3]; + for (let t3 = 0; t3 < e38.length && !(i3.length >= r2); t3 += 1) { + let r3 = e38[t3]; if (s3) { - r3 === `"` ? e9[t3 + 1] === `"` ? (a3 += `"`, t3 += 1) : s3 = false : a3 += r3; + r3 === `"` ? e38[t3 + 1] === `"` ? (a3 += `"`, t3 += 1) : s3 = false : a3 += r3; continue; } if (r3 === `"`) { - s3 = true, c2 = true; + s3 = true, c3 = true; continue; } if (r3 === n2) { - c2 = true, l4(); + c3 = true, l5(); continue; } if (r3 === ` @@ -5479,62 +13282,66 @@ function e8(e9, t2 = {}) { continue; } if (r3 === `\r`) { - e9[t3 + 1] === ` + e38[t3 + 1] === ` ` && (t3 += 1), u3(); continue; } - a3 += r3, c2 = true; + a3 += r3, c3 = true; } - return i3.length < r2 && (c2 || a3.length > 0 || o3.length > 0) && u3(), i3; + return i3.length < r2 && (c3 || a3.length > 0 || o3.length > 0) && u3(), i3; } -// ../../../../../private/dist/renderer/assets/chunk-view-Cwu5IFAB.js -var HTMLInputElement2 = globalThis.HTMLInputElement; -var HTMLSelectElement = globalThis.HTMLSelectElement; -var Y3 = u(sandVaultReact(), 1); -var X3 = UA(); -var ie3 = 200; -var Z3 = 512; -var ae3 = 2e3; -var oe4 = 10; -var se4 = 2048; -var ce4 = 4096; -var le3 = `http://sn`; -var ue3 = /^NoteType:Credit Card$/; -function de4(e9) { +// ../../../../../private/dist/renderer/assets/chunk-view-CuYU9NOh.js +var oe4 = new URL(`amex-BY11FWZr.svg`, import.meta.url).href; +var se4 = `data:image/svg+xml,%3csvg%20width='20'%20height='5'%20viewBox='0%20-9.3034%20220.5673%2055.1418'%20xmlns='http://www.w3.org/2000/svg'%3e%3cdefs%3e%3cclipPath%20id='clipPath18'%20clipPathUnits='userSpaceOnUse'%3e%3cpath%20d='m%200,0%201766.57,0%200,479%20L%200,479%200,0%20Z'%20/%3e%3c/clipPath%3e%3clinearGradient%20id='discover-o'%20x1='0'%20y1='1'%20x2='1'%20y2='0'%3e%3cstop%20offset='0.15'%20stop-color='%23b12c21'/%3e%3cstop%20offset='0.31'%20stop-color='%23e0461e'/%3e%3cstop%20offset='0.5'%20stop-color='%23e9581b'/%3e%3cstop%20offset='0.69'%20stop-color='%23f27e15'/%3e%3cstop%20offset='0.85'%20stop-color='%23f59014'/%3e%3c/linearGradient%3e%3c/defs%3e%3cg%20transform='matrix(1.25,0,0,-1.25,-0.25390625,59.383859)'%3e%3cg%20transform='scale(0.1,0.1)'%3e%3cg%3e%3cg%20clip-path='url(%23clipPath18)'%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='M%20145.605,261.297%20C%20128.492,245.844%20106.262,239.102%2071.0703,239.102%20l%20-14.6172,0%200,184.644%2014.6172,0%20c%2035.1917,0%2056.5467,-6.297%2074.5347,-22.582%2018.836,-16.773%2030.168,-42.762%2030.168,-69.512%200,-26.804%20-11.332,-53.589%20-30.168,-70.355%20z%20m%20-63.6245,209.758%20-79.94925,0%200,-279.223%2079.52735,0%20c%2042.2894,0%2072.8244,9.977%2099.6294,32.234%2031.851,26.36%2050.687,66.09%2050.687,107.184%200,82.402%20-61.566,139.805%20-149.8945,139.805'%20/%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='m%20256.938,191.832%2054.4648,0%200,279.223%20-54.4648,0%200,-279.223%20z'%20/%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='m%20444.578,363.906%20c%20-32.683,12.094%20-42.281,20.071%20-42.281,35.157%200,17.585%2017.098,30.949%2040.574,30.949%2016.32,0%2029.731,-6.703%2043.922,-22.614%20l%2028.496,37.317%20c%20-23.418,20.484%20-51.437,30.957%20-82.051,30.957%20-49.402,0%20-87.086,-34.309%20-87.086,-80.008%200,-38.469%2017.547,-58.164%2068.7,-76.574%2021.32,-7.52%2032.171,-12.531%2037.648,-15.902%2010.883,-7.106%2016.332,-17.165%2016.332,-28.891%200,-22.625%20-17.988,-39.387%20-42.289,-39.387%20-25.977,0%20-46.902,12.992%20-59.441,37.242%20l%20-35.188,-33.879%20c%2025.094,-36.835%2055.231,-53.16%2096.672,-53.16%2056.602,0%2096.305,37.633%2096.305,91.688%200,44.363%20-18.356,64.445%20-80.313,87.105'%20/%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='m%20542.074,331.25%20c%200,-82.074%2064.446,-145.715%20147.383,-145.715%2023.445,0%2043.523,4.61%2068.285,16.274%20l%200,64.113%20c%20-21.773,-21.793%20-41.058,-30.582%20-65.754,-30.582%20-54.851,0%20-93.785,39.769%20-93.785,96.312%200,53.61%2040.164,95.899%2091.254,95.899%2025.977,0%2045.641,-9.27%2068.285,-31.418%20l%200,64.082%20c%20-23.906,12.129%20-43.566,17.152%20-67,17.152%20-82.515,0%20-148.668,-64.929%20-148.668,-146.117'%20/%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='m%201189.59,283.5%20-74.46,187.555%20-59.5,0%20118.49,-286.387%2029.31,0%20120.63,286.387%20-59.04,0%20-75.43,-187.555'%20/%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='m%201348.69,191.832%20154.46,0%200,47.27%20-100.04,0%200,75.371%2096.35,0%200,47.297%20-96.35,0%200,61.976%20100.04,0%200,47.309%20-154.46,0%200,-279.223'%20/%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='m%201609.53,342.504%20-15.91,0%200,84.57%2016.77,0%20c%2033.92,0%2052.36,-14.211%2052.36,-41.386%200,-28.071%20-18.44,-43.184%20-53.22,-43.184%20z%20m%20109.27,46.117%20c%200,52.274%20-36.01,82.434%20-98.82,82.434%20l%20-80.76,0%200,-279.223%2054.4,0%200,112.168%207.1,0%2075.39,-112.168%2066.98,0%20-87.9,117.633%20c%2041.02,8.34%2063.61,36.402%2063.61,79.156'%20/%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='m%201743.24,457.211%20-0.99,0%200,6.414%201.05,0%20c%202.9,0%204.4,-1.043%204.4,-3.156%200,-2.172%20-1.52,-3.258%20-4.46,-3.258%20z%20m%2010.32,3.348%20c%200,4.894%20-3.37,7.57%20-9.29,7.57%20l%20-7.88,0%200,-24.543%205.86,0%200,9.519%206.87,-9.519%207.15,0%20-8.07,10.121%20c%203.45,0.93%205.36,3.445%205.36,6.852'%20/%3e%3cpath%20style='fill:%23201d1c;fill-opacity:1;fill-rule:nonzero;stroke:none'%20d='m%201745.37,438.332%20c%20-9.38,0%20-17.05,7.805%20-17.05,17.543%200,9.773%207.57,17.574%2017.05,17.574%209.33,0%2016.94,-7.98%2016.94,-17.574%200,-9.656%20-7.61,-17.543%20-16.94,-17.543%20z%20m%200.08,38.969%20c%20-11.92,0%20-21.38,-9.512%20-21.38,-21.395%200,-11.875%209.57,-21.398%2021.38,-21.398%2011.61,0%2021.12,9.625%2021.12,21.398%200,11.715%20-9.51,21.395%20-21.12,21.395'%20/%3e%3c/g%3e%3c/g%3e%3ccircle%20cx='924.076'%20cy='330.512'%20r='148.545'%20fill='url(%23discover-o)'%20/%3e%3c/g%3e%3c/g%3e%3c/svg%3e`; +var ce5 = `data:image/svg+xml,%3csvg%20width='16'%20height='11'%20viewBox='-0.0159%20-0.5521%2016%2011'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Logo/Mastercard'%3e%3cpath%20id='Vector'%20d='M4.91824%200C3.611%200.00424234%202.35886%200.528507%201.43674%201.45769C0.514619%202.38687%20-0.00210883%203.64502%206.46892e-06%204.9559C0.00212176%206.26678%200.522907%207.52324%201.44802%208.44942C2.37313%209.37561%203.62696%209.89581%204.93421%209.89581C6.24146%209.89581%207.49529%209.37561%208.4204%208.44942C9.34551%207.52324%209.8663%206.26678%209.86841%204.9559C9.87053%203.64502%209.3538%202.38687%208.43168%201.45769C7.50956%200.528507%206.25742%200.00424234%204.95018%200L4.91824%200Z'%20fill='%23EB001B'/%3e%3cpath%20id='Vector_2'%20d='M11.0181%200C9.7109%200.00424234%208.45876%200.528507%207.53664%201.45769C6.61452%202.38687%206.09779%203.64502%206.0999%204.9559C6.10202%206.26678%206.6228%207.52324%207.54792%208.44942C8.47303%209.37561%209.72686%209.89581%2011.0341%209.89581C12.3414%209.89581%2013.5952%209.37561%2014.5203%208.44942C15.4454%207.52324%2015.9662%206.26678%2015.9683%204.9559C15.9704%203.64502%2015.4537%202.38687%2014.5316%201.45769C13.6095%200.528507%2012.3573%200.00424234%2011.0501%200L11.0181%200Z'%20fill='%23F79E1B'/%3e%3cpath%20id='Vector_3'%20d='M7.98415%201.05684C7.39638%201.5198%206.92117%202.11061%206.5944%202.78467C6.26763%203.45874%206.09784%204.19843%206.09784%204.94792C6.09784%205.6974%206.26763%206.4371%206.5944%207.11116C6.92117%207.78522%207.39638%208.37603%207.98415%208.839C8.57192%208.37603%209.04713%207.78522%209.3739%207.11116C9.70067%206.4371%209.87046%205.6974%209.87046%204.94792C9.87046%204.19843%209.70067%203.45874%209.3739%202.78467C9.04713%202.11061%208.57192%201.5198%207.98415%201.05684Z'%20fill='%23FF5F00'/%3e%3c/g%3e%3c/svg%3e`; +var le5 = `data:image/svg+xml,%3csvg%20width='18'%20height='7'%20viewBox='-0.064%20-1.3091%2040.128%2015.6054'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Logo/Visa%20(white)'%3e%3cpath%20id='Vector'%20d='M26.0476%200.02C23.2104%200.02%2020.6748%201.4908%2020.6748%204.2076C20.6748%207.3236%2025.1716%207.5388%2025.1716%209.1044C25.1716%209.7636%2024.4164%2010.3536%2023.126%2010.3536C21.2952%2010.3536%2019.9268%209.5292%2019.9268%209.5292L19.3412%2012.2712C19.3412%2012.2712%2020.9176%2012.9676%2023.0104%2012.9676C26.1124%2012.9676%2028.5536%2011.4248%2028.5536%208.6612C28.5536%205.3684%2024.038%205.1596%2024.038%203.7068C24.038%203.1904%2024.658%202.6248%2025.9444%202.6248C27.396%202.6248%2028.58%203.2244%2028.58%203.2244L29.1532%200.5764C29.1532%200.5764%2027.8644%200.02%2026.0472%200.02H26.0476ZM0.0888%200.22L0.02%200.6196C0.02%200.6196%201.2136%200.838%202.2888%201.274C3.6732%201.7736%203.7716%202.0648%204.0048%202.968L6.5452%2012.7612H9.9508L15.1972%200.22H11.7996L8.4284%208.7468L7.0528%201.5188C6.9268%200.6916%206.2876%200.2196%205.5056%200.2196H0.0892L0.0888%200.22ZM16.5636%200.22L13.8984%2012.7612H17.1384L19.794%200.22H16.5636ZM34.634%200.22C33.8528%200.22%2033.4388%200.6384%2033.1352%201.3692L28.3884%2012.7612H31.786L32.4432%2010.8624H36.5824L36.982%2012.7612H39.98L37.3648%200.22H34.634ZM35.076%203.6084L36.0832%208.3144H33.3852L35.0764%203.6084H35.076Z'%20fill='white'/%3e%3c/g%3e%3c/svg%3e`; +var ue5 = { amex: oe4, visa: `data:image/svg+xml,%3csvg%20width='18'%20height='7'%20viewBox='-0.0287%20-0.5791%2018%207'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='Logo/Visa'%3e%3cpath%20id='Vector'%20d='M11.684%200.00899621C10.4114%200.00899621%209.27398%200.670578%209.27398%201.89262C9.27398%203.29423%2011.2911%203.39103%2011.2911%204.09526C11.2911%204.39177%2010.9523%204.65716%2010.3735%204.65716C9.55227%204.65716%208.93845%204.28634%208.93845%204.28634L8.67578%205.51972C8.67578%205.51972%209.38289%205.83296%2010.3216%205.83296C11.7131%205.83296%2012.8081%205.139%2012.8081%203.8959C12.8081%202.41476%2010.7826%202.32084%2010.7826%201.66736C10.7826%201.43508%2011.0607%201.18066%2011.6377%201.18066C12.2889%201.18066%2012.82%201.45037%2012.82%201.45037L13.0771%200.259271C13.0771%200.259271%2012.499%200.00899621%2011.6838%200.00899621H11.684ZM0.0398325%200.0989583L0.00897129%200.278703C0.00897129%200.278703%200.544378%200.376941%201.02667%200.573059C1.64767%200.797784%201.69181%200.928769%201.79641%201.33504L2.93594%205.74012H4.46358L6.81692%200.0989583H5.29288L3.78068%203.9344L3.16364%200.683172C3.10712%200.311089%202.82039%200.0987784%202.46962%200.0987784H0.040012L0.0398325%200.0989583ZM7.42984%200.0989583L6.23433%205.74012H7.68768L8.87889%200.0989583H7.42984ZM15.5356%200.0989583C15.1852%200.0989583%2014.9995%200.287159%2014.8633%200.615881L12.734%205.74012H14.2581L14.5529%204.88602H16.4096L16.5888%205.74012H17.9336L16.7605%200.0989583H15.5356ZM15.7338%201.6231L16.1856%203.73991H14.9754L15.734%201.6231H15.7338Z'%20fill='%231434CB'/%3e%3c/g%3e%3c/svg%3e`, mastercard: ce5, discover: se4 }; +var de5 = { amex: oe4, visa: le5, mastercard: ce5, discover: se4 }; +var Y5 = u(sandVaultReact(), 1); +var X5 = Ij(); +var fe4 = 200; +var pe4 = 512; +var me4 = 2e3; +var he4 = 10; +var ge4 = 2048; +var _e4 = 4096; +var ve4 = `http://sn`; +var ye4 = /^NoteType:Credit Card$/; +function be4(e38) { let t2 = /* @__PURE__ */ new Map(); - return e9.forEach((e10, n2) => { - let r2 = e10.trim().toLowerCase(); + return e38.forEach((e39, n2) => { + let r2 = e39.trim().toLowerCase(); t2.has(r2) || t2.set(r2, n2); - }), { get: (e10, ...n2) => { + }), { get: (e39, ...n2) => { for (let r2 of n2) { let n3 = t2.get(r2); - if (n3 !== void 0) return e10[n3] ?? ``; + if (n3 !== void 0) return e39[n3] ?? ``; } return ``; - }, has: (...e10) => e10.every((e11) => t2.has(e11)) }; -} -function fe4(e9) { - if (e9.has(`login_uri`, `login_username`, `login_password`)) return `bitwarden`; - if (e9.has(`url`, `username`, `password`, `extra`, `name`, `grouping`)) return `lastpass`; - if (e9.has(`url`, `username`, `password`) && (e9.has(`httprealm`) || e9.has(`formactionorigin`) || e9.has(`guid`))) return `firefox`; - if (e9.has(`title`, `url`, `username`, `password`)) { - let t2 = e9.has(`favorite`) || e9.has(`archived`) || e9.has(`tags`), n2 = e9.has(`notes`) && !e9.has(`otpauth`); + }, has: (...e39) => e39.every((e40) => t2.has(e40)) }; +} +function xe4(e38) { + if (e38.has(`login_uri`, `login_username`, `login_password`)) return `bitwarden`; + if (e38.has(`url`, `username`, `password`, `extra`, `name`, `grouping`)) return `lastpass`; + if (e38.has(`url`, `username`, `password`) && (e38.has(`httprealm`) || e38.has(`formactionorigin`) || e38.has(`guid`))) return `firefox`; + if (e38.has(`title`, `url`, `username`, `password`)) { + let t2 = e38.has(`favorite`) || e38.has(`archived`) || e38.has(`tags`), n2 = e38.has(`notes`) && !e38.has(`otpauth`); return t2 || n2 ? `1password` : `safari`; } - return e9.has(`name`, `url`, `username`, `password`) ? `chrome` : null; + return e38.has(`name`, `url`, `username`, `password`) ? `chrome` : null; } -function pe4(e9, t2 = /\s+/) { - return e9.split(t2).map((e10) => e10.trim()).filter((e10) => e10.length > 0); +function Se4(e38, t2 = /\s+/) { + return e38.split(t2).map((e39) => e39.trim()).filter((e39) => e39.length > 0); } -function me4(e9) { - let t2 = /* @__PURE__ */ new Map(), n2 = e9.split(/\r?\n/); - for (let [e10, r2] of n2.entries()) { +function Ce4(e38) { + let t2 = /* @__PURE__ */ new Map(), n2 = e38.split(/\r?\n/); + for (let [e39, r2] of n2.entries()) { let i3 = r2.indexOf(`:`); if (i3 <= 0) continue; let a3 = r2.slice(0, i3).trim(); if (a3 === `Notes`) { - t2.set(a3, [r2.slice(i3 + 1), ...n2.slice(e10 + 1)].join(` + t2.set(a3, [r2.slice(i3 + 1), ...n2.slice(e39 + 1)].join(` `)); break; } @@ -5542,1129 +13349,1477 @@ function me4(e9) { } return t2; } -function he4(e9, t2) { - let n2 = t2.get(e9, `url`).trim(), r2 = t2.get(e9, `extra`), i3 = t2.get(e9, `name`).trim(); - if (n2 !== le3) return { kind: `login`, login: { title: i3, username: t2.get(e9, `username`), password: t2.get(e9, `password`), notes: r2, sites: pe4(n2) } }; - if (!ue3.test(r2.split(/\r?\n/)[0]?.trim() ?? ``)) return { kind: `other`, title: i3 }; - let a3 = me4(r2); +function we4(e38, t2) { + let n2 = t2.get(e38, `url`).trim(), r2 = t2.get(e38, `extra`), i3 = t2.get(e38, `name`).trim(); + if (n2 !== ve4) return { kind: `login`, login: { title: i3, username: t2.get(e38, `username`), password: t2.get(e38, `password`), notes: r2, sites: Se4(n2) } }; + if (!ye4.test(r2.split(/\r?\n/)[0]?.trim() ?? ``)) return { kind: `other`, title: i3 }; + let a3 = Ce4(r2); return { kind: `card`, card: { title: i3, brand: a3.get(`Type`) ?? ``, number: a3.get(`Number`) ?? ``, expiry: a3.get(`Expiration Date`) ?? ``, csc: a3.get(`Security Code`) ?? ``, holderName: a3.get(`Name on Card`) ?? `` } }; } -function ge3(e9, t2, n2) { - let r2 = (...e10) => n2.get(t2, ...e10); - switch (e9) { +function Te4(e38, t2, n2) { + let r2 = (...e39) => n2.get(t2, ...e39); + switch (e38) { case `bitwarden`: { - let e10 = r2(`type`).trim().toLowerCase(); - return e10 !== `` && e10 !== `login` ? { kind: `other`, title: r2(`name`).trim() } : { kind: `login`, login: { title: r2(`name`).trim(), username: r2(`login_username`), password: r2(`login_password`), notes: r2(`notes`), sites: pe4(r2(`login_uri`), /[\s,]+/) } }; + let e39 = r2(`type`).trim().toLowerCase(); + return e39 !== `` && e39 !== `login` ? { kind: `other`, title: r2(`name`).trim() } : { kind: `login`, login: { title: r2(`name`).trim(), username: r2(`login_username`), password: r2(`login_password`), notes: r2(`notes`), sites: Se4(r2(`login_uri`), /[\s,]+/) } }; } case `lastpass`: - return he4(t2, n2); + return we4(t2, n2); case `firefox`: - return r2(`url`).startsWith(`chrome://`) ? { kind: `other`, title: r2(`url`) } : { kind: `login`, login: { title: ``, username: r2(`username`), password: r2(`password`), notes: ``, sites: pe4(r2(`url`)) } }; + return r2(`url`).startsWith(`chrome://`) ? { kind: `other`, title: r2(`url`) } : { kind: `login`, login: { title: ``, username: r2(`username`), password: r2(`password`), notes: ``, sites: Se4(r2(`url`)) } }; case `chrome`: - return { kind: `login`, login: { title: r2(`name`).trim(), username: r2(`username`), password: r2(`password`), notes: r2(`note`, `notes`), sites: pe4(r2(`url`)) } }; + return { kind: `login`, login: { title: r2(`name`).trim(), username: r2(`username`), password: r2(`password`), notes: r2(`note`, `notes`), sites: Se4(r2(`url`)) } }; case `1password`: case `safari`: - return { kind: `login`, login: { title: r2(`title`).trim(), username: r2(`username`), password: r2(`password`), notes: r2(`notes`), sites: pe4(r2(`url`)) } }; + return { kind: `login`, login: { title: r2(`title`).trim(), username: r2(`username`), password: r2(`password`), notes: r2(`notes`), sites: Se4(r2(`url`)) } }; default: - return e9; + return e38; } } -function _e3(e9) { - let t2 = e9.includes(`://`) ? e9 : `https://${e9}`, n2 = URL.parse(t2); - return n2 === null || n2.hostname.length === 0 ? `invalid-website` : n2.protocol === `http:` ? `insecure-website` : n2.protocol === `https:` ? t2.length > se4 ? `too-long` : { site: t2, host: ve3(n2.hostname) } : `invalid-website`; +function Ee4(e38) { + let t2 = e38.includes(`://`) ? e38 : `https://${e38}`, n2 = URL.parse(t2); + return n2 === null || n2.hostname.length === 0 ? `invalid-website` : n2.protocol === `http:` ? `insecure-website` : n2.protocol === `https:` ? t2.length > ge4 ? `too-long` : { site: t2, host: De4(n2.hostname) } : `invalid-website`; } -function ve3(e9) { - return e9.toLowerCase().replace(/^www\./, ``); +function De4(e38) { + return e38.toLowerCase().replace(/^www\./, ``); } -function ye3(e9) { - let t2 = URL.parse(e9.includes(`://`) ? e9 : `https://${e9}`)?.hostname; - return t2 === void 0 || t2.length === 0 ? null : ve3(t2); +function Oe4(e38) { + let t2 = URL.parse(e38.includes(`://`) ? e38 : `https://${e38}`)?.hostname; + return t2 === void 0 || t2.length === 0 ? null : De4(t2); } -function be3({ host: e9, username: t2 }) { - return `${e9} +function ke4({ host: e38, username: t2 }) { + return `${e38} ${t2.trim().toLowerCase()}`; } -function xe3({ last4: e9, month: t2, year: n2 }) { - return `${e9} +function Ae4({ last4: e38, month: t2, year: n2 }) { + return `${e38} ${t2} ${n2}`; } -function Se3(e9) { - let t2 = /^([a-z][a-z0-9+.-]*):\/\//i.exec(e9)?.[1]; +function je4(e38) { + let t2 = /^([a-z][a-z0-9+.-]*):\/\//i.exec(e38)?.[1]; return t2 !== void 0 && !/^https?$/i.test(t2); } -var Ce3 = [`january`, `february`, `march`, `april`, `may`, `june`, `july`, `august`, `september`, `october`, `november`, `december`]; -function we3(e9) { - let t2 = e9.trim().toLowerCase(); +var Me4 = [`january`, `february`, `march`, `april`, `may`, `june`, `july`, `august`, `september`, `october`, `november`, `december`]; +function Ne4(e38) { + let t2 = e38.trim().toLowerCase(); if (/^\d{1,2}$/.test(t2)) { - let e10 = Number(t2); - return e10 >= 1 && e10 <= 12 ? e10 : null; + let e39 = Number(t2); + return e39 >= 1 && e39 <= 12 ? e39 : null; } if (t2.length < 3) return null; - let n2 = Ce3.findIndex((e10) => e10.startsWith(t2)); + let n2 = Me4.findIndex((e39) => e39.startsWith(t2)); return n2 === -1 ? null : n2 + 1; } -function Te2(e9) { - let t2 = e9.trim(); +function Pe4(e38) { + let t2 = e38.trim(); return /^\d{2}$/.test(t2) ? 2e3 + Number(t2) : /^\d{4}$/.test(t2) ? Number(t2) : null; } -function Ee3(e9) { - let t2 = e9.trim(), n2 = /^(\d{4})-(\d{1,2})$/.exec(t2), r2 = n2 === null ? t2.split(/\s*[,/\-\s]\s*/) : [n2[2], n2[1]]; +function Fe3(e38) { + let t2 = e38.trim(), n2 = /^(\d{4})-(\d{1,2})$/.exec(t2), r2 = n2 === null ? t2.split(/\s*[,/\-\s]\s*/) : [n2[2], n2[1]]; if (r2.length !== 2) return null; - let i3 = we3(r2[0] ?? ``), a3 = Te2(r2[1] ?? ``); + let i3 = Ne4(r2[0] ?? ``), a3 = Pe4(r2[1] ?? ``); return i3 === null || a3 === null ? null : { month: i3, year: a3 }; } -function De3(e9) { - return `${String(e9.month).padStart(2, `0`)}/${String(e9.year % 100).padStart(2, `0`)}`; -} -function Oe3(e9) { - return e9.title.length > ie3 || e9.username.trim().length > Z3 || e9.notes.trim().length > ae3 || e9.sites.length > oe4 || new TextEncoder().encode(e9.password).length > ce4; -} -function ke3(e9, t2, n2) { - let r2 = { ...t2, sites: t2.sites.filter((e10) => !Se3(e10)) }, i3 = r2.sites.map(_e3), a3 = i3.find((e10) => typeof e10 != `string`)?.host, o3 = r2.title.length > 0 ? r2.title : a3 ?? ``, s3 = r2.username.trim(), c2 = (n3) => ({ row: e9, kind: `login`, primary: o3.length > 0 ? o3 : t2.sites[0] ?? ``, secondary: s3, status: n3 }), l4 = (e10) => ({ preview: c2({ kind: `invalid`, problem: e10 }), item: null }); - if (t2.sites.length === 0) return l4(`missing-website`); - if (r2.sites.length === 0) return l4(`invalid-website`); - let u3 = i3.find((e10) => typeof e10 == `string`); - if (u3 !== void 0) return l4(u3); - if (r2.password.length === 0) return l4(`missing-password`); - if (Oe3({ ...r2, title: o3 })) return l4(`too-long`); - let d3 = i3.flatMap((e10) => typeof e10 == `string` ? [] : [e10]), f4 = d3.map(({ host: e10 }) => be3({ host: e10, username: s3 })); - if (f4.some((e10) => n2.loginKeys.has(e10))) return { preview: c2({ kind: `duplicate` }), item: null }; - for (let e10 of f4) n2.loginKeys.add(e10); - return { preview: c2({ kind: `ready` }), item: { kind: `login`, login: { id: ``, title: o3, username: s3, notes: r2.notes.replace(/\r\n?/g, ` -`).trim(), sites: d3.map(({ site: e10 }) => e10), password: r2.password } } }; -} -function Ae3(e9, t2, n2) { - let r2 = t2.number.replace(/[\s-]/g, ``), i3 = r2.slice(-4), a3 = t2.brand.trim(), o3 = Ee3(t2.expiry), s3 = t2.holderName.trim(), c2 = (n3) => ({ row: e9, kind: `card`, primary: i3.length === 4 ? `${a3} \u2022\u2022\u2022\u2022 ${i3}`.trim() : t2.title, secondary: [s3, o3 === null ? `` : De3(o3)].filter((e10) => e10.length > 0).join(` \xB7 `), status: n3 }), l4 = (e10) => ({ preview: c2({ kind: `invalid`, problem: e10 }), item: null }); - if (!n2.cardsEnabled) return { preview: c2({ kind: `skipped`, reason: `cards-off` }), item: null }; - if (!re3(r2)) return l4(`invalid-card-number`); - if (o3 === null) return l4(`invalid-expiry`); +function Ie4(e38) { + return `${String(e38.month).padStart(2, `0`)}/${String(e38.year % 100).padStart(2, `0`)}`; +} +function Le4(e38) { + return e38.title.length > fe4 || e38.username.trim().length > pe4 || e38.notes.trim().length > me4 || e38.sites.length > he4 || new TextEncoder().encode(e38.password).length > _e4; +} +function Re4(e38, t2, n2) { + let r2 = { ...t2, sites: t2.sites.filter((e39) => !je4(e39)) }, i3 = r2.sites.map(Ee4), a3 = i3.find((e39) => typeof e39 != `string`)?.host, o3 = r2.title.length > 0 ? r2.title : a3 ?? ``, s3 = r2.username.trim(), c3 = (n3) => ({ row: e38, kind: `login`, primary: o3.length > 0 ? o3 : t2.sites[0] ?? ``, secondary: s3, status: n3 }), l5 = (e39) => ({ preview: c3({ kind: `invalid`, problem: e39 }), item: null }); + if (t2.sites.length === 0) return l5(`missing-website`); + if (r2.sites.length === 0) return l5(`invalid-website`); + let u3 = i3.find((e39) => typeof e39 == `string`); + if (u3 !== void 0) return l5(u3); + if (r2.password.length === 0) return l5(`missing-password`); + if (Le4({ ...r2, title: o3 })) return l5(`too-long`); + let d3 = i3.flatMap((e39) => typeof e39 == `string` ? [] : [e39]), f4 = d3.map(({ host: e39 }) => ke4({ host: e39, username: s3 })); + if (f4.some((e39) => n2.loginKeys.has(e39))) return { preview: c3({ kind: `duplicate` }), item: null }; + for (let e39 of f4) n2.loginKeys.add(e39); + return { preview: c3({ kind: `ready` }), item: { kind: `login`, login: { id: ``, title: o3, username: s3, notes: r2.notes.replace(/\r\n?/g, ` +`).trim(), sites: d3.map(({ site: e39 }) => e39), password: r2.password } } }; +} +function ze4(e38, t2, n2) { + let r2 = t2.number.replace(/[\s-]/g, ``), i3 = r2.slice(-4), a3 = t2.brand.trim(), o3 = Fe3(t2.expiry), s3 = t2.holderName.trim(), c3 = (n3) => ({ row: e38, kind: `card`, primary: i3.length === 4 ? `${a3} \u2022\u2022\u2022\u2022 ${i3}`.trim() : t2.title, secondary: [s3, o3 === null ? `` : Ie4(o3)].filter((e39) => e39.length > 0).join(` \xB7 `), status: n3 }), l5 = (e39) => ({ preview: c3({ kind: `invalid`, problem: e39 }), item: null }); + if (!n2.cardsEnabled) return { preview: c3({ kind: `skipped`, reason: `cards-off` }), item: null }; + if (!Y4(r2)) return l5(`invalid-card-number`); + if (o3 === null) return l5(`invalid-expiry`); let u3 = n2.now.getFullYear() * 12 + n2.now.getMonth(); - if (o3.year * 12 + o3.month - 1 < u3) return l4(`expired-card`); + if (o3.year * 12 + o3.month - 1 < u3) return l5(`expired-card`); let d3 = t2.csc.trim(); - if (d3.length > 0 && !/^\d{3,4}$/.test(d3)) return l4(`invalid-security-code`); - if (s3.length > ie3) return l4(`too-long`); - let f4 = xe3({ last4: i3, month: o3.month, year: o3.year }); - if (n2.cardKeys.has(f4)) return { preview: c2({ kind: `duplicate` }), item: null }; + if (d3.length > 0 && !/^\d{3,4}$/.test(d3)) return l5(`invalid-security-code`); + if (s3.length > fe4) return l5(`too-long`); + let f4 = Ae4({ last4: i3, month: o3.month, year: o3.year }); + if (n2.cardKeys.has(f4)) return { preview: c3({ kind: `duplicate` }), item: null }; n2.cardKeys.add(f4); - let p4 = { cc_number: r2, cc_exp: De3(o3) }; - return d3.length > 0 && (p4.cc_csc = d3), s3.length > 0 && (p4.cc_name = s3), { preview: c2({ kind: `ready` }), item: { kind: `card`, card: { values: p4 } } }; + let p4 = { cc_number: r2, cc_exp: Ie4(o3) }; + return d3.length > 0 && (p4.cc_csc = d3), s3.length > 0 && (p4.cc_name = s3), { preview: c3({ kind: `ready` }), item: { kind: `card`, card: { values: p4 } } }; } -function je3(e9) { +function Be4(e38) { let t2 = /* @__PURE__ */ new Set(), n2 = /* @__PURE__ */ new Set(); - for (let r2 of e9) { + for (let r2 of e38) { if (r2.card !== void 0) { - let { last4: e10, expMonth: t3, expYear: i3 } = r2.card; - n2.add(xe3({ last4: e10, month: t3, year: i3 < 100 ? 2e3 + i3 : i3 })); + let { last4: e39, expMonth: t3, expYear: i3 } = r2.card; + n2.add(Ae4({ last4: e39, month: t3, year: i3 < 100 ? 2e3 + i3 : i3 })); continue; } - for (let e10 of r2.sites) { - let n3 = ye3(e10); - n3 !== null && t2.add(be3({ host: n3, username: r2.username })); + for (let e39 of r2.sites) { + let n3 = Oe4(e39); + n3 !== null && t2.add(ke4({ host: n3, username: r2.username })); } } return { loginKeys: t2, cardKeys: n2 }; } -function Me2({ text: e9, existing: t2, cardsEnabled: n2, now: r2 }) { - let [i3, ...a3] = e8(e9.replace(/^\uFEFF/, ``)); +function Ve4({ text: e38, existing: t2, cardsEnabled: n2, now: r2 }) { + let [i3, ...a3] = e37(e38.replace(/^\uFEFF/, ``)); if (i3 === void 0) return { kind: `unrecognized` }; - let o3 = de4(i3), s3 = fe4(o3); + let o3 = be4(i3), s3 = xe4(o3); if (s3 === null) return { kind: `unrecognized` }; - let c2 = { cardsEnabled: n2, now: r2, ...je3(t2) }, l4 = []; - for (let [e10, t3] of a3.entries()) { - if (t3.every((e11) => e11.trim().length === 0)) continue; - let n3 = e10 + 1, r3 = ge3(s3, t3, o3); + let c3 = { cardsEnabled: n2, now: r2, ...Be4(t2) }, l5 = []; + for (let [e39, t3] of a3.entries()) { + if (t3.every((e40) => e40.trim().length === 0)) continue; + let n3 = e39 + 1, r3 = Te4(s3, t3, o3); switch (r3.kind) { case `login`: - l4.push(ke3(n3, r3.login, c2)); + l5.push(Re4(n3, r3.login, c3)); break; case `card`: - l4.push(Ae3(n3, r3.card, c2)); + l5.push(ze4(n3, r3.card, c3)); break; case `other`: - l4.push({ preview: { row: n3, kind: `other`, primary: r3.title, secondary: ``, status: { kind: `skipped`, reason: `unsupported-item` } }, item: null }); + l5.push({ preview: { row: n3, kind: `other`, primary: r3.title, secondary: ``, status: { kind: `skipped`, reason: `unsupported-item` } }, item: null }); break; default: return r3; } } - return { kind: `parsed`, format: s3, rows: l4 }; -} -var Q2 = Ke(); -var Ne2 = { kzqmXN: `sand-5lhr3w`, $$css: true }; -var Pe2 = { count: { k8WAf4: `sand-j8oexa`, kg3NbH: `sand-dqyycr`, kaIpWk: `sand-1i4c3av`, kWkggS: `sand-105pnba`, kMwMTN: `sand-1o0liin`, $$css: true }, row: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-1dbef6d`, k8WAf4: `sand-1lqmthn`, kg3NbH: `sand-w3enoh`, kEafiO: `sand-1hc762m sand-1g31smg`, kPef9Z: `sand-13fuv20`, kLZC3w: `sand-13nz628`, kMwMTN: `sand-tyxrsu`, $$css: true }, ellipsis: { kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, khDVqt: `sand-uxw1ft`, $$css: true }, secondary: { kMwMTN: `sand-1o0liin`, $$css: true }, status: { kmuXW: `sand-2lah0s`, ks0D6T: `sand-1y8h3ww`, k9WMMc: `sand-p4054r`, kMwMTN: `sand-169k319`, $$css: true }, fill: { kZKoxP: `sand-5yr21d`, kaIpWk: `sand-1i4c3av`, kWkggS: `sand-8rotk8`, k1ekBW: `sand-xrbq2n`, kIyJzY: `sand-1firant`, $$css: true } }; -var Fe3 = { value: (e9) => [Ne2, { "--x-width": ((e10) => typeof e10 == `number` ? e10 + `px` : e10 ?? void 0)(`${e9}%`) }] }; -var Ie3 = { className: `sand-78zum5 sand-dt5ytf sand-q3t0pi sand-1ghz6dp sand-1717udv sand-1odjw0f sand-e8uvvx sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1qmwy7c` }; -var Le3 = `\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022`; -var Re3 = { "1password": { id: `i2K63W` }, chrome: { id: `7K3Gyf` }, safari: { id: `w3F/28` }, firefox: { id: `htpCxn` }, bitwarden: { id: `M8XZOv` }, lastpass: { id: `fwTvs/` } }; -var ze3 = { login: `key`, card: `credit-card`, other: `lock` }; -var Be3 = { "missing-password": { id: `5QvEib` }, "missing-website": { id: `8sn99t` }, "insecure-website": { id: `nLwGv6` }, "invalid-website": { id: `OH8hLt` }, "too-long": { id: `70Usji` }, "invalid-card-number": { id: `0FSRiz` }, "invalid-expiry": { id: `yUqfOJ` }, "expired-card": { id: `yMg5R0` }, "invalid-security-code": { id: `7xaBoY` } }; -var Ve3 = { "cards-off": { id: `eBD04a` }, "unsupported-item": { id: `lsUECU` } }; -function He3(e9) { - let t2 = (t3) => e9.filter((e10) => e10.status.kind === t3).length; + return { kind: `parsed`, format: s3, rows: l5 }; +} +var Z5 = it(); +var He4 = { kzqmXN: `sand-5lhr3w`, $$css: true }; +var Ue3 = { count: { k8WAf4: `sand-j8oexa`, kg3NbH: `sand-dqyycr`, kaIpWk: `sand-1i4c3av`, kWkggS: `sand-105pnba`, kMwMTN: `sand-1o0liin`, $$css: true }, row: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-1dbef6d`, k8WAf4: `sand-1lqmthn`, kg3NbH: `sand-w3enoh`, kEafiO: `sand-1hc762m sand-1g31smg`, kPef9Z: `sand-13fuv20`, kLZC3w: `sand-13nz628`, kMwMTN: `sand-tyxrsu`, $$css: true }, ellipsis: { kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, khDVqt: `sand-uxw1ft`, $$css: true }, secondary: { kMwMTN: `sand-1o0liin`, $$css: true }, status: { kmuXW: `sand-2lah0s`, ks0D6T: `sand-1y8h3ww`, k9WMMc: `sand-p4054r`, kMwMTN: `sand-169k319`, $$css: true }, fill: { kZKoxP: `sand-5yr21d`, kaIpWk: `sand-1i4c3av`, kWkggS: `sand-8rotk8`, k1ekBW: `sand-xrbq2n`, kIyJzY: `sand-1firant`, $$css: true } }; +var We3 = { value: (e38) => [He4, { "--x-width": ((e39) => typeof e39 == `number` ? e39 + `px` : e39 ?? void 0)(`${e38}%`) }] }; +var Ge3 = { className: `sand-78zum5 sand-dt5ytf sand-q3t0pi sand-1ghz6dp sand-1717udv sand-1odjw0f sand-e8uvvx sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1qmwy7c` }; +var Ke3 = `\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022`; +var qe3 = { "1password": { id: `i2K63W` }, chrome: { id: `7K3Gyf` }, safari: { id: `w3F/28` }, firefox: { id: `htpCxn` }, bitwarden: { id: `M8XZOv` }, lastpass: { id: `fwTvs/` } }; +var Je3 = { login: `key`, card: `credit-card`, other: `lock` }; +var Ye3 = { "missing-password": { id: `5QvEib` }, "missing-website": { id: `8sn99t` }, "insecure-website": { id: `nLwGv6` }, "invalid-website": { id: `OH8hLt` }, "too-long": { id: `70Usji` }, "invalid-card-number": { id: `0FSRiz` }, "invalid-expiry": { id: `yUqfOJ` }, "expired-card": { id: `yMg5R0` }, "invalid-security-code": { id: `7xaBoY` } }; +var Xe3 = { "cards-off": { id: `eBD04a` }, "unsupported-item": { id: `lsUECU` } }; +function Ze3(e38) { + let t2 = (t3) => e38.filter((e39) => e39.status.kind === t3).length; return { ready: t2(`ready`), duplicates: t2(`duplicate`), invalid: t2(`invalid`), skipped: t2(`skipped`) }; } -function Ue3(e9) { - Ue3.d = 1881; - let t2 = (0, X3.c)(3), { kind: n2 } = e9, r2; +function Qe3(e38) { + Qe3.d = 2088; + let t2 = (0, X5.c)(3), { kind: n2 } = e38, r2; t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-vy4d1p sand-xk0z11 sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1e1y6u3 sand-1o0liin` }, t2[0] = r2) : r2 = t2[0]; - let i3 = ze3[n2], a3; - return t2[1] === i3 ? a3 = t2[2] : (a3 = (0, Q2.jsx)(`span`, { "aria-hidden": `true`, ...r2, children: (0, Q2.jsx)(tC, { name: i3, size: `sm` }) }), t2[1] = i3, t2[2] = a3), a3; + let i3 = Je3[n2], a3; + return t2[1] === i3 ? a3 = t2[2] : (a3 = (0, Z5.jsx)(`span`, { "aria-hidden": `true`, ...r2, children: (0, Z5.jsx)(aS, { name: i3, size: `sm` }) }), t2[1] = i3, t2[2] = a3), a3; } -function We3(e9) { - return e9.kind !== `login` || e9.status.kind === `invalid` && e9.status.problem === `missing-password` ? e9.secondary : e9.secondary.length === 0 ? Le3 : `${e9.secondary} \xB7 ${Le3}`; +function $e3(e38) { + return e38.kind !== `login` || e38.status.kind === `invalid` && e38.status.problem === `missing-password` ? e38.secondary : e38.secondary.length === 0 ? Ke3 : `${e38.secondary} \xB7 ${Ke3}`; } -function Ge4(e9) { - Ge4.d = 1886; - let t2 = (0, X3.c)(10), { status: r2 } = e9, { _: i3 } = bb(); - switch (r2.kind) { +function et3(e38) { + et3.d = 2093; + let t2 = (0, X5.c)(10), { status: n2 } = e38, { _: i3 } = fx(); + switch (n2.kind) { case `ready`: { - let e10; - return t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e10 = (0, Q2.jsx)(Sb, { id: `ckH3fT` }), t2[0] = e10) : e10 = t2[0], e10; + let e39; + return t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = (0, Z5.jsx)(mx, { id: `ckH3fT` }), t2[0] = e39) : e39 = t2[0], e39; } case `duplicate`: { - let e10; - return t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e10 = (0, Q2.jsx)(Sb, { id: `WhRvk/` }), t2[1] = e10) : e10 = t2[1], e10; + let e39; + return t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = (0, Z5.jsx)(mx, { id: `WhRvk/` }), t2[1] = e39) : e39 = t2[1], e39; } case `invalid`: { - let e10 = Be3[r2.problem], a3; - t2[2] !== i3 || t2[3] !== e10 ? (a3 = i3(e10), t2[2] = i3, t2[3] = e10, t2[4] = a3) : a3 = t2[4]; + let e39 = Ye3[n2.problem], a3; + t2[2] !== i3 || t2[3] !== e39 ? (a3 = i3(e39), t2[2] = i3, t2[3] = e39, t2[4] = a3) : a3 = t2[4]; let o3; - return t2[5] === a3 ? o3 = t2[6] : (o3 = (0, Q2.jsx)(Kd, { as: `span`, color: `red`, size: `xs`, children: a3 }), t2[5] = a3, t2[6] = o3), o3; + return t2[5] === a3 ? o3 = t2[6] : (o3 = (0, Z5.jsx)(Ef2, { as: `span`, color: `red`, size: `xs`, children: a3 }), t2[5] = a3, t2[6] = o3), o3; } case `skipped`: { - let e10 = Ve3[r2.reason], n2; - return t2[7] !== i3 || t2[8] !== e10 ? (n2 = i3(e10), t2[7] = i3, t2[8] = e10, t2[9] = n2) : n2 = t2[9], n2; + let e39 = Xe3[n2.reason], r2; + return t2[7] !== i3 || t2[8] !== e39 ? (r2 = i3(e39), t2[7] = i3, t2[8] = e39, t2[9] = r2) : r2 = t2[9], r2; } default: - return r2; + return n2; } } -function Ke4(e9) { - Ke4.d = 1884; - let t2 = (0, X3.c)(25), { row: n2, status: r2 } = e9, { _: i3 } = bb(), a3; - t2[0] === n2 ? a3 = t2[1] : (a3 = We3(n2), t2[0] = n2, t2[1] = a3); +function tt3(e38) { + tt3.d = 2091; + let t2 = (0, X5.c)(25), { row: n2, status: r2 } = e38, { _: i3 } = fx(), a3; + t2[0] === n2 ? a3 = t2[1] : (a3 = $e3(n2), t2[0] = n2, t2[1] = a3); let o3 = a3, s3; - t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = h(Pe2.row, sx.body2), t2[2] = s3) : s3 = t2[2]; - let c2; - t2[3] === n2.kind ? c2 = t2[4] : (c2 = (0, Q2.jsx)(Ue3, { kind: n2.kind }), t2[3] = n2.kind, t2[4] = c2); - let l4, u3; - t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l4 = { className: `sand-78zum5 sand-dt5ytf sand-1iyjqo2 sand-euugli` }, u3 = { className: `sand-b3r6kr sand-lyipyv sand-uxw1ft` }, t2[5] = l4, t2[6] = u3) : (l4 = t2[5], u3 = t2[6]); + t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = h(Ue3.row, Jb2.body2), t2[2] = s3) : s3 = t2[2]; + let c3; + t2[3] === n2.kind ? c3 = t2[4] : (c3 = (0, Z5.jsx)(Qe3, { kind: n2.kind }), t2[3] = n2.kind, t2[4] = c3); + let l5, u3; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = { className: `sand-78zum5 sand-dt5ytf sand-1iyjqo2 sand-euugli` }, u3 = { className: `sand-b3r6kr sand-lyipyv sand-uxw1ft` }, t2[5] = l5, t2[6] = u3) : (l5 = t2[5], u3 = t2[6]); let d3; t2[7] !== i3 || t2[8] !== n2.primary || t2[9] !== n2.row ? (d3 = n2.primary.length > 0 ? n2.primary : i3({ id: `JeiswB`, values: { 0: n2.row } }), t2[7] = i3, t2[8] = n2.primary, t2[9] = n2.row, t2[10] = d3) : d3 = t2[10]; let f4; - t2[11] === d3 ? f4 = t2[12] : (f4 = (0, Q2.jsx)(`span`, { ...u3, children: d3 }), t2[11] = d3, t2[12] = f4); + t2[11] === d3 ? f4 = t2[12] : (f4 = (0, Z5.jsx)(`span`, { ...u3, children: d3 }), t2[11] = d3, t2[12] = f4); let p4; - t2[13] === o3 ? p4 = t2[14] : (p4 = o3.length > 0 ? (0, Q2.jsx)(`span`, { ...h(Pe2.ellipsis, Pe2.secondary, sx.caption), children: o3 }) : null, t2[13] = o3, t2[14] = p4); + t2[13] === o3 ? p4 = t2[14] : (p4 = o3.length > 0 ? (0, Z5.jsx)(`span`, { ...h(Ue3.ellipsis, Ue3.secondary, Jb2.caption), children: o3 }) : null, t2[13] = o3, t2[14] = p4); let m3; - t2[15] !== f4 || t2[16] !== p4 ? (m3 = (0, Q2.jsxs)(`span`, { ...l4, children: [f4, p4] }), t2[15] = f4, t2[16] = p4, t2[17] = m3) : m3 = t2[17]; - let h3; - t2[18] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h3 = h(Pe2.status, sx.caption), t2[18] = h3) : h3 = t2[18]; - let g3; - t2[19] === r2 ? g3 = t2[20] : (g3 = (0, Q2.jsx)(`span`, { ...h3, children: r2 }), t2[19] = r2, t2[20] = g3); - let _2; - return t2[21] !== g3 || t2[22] !== c2 || t2[23] !== m3 ? (_2 = (0, Q2.jsxs)(`li`, { ...s3, children: [c2, m3, g3] }), t2[21] = g3, t2[22] = c2, t2[23] = m3, t2[24] = _2) : _2 = t2[24], _2; -} -function qe3(e9) { - qe3.d = 1880; - let t2 = (0, X3.c)(3), { children: n2 } = e9, r2; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = h(Pe2.count, sx.caption), t2[0] = r2) : r2 = t2[0]; + t2[15] !== f4 || t2[16] !== p4 ? (m3 = (0, Z5.jsxs)(`span`, { ...l5, children: [f4, p4] }), t2[15] = f4, t2[16] = p4, t2[17] = m3) : m3 = t2[17]; + let h4; + t2[18] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h4 = h(Ue3.status, Jb2.caption), t2[18] = h4) : h4 = t2[18]; + let g5; + t2[19] === r2 ? g5 = t2[20] : (g5 = (0, Z5.jsx)(`span`, { ...h4, children: r2 }), t2[19] = r2, t2[20] = g5); + let v5; + return t2[21] !== g5 || t2[22] !== c3 || t2[23] !== m3 ? (v5 = (0, Z5.jsxs)(`li`, { ...s3, children: [c3, m3, g5] }), t2[21] = g5, t2[22] = c3, t2[23] = m3, t2[24] = v5) : v5 = t2[24], v5; +} +function nt3(e38) { + nt3.d = 2087; + let t2 = (0, X5.c)(3), { children: n2 } = e38, r2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = h(Ue3.count, Jb2.caption), t2[0] = r2) : r2 = t2[0]; let i3; - return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, Q2.jsx)(`span`, { ...r2, children: n2 }), t2[1] = n2, t2[2] = i3), i3; -} -function Je3(e9) { - Je3.d = 1883; - let t2 = (0, X3.c)(101), { phase: r2, existing: i3, cardsEnabled: a3, onPlanned: c2, onError: l4, onImport: u3, onClose: d3 } = e9, { _: f4 } = bb(), p4 = (0, Y3.useRef)(null), m3; - t2[0] !== f4 || t2[1] !== a3 || t2[2] !== i3 || t2[3] !== l4 || t2[4] !== c2 ? (m3 = async (e10) => { - let t3 = e10.currentTarget, n2 = t3.files?.[0]; - if (t3.value = ``, n2 === void 0) return; - if (n2.size > 5242880) { - l4(f4({ id: `uycY/T` })); + return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, Z5.jsx)(`span`, { ...r2, children: n2 }), t2[1] = n2, t2[2] = i3), i3; +} +function rt4(e38) { + rt4.d = 2090; + let t2 = (0, X5.c)(101), { phase: n2, existing: i3, cardsEnabled: a3, onPlanned: o3, onError: s3, onImport: c3, onClose: l5 } = e38, { _: u3 } = fx(), d3 = (0, Y5.useRef)(null), f4; + t2[0] !== u3 || t2[1] !== a3 || t2[2] !== i3 || t2[3] !== s3 || t2[4] !== o3 ? (f4 = async (e39) => { + let t3 = e39.currentTarget, n3 = t3.files?.[0]; + if (t3.value = ``, n3 === void 0) return; + if (n3.size > 5242880) { + s3(u3({ id: `uycY/T` })); return; } - let r3 = await n2.text().then(Ze3, Xe3); - if (r3.kind === `unreadable`) { - l4(f4({ id: `WYG9Bc` })); + let r2 = await n3.text().then(ot3, at3); + if (r2.kind === `unreadable`) { + s3(u3({ id: `WYG9Bc` })); return; } - let o3 = r3.text, s3 = Me2({ text: o3, existing: i3, cardsEnabled: a3, now: /* @__PURE__ */ new Date() }); - if (s3.kind === `unrecognized`) { - l4(f4({ id: `Uq6RAf` })); + let c4 = r2.text, l6 = Ve4({ text: c4, existing: i3, cardsEnabled: a3, now: /* @__PURE__ */ new Date() }); + if (l6.kind === `unrecognized`) { + s3(u3({ id: `Uq6RAf` })); return; } - c2(s3); - }, t2[0] = f4, t2[1] = a3, t2[2] = i3, t2[3] = l4, t2[4] = c2, t2[5] = m3) : m3 = t2[5]; - let h3 = m3, g3; - t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g3 = () => p4.current?.click(), t2[6] = g3) : g3 = t2[6]; - let _2 = g3, v3; - t2[7] === f4 ? v3 = t2[8] : (v3 = f4({ id: `rfbXwj` }), t2[7] = f4, t2[8] = v3); - let y3; - t2[9] === h3 ? y3 = t2[10] : (y3 = (e10) => void h3(e10), t2[9] = h3, t2[10] = y3); - let b3; - t2[11] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (b3 = { className: `sand-1s85apg` }, t2[11] = b3) : b3 = t2[11]; - let x3; - t2[12] !== v3 || t2[13] !== y3 ? (x3 = (0, Q2.jsx)(`input`, { accept: `.csv,text/csv`, "aria-label": v3, onChange: y3, ref: p4, tabIndex: -1, type: `file`, ...b3 }), t2[12] = v3, t2[13] = y3, t2[14] = x3) : x3 = t2[14]; - let S3 = x3; - if (r2.kind === `pick`) { - let e10; - t2[15] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e10 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa` }, t2[15] = e10) : e10 = t2[15]; + o3(l6); + }, t2[0] = u3, t2[1] = a3, t2[2] = i3, t2[3] = s3, t2[4] = o3, t2[5] = f4) : f4 = t2[5]; + let p4 = f4, m3; + t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m3 = () => d3.current?.click(), t2[6] = m3) : m3 = t2[6]; + let h4 = m3, g5; + t2[7] === u3 ? g5 = t2[8] : (g5 = u3({ id: `rfbXwj` }), t2[7] = u3, t2[8] = g5); + let _5; + t2[9] === p4 ? _5 = t2[10] : (_5 = (e39) => void p4(e39), t2[9] = p4, t2[10] = _5); + let v5; + t2[11] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (v5 = { className: `sand-1s85apg` }, t2[11] = v5) : v5 = t2[11]; + let y4; + t2[12] !== g5 || t2[13] !== _5 ? (y4 = (0, Z5.jsx)(`input`, { accept: `.csv,text/csv`, "aria-label": g5, onChange: _5, ref: d3, tabIndex: -1, type: `file`, ...v5 }), t2[12] = g5, t2[13] = _5, t2[14] = y4) : y4 = t2[14]; + let b2 = y4; + if (n2.kind === `pick`) { + let e39; + t2[15] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa` }, t2[15] = e39) : e39 = t2[15]; let i4; - t2[16] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i4 = (0, Q2.jsx)(Kd, { as: `p`, color: `secondary`, size: `sm`, children: (0, Q2.jsx)(Sb, { id: `vmh1dn` }) }), t2[16] = i4) : i4 = t2[16]; - let c3; - t2[17] === a3 ? c3 = t2[18] : (c3 = a3 ? (0, Q2.jsx)(Kd, { as: `p`, color: `secondary`, size: `sm`, children: (0, Q2.jsx)(Sb, { id: `NE09IK` }) }) : null, t2[17] = a3, t2[18] = c3); - let l5; - t2[19] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = (0, Q2.jsx)(Kd, { as: `p`, color: `secondary`, size: `sm`, children: (0, Q2.jsx)(Sb, { id: `yhT5K5` }) }), t2[19] = l5) : l5 = t2[19]; + t2[16] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i4 = (0, Z5.jsx)(Ef2, { as: `p`, color: `secondary`, size: `sm`, children: (0, Z5.jsx)(mx, { id: `vmh1dn` }) }), t2[16] = i4) : i4 = t2[16]; + let o4; + t2[17] === a3 ? o4 = t2[18] : (o4 = a3 ? (0, Z5.jsx)(Ef2, { as: `p`, color: `secondary`, size: `sm`, children: (0, Z5.jsx)(mx, { id: `NE09IK` }) }) : null, t2[17] = a3, t2[18] = o4); + let s4; + t2[19] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s4 = (0, Z5.jsx)(Ef2, { as: `p`, color: `secondary`, size: `sm`, children: (0, Z5.jsx)(mx, { id: `yhT5K5` }) }), t2[19] = s4) : s4 = t2[19]; + let c4; + t2[20] === o4 ? c4 = t2[21] : (c4 = (0, Z5.jsxs)(`div`, { ...e39, children: [i4, o4, s4] }), t2[20] = o4, t2[21] = c4); let u4; - t2[20] === c3 ? u4 = t2[21] : (u4 = (0, Q2.jsxs)(`div`, { ...e10, children: [i4, c3, l5] }), t2[20] = c3, t2[21] = u4); + t2[22] !== b2 || t2[23] !== c4 ? (u4 = (0, Z5.jsxs)(_, { children: [c4, b2] }), t2[22] = b2, t2[23] = c4, t2[24] = u4) : u4 = t2[24]; + let d4; + t2[25] === n2.error ? d4 = t2[26] : (d4 = n2.error === null ? null : (0, Z5.jsx)(Ef2, { as: `p`, color: `red`, role: `alert`, size: `xs`, children: n2.error }), t2[25] = n2.error, t2[26] = d4); let f5; - t2[22] !== S3 || t2[23] !== u4 ? (f5 = (0, Q2.jsxs)(_, { children: [u4, S3] }), t2[22] = S3, t2[23] = u4, t2[24] = f5) : f5 = t2[24]; + t2[27] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f5 = (0, Z5.jsx)(mx, { id: `dEgA5A` }), t2[27] = f5) : f5 = t2[27]; let p5; - t2[25] === r2.error ? p5 = t2[26] : (p5 = r2.error === null ? null : (0, Q2.jsx)(Kd, { as: `p`, color: `red`, role: `alert`, size: `xs`, children: r2.error }), t2[25] = r2.error, t2[26] = p5); + t2[28] === l5 ? p5 = t2[29] : (p5 = (0, Z5.jsx)(LS, { onClick: l5, size: `lg`, type: `button`, variant: `secondary`, children: f5 }), t2[28] = l5, t2[29] = p5); let m4; - t2[27] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m4 = (0, Q2.jsx)(Sb, { id: `dEgA5A` }), t2[27] = m4) : m4 = t2[27]; - let h4; - t2[28] === d3 ? h4 = t2[29] : (h4 = (0, Q2.jsx)(MC, { onClick: d3, size: `lg`, type: `button`, variant: `secondary`, children: m4 }), t2[28] = d3, t2[29] = h4); - let g4; - t2[30] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g4 = (0, Q2.jsx)(MC, { onClick: _2, size: `lg`, type: `button`, variant: `primary`, children: (0, Q2.jsx)(Sb, { id: `cKp8I8` }) }), t2[30] = g4) : g4 = t2[30]; - let v4; - t2[31] === h4 ? v4 = t2[32] : (v4 = (0, Q2.jsxs)(Q2.Fragment, { children: [h4, g4] }), t2[31] = h4, t2[32] = v4); - let y4; - t2[33] !== p5 || t2[34] !== v4 ? (y4 = (0, Q2.jsx)(TC, { leading: p5, trailing: v4 }), t2[33] = p5, t2[34] = v4, t2[35] = y4) : y4 = t2[35]; - let b4; - return t2[36] !== f5 || t2[37] !== y4 ? (b4 = (0, Q2.jsxs)(Q2.Fragment, { children: [f5, y4] }), t2[36] = f5, t2[37] = y4, t2[38] = b4) : b4 = t2[38], b4; - } - let C2, w3, T3, E3, D2, O3, j3, M3, N2, P2, F2; - if (t2[39] !== f4 || t2[40] !== S3 || t2[41] !== d3 || t2[42] !== u3 || t2[43] !== r2.format || t2[44] !== r2.rows) { - let e10 = He3(r2.rows), i4; + t2[30] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m4 = (0, Z5.jsx)(LS, { onClick: h4, size: `lg`, type: `button`, variant: `primary`, children: (0, Z5.jsx)(mx, { id: `cKp8I8` }) }), t2[30] = m4) : m4 = t2[30]; + let g6; + t2[31] === p5 ? g6 = t2[32] : (g6 = (0, Z5.jsxs)(Z5.Fragment, { children: [p5, m4] }), t2[31] = p5, t2[32] = g6); + let _6; + t2[33] !== d4 || t2[34] !== g6 ? (_6 = (0, Z5.jsx)(AS, { leading: d4, trailing: g6 }), t2[33] = d4, t2[34] = g6, t2[35] = _6) : _6 = t2[35]; + let v6; + return t2[36] !== u4 || t2[37] !== _6 ? (v6 = (0, Z5.jsxs)(Z5.Fragment, { children: [u4, _6] }), t2[36] = u4, t2[37] = _6, t2[38] = v6) : v6 = t2[38], v6; + } + let x2, S2, C2, w2, T2, E2, D2, O2, k2, j2, M2; + if (t2[39] !== u3 || t2[40] !== b2 || t2[41] !== l5 || t2[42] !== c3 || t2[43] !== n2.format || t2[44] !== n2.rows) { + let e39 = Ze3(n2.rows), i4; t2[56] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i4 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa` }, t2[56] = i4) : i4 = t2[56]; - let a4 = Re3[r2.format], c3; - t2[57] !== f4 || t2[58] !== a4 ? (c3 = f4(a4), t2[57] = f4, t2[58] = a4, t2[59] = c3) : c3 = t2[59]; - let l5; - t2[60] === c3 ? l5 = t2[61] : (l5 = (0, Q2.jsx)(Kd, { as: `p`, size: `sm`, children: c3 }), t2[60] = c3, t2[61] = l5); - let p5; - t2[62] === f4 ? p5 = t2[63] : (p5 = f4({ id: `x2fZoE` }), t2[62] = f4, t2[63] = p5); - let m4; - t2[64] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m4 = { className: `sand-78zum5 sand-1a02dak sand-pkkfsy` }, t2[64] = m4) : m4 = t2[64]; - let h4 = (0, Q2.jsxs)(`div`, { "aria-label": p5, role: `group`, ...m4, children: [(0, Q2.jsx)(qe3, { children: f4({ id: `GQignI`, values: { 0: e10.ready } }) }), e10.duplicates > 0 ? (0, Q2.jsx)(qe3, { children: f4({ id: `bPYHMq`, values: { 0: e10.duplicates } }) }) : null, e10.invalid > 0 ? (0, Q2.jsx)(qe3, { children: f4({ id: `R15yqd`, values: { 0: e10.invalid } }) }) : null, e10.skipped > 0 ? (0, Q2.jsx)(qe3, { children: f4({ id: `fAcGxw`, values: { 0: e10.skipped } }) }) : null] }), g4; - t2[65] === f4 ? g4 = t2[66] : (g4 = f4({ id: `Q1ylu5` }), t2[65] = f4, t2[66] = g4); - let v4; - t2[67] === r2.rows ? v4 = t2[68] : (v4 = r2.rows.map(Ye3), t2[67] = r2.rows, t2[68] = v4); - let y4; - t2[69] !== g4 || t2[70] !== v4 ? (y4 = (0, Q2.jsx)(`ul`, { "aria-label": g4, ...Ie3, children: v4 }), t2[69] = g4, t2[70] = v4, t2[71] = y4) : y4 = t2[71]; - let b4; - t2[72] !== l5 || t2[73] !== h4 || t2[74] !== y4 ? (b4 = (0, Q2.jsxs)(`div`, { ...i4, children: [l5, h4, y4] }), t2[72] = l5, t2[73] = h4, t2[74] = y4, t2[75] = b4) : b4 = t2[75], t2[76] !== S3 || t2[77] !== b4 ? (M3 = (0, Q2.jsxs)(_, { children: [b4, S3] }), t2[76] = S3, t2[77] = b4, t2[78] = M3) : M3 = t2[78], w3 = TC, t2[79] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (j3 = (0, Q2.jsx)(MC, { onClick: _2, size: `lg`, type: `button`, variant: `tertiary`, children: (0, Q2.jsx)(Sb, { id: `0KHIyx` }) }), t2[79] = j3) : j3 = t2[79]; - let x4; - t2[80] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (x4 = (0, Q2.jsx)(Sb, { id: `dEgA5A` }), t2[80] = x4) : x4 = t2[80], t2[81] === d3 ? O3 = t2[82] : (O3 = (0, Q2.jsx)(MC, { onClick: d3, size: `lg`, type: `button`, variant: `secondary`, children: x4 }), t2[81] = d3, t2[82] = O3), C2 = MC, N2 = e10.ready === 0, P2 = () => u3(e10.duplicates), F2 = `lg`, T3 = `button`, E3 = `primary`, D2 = f4({ id: `dF5m/c`, values: { 0: e10.ready } }), t2[39] = f4, t2[40] = S3, t2[41] = d3, t2[42] = u3, t2[43] = r2.format, t2[44] = r2.rows, t2[45] = C2, t2[46] = w3, t2[47] = T3, t2[48] = E3, t2[49] = D2, t2[50] = O3, t2[51] = j3, t2[52] = M3, t2[53] = N2, t2[54] = P2, t2[55] = F2; - } else C2 = t2[45], w3 = t2[46], T3 = t2[47], E3 = t2[48], D2 = t2[49], O3 = t2[50], j3 = t2[51], M3 = t2[52], N2 = t2[53], P2 = t2[54], F2 = t2[55]; - let L; - t2[83] !== C2 || t2[84] !== T3 || t2[85] !== E3 || t2[86] !== D2 || t2[87] !== N2 || t2[88] !== P2 || t2[89] !== F2 ? (L = (0, Q2.jsx)(C2, { disabled: N2, onClick: P2, size: F2, type: T3, variant: E3, children: D2 }), t2[83] = C2, t2[84] = T3, t2[85] = E3, t2[86] = D2, t2[87] = N2, t2[88] = P2, t2[89] = F2, t2[90] = L) : L = t2[90]; - let R3; - t2[91] !== O3 || t2[92] !== L ? (R3 = (0, Q2.jsxs)(Q2.Fragment, { children: [O3, L] }), t2[91] = O3, t2[92] = L, t2[93] = R3) : R3 = t2[93]; - let z4; - t2[94] !== w3 || t2[95] !== j3 || t2[96] !== R3 ? (z4 = (0, Q2.jsx)(w3, { leading: j3, trailing: R3 }), t2[94] = w3, t2[95] = j3, t2[96] = R3, t2[97] = z4) : z4 = t2[97]; - let B4; - return t2[98] !== M3 || t2[99] !== z4 ? (B4 = (0, Q2.jsxs)(Q2.Fragment, { children: [M3, z4] }), t2[98] = M3, t2[99] = z4, t2[100] = B4) : B4 = t2[100], B4; -} -function Ye3(e9) { - return (0, Q2.jsx)(Ke4, { row: e9, status: (0, Q2.jsx)(Ge4, { status: e9.status }) }, e9.row); -} -function Xe3(e9) { - return { kind: `unreadable`, cause: e9 }; -} -function Ze3(e9) { - return { kind: `read`, text: e9 }; -} -function Qe3(e9) { - Qe3.d = 1885; - let t2 = (0, X3.c)(43), { done: r2, total: i3, onStop: a3 } = e9, { _: c2 } = bb(), l4, u3, d3, f4, p4, m3, h3, g3, _2, v3; - if (t2[0] !== c2 || t2[1] !== r2 || t2[2] !== i3) { - let e10 = i3 === 0 ? 100 : Math.round(r2 / i3 * 100); - l4 = _, t2[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (_2 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa` }, t2[13] = _2) : _2 = t2[13], t2[14] !== r2 || t2[15] !== i3 ? (v3 = (0, Q2.jsx)(Kd, { as: `p`, size: `sm`, children: (0, Q2.jsx)(Sb, { id: `YLKiRf`, values: { done: r2, total: i3 } }) }), t2[14] = r2, t2[15] = i3, t2[16] = v3) : v3 = t2[16], t2[17] === c2 ? d3 = t2[18] : (d3 = c2({ id: `5NjsW4` }), t2[17] = c2, t2[18] = d3), f4 = i3, p4 = 0, m3 = r2, h3 = `progressbar`, t2[19] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g3 = { className: `sand-ols6we sand-b3r6kr sand-1i4c3av sand-105pnba` }, t2[19] = g3) : g3 = t2[19], u3 = h(Pe2.fill, Fe3.value(e10)), t2[0] = c2, t2[1] = r2, t2[2] = i3, t2[3] = l4, t2[4] = u3, t2[5] = d3, t2[6] = f4, t2[7] = p4, t2[8] = m3, t2[9] = h3, t2[10] = g3, t2[11] = _2, t2[12] = v3; - } else l4 = t2[3], u3 = t2[4], d3 = t2[5], f4 = t2[6], p4 = t2[7], m3 = t2[8], h3 = t2[9], g3 = t2[10], _2 = t2[11], v3 = t2[12]; - let y3; - t2[20] === u3 ? y3 = t2[21] : (y3 = (0, Q2.jsx)(`div`, { ...u3 }), t2[20] = u3, t2[21] = y3); - let b3; - t2[22] !== y3 || t2[23] !== d3 || t2[24] !== f4 || t2[25] !== p4 || t2[26] !== m3 || t2[27] !== h3 || t2[28] !== g3 ? (b3 = (0, Q2.jsx)(`div`, { "aria-label": d3, "aria-valuemax": f4, "aria-valuemin": p4, "aria-valuenow": m3, role: h3, ...g3, children: y3 }), t2[22] = y3, t2[23] = d3, t2[24] = f4, t2[25] = p4, t2[26] = m3, t2[27] = h3, t2[28] = g3, t2[29] = b3) : b3 = t2[29]; - let x3; - t2[30] !== b3 || t2[31] !== _2 || t2[32] !== v3 ? (x3 = (0, Q2.jsxs)(`div`, { ..._2, children: [v3, b3] }), t2[30] = b3, t2[31] = _2, t2[32] = v3, t2[33] = x3) : x3 = t2[33]; - let S3; - t2[34] !== l4 || t2[35] !== x3 ? (S3 = (0, Q2.jsx)(l4, { children: x3 }), t2[34] = l4, t2[35] = x3, t2[36] = S3) : S3 = t2[36]; + let a4 = qe3[n2.format], o4; + t2[57] !== u3 || t2[58] !== a4 ? (o4 = u3(a4), t2[57] = u3, t2[58] = a4, t2[59] = o4) : o4 = t2[59]; + let s4; + t2[60] === o4 ? s4 = t2[61] : (s4 = (0, Z5.jsx)(Ef2, { as: `p`, size: `sm`, children: o4 }), t2[60] = o4, t2[61] = s4); + let d4; + t2[62] === u3 ? d4 = t2[63] : (d4 = u3({ id: `x2fZoE` }), t2[62] = u3, t2[63] = d4); + let f5; + t2[64] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f5 = { className: `sand-78zum5 sand-1a02dak sand-pkkfsy` }, t2[64] = f5) : f5 = t2[64]; + let p5 = (0, Z5.jsxs)(`div`, { "aria-label": d4, role: `group`, ...f5, children: [(0, Z5.jsx)(nt3, { children: u3({ id: `GQignI`, values: { 0: e39.ready } }) }), e39.duplicates > 0 ? (0, Z5.jsx)(nt3, { children: u3({ id: `bPYHMq`, values: { 0: e39.duplicates } }) }) : null, e39.invalid > 0 ? (0, Z5.jsx)(nt3, { children: u3({ id: `R15yqd`, values: { 0: e39.invalid } }) }) : null, e39.skipped > 0 ? (0, Z5.jsx)(nt3, { children: u3({ id: `fAcGxw`, values: { 0: e39.skipped } }) }) : null] }), m4; + t2[65] === u3 ? m4 = t2[66] : (m4 = u3({ id: `Q1ylu5` }), t2[65] = u3, t2[66] = m4); + let g6; + t2[67] === n2.rows ? g6 = t2[68] : (g6 = n2.rows.map(it4), t2[67] = n2.rows, t2[68] = g6); + let _6; + t2[69] !== m4 || t2[70] !== g6 ? (_6 = (0, Z5.jsx)(`ul`, { "aria-label": m4, ...Ge3, children: g6 }), t2[69] = m4, t2[70] = g6, t2[71] = _6) : _6 = t2[71]; + let v6; + t2[72] !== s4 || t2[73] !== p5 || t2[74] !== _6 ? (v6 = (0, Z5.jsxs)(`div`, { ...i4, children: [s4, p5, _6] }), t2[72] = s4, t2[73] = p5, t2[74] = _6, t2[75] = v6) : v6 = t2[75], t2[76] !== b2 || t2[77] !== v6 ? (O2 = (0, Z5.jsxs)(_, { children: [v6, b2] }), t2[76] = b2, t2[77] = v6, t2[78] = O2) : O2 = t2[78], S2 = AS, t2[79] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (D2 = (0, Z5.jsx)(LS, { onClick: h4, size: `lg`, type: `button`, variant: `tertiary`, children: (0, Z5.jsx)(mx, { id: `0KHIyx` }) }), t2[79] = D2) : D2 = t2[79]; + let y5; + t2[80] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (y5 = (0, Z5.jsx)(mx, { id: `dEgA5A` }), t2[80] = y5) : y5 = t2[80], t2[81] === l5 ? E2 = t2[82] : (E2 = (0, Z5.jsx)(LS, { onClick: l5, size: `lg`, type: `button`, variant: `secondary`, children: y5 }), t2[81] = l5, t2[82] = E2), x2 = LS, k2 = e39.ready === 0, j2 = () => c3(e39.duplicates), M2 = `lg`, C2 = `button`, w2 = `primary`, T2 = u3({ id: `dF5m/c`, values: { 0: e39.ready } }), t2[39] = u3, t2[40] = b2, t2[41] = l5, t2[42] = c3, t2[43] = n2.format, t2[44] = n2.rows, t2[45] = x2, t2[46] = S2, t2[47] = C2, t2[48] = w2, t2[49] = T2, t2[50] = E2, t2[51] = D2, t2[52] = O2, t2[53] = k2, t2[54] = j2, t2[55] = M2; + } else x2 = t2[45], S2 = t2[46], C2 = t2[47], w2 = t2[48], T2 = t2[49], E2 = t2[50], D2 = t2[51], O2 = t2[52], k2 = t2[53], j2 = t2[54], M2 = t2[55]; + let N3; + t2[83] !== x2 || t2[84] !== C2 || t2[85] !== w2 || t2[86] !== T2 || t2[87] !== k2 || t2[88] !== j2 || t2[89] !== M2 ? (N3 = (0, Z5.jsx)(x2, { disabled: k2, onClick: j2, size: M2, type: C2, variant: w2, children: T2 }), t2[83] = x2, t2[84] = C2, t2[85] = w2, t2[86] = T2, t2[87] = k2, t2[88] = j2, t2[89] = M2, t2[90] = N3) : N3 = t2[90]; + let P3; + t2[91] !== E2 || t2[92] !== N3 ? (P3 = (0, Z5.jsxs)(Z5.Fragment, { children: [E2, N3] }), t2[91] = E2, t2[92] = N3, t2[93] = P3) : P3 = t2[93]; + let F2; + t2[94] !== S2 || t2[95] !== D2 || t2[96] !== P3 ? (F2 = (0, Z5.jsx)(S2, { leading: D2, trailing: P3 }), t2[94] = S2, t2[95] = D2, t2[96] = P3, t2[97] = F2) : F2 = t2[97]; + let L3; + return t2[98] !== O2 || t2[99] !== F2 ? (L3 = (0, Z5.jsxs)(Z5.Fragment, { children: [O2, F2] }), t2[98] = O2, t2[99] = F2, t2[100] = L3) : L3 = t2[100], L3; +} +function it4(e38) { + return (0, Z5.jsx)(tt3, { row: e38, status: (0, Z5.jsx)(et3, { status: e38.status }) }, e38.row); +} +function at3(e38) { + return { kind: `unreadable`, cause: e38 }; +} +function ot3(e38) { + return { kind: `read`, text: e38 }; +} +function st2(e38) { + st2.d = 2092; + let t2 = (0, X5.c)(43), { done: n2, total: i3, onStop: a3 } = e38, { _: o3 } = fx(), s3, c3, l5, u3, d3, f4, p4, m3, h4, g5; + if (t2[0] !== o3 || t2[1] !== n2 || t2[2] !== i3) { + let e39 = i3 === 0 ? 100 : Math.round(n2 / i3 * 100); + s3 = _, t2[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h4 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa` }, t2[13] = h4) : h4 = t2[13], t2[14] !== n2 || t2[15] !== i3 ? (g5 = (0, Z5.jsx)(Ef2, { as: `p`, size: `sm`, children: (0, Z5.jsx)(mx, { id: `YLKiRf`, values: { done: n2, total: i3 } }) }), t2[14] = n2, t2[15] = i3, t2[16] = g5) : g5 = t2[16], t2[17] === o3 ? l5 = t2[18] : (l5 = o3({ id: `5NjsW4` }), t2[17] = o3, t2[18] = l5), u3 = i3, d3 = 0, f4 = n2, p4 = `progressbar`, t2[19] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m3 = { className: `sand-ols6we sand-b3r6kr sand-1i4c3av sand-105pnba` }, t2[19] = m3) : m3 = t2[19], c3 = h(Ue3.fill, We3.value(e39)), t2[0] = o3, t2[1] = n2, t2[2] = i3, t2[3] = s3, t2[4] = c3, t2[5] = l5, t2[6] = u3, t2[7] = d3, t2[8] = f4, t2[9] = p4, t2[10] = m3, t2[11] = h4, t2[12] = g5; + } else s3 = t2[3], c3 = t2[4], l5 = t2[5], u3 = t2[6], d3 = t2[7], f4 = t2[8], p4 = t2[9], m3 = t2[10], h4 = t2[11], g5 = t2[12]; + let _5; + t2[20] === c3 ? _5 = t2[21] : (_5 = (0, Z5.jsx)(`div`, { ...c3 }), t2[20] = c3, t2[21] = _5); + let v5; + t2[22] !== _5 || t2[23] !== l5 || t2[24] !== u3 || t2[25] !== d3 || t2[26] !== f4 || t2[27] !== p4 || t2[28] !== m3 ? (v5 = (0, Z5.jsx)(`div`, { "aria-label": l5, "aria-valuemax": u3, "aria-valuemin": d3, "aria-valuenow": f4, role: p4, ...m3, children: _5 }), t2[22] = _5, t2[23] = l5, t2[24] = u3, t2[25] = d3, t2[26] = f4, t2[27] = p4, t2[28] = m3, t2[29] = v5) : v5 = t2[29]; + let y4; + t2[30] !== v5 || t2[31] !== h4 || t2[32] !== g5 ? (y4 = (0, Z5.jsxs)(`div`, { ...h4, children: [g5, v5] }), t2[30] = v5, t2[31] = h4, t2[32] = g5, t2[33] = y4) : y4 = t2[33]; + let b2; + t2[34] !== s3 || t2[35] !== y4 ? (b2 = (0, Z5.jsx)(s3, { children: y4 }), t2[34] = s3, t2[35] = y4, t2[36] = b2) : b2 = t2[36]; + let x2; + t2[37] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (x2 = (0, Z5.jsx)(mx, { id: `sqgQgy` }), t2[37] = x2) : x2 = t2[37]; + let S2; + t2[38] === a3 ? S2 = t2[39] : (S2 = (0, Z5.jsx)(AS, { trailing: (0, Z5.jsx)(LS, { onClick: a3, size: `lg`, type: `button`, variant: `secondary`, children: x2 }) }), t2[38] = a3, t2[39] = S2); let C2; - t2[37] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (C2 = (0, Q2.jsx)(Sb, { id: `sqgQgy` }), t2[37] = C2) : C2 = t2[37]; - let w3; - t2[38] === a3 ? w3 = t2[39] : (w3 = (0, Q2.jsx)(TC, { trailing: (0, Q2.jsx)(MC, { onClick: a3, size: `lg`, type: `button`, variant: `secondary`, children: C2 }) }), t2[38] = a3, t2[39] = w3); - let T3; - return t2[40] !== S3 || t2[41] !== w3 ? (T3 = (0, Q2.jsxs)(Q2.Fragment, { children: [S3, w3] }), t2[40] = S3, t2[41] = w3, t2[42] = T3) : T3 = t2[42], T3; -} -function $e3(e9) { - $e3.d = 1887; - let t2 = (0, X3.c)(26), { summary: r2, onClose: i3 } = e9, { _: a3 } = bb(), { logins: c2, cards: l4, duplicates: u3, failures: d3, stoppedEarly: f4 } = r2, p4; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa` }, t2[0] = p4) : p4 = t2[0]; + return t2[40] !== b2 || t2[41] !== S2 ? (C2 = (0, Z5.jsxs)(Z5.Fragment, { children: [b2, S2] }), t2[40] = b2, t2[41] = S2, t2[42] = C2) : C2 = t2[42], C2; +} +function ct2(e38) { + ct2.d = 2094; + let t2 = (0, X5.c)(26), { summary: n2, onClose: i3 } = e38, { _: a3 } = fx(), { logins: o3, cards: s3, duplicates: c3, failures: l5, stoppedEarly: u3 } = n2, d3; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (d3 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa` }, t2[0] = d3) : d3 = t2[0]; + let f4; + t2[1] !== a3 || t2[2] !== s3 || t2[3] !== o3 ? (f4 = a3(s3 > 0 ? { id: `wKV/qm`, values: { logins: o3, cards: s3 } } : { id: `qj/uYG`, values: { logins: o3 } }), t2[1] = a3, t2[2] = s3, t2[3] = o3, t2[4] = f4) : f4 = t2[4]; + let p4; + t2[5] === f4 ? p4 = t2[6] : (p4 = (0, Z5.jsx)(Ef2, { as: `p`, role: `status`, size: `sm`, children: f4 }), t2[5] = f4, t2[6] = p4); let m3; - t2[1] !== a3 || t2[2] !== l4 || t2[3] !== c2 ? (m3 = a3(l4 > 0 ? { id: `wKV/qm`, values: { logins: c2, cards: l4 } } : { id: `qj/uYG`, values: { logins: c2 } }), t2[1] = a3, t2[2] = l4, t2[3] = c2, t2[4] = m3) : m3 = t2[4]; - let h3; - t2[5] === m3 ? h3 = t2[6] : (h3 = (0, Q2.jsx)(Kd, { as: `p`, role: `status`, size: `sm`, children: m3 }), t2[5] = m3, t2[6] = h3); - let g3; - t2[7] !== a3 || t2[8] !== u3 ? (g3 = u3 > 0 ? (0, Q2.jsx)(Kd, { as: `p`, color: `secondary`, size: `sm`, children: a3({ id: `kof2re`, values: { duplicates: u3 } }) }) : null, t2[7] = a3, t2[8] = u3, t2[9] = g3) : g3 = t2[9]; - let _2; - t2[10] === f4 ? _2 = t2[11] : (_2 = f4 ? (0, Q2.jsx)(Kd, { as: `p`, color: `secondary`, size: `sm`, children: (0, Q2.jsx)(Sb, { id: `9oQeTa` }) }) : null, t2[10] = f4, t2[11] = _2); - let v3; - t2[12] !== a3 || t2[13] !== d3 ? (v3 = d3.length > 0 ? (0, Q2.jsxs)(Q2.Fragment, { children: [(0, Q2.jsx)(Kd, { as: `p`, color: `red`, size: `sm`, children: a3({ id: `DGFoI3`, values: { 0: d3.length } }) }), (0, Q2.jsx)(`ul`, { "aria-label": a3({ id: `jfSsZr` }), ...Ie3, children: d3.map(et3) })] }) : null, t2[12] = a3, t2[13] = d3, t2[14] = v3) : v3 = t2[14]; - let y3; - t2[15] !== h3 || t2[16] !== g3 || t2[17] !== _2 || t2[18] !== v3 ? (y3 = (0, Q2.jsx)(_, { children: (0, Q2.jsxs)(`div`, { ...p4, children: [h3, g3, _2, v3] }) }), t2[15] = h3, t2[16] = g3, t2[17] = _2, t2[18] = v3, t2[19] = y3) : y3 = t2[19]; - let b3; - t2[20] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (b3 = (0, Q2.jsx)(Sb, { id: `DPfwMq` }), t2[20] = b3) : b3 = t2[20]; - let x3; - t2[21] === i3 ? x3 = t2[22] : (x3 = (0, Q2.jsx)(TC, { trailing: (0, Q2.jsx)(MC, { onClick: i3, size: `lg`, type: `button`, variant: `primary`, children: b3 }) }), t2[21] = i3, t2[22] = x3); - let S3; - return t2[23] !== y3 || t2[24] !== x3 ? (S3 = (0, Q2.jsxs)(Q2.Fragment, { children: [y3, x3] }), t2[23] = y3, t2[24] = x3, t2[25] = S3) : S3 = t2[25], S3; -} -function et3(e9) { - let { preview: t2, message: r2 } = e9; - return (0, Q2.jsx)(Ke4, { row: t2, status: (0, Q2.jsx)(Kd, { as: `span`, color: `red`, size: `xs`, children: r2 }) }, t2.row); -} -function tt3(e9) { - tt3.d = 1882; - let t2 = (0, X3.c)(23), { items: n2, cardsEnabled: r2, onClose: i3 } = e9, { _: a3 } = bb(), o3 = kge(), s3; + t2[7] !== a3 || t2[8] !== c3 ? (m3 = c3 > 0 ? (0, Z5.jsx)(Ef2, { as: `p`, color: `secondary`, size: `sm`, children: a3({ id: `kof2re`, values: { duplicates: c3 } }) }) : null, t2[7] = a3, t2[8] = c3, t2[9] = m3) : m3 = t2[9]; + let h4; + t2[10] === u3 ? h4 = t2[11] : (h4 = u3 ? (0, Z5.jsx)(Ef2, { as: `p`, color: `secondary`, size: `sm`, children: (0, Z5.jsx)(mx, { id: `9oQeTa` }) }) : null, t2[10] = u3, t2[11] = h4); + let g5; + t2[12] !== a3 || t2[13] !== l5 ? (g5 = l5.length > 0 ? (0, Z5.jsxs)(Z5.Fragment, { children: [(0, Z5.jsx)(Ef2, { as: `p`, color: `red`, size: `sm`, children: a3({ id: `DGFoI3`, values: { 0: l5.length } }) }), (0, Z5.jsx)(`ul`, { "aria-label": a3({ id: `jfSsZr` }), ...Ge3, children: l5.map(lt2) })] }) : null, t2[12] = a3, t2[13] = l5, t2[14] = g5) : g5 = t2[14]; + let _5; + t2[15] !== p4 || t2[16] !== m3 || t2[17] !== h4 || t2[18] !== g5 ? (_5 = (0, Z5.jsx)(_, { children: (0, Z5.jsxs)(`div`, { ...d3, children: [p4, m3, h4, g5] }) }), t2[15] = p4, t2[16] = m3, t2[17] = h4, t2[18] = g5, t2[19] = _5) : _5 = t2[19]; + let v5; + t2[20] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (v5 = (0, Z5.jsx)(mx, { id: `DPfwMq` }), t2[20] = v5) : v5 = t2[20]; + let y4; + t2[21] === i3 ? y4 = t2[22] : (y4 = (0, Z5.jsx)(AS, { trailing: (0, Z5.jsx)(LS, { onClick: i3, size: `lg`, type: `button`, variant: `primary`, children: v5 }) }), t2[21] = i3, t2[22] = y4); + let b2; + return t2[23] !== _5 || t2[24] !== y4 ? (b2 = (0, Z5.jsxs)(Z5.Fragment, { children: [_5, y4] }), t2[23] = _5, t2[24] = y4, t2[25] = b2) : b2 = t2[25], b2; +} +function lt2(e38) { + let { preview: t2, message: n2 } = e38; + return (0, Z5.jsx)(tt3, { row: t2, status: (0, Z5.jsx)(Ef2, { as: `span`, color: `red`, size: `xs`, children: n2 }) }, t2.row); +} +function ut2(e38) { + ut2.d = 2089; + let t2 = (0, X5.c)(23), { items: n2, cardsEnabled: r2, onClose: i3 } = e38, { _: a3 } = fx(), o3 = v_2(), s3; t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = [], t2[0] = s3) : s3 = t2[0]; - let c2 = (0, Y3.useRef)(s3), l4; - t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l4 = [], t2[1] = l4) : l4 = t2[1]; - let d3 = (0, Y3.useRef)(l4), f4 = (0, Y3.useRef)(null), p4; - t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = { kind: `pick`, error: null }, t2[2] = p4) : p4 = t2[2]; - let [m3, h3] = (0, Y3.useState)(p4), g3; - t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g3 = () => { - c2.current = [], d3.current = []; - }, t2[3] = g3) : g3 = t2[3]; - let _2 = g3, v3; - t2[4] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (v3 = (e10) => { - let t3 = e10.rows.flatMap(st2); - c2.current = t3.map(ot2), d3.current = t3.map(at4), h3({ kind: `preview`, format: e10.format, rows: e10.rows.map(it3) }); - }, t2[4] = v3) : v3 = t2[4]; - let y3 = v3, b3; - t2[5] === o3 ? b3 = t2[6] : (b3 = async (e10) => { - let t3 = c2.current, n3 = d3.current; - _2(); + let c3 = (0, Y5.useRef)(s3), l5; + t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = [], t2[1] = l5) : l5 = t2[1]; + let u3 = (0, Y5.useRef)(l5), d3 = (0, Y5.useRef)(null), f4; + t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f4 = { kind: `pick`, error: null }, t2[2] = f4) : f4 = t2[2]; + let [p4, m3] = (0, Y5.useState)(f4), h4; + t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h4 = () => { + c3.current = [], u3.current = []; + }, t2[3] = h4) : h4 = t2[3]; + let g5 = h4, _5; + t2[4] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (_5 = (e39) => { + let t3 = e39.rows.flatMap(gt2); + c3.current = t3.map(ht3), u3.current = t3.map(mt4), m3({ kind: `preview`, format: e39.format, rows: e39.rows.map(pt3) }); + }, t2[4] = _5) : _5 = t2[4]; + let v5 = _5, y4; + t2[5] === o3 ? y4 = t2[6] : (y4 = async (e39) => { + let t3 = c3.current, n3 = u3.current; + g5(); let r3 = new AbortController(); - f4.current = r3; - let i4 = 0, a4 = 0, s4 = 0, l5 = []; - h3({ kind: `importing`, done: 0, total: t3.length }); - let u3 = await o3.importItems(t3, { signal: r3.signal, onSettled: (e11) => { + d3.current = r3; + let i4 = 0, a4 = 0, s4 = 0, l6 = []; + m3({ kind: `importing`, done: 0, total: t3.length }); + let f5 = await o3.importItems(t3, { signal: r3.signal, onSettled: (e40) => { let r4 = t3[i4], o4 = n3[i4]; - i4 += 1, e11.kind === `imported` ? r4?.kind === `card` ? s4 += 1 : a4 += 1 : o4 !== void 0 && l5.push({ preview: o4, message: e11.message }), h3({ kind: `importing`, done: i4, total: t3.length }); - } }).then(rt3, nt4); - f4.current = null, h3({ kind: `summary`, logins: a4, cards: s4, duplicates: e10, failures: l5, stoppedEarly: u3 || i4 < t3.length }); - }, t2[5] = o3, t2[6] = b3); - let x3 = b3, S3; - t2[7] === i3 ? S3 = t2[8] : (S3 = () => { - f4.current?.abort(), _2(), i3(); - }, t2[7] = i3, t2[8] = S3); - let C2 = S3, w3; - t2[9] !== r2 || t2[10] !== C2 || t2[11] !== m3 || t2[12] !== x3 ? (w3 = (e10) => m3.kind === `pick` || m3.kind === `preview` ? (0, Q2.jsx)(Je3, { cardsEnabled: r2, existing: e10, onClose: C2, onError: (e11) => { - _2(), h3({ kind: `pick`, error: e11 }); - }, onImport: (e11) => void x3(e11), onPlanned: y3, phase: m3 }) : null, t2[9] = r2, t2[10] = C2, t2[11] = m3, t2[12] = x3, t2[13] = w3) : w3 = t2[13]; - let T3 = w3, E3; - if (t2[14] !== a3 || t2[15] !== C2 || t2[16] !== n2 || t2[17] !== m3 || t2[18] !== T3) { - let e10 = () => m3.kind === `importing` ? (0, Q2.jsx)(Qe3, { done: m3.done, onStop: () => f4.current?.abort(), total: m3.total }) : m3.kind === `summary` ? (0, Q2.jsx)($e3, { onClose: C2, summary: m3 }) : n2.panel({ empty: T3([]), value: T3 }), r3; - t2[20] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r3 = (0, Q2.jsx)(tC, { "aria-hidden": true, name: `lock`, size: `sm` }), t2[20] = r3) : r3 = t2[20]; + i4 += 1, e40.kind === `imported` ? r4?.kind === `card` ? s4 += 1 : a4 += 1 : o4 !== void 0 && l6.push({ preview: o4, message: e40.message }), m3({ kind: `importing`, done: i4, total: t3.length }); + } }).then(ft2, dt2); + d3.current = null, m3({ kind: `summary`, logins: a4, cards: s4, duplicates: e39, failures: l6, stoppedEarly: f5 || i4 < t3.length }); + }, t2[5] = o3, t2[6] = y4); + let x2 = y4, S2; + t2[7] === i3 ? S2 = t2[8] : (S2 = () => { + d3.current?.abort(), g5(), i3(); + }, t2[7] = i3, t2[8] = S2); + let C2 = S2, w2; + t2[9] !== r2 || t2[10] !== C2 || t2[11] !== p4 || t2[12] !== x2 ? (w2 = (e39) => p4.kind === `pick` || p4.kind === `preview` ? (0, Z5.jsx)(rt4, { cardsEnabled: r2, existing: e39, onClose: C2, onError: (e40) => { + g5(), m3({ kind: `pick`, error: e40 }); + }, onImport: (e40) => void x2(e40), onPlanned: v5, phase: p4 }) : null, t2[9] = r2, t2[10] = C2, t2[11] = p4, t2[12] = x2, t2[13] = w2) : w2 = t2[13]; + let T2 = w2, E2; + if (t2[14] !== a3 || t2[15] !== C2 || t2[16] !== n2 || t2[17] !== p4 || t2[18] !== T2) { + let e39 = () => p4.kind === `importing` ? (0, Z5.jsx)(st2, { done: p4.done, onStop: () => d3.current?.abort(), total: p4.total }) : p4.kind === `summary` ? (0, Z5.jsx)(ct2, { onClose: C2, summary: p4 }) : n2.panel({ empty: T2([]), value: T2 }), r3; + t2[20] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r3 = (0, Z5.jsx)(aS, { "aria-hidden": true, name: `lock`, size: `sm` }), t2[20] = r3) : r3 = t2[20]; let i4; - t2[21] === a3 ? i4 = t2[22] : (i4 = a3({ id: `jJOolg` }), t2[21] = a3, t2[22] = i4), E3 = (0, Q2.jsx)(U3, { icon: r3, onClose: C2, title: i4, titleInTitlebar: true, width: 520, children: e10() }), t2[14] = a3, t2[15] = C2, t2[16] = n2, t2[17] = m3, t2[18] = T3, t2[19] = E3; - } else E3 = t2[19]; - return E3; + t2[21] === a3 ? i4 = t2[22] : (i4 = a3({ id: `jJOolg` }), t2[21] = a3, t2[22] = i4), E2 = (0, Z5.jsx)(v2, { icon: r3, onClose: C2, title: i4, titleInTitlebar: true, width: 520, children: e39() }), t2[14] = a3, t2[15] = C2, t2[16] = n2, t2[17] = p4, t2[18] = T2, t2[19] = E2; + } else E2 = t2[19]; + return E2; } -function nt4() { +function dt2() { return true; } -function rt3() { +function ft2() { return false; } -function it3(e9) { - return e9.preview; +function pt3(e38) { + return e38.preview; +} +function mt4(e38) { + return e38.preview; +} +function ht3(e38) { + return e38.item; +} +function gt2(e38) { + return e38.item === null ? [] : [{ item: e38.item, preview: e38.preview }]; +} +var _t2 = { image: { k1xSpc: `sand-1lliihq`, kfzvcC: `sand-47corl`, kfSwDN: `sand-87ps6o`, $$css: true }, tileMark: { kzqmXN: `sand-6jxa94`, kZKoxP: `sand-1v9usgg`, kVIFPx: `sand-19kjcj4`, $$css: true }, inputImage: { kzqmXN: `sand-1kky2od`, kZKoxP: `sand-lup9mm`, kVIFPx: `sand-19kjcj4`, $$css: true }, inverted: { ku685b: `sand-1dftt0s`, $$css: true } }; +function vt2(e38) { + return /^[a-z0-9-]+(\.[a-z0-9-]+)*\.[a-z][a-z0-9-]+$/.test(e38); +} +function yt3(e38) { + yt3.d = 2135; + let t2 = (0, X5.c)(2), { variant: n2 } = e38, r2 = n2 === `tile` ? `md` : `lg`, i3; + return t2[0] === r2 ? i3 = t2[1] : (i3 = (0, Z5.jsx)(aS, { "aria-hidden": true, name: `key`, size: r2 }), t2[0] = r2, t2[1] = i3), i3; +} +function bt3(e38) { + bt3.d = 2136; + let t2 = (0, X5.c)(5), { src: n2, imageStyle: r2 } = e38, i3; + t2[0] === r2 ? i3 = t2[1] : (i3 = h(_t2.image, r2), t2[0] = r2, t2[1] = i3); + let a3; + return t2[2] !== n2 || t2[3] !== i3 ? (a3 = (0, Z5.jsx)(`img`, { alt: ``, "aria-hidden": true, draggable: false, src: n2, ...i3 }), t2[2] = n2, t2[3] = i3, t2[4] = a3) : a3 = t2[4], a3; +} +function xt2(e38) { + xt2.d = 2133; + let t2 = (0, X5.c)(9), { src: n2, variant: r2 } = e38, i3 = df2().resolved === `dark`, a3 = r2 === `tile` ? _t2.tileMark : _t2.inputImage, o3; + t2[0] !== i3 || t2[1] !== n2 ? (o3 = i3 && Zx(n2) && _t2.inverted, t2[0] = i3, t2[1] = n2, t2[2] = o3) : o3 = t2[2]; + let s3; + t2[3] !== a3 || t2[4] !== o3 ? (s3 = [a3, o3], t2[3] = a3, t2[4] = o3, t2[5] = s3) : s3 = t2[5]; + let c3; + return t2[6] !== n2 || t2[7] !== s3 ? (c3 = (0, Z5.jsx)(bt3, { imageStyle: s3, src: n2 }), t2[6] = n2, t2[7] = s3, t2[8] = c3) : c3 = t2[8], c3; +} +function St3(e38) { + St3.d = 2134; + let t2 = (0, X5.c)(11), { host: n2, variant: r2 } = e38, i3 = `https://${n2}`, a3; + t2[0] === i3 ? a3 = t2[1] : (a3 = Mbt(i3), t2[0] = i3, t2[1] = a3); + let o3 = a3, [s3, c3] = (0, Y5.useState)(false); + if (o3 == null || s3) { + let e39; + return t2[2] === r2 ? e39 = t2[3] : (e39 = (0, Z5.jsx)(yt3, { variant: r2 }), t2[2] = r2, t2[3] = e39), e39; + } + let l5, u3; + t2[4] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = () => c3(true), u3 = (e39) => { + let { naturalWidth: t3, naturalHeight: n3 } = e39.currentTarget; + (t3 <= 1 || n3 <= 1) && c3(true); + }, t2[4] = l5, t2[5] = u3) : (l5 = t2[4], u3 = t2[5]); + let d3; + t2[6] === r2 ? d3 = t2[7] : (d3 = { 0: { className: `sand-1lliihq sand-47corl sand-87ps6o sand-1kky2od sand-lup9mm sand-19kjcj4` }, 1: { className: `sand-1lliihq sand-47corl sand-87ps6o sand-h8yej3 sand-5yr21d sand-l1xv1r` } }[(r2 === `tile`) << 0], t2[6] = r2, t2[7] = d3); + let f4; + return t2[8] !== o3 || t2[9] !== d3 ? (f4 = (0, Z5.jsx)(`img`, { alt: ``, "aria-hidden": true, draggable: false, onError: l5, onLoad: u3, src: o3, ...d3 }), t2[8] = o3, t2[9] = d3, t2[10] = f4) : f4 = t2[10], f4; +} +function Ct2(e38) { + Ct2.d = 2137; + let t2 = (0, X5.c)(10), { host: n2, variant: r2 } = e38; + if (n2 == null || !vt2(n2)) { + let e39; + return t2[0] === r2 ? e39 = t2[1] : (e39 = (0, Z5.jsx)(yt3, { variant: r2 }), t2[0] = r2, t2[1] = e39), e39; + } + let i3; + t2[2] === n2 ? i3 = t2[3] : (i3 = Xx(n2), t2[2] = n2, t2[3] = i3); + let a3 = i3; + if (a3 != null) { + let e39; + return t2[4] !== a3 || t2[5] !== r2 ? (e39 = (0, Z5.jsx)(xt2, { src: a3, variant: r2 }), t2[4] = a3, t2[5] = r2, t2[6] = e39) : e39 = t2[6], e39; + } + let o3; + return t2[7] !== n2 || t2[8] !== r2 ? (o3 = (0, Z5.jsx)(St3, { host: n2, variant: r2 }, n2), t2[7] = n2, t2[8] = r2, t2[9] = o3) : o3 = t2[9], o3; +} +function wt2(e38) { + wt2.d = 2138; + let t2 = (0, X5.c)(8), { host: n2, variant: r2 } = e38, i3; + t2[0] === r2 ? i3 = t2[1] : (i3 = { 0: { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-1kky2od sand-lup9mm sand-b3r6kr sand-1i6gnc1 sand-1o0liin` }, 1: { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-9f619 sand-vy4d1p sand-xk0z11 sand-b3r6kr sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-t9pb60 sand-10e981r sand-1o0liin` } }[(r2 === `tile`) << 0], t2[0] = r2, t2[1] = i3); + let a3; + t2[2] !== n2 || t2[3] !== r2 ? (a3 = (0, Z5.jsx)(Ct2, { host: n2, variant: r2 }), t2[2] = n2, t2[3] = r2, t2[4] = a3) : a3 = t2[4]; + let o3; + return t2[5] !== i3 || t2[6] !== a3 ? (o3 = (0, Z5.jsx)(`span`, { "aria-hidden": true, ...i3, children: a3 }), t2[5] = i3, t2[6] = a3, t2[7] = o3) : o3 = t2[7], o3; +} +var Tt2 = 420; +var Et2 = `\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022`; +var Q5 = { surface: { kVQacm: `sand-b3r6kr`, kMzoRj: `sand-c342km`, ksu8eU: `sand-ng3xce`, kaIpWk: `sand-ixl9f9`, kWkggS: `sand-10e981r`, kGVxlE: `sand-w5uq4s`, kMwMTN: `sand-tyxrsu`, $$css: true }, title: { kzQI83: `sand-1iyjqo2`, k7Eaqz: `sand-euugli`, kogj98: `sand-1ghz6dp`, kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, khDVqt: `sand-uxw1ft`, $$css: true }, iconButton: { kMwMTN: `sand-1o0liin`, $$css: true }, label: { kMwMTN: `sand-1o0liin`, $$css: true }, inputFrame: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-167g77z`, kB7OPa: `sand-9f619`, kZKoxP: `sand-10w6t97`, k7Eaqz: `sand-euugli`, kg3NbH: `sand-1q4txso`, kMzoRj: `sand-mkeg23`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-17tbahu sand-12mhxhr`, kMeerF: `sand-t08umf`, k3XXqK: `sand-1t137rt sand-nnj0qo`, kjBf7l: `sand-1v39l1b`, kInvED: `sand-1g40iwv`, kaIpWk: `sand-1t6ttyj`, kWkggS: `sand-10e981r`, $$css: true }, inputFrameWithIcon: { kZCmMZ: `sand-mzvs34`, $$css: true }, helper: { kogj98: `sand-1ghz6dp`, kg3NbH: `sand-fn1xvj`, kMwMTN: `sand-1o0liin`, kHjlTd: `sand-j0a0fe`, $$css: true }, detailTerm: { kmuXW: `sand-2lah0s`, kzqmXN: `sand-jzaux3`, kMwMTN: `sand-1o0liin`, $$css: true }, detailValue: { kzQI83: `sand-1iyjqo2`, k7Eaqz: `sand-euugli`, kogj98: `sand-1ghz6dp`, kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, khDVqt: `sand-uxw1ft`, $$css: true }, detailValueWrap: { khDVqt: `sand-126k92a`, kHjlTd: `sand-j0a0fe`, $$css: true }, body: { kogj98: `sand-1ghz6dp`, kMwMTN: `sand-1o0liin`, kHjlTd: `sand-j0a0fe`, $$css: true }, error: { kzQI83: `sand-1iyjqo2`, k7Eaqz: `sand-euugli`, kogj98: `sand-1ghz6dp`, kMwMTN: `sand-i69oq4`, $$css: true }, removeInDetail: { kWkggS: `sand-fwqdrz sand-19jy9ex sand-1g6zli8`, $$css: true } }; +function Dt3(e38) { + let t2 = e38.trim(); + if (t2.length === 0) return null; + let n2 = URL.parse(t2.includes(`://`) ? t2 : `https://${t2}`)?.hostname; + return n2 == null || n2.length === 0 ? null : n2.toLowerCase().replace(/^www\./, ``); +} +function Ot3(e38) { + return e38.split(/\s+/).map((e39) => e39.replace(/,+$/, ``)).filter((e39) => e39.length > 0); +} +function kt3(e38) { + let t2 = e38[0]; + return t2 === void 0 ? null : Dt3(t2); +} +function At2(e38) { + let t2 = URL.parse(e38.includes(`://`) ? e38 : `https://${e38}`); + return t2 != null && (t2.protocol === `https:` || t2.protocol === `http:`) ? t2.href : null; +} +function jt2(e38) { + return kt3(e38.sites); +} +function Mt3(e38) { + return jt2(e38) ?? e38.title; +} +function Nt2(e38) { + Nt2.d = 2109; + let t2 = (0, X5.c)(15), { leading: n2, title: r2, hasClose: i3, isBusy: a3, initialFocus: o3, onClose: s3, children: c3 } = e38, l5 = i3 === void 0 || i3, u3 = a3 !== void 0 && a3, d3; + t2[0] === o3 ? d3 = t2[1] : (d3 = o3 == null ? {} : { initialFocus: o3 }, t2[0] = o3, t2[1] = d3); + let p4; + t2[2] !== u3 || t2[3] !== s3 ? (p4 = (e39) => { + !e39 && !u3 && s3(); + }, t2[2] = u3, t2[3] = s3, t2[4] = p4) : p4 = t2[4]; + let m3 = l5 && !u3, h4; + t2[5] !== n2 || t2[6] !== s3 || t2[7] !== m3 || t2[8] !== r2 ? (h4 = (0, Z5.jsx)(Pt3, { hasClose: m3, leading: n2, onClose: s3, title: r2 }), t2[5] = n2, t2[6] = s3, t2[7] = m3, t2[8] = r2, t2[9] = h4) : h4 = t2[9]; + let g5; + return t2[10] !== c3 || t2[11] !== d3 || t2[12] !== p4 || t2[13] !== h4 ? (g5 = (0, Z5.jsxs)(CC.Root, { ...d3, onOpenChange: p4, open: true, surfaceStyle: Q5.surface, width: Tt2, children: [h4, c3] }), t2[10] = c3, t2[11] = d3, t2[12] = p4, t2[13] = h4, t2[14] = g5) : g5 = t2[14], g5; +} +function Pt3(e38) { + Pt3.d = 2114; + let t2 = (0, X5.c)(13), { leading: r2, title: i3, hasClose: a3, onClose: o3 } = e38, { _: s3 } = fx(), { titleId: c3 } = Gp2(), l5; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = { className: `sand-78zum5 sand-6s0dn4 sand-167g77z sand-euugli sand-10dr8xq sand-f7dkkf sand-pdmqnj` }, t2[0] = l5) : l5 = t2[0]; + let u3; + t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u3 = h(Jb2.body1, Yb2.semibold, Q5.title), t2[1] = u3) : u3 = t2[1]; + let d3; + t2[2] !== i3 || t2[3] !== c3 ? (d3 = (0, Z5.jsx)(`h2`, { id: c3, ...u3, children: i3 }), t2[2] = i3, t2[3] = c3, t2[4] = d3) : d3 = t2[4]; + let f4; + t2[5] !== s3 || t2[6] !== a3 || t2[7] !== o3 ? (f4 = a3 ? (0, Z5.jsx)(uS, { "aria-label": s3({ id: `cu6iol` }), icon: `close`, iconSize: `lg`, onClick: o3, shape: `square`, size: `sm`, style: Q5.iconButton, variant: `ghost` }) : null, t2[5] = s3, t2[6] = a3, t2[7] = o3, t2[8] = f4) : f4 = t2[8]; + let p4; + return t2[9] !== r2 || t2[10] !== d3 || t2[11] !== f4 ? (p4 = (0, Z5.jsxs)(`div`, { ...l5, children: [r2, d3, f4] }), t2[9] = r2, t2[10] = d3, t2[11] = f4, t2[12] = p4) : p4 = t2[12], p4; +} +function Ft2(e38) { + Ft2.d = 2111; + let t2 = (0, X5.c)(2), { error: n2 } = e38, r2; + return t2[0] === n2 ? r2 = t2[1] : (r2 = n2 === null ? null : (0, Z5.jsx)(`p`, { role: `alert`, ...h(Jb2.caption, Q5.error), children: n2 }), t2[0] = n2, t2[1] = r2), r2; +} +function It3() { + let e38 = (0, X5.c)(4), [t2, n2] = (0, Y5.useState)(null), [r2, i3] = (0, Y5.useState)(false), a3 = (0, Y5.useRef)(false), o3; + e38[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (o3 = async (e39, t3) => { + if (a3.current) return false; + a3.current = true, n2(null), i3(true); + let r3 = await e39().then(Lt3, (e40) => (n2(aye(e40) ?? t3), false)); + return a3.current = false, i3(false), r3; + }, e38[0] = o3) : o3 = e38[0]; + let s3 = o3, c3; + return e38[1] !== t2 || e38[2] !== r2 ? (c3 = { error: t2, isSaving: r2, run: s3 }, e38[1] = t2, e38[2] = r2, e38[3] = c3) : c3 = e38[3], c3; +} +function Lt3() { + return true; +} +function Rt3(e38) { + Rt3.d = 2106; + let t2 = (0, X5.c)(10), { term: n2, children: r2, trailing: i3 } = e38, a3, o3; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (a3 = { className: `sand-78zum5 sand-1pha0wt sand-1v2ro7d sand-9f619 sand-euugli sand-kd4jle sand-p59q4u sand-1g0dm76 sand-f159sx sand-1hkp6id sand-1t1lzn6 sand-1q0q8m5 sand-1vu50b0` }, o3 = h(Jb2.caption, Q5.detailTerm), t2[0] = a3, t2[1] = o3) : (a3 = t2[0], o3 = t2[1]); + let s3; + t2[2] === n2 ? s3 = t2[3] : (s3 = (0, Z5.jsx)(`dt`, { ...o3, children: n2 }), t2[2] = n2, t2[3] = s3); + let c3; + t2[4] === i3 ? c3 = t2[5] : (c3 = i3 == null ? null : (0, Z5.jsx)(`span`, { className: `sand-78zum5 sand-amitd3 sand-2lah0s sand-3tgyqv`, children: i3 }), t2[4] = i3, t2[5] = c3); + let l5; + return t2[6] !== r2 || t2[7] !== s3 || t2[8] !== c3 ? (l5 = (0, Z5.jsxs)(`div`, { ...a3, children: [s3, r2, c3] }), t2[6] = r2, t2[7] = s3, t2[8] = c3, t2[9] = l5) : l5 = t2[9], l5; +} +function zt3(e38) { + zt3.d = 2108; + let t2 = (0, X5.c)(78), { credential: n2, onEdit: r2, onRemove: i3, onClose: a3 } = e38, { _: o3 } = fx(), s3 = Md2(), c3, d3, f4, p4, m3, h4, g5, v5, y4, b2, x2; + if (t2[0] !== o3 || t2[1] !== n2 || t2[2] !== a3 || t2[3] !== s3) { + f4 = Mt3(n2); + let e39; + t2[15] === n2 ? e39 = t2[16] : (e39 = jt2(n2), t2[15] = n2, t2[16] = e39); + let r3 = e39, i4 = n2.sites[0], l5; + t2[17] === i4 ? l5 = t2[18] : (l5 = i4 === void 0 ? null : At2(i4), t2[17] = i4, t2[18] = l5); + let _5 = l5, S3; + t2[19] === n2.sites ? S3 = t2[20] : (S3 = new Intl.ListFormat(YE(), { style: `short`, type: `unit` }).format(n2.sites.map(Bt3)), t2[19] = n2.sites, t2[20] = S3), x2 = S3, d3 = Nt2, t2[21] === r3 ? v5 = t2[22] : (v5 = (0, Z5.jsx)(wt2, { host: r3, variant: `tile` }), t2[21] = r3, t2[22] = v5), y4 = a3, b2 = f4, t2[23] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g5 = { className: `sand-78zum5 sand-dt5ytf sand-1v2ro7d sand-euugli sand-1iorvi4 sand-10b6aqq sand-1hr3lfm` }, h4 = { className: `sand-78zum5 sand-dt5ytf sand-euugli sand-1ghz6dp sand-b3r6kr sand-mkeg23 sand-1y0btm7 sand-17tbahu sand-1t6ttyj` }, t2[23] = h4, t2[24] = g5) : (h4 = t2[23], g5 = t2[24]), c3 = Rt3, t2[25] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = (0, Z5.jsx)(mx, { id: `On0aF2` }), t2[25] = p4) : p4 = t2[25], m3 = _5 === null ? null : (0, Z5.jsx)(uS, { "aria-label": o3({ id: `dz9oyW`, values: { domain: f4 } }), icon: `arrow-right-up`, iconSize: `lg`, onClick: () => void s3(_5), shape: `square`, size: `sm`, style: Q5.iconButton, variant: `ghost` }), t2[0] = o3, t2[1] = n2, t2[2] = a3, t2[3] = s3, t2[4] = c3, t2[5] = d3, t2[6] = f4, t2[7] = p4, t2[8] = m3, t2[9] = h4, t2[10] = g5, t2[11] = v5, t2[12] = y4, t2[13] = b2, t2[14] = x2; + } else c3 = t2[4], d3 = t2[5], f4 = t2[6], p4 = t2[7], m3 = t2[8], h4 = t2[9], g5 = t2[10], v5 = t2[11], y4 = t2[12], b2 = t2[13], x2 = t2[14]; + let S2; + t2[26] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (S2 = h(Jb2.body1, Q5.detailValue), t2[26] = S2) : S2 = t2[26]; + let C2 = x2.length === 0 ? f4 : x2, w2; + t2[27] === C2 ? w2 = t2[28] : (w2 = (0, Z5.jsx)(`dd`, { ...S2, children: C2 }), t2[27] = C2, t2[28] = w2); + let T2; + t2[29] !== c3 || t2[30] !== p4 || t2[31] !== w2 || t2[32] !== m3 ? (T2 = (0, Z5.jsx)(c3, { term: p4, trailing: m3, children: w2 }), t2[29] = c3, t2[30] = p4, t2[31] = w2, t2[32] = m3, t2[33] = T2) : T2 = t2[33]; + let D2; + t2[34] === n2.username ? D2 = t2[35] : (D2 = n2.username.length === 0 ? null : (0, Z5.jsx)(Rt3, { term: (0, Z5.jsx)(mx, { id: `7sNhEz` }), children: (0, Z5.jsx)(`dd`, { ...h(Jb2.body1, Q5.detailValue), children: n2.username }) }), t2[34] = n2.username, t2[35] = D2); + let O2; + t2[36] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (O2 = (0, Z5.jsx)(mx, { id: `8ZsakT` }), t2[36] = O2) : O2 = t2[36]; + let k2; + t2[37] === o3 ? k2 = t2[38] : (k2 = o3({ id: `HQJ8BO` }), t2[37] = o3, t2[38] = k2); + let A2; + t2[39] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (A2 = { className: `sand-1iyjqo2 sand-euugli sand-1ghz6dp sand-b3r6kr sand-lyipyv sand-uxw1ft` }, t2[39] = A2) : A2 = t2[39]; + let j2; + t2[40] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (j2 = (0, Z5.jsx)(`span`, { "aria-hidden": true, className: `sand-mpsg8l sand-1jvydc1 sand-1fc57z9 sand-12oo3zp`, children: Et2 }), t2[40] = j2) : j2 = t2[40]; + let M2; + t2[41] === k2 ? M2 = t2[42] : (M2 = (0, Z5.jsx)(Rt3, { term: O2, children: (0, Z5.jsx)(`dd`, { "aria-label": k2, ...A2, children: j2 }) }), t2[41] = k2, t2[42] = M2); + let N3; + t2[43] === n2.notes ? N3 = t2[44] : (N3 = n2.notes.length === 0 ? null : (0, Z5.jsx)(Rt3, { term: (0, Z5.jsx)(mx, { id: `1DBGsz` }), children: (0, Z5.jsx)(`dd`, { ...h(Jb2.body1, Q5.detailValue, Q5.detailValueWrap), children: n2.notes }) }), t2[43] = n2.notes, t2[44] = N3); + let P3; + t2[45] !== T2 || t2[46] !== D2 || t2[47] !== M2 || t2[48] !== N3 || t2[49] !== h4 ? (P3 = (0, Z5.jsxs)(`dl`, { ...h4, children: [T2, D2, M2, N3] }), t2[45] = T2, t2[46] = D2, t2[47] = M2, t2[48] = N3, t2[49] = h4, t2[50] = P3) : P3 = t2[50]; + let F2; + t2[51] !== P3 || t2[52] !== g5 ? (F2 = (0, Z5.jsx)(`div`, { ...g5, children: P3 }), t2[51] = P3, t2[52] = g5, t2[53] = F2) : F2 = t2[53]; + let L3; + t2[54] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (L3 = { className: `sand-78zum5 sand-6s0dn4 sand-13a6bvl sand-167g77z sand-euugli sand-889kno sand-1hr3lfm sand-1l90r2v` }, t2[54] = L3) : L3 = t2[54]; + let R3; + t2[55] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (R3 = (0, Z5.jsx)(mx, { id: `t/YqKh` }), t2[55] = R3) : R3 = t2[55]; + let z2; + t2[56] === i3 ? z2 = t2[57] : (z2 = (0, Z5.jsx)(LS, { onClick: i3, sentiment: `danger`, size: `lg`, style: Q5.removeInDetail, variant: `secondary`, children: R3 }), t2[56] = i3, t2[57] = z2); + let U3; + t2[58] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (U3 = { className: `sand-78zum5 sand-167g77z` }, t2[58] = U3) : U3 = t2[58]; + let W3; + t2[59] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (W3 = (0, Z5.jsx)(mx, { id: `ePK91l` }), t2[59] = W3) : W3 = t2[59]; + let G2; + t2[60] === r2 ? G2 = t2[61] : (G2 = (0, Z5.jsx)(LS, { onClick: r2, size: `lg`, variant: `secondary`, children: W3 }), t2[60] = r2, t2[61] = G2); + let K4; + t2[62] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (K4 = (0, Z5.jsx)(mx, { id: `DPfwMq` }), t2[62] = K4) : K4 = t2[62]; + let q4; + t2[63] === a3 ? q4 = t2[64] : (q4 = (0, Z5.jsx)(LS, { onClick: a3, size: `lg`, variant: `primary`, children: K4 }), t2[63] = a3, t2[64] = q4); + let J4; + t2[65] !== G2 || t2[66] !== q4 ? (J4 = (0, Z5.jsxs)(`div`, { ...U3, children: [G2, q4] }), t2[65] = G2, t2[66] = q4, t2[67] = J4) : J4 = t2[67]; + let ee2; + t2[68] !== z2 || t2[69] !== J4 ? (ee2 = (0, Z5.jsxs)(`div`, { ...L3, children: [z2, J4] }), t2[68] = z2, t2[69] = J4, t2[70] = ee2) : ee2 = t2[70]; + let te2; + return t2[71] !== d3 || t2[72] !== F2 || t2[73] !== ee2 || t2[74] !== v5 || t2[75] !== y4 || t2[76] !== b2 ? (te2 = (0, Z5.jsxs)(d3, { leading: v5, onClose: y4, title: b2, children: [F2, ee2] }), t2[71] = d3, t2[72] = F2, t2[73] = ee2, t2[74] = v5, t2[75] = y4, t2[76] = b2, t2[77] = te2) : te2 = t2[77], te2; +} +function Bt3(e38) { + return Dt3(e38) ?? e38; +} +function Vt3(e38) { + Vt3.d = 2107; + let t2 = (0, X5.c)(26), n2, r2, i3, a3; + t2[0] === e38 ? (n2 = t2[1], r2 = t2[2], i3 = t2[3], a3 = t2[4]) : ({ label: r2, isOptional: a3, leading: i3, ...n2 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = r2, t2[3] = i3, t2[4] = a3); + let o3 = a3 !== void 0 && a3, s3 = (0, Y5.useId)(), c3; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (c3 = { className: `sand-78zum5 sand-dt5ytf sand-1jnr06f sand-euugli` }, t2[5] = c3) : c3 = t2[5]; + let l5; + t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = h(Jb2.caption, Q5.label), t2[6] = l5) : l5 = t2[6]; + let u3; + t2[7] === o3 ? u3 = t2[8] : (u3 = o3 ? (0, Z5.jsxs)(Z5.Fragment, { children: [` `, (0, Z5.jsx)(`span`, { className: `sand-x1phaw`, children: (0, Z5.jsx)(mx, { id: `WyGyYp` }) })] }) : null, t2[7] = o3, t2[8] = u3); + let d3; + t2[9] !== s3 || t2[10] !== r2 || t2[11] !== u3 ? (d3 = (0, Z5.jsxs)(`label`, { htmlFor: s3, ...l5, children: [r2, u3] }), t2[9] = s3, t2[10] = r2, t2[11] = u3, t2[12] = d3) : d3 = t2[12]; + let f4; + t2[13] === i3 ? f4 = t2[14] : (f4 = h(Jb2.body2, Q5.inputFrame, i3 != null && Q5.inputFrameWithIcon), t2[13] = i3, t2[14] = f4); + let p4; + t2[15] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = { className: `sand-1iyjqo2 sand-euugli sand-1ghz6dp sand-1717udv sand-ng3xce sand-1t137rt sand-jbqb8w sand-tyxrsu sand-jb2p0i sand-1gvdfu` }, t2[15] = p4) : p4 = t2[15]; + let m3; + t2[16] !== s3 || t2[17] !== n2 ? (m3 = (0, Z5.jsx)(`input`, { id: s3, spellCheck: false, ...n2, ...p4 }), t2[16] = s3, t2[17] = n2, t2[18] = m3) : m3 = t2[18]; + let h4; + t2[19] !== i3 || t2[20] !== f4 || t2[21] !== m3 ? (h4 = (0, Z5.jsxs)(`div`, { ...f4, children: [i3, m3] }), t2[19] = i3, t2[20] = f4, t2[21] = m3, t2[22] = h4) : h4 = t2[22]; + let g5; + return t2[23] !== d3 || t2[24] !== h4 ? (g5 = (0, Z5.jsxs)(`div`, { ...c3, children: [d3, h4] }), t2[23] = d3, t2[24] = h4, t2[25] = g5) : g5 = t2[25], g5; +} +function Ht4(e38) { + Ht4.d = 2112; + let t2 = (0, X5.c)(79), { editing: n2, onClose: r2, onSaved: i3 } = e38, a3 = i3 === void 0 ? r2 : i3, { _: o3 } = fx(), s3 = v_2(), [c3, l5] = (0, Y5.useState)(null), [u3, d3] = (0, Y5.useState)(null), [f4, p4] = (0, Y5.useState)(null), m3 = c3 ?? n2?.sites.join(` `) ?? ``, h4 = u3 ?? n2?.username ?? ``, g5 = f4 ?? n2?.notes ?? ``, [v5, y4] = (0, Y5.useState)(null), x2 = c3 === null ? m3 : v5 ?? n2?.sites.join(` `) ?? ``, S2 = (0, Y5.useRef)(null), C2 = (0, Y5.useRef)(null), w2 = It3(), T2 = n2 === null, E2 = Ot3(m3), D2 = kt3(E2), O2 = kt3(Ot3(x2)), k2 = E2.length > 0 && !w2.isSaving, A2; + t2[0] !== n2 || t2[1] !== D2 || t2[2] !== E2[0] ? (A2 = () => { + let e39 = D2 ?? E2[0] ?? ``; + return n2 === null || n2.title === Mt3(n2) ? e39 : n2.title; + }, t2[0] = n2, t2[1] = D2, t2[2] = E2[0], t2[3] = A2) : A2 = t2[3]; + let j2 = A2, M2; + t2[4] !== o3 || t2[5] !== k2 || t2[6] !== n2?.id || t2[7] !== T2 || t2[8] !== g5 || t2[9] !== a3 || t2[10] !== j2 || t2[11] !== E2 || t2[12] !== h4 || t2[13] !== s3 || t2[14] !== w2 ? (M2 = async (e39) => { + if (e39.preventDefault(), !k2) return; + let t3 = C2.current?.value ?? ``; + if (T2 && t3.length === 0) { + C2.current?.reportValidity(); + return; + } + await w2.run(() => s3.put({ id: n2?.id ?? ``, title: j2(), username: h4, notes: g5, sites: E2, password: t3 }), o3({ id: `QqKsGg` })) && a3(); + }, t2[4] = o3, t2[5] = k2, t2[6] = n2?.id, t2[7] = T2, t2[8] = g5, t2[9] = a3, t2[10] = j2, t2[11] = E2, t2[12] = h4, t2[13] = s3, t2[14] = w2, t2[15] = M2) : M2 = t2[15]; + let N3 = M2, P3; + if (t2[16] !== o3 || t2[17] !== n2) { + let e39 = n2 === null ? null : Mt3(n2); + P3 = o3(e39 === null ? { id: `3UUCyn` } : { id: `uvumiB`, values: { editingDomain: e39 } }), t2[16] = o3, t2[17] = n2, t2[18] = P3; + } else P3 = t2[18]; + let F2 = P3, L3 = T2 ? S2 : C2, R3 = w2.isSaving, z2; + t2[19] === N3 ? z2 = t2[20] : (z2 = (e39) => void N3(e39), t2[19] = N3, t2[20] = z2); + let U3, W3; + t2[21] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (U3 = { className: `sand-jp7ctv` }, W3 = { className: `sand-78zum5 sand-dt5ytf sand-1v2ro7d sand-euugli sand-1iorvi4 sand-10b6aqq sand-1hr3lfm` }, t2[21] = U3, t2[22] = W3) : (U3 = t2[21], W3 = t2[22]); + let G2; + t2[23] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (G2 = (0, Z5.jsx)(mx, { id: `On0aF2` }), t2[23] = G2) : G2 = t2[23]; + let K4; + t2[24] === O2 ? K4 = t2[25] : (K4 = (0, Z5.jsx)(wt2, { host: O2, variant: `input` }), t2[24] = O2, t2[25] = K4); + let q4; + t2[26] !== y4 || t2[27] !== c3 ? (q4 = () => y4(c3), t2[26] = y4, t2[27] = c3, t2[28] = q4) : q4 = t2[28]; + let J4; + t2[29] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (J4 = (e39) => l5(e39.currentTarget.value), t2[29] = J4) : J4 = t2[29]; + let ee2; + t2[30] !== m3 || t2[31] !== K4 || t2[32] !== q4 ? (ee2 = (0, Z5.jsx)(Vt3, { autoComplete: `off`, inputMode: `url`, label: G2, leading: K4, onBlur: q4, onChange: J4, placeholder: `example.com`, ref: S2, required: true, value: m3 }), t2[30] = m3, t2[31] = K4, t2[32] = q4, t2[33] = ee2) : ee2 = t2[33]; + let te2, ne3; + t2[34] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (te2 = (0, Z5.jsx)(mx, { id: `5E4MzW` }), ne3 = (e39) => d3(e39.currentTarget.value), t2[34] = te2, t2[35] = ne3) : (te2 = t2[34], ne3 = t2[35]); + let re3; + t2[36] === h4 ? re3 = t2[37] : (re3 = (0, Z5.jsx)(Vt3, { autoComplete: `username`, isOptional: true, label: te2, onChange: ne3, placeholder: `name@example.com`, value: h4 }), t2[36] = h4, t2[37] = re3); + let ie3; + t2[38] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (ie3 = (0, Z5.jsx)(mx, { id: `8ZsakT` }), t2[38] = ie3) : ie3 = t2[38]; + let ae3; + t2[39] !== o3 || t2[40] !== T2 ? (ae3 = T2 ? void 0 : o3({ id: `6SNOki` }), t2[39] = o3, t2[40] = T2, t2[41] = ae3) : ae3 = t2[41]; + let oe5; + t2[42] !== T2 || t2[43] !== ae3 ? (oe5 = (0, Z5.jsx)(Vt3, { autoComplete: `current-password`, label: ie3, placeholder: ae3, ref: C2, required: T2, type: `password` }), t2[42] = T2, t2[43] = ae3, t2[44] = oe5) : oe5 = t2[44]; + let se5, ce6; + t2[45] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (se5 = (0, Z5.jsx)(mx, { id: `1DBGsz` }), ce6 = (e39) => p4(e39.currentTarget.value), t2[45] = se5, t2[46] = ce6) : (se5 = t2[45], ce6 = t2[46]); + let le6; + t2[47] === g5 ? le6 = t2[48] : (le6 = (0, Z5.jsx)(Vt3, { autoComplete: `off`, isOptional: true, label: se5, onChange: ce6, value: g5 }), t2[47] = g5, t2[48] = le6); + let ue6; + t2[49] !== D2 || t2[50] !== T2 ? (ue6 = T2 ? (0, Z5.jsx)(`p`, { ...h(Jb2.caption, Q5.helper), children: D2 === null ? (0, Z5.jsx)(mx, { id: `P6suyj` }) : (0, Z5.jsx)(mx, { id: `aSajXj`, values: { host: D2 } }) }) : null, t2[49] = D2, t2[50] = T2, t2[51] = ue6) : ue6 = t2[51]; + let de6; + t2[52] !== ee2 || t2[53] !== re3 || t2[54] !== oe5 || t2[55] !== le6 || t2[56] !== ue6 ? (de6 = (0, Z5.jsxs)(`div`, { ...W3, children: [ee2, re3, oe5, le6, ue6] }), t2[52] = ee2, t2[53] = re3, t2[54] = oe5, t2[55] = le6, t2[56] = ue6, t2[57] = de6) : de6 = t2[57]; + let fe5; + t2[58] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (fe5 = { className: `sand-78zum5 sand-6s0dn4 sand-13a6bvl sand-167g77z sand-euugli sand-889kno sand-1hr3lfm sand-1l90r2v` }, t2[58] = fe5) : fe5 = t2[58]; + let pe5; + t2[59] === w2.error ? pe5 = t2[60] : (pe5 = (0, Z5.jsx)(Ft2, { error: w2.error }), t2[59] = w2.error, t2[60] = pe5); + let me5 = !k2, he5; + t2[61] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (he5 = (0, Z5.jsx)(mx, { id: `br7Ace` }), t2[61] = he5) : he5 = t2[61]; + let ge5; + t2[62] !== me5 || t2[63] !== w2.isSaving ? (ge5 = (0, Z5.jsx)(LS, { disabled: me5, pending: w2.isSaving, size: `lg`, type: `submit`, variant: `primary`, children: he5 }), t2[62] = me5, t2[63] = w2.isSaving, t2[64] = ge5) : ge5 = t2[64]; + let _e5; + t2[65] !== pe5 || t2[66] !== ge5 ? (_e5 = (0, Z5.jsxs)(`div`, { ...fe5, children: [pe5, ge5] }), t2[65] = pe5, t2[66] = ge5, t2[67] = _e5) : _e5 = t2[67]; + let ve5; + t2[68] !== de6 || t2[69] !== _e5 || t2[70] !== z2 || t2[71] !== F2 ? (ve5 = (0, Z5.jsxs)(`form`, { "aria-label": F2, onSubmit: z2, ...U3, children: [de6, _e5] }), t2[68] = de6, t2[69] = _e5, t2[70] = z2, t2[71] = F2, t2[72] = ve5) : ve5 = t2[72]; + let ye5; + return t2[73] !== r2 || t2[74] !== ve5 || t2[75] !== L3 || t2[76] !== F2 || t2[77] !== w2.isSaving ? (ye5 = (0, Z5.jsx)(Nt2, { initialFocus: L3, isBusy: R3, onClose: r2, title: F2, children: ve5 }), t2[73] = r2, t2[74] = ve5, t2[75] = L3, t2[76] = F2, t2[77] = w2.isSaving, t2[78] = ye5) : ye5 = t2[78], ye5; +} +function Ut3(e38) { + Ut3.d = 2113; + let t2 = (0, X5.c)(37), { credential: n2, onCancel: r2, onRemoved: i3 } = e38, { _: a3 } = fx(), o3 = v_2(), s3 = It3(), c3; + t2[0] === n2 ? c3 = t2[1] : (c3 = Mt3(n2), t2[0] = n2, t2[1] = c3); + let l5 = c3, u3 = `\u2068${n2.username.length === 0 ? l5 : `${l5} (${n2.username})`}\u2069`, d3; + t2[2] !== a3 || t2[3] !== n2.id || t2[4] !== i3 || t2[5] !== o3 || t2[6] !== s3 ? (d3 = async () => { + await s3.run(() => o3.remove(n2.id), a3({ id: `eWGcnp` })) && i3(); + }, t2[2] = a3, t2[3] = n2.id, t2[4] = i3, t2[5] = o3, t2[6] = s3, t2[7] = d3) : d3 = t2[7]; + let f4 = d3, p4 = s3.isSaving, m3; + t2[8] === a3 ? m3 = t2[9] : (m3 = a3({ id: `Yk6n1o` }), t2[8] = a3, t2[9] = m3); + let h4, g5; + t2[10] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h4 = { className: `sand-78zum5 sand-dt5ytf sand-1v2ro7d sand-euugli sand-1iorvi4 sand-10b6aqq sand-1hr3lfm` }, g5 = h(Jb2.body1, Q5.body), t2[10] = h4, t2[11] = g5) : (h4 = t2[10], g5 = t2[11]); + let v5; + t2[12] === u3 ? v5 = t2[13] : (v5 = (0, Z5.jsx)(`div`, { ...h4, children: (0, Z5.jsx)(`p`, { ...g5, children: (0, Z5.jsx)(mx, { id: `Mm9cq/`, values: { name: u3 } }) }) }), t2[12] = u3, t2[13] = v5); + let y4; + t2[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (y4 = { className: `sand-78zum5 sand-6s0dn4 sand-13a6bvl sand-167g77z sand-euugli sand-889kno sand-1hr3lfm sand-1l90r2v` }, t2[14] = y4) : y4 = t2[14]; + let x2; + t2[15] === s3.error ? x2 = t2[16] : (x2 = (0, Z5.jsx)(Ft2, { error: s3.error }), t2[15] = s3.error, t2[16] = x2); + let S2; + t2[17] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (S2 = (0, Z5.jsx)(mx, { id: `dEgA5A` }), t2[17] = S2) : S2 = t2[17]; + let C2; + t2[18] !== r2 || t2[19] !== s3.isSaving ? (C2 = (0, Z5.jsx)(LS, { disabled: s3.isSaving, onClick: r2, size: `lg`, variant: `secondary`, children: S2 }), t2[18] = r2, t2[19] = s3.isSaving, t2[20] = C2) : C2 = t2[20]; + let w2; + t2[21] === f4 ? w2 = t2[22] : (w2 = () => void f4(), t2[21] = f4, t2[22] = w2); + let T2; + t2[23] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (T2 = (0, Z5.jsx)(mx, { id: `t/YqKh` }), t2[23] = T2) : T2 = t2[23]; + let E2; + t2[24] !== w2 || t2[25] !== s3.isSaving ? (E2 = (0, Z5.jsx)(LS, { onClick: w2, pending: s3.isSaving, sentiment: `danger`, size: `lg`, variant: `primary`, children: T2 }), t2[24] = w2, t2[25] = s3.isSaving, t2[26] = E2) : E2 = t2[26]; + let D2; + t2[27] !== C2 || t2[28] !== E2 || t2[29] !== x2 ? (D2 = (0, Z5.jsxs)(`div`, { ...y4, children: [x2, C2, E2] }), t2[27] = C2, t2[28] = E2, t2[29] = x2, t2[30] = D2) : D2 = t2[30]; + let O2; + return t2[31] !== r2 || t2[32] !== D2 || t2[33] !== m3 || t2[34] !== v5 || t2[35] !== s3.isSaving ? (O2 = (0, Z5.jsxs)(Nt2, { hasClose: false, isBusy: p4, onClose: r2, title: m3, children: [v5, D2] }), t2[31] = r2, t2[32] = D2, t2[33] = m3, t2[34] = v5, t2[35] = s3.isSaving, t2[36] = O2) : O2 = t2[36], O2; +} +function Wt3(e38) { + Wt3.d = 2110; + let t2 = (0, X5.c)(13), { credential: n2, onClose: r2 } = e38, [i3, a3] = (0, Y5.useState)(`view`); + switch (i3) { + case `view`: { + let e39, i4; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = () => a3(`edit`), i4 = () => a3(`remove`), t2[0] = e39, t2[1] = i4) : (e39 = t2[0], i4 = t2[1]); + let o3; + return t2[2] !== n2 || t2[3] !== r2 ? (o3 = (0, Z5.jsx)(zt3, { credential: n2, onClose: r2, onEdit: e39, onRemove: i4 }), t2[2] = n2, t2[3] = r2, t2[4] = o3) : o3 = t2[4], o3; + } + case `edit`: { + let e39; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = () => a3(`view`), t2[5] = e39) : e39 = t2[5]; + let i4; + return t2[6] !== n2 || t2[7] !== r2 ? (i4 = (0, Z5.jsx)(Ht4, { editing: n2, onClose: e39, onSaved: r2 }), t2[6] = n2, t2[7] = r2, t2[8] = i4) : i4 = t2[8], i4; + } + case `remove`: { + let e39; + t2[9] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = () => a3(`view`), t2[9] = e39) : e39 = t2[9]; + let i4; + return t2[10] !== n2 || t2[11] !== r2 ? (i4 = (0, Z5.jsx)(Ut3, { credential: n2, onCancel: e39, onRemoved: r2 }), t2[10] = n2, t2[11] = r2, t2[12] = i4) : i4 = t2[12], i4; + } + } +} +var Gt2 = [`login`, `card`, `contact`]; +var Kt2 = { amex: `amex`, "american express": `amex`, visa: `visa`, mastercard: `mastercard`, discover: `discover` }; +function qt3(e38) { + return Kt2[e38.trim().toLowerCase()] ?? null; +} +var Jt4 = `card`; +function Yt4(e38, t2) { + let n2 = e38.brand.trim(); + return n2.length === 0 ? t2 : n2; +} +function Xt4(e38, t2, n2) { + if (e38.length === 0 || e38 === n2) return true; + let r2 = Ep3(e38.replace(/\s+/g, ``), `en`), i3 = r2.endsWith(t2.last4) ? r2.slice(0, -t2.last4.length) : null; + return i3 !== null && [Ep3(n2.replace(/\s+/g, ``), `en`), Jt4].some((e39) => i3.startsWith(e39) && /^[\u2022*]*$/u.test(i3.slice(e39.length))); +} +function Zt4(e38, t2, n2) { + let r2 = t2.nickname.trim(); + if (r2.length > 0) return r2; + let i3 = e38.title.trim(), a3 = Yt4(t2, n2); + return Xt4(i3, t2, a3) ? a3 : i3; +} +function Qt4(e38, t2) { + return [e38.title, t2.name, t2.email, t2.phone].map((e39) => e39.trim()).find((e39) => e39.length > 0) ?? ``; +} +function $t4(e38) { + return [e38.line1, e38.line2, e38.city, e38.region, e38.postalCode, e38.country].map((e39) => e39.trim()).filter((e39) => e39.length > 0).join(`, `); +} +function en4(e38) { + return e38.length === 0 ? null : { kind: `text`, text: e38 }; +} +function tn4(e38) { + let t2 = Mt3(e38), n2 = e38.username.trim(), r2 = [], i3 = e38.title.trim(); + i3.length > 0 && i3 !== t2 && r2.push([i3, { kind: `text`, text: i3 }]); + for (let t3 of e38.sites) r2.push([t3, { kind: `text`, text: t3 }]); + let a3 = e38.notes.trim(); + return a3.length > 0 && r2.push([a3, { kind: `note`, text: a3 }]), { row: { id: e38.id, kind: `login`, credential: e38, title: t2, subtitle: en4(n2) }, extras: r2 }; +} +function nn4(e38, t2, n2) { + let r2 = Zt4(e38, t2, n2), i3 = Yt4(t2, n2), a3 = i3 === r2 ? null : i3; + return { row: { id: e38.id, kind: `card`, credential: e38, title: r2, subtitle: { kind: `card`, extra: null, brand: a3, last4: t2.last4 } }, extras: [t2.holderName, e38.notes].map((e39) => e39.trim()).filter((e39) => e39.length > 0).map((e39) => [e39, { kind: `card`, extra: e39, brand: a3, last4: t2.last4 }]) }; +} +function rn3(e38, t2) { + let n2 = Qt4(e38, t2), r2 = [t2.name, t2.email, t2.phone].map((e39) => e39.trim()).find((e39) => e39.length > 0 && e39 !== n2) ?? ``, i3 = [t2.name, t2.email, t2.phone, $t4(t2)].map((e39) => e39.trim()).filter((e39) => e39.length > 0 && e39 !== n2 && e39 !== r2).map((e39) => [e39, { kind: `text`, text: e39 }]); + return { row: { id: e38.id, kind: `contact`, credential: e38, title: n2, subtitle: en4(r2) }, extras: i3 }; +} +function an3(e38, t2) { + return e38.card === void 0 ? e38.contact === void 0 ? tn4(e38) : rn3(e38, e38.contact) : nn4(e38, e38.card, t2); +} +function on2(e38) { + return e38 === null ? `` : e38.kind === `card` ? [e38.extra, e38.brand, e38.last4].filter((e39) => e39 !== null).join(` `) : e38.text; +} +function sn3(e38, t2, n2) { + let { row: r2 } = e38; + if (t2.length === 0) return r2; + let i3 = (e39) => Ep3(e39, n2).includes(t2); + if (i3(r2.title) || i3(on2(r2.subtitle))) return r2; + let a3 = e38.extras.find(([e39]) => i3(e39)); + return a3 === void 0 ? null : { ...r2, subtitle: a3[1] }; +} +var cn3 = (e38, t2) => e38.title.localeCompare(t2.title, void 0, { sensitivity: `base` }) || e38.id.localeCompare(t2.id); +function ln3(e38, { query: t2, tab: n2, locale: r2, cardLabel: i3 }) { + let a3 = Ep3(t2.trim(), r2), o3 = e38.map((e39) => sn3(an3(e39, i3), a3, r2)).filter((e39) => e39 !== null).toSorted(cn3), s3 = { all: o3.length, login: 0, card: 0, contact: 0 }; + for (let e39 of o3) s3[e39.kind] += 1; + let l5 = n2 === `all` ? o3 : o3.filter((e39) => e39.kind === n2); + return { rows: a3.length > 0 && n2 === `all` ? Gt2.flatMap((e39) => l5.filter((t3) => t3.kind === e39)) : l5, counts: s3 }; +} +function un3(e38, t2, n2) { + let r2 = Ep3(t2.trim(), n2); + if (r2.length === 0) return [{ text: e38, isMatch: false }]; + let i3 = Ep3(e38, n2); + if (i3.length !== e38.length) return [{ text: e38, isMatch: false }]; + let a3 = [], o3 = 0; + for (let t3 = i3.indexOf(r2); t3 !== -1; t3 = i3.indexOf(r2, o3)) t3 > o3 && a3.push({ text: e38.slice(o3, t3), isMatch: false }), a3.push({ text: e38.slice(t3, t3 + r2.length), isMatch: true }), o3 = t3 + r2.length; + return o3 < e38.length && a3.push({ text: e38.slice(o3), isMatch: false }), a3; +} +var $4 = { tab: { k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-17d4w8g`, kogj98: `sand-1ghz6dp`, k8WAf4: `sand-ifx94n`, kg3NbH: `sand-1awh872`, kMzoRj: `sand-c342km`, ksu8eU: `sand-ng3xce`, kaIpWk: `sand-149ho13`, kWkggS: `sand-jbqb8w sand-1sygd3j`, kMwMTN: `sand-1o0liin`, kkrTdU: `sand-1ypdohk`, khDVqt: `sand-uxw1ft`, k3XXqK: `sand-1t137rt sand-9v5kkp`, kMeerF: `sand-1de99jn`, kjBf7l: `sand-1v39l1b`, kInvED: `sand-1g40iwv`, $$css: true }, tabSelected: { kWkggS: `sand-fwqdrz sand-11hyl0l`, kMwMTN: `sand-tyxrsu`, $$css: true }, searchInput: { kzQI83: `sand-1iyjqo2`, k7Eaqz: `sand-euugli`, kogj98: `sand-1ghz6dp`, kmVPX3: `sand-1717udv`, kMzoRj: `sand-c342km`, ksu8eU: `sand-ng3xce`, k3XXqK: `sand-1t137rt`, kWkggS: `sand-jbqb8w`, kMwMTN: `sand-tyxrsu`, kMv6JI: `sand-jb2p0i`, k8Qsv1: `sand-1b0dx11`, k9l4BL: `sand-1hcrkkg`, $$css: true }, groupLabel: { kogj98: `sand-1ghz6dp`, kg3NbH: `sand-dqyycr`, kLKAdn: `sand-889kno`, kGO01o: `sand-jkvuk6`, kMwMTN: `sand-1o0liin`, $$css: true }, groupLabelFirst: { kLKAdn: `sand-1yrsyyn`, $$css: true }, cardFace: { kB7OPa: `sand-9f619`, kVAEAm: `sand-1n2onr6`, k1xSpc: `sand-3nfvp2`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kzqmXN: `sand-1849jeq`, kZKoxP: `sand-hvdbge`, kVQacm: `sand-b3r6kr`, kMzoRj: `sand-qjedn3`, ksu8eU: `sand-1y0btm7`, kVAM5u: `sand-17tbahu`, kaIpWk: `sand-1i6gnc1`, kWkggS: `sand-fwqdrz`, kMwMTN: `sand-1o0liin`, $$css: true }, cardFaceAmex: { kWkggS: `sand-14hfbwc`, $$css: true }, cardFaceLogoOnWhite: { kWkggS: `sand-83z2og`, $$css: true }, cardLogo: { k1xSpc: `sand-1lliihq`, kmuXW: `sand-2lah0s`, $$css: true }, cardLogoAmex: { kzqmXN: `sand-1kky2od`, kZKoxP: `sand-1ta3ar0`, $$css: true }, cardLogoDiscover: { kzqmXN: `sand-w4jnvo`, kZKoxP: `sand-1ycjhwn`, $$css: true }, cardLogoMastercard: { kzqmXN: `sand-1kky2od`, kZKoxP: `sand-6w4g8m`, $$css: true }, cardLogoVisa: { kzqmXN: `sand-1xp8n7a`, kZKoxP: `sand-1hagigm`, $$css: true }, title: { kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, khDVqt: `sand-uxw1ft`, $$css: true }, subtitle: { kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, khDVqt: `sand-uxw1ft`, kMwMTN: `sand-1o0liin`, $$css: true }, match: { kWkggS: `sand-jbqb8w`, kMwMTN: `sand-10kc733`, $$css: true }, chevron: { kmuXW: `sand-2lah0s`, kMwMTN: `sand-169k319`, $$css: true }, footer: { kogj98: `sand-1ghz6dp`, kZCmMZ: `sand-mzvs34`, kwRFfy: `sand-11lfxj5`, kMwMTN: `sand-169k319`, $$css: true }, message: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kjj79g: `sand-l56j7k`, kAzted: `sand-uxxueq`, kogj98: `sand-1ghz6dp`, kg3NbH: `sand-1hr3lfm`, kMwMTN: `sand-1o0liin`, k9WMMc: `sand-2b8uid`, $$css: true } }; +var dn3 = { login: { id: `NLLW52` }, card: { id: `Ccpbzh` }, contact: { id: `OBRLoG` } }; +var fn4 = { all: { id: `5a1TO9` }, login: { id: `mx2Qib` }, card: { id: `1A2dM9` }, contact: { id: `Fjs6To` } }; +var pn3 = { amex: $4.cardLogoAmex, visa: $4.cardLogoVisa, mastercard: $4.cardLogoMastercard, discover: $4.cardLogoDiscover }; +function mn3(e38, t2) { + return e38 === `amex` ? $4.cardFaceAmex : e38 === `discover` && t2 ? $4.cardFaceLogoOnWhite : null; +} +function hn3(e38) { + hn3.d = 2097; + let t2 = (0, X5.c)(6), { text: n2, query: r2 } = e38, { i18n: i3 } = fx(), a3; + t2[0] !== i3.locale || t2[1] !== r2 || t2[2] !== n2 ? (a3 = un3(n2, r2, i3.locale || `en`).map(gn3), t2[0] = i3.locale, t2[1] = r2, t2[2] = n2, t2[3] = a3) : a3 = t2[3]; + let o3; + return t2[4] === a3 ? o3 = t2[5] : (o3 = (0, Z5.jsx)(Z5.Fragment, { children: a3 }), t2[4] = a3, t2[5] = o3), o3; } -function at4(e9) { - return e9.preview; +function gn3(e38, t2) { + return e38.isMatch ? (0, Z5.jsx)(`mark`, { ...h($4.match, Yb2.medium), children: e38.text }, t2) : e38.text; } -function ot2(e9) { - return e9.item; +function _n3(e38) { + _n3.d = 2095; + let t2 = (0, X5.c)(6), { brand: n2 } = e38, r2 = qt3(n2), i3 = df2().resolved === `dark`, a3 = h($4.cardFace, mn3(r2, i3)), o3; + t2[0] !== r2 || t2[1] !== i3 ? (o3 = r2 === null ? (0, Z5.jsx)(aS, { name: `credit-card`, size: `sm` }) : (0, Z5.jsx)(`img`, { alt: ``, draggable: false, src: (i3 ? de5 : ue5)[r2], ...h($4.cardLogo, pn3[r2]) }), t2[0] = r2, t2[1] = i3, t2[2] = o3) : o3 = t2[2]; + let s3; + return t2[3] !== a3 || t2[4] !== o3 ? (s3 = (0, Z5.jsx)(`span`, { ...a3, children: o3 }), t2[3] = a3, t2[4] = o3, t2[5] = s3) : s3 = t2[5], s3; } -function st2(e9) { - return e9.item === null ? [] : [{ item: e9.item, preview: e9.preview }]; +function vn3(e38) { + vn3.d = 2105; + let t2 = (0, X5.c)(3), { children: n2 } = e38, r2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { className: `sand-9f619 sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-vy4d1p sand-xk0z11 sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-t9pb60 sand-10e981r sand-1o0liin` }, t2[0] = r2) : r2 = t2[0]; + let i3; + return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, Z5.jsx)(`span`, { ...r2, children: n2 }), t2[1] = n2, t2[2] = i3), i3; } -var ct2 = { row: { k1xSpc: `sand-78zum5`, kGNEyG: `sand-6s0dn4`, kOIVth: `sand-1dbef6d`, kzqmXN: `sand-h8yej3`, kB7OPa: `sand-9f619`, kogj98: `sand-1ghz6dp`, k8WAf4: `sand-12ffz05`, kg3NbH: `sand-2f45yy`, kMwMTN: `sand-tyxrsu`, $$css: true }, secondary: { kVQacm: `sand-b3r6kr`, kg5iWk: `sand-lyipyv`, khDVqt: `sand-uxw1ft`, kMwMTN: `sand-1o0liin`, $$css: true } }; -var lt2 = { className: `sand-rvj5dj sand-cjjqqt sand-ehausa` }; -var ut2 = { className: `sand-rvj5dj sand-cjjqqt sand-ehausa sand-pqajaz sand-18hwk67 sand-xs79tx` }; -var dt2 = { className: `sand-78zum5 sand-dt5ytf sand-11twubx` }; -var ft2 = { className: `sand-78zum5 sand-1qjc9v5 sand-euugli sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1qmwy7c` }; -var pt = { className: `sand-1iyjqo2 sand-euugli sand-1ghz6dp sand-knfcqp sand-1awh872 sand-ng3xce sand-1qmwy7c sand-1a2a7pz sand-jbqb8w sand-jb2p0i sand-11wthnw sand-tyxrsu sand-1h7ufjq` }; -var mt2 = h(d2.option); -var ht2 = [[{ key: `line1`, label: { id: `gzEjAL` } }], [{ key: `line2`, label: { id: `cormHa` } }], [{ key: `city`, label: { id: `3wV73y` } }, { key: `region`, label: { id: `BKTGoj` } }], [{ key: `postalCode`, label: { id: `XSEMno` } }, { key: `country`, label: { id: `JNCzPW` } }]]; -function gt2(e9) { - return e9.split(/\s+/).map((e10) => e10.replace(/,+$/, ``)).filter((e10) => e10.length > 0); +function yn3(e38) { + yn3.d = 2100; + let t2 = (0, X5.c)(7), { row: n2 } = e38, { card: r2 } = n2.credential; + if (r2 !== void 0) { + let e39; + return t2[0] === r2.brand ? e39 = t2[1] : (e39 = (0, Z5.jsx)(_n3, { brand: r2.brand }), t2[0] = r2.brand, t2[1] = e39), e39; + } + if (n2.kind === `login`) { + let e39; + t2[2] === n2.credential ? e39 = t2[3] : (e39 = jt2(n2.credential), t2[2] = n2.credential, t2[3] = e39); + let r3; + return t2[4] === e39 ? r3 = t2[5] : (r3 = (0, Z5.jsx)(wt2, { host: e39, variant: `tile` }), t2[4] = e39, t2[5] = r3), r3; + } + let i3; + return t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i3 = (0, Z5.jsx)(vn3, { children: (0, Z5.jsx)(aS, { name: `person`, size: `md` }) }), t2[6] = i3) : i3 = t2[6], i3; } -function _t2(e9) { - let t2 = e9.sites[0], n2 = t2 === void 0 ? void 0 : URL.parse(t2.includes(`://`) ? t2 : `https://${t2}`)?.hostname; - return n2 === void 0 || n2.length === 0 ? e9.title : n2.replace(/^www\./, ``); +function bn3(e38) { + bn3.d = 2099; + let t2 = (0, X5.c)(3), { row: n2 } = e38, r2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-1849jeq sand-xk0z11` }, t2[0] = r2) : r2 = t2[0]; + let i3; + return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, Z5.jsx)(`span`, { "aria-hidden": `true`, ...r2, children: (0, Z5.jsx)(yn3, { row: n2 }) }), t2[1] = n2, t2[2] = i3), i3; +} +function xn3(e38) { + xn3.d = 2102; + let t2 = (0, X5.c)(21), { subtitle: n2, query: r2 } = e38; + if (n2.kind === `text`) { + let e39; + return t2[0] !== r2 || t2[1] !== n2.text ? (e39 = (0, Z5.jsx)(hn3, { query: r2, text: n2.text }), t2[0] = r2, t2[1] = n2.text, t2[2] = e39) : e39 = t2[2], e39; + } + if (n2.kind === `note`) { + let e39; + t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = (0, Z5.jsx)(mx, { id: `ycCSuD` }), t2[3] = e39) : e39 = t2[3]; + let i4; + return t2[4] !== r2 || t2[5] !== n2.text ? (i4 = (0, Z5.jsxs)(Z5.Fragment, { children: [e39, ` `, (0, Z5.jsx)(hn3, { query: r2, text: n2.text })] }), t2[4] = r2, t2[5] = n2.text, t2[6] = i4) : i4 = t2[6], i4; + } + let i3; + t2[7] !== r2 || t2[8] !== n2.extra ? (i3 = n2.extra === null ? null : (0, Z5.jsxs)(Z5.Fragment, { children: [(0, Z5.jsx)(hn3, { query: r2, text: n2.extra }), ` \xB7 `] }), t2[7] = r2, t2[8] = n2.extra, t2[9] = i3) : i3 = t2[9]; + let a3; + t2[10] !== r2 || t2[11] !== n2.brand ? (a3 = n2.brand === null ? null : (0, Z5.jsxs)(Z5.Fragment, { children: [(0, Z5.jsx)(hn3, { query: r2, text: n2.brand }), ` `] }), t2[10] = r2, t2[11] = n2.brand, t2[12] = a3) : a3 = t2[12]; + let o3; + t2[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (o3 = { className: `sand-mpsg8l sand-y5h43f` }, t2[13] = o3) : o3 = t2[13]; + let s3; + t2[14] !== r2 || t2[15] !== n2.last4 ? (s3 = (0, Z5.jsxs)(`span`, { ...o3, children: [`\u2022\u2022\u2022\u2022 `, (0, Z5.jsx)(hn3, { query: r2, text: n2.last4 })] }), t2[14] = r2, t2[15] = n2.last4, t2[16] = s3) : s3 = t2[16]; + let c3; + return t2[17] !== i3 || t2[18] !== a3 || t2[19] !== s3 ? (c3 = (0, Z5.jsxs)(Z5.Fragment, { children: [i3, a3, s3] }), t2[17] = i3, t2[18] = a3, t2[19] = s3, t2[20] = c3) : c3 = t2[20], c3; +} +function Sn3() { + let { _: e38 } = fx(); + return (t2) => { + let { card: n2 } = t2.credential; + if (n2 !== void 0) { + let r3 = t2.title, i4 = n2.last4; + return e38({ id: `ZZ060Q`, values: { title: r3, last4: i4 } }); + } + if (t2.kind === `contact`) { + let n3 = t2.title; + return e38({ id: `ja+MfM`, values: { name: n3 } }); + } + let r2 = t2.credential.username, i3 = Mt3(t2.credential), a3 = r2.length === 0 ? i3 : `${i3} (${r2})`; + return e38({ id: `HSllT+`, values: { name: a3 } }); + }; } -function vt(e9) { - return `${String(e9.expMonth).padStart(2, `0`)}/${String(e9.expYear % 100).padStart(2, `0`)}`; +function Cn3(e38) { + Cn3.d = 2104; + let t2 = (0, X5.c)(23), { row: n2, query: r2, label: i3, onOpen: a3 } = e38, o3; + t2[0] !== a3 || t2[1] !== n2.credential ? (o3 = () => a3(n2.credential), t2[0] = a3, t2[1] = n2.credential, t2[2] = o3) : o3 = t2[2]; + let s3; + t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = { className: `sand-78zum5 sand-6s0dn4 sand-1v2ro7d sand-h8yej3 sand-9f619 sand-1ghz6dp sand-e8ttls sand-c342km sand-ng3xce sand-t9pb60 sand-jbqb8w sand-1sygd3j sand-tyxrsu sand-1yc453h sand-1ypdohk sand-1t137rt sand-9v5kkp sand-1de99jn sand-1v39l1b sand-1g40iwv` }, t2[3] = s3) : s3 = t2[3]; + let c3; + t2[4] === n2 ? c3 = t2[5] : (c3 = (0, Z5.jsx)(bn3, { row: n2 }), t2[4] = n2, t2[5] = c3); + let l5, u3; + t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = { className: `sand-78zum5 sand-dt5ytf sand-1iyjqo2 sand-euugli` }, u3 = h($4.title, Jb2.body2, Yb2.medium), t2[6] = l5, t2[7] = u3) : (l5 = t2[6], u3 = t2[7]); + let d3; + t2[8] !== r2 || t2[9] !== n2.title ? (d3 = (0, Z5.jsx)(`span`, { ...u3, children: (0, Z5.jsx)(hn3, { query: r2, text: n2.title }) }), t2[8] = r2, t2[9] = n2.title, t2[10] = d3) : d3 = t2[10]; + let f4; + t2[11] !== r2 || t2[12] !== n2.subtitle ? (f4 = n2.subtitle === null ? null : (0, Z5.jsx)(`span`, { ...h($4.subtitle, Jb2.label), children: (0, Z5.jsx)(xn3, { query: r2, subtitle: n2.subtitle }) }), t2[11] = r2, t2[12] = n2.subtitle, t2[13] = f4) : f4 = t2[13]; + let p4; + t2[14] !== d3 || t2[15] !== f4 ? (p4 = (0, Z5.jsxs)(`span`, { ...l5, children: [d3, f4] }), t2[14] = d3, t2[15] = f4, t2[16] = p4) : p4 = t2[16]; + let m3; + t2[17] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (m3 = (0, Z5.jsx)(aS, { name: `chevron-right`, size: `sm`, style: $4.chevron }), t2[17] = m3) : m3 = t2[17]; + let h4; + return t2[18] !== i3 || t2[19] !== o3 || t2[20] !== c3 || t2[21] !== p4 ? (h4 = (0, Z5.jsxs)(`button`, { "aria-label": i3, onClick: o3, type: `button`, ...s3, children: [c3, p4, m3] }), t2[18] = i3, t2[19] = o3, t2[20] = c3, t2[21] = p4, t2[22] = h4) : h4 = t2[22], h4; +} +function wn3(e38) { + wn3.d = 2101; + let t2 = (0, X5.c)(27), { query: n2, onQueryChange: r2 } = e38, { _: i3 } = fx(), a3 = (0, Y5.useRef)(null), o3 = n2.length > 0, s3; + t2[0] === o3 ? s3 = t2[1] : (s3 = { 0: { className: `sand-9f619 sand-78zum5 sand-6s0dn4 sand-2lah0s sand-17d4w8g sand-zjbwwf sand-10w6t97 sand-1pixwil sand-f159sx sand-mkeg23 sand-1y0btm7 sand-17tbahu sand-sb55g1 sand-149ho13 sand-si5pdb sand-1t137rt sand-14xc8xn sand-1de99jn sand-1v39l1b sand-1g40iwv sand-1o0liin` }, 1: { className: `sand-9f619 sand-78zum5 sand-6s0dn4 sand-2lah0s sand-17d4w8g sand-zjbwwf sand-10w6t97 sand-1pixwil sand-mkeg23 sand-1y0btm7 sand-17tbahu sand-sb55g1 sand-149ho13 sand-si5pdb sand-1t137rt sand-14xc8xn sand-1de99jn sand-1v39l1b sand-1g40iwv sand-1o0liin sand-11lfxj5` } }[!!o3 << 0], t2[0] = o3, t2[1] = s3); + let c3; + t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (c3 = (0, Z5.jsx)(aS, { name: `search`, size: `md` }), t2[2] = c3) : c3 = t2[2]; + let l5; + t2[3] === i3 ? l5 = t2[4] : (l5 = i3({ id: `R/b23j` }), t2[3] = i3, t2[4] = l5); + let u3; + t2[5] === r2 ? u3 = t2[6] : (u3 = (e39) => r2(e39.currentTarget.value), t2[5] = r2, t2[6] = u3); + let d3; + t2[7] !== o3 || t2[8] !== r2 ? (d3 = (e39) => { + e39.key === `Escape` && o3 && (e39.preventDefault(), e39.stopPropagation(), r2(``)); + }, t2[7] = o3, t2[8] = r2, t2[9] = d3) : d3 = t2[9]; + let f4; + t2[10] === i3 ? f4 = t2[11] : (f4 = i3({ id: `R/b23j` }), t2[10] = i3, t2[11] = f4); + let p4; + t2[12] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = h($4.searchInput, Jb2.body2), t2[12] = p4) : p4 = t2[12]; + let m3; + t2[13] !== n2 || t2[14] !== l5 || t2[15] !== u3 || t2[16] !== d3 || t2[17] !== f4 ? (m3 = (0, Z5.jsx)(`input`, { "aria-label": l5, autoComplete: `off`, onChange: u3, onKeyDown: d3, placeholder: f4, ref: a3, spellCheck: false, type: `search`, value: n2, ...p4 }), t2[13] = n2, t2[14] = l5, t2[15] = u3, t2[16] = d3, t2[17] = f4, t2[18] = m3) : m3 = t2[18]; + let h4; + t2[19] !== i3 || t2[20] !== o3 || t2[21] !== r2 ? (h4 = o3 ? (0, Z5.jsx)(`button`, { "aria-label": i3({ id: `V8yTm6` }), onClick: () => { + r2(``), a3.current?.focus(); + }, type: `button`, className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-1ghz6dp sand-9ms5i6 sand-c342km sand-ng3xce sand-149ho13 sand-jbqb8w sand-1sygd3j sand-1o0liin sand-1ypdohk`, children: (0, Z5.jsx)(aS, { name: `x`, size: `md` }) }) : null, t2[19] = i3, t2[20] = o3, t2[21] = r2, t2[22] = h4) : h4 = t2[22]; + let g5; + return t2[23] !== s3 || t2[24] !== m3 || t2[25] !== h4 ? (g5 = (0, Z5.jsxs)(`div`, { ...s3, children: [c3, m3, h4] }), t2[23] = s3, t2[24] = m3, t2[25] = h4, t2[26] = g5) : g5 = t2[26], g5; +} +function Tn3(e38) { + Tn3.d = 2103; + let t2 = (0, X5.c)(21), { tabs: n2, selected: r2, counts: i3, listId: a3, onSelect: o3 } = e38, { _: s3 } = fx(), c3; + t2[0] === s3 ? c3 = t2[1] : (c3 = (e39) => s3(e39 === `all` ? { id: `N40H+G` } : dn3[e39]), t2[0] = s3, t2[1] = c3); + let l5 = c3, u3; + t2[2] === s3 ? u3 = t2[3] : (u3 = s3({ id: `76H695` }), t2[2] = s3, t2[3] = u3); + let d3; + t2[4] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (d3 = { className: `sand-78zum5 sand-6s0dn4 sand-1jnr06f sand-1iyjqo2 sand-euugli` }, t2[4] = d3) : d3 = t2[4]; + let f4; + if (t2[5] !== i3 || t2[6] !== l5 || t2[7] !== a3 || t2[8] !== o3 || t2[9] !== r2 || t2[10] !== n2) { + let e39; + t2[12] !== i3 || t2[13] !== l5 || t2[14] !== a3 || t2[15] !== o3 || t2[16] !== r2 ? (e39 = (e40) => { + let t3 = e40 === r2; + return (0, Z5.jsxs)(`button`, { "aria-controls": a3, "aria-selected": t3, onClick: () => o3(e40), onFocus: () => { + t3 || o3(e40); + }, role: `tab`, tabIndex: t3 ? 0 : -1, type: `button`, ...h($4.tab, t3 && $4.tabSelected, Jb2.body2), children: [(0, Z5.jsx)(`span`, { ...h(Yb2.medium), children: l5(e40) }), (0, Z5.jsx)(`span`, { className: `sand-169k319 sand-ss6m8b`, children: i3[e40] })] }, e40); + }, t2[12] = i3, t2[13] = l5, t2[14] = a3, t2[15] = o3, t2[16] = r2, t2[17] = e39) : e39 = t2[17], f4 = n2.map(e39), t2[5] = i3, t2[6] = l5, t2[7] = a3, t2[8] = o3, t2[9] = r2, t2[10] = n2, t2[11] = f4; + } else f4 = t2[11]; + let p4; + return t2[18] !== u3 || t2[19] !== f4 ? (p4 = (0, Z5.jsx)(`div`, { "aria-label": u3, onKeyDown: NT, role: `tablist`, ...d3, children: f4 }), t2[18] = u3, t2[19] = f4, t2[20] = p4) : p4 = t2[20], p4; } -function yt() { - let e9 = (0, X3.c)(4), [t2, n2] = (0, Y3.useState)(null), [r2, i3] = (0, Y3.useState)(false), a3; - e9[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (a3 = async (e10, t3) => { +function En3(e38) { + En3.d = 2098; + let t2 = (0, X5.c)(16), { rows: n2, query: r2, showGroups: i3, onOpen: a3 } = e38, { _: o3 } = fx(), s3 = Sn3(), c3; + t2[0] !== s3 || t2[1] !== a3 || t2[2] !== r2 ? (c3 = (e39) => (0, Z5.jsx)(Cn3, { label: s3(e39), onOpen: a3, query: r2, row: e39 }, e39.id), t2[0] = s3, t2[1] = a3, t2[2] = r2, t2[3] = c3) : c3 = t2[3]; + let l5 = c3; + if (!i3) { + let e39; + return t2[4] !== l5 || t2[5] !== n2 ? (e39 = n2.map(l5), t2[4] = l5, t2[5] = n2, t2[6] = e39) : e39 = t2[6], e39; + } + let u3; + if (t2[7] !== o3 || t2[8] !== l5 || t2[9] !== n2) { + let e39; + t2[11] === n2 ? e39 = t2[12] : (e39 = (e40) => n2.filter((t3) => t3.kind === e40), t2[11] = n2, t2[12] = e39); + let r3; + t2[13] !== o3 || t2[14] !== l5 ? (r3 = (e40, t3) => (0, Z5.jsxs)(`div`, { role: `group`, "aria-label": o3(dn3[e40.kind]), children: [(0, Z5.jsx)(`p`, { "aria-hidden": `true`, ...h($4.groupLabel, t3 === 0 && $4.groupLabelFirst, Jb2.caption, Yb2.medium), children: o3(dn3[e40.kind]) }), e40.rows.map(l5)] }, e40.kind), t2[13] = o3, t2[14] = l5, t2[15] = r3) : r3 = t2[15], u3 = Gt2.flatMap(e39).reduce(Dn3, []).map(r3), t2[7] = o3, t2[8] = l5, t2[9] = n2, t2[10] = u3; + } else u3 = t2[10]; + return u3; +} +function Dn3(e38, t2) { + let n2 = e38.at(-1); + return n2?.kind === t2.kind ? n2.rows.push(t2) : e38.push({ kind: t2.kind, rows: [t2] }), e38; +} +function On3(e38) { + On3.d = 2096; + let t2 = (0, X5.c)(58), { items: n2, showCards: r2, onOpen: i3 } = e38, { i18n: a3, _: o3 } = fx(), s3 = (0, Y5.useId)(), [c3, l5] = (0, Y5.useState)(`all`), [u3, d3] = (0, Y5.useState)(`all`), [f4, p4] = (0, Y5.useState)(``), h4; + t2[0] === f4 ? h4 = t2[1] : (h4 = f4.trim(), t2[0] = f4, t2[1] = h4); + let g5 = h4.length > 0, v5; + t2[2] === r2 ? v5 = t2[3] : (v5 = r2 ? [`all`, `login`, `card`, `contact`] : [`all`, `login`, `contact`], t2[2] = r2, t2[3] = v5); + let y4 = v5, b2 = g5 ? u3 : c3, x2 = y4.includes(b2) ? b2 : `all`, S2 = a3.locale || `en`, C2; + t2[4] !== o3 || t2[5] !== n2 || t2[6] !== f4 || t2[7] !== x2 || t2[8] !== S2 ? (C2 = ln3(n2, { query: f4, tab: x2, locale: S2, cardLabel: o3({ id: `kryGs+` }) }), t2[4] = o3, t2[5] = n2, t2[6] = f4, t2[7] = x2, t2[8] = S2, t2[9] = C2) : C2 = t2[9]; + let w2 = C2, T2; + t2[10] === g5 ? T2 = t2[11] : (T2 = (e39) => { + !g5 && e39.trim().length > 0 && d3(`all`), p4(e39); + }, t2[10] = g5, t2[11] = T2); + let E2 = T2, D2; + t2[12] === g5 ? D2 = t2[13] : (D2 = (e39) => g5 ? d3(e39) : l5(e39), t2[12] = g5, t2[13] = D2); + let O2 = D2, k2 = w2.rows.length > 0, A2, j2; + t2[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (A2 = { className: `sand-78zum5 sand-dt5ytf sand-1665zp3` }, j2 = { className: `sand-78zum5 sand-6s0dn4 sand-1v2ro7d sand-euugli` }, t2[14] = A2, t2[15] = j2) : (A2 = t2[14], j2 = t2[15]); + let M2; + t2[16] !== s3 || t2[17] !== O2 || t2[18] !== x2 || t2[19] !== y4 || t2[20] !== w2.counts ? (M2 = (0, Z5.jsx)(Tn3, { counts: w2.counts, listId: s3, onSelect: O2, selected: x2, tabs: y4 }), t2[16] = s3, t2[17] = O2, t2[18] = x2, t2[19] = y4, t2[20] = w2.counts, t2[21] = M2) : M2 = t2[21]; + let N3; + t2[22] !== E2 || t2[23] !== f4 ? (N3 = (0, Z5.jsx)(wn3, { onQueryChange: E2, query: f4 }), t2[22] = E2, t2[23] = f4, t2[24] = N3) : N3 = t2[24]; + let P3; + t2[25] !== N3 || t2[26] !== M2 ? (P3 = (0, Z5.jsxs)(`div`, { ...j2, children: [M2, N3] }), t2[25] = N3, t2[26] = M2, t2[27] = P3) : P3 = t2[27]; + let F2; + t2[28] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (F2 = { className: `sand-78zum5 sand-dt5ytf sand-17d4w8g` }, t2[28] = F2) : F2 = t2[28]; + let I2; + t2[29] !== o3 || t2[30] !== k2 || t2[31] !== g5 || t2[32] !== s3 || t2[33] !== i3 || t2[34] !== f4 || t2[35] !== x2 || t2[36] !== w2.rows ? (I2 = k2 ? (0, Z5.jsx)(`div`, { "aria-label": o3({ id: `PH2oLy` }), id: s3, role: `tabpanel`, className: `sand-78zum5 sand-dt5ytf sand-1ruevkc sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-hojbe8`, children: (0, Z5.jsx)(En3, { onOpen: i3, query: f4, rows: w2.rows, showGroups: g5 && x2 === `all` }) }) : null, t2[29] = o3, t2[30] = k2, t2[31] = g5, t2[32] = s3, t2[33] = i3, t2[34] = f4, t2[35] = x2, t2[36] = w2.rows, t2[37] = I2) : I2 = t2[37]; + let L3; + t2[38] !== o3 || t2[39] !== k2 || t2[40] !== g5 || t2[41] !== s3 || t2[42] !== f4 || t2[43] !== x2 ? (L3 = k2 ? null : (0, Z5.jsx)(`p`, { id: s3, role: `tabpanel`, ...h($4.message, Jb2.body2), children: g5 ? (0, Z5.jsx)(mx, { id: `TBlG9c`, values: { 0: f4.trim() } }) : o3(fn4[x2]) }), t2[38] = o3, t2[39] = k2, t2[40] = g5, t2[41] = s3, t2[42] = f4, t2[43] = x2, t2[44] = L3) : L3 = t2[44]; + let R3; + t2[45] === L3 ? R3 = t2[46] : (R3 = (0, Z5.jsx)(Ix, { children: L3 }), t2[45] = L3, t2[46] = R3); + let z2; + t2[47] !== k2 || t2[48] !== g5 || t2[49] !== r2 ? (z2 = g5 && !k2 ? null : (0, Z5.jsx)(`p`, { ...h($4.footer, Jb2.label), children: r2 ? (0, Z5.jsx)(mx, { id: `2HFHfz` }) : (0, Z5.jsx)(mx, { id: `/iPSdc` }) }), t2[47] = k2, t2[48] = g5, t2[49] = r2, t2[50] = z2) : z2 = t2[50]; + let U3; + t2[51] !== I2 || t2[52] !== R3 || t2[53] !== z2 ? (U3 = (0, Z5.jsxs)(`div`, { ...F2, children: [I2, R3, z2] }), t2[51] = I2, t2[52] = R3, t2[53] = z2, t2[54] = U3) : U3 = t2[54]; + let W3; + return t2[55] !== P3 || t2[56] !== U3 ? (W3 = (0, Z5.jsxs)(`div`, { ...A2, children: [P3, U3] }), t2[55] = P3, t2[56] = U3, t2[57] = W3) : W3 = t2[57], W3; +} +var kn3 = { className: `sand-rvj5dj sand-cjjqqt sand-ehausa` }; +var An3 = { className: `sand-rvj5dj sand-cjjqqt sand-ehausa sand-pqajaz sand-18hwk67 sand-xs79tx` }; +var jn3 = { className: `sand-78zum5 sand-dt5ytf sand-11twubx` }; +var Mn3 = { className: `sand-78zum5 sand-1qjc9v5 sand-euugli sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1qmwy7c` }; +var Nn3 = { className: `sand-1iyjqo2 sand-euugli sand-1ghz6dp sand-knfcqp sand-1awh872 sand-ng3xce sand-1qmwy7c sand-1a2a7pz sand-jbqb8w sand-jb2p0i sand-11wthnw sand-tyxrsu sand-1h7ufjq` }; +var Pn3 = h(d2.option); +var Fn3 = [[{ key: `line1`, label: { id: `gzEjAL` } }], [{ key: `line2`, label: { id: `cormHa` } }], [{ key: `city`, label: { id: `3wV73y` } }, { key: `region`, label: { id: `BKTGoj` } }], [{ key: `postalCode`, label: { id: `XSEMno` } }, { key: `country`, label: { id: `JNCzPW` } }]]; +function In3() { + let e38 = (0, X5.c)(4), [t2, n2] = (0, Y5.useState)(null), [r2, i3] = (0, Y5.useState)(false), a3; + e38[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (a3 = async (e39, t3) => { n2(null), i3(true); - let r3 = await e10().then(bt, (e11) => (n2(Mge(e11) ?? t3), false)); + let r3 = await e39().then(Ln3, (e40) => (n2(aye(e40) ?? t3), false)); return i3(false), r3; - }, e9[0] = a3) : a3 = e9[0]; + }, e38[0] = a3) : a3 = e38[0]; let o3 = a3, s3; - return e9[1] !== t2 || e9[2] !== r2 ? (s3 = { error: t2, isSaving: r2, run: o3 }, e9[1] = t2, e9[2] = r2, e9[3] = s3) : s3 = e9[3], s3; + return e38[1] !== t2 || e38[2] !== r2 ? (s3 = { error: t2, isSaving: r2, run: o3 }, e38[1] = t2, e38[2] = r2, e38[3] = s3) : s3 = e38[3], s3; } -function bt() { +function Ln3() { return true; } -function xt(e9) { - xt.d = 1901; - let t2 = (0, X3.c)(2), { error: r2 } = e9, i3; - return t2[0] === r2 ? i3 = t2[1] : (i3 = r2 === null ? null : (0, Q2.jsx)(Kd, { as: `p`, color: `red`, role: `alert`, size: `xs`, children: r2 }), t2[0] = r2, t2[1] = i3), i3; +function Rn3(e38) { + Rn3.d = 2121; + let t2 = (0, X5.c)(2), { error: n2 } = e38, i3; + return t2[0] === n2 ? i3 = t2[1] : (i3 = n2 === null ? null : (0, Z5.jsx)(Ef2, { as: `p`, color: `red`, role: `alert`, size: `xs`, children: n2 }), t2[0] = n2, t2[1] = i3), i3; } -function St() { - return fC() === `elevated`; +function zn3() { + return gS() === `elevated`; } -function Ct(e9) { - Ct.d = 1900; - let t2 = (0, X3.c)(17), { isSaving: n2, saveLabel: r2, cancelLabel: i3, onCancel: a3 } = e9, s3 = St(), c2 = s3 ? `lg` : `sm`, l4; - t2[0] === i3 ? l4 = t2[1] : (l4 = i3 ?? (0, Q2.jsx)(Sb, { id: `dEgA5A` }), t2[0] = i3, t2[1] = l4); +function Bn3(e38) { + Bn3.d = 2120; + let t2 = (0, X5.c)(17), { isSaving: n2, saveLabel: r2, cancelLabel: i3, onCancel: a3 } = e38, o3 = zn3(), s3 = o3 ? `lg` : `sm`, c3; + t2[0] === i3 ? c3 = t2[1] : (c3 = i3 ?? (0, Z5.jsx)(mx, { id: `dEgA5A` }), t2[0] = i3, t2[1] = c3); + let l5; + t2[2] !== n2 || t2[3] !== a3 || t2[4] !== s3 || t2[5] !== c3 ? (l5 = (0, Z5.jsx)(LS, { disabled: n2, onClick: a3, size: s3, type: `button`, variant: `secondary`, children: c3 }), t2[2] = n2, t2[3] = a3, t2[4] = s3, t2[5] = c3, t2[6] = l5) : l5 = t2[6]; let u3; - t2[2] !== n2 || t2[3] !== a3 || t2[4] !== c2 || t2[5] !== l4 ? (u3 = (0, Q2.jsx)(MC, { disabled: n2, onClick: a3, size: c2, type: `button`, variant: `secondary`, children: l4 }), t2[2] = n2, t2[3] = a3, t2[4] = c2, t2[5] = l4, t2[6] = u3) : u3 = t2[6]; + t2[7] !== n2 || t2[8] !== r2 || t2[9] !== s3 ? (u3 = (0, Z5.jsx)(LS, { disabled: n2, pending: n2, size: s3, type: `submit`, variant: `primary`, children: r2 }), t2[7] = n2, t2[8] = r2, t2[9] = s3, t2[10] = u3) : u3 = t2[10]; let d3; - t2[7] !== n2 || t2[8] !== r2 || t2[9] !== c2 ? (d3 = (0, Q2.jsx)(MC, { disabled: n2, pending: n2, size: c2, type: `submit`, variant: `primary`, children: r2 }), t2[7] = n2, t2[8] = r2, t2[9] = c2, t2[10] = d3) : d3 = t2[10]; - let f4; - t2[11] !== u3 || t2[12] !== d3 ? (f4 = (0, Q2.jsxs)(Q2.Fragment, { children: [u3, d3] }), t2[11] = u3, t2[12] = d3, t2[13] = f4) : f4 = t2[13]; - let p4 = f4, m3; - return t2[14] !== p4 || t2[15] !== s3 ? (m3 = s3 ? p4 : (0, Q2.jsx)(`div`, { className: `sand-78zum5 sand-6s0dn4 sand-13a6bvl sand-pkkfsy`, children: p4 }), t2[14] = p4, t2[15] = s3, t2[16] = m3) : m3 = t2[16], m3; -} -function wt(e9) { - wt.d = 1915; - let t2 = (0, X3.c)(24), { label: n2, formRef: r2, error: i3, actions: a3, onSubmit: o3, children: c2 } = e9; - if (St()) { - let e10; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e10 = { className: `sand-jp7ctv` }, t2[0] = e10) : e10 = t2[0]; - let l5; - t2[1] === c2 ? l5 = t2[2] : (l5 = (0, Q2.jsx)(_, { children: c2 }), t2[1] = c2, t2[2] = l5); + t2[11] !== l5 || t2[12] !== u3 ? (d3 = (0, Z5.jsxs)(Z5.Fragment, { children: [l5, u3] }), t2[11] = l5, t2[12] = u3, t2[13] = d3) : d3 = t2[13]; + let f4 = d3, p4; + return t2[14] !== f4 || t2[15] !== o3 ? (p4 = o3 ? f4 : (0, Z5.jsx)(`div`, { className: `sand-78zum5 sand-6s0dn4 sand-13a6bvl sand-pkkfsy`, children: f4 }), t2[14] = f4, t2[15] = o3, t2[16] = p4) : p4 = t2[16], p4; +} +function Vn3(e38) { + Vn3.d = 2132; + let t2 = (0, X5.c)(26), { label: n2, error: r2, actions: i3, removeAction: a3, onSubmit: o3, children: s3 } = e38, c3 = a3 === void 0 ? null : a3; + if (zn3()) { + let e39; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = { className: `sand-jp7ctv` }, t2[0] = e39) : e39 = t2[0]; + let a4; + t2[1] === s3 ? a4 = t2[2] : (a4 = (0, Z5.jsx)(_, { children: s3 }), t2[1] = s3, t2[2] = a4); + let l6; + t2[3] === r2 ? l6 = t2[4] : (l6 = (0, Z5.jsx)(Rn3, { error: r2 }), t2[3] = r2, t2[4] = l6); let u4; - t2[3] === i3 ? u4 = t2[4] : (u4 = (0, Q2.jsx)(xt, { error: i3 }), t2[3] = i3, t2[4] = u4); + t2[5] !== c3 || t2[6] !== l6 ? (u4 = (0, Z5.jsxs)(Z5.Fragment, { children: [c3, l6] }), t2[5] = c3, t2[6] = l6, t2[7] = u4) : u4 = t2[7]; let d4; - t2[5] !== a3 || t2[6] !== u4 ? (d4 = (0, Q2.jsx)(TC, { leading: u4, trailing: a3 }), t2[5] = a3, t2[6] = u4, t2[7] = d4) : d4 = t2[7]; + t2[8] !== i3 || t2[9] !== u4 ? (d4 = (0, Z5.jsx)(AS, { leading: u4, trailing: i3 }), t2[8] = i3, t2[9] = u4, t2[10] = d4) : d4 = t2[10]; let f4; - return t2[8] !== r2 || t2[9] !== n2 || t2[10] !== o3 || t2[11] !== l5 || t2[12] !== d4 ? (f4 = (0, Q2.jsxs)(`form`, { "aria-label": n2, onSubmit: o3, ref: r2, ...e10, children: [l5, d4] }), t2[8] = r2, t2[9] = n2, t2[10] = o3, t2[11] = l5, t2[12] = d4, t2[13] = f4) : f4 = t2[13], f4; + return t2[11] !== n2 || t2[12] !== o3 || t2[13] !== a4 || t2[14] !== d4 ? (f4 = (0, Z5.jsxs)(`form`, { "aria-label": n2, onSubmit: o3, ...e39, children: [a4, d4] }), t2[11] = n2, t2[12] = o3, t2[13] = a4, t2[14] = d4, t2[15] = f4) : f4 = t2[15], f4; } - let l4; - t2[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l4 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa sand-y3j6vt sand-2f45yy` }, t2[14] = l4) : l4 = t2[14]; + let l5; + t2[16] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l5 = { className: `sand-78zum5 sand-dt5ytf sand-ehausa sand-y3j6vt sand-2f45yy` }, t2[16] = l5) : l5 = t2[16]; let u3; - t2[15] === i3 ? u3 = t2[16] : (u3 = (0, Q2.jsx)(xt, { error: i3 }), t2[15] = i3, t2[16] = u3); + t2[17] === r2 ? u3 = t2[18] : (u3 = (0, Z5.jsx)(Rn3, { error: r2 }), t2[17] = r2, t2[18] = u3); let d3; - return t2[17] !== a3 || t2[18] !== c2 || t2[19] !== r2 || t2[20] !== n2 || t2[21] !== o3 || t2[22] !== u3 ? (d3 = (0, Q2.jsxs)(`form`, { "aria-label": n2, onSubmit: o3, ref: r2, ...l4, children: [c2, u3, a3] }), t2[17] = a3, t2[18] = c2, t2[19] = r2, t2[20] = n2, t2[21] = o3, t2[22] = u3, t2[23] = d3) : d3 = t2[23], d3; -} -function Tt(e9) { - Tt.d = 1899; - let t2 = (0, X3.c)(3), { children: n2 } = e9, r2 = St() ? ut2 : lt2, i3; - return t2[0] !== n2 || t2[1] !== r2 ? (i3 = (0, Q2.jsx)(`div`, { ...r2, children: n2 }), t2[0] = n2, t2[1] = r2, t2[2] = i3) : i3 = t2[2], i3; -} -function Et(e9) { - Et.d = 1914; - let t2 = (0, X3.c)(39), r2, i3, a3, o3; - t2[0] === e9 ? (r2 = t2[1], i3 = t2[2], a3 = t2[3], o3 = t2[4]) : ({ label: i3, required: a3, type: o3, ...r2 } = e9, t2[0] = e9, t2[1] = r2, t2[2] = i3, t2[3] = a3, t2[4] = o3); - let s3 = a3 !== void 0 && a3, c2 = (0, Y3.useId)(), l4 = St(), [u3, d3] = (0, Y3.useState)(false), f4 = o3 === `password`, p4; - t2[5] !== f4 || t2[6] !== u3 || t2[7] !== i3 ? (p4 = f4 ? (0, Q2.jsx)(m2, { isRevealed: u3, label: i3, onToggle: () => d3(Dt) }) : null, t2[5] = f4, t2[6] = u3, t2[7] = i3, t2[8] = p4) : p4 = t2[8]; - let m3 = p4, h3 = f4 && u3 ? `text` : o3; - if (l4) { - let e10; - t2[9] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e10 = h(d2.control, d2.controlElevated), t2[9] = e10) : e10 = t2[9]; - let n2; - t2[10] !== c2 || t2[11] !== r2 || t2[12] !== h3 || t2[13] !== s3 ? (n2 = (0, Q2.jsx)(`input`, { autoComplete: `off`, id: c2, spellCheck: false, ...r2, required: s3, type: h3, ...e10 }), t2[10] = c2, t2[11] = r2, t2[12] = h3, t2[13] = s3, t2[14] = n2) : n2 = t2[14]; + return t2[19] !== i3 || t2[20] !== s3 || t2[21] !== n2 || t2[22] !== o3 || t2[23] !== c3 || t2[24] !== u3 ? (d3 = (0, Z5.jsxs)(`form`, { "aria-label": n2, onSubmit: o3, ...l5, children: [s3, u3, c3, i3] }), t2[19] = i3, t2[20] = s3, t2[21] = n2, t2[22] = o3, t2[23] = c3, t2[24] = u3, t2[25] = d3) : d3 = t2[25], d3; +} +function Hn3(e38) { + Hn3.d = 2119; + let t2 = (0, X5.c)(3), { children: n2 } = e38, r2 = zn3() ? An3 : kn3, i3; + return t2[0] !== n2 || t2[1] !== r2 ? (i3 = (0, Z5.jsx)(`div`, { ...r2, children: n2 }), t2[0] = n2, t2[1] = r2, t2[2] = i3) : i3 = t2[2], i3; +} +function Un3(e38) { + Un3.d = 2131; + let t2 = (0, X5.c)(39), n2, i3, a3, o3; + t2[0] === e38 ? (n2 = t2[1], i3 = t2[2], a3 = t2[3], o3 = t2[4]) : ({ label: i3, required: a3, type: o3, ...n2 } = e38, t2[0] = e38, t2[1] = n2, t2[2] = i3, t2[3] = a3, t2[4] = o3); + let s3 = a3 !== void 0 && a3, c3 = (0, Y5.useId)(), l5 = zn3(), [u3, d3] = (0, Y5.useState)(false), f4 = o3 === `password`, p4; + t2[5] !== f4 || t2[6] !== u3 || t2[7] !== i3 ? (p4 = f4 ? (0, Z5.jsx)(m2, { isRevealed: u3, label: i3, onToggle: () => d3(Wn3) }) : null, t2[5] = f4, t2[6] = u3, t2[7] = i3, t2[8] = p4) : p4 = t2[8]; + let m3 = p4, h4 = f4 && u3 ? `text` : o3; + if (l5) { + let e39; + t2[9] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (e39 = h(d2.control, d2.controlElevated), t2[9] = e39) : e39 = t2[9]; + let r2; + t2[10] !== c3 || t2[11] !== n2 || t2[12] !== h4 || t2[13] !== s3 ? (r2 = (0, Z5.jsx)(`input`, { autoComplete: `off`, id: c3, spellCheck: false, ...n2, required: s3, type: h4, ...e39 }), t2[10] = c3, t2[11] = n2, t2[12] = h4, t2[13] = s3, t2[14] = r2) : r2 = t2[14]; let a4; - t2[15] !== m3 || t2[16] !== n2 ? (a4 = (0, Q2.jsxs)(p2, { children: [n2, m3] }), t2[15] = m3, t2[16] = n2, t2[17] = a4) : a4 = t2[17]; + t2[15] !== m3 || t2[16] !== r2 ? (a4 = (0, Z5.jsxs)(p2, { children: [r2, m3] }), t2[15] = m3, t2[16] = r2, t2[17] = a4) : a4 = t2[17]; let o4; - return t2[18] !== c2 || t2[19] !== i3 || t2[20] !== s3 || t2[21] !== a4 ? (o4 = (0, Q2.jsx)(g, { htmlFor: c2, isRequired: s3, label: i3, requirementMarker: `asterisk`, children: a4 }), t2[18] = c2, t2[19] = i3, t2[20] = s3, t2[21] = a4, t2[22] = o4) : o4 = t2[22], o4; - } - let g3; - t2[23] === i3 ? g3 = t2[24] : (g3 = (0, Q2.jsx)(Kd, { as: `span`, color: `secondary`, size: `xs`, children: i3 }), t2[23] = i3, t2[24] = g3); - let _2; - t2[25] !== c2 || t2[26] !== g3 ? (_2 = (0, Q2.jsx)(`label`, { htmlFor: c2, children: g3 }), t2[25] = c2, t2[26] = g3, t2[27] = _2) : _2 = t2[27]; - let v3; - t2[28] !== c2 || t2[29] !== r2 || t2[30] !== h3 || t2[31] !== s3 ? (v3 = (0, Q2.jsx)(`input`, { autoComplete: `off`, id: c2, spellCheck: false, ...r2, required: s3, type: h3, ...pt }), t2[28] = c2, t2[29] = r2, t2[30] = h3, t2[31] = s3, t2[32] = v3) : v3 = t2[32]; - let y3; - t2[33] !== m3 || t2[34] !== v3 ? (y3 = (0, Q2.jsxs)(`div`, { ...ft2, children: [v3, m3] }), t2[33] = m3, t2[34] = v3, t2[35] = y3) : y3 = t2[35]; - let b3; - return t2[36] !== _2 || t2[37] !== y3 ? (b3 = (0, Q2.jsxs)(`div`, { ...dt2, children: [_2, y3] }), t2[36] = _2, t2[37] = y3, t2[38] = b3) : b3 = t2[38], b3; -} -function Dt(e9) { - return !e9; -} -var Ot = `ABCDEFGHIJKLMNOPQRSTUVWXYZ`; -var kt = _t((e9) => { - let t2 = new Intl.DisplayNames([e9], { type: `region`, fallback: `none` }), n2 = new Intl.Collator(e9); - return [...Ot].flatMap((e10) => [...Ot].map((t3) => `${e10}${t3}`)).filter(wge).map((e10) => ({ code: e10, label: t2.of(e10) ?? e10 })).toSorted((e10, t3) => n2.compare(e10.label, t3.label)); + return t2[18] !== c3 || t2[19] !== i3 || t2[20] !== s3 || t2[21] !== a4 ? (o4 = (0, Z5.jsx)(g, { htmlFor: c3, isRequired: s3, label: i3, requirementMarker: `asterisk`, children: a4 }), t2[18] = c3, t2[19] = i3, t2[20] = s3, t2[21] = a4, t2[22] = o4) : o4 = t2[22], o4; + } + let g5; + t2[23] === i3 ? g5 = t2[24] : (g5 = (0, Z5.jsx)(Ef2, { as: `span`, color: `secondary`, size: `xs`, children: i3 }), t2[23] = i3, t2[24] = g5); + let _5; + t2[25] !== c3 || t2[26] !== g5 ? (_5 = (0, Z5.jsx)(`label`, { htmlFor: c3, children: g5 }), t2[25] = c3, t2[26] = g5, t2[27] = _5) : _5 = t2[27]; + let v5; + t2[28] !== c3 || t2[29] !== n2 || t2[30] !== h4 || t2[31] !== s3 ? (v5 = (0, Z5.jsx)(`input`, { autoComplete: `off`, id: c3, spellCheck: false, ...n2, required: s3, type: h4, ...Nn3 }), t2[28] = c3, t2[29] = n2, t2[30] = h4, t2[31] = s3, t2[32] = v5) : v5 = t2[32]; + let y4; + t2[33] !== m3 || t2[34] !== v5 ? (y4 = (0, Z5.jsxs)(`div`, { ...Mn3, children: [v5, m3] }), t2[33] = m3, t2[34] = v5, t2[35] = y4) : y4 = t2[35]; + let b2; + return t2[36] !== _5 || t2[37] !== y4 ? (b2 = (0, Z5.jsxs)(`div`, { ...jn3, children: [_5, y4] }), t2[36] = _5, t2[37] = y4, t2[38] = b2) : b2 = t2[38], b2; +} +function Wn3(e38) { + return !e38; +} +var Gn3 = `ABCDEFGHIJKLMNOPQRSTUVWXYZ`; +var Kn3 = fn((e38) => { + let t2 = new Intl.DisplayNames([e38], { type: `region`, fallback: `none` }), n2 = new Intl.Collator(e38); + return [...Gn3].flatMap((e39) => [...Gn3].map((t3) => `${e39}${t3}`)).filter($ve).map((e39) => ({ code: e39, label: t2.of(e39) ?? e39 })).toSorted((e39, t3) => n2.compare(e39.label, t3.label)); }); -var At = _t(() => K3.map((e9) => e9.id === `billing_country` ? { ...e9, type: `select`, options: kt().map(({ code: e10, label: t2 }) => ({ label: t2, value: e10 })) } : e9)); -function jt(e9) { - jt.d = 1896; - let t2 = (0, X3.c)(31), { label: r2, value: i3, onChange: a3 } = e9, o3 = (0, Y3.useId)(), s3 = St(), c2; +function qn4(e38) { + qn4.d = 2118; + let t2 = (0, X5.c)(31), { label: n2, value: i3, onChange: a3 } = e38, o3 = (0, Y5.useId)(), s3 = zn3(), c3; if (t2[0] !== i3) { - let e10 = kt(), n2 = i3.length === 0 || e10.some((e11) => e11.code === i3), r3; - t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r3 = (0, Q2.jsx)(`option`, { value: ``, ...mt2 }), t2[2] = r3) : r3 = t2[2], c2 = (0, Q2.jsxs)(Q2.Fragment, { children: [r3, n2 ? null : (0, Q2.jsx)(`option`, { value: i3, ...mt2, children: i3 }), e10.map(Mt)] }), t2[0] = i3, t2[1] = c2; - } else c2 = t2[1]; - let l4 = c2; + let e39 = Kn3(), n3 = i3.length === 0 || e39.some((e40) => e40.code === i3), r2; + t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = (0, Z5.jsx)(`option`, { value: ``, ...Pn3 }), t2[2] = r2) : r2 = t2[2], c3 = (0, Z5.jsxs)(Z5.Fragment, { children: [r2, n3 ? null : (0, Z5.jsx)(`option`, { value: i3, ...Pn3, children: i3 }), e39.map(Jn4)] }), t2[0] = i3, t2[1] = c3; + } else c3 = t2[1]; + let l5 = c3; if (s3) { - let e10; - t2[3] === a3 ? e10 = t2[4] : (e10 = (e11) => a3(e11.currentTarget.value), t2[3] = a3, t2[4] = e10); - let n2; - t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (n2 = h(d2.control, d2.controlElevated, d2.select, d2.selectElevated), t2[5] = n2) : n2 = t2[5]; + let e39; + t2[3] === a3 ? e39 = t2[4] : (e39 = (e40) => a3(e40.currentTarget.value), t2[3] = a3, t2[4] = e39); + let r2; + t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = h(d2.control, d2.controlElevated, d2.select, d2.selectElevated), t2[5] = r2) : r2 = t2[5]; let s4; - t2[6] !== l4 || t2[7] !== o3 || t2[8] !== e10 || t2[9] !== i3 ? (s4 = (0, Q2.jsx)(p2, { children: (0, Q2.jsx)(`select`, { id: o3, onChange: e10, value: i3, ...n2, children: l4 }) }), t2[6] = l4, t2[7] = o3, t2[8] = e10, t2[9] = i3, t2[10] = s4) : s4 = t2[10]; - let c3; - return t2[11] !== o3 || t2[12] !== r2 || t2[13] !== s4 ? (c3 = (0, Q2.jsx)(g, { htmlFor: o3, label: r2, requirementMarker: `asterisk`, children: s4 }), t2[11] = o3, t2[12] = r2, t2[13] = s4, t2[14] = c3) : c3 = t2[14], c3; + t2[6] !== l5 || t2[7] !== o3 || t2[8] !== e39 || t2[9] !== i3 ? (s4 = (0, Z5.jsx)(p2, { children: (0, Z5.jsx)(`select`, { id: o3, onChange: e39, value: i3, ...r2, children: l5 }) }), t2[6] = l5, t2[7] = o3, t2[8] = e39, t2[9] = i3, t2[10] = s4) : s4 = t2[10]; + let c4; + return t2[11] !== o3 || t2[12] !== n2 || t2[13] !== s4 ? (c4 = (0, Z5.jsx)(g, { htmlFor: o3, label: n2, requirementMarker: `asterisk`, children: s4 }), t2[11] = o3, t2[12] = n2, t2[13] = s4, t2[14] = c4) : c4 = t2[14], c4; } let u3; - t2[15] === r2 ? u3 = t2[16] : (u3 = (0, Q2.jsx)(Kd, { as: `span`, color: `secondary`, size: `xs`, children: r2 }), t2[15] = r2, t2[16] = u3); + t2[15] === n2 ? u3 = t2[16] : (u3 = (0, Z5.jsx)(Ef2, { as: `span`, color: `secondary`, size: `xs`, children: n2 }), t2[15] = n2, t2[16] = u3); let d3; - t2[17] !== o3 || t2[18] !== u3 ? (d3 = (0, Q2.jsx)(`label`, { htmlFor: o3, children: u3 }), t2[17] = o3, t2[18] = u3, t2[19] = d3) : d3 = t2[19]; + t2[17] !== o3 || t2[18] !== u3 ? (d3 = (0, Z5.jsx)(`label`, { htmlFor: o3, children: u3 }), t2[17] = o3, t2[18] = u3, t2[19] = d3) : d3 = t2[19]; let f4; - t2[20] === a3 ? f4 = t2[21] : (f4 = (e10) => a3(e10.currentTarget.value), t2[20] = a3, t2[21] = f4); + t2[20] === a3 ? f4 = t2[21] : (f4 = (e39) => a3(e39.currentTarget.value), t2[20] = a3, t2[21] = f4); let p4; t2[22] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = { className: `sand-1iyjqo2 sand-euugli sand-1ghz6dp sand-knfcqp sand-1awh872 sand-ng3xce sand-1qmwy7c sand-1a2a7pz sand-jbqb8w sand-jb2p0i sand-11wthnw sand-tyxrsu sand-1h7ufjq` }, t2[22] = p4) : p4 = t2[22]; let m3; - t2[23] !== l4 || t2[24] !== o3 || t2[25] !== f4 || t2[26] !== i3 ? (m3 = (0, Q2.jsx)(`div`, { ...ft2, children: (0, Q2.jsx)(`select`, { id: o3, onChange: f4, value: i3, ...p4, children: l4 }) }), t2[23] = l4, t2[24] = o3, t2[25] = f4, t2[26] = i3, t2[27] = m3) : m3 = t2[27]; - let h3; - return t2[28] !== d3 || t2[29] !== m3 ? (h3 = (0, Q2.jsxs)(`div`, { ...dt2, children: [d3, m3] }), t2[28] = d3, t2[29] = m3, t2[30] = h3) : h3 = t2[30], h3; -} -function Mt(e9) { - return (0, Q2.jsx)(`option`, { value: e9.code, ...mt2, children: e9.label }, e9.code); -} -function Nt2(e9) { - Nt2.d = 1888; - let t2 = (0, X3.c)(6), { field: n2, value: r2, onChange: i3 } = e9, { _: a3 } = bb(), o3; - return t2[0] !== a3 || t2[1] !== n2.key || t2[2] !== n2.label || t2[3] !== i3 || t2[4] !== r2 ? (o3 = n2.key === `country` ? (0, Q2.jsx)(jt, { label: a3(n2.label), onChange: i3, value: r2 }) : (0, Q2.jsx)($3, { label: a3(n2.label), onChange: i3, value: r2 }), t2[0] = a3, t2[1] = n2.key, t2[2] = n2.label, t2[3] = i3, t2[4] = r2, t2[5] = o3) : o3 = t2[5], o3; -} -function $3(e9) { - $3.d = 1913; - let t2 = (0, X3.c)(8), { label: n2, value: r2, onChange: i3, placeholder: a3, required: o3 } = e9, s3 = o3 !== void 0 && o3, c2; - t2[0] === i3 ? c2 = t2[1] : (c2 = (e10) => i3(e10.currentTarget.value), t2[0] = i3, t2[1] = c2); - let l4; - return t2[2] !== n2 || t2[3] !== a3 || t2[4] !== s3 || t2[5] !== c2 || t2[6] !== r2 ? (l4 = (0, Q2.jsx)(Et, { label: n2, onChange: c2, placeholder: a3, required: s3, value: r2 }), t2[2] = n2, t2[3] = a3, t2[4] = s3, t2[5] = c2, t2[6] = r2, t2[7] = l4) : l4 = t2[7], l4; -} -function Pt(e9) { - Pt.d = 1898; - let t2 = (0, X3.c)(8), { label: n2, name: r2, value: i3, onChange: a3 } = e9, o3; - t2[0] !== a3 || t2[1] !== i3 ? (o3 = (e10) => a3(J3({ value: e10.currentTarget.value, previous: i3 })), t2[0] = a3, t2[1] = i3, t2[2] = o3) : o3 = t2[2]; + t2[23] !== l5 || t2[24] !== o3 || t2[25] !== f4 || t2[26] !== i3 ? (m3 = (0, Z5.jsx)(`div`, { ...Mn3, children: (0, Z5.jsx)(`select`, { id: o3, onChange: f4, value: i3, ...p4, children: l5 }) }), t2[23] = l5, t2[24] = o3, t2[25] = f4, t2[26] = i3, t2[27] = m3) : m3 = t2[27]; + let h4; + return t2[28] !== d3 || t2[29] !== m3 ? (h4 = (0, Z5.jsxs)(`div`, { ...jn3, children: [d3, m3] }), t2[28] = d3, t2[29] = m3, t2[30] = h4) : h4 = t2[30], h4; +} +function Jn4(e38) { + return (0, Z5.jsx)(`option`, { value: e38.code, ...Pn3, children: e38.label }, e38.code); +} +function Yn3(e38) { + Yn3.d = 2115; + let t2 = (0, X5.c)(6), { field: n2, value: r2, onChange: i3 } = e38, { _: a3 } = fx(), o3; + return t2[0] !== a3 || t2[1] !== n2.key || t2[2] !== n2.label || t2[3] !== i3 || t2[4] !== r2 ? (o3 = n2.key === `country` ? (0, Z5.jsx)(qn4, { label: a3(n2.label), onChange: i3, value: r2 }) : (0, Z5.jsx)(Xn3, { label: a3(n2.label), onChange: i3, value: r2 }), t2[0] = a3, t2[1] = n2.key, t2[2] = n2.label, t2[3] = i3, t2[4] = r2, t2[5] = o3) : o3 = t2[5], o3; +} +function Xn3(e38) { + Xn3.d = 2130; + let t2 = (0, X5.c)(8), { label: n2, value: r2, onChange: i3, placeholder: a3, required: o3 } = e38, s3 = o3 !== void 0 && o3, c3; + t2[0] === i3 ? c3 = t2[1] : (c3 = (e39) => i3(e39.currentTarget.value), t2[0] = i3, t2[1] = c3); + let l5; + return t2[2] !== n2 || t2[3] !== a3 || t2[4] !== s3 || t2[5] !== c3 || t2[6] !== r2 ? (l5 = (0, Z5.jsx)(Un3, { label: n2, onChange: c3, placeholder: a3, required: s3, value: r2 }), t2[2] = n2, t2[3] = a3, t2[4] = s3, t2[5] = c3, t2[6] = r2, t2[7] = l5) : l5 = t2[7], l5; +} +function Zn3(e38) { + Zn3.d = 2127; + let t2 = (0, X5.c)(2), { onClose: n2 } = e38, r2; + return t2[0] === n2 ? r2 = t2[1] : (r2 = (0, Z5.jsx)(Ht4, { editing: null, onClose: n2 }), t2[0] = n2, t2[1] = r2), r2; +} +function Qn3(e38) { + Qn3.d = 2124; + let t2 = (0, X5.c)(3), { onClose: n2 } = e38, r2; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { kind: `add` }, t2[0] = r2) : r2 = t2[0]; + let i3; + return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, Z5.jsx)(y3, { onClose: n2, target: r2 }), t2[1] = n2, t2[2] = i3), i3; +} +var $n2 = [{ id: `login`, label: { id: `z0t9bb` }, formTitle: { id: `3UUCyn` }, icon: `key`, gate: null, Dialog: Zn3 }, { id: `card`, label: { id: `kryGs+` }, formTitle: { id: `pnrmSP` }, icon: `credit-card`, gate: h_2, Dialog: Qn3 }, { id: `contact`, label: { id: `OBRLoG` }, formTitle: { id: `SJc6TB` }, icon: `person`, gate: null, Form: or2 }]; +function er(e38) { + er.d = 2128; + let t2 = (0, X5.c)(17), { type: n2, onClose: r2 } = e38, { _: i3 } = fx(); + if (`Dialog` in n2) { + let e39; + return t2[0] !== r2 || t2[1] !== n2.Dialog ? (e39 = (0, Z5.jsx)(n2.Dialog, { onClose: r2 }), t2[0] = r2, t2[1] = n2.Dialog, t2[2] = e39) : e39 = t2[2], e39; + } + let a3; + t2[3] === n2.icon ? a3 = t2[4] : (a3 = (0, Z5.jsx)(aS, { "aria-hidden": true, name: n2.icon, size: `sm` }), t2[3] = n2.icon, t2[4] = a3); + let o3; + t2[5] !== i3 || t2[6] !== n2.formTitle ? (o3 = i3(n2.formTitle), t2[5] = i3, t2[6] = n2.formTitle, t2[7] = o3) : o3 = t2[7]; let s3; - return t2[3] !== n2 || t2[4] !== r2 || t2[5] !== o3 || t2[6] !== i3 ? (s3 = (0, Q2.jsx)(Et, { inputMode: `numeric`, label: n2, name: r2, onChange: o3, required: true, value: i3 }), t2[3] = n2, t2[4] = r2, t2[5] = o3, t2[6] = i3, t2[7] = s3) : s3 = t2[7], s3; -} -function Ft(e9) { - Ft.d = 1905; - let t2 = (0, X3.c)(73), { editing: n2, cancelLabel: r2, onCancel: i3, onDone: a3 } = e9, { _: o3 } = bb(), s3 = kge(), [c2, l4] = (0, Y3.useState)(n2?.title ?? ``), [d3, f4] = (0, Y3.useState)(n2?.username ?? ``), p4; - t2[0] === n2?.sites ? p4 = t2[1] : (p4 = n2?.sites.join(` `) ?? ``, t2[0] = n2?.sites, t2[1] = p4); - let [m3, h3] = (0, Y3.useState)(p4), [g3, _2] = (0, Y3.useState)(n2?.notes ?? ``), v3 = (0, Y3.useRef)(null), y3 = yt(), b3, x3, S3, C2, w3; - if (t2[2] !== o3 || t2[3] !== r2 || t2[4] !== n2 || t2[5] !== g3 || t2[6] !== i3 || t2[7] !== a3 || t2[8] !== m3 || t2[9] !== c2 || t2[10] !== d3 || t2[11] !== s3 || t2[12] !== y3) { - let e10 = n2 === null ? null : _t2(n2), l5; - t2[18] !== o3 || t2[19] !== n2?.id || t2[20] !== g3 || t2[21] !== a3 || t2[22] !== m3 || t2[23] !== c2 || t2[24] !== d3 || t2[25] !== s3 || t2[26] !== y3 ? (l5 = async (e11) => { - e11.preventDefault(), await y3.run(() => s3.put({ id: n2?.id ?? ``, title: c2, username: d3, notes: g3, sites: gt2(m3), password: v3.current?.value ?? `` }), o3({ id: `QqKsGg` })) && a3(); - }, t2[18] = o3, t2[19] = n2?.id, t2[20] = g3, t2[21] = a3, t2[22] = m3, t2[23] = c2, t2[24] = d3, t2[25] = s3, t2[26] = y3, t2[27] = l5) : l5 = t2[27]; - let u3 = l5; - b3 = wt; - let f5; - t2[28] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f5 = (0, Q2.jsx)(Sb, { id: `br7Ace` }), t2[28] = f5) : f5 = t2[28], t2[29] !== r2 || t2[30] !== i3 || t2[31] !== y3.isSaving ? (x3 = (0, Q2.jsx)(Ct, { cancelLabel: r2, isSaving: y3.isSaving, onCancel: i3, saveLabel: f5 }), t2[29] = r2, t2[30] = i3, t2[31] = y3.isSaving, t2[32] = x3) : x3 = t2[32], S3 = y3.error, C2 = o3(e10 === null ? { id: `3UUCyn` } : { id: `6ixmzu`, values: { name: e10 } }), w3 = (e11) => void u3(e11), t2[2] = o3, t2[3] = r2, t2[4] = n2, t2[5] = g3, t2[6] = i3, t2[7] = a3, t2[8] = m3, t2[9] = c2, t2[10] = d3, t2[11] = s3, t2[12] = y3, t2[13] = b3, t2[14] = x3, t2[15] = S3, t2[16] = C2, t2[17] = w3; - } else b3 = t2[13], x3 = t2[14], S3 = t2[15], C2 = t2[16], w3 = t2[17]; - let T3; - t2[33] === o3 ? T3 = t2[34] : (T3 = o3({ id: `6YtxFj` }), t2[33] = o3, t2[34] = T3); - let E3; - t2[35] !== T3 || t2[36] !== c2 ? (E3 = (0, Q2.jsx)($3, { label: T3, onChange: l4, required: true, value: c2 }), t2[35] = T3, t2[36] = c2, t2[37] = E3) : E3 = t2[37]; + t2[8] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = (0, Z5.jsx)(mx, { id: `dEgA5A` }), t2[8] = s3) : s3 = t2[8]; + let c3; + t2[9] !== r2 || t2[10] !== n2.Form ? (c3 = (0, Z5.jsx)(n2.Form, { cancelLabel: s3, onCancel: r2, onDone: r2 }), t2[9] = r2, t2[10] = n2.Form, t2[11] = c3) : c3 = t2[11]; + let l5; + return t2[12] !== r2 || t2[13] !== a3 || t2[14] !== o3 || t2[15] !== c3 ? (l5 = (0, Z5.jsx)(v2, { icon: a3, onClose: r2, title: o3, titleInTitlebar: true, width: 520, children: c3 }), t2[12] = r2, t2[13] = a3, t2[14] = o3, t2[15] = c3, t2[16] = l5) : l5 = t2[16], l5; +} +var tr = { name: ``, line1: ``, line2: ``, city: ``, region: ``, postalCode: ``, country: ``, phone: ``, email: `` }; +var nr2 = [[{ key: `line1`, label: { id: `Du6bPw` } }], ...Fn3.slice(1)]; +function rr2(e38) { + if (e38 === void 0) return tr; + let t2 = Qve(e38.country); + return { ...e38, country: $ve(t2) ? t2 : `` }; +} +function ir2(e38) { + ir2.d = 2117; + let t2 = (0, X5.c)(64), { editing: n2, cancelLabel: r2, removeAction: i3, onCancel: a3, onDone: o3 } = e38, { _: s3 } = fx(), c3 = v_2(), [l5, u3] = (0, Y5.useState)(n2?.title ?? ``), d3; + t2[0] === n2?.contact ? d3 = t2[1] : (d3 = () => rr2(n2?.contact), t2[0] = n2?.contact, t2[1] = d3); + let [f4, p4] = (0, Y5.useState)(d3), m3 = In3(), h4; + t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h4 = (e39) => p4((t3) => ({ ...t3, ...e39 })), t2[2] = h4) : h4 = t2[2]; + let g5 = h4, _5; + t2[3] === f4 ? _5 = t2[4] : (_5 = (e39) => (0, Z5.jsx)(Yn3, { field: e39, onChange: (t3) => g5({ [e39.key]: t3 }), value: f4[e39.key] }, e39.key), t2[3] = f4, t2[4] = _5); + let v5 = _5, y4 = n2?.title ?? ``, x2; + t2[5] !== s3 || t2[6] !== f4 || t2[7] !== n2?.id || t2[8] !== o3 || t2[9] !== l5 || t2[10] !== c3 || t2[11] !== m3 ? (x2 = async (e39) => { + e39.preventDefault(), await m3.run(() => c3.putContact({ id: n2?.id ?? ``, title: l5, contact: f4 }), s3({ id: `QqKsGg` })) && o3(); + }, t2[5] = s3, t2[6] = f4, t2[7] = n2?.id, t2[8] = o3, t2[9] = l5, t2[10] = c3, t2[11] = m3, t2[12] = x2) : x2 = t2[12]; + let S2 = x2, C2; + t2[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (C2 = (0, Z5.jsx)(mx, { id: `PAx2Yh` }), t2[13] = C2) : C2 = t2[13]; + let w2; + t2[14] !== r2 || t2[15] !== a3 || t2[16] !== m3.isSaving ? (w2 = (0, Z5.jsx)(Bn3, { cancelLabel: r2, isSaving: m3.isSaving, onCancel: a3, saveLabel: C2 }), t2[14] = r2, t2[15] = a3, t2[16] = m3.isSaving, t2[17] = w2) : w2 = t2[17]; + let T2 = m3.error, E2; + t2[18] !== s3 || t2[19] !== n2 || t2[20] !== y4 ? (E2 = s3(n2 === null ? { id: `SJc6TB` } : { id: `ja+MfM`, values: { name: y4 } }), t2[18] = s3, t2[19] = n2, t2[20] = y4, t2[21] = E2) : E2 = t2[21]; let D2; - t2[38] === o3 ? D2 = t2[39] : (D2 = o3({ id: `On0aF2` }), t2[38] = o3, t2[39] = D2); - let O3; - t2[40] !== m3 || t2[41] !== D2 ? (O3 = (0, Q2.jsx)($3, { label: D2, onChange: h3, placeholder: `https://example.com`, required: true, value: m3 }), t2[40] = m3, t2[41] = D2, t2[42] = O3) : O3 = t2[42]; - let j3; - t2[43] === o3 ? j3 = t2[44] : (j3 = o3({ id: `5E4MzW` }), t2[43] = o3, t2[44] = j3); - let M3; - t2[45] !== j3 || t2[46] !== d3 ? (M3 = (0, Q2.jsx)($3, { label: j3, onChange: f4, value: d3 }), t2[45] = j3, t2[46] = d3, t2[47] = M3) : M3 = t2[47]; - let N2; - t2[48] === o3 ? N2 = t2[49] : (N2 = o3({ id: `8ZsakT` }), t2[48] = o3, t2[49] = N2); - let P2; - t2[50] !== o3 || t2[51] !== n2 ? (P2 = n2 === null ? `` : o3({ id: `6SNOki` }), t2[50] = o3, t2[51] = n2, t2[52] = P2) : P2 = t2[52]; - let F2 = n2 === null, I; - t2[53] !== N2 || t2[54] !== P2 || t2[55] !== F2 ? (I = (0, Q2.jsx)(Et, { autoComplete: `new-password`, label: N2, placeholder: P2, ref: v3, required: F2, type: `password` }), t2[53] = N2, t2[54] = P2, t2[55] = F2, t2[56] = I) : I = t2[56]; - let L; - t2[57] === o3 ? L = t2[58] : (L = o3({ id: `1DBGsz` }), t2[57] = o3, t2[58] = L); + t2[22] === S2 ? D2 = t2[23] : (D2 = (e39) => void S2(e39), t2[22] = S2, t2[23] = D2); + let O2; + t2[24] === s3 ? O2 = t2[25] : (O2 = s3({ id: `87a/t/` }), t2[24] = s3, t2[25] = O2); + let k2; + t2[26] !== O2 || t2[27] !== l5 ? (k2 = (0, Z5.jsx)(Xn3, { label: O2, onChange: u3, value: l5 }), t2[26] = O2, t2[27] = l5, t2[28] = k2) : k2 = t2[28]; + let A2; + t2[29] === s3 ? A2 = t2[30] : (A2 = s3({ id: `0W0FHK` }), t2[29] = s3, t2[30] = A2); + let j2; + t2[31] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (j2 = (e39) => g5({ name: e39 }), t2[31] = j2) : j2 = t2[31]; + let M2; + t2[32] !== f4.name || t2[33] !== A2 ? (M2 = (0, Z5.jsx)(Xn3, { label: A2, onChange: j2, value: f4.name }), t2[32] = f4.name, t2[33] = A2, t2[34] = M2) : M2 = t2[34]; + let N3; + t2[35] !== k2 || t2[36] !== M2 ? (N3 = (0, Z5.jsxs)(Hn3, { children: [k2, M2] }), t2[35] = k2, t2[36] = M2, t2[37] = N3) : N3 = t2[37]; + let P3; + t2[38] === v5 ? P3 = t2[39] : (P3 = nr2.map((e39) => e39.length === 1 ? e39.map(v5) : (0, Z5.jsx)(Hn3, { children: e39.map(v5) }, e39.map(ar2).join())), t2[38] = v5, t2[39] = P3); + let F2; + t2[40] === s3 ? F2 = t2[41] : (F2 = s3({ id: `zmwvG2` }), t2[40] = s3, t2[41] = F2); + let I2; + t2[42] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (I2 = (e39) => g5({ phone: e39 }), t2[42] = I2) : I2 = t2[42]; + let L3; + t2[43] !== f4.phone || t2[44] !== F2 ? (L3 = (0, Z5.jsx)(Xn3, { label: F2, onChange: I2, value: f4.phone }), t2[43] = f4.phone, t2[44] = F2, t2[45] = L3) : L3 = t2[45]; let R3; - t2[59] !== g3 || t2[60] !== L ? (R3 = (0, Q2.jsx)($3, { label: L, onChange: _2, value: g3 }), t2[59] = g3, t2[60] = L, t2[61] = R3) : R3 = t2[61]; - let z4; - return t2[62] !== b3 || t2[63] !== M3 || t2[64] !== I || t2[65] !== R3 || t2[66] !== x3 || t2[67] !== S3 || t2[68] !== C2 || t2[69] !== w3 || t2[70] !== E3 || t2[71] !== O3 ? (z4 = (0, Q2.jsxs)(b3, { actions: x3, error: S3, label: C2, onSubmit: w3, children: [E3, O3, M3, I, R3] }), t2[62] = b3, t2[63] = M3, t2[64] = I, t2[65] = R3, t2[66] = x3, t2[67] = S3, t2[68] = C2, t2[69] = w3, t2[70] = E3, t2[71] = O3, t2[72] = z4) : z4 = t2[72], z4; -} -function It(e9) { - let { line1: t2, line2: n2, city: r2, region: i3, postalCode: a3, country: o3 } = e9; - return { line1: t2, line2: n2, city: r2, region: i3, postalCode: a3, country: Cge(o3) }; -} -function Lt(e9, t2) { - let n2 = (e10) => e10.trim().toLowerCase().replace(/\s+/g, ` `), r2 = Cge(e9.country), i3 = Cge(t2.country); - return [`line1`, `line2`, `city`, `region`, `postalCode`].every((r3) => n2(e9[r3]) === n2(t2[r3])) && (r2 === `` || i3 === `` || r2 === i3); -} -function Rt2(e9) { - return e9.line1.trim().length > 0; -} -function zt2(e9) { - return e9.flatMap((e10) => e10.contact === void 0 ? [] : [{ credential: e10, contact: e10.contact }]).toSorted((e10, t2) => Number(t2.contact.defaultShipping) - Number(e10.contact.defaultShipping) || e10.credential.title.localeCompare(t2.credential.title)); -} -function Bt2(e9) { - Bt2.d = 1912; - let t2 = (0, X3.c)(17), { addresses: r2, value: i3, onPick: a3 } = e9, { _: o3 } = bb(); - if (r2.length === 0) return null; - let s3; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = { className: `sand-78zum5 sand-dt5ytf sand-11twubx` }, t2[0] = s3) : s3 = t2[0]; - let c2; - t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (c2 = (0, Q2.jsx)(Kd, { as: `span`, color: `secondary`, size: `xs`, children: (0, Q2.jsx)(Sb, { id: `AUlTmE` }) }), t2[1] = c2) : c2 = t2[1]; - let l4; - t2[2] !== r2 || t2[3] !== a3 ? (l4 = (e10) => { - let t3 = e10.currentTarget.value; - a3(r2.find((e11) => e11.credential.id === t3)); - }, t2[2] = r2, t2[3] = a3, t2[4] = l4) : l4 = t2[4]; + t2[46] === s3 ? R3 = t2[47] : (R3 = s3({ id: `ATGYL1` }), t2[46] = s3, t2[47] = R3); + let z2; + t2[48] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (z2 = (e39) => g5({ email: e39 }), t2[48] = z2) : z2 = t2[48]; + let B3; + t2[49] !== f4.email || t2[50] !== R3 ? (B3 = (0, Z5.jsx)(Xn3, { label: R3, onChange: z2, value: f4.email }), t2[49] = f4.email, t2[50] = R3, t2[51] = B3) : B3 = t2[51]; + let U3; + t2[52] !== L3 || t2[53] !== B3 ? (U3 = (0, Z5.jsxs)(Hn3, { children: [L3, B3] }), t2[52] = L3, t2[53] = B3, t2[54] = U3) : U3 = t2[54]; + let W3; + return t2[55] !== i3 || t2[56] !== N3 || t2[57] !== P3 || t2[58] !== U3 || t2[59] !== w2 || t2[60] !== E2 || t2[61] !== D2 || t2[62] !== m3.error ? (W3 = (0, Z5.jsxs)(Vn3, { actions: w2, error: T2, label: E2, onSubmit: D2, removeAction: i3, children: [N3, P3, U3] }), t2[55] = i3, t2[56] = N3, t2[57] = P3, t2[58] = U3, t2[59] = w2, t2[60] = E2, t2[61] = D2, t2[62] = m3.error, t2[63] = W3) : W3 = t2[63], W3; +} +function ar2(e38) { + return e38.key; +} +function or2(e38) { + or2.d = 2125; + let t2 = (0, X5.c)(4), { cancelLabel: n2, onCancel: r2, onDone: i3 } = e38, a3; + return t2[0] !== n2 || t2[1] !== r2 || t2[2] !== i3 ? (a3 = (0, Z5.jsx)(ir2, { cancelLabel: n2, editing: null, onCancel: r2, onDone: i3 }), t2[0] = n2, t2[1] = r2, t2[2] = i3, t2[3] = a3) : a3 = t2[3], a3; +} +function sr2(e38, t2) { + let n2 = (0, X5.c)(11), { _: r2 } = fx(), i3 = v_2(), a3 = Yu3(), o3 = In3(), s3; + n2[0] !== r2 || n2[1] !== a3 || n2[2] !== t2 || n2[3] !== e38 || n2[4] !== i3 || n2[5] !== o3 ? (s3 = async () => await a3(tO({ ...t2, confirmLabel: r2({ id: `t/YqKh` }), cancelLabel: r2({ id: `dEgA5A` }) })) ? o3.run(() => i3.remove(e38), r2({ id: `eWGcnp` })) : false, n2[0] = r2, n2[1] = a3, n2[2] = t2, n2[3] = e38, n2[4] = i3, n2[5] = o3, n2[6] = s3) : s3 = n2[6]; + let c3 = s3, l5; + return n2[7] !== c3 || n2[8] !== o3.error || n2[9] !== o3.isSaving ? (l5 = { error: o3.error, isRemoving: o3.isSaving, confirm: c3 }, n2[7] = c3, n2[8] = o3.error, n2[9] = o3.isSaving, n2[10] = l5) : l5 = n2[10], l5; +} +function cr2(e38) { + cr2.d = 2129; + let t2 = (0, X5.c)(16), { id: n2, label: r2, title: i3, description: a3, onRemoved: o3 } = e38, s3; + t2[0] !== a3 || t2[1] !== i3 ? (s3 = { title: i3, description: a3 }, t2[0] = a3, t2[1] = i3, t2[2] = s3) : s3 = t2[2]; + let c3 = sr2(n2, s3), l5; + t2[3] !== o3 || t2[4] !== c3 ? (l5 = () => void c3.confirm().then((e39) => { + e39 && o3(); + }), t2[3] = o3, t2[4] = c3, t2[5] = l5) : l5 = t2[5]; let u3; - t2[5] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u3 = { className: `sand-1iyjqo2 sand-euugli sand-1ghz6dp sand-knfcqp sand-1awh872 sand-ng3xce sand-1qmwy7c sand-1a2a7pz sand-jbqb8w sand-jb2p0i sand-11wthnw sand-tyxrsu sand-1h7ufjq` }, t2[5] = u3) : u3 = t2[5]; + t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u3 = (0, Z5.jsx)(mx, { id: `t/YqKh` }), t2[6] = u3) : u3 = t2[6]; let d3; - t2[6] === o3 ? d3 = t2[7] : (d3 = o3({ id: `sRag9r` }), t2[6] = o3, t2[7] = d3); + t2[7] !== r2 || t2[8] !== c3.isRemoving || t2[9] !== l5 ? (d3 = (0, Z5.jsx)(LS, { "aria-label": r2, disabled: c3.isRemoving, onClick: l5, pending: c3.isRemoving, sentiment: `danger`, size: `lg`, type: `button`, variant: `secondary`, children: u3 }), t2[7] = r2, t2[8] = c3.isRemoving, t2[9] = l5, t2[10] = d3) : d3 = t2[10]; let f4; - t2[8] === d3 ? f4 = t2[9] : (f4 = (0, Q2.jsx)(`option`, { value: ``, ...mt2, children: d3 }), t2[8] = d3, t2[9] = f4); + t2[11] === c3.error ? f4 = t2[12] : (f4 = (0, Z5.jsx)(Rn3, { error: c3.error }), t2[11] = c3.error, t2[12] = f4); let p4; - t2[10] === r2 ? p4 = t2[11] : (p4 = r2.map(Vt2), t2[10] = r2, t2[11] = p4); - let m3; - return t2[12] !== l4 || t2[13] !== f4 || t2[14] !== p4 || t2[15] !== i3 ? (m3 = (0, Q2.jsxs)(`label`, { ...s3, children: [c2, (0, Q2.jsx)(`div`, { ...ft2, children: (0, Q2.jsxs)(`select`, { onChange: l4, value: i3, ...u3, children: [f4, p4] }) })] }), t2[12] = l4, t2[13] = f4, t2[14] = p4, t2[15] = i3, t2[16] = m3) : m3 = t2[16], m3; -} -function Vt2(e9) { - return (0, Q2.jsx)(`option`, { value: e9.credential.id, ...mt2, children: e9.credential.title }, e9.credential.id); -} -function Ht2(e9) { - Ht2.d = 1889; - let t2 = (0, X3.c)(66), { credential: r2, card: i3, addresses: a3, onDone: o3 } = e9, { _: s3 } = bb(), c2 = kge(), [l4, d3] = (0, Y3.useState)(i3.holderName), f4; - t2[0] === i3 ? f4 = t2[1] : (f4 = vt(i3), t2[0] = i3, t2[1] = f4); - let [p4, m3] = (0, Y3.useState)(f4), h3; - t2[2] === i3.billingAddress ? h3 = t2[3] : (h3 = It(i3.billingAddress), t2[2] = i3.billingAddress, t2[3] = h3); - let [g3, _2] = (0, Y3.useState)(h3), [v3, y3] = (0, Y3.useState)(a3.some((e10) => e10.credential.id === i3.billingAddressId && Lt(It(e10.contact), i3.billingAddress)) ? i3.billingAddressId : ``), b3 = yt(), { brand: x3, last4: S3 } = i3, C2, w3, T3, E3, D2, O3; - if (t2[4] !== s3 || t2[5] !== g3 || t2[6] !== v3 || t2[7] !== x3 || t2[8] !== r2 || t2[9] !== p4 || t2[10] !== l4 || t2[11] !== S3 || t2[12] !== o3 || t2[13] !== c2 || t2[14] !== b3) { - let e10 = s3({ id: `CGtciJ`, values: { brand: x3, last4: S3 } }), n2; - t2[21] === g3 ? n2 = t2[22] : (n2 = (e11) => (0, Q2.jsx)(Nt2, { field: e11, onChange: (t3) => { - y3(``), _2((n3) => ({ ...n3, [e11.key]: t3 })); - }, value: g3[e11.key] }, e11.key), t2[21] = g3, t2[22] = n2), w3 = n2; - let i4; - t2[23] !== s3 || t2[24] !== g3 || t2[25] !== v3 || t2[26] !== r2 || t2[27] !== p4 || t2[28] !== l4 || t2[29] !== o3 || t2[30] !== c2 || t2[31] !== b3 ? (i4 = async (e11) => { - e11.preventDefault(), await b3.run(() => c2.updateCard({ id: r2.id, holderName: l4, expiry: J3({ value: p4 }), billingAddress: g3, billingAddressId: v3 }), s3({ id: `QqKsGg` })) && o3(); - }, t2[23] = s3, t2[24] = g3, t2[25] = v3, t2[26] = r2, t2[27] = p4, t2[28] = l4, t2[29] = o3, t2[30] = c2, t2[31] = b3, t2[32] = i4) : i4 = t2[32]; - let a4 = i4; - C2 = wt; - let u3; - t2[33] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (u3 = (0, Q2.jsx)(Sb, { id: `xGekty` }), t2[33] = u3) : u3 = t2[33], t2[34] !== o3 || t2[35] !== b3.isSaving ? (T3 = (0, Q2.jsx)(Ct, { isSaving: b3.isSaving, onCancel: o3, saveLabel: u3 }), t2[34] = o3, t2[35] = b3.isSaving, t2[36] = T3) : T3 = t2[36], E3 = b3.error, D2 = s3({ id: `ja+MfM`, values: { name: e10 } }), O3 = (e11) => void a4(e11), t2[4] = s3, t2[5] = g3, t2[6] = v3, t2[7] = x3, t2[8] = r2, t2[9] = p4, t2[10] = l4, t2[11] = S3, t2[12] = o3, t2[13] = c2, t2[14] = b3, t2[15] = C2, t2[16] = w3, t2[17] = T3, t2[18] = E3, t2[19] = D2, t2[20] = O3; - } else C2 = t2[15], w3 = t2[16], T3 = t2[17], E3 = t2[18], D2 = t2[19], O3 = t2[20]; - let j3; - t2[37] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (j3 = (0, Q2.jsx)(Kd, { as: `p`, color: `secondary`, size: `xs`, children: (0, Q2.jsx)(Sb, { id: `AomB24` }) }), t2[37] = j3) : j3 = t2[37]; - let M3; - t2[38] === s3 ? M3 = t2[39] : (M3 = s3({ id: `Mf9Gtf` }), t2[38] = s3, t2[39] = M3); - let N2; - t2[40] !== l4 || t2[41] !== M3 ? (N2 = (0, Q2.jsx)($3, { label: M3, onChange: d3, value: l4 }), t2[40] = l4, t2[41] = M3, t2[42] = N2) : N2 = t2[42]; - let P2; - t2[43] === s3 ? P2 = t2[44] : (P2 = s3({ id: `hwlSE2` }), t2[43] = s3, t2[44] = P2); - let F2; - t2[45] !== p4 || t2[46] !== P2 ? (F2 = (0, Q2.jsx)(Pt, { label: P2, onChange: m3, value: p4 }), t2[45] = p4, t2[46] = P2, t2[47] = F2) : F2 = t2[47]; - let I; - t2[48] !== F2 || t2[49] !== N2 ? (I = (0, Q2.jsxs)(Tt, { children: [N2, F2] }), t2[48] = F2, t2[49] = N2, t2[50] = I) : I = t2[50]; - let L; - t2[51] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (L = (e10) => { - y3(e10?.credential.id ?? ``), e10 !== void 0 && _2(It(e10.contact)); - }, t2[51] = L) : L = t2[51]; - let R3; - t2[52] !== a3 || t2[53] !== v3 ? (R3 = (0, Q2.jsx)(Bt2, { addresses: a3, onPick: L, value: v3 }), t2[52] = a3, t2[53] = v3, t2[54] = R3) : R3 = t2[54]; - let z4; - t2[55] === w3 ? z4 = t2[56] : (z4 = ht2.map((e10) => e10.length === 1 ? e10.map(w3) : (0, Q2.jsx)(Tt, { children: e10.map(w3) }, e10.map(Ut2).join())), t2[55] = w3, t2[56] = z4); - let B4; - return t2[57] !== C2 || t2[58] !== I || t2[59] !== R3 || t2[60] !== z4 || t2[61] !== T3 || t2[62] !== E3 || t2[63] !== D2 || t2[64] !== O3 ? (B4 = (0, Q2.jsxs)(C2, { actions: T3, error: E3, label: D2, onSubmit: O3, children: [j3, I, R3, z4] }), t2[57] = C2, t2[58] = I, t2[59] = R3, t2[60] = z4, t2[61] = T3, t2[62] = E3, t2[63] = D2, t2[64] = O3, t2[65] = B4) : B4 = t2[65], B4; -} -function Ut2(e9) { - return e9.key; -} -var Wt2 = new Set(K3.filter((e9) => e9.secret === true).map((e9) => e9.id)); -function Gt2(e9) { - Gt2.d = 1908; - let t2 = (0, X3.c)(40), { cancelLabel: n2, onCancel: r2, onDone: i3, initialFiles: a3 } = e9, o3; - t2[0] === a3 ? o3 = t2[1] : (o3 = a3 === void 0 ? [] : a3, t2[0] = a3, t2[1] = o3); - let s3 = o3, { _: c2 } = bb(), l4 = kge(), d3 = (0, Y3.useRef)(null), f4 = yt(), p4; - t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = {}, t2[2] = p4) : p4 = t2[2]; - let [m3, h3] = (0, Y3.useState)(p4), g3; - t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (g3 = (e10, t3) => h3((n3) => ({ ...n3, [e10]: t3 })), t2[3] = g3) : g3 = t2[3]; - let _2 = g3, v3 = !f4.isSaving, y3; - t2[4] === m3 ? y3 = t2[5] : (y3 = () => ({ ...ze2(d3.current), cc_exp: m3.cc_exp ?? ``, cc_name: m3.cc_name ?? `` }), t2[4] = m3, t2[5] = y3); - let b3; - t2[6] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (b3 = (e10) => { - let t3 = {}; - for (let [n3, r3] of Object.entries(e10)) r3 !== void 0 && (n3 === `cc_number` || n3 === `cc_csc` ? t3[n3] = r3 : _2(n3, r3)); - d3.current !== null && Be2(d3.current, t3); - }, t2[6] = b3) : b3 = t2[6]; - let x3; - t2[7] !== s3 || t2[8] !== v3 || t2[9] !== y3 ? (x3 = { canAct: v3, initialFiles: s3, currentValues: y3, onFill: b3 }, t2[7] = s3, t2[8] = v3, t2[9] = y3, t2[10] = x3) : x3 = t2[10]; - let S3 = ke2(x3), C2; - t2[11] !== c2 || t2[12] !== i3 || t2[13] !== l4 || t2[14] !== f4 ? (C2 = async (e10) => { - e10.preventDefault(); - let t3 = d3.current; - if (t3 === null) return; - let n3 = {}; - for (let { id: e11 } of K3) { - let r3 = t3.elements.namedItem(e11), i4 = r3 instanceof HTMLInputElement2 || r3 instanceof HTMLSelectElement ? r3.value.trim() : ``, a4 = e11 === `cc_exp` ? J3({ value: i4 }) : i4; - a4.length > 0 && (n3[e11] = a4); - } - await f4.run(() => l4.createCard({ values: n3 }), c2({ id: `QqKsGg` })) && i3(); - }, t2[11] = c2, t2[12] = i3, t2[13] = l4, t2[14] = f4, t2[15] = C2) : C2 = t2[15]; - let w3 = C2, T3; - t2[16] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (T3 = (0, Q2.jsx)(Sb, { id: `xGekty` }), t2[16] = T3) : T3 = t2[16]; - let E3; - t2[17] !== n2 || t2[18] !== r2 || t2[19] !== f4.isSaving ? (E3 = (0, Q2.jsx)(Ct, { cancelLabel: n2, isSaving: f4.isSaving, onCancel: r2, saveLabel: T3 }), t2[17] = n2, t2[18] = r2, t2[19] = f4.isSaving, t2[20] = E3) : E3 = t2[20]; - let D2 = f4.error, O3; - t2[21] === c2 ? O3 = t2[22] : (O3 = c2({ id: `pnrmSP` }), t2[21] = c2, t2[22] = O3); - let j3; - t2[23] === w3 ? j3 = t2[24] : (j3 = (e10) => void w3(e10), t2[23] = w3, t2[24] = j3); - let M3; - t2[25] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (M3 = At(), t2[25] = M3) : M3 = t2[25]; - let N2; - t2[26] === m3 ? N2 = t2[27] : (N2 = (e10) => Wt2.has(e10) ? void 0 : m3[e10] ?? ``, t2[26] = m3, t2[27] = N2); - let P2; - t2[28] !== S3 || t2[29] !== N2 ? (P2 = (0, Q2.jsx)(nt3, { fields: M3, onValueChange: _2, photoFill: S3, valueOf: N2 }), t2[28] = S3, t2[29] = N2, t2[30] = P2) : P2 = t2[30]; - let F2; - t2[31] !== E3 || t2[32] !== O3 || t2[33] !== j3 || t2[34] !== P2 || t2[35] !== f4.error ? (F2 = (0, Q2.jsx)(wt, { actions: E3, error: D2, formRef: d3, label: O3, onSubmit: j3, children: P2 }), t2[31] = E3, t2[32] = O3, t2[33] = j3, t2[34] = P2, t2[35] = f4.error, t2[36] = F2) : F2 = t2[36]; - let I; - return t2[37] !== S3 || t2[38] !== F2 ? (I = (0, Q2.jsx)(Fe2, { fill: S3, children: F2 }), t2[37] = S3, t2[38] = F2, t2[39] = I) : I = t2[39], I; -} -function Kt2(e9) { - Kt2.d = 1910; - let t2 = (0, X3.c)(4), { cancelLabel: n2, onCancel: r2, onDone: i3 } = e9, a3; - return t2[0] !== n2 || t2[1] !== r2 || t2[2] !== i3 ? (a3 = (0, Q2.jsx)(Ft, { cancelLabel: n2, editing: null, onCancel: r2, onDone: i3 }), t2[0] = n2, t2[1] = r2, t2[2] = i3, t2[3] = a3) : a3 = t2[3], a3; -} -var qt2 = [{ id: `login`, label: { id: `z0t9bb` }, description: { id: `x5oYhz` }, formTitle: { id: `3UUCyn` }, icon: `key`, gate: null, Form: Kt2 }, { id: `card`, label: { id: `kryGs+` }, description: { id: `18LOMS` }, formTitle: { id: `pnrmSP` }, icon: `credit-card`, gate: yge, Form: Gt2 }, { id: `contact`, label: { id: `jfC/xh` }, description: { id: `Corqen` }, formTitle: { id: `USnyM6` }, icon: `person`, gate: null, Form: tn }]; -function Jt(e9) { - Jt.d = 1911; - let t2 = (0, X3.c)(14), { types: n2, onClose: r2 } = e9, { _: i3 } = bb(), a3 = n2.length === 1 ? n2[0] : void 0, [o3, s3] = (0, Y3.useState)(a3 ?? null), c2; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (c2 = (0, Q2.jsx)(tC, { "aria-hidden": true, name: `lock`, size: `sm` }), t2[0] = c2) : c2 = t2[0]; - let l4; - t2[1] !== i3 || t2[2] !== o3 ? (l4 = i3(o3 === null ? { id: `KofAh0` } : o3.formTitle), t2[1] = i3, t2[2] = o3, t2[3] = l4) : l4 = t2[3]; + return t2[13] !== d3 || t2[14] !== f4 ? (p4 = (0, Z5.jsxs)(Z5.Fragment, { children: [d3, f4] }), t2[13] = d3, t2[14] = f4, t2[15] = p4) : p4 = t2[15], p4; +} +function lr2(e38) { + lr2.d = 2116; + let t2 = (0, X5.c)(45), { credential: n2, onClose: r2 } = e38, { _: i3 } = fx(), a3, o3, s3, c3, l5, u3, d3, f4, p4, m3, h4, g5, _5, v5, y4, b2; + if (t2[0] !== i3 || t2[1] !== n2 || t2[2] !== r2) { + let e39 = n2.contact === void 0 ? n2.title : Qt4(n2, n2.contact); + s3 = v2, t2[19] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (b2 = (0, Z5.jsx)(aS, { "aria-hidden": true, name: `person`, size: `sm` }), t2[19] = b2) : b2 = t2[19], l5 = r2, t2[20] === i3 ? u3 = t2[21] : (u3 = i3({ id: `vcQwyD` }), t2[20] = i3, t2[21] = u3), d3 = true, f4 = 520, o3 = ir2, _5 = n2, v5 = r2, y4 = r2, a3 = cr2, t2[22] === i3 ? c3 = t2[23] : (c3 = i3({ id: `zJNxoa` }), t2[22] = i3, t2[23] = c3), p4 = n2.id, m3 = i3({ id: `HLazKQ`, values: { name: e39 } }), h4 = r2, g5 = i3({ id: `DfnecK`, values: { name: e39 } }), t2[0] = i3, t2[1] = n2, t2[2] = r2, t2[3] = a3, t2[4] = o3, t2[5] = s3, t2[6] = c3, t2[7] = l5, t2[8] = u3, t2[9] = d3, t2[10] = f4, t2[11] = p4, t2[12] = m3, t2[13] = h4, t2[14] = g5, t2[15] = _5, t2[16] = v5, t2[17] = y4, t2[18] = b2; + } else a3 = t2[3], o3 = t2[4], s3 = t2[5], c3 = t2[6], l5 = t2[7], u3 = t2[8], d3 = t2[9], f4 = t2[10], p4 = t2[11], m3 = t2[12], h4 = t2[13], g5 = t2[14], _5 = t2[15], v5 = t2[16], y4 = t2[17], b2 = t2[18]; + let x2; + t2[24] !== a3 || t2[25] !== c3 || t2[26] !== p4 || t2[27] !== m3 || t2[28] !== h4 || t2[29] !== g5 ? (x2 = (0, Z5.jsx)(a3, { description: c3, id: p4, label: m3, onRemoved: h4, title: g5 }), t2[24] = a3, t2[25] = c3, t2[26] = p4, t2[27] = m3, t2[28] = h4, t2[29] = g5, t2[30] = x2) : x2 = t2[30]; + let S2; + t2[31] !== o3 || t2[32] !== x2 || t2[33] !== _5 || t2[34] !== v5 || t2[35] !== y4 ? (S2 = (0, Z5.jsx)(o3, { editing: _5, onCancel: v5, onDone: y4, removeAction: x2 }), t2[31] = o3, t2[32] = x2, t2[33] = _5, t2[34] = v5, t2[35] = y4, t2[36] = S2) : S2 = t2[36]; + let C2; + return t2[37] !== s3 || t2[38] !== l5 || t2[39] !== u3 || t2[40] !== d3 || t2[41] !== f4 || t2[42] !== S2 || t2[43] !== b2 ? (C2 = (0, Z5.jsx)(s3, { icon: b2, onClose: l5, title: u3, titleInTitlebar: d3, width: f4, children: S2 }), t2[37] = s3, t2[38] = l5, t2[39] = u3, t2[40] = d3, t2[41] = f4, t2[42] = S2, t2[43] = b2, t2[44] = C2) : C2 = t2[44], C2; +} +function ur2(e38) { + ur2.d = 2126; + let t2 = (0, X5.c)(25), { types: n2, disabled: r2, onPick: i3, onImport: a3 } = e38, { _: o3 } = fx(), s3; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = (0, Z5.jsx)(mx, { id: `KofAh0` }), t2[0] = s3) : s3 = t2[0]; + let c3; + t2[1] === r2 ? c3 = t2[2] : (c3 = (0, Z5.jsx)(bT.Trigger, { children: (0, Z5.jsx)(LS, { disabled: r2, size: `md`, style: Jb2.body2, trailingIcon: `chevron-down`, variant: `primary`, children: s3 }) }), t2[1] = r2, t2[2] = c3); + let l5; + t2[3] === o3 ? l5 = t2[4] : (l5 = o3({ id: `KofAh0` }), t2[3] = o3, t2[4] = l5); let u3; - t2[4] !== i3 || t2[5] !== r2 || t2[6] !== a3 || t2[7] !== o3 || t2[8] !== n2 ? (u3 = o3 === null ? (0, Q2.jsx)(Aw, { label: i3({ id: `KofAh0` }), role: `group`, children: n2.map((e10) => (0, Q2.jsx)(jw, { description: i3(e10.description), label: i3(e10.label), leading: (0, Q2.jsx)(nn, { children: (0, Q2.jsx)(tC, { name: e10.icon, size: `sm` }) }), onClick: () => s3(e10), trailing: (0, Q2.jsx)(tC, { "aria-hidden": true, name: `chevron-right`, size: `sm` }) }, e10.id)) }) : (0, Q2.jsx)(o3.Form, { cancelLabel: a3 === void 0 ? (0, Q2.jsx)(Sb, { id: `iH8pgl` }) : (0, Q2.jsx)(Sb, { id: `dEgA5A` }), onCancel: a3 === void 0 ? () => s3(null) : r2, onDone: r2 }), t2[4] = i3, t2[5] = r2, t2[6] = a3, t2[7] = o3, t2[8] = n2, t2[9] = u3) : u3 = t2[9]; - let d3; - return t2[10] !== r2 || t2[11] !== l4 || t2[12] !== u3 ? (d3 = (0, Q2.jsx)(U3, { icon: c2, onClose: r2, title: l4, titleInTitlebar: true, width: 520, children: u3 }), t2[10] = r2, t2[11] = l4, t2[12] = u3, t2[13] = d3) : d3 = t2[13], d3; -} -function Yt(e9) { - Yt.d = 1890; - let t2 = (0, X3.c)(11), { files: n2, onClose: r2 } = e9, { _: i3 } = bb(), a3; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (a3 = (0, Q2.jsx)(tC, { "aria-hidden": true, name: `credit-card`, size: `sm` }), t2[0] = a3) : a3 = t2[0]; - let o3; - t2[1] === i3 ? o3 = t2[2] : (o3 = i3({ id: `pnrmSP` }), t2[1] = i3, t2[2] = o3); - let s3; - t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (s3 = (0, Q2.jsx)(Sb, { id: `dEgA5A` }), t2[3] = s3) : s3 = t2[3]; - let c2; - t2[4] !== n2 || t2[5] !== r2 ? (c2 = (0, Q2.jsx)(Gt2, { cancelLabel: s3, initialFiles: n2, onCancel: r2, onDone: r2 }), t2[4] = n2, t2[5] = r2, t2[6] = c2) : c2 = t2[6]; - let l4; - return t2[7] !== r2 || t2[8] !== o3 || t2[9] !== c2 ? (l4 = (0, Q2.jsx)(U3, { icon: a3, onClose: r2, title: o3, titleInTitlebar: true, width: 520, children: c2 }), t2[7] = r2, t2[8] = o3, t2[9] = c2, t2[10] = l4) : l4 = t2[10], l4; -} -var Xt = { name: ``, line1: ``, line2: ``, city: ``, region: ``, postalCode: ``, country: ``, phone: ``, email: ``, defaultShipping: false }; -var Zt = [[{ key: `line1`, label: { id: `Du6bPw` } }], ...ht2.slice(1)]; -function Qt(e9) { - if (e9 === void 0) return Xt; - let t2 = Cge(e9.country); - return { ...e9, country: wge(t2) ? t2 : `` }; -} -function $t(e9) { - $t.d = 1893; - let t2 = (0, X3.c)(77), { editing: r2, cancelLabel: i3, onCancel: a3, onDone: o3 } = e9, { _: s3 } = bb(), c2 = kge(), l4 = (0, Y3.useId)(), [d3, f4] = (0, Y3.useState)(r2?.title ?? ``), m3; - t2[0] === r2?.contact ? m3 = t2[1] : (m3 = () => Qt(r2?.contact), t2[0] = r2?.contact, t2[1] = m3); - let [h3, g3] = (0, Y3.useState)(m3), _2 = yt(), v3; - t2[2] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (v3 = (e10) => g3((t3) => ({ ...t3, ...e10 })), t2[2] = v3) : v3 = t2[2]; - let y3 = v3, b3; - t2[3] === h3 ? b3 = t2[4] : (b3 = (e10) => (0, Q2.jsx)(Nt2, { field: e10, onChange: (t3) => y3({ [e10.key]: t3 }), value: h3[e10.key] }, e10.key), t2[3] = h3, t2[4] = b3); - let x3 = b3, S3 = r2?.title ?? ``, C2; - t2[5] === h3 ? C2 = t2[6] : (C2 = Rt2(h3), t2[5] = h3, t2[6] = C2); - let w3 = C2, T3; - t2[7] !== s3 || t2[8] !== w3 || t2[9] !== h3 || t2[10] !== r2?.id || t2[11] !== o3 || t2[12] !== d3 || t2[13] !== c2 || t2[14] !== _2 ? (T3 = async (e10) => { - e10.preventDefault(); - let t3 = { ...h3, defaultShipping: h3.defaultShipping && w3 }; - await _2.run(() => c2.putContact({ id: r2?.id ?? ``, title: d3, contact: t3 }), s3({ id: `QqKsGg` })) && o3(); - }, t2[7] = s3, t2[8] = w3, t2[9] = h3, t2[10] = r2?.id, t2[11] = o3, t2[12] = d3, t2[13] = c2, t2[14] = _2, t2[15] = T3) : T3 = t2[15]; - let E3 = T3, D2; - t2[16] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (D2 = (0, Q2.jsx)(Sb, { id: `PAx2Yh` }), t2[16] = D2) : D2 = t2[16]; - let O3; - t2[17] !== i3 || t2[18] !== a3 || t2[19] !== _2.isSaving ? (O3 = (0, Q2.jsx)(Ct, { cancelLabel: i3, isSaving: _2.isSaving, onCancel: a3, saveLabel: D2 }), t2[17] = i3, t2[18] = a3, t2[19] = _2.isSaving, t2[20] = O3) : O3 = t2[20]; - let j3 = _2.error, M3; - t2[21] !== s3 || t2[22] !== r2 || t2[23] !== S3 ? (M3 = s3(r2 === null ? { id: `USnyM6` } : { id: `ja+MfM`, values: { name: S3 } }), t2[21] = s3, t2[22] = r2, t2[23] = S3, t2[24] = M3) : M3 = t2[24]; - let N2; - t2[25] === E3 ? N2 = t2[26] : (N2 = (e10) => void E3(e10), t2[25] = E3, t2[26] = N2); - let P2; - t2[27] === s3 ? P2 = t2[28] : (P2 = s3({ id: `87a/t/` }), t2[27] = s3, t2[28] = P2); - let F2; - t2[29] !== P2 || t2[30] !== d3 ? (F2 = (0, Q2.jsx)($3, { label: P2, onChange: f4, value: d3 }), t2[29] = P2, t2[30] = d3, t2[31] = F2) : F2 = t2[31]; - let I; - t2[32] === s3 ? I = t2[33] : (I = s3({ id: `0W0FHK` }), t2[32] = s3, t2[33] = I); - let L; - t2[34] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (L = (e10) => y3({ name: e10 }), t2[34] = L) : L = t2[34]; - let R3; - t2[35] !== h3.name || t2[36] !== I ? (R3 = (0, Q2.jsx)($3, { label: I, onChange: L, value: h3.name }), t2[35] = h3.name, t2[36] = I, t2[37] = R3) : R3 = t2[37]; - let z4; - t2[38] !== F2 || t2[39] !== R3 ? (z4 = (0, Q2.jsxs)(Tt, { children: [F2, R3] }), t2[38] = F2, t2[39] = R3, t2[40] = z4) : z4 = t2[40]; - let B4; - t2[41] === x3 ? B4 = t2[42] : (B4 = Zt.map((e10) => e10.length === 1 ? e10.map(x3) : (0, Q2.jsx)(Tt, { children: e10.map(x3) }, e10.map(en).join())), t2[41] = x3, t2[42] = B4); - let V4; - t2[43] === s3 ? V4 = t2[44] : (V4 = s3({ id: `zmwvG2` }), t2[43] = s3, t2[44] = V4); - let H4; - t2[45] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (H4 = (e10) => y3({ phone: e10 }), t2[45] = H4) : H4 = t2[45]; - let U4; - t2[46] !== h3.phone || t2[47] !== V4 ? (U4 = (0, Q2.jsx)($3, { label: V4, onChange: H4, value: h3.phone }), t2[46] = h3.phone, t2[47] = V4, t2[48] = U4) : U4 = t2[48]; - let W4; - t2[49] === s3 ? W4 = t2[50] : (W4 = s3({ id: `ATGYL1` }), t2[49] = s3, t2[50] = W4); - let G5; - t2[51] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (G5 = (e10) => y3({ email: e10 }), t2[51] = G5) : G5 = t2[51]; - let K4; - t2[52] !== h3.email || t2[53] !== W4 ? (K4 = (0, Q2.jsx)($3, { label: W4, onChange: G5, value: h3.email }), t2[52] = h3.email, t2[53] = W4, t2[54] = K4) : K4 = t2[54]; - let ee2; - t2[55] !== U4 || t2[56] !== K4 ? (ee2 = (0, Q2.jsxs)(Tt, { children: [U4, K4] }), t2[55] = U4, t2[56] = K4, t2[57] = ee2) : ee2 = t2[57]; - let q4; - t2[58] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (q4 = { className: `sand-78zum5 sand-6s0dn4 sand-ehausa` }, t2[58] = q4) : q4 = t2[58]; - let te3 = h3.defaultShipping && w3, ne3 = !w3, re4; - t2[59] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (re4 = (e10) => y3({ defaultShipping: e10 }), t2[59] = re4) : re4 = t2[59]; - let J4; - t2[60] !== l4 || t2[61] !== te3 || t2[62] !== ne3 ? (J4 = (0, Q2.jsx)(OC, { id: l4, isChecked: te3, isDisabled: ne3, onChange: re4 }), t2[60] = l4, t2[61] = te3, t2[62] = ne3, t2[63] = J4) : J4 = t2[63]; - let ie4; - t2[64] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (ie4 = (0, Q2.jsx)(Kd, { as: `span`, size: `xs`, children: (0, Q2.jsx)(Sb, { id: `6cXc68` }) }), t2[64] = ie4) : ie4 = t2[64]; - let Z4; - t2[65] !== l4 || t2[66] !== J4 ? (Z4 = (0, Q2.jsxs)(`label`, { htmlFor: l4, ...q4, children: [J4, ie4] }), t2[65] = l4, t2[66] = J4, t2[67] = Z4) : Z4 = t2[67]; - let ae4; - return t2[68] !== N2 || t2[69] !== z4 || t2[70] !== B4 || t2[71] !== ee2 || t2[72] !== Z4 || t2[73] !== O3 || t2[74] !== M3 || t2[75] !== _2.error ? (ae4 = (0, Q2.jsxs)(wt, { actions: O3, error: j3, label: M3, onSubmit: N2, children: [z4, B4, ee2, Z4] }), t2[68] = N2, t2[69] = z4, t2[70] = B4, t2[71] = ee2, t2[72] = Z4, t2[73] = O3, t2[74] = M3, t2[75] = _2.error, t2[76] = ae4) : ae4 = t2[76], ae4; -} -function en(e9) { - return e9.key; -} -function tn(e9) { - tn.d = 1909; - let t2 = (0, X3.c)(4), { cancelLabel: n2, onCancel: r2, onDone: i3 } = e9, a3; - return t2[0] !== n2 || t2[1] !== r2 || t2[2] !== i3 ? (a3 = (0, Q2.jsx)($t, { cancelLabel: n2, editing: null, onCancel: r2, onDone: i3 }), t2[0] = n2, t2[1] = r2, t2[2] = i3, t2[3] = a3) : a3 = t2[3], a3; -} -function nn(e9) { - nn.d = 1904; - let t2 = (0, X3.c)(3), { children: n2 } = e9, r2; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (r2 = { className: `sand-3nfvp2 sand-6s0dn4 sand-l56j7k sand-2lah0s sand-vy4d1p sand-xk0z11 sand-qjedn3 sand-1y0btm7 sand-17tbahu sand-1e1y6u3 sand-y5h43f sand-1s688f` }, t2[0] = r2) : r2 = t2[0]; - let i3; - return t2[1] === n2 ? i3 = t2[2] : (i3 = (0, Q2.jsx)(`span`, { "aria-hidden": `true`, ...r2, children: n2 }), t2[1] = n2, t2[2] = i3), i3; -} -function rn(e9) { - rn.d = 1916; - let t2 = (0, X3.c)(21), { tile: r2, primary: i3, secondary: a3, error: o3, children: s3 } = e9, c2; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (c2 = h(ct2.row, sx.body2), t2[0] = c2) : c2 = t2[0]; - let l4, u3; - t2[1] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (l4 = { className: `sand-78zum5 sand-dt5ytf sand-1iyjqo2 sand-euugli` }, u3 = { className: `sand-b3r6kr sand-lyipyv sand-uxw1ft` }, t2[1] = l4, t2[2] = u3) : (l4 = t2[1], u3 = t2[2]); + if (t2[5] !== o3 || t2[6] !== i3 || t2[7] !== n2) { + let e39; + t2[9] !== o3 || t2[10] !== i3 ? (e39 = (e40) => (0, Z5.jsx)(bT.Item, { leading: (0, Z5.jsx)(aS, { name: e40.icon, size: `md` }), onSelect: () => i3(e40), children: o3(e40.label) }, e40.id), t2[9] = o3, t2[10] = i3, t2[11] = e39) : e39 = t2[11], u3 = n2.map(e39), t2[5] = o3, t2[6] = i3, t2[7] = n2, t2[8] = u3; + } else u3 = t2[8]; let d3; - t2[3] === i3 ? d3 = t2[4] : (d3 = (0, Q2.jsx)(`span`, { ...u3, children: i3 }), t2[3] = i3, t2[4] = d3); + t2[12] === u3 ? d3 = t2[13] : (d3 = (0, Z5.jsx)(bT.Section, { children: u3 }), t2[12] = u3, t2[13] = d3); let f4; - t2[5] === o3 ? f4 = t2[6] : (f4 = o3 === null ? null : (0, Q2.jsx)(Kd, { as: `span`, color: `red`, role: `alert`, size: `xs`, children: o3 }), t2[5] = o3, t2[6] = f4); + t2[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f4 = (0, Z5.jsx)(aS, { name: `file-text`, size: `md` }), t2[14] = f4) : f4 = t2[14]; let p4; - t2[7] !== o3 || t2[8] !== a3 ? (p4 = o3 === null && a3 !== null ? (0, Q2.jsx)(`span`, { ...h(ct2.secondary, sx.caption), children: a3 }) : null, t2[7] = o3, t2[8] = a3, t2[9] = p4) : p4 = t2[9]; + t2[15] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (p4 = (0, Z5.jsx)(mx, { id: `yrzweQ` }), t2[15] = p4) : p4 = t2[15]; let m3; - t2[10] !== d3 || t2[11] !== f4 || t2[12] !== p4 ? (m3 = (0, Q2.jsxs)(`span`, { ...l4, children: [d3, f4, p4] }), t2[10] = d3, t2[11] = f4, t2[12] = p4, t2[13] = m3) : m3 = t2[13]; - let h3; - t2[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (h3 = { className: `sand-78zum5 sand-2lah0s sand-pkkfsy` }, t2[14] = h3) : h3 = t2[14]; - let g3; - t2[15] === s3 ? g3 = t2[16] : (g3 = (0, Q2.jsx)(`span`, { ...h3, children: s3 }), t2[15] = s3, t2[16] = g3); - let _2; - return t2[17] !== m3 || t2[18] !== g3 || t2[19] !== r2 ? (_2 = (0, Q2.jsxs)(`div`, { ...c2, children: [r2, m3, g3] }), t2[17] = m3, t2[18] = g3, t2[19] = r2, t2[20] = _2) : _2 = t2[20], _2; -} -function an(e9, t2) { - let n2 = (0, X3.c)(11), { _: r2 } = bb(), i3 = kge(), a3 = nd(), o3 = yt(), s3; - n2[0] !== r2 || n2[1] !== a3 || n2[2] !== t2 || n2[3] !== e9 || n2[4] !== i3 || n2[5] !== o3 ? (s3 = async () => { - await a3(PO({ ...t2, confirmLabel: r2({ id: `t/YqKh` }), cancelLabel: r2({ id: `dEgA5A` }) })) && await o3.run(() => i3.remove(e9), r2({ id: `eWGcnp` })); - }, n2[0] = r2, n2[1] = a3, n2[2] = t2, n2[3] = e9, n2[4] = i3, n2[5] = o3, n2[6] = s3) : s3 = n2[6]; - let c2 = s3, l4; - return n2[7] !== c2 || n2[8] !== o3.error || n2[9] !== o3.isSaving ? (l4 = { error: o3.error, isRemoving: o3.isSaving, confirm: c2 }, n2[7] = c2, n2[8] = o3.error, n2[9] = o3.isSaving, n2[10] = l4) : l4 = n2[10], l4; -} -function on(e9) { - on.d = 1906; - let t2 = (0, X3.c)(10), { credential: n2, disabled: r2, onEdit: i3 } = e9, { _: a3 } = bb(), s3 = _t2(n2), c2 = n2.username.length === 0 ? null : n2.username, l4 = c2 === null ? s3 : `${s3} (${c2})`, u3 = an(n2.id, { title: a3({ id: `Yk6n1o` }), description: a3({ id: `Mm9cq/`, values: { name: l4 } }) }), d3 = u3.error, f4; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (f4 = (0, Q2.jsx)(Sb, { id: `ePK91l` }), t2[0] = f4) : f4 = t2[0]; - let p4 = MC, m3 = a3({ id: `Hi5XX+`, values: { name: l4 } }), h3 = r2 || u3.isRemoving, g3; - t2[1] === u3 ? g3 = t2[2] : (g3 = () => void u3.confirm(), t2[1] = u3, t2[2] = g3); - let _2; - t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (_2 = (0, Q2.jsx)(Sb, { id: `t/YqKh` }), t2[3] = _2) : _2 = t2[3]; - let v3; - return t2[4] !== p4 || t2[5] !== u3.isRemoving || t2[6] !== m3 || t2[7] !== h3 || t2[8] !== g3 ? (v3 = (0, Q2.jsx)(p4, { "aria-label": m3, disabled: h3, onClick: g3, pending: u3.isRemoving, sentiment: `danger`, size: `sm`, type: `button`, variant: `secondary`, children: _2 }), t2[4] = p4, t2[5] = u3.isRemoving, t2[6] = m3, t2[7] = h3, t2[8] = g3, t2[9] = v3) : v3 = t2[9], (0, Q2.jsxs)(rn, { error: d3, primary: s3, secondary: c2, tile: (0, Q2.jsx)(nn, { children: s3.charAt(0).toUpperCase() }), children: [(0, Q2.jsx)(MC, { "aria-label": a3({ id: `6ixmzu`, values: { name: l4 } }), disabled: r2 || u3.isRemoving, onClick: i3, size: `sm`, type: `button`, variant: `secondary`, children: f4 }), v3] }); -} -function sn(e9) { - sn.d = 1891; - let t2 = (0, X3.c)(18), { credential: n2, card: r2, disabled: i3, onEdit: a3 } = e9, { _: s3 } = bb(), { brand: c2, last4: l4, holderName: u3 } = r2, d3 = s3({ id: `CGtciJ`, values: { brand: c2, last4: l4 } }), f4 = vt(r2), p4 = an(n2.id, { title: s3({ id: `DfnecK`, values: { name: d3 } }), description: s3({ id: `mtX2At` }) }), m3 = rn, h3 = p4.error, g3 = u3.length === 0 ? s3({ id: `zBCQ3P`, values: { expiry: f4 } }) : s3({ id: `4dHPeH`, values: { holderName: u3, expiry: f4 } }), _2; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (_2 = (0, Q2.jsx)(nn, { children: (0, Q2.jsx)(tC, { name: `credit-card`, size: `sm` }) }), t2[0] = _2) : _2 = t2[0]; - let v3 = a3 === null ? null : (0, Q2.jsx)(MC, { "aria-label": s3({ id: `ja+MfM`, values: { name: d3 } }), disabled: i3 || p4.isRemoving, onClick: a3, size: `sm`, type: `button`, variant: `secondary`, children: (0, Q2.jsx)(Sb, { id: `ePK91l` }) }), y3 = MC, b3 = s3({ id: `HLazKQ`, values: { name: d3 } }), x3 = i3 || p4.isRemoving, S3; - t2[1] === p4 ? S3 = t2[2] : (S3 = () => void p4.confirm(), t2[1] = p4, t2[2] = S3); - let C2; - t2[3] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (C2 = (0, Q2.jsx)(Sb, { id: `t/YqKh` }), t2[3] = C2) : C2 = t2[3]; - let w3; - t2[4] !== y3 || t2[5] !== p4.isRemoving || t2[6] !== b3 || t2[7] !== x3 || t2[8] !== S3 ? (w3 = (0, Q2.jsx)(y3, { "aria-label": b3, disabled: x3, onClick: S3, pending: p4.isRemoving, sentiment: `danger`, size: `sm`, type: `button`, variant: `secondary`, children: C2 }), t2[4] = y3, t2[5] = p4.isRemoving, t2[6] = b3, t2[7] = x3, t2[8] = S3, t2[9] = w3) : w3 = t2[9]; - let T3; - return t2[10] !== m3 || t2[11] !== d3 || t2[12] !== p4.error || t2[13] !== g3 || t2[14] !== _2 || t2[15] !== v3 || t2[16] !== w3 ? (T3 = (0, Q2.jsxs)(m3, { error: h3, primary: d3, secondary: g3, tile: _2, children: [v3, w3] }), t2[10] = m3, t2[11] = d3, t2[12] = p4.error, t2[13] = g3, t2[14] = _2, t2[15] = v3, t2[16] = w3, t2[17] = T3) : T3 = t2[17], T3; -} -function cn(e9) { - let { name: t2, line1: n2, line2: r2, city: i3, region: a3, postalCode: o3, country: s3, phone: c2, email: l4 } = e9; - return [t2, n2, r2, i3, a3, o3, s3, c2, l4].filter((e10) => e10.length > 0).join(`, `); -} -function ln(e9) { - ln.d = 1894; - let t2 = (0, X3.c)(35), { credential: n2, contact: r2, disabled: i3, onEdit: a3 } = e9, { _: s3 } = bb(), c2 = n2.title, l4 = cn(r2), u3 = n2.id, d3; - t2[0] !== s3 || t2[1] !== c2 ? (d3 = s3({ id: `DfnecK`, values: { name: c2 } }), t2[0] = s3, t2[1] = c2, t2[2] = d3) : d3 = t2[2]; - let f4; - t2[3] === s3 ? f4 = t2[4] : (f4 = s3({ id: `zJNxoa` }), t2[3] = s3, t2[4] = f4); - let p4; - t2[5] !== d3 || t2[6] !== f4 ? (p4 = { title: d3, description: f4 }, t2[5] = d3, t2[6] = f4, t2[7] = p4) : p4 = t2[7]; - let m3 = an(u3, p4), h3 = rn, g3 = m3.error, _2 = r2.defaultShipping ? s3({ id: `0k9c6p`, values: { summary: l4 } }) : l4, v3; - t2[8] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (v3 = (0, Q2.jsx)(nn, { children: (0, Q2.jsx)(tC, { name: `person`, size: `sm` }) }), t2[8] = v3) : v3 = t2[8]; - let y3; - t2[9] !== s3 || t2[10] !== c2 ? (y3 = s3({ id: `ja+MfM`, values: { name: c2 } }), t2[9] = s3, t2[10] = c2, t2[11] = y3) : y3 = t2[11]; - let b3 = i3 || m3.isRemoving, x3; - t2[12] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (x3 = (0, Q2.jsx)(Sb, { id: `ePK91l` }), t2[12] = x3) : x3 = t2[12]; - let S3; - t2[13] !== a3 || t2[14] !== y3 || t2[15] !== b3 ? (S3 = (0, Q2.jsx)(MC, { "aria-label": y3, disabled: b3, onClick: a3, size: `sm`, type: `button`, variant: `secondary`, children: x3 }), t2[13] = a3, t2[14] = y3, t2[15] = b3, t2[16] = S3) : S3 = t2[16]; - let C2; - t2[17] !== s3 || t2[18] !== c2 ? (C2 = s3({ id: `HLazKQ`, values: { name: c2 } }), t2[17] = s3, t2[18] = c2, t2[19] = C2) : C2 = t2[19]; - let w3 = i3 || m3.isRemoving, T3; - t2[20] === m3 ? T3 = t2[21] : (T3 = () => void m3.confirm(), t2[20] = m3, t2[21] = T3); - let E3; - t2[22] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (E3 = (0, Q2.jsx)(Sb, { id: `t/YqKh` }), t2[22] = E3) : E3 = t2[22]; - let D2; - t2[23] !== m3.isRemoving || t2[24] !== C2 || t2[25] !== w3 || t2[26] !== T3 ? (D2 = (0, Q2.jsx)(MC, { "aria-label": C2, disabled: w3, onClick: T3, pending: m3.isRemoving, sentiment: `danger`, size: `sm`, type: `button`, variant: `secondary`, children: E3 }), t2[23] = m3.isRemoving, t2[24] = C2, t2[25] = w3, t2[26] = T3, t2[27] = D2) : D2 = t2[27]; - let j3; - return t2[28] !== h3 || t2[29] !== c2 || t2[30] !== m3.error || t2[31] !== S3 || t2[32] !== D2 || t2[33] !== _2 ? (j3 = (0, Q2.jsxs)(h3, { error: g3, primary: c2, secondary: _2, tile: v3, children: [S3, D2] }), t2[28] = h3, t2[29] = c2, t2[30] = m3.error, t2[31] = S3, t2[32] = D2, t2[33] = _2, t2[34] = j3) : j3 = t2[34], j3; -} -function un(e9) { - un.d = 1897; - let t2 = (0, X3.c)(2), { label: n2 } = e9, r2; - return t2[0] === n2 ? r2 = t2[1] : (r2 = (0, Q2.jsx)(M2, { anchorId: oo, label: n2, variant: `card`, children: null }), t2[0] = n2, t2[1] = r2), r2; -} -function dn(e9) { - dn.d = 1907; - let t2 = (0, X3.c)(18), { items: n2, form: r2, setForm: i3 } = e9, { _: a3 } = bb(), o3, s3, c2, l4; - if (t2[0] !== a3 || t2[1] !== r2 || t2[2] !== n2 || t2[3] !== i3) { - let e10 = n2.filter(pn).toSorted(fn); - o3 = S2, t2[8] === a3 ? s3 = t2[9] : (s3 = a3({ id: `NLLW52` }), t2[8] = a3, t2[9] = s3), c2 = e10.length === 0 ? (0, Q2.jsx)(un, { label: a3({ id: `5MOY3C` }) }) : null; - let u4; - t2[10] !== r2 || t2[11] !== i3 ? (u4 = (e11) => r2?.kind === `edit-login` && r2.id === e11.id ? (0, Q2.jsx)(Ft, { editing: e11, onCancel: () => i3(null), onDone: () => i3(null) }, e11.id) : (0, Q2.jsx)(on, { credential: e11, disabled: r2 !== null, onEdit: () => i3({ kind: `edit-login`, id: e11.id }) }, e11.id), t2[10] = r2, t2[11] = i3, t2[12] = u4) : u4 = t2[12], l4 = e10.map(u4), t2[0] = a3, t2[1] = r2, t2[2] = n2, t2[3] = i3, t2[4] = o3, t2[5] = s3, t2[6] = c2, t2[7] = l4; - } else o3 = t2[4], s3 = t2[5], c2 = t2[6], l4 = t2[7]; - let u3; - return t2[13] !== o3 || t2[14] !== s3 || t2[15] !== c2 || t2[16] !== l4 ? (u3 = (0, Q2.jsxs)(o3, { title: s3, children: [c2, l4] }), t2[13] = o3, t2[14] = s3, t2[15] = c2, t2[16] = l4, t2[17] = u3) : u3 = t2[17], u3; -} -function fn(e9, t2) { - return _t2(e9).localeCompare(_t2(t2)); -} -function pn(e9) { - return e9.card === void 0 && e9.contact === void 0; -} -function mn(e9) { - mn.d = 1892; - let t2 = (0, X3.c)(26), { items: n2, form: r2, canSaveCards: i3, setForm: a3 } = e9, { _: o3 } = bb(), s3, c2, l4, u3, d3, f4; - if (t2[0] !== o3 || t2[1] !== i3 || t2[2] !== r2 || t2[3] !== n2 || t2[4] !== a3) { - f4 = /* @__PURE__ */ Symbol.for(`react.early_return_sentinel`); - bb0: { - let e10 = n2.flatMap(_n).toSorted(gn); - if (e10.length === 0 && !i3) { - f4 = null; - break bb0; - } - s3 = S2, t2[11] === o3 ? c2 = t2[12] : (c2 = o3({ id: `PgseLK` }), t2[11] = o3, t2[12] = c2), t2[13] === o3 ? l4 = t2[14] : (l4 = o3({ id: `Ccpbzh` }), t2[13] = o3, t2[14] = l4), u3 = e10.length === 0 ? (0, Q2.jsx)(un, { label: o3({ id: `1A2dM9` }) }) : null; - let p5; - t2[15] !== i3 || t2[16] !== r2 || t2[17] !== n2 || t2[18] !== a3 ? (p5 = (e11) => { - let { credential: t3, card: o4 } = e11; - return r2?.kind === `edit-card` && r2.id === t3.id ? (0, Q2.jsx)(Ht2, { addresses: zt2(n2).filter(hn), card: o4, credential: t3, onDone: () => a3(null) }, t3.id) : (0, Q2.jsx)(sn, { card: o4, credential: t3, disabled: r2 !== null, onEdit: i3 ? () => a3({ kind: `edit-card`, id: t3.id }) : null }, t3.id); - }, t2[15] = i3, t2[16] = r2, t2[17] = n2, t2[18] = a3, t2[19] = p5) : p5 = t2[19], d3 = e10.map(p5); - } - t2[0] = o3, t2[1] = i3, t2[2] = r2, t2[3] = n2, t2[4] = a3, t2[5] = s3, t2[6] = c2, t2[7] = l4, t2[8] = u3, t2[9] = d3, t2[10] = f4; - } else s3 = t2[5], c2 = t2[6], l4 = t2[7], u3 = t2[8], d3 = t2[9], f4 = t2[10]; - if (f4 !== /* @__PURE__ */ Symbol.for(`react.early_return_sentinel`)) return f4; - let p4; - return t2[20] !== s3 || t2[21] !== c2 || t2[22] !== l4 || t2[23] !== u3 || t2[24] !== d3 ? (p4 = (0, Q2.jsxs)(s3, { footer: c2, title: l4, children: [u3, d3] }), t2[20] = s3, t2[21] = c2, t2[22] = l4, t2[23] = u3, t2[24] = d3, t2[25] = p4) : p4 = t2[25], p4; -} -function hn(e9) { - let { contact: t2 } = e9; - return Rt2(t2); -} -function gn(e9, t2) { - return e9.credential.title.localeCompare(t2.credential.title); -} -function _n(e9) { - return e9.card === void 0 ? [] : [{ credential: e9, card: e9.card }]; -} -function vn(e9) { - vn.d = 1895; - let t2 = (0, X3.c)(22), { items: n2, form: r2, setForm: i3 } = e9, { _: a3 } = bb(), o3, s3, c2, l4, u3; - if (t2[0] !== a3 || t2[1] !== r2 || t2[2] !== n2 || t2[3] !== i3) { - let e10 = zt2(n2); - o3 = S2, t2[9] === a3 ? s3 = t2[10] : (s3 = a3({ id: `J4YQOg` }), t2[9] = a3, t2[10] = s3), t2[11] === a3 ? c2 = t2[12] : (c2 = a3({ id: `gVfVfe` }), t2[11] = a3, t2[12] = c2), l4 = e10.length === 0 ? (0, Q2.jsx)(un, { label: a3({ id: `HzlckB` }) }) : null; - let d4; - t2[13] !== r2 || t2[14] !== i3 ? (d4 = (e11) => { - let { credential: t3, contact: n3 } = e11; - return r2?.kind === `edit-contact` && r2.id === t3.id ? (0, Q2.jsx)($t, { editing: t3, onCancel: () => i3(null), onDone: () => i3(null) }, t3.id) : (0, Q2.jsx)(ln, { contact: n3, credential: t3, disabled: r2 !== null, onEdit: () => i3({ kind: `edit-contact`, id: t3.id }) }, t3.id); - }, t2[13] = r2, t2[14] = i3, t2[15] = d4) : d4 = t2[15], u3 = e10.map(d4), t2[0] = a3, t2[1] = r2, t2[2] = n2, t2[3] = i3, t2[4] = o3, t2[5] = s3, t2[6] = c2, t2[7] = l4, t2[8] = u3; - } else o3 = t2[4], s3 = t2[5], c2 = t2[6], l4 = t2[7], u3 = t2[8]; - let d3; - return t2[16] !== o3 || t2[17] !== s3 || t2[18] !== c2 || t2[19] !== l4 || t2[20] !== u3 ? (d3 = (0, Q2.jsxs)(o3, { footer: s3, title: c2, children: [l4, u3] }), t2[16] = o3, t2[17] = s3, t2[18] = c2, t2[19] = l4, t2[20] = u3, t2[21] = d3) : d3 = t2[21], d3; -} -function yn() { - yn.d = 1902; - let e9 = (0, X3.c)(38), n2 = kge(); - aO(n2.load); - let r2 = Dge(), i3 = wu(yge), a3 = Ou(), s3; - e9[0] === a3 ? s3 = e9[1] : (s3 = () => (a3(yge), bn), e9[0] = a3, e9[1] = s3), Bw(s3); - let l4 = Age(), [d3, f4] = (0, Y3.useState)(null), [p4, m3] = (0, Y3.useState)(false), [_2, v3] = (0, Y3.useState)(false), C2 = Oge(d3 === null ? null : d3.id), w3 = d3 !== null && C2 === void 0 ? null : d3, E3; - e9[2] === i3 ? E3 = e9[3] : (E3 = qt2.filter((e10) => e10.gate === null || i3), e9[2] = i3, e9[3] = E3); - let D2 = E3, O3; - e9[4] !== i3 || e9[5] !== w3 ? (O3 = (e10) => (0, Q2.jsxs)(Q2.Fragment, { children: [(0, Q2.jsx)(dn, { form: w3, items: e10, setForm: f4 }), (0, Q2.jsx)(mn, { canSaveCards: i3, form: w3, items: e10, setForm: f4 }), (0, Q2.jsx)(vn, { form: w3, items: e10, setForm: f4 })] }), e9[4] = i3, e9[5] = w3, e9[6] = O3) : O3 = e9[6]; - let A3 = O3, j3 = w3 !== null || p4 || _2, M3 = i3 && !j3 ? l4 : null, N2 = j3 || M3 !== null, P2; - e9[7] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (P2 = { className: `sand-78zum5 sand-dt5ytf sand-3qzy4x` }, e9[7] = P2) : P2 = e9[7]; + t2[16] === a3 ? m3 = t2[17] : (m3 = (0, Z5.jsx)(bT.Section, { children: (0, Z5.jsx)(bT.Item, { leading: f4, onSelect: a3, children: p4 }) }), t2[16] = a3, t2[17] = m3); + let h4; + t2[18] !== l5 || t2[19] !== d3 || t2[20] !== m3 ? (h4 = (0, Z5.jsxs)(bT.Content, { "aria-label": l5, children: [d3, m3] }), t2[18] = l5, t2[19] = d3, t2[20] = m3, t2[21] = h4) : h4 = t2[21]; + let g5; + return t2[22] !== c3 || t2[23] !== h4 ? (g5 = (0, Z5.jsxs)(bT, { placement: `bottom-end`, children: [c3, h4] }), t2[22] = c3, t2[23] = h4, t2[24] = g5) : g5 = t2[24], g5; +} +function dr2() { + dr2.d = 2122; + let e38 = (0, X5.c)(32), { _: n2 } = fx(), r2 = v_2(); + wD(r2.load); + let i3 = eye(), a3 = Au(h_2), o3 = Nu2(), c3; + e38[0] === o3 ? c3 = e38[1] : (c3 = () => (o3(h_2), pr2), e38[0] = o3, e38[1] = c3), DE(c3); + let [l5, u3] = (0, Y5.useState)(null), [d3, f4] = (0, Y5.useState)(null), [m3, g5] = (0, Y5.useState)(false), _5 = nye(l5) ?? null, v5; + e38[2] === a3 ? v5 = e38[3] : (v5 = $n2.filter((e39) => e39.gate === null || a3), e38[2] = a3, e38[3] = v5); + let y4 = v5, x2; + e38[4] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (x2 = () => u3(null), e38[4] = x2) : x2 = e38[4]; + let S2 = x2, E2; + e38[5] !== n2 || e38[6] !== a3 || e38[7] !== _5 ? (E2 = (e39) => _5 === null ? null : _5.card === void 0 ? _5.contact === void 0 ? (0, Z5.jsx)(Wt3, { credential: _5, onClose: S2 }) : (0, Z5.jsx)(lr2, { credential: _5, onClose: S2 }) : (0, Z5.jsx)(y3, { onClose: S2, target: { kind: `edit`, credential: _5, card: _5.card, items: e39, title: Zt4(_5, _5.card, n2({ id: `kryGs+` })), canEdit: a3 } }), e38[5] = n2, e38[6] = a3, e38[7] = _5, e38[8] = E2) : E2 = e38[8]; + let O2 = E2, k2; + e38[9] !== a3 || e38[10] !== O2 ? (k2 = (e39) => (0, Z5.jsxs)(Z5.Fragment, { children: [(0, Z5.jsx)(On3, { items: e39, onOpen: (e40) => u3(e40.id), showCards: a3 || e39.some(fr3) }), O2(e39)] }), e38[9] = a3, e38[10] = O2, e38[11] = k2) : k2 = e38[11]; + let A2 = k2, j2 = _5 !== null || d3 !== null || m3, M2, N3; + e38[12] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (M2 = Bo3(`vault`), N3 = { className: `sand-78zum5 sand-dt5ytf sand-3qzy4x` }, e38[12] = M2, e38[13] = N3) : (M2 = e38[12], N3 = e38[13]); + let P3; + e38[14] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (P3 = () => g5(true), e38[14] = P3) : P3 = e38[14]; let F2; - e9[8] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (F2 = () => v3(true), e9[8] = F2) : F2 = e9[8]; - let I; - e9[9] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (I = (0, Q2.jsx)(Sb, { id: `l3s5ri` }), e9[9] = I) : I = e9[9]; - let L; - e9[10] === N2 ? L = e9[11] : (L = (0, Q2.jsx)(MC, { disabled: N2, onClick: F2, size: `md`, style: sx.body2, variant: `secondary`, children: I }), e9[10] = N2, e9[11] = L); + e38[15] !== j2 || e38[16] !== y4 ? (F2 = (0, Z5.jsx)(v3, { children: (0, Z5.jsx)(ur2, { disabled: j2, onImport: P3, onPick: f4, types: y4 }) }), e38[15] = j2, e38[16] = y4, e38[17] = F2) : F2 = e38[17]; + let I2; + e38[18] !== i3 || e38[19] !== A2 ? (I2 = i3.panel({ empty: A2([]), value: A2 }), e38[18] = i3, e38[19] = A2, e38[20] = I2) : I2 = e38[20]; + let L3; + e38[21] === d3 ? L3 = e38[22] : (L3 = d3 === null ? null : (0, Z5.jsx)(er, { onClose: () => f4(null), type: d3 }), e38[21] = d3, e38[22] = L3); let R3; - e9[12] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (R3 = () => m3(true), e9[12] = R3) : R3 = e9[12]; - let z4; - e9[13] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (z4 = (0, Q2.jsx)(Sb, { id: `KofAh0` }), e9[13] = z4) : z4 = e9[13]; - let B4; - e9[14] === N2 ? B4 = e9[15] : (B4 = (0, Q2.jsx)(MC, { disabled: N2, onClick: R3, size: `md`, style: sx.body2, variant: `primary`, children: z4 }), e9[14] = N2, e9[15] = B4); - let V4; - e9[16] !== L || e9[17] !== B4 ? (V4 = (0, Q2.jsxs)(v2, { children: [L, B4] }), e9[16] = L, e9[17] = B4, e9[18] = V4) : V4 = e9[18]; - let H4; - e9[19] !== r2 || e9[20] !== A3 ? (H4 = r2.panel({ empty: A3([]), value: A3 }), e9[19] = r2, e9[20] = A3, e9[21] = H4) : H4 = e9[21]; - let U4; - e9[22] !== p4 || e9[23] !== D2 ? (U4 = p4 ? (0, Q2.jsx)(Jt, { onClose: () => m3(false), types: D2 }) : null, e9[22] = p4, e9[23] = D2, e9[24] = U4) : U4 = e9[24]; - let W4; - e9[25] !== M3 || e9[26] !== n2.clearCardPhotoHandoff ? (W4 = M3 === null ? null : (0, Q2.jsx)(Yt, { files: M3.files, onClose: n2.clearCardPhotoHandoff }), e9[25] = M3, e9[26] = n2.clearCardPhotoHandoff, e9[27] = W4) : W4 = e9[27]; - let G5; - e9[28] !== i3 || e9[29] !== _2 || e9[30] !== r2 ? (G5 = _2 ? (0, Q2.jsx)(tt3, { cardsEnabled: i3, items: r2, onClose: () => v3(false) }) : null, e9[28] = i3, e9[29] = _2, e9[30] = r2, e9[31] = G5) : G5 = e9[31]; - let K4; - return e9[32] !== V4 || e9[33] !== H4 || e9[34] !== U4 || e9[35] !== W4 || e9[36] !== G5 ? (K4 = (0, Q2.jsxs)(`div`, { ...P2, children: [V4, H4, U4, W4, G5] }), e9[32] = V4, e9[33] = H4, e9[34] = U4, e9[35] = W4, e9[36] = G5, e9[37] = K4) : K4 = e9[37], K4; + e38[23] !== a3 || e38[24] !== m3 || e38[25] !== i3 ? (R3 = m3 ? (0, Z5.jsx)(ut2, { cardsEnabled: a3, items: i3, onClose: () => g5(false) }) : null, e38[23] = a3, e38[24] = m3, e38[25] = i3, e38[26] = R3) : R3 = e38[26]; + let z2; + return e38[27] !== L3 || e38[28] !== R3 || e38[29] !== F2 || e38[30] !== I2 ? (z2 = (0, Z5.jsxs)(`div`, { id: M2, ...N3, children: [F2, I2, L3, R3] }), e38[27] = L3, e38[28] = R3, e38[29] = F2, e38[30] = I2, e38[31] = z2) : z2 = e38[31], z2; +} +function fr3(e38) { + return e38.card !== void 0; } -function bn() { +function pr2() { } -function xn() { - return xn.d = 1903, Ege() ? (0, Q2.jsx)(yn, {}) : null; +function mr2() { + return mr2.d = 2123, __2() ? (0, Z5.jsx)(dr2, {}) : null; } -function Sn() { - Sn.d = 1806; - let e9 = (0, X3.c)(1), t2; - return e9[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (t2 = (0, Q2.jsx)(o2, { children: (0, Q2.jsx)(xn, {}) }), e9[0] = t2) : t2 = e9[0], t2; +function hr2() { + hr2.d = 2011; + let e38 = (0, X5.c)(1), t2; + return e38[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (t2 = (0, Z5.jsx)(o2, { children: (0, Z5.jsx)(mr2, {}) }), e38[0] = t2) : t2 = e38[0], t2; } -function Cn(e9) { - Cn.d = 1807; - let t2 = (0, X3.c)(3), { params: n2 } = e9, r2 = n2.focusSetting ?? null, i3; - t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i3 = (0, Q2.jsx)(Sn, {}), t2[0] = i3) : i3 = t2[0]; +function gr2(e38) { + gr2.d = 2012; + let t2 = (0, X5.c)(3), { params: n2 } = e38, r2 = n2.focusSetting ?? null, i3; + t2[0] === /* @__PURE__ */ Symbol.for(`react.memo_cache_sentinel`) ? (i3 = (0, Z5.jsx)(hr2, {}), t2[0] = i3) : i3 = t2[0]; let a3; - return t2[1] === r2 ? a3 = t2[2] : (a3 = (0, Q2.jsx)(T2, { focus: r2, children: i3 }), t2[1] = r2, t2[2] = a3), a3; + return t2[1] === r2 ? a3 = t2[2] : (a3 = (0, Z5.jsx)(l4, { focus: r2, children: i3 }), t2[1] = r2, t2[2] = a3), a3; } export { - xb as createUpstreamVaultLinguiProvider, - qen as createUpstreamVaultStore, - Cn as default + px as createUpstreamVaultLinguiProvider, + _3 as createUpstreamVaultPaneHeaderProvider, + Gmn as createUpstreamVaultStore, + gr2 as default }; diff --git a/manifests/ports/grokbot-0755-unpacked.json b/manifests/ports/grokbot-0755-unpacked.json new file mode 100644 index 00000000..8018731f --- /dev/null +++ b/manifests/ports/grokbot-0755-unpacked.json @@ -0,0 +1,28 @@ +{ + "schemaVersion": 1, + "version": "0.75.5", + "source": "rea-grokbot-0755/asar/app.asar.unpacked", + "integritySource": "captured-unpacked-bytes", + "files": [ + { + "path": "dist/deps/sand-notification-settings/build/Release/sand_notification_settings.node", + "sha256": "ca769adb52b1ae6bf96c0c7625dd4f2c31c1eab9a25d07a32b5cf565840006ed", + "asarDeclaredSha256": "e2ab6519cb76945eb7750f5271cbf967e63b5e7eddbc11e2329366869f466671" + }, + { + "path": "dist/deps/sand-window-capture/build/Release/sand_window_capture.node", + "sha256": "a3630613ab7cb4b74e1cc229caf63a3a8454b45374553b74559225091cfdcb7d", + "asarDeclaredSha256": "a86fb14b384f69014872bc55e0fdd6eeb4829de873784943a8f0e1a9d1d9a7f5" + }, + { + "path": "dist/deps/sand-card-text-recognition/build/Release/sand_card_text_recognition.node", + "sha256": "4418dad796ef7cbd8965b64d291d992f9dc0fec59eced37ae1865ebf0b7bd452", + "asarDeclaredSha256": "fd962ba1e1636753420b4fdf71ba0760015d563f38cede190c3aa4c1d3d8dac2" + }, + { + "path": "dist/deps/sand-devicecheck/build/Release/sand_devicecheck.node", + "sha256": "1b13c047a253e1094b20485e8233d87bb25312eb172894a348ea1ba09cf832d0", + "asarDeclaredSha256": "9d24a90f4bfa81b5b99bd6a9bbd92fc35699a44fa817187365a6a60612faba01" + } + ] +} diff --git a/package-lock.json b/package-lock.json index 319ab63a..ba320405 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "grok-bot-0.18-reconstructed", - "version": "0.18.0-reconstructed.1", + "version": "0.75.5-reconstructed.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "grok-bot-0.18-reconstructed", - "version": "0.18.0-reconstructed.1", + "version": "0.75.5-reconstructed.1", "hasInstallScript": true, "dependencies": { "@ai-sdk/openai": "^1.3.24", diff --git a/package.json b/package.json index f0f7c1b7..b6f538e5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "grok-bot-0.18-reconstructed", - "version": "0.18.0-reconstructed.1", + "version": "0.75.5-reconstructed.1", "private": true, "type": "module", "description": "Source-oriented reconstruction of the publicly shipped Grok Bot 0.18.0 macOS application", diff --git a/scripts/clean-build.mjs b/scripts/clean-build.mjs index 472e15e8..8f1e1724 100644 --- a/scripts/clean-build.mjs +++ b/scripts/clean-build.mjs @@ -36,6 +36,7 @@ import { electronMainBindingProvenancePath, } from "./electron-main-production-activation.mjs"; import { applyOriginalRendererRouterPatch } from "./lib/router-renderer-patch.mjs"; +import { applyOriginalRendererMemoryImport } from "./lib/agent-memory-import-renderer-patch.mjs"; import { applyOriginalRendererLibraryStageClose } from "./lib/library-stage-close-renderer-patch.mjs"; import { applyOriginalRendererSidebarTopBarSearch } from "./lib/sidebar-search-renderer-patch.mjs"; import { applyOriginalRendererChatHeaderIdentity } from "./lib/chat-header-identity-renderer-patch.mjs"; @@ -45,12 +46,16 @@ import { applyOriginalRendererSkillDetail } from "./lib/skill-detail-renderer-pa import { applyOriginalRendererTeachSuccessPath } from "./lib/teach-success-path-renderer-patch.mjs"; import { applyOriginalRendererInfoPaneSplit } from "./lib/info-pane-split-renderer-patch.mjs"; import { applyOriginalRendererAgentModel } from "./lib/agent-model-renderer-patch.mjs"; +import { applyOriginalRendererAgentDataCards } from "./lib/agent-data-cards-renderer-patch.mjs"; import { applyOriginalRendererComputerUpdate } from "./lib/computer-update-renderer-patch.mjs"; import { applyOriginalRendererLanguagePatch } from "./lib/language-renderer-patch.mjs"; import { applyHardwareAccelerationSettingsPatch } from "./lib/hardware-acceleration-settings-patch.mjs"; import { applyOriginalRendererSettingsI18n } from "./lib/settings-i18n-patch.mjs"; +import { applySettingsUpdate0753Patch } from "./lib/settings-update-0753-patch.mjs"; +import { applyVaultSettingsRenderer0721 } from "./lib/vault-settings-renderer-patch.mjs"; import { applyOriginalRendererMainI18n } from "./lib/main-i18n-patch.mjs"; import { applyOriginalRendererExtraI18n } from "./lib/extra-i18n-patch.mjs"; +import { applyUpdatePillCopy0755Patch } from "./lib/update-pill-copy-0755-patch.mjs"; import { applyTeachGateRestorePatch } from "./lib/teach-gate-restore-patch.mjs"; import { applyGrokMainAgentGatePatch } from "./lib/grok-main-agent-gate-patch.mjs"; import { applyBotColorGatePatch } from "./lib/bot-color-gate-patch.mjs"; @@ -328,6 +333,11 @@ export async function buildFidelityReconstructedAsar({ await applyOriginalRendererSidebarTopBarSearch({ stageRoot }); // Must run before the i18n passes (it resolves its label through RLocT, which // main-i18n appends to this chunk later — function declarations hoist). + // Settings → 记忆: Muse-style memory import (dialog distillation to the MAIN bot). + // Anchors on the router patch's OUTPUT (registry entry list + panel switch), so it must + // run immediately after it — and, like the router patch, before the i18n passes below + // (its labels resolve through the RLocT runtime settings-i18n appends later). + await applyOriginalRendererMemoryImport({ stageRoot }); await applyOriginalRendererChatHeaderIdentity({ stageRoot }); // Independent of the header patches (it rewrites the transcript's activity mark, not the // chat header) and touches no string literal, so it is order-free against the passes @@ -367,6 +377,11 @@ export async function buildFidelityReconstructedAsar({ // check-circle banner). It pins the two inputs that decide that card and rewrites the // group's strings through RLocT, so — like every pass that emits RLocT — it must land // before the i18n passes below, which append the RLocT runtime to this same chunk. + // Experimental read-only bot data cards (soul / memory journal / user profile / audit / + // workflows) in the same panel. Anchors on the agent-model patch's OUTPUT, so it must + // run immediately after it — and, like every pass that emits RLocT literals, before the + // i18n passes below, which append the RLocT runtime to this same chunk. + await applyOriginalRendererAgentDataCards({ stageRoot }); await applyOriginalRendererComputerUpdate({ stageRoot }); await applyMainAgentRendererPatch({ stageRoot }); // 0.75.3 sidebar search presentation and its Create new Bot host. Both depend on @@ -434,6 +449,9 @@ export async function buildFidelityReconstructedAsar({ await applyOriginalRendererSettingsI18n({ stageRoot }); await applyOriginalRendererMainI18n({ stageRoot }); await applyOriginalRendererExtraI18n({ stageRoot }); + // The 0.18 renderer already has the footer update pill and Update-ready + // modal; port the official 0.75.5 copy now that RLocT exists. + await applyUpdatePillCopy0755Patch({ stageRoot }); // After i18n so the injected host source is not rewritten. The general-panel // anchor survives the router patch, and the plugins-list anchor is untouched // by the view-chunk passes above. @@ -442,6 +460,10 @@ export async function buildFidelityReconstructedAsar({ // Hardware acceleration toggle: lands in Sa()'s `r` slot after Language (Fragment). // Depends on the Language Sa slot rewrite above; independent of i18n (bilingual inline). await applyHardwareAccelerationSettingsPatch({ stageRoot }); + // Settings → Updates: port the official 0.75.3 Automatic Updates + Version + // card over the 0.18 update pane. Uses the settings kit and RLocT runtime + // already present; run after all i18n and settings-row passes. + await applySettingsUpdate0753Patch({ stageRoot }); // Last among the chunk-mutating passes: the flip touches one gate-fallback token in the // renderer chunk and the host bundle's bundled FLAGS default, neither of which the i18n // passes read or write. It must land before the packaging audit snapshots the stage. @@ -456,6 +478,7 @@ export async function buildFidelityReconstructedAsar({ // ON from Statsig, 9 kept OFF). Same table, own gate-name already-present guard; must // run after the three passes above so their names are not mistaken for ours. await apply0712GateEcosystemPatch({ stageRoot }); + await applyVaultSettingsRenderer0721({ stageRoot }); await overlayAuditMetadata(clean, { stageRoot }); await packStagedAppWithIntegrity({ stageRoot, archivePath, unpackedRoot }); console.log(`Fidelity hybrid ASAR ready: ${archivePath}`); diff --git a/scripts/lib/agent-data-cards-renderer-patch.mjs b/scripts/lib/agent-data-cards-renderer-patch.mjs new file mode 100644 index 00000000..54a9f35e --- /dev/null +++ b/scripts/lib/agent-data-cards-renderer-patch.mjs @@ -0,0 +1,178 @@ +// Read-only bot data cards (soul / memory journal / user profile / audit / workflows), +// injected into the checksum-pinned 0.18 renderer chunk's bot properties panel (h3n). +// +// EXPERIMENTAL EXTENSION — no upstream equivalent in 0.18 or the official 0.62/0.75 apps: +// neither surface exposes the box-side per-bot data files. Like the per-bot model card, +// it exists because the rebuild owns the local box runtime, and it is recorded as such in +// the provenance file (dist/renderer-agent-data-cards-extension.json). +// +// Placement evidence. This patch runs AFTER applyOriginalRendererAgentModel in the +// clean-build pipeline and anchors on that patch's output (the h3n return line that +// already carries RAgentModelCard), appending one more child, RAgentDataCards. The +// component renders five cards built from exactly the card / row / text / control markup +// and atomic classes the Notifications and model cards use. No memo slot is added to h3n +// (same argument as the model card: the card owns its state; element identity stability +// is harmless for state updates). +// +// Data flow: window.desktop.agent.getAgentDataOverview(agentId) / +// getAgentMemoryLog(agentId, month) / getAgentWorkflowContent(slug) → main-edge → +// box/agent-data-reader.ts → `docker exec` reads a FIXED whitelist under +// /home/box/sand-data (agents//memory/profile.md, agents//memory/log/*.md, +// user-memory/agents//profile.md, agents//audit.jsonl tail, workflows/*/SKILL.md). +// Every read is byte-capped and id/slug/month validated; secrets files are unreachable. +// +// i18n: every label is a direct RLocT("…","…") literal pair so the main-i18n pass (which +// runs AFTER this patch and appends the RLocT runtime) can scan and wrap them — do not +// route these through a helper that hides the literals. + +import { createHash } from "node:crypto"; +import { readdir, readFile, stat, writeFile } from "node:fs/promises"; +import path from "node:path"; + +export const H3N_RETURN_WITH_MODEL = + 'I=p.jsxs("div",{className:d,children:[E,A,p.jsx(RAgentModelCard,{agent:t})]}),e[28]=E,e[29]=A,e[30]=I'; + +export const H3N_RETURN_WITH_DATA = + 'I=p.jsxs("div",{className:d,children:[E,A,p.jsx(RAgentModelCard,{agent:t}),p.jsx(RAgentDataCards,{agent:t})]}),e[28]=E,e[29]=A,e[30]=I'; + +export const H3N_SIGNATURE = + "function h3n(n){const e=he.c(31),{agent:t,onNameChange:s,onTitleChange:r,onDescriptionChange:i}=n,"; + +/** Atomic classes copied verbatim from the agent-model patch (proven against the pinned CSS). */ +export const CARD_CLASSES = "sand-78zum5 sand-dt5ytf sand-167g77z sand-1y1aw1k sand-y13l1i sand-wib8y2 sand-163pfp sand-4pepcl sand-cq4si4"; +export const ROW_CLASSES = "sand-78zum5 sand-6s0dn4 sand-1qughib sand-1v2ro7d sand-1iorvi4 sand-jkvuk6 sand-11iknt3 sand-mzs88n"; +export const TEXT_CLASSES = "sand-78zum5 sand-dt5ytf sand-195vfkc sand-euugli"; +export const LABEL_CLASSES = "sand-11wthnw sand-1ja60sm sand-1wd3ewq"; +export const CONTROL_CLASSES = "sand-1c4vz4f sand-2lah0s sand-dl72j9 sand-78zum5 sand-6s0dn4"; + +export const REUSED_CLASSES = Object.freeze( + [...new Set([CARD_CLASSES, ROW_CLASSES, TEXT_CLASSES, LABEL_CLASSES, CONTROL_CLASSES].join(" ").split(" "))], +); + +/** Chunk-level identifiers the injected code relies on. Each must be a top-level binding. */ +export const REQUIRED_CHUNK_BINDINGS = Object.freeze(["p", "S", "re", "vt", "so"]); + +/** Select sentinel for "nothing picked yet"; also guards loadMem/loadWf against no-ops. */ +export const NONE_SENTINEL = "__r-agent-data-none__"; + +// No backticks anywhere in here: the source is spliced into a minified chunk as plain text. +// The sentinel const comes first so every later reference (render-time) is initialized. +export const COMPONENT_SOURCE = [ + 'const RAgentDataNone=' + JSON.stringify(NONE_SENTINEL) + ';', 'const RAgentDataCardClasses=' + JSON.stringify(CARD_CLASSES) + ',RAgentDataRowClasses=' + JSON.stringify(ROW_CLASSES) + ',RAgentDataTextClasses=' + JSON.stringify(TEXT_CLASSES) + ',RAgentDataLabelClasses=' + JSON.stringify(LABEL_CLASSES) + ',RAgentDataControlClasses=' + JSON.stringify(CONTROL_CLASSES) + ';', + 'function RAgentDataWhen(ts){try{const d=new Date(ts);if(isNaN(d.getTime()))return String(ts);const z=n=>(n<10?"0":"")+n;return z(d.getMonth()+1)+"-"+z(d.getDate())+" "+z(d.getHours())+":"+z(d.getMinutes())}catch(err){return String(ts)}}', + 'const RAgentDataPre=text=>p.jsx("div",{"data-r-agent-data-pre":"",style:{maxHeight:"280px",overflowY:"auto",whiteSpace:"pre-wrap",wordBreak:"break-word",margin:"8px 0 0",padding:"8px 10px",borderRadius:"8px",background:"rgba(128,128,128,0.14)",fontSize:"12px",lineHeight:"1.55",userSelect:"text"},children:typeof text==="string"&&text.length>0?text:RLocT("(empty)","(空)")});', + 'const RAgentDataBtn=o=>p.jsx("button",{type:"button",onClick:o.onClick,style:{border:"none",cursor:"pointer",borderRadius:"8px",padding:"4px 10px",fontSize:"12px",background:o.active?"rgba(128,128,128,0.28)":"rgba(128,128,128,0.14)",color:"inherit",whiteSpace:"nowrap"},children:o.label});', + 'const RAgentDataHint=text=>text==null?null:p.jsx(vt,{color:"secondary",size:"sm",children:text});', + "function RAgentDataCards({agent:t}){", + "const[nz,setNz]=S.useState(0),[ov,setOv]=S.useState({busy:!0,error:null,data:null}),[open,setOpen]=S.useState(null),[memMonth,setMemMonth]=S.useState(null),[mem,setMem]=S.useState({busy:!1,content:null,error:null}),[wfSlug,setWfSlug]=S.useState(null),[wf,setWf]=S.useState({busy:!1,content:null,error:null});", + "const memSeq=S.useRef(0),wfSeq=S.useRef(0);", + "S.useEffect(()=>{let c=!0;const g=window.desktop&&window.desktop.agent;", + "setOpen(null);setMemMonth(null);setMem({busy:!1,content:null,error:null});setWfSlug(null);setWf({busy:!1,content:null,error:null});", + 'if(!g||typeof g.getAgentDataOverview!=="function"){setOv({busy:!1,error:RLocT("Unavailable in this build.","当前构建未开放此功能。"),data:null});return()=>{c=!1}}', + "setOv({busy:!0,error:null,data:null});", + 'g.getAgentDataOverview(t.id).then(r=>{if(!c)return;if(r&&r.ok&&r.data){setOv({busy:!1,error:null,data:r.data});const ms=Array.isArray(r.data.memoryLogMonths)?r.data.memoryLogMonths.filter(m=>typeof m==="string"):[];setMemMonth(ms.length>0?ms[0]:null)}else setOv({busy:!1,error:String((r&&r.reason)||"read-failed"),data:null})}).catch(err=>{if(c)setOv({busy:!1,error:String((err&&err.message)||err),data:null})});', + "return()=>{c=!1}},[t.id,nz]);", + "const loadMem=m=>{if(m==null||m===RAgentDataNone)return;const n=++memSeq.current;setMem({busy:!0,content:null,error:null});const g=window.desktop&&window.desktop.agent;", + 'Promise.resolve(g&&typeof g.getAgentMemoryLog==="function"?g.getAgentMemoryLog(t.id,m):null).then(r=>{if(memSeq.current!==n)return;if(r&&r.ok){const c=r.data&&typeof r.data.content==="string"?r.data.content:null;setMem({busy:!1,content:c,error:c==null?RLocT("No entries for this month.","该月份暂无记录。"):null})}else setMem({busy:!1,content:null,error:String((r&&r.reason)||"read-failed")})}).catch(err=>{if(memSeq.current===n)setMem({busy:!1,content:null,error:String((err&&err.message)||err)})})};', + "const loadWf=s=>{if(s==null||s===RAgentDataNone)return;const n=++wfSeq.current;setWf({busy:!0,content:null,error:null});const g=window.desktop&&window.desktop.agent;", + 'Promise.resolve(g&&typeof g.getAgentWorkflowContent==="function"?g.getAgentWorkflowContent(s):null).then(r=>{if(wfSeq.current!==n)return;if(r&&r.ok){const c=r.data&&typeof r.data.content==="string"?r.data.content:null;setWf({busy:!1,content:c,error:c==null?RLocT("No SKILL.md in this workflow.","该技能没有 SKILL.md。"):null})}else setWf({busy:!1,content:null,error:String((r&&r.reason)||"read-failed")})}).catch(err=>{if(wfSeq.current===n)setWf({busy:!1,content:null,error:String((err&&err.message)||err)})})};', + "if(t.isGroup)return null;", + "const d=ov.data;", + "const pick=(list,placeholder)=>[{value:RAgentDataNone,label:placeholder}].concat((list||[]).filter(m=>typeof m===\"string\").map(m=>({value:m,label:m})));", + "const cardEl=(key,label,hint,control,extra)=>p.jsxs(\"div\",{className:re(\"sand-agent-settings__card\",RAgentDataCardClasses),[\"data-r-agent-\"+key]:\"\",children:[", + 'p.jsxs("div",{className:re("sand-agent-settings__row",RAgentDataRowClasses),children:[', + 'p.jsxs("span",{className:re("sand-agent-settings__text",RAgentDataTextClasses),children:[', + 'p.jsx("span",{className:RAgentDataLabelClasses,children:label}),RAgentDataHint(hint)]}),', + 'p.jsx("span",{className:re("sand-agent-settings__control",RAgentDataControlClasses),children:control})]}),', + "extra||null]});", + 'const wrap=children=>p.jsx("div",{style:{display:"flex",flexDirection:"column",gap:"8px"},"data-r-agent-data":"",children:children});', + 'if(ov.busy)return wrap([cardEl("loading",RLocT("Bot data","Bot 数据"),RLocT("Loading…","读取中…"),null,null)]);', + 'if(ov.error)return wrap([cardEl("error",RLocT("Bot data","Bot 数据"),ov.error,p.jsx(RAgentDataBtn,{label:RLocT("Retry","重试"),active:!1,onClick:()=>setNz(n=>n+1)}),null)]);', + 'const auditText=d.audit&&Array.isArray(d.audit.entries)?d.audit.entries.map(x=>(x.ts?RAgentDataWhen(x.ts)+" ":"")+"["+x.type+"] "+x.summary).join("\\n"):null;', + "const soulExtra=open===\"soul\"?RAgentDataPre(d.soul):null;", + "const userExtra=open===\"user\"?RAgentDataPre(d.userProfile):null;", + 'const auditExtra=open==="audit"?(auditText!=null&&auditText.length>0?RAgentDataPre(auditText+(d.audit&&d.audit.truncated?"\\n… "+RLocT("older entries truncated","更早的记录已截断"):"")):RAgentDataHint(RLocT("No audit entries.","暂无审计记录。"))):null;', + 'const memExtra=mem.busy?RAgentDataHint(RLocT("Loading…","读取中…")):mem.error?RAgentDataHint(mem.error):mem.content!=null?RAgentDataPre(mem.content):null;', + 'const wfExtra=wf.busy?RAgentDataHint(RLocT("Loading…","读取中…")):wf.error?RAgentDataHint(wf.error):wf.content!=null?RAgentDataPre(wf.content):null;', + "return wrap([", + 'cardEl("soul",RLocT("Soul","人格 (Soul)"),RLocT("memory/profile.md","memory/profile.md"),p.jsx(RAgentDataBtn,{label:open==="soul"?RLocT("Hide","收起"):RLocT("View","查看"),active:open==="soul",onClick:()=>setOpen(o=>o==="soul"?null:"soul")}),soulExtra),', + 'cardEl("memory",RLocT("Memory","记忆"),RLocT("memory/log/YYYY-MM.md","memory/log/YYYY-MM.md"),p.jsx(so,{"aria-label":RLocT("Memory month","记忆月份"),disabled:!d.memoryLogMonths||d.memoryLogMonths.length===0,onValueChange:n=>{if(n!==null){setMemMonth(n);loadMem(n)}},options:pick(d.memoryLogMonths,RLocT("No journal yet","暂无记忆日志")),placement:"bottom-end",size:"md",value:memMonth??RAgentDataNone}),memExtra),', + 'cardEl("user",RLocT("User profile","用户画像"),RLocT("user-memory profile.md","user-memory 画像"),p.jsx(RAgentDataBtn,{label:open==="user"?RLocT("Hide","收起"):RLocT("View","查看"),active:open==="user",onClick:()=>setOpen(o=>o==="user"?null:"user")}),userExtra),', + 'cardEl("audit",RLocT("Audit","行为审计"),RLocT("audit.jsonl (latest)","audit.jsonl(最近)"),p.jsx(RAgentDataBtn,{label:open==="audit"?RLocT("Hide","收起"):RLocT("View","查看"),active:open==="audit",onClick:()=>setOpen(o=>o==="audit"?null:"audit")}),auditExtra),', + 'cardEl("workflow",RLocT("Workflows","技能"),RLocT("workflows/*/SKILL.md","workflows/*/SKILL.md"),p.jsx(so,{"aria-label":RLocT("Workflow","技能"),disabled:!d.workflows||d.workflows.length===0,onValueChange:n=>{if(n!==null){setWfSlug(n);loadWf(n)}},options:pick(d.workflows,RLocT("Pick a workflow","选择技能")),placement:"bottom-end",size:"md",value:wfSlug??RAgentDataNone}),wfExtra)', + "]);", + "}", +].join("\n"); + +function replaceExactlyOnce(source, before, after, label) { + const first = source.indexOf(before); + if (first < 0 || source.indexOf(before, first + 1) >= 0) { + throw new Error(`Original renderer ${label} anchor is missing or ambiguous.`); + } + return source.slice(0, first) + after + source.slice(first + before.length); +} + +export function patchOriginalAgentDataCards(source) { + if (source.includes("function RAgentDataCards(")) { + throw new Error("Agent data cards are already injected into the renderer chunk."); + } + if (source.includes("const RAgentDataNone=")) { + throw new Error("Agent data sentinel binding already present in the renderer chunk."); + } + if (!source.includes("function RAgentModelCard(")) { + throw new Error("Agent data cards require the agent-model patch to run first."); + } + let patched = replaceExactlyOnce(source, H3N_RETURN_WITH_MODEL, H3N_RETURN_WITH_DATA, "bot properties return (with model card)"); + patched = replaceExactlyOnce(patched, H3N_SIGNATURE, COMPONENT_SOURCE + H3N_SIGNATURE, "bot properties signature"); + return patched; +} + +export function assertAgentDataClassesResolve(css) { + const missing = REUSED_CLASSES.filter((name) => !css.includes(`.${name}`)); + if (missing.length > 0) { + throw new Error(`Agent data card classes missing from the pinned CSS: ${missing.join(", ")}`); + } + return REUSED_CLASSES.length; +} + +export async function applyOriginalRendererAgentDataCards({ stageRoot }) { + const assetsRoot = path.join(stageRoot, "dist", "renderer", "assets"); + const candidates = []; + let css = ""; + for (const name of await readdir(assetsRoot)) { + const target = path.join(assetsRoot, name); + if (name.endsWith(".css")) { css += await readFile(target, "utf8"); continue; } + if (!name.endsWith(".js")) continue; + const source = await readFile(target, "utf8"); + if (source.includes(H3N_RETURN_WITH_MODEL)) candidates.push({ name, target, source }); + } + if (candidates.length !== 1) { + throw new Error(`Expected one original renderer chunk carrying the agent-model card anchor, found ${candidates.length}.`); + } + const classCount = assertAgentDataClassesResolve(css); + const candidate = candidates[0]; + const patched = patchOriginalAgentDataCards(candidate.source); + await writeFile(candidate.target, patched); + const record = { + schemaVersion: 1, + mode: "original-renderer-agent-data-cards", + chunks: [ + { + role: "bot-properties-data-cards", + path: `dist/renderer/assets/${candidate.name}`, + original: { bytes: Buffer.byteLength(candidate.source), sha256: createHash("sha256").update(candidate.source).digest("hex") }, + patched: { bytes: Buffer.byteLength(patched), sha256: createHash("sha256").update(patched).digest("hex") }, + reusedClasses: classCount, + }, + ], + evidence: { + upstreamEquivalent: null, + note: "Experimental extension: no upstream or official surface exposes box-side bot data files. Markup mirrors h3n's Notifications card; runs after the agent-model patch and anchors on its output.", + }, + features: ["experimental-bot-soul-viewer", "experimental-bot-memory-viewer", "experimental-bot-user-profile-viewer", "experimental-bot-audit-viewer", "experimental-bot-workflow-viewer"], + transformations: ["bot-properties-appends-data-cards"], + }; + const provenancePath = path.join(stageRoot, "dist", "renderer-agent-data-cards-extension.json"); + await writeFile(provenancePath, `${JSON.stringify(record, null, 2)}\n`); + return { ...record, provenancePath, provenanceBytes: (await stat(provenancePath)).size }; +} diff --git a/scripts/lib/agent-memory-import-renderer-patch.mjs b/scripts/lib/agent-memory-import-renderer-patch.mjs new file mode 100644 index 00000000..2bda86c6 --- /dev/null +++ b/scripts/lib/agent-memory-import-renderer-patch.mjs @@ -0,0 +1,146 @@ +// Settings → 记忆 (Memory): the Muse-style "import memory" section. EXPERIMENTAL +// EXTENSION — no upstream equivalent. The pasted snapshot from another assistant is +// distilled by the MAIN bot as an ordinary user turn (dialog distillation, v1): the +// desktop posts /api/sendPrompt with a prompt that tells the bot to extract durable +// facts via its UpdateMemory tool. The import lives in Settings — not on a bot panel — +// because the snapshot describes the USER ("helps the bot understand who I am"), and +// the receiving bot is the main bot (window.desktop.agent.getMainAgent()). +// +// Anchoring. This patch runs AFTER applyOriginalRendererRouterPatch (clean-build order) +// and anchors on its OUTPUT in two chunks: +// * the settings registry chunk: the wDn array entry list, post-router form — the +// memory section is spliced in between Router and Usage & Billing; +// * the settings panel chunk: the x=== section switch, post-router form — the memory +// panel is appended to the same conditional chain. +// The component source splices before the shared `function Sa(s){` anchor in the panel +// chunk, exactly like the router panel does. i18n mirrors RRouterLoc: RMemLoc delegates +// to the RLocT that settings-i18n-patch appends later and falls back to English. +// +// State mapping inside RMemoryPanel (kept deliberately boring): +// s=text e=setText · t=busy n=setBusy · r=status i=setStatus · o=mainAgent l=setMain · c=copied u=setCopied + +import { createHash } from "node:crypto"; +import { readdir, readFile, stat, writeFile } from "node:fs/promises"; +import path from "node:path"; + +export const REGISTRY_BEFORE = + ',{id:"router",label:(typeof RLocT==="function"?RLocT("Router","路由"):"Router"),icon:"git-branch"},{id:"usage"'; +export const REGISTRY_AFTER = + ',{id:"router",label:(typeof RLocT==="function"?RLocT("Router","路由"):"Router"),icon:"git-branch"},{id:"memory",label:(typeof RLocT==="function"?RLocT("Memory","记忆"):"Memory"),icon:"bookmark"},{id:"usage"'; + +export const PANEL_SWITCH_BEFORE = + ':x==="router"?a.jsx(RRouterPanel,{}):null'; +export const PANEL_SWITCH_AFTER = + ':x==="router"?a.jsx(RRouterPanel,{}):x==="memory"?a.jsx(RMemoryPanel,{}):null'; + +export const COMPONENT_ANCHOR = "function Sa(s){"; + +/** Chunk-level identifiers the injected panel relies on (same set RRouterPanel uses). */ +export const REQUIRED_CHUNK_BINDINGS = Object.freeze(["a", "de", "Te", "re", "ie", "se", "oe", "k"]); + +// Must stay byte-identical to IMPORT_MEMORY_TEMPLATE in +// source/shared/node/agent-memory-import.ts (tests/agent-memory-import.test.mjs guards it). +export const MEMORY_TEMPLATE = [ + "你正在帮助我将背景信息从一个 AI 助手迁移到另一个 AI 助手。", + "请基于我们过往的对话,整理一份关于我的便携式记忆快照,仅收录你确切掌握的信息。", + "输出将逐字输入到新 AI 的记忆中,质量优先于完整性。", + "要求:", + "1. 使用下列章节标题输出一个 Markdown 区块,无可靠信息的章节直接省略,不要编造占位符:", + " ## 身份信息 / ## 职业与工作 / ## 沟通偏好 / ## 经常提及的人 / ## 健康与饮食 / ## 兴趣与爱好 / ## 进行中的项目 / ## 工作风格与价值观 / ## 工具与环境 / ## 其他持久信息", + "2. 每个要点一句话、第三人称(“用户”、“他/她”),只写事实,不写过渡句。", + "3. 不确定的信息在要点末尾标注“(推断)”。", + "4. 忽略一次性陈述(除非明显重要)和敏感信息(健康状况、财务细节、心理健康)。", + "5. 硬性上限:2000 字。", +].join("\n"); + +export const MEMORY_MAX_CHARS = 64 * 1024; + +// No backticks in COMPONENT_SOURCE: it is spliced into a minified chunk as plain text. +export const COMPONENT_SOURCE = String.raw`function RMemLoc(en,zh){try{return RLocT(en,zh)}catch(_e){return en}} +const RMemoryTemplate=${JSON.stringify(MEMORY_TEMPLATE)}; +function RMemoryPanel(){ + const[s,e]=de.useState(""),[t,n]=de.useState(!1),[r,i]=de.useState(""),[o,l]=de.useState(null),[c,u]=de.useState(!1); + de.useEffect(()=>{let d=!0;const g=window.desktop&&window.desktop.agent;Promise.resolve(g&&typeof g.getMainAgent==="function"?g.getMainAgent():null).then(m=>{if(d)l(typeof m==="string"&&m.length>0?m:null)}).catch(()=>{if(d)l(null)});return()=>{d=!1}},[]); + const p=()=>{if(s.trim().length===0){i(RMemLoc("Paste the memory snapshot first.","请先粘贴记忆快照。"));return} + const g=window.desktop&&window.desktop.agent;if(!g||typeof g.importAgentMemory!=="function"){i(RMemLoc("Unavailable in this build.","当前构建未开放此功能。"));return} + if(o==null){i(RMemLoc("No main Bot is set. Pick one in the sidebar first.","未设置主 Bot,请先在侧栏选择主 Bot。"));return} + n(!0);i(""); + g.importAgentMemory(o,s.trim()).then(m=>{if(m!=null&&m.ok===false)i(RMemLoc("Failed: ","发送失败:")+String(m.reason??""));else{i(RMemLoc("Sent. The main Bot is distilling this into its memory — see the chat for its report.","已发送。主 Bot 正在提炼入库,可在聊天中查看汇报。"));e("")}}).catch(m=>{i(RMemLoc("Failed: ","发送失败:")+String(m&&m.message||m))}).finally(()=>n(!1))}; + const y=()=>{const g=navigator.clipboard;Promise.resolve(g&&typeof g.writeText==="function"?g.writeText(RMemoryTemplate):Promise.reject()).then(()=>{u(!0);setTimeout(()=>u(!1),2500)},()=>{i(RMemLoc("Copy failed — select the text manually.","复制失败,请手动选择文本复制。"));setTimeout(()=>i(""),2500)})}; + return a.jsx(Te,{children:a.jsxs("div",{className:k("sand-settings-general","sand-9f619 sand-78zum5 sand-dt5ytf sand-3qzy4x"),"data-r-memory-import":"",children:[ + a.jsx(re,{title:RMemLoc("Import memory","导入记忆"),children:a.jsx(ie,{description:RMemLoc("Import a memory snapshot from another assistant so the main Bot understands who you are. The Bot distils durable facts into its own memory — this is not a verbatim copy.","从其他 AI 助手导入记忆快照,帮助主 Bot 理解你是谁。Bot 会把持久事实提炼进自己的记忆——这不是逐字副本。"),label:RMemLoc("How it works","工作方式"),variant:"card",children:a.jsxs("div",{className:"sand-9f619 sand-78zum5 sand-dt5ytf",style:{gap:8,width:360},children:[a.jsx("div",{"aria-label":RMemLoc("Memory snapshot prompt","记忆快照提示词"),style:{maxHeight:220,overflowY:"auto",whiteSpace:"pre-wrap",wordBreak:"break-word",margin:0,padding:"8px 10px",borderRadius:8,background:"rgba(128,128,128,0.14)",fontSize:12,lineHeight:1.55,userSelect:"text"},children:RMemoryTemplate}),a.jsx(oe,{onClick:y,shape:"rectangular",size:"sm",variant:"secondary",children:c?RMemLoc("Copied","已复制"):RMemLoc("Copy","复制")})]})})}), + a.jsx(re,{title:RMemLoc("Paste the snapshot","粘贴快照"),children:a.jsx(ie,{description:o==null?RMemLoc("Sends to the main Bot. No main Bot is set yet.","将发送给主 Bot。尚未设置主 Bot。"):RMemLoc("Sends to the main Bot.","将发送给主 Bot。"),label:RMemLoc("Snapshot","记忆快照"),variant:"card",children:a.jsxs("div",{className:"sand-9f619 sand-78zum5 sand-dt5ytf",style:{gap:8,width:360},children:[a.jsx("textarea",{"aria-label":RMemLoc("Memory snapshot","记忆快照"),disabled:t,maxLength:${MEMORY_MAX_CHARS},onChange:m=>{e(m.currentTarget.value);i("")},placeholder:RMemLoc("Paste the snapshot from the other assistant here…","把其他助手生成的记忆快照粘贴到这里…"),style:{boxSizing:"border-box",width:"100%",minWidth:0,minHeight:140,resize:"vertical",padding:"8px 10px",borderRadius:8,border:"1px solid var(--sand-border,#7777772b)",background:"transparent",color:"inherit",fontFamily:"inherit",fontSize:13,lineHeight:1.55},value:s}),a.jsx(oe,{disabled:t||s.trim().length===0,onClick:p,shape:"rectangular",size:"sm",variant:"secondary",children:t?RMemLoc("Sending…","发送中…"):RMemLoc("Add memory","添加记忆")})]})})}), + r?a.jsx(se,{as:"p",color:"red",size:"sm",children:r}):null + ]})})} +`; + +function replaceExactlyOnce(source, before, after, label) { + const first = source.indexOf(before); + if (first < 0 || source.indexOf(before, first + 1) >= 0) { + throw new Error(`Original renderer ${label} anchor is missing or ambiguous.`); + } + return source.slice(0, first) + after + source.slice(first + before.length); +} + +export function patchOriginalSettingsRegistry(source) { + if (source.includes('{id:"memory"')) throw new Error("Memory settings section is already registered."); + return replaceExactlyOnce(source, REGISTRY_BEFORE, REGISTRY_AFTER, "settings registry (post-router)"); +} + +export function patchOriginalSettingsPanel(source) { + if (source.includes("function RMemoryPanel(")) throw new Error("Memory settings panel is already injected."); + if (!source.includes("function RRouterPanel(")) throw new Error("Memory settings panel requires the router patch to run first."); + let patched = replaceExactlyOnce(source, COMPONENT_ANCHOR, COMPONENT_SOURCE + COMPONENT_ANCHOR, "memory component insertion"); + patched = replaceExactlyOnce(patched, PANEL_SWITCH_BEFORE, PANEL_SWITCH_AFTER, "memory panel switch"); + return patched; +} + +export async function applyOriginalRendererMemoryImport({ stageRoot }) { + const assetsRoot = path.join(stageRoot, "dist", "renderer", "assets"); + const registryCandidates = []; + const panelCandidates = []; + for (const name of await readdir(assetsRoot)) { + if (!name.endsWith(".js")) continue; + const target = path.join(assetsRoot, name); + const source = await readFile(target, "utf8"); + if (source.includes(REGISTRY_BEFORE)) registryCandidates.push({ name, target, source }); + if (source.includes(PANEL_SWITCH_BEFORE)) panelCandidates.push({ name, target, source }); + } + if (registryCandidates.length !== 1 || panelCandidates.length !== 1) { + throw new Error(`Expected one settings registry and one settings panel chunk (post-router), found ${registryCandidates.length}/${panelCandidates.length}.`); + } + const registry = registryCandidates[0]; + const panel = panelCandidates[0]; + const registryPatched = patchOriginalSettingsRegistry(registry.source); + const panelPatched = patchOriginalSettingsPanel(panel.source); + await writeFile(registry.target, registryPatched); + await writeFile(panel.target, panelPatched); + const hash = (text) => createHash("sha256").update(text).digest("hex"); + const record = { + schemaVersion: 1, + mode: "original-renderer-memory-import", + chunks: [ + { + role: "settings-registry-memory-section", + path: `dist/renderer/assets/${registry.name}`, + original: { bytes: Buffer.byteLength(registry.source), sha256: hash(registry.source) }, + patched: { bytes: Buffer.byteLength(registryPatched), sha256: hash(registryPatched) }, + }, + { + role: "settings-panel-memory-panel", + path: `dist/renderer/assets/${panel.name}`, + original: { bytes: Buffer.byteLength(panel.source), sha256: hash(panel.source) }, + patched: { bytes: Buffer.byteLength(panelPatched), sha256: hash(panelPatched) }, + }, + ], + evidence: { + upstreamEquivalent: null, + note: "Experimental extension: Muse-style memory import, Settings-level (about the user, not a bot property). Delivered to the main bot as a distillation turn via /api/sendPrompt; no host change.", + }, + features: ["experimental-memory-import"], + transformations: ["settings-registry-appends-memory-section", "settings-panel-appends-memory-panel"], + }; + const provenancePath = path.join(stageRoot, "dist", "renderer-memory-import-extension.json"); + await writeFile(provenancePath, `${JSON.stringify(record, null, 2)}\n`); + return { ...record, provenancePath, provenanceBytes: (await stat(provenancePath)).size }; +} diff --git a/scripts/lib/app-link-card-renderer-patch.mjs b/scripts/lib/app-link-card-renderer-patch.mjs index e443539e..4310f142 100644 --- a/scripts/lib/app-link-card-renderer-patch.mjs +++ b/scripts/lib/app-link-card-renderer-patch.mjs @@ -176,11 +176,16 @@ export function patchAppLinkCards(source) { export function patchAppComputerSettings(source) { const branch = 'P=x==="beta"?a.jsx(Te,{', rows = 'children:[a.jsx(ma,{}),a.jsx(qs,{'; - for (const anchor of [branch, rows, 'function da(){']) { + // The shared-computer section is mounted inside the computer pane. Left as a sibling of + // the pane switch it also rendered on Settings → 更新, which must only carry the channel + // and version rows. + const rowsEnd = 'workingAgentNames:p})]})}):null'; + for (const anchor of [branch, rows, rowsEnd, 'function da(){']) { if (source.split(anchor).length !== 2) throw new Error('Computer settings anchor missing or ambiguous: ' + anchor); } const patched = source.replace(branch, 'P=x==="beta"||x==="computer"?a.jsx(Te,{') - .replace(rows, 'children:[x==="beta"?a.jsx(ma,{}):a.jsx("div",{"data-r-app-setting":"computers",tabIndex:-1,children:a.jsx(re,{title:RLocT("Your computer","你的电脑"),children:a.jsx(da,{})})}),a.jsx(qs,{'); + .replace(rows, 'children:[x==="beta"?a.jsx(ma,{}):a.jsx("div",{"data-r-app-setting":"computers",tabIndex:-1,children:[a.jsx(re,{title:RLocT("Your computer","你的电脑"),children:a.jsx(da,{})}),a.jsx(qs,{') + .replace(rowsEnd, 'workingAgentNames:p})]})]})}):null'); parse(patched, { ecmaVersion: 'latest', sourceType: 'module' }); return patched; } diff --git a/scripts/lib/build-asar.mjs b/scripts/lib/build-asar.mjs index 286fa928..a2cf2e00 100644 --- a/scripts/lib/build-asar.mjs +++ b/scripts/lib/build-asar.mjs @@ -13,8 +13,8 @@ import { packStagedAppWithIntegrity } from "./asar-integrity.mjs"; import { resolveRuntimeApp } from "./runtime.mjs"; export const reconstructedUpdaterGuard = [ - "// Reconstructed-build guard: do not consume official update or telemetry services.", - "process.env.SAND_DISABLE_UPDATES ??= \"1\";", + "// Reconstructed-build guard: updates come from this repo's GitHub Releases,", + "// never from the official Cursor update endpoint; Sentry/telemetry stay off.", "process.env.SAND_DISABLE_SENTRY ??= \"1\";", "process.env.SAND_DISABLE_TELEMETRY ??= \"1\";", "" @@ -150,13 +150,21 @@ export async function buildAsar({ await mkdir(buildRoot, { recursive: true }); await copySourceAppForStaging(sourceAppDir, stageRoot); + // The reconstructed app always reports the release tag (for example + // 0.75.3-reconstructed.1), never the pinned upstream 0.18.0 base. The + // updater compares this value against GitHub release tags, so the staged + // package.json is the single source of truth for the installed version. + const releaseVersion = process.env.GROK_NODE_APP_VERSION?.trim() || "0.75.5-reconstructed.1"; + const stagedPackagePath = path.join(stageRoot, "package.json"); + const stagedPackage = JSON.parse(await readFile(stagedPackagePath, "utf8")); + stagedPackage.version = releaseVersion; + stagedPackage.sandTrack ??= "stable"; + if (process.env.GROK_BOT_BUILD_DEV_APP === "1") { - const stagedPackagePath = path.join(stageRoot, "package.json"); - const stagedPackage = JSON.parse(await readFile(stagedPackagePath, "utf8")); stagedPackage.sandLab = true; stagedPackage.productName = "Grok Bot 0.18 Dev"; - await writeFile(stagedPackagePath, `${JSON.stringify(stagedPackage, null, 2)}\n`); } + await writeFile(stagedPackagePath, `${JSON.stringify(stagedPackage, null, 2)}\n`); for (const directory of ["deps", "native"]) { const source = path.join(runtimeUnpacked, directory); diff --git a/scripts/lib/desktop-0721.mjs b/scripts/lib/desktop-0721.mjs index 38632f07..b6ef4494 100644 --- a/scripts/lib/desktop-0721.mjs +++ b/scripts/lib/desktop-0721.mjs @@ -4,23 +4,25 @@ import path from "node:path"; import { pathToFileURL } from "node:url"; import { parse } from "acorn"; import { full } from "acorn-walk"; +import { desktopCoreRuntimeSource } from "./desktop-core-runtime-0721.mjs"; +import { bundleUpstreamModule } from "./upstream-module.mjs"; const digest = (bytes) => createHash("sha256").update(bytes).digest("hex"); const mainPath = "dist/electron-main/main-app.cjs"; const corePath = "dist/electron-main/main-core.cjs"; export const notificationNativePin = Object.freeze({ path: "dist/deps/sand-notification-settings/build/Release/sand_notification_settings.node", - sha256: "3e58c2e52be30df6f4e3a357331e44cac4529c6aa02b2e81338432d49c6615ac", - asarDeclaredSha256: "c002fd02246453816c69ac309ea5f24f6913d7f153ac197efebc31eb3d9a2047", - bytes: 102336, + sha256: "ca769adb52b1ae6bf96c0c7625dd4f2c31c1eab9a25d07a32b5cf565840006ed", + asarDeclaredSha256: "e2ab6519cb76945eb7750f5271cbf967e63b5e7eddbc11e2329366869f466671", + bytes: 102368, }); async function helpers(directory) { let base = directory === undefined ? new URL("./", import.meta.url) : pathToFileURL(`${path.resolve(directory)}/`); - const [{ openUpstream0721 }, { extractUpstreamDeclarations }] = await Promise.all([ - import(new URL("upstream-0721.mjs", base)), import(new URL("upstream-declarations.mjs", base)), + const [{ openUpstream0755 }, { extractUpstreamDeclarations }] = await Promise.all([ + import(new URL("upstream-0755.mjs", base)), import(new URL("upstream-declarations.mjs", base)), ]); - return { openUpstream0721, extractUpstreamDeclarations }; + return { openUpstream0755, extractUpstreamDeclarations }; } function extractInitialized(extract, code, exports, initialBindings = {}) { @@ -108,28 +110,34 @@ function desktopCatalogs(input, code) { export async function generateDesktop0721Module({ outputFile, upstream, helpersDir } = {}) { if (!outputFile) throw new TypeError("outputFile is required"); - const { openUpstream0721, extractUpstreamDeclarations } = await helpers(helpersDir); - const input = upstream ?? await openUpstream0721(); - const coreExports = { defaultPreferences: "J_", isPreferences: "xj", createRetryPolicy: "vR", realClock: "ae", RetryExhaustedError: "fc" }; + const { openUpstream0755, extractUpstreamDeclarations } = await helpers(helpersDir); + const input = upstream ?? await openUpstream0755(); + const coreRuntime = `const module = {exports:{}};\nconst exports = module.exports;\n${desktopCoreRuntimeSource(input.read(corePath).toString("utf8"))}`; + const coreExports = { defaultPreferences: "eh", isPreferences: "Lj", createRetryPolicy: "OR", realClock: "ae", RetryExhaustedError: "fc" }; const core = extractInitialized(extractUpstreamDeclarations, input.read(corePath).toString("utf8"), coreExports, { performance: "globalThis.performance" }); - const exports = { startMenubarTray: "cJn", createRoster: "jCt", loadNative: "CC", parsePermission: "EJn", - mapPermission: "vJn", readPermission: "kC", createPermission: "IIt", composePermission: "MIt", showProbe: "a6n" }; + const exports = { startMenubarTray: "QJn", createRoster: "Dvt", loadNative: "VC", parsePermission: "XJn", + mapPermission: "e6n", readPermission: "zC", createPermission: "hIt", composePermission: "bIt", showProbe: "L6n" }; const translations = "({i18n:{_:ports.translate}})"; const invariant = "({invariant:(value,message)=>{if(!value)throw new Error(typeof message==='function'?message():message)}})"; const bindings = { Zi: "ports.electron", RK: "ports.electron", Jh: "ports.electron", Mge: "({reportDesktopEdgeFailure:ports.reportFailure})", HCt: "({reportDesktopEdgeFailure:ports.reportFailure})", + Ffe: "({reportDesktopEdgeFailure:ports.reportFailure})", + $ae: "({captureSandSentryWarning:(area,detail)=>ports.reportFailure(area,'warning',new Error(detail))})", Pge: "({errorLogTag:error=>error instanceof Error?error.name:'UnknownError'})", Oge: "({isUnknownRecord:value=>typeof value==='object'&&value!==null&&!Array.isArray(value)})", Lkt: "({rosterPhotoImageSrc:photo=>ports.rosterPhotoUrl(photo.key)})", - OK: translations, xkt: translations, MK: translations, Fge: translations, - Nkt: "({realClock:ports.clock??core.realClock})", TC: "core", kIt: "({SandDomainError:Error})", - PK: invariant, ekt: invariant, SJn: "ports.loadNotificationNative", Bkt: "({default:require('node:path')})", - Request: "globalThis.Request", + Tkt: "({rosterPhotoImageSrc:photo=>ports.rosterPhotoUrl(photo.key)})", + OK: translations, xkt: translations, MK: translations, Fge: translations, XK: translations, + Nkt: "({realClock:ports.clock??core.realClock})", Ikt: "({realClock:ports.clock??core.realClock})", + TC: "core", kIt: "({SandDomainError:Error})", + PK: invariant, SJn: "ports.loadNotificationNative", ZJn: "(name)=>ports.loadNotificationNative(name)", + Bkt: "({default:require('node:path')})", + Request: "globalThis.Request", vJn: "5", }; const main = extractInitialized(extractUpstreamDeclarations, input.read(mainPath).toString("utf8"), exports, bindings); const catalogs = desktopCatalogs(input, main.code); - const code = `"use strict";\nexports.desktopCatalogs = ${JSON.stringify(catalogs)};\nexports.createDesktop0721Upstream = function(ports) {\nconst core = (()=>{\n${factoryBody(core, coreExports)}\n})();\nconst main = (()=>{\n${factoryBody(main, exports)}\n})();\nreturn {...main,defaultPreferences:core.defaultPreferences,isPreferences:core.isPreferences};\n};\n`; + const code = `"use strict";\nconst nodeRequire = require;\nexports.desktopCatalogs = ${JSON.stringify(catalogs)};\nexports.createDesktop0721Upstream = function(ports) {\nfunction require(name) {\nreturn name === "electron" ? ports.electron : name === "original-fs" ? nodeRequire("node:fs") : nodeRequire(name);\n}\n(()=>{\nconst __import_meta_url = require("node:url").pathToFileURL(__filename).href;\nconst savedElectronVersion = process.versions.electron;\nif (savedElectronVersion === undefined) process.versions.electron = "0.0.0";\ntry {\n${coreRuntime}\n} finally {\nif (savedElectronVersion === undefined) delete process.versions.electron;\n}\n})();\nconst core = (()=>{\n${factoryBody(core, coreExports)}\n})();\nconst main = (()=>{\n${factoryBody(main, exports)}\n})();\nreturn {...main,defaultPreferences:core.defaultPreferences,isPreferences:core.isPreferences};\n};\n`; const manifest = { upstream: input.identity, outputSha256: digest(code), sources: [{ path: corePath, ...core }, { path: mainPath, ...main }].map(({ code: ignored, ...record }) => record), artifacts: input.provenance() }; @@ -141,8 +149,8 @@ export async function generateDesktop0721Module({ outputFile, upstream, helpersD export async function stageDesktop0721Resources({ outputDir, upstream, helpersDir, notificationNativePath } = {}) { if (!outputDir) throw new TypeError("outputDir is required"); - const { openUpstream0721 } = await helpers(helpersDir); - const input = upstream ?? await openUpstream0721(); + const { openUpstream0755 } = await helpers(helpersDir); + const input = upstream ?? await openUpstream0755(); const paths = input.files.filter((entry) => /^dist\/electron-main\/menubar-tray\/assets\/[^/]+\.png$/.test(entry) || ["dist/deps/sand-notification-settings/package.json", "dist/deps/sand-notification-settings/index.js"].includes(entry)); @@ -173,24 +181,57 @@ export async function stageDesktop0721Resources({ outputDir, upstream, helpersDi export async function generateDesktop0721RulesModule({ outputFile, upstream, helpersDir } = {}) { if (!outputFile) throw new TypeError("outputFile is required"); - const { openUpstream0721, extractUpstreamDeclarations } = await helpers(helpersDir); - const input = upstream ?? await openUpstream0721(); - const operationsPath = "dist/renderer/assets/chunk-general-pane-DfO6XZcq.js"; - const panelPath = "dist/renderer/assets/chunk-view-C9fWByH0.js"; - const operationsExports = { isAtCap: "It", findRule: "Ft", groupRules: "Mt", sameRule: "Pt", behaviors: "jt", listRules: "Dt", editRule: "Lt", deleteRule: "Nt" }; - const operations = extractInitialized(extractUpstreamDeclarations, input.read(operationsPath).toString("utf8"), operationsExports); - const bindings = { - U: "ports.compilerRuntime", W: "ports.React", G: "ports.jsxRuntime", T: "ports.useLingui", - a: "ports.Button", c: "ports.IconButton", t: "ports.Text", n: "ports.Tooltip", C: "ports.Icon", - w: "ports.Trans", D: "ports.styles", l: "ports.controlStyles", N: "1000", - I: "ports.operations.groupRules", F: "ports.operations.findRule", B: "ports.operations.editRule", - V: "ports.operations.deleteRule", L: "ports.operations.sameRule", R: "ports.operations.behaviors", - z: "ports.operations.listRules", P: "ports.operations.isAtCap", - }; - const panel = extractInitialized(extractUpstreamDeclarations, input.read(panelPath).toString("utf8"), { RulesEditor: "J" }, bindings); - const code = `export const operations = (()=>{${factoryBody(operations, operationsExports)}})();\nexport function createPersonalRulesEditor(adapters) {\nconst ports = {...adapters,operations};\nconst {RulesEditor} = (()=>{${factoryBody(panel, { RulesEditor: "J" })}})();\nreturn function PersonalRulesEditor(props) { return ports.jsxRuntime.jsx(RulesEditor,{...props,teamRules:{allowInstructions:[],blockInstructions:[]}}); };\n}\n`; + const { openUpstream0755 } = await helpers(helpersDir); + const input = upstream ?? await openUpstream0755(); + const commonPath = "dist/renderer/assets/index.eager-common-F4Y1-gMW.js"; + const vendorPath = "dist/renderer/assets/index.eager-vendor-CRCbzhle.js"; + const panelPath = "dist/renderer/assets/chunk-view-Csdcxtbd.js"; + const entryPath = "dist/renderer/assets/rules-0755-entry.js"; + const entry = `import {RulesEditor} from "./chunk-view-Csdcxtbd.js"; +import {a as editRule,c as instructionList,d as sameRule,i as behaviors,l as deleteRule,o as groupRules,s as isAtCap,u as findRule} from "./chunk-general-pane-C6f-EusD.js"; +const operations={editRule,instructionList,sameRule,behaviors,deleteRule,groupRules,isAtCap,findRule}; +function createPersonalRulesEditor(adapters){globalThis.__sandRulesReact=adapters.React;globalThis.__sandRulesJsx=adapters.jsxRuntime;globalThis.__sandRulesLingui=adapters.useLingui;return function PersonalRulesEditor(props){return adapters.jsxRuntime.jsx(RulesEditor,{...props,rulesInEffect:props.rulesInEffect??{kind:"none"},teamRules:{allowInstructions:[],blockInstructions:[]}});};} +export {operations,createPersonalRulesEditor};\n`; + const archive = { ...input, read(relative) { + if (relative === entryPath) return Buffer.from(entry); + let source = input.read(relative).toString("utf8"); + if (relative === commonPath) { + source = source.replace("ot as At", "sandRulesReact as At").replace("it as jt", "sandRulesJsx as jt"); + source = `function sandRulesReact(){return globalThis.__sandRulesReact}\nfunction sandRulesJsx(){return globalThis.__sandRulesJsx}\n${source}`; + } + if (relative === vendorPath) { + source = source.replace("fx as nt", "sandRulesLingui as nt"); + source = `function sandRulesLingui(){return globalThis.__sandRulesLingui()}\n${source}`; + } + if (relative === panelPath) source = `export {Z as RulesEditor};\n${source}`; + return Buffer.from(source); + } }; + const bundled = await bundleUpstreamModule({ archive, entry: entryPath, + exports: ["operations", "createPersonalRulesEditor"], bindings: { + CSS: "globalThis.CSS", DOMRect: "globalThis.DOMRect", Element: "globalThis.Element", + Event: "globalThis.Event", FocusEvent: "globalThis.FocusEvent", + HTMLAnchorElement: "globalThis.HTMLAnchorElement", HTMLInputElement: "globalThis.HTMLInputElement", + HTMLTextAreaElement: "globalThis.HTMLTextAreaElement", HTMLElement: "globalThis.HTMLElement", + Image: "globalThis.Image", IntersectionObserver: "globalThis.IntersectionObserver", + KeyboardEvent: "globalThis.KeyboardEvent", MouseEvent: "globalThis.MouseEvent", + MutationObserver: "globalThis.MutationObserver", Node: "globalThis.Node", + ResizeObserver: "globalThis.ResizeObserver", ShadowRoot: "globalThis.ShadowRoot", + __REACT_DEVTOOLS_GLOBAL_HOOK__: "globalThis.__REACT_DEVTOOLS_GLOBAL_HOOK__", + cancelAnimationFrame: "globalThis.cancelAnimationFrame", document: "globalThis.document", + getComputedStyle: "globalThis.getComputedStyle", navigator: "globalThis.navigator", + performance: "globalThis.performance", requestAnimationFrame: "globalThis.requestAnimationFrame", + reportError: "globalThis.reportError", window: "globalThis.window", + } }); + const code = [ + 'import * as __rulesReact from "react";', + 'import * as __rulesJsx from "react/jsx-runtime";', + "globalThis.__sandRulesReact=__rulesReact;", + "globalThis.__sandRulesJsx=__rulesJsx;", + bundled.code, + "", + ].join("\n"); const manifest = { upstream: input.identity, outputSha256: digest(code), - sources: [{ path: operationsPath, ...operations }, { path: panelPath, ...panel }].map(({ code: ignored, ...record }) => record) }; + artifacts: input.provenance(), modules: bundled.modules }; await mkdir(path.dirname(outputFile), { recursive: true }); await writeFile(outputFile, code); await writeFile(`${outputFile}.provenance.json`, `${JSON.stringify(manifest, null, 2)}\n`); diff --git a/scripts/lib/desktop-core-runtime-0721.mjs b/scripts/lib/desktop-core-runtime-0721.mjs new file mode 100644 index 00000000..8e9006c5 --- /dev/null +++ b/scripts/lib/desktop-core-runtime-0721.mjs @@ -0,0 +1,22 @@ +import { parse } from "acorn"; + +const REGISTRY = 'globalThis[Symbol.for("sand.main-core.modules")]'; + +export function desktopCoreRuntimeSource(code) { + const ast = parse(code, { ecmaVersion: "latest", sourceType: "script" }); + let registration; + for (const statement of ast.body) { + if (statement.type !== "ExpressionStatement" || statement.expression.type !== "AssignmentExpression") continue; + const { left, right } = statement.expression; + if (left.type !== "MemberExpression" || left.computed !== true + || code.slice(left.start, left.end) !== REGISTRY + || right.type !== "CallExpression" + || code.slice(right.callee.start, right.callee.end) !== "Object.freeze") continue; + registration = statement; + } + if (registration === undefined) throw new Error("Upstream main-core module registry is missing"); + if (code.indexOf(REGISTRY) !== registration.start) throw new Error("Upstream main-core module registry is ambiguous"); + const strict = code.indexOf('"use strict";'); + if (strict < 0 || strict > registration.start) throw new Error("Upstream main-core strict preamble is missing"); + return code.slice(strict, registration.end); +} diff --git a/scripts/lib/desktop-mount-0721.mjs b/scripts/lib/desktop-mount-0721.mjs index b330a99f..1f3d56e4 100644 --- a/scripts/lib/desktop-mount-0721.mjs +++ b/scripts/lib/desktop-mount-0721.mjs @@ -4,8 +4,9 @@ import path from "node:path"; import { parse } from "acorn"; import { simple, ancestor } from "acorn-walk"; import { transform } from "esbuild"; -import { openUpstream0721 } from "./upstream-0721.mjs"; +import { openUpstream0755 } from "./upstream-0755.mjs"; import { extractUpstreamDeclarations } from "./upstream-declarations.mjs"; +import { desktopCoreRuntimeSource } from "./desktop-core-runtime-0721.mjs"; const digest = (bytes) => createHash("sha256").update(bytes).digest("hex"); const panel = "src/electron-renderer/desktop-mount/panel/panel.html"; @@ -24,7 +25,7 @@ function extractInitialized(code, exports, bindings = {}) { const functions = parents.filter((parent) => /Function/.test(parent.type)); if (functions.length !== 1 || functions[0].type !== "ArrowFunctionExpression") return; const parent = parents[parents.indexOf(functions[0]) - 1]; - if (parent?.type !== "CallExpression" || !["I", "N"].includes(parent.callee.name)) return; + if (parent?.type !== "CallExpression" || parent.callee.type !== "Identifier") return; const list = assignments.get(node.left.name) ?? []; list.push(node); assignments.set(node.left.name, list); @@ -53,18 +54,19 @@ function extractInitialized(code, exports, bindings = {}) { export async function stageDesktopMount0721({ distRoot, asarPath } = {}) { if (!distRoot || !path.isAbsolute(distRoot)) throw new TypeError("distRoot must be absolute"); - const upstream = await openUpstream0721(asarPath === undefined ? {} : { asarPath }); + const upstream = await openUpstream0755(asarPath === undefined ? {} : { asarPath }); const coreCode = upstream.read("dist/electron-main/main-core.cjs").toString("utf8"); + const coreRuntime = `const module = {exports:{}};\nconst exports = module.exports;\n${desktopCoreRuntimeSource(coreCode)}`; const appCode = upstream.read("dist/electron-main/main-app.cjs").toString("utf8"); const core = extractInitialized(coreCode, { - rpcObject: "LB", rpcString: "PB", rpcUint8Array: "UB", rpcOptional: "NB", - createTaskBoundaryPolicy: "Pa", ipcMainTransport: "tB", parseAgentId: "Na", - invariant: "Ze", isUnknownRecord: "k", errorLogTag: "Nt", writeFileAtomicSync: "rn", + rpcObject: "HB", rpcString: "LB", rpcUint8Array: "WB", rpcOptional: "GB", + createTaskBoundaryPolicy: "Oa", ipcMainTransport: "aB", parseAgentId: "Na", + invariant: "Ze", isUnknownRecord: "k", errorLogTag: "Nt", writeFileAtomicSync: "Wt", }); const app = extractInitialized(appCode, { - createMount: "wet", createCapture: "ftt", createPicker: "att", createCaptureService: "ctt", - createPositionStore: "Uet", createCaptureGate: "Get", createHotkey: "Vet", - isCaptureSupported: "Fet", loadNative: "ltt", serveEdge: "kl", mountEdge: "uet", + createMount: "xet", createCapture: "Att", createPicker: "ltt", createCaptureService: "mtt", + createPositionStore: "Qet", createCaptureGate: "zet", createHotkey: "jet", + isCaptureSupported: "Vet", loadNative: "utt", }, { _c: '() => require("@desktop/core")', NV: '() => require("@desktop/core")', LGe: '() => require("@desktop/core")', @@ -72,7 +74,7 @@ export async function stageDesktopMount0721({ distRoot, asarPath } = {}) { be: '() => require("@desktop/core")', Ot: '() => require("@desktop/core")', xe: '() => require("@desktop/core")', Fr: '() => require("@desktop/core")', co: '() => require("@desktop/report")', xw: '() => ({PRELOAD_DIST_DIR: require("@desktop/paths").preloadRoot})', - E: 'require("@desktop/zod")', + E: 'require("@desktop/zod")', p: 'require("@desktop/zod")', okn: 'require("@desktop/paths").panelDocument', kkn: 'require("@desktop/paths").overlayDocument', Nkn: 'require("@desktop/nativeRequire")', }); @@ -84,10 +86,13 @@ module.exports.createUpstream = function(ports) { let core; const require = (name) => { if (name === "electron") return ports.electron; + if (name === "original-fs") return nodeRequire("node:fs"); if (name === "@desktop/core") return {...core, ipcMainTransport: (config) => core.ipcMainTransport({...config, broadcast: (channel, value) => { config.broadcast(channel, value); - if (channel === "dune-rpc:desktop-mount:e:prompt-submitted") ports.onPromptSubmitted(value); + if (typeof value === "object" && value !== null && "agentId" in value && "prompt" in value && "attachments" in value) { + ports.onPromptSubmitted(value); + } } })}; if (name === "@desktop/report") return {captureSandSentryWarning: ports.reportWarning}; @@ -96,6 +101,28 @@ module.exports.createUpstream = function(ports) { if (name === "@desktop/nativeRequire") return ports.nativeRequire; return nodeRequire(name); }; + (() => { + const __import_meta_url = nodeRequire("node:url").pathToFileURL(__filename).href; + const savedElectronVersion = process.versions.electron; + if (savedElectronVersion === undefined) process.versions.electron = "0.0.0"; + try { +${coreRuntime} + } finally { + if (savedElectronVersion === undefined) delete process.versions.electron; + } + })(); + const coreModules = globalThis[Symbol.for("sand.main-core.modules")]; + const mountCore = coreModules[31]; + const modulesWithMountTransport = [...coreModules]; + modulesWithMountTransport[31] = {...mountCore, ipcMainTransport: (config) => mountCore.ipcMainTransport({...config, + broadcast: (channel, value) => { + config.broadcast(channel, value); + if (typeof value === "object" && value !== null && "agentId" in value && "prompt" in value && "attachments" in value) { + ports.onPromptSubmitted(value); + } + } + })}; + globalThis[Symbol.for("sand.main-core.modules")] = modulesWithMountTransport; core = (() => { const module = {exports:{}}; ${coreCjs}\nreturn module.exports; })(); return (() => { const module = {exports:{}}; ${appCjs}\nreturn module.exports; })(); }; diff --git a/scripts/lib/desktop-mount-renderer-0721.mjs b/scripts/lib/desktop-mount-renderer-0721.mjs index 8e2e3559..7aa15e62 100644 --- a/scripts/lib/desktop-mount-renderer-0721.mjs +++ b/scripts/lib/desktop-mount-renderer-0721.mjs @@ -3,35 +3,51 @@ import { readFile, readdir, writeFile } from "node:fs/promises"; import path from "node:path"; import { parse } from "acorn"; import { transform } from "esbuild"; -import { openUpstream0721 } from "./upstream-0721.mjs"; +import { openUpstream0755 } from "./upstream-0755.mjs"; import { extractUpstreamDeclarations } from "./upstream-declarations.mjs"; import { bundleUpstreamModule } from "./upstream-module.mjs"; -const entry = "dist/renderer/assets/index.eager-app-CG8Fw00L.js"; +const entry = "dist/renderer/assets/index.eager-app-uZS5Ltig.js"; const mark = "/* grok-node-desktop-mount-0721 */"; const sha = (value) => createHash("sha256").update(value).digest("hex"); +const browserBindings = { + CSS: "globalThis.CSS", DOMRect: "globalThis.DOMRect", Element: "globalThis.Element", + Event: "globalThis.Event", FocusEvent: "globalThis.FocusEvent", + HTMLAnchorElement: "globalThis.HTMLAnchorElement", HTMLElement: "globalThis.HTMLElement", + IntersectionObserver: "globalThis.IntersectionObserver", MouseEvent: "globalThis.MouseEvent", + MutationObserver: "globalThis.MutationObserver", Node: "globalThis.Node", + ResizeObserver: "globalThis.ResizeObserver", ShadowRoot: "globalThis.ShadowRoot", + __REACT_DEVTOOLS_GLOBAL_HOOK__: "globalThis.__REACT_DEVTOOLS_GLOBAL_HOOK__", + cancelAnimationFrame: "globalThis.cancelAnimationFrame", document: "globalThis.document", + getComputedStyle: "globalThis.getComputedStyle", navigator: "globalThis.navigator", + performance: "globalThis.performance", requestAnimationFrame: "globalThis.requestAnimationFrame", + reportError: "globalThis.reportError", + window: "globalThis.window", +}; export async function buildDesktopMountRenderer0721(archive = undefined) { - archive ??= await openUpstream0721(); + archive ??= await openUpstream0755(); const extracted = extractUpstreamDeclarations({ code: archive.read(entry).toString("utf8"), - exports: { createController: "yce", MenuItem: "Kj", makeTarget: "kA", choicesOf: "kRe", previewOf: "ORe" }, + exports: { createController: "Ule", MenuItem: "xT", makeTarget: "FUe", choicesOf: "RUe", previewOf: "IUe", markStateOf: "qVe" }, bindings: { X: "ports.React", Y: "ports.jsx", Z: "ports.compiler", J: "(()=>({_:ports.translate}))", wu: "(name=>ports.client.experiments.snapshots.get()?.featureGates?.[name]===true)", Ou: "(()=>()=>{})", Af: "(()=>({platform:ports.platform}))", Cce: "(()=>ports.useSnapshot(ports.controller.snapshots))", wce: "(()=>ports.controller)", P: "ports.React.useEffect", Vn: "ports.Icon", sE: "ports.Menu", wA: "ports.agentName", - gp: "ports.sendPrompt", Qs: "ports.SourceFailure", hp: "ports.reportPromise", _l: "ports.reportError", + Gf: "ports.sendPrompt", gp: "ports.sendPrompt", ec: "ports.SourceFailure", + Qs: "ports.SourceFailure", hp: "ports.reportPromise", _l: "ports.reportError", + ...browserBindings, } }); if (extracted.unresolved.some((name) => name !== "ports")) throw new Error(`Unresolved mount renderer bindings: ${extracted.unresolved.join(", ")}`); const ast = parse(extracted.code, { ecmaVersion: "latest", sourceType: "module" }); const imports = ast.body.filter((node) => node.type === "ImportDeclaration").map((node) => extracted.code.slice(node.start, node.end)); const body = ast.body.filter((node) => node.type !== "ImportDeclaration" && node.type !== "ExportNamedDeclaration") .map((node) => extracted.code.slice(node.start, node.end)).join("\n"); - const virtual = `${imports.join("\n")}\nfunction createMountRenderer(ports){\n${body}\nreturn {createController:yce,MenuItem:Kj,makeTarget:kA,choicesOf:kRe,previewOf:ORe};}\nexport {createMountRenderer};`; + const virtual = `${imports.join("\n")}\nfunction createMountRenderer(ports){\n${body}\nreturn {createController:Ule,MenuItem:xT,makeTarget:FUe,choicesOf:RUe,previewOf:IUe,markStateOf:qVe};}\nexport {createMountRenderer};`; const bundled = await bundleUpstreamModule({ archive: { ...archive, read(relative) { return relative === entry ? Buffer.from(virtual) : archive.read(relative); } }, - entry, exports: ["createMountRenderer"] }); + entry, exports: ["createMountRenderer"], bindings: browserBindings }); const compiled = await transform(bundled.code, { format: "iife", globalName: "RDesktopMountUpstream0721", target: "es2022" }); return { code: compiled.code, provenance: { upstream: archive.identity, source: extracted.provenance, modules: bundled.modules } }; } @@ -52,7 +68,7 @@ const RDesktopMountMenu0721=RDesktopMountParts0721.MenuItem; const RDesktopMountClient0721={...Er,roster:{...Er.roster,snapshots:{...Er.roster.snapshots, get:()=>{const state=Er.roster.snapshots.get();return {...state,agentsById:new Map(state.agents.rows.map(agent=>[agent.id,agent]))};}}}}; RDesktopMountController0721=RDesktopMountParts0721.createController({source:window.desktopMount,client:RDesktopMountClient0721, - choicesOf:RDesktopMountParts0721.choicesOf,previewOf:RDesktopMountParts0721.previewOf,discardStaged:vft}); + choicesOf:RDesktopMountParts0721.choicesOf,previewOf:RDesktopMountParts0721.previewOf,markStateOf:RDesktopMountParts0721.markStateOf,discardStaged:vft}); window.addEventListener("pagehide",()=>RDesktopMountController0721.dispose(),{once:true}); `; } @@ -78,7 +94,7 @@ export async function applyDesktopMountRenderer0721({ stageRoot }) { parse(patched, { ecmaVersion: "latest", sourceType: "module" }); await writeFile(path.join(assets, file), patched); const provenance = { ...generated.provenance, file, originalSha256: sha(source), patchedSha256: sha(patched), - adapter: "existing-send-journal-and-draft-recovery", upstreamController: "yce", upstreamMenu: "Kj" }; + adapter: "existing-send-journal-and-draft-recovery", upstreamController: "Ule", upstreamMenu: "xT" }; await writeFile(path.join(stageRoot, "dist/renderer-desktop-mount-0721.json"), `${JSON.stringify(provenance, null, 2)}\n`); return provenance; } diff --git a/scripts/lib/generate-upstream-unpacked-manifest.mjs b/scripts/lib/generate-upstream-unpacked-manifest.mjs index 8c33b5a2..3f52f31a 100644 --- a/scripts/lib/generate-upstream-unpacked-manifest.mjs +++ b/scripts/lib/generate-upstream-unpacked-manifest.mjs @@ -5,8 +5,8 @@ import { fileURLToPath } from "node:url"; import { statFile } from "@electron/asar"; const repoRoot = fileURLToPath(new URL("../../", import.meta.url)); -const asarPath = path.resolve(repoRoot, "../rea-grokbot-0750/asar/app.asar"); -const outputPath = path.join(repoRoot, "manifests/ports/grokbot-0750-unpacked.json"); +const asarPath = path.resolve(repoRoot, "../rea-grokbot-0755/asar/app.asar"); +const outputPath = path.join(repoRoot, "manifests/ports/grokbot-0755-unpacked.json"); const sha256 = (bytes) => createHash("sha256").update(bytes).digest("hex"); const NATIVE_PATHS = [ @@ -29,8 +29,8 @@ for (const relative of NATIVE_PATHS) { const manifest = { schemaVersion: 1, - version: "0.75.0", - source: "rea-grokbot-0750/asar/app.asar.unpacked", + version: "0.75.5", + source: "rea-grokbot-0755/asar/app.asar.unpacked", integritySource: "captured-unpacked-bytes", files, }; diff --git a/scripts/lib/settings-i18n-patch.mjs b/scripts/lib/settings-i18n-patch.mjs index 0d8070e7..c54e6027 100644 --- a/scripts/lib/settings-i18n-patch.mjs +++ b/scripts/lib/settings-i18n-patch.mjs @@ -218,13 +218,28 @@ const PA_ANCHOR = "function pa(){"; const RUNTIME_PRELUDE = RUNTIME_LINES.join(ENGINE_NL) + ENGINE_NL; +const OPTIONAL_SETTINGS_I18N_PAIRS = new Set(["Accent", "Black", "Bot color"]); + export function patchOriginalSettingsI18n(source) { if (source.indexOf(PA_ANCHOR) < 0) throw new Error("Original renderer Settings anchor is missing."); let patched = PA_ANCHOR_REPLACEMENT(source); const applied = []; for (const [en, zh] of SETTINGS_I18N_PAIRS) { const mode = SETTINGS_I18N_PANEL.has(en) ? "PANEL" : "FULL"; - const result = applyEnginePair(patched, en, zh, mode); + let result; + try { + result = applyEnginePair(patched, en, zh, mode); + } catch (error) { + // Optional rows added by later renderer extensions can leave a label + // only inside a quoted span that the pair matcher deliberately ignores. + // A missing optional translation must not abort packaging; record it and + // keep the original English literal. + if (error instanceof Error && OPTIONAL_SETTINGS_I18N_PAIRS.has(en) && error.message.startsWith("i18n pair has no anchor outside string spans:")) { + applied.push({ en, mode, hits: 0, skipped: true }); + continue; + } + throw error; + } patched = result.patched; applied.push({ en, mode, hits: result.hits }); } diff --git a/scripts/lib/settings-update-0753-patch.mjs b/scripts/lib/settings-update-0753-patch.mjs new file mode 100644 index 00000000..6c0b0d37 --- /dev/null +++ b/scripts/lib/settings-update-0753-patch.mjs @@ -0,0 +1,124 @@ +// Settings → Updates, ported from the official Grok Bot 0.75.3 update pane +// (`chunk-view-DROqRPMJ.js`): Automatic Updates + Version/status row, with the +// update-track row hidden because the reconstructed GitHub feed has one track. +// The component uses the 0.18 settings kit already in the chunk (SettingsGroup, +// SettingsRow, Button, Switch) and the existing update controller hooks. + +import { createHash } from "node:crypto"; +import { readdir, readFile, writeFile } from "node:fs/promises"; +import path from "node:path"; +import { parse } from "acorn"; + +const hash = text => createHash("sha256").update(text).digest("hex"); + +const PANEL_MARKERS = ["Update Track", "Grok Bot Updates", "Check for Updates"]; + +const REPLACEMENT = `function MA_PLACEHOLDER(){ + const {status:e,isLoading:t}=us(); + const {check:n,isPending:d}=ms(); + const {setTrack:l,isPending:r}=fs(); + const {setAutoUpdateWhenIdleOptIn:i,isPending:o}=hs(); + const {quitAndInstall:c}=bs(); + const f=ps(); + const {externalLinkHandlers:h}=Fe(); + const m=ys(),u=gs(),p=vs(),b=xs(); + const {setEnabled:y,isPending:j}=ks(); + const v=m&&u; + let E; + if(p){E=ca(b)}else if(v){E="Route web traffic from Grok Bot's computer out through this desktop instead of the cloud. Applies to new connections."}else{E="Grok Bot's computer wasn't provisioned with the egress tunnel — start a new one to use this."} + const C=(m||p)?a.jsx(re,{title:"Egress",children:a.jsx(ie,{description:E,label:"Route egress through this desktop",variant:"card",children:a.jsx(Ne,{isChecked:p,isDisabled:j||!v&&!p,label:"Route egress through this desktop",onToggle:()=>y(!p)})})}):null; + if(e==null){ + const msg=t?RLocT("Loading update status…","正在加载更新状态…"):RLocT("Grok Bot couldn't load update status. Check again to retry.","Grok Bot 无法加载更新状态。请再次检查以重试。"); + const btn=a.jsx(oe,{disabled:t,onClick:()=>n(),shape:"rectangular",size:"md",style:[ke.body2,pe.checkWeakBorder],variant:"secondary",children:RLocT("Check for Updates","检查更新")}); + return a.jsxs(a.Fragment,{children:[C,a.jsx(re,{title:RLocT("Grok Bot Updates","Grok Bot 更新"),children:a.jsx(ie,{description:msg,label:RLocT("Grok Bot Updates","Grok Bot 更新"),variant:"card",children:btn})})]}); + } + const st=e.state; + const I=st.type==="disabled"; + const M=st.type==="checking"; + const P=M||st.type==="available"||st.type==="downloading"||st.type==="staging"; + const ready=st.type==="ready"; + const status=RCompUpdateStatusText(e); + const checkLabel=t||d||M?RLocT("Checking…","检查中…"):RLocT("Check for Updates","检查更新"); + const autoRow=a.jsx(ie,{description:RLocT("Automatically update your client while you're away.","在你离开时自动更新客户端。"),label:RLocT("Automatic Updates","自动更新"),variant:"card",children:a.jsx(Ne,{isChecked:e.autoUpdateWhenIdleOptIn,isDisabled:I||o,label:RLocT("Automatic Updates","自动更新"),onToggle:()=>i(!e.autoUpdateWhenIdleOptIn)})}); + const versionLabel=RLocT("Version ","版本 ")+e.currentVersion; + const extra=a.jsx("a",{href:"https://github.com/tyonger-stack/GrokNode/releases",rel:"noopener noreferrer",target:"_blank",children:"GitHub Releases"}); + const action=ready?a.jsx(Ns,{onClick:()=>{we({surface:"settings",action:"clicked",kind:"ready",targetVersion:st.version});c()},size:"md",variant:"primary",children:RLocT("Restart to Update","更新并重启")}):a.jsx(oe,{disabled:I||P||d,onClick:()=>{we({surface:"settings",action:"clicked",kind:"check"});n()},shape:"rectangular",size:"md",style:[ke.body2,pe.checkWeakBorder],variant:"secondary",children:checkLabel}); + const versionRow=a.jsx(ie,{description:status,extraCopy:extra,label:versionLabel,variant:"card",children:action}); + const group=a.jsx(re,{title:RLocT("Grok Bot Updates","Grok Bot 更新"),children:[autoRow,versionRow]}); + return a.jsxs(a.Fragment,{children:[C,group]}); +} +function RCompUpdateStatusText(s){ + const st=s.state; + if(st.type==="disabled"){ + if(st.reason==="disabled-by-env")return RLocT("Updates are disabled by SAND_DISABLE_UPDATES","更新已被 SAND_DISABLE_UPDATES 停用"); + if(st.reason==="lab-build")return RLocT("Grok Bot Lab is a one-off test build and never auto-updates","Grok Bot Lab 是一次性测试构建,绝不会自动更新"); + if(st.reason==="not-packaged")return RLocT("Updates are disabled in dev builds","开发构建中已停用更新"); + return RLocT("Updates aren't available on this platform","此平台不支持更新"); + } + if(st.type==="checking")return RLocT("Checking for updates…","正在检查更新…"); + if(st.type==="available")return RLocT("Grok Bot ","Grok Bot ")+st.version+RLocT(" is available"," 可用"); + if(st.type==="downloading")return RLocT("Downloading Grok Bot ","正在下载 Grok Bot ")+st.version+"…"; + if(st.type==="staging")return RLocT("Preparing Grok Bot ","正在准备 Grok Bot ")+st.version+"…"; + if(st.type==="ready")return RLocT("Grok Bot ","Grok Bot ")+st.version+RLocT(" is ready. Restart to apply."," 已就绪,重启以应用。"); + if(st.type==="idle"){ + const lc=st.lastCheck; + if(lc==null)return ""; + if(lc.result==="up-to-date")return RLocT("You're up to date","已是最新版本"); + return RLocT("Update check failed: ","更新检查失败:")+(lc.errorMessage||RLocT("unknown error","未知错误")); + } + return ""; +} +`; + +function findPanel(source) { + const ast = parse(source, { ecmaVersion: "latest", sourceType: "module" }); + const found = []; + for (const node of ast.body) { + if (node.type !== "FunctionDeclaration" || node.id == null) continue; + const body = source.slice(node.start, node.end); + if (PANEL_MARKERS.every(marker => body.includes(marker))) found.push({ node, name: node.id.name }); + } + return found; +} + +export function patchSettingsUpdate0753(source) { + if (source.includes("RCompUpdateStatusText(")) return { text: source, applied: false, reason: "already-present" }; + const candidates = findPanel(source); + if (candidates.length !== 1) throw new Error(`Update panel patch: expected one settings panel, found ${candidates.length}.`); + const { node, name } = candidates[0]; + const replacement = REPLACEMENT.replace("MA_PLACEHOLDER", name); + let patched = source.slice(0, node.start) + replacement + source.slice(node.end); + const computerCall = /,a\.jsx\(qs,\{[^{}]*\}\)/; + if (!computerCall.test(patched)) throw new Error("Update panel patch: computer section call not found."); + patched = patched.replace(computerCall, ""); + parse(patched, { ecmaVersion: "latest", sourceType: "module" }); + return { text: patched, applied: true, reason: "patched", name }; +} + +export async function applySettingsUpdate0753Patch({ stageRoot }) { + const assets = path.join(stageRoot, "dist", "renderer", "assets"); + const files = (await readdir(assets)).filter(file => file.endsWith(".js")); + const candidates = []; + for (const file of files) { + const source = await readFile(path.join(assets, file), "utf8"); + // The main renderer also carries the update-pill copy. The settings chunk is + // the one that owns the Appearance section and the bot-color row. + if (source.includes("function pa(){") && source.includes("RbcAccentRow(") && PANEL_MARKERS.every(marker => source.includes(marker))) candidates.push({ file, source }); + } + if (candidates.length !== 1) throw new Error(`Update panel patch: expected one settings chunk, found ${candidates.length}.`); + const { file, source } = candidates[0]; + const result = patchSettingsUpdate0753(source); + if (!result.applied) { console.log(`Update panel: skipped (${result.reason})`); return { mode: "settings-update-0753", applied: false, reason: result.reason }; } + await writeFile(path.join(assets, file), result.text); + console.log(`Update panel: ported official 0.75.3 Automatic Updates + Version card (${file}).`); + const provenance = { + mode: "settings-update-0753", + referenceVersion: "0.75.3", + reference: "chunk-view-DROqRPMJ.js", + file, + files: [{ file, originalSha256: hash(source), patchedSha256: hash(result.text) }], + features: ["automatic-updates-row", "version-status-check-row", "single-github-releases-track", "no-computer-section-in-updates"], + }; + await writeFile(path.join(stageRoot, "dist", "renderer-settings-update-0753-extension.json"), JSON.stringify(provenance, null, 2) + "\n"); + return provenance; +} diff --git a/scripts/lib/update-pill-copy-0755-patch.mjs b/scripts/lib/update-pill-copy-0755-patch.mjs new file mode 100644 index 00000000..4c247c9a --- /dev/null +++ b/scripts/lib/update-pill-copy-0755-patch.mjs @@ -0,0 +1,61 @@ +// The 0.18 renderer already contains the official footer update pill and the +// "Update ready" modal. The reconstructed UI kept older English copy, so port +// the official 0.75.5 strings into those existing components. + +import { createHash } from "node:crypto"; +import { readdir, readFile, writeFile } from "node:fs/promises"; +import path from "node:path"; + +const hash = text => createHash("sha256").update(text).digest("hex"); + +const REPLACEMENTS = [ + [ + 'Xbn="A new version of the app is available",Qbn="A new version of Grok Bot\'s computer is available",eTn="Updates are ready for Grok Bot and its computer",bve="Update queued — click to cancel";', + 'Xbn=RLocT("A new version is available","有新版本可用"),Qbn=RLocT("A new version of Grok Node\'s computer is available","Grok Node 的电脑有新版本可用"),eTn=RLocT("Updates are ready for Grok Node and its computer","Grok Node 和电脑都有更新"),bve=RLocT("Update queued — click to cancel","更新已排队,点击取消");', + ], + [ + "description:`Restart to finish installing Grok Bot ${n}. Your agents and work will be right where you left them.`", + 'description:RLocT("Restart to finish installing Grok Bot "+n+". Your Bots and work will be right where you left them.","重启以完成 Grok Bot "+n+" 的安装。你的 Bot 和工作都会原样保留。")', + ], + [ + 'confirmLabel:(RLocT("Restart to update","更新并重启"))', + 'confirmLabel:RLocT("Update","更新")', + ], +]; + +export function patchUpdatePillCopy(source) { + let patched = source; + const applied = []; + for (const [before, after] of REPLACEMENTS) { + const hits = patched.split(before).length - 1; + if (hits !== 1) throw new Error(`Update pill copy anchor expected once, found ${hits}: ${before.slice(0, 60)}`); + patched = patched.replace(before, after); + applied.push({ before: before.slice(0, 60), hits }); + } + return { text: patched, applied }; +} + +export async function applyUpdatePillCopy0755Patch({ stageRoot }) { + const assets = path.join(stageRoot, "dist", "renderer", "assets"); + const files = (await readdir(assets)).filter(file => file.endsWith(".js")); + const candidates = []; + for (const file of files) { + const source = await readFile(path.join(assets, file), "utf8"); + if (source.includes('Xbn="A new version of the app is available"') && source.includes("function aIe(")) candidates.push({ file, source }); + } + if (candidates.length !== 1) throw new Error(`Update pill copy patch: expected one main renderer chunk, found ${candidates.length}.`); + const { file, source } = candidates[0]; + const result = patchUpdatePillCopy(source); + await writeFile(path.join(assets, file), result.text); + console.log(`Update pill copy: ported official 0.75.5 strings (${file}).`); + const provenance = { + mode: "update-pill-copy-0755", + referenceVersion: "0.75.5", + file, + files: [{ file, originalSha256: hash(source), patchedSha256: hash(result.text) }], + features: ["footer-update-pill-copy", "update-ready-modal-copy"], + applied: result.applied, + }; + await writeFile(path.join(stageRoot, "dist", "renderer-update-pill-copy-0755.json"), JSON.stringify(provenance, null, 2) + "\n"); + return provenance; +} diff --git a/scripts/lib/upstream-0755.mjs b/scripts/lib/upstream-0755.mjs new file mode 100644 index 00000000..6e0b2d6f --- /dev/null +++ b/scripts/lib/upstream-0755.mjs @@ -0,0 +1,18 @@ +import { fileURLToPath } from "node:url"; +import { createUpstreamAsarIdentity, openUpstreamAsar, upstreamAsarPaths } from "./upstream-asar.mjs"; + +export const UPSTREAM_0755 = createUpstreamAsarIdentity( + "0.75.5", + "12bba50ba6cf12b35132518788610677a3fdc65de4ad849628d757bc7b780e5a", +); + +const repoRoot = fileURLToPath(new URL("../../", import.meta.url)); +const { defaultAsar, nativeManifestPath } = upstreamAsarPaths( + repoRoot, + "rea-grokbot-0755", + "manifests/ports/grokbot-0755-unpacked.json", +); + +export async function openUpstream0755({ asarPath = process.env.GROK_BOT_0755_ASAR ?? defaultAsar } = {}) { + return openUpstreamAsar(UPSTREAM_0755, { asarPath, nativeManifestPath }); +} diff --git a/scripts/lib/upstream-module.mjs b/scripts/lib/upstream-module.mjs index 1c89ace8..47e96239 100644 --- a/scripts/lib/upstream-module.mjs +++ b/scripts/lib/upstream-module.mjs @@ -5,7 +5,7 @@ import { parse } from "acorn"; import { build } from "esbuild"; import { extractUpstreamDeclarations } from "./upstream-declarations.mjs"; -export async function bundleUpstreamModule({ archive, entry, exports: requested, platform = "browser" }) { +export async function bundleUpstreamModule({ archive, entry, exports: requested, platform = "browser", bindings = {} }) { const sources = new Map(); const demands = new Map([[entry, new Set(requested)]]); const output = new Map(); @@ -27,7 +27,7 @@ export async function bundleUpstreamModule({ archive, entry, exports: requested, if (!local) throw new Error(`Missing upstream export ${name} in ${relative}`); exports[name] = local; } - const extracted = extractUpstreamDeclarations({ code: source, exports, strict: true }); + const extracted = extractUpstreamDeclarations({ code: source, exports, bindings, strict: true }); output.set(relative, extracted); const selected = parse(extracted.code, { ecmaVersion: "latest", sourceType: "module" }); for (const node of selected.body) { diff --git a/scripts/lib/vault-0721.mjs b/scripts/lib/vault-0721.mjs index 5f4487f5..40706f0c 100644 --- a/scripts/lib/vault-0721.mjs +++ b/scripts/lib/vault-0721.mjs @@ -3,15 +3,15 @@ import os from "node:os"; import path from "node:path"; import { fileURLToPath } from "node:url"; import { build } from "esbuild"; -import { openUpstream0721 } from "./upstream-0721.mjs"; +import { openUpstream0755 } from "./upstream-0755.mjs"; import { extractUpstreamDeclarations } from "./upstream-declarations.mjs"; const repoRoot = fileURLToPath(new URL("../../", import.meta.url)); const defaultOutput = path.join(repoRoot, "source/electron-main/vault/upstream-vault-parsers.generated.mjs"); export const UPSTREAM_VAULT_SOURCES = Object.freeze({ - view: "dist/renderer/assets/chunk-view-Cwu5IFAB.js", - cardFields: "dist/renderer/assets/chunk-vault-card-fields-BBZgWwVF.js", + view: "dist/renderer/assets/chunk-view-CuYU9NOh.js", + cardFields: "dist/renderer/assets/chunk-vault-card-dialog-C8ioyi_k.js", csvParse: "dist/renderer/assets/chunk-csv-parse-C5LpQq5n.js", mainApp: "dist/electron-main/main-app.cjs", }); @@ -20,7 +20,7 @@ export async function buildUpstreamVaultParsers({ archive: archiveInput, output = defaultOutput, } = {}) { - const archive = archiveInput ?? await openUpstream0721(); + const archive = archiveInput ?? await openUpstream0755(); const view = archive.read(UPSTREAM_VAULT_SOURCES.view).toString("utf8"); const cardFields = archive.read(UPSTREAM_VAULT_SOURCES.cardFields).toString("utf8"); const csvParse = archive.read(UPSTREAM_VAULT_SOURCES.csvParse).toString("utf8"); @@ -29,27 +29,27 @@ export async function buildUpstreamVaultParsers({ const viewExtraction = extractUpstreamDeclarations({ code: view, exports: { - parseCsv: "Me", - planLogin: "ke", - planCard: "Ae", - duplicateKeys: "je", - parseExpiry: "Ee", - formatExpiry: "De", + parseCsv: "Ve", + planLogin: "Re", + planCard: "ze", + duplicateKeys: "Be", + parseExpiry: "Fe", + formatExpiry: "Ie", }, strict: true, }); const cardExtraction = extractUpstreamDeclarations({ code: cardFields, - exports: { validateCardNumber: "re", cardPhotoValues: "ce", m: "re" }, + exports: { validateCardNumber: "Y", cardPhotoValues: "gt", m: "Y", y: "Y" }, strict: true, }); const mainExtraction = extractUpstreamDeclarations({ code: mainApp, exports: { - parseRecognizedCard: "mat", - detectCardNumber: "gat", - detectCardBrand: "HMn", - validateSecurityCode: "cMn", + parseRecognizedCard: "o$", + detectCardNumber: "nPn", + detectCardBrand: "r$", + validateSecurityCode: "fMn", }, strict: true, }); @@ -57,12 +57,12 @@ export async function buildUpstreamVaultParsers({ const root = await mkdtemp(path.join(os.tmpdir(), "grok-vault-upstream-")); try { await writeFile(path.join(root, "view.mjs"), viewExtraction.code); - await writeFile(path.join(root, "chunk-vault-card-fields-BBZgWwVF.js"), cardExtraction.code); + await writeFile(path.join(root, "chunk-vault-card-dialog-C8ioyi_k.js"), cardExtraction.code); await writeFile(path.join(root, "main.mjs"), mainExtraction.code); await writeFile(path.join(root, "chunk-csv-parse-C5LpQq5n.js"), csvParse); await writeFile(path.join(root, "entry.mjs"), [ 'export { parseCsv, planLogin, planCard, duplicateKeys, parseExpiry, formatExpiry } from "./view.mjs";', - 'export { validateCardNumber, cardPhotoValues } from "./chunk-vault-card-fields-BBZgWwVF.js";', + 'export { validateCardNumber, cardPhotoValues } from "./chunk-vault-card-dialog-C8ioyi_k.js";', 'export { parseRecognizedCard, detectCardNumber, detectCardBrand, validateSecurityCode } from "./main.mjs";', "", ].join("\n")); @@ -91,7 +91,7 @@ export async function buildUpstreamVaultParsers({ }; const bundledCode = bundled.outputFiles[0].text.replaceAll(root, ""); const contents = [ - "// Generated by scripts/lib/vault-0721.mjs from the pinned Grok Bot 0.72.1 ASAR. Do not edit.", + "// Generated by scripts/lib/vault-0721.mjs from the pinned Grok Bot 0.75.5 ASAR. Do not edit.", "// provenance=" + JSON.stringify(provenance), bundledCode, "", diff --git a/scripts/lib/vault-renderer-patch.mjs b/scripts/lib/vault-renderer-patch.mjs index b21ca56f..f6462e5e 100644 --- a/scripts/lib/vault-renderer-patch.mjs +++ b/scripts/lib/vault-renderer-patch.mjs @@ -5,7 +5,7 @@ import path from "node:path"; import { fileURLToPath } from "node:url"; import { build } from "esbuild"; import { parse } from "acorn"; -import { openUpstream0721 } from "./upstream-0721.mjs"; +import { openUpstream0755 } from "./upstream-0755.mjs"; import { bundleUpstreamModule } from "./upstream-module.mjs"; import { chunkReactPlugin } from "./library-host-renderer-patch.mjs"; @@ -17,7 +17,7 @@ const messagesPath = path.join(vaultDir, "upstream-vault-messages.generated.mjs" export const VAULT_RENDERER_NAMESPACE = "__sandVaultRendererNS"; export const VAULT_RENDERER_MARK = "/* sand-vault-0721 */"; -const browserGlobals = `const window=globalThis.window,document=globalThis.document,HTMLElement=globalThis.HTMLElement,HTMLInputElement=globalThis.HTMLInputElement,HTMLSelectElement=globalThis.HTMLSelectElement,reportError=globalThis.reportError,ResizeObserver=globalThis.ResizeObserver,cancelAnimationFrame=globalThis.cancelAnimationFrame,getComputedStyle=globalThis.getComputedStyle,requestAnimationFrame=globalThis.requestAnimationFrame,navigator=globalThis.navigator,location=globalThis.location,history=globalThis.history,__REACT_DEVTOOLS_GLOBAL_HOOK__=globalThis.__REACT_DEVTOOLS_GLOBAL_HOOK__,CSS=globalThis.CSS,Element=globalThis.Element,Node=globalThis.Node,ShadowRoot=globalThis.ShadowRoot,performance=globalThis.performance;\n`; +const browserGlobals = `const window=globalThis.window,document=globalThis.document,HTMLElement=globalThis.HTMLElement,HTMLInputElement=globalThis.HTMLInputElement,HTMLSelectElement=globalThis.HTMLSelectElement,HTMLTextAreaElement=globalThis.HTMLTextAreaElement,HTMLAnchorElement=globalThis.HTMLAnchorElement,Image=globalThis.Image,Event=globalThis.Event,DOMException=globalThis.DOMException,KeyboardEvent=globalThis.KeyboardEvent,FocusEvent=globalThis.FocusEvent,MouseEvent=globalThis.MouseEvent,IntersectionObserver=globalThis.IntersectionObserver,MutationObserver=globalThis.MutationObserver,reportError=globalThis.reportError,ResizeObserver=globalThis.ResizeObserver,cancelAnimationFrame=globalThis.cancelAnimationFrame,getComputedStyle=globalThis.getComputedStyle,requestAnimationFrame=globalThis.requestAnimationFrame,navigator=globalThis.navigator,location=globalThis.location,history=globalThis.history,__REACT_DEVTOOLS_GLOBAL_HOOK__=globalThis.__REACT_DEVTOOLS_GLOBAL_HOOK__,CSS=globalThis.CSS,Element=globalThis.Element,Node=globalThis.Node,ShadowRoot=globalThis.ShadowRoot,performance=globalThis.performance;\n`; // Upstream initializes some module-level factories with a side-effect pattern: // var cc,lc;(class e{ ... static{ cc=...; lc=... } ... }) @@ -55,11 +55,11 @@ export function inlineClassStaticFactories(source) { return out + source.slice(cursor); } const virtualEntry = "dist/renderer/assets/sand-vault-0721-entry.js"; -const upstreamView = "dist/renderer/assets/chunk-view-Cwu5IFAB.js"; -const upstreamEagerApp = "dist/renderer/assets/index.eager-app-CG8Fw00L.js"; -const upstreamCommon = "dist/renderer/assets/index.eager-common-BH0hmUYG.js"; -const upstreamCss = "dist/renderer/assets/index-CMR1RvAA.css"; -const upstreamVendor = "dist/renderer/assets/index.eager-vendor-cR6BHVc-.js"; +const upstreamView = "dist/renderer/assets/chunk-view-CuYU9NOh.js"; +const upstreamEagerApp = "dist/renderer/assets/index.eager-app-uZS5Ltig.js"; +const upstreamCommon = "dist/renderer/assets/index.eager-common-F4Y1-gMW.js"; +const upstreamCss = "dist/renderer/assets/index-CFSAhbDS.css"; +const upstreamVendor = "dist/renderer/assets/index.eager-vendor-CRCbzhle.js"; function replaceOnce(source, before, after, label) { const first = source.indexOf(before); @@ -79,25 +79,25 @@ function transformUpstreamArchive(archive) { read(relative) { if (process.env.SAND_VAULT_DEBUG) console.error("vault-read", relative); const bytes = relative === virtualEntry - ? Buffer.from(`import {sandVaultSettings as settings} from "./chunk-view-Cwu5IFAB.js"; import {sandVaultCreateStore as createStore} from "./index.eager-app-CG8Fw00L.js"; import {F as linguiProvider} from "./index.eager-vendor-cR6BHVc-.js"; export {settings as default, createStore as createUpstreamVaultStore, linguiProvider as createUpstreamVaultLinguiProvider};\n`) + ? Buffer.from(`import {sandVaultSettings as settings} from "./chunk-view-CuYU9NOh.js"; import {sandVaultCreateStore as createStore} from "./index.eager-app-uZS5Ltig.js"; import {et as linguiProvider} from "./index.eager-vendor-CRCbzhle.js"; import {r as paneHeaderProvider} from "./chunk-pane-header-BbJph3XZ.js"; export {settings as default, createStore as createUpstreamVaultStore, linguiProvider as createUpstreamVaultLinguiProvider, paneHeaderProvider as createUpstreamVaultPaneHeaderProvider};\n`) : archive.read(relative); let source = Buffer.concat([Buffer.from(browserGlobals), bytes]).toString("utf8"); if (relative === upstreamCommon) { - source = replaceOnce(source, "Je as V", "sandVaultReact as V", "React port"); + source = replaceOnce(source, "ot as At", "sandVaultReact as At", "React port"); source = `function sandVaultReact(){return globalThis.__sandVaultReact}\n${source}`; } if (relative === upstreamEagerApp) { source = replaceOnce(source, "function Q(){", "function SandOriginalVaultQ(){", "client hook"); - source = replaceOnce(source, "function Ip(){", "function SandOriginalVaultIp(){", "auth hook"); - source = `function Q(){return globalThis.__sandVault0721Client}\nfunction Ip(){return {status:{kind:"logged-in"}}}\n${source}`; + source = replaceOnce(source, "function up(){return Nc(Q().auth.snapshots)}", "function up(){return {status:{kind:\"logged-in\"}}}", "auth hook"); + source = `function Q(){return globalThis.__sandVault0721Client}\n${source}`; const tail = source.lastIndexOf("};"); if (tail < 0) throw new Error("Upstream eager-app export table is missing."); - source = source.slice(0, tail) + ",qen as sandVaultCreateStore" + source.slice(tail); + source = source.slice(0, tail) + ",Gmn as sandVaultCreateStore" + source.slice(tail); if (process.env.SAND_VAULT_DEBUG) console.error(source.slice(Math.max(0, source.length - 500))); } if (process.env.SAND_VAULT_DEBUG && relative === virtualEntry) console.error(JSON.stringify(source.slice(0, 180))); if (relative === upstreamView) { - source = replaceOnce(source, "Cn as default", "Cn as default,Cn as sandVaultSettings", "settings export"); + source = replaceOnce(source, "gr as default", "gr as default,gr as sandVaultSettings", "settings export"); } if (relative === upstreamCommon || relative === upstreamEagerApp || relative === upstreamView || relative === upstreamVendor) { source = inlineClassStaticFactories(source); @@ -162,11 +162,11 @@ function extractScopedVaultCss(css, classNames) { } export async function buildUpstreamVaultSettings() { - const archive = transformUpstreamArchive(await openUpstream0721()); + const archive = transformUpstreamArchive(await openUpstream0755()); const result = await bundleUpstreamModule({ archive, entry: virtualEntry, - exports: ["default", "createUpstreamVaultStore", "createUpstreamVaultLinguiProvider"], + exports: ["default", "createUpstreamVaultStore", "createUpstreamVaultLinguiProvider", "createUpstreamVaultPaneHeaderProvider"], platform: "browser", }); let code = result.code.replaceAll(os.tmpdir(), ""); @@ -180,7 +180,7 @@ export async function buildUpstreamVaultSettings() { styleSha256: createHash("sha256").update(css).digest("hex"), }; const contents = [ - "// Generated by scripts/lib/vault-renderer-patch.mjs from the pinned Grok Bot 0.72.1 ASAR. Do not edit.", + "// Generated by scripts/lib/vault-renderer-patch.mjs from the pinned Grok Bot 0.75.5 ASAR. Do not edit.", `// provenance=${JSON.stringify(provenance)}`, `export const upstreamVaultStyle = ${JSON.stringify(css)};`, code, @@ -232,21 +232,21 @@ function extractCatalogEntries(source, ids) { } export async function buildUpstreamVaultMessages(settingsBundleCode) { - const archive = await openUpstream0721(); + const archive = await openUpstream0755(); const ids = collectBundleMessageIds(settingsBundleCode); if (ids.size < 20) throw new Error(`Vault bundle exposed too few message ids: ${ids.size}`); const en = extractCatalogEntries(archive.read(upstreamEagerApp).toString("utf8"), ids); let zhSource = null; for (const file of archive.files) { - if (!/dist\/renderer\/assets\/chunk-agents-[^/]+\.js$/u.test(file)) continue; + if (!/dist\/renderer\/assets\/chunk-settings-[^/]+\.js$/u.test(file)) continue; const text = archive.read(file).toString("utf8"); - if (text.includes("\u6302\u8f7d\u5230\u684c\u9762")) { zhSource = text; break; } + if (text.includes('"NLLW52"') && text.includes("\u4fdd\u9669\u5e93")) { zhSource = text; break; } } if (zhSource === null) throw new Error("Simplified Chinese renderer catalog was not found"); const zh = extractCatalogEntries(zhSource, ids); const provenance = { upstream: archive.identity, ids: ids.size, en: Object.keys(en).length, zhCN: Object.keys(zh).length }; const contents = [ - "// Generated by scripts/lib/vault-renderer-patch.mjs from the pinned Grok Bot 0.72.1 ASAR. Do not edit.", + "// Generated by scripts/lib/vault-renderer-patch.mjs from the pinned Grok Bot 0.75.5 ASAR. Do not edit.", `// provenance=${JSON.stringify(provenance)}`, `export const upstreamVaultMessages = ${JSON.stringify({ en, "zh-CN": zh })};`, "", @@ -282,7 +282,9 @@ export async function buildVaultRendererBundle() { if (!file.includes("RVaultSettingsHost")) throw new Error("Vault renderer bundle did not emit RVaultSettingsHost."); if (/from\s+"react"|require\("react"\)/u.test(file)) throw new Error("Vault renderer bundle bundled a second React runtime."); if (/createRoot\s*\(/u.test(file)) throw new Error("Vault renderer bundle must mount inside the existing React tree."); - if (/new\s+MutationObserver/u.test(file)) throw new Error("Vault renderer bundle must not install a DOM observer."); + if (/new\s+MutationObserver[\s\S]{0,320}\.observe\(\s*(?:document\.(?:body|documentElement)|window)\b/u.test(file)) { + throw new Error("Vault renderer bundle must not observe the document root."); + } const inputs = Object.keys(result.metafile.inputs).map((input) => path.resolve(repoRoot, input)); if (inputs.some((input) => /[/\\]node_modules[/\\](react|react-dom)[/\\]/u.test(input))) { throw new Error("Vault renderer must compile against the pinned chunk React runtime."); diff --git a/scripts/lib/vault-resources-0721.mjs b/scripts/lib/vault-resources-0721.mjs index 55f1cf1f..77543946 100644 --- a/scripts/lib/vault-resources-0721.mjs +++ b/scripts/lib/vault-resources-0721.mjs @@ -2,14 +2,14 @@ import { createHash } from "node:crypto"; import { mkdir, readFile, writeFile } from "node:fs/promises"; import path from "node:path"; import { fileURLToPath } from "node:url"; -import { openUpstream0721 } from "./upstream-0721.mjs"; +import { openUpstream0755 } from "./upstream-0755.mjs"; import { buildUpstreamVaultParsers } from "./vault-0721.mjs"; const root = fileURLToPath(new URL("../../", import.meta.url)); const sha = (value) => createHash("sha256").update(value).digest("hex"); export async function stageVaultResources0721({ outputRoot, archive: supplied } = {}) { - const archive = supplied ?? await openUpstream0721(); + const archive = supplied ?? await openUpstream0755(); const output = path.resolve(outputRoot, "dist/upstream-0721/vault-parsers.mjs"); const generated = await buildUpstreamVaultParsers({ archive, output }); const expected = await readFile(path.join(root, "source/electron-main/vault/upstream-vault-parsers.generated.mjs")); diff --git a/scripts/lib/vault-settings-renderer-patch.mjs b/scripts/lib/vault-settings-renderer-patch.mjs index 95719dce..fc59a7c3 100644 --- a/scripts/lib/vault-settings-renderer-patch.mjs +++ b/scripts/lib/vault-settings-renderer-patch.mjs @@ -4,11 +4,11 @@ import path from "node:path"; import { parse } from "acorn"; import { buildVaultRendererBundle, VAULT_RENDERER_MARK } from "./vault-renderer-patch.mjs"; -const REGISTRY_ANCHOR = 'const wDn=[{id:"general",label:"General",icon:"settings-gear"},'; -const REGISTRY_ENTRY = '{id:"vault",label:"Vault",icon:"vault"},'; +const REGISTRY_ANCHOR = '{id:"computer",label:RLocT("Computer","电脑"),icon:"device-desktop"},'; +const REGISTRY_ENTRY = '{id:"vault",label:RLocT("Vault","保险库"),icon:"vault"},'; // Anchors on the general-section test itself so the pass composes with the // local-teams patch, which rewrites the leading `Q=` of this ternary chain. -const PANEL_ANCHOR = 'x==="general"?a.jsx(Te,{children:a.jsx(Sa,{auth:t})}):'; +const PANEL_ANCHOR = 'x==="router"?a.jsx(RRouterPanel,{}):'; const PANEL_BRANCH = 'x==="vault"?a.jsx(Te,{children:a.jsx(globalThis.__sandVaultRendererNS.RVaultSettingsHost,{focusSetting:null})}):'; function replaceOnce(source, before, after, label) { @@ -46,6 +46,6 @@ export async function applyVaultSettingsRenderer0721({ stageRoot }) { const provenance = { version: 1, feature: "vault-settings-0721", files, upstream: built.generated.provenance, messages: built.messages?.provenance ?? null }; await writeFile(path.join(stageRoot, "dist/renderer/renderer-vault-settings-0721.json"), `${JSON.stringify(provenance, null, 2)}\n`); - console.log(`Vault settings: original 0.72.1 panel mounted into ${registry[0].name} + ${panel[0].name}`); + console.log(`Vault settings: original 0.75.5 panel mounted into ${registry[0].name} + ${panel[0].name}`); return provenance; } diff --git a/scripts/lib/visualization-0721.mjs b/scripts/lib/visualization-0721.mjs index f9b9ef20..a478a092 100644 --- a/scripts/lib/visualization-0721.mjs +++ b/scripts/lib/visualization-0721.mjs @@ -2,11 +2,11 @@ import { createHash } from "node:crypto"; import { mkdir, writeFile } from "node:fs/promises"; import path from "node:path"; import { transform } from "esbuild"; -import { openUpstream0721 } from "./upstream-0721.mjs"; +import { openUpstream0755 } from "./upstream-0755.mjs"; import { bundleUpstreamModule } from "./upstream-module.mjs"; import { extractUpstreamDeclarations } from "./upstream-declarations.mjs"; -export const VISUALIZATION_0721_ENTRY = "dist/renderer/assets/chunk-visualization-document-B7ED4-0Y.js"; +export const VISUALIZATION_0721_ENTRY = "dist/renderer/assets/chunk-visualization-document-BO2hVAw0.js"; export const VISUALIZATION_0721_EXPORTS = Object.freeze([ "buildVisualizationDocument", "parseVisualizationFragment", "parseVisualizationFrameMessage", "VISUALIZATION_DOCUMENTED_TOKENS", "VISUALIZATION_FRAGMENT_MAX_BYTES", @@ -16,7 +16,7 @@ export const VISUALIZATION_0721_EXPORTS = Object.freeze([ export async function stageVisualization0721({ stageRoot, archive } = {}) { if (!stageRoot) throw new TypeError("stageVisualization0721 requires stageRoot"); - archive ??= await openUpstream0721(); + archive ??= await openUpstream0755(); const runtime = await bundleUpstreamModule({ archive, entry: VISUALIZATION_0721_ENTRY, exports: VISUALIZATION_0721_EXPORTS }); const assets = path.join(stageRoot, "dist/renderer/assets"); @@ -38,7 +38,7 @@ export async function stageVisualization0721({ stageRoot, archive } = {}) { } const protocolSource = "dist/electron-main/main-core.cjs"; const protocol = extractUpstreamDeclarations({ code: archive.read(protocolSource).toString("utf8"), - exports: { createVisualizationDocumentStore: "vV" }, bindings: { Response: "globalThis.Response" }, strict: true }); + exports: { createVisualizationDocumentStore: "UV" }, bindings: { Response: "globalThis.Response" }, strict: true }); const protocolBundle = await transform(protocol.code, { format: "cjs", target: "node22", legalComments: "none" }); const protocolPath = "dist/upstream-0721/visualization-protocol.cjs"; await mkdir(path.join(stageRoot, "dist/upstream-0721"), { recursive: true }); diff --git a/scripts/package-macos.mjs b/scripts/package-macos.mjs index 1a3ca2b0..963aacac 100644 --- a/scripts/package-macos.mjs +++ b/scripts/package-macos.mjs @@ -47,6 +47,11 @@ const infoPlist = path.join(outputApp, "Contents", "Info.plist"); await run(SYSTEM_TOOLS.plutil, ["-remove", "ElectronAsarIntegrity", infoPlist]); await run(SYSTEM_TOOLS.plutil, ["-replace", "CFBundleIdentifier", "-string", reconstructedBundleId, infoPlist]); await run(SYSTEM_TOOLS.plutil, ["-replace", "CFBundleDisplayName", "-string", reconstructedName, infoPlist]); +// Release reconstructed.1 (0.75.5 line): ship Info.plist as 0.75.5 to match official Grok Bot display/internal version. +// Upstream fidelity runtime remains the checksum-pinned 0.18.0 DMG base; only Info.plist versions change. +const releaseBundleVersion = process.env.GROK_NODE_BUNDLE_VERSION?.trim() || "0.75.5"; +await run(SYSTEM_TOOLS.plutil, ["-replace", "CFBundleShortVersionString", "-string", releaseBundleVersion, infoPlist]); +await run(SYSTEM_TOOLS.plutil, ["-replace", "CFBundleVersion", "-string", releaseBundleVersion, infoPlist]); // Hint macOS that this app's resources are localized primarily for Simplified // Chinese so it auto-translates built-in menu roles (`editMenu`, `windowMenu`, // `help`, `services`, `hide`, …) when the user is on a Chinese-locale Mac. diff --git a/source/electron-main/box/agent-data-reader.ts b/source/electron-main/box/agent-data-reader.ts new file mode 100644 index 00000000..0609b935 --- /dev/null +++ b/source/electron-main/box/agent-data-reader.ts @@ -0,0 +1,178 @@ +import { LOCAL_DOCKER_BOX_CONTAINER, runDocker } from "./local-docker-host-connector.js"; + +/** + * Read-only viewer for the per-bot data files the reconstructed box keeps under + * /home/box/sand-data (soul/persona memory, memory journal, user-level memory, + * audit log, workflows). Everything here is whitelist-only: ids/slugs/months are + * validated before they ever touch a shell command, the file set is fixed, and + * every read is byte-capped. No secrets files (box-secrets.json, connector-secrets, + * local-mcp-credentials, …) are reachable through this module. + */ + +const BOX_DATA_ROOT = "/home/box/sand-data"; +const AGENT_DATA_ROOT = `${BOX_DATA_ROOT}/agents`; +const USER_MEMORY_ROOT = `${BOX_DATA_ROOT}/user-memory/agents`; +const WORKFLOW_ROOT = `${BOX_DATA_ROOT}/workflows`; +const PROFILE_FILE = "memory/profile.md"; +const LOG_DIR = "memory/log"; +const AUDIT_FILE = "audit.jsonl"; +const USER_PROFILE_FILE = "profile.md"; +const SKILL_FILE = "SKILL.md"; + +export const AGENT_ID_PATTERN = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i; +export const MEMORY_MONTH_PATTERN = /^\d{4}-(?:0[1-9]|1[0-2])$/; +export const WORKFLOW_SLUG_PATTERN = /^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$/; + +/** Keep every cap below runDocker's own 200 KB output window so nothing is silently trimmed head-first. */ +export const TEXT_READ_CAP_BYTES = 128 * 1024; +export const AUDIT_TAIL_BYTES = 96 * 1024; +export const AUDIT_MAX_ENTRIES = 60; + +export interface AgentDataAuditEntry { readonly ts: string | null; readonly type: string; readonly summary: string } +export interface AgentDataOverview { + readonly soul: string | null; + readonly soulTruncated: boolean; + readonly userProfile: string | null; + readonly userProfileTruncated: boolean; + readonly memoryLogMonths: readonly string[]; + readonly audit: { readonly entries: readonly AgentDataAuditEntry[]; readonly truncated: boolean }; + readonly workflows: readonly string[]; +} +export type AgentDataRead = { readonly ok: true; readonly data: T } | { readonly ok: false; readonly reason: string; readonly detail?: string }; +type TextRead = { readonly ok: true; readonly content: string | null; readonly truncated: boolean }; + +export function normalizeAgentId(value: unknown): string | null { + if (typeof value !== "string") return null; + const trimmed = value.trim(); + return AGENT_ID_PATTERN.test(trimmed) ? trimmed.toLowerCase() : null; +} + +export function normalizeMemoryMonth(value: unknown): string | null { + if (typeof value !== "string") return null; + const trimmed = value.trim(); + return MEMORY_MONTH_PATTERN.test(trimmed) ? trimmed : null; +} + +export function normalizeWorkflowSlug(value: unknown): string | null { + if (typeof value !== "string") return null; + const trimmed = value.trim(); + return WORKFLOW_SLUG_PATTERN.test(trimmed) ? trimmed : null; +} + +/** + * Pure parser for a `tail -c` slice of audit.jsonl. `tail -c` keeps the END of the + * file, so only the first line can be torn; a line that does not start with "{" is + * dropped rather than guessed at. Newest entries come out first for display. + */ +export function parseAuditTail(raw: string, byteCap: number): { entries: AgentDataAuditEntry[]; truncated: boolean } { + const truncated = raw.length >= byteCap; + let lines = raw.split("\n"); + const first = lines[0]; + if (first != null && !first.trimStart().startsWith("{")) lines = lines.slice(1); + const entries: AgentDataAuditEntry[] = []; + for (const line of lines) { + const candidate = line.trim(); + if (!candidate.startsWith("{")) continue; + try { + const parsed = JSON.parse(candidate) as Record; + entries.push({ + ts: typeof parsed.ts === "string" ? parsed.ts : null, + type: typeof parsed.type === "string" ? parsed.type : "unknown", + summary: auditSummary(parsed), + }); + } catch {} + } + return { entries: entries.slice(-AUDIT_MAX_ENTRIES).reverse(), truncated }; +} + +function auditSummary(parsed: Record): string { + for (const key of ["command", "url", "path", "action", "name", "title"] as const) { + const value = parsed[key]; + if (typeof value === "string" && value.trim().length > 0) return value.length > 300 ? `${value.slice(0, 300)}…` : value; + } + const raw = JSON.stringify(parsed); + return raw.length > 300 ? `${raw.slice(0, 300)}…` : raw; +} + +function classifyDockerFailure(output: string): { ok: false; reason: string; detail?: string } { + if (/No such container/i.test(output)) return { ok: false, reason: "container-missing", detail: output }; + if (/is not running/i.test(output)) return { ok: false, reason: "container-stopped", detail: output }; + if (/is paused/i.test(output)) return { ok: false, reason: "container-paused", detail: output }; + if (/Cannot connect to the Docker daemon|docker: command not found|ENOENT|error during connect/i.test(output)) return { ok: false, reason: "docker-unavailable", detail: output }; + return { ok: false, reason: "read-failed", detail: output }; +} + +/** Heal the leaked-pause state before probing (same heuristic as the snapshot store). */ +async function execInBox(shellCommand: string): Promise<{ ok: true; output: string } | { ok: false; reason: string; detail?: string }> { + const paused = await runDocker(["inspect", "--format", "{{.State.Paused}}", LOCAL_DOCKER_BOX_CONTAINER]); + if (paused.ok && paused.output.trim() === "true") { + const unpaused = await runDocker(["unpause", LOCAL_DOCKER_BOX_CONTAINER]); + if (!unpaused.ok) return { ok: false, reason: "container-paused", detail: unpaused.output }; + } + const result = await runDocker(["exec", LOCAL_DOCKER_BOX_CONTAINER, "sh", "-c", shellCommand]); + if (result.ok) return { ok: true, output: result.output }; + return classifyDockerFailure(result.output); +} + +/** + * `head -c cap+1` capped read. The trailing `; true` makes a missing file an empty + * success (an empty state, not an error); only container-level failures propagate. + * Output longer than cap after the runDocker trim means the file was bigger than cap. + */ +async function capRead(shellCommand: string): Promise { + const outcome = await execInBox(shellCommand); + if (!outcome.ok) return outcome; + const trimmed = outcome.output.trim(); + if (trimmed.length === 0) return { ok: true, content: null, truncated: false }; + const truncated = trimmed.length >= TEXT_READ_CAP_BYTES; + return { ok: true, content: truncated ? trimmed.slice(0, TEXT_READ_CAP_BYTES) : trimmed, truncated }; +} + +export async function readAgentDataOverview(rawAgentId: unknown): Promise> { + const agentId = normalizeAgentId(rawAgentId); + if (agentId == null) return { ok: false, reason: "invalid-agent-id" }; + const agentDir = `${AGENT_DATA_ROOT}/${agentId}`; + const [soul, user, months, audit, workflows] = await Promise.all([ + capRead(`head -c ${TEXT_READ_CAP_BYTES + 1} ${agentDir}/${PROFILE_FILE} 2>/dev/null; true`), + capRead(`head -c ${TEXT_READ_CAP_BYTES + 1} ${USER_MEMORY_ROOT}/${agentId}/${USER_PROFILE_FILE} 2>/dev/null; true`), + execInBox(`ls -1 ${agentDir}/${LOG_DIR} 2>/dev/null; true`), + execInBox(`tail -c ${AUDIT_TAIL_BYTES + 1} ${agentDir}/${AUDIT_FILE} 2>/dev/null; true`), + execInBox(`ls -1 ${WORKFLOW_ROOT} 2>/dev/null; true`), + ]); + if (!soul.ok) return soul; + if (!user.ok) return user; + if (!months.ok) return months; + if (!audit.ok) return audit; + if (!workflows.ok) return workflows; + const monthList = months.output.split("\n").map((name) => name.trim()).filter((name) => MEMORY_MONTH_PATTERN.test(name)).sort().reverse(); + return { + ok: true, + data: { + soul: soul.content, + soulTruncated: soul.truncated, + userProfile: user.content, + userProfileTruncated: user.truncated, + memoryLogMonths: monthList, + audit: parseAuditTail(audit.output, AUDIT_TAIL_BYTES), + workflows: workflows.output.split("\n").map((name) => name.trim()).filter((name) => WORKFLOW_SLUG_PATTERN.test(name)).sort(), + }, + }; +} + +export async function readAgentMemoryLog(rawAgentId: unknown, rawMonth: unknown): Promise> { + const agentId = normalizeAgentId(rawAgentId); + const month = normalizeMemoryMonth(rawMonth); + if (agentId == null) return { ok: false, reason: "invalid-agent-id" }; + if (month == null) return { ok: false, reason: "invalid-month" }; + const outcome = await capRead(`head -c ${TEXT_READ_CAP_BYTES + 1} ${AGENT_DATA_ROOT}/${agentId}/${LOG_DIR}/${month}.md 2>/dev/null; true`); + if (!outcome.ok) return outcome; + return { ok: true, data: { content: outcome.content, truncated: outcome.truncated } }; +} + +export async function readAgentWorkflowContent(rawSlug: unknown): Promise> { + const slug = normalizeWorkflowSlug(rawSlug); + if (slug == null) return { ok: false, reason: "invalid-slug" }; + const outcome = await capRead(`head -c ${TEXT_READ_CAP_BYTES + 1} ${WORKFLOW_ROOT}/${slug}/${SKILL_FILE} 2>/dev/null; true`); + if (!outcome.ok) return outcome; + return { ok: true, data: { content: outcome.content, truncated: outcome.truncated } }; +} diff --git a/source/electron-main/box/local-docker-host-connector.ts b/source/electron-main/box/local-docker-host-connector.ts index 066715db..c27a7e9d 100644 --- a/source/electron-main/box/local-docker-host-connector.ts +++ b/source/electron-main/box/local-docker-host-connector.ts @@ -119,7 +119,7 @@ async function verifyHostIdentity(hostBundle: LocalHostBundle): Promise { +export function runDocker(args: readonly string[]): Promise { return new Promise((resolve) => { const binary = resolveDockerBinary(); const installDir = dirname(binary); diff --git a/source/electron-main/coordinator/account-transition-cleanup.ts b/source/electron-main/coordinator/account-transition-cleanup.ts index f5734b41..8f0309e7 100644 --- a/source/electron-main/coordinator/account-transition-cleanup.ts +++ b/source/electron-main/coordinator/account-transition-cleanup.ts @@ -45,6 +45,7 @@ export function createProductionAccountTransitionCleanup( mcpCustomInstructions: {}, mcpCustomInstructionsByServerId: {}, mcpDisabledToolsByServerId: {}, + grokBotVaultContext: null, }); } catch (error) { deps.reportHostSettingsClearFailure(error); diff --git a/source/electron-main/coordinator/production-provider.ts b/source/electron-main/coordinator/production-provider.ts index ffa73855..19768a49 100644 --- a/source/electron-main/coordinator/production-provider.ts +++ b/source/electron-main/coordinator/production-provider.ts @@ -14,6 +14,7 @@ import { type WebAuthnPromptWindowOptions, } from "./coordinator-executors.js"; import { createCoordinatorHandoffTelemetry } from "./coordinator-handoff-telemetry.js"; +import { getLocal0721Backends } from "../local-backends-0721.js"; import type { CoordinatorChildProcess, CoordinatorMessageChannel, @@ -404,7 +405,9 @@ export function createProductionCoordinatorAdapter< void Promise.resolve(ports.telemetry.flushNow()).catch((error) => ports.reportFailure("coordinator", "connect-flush", error), ); - void resync.onTransportConnected(); + void resync.onTransportConnected() + .then(() => getLocal0721Backends(context).syncVaultContext()) + .catch(() => undefined); ports.resync.onHostSettingsTransportConnected(); context.hostSettingsFields.onTransportConnected(); }, diff --git a/source/electron-main/desktop-mount/index.ts b/source/electron-main/desktop-mount/index.ts index 1fd7681b..aebb2d64 100644 --- a/source/electron-main/desktop-mount/index.ts +++ b/source/electron-main/desktop-mount/index.ts @@ -35,6 +35,7 @@ interface Factories { createMount(options: { getMainWindow: DesktopMount0721Options["getMainWindow"]; focusMainWindow(): void; + readAccountSlot(): string | null; isGateOn(): boolean; attachments: Attachments & { stagePath(request: { filename: string; sourcePath: string }): Promise }; positionStore: { load(): { x: number; y: number } | null; save(position: { x: number; y: number }): void }; @@ -56,6 +57,7 @@ interface Factories { export interface DesktopMount0721Options { electron: Electron; getMainWindow(): import("electron").BrowserWindow | null; + readAccountSlot(): string | null; isEnabled(): boolean; exposeCaptureGate?: () => void; attachments: Attachments; @@ -135,6 +137,7 @@ export function createDesktopMount0721(options: DesktopMount0721Options) { }; const mount = upstream.createMount({ getMainWindow: options.getMainWindow, isGateOn: options.isEnabled, + readAccountSlot: options.readAccountSlot, focusMainWindow: () => options.getMainWindow()?.focus(), attachments: createDesktopMountStagingPort(options.attachments), positionStore: upstream.createPositionStore(), startCapture: runCapture, diff --git a/source/electron-main/desktop-runtime-0721.ts b/source/electron-main/desktop-runtime-0721.ts index 0bf704d0..a433dd60 100644 --- a/source/electron-main/desktop-runtime-0721.ts +++ b/source/electron-main/desktop-runtime-0721.ts @@ -162,6 +162,7 @@ export function prepareDesktop0721(electron: typeof import("electron") = require return window instanceof electron.BrowserWindow ? window : null; }, isEnabled: () => resolveLocal0721Feature("sand_desktop_mount") === true, + readAccountSlot: () => context.accountLifecycle.getAccountScope() ?? null, attachments, generatedPath: join(mainRoot, "desktop-mount/upstream-0721.cjs"), rendererRoot: join(dist, "renderer/upstream-0721"), diff --git a/source/electron-main/local-backend-handlers-0721.ts b/source/electron-main/local-backend-handlers-0721.ts index 7013b614..dc570988 100644 --- a/source/electron-main/local-backend-handlers-0721.ts +++ b/source/electron-main/local-backend-handlers-0721.ts @@ -3,26 +3,43 @@ import type { Local0721Backends } from "./local-backends-0721.js"; const text = z.string().max(16384); const id = z.string().max(512); -const address = z.object({ line1: text, line2: text, city: text, region: text, postalCode: text, country: text }).strict(); -const login = z.object({ title: text, username: text, password: text, notes: text, - sites: z.array(z.string().max(4096)).max(128) }).strict(); +const vaultId = z.string().min(1).max(256); +const vaultTitle = z.string().max(200); +const vaultUsername = z.string().max(512); +const vaultNotes = z.string().max(2048); +const vaultSite = z.string().max(2048); +const vaultPassword = z.string().refine((value) => new TextEncoder().encode(value).byteLength <= 4096, + "Vault password must be at most 4096 bytes"); +const vaultAddress = z.object({ line1: z.string().max(256), line2: z.string().max(256), + city: z.string().max(256), region: z.string().max(256), postalCode: z.string().max(256), + country: z.string().max(256) }).strict(); +const login = z.object({ title: vaultTitle, username: vaultUsername, password: vaultPassword, + notes: vaultNotes, sites: z.array(vaultSite).max(10) }).strict(); const team = z.object({ teamId: id.min(1) }).strict(); export function createLocalBackendHandlers0721(get: () => Local0721Backends) { const cardPhotoReads = new Map(); return { listGrokBotVaultCredentials: () => get().vault.listGrokBotVaultCredentials(), - putGrokBotVaultCredential: (raw: unknown) => get().vault.putGrokBotVaultCredential(login.extend({ id }).parse(raw)), + putGrokBotVaultCredential: (raw: unknown) => get().vault.putGrokBotVaultCredential(login.extend({ id: vaultId }).parse(raw)), createGrokBotVaultLogins: (raw: unknown) => get().vault.createGrokBotVaultLogins( - z.object({ logins: z.array(login).max(10000) }).strict().parse(raw)), - updateGrokBotVaultCard: (raw: unknown) => get().vault.updateGrokBotVaultCard( - z.object({ id, holderName: text, expiry: text, billingAddress: address, billingAddressId: id }).strict().parse(raw)), + z.object({ logins: z.array(login).max(1000) }).strict().parse(raw)), + updateGrokBotVaultCard: (raw: unknown) => { + const card = z.object({ id: vaultId, holderName: z.string().max(200), + nickname: z.string().max(200).optional(), expiry: z.string().max(64), + billingAddress: vaultAddress, billingAddressId: vaultId }).strict().parse(raw); + const { nickname, ...base } = card; + return get().vault.updateGrokBotVaultCard({ ...base, + ...(nickname === undefined ? {} : { nickname }) }); + }, putGrokBotVaultContact: (raw: unknown) => get().vault.putGrokBotVaultContact( - z.object({ id, title: text, contact: address.extend({ name: text, phone: text, email: text, defaultShipping: z.boolean() }) }).strict().parse(raw)), + z.object({ id: vaultId, title: vaultTitle, + contact: vaultAddress.extend({ name: z.string().max(200), phone: z.string().max(64), + email: z.string().max(320), defaultShipping: z.boolean() }) }).strict().parse(raw)), createGrokBotVaultCard: (raw: unknown) => get().vault.createGrokBotVaultCard( - z.object({ values: z.record(z.string(), text) }).strict().parse(raw)), + z.object({ values: z.record(z.string(), z.string().max(4096)) }).strict().parse(raw)), deleteGrokBotVaultCredential: async (raw: unknown) => { - await get().vault.deleteGrokBotVaultCredential(z.object({ id }).strict().parse(raw).id); + await get().vault.deleteGrokBotVaultCredential(z.object({ id: vaultId }).strict().parse(raw).id); return {}; }, readGrokBotCardPhoto: async (raw: unknown) => { diff --git a/source/electron-main/local-backends-0721.ts b/source/electron-main/local-backends-0721.ts index e1d5806f..cacf69d7 100644 --- a/source/electron-main/local-backends-0721.ts +++ b/source/electron-main/local-backends-0721.ts @@ -25,6 +25,29 @@ function createBackends(context: ProductionServiceContext) { const accountScope = createHash("sha256").update("grok-node-local-profile\0").update(profile).digest("hex"); const privateRoot = join(profile, "local-0721"); let vault: ReturnType | undefined; + const getVault = (): ReturnType => vault ??= createLocalVaultBackend({ + accountScope, storePath: join(privateRoot, "vault.enc"), codec: context.native.safeStorage, + loadCardPhotoNative, onChange: () => syncVaultContext().catch(() => undefined), + }); + const syncVaultContext = async (): Promise => { + try { + const snapshot = await getVault().sessionSnapshot(); + let lastError: unknown = null; + for (let attempt = 0; attempt < 3; attempt += 1) { + try { + const applied = await context.coordinatorResync.pushHostSettings({ grokBotVaultContext: snapshot }); + if (applied !== null) return; + lastError = new Error("Host rejected the Vault session context"); + } catch (error) { lastError = error; } + if (attempt < 2) await new Promise((resolve) => setTimeout(resolve, 250 * (attempt + 1))); + } + throw lastError ?? new Error("Host did not acknowledge the Vault session context"); + } catch (error) { + await context.coordinatorResync.pushHostSettings({ grokBotVaultContext: null }).catch(() => null); + context.reportFailure("vault", "session-context-sync", error); + throw error; + } + }; const tailnet = createLocalTailnet({ dataRoot: privateRoot, codec: context.native.safeStorage, async requireTeam(teamId, action) { const legs = context.coordinatorLegs.legs; @@ -36,10 +59,7 @@ function createBackends(context: ProductionServiceContext) { z.object({ authorized: z.literal(true) }).parse(result); }, }); - return { get vault() { - return vault ??= createLocalVaultBackend({ accountScope, - storePath: join(privateRoot, "vault.enc"), codec: context.native.safeStorage, loadCardPhotoNative }); - }, tailnet }; + return { syncVaultContext, get vault() { return getVault(); }, tailnet }; } export type Local0721Backends = ReturnType; diff --git a/source/electron-main/main-edge.ts b/source/electron-main/main-edge.ts index 3356a300..3bc5e872 100644 --- a/source/electron-main/main-edge.ts +++ b/source/electron-main/main-edge.ts @@ -15,6 +15,9 @@ import { OPENCODEX_CHANNEL_PROBE_TIMEOUT_MS, OPENCODEX_MAC_FORWARDER_PORT, effor import { mergeOpenRouterChannelStatus, normalizeOpenRouterChannelStatus } from "../shared/openrouter-channel-status.js"; import { decodeLibraryJson } from "../shared/library/json-bytes.js"; import { getLocalDockerStatus, probeLocalDockerRelay, startLocalDockerBox, stopLocalDockerBox } from "./box/local-docker-host-connector.js"; +import { readAgentDataOverview, readAgentMemoryLog, readAgentWorkflowContent } from "./box/agent-data-reader.js"; +import { buildImportMemoryPrompt, IMPORT_MEMORY_MAX_CHARS } from "../shared/node/agent-memory-import.js"; +import { GATEWAY_API_PREFIX, GATEWAY_AUTH_SCHEME } from "../shared/gateway-wire.js"; import { setApplicationMenuUnreadFilterChecked } from "./application-menu.js"; import { createComputerPreviewController } from "./computer-sleep.js"; import { createLocalBackendHandlers0721 } from "./local-backend-handlers-0721.js"; @@ -350,6 +353,46 @@ export function createMainEdgeHandlers(deps: MainEdgeDeps): HandlerMap { } return { agentId: id, effort: selected }; }, + getAgentDataOverview: async (raw) => { + const agentId = req(raw).agentId; + invariant(typeof agentId === "string" && agentId.trim().length > 0, "Choose a Bot."); + return await readAgentDataOverview(agentId); + }, + getAgentMemoryLog: async (raw) => { + const { agentId, month } = req(raw); + invariant(typeof agentId === "string" && agentId.trim().length > 0, "Choose a Bot."); + invariant(typeof month === "string" && month.trim().length > 0, "Choose a memory month."); + return await readAgentMemoryLog(agentId, month); + }, + getAgentWorkflowContent: async (raw) => { + const slug = req(raw).slug; + invariant(typeof slug === "string" && slug.trim().length > 0, "Choose a workflow."); + return await readAgentWorkflowContent(slug); + }, + importAgentMemory: async (raw) => { + const { agentId, text } = req(raw); + invariant(typeof agentId === "string" && agentId.trim().length > 0, "Choose a Bot."); + invariant(typeof text === "string" && text.trim().length > 0, "Paste the memory snapshot first."); + invariant(typeof text === "string" && text.length <= IMPORT_MEMORY_MAX_CHARS, "The memory snapshot is too large."); + const id = agentId.trim(); + const snapshot = text as string; + // Dialog distillation (v1): deliver the snapshot as an ordinary user turn whose + // prompt tells the bot to distill durable facts via its UpdateMemory tool. No host + // or protocol change — this is the same /api/sendPrompt the chat composer uses. + const prompt = buildImportMemoryPrompt(snapshot); + const connection = await startLocalDockerBox(String(Reflect.get(deps.settingsStore, "settingsPath"))); + const response = await fetch(`${connection.baseUrl}${GATEWAY_API_PREFIX}/sendPrompt`, { + method: "POST", + headers: { "content-type": "application/json", authorization: `${GATEWAY_AUTH_SCHEME} ${connection.token}` }, + body: JSON.stringify({ agentId: id, prompt, clientNonce: `memory-import-${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 10)}` }), + signal: AbortSignal.timeout(20_000), + }); + if (!response.ok) { + const detail = (await response.text().catch(() => response.statusText)).slice(0, 300); + return { ok: false, reason: `gateway ${response.status}: ${detail}` }; + } + return { ok: true }; + }, getOpenRouterBaseUrl: async () => { const persisted = persistedOpenRouterBaseUrl(deps.settingsStore); return { baseUrl: resolveOpenRouterBaseUrl(persisted), baseUrlOverride: persisted }; diff --git a/source/electron-main/update/github-update-feed.ts b/source/electron-main/update/github-update-feed.ts new file mode 100644 index 00000000..5ac20240 --- /dev/null +++ b/source/electron-main/update/github-update-feed.ts @@ -0,0 +1,202 @@ +import { SAND_PRODUCT_DISPLAY_NAME } from "../../shared/product-name.js"; +import { compareVersions, isNewerVersion, parseVersion } from "./update-version.js"; +import { UpdateHttpStatusError } from "./update-feed.js"; + +/** + * GitHub Releases update feed for reconstructed builds. + * + * Reconstructed packages must NOT consume the official Cursor update endpoint + * (`https://api2.cursor.sh/updates`). The default update source is this repo's + * GitHub Releases (`tyonger-stack/GrokNode`). + * + * Design notes (read before extending): + * - Track semantics are intentionally ignored on this feed: GitHub releases have + * no stable/nightly/dogfood channels, so every check scans recent releases and + * picks the newest version newer than the running build. Telemetry still + * records the effective track for continuity, but it does not filter offers. + * - Only `darwin-arm64` has a first-class asset today + * (`Grok-Node--mac-arm64.zip`). Other platforms return `null` from the + * mapper (== "no update"), which is an honest gap, not a silent failure: the + * asset naming convention only defines the mac-arm64 zip. + * - GitHub's releases API provides no sha256/signature sidecar, so `sha256` is + * absent from the mapped manifest and `downloadAndVerify` skips hash pinning on + * this path. Squirrel.Mac staging additionally requires a Developer ID + * signature to auto-install; reconstructed ad-hoc builds may stage but fail to + * apply. The Settings UI therefore always surfaces the Releases page link as + * the reliable fallback (prompt + manual download), even when download/staging + * succeeds. + * - Unauthenticated `api.github.com` calls are rate-limited (60/hr/IP). The + * hourly check cadence stays far below that; a 403/429 surfaces as a normal + * check error, never as a staged update. + */ + +export const GITHUB_UPDATE_OWNER = "tyonger-stack"; +export const GITHUB_UPDATE_REPO = "GrokNode"; +export const DEFAULT_GITHUB_RELEASES_API_BASE = "https://api.github.com/repos/tyonger-stack/GrokNode"; +export const GITHUB_RELEASES_HTML_URL = "https://github.com/tyonger-stack/GrokNode/releases"; +export const GITHUB_RELEASES_PER_PAGE = 20; + +/** First-class asset: `Grok-Node-0.75.3-reconstructed.6-mac-arm64.zip`. */ +export const GITHUB_MAC_ARM64_ASSET_PATTERN = /^Grok-Node-.*-mac-arm64\.zip$/; +/** Reserved for a future x64 asset; no such artifact is published today. */ +export const GITHUB_MAC_X64_ASSET_PATTERN = /^Grok-Node-.*-mac-(x64|intel)\.zip$/; +/** Reserved for future Windows artifacts; no such artifact is published today. */ +export const GITHUB_WINDOWS_ASSET_PATTERN = /^Grok-Node-.*-win-(x64|arm64)\.exe$/; + +export interface GitHubReleaseAsset { + readonly name: string; + readonly browser_download_url: string; +} + +export interface GitHubRelease { + readonly tag_name: string; + readonly html_url: string; + readonly published_at: string | null; + readonly draft: boolean; + readonly prerelease: boolean; + readonly assets: readonly GitHubReleaseAsset[]; +} + +export interface GitHubUpdateManifest { + /** Version without a leading `v` (e.g. `0.75.3-reconstructed.6`). */ + readonly version: string; + /** Direct asset download URL (== Squirrel `url`). */ + readonly url: string; + /** Display name (`Grok Bot `). */ + readonly name: string; + readonly htmlUrl: string; + readonly pubDate?: string; +} + +/** + * Strip a leading `v`/`V` from a release tag and validate the remainder with + * the shared reconstructed version parser (handles `0.75.3-reconstructed.N`). + */ +export function normalizeGitHubTagVersion(tag: string): string | null { + if (typeof tag !== "string" || tag.length === 0) return null; + const version = tag.startsWith("v") || tag.startsWith("V") ? tag.slice(1) : tag; + if (version.length === 0) return null; + return parseVersion(version) == null ? null : version; +} + +export function githubAssetPatternForPlatform(platform: string): RegExp | null { + if (platform === "darwin-arm64") return GITHUB_MAC_ARM64_ASSET_PATTERN; + if (platform === "darwin-x64") return GITHUB_MAC_X64_ASSET_PATTERN; + if (platform.startsWith("win32")) return GITHUB_WINDOWS_ASSET_PATTERN; + return null; +} + +export function findGitHubAssetForPlatform( + release: Pick, + platform: string, +): GitHubReleaseAsset | null { + const pattern = githubAssetPatternForPlatform(platform); + if (pattern == null) return null; + const assets = Array.isArray(release.assets) ? release.assets : []; + for (const asset of assets) { + if (asset != null && typeof asset.name === "string" && typeof asset.browser_download_url === "string" && pattern.test(asset.name)) { + try { + new URL(asset.browser_download_url); + } catch { + continue; + } + return asset; + } + } + return null; +} + +/** + * Map one GitHub release to the squirrel-shaped manifest the existing + * `parseUpdateResponse` path consumes (`{ url, name: version }`), enriched with + * display/HTML metadata for status + UI. Returns `null` when the release has no + * usable version or no asset for this platform. + */ +export function mapGitHubReleaseToUpdateManifest( + release: GitHubRelease, + platform: string, +): GitHubUpdateManifest | null { + if (release == null || typeof release !== "object" || release.draft === true) return null; + const version = normalizeGitHubTagVersion(release.tag_name); + if (version == null) return null; + const asset = findGitHubAssetForPlatform(release, platform); + if (asset == null) return null; + const htmlUrl = typeof release.html_url === "string" && release.html_url.length > 0 ? release.html_url : GITHUB_RELEASES_HTML_URL; + return { + version, + url: asset.browser_download_url, + name: `${SAND_PRODUCT_DISPLAY_NAME} ${version}`, + htmlUrl, + ...(release.published_at == null ? {} : { pubDate: release.published_at }), + }; +} + +/** + * Pick the newest release newer than `currentVersion` with a usable asset. + * Drafts are skipped; prereleases are considered because reconstructed tags + * (`-reconstructed.N`) parse as prereleases under semver rules. + */ +export function selectNewestGitHubUpdate( + releases: readonly GitHubRelease[], + currentVersion: string, + platform: string, +): GitHubUpdateManifest | null { + if (!Array.isArray(releases) || parseVersion(currentVersion) == null) return null; + const candidates: GitHubUpdateManifest[] = []; + for (const release of releases) { + if (release == null || typeof release !== "object") continue; + const manifest = mapGitHubReleaseToUpdateManifest(release, platform); + if (manifest == null) continue; + try { + if (isNewerVersion(manifest.version, currentVersion)) candidates.push(manifest); + } catch { + continue; + } + } + candidates.sort((a, b) => compareVersions(b.version, a.version)); + return candidates[0] ?? null; +} + +export function buildGitHubReleasesListUrl(baseUrl: string): string { + return `${baseUrl.replace(/\/+$/, "")}/releases?per_page=${GITHUB_RELEASES_PER_PAGE}&page=1`; +} + +export function resolveGitHubApiBase(feedBaseUrl?: string): string { + if (feedBaseUrl == null || feedBaseUrl.length === 0) return DEFAULT_GITHUB_RELEASES_API_BASE; + return feedBaseUrl.replace(/\/+$/, ""); +} + +/** True for `api.github.com/repos/...` bases (and empty/undefined, which default to GitHub). */ +export function isGitHubFeedBaseUrl(value: string | undefined): boolean { + if (value == null || value.length === 0) return true; + return value.includes("api.github.com/repos/"); +} + +/** True only when the configured base is an explicit non-GitHub (legacy Cursor) feed. */ +export function isLegacyCursorFeedBaseUrl(value: string | undefined): boolean { + return value != null && value.length > 0 && !isGitHubFeedBaseUrl(value); +} + +export async function fetchGitHubUpdateManifest(options: { + readonly baseUrl?: string; + readonly currentVersion: string; + readonly platform: string; + readonly fetchImpl?: typeof fetch; + readonly signal?: AbortSignal; +}): Promise { + const base = resolveGitHubApiBase(options.baseUrl); + const url = buildGitHubReleasesListUrl(base); + const response = await (options.fetchImpl ?? fetch)(url, { + redirect: "follow", + ...(options.signal === undefined ? {} : { signal: options.signal }), + headers: { + Accept: "application/vnd.github+json", + "User-Agent": "GrokNode-Reconstructed-Updater", + "cache-control": "no-cache", + }, + }); + if (!response.ok) throw new UpdateHttpStatusError(response.status, url); + const payload: unknown = await response.json(); + if (!Array.isArray(payload)) return null; + return selectNewestGitHubUpdate(payload as GitHubRelease[], options.currentVersion, options.platform); +} diff --git a/source/electron-main/update/sand-update-service.ts b/source/electron-main/update/sand-update-service.ts index 7faf203c..f6a4f09a 100644 --- a/source/electron-main/update/sand-update-service.ts +++ b/source/electron-main/update/sand-update-service.ts @@ -6,6 +6,7 @@ import { NIGHTLY_UPDATE_TRACK_DISABLED, availableUpdateTracks, resolveEffectiveT import { type UpdateApplyMarker, decideUpdateApplySettlement } from "./apply-marker.js"; import { downloadAndVerify } from "./update-download.js"; import { DEFAULT_UPDATE_BASE_URL, UpdateHttpStatusError, buildUpdateRequestUrl, parseUpdateResponse, resolveUpdatePlatform, updateResponseKind } from "./update-feed.js"; +import { GITHUB_RELEASES_HTML_URL, fetchGitHubUpdateManifest, isLegacyCursorFeedBaseUrl } from "./github-update-feed.js"; import { runPeriodicIdleApplyTick, tryApplyStagedWhenIdle } from "./idle-relaunch-apply.js"; import { SquirrelFeedServer } from "./squirrel-feed-server.js"; import { classifyUpdateCheckError, updateDisabledError, updateError } from "./update-telemetry.js"; @@ -37,6 +38,7 @@ export class SandUpdateService { readonly responseKind: "squirrel" | "iupdate"; private readonly clock: Clock; private readonly now: () => number; private readonly feedServer: SquirrelFeedServer; private checkAbort: AbortController | null = null; private attemptTrack: SandUpdateTrack | null = null; private notedEffectiveTrack: SandUpdateTrack | null = null; private stagedZipPath: string | null = null; private stagedVersion: string | null = null; private stagedAtMs: number | null = null; private checkSeq = 0; private stagedInstallerPath: string | null = null; private forceRunOnQuit = false; private initialArm: { dispose(): void } | null = null; private periodicArm: { dispose(): void } | null = null; private periodicTickInFlight = false; private stagingArm: { dispose(): void } | null = null; private isDisposed = false; private backendRequiresUpdate = false; private stagingDir: string | null = null; private installerLaunched = false; + private lastGitHubReleaseUrl: string | null = null; private lastGitHubDownloadUrl: string | null = null; private lastGitHubTargetVersion: string | null = null; constructor(private readonly options: SandUpdateServiceOptions) { this.clock = options.clock ?? realClock; this.now = options.now ?? Date.now; this.feedServer = options.feedServer ?? new SquirrelFeedServer(); @@ -51,7 +53,7 @@ export class SandUpdateService { private scheduleNextPeriodicCheck(): void { if (this.isDisposed || this.state.type === "disabled") return; this.clearPeriodicArm(); this.periodicArm = this.clock.schedule(this.nextPeriodicDelayMs(), () => { this.scheduleNextPeriodicCheck(); if (this.periodicTickInFlight) return; this.periodicTickInFlight = true; void runPeriodicIdleApplyTick({ isDisposed: () => this.isDisposed, refreshFeed: () => this.checkForUpdates({ trigger: "periodic" }).then(() => undefined), applyWhenIdle: () => tryApplyStagedWhenIdle({ updateReady: this.state.type === "ready", optInEnabled: this.options.getAutoUpdateWhenIdleOptIn?.() ?? false, gateEnabled: this.options.getAutoUpdateWhenIdleGateEnabled?.() ?? false, signals: this.options.idleRelaunchSignals, stillReady: () => this.state.type === "ready", quitAndInstall: () => this.quitAndInstall(), ...(this.options.log === undefined ? {} : { log: this.options.log }) }), cancelRearm: () => this.clearPeriodicArm(), ...(this.options.log === undefined ? {} : { log: this.options.log }) }).finally(() => { this.periodicTickInFlight = false; }); }); } nextPeriodicDelayMs(): number { const interval = this.options.checkIntervalMs ?? DEFAULT_CHECK_INTERVAL_MS; const ceiling = this.options.checkIntervalJitterMs ?? DEFAULT_CHECK_INTERVAL_JITTER_MS; return ceiling <= 0 ? interval : interval + Math.floor((this.options.random ?? Math.random)() * ceiling); } dispose(): void { this.isDisposed = true; this.initialArm?.dispose(); this.clearPeriodicArm(); this.clearStagingTimer(); this.checkAbort?.abort(); this.feedServer.stop(); if (this.stagingDir != null && !this.installerLaunched && this.stagedInstallerPath == null && this.stagedZipPath == null) void rm(this.stagingDir, { recursive: true, force: true }).catch((error) => this.failure("staging-cleanup", error)); } - getStatus(): any { const gate = this.releaseTrackGate(); const currentTrack = this.effectiveTrack(); return { state: this.state, currentVersion: this.options.currentVersion, currentTrack, trackOverride: this.options.getTrackOverride(), buildDefaultTrack: this.options.buildDefaultTrack, availableTracks: availableUpdateTracks({ unlockInternalTracks: gate.unlockInternalTracks, effectiveTrack: currentTrack }), isTrackManagedByPolicy: gate.managedTrack != null, isBelowMinimumVersion: this.isBelowMinimumVersion(), autoUpdateWhenIdleOptIn: this.options.getAutoUpdateWhenIdleOptIn?.() ?? false, autoUpdateWhenIdleGateEnabled: this.options.getAutoUpdateWhenIdleGateEnabled?.() ?? false }; } + getStatus(): any { const gate = this.releaseTrackGate(); const currentTrack = this.effectiveTrack(); return { state: this.state, currentVersion: this.options.currentVersion, currentTrack, trackOverride: this.options.getTrackOverride(), buildDefaultTrack: this.options.buildDefaultTrack, availableTracks: availableUpdateTracks({ unlockInternalTracks: gate.unlockInternalTracks, effectiveTrack: currentTrack }), isTrackManagedByPolicy: gate.managedTrack != null, isBelowMinimumVersion: this.isBelowMinimumVersion(), autoUpdateWhenIdleOptIn: this.options.getAutoUpdateWhenIdleOptIn?.() ?? false, autoUpdateWhenIdleGateEnabled: this.options.getAutoUpdateWhenIdleGateEnabled?.() ?? false, releasesUrl: GITHUB_RELEASES_HTML_URL, ...(this.lastGitHubTargetVersion == null ? {} : { githubRelease: { version: this.lastGitHubTargetVersion, releaseUrl: this.lastGitHubReleaseUrl ?? GITHUB_RELEASES_HTML_URL, downloadUrl: this.lastGitHubDownloadUrl ?? (this.lastGitHubReleaseUrl ?? GITHUB_RELEASES_HTML_URL) } }) }; } setAutoUpdateWhenIdleOptIn(enabled: boolean): any { this.options.persistAutoUpdateWhenIdleOptIn?.(enabled); const status = this.getStatus(); this.options.onStatusChange(status); return status; } isBelowMinimumVersion(): boolean { if (this.state.type === "disabled") return false; if (this.backendRequiresUpdate) return true; const minimum = this.options.getMinimumVersion?.(); return typeof minimum === "string" && minimum.length > 0 && parseVersion(minimum) != null && parseVersion(this.options.currentVersion) != null && compareVersions(this.options.currentVersion, minimum) < 0; } noteMinimumVersionMayHaveChanged(): void { if (this.isDisposed || this.state.type === "disabled") return; this.emitStatus(); if (this.isBelowMinimumVersion() && this.state.type === "idle") void this.checkForUpdates({ trigger: "min_version" }); } @@ -76,7 +78,32 @@ export class SandUpdateService { private releaseTrackGate() { return this.options.getReleaseTrackGate?.() ?? { managedTrack: undefined, unlockInternalTracks: false }; } private effectiveTrack(): SandUpdateTrack { const managedTrack = this.releaseTrackGate().managedTrack; const userOverride = this.options.getTrackOverride(); return resolveEffectiveTrack({ ...(managedTrack === undefined ? {} : { managedTrack }), ...(userOverride == null ? {} : { userOverride }), buildDefault: this.options.buildDefaultTrack }); } shouldApplyOffer(offerVersion: string): boolean { const baseline = this.stagedVersion ?? this.options.currentVersion; if (isNewerVersion(offerVersion, baseline)) return true; const offerTrack = parseVersion(offerVersion)?.prerelease[0]; const currentTrack = parseVersion(this.options.currentVersion)?.prerelease[0]; if (this.stagedVersion == null && offerVersion !== this.options.currentVersion && offerTrack != null && offerTrack !== currentTrack) return true; return NIGHTLY_UPDATE_TRACK_DISABLED && this.stagedVersion == null && isPrerelease(this.options.currentVersion) && !isPrerelease(offerVersion) && offerVersion !== this.options.currentVersion; } - private async fetchUpdate(track: SandUpdateTrack, signal: AbortSignal): Promise { const url = buildUpdateRequestUrl(this.options.feedBaseUrl ?? DEFAULT_UPDATE_BASE_URL, track, this.options.currentVersion, this.options.machineId, this.updatePlatform); const response = await (this.options.fetchImpl ?? fetch)(url, { redirect: "follow", signal, headers: { "cache-control": "no-cache" } }); if (response.status === 204) return null; if (!response.ok) throw new UpdateHttpStatusError(response.status, url); return parseUpdateResponse(await response.json(), this.responseKind); } + private async fetchUpdate(track: SandUpdateTrack, signal: AbortSignal): Promise { + // Default path: GitHub Releases. An explicit non-GitHub `feedBaseUrl` (legacy Cursor + // endpoint or test fixture) keeps the original request/response shape. + if (isLegacyCursorFeedBaseUrl(this.options.feedBaseUrl)) { + const url = buildUpdateRequestUrl(this.options.feedBaseUrl ?? DEFAULT_UPDATE_BASE_URL, track, this.options.currentVersion, this.options.machineId, this.updatePlatform); + const response = await (this.options.fetchImpl ?? fetch)(url, { redirect: "follow", signal, headers: { "cache-control": "no-cache" } }); + if (response.status === 204) return null; + if (!response.ok) throw new UpdateHttpStatusError(response.status, url); + return parseUpdateResponse(await response.json(), this.responseKind); + } + // GitHub Releases feed: track is recorded for telemetry but does not filter offers. + // No sha256 sidecar exists on this feed, so staging relies on HTTPS + Squirrel.Mac + // handling; ad-hoc (non-Developer-ID) signatures may stage yet fail to auto-apply, + // in which case the Settings UI falls back to the Releases page link (see status + // `releasesUrl`/`githubRelease`). + const manifest = await fetchGitHubUpdateManifest({ ...(this.options.feedBaseUrl === undefined ? {} : { baseUrl: this.options.feedBaseUrl }), currentVersion: this.options.currentVersion, platform: this.updatePlatform, ...(this.options.fetchImpl === undefined ? {} : { fetchImpl: this.options.fetchImpl }), signal }); + if (manifest == null) return null; + this.lastGitHubReleaseUrl = manifest.htmlUrl; + this.lastGitHubDownloadUrl = manifest.url; + this.lastGitHubTargetVersion = manifest.version; + // NB: squirrel (macOS) validates `{ url, name: version }`; iupdate (Windows) validates + // `{ url, version }`. Only darwin-arm64 ships an asset today, but keep both shapes + // correct so a future Windows asset does not fail validation here. + const payload = this.responseKind === "iupdate" ? { url: manifest.url, version: manifest.version } : { url: manifest.url, name: manifest.version }; + return { ...parseUpdateResponse(payload, this.responseKind), ...(manifest.pubDate === undefined ? {} : { pubDate: manifest.pubDate }) }; + } private async ensureStagingDir(): Promise { this.stagingDir ??= await mkdtemp(join(this.options.tempDir, "sand-update-")); return this.stagingDir; } private async downloadAndStage(manifest: any, track: SandUpdateTrack, signal: AbortSignal): Promise { const path = join(await this.ensureStagingDir(), `sand-update-${manifest.version}.${this.responseKind === "iupdate" ? "exe" : "zip"}`); let last = -1; this.setState({ type: "downloading", version: manifest.version, progress: null }); await downloadAndVerify({ url: manifest.url, ...(manifest.sha256 === undefined ? {} : { sha256: manifest.sha256 }), destinationPath: path, ...(this.options.fetchImpl === undefined ? {} : { fetchImpl: this.options.fetchImpl }), signal, onProgress: ({ receivedBytes, totalBytes }) => { if (totalBytes == null || signal.aborted) return; const progress = Math.min(receivedBytes / totalBytes, 1); if (progress - last >= PROGRESS_EMIT_STEP) { last = progress; this.setState({ type: "downloading", version: manifest.version, progress }); } }, reportCleanupFailure: (error) => this.failure("download-cleanup", error) }); if (signal.aborted || this.effectiveTrack() !== track) { await this.removeFile(path, "download-cleanup"); if (!signal.aborted) this.setState(this.parkedState()); return; } if (this.responseKind === "iupdate") return await this.stageWindowsInstaller(manifest.version, path, signal, track); if (this.options.squirrel == null) { await this.removeFile(path, "download-cleanup"); throw new SandUpdateApplyError("Update downloaded and verified, but applying updates requires Squirrel.Mac (macOS only)."); } this.setState({ type: "staging", version: manifest.version }); this.stagedZipPath = path; const feedUrl = await this.feedServer.start({ version: manifest.version, zipPath: path, ...(manifest.name === undefined ? {} : { releaseName: manifest.name }), ...(manifest.pubDate === undefined ? {} : { pubDate: manifest.pubDate }) }); this.options.squirrel.setFeedURL({ url: feedUrl }); this.stagedVersion = null; this.stagedAtMs = null; this.invalidatePendingApply(manifest.version); this.options.squirrel.checkForUpdates(); this.startStagingTimeout(manifest.version); } private async stageWindowsInstaller(version: string, path: string, signal: AbortSignal, track: SandUpdateTrack): Promise { const windows = this.options.windows; if (windows == null) { await this.removeFile(path, "installer-cleanup"); throw new SandUpdateApplyError("Update downloaded, but no installer backend is available to apply it on this platform."); } this.setState({ type: "staging", version }); try { await windows.verifySignature(path); } catch (error) { await this.removeFile(path, "installer-cleanup"); throw new SandUpdateApplyError(`Installer signature verification failed: ${message(error)}`); } if (signal.aborted || this.effectiveTrack() !== track) { await this.removeFile(path, "installer-cleanup"); if (!signal.aborted) this.setState(this.parkedState()); return; } if (this.stagedInstallerPath != null && this.stagedInstallerPath !== path) void this.removeFile(this.stagedInstallerPath, "staged-cleanup"); this.invalidatePendingApply(version); this.stagedInstallerPath = path; this.stagedVersion = version; this.stagedAtMs = this.now(); this.recordApplyStaged(version); this.emitOutcome("staged"); this.setState({ type: "ready", version }); } diff --git a/source/electron-main/update/update-feed.ts b/source/electron-main/update/update-feed.ts index 89093a22..b49214d5 100644 --- a/source/electron-main/update/update-feed.ts +++ b/source/electron-main/update/update-feed.ts @@ -5,7 +5,11 @@ export const SAND_UPDATE_PLATFORM = "darwin-arm64"; export const SAND_UPDATE_PLATFORM_DARWIN_X64 = "darwin-x64"; export const SAND_UPDATE_PLATFORM_WIN32 = "win32-x64-user"; export const SAND_UPDATE_PLATFORM_WIN32_ARM64 = "win32-arm64-user"; -export const DEFAULT_UPDATE_BASE_URL = "https://api2.cursor.sh/updates"; +// Legacy Cursor update endpoint. Reconstructed builds no longer use this as the +// default feed (see `./github-update-feed.ts`); it remains only for explicit +// `SAND_UPDATE_FEED_BASE_URL` overrides and offline fixtures. +export const LEGACY_CURSOR_UPDATE_BASE_URL = "https://api2.cursor.sh/updates"; +export const DEFAULT_UPDATE_BASE_URL = LEGACY_CURSOR_UPDATE_BASE_URL; export type UpdateTrack = "stable" | "nightly" | "dogfood"; export function resolveUpdatePlatform(platform: NodeJS.Platform, arch: string): string { if (platform === "win32") return arch === "arm64" ? SAND_UPDATE_PLATFORM_WIN32_ARM64 : SAND_UPDATE_PLATFORM_WIN32; if (platform === "darwin" && arch === "x64") return SAND_UPDATE_PLATFORM_DARWIN_X64; return SAND_UPDATE_PLATFORM; } diff --git a/source/electron-main/update/update-wiring.ts b/source/electron-main/update/update-wiring.ts index 5a644b1e..724d04d7 100644 --- a/source/electron-main/update/update-wiring.ts +++ b/source/electron-main/update/update-wiring.ts @@ -16,7 +16,8 @@ export function createUpdateServiceWiring(deps: { const feedBaseUrl = (deps.env ?? process.env).SAND_UPDATE_FEED_BASE_URL; const options: SandUpdateServiceOptions = { currentVersion: deps.currentVersion, buildDefaultTrack: deps.buildDefaultTrack, ...(deps.disabledReason === undefined ? {} : { disabledReason: deps.disabledReason }), squirrel: platform === "darwin" ? deps.electron.autoUpdater : null, tempDir: deps.electron.app.getPath("temp"), machineId: deps.machineId, ...(feedBaseUrl === undefined ? {} : { feedBaseUrl }), - getTrackOverride: () => deps.settingsStore.getUpdateTrackOverride(), persistTrackOverride: (track) => deps.settingsStore.setUpdateTrackOverride(track), getAutoUpdateWhenIdleOptIn: () => deps.settingsStore.getAutoUpdateWhenIdleOptIn(), persistAutoUpdateWhenIdleOptIn: (enabled) => deps.settingsStore.setAutoUpdateWhenIdleOptIn(enabled), getAutoUpdateWhenIdleGateEnabled: () => deps.getExperimentService()?.checkFeatureGate("sand_auto_update_when_idle") ?? false, + getTrackOverride: () => deps.settingsStore.getUpdateTrackOverride(), persistTrackOverride: (track) => deps.settingsStore.setUpdateTrackOverride(track), getAutoUpdateWhenIdleOptIn: () => deps.settingsStore.getAutoUpdateWhenIdleOptIn(), persistAutoUpdateWhenIdleOptIn: (enabled) => deps.settingsStore.setAutoUpdateWhenIdleOptIn(enabled), + getAutoUpdateWhenIdleGateEnabled: () => true, idleRelaunchSignals: createIdleRelaunchSignals({ powerMonitor: deps.electron.powerMonitor, probeHostIdle: () => deps.getHostStatus().then((status) => status.isBusy ? { kind: "busy" } : { kind: "confirmed-idle" }, () => ({ kind: "unavailable" })) }), getMinimumVersion: () => deps.getExperimentService()?.getDynamicConfig("sand_min_client_version").min_version ?? null, getReleaseTrackGate: () => resolveReleaseTrackGate(deps.getExperimentService()?.getDynamicConfig("sand_internal_release_track_override") ?? {}), hasLiveExperimentBootstrap: () => deps.getExperimentService()?.hasLiveStatsigBootstrap() === true, getFlagsAgeMs: () => deps.getExperimentService()?.getFlagsAgeMs(), onStatusChange: deps.emitStatus, log, applyMarker: createUpdateApplyMarkerStore(join(deps.electron.app.getPath("userData"), "sand-update-apply-marker.json")), ...(deps.reportOutcome === undefined ? {} : { reportOutcome: deps.reportOutcome }), ...(deps.reportCheck === undefined ? {} : { reportCheck: deps.reportCheck }), ...(deps.reportApply === undefined ? {} : { reportApply: deps.reportApply }), diff --git a/source/electron-main/vault/local-vault-backend.ts b/source/electron-main/vault/local-vault-backend.ts index 65f21760..79687463 100644 --- a/source/electron-main/vault/local-vault-backend.ts +++ b/source/electron-main/vault/local-vault-backend.ts @@ -15,6 +15,7 @@ import type { VaultCredentialReference, VaultLoginInput, VaultLoginValues, + VaultSessionSnapshot, VaultTrustedCredential, } from "../../shared/vault.js"; import { @@ -92,6 +93,7 @@ interface StoredCardRecord extends StoredVaultRecordBase { readonly expMonth: number; readonly expYear: number; readonly holderName: string; + readonly nickname: string; readonly billingAddressId: string; readonly billingAddress: VaultAddress; readonly secretCiphertextBase64: string; @@ -126,6 +128,7 @@ export interface LocalVaultBackendOptions { readonly cardsEnabled?: boolean; readonly now?: () => number; readonly loadCardPhotoNative?: () => CardTextRecognitionNative | undefined; + readonly onChange?: () => Promise | void; } const mutationTails = new Map>(); @@ -210,6 +213,7 @@ function parseStoredRecord(value: unknown): StoredVaultRecord { expMonth, expYear, holderName: stringProperty(value, "holderName", 200), + nickname: typeof value.nickname === "string" && value.nickname.length <= 200 ? value.nickname : "", billingAddressId: stringProperty(value, "billingAddressId", 256), billingAddress: parseStoredAddress(value.billingAddress), secretCiphertextBase64: stringProperty(value, "secretCiphertextBase64", 262144), @@ -277,6 +281,7 @@ function credentialOf(record: StoredVaultRecord): VaultCredential { expMonth: record.expMonth, expYear: record.expYear, holderName: record.holderName, + nickname: record.nickname, billingAddressId: record.billingAddressId, billingAddress: record.billingAddress, } }; @@ -392,6 +397,28 @@ export class LocalVaultBackend { return this.withAccount(async (account) => [...account.values()].map(credentialOf)); } + async sessionSnapshot(): Promise { + const account = await this.loadAccount(); + const nowMs = this.nowMs(); + const records = [...account.values()].sort((left, right) => left.updatedAtMs - right.updatedAtMs); + const logins: VaultSessionSnapshot["logins"][number][] = []; + const contacts: VaultSessionSnapshot["contacts"][number][] = []; + for (const record of records) { + if (record.kind === "login") { + const secret = decryptedSecret(this.options.codec, record.secretCiphertextBase64); + if (secret.password === undefined) throw new VaultStorageCorruptedError("Vault login secret is malformed"); + logins.push({ id: record.id, title: record.title, username: record.username, notes: record.notes, + sites: [...record.sites], password: secret.password, updatedAtMs: record.updatedAtMs }); + } else if (record.kind === "contact") { + contacts.push({ id: record.id, title: record.title, name: record.name, line1: record.line1, + line2: record.line2, city: record.city, region: record.region, postalCode: record.postalCode, + country: record.country, phone: record.phone, email: record.email, + defaultShipping: record.defaultShipping, updatedAtMs: record.updatedAtMs }); + } + } + return { version: 1, updatedAtMs: nowMs, logins, contacts }; + } + async put(input: VaultLoginInput): Promise { return this.withAccount(async (account, nowMs) => { const id = this.validId(input.id); @@ -456,7 +483,7 @@ export class LocalVaultBackend { this.validateHolderName(input.holderName); const expiry = expiryOf(input.expiry, "expiry"); this.assertNotExpired(expiry, nowMs); - const updated: StoredCardRecord = { ...record, holderName: input.holderName, expMonth: expiry.month, expYear: expiry.year, + const updated: StoredCardRecord = { ...record, holderName: input.holderName, nickname: input.nickname ?? record.nickname, expMonth: expiry.month, expYear: expiry.year, billingAddress: this.validAddress(input.billingAddress), billingAddressId: this.validText(input.billingAddressId, 256), updatedAtMs: nowMs }; account.set(id, updated); @@ -522,6 +549,7 @@ export class LocalVaultBackend { expMonth: expiry.month, expYear: expiry.year, holderName, + nickname: "", billingAddressId: values.billingAddressId ?? "", billingAddress: addressFromCardValues(values), secretCiphertextBase64: encryptedSecret(this.options.codec, secret), @@ -798,19 +826,26 @@ export function createLocalVaultBackend(options: LocalVaultBackendOptions): { readonly readGrokBotCardPhoto: (request: VaultCardPhotoRequest, signal?: AbortSignal) => Promise; readonly credentialReferenceFor: (id: string) => VaultCredentialReference; readonly readTrustedCredential: (reference: VaultCredentialReference) => Promise; + readonly sessionSnapshot: () => Promise; } { const backend = new LocalVaultBackend(options); + const changed = async (operation: Promise): Promise => { + const result = await operation; + try { void Promise.resolve(options.onChange?.()).catch(() => undefined); } catch {} + return result; + }; return { listGrokBotVaultCredentials: () => backend.list(), - putGrokBotVaultCredential: (input) => backend.put(input), - createGrokBotVaultLogins: (input) => backend.createLogins(input), - updateGrokBotVaultCard: (input) => backend.updateCard(input), - putGrokBotVaultContact: (input) => backend.putContact(input), - createGrokBotVaultCard: (input) => backend.createCard(input), - deleteGrokBotVaultCredential: (id) => backend.remove(id), + putGrokBotVaultCredential: (input) => changed(backend.put(input)), + createGrokBotVaultLogins: (input) => changed(backend.createLogins(input)), + updateGrokBotVaultCard: (input) => changed(backend.updateCard(input)), + putGrokBotVaultContact: (input) => changed(backend.putContact(input)), + createGrokBotVaultCard: (input) => changed(backend.createCard(input)), + deleteGrokBotVaultCredential: (id) => changed(backend.remove(id)), readCardPhoto: (request, signal) => backend.readCardPhoto(request, signal), readGrokBotCardPhoto: (request, signal) => backend.readCardPhoto(request, signal), credentialReferenceFor: (id) => backend.credentialReferenceFor(id), readTrustedCredential: (reference) => backend.readTrustedCredential(reference), + sessionSnapshot: () => backend.sessionSnapshot(), }; } diff --git a/source/electron-main/vault/upstream-vault-parsers.generated.mjs b/source/electron-main/vault/upstream-vault-parsers.generated.mjs index f3ed48fd..d8e36896 100644 --- a/source/electron-main/vault/upstream-vault-parsers.generated.mjs +++ b/source/electron-main/vault/upstream-vault-parsers.generated.mjs @@ -1,9 +1,9 @@ -// Generated by scripts/lib/vault-0721.mjs from the pinned Grok Bot 0.72.1 ASAR. Do not edit.// provenance={"upstreamIdentity":{"version":"0.72.1","asarSha256":"b272ee13db0fb9106f9276a46a8e47baf688c8d5ac1b1dc400df6fcba9e76996"},"sources":{"dist/renderer/assets/chunk-view-Cwu5IFAB.js":[{"kind":"ImportSpecifier","bindings":["V"],"start":982,"end":988,"sha256":"abb88dcd16b7b1503166c9b9482dd044c90f60a08824858dfe5bc165f035aa4f","statementStart":954,"statementEnd":1068,"statementSha256":"e99bd49463d8b0728be7d77b216bf4d3e883322848aecbe706049d18acbe00cd"},{"kind":"ImportSpecifier","bindings":["J"],"start":1250,"end":1256,"sha256":"d5de01ed96406d57db70573aa7dedcfd0bc3fb7f7dc3a5bcd9e4c9f7bd15447b","statementStart":1243,"statementEnd":1293,"statementSha256":"a9cf75c9b19f30c7cf9ca2cb680145e9ed011a3755005b7d88b50d1072d4115e"},{"kind":"VariableDeclarator","bindings":["ie"],"start":1314,"end":1320,"sha256":"10073d9d0b4500c4bd80ee3a482abca8c9626c2cce2854eceded4b88e7d17f09","statementStart":1293,"statementEnd":1399,"statementSha256":"a6662ec6570c5bc7e1b32ee507ba4e4a407b4f8aa000218655433298d2d01315"},{"kind":"VariableDeclarator","bindings":["Z"],"start":1321,"end":1326,"sha256":"5658fd70d877d29eaf185ed3d8a9cbd253f9a0d2b4b6c9d71fe85e984fb9a566","statementStart":1293,"statementEnd":1399,"statementSha256":"a6662ec6570c5bc7e1b32ee507ba4e4a407b4f8aa000218655433298d2d01315"},{"kind":"VariableDeclarator","bindings":["ae"],"start":1327,"end":1333,"sha256":"131294d487bb945c003d7cb98c41ab40e90045a4a7d16e8652261dc4f02e8f28","statementStart":1293,"statementEnd":1399,"statementSha256":"a6662ec6570c5bc7e1b32ee507ba4e4a407b4f8aa000218655433298d2d01315"},{"kind":"VariableDeclarator","bindings":["oe"],"start":1334,"end":1339,"sha256":"5d6dffa85b05e7d700a59a0738f29305966d148c6a9044acefc1b60a90b4bbaa","statementStart":1293,"statementEnd":1399,"statementSha256":"a6662ec6570c5bc7e1b32ee507ba4e4a407b4f8aa000218655433298d2d01315"},{"kind":"VariableDeclarator","bindings":["se"],"start":1340,"end":1347,"sha256":"69e62f6eb16d3639eabe4dc92fa4c9540fa3b7ea5134a0940b6e890c902dc817","statementStart":1293,"statementEnd":1399,"statementSha256":"a6662ec6570c5bc7e1b32ee507ba4e4a407b4f8aa000218655433298d2d01315"},{"kind":"VariableDeclarator","bindings":["ce"],"start":1348,"end":1355,"sha256":"0c6a60d83247338a4c9ce59ac0f468b973d9f76df3a2e5a3593e7e1af02c5d8b","statementStart":1293,"statementEnd":1399,"statementSha256":"a6662ec6570c5bc7e1b32ee507ba4e4a407b4f8aa000218655433298d2d01315"},{"kind":"VariableDeclarator","bindings":["le"],"start":1356,"end":1370,"sha256":"4a6dd0c11e8ce1691794b72f83325e1a0310fb88d9fdcf5830b74222bb3db44c","statementStart":1293,"statementEnd":1399,"statementSha256":"a6662ec6570c5bc7e1b32ee507ba4e4a407b4f8aa000218655433298d2d01315"},{"kind":"VariableDeclarator","bindings":["ue"],"start":1371,"end":1398,"sha256":"f01ca341152f22a3fde4cffecaefc612a45d308e7d7f5af22b163eb4256d2f2d","statementStart":1293,"statementEnd":1399,"statementSha256":"a6662ec6570c5bc7e1b32ee507ba4e4a407b4f8aa000218655433298d2d01315"},{"kind":"FunctionDeclaration","bindings":["de"],"start":1399,"end":1626,"sha256":"9f699aac22ffbb7f500c6d6c943d70ff93fd0ac845dc2394a587a891016471a2","statementStart":1399,"statementEnd":1626,"statementSha256":"9f699aac22ffbb7f500c6d6c943d70ff93fd0ac845dc2394a587a891016471a2"},{"kind":"FunctionDeclaration","bindings":["fe"],"start":1626,"end":2151,"sha256":"ad7cb164e0b1228ff0d04a90ccebe0bb441cf7a6b8c1d282cdc513ad4e6a13ba","statementStart":1626,"statementEnd":2151,"statementSha256":"ad7cb164e0b1228ff0d04a90ccebe0bb441cf7a6b8c1d282cdc513ad4e6a13ba"},{"kind":"FunctionDeclaration","bindings":["pe"],"start":2151,"end":2231,"sha256":"1be520cb1e143c28bb4f0c60a63484c3ce2dd52986a715997fab8bf3816644f2","statementStart":2151,"statementEnd":2231,"statementSha256":"1be520cb1e143c28bb4f0c60a63484c3ce2dd52986a715997fab8bf3816644f2"},{"kind":"FunctionDeclaration","bindings":["me"],"start":2231,"end":2481,"sha256":"03a513e064295ca78f1b248758bda30d20c3a4f698bd235f422d9a56318155fd","statementStart":2231,"statementEnd":2481,"statementSha256":"03a513e064295ca78f1b248758bda30d20c3a4f698bd235f422d9a56318155fd"},{"kind":"FunctionDeclaration","bindings":["he"],"start":2481,"end":2971,"sha256":"252b81e2bcf7032b9ea8e1fa5d782b3cedaada7b50cfee20fb53d400d3fe0776","statementStart":2481,"statementEnd":2971,"statementSha256":"252b81e2bcf7032b9ea8e1fa5d782b3cedaada7b50cfee20fb53d400d3fe0776"},{"kind":"FunctionDeclaration","bindings":["ge"],"start":2971,"end":3858,"sha256":"f310dfa912ca16c072b19436fbf73359e4d6ba0fed3e20d021071c4fc15fe469","statementStart":2971,"statementEnd":3858,"statementSha256":"f310dfa912ca16c072b19436fbf73359e4d6ba0fed3e20d021071c4fc15fe469"},{"kind":"FunctionDeclaration","bindings":["_e"],"start":3858,"end":4118,"sha256":"9145d88d86780cd5e9d72a453bc4178fe4b2a835ad3d1bab8b324d2919d8a28c","statementStart":3858,"statementEnd":4118,"statementSha256":"9145d88d86780cd5e9d72a453bc4178fe4b2a835ad3d1bab8b324d2919d8a28c"},{"kind":"FunctionDeclaration","bindings":["ve"],"start":4118,"end":4177,"sha256":"cf440f5fddd282120c7a1f0539fb2d5d568898e2e7f8dcbc60db92521e30a558","statementStart":4118,"statementEnd":4177,"statementSha256":"cf440f5fddd282120c7a1f0539fb2d5d568898e2e7f8dcbc60db92521e30a558"},{"kind":"FunctionDeclaration","bindings":["ye"],"start":4177,"end":4297,"sha256":"d61667290c76f73ce1cebf8cd968697bbb5a488657455a7e2ee46bc464768cf9","statementStart":4177,"statementEnd":4297,"statementSha256":"d61667290c76f73ce1cebf8cd968697bbb5a488657455a7e2ee46bc464768cf9"},{"kind":"FunctionDeclaration","bindings":["be"],"start":4297,"end":4370,"sha256":"a8662c76fe55ae2ffd0436afc3132f05d366a10e9339ed6357f17ea63b5bc644","statementStart":4297,"statementEnd":4370,"statementSha256":"a8662c76fe55ae2ffd0436afc3132f05d366a10e9339ed6357f17ea63b5bc644"},{"kind":"FunctionDeclaration","bindings":["xe"],"start":4370,"end":4433,"sha256":"c514cc271cf0a0c1001f27e48f34ead59b798e72877d565d5e173c921ea6b6ef","statementStart":4370,"statementEnd":4433,"statementSha256":"c514cc271cf0a0c1001f27e48f34ead59b798e72877d565d5e173c921ea6b6ef"},{"kind":"FunctionDeclaration","bindings":["Se"],"start":4433,"end":4536,"sha256":"9cce9aa59564e6a5cf0b921907c1972bae4d46a548df3ea8ac88c31a825745f0","statementStart":4433,"statementEnd":4536,"statementSha256":"9cce9aa59564e6a5cf0b921907c1972bae4d46a548df3ea8ac88c31a825745f0"},{"kind":"VariableDeclarator","bindings":["Ce"],"start":4540,"end":4654,"sha256":"ebb32bea6d006701f235ce67a2eb4016825d3aef1f16b0fbf70df3545211424c","statementStart":4536,"statementEnd":4655,"statementSha256":"ad09e2b5386e575086f57e08da25fa9e71f660e47b4a934723fa047fd2d403d3"},{"kind":"FunctionDeclaration","bindings":["we"],"start":4655,"end":4853,"sha256":"1085e4ae5e3f9203a1622f4c5b88545d9d658db02b958adb4c6888b674618bb3","statementStart":4655,"statementEnd":4853,"statementSha256":"1085e4ae5e3f9203a1622f4c5b88545d9d658db02b958adb4c6888b674618bb3"},{"kind":"FunctionDeclaration","bindings":["Te"],"start":4853,"end":4954,"sha256":"68e7e9d3a48e6b5c02d3b5b8de9e99887a139ecf7249401da519591cc425220e","statementStart":4853,"statementEnd":4954,"statementSha256":"68e7e9d3a48e6b5c02d3b5b8de9e99887a139ecf7249401da519591cc425220e"},{"kind":"FunctionDeclaration","bindings":["Ee"],"start":4954,"end":5175,"sha256":"8ac68314e207221332a51e60bec3f3b1d6db96c2175fb28123b8cdb27e26fd32","statementStart":4954,"statementEnd":5175,"statementSha256":"8ac68314e207221332a51e60bec3f3b1d6db96c2175fb28123b8cdb27e26fd32"},{"kind":"FunctionDeclaration","bindings":["De"],"start":5175,"end":5271,"sha256":"cd6f26ac5da0fef0b301ba38e40f4967e7d89801b58ef7091120f893903a07b3","statementStart":5175,"statementEnd":5271,"statementSha256":"cd6f26ac5da0fef0b301ba38e40f4967e7d89801b58ef7091120f893903a07b3"},{"kind":"FunctionDeclaration","bindings":["Oe"],"start":5271,"end":5432,"sha256":"3f20b99ba76596d1e822d25873859c4179b2593c2044063495bb2088dc59b9de","statementStart":5271,"statementEnd":5432,"statementSha256":"3f20b99ba76596d1e822d25873859c4179b2593c2044063495bb2088dc59b9de"},{"kind":"FunctionDeclaration","bindings":["ke"],"start":5432,"end":6389,"sha256":"1c1a5411d91a0389989e009063a7f2249d83a2d3611bffff9c97a6e44e4fa3e3","statementStart":5432,"statementEnd":6389,"statementSha256":"1c1a5411d91a0389989e009063a7f2249d83a2d3611bffff9c97a6e44e4fa3e3"},{"kind":"FunctionDeclaration","bindings":["Ae"],"start":6389,"end":7416,"sha256":"283dc2e62260466d32bad6683a0bdb42c11ef77592ddc57708cef90ca0e764f7","statementStart":6389,"statementEnd":7416,"statementSha256":"283dc2e62260466d32bad6683a0bdb42c11ef77592ddc57708cef90ca0e764f7"},{"kind":"FunctionDeclaration","bindings":["je"],"start":7416,"end":7705,"sha256":"ecabc06f3a1fb4eaf8e91dcba8d0d4bc39bebf1b091c5d435c116572b6898784","statementStart":7416,"statementEnd":7705,"statementSha256":"ecabc06f3a1fb4eaf8e91dcba8d0d4bc39bebf1b091c5d435c116572b6898784"},{"kind":"FunctionDeclaration","bindings":["Me"],"start":7705,"end":8336,"sha256":"ce98e6efbc8155a0f2cb28c4506ca3c764a4295c0f9fa011e868a3647fbc0d05","statementStart":7705,"statementEnd":8336,"statementSha256":"ce98e6efbc8155a0f2cb28c4506ca3c764a4295c0f9fa011e868a3647fbc0d05"}],"dist/renderer/assets/chunk-vault-card-fields-BBZgWwVF.js":[{"kind":"VariableDeclarator","bindings":["te"],"start":3910,"end":3921,"sha256":"3a6240ff57776702f6f0c67a004921ee60c5e93a300957a82397de18282c6e62","statementStart":3895,"statementEnd":3939,"statementSha256":"e795db4e84bd09a36539562a0415f5a771ff079430d6f570d168e63a8877c738"},{"kind":"VariableDeclarator","bindings":["ne"],"start":3922,"end":3938,"sha256":"fcdced09de65c118765a156a381c8bf719cc095904484b36e11f4852531b4fb3","statementStart":3895,"statementEnd":3939,"statementSha256":"e795db4e84bd09a36539562a0415f5a771ff079430d6f570d168e63a8877c738"},{"kind":"FunctionDeclaration","bindings":["re"],"start":3939,"end":4120,"sha256":"8fd0d3a8987b0a17153a7d480565f630cbb8e98cf4e105fe7cfbf0ee9afd11ec","statementStart":3939,"statementEnd":4120,"statementSha256":"8fd0d3a8987b0a17153a7d480565f630cbb8e98cf4e105fe7cfbf0ee9afd11ec"},{"kind":"VariableDeclarator","bindings":["oe"],"start":5718,"end":5724,"sha256":"a76db88aa2207dfc6b63ff207d88ac8027c21a0d3ad030170e8c1b952363358b","statementStart":5670,"statementEnd":5725,"statementSha256":"7a673771576f40a2eab7113fe02b9304289592c042e041a95b0b697c6239f307"},{"kind":"FunctionDeclaration","bindings":["se"],"start":5725,"end":5777,"sha256":"25a10e61c4e44158c9dad426b01d2100d1cfe00635cd717c2578d89255c11611","statementStart":5725,"statementEnd":5777,"statementSha256":"25a10e61c4e44158c9dad426b01d2100d1cfe00635cd717c2578d89255c11611"},{"kind":"FunctionDeclaration","bindings":["ce"],"start":5777,"end":6336,"sha256":"a888e4dba8e2bbccf1b3b49d148a0ba93477cc731346a73b076ec5c04e2f3272","statementStart":5777,"statementEnd":6336,"statementSha256":"a888e4dba8e2bbccf1b3b49d148a0ba93477cc731346a73b076ec5c04e2f3272"}],"dist/electron-main/main-app.cjs":[{"kind":"VariableDeclarator","bindings":["dMn"],"start":2564642,"end":2565154,"sha256":"c9648bfc5acc394e64a4f82d263acface3d4fd93d2c99eca2e5413ca7a151d86","statementStart":2564638,"statementEnd":2565155,"statementSha256":"7d7d0b80b88e23a1a20a0a72cd64311e3a6302428f415c7f7789f7bc594cad1a"},{"kind":"FunctionDeclaration","bindings":["jse"],"start":2565155,"end":2565291,"sha256":"5beff7236477e305b0eb044931d8a516c11405e6680607d2323c3f9421b9e1bb","statementStart":2565155,"statementEnd":2565291,"statementSha256":"5beff7236477e305b0eb044931d8a516c11405e6680607d2323c3f9421b9e1bb"},{"kind":"FunctionDeclaration","bindings":["dat"],"start":2565291,"end":2565463,"sha256":"de104832d01e07b058025654c039926df54befdef7ce5bb00c23acc54ee031c4","statementStart":2565291,"statementEnd":2565463,"statementSha256":"de104832d01e07b058025654c039926df54befdef7ce5bb00c23acc54ee031c4"},{"kind":"FunctionDeclaration","bindings":["zse"],"start":2565463,"end":2565506,"sha256":"b0106f37854ce59f196ce4e206d07a9120503364ed137958fd54a310bdd8dfee","statementStart":2565463,"statementEnd":2565506,"statementSha256":"b0106f37854ce59f196ce4e206d07a9120503364ed137958fd54a310bdd8dfee"},{"kind":"FunctionDeclaration","bindings":["cMn"],"start":2565506,"end":2565619,"sha256":"7386e8ebcf4cca66b26f80945ab325bb886b19e5c65f8abebd5c3473e65ff115","statementStart":2565506,"statementEnd":2565619,"statementSha256":"7386e8ebcf4cca66b26f80945ab325bb886b19e5c65f8abebd5c3473e65ff115"},{"kind":"VariableDeclarator","bindings":["rat"],"start":2565623,"end":2565696,"sha256":"97fbef362fbf604833658a315188ab1fb730a02685d0e285b09b750e670e4ed1","statementStart":2565619,"statementEnd":2565697,"statementSha256":"80591f256e07b332adeb8e5fd2da2432bd32d117929bc396c807b47fec70b749"},{"kind":"FunctionDeclaration","bindings":["uMn"],"start":2565697,"end":2565849,"sha256":"e652beb9c41eba68ea0f27cfb2ea2f4effef051a02543d26d9bf52451272b669","statementStart":2565697,"statementEnd":2565849,"statementSha256":"e652beb9c41eba68ea0f27cfb2ea2f4effef051a02543d26d9bf52451272b669"},{"kind":"FunctionDeclaration","bindings":["ch"],"start":2565849,"end":2565930,"sha256":"2f9327bf4393e65e792c8660263f3cff42a6a4db6cc264ab6e646e965a2769dd","statementStart":2565849,"statementEnd":2565930,"statementSha256":"2f9327bf4393e65e792c8660263f3cff42a6a4db6cc264ab6e646e965a2769dd"},{"kind":"FunctionDeclaration","bindings":["D$"],"start":2565930,"end":2565974,"sha256":"279901ddb33c9299ae72e2108d075814e8e89cd656d444ba4536a0da261fdb11","statementStart":2565930,"statementEnd":2565974,"statementSha256":"279901ddb33c9299ae72e2108d075814e8e89cd656d444ba4536a0da261fdb11"},{"kind":"FunctionDeclaration","bindings":["oat"],"start":2565974,"end":2566088,"sha256":"5ab321d1ac3e22e4cf1e7b24203b805abe50a7afdb9f12e2f5421eccef16f876","statementStart":2565974,"statementEnd":2566088,"statementSha256":"5ab321d1ac3e22e4cf1e7b24203b805abe50a7afdb9f12e2f5421eccef16f876"},{"kind":"FunctionDeclaration","bindings":["pMn"],"start":2566088,"end":2566429,"sha256":"297d0a3c74ae4593e7ed81bff979fd3dac95cf3a2bae285c1d9060b54a5fa5e9","statementStart":2566088,"statementEnd":2566429,"statementSha256":"297d0a3c74ae4593e7ed81bff979fd3dac95cf3a2bae285c1d9060b54a5fa5e9"},{"kind":"FunctionDeclaration","bindings":["mMn"],"start":2566429,"end":2566766,"sha256":"5ea23e0195b43f58307694dcf3262643f7a5a963474a684883e2ec3d7261ec0c","statementStart":2566429,"statementEnd":2566766,"statementSha256":"5ea23e0195b43f58307694dcf3262643f7a5a963474a684883e2ec3d7261ec0c"},{"kind":"FunctionDeclaration","bindings":["fMn"],"start":2566766,"end":2566898,"sha256":"1a4dbc5477d49106c6bab531e2cb871277428b3c1d07c02a181cc6a41d2042b8","statementStart":2566766,"statementEnd":2566898,"statementSha256":"1a4dbc5477d49106c6bab531e2cb871277428b3c1d07c02a181cc6a41d2042b8"},{"kind":"FunctionDeclaration","bindings":["B$"],"start":2566898,"end":2566984,"sha256":"a41e4f1c441f6e3b3d53de93cc4bda1313da8ca00955f8d1fa00b19296f60096","statementStart":2566898,"statementEnd":2566984,"statementSha256":"a41e4f1c441f6e3b3d53de93cc4bda1313da8ca00955f8d1fa00b19296f60096"},{"kind":"FunctionDeclaration","bindings":["$l"],"start":2566984,"end":2567023,"sha256":"ca97a9cd45a496fc85af6d1c776dbdd504a3c6e36d18c7ed1fd36850a575ab30","statementStart":2566984,"statementEnd":2567023,"statementSha256":"ca97a9cd45a496fc85af6d1c776dbdd504a3c6e36d18c7ed1fd36850a575ab30"},{"kind":"FunctionDeclaration","bindings":["aat"],"start":2567023,"end":2567108,"sha256":"535bef1b18bad0fe654af7a15ba491d46d4d929208d9831172310c5690563ce3","statementStart":2567023,"statementEnd":2567108,"statementSha256":"535bef1b18bad0fe654af7a15ba491d46d4d929208d9831172310c5690563ce3"},{"kind":"FunctionDeclaration","bindings":["gMn"],"start":2567108,"end":2567334,"sha256":"322a258ac8aebd2a61d24cd2c33fdc15d1f392d03a9d27fd8c873b08884657ff","statementStart":2567108,"statementEnd":2567334,"statementSha256":"322a258ac8aebd2a61d24cd2c33fdc15d1f392d03a9d27fd8c873b08884657ff"},{"kind":"FunctionDeclaration","bindings":["yMn"],"start":2567334,"end":2567862,"sha256":"2c6977a7f2c38d1f5d0f702567d657f05e3036da5f5456bba651d1aba24ccef3","statementStart":2567334,"statementEnd":2567862,"statementSha256":"2c6977a7f2c38d1f5d0f702567d657f05e3036da5f5456bba651d1aba24ccef3"},{"kind":"FunctionDeclaration","bindings":["N$"],"start":2567862,"end":2568143,"sha256":"4a9fb0f58d9241a336d85f939f37867cb1b6a68be1057fa6cd671b25085e6423","statementStart":2567862,"statementEnd":2568143,"statementSha256":"4a9fb0f58d9241a336d85f939f37867cb1b6a68be1057fa6cd671b25085e6423"},{"kind":"VariableDeclarator","bindings":["hMn"],"start":2568147,"end":2568206,"sha256":"c06796833d18277ace7ab4bac3ba121e7d4c64843b450715ee238239e0f23ca0","statementStart":2568143,"statementEnd":2568504,"statementSha256":"fbf8ee9489be975b4249e9275b2842087517c2fa75360baddf4a3868de5710c6"},{"kind":"VariableDeclarator","bindings":["cat"],"start":2568207,"end":2568318,"sha256":"bc1bb9c6048d841b743fcbe562e759d08764bed46092d311713940b256f362cf","statementStart":2568143,"statementEnd":2568504,"statementSha256":"fbf8ee9489be975b4249e9275b2842087517c2fa75360baddf4a3868de5710c6"},{"kind":"VariableDeclarator","bindings":["$se"],"start":2568319,"end":2568427,"sha256":"9c5a25653eb0f92dc5acae6f0462600622ed84187aed6dbe5a5464d9e8292e7a","statementStart":2568143,"statementEnd":2568504,"statementSha256":"fbf8ee9489be975b4249e9275b2842087517c2fa75360baddf4a3868de5710c6"},{"kind":"VariableDeclarator","bindings":["Qse"],"start":2568428,"end":2568494,"sha256":"85748d93379536f282cf388b378c3c15516a80cf89674de580099bf31ecfef0b","statementStart":2568143,"statementEnd":2568504,"statementSha256":"fbf8ee9489be975b4249e9275b2842087517c2fa75360baddf4a3868de5710c6"},{"kind":"VariableDeclarator","bindings":["AMn"],"start":2568495,"end":2568503,"sha256":"7b0bbbe2a678825330b2dfe8d4cbeffc54574148121c33578205b81ded25be08","statementStart":2568143,"statementEnd":2568504,"statementSha256":"fbf8ee9489be975b4249e9275b2842087517c2fa75360baddf4a3868de5710c6"},{"kind":"FunctionDeclaration","bindings":["aM"],"start":2568504,"end":2568681,"sha256":"abe964e5f31aa4d4caa981cd6a03ba0650fae46cfb78faedcfa84641c60b2aa1","statementStart":2568504,"statementEnd":2568681,"statementSha256":"abe964e5f31aa4d4caa981cd6a03ba0650fae46cfb78faedcfa84641c60b2aa1"},{"kind":"FunctionDeclaration","bindings":["iat"],"start":2568681,"end":2568757,"sha256":"e4bbc0e022f18d1847f5c29b16b42770297e4238194faf9341e66d4927e710fd","statementStart":2568681,"statementEnd":2568757,"statementSha256":"e4bbc0e022f18d1847f5c29b16b42770297e4238194faf9341e66d4927e710fd"},{"kind":"FunctionDeclaration","bindings":["Vse"],"start":2568757,"end":2568863,"sha256":"33e259f35c1579e44e1400f37a49d1196e35664d56e2574b46a66a43948c5e23","statementStart":2568757,"statementEnd":2568863,"statementSha256":"33e259f35c1579e44e1400f37a49d1196e35664d56e2574b46a66a43948c5e23"},{"kind":"FunctionDeclaration","bindings":["_Mn"],"start":2568863,"end":2569177,"sha256":"e7b1c6907ec7208acec9826c80a51e568f8195d51bfba61f8fa557ea487ece5c","statementStart":2568863,"statementEnd":2569177,"statementSha256":"e7b1c6907ec7208acec9826c80a51e568f8195d51bfba61f8fa557ea487ece5c"},{"kind":"FunctionDeclaration","bindings":["SMn"],"start":2569177,"end":2569261,"sha256":"4a324a80def5188d1275f0a8cda8d750a11002ae33266d8c5ee0e24f0e584ed2","statementStart":2569177,"statementEnd":2569261,"statementSha256":"4a324a80def5188d1275f0a8cda8d750a11002ae33266d8c5ee0e24f0e584ed2"},{"kind":"FunctionDeclaration","bindings":["bMn"],"start":2569261,"end":2569682,"sha256":"13c17ea73101cb1486514b0c5eb9dbbfe5876aa53532194e71d3b2de0190067a","statementStart":2569261,"statementEnd":2569682,"statementSha256":"13c17ea73101cb1486514b0c5eb9dbbfe5876aa53532194e71d3b2de0190067a"},{"kind":"VariableDeclarator","bindings":["sat"],"start":2569686,"end":2569785,"sha256":"7bb0e584e774595deac9c1481e694971fe3be252b7d94e31be3f8173c8a3856e","statementStart":2569682,"statementEnd":2569786,"statementSha256":"c82949eaf3f73573a47e7ba917238ffe3be4e87d68af95697ba61f846cccccf0"},{"kind":"FunctionDeclaration","bindings":["uv"],"start":2569786,"end":2569861,"sha256":"29df20d91cb308674d57ca8eb9e445681fe01e4ecc2fb5373dd959e88f071f4e","statementStart":2569786,"statementEnd":2569861,"statementSha256":"29df20d91cb308674d57ca8eb9e445681fe01e4ecc2fb5373dd959e88f071f4e"},{"kind":"FunctionDeclaration","bindings":["lat"],"start":2569861,"end":2569918,"sha256":"b19b30eefdc2b686eb1537b238ff88a043f66f5f22c2a891e119dfe4767452c4","statementStart":2569861,"statementEnd":2569918,"statementSha256":"b19b30eefdc2b686eb1537b238ff88a043f66f5f22c2a891e119dfe4767452c4"},{"kind":"FunctionDeclaration","bindings":["EMn"],"start":2569918,"end":2570087,"sha256":"5552bc23059b84ab7c97a8e384e984bbc174899aef17b3b27bdfea0ae63c6446","statementStart":2569918,"statementEnd":2570087,"statementSha256":"5552bc23059b84ab7c97a8e384e984bbc174899aef17b3b27bdfea0ae63c6446"},{"kind":"FunctionDeclaration","bindings":["vMn"],"start":2570087,"end":2570793,"sha256":"563ccc9268258ebf97345c686976561cf379ec761cc70f549909efd40793de98","statementStart":2570087,"statementEnd":2570793,"statementSha256":"563ccc9268258ebf97345c686976561cf379ec761cc70f549909efd40793de98"},{"kind":"VariableDeclarator","bindings":["CMn"],"start":2570797,"end":2570854,"sha256":"2717348e2c3a7fb707f2d1a8f7a5f9ae9d3846d4fb2b5f733872be441f80aec3","statementStart":2570793,"statementEnd":2572456,"statementSha256":"7f81ca6a767c793ff211ed65e5a68daec82383efcc4a3886b0c33ca2b18e2933"},{"kind":"VariableDeclarator","bindings":["kMn"],"start":2570855,"end":2570884,"sha256":"834701cf672fe8b45547a701754959b2427116bc8c47af7b829579e0fc847e0c","statementStart":2570793,"statementEnd":2572456,"statementSha256":"7f81ca6a767c793ff211ed65e5a68daec82383efcc4a3886b0c33ca2b18e2933"},{"kind":"VariableDeclarator","bindings":["IMn"],"start":2570885,"end":2570891,"sha256":"164060037ecfbf3c267efa82541c8b44fee0b82bb96c675e7e7ae70b711e141c","statementStart":2570793,"statementEnd":2572456,"statementSha256":"7f81ca6a767c793ff211ed65e5a68daec82383efcc4a3886b0c33ca2b18e2933"},{"kind":"VariableDeclarator","bindings":["TMn"],"start":2570892,"end":2570898,"sha256":"34c7b163ca1183af969aeced056b086af8f746fed43c27155569438b515497f3","statementStart":2570793,"statementEnd":2572456,"statementSha256":"7f81ca6a767c793ff211ed65e5a68daec82383efcc4a3886b0c33ca2b18e2933"},{"kind":"VariableDeclarator","bindings":["uat"],"start":2570899,"end":2572310,"sha256":"e41d439f72ed67d727342d30d6c7e72187575c8cf51e0026bee1d644ab64400d","statementStart":2570793,"statementEnd":2572456,"statementSha256":"7f81ca6a767c793ff211ed65e5a68daec82383efcc4a3886b0c33ca2b18e2933"},{"kind":"VariableDeclarator","bindings":["pat"],"start":2572311,"end":2572455,"sha256":"4eb32310f1827927c3d078280bab130b5ea5330f2d465aad06c3a22345d6341f","statementStart":2570793,"statementEnd":2572456,"statementSha256":"7f81ca6a767c793ff211ed65e5a68daec82383efcc4a3886b0c33ca2b18e2933"},{"kind":"FunctionDeclaration","bindings":["L$"],"start":2572456,"end":2572507,"sha256":"fd813404d3e976104b274593373adeb284453685cabf3a652e12d6fb4ac267ad","statementStart":2572456,"statementEnd":2572507,"statementSha256":"fd813404d3e976104b274593373adeb284453685cabf3a652e12d6fb4ac267ad"},{"kind":"FunctionDeclaration","bindings":["RMn"],"start":2572507,"end":2572568,"sha256":"82ed9678fdfaed7c417de88a262276d2bef669a85408cf783d1dcfa0b4088e6b","statementStart":2572507,"statementEnd":2572568,"statementSha256":"82ed9678fdfaed7c417de88a262276d2bef669a85408cf783d1dcfa0b4088e6b"},{"kind":"FunctionDeclaration","bindings":["wMn"],"start":2572568,"end":2572704,"sha256":"38464bf36fe7ee33823c8d214419f04f2e204477355898440c64f96515e12a62","statementStart":2572568,"statementEnd":2572704,"statementSha256":"38464bf36fe7ee33823c8d214419f04f2e204477355898440c64f96515e12a62"},{"kind":"FunctionDeclaration","bindings":["Hse"],"start":2572704,"end":2572852,"sha256":"419a31aed845ffef2ac849d3ec29607bee20ec6e0425273c55e71ff74b45c946","statementStart":2572704,"statementEnd":2572852,"statementSha256":"419a31aed845ffef2ac849d3ec29607bee20ec6e0425273c55e71ff74b45c946"},{"kind":"VariableDeclarator","bindings":["MMn"],"start":2572856,"end":2573174,"sha256":"bb0cc9f5704f75bb5a2b730ea9f0f97a7df33d4b1a75584ba3ad89889c55903e","statementStart":2572852,"statementEnd":2573175,"statementSha256":"1d1b011e16f5635e83f41742ce76730318f5936186bb85ce2b4b8adc6543d7fc"},{"kind":"FunctionDeclaration","bindings":["xMn"],"start":2573175,"end":2573239,"sha256":"4669f6b0e561841d97f1fc1d38b3258452967daca4bb6fa99d76fe3a9a1dfd26","statementStart":2573175,"statementEnd":2573239,"statementSha256":"4669f6b0e561841d97f1fc1d38b3258452967daca4bb6fa99d76fe3a9a1dfd26"},{"kind":"FunctionDeclaration","bindings":["PMn"],"start":2573239,"end":2573419,"sha256":"5d0872f8c63759d27f3a59373af3e9da81787e5082f0011efca6d465304fcd75","statementStart":2573239,"statementEnd":2573419,"statementSha256":"5d0872f8c63759d27f3a59373af3e9da81787e5082f0011efca6d465304fcd75"},{"kind":"FunctionDeclaration","bindings":["OMn"],"start":2573419,"end":2573624,"sha256":"970fdfc0a4e9d5f8b5d41a6ebb098322003e791ee60750be2b6bf28ed5c14570","statementStart":2573419,"statementEnd":2573624,"statementSha256":"970fdfc0a4e9d5f8b5d41a6ebb098322003e791ee60750be2b6bf28ed5c14570"},{"kind":"FunctionDeclaration","bindings":["DMn"],"start":2573624,"end":2573867,"sha256":"594879753c538ce2ef3219a4e163a3041e80639a0659e3da15d042cf16cae68a","statementStart":2573624,"statementEnd":2573867,"statementSha256":"594879753c538ce2ef3219a4e163a3041e80639a0659e3da15d042cf16cae68a"},{"kind":"FunctionDeclaration","bindings":["mat"],"start":2573867,"end":2574223,"sha256":"069c9654bb879f768a2b85ebd4af1af9cc1e3edd6b3723b436e7763de29ca995","statementStart":2573867,"statementEnd":2574223,"statementSha256":"069c9654bb879f768a2b85ebd4af1af9cc1e3edd6b3723b436e7763de29ca995"},{"kind":"VariableDeclarator","bindings":["BMn"],"start":2574227,"end":2574295,"sha256":"ff4aede876da333c36efa8a2a0be01804e7eb94ba74e5ca4b4102acecf1cfda4","statementStart":2574223,"statementEnd":2574488,"statementSha256":"d4e1d7f3d8a449384de819578d6cdcec4bd72e27dcc742766a13a15268bc329b"},{"kind":"VariableDeclarator","bindings":["NMn"],"start":2574296,"end":2574397,"sha256":"73817869ba771afec127eb4424e0efbb59b1c9b8601dc627477968c95d56e5ba","statementStart":2574223,"statementEnd":2574488,"statementSha256":"d4e1d7f3d8a449384de819578d6cdcec4bd72e27dcc742766a13a15268bc329b"},{"kind":"VariableDeclarator","bindings":["LMn"],"start":2574398,"end":2574405,"sha256":"580c46a123a5eed6323ee9db66693a1d763dba9a26244c3ca9f3b60220bab496","statementStart":2574223,"statementEnd":2574488,"statementSha256":"d4e1d7f3d8a449384de819578d6cdcec4bd72e27dcc742766a13a15268bc329b"},{"kind":"VariableDeclarator","bindings":["UMn"],"start":2574406,"end":2574412,"sha256":"cfeb8fee8ed64d887e5e1ed66a48598d3e0dd8cfda023ef7ced8dde48f065adc","statementStart":2574223,"statementEnd":2574488,"statementSha256":"d4e1d7f3d8a449384de819578d6cdcec4bd72e27dcc742766a13a15268bc329b"},{"kind":"VariableDeclarator","bindings":["FMn"],"start":2574413,"end":2574418,"sha256":"03b2730959b9dac7b2f304f4de569f0526bf9d09162a6927f90ba028d2f95fa2","statementStart":2574223,"statementEnd":2574488,"statementSha256":"d4e1d7f3d8a449384de819578d6cdcec4bd72e27dcc742766a13a15268bc329b"},{"kind":"VariableDeclarator","bindings":["GMn"],"start":2574419,"end":2574487,"sha256":"a009753a27f1d079a47ab50cc14b86aae1f14eed4659a452bf5d5e0562c15c21","statementStart":2574223,"statementEnd":2574488,"statementSha256":"d4e1d7f3d8a449384de819578d6cdcec4bd72e27dcc742766a13a15268bc329b"},{"kind":"FunctionDeclaration","bindings":["fat"],"start":2574488,"end":2574526,"sha256":"6accc36f282100f12e9275091c48f0f69bede1068f890369743c4ffbf26725d6","statementStart":2574488,"statementEnd":2574526,"statementSha256":"6accc36f282100f12e9275091c48f0f69bede1068f890369743c4ffbf26725d6"},{"kind":"FunctionDeclaration","bindings":["QMn"],"start":2574526,"end":2574650,"sha256":"a76b9e2d7576ae7b3e1df63a4b709ed119239f5613af636c212652cd4a521250","statementStart":2574526,"statementEnd":2574650,"statementSha256":"a76b9e2d7576ae7b3e1df63a4b709ed119239f5613af636c212652cd4a521250"},{"kind":"FunctionDeclaration","bindings":["VMn"],"start":2574650,"end":2574878,"sha256":"08a73cda2c7d12e3c06e9d631d1db118719a2fcd4c4c913460aa238644c40ab9","statementStart":2574650,"statementEnd":2574878,"statementSha256":"08a73cda2c7d12e3c06e9d631d1db118719a2fcd4c4c913460aa238644c40ab9"},{"kind":"FunctionDeclaration","bindings":["HMn"],"start":2574878,"end":2575045,"sha256":"3bf5c31e4dc77fd6296d920e4305a22a40b3a0d87d4877bab2667d0a9126c6e3","statementStart":2574878,"statementEnd":2575045,"statementSha256":"3bf5c31e4dc77fd6296d920e4305a22a40b3a0d87d4877bab2667d0a9126c6e3"},{"kind":"FunctionDeclaration","bindings":["jMn"],"start":2575045,"end":2575265,"sha256":"8ea87a084b23054e7518a2e4fd51ccc3a7fcf26c5b5e923157228f5a2526ed2a","statementStart":2575045,"statementEnd":2575265,"statementSha256":"8ea87a084b23054e7518a2e4fd51ccc3a7fcf26c5b5e923157228f5a2526ed2a"},{"kind":"FunctionDeclaration","bindings":["gat"],"start":2575265,"end":2575425,"sha256":"add7adfebbeef0992cf492675f29f4caae3461ef939b66b82e3484786d51987e","statementStart":2575265,"statementEnd":2575425,"statementSha256":"add7adfebbeef0992cf492675f29f4caae3461ef939b66b82e3484786d51987e"}]},"inputSha256":{"dist/renderer/assets/chunk-view-Cwu5IFAB.js":"dd46ccc8fd96a29cf90535a23b682cac313a754f3c5fe246959d812a2fdca9eb","dist/renderer/assets/chunk-vault-card-fields-BBZgWwVF.js":"b05480e6332f105b7721d5b78a0d27561919afc85ea103cc291af0a1940c7177","dist/electron-main/main-app.cjs":"fa230cd5412ef24df45eadf8af519a6cc285f5d44a81771ae074875fe5f94030"}}// ../../../../../private/chunk-vault-card-fields-BBZgWwVF.js -var te = /[\s-]/g; -var ne = /^\d{13,19}$/; -function re(e2) { - let t = e2.replace(te, ``); - if (!ne.test(t)) return false; +// Generated by scripts/lib/vault-0721.mjs from the pinned Grok Bot 0.75.5 ASAR. Do not edit.// provenance={"upstreamIdentity":{"version":"0.75.5","asarSha256":"12bba50ba6cf12b35132518788610677a3fdc65de4ad849628d757bc7b780e5a"},"sources":{"dist/renderer/assets/chunk-view-CuYU9NOh.js":[{"kind":"ImportSpecifier","bindings":["re"],"start":1250,"end":1257,"sha256":"e1943d9a594511badf8b31acb6f1f4bfb2de1f653264b4421e3fe2ce69c2d0f8","statementStart":1243,"statementEnd":1302,"statementSha256":"61f531940765428b6948aeb01a953255110208e4396b07c112f99d985b5480f8"},{"kind":"ImportSpecifier","bindings":["ae"],"start":1368,"end":1375,"sha256":"a9ae4ad41861b3fe803163bfd4b7f181974e07931920fef2fcf728bac9c99820","statementStart":1361,"statementEnd":1412,"statementSha256":"462d3038374559e646472e996e81c7067232b068a3940f8b2930417c7a09367b"},{"kind":"VariableDeclarator","bindings":["fe"],"start":11152,"end":11158,"sha256":"42a89bb272aee49754d34465c5f324028215d59f576e0ca36202d9703d207d0a","statementStart":1412,"statementEnd":11238,"statementSha256":"1275fc473d849d5812e4814c914f92d53f4d5cb996cd51986cf7cb5638eb1b3f"},{"kind":"VariableDeclarator","bindings":["pe"],"start":11159,"end":11165,"sha256":"57b1f1570f738252995c81fa437fb202546a7377e38fa884d067e656894abf21","statementStart":1412,"statementEnd":11238,"statementSha256":"1275fc473d849d5812e4814c914f92d53f4d5cb996cd51986cf7cb5638eb1b3f"},{"kind":"VariableDeclarator","bindings":["me"],"start":11166,"end":11172,"sha256":"b29ccc696a77b2fea4e4d0acef6d1812b16df16136c57d8daaa8e7b5d6714a48","statementStart":1412,"statementEnd":11238,"statementSha256":"1275fc473d849d5812e4814c914f92d53f4d5cb996cd51986cf7cb5638eb1b3f"},{"kind":"VariableDeclarator","bindings":["he"],"start":11173,"end":11178,"sha256":"b094e6dcbd5bb909b4c31f93c2b726972912f26b5f0d4e87d08863e65b401b38","statementStart":1412,"statementEnd":11238,"statementSha256":"1275fc473d849d5812e4814c914f92d53f4d5cb996cd51986cf7cb5638eb1b3f"},{"kind":"VariableDeclarator","bindings":["ge"],"start":11179,"end":11186,"sha256":"53846b14bc37a91cc74268560936c3ec87a760196a4cde5ce07f6e50cc9e7fd4","statementStart":1412,"statementEnd":11238,"statementSha256":"1275fc473d849d5812e4814c914f92d53f4d5cb996cd51986cf7cb5638eb1b3f"},{"kind":"VariableDeclarator","bindings":["_e"],"start":11187,"end":11194,"sha256":"bf0984a871805cb142125f1600496272b5ee9d5310b91a088b68080de27263b2","statementStart":1412,"statementEnd":11238,"statementSha256":"1275fc473d849d5812e4814c914f92d53f4d5cb996cd51986cf7cb5638eb1b3f"},{"kind":"VariableDeclarator","bindings":["ve"],"start":11195,"end":11209,"sha256":"4c43bb878145d4402b822f27fa9d0c229b833de8368be5fcbfe37f01d9476ef2","statementStart":1412,"statementEnd":11238,"statementSha256":"1275fc473d849d5812e4814c914f92d53f4d5cb996cd51986cf7cb5638eb1b3f"},{"kind":"VariableDeclarator","bindings":["ye"],"start":11210,"end":11237,"sha256":"595767b589dee515e7b13519fe17ddf72b954f3554a877dea5c89693561f0705","statementStart":1412,"statementEnd":11238,"statementSha256":"1275fc473d849d5812e4814c914f92d53f4d5cb996cd51986cf7cb5638eb1b3f"},{"kind":"FunctionDeclaration","bindings":["be"],"start":11238,"end":11465,"sha256":"f7fc7971ccae911932f2715ca8ae672f61281a7ed2c03f07a1fc82090cec26ab","statementStart":11238,"statementEnd":11465,"statementSha256":"f7fc7971ccae911932f2715ca8ae672f61281a7ed2c03f07a1fc82090cec26ab"},{"kind":"FunctionDeclaration","bindings":["xe"],"start":11465,"end":11990,"sha256":"aa35f929dae70392923007b3c9564c4ef2904fdaa8fd38019f0d1df8bc273859","statementStart":11465,"statementEnd":11990,"statementSha256":"aa35f929dae70392923007b3c9564c4ef2904fdaa8fd38019f0d1df8bc273859"},{"kind":"FunctionDeclaration","bindings":["Se"],"start":11990,"end":12070,"sha256":"fc61cad3a199aabb9c2848f0b9bfae934a07ab65c80db446239c002735d462bb","statementStart":11990,"statementEnd":12070,"statementSha256":"fc61cad3a199aabb9c2848f0b9bfae934a07ab65c80db446239c002735d462bb"},{"kind":"FunctionDeclaration","bindings":["Ce"],"start":12070,"end":12320,"sha256":"6e2ba7afca3df2b35068e0a8ab27e4ef31ca20a20298aababb369911f6d0fe3d","statementStart":12070,"statementEnd":12320,"statementSha256":"6e2ba7afca3df2b35068e0a8ab27e4ef31ca20a20298aababb369911f6d0fe3d"},{"kind":"FunctionDeclaration","bindings":["we"],"start":12320,"end":12810,"sha256":"29673ebde707b9dd37e1998738083ba8317983e46955ddc44f864a0a8f908d24","statementStart":12320,"statementEnd":12810,"statementSha256":"29673ebde707b9dd37e1998738083ba8317983e46955ddc44f864a0a8f908d24"},{"kind":"FunctionDeclaration","bindings":["Te"],"start":12810,"end":13697,"sha256":"14143579f5babbeae2df1b3f850b0c9dbe7140b7fa69eb814afcccb2cb116320","statementStart":12810,"statementEnd":13697,"statementSha256":"14143579f5babbeae2df1b3f850b0c9dbe7140b7fa69eb814afcccb2cb116320"},{"kind":"FunctionDeclaration","bindings":["Ee"],"start":13697,"end":13957,"sha256":"d4a72a0b25edad30fbe9567042e6828a8dd665ad4666a6d9dea3a04df9c2a35c","statementStart":13697,"statementEnd":13957,"statementSha256":"d4a72a0b25edad30fbe9567042e6828a8dd665ad4666a6d9dea3a04df9c2a35c"},{"kind":"FunctionDeclaration","bindings":["De"],"start":13957,"end":14016,"sha256":"7ee4fe5b01f45631729bf914a643c0695c4ee746e992d889bd4c78d7e291e16c","statementStart":13957,"statementEnd":14016,"statementSha256":"7ee4fe5b01f45631729bf914a643c0695c4ee746e992d889bd4c78d7e291e16c"},{"kind":"FunctionDeclaration","bindings":["Oe"],"start":14016,"end":14136,"sha256":"a243e7fe66e2d1d2cd1c01e25c9d25d05541751fc9f5ec1c6530e81c76f655d7","statementStart":14016,"statementEnd":14136,"statementSha256":"a243e7fe66e2d1d2cd1c01e25c9d25d05541751fc9f5ec1c6530e81c76f655d7"},{"kind":"FunctionDeclaration","bindings":["ke"],"start":14136,"end":14209,"sha256":"3f194d30f0a342b5a4972dcc7ef482b14a34c0b2054f4e5f25aaf4d8553108e9","statementStart":14136,"statementEnd":14209,"statementSha256":"3f194d30f0a342b5a4972dcc7ef482b14a34c0b2054f4e5f25aaf4d8553108e9"},{"kind":"FunctionDeclaration","bindings":["Ae"],"start":14209,"end":14272,"sha256":"cecd907add08b0897a55b1a25761de028703bef0528e2077f143998d2329e653","statementStart":14209,"statementEnd":14272,"statementSha256":"cecd907add08b0897a55b1a25761de028703bef0528e2077f143998d2329e653"},{"kind":"FunctionDeclaration","bindings":["je"],"start":14272,"end":14375,"sha256":"0ac4c01e75b910ae7e1d47516663a81a55ef1828590f1c2811781771f0b6542c","statementStart":14272,"statementEnd":14375,"statementSha256":"0ac4c01e75b910ae7e1d47516663a81a55ef1828590f1c2811781771f0b6542c"},{"kind":"VariableDeclarator","bindings":["Me"],"start":14379,"end":14493,"sha256":"02a1eafcff3876921d3ac77254bcdc7e0bf5d8bbdb30cf9bf33f1667eeb5afee","statementStart":14375,"statementEnd":14494,"statementSha256":"91187165d8b316bb1cd0128d436c7df66624c4ab71a359cd79fc7d5389779035"},{"kind":"FunctionDeclaration","bindings":["Ne"],"start":14494,"end":14692,"sha256":"cd38fc652ce68b7a0f0cb8de44c940ca9bad43070d0546e1d17ed0da92de7a89","statementStart":14494,"statementEnd":14692,"statementSha256":"cd38fc652ce68b7a0f0cb8de44c940ca9bad43070d0546e1d17ed0da92de7a89"},{"kind":"FunctionDeclaration","bindings":["Pe"],"start":14692,"end":14793,"sha256":"e914ea0ab2e088564ea1d3b28c2647786a2d566114576e1f4e110a8be3316965","statementStart":14692,"statementEnd":14793,"statementSha256":"e914ea0ab2e088564ea1d3b28c2647786a2d566114576e1f4e110a8be3316965"},{"kind":"FunctionDeclaration","bindings":["Fe"],"start":14793,"end":15014,"sha256":"b84116e14610bb7593c085e7b112f762a763d78273a95fc0578bf8a2bff796b0","statementStart":14793,"statementEnd":15014,"statementSha256":"b84116e14610bb7593c085e7b112f762a763d78273a95fc0578bf8a2bff796b0"},{"kind":"FunctionDeclaration","bindings":["Ie"],"start":15014,"end":15110,"sha256":"4b56e2babdbc9a0e5444c31ad836fb5b6365693c09e8263623e8296746b19df9","statementStart":15014,"statementEnd":15110,"statementSha256":"4b56e2babdbc9a0e5444c31ad836fb5b6365693c09e8263623e8296746b19df9"},{"kind":"FunctionDeclaration","bindings":["Le"],"start":15110,"end":15272,"sha256":"33d05484fdf2a9ea62a042432e644fd41bceaa8caac21e8c5204bd0e8857be29","statementStart":15110,"statementEnd":15272,"statementSha256":"33d05484fdf2a9ea62a042432e644fd41bceaa8caac21e8c5204bd0e8857be29"},{"kind":"FunctionDeclaration","bindings":["Re"],"start":15272,"end":16229,"sha256":"d806207a490cbd48bb4357f040989fa07756b38bf2db0845bada8986e28b5ee9","statementStart":15272,"statementEnd":16229,"statementSha256":"d806207a490cbd48bb4357f040989fa07756b38bf2db0845bada8986e28b5ee9"},{"kind":"FunctionDeclaration","bindings":["ze"],"start":16229,"end":17257,"sha256":"256f53a2f0557aa8290b9c535895237fe22a6fda0b1effd2dbda4600874087c6","statementStart":16229,"statementEnd":17257,"statementSha256":"256f53a2f0557aa8290b9c535895237fe22a6fda0b1effd2dbda4600874087c6"},{"kind":"FunctionDeclaration","bindings":["Be"],"start":17257,"end":17546,"sha256":"e460ee46d826f5b41b02abfa016ea1e872b23215ec0b128696857afb8b3bf627","statementStart":17257,"statementEnd":17546,"statementSha256":"e460ee46d826f5b41b02abfa016ea1e872b23215ec0b128696857afb8b3bf627"},{"kind":"FunctionDeclaration","bindings":["Ve"],"start":17546,"end":18178,"sha256":"91707d501230362e2887d502a61e410fb7cf71008d7aca477975c0055c8620ca","statementStart":17546,"statementEnd":18178,"statementSha256":"91707d501230362e2887d502a61e410fb7cf71008d7aca477975c0055c8620ca"}],"dist/renderer/assets/chunk-vault-card-dialog-C8ioyi_k.js":[{"kind":"VariableDeclarator","bindings":["J"],"start":8212,"end":8222,"sha256":"c2e1037959308738cd040070824fc4ce71773ab4a7eeb8492f9d0796bddfa88c","statementStart":8208,"statementEnd":8240,"statementSha256":"75a31dcdd45e2b7c8c6d59eb79291e89a9a42cd447f380db757d16658af06799"},{"kind":"VariableDeclarator","bindings":["le"],"start":8223,"end":8239,"sha256":"23cb20032ed5122f15ac838215837d51857cbad0dbe9b8429b2196cec88d0f4f","statementStart":8208,"statementEnd":8240,"statementSha256":"75a31dcdd45e2b7c8c6d59eb79291e89a9a42cd447f380db757d16658af06799"},{"kind":"FunctionDeclaration","bindings":["Y"],"start":8240,"end":8419,"sha256":"889abd872e3c36e08e36e2ab792286006bf201dc30a43a8fea80eaa2eb98e1e8","statementStart":8240,"statementEnd":8419,"statementSha256":"889abd872e3c36e08e36e2ab792286006bf201dc30a43a8fea80eaa2eb98e1e8"},{"kind":"VariableDeclarator","bindings":["mt"],"start":33056,"end":33062,"sha256":"9f79719d5fb7d85b792b5cbe52082242fe3b0bea3ae690fb87b4fe24744655e3","statementStart":33007,"statementEnd":33063,"statementSha256":"cc5564ad21a857e9519aee99680dc3264077bf07a6ee2c9d74b8e43136b353a8"},{"kind":"FunctionDeclaration","bindings":["ht"],"start":33063,"end":33115,"sha256":"785c0da7a951f01bcf8c19aea234d93bcbf2587d38ad14a6f1598386a1b7aa2e","statementStart":33063,"statementEnd":33115,"statementSha256":"785c0da7a951f01bcf8c19aea234d93bcbf2587d38ad14a6f1598386a1b7aa2e"},{"kind":"FunctionDeclaration","bindings":["gt"],"start":33115,"end":33673,"sha256":"a1ff78f40b945a7ebecd21de194501502c7054a0308c48d36441cfb382f63779","statementStart":33115,"statementEnd":33673,"statementSha256":"a1ff78f40b945a7ebecd21de194501502c7054a0308c48d36441cfb382f63779"}],"dist/electron-main/main-app.cjs":[{"kind":"VariableDeclarator","bindings":["mMn"],"start":2548957,"end":2549469,"sha256":"7fe2fb5bf7f4c3ba9a213c742aabb05dbb3dfd50ce8daebed52d1084bdb1b79b","statementStart":2548953,"statementEnd":2549470,"statementSha256":"cbea027ca3410f1c7b5c0c4bc0dbf00ec5876264cacb517568153e1f708cad2e"},{"kind":"FunctionDeclaration","bindings":["yse"],"start":2549470,"end":2549606,"sha256":"fcdf8b946067b081cfd76dd08621743c37d3527b732d4dc55f7a0e2286f940c1","statementStart":2549470,"statementEnd":2549606,"statementSha256":"fcdf8b946067b081cfd76dd08621743c37d3527b732d4dc55f7a0e2286f940c1"},{"kind":"FunctionDeclaration","bindings":["Aat"],"start":2549606,"end":2549778,"sha256":"c917c00e04816f757f34d073597c37b5eba2b4b8f51fa5911c3b37a5640150bd","statementStart":2549606,"statementEnd":2549778,"statementSha256":"c917c00e04816f757f34d073597c37b5eba2b4b8f51fa5911c3b37a5640150bd"},{"kind":"FunctionDeclaration","bindings":["r$"],"start":2549778,"end":2549820,"sha256":"966714fe7c1792d9f742d5c475e73d44b063235ebf717baf919f3fa09c26658d","statementStart":2549778,"statementEnd":2549820,"statementSha256":"966714fe7c1792d9f742d5c475e73d44b063235ebf717baf919f3fa09c26658d"},{"kind":"FunctionDeclaration","bindings":["fMn"],"start":2549820,"end":2549932,"sha256":"c48257967b2758e70e967b3705f520066634c28a170f4ac7b7fcae195ba3ffec","statementStart":2549820,"statementEnd":2549932,"statementSha256":"c48257967b2758e70e967b3705f520066634c28a170f4ac7b7fcae195ba3ffec"},{"kind":"VariableDeclarator","bindings":["uat"],"start":2549936,"end":2550009,"sha256":"9e072d01ef799ba8638ba0707552fec14f99b21fd2c93d6e996c66240b189a62","statementStart":2549932,"statementEnd":2550010,"statementSha256":"88dea31f80191936844c4a64f9e7478e96be0a1c60b9479c82ebe2f2814d1fb2"},{"kind":"FunctionDeclaration","bindings":["gMn"],"start":2550010,"end":2550162,"sha256":"1c79113076f0c025b82fa361beae08dce157ffc47a56e6e877507165b4f21369","statementStart":2550010,"statementEnd":2550162,"statementSha256":"1c79113076f0c025b82fa361beae08dce157ffc47a56e6e877507165b4f21369"},{"kind":"FunctionDeclaration","bindings":["Im"],"start":2550162,"end":2550243,"sha256":"e700ac188cade893a4faf377b8ee8f12c86c210ddd85c1a4cdfce0b9b9c63595","statementStart":2550162,"statementEnd":2550243,"statementSha256":"e700ac188cade893a4faf377b8ee8f12c86c210ddd85c1a4cdfce0b9b9c63595"},{"kind":"FunctionDeclaration","bindings":["Xj"],"start":2550243,"end":2550286,"sha256":"b565cc387bae786773ed990b8b493387f589cb50fa1750d4a915f6cf4d9f36be","statementStart":2550243,"statementEnd":2550286,"statementSha256":"b565cc387bae786773ed990b8b493387f589cb50fa1750d4a915f6cf4d9f36be"},{"kind":"FunctionDeclaration","bindings":["pat"],"start":2550286,"end":2550400,"sha256":"d3da723dd6f1fa1f1faad04e336d7ace83f9b741741ac6b489f7fe612db3d551","statementStart":2550286,"statementEnd":2550400,"statementSha256":"d3da723dd6f1fa1f1faad04e336d7ace83f9b741741ac6b489f7fe612db3d551"},{"kind":"FunctionDeclaration","bindings":["yMn"],"start":2550400,"end":2550741,"sha256":"e967c3b3f18a635e6f886d9dbfe24b1e8908cc4d3cf49c8271bec3b2bbdc321a","statementStart":2550400,"statementEnd":2550741,"statementSha256":"e967c3b3f18a635e6f886d9dbfe24b1e8908cc4d3cf49c8271bec3b2bbdc321a"},{"kind":"FunctionDeclaration","bindings":["AMn"],"start":2550741,"end":2551078,"sha256":"d05e7ca1cbeee6a39ebc35b6806090b0852c069ed8886d76607e8aaaaae34598","statementStart":2550741,"statementEnd":2551078,"statementSha256":"d05e7ca1cbeee6a39ebc35b6806090b0852c069ed8886d76607e8aaaaae34598"},{"kind":"FunctionDeclaration","bindings":["hMn"],"start":2551078,"end":2551210,"sha256":"6ffb9eed11f54700fbc0175e4a0073c4078a2f872312cd0ded49ae20af4791b7","statementStart":2551078,"statementEnd":2551210,"statementSha256":"6ffb9eed11f54700fbc0175e4a0073c4078a2f872312cd0ded49ae20af4791b7"},{"kind":"FunctionDeclaration","bindings":["e$"],"start":2551210,"end":2551296,"sha256":"fd36b75b132fbea15aea0fcc9c6f368b884f312fe73fbc6d8da2ffea92a29c1f","statementStart":2551210,"statementEnd":2551296,"statementSha256":"fd36b75b132fbea15aea0fcc9c6f368b884f312fe73fbc6d8da2ffea92a29c1f"},{"kind":"FunctionDeclaration","bindings":["Ao"],"start":2551296,"end":2551335,"sha256":"aff2e887a752d7be3ae3d44cb786190179b48804ffd9505c978bd00bd0cef722","statementStart":2551296,"statementEnd":2551335,"statementSha256":"aff2e887a752d7be3ae3d44cb786190179b48804ffd9505c978bd00bd0cef722"},{"kind":"FunctionDeclaration","bindings":["mat"],"start":2551335,"end":2551420,"sha256":"9ec02555de6a8086fd9f336c6e7b511e247a96920c7c6b41e4af6b3b2ef6ba2e","statementStart":2551335,"statementEnd":2551420,"statementSha256":"9ec02555de6a8086fd9f336c6e7b511e247a96920c7c6b41e4af6b3b2ef6ba2e"},{"kind":"FunctionDeclaration","bindings":["SMn"],"start":2551420,"end":2551646,"sha256":"acc811e168549f07a54e8f50817c73d3f1d9e404febea3df02bd646956e904df","statementStart":2551420,"statementEnd":2551646,"statementSha256":"acc811e168549f07a54e8f50817c73d3f1d9e404febea3df02bd646956e904df"},{"kind":"FunctionDeclaration","bindings":["_Mn"],"start":2551646,"end":2552481,"sha256":"1f2881586c002c9959fd7762a2884f77a7692bfc1ad02b973a36c6bd64664a1c","statementStart":2551646,"statementEnd":2552481,"statementSha256":"1f2881586c002c9959fd7762a2884f77a7692bfc1ad02b973a36c6bd64664a1c"},{"kind":"FunctionDeclaration","bindings":["t$"],"start":2552481,"end":2552783,"sha256":"4434c4abc89133a83cb70c03d94c7ed28b9bb41b3ef4edeee00a59a248576da3","statementStart":2552481,"statementEnd":2552783,"statementSha256":"4434c4abc89133a83cb70c03d94c7ed28b9bb41b3ef4edeee00a59a248576da3"},{"kind":"VariableDeclarator","bindings":["EMn"],"start":2552787,"end":2552846,"sha256":"ae185fb4b489589c0aa25234ccb5207ccd6e0e1c8abb016b3bc65272e57c83d3","statementStart":2552783,"statementEnd":2553222,"statementSha256":"a314e99e5bb41a64fdf87e85342fded84dfb9c26bb7d6f63fa3837ae595e1cb9"},{"kind":"VariableDeclarator","bindings":["By"],"start":2552847,"end":2552957,"sha256":"4b3bfb035ae12d63e4404c9a3516a4704708844c627e70c78d9515f1fb3f3426","statementStart":2552783,"statementEnd":2553222,"statementSha256":"a314e99e5bb41a64fdf87e85342fded84dfb9c26bb7d6f63fa3837ae595e1cb9"},{"kind":"VariableDeclarator","bindings":["Ase"],"start":2552958,"end":2553066,"sha256":"6b9b5bbc72aa4e9f8d1f4d75719328438ef66dabe59e4330d37a5cf63238da37","statementStart":2552783,"statementEnd":2553222,"statementSha256":"a314e99e5bb41a64fdf87e85342fded84dfb9c26bb7d6f63fa3837ae595e1cb9"},{"kind":"VariableDeclarator","bindings":["bMn"],"start":2553067,"end":2553088,"sha256":"832472881c262b3efe3cde4bd7834c6e74085111b5c58d235ad9262a9bdb785a","statementStart":2552783,"statementEnd":2553222,"statementSha256":"a314e99e5bb41a64fdf87e85342fded84dfb9c26bb7d6f63fa3837ae595e1cb9"},{"kind":"VariableDeclarator","bindings":["CMn"],"start":2553089,"end":2553146,"sha256":"1a2849d6be94d41fa3df10213951a7e730deaa5210b3eef19f344e13f2918583","statementStart":2552783,"statementEnd":2553222,"statementSha256":"a314e99e5bb41a64fdf87e85342fded84dfb9c26bb7d6f63fa3837ae595e1cb9"},{"kind":"VariableDeclarator","bindings":["Cw"],"start":2553147,"end":2553212,"sha256":"3e8d3f5028880efbd127d50da3242977acb63958ce9bb2936889067b55aaac34","statementStart":2552783,"statementEnd":2553222,"statementSha256":"a314e99e5bb41a64fdf87e85342fded84dfb9c26bb7d6f63fa3837ae595e1cb9"},{"kind":"VariableDeclarator","bindings":["vMn"],"start":2553213,"end":2553221,"sha256":"dd5def5fecd434b2276257ec0e4923dede5aa6758b1aa4d8602ec16e73b6f4dd","statementStart":2552783,"statementEnd":2553222,"statementSha256":"a314e99e5bb41a64fdf87e85342fded84dfb9c26bb7d6f63fa3837ae595e1cb9"},{"kind":"FunctionDeclaration","bindings":["km"],"start":2553222,"end":2553399,"sha256":"c29aabf3b49d4fbc2dba3caa363b641d37043d8554109af18854ab5fd38c2ded","statementStart":2553222,"statementEnd":2553399,"statementSha256":"c29aabf3b49d4fbc2dba3caa363b641d37043d8554109af18854ab5fd38c2ded"},{"kind":"FunctionDeclaration","bindings":["fat"],"start":2553399,"end":2553475,"sha256":"467614a1242f6f22f540ae306cc89a899524a690849da076f3f53dd572d0d733","statementStart":2553399,"statementEnd":2553475,"statementSha256":"467614a1242f6f22f540ae306cc89a899524a690849da076f3f53dd572d0d733"},{"kind":"FunctionDeclaration","bindings":["Jj"],"start":2553475,"end":2553580,"sha256":"0490318d1473bad60e3e143a9debfefbc409bfc2668eeba7b4716d34e3a6c205","statementStart":2553475,"statementEnd":2553580,"statementSha256":"0490318d1473bad60e3e143a9debfefbc409bfc2668eeba7b4716d34e3a6c205"},{"kind":"FunctionDeclaration","bindings":["kMn"],"start":2553580,"end":2553893,"sha256":"f1a482f5ad5563382e4f07885708b5118f35b4a1bf203656e6909420bf1fa934","statementStart":2553580,"statementEnd":2553893,"statementSha256":"f1a482f5ad5563382e4f07885708b5118f35b4a1bf203656e6909420bf1fa934"},{"kind":"FunctionDeclaration","bindings":["IMn"],"start":2553893,"end":2553977,"sha256":"78502f9fd095c3bf7b8297d0a1d93225bd993c26e1435c8dc23bf8b15edc6523","statementStart":2553893,"statementEnd":2553977,"statementSha256":"78502f9fd095c3bf7b8297d0a1d93225bd993c26e1435c8dc23bf8b15edc6523"},{"kind":"FunctionDeclaration","bindings":["TMn"],"start":2553977,"end":2554391,"sha256":"c29d594e690f03aa04ab61f37e061ec7b5cfa30d49ab6f6e71b0f2c06c6cbea2","statementStart":2553977,"statementEnd":2554391,"statementSha256":"c29d594e690f03aa04ab61f37e061ec7b5cfa30d49ab6f6e71b0f2c06c6cbea2"},{"kind":"VariableDeclarator","bindings":["fse"],"start":2554395,"end":2554539,"sha256":"231e96873bc5fd883229a3478faa1ac34f675abce412862840edcc5e57b0a010","statementStart":2554391,"statementEnd":2554540,"statementSha256":"3bc130eb6311f5594ad3dd2b3a7710c3c0f11708f9c9e98adfb5b2f719426afe"},{"kind":"FunctionDeclaration","bindings":["vw"],"start":2554540,"end":2554615,"sha256":"6d166b852b84301b6456b9328712e0e99d1cab741c33a2255e5c18cf6098b944","statementStart":2554540,"statementEnd":2554615,"statementSha256":"6d166b852b84301b6456b9328712e0e99d1cab741c33a2255e5c18cf6098b944"},{"kind":"FunctionDeclaration","bindings":["gat"],"start":2554615,"end":2554672,"sha256":"567a15e8448c6eff227dda2f0bd96194267c73355095946dd5c21ba9edfa65c7","statementStart":2554615,"statementEnd":2554672,"statementSha256":"567a15e8448c6eff227dda2f0bd96194267c73355095946dd5c21ba9edfa65c7"},{"kind":"FunctionDeclaration","bindings":["RMn"],"start":2554672,"end":2554841,"sha256":"8109aa199fa42dfcd0e7fdaaa334d0a61a3bb617250b8a860ca2ae5bbc2f4fd6","statementStart":2554672,"statementEnd":2554841,"statementSha256":"8109aa199fa42dfcd0e7fdaaa334d0a61a3bb617250b8a860ca2ae5bbc2f4fd6"},{"kind":"VariableDeclarator","bindings":["hat"],"start":2554845,"end":2554870,"sha256":"09c48bcc87add3cb06e68f66fa418f69812ebbd8f945909272c71bce3d75dc06","statementStart":2554841,"statementEnd":2555099,"statementSha256":"3ae64d7b24b17678b59cc9b43d29ab45aca65268133cb8acba3ca9fe7767cd5c"},{"kind":"VariableDeclarator","bindings":["wMn"],"start":2554871,"end":2555098,"sha256":"1fdf052e1b9d24bd0ef418f0c3e88b6d5438c1112d3c910047542ed01f06450f","statementStart":2554841,"statementEnd":2555099,"statementSha256":"3ae64d7b24b17678b59cc9b43d29ab45aca65268133cb8acba3ca9fe7767cd5c"},{"kind":"FunctionDeclaration","bindings":["Sat"],"start":2555099,"end":2555249,"sha256":"d3d4813fdc6553f07cc7a524f07d3914f61fff435e8fc5e94bdb079c2ee68ec0","statementStart":2555099,"statementEnd":2555249,"statementSha256":"d3d4813fdc6553f07cc7a524f07d3914f61fff435e8fc5e94bdb079c2ee68ec0"},{"kind":"FunctionDeclaration","bindings":["hse"],"start":2555249,"end":2555391,"sha256":"93ee04e71b6f57d3e59ff4d558ab5404a31d9fa1478abf5f40bbdbcb224ae5fd","statementStart":2555249,"statementEnd":2555391,"statementSha256":"93ee04e71b6f57d3e59ff4d558ab5404a31d9fa1478abf5f40bbdbcb224ae5fd"},{"kind":"VariableDeclarator","bindings":["MMn"],"start":2555395,"end":2555457,"sha256":"368851a85b987ddd8e91165658bac767711186cdbfc93a105f22e8700242194d","statementStart":2555391,"statementEnd":2555458,"statementSha256":"519fc54d4b319acb030e6fe8aa32b9d337937a763b58aa7294308dd7efb96a33"},{"kind":"FunctionDeclaration","bindings":["_at"],"start":2555458,"end":2555557,"sha256":"becbc65aad7ff1b010f3fea397200ffaa5f3748eb5be61223c6bc1ce2858f5f2","statementStart":2555458,"statementEnd":2555557,"statementSha256":"becbc65aad7ff1b010f3fea397200ffaa5f3748eb5be61223c6bc1ce2858f5f2"},{"kind":"FunctionDeclaration","bindings":["Eat"],"start":2555557,"end":2555737,"sha256":"74ecadfb932f2974af30caa6d91c511ba1172eba89125e245b2cae651a0b924c","statementStart":2555557,"statementEnd":2555737,"statementSha256":"74ecadfb932f2974af30caa6d91c511ba1172eba89125e245b2cae651a0b924c"},{"kind":"FunctionDeclaration","bindings":["PMn"],"start":2555737,"end":2556059,"sha256":"b076cde55af756945afee317b1fcbdfd081edda6435d2da016f054bd7e697c79","statementStart":2555737,"statementEnd":2556059,"statementSha256":"b076cde55af756945afee317b1fcbdfd081edda6435d2da016f054bd7e697c79"},{"kind":"FunctionDeclaration","bindings":["xMn"],"start":2556059,"end":2556153,"sha256":"c430a291730d29386c293ae148c3e38693d15c58b33d1fe2405ea5d9097e8cb6","statementStart":2556059,"statementEnd":2556153,"statementSha256":"c430a291730d29386c293ae148c3e38693d15c58b33d1fe2405ea5d9097e8cb6"},{"kind":"FunctionDeclaration","bindings":["OMn"],"start":2556153,"end":2556330,"sha256":"d53fcc31579b3ce5feea8c86189e012b2f8ab9450d5ace63ea4ce99864c26380","statementStart":2556153,"statementEnd":2556330,"statementSha256":"d53fcc31579b3ce5feea8c86189e012b2f8ab9450d5ace63ea4ce99864c26380"},{"kind":"FunctionDeclaration","bindings":["DMn"],"start":2556330,"end":2556734,"sha256":"07b5993195f82ccd4a61f3c4ed4e90ae434fdeb021f4af659f2690007481c6a8","statementStart":2556330,"statementEnd":2556734,"statementSha256":"07b5993195f82ccd4a61f3c4ed4e90ae434fdeb021f4af659f2690007481c6a8"},{"kind":"FunctionDeclaration","bindings":["BMn"],"start":2556734,"end":2557010,"sha256":"ae9e2d693440c91c2e4fb156367bf1cc460f46539168d289b7a0167e20ba036d","statementStart":2556734,"statementEnd":2557010,"statementSha256":"ae9e2d693440c91c2e4fb156367bf1cc460f46539168d289b7a0167e20ba036d"},{"kind":"FunctionDeclaration","bindings":["yat"],"start":2557010,"end":2558439,"sha256":"1c7ca325461348cbe78e7331c27367594a8336345603c41305df3bdf16626459","statementStart":2557010,"statementEnd":2558439,"statementSha256":"1c7ca325461348cbe78e7331c27367594a8336345603c41305df3bdf16626459"},{"kind":"VariableDeclarator","bindings":["NMn"],"start":2558443,"end":2558548,"sha256":"5de82dffdd20abad9398d5ad833cebae7ff7193207de2629d7da0eca4cc9e0d1","statementStart":2558439,"statementEnd":2560150,"statementSha256":"42682b6c2fc42a8f9d11457ef3e9b55688ea66e7ccc4ae3e13063948693853af"},{"kind":"VariableDeclarator","bindings":["LMn"],"start":2558549,"end":2558578,"sha256":"f613faa42641b311f7cfa28e5aeee0dc20367809a5a8553128e8887886a79ee4","statementStart":2558439,"statementEnd":2560150,"statementSha256":"42682b6c2fc42a8f9d11457ef3e9b55688ea66e7ccc4ae3e13063948693853af"},{"kind":"VariableDeclarator","bindings":["UMn"],"start":2558579,"end":2558585,"sha256":"5714fe66b427fa6fecf92821d28f7a44d0c75321ff44e18281ad7d7d581801da","statementStart":2558439,"statementEnd":2560150,"statementSha256":"42682b6c2fc42a8f9d11457ef3e9b55688ea66e7ccc4ae3e13063948693853af"},{"kind":"VariableDeclarator","bindings":["FMn"],"start":2558586,"end":2558592,"sha256":"aefb6115c5a7735b34240659a72cbadf8475391abdae2a7f8a2926dc9e4929aa","statementStart":2558439,"statementEnd":2560150,"statementSha256":"42682b6c2fc42a8f9d11457ef3e9b55688ea66e7ccc4ae3e13063948693853af"},{"kind":"VariableDeclarator","bindings":["bat"],"start":2558593,"end":2560004,"sha256":"125966446f9365cbed7a3e288a8d428faa44233d61e7d4c1e6943c45b2d043fd","statementStart":2558439,"statementEnd":2560150,"statementSha256":"42682b6c2fc42a8f9d11457ef3e9b55688ea66e7ccc4ae3e13063948693853af"},{"kind":"VariableDeclarator","bindings":["Cat"],"start":2560005,"end":2560149,"sha256":"475d206317206fde85ac137c89b65113542f3e2198be142f12cc2dcce8a21e9a","statementStart":2558439,"statementEnd":2560150,"statementSha256":"42682b6c2fc42a8f9d11457ef3e9b55688ea66e7ccc4ae3e13063948693853af"},{"kind":"FunctionDeclaration","bindings":["n$"],"start":2560150,"end":2560249,"sha256":"29ec79c26e50c121c0b8f3877200f6b6c8c8d73ec936c3186c4347e380df0d7c","statementStart":2560150,"statementEnd":2560249,"statementSha256":"29ec79c26e50c121c0b8f3877200f6b6c8c8d73ec936c3186c4347e380df0d7c"},{"kind":"FunctionDeclaration","bindings":["GMn"],"start":2560249,"end":2560310,"sha256":"ee8020148b88d56358899b94c1a71d09aa8c3fc727095dd83ebf1ce9cfc1ee18","statementStart":2560249,"statementEnd":2560310,"statementSha256":"ee8020148b88d56358899b94c1a71d09aa8c3fc727095dd83ebf1ce9cfc1ee18"},{"kind":"FunctionDeclaration","bindings":["QMn"],"start":2560310,"end":2560446,"sha256":"bb2577503d83b3f5368e464c1574a3fd52df78bb7083c32061410173e89a0a34","statementStart":2560310,"statementEnd":2560446,"statementSha256":"bb2577503d83b3f5368e464c1574a3fd52df78bb7083c32061410173e89a0a34"},{"kind":"FunctionDeclaration","bindings":["gse"],"start":2560446,"end":2560594,"sha256":"af03ce003df86c2b323040a83b63bd9c786ccde49ed12ec121c8c75de570e9ec","statementStart":2560446,"statementEnd":2560594,"statementSha256":"af03ce003df86c2b323040a83b63bd9c786ccde49ed12ec121c8c75de570e9ec"},{"kind":"VariableDeclarator","bindings":["VMn"],"start":2560598,"end":2560916,"sha256":"bd2cf03a0aa30fe9f0c9bd6cd8ade887c60d5f4a1c4b388c54abd604823c39f0","statementStart":2560594,"statementEnd":2560917,"statementSha256":"99f07153e3cdfc22be8e0ca0c9dce34238dfcacbb794eff619f8055c603c33ec"},{"kind":"FunctionDeclaration","bindings":["zMn"],"start":2560917,"end":2560981,"sha256":"15f718dc96c31d8eec8bc9da7685995177e67feb152162d667781229a4a94525","statementStart":2560917,"statementEnd":2560981,"statementSha256":"15f718dc96c31d8eec8bc9da7685995177e67feb152162d667781229a4a94525"},{"kind":"FunctionDeclaration","bindings":["HMn"],"start":2560981,"end":2561161,"sha256":"0f09dc24acdbb3e177b73b62c975b1c77815da6215a5c2e34e2cba07c0043091","statementStart":2560981,"statementEnd":2561161,"statementSha256":"0f09dc24acdbb3e177b73b62c975b1c77815da6215a5c2e34e2cba07c0043091"},{"kind":"FunctionDeclaration","bindings":["jMn"],"start":2561161,"end":2561366,"sha256":"96a60114f3c19360784b2c84b7a2d48827d1fcd3153c8ce56453a1bf21d6061e","statementStart":2561161,"statementEnd":2561366,"statementSha256":"96a60114f3c19360784b2c84b7a2d48827d1fcd3153c8ce56453a1bf21d6061e"},{"kind":"FunctionDeclaration","bindings":["$Mn"],"start":2561366,"end":2561609,"sha256":"6f3eae4ae968de4842df06e63cdf3a1238a1e824fbf7c4e8bb71b0d6e1c28dd8","statementStart":2561366,"statementEnd":2561609,"statementSha256":"6f3eae4ae968de4842df06e63cdf3a1238a1e824fbf7c4e8bb71b0d6e1c28dd8"},{"kind":"FunctionDeclaration","bindings":["o$"],"start":2561609,"end":2562111,"sha256":"e37d0d316dc24270449bb57677d6fabb8ccb9401b3a0c9fd9aeec149629f7b31","statementStart":2561609,"statementEnd":2562111,"statementSha256":"e37d0d316dc24270449bb57677d6fabb8ccb9401b3a0c9fd9aeec149629f7b31"},{"kind":"VariableDeclarator","bindings":["qMn"],"start":2562115,"end":2562183,"sha256":"35c0f3b69ad4c9923a243a87eb600926611d2c529920493564c234af6be51280","statementStart":2562111,"statementEnd":2562376,"statementSha256":"83b9e018f0289792b9919eac19136e8bcd4f88728ba5f5b258a96da43f7c8862"},{"kind":"VariableDeclarator","bindings":["WMn"],"start":2562184,"end":2562285,"sha256":"1db7dc333d2917efcbc1eda202db4a95c8e1428ea254ef327641c74700077bae","statementStart":2562111,"statementEnd":2562376,"statementSha256":"83b9e018f0289792b9919eac19136e8bcd4f88728ba5f5b258a96da43f7c8862"},{"kind":"VariableDeclarator","bindings":["KMn"],"start":2562286,"end":2562293,"sha256":"ee5658e3ee847a70142a0216f774bda1fa79f058bd210bb6ad8cd6526c164c6b","statementStart":2562111,"statementEnd":2562376,"statementSha256":"83b9e018f0289792b9919eac19136e8bcd4f88728ba5f5b258a96da43f7c8862"},{"kind":"VariableDeclarator","bindings":["YMn"],"start":2562294,"end":2562300,"sha256":"3731ede748a096cca0d49d25b7a0a1ccadec7c0e8df31ff0096ad73bf7a77068","statementStart":2562111,"statementEnd":2562376,"statementSha256":"83b9e018f0289792b9919eac19136e8bcd4f88728ba5f5b258a96da43f7c8862"},{"kind":"VariableDeclarator","bindings":["JMn"],"start":2562307,"end":2562375,"sha256":"b154912ee4843e824ac814be3217827412fdea71327cec54b62fb4d2d3d76fd0","statementStart":2562111,"statementEnd":2562376,"statementSha256":"83b9e018f0289792b9919eac19136e8bcd4f88728ba5f5b258a96da43f7c8862"},{"kind":"FunctionDeclaration","bindings":["vat"],"start":2562376,"end":2562414,"sha256":"2dd68f825a614ef03024d0878098ee0cf6241c71803905b530559061101798ec","statementStart":2562376,"statementEnd":2562414,"statementSha256":"2dd68f825a614ef03024d0878098ee0cf6241c71803905b530559061101798ec"},{"kind":"FunctionDeclaration","bindings":["XMn"],"start":2562414,"end":2562538,"sha256":"6f2bb5a4f93d2eb1e2645f7ef6218396073f12558989e6cd0514bb9ba4d6d959","statementStart":2562414,"statementEnd":2562538,"statementSha256":"6f2bb5a4f93d2eb1e2645f7ef6218396073f12558989e6cd0514bb9ba4d6d959"},{"kind":"FunctionDeclaration","bindings":["ePn"],"start":2562538,"end":2562766,"sha256":"7ef9e98865364584f018c7915437f6e1e9e31baf0ca4c5c8e7f4670bd0f0e900","statementStart":2562538,"statementEnd":2562766,"statementSha256":"7ef9e98865364584f018c7915437f6e1e9e31baf0ca4c5c8e7f4670bd0f0e900"},{"kind":"FunctionDeclaration","bindings":["tPn"],"start":2562766,"end":2562932,"sha256":"c605720721b3fb217e4acaa4d66d59b6fd933fb07715747b8922499c181ddfae","statementStart":2562766,"statementEnd":2562932,"statementSha256":"c605720721b3fb217e4acaa4d66d59b6fd933fb07715747b8922499c181ddfae"},{"kind":"FunctionDeclaration","bindings":["nPn"],"start":2562932,"end":2563152,"sha256":"09bc4677f187f371ca80c94250268bfc5a350d92e967f246be8ede3913ac134c","statementStart":2562932,"statementEnd":2563152,"statementSha256":"09bc4677f187f371ca80c94250268bfc5a350d92e967f246be8ede3913ac134c"}]},"inputSha256":{"dist/renderer/assets/chunk-view-CuYU9NOh.js":"deb89a650b3e17225301344a6e0cbb348bcd65e3c209a3a8e10c77936eefc08d","dist/renderer/assets/chunk-vault-card-dialog-C8ioyi_k.js":"b20198a1d8012fdf0b376ab53bff14ab5525e3f3b6d3dce9a03aee1f06feaf17","dist/electron-main/main-app.cjs":"d1b9a5657a1ffe76fe12eeb7ede4d5c97171d83af0b7dda98233ec7de10fb483"}}// ../../../../../private/chunk-vault-card-dialog-C8ioyi_k.js +var J = /[\s-]/g; +var le = /^\d{13,19}$/; +function Y(e2) { + let t = e2.replace(J, ``); + if (!le.test(t)) return false; let n = 0; for (let e3 = 0; e3 < t.length; e3++) { let r = t.charCodeAt(t.length - 1 - e3) - 48; @@ -11,18 +11,18 @@ function re(e2) { } return n % 10 == 0; } -var oe = 200; -function se(e2) { +var mt = 200; +function ht(e2) { return String(e2 % 100).padStart(2, `0`); } -function ce(e2) { +function gt(e2) { if (e2.outcome !== `read`) return {}; let t = {}; - re(e2.number) && (t.cc_number = e2.number); + Y(e2.number) && (t.cc_number = e2.number); let n = e2.expYear > 0 && e2.expYear < 100 ? 2e3 + e2.expYear : e2.expYear; - Number.isInteger(e2.expMonth) && e2.expMonth >= 1 && e2.expMonth <= 12 && Number.isInteger(n) && n >= 2e3 && n <= 2099 && (t.cc_exp = `${se(e2.expMonth)}/${se(n)}`); + Number.isInteger(e2.expMonth) && e2.expMonth >= 1 && e2.expMonth <= 12 && Number.isInteger(n) && n >= 2e3 && n <= 2099 && (t.cc_exp = `${ht(e2.expMonth)}/${ht(n)}`); let r = e2.cardholderName.trim(); - r.length > 0 && r.length <= oe && !/\d/.test(r) && (t.cc_name = r); + r.length > 0 && r.length <= mt && !/\d/.test(r) && (t.cc_name = r); let i = e2.securityCode; if (t.cc_number !== void 0 && i !== void 0) { let e3 = t.cc_number.replace(/[\s-]/g, ``), n2 = /^3[47][0-9]{13}$/.test(e3) ? 4 : 3; @@ -75,15 +75,15 @@ function e(e2, t = {}) { } // ../../../../../private/view.mjs -var ie = 200; -var Z = 512; -var ae = 2e3; -var oe2 = 10; -var se2 = 2048; -var ce2 = 4096; -var le = `http://sn`; -var ue = /^NoteType:Credit Card$/; -function de(e2) { +var fe = 200; +var pe = 512; +var me = 2e3; +var he = 10; +var ge = 2048; +var _e = 4096; +var ve = `http://sn`; +var ye = /^NoteType:Credit Card$/; +function be(e2) { let t = /* @__PURE__ */ new Map(); return e2.forEach((e3, n) => { let r = e3.trim().toLowerCase(); @@ -96,7 +96,7 @@ function de(e2) { return ``; }, has: (...e3) => e3.every((e4) => t.has(e4)) }; } -function fe(e2) { +function xe(e2) { if (e2.has(`login_uri`, `login_username`, `login_password`)) return `bitwarden`; if (e2.has(`url`, `username`, `password`, `extra`, `name`, `grouping`)) return `lastpass`; if (e2.has(`url`, `username`, `password`) && (e2.has(`httprealm`) || e2.has(`formactionorigin`) || e2.has(`guid`))) return `firefox`; @@ -106,10 +106,10 @@ function fe(e2) { } return e2.has(`name`, `url`, `username`, `password`) ? `chrome` : null; } -function pe(e2, t = /\s+/) { +function Se(e2, t = /\s+/) { return e2.split(t).map((e3) => e3.trim()).filter((e3) => e3.length > 0); } -function me(e2) { +function Ce(e2) { let t = /* @__PURE__ */ new Map(), n = e2.split(/\r?\n/); for (let [e3, r] of n.entries()) { let i = r.indexOf(`:`); @@ -124,144 +124,144 @@ function me(e2) { } return t; } -function he(e2, t) { +function we(e2, t) { let n = t.get(e2, `url`).trim(), r = t.get(e2, `extra`), i = t.get(e2, `name`).trim(); - if (n !== le) return { kind: `login`, login: { title: i, username: t.get(e2, `username`), password: t.get(e2, `password`), notes: r, sites: pe(n) } }; - if (!ue.test(r.split(/\r?\n/)[0]?.trim() ?? ``)) return { kind: `other`, title: i }; - let a = me(r); + if (n !== ve) return { kind: `login`, login: { title: i, username: t.get(e2, `username`), password: t.get(e2, `password`), notes: r, sites: Se(n) } }; + if (!ye.test(r.split(/\r?\n/)[0]?.trim() ?? ``)) return { kind: `other`, title: i }; + let a = Ce(r); return { kind: `card`, card: { title: i, brand: a.get(`Type`) ?? ``, number: a.get(`Number`) ?? ``, expiry: a.get(`Expiration Date`) ?? ``, csc: a.get(`Security Code`) ?? ``, holderName: a.get(`Name on Card`) ?? `` } }; } -function ge(e2, t, n) { +function Te(e2, t, n) { let r = (...e3) => n.get(t, ...e3); switch (e2) { case `bitwarden`: { let e3 = r(`type`).trim().toLowerCase(); - return e3 !== `` && e3 !== `login` ? { kind: `other`, title: r(`name`).trim() } : { kind: `login`, login: { title: r(`name`).trim(), username: r(`login_username`), password: r(`login_password`), notes: r(`notes`), sites: pe(r(`login_uri`), /[\s,]+/) } }; + return e3 !== `` && e3 !== `login` ? { kind: `other`, title: r(`name`).trim() } : { kind: `login`, login: { title: r(`name`).trim(), username: r(`login_username`), password: r(`login_password`), notes: r(`notes`), sites: Se(r(`login_uri`), /[\s,]+/) } }; } case `lastpass`: - return he(t, n); + return we(t, n); case `firefox`: - return r(`url`).startsWith(`chrome://`) ? { kind: `other`, title: r(`url`) } : { kind: `login`, login: { title: ``, username: r(`username`), password: r(`password`), notes: ``, sites: pe(r(`url`)) } }; + return r(`url`).startsWith(`chrome://`) ? { kind: `other`, title: r(`url`) } : { kind: `login`, login: { title: ``, username: r(`username`), password: r(`password`), notes: ``, sites: Se(r(`url`)) } }; case `chrome`: - return { kind: `login`, login: { title: r(`name`).trim(), username: r(`username`), password: r(`password`), notes: r(`note`, `notes`), sites: pe(r(`url`)) } }; + return { kind: `login`, login: { title: r(`name`).trim(), username: r(`username`), password: r(`password`), notes: r(`note`, `notes`), sites: Se(r(`url`)) } }; case `1password`: case `safari`: - return { kind: `login`, login: { title: r(`title`).trim(), username: r(`username`), password: r(`password`), notes: r(`notes`), sites: pe(r(`url`)) } }; + return { kind: `login`, login: { title: r(`title`).trim(), username: r(`username`), password: r(`password`), notes: r(`notes`), sites: Se(r(`url`)) } }; default: return e2; } } -function _e(e2) { +function Ee(e2) { let t = e2.includes(`://`) ? e2 : `https://${e2}`, n = URL.parse(t); - return n === null || n.hostname.length === 0 ? `invalid-website` : n.protocol === `http:` ? `insecure-website` : n.protocol === `https:` ? t.length > se2 ? `too-long` : { site: t, host: ve(n.hostname) } : `invalid-website`; + return n === null || n.hostname.length === 0 ? `invalid-website` : n.protocol === `http:` ? `insecure-website` : n.protocol === `https:` ? t.length > ge ? `too-long` : { site: t, host: De(n.hostname) } : `invalid-website`; } -function ve(e2) { +function De(e2) { return e2.toLowerCase().replace(/^www\./, ``); } -function ye(e2) { +function Oe(e2) { let t = URL.parse(e2.includes(`://`) ? e2 : `https://${e2}`)?.hostname; - return t === void 0 || t.length === 0 ? null : ve(t); + return t === void 0 || t.length === 0 ? null : De(t); } -function be({ host: e2, username: t }) { +function ke({ host: e2, username: t }) { return `${e2} ${t.trim().toLowerCase()}`; } -function xe({ last4: e2, month: t, year: n }) { +function Ae({ last4: e2, month: t, year: n }) { return `${e2} ${t} ${n}`; } -function Se(e2) { +function je(e2) { let t = /^([a-z][a-z0-9+.-]*):\/\//i.exec(e2)?.[1]; return t !== void 0 && !/^https?$/i.test(t); } -var Ce = [`january`, `february`, `march`, `april`, `may`, `june`, `july`, `august`, `september`, `october`, `november`, `december`]; -function we(e2) { +var Me = [`january`, `february`, `march`, `april`, `may`, `june`, `july`, `august`, `september`, `october`, `november`, `december`]; +function Ne(e2) { let t = e2.trim().toLowerCase(); if (/^\d{1,2}$/.test(t)) { let e3 = Number(t); return e3 >= 1 && e3 <= 12 ? e3 : null; } if (t.length < 3) return null; - let n = Ce.findIndex((e3) => e3.startsWith(t)); + let n = Me.findIndex((e3) => e3.startsWith(t)); return n === -1 ? null : n + 1; } -function Te(e2) { +function Pe(e2) { let t = e2.trim(); return /^\d{2}$/.test(t) ? 2e3 + Number(t) : /^\d{4}$/.test(t) ? Number(t) : null; } -function Ee(e2) { +function Fe(e2) { let t = e2.trim(), n = /^(\d{4})-(\d{1,2})$/.exec(t), r = n === null ? t.split(/\s*[,/\-\s]\s*/) : [n[2], n[1]]; if (r.length !== 2) return null; - let i = we(r[0] ?? ``), a = Te(r[1] ?? ``); + let i = Ne(r[0] ?? ``), a = Pe(r[1] ?? ``); return i === null || a === null ? null : { month: i, year: a }; } -function De(e2) { +function Ie(e2) { return `${String(e2.month).padStart(2, `0`)}/${String(e2.year % 100).padStart(2, `0`)}`; } -function Oe(e2) { - return e2.title.length > ie || e2.username.trim().length > Z || e2.notes.trim().length > ae || e2.sites.length > oe2 || new TextEncoder().encode(e2.password).length > ce2; +function Le(e2) { + return e2.title.length > fe || e2.username.trim().length > pe || e2.notes.trim().length > me || e2.sites.length > he || new TextEncoder().encode(e2.password).length > _e; } -function ke(e2, t, n) { - let r = { ...t, sites: t.sites.filter((e3) => !Se(e3)) }, i = r.sites.map(_e), a = i.find((e3) => typeof e3 != `string`)?.host, o = r.title.length > 0 ? r.title : a ?? ``, s = r.username.trim(), c = (n2) => ({ row: e2, kind: `login`, primary: o.length > 0 ? o : t.sites[0] ?? ``, secondary: s, status: n2 }), l = (e3) => ({ preview: c({ kind: `invalid`, problem: e3 }), item: null }); +function Re(e2, t, n) { + let r = { ...t, sites: t.sites.filter((e3) => !je(e3)) }, i = r.sites.map(Ee), a = i.find((e3) => typeof e3 != `string`)?.host, o = r.title.length > 0 ? r.title : a ?? ``, s = r.username.trim(), c = (n2) => ({ row: e2, kind: `login`, primary: o.length > 0 ? o : t.sites[0] ?? ``, secondary: s, status: n2 }), l = (e3) => ({ preview: c({ kind: `invalid`, problem: e3 }), item: null }); if (t.sites.length === 0) return l(`missing-website`); if (r.sites.length === 0) return l(`invalid-website`); let u = i.find((e3) => typeof e3 == `string`); if (u !== void 0) return l(u); if (r.password.length === 0) return l(`missing-password`); - if (Oe({ ...r, title: o })) return l(`too-long`); - let d = i.flatMap((e3) => typeof e3 == `string` ? [] : [e3]), f = d.map(({ host: e3 }) => be({ host: e3, username: s })); + if (Le({ ...r, title: o })) return l(`too-long`); + let d = i.flatMap((e3) => typeof e3 == `string` ? [] : [e3]), f = d.map(({ host: e3 }) => ke({ host: e3, username: s })); if (f.some((e3) => n.loginKeys.has(e3))) return { preview: c({ kind: `duplicate` }), item: null }; for (let e3 of f) n.loginKeys.add(e3); return { preview: c({ kind: `ready` }), item: { kind: `login`, login: { id: ``, title: o, username: s, notes: r.notes.replace(/\r\n?/g, ` `).trim(), sites: d.map(({ site: e3 }) => e3), password: r.password } } }; } -function Ae(e2, t, n) { - let r = t.number.replace(/[\s-]/g, ``), i = r.slice(-4), a = t.brand.trim(), o = Ee(t.expiry), s = t.holderName.trim(), c = (n2) => ({ row: e2, kind: `card`, primary: i.length === 4 ? `${a} \u2022\u2022\u2022\u2022 ${i}`.trim() : t.title, secondary: [s, o === null ? `` : De(o)].filter((e3) => e3.length > 0).join(` \xB7 `), status: n2 }), l = (e3) => ({ preview: c({ kind: `invalid`, problem: e3 }), item: null }); +function ze(e2, t, n) { + let r = t.number.replace(/[\s-]/g, ``), i = r.slice(-4), a = t.brand.trim(), o = Fe(t.expiry), s = t.holderName.trim(), c = (n2) => ({ row: e2, kind: `card`, primary: i.length === 4 ? `${a} \u2022\u2022\u2022\u2022 ${i}`.trim() : t.title, secondary: [s, o === null ? `` : Ie(o)].filter((e3) => e3.length > 0).join(` \xB7 `), status: n2 }), l = (e3) => ({ preview: c({ kind: `invalid`, problem: e3 }), item: null }); if (!n.cardsEnabled) return { preview: c({ kind: `skipped`, reason: `cards-off` }), item: null }; - if (!re(r)) return l(`invalid-card-number`); + if (!Y(r)) return l(`invalid-card-number`); if (o === null) return l(`invalid-expiry`); let u = n.now.getFullYear() * 12 + n.now.getMonth(); if (o.year * 12 + o.month - 1 < u) return l(`expired-card`); let d = t.csc.trim(); if (d.length > 0 && !/^\d{3,4}$/.test(d)) return l(`invalid-security-code`); - if (s.length > ie) return l(`too-long`); - let f = xe({ last4: i, month: o.month, year: o.year }); + if (s.length > fe) return l(`too-long`); + let f = Ae({ last4: i, month: o.month, year: o.year }); if (n.cardKeys.has(f)) return { preview: c({ kind: `duplicate` }), item: null }; n.cardKeys.add(f); - let p = { cc_number: r, cc_exp: De(o) }; + let p = { cc_number: r, cc_exp: Ie(o) }; return d.length > 0 && (p.cc_csc = d), s.length > 0 && (p.cc_name = s), { preview: c({ kind: `ready` }), item: { kind: `card`, card: { values: p } } }; } -function je(e2) { +function Be(e2) { let t = /* @__PURE__ */ new Set(), n = /* @__PURE__ */ new Set(); for (let r of e2) { if (r.card !== void 0) { let { last4: e3, expMonth: t2, expYear: i } = r.card; - n.add(xe({ last4: e3, month: t2, year: i < 100 ? 2e3 + i : i })); + n.add(Ae({ last4: e3, month: t2, year: i < 100 ? 2e3 + i : i })); continue; } for (let e3 of r.sites) { - let n2 = ye(e3); - n2 !== null && t.add(be({ host: n2, username: r.username })); + let n2 = Oe(e3); + n2 !== null && t.add(ke({ host: n2, username: r.username })); } } return { loginKeys: t, cardKeys: n }; } -function Me({ text: e2, existing: t, cardsEnabled: n, now: r }) { +function Ve({ text: e2, existing: t, cardsEnabled: n, now: r }) { let [i, ...a] = e(e2.replace(/^\uFEFF/, ``)); if (i === void 0) return { kind: `unrecognized` }; - let o = de(i), s = fe(o); + let o = be(i), s = xe(o); if (s === null) return { kind: `unrecognized` }; - let c = { cardsEnabled: n, now: r, ...je(t) }, l = []; + let c = { cardsEnabled: n, now: r, ...Be(t) }, l = []; for (let [e3, t2] of a.entries()) { if (t2.every((e4) => e4.trim().length === 0)) continue; - let n2 = e3 + 1, r2 = ge(s, t2, o); + let n2 = e3 + 1, r2 = Te(s, t2, o); switch (r2.kind) { case `login`: - l.push(ke(n2, r2.login, c)); + l.push(Re(n2, r2.login, c)); break; case `card`: - l.push(Ae(n2, r2.card, c)); + l.push(ze(n2, r2.card, c)); break; case `other`: l.push({ preview: { row: n2, kind: `other`, primary: r2.title, secondary: ``, status: { kind: `skipped`, reason: `unsupported-item` } }, item: null }); @@ -274,13 +274,13 @@ function Me({ text: e2, existing: t, cardsEnabled: n, now: r }) { } // ../../../../../private/main.mjs -var dMn = [{ brand: "amex", prefix: /^3[47]/, lengths: [15], standardLength: 15 }, { brand: "visa", prefix: /^4/, lengths: [13, 16, 19], standardLength: 16 }, { brand: "mastercard", prefix: /^(?:5[1-5]|222[1-9]|22[3-9]\d|2[3-6]\d\d|27[01]\d|2720)/, lengths: [16], standardLength: 16 }, { brand: "discover", prefix: /^(?:6011|65|64[4-9])/, lengths: [16, 17, 18, 19], standardLength: 16 }, { brand: "jcb", prefix: /^35(?:2[89]|[3-8]\d)/, lengths: [16, 17, 18, 19], standardLength: 16 }, { brand: "diners", prefix: /^3(?:0[0-5]|[689])/, lengths: [14, 15, 16, 17, 18, 19], standardLength: 14 }]; -function jse(e2) { +var mMn = [{ brand: "amex", prefix: /^3[47]/, lengths: [15], standardLength: 15 }, { brand: "visa", prefix: /^4/, lengths: [13, 16, 19], standardLength: 16 }, { brand: "mastercard", prefix: /^(?:5[1-5]|222[1-9]|22[3-9]\d|2[3-6]\d\d|27[01]\d|2720)/, lengths: [16], standardLength: 16 }, { brand: "discover", prefix: /^(?:6011|65|64[4-9])/, lengths: [16, 17, 18, 19], standardLength: 16 }, { brand: "jcb", prefix: /^35(?:2[89]|[3-8]\d)/, lengths: [16, 17, 18, 19], standardLength: 16 }, { brand: "diners", prefix: /^3(?:0[0-5]|[689])/, lengths: [14, 15, 16, 17, 18, 19], standardLength: 14 }]; +function yse(e2) { if (!/^\d+$/.test(e2)) return null; - for (let t of dMn) if (t.prefix.test(e2) && t.lengths.includes(e2.length)) return t; + for (let t of mMn) if (t.prefix.test(e2) && t.lengths.includes(e2.length)) return t; return null; } -function dat(e2) { +function Aat(e2) { if (!/^\d{13,19}$/.test(e2)) return false; let t = 0; for (let n = 0; n < e2.length; n++) { @@ -289,335 +289,411 @@ function dat(e2) { } return t % 10 === 0; } -function zse(e2) { - return jse(e2)?.brand ?? null; +function r$(e2) { + return yse(e2)?.brand ?? null; } -function cMn({ securityCode: e2, number: t }) { - let n = zse(t); +function fMn({ securityCode: e2, number: t }) { + let n = r$(t); return n === null ? false : (n === "amex" ? /^\d{4}$/ : /^\d{3}$/).test(e2); } -var rat = { O: "0", o: "0", D: "0", Q: "0", I: "1", l: "1", "|": "1", Z: "2", z: "2", S: "5", B: "8" }; -function uMn(e2) { +var uat = { O: "0", o: "0", D: "0", Q: "0", I: "1", l: "1", "|": "1", Z: "2", z: "2", S: "5", B: "8" }; +function gMn(e2) { let t = 0; for (let n of e2) if (n >= "0" && n <= "9") t++; - else if (n !== "/" && rat[n] === void 0) return e2; - return t < 2 ? e2 : Array.from(e2, (n) => rat[n] ?? n).join(""); + else if (n !== "/" && uat[n] === void 0) return e2; + return t < 2 ? e2 : Array.from(e2, (n) => uat[n] ?? n).join(""); } -function ch(e2) { - return e2.split(/(\s+)/).map((t) => /^\s+$/.test(t) ? t : uMn(t)).join(""); +function Im(e2) { + return e2.split(/(\s+)/).map((t) => /^\s+$/.test(t) ? t : gMn(t)).join(""); } -function D$(e2) { - return zse(e2) !== null && dat(e2); +function Xj(e2) { + return r$(e2) !== null && Aat(e2); } -function oat({ digits: e2, wholeGroups: t }) { - let n = jse(e2)?.standardLength === e2.length; +function pat({ digits: e2, wholeGroups: t }) { + let n = yse(e2)?.standardLength === e2.length; return (t ? 200 : 0) + (n ? 100 : 0) + e2.length; } -function pMn(e2) { +function yMn(e2) { let t = []; for (let o = 0; o < e2.length; o++) { let r = "", a = true; for (let i = o; i < e2.length; i++) { let s = e2[i] ?? ""; if (r += s, a &&= s.length >= 4, r.length > 19) break; - D$(r) && t.push({ digits: r, wholeGroups: a }); + Xj(r) && t.push({ digits: r, wholeGroups: a }); } } let [n] = e2; if (e2.length === 1 && n !== void 0 && n.length > 13) for (let o = 13; o < n.length; o++) { let r = n.slice(0, o); - D$(r) && t.push({ digits: r, wholeGroups: true }); + Xj(r) && t.push({ digits: r, wholeGroups: true }); } return t; } -function mMn(e2) { +function AMn(e2) { let t = []; - for (let n of ch(e2).match(/\d+(?:[ \-.]\d+)*/g) ?? []) { - let o = n.split(/[ \-.]/), r = pMn(o), a = o.length === 1 ? o[0] : void 0; - if (a !== void 0 && r.length > 1 && jse(a)?.standardLength !== a.length) { + for (let n of Im(e2).match(/\d+(?:[ \-.]\d+)*/g) ?? []) { + let o = n.split(/[ \-.]/), r = yMn(o), a = o.length === 1 ? o[0] : void 0; + if (a !== void 0 && r.length > 1 && yse(a)?.standardLength !== a.length) { t.push(...r.map(({ digits: s }) => s)); continue; } let i = null; - for (let s of r) (i === null || oat(s) > oat(i)) && (i = s); + for (let s of r) (i === null || pat(s) > pat(i)) && (i = s); i !== null && t.push(i.digits); } return t; } -function fMn(e2) { +function hMn(e2) { let t = [], n = null; for (let o of e2) { - let r = mMn(o); - r.length !== 0 && (ch(o) === o ? t.push(...r) : n ??= r); + let r = AMn(o); + r.length !== 0 && (Im(o) === o ? t.push(...r) : n ??= r); } return t.length > 0 ? t : n ?? []; } -function B$(e2, t) { +function e$(e2, t) { let [n = "", ...o] = e2.map((r) => t(r.trim())); return o.some((r) => r !== "" && r !== n); } -function $l(e2) { +function Ao(e2) { return (e2[0] ?? "").trim(); } -function aat(e2) { - let t = ch($l(e2)); +function mat(e2) { + let t = Im(Ao(e2)); return /^\d+(?:\s+\d+)*$/.test(t) ? t.split(/\s+/) : null; } -function gMn(e2, t, n) { +function SMn(e2, t, n) { let o = [], r = () => { - let a = o.flatMap((s) => aat(s) ?? []), i = a.join(""); - if (o.length >= 2 && a.map((s) => s.length).join() === "4,8,4" && D$(i)) { + let a = o.flatMap((s) => mat(s) ?? []), i = a.join(""); + if (o.length >= 2 && a.map((s) => s.length).join() === "4,8,4" && Xj(i)) { t.add(i); for (let s of o) n.add(s); } o = []; }; - for (let a of e2) aat(a) === null ? r() : o.push(a); + for (let a of e2) mat(a) === null ? r() : o.push(a); r(); } -function yMn(e2, t) { - let n = /* @__PURE__ */ new Set(), o = /* @__PURE__ */ new Set(); - for (let a of e2) { - for (let i of a) { - let s = fMn(i); - for (let d of s) n.add(d); - s.length > 0 && o.add(i); +function _Mn(e2, t) { + let n = /* @__PURE__ */ new Set(), o = /* @__PURE__ */ new Set(), r = [], a = (s, d) => { + let c = r.find((u) => s.some((f) => u.lines.has(f))); + if (c === void 0) r.push({ lines: new Set(s), numbers: new Set(d) }); + else { + for (let u of s) c.lines.add(u); + for (let u of d) c.numbers.add(u); + } + }; + for (let s of e2) { + for (let d of s) { + let c = hMn(d); + for (let u of c) n.add(u); + c.length > 0 && (o.add(d), a([d], c)); } - for (let i = 0; i < a.length; i++) { - let s = "", d = 0; - for (let c = i; c < a.length; c++) { - let u = a[c], f = u === void 0 ? [] : ch($l(u)).split(/\s+/); - if (!f.every((g) => /^\d{4,6}$/.test(g)) || (s += f.join(""), d += f.length, s.length > 19)) break; - if (!(c === i || d < 3 || !D$(s))) { - n.add(s); - for (let g of a.slice(i, c + 1)) o.add(g); + for (let d = 0; d < s.length; d++) { + let c = "", u = 0; + for (let f = d; f < s.length; f++) { + let y = s[f], A = y === void 0 ? [] : Im(Ao(y)).split(/\s+/); + if (!A.every((_) => /^\d{4,6}$/.test(_)) || (c += A.join(""), u += A.length, c.length > 19)) break; + if (!(f === d || u < 3 || !Xj(c))) { + n.add(c); + for (let _ of s.slice(d, f + 1)) o.add(_); + a(s.slice(d, f + 1), [c]); break; } } } } - if (n.size === 0) for (let a of t.flat()) gMn(a, n, o); - let [r] = n; - return { number: n.size === 1 && r !== void 0 ? r : null, usedLines: o }; + if (n.size === 0) for (let s of t.flat()) SMn(s, n, o); + let [i] = n; + return { number: n.size === 1 && i !== void 0 ? i : null, differentCards: r.some((s) => r.some((d) => s !== d && [...s.numbers].every((c) => !d.numbers.has(c)))), usedLines: o }; } -function N$(e2, t) { +function t$(e2, t) { let n = []; - for (let o of e2) o.forEach((r, a) => { - let i = $l(r), s = t.exec(i); - if (s === null) return; - let d = i.slice(s.index + s[0].length).replace(/^[\s:.#-]+/, "").trim(); - if (d.length > 0) { - n.push({ value: d, line: r }); - return; - } - let c = o[a + 1]; - c !== void 0 && n.push({ value: $l(c), line: c }); - }); - return n; -} -var hMn = /(? { + o.forEach((a, i) => { + let s = Ao(a), d = t.exec(s); + if (d === null) return; + let c = s.slice(d.index + d[0].length).replace(/^[\s:.#-]+/, "").trim(); + if (c.length > 0) { + n.push({ value: c, line: a, photo: r }); + return; + } + let u = o[i + 1]; + u !== void 0 && n.push({ value: Ao(u), line: u, photo: r }); + }); + }), n; +} +var EMn = /(?= 2e3 && a <= AMn && t.push({ month: o, year: a }); + a >= 2e3 && a <= vMn && t.push({ month: o, year: a }); } return t; } -function iat(e2) { - return aM(e2).map(({ month: t, year: n }) => `${t}/${n}`).join(" "); +function fat(e2) { + return km(e2).map(({ month: t, year: n }) => `${t}/${n}`).join(" "); } -function Vse(e2) { +function Jj(e2) { let t = null; for (let n of e2) (t === null || n.year * 12 + n.month > t.year * 12 + t.month) && (t = n); return t; } -function _Mn(e2, t) { +function kMn(e2, t) { let n = /* @__PURE__ */ new Set(), o = /* @__PURE__ */ new Set(); for (let r of e2) r.forEach((a, i) => { - let s = $l(a); - if (!$se.test(s)) return; + let s = Ao(a); + if (!Ase.test(s)) return; n.add(a); let d = r[i + 1]; - if (d === void 0 || aM(s).length > 0) return; - let c = $l(d); - if (t.has(d) || cat.test(c)) { + if (d === void 0 || km(s).length > 0) return; + let c = Ao(d); + if (t.has(d) || By.test(c)) { o.add(d); let u = r[i + 2]; - u !== void 0 && aM(c).length === 0 && o.add(u); + u !== void 0 && km(c).length === 0 && o.add(u); } else n.add(d); }); return { skipped: n, contested: o }; } -function SMn(e2) { +function IMn(e2) { return e2.every(({ month: t, year: n }) => t === e2[0]?.month && n === e2[0]?.year); } -function bMn(e2, t) { - let n = new Set(N$(e2, Qse).map(({ line: c }) => c)), { skipped: o, contested: r } = _Mn(e2, t), a = N$(e2, cat).flatMap(({ value: c, line: u }) => o.has(u) || r.has(u) || B$(u, iat) ? [] : aM(c.split(Qse)[0] ?? "")); - if (a.length > 0) return Vse(a); +function TMn(e2, t) { + let n = new Set(t$(e2, Cw).map(({ line: c }) => c)), { skipped: o, contested: r } = kMn(e2, t), a = t$(e2, By).flatMap(({ value: c, line: u }) => o.has(u) || r.has(u) || e$(u, fat) ? [] : km(c.split(Cw)[0] ?? "")); + if (a.length > 0) return Jj(a); let i = [], s = []; - for (let c of e2) for (let u of c) n.has(u) || o.has(u) || Qse.test($l(u)) || B$(u, iat) || (r.has(u) ? s : i).push(...aM($l(u))); - if (s.length === 0) return Vse(i); + for (let c of e2) for (let u of c) n.has(u) || o.has(u) || Cw.test(Ao(u)) || e$(u, fat) || (r.has(u) ? s : i).push(...km(Ao(u))); + if (s.length === 0) return Jj(i); let d = [...i, ...s]; - return SMn(d) ? Vse(d) : null; + return IMn(d) ? Jj(d) : null; } -var sat = /\b(?:cvv2?|cvc2?|cid|csc|security\s+code|verification\s+(?:code|number|value)|card\s+code)\b/i; -function uv(e2) { +var fse = /\b(?:cvv2?|cvc2?|cid|csc|security\s+code|verification\s+(?:code|number|value)|card\s+code)\b|^(?:cw2?|cve)\b(?=[\s:#.-]*(?:\d{3,4}\s*)?$)/i; +function vw(e2) { let t = new Set(e2), [n] = t; return t.size === 1 && n !== void 0 ? n : null; } -function lat(e2) { - return (ch(e2).match(/\d+/g) ?? []).join(""); +function gat(e2) { + return (Im(e2).match(/\d+/g) ?? []).join(""); } -function EMn(e2, t) { +function RMn(e2, t) { let n = /^(\d{4})\s+(\d{3,4})(?!\d)/.exec(e2); if (n?.[1] === t && n[2] !== void 0) return [n[2]]; let o = /^(\d{3,4})(?!\d)/.exec(e2); return o?.[1] === void 0 ? [] : [o[1]]; } -function vMn({ photos: e2, number: t, usedLines: n }) { - let o = (y) => cMn({ securityCode: y, number: t }), r = t.slice(-4), a = [], s = N$(e2, sat).flatMap(({ value: y, line: S }) => { - if (B$(S, lat)) return []; - let b = EMn(y, r); - return sat.test($l(S)) ? b : (a.push(...b), []); - }).filter(o); - if (s.length > 0) return uv(s); - let d = [], c = [], u = new RegExp(`${t.replace(/\d/g, "$&[ -]?")}\\s+(\\d{3,4})$`); - for (let y of e2) for (let S of y) { - if (B$(S, lat)) continue; - let b = ch($l(S)); - if (n.has(S)) { - let C = u.exec(b)?.[1]; - C !== void 0 && d.push(C); - continue; - } - let v = /^(\d{4})\s+(\d{3,4})$/.exec(b); - v?.[1] === r && v[2] !== void 0 ? d.push(v[2]) : /^\d{3,4}$/.test(b) && c.push(b); +var hat = /(? { + let n = Ao(t); + return [...n.matchAll(hat)].flatMap((o) => wMn.test(n.slice(Math.max(0, o.index - 32), o.index)) ? [o[0]] : []); + }); +} +function hse(e2, t) { + return [...e2.matchAll(hat)].some((n) => n[0] === t && !/\d[\s.,-]?$/.test(e2.slice(0, n.index)) && !/^[.,]?\d/.test(e2.slice(n.index + 4))); +} +var MMn = /\b(?:checking|savings|account|acct|available|balance)\b/i; +function _at(e2) { + let t = e2.map(Ao); + return t.some((n) => MMn.test(n)) && !t.some((n) => fse.test(n) || By.test(n)); +} +function Eat(e2, t, n, { bankAccounts: o }) { + let r = /* @__PURE__ */ new Set(); + return e2.forEach((a, i) => { + let s = Sat(a); + s.length > 0 && !a.some((d) => n.has(d) || hse(Ao(d), t)) && !s.includes(t) && (o || !_at(a)) && r.add(i); + }), r; +} +function PMn(e2, t) { + return e2.map((n) => { + let o = n.map(Ao), r = n.some((d) => t.has(d)), a = o.filter((d) => !Cw.test(d)).flatMap(km), i = o.flatMap((d, c) => By.test(d) || By.test(o[c - 1] ?? "") ? km(d) : []), s = o.some((d) => By.test(d)); + return { texts: o, masked: Sat(n), showsNumber: r, expiries: a, cardExpiries: s ? i : r && !_at(n) ? o.filter((d) => CMn.test(d)).flatMap(km) : [] }; + }); +} +function xMn({ texts: e2, masked: t, showsNumber: n }, o) { + return n || t.includes(o) || e2.some((r) => hse(r, o)); +} +function OMn(e2, t) { + return new Set(e2.flatMap((o) => { + if (!(o.showsNumber || o.masked.includes(t))) return []; + let r = Jj(o.cardExpiries); + return r === null ? [] : [`${r.month}/${r.year}`]; + })).size > 1; +} +function DMn(e2, t, n, o, r) { + let a = ({ month: u, year: f }) => o !== null && u === o.month && f === o.year, i = e2.some(({ showsNumber: u, expiries: f }) => u && f.some(a)), s = Eat(t, n, r, { bankAccounts: false }), d = /* @__PURE__ */ new Set(); + e2.forEach(({ showsNumber: u, expiries: f }, y) => { + o !== null && f.length > 0 && !f.some(a) && (!u || i) && d.add(y); + }); + let c = /* @__PURE__ */ new Set(); + return s.size > 0 && e2.forEach((u, f) => { + !s.has(f) && !d.has(f) && !xMn(u, n) && c.add(f); + }), { skipped: /* @__PURE__ */ new Set([...s, ...d, ...c]) }; +} +function BMn({ photos: e2, number: t, expiry: n, usedLines: o }) { + let r = t.slice(-4), a = PMn(e2, o); + if (OMn(a, r)) return null; + let { skipped: i } = DMn(a, e2, r, n, o), s = yat({ photos: e2, number: t, usedLines: o, otherCards: i }); + return i.size === 0 || yat({ photos: e2, number: t, usedLines: o, otherCards: /* @__PURE__ */ new Set() }) === s ? s : null; +} +function yat({ photos: e2, number: t, usedLines: n, otherCards: o }) { + let r = (w) => fMn({ securityCode: w, number: t }), a = t.slice(-4), i = [], s = /* @__PURE__ */ new Set(); + for (let { value: w, line: M, photo: B } of t$(e2, fse)) { + if (o.has(B) || e$(M, gat)) continue; + let F = !fse.test(Ao(M)); + F && !new RegExp(`^(?:${a}\\s+)?\\d{3,4}[.,;:]?$`).test(w.trim()) || (s.add(M), i.push(...RMn(w, a).map((D) => ({ code: D, photo: B, underLabel: F })))); + } + let d = r$(t) === "amex", c = [], u = [], f = new RegExp(`${t.replace(/\d/g, "$&[ -]?")}\\s+(\\d{3,4})$`), y = /* @__PURE__ */ new Set(), A = /* @__PURE__ */ new Set(), _ = /* @__PURE__ */ new Set(); + e2.forEach((w, M) => { + if (o.has(M)) return; + let B = w.some((O) => n.has(O)); + B && A.add(M), (B || w.some((O) => hse(Ao(O), a))) && _.add(M); + let F = w.length > 0 && w.every((O) => /^\d{3,4}$/.test(Im(Ao(O)))); + !B && !w.some((O) => s.has(O)) && y.add(M), w.forEach((O, L) => { + if (e$(O, gat)) return; + let N = Im(Ao(O)); + if (n.has(O)) { + let H = f.exec(N)?.[1]; + H !== void 0 && c.push({ code: H, photo: M }); + return; + } + let q = /^(\d{4})\s+(\d{3,4})$/.exec(N); + if (q?.[1] === a && q[2] !== void 0) c.push({ code: q[2], photo: M }); + else if (/^\d{3,4}$/.test(N) && (B || F || !d) && !s.has(O)) { + let H = w.slice(Math.max(0, L - 2), L).some((X) => { + let te = Ao(X); + return Cw.test(te) || By.test(te); + }); + if (bMn.test(N) && H) return; + u.push({ code: N, photo: M }); + } + }); + }); + let E = (w) => w.map(({ code: M }) => M).filter(r), b = i.filter(({ code: w }) => r(w)); + if (b.length > 0) { + let w = new Set(b.filter(({ underLabel: F }) => F).map(({ photo: F }) => F)), M = b.some(({ photo: F }) => !_.has(F)), B = u.filter(({ photo: F }) => d || y.has(F) || w.has(F) || M && A.has(F)); + return vw(E([...b, ...c, ...B])); } - let f = a.filter(o); - if (f.length > 0) return uv([...f, ...d, ...c].filter(o)); - let g = d.filter(o); - return uv(g.length > 0 ? g : c.filter(o)); -} -var CMn = /\b(?:card\s*holder(?:\s+name)?|name\s+on\s+card)\b/i; -var kMn = /^[\p{L}][\p{L}.'\- ]*$/u; -var IMn = 60; -var TMn = 26; -var uat = /* @__PURE__ */ new Set(["ACCOUNT", "AGREEMENT", "ALTERED", "ANNUAL", "BALANCE", "BEND", "CALL", "CARDMEMBER", "CLUB", "DINERS", "DUE", "FEE", "FOREIGN", "FOUND", "FREE", "HERE", "IF", "LOST", "MINIMUM", "NOT", "OR", "PASS", "PAYMENT", "PLEASE", "PRIORITY", "REVERSE", "SEE", "SIGN", "STOLEN", "THANK", "TOLL", "TRANSACTION", "TRANSFER", "TRANSFERABLE", "US", "VOID", "YOU", "YOUR", "ALLY", "AMERICA", "AMERICAN", "AMEX", "APPLE", "AUTHORIZED", "BACK", "BANK", "BANKING", "BARCLAYS", "BILT", "BUSINESS", "CAPITAL", "CARD", "CARDHOLDER", "CASH", "CASHBACK", "CHASE", "CHIME", "CHIP", "CITI", "CITIBANK", "CITIZENS", "CLASSIC", "CODE", "CONTACTLESS", "CORPORATE", "CREDIT", "CUSTOMER", "DATE", "DEBIT", "DISCOVER", "ELECTRONIC", "ELITE", "EXP", "EXPIRES", "EXPIRY", "EXPRESS", "FARGO", "FEDERAL", "FINANCIAL", "FIRST", "FREEDOM", "FROM", "GOLDMAN", "GOOD", "HSBC", "INFINITE", "INTERNATIONAL", "MASTER", "MASTERCARD", "MEMBER", "MILES", "MONZO", "MORGAN", "NAME", "NATIONAL", "NAVY", "NUMBER", "ONLY", "PAY", "PLATINUM", "PLUS", "POINTS", "PREFERRED", "PREMIER", "RESERVE", "REVOLUT", "REWARDS", "SACHS", "SANTANDER", "SAPPHIRE", "SAVINGS", "SECURED", "SECURITY", "SERVICE", "SIGNATURE", "SINCE", "STANDARD", "STUDENT", "SYNCHRONY", "THROUGH", "THRU", "TRAVEL", "TRUST", "UNION", "UNLIMITED", "USAA", "USE", "VALID", "VENTURE", "VERIFICATION", "VISA", "WELLS", "WORLD", "CIRRUS", "ELECTRON", "EMV", "END", "INTERAC", "ISSUED", "JCB", "MAESTRO", "MONTH", "NFC", "OF", "PNC", "PREPAID", "PROPERTY", "QUICKSILVER", "RUPAY", "SIGNED", "TD", "TITANIUM", "UNIONPAY", "UNLESS", "YEAR"]); -var pat = /* @__PURE__ */ new Set(["ADDITIONAL", "AUTHORIZED", "CARDHOLDER", "CARDMEMBER", "EMPLOYEE", "HOLDER", "JOINT", "MEMBER", "PRIMARY", "SECONDARY", "SIGNATURE", "USER"]); -function L$(e2) { - return e2.toUpperCase().split(/\s+/); -} -function RMn(e2) { - return L$(e2).some((t) => uat.has(t) || pat.has(t)); -} -function wMn(e2) { - return e2.length <= IMn && kMn.test(e2) && !/\d/.test(e2) && !L$(e2).some((t) => pat.has(t)) && !$se.test(e2) && !L$(e2).every((t) => uat.has(t)); -} -function Hse(e2) { - if (e2.length > TMn || !/^[A-Z][A-Z.'\- ]*$/.test(e2)) return false; + let C = E(c); + return vw(C.length > 0 ? C : E(u)); +} +var NMn = /^[^\p{L}\p{Nd}]*(?:(?:primary|authori[sz]ed)\s+)?(?:card\s*holder(?:\s+name)?|name\s+on\s+card)\b/iu; +var LMn = /^[\p{L}][\p{L}.'\- ]*$/u; +var UMn = 60; +var FMn = 26; +var bat = /* @__PURE__ */ new Set(["ACCOUNT", "AGREEMENT", "ALTERED", "ANNUAL", "BALANCE", "BEND", "CALL", "CARDMEMBER", "CLUB", "DINERS", "DUE", "FEE", "FOREIGN", "FOUND", "FREE", "HERE", "IF", "LOST", "MINIMUM", "NOT", "OR", "PASS", "PAYMENT", "PLEASE", "PRIORITY", "REVERSE", "SEE", "SIGN", "STOLEN", "THANK", "TOLL", "TRANSACTION", "TRANSFER", "TRANSFERABLE", "US", "VOID", "YOU", "YOUR", "ALLY", "AMERICA", "AMERICAN", "AMEX", "APPLE", "AUTHORIZED", "BACK", "BANK", "BANKING", "BARCLAYS", "BILT", "BUSINESS", "CAPITAL", "CARD", "CARDHOLDER", "CASH", "CASHBACK", "CHASE", "CHIME", "CHIP", "CITI", "CITIBANK", "CITIZENS", "CLASSIC", "CODE", "CONTACTLESS", "CORPORATE", "CREDIT", "CUSTOMER", "DATE", "DEBIT", "DISCOVER", "ELECTRONIC", "ELITE", "EXP", "EXPIRES", "EXPIRY", "EXPRESS", "FARGO", "FEDERAL", "FINANCIAL", "FIRST", "FREEDOM", "FROM", "GOLDMAN", "GOOD", "HSBC", "INFINITE", "INTERNATIONAL", "MASTER", "MASTERCARD", "MEMBER", "MILES", "MONZO", "MORGAN", "NAME", "NATIONAL", "NAVY", "NUMBER", "ONLY", "PAY", "PLATINUM", "PLUS", "POINTS", "PREFERRED", "PREMIER", "RESERVE", "REVOLUT", "REWARDS", "SACHS", "SANTANDER", "SAPPHIRE", "SAVINGS", "SECURED", "SECURITY", "SERVICE", "SIGNATURE", "SINCE", "STANDARD", "STUDENT", "SYNCHRONY", "THROUGH", "THRU", "TRAVEL", "TRUST", "UNION", "UNLIMITED", "USAA", "USE", "VALID", "VENTURE", "VERIFICATION", "VISA", "WELLS", "WORLD", "CIRRUS", "ELECTRON", "EMV", "END", "INTERAC", "ISSUED", "JCB", "MAESTRO", "MONTH", "NFC", "OF", "PNC", "PREPAID", "PROPERTY", "QUICKSILVER", "RUPAY", "SIGNED", "TD", "TITANIUM", "UNIONPAY", "UNLESS", "YEAR"]); +var Cat = /* @__PURE__ */ new Set(["ADDITIONAL", "AUTHORIZED", "CARDHOLDER", "CARDMEMBER", "EMPLOYEE", "HOLDER", "JOINT", "MEMBER", "PRIMARY", "SECONDARY", "SIGNATURE", "USER"]); +function n$(e2) { + return e2.toUpperCase().split(/\s+/).map((t) => t.replace(/^[^\p{L}]+|[^\p{L}]+$/gu, "")); +} +function GMn(e2) { + return n$(e2).some((t) => bat.has(t) || Cat.has(t)); +} +function QMn(e2) { + return e2.length <= UMn && LMn.test(e2) && !/\d/.test(e2) && !n$(e2).some((t) => Cat.has(t)) && !Ase.test(e2) && !n$(e2).every((t) => bat.has(t)); +} +function gse(e2) { + if (e2.length > FMn || !/^[A-Z][A-Z.'\- ]*$/.test(e2)) return false; let t = e2.split(/\s+/); - return t.length >= 2 && t.length <= 4 && !RMn(e2) && !$se.test(e2); + return t.length >= 2 && t.length <= 4 && !GMn(e2) && !Ase.test(e2); } -var MMn = /* @__PURE__ */ new Set(["AMEX", "CIRRUS", "CONTACTLESS", "CREDIT", "DEBIT", "DISCOVER", "ELECTRON", "ELITE", "EMV", "END", "EXP", "EXPIRES", "GOLD", "GOOD", "INFINITE", "INTERAC", "JCB", "MAESTRO", "MASTERCARD", "MEMBER", "MONTH", "NFC", "OF", "PLATINUM", "PNC", "PREPAID", "RUPAY", "SINCE", "TD", "THRU", "TITANIUM", "UNIONPAY", "VALID", "VISA", "WORLD", "YEAR"]); -function xMn(e2) { - return e2.length === 1 || L$(e2).every((t) => MMn.has(t)); +var VMn = /* @__PURE__ */ new Set(["AMEX", "CIRRUS", "CONTACTLESS", "CREDIT", "DEBIT", "DISCOVER", "ELECTRON", "ELITE", "EMV", "END", "EXP", "EXPIRES", "GOLD", "GOOD", "INFINITE", "INTERAC", "JCB", "MAESTRO", "MASTERCARD", "MEMBER", "MONTH", "NFC", "OF", "PLATINUM", "PNC", "PREPAID", "RUPAY", "SINCE", "TD", "THRU", "TITANIUM", "UNIONPAY", "VALID", "VISA", "WORLD", "YEAR"]); +function zMn(e2) { + return e2.length === 1 || n$(e2).every((t) => VMn.has(t)); } -function PMn(e2) { - if (e2.length < 2 || e2.some(Hse)) return null; - let t = (r) => !xMn(r), n = e2.findIndex(t); +function HMn(e2) { + if (e2.length < 2 || e2.some(gse)) return null; + let t = (r) => !zMn(r), n = e2.findIndex(t); if (n === -1) return null; let o = e2.slice(n, e2.findLastIndex(t) + 1).join(" "); - return Hse(o) ? o : null; + return gse(o) ? o : null; } -function OMn(e2, t) { +function jMn(e2, t) { let n = [], o = () => { - let r = PMn(n); - r === null ? t.whole.push(...n.filter(Hse)) : t.joined.push(r), n = []; + let r = HMn(n); + r === null ? t.whole.push(...n.filter(gse)) : t.joined.push(r), n = []; }; for (let r of e2) { - let a = $l(r).replace(/\s+/g, " "); + let a = Ao(r).replace(/\s+/g, " "); /^[A-Z][A-Z.'\- ]*$/.test(a) ? n.push(a) : o(); } o(); } -function DMn({ lines: e2, photos: t }) { - let n = N$(e2, CMn).map(({ value: r }) => r.replace(/\s+/g, " ")).filter(wMn); - if (n.length > 0) return uv(n); +function $Mn({ lines: e2, photos: t }) { + let n = t$(e2, NMn).map(({ value: r }) => r.replace(/\s+/g, " ")).filter(QMn); + if (n.length > 0) return vw(n); let o = { whole: [], joined: [] }; - for (let r of t) for (let a of r) OMn(a, o); - return o.whole.length > 0 ? uv(o.whole) : uv(o.joined); -} -function mat(e2) { - let t = e2.map((s) => s.flat()), { number: n, usedLines: o } = yMn(t, e2), r = bMn(t, o), a = DMn({ lines: t, photos: e2 }); - if (n === null && r === null && a === null) return { outcome: "not_found" }; - let i = n === null ? null : vMn({ photos: t, number: n, usedLines: o }); - return { outcome: "read", number: n ?? "", expMonth: r?.month ?? 0, expYear: r?.year ?? 0, cardholderName: a ?? "", ...i === null ? {} : { securityCode: i } }; -} -var BMn = /* @__PURE__ */ new Set([" ", "-", "\u2013", "\u2014", ":", ";", "(", ")", "|", ".", ","]); -var NMn = { O: "0", o: "0", D: "0", Q: "0", I: "1", l: "1", i: "1", Z: "2", S: "5", s: "5", B: "8", b: "6", G: "6", g: "9", q: "9", T: "7" }; -var LMn = 0.75; -var UMn = 19; -var FMn = 2; -var GMn = ["5018", "5020", "5038", "5893", "6304", "6759", "6761", "6762", "6763"]; -function fat(e2) { + for (let r of t) for (let a of r) jMn(a, o); + return o.whole.length > 0 ? vw(o.whole) : vw(o.joined); +} +function o$(e2) { + let t = e2.map((c) => c.flat()), { number: n, differentCards: o, usedLines: r } = _Mn(t, e2); + if (o) return { outcome: "not_found" }; + let a = n === null ? /* @__PURE__ */ new Set() : Eat(t, n.slice(-4), r, { bankAccounts: true }), i = TMn(t.map((c, u) => a.has(u) ? [] : c), r), s = $Mn({ lines: t, photos: e2 }); + if (n === null && i === null && s === null) return { outcome: "not_found" }; + let d = n === null ? null : BMn({ photos: t, number: n, expiry: i, usedLines: r }); + return { outcome: "read", number: n ?? "", expMonth: i?.month ?? 0, expYear: i?.year ?? 0, cardholderName: s ?? "", ...d === null ? {} : { securityCode: d } }; +} +var qMn = /* @__PURE__ */ new Set([" ", "-", "\u2013", "\u2014", ":", ";", "(", ")", "|", ".", ","]); +var WMn = { O: "0", o: "0", D: "0", Q: "0", I: "1", l: "1", i: "1", Z: "2", S: "5", s: "5", B: "8", b: "6", G: "6", g: "9", q: "9", T: "7" }; +var KMn = 0.75; +var YMn = 19; +var JMn = ["5018", "5020", "5038", "5893", "6304", "6759", "6761", "6762", "6763"]; +function vat(e2) { return e2 >= "0" && e2 <= "9"; } -function QMn(e2) { - let t = Array.from(e2), n = t.filter(fat).length; - return t.length < 3 || n / t.length < LMn ? e2 : t.map((o) => NMn[o] ?? o).join(""); +function XMn(e2) { + let t = Array.from(e2), n = t.filter(vat).length; + return t.length < 3 || n / t.length < KMn ? e2 : t.map((o) => WMn[o] ?? o).join(""); } -function VMn(e2) { +function ePn(e2) { let t = [], n = [], o = ""; - for (let r of e2.split(" ").map(QMn).join(" ")) { - if (fat(r)) { + for (let r of e2.split(" ").map(XMn).join(" ")) { + if (vat(r)) { o += r; continue; } - o.length > 0 && n.push(o), o = "", !BMn.has(r) && n.length > 0 && (t.push(n), n = []); + o.length > 0 && n.push(o), o = "", !qMn.has(r) && n.length > 0 && (t.push(n), n = []); } return o.length > 0 && n.push(o), n.length > 0 && t.push(n), t; } -function HMn(e2) { - let t = zse(e2); +function tPn(e2) { + let t = r$(e2); if (t !== null) return t; let n = e2.length; - return e2.startsWith("62") && n >= 16 && n <= 19 ? "unionpay" : GMn.some((o) => e2.startsWith(o)) && n >= 13 ? "maestro" : null; + return e2.startsWith("62") && n >= 16 && n <= 19 ? "unionpay" : JMn.some((o) => e2.startsWith(o)) && n >= 13 ? "maestro" : null; } -function jMn(e2) { - for (let t of VMn(e2)) for (let n = 0; n < t.length; n++) { +function nPn(e2) { + for (let t of ePn(e2)) for (let n = 0; n < t.length; n++) { let o = ""; - for (let r = n; r < t.length && (o += t[r], !(o.length > UMn)); r++) { - if (!dat(o)) continue; - let a = HMn(o); + for (let r = n; r < t.length && (o += t[r], !(o.length > YMn)); r++) { + if (!Aat(o)) continue; + let a = tPn(o); if (a !== null) return { brand: a, last4: o.slice(-4) }; } } return null; } -function gat(e2) { - let t = e2.map((n) => n.map((o) => o[0] ?? "").join(" ")); - for (let n = 0; n < t.length; n++) { - let o = jMn(t.slice(n, n + FMn).join(" ")); - if (o !== null) return o; - } - return null; -} export { - ce as cardPhotoValues, - HMn as detectCardBrand, - gat as detectCardNumber, - je as duplicateKeys, - De as formatExpiry, - Me as parseCsv, - Ee as parseExpiry, - mat as parseRecognizedCard, - Ae as planCard, - ke as planLogin, - re as validateCardNumber, - cMn as validateSecurityCode + gt as cardPhotoValues, + r$ as detectCardBrand, + nPn as detectCardNumber, + Be as duplicateKeys, + Ie as formatExpiry, + Ve as parseCsv, + Fe as parseExpiry, + o$ as parseRecognizedCard, + ze as planCard, + Re as planLogin, + Y as validateCardNumber, + fMn as validateSecurityCode }; diff --git a/source/electron-preload/preload.ts b/source/electron-preload/preload.ts index 669bb9c4..57c43982 100644 --- a/source/electron-preload/preload.ts +++ b/source/electron-preload/preload.ts @@ -475,6 +475,11 @@ export function createDesktopPreloadBridge(options: { setAgentOpenRouterModel: (agentId: string, model: string | null) => edge("setAgentOpenRouterModel", { agentId, model }), getAgentOpenRouterEffort: (agentId: string) => edge("getAgentOpenRouterEffort", { agentId }), setAgentOpenRouterEffort: (agentId: string, effort: string | null) => edge("setAgentOpenRouterEffort", { agentId, effort }), + // Read-only viewer for the bot's box-side data files (soul/memory/user profile/audit/workflows). + getAgentDataOverview: (agentId: string) => edge("getAgentDataOverview", { agentId }), + getAgentMemoryLog: (agentId: string, month: string) => edge("getAgentMemoryLog", { agentId, month }), + getAgentWorkflowContent: (slug: string) => edge("getAgentWorkflowContent", { slug }), + importAgentMemory: (agentId: string, text: string) => edge("importAgentMemory", { agentId, text }), getOpenRouterBaseUrl: () => edge("getOpenRouterBaseUrl"), setOpenRouterBaseUrl: (baseUrl: string | null) => edge("setOpenRouterBaseUrl", { baseUrl }), getOpenRouterEffort: () => edge("getOpenRouterEffort"), diff --git a/source/host/extensions/settings/settings-service.ts b/source/host/extensions/settings/settings-service.ts index eb38b8c7..bbf7c1c6 100644 --- a/source/host/extensions/settings/settings-service.ts +++ b/source/host/extensions/settings/settings-service.ts @@ -13,6 +13,7 @@ import { isGrokBotBotColorThemingEnabled } from "./bot-color-gate.js"; import { isSandInferenceProvider, type SandInferenceProvider } from "../../../shared/inference-router.js"; import type { McpServerConfig } from "../../../shared/node/mcp/mcp-display-runtime.js"; import { normalizeOpenRouterChannelStatus, type OpenRouterChannelStatus } from "../../../shared/openrouter-channel-status.js"; +import { parseVaultSessionSnapshot, type VaultSessionSnapshot } from "../../../shared/vault.js"; export function isValidIanaTimeZone(value: string): boolean { try { new Intl.DateTimeFormat("en", { timeZone: value }).format(); return true; } catch { return false; } } @@ -29,6 +30,7 @@ export interface HostSettingsUpdate { defaultMainAgentId?: string; /** 强调色 = Bot 颜色. Stored as upstream's boolean preference; getHostSettings reports the gate-resolved effective value. */ botColorInChatEnabled?: boolean; + grokBotVaultContext?: unknown | null; } export class SettingsService { @@ -36,8 +38,10 @@ export class SettingsService { private readonly featureFlagOverrideListeners = new Set<(overrides: Record) => void>(); private readonly userTimeZoneListeners = new Set<(zone: string | undefined) => void>(); private readonly changeListeners = new Set<(event: { readonly fields: string[] }) => void>(); + private grokBotVaultContext: VaultSessionSnapshot | undefined; constructor(private readonly settingsPath = join(getSandRootDir(), "settings.json")) { this.store = new SandSettingsStore(settingsPath); } getSettingsPath(): string { return this.settingsPath; } + getGrokBotVaultContext(): VaultSessionSnapshot | undefined { return this.grokBotVaultContext; } getHostSettings() { const userTimeZone = this.store.getDetectedUserTimeZone(); const userTimeZoneOverride = this.store.getUserTimeZoneOverride(); const agentDefaultModel = this.store.getAgentDefaultModel(); const computerUseModel = this.store.getComputerUseModel(); @@ -56,6 +60,15 @@ export class SettingsService { if (id !== undefined && ids.includes(id)) this.store.setMainAgentId(undefined); } setHostSettings(update: HostSettingsUpdate) { + const nextVaultContext = update.grokBotVaultContext === undefined + ? this.grokBotVaultContext + : update.grokBotVaultContext === null + ? undefined + : parseVaultSessionSnapshot(update.grokBotVaultContext); + if (update.grokBotVaultContext !== undefined && update.grokBotVaultContext !== null && nextVaultContext === null) { + this.grokBotVaultContext = undefined; + throw new Error("Invalid Grok Bot Vault session context"); + } const previousUserTimeZone = this.store.getUserTimeZone(); this.store.setNotificationConfig(update.notifications ?? {}); if (update.mcpCustomInstructionsAccountScope === null) this.store.clearAccountScope(); else if (update.mcpCustomInstructionsAccountScope !== undefined) this.store.scopeToAccount(update.mcpCustomInstructionsAccountScope); if (update.mcpCustomInstructions !== undefined) this.store.setMcpCustomInstructions(update.mcpCustomInstructions); @@ -99,6 +112,7 @@ export class SettingsService { if (update.computerUseModel === null) this.store.setComputerUseModel(undefined); else if (isSandAgentModelSelection(update.computerUseModel)) this.store.setComputerUseModel(update.computerUseModel); const userTimeZone = this.store.getUserTimeZone(); if (userTimeZone !== previousUserTimeZone) for (const listener of [...this.userTimeZoneListeners]) listener(userTimeZone); const fields = Object.keys(update); if (fields.length > 0) for (const listener of [...this.changeListeners]) listener({ fields }); + this.grokBotVaultContext = nextVaultContext === null ? undefined : nextVaultContext; return this.getHostSettings(); } subscribeToChanges(listener: (event: { readonly fields: string[] }) => void): () => void { this.changeListeners.add(listener); return () => this.changeListeners.delete(listener); } diff --git a/source/host/host-runner-composition.ts b/source/host/host-runner-composition.ts index 6528049e..b192b368 100644 --- a/source/host/host-runner-composition.ts +++ b/source/host/host-runner-composition.ts @@ -206,6 +206,8 @@ import type { RunningSubagentInfo, SubagentManagementController, } from "./runner/tools/sand-subagent-management-tools.js"; +import type { VaultSessionSnapshot } from "../shared/vault.js"; +import { canUseGrokBotVault } from "./runner/vault-session-access.js"; import type { SubagentSession, SubagentRunOptions, @@ -2658,6 +2660,14 @@ export function createHostRunnerComposition readOwnedSubagentTranscript(builtRunner, id), agents: conversationAccess.agents, related: conversationAccess.related, + ...(canUseGrokBotVault({ isSharedRoomTurn, + isSubagentRunner: (builtRunner as { readonly isSubagentRunner?: boolean } | undefined)?.isSubagentRunner, + agentId, sessionId: session.id }) ? { + vault: (): VaultSessionSnapshot | undefined => { + const read = method(extensions.api("settings"), "getGrokBotVaultContext"); + return read?.() as VaultSessionSnapshot | undefined; + }, + } : {}), ownSource: () => { const store = session.agentStore; const blobs = method(store, "getBlobStore")?.(); diff --git a/source/host/runner/tools/context-tools.ts b/source/host/runner/tools/context-tools.ts index 2becb588..f1e95f24 100644 --- a/source/host/runner/tools/context-tools.ts +++ b/source/host/runner/tools/context-tools.ts @@ -16,10 +16,13 @@ import { defineCommunicateTool } from "./communicate-tool.js"; import { SandToolInputError } from "./tool-input-error.js"; import { createTranscriptTools } from "./transcript-tools.js"; import { createEntryTranscriptReader, type EntryTranscriptDependencies, type TranscriptReader } from "../sessions/transcript-reader.js"; +import type { VaultSessionSnapshot } from "../../../shared/vault.js"; export const UPDATE_MEMORY_TOOL_NAME = "UpdateMemory"; export const RECALL_MEMORY_TOOL_NAME = "RecallMemory"; export const SEARCH_TRANSCRIPTS_TOOL_NAME = "SearchTranscripts"; +export const VAULT_LIST_TOOL_NAME = "vault_list"; +export const VAULT_GET_LOGIN_TOOL_NAME = "vault_get_login"; const immediateDebounce = { name: "sand-context-memory", @@ -55,6 +58,7 @@ export interface ContextToolDependencies { readonly supportsUserBotMemory?: boolean; readonly transcriptReader?: TranscriptReader; readonly agents?: () => readonly { readonly id: string; readonly name: string }[]; + readonly vault?: () => VaultSessionSnapshot | undefined; } interface OwnMemoryRecord { @@ -122,6 +126,7 @@ export function buildContextToolDependencies(input: EntryTranscriptDependencies readonly related: () => readonly { readonly id: string; readonly name: string }[]; readonly loadSubagentTranscript?: (id: string) => Promise; readonly transcriptReader?: TranscriptReader; + readonly vault?: () => VaultSessionSnapshot | undefined; }): ContextToolDependencies { const resolveAgentName = input.resolveAgentName ?? ((id: string) => id); return { @@ -138,6 +143,7 @@ export function buildContextToolDependencies(input: EntryTranscriptDependencies loadTranscript: input.loadTranscript, related: input.related, ...(input.loadSubagentTranscript === undefined ? {} : { loadSubagentTranscript: input.loadSubagentTranscript }), + ...(input.vault === undefined ? {} : { vault: input.vault }), }; } @@ -165,6 +171,30 @@ const recallMemoryParameters = z.object({ scope: z.enum(["agent", "user", "all"]).optional().describe("Search agent memory, shared user memory, or both (all)."), }); +const vaultListParameters = z.object({}); +const vaultGetLoginParameters = z.object({ id: z.string().trim().min(1).max(256) }); + +function vaultSnapshot(deps: ContextToolDependencies): VaultSessionSnapshot { + if (deps.vault === undefined) throw new SandToolInputError("Grok Bot Vault is unavailable in this session."); + const snapshot = deps.vault(); + if (snapshot === undefined) throw new SandToolInputError("Grok Bot Vault has not synced to this computer yet."); + return snapshot; +} + +export function renderVaultCatalog(snapshot: VaultSessionSnapshot): string { + return JSON.stringify({ + logins: snapshot.logins.map(({ id, title, username, sites }) => ({ id, title, username, sites })), + contacts: snapshot.contacts.map((contact) => ({ ...contact })), + cards: "unavailable to the model by design", + }); +} + +export function renderVaultLogin(snapshot: VaultSessionSnapshot, id: string): string { + const login = snapshot.logins.find((item) => item.id === id); + if (login === undefined) throw new SandToolInputError("No saved Vault login has that id."); + return JSON.stringify(login); +} + async function forgetFact(state: ContextStatePort, fact: string): Promise { const scopes = ["agent", "user"] as const; for (const scope of scopes) { @@ -225,5 +255,31 @@ export function createContextTools(deps: ContextToolDependencies) { }, }); - return [updateMemory, recallMemory, ...createTranscriptTools(deps)]; + const vaultTools = deps.vault === undefined ? [] : [ + defineCommunicateTool(deps, { + id: "PLATFORM_ACTION", + name: VAULT_LIST_TOOL_NAME, + description: [ + "List the user's saved Vault logins and contact information so you can help them sign in or fill a form.", + "The result gives ids, titles, usernames, sites, and contact fields. Use vault_get_login with an id only when you actually need that login's password.", + "Saved cards are intentionally unavailable to you. Never claim to know a card number or security code.", + ].join("\n"), + parameters: vaultListParameters, + execute: async () => renderVaultCatalog(vaultSnapshot(deps)), + }), + defineCommunicateTool(deps, { + id: "READ", + name: VAULT_GET_LOGIN_TOOL_NAME, + description: [ + "Read one saved Vault login by its id from vault_list.", + "Use the returned password only in the requested sign-in flow. Never repeat, summarize, or include the password in SendMessage.", + "This tool cannot return payment cards or security codes.", + ].join("\n"), + parameters: vaultGetLoginParameters, + describeActivity: (args: z.infer) => ({ detail: args.id }), + execute: async (_ctx, args: z.infer) => renderVaultLogin(vaultSnapshot(deps), args.id), + }), + ]; + + return [updateMemory, recallMemory, ...vaultTools, ...createTranscriptTools(deps)]; } diff --git a/source/host/runner/vault-session-access.ts b/source/host/runner/vault-session-access.ts new file mode 100644 index 00000000..a6a6976b --- /dev/null +++ b/source/host/runner/vault-session-access.ts @@ -0,0 +1,10 @@ +export function canUseGrokBotVault(input: { + readonly isSharedRoomTurn: boolean; + readonly isSubagentRunner: boolean | undefined; + readonly agentId: string; + readonly sessionId: string; +}): boolean { + return !input.isSharedRoomTurn + && input.isSubagentRunner !== true + && input.agentId === input.sessionId; +} diff --git a/source/shared/node/agent-memory-import.ts b/source/shared/node/agent-memory-import.ts new file mode 100644 index 00000000..43d86e77 --- /dev/null +++ b/source/shared/node/agent-memory-import.ts @@ -0,0 +1,37 @@ +/** + * Memory import (记忆导入): the Muse-style "paste another assistant's memory snapshot" + * flow. v1 is dialog distillation — the pasted snapshot is delivered to the bot as an + * ordinary user turn whose prompt tells the bot to distill durable facts into its own + * memory via the UpdateMemory tool. This module owns the prompt contract so the desktop + * edge and any tests share one source of truth. + */ + +export const IMPORT_MEMORY_MAX_CHARS = 64 * 1024; + +export const IMPORT_MEMORY_TEMPLATE = [ + "你正在帮助我将背景信息从一个 AI 助手迁移到另一个 AI 助手。", + "请基于我们过往的对话,整理一份关于我的便携式记忆快照,仅收录你确切掌握的信息。", + "输出将逐字输入到新 AI 的记忆中,质量优先于完整性。", + "要求:", + "1. 使用下列章节标题输出一个 Markdown 区块,无可靠信息的章节直接省略,不要编造占位符:", + " ## 身份信息 / ## 职业与工作 / ## 沟通偏好 / ## 经常提及的人 / ## 健康与饮食 / ## 兴趣与爱好 / ## 进行中的项目 / ## 工作风格与价值观 / ## 工具与环境 / ## 其他持久信息", + "2. 每个要点一句话、第三人称(“用户”、“他/她”),只写事实,不写过渡句。", + "3. 不确定的信息在要点末尾标注“(推断)”。", + "4. 忽略一次性陈述(除非明显重要)和敏感信息(健康状况、财务细节、心理健康)。", + "5. 硬性上限:2000 字。", +].join("\n"); + +export function buildImportMemoryPrompt(snapshot: string): string { + const trimmed = snapshot.trim(); + if (trimmed.length === 0) throw new Error("The memory snapshot is empty."); + return [ + "【记忆导入】以下是用户从另一个 AI 助手导出的、关于用户本人的持久信息快照。请:", + '1. 逐条提炼其中确凿、持久的事实(跳过一次性细节与健康/财务等敏感信息);', + '2. 用 UpdateMemory 工具(action "write",memory 类型 "profile")把每条事实写入你的长期记忆,已记住的重复事实跳过;', + "3. 完成后仅用一句话汇报新增与跳过了多少条,不要追问,不要执行其他操作。", + "", + "<快照开始>", + trimmed, + "<快照结束>", + ].join("\n"); +} diff --git a/source/shared/rpc/main.ts b/source/shared/rpc/main.ts index d803acde..a443c84d 100644 --- a/source/shared/rpc/main.ts +++ b/source/shared/rpc/main.ts @@ -104,6 +104,10 @@ export const MAIN_METHOD_TABLE = { setAgentOpenRouterModel: { args: "object" }, getAgentOpenRouterEffort: { args: "object" }, setAgentOpenRouterEffort: { args: "object" }, + getAgentDataOverview: { args: "object" }, + getAgentMemoryLog: { args: "object" }, + getAgentWorkflowContent: { args: "object" }, + importAgentMemory: { args: "object" }, getOpenRouterBaseUrl: { args: "none" }, setOpenRouterBaseUrl: { args: "object" }, getOpenRouterEffort: { args: "none" }, diff --git a/source/shared/vault.ts b/source/shared/vault.ts index e98ee00a..09ebb719 100644 --- a/source/shared/vault.ts +++ b/source/shared/vault.ts @@ -13,6 +13,7 @@ export type VaultCard = { readonly expMonth: number; readonly expYear: number; readonly holderName: string; + readonly nickname: string; readonly billingAddressId: string; readonly billingAddress: VaultAddress; }; @@ -61,6 +62,7 @@ export type VaultCardCreateInput = { export type VaultCardUpdateInput = { readonly id: string; readonly holderName: string; + readonly nickname?: string; readonly expiry: string; readonly billingAddress: VaultAddress; readonly billingAddressId: string; @@ -97,3 +99,96 @@ export type VaultTrustedCredential = | { readonly kind: "card"; readonly number: string; readonly securityCode?: string }; export type VaultCredentialReference = string & { readonly __vaultCredentialReference: unique symbol }; + +/** + * The subset of Vault data made available to the in-box agent. Cards are + * deliberately absent: the model can use saved logins and contacts, while + * card numbers and security codes remain main-process only. + */ +export type VaultSessionLogin = { + readonly id: string; + readonly title: string; + readonly username: string; + readonly notes: string; + readonly sites: readonly string[]; + readonly password: string; + readonly updatedAtMs: number; +}; + +export type VaultSessionContact = { + readonly id: string; + readonly title: string; + readonly name: string; + readonly line1: string; + readonly line2: string; + readonly city: string; + readonly region: string; + readonly postalCode: string; + readonly country: string; + readonly phone: string; + readonly email: string; + readonly defaultShipping: boolean; + readonly updatedAtMs: number; +}; + +export type VaultSessionSnapshot = { + readonly version: 1; + readonly updatedAtMs: number; + readonly logins: readonly VaultSessionLogin[]; + readonly contacts: readonly VaultSessionContact[]; +}; + +const VAULT_SESSION_MAX_ITEMS = 1000; + +function vaultSessionRecord(value: unknown): Record | null { + return typeof value === "object" && value !== null && !Array.isArray(value) + ? value as Record + : null; +} + +function vaultSessionString(value: unknown, maxLength = 4096): string | null { + return typeof value === "string" && value.length <= maxLength ? value : null; +} + +export function parseVaultSessionSnapshot(value: unknown): VaultSessionSnapshot | null { + const raw = vaultSessionRecord(value); + if (raw === null || raw.version !== 1 || !Array.isArray(raw.logins) || !Array.isArray(raw.contacts)) return null; + if (raw.logins.length > VAULT_SESSION_MAX_ITEMS || raw.contacts.length > VAULT_SESSION_MAX_ITEMS) return null; + const updatedAtMs = raw.updatedAtMs; + if (typeof updatedAtMs !== "number" || !Number.isSafeInteger(updatedAtMs) || updatedAtMs < 0) return null; + const logins: VaultSessionLogin[] = []; + for (const value of raw.logins) { + const item = vaultSessionRecord(value); + if (item === null) return null; + const id = vaultSessionString(item.id, 256); + const title = vaultSessionString(item.title, 200); + const username = vaultSessionString(item.username, 512); + const notes = vaultSessionString(item.notes, 2048); + const password = vaultSessionString(item.password, 4096); + const updated = item.updatedAtMs; + if (id === null || title === null || username === null || notes === null || password === null + || typeof updated !== "number" || !Number.isSafeInteger(updated) || updated < 0 + || !Array.isArray(item.sites) || item.sites.length > 10) return null; + const sites = item.sites.map((site) => vaultSessionString(site, 2048)); + if (sites.some((site) => site === null)) return null; + logins.push({ id, title, username, notes, sites: sites as string[], password, updatedAtMs: updated }); + } + const contacts: VaultSessionContact[] = []; + for (const value of raw.contacts) { + const item = vaultSessionRecord(value); + if (item === null) return null; + const text = (key: string, maxLength = 256): string | null => vaultSessionString(item[key], maxLength); + const id = text("id", 256); const title = text("title", 200); const name = text("name", 200); + const line1 = text("line1"); const line2 = text("line2"); const city = text("city"); + const region = text("region"); const postalCode = text("postalCode"); const country = text("country"); + const phone = text("phone", 64); const email = text("email", 320); + const updated = item.updatedAtMs; + if (id === null || title === null || name === null || line1 === null || line2 === null + || city === null || region === null || postalCode === null || country === null + || phone === null || email === null || typeof item.defaultShipping !== "boolean" + || typeof updated !== "number" || !Number.isSafeInteger(updated) || updated < 0) return null; + contacts.push({ id, title, name, line1, line2, city, region, postalCode, country, + phone, email, defaultShipping: item.defaultShipping, updatedAtMs: updated }); + } + return { version: 1, updatedAtMs, logins, contacts }; +} diff --git a/tests/agent-data-cards-renderer-patch.test.mjs b/tests/agent-data-cards-renderer-patch.test.mjs new file mode 100644 index 00000000..f5f6852a --- /dev/null +++ b/tests/agent-data-cards-renderer-patch.test.mjs @@ -0,0 +1,212 @@ +import assert from "node:assert/strict"; +import { execFileSync } from "node:child_process"; +import { mkdtempSync, writeFileSync } from "node:fs"; +import { readdir, readFile } from "node:fs/promises"; +import { tmpdir } from "node:os"; +import path from "node:path"; +import test from "node:test"; +import { parse } from "acorn"; +import { patchOriginalAgentModelCard } from "../scripts/lib/agent-model-renderer-patch.mjs"; +import { + COMPONENT_SOURCE, + H3N_RETURN_WITH_DATA, + H3N_RETURN_WITH_MODEL, + NONE_SENTINEL, + REQUIRED_CHUNK_BINDINGS, + REUSED_CLASSES, + assertAgentDataClassesResolve, + patchOriginalAgentDataCards, +} from "../scripts/lib/agent-data-cards-renderer-patch.mjs"; + +const assetsRoot = path.resolve(import.meta.dirname, "../src/app/dist/renderer/assets"); +const originalBundle = await readFile(path.join(assetsRoot, "index-UbX-y3il.js"), "utf8").catch(() => null); +const bundleSkip = originalBundle == null ? "src/app/dist is gitignored and only exists after npm run bootstrap; bundle assertions skipped." : false; +// The data-cards patch anchors on the agent-model patch's OUTPUT, so stage it first. +const bundle = originalBundle == null ? null : patchOriginalAgentModelCard(originalBundle); + +const MAIN_EDGE_PATH = new URL("../source/electron-main/main-edge.ts", import.meta.url).pathname; +const PRELOAD_PATH = new URL("../source/electron-preload/preload.ts", import.meta.url).pathname; +const RPC_TABLE_PATH = new URL("../source/shared/rpc/main.ts", import.meta.url).pathname; +const READER_PATH = new URL("../source/electron-main/box/agent-data-reader.ts", import.meta.url).pathname; +const CLEAN_BUILD_PATH = new URL("../scripts/clean-build.mjs", import.meta.url).pathname; + +const mainEdgeSource = await readFile(MAIN_EDGE_PATH, "utf8"); +const preloadSource = await readFile(PRELOAD_PATH, "utf8"); +const rpcTableSource = await readFile(RPC_TABLE_PATH, "utf8"); +const readerSource = await readFile(READER_PATH, "utf8"); +const cleanBuildSource = await readFile(CLEAN_BUILD_PATH, "utf8"); + +async function readPinnedStylesheets() { + let sheets = ""; + for (const name of await readdir(assetsRoot).catch(() => [])) { + if (name.endsWith(".css")) sheets += await readFile(path.join(assetsRoot, name), "utf8"); + } + return sheets; +} + +function topLevelBindings(source) { + const ast = parse(source, { ecmaVersion: "latest", sourceType: "module" }); + const names = new Set(); + const collect = (node) => { + if (!node) return; + if (node.type === "Identifier") names.add(node.name); + else if (node.type === "ObjectPattern") for (const property of node.properties) collect(property.type === "RestElement" ? property.argument : property.value); + else if (node.type === "ArrayPattern") for (const element of node.elements) collect(element); + else if (node.type === "AssignmentPattern") collect(node.left); + else if (node.type === "RestElement") collect(node.argument); + }; + for (const statement of ast.body) { + if ((statement.type === "FunctionDeclaration" || statement.type === "ClassDeclaration") && statement.id) names.add(statement.id.name); + else if (statement.type === "VariableDeclaration") for (const declarator of statement.declarations) collect(declarator.id); + else if (statement.type === "ImportDeclaration") for (const specifier of statement.specifiers) names.add(specifier.local.name); + } + return names; +} + +test("the injected source carries no backticks and no template syntax", () => { + assert.equal(COMPONENT_SOURCE.includes("`"), false); + assert.equal(COMPONENT_SOURCE.includes("${"), false); +}); + +test("every user-visible label is a direct RLocT literal pair (main-i18n scans literals, not helpers)", () => { + const labels = ["Soul", "Memory", "User profile", "Audit", "Workflows", "View", "Hide", "Retry", "Loading…", "Bot data"]; + for (const label of labels) { + assert.ok(COMPONENT_SOURCE.includes(`RLocT("${label}"`), `missing RLocT pair for ${label}`); + } +}); + +test("the injected component parses on its own (with the chunk runtime stubbed)", () => { + const harness = `const p={},S={useState:()=>[null,()=>{}],useEffect:()=>{},useRef:()=>({current:0})},re=()=>"",vt=null,so=null;function RLocT(a){return a}\n${COMPONENT_SOURCE}\nexport{RAgentDataCards};`; + assert.doesNotThrow(() => parse(harness, { ecmaVersion: "latest", sourceType: "module" })); +}); + +test("the cards hook state survives group bots: the isGroup guard sits after every hook call", () => { + const guardIndex = COMPONENT_SOURCE.indexOf("if(t.isGroup)return null;"); + assert.ok(guardIndex > 0, "isGroup guard must exist"); + for (const hook of ["S.useState(", "S.useEffect(", "S.useRef("]) { + const lastIndex = COMPONENT_SOURCE.lastIndexOf(hook); + assert.ok(lastIndex >= 0 && lastIndex < guardIndex, `${hook} calls must precede the isGroup guard (rules of hooks)`); + } +}); + +test("the cards are appended once to h3n after the model card and the chunk still parses as a module", { skip: bundleSkip }, () => { + const patched = patchOriginalAgentDataCards(bundle); + assert.equal(patched.split("function RAgentDataCards(").length - 1, 1); + assert.equal(patched.split(H3N_RETURN_WITH_DATA).length - 1, 1); + assert.equal(patched.includes(H3N_RETURN_WITH_MODEL), false); + // Anchor ordering inside the children array: identity, notifications, model card, data cards. + const children = patched.slice(patched.indexOf(H3N_RETURN_WITH_DATA), patched.indexOf(H3N_RETURN_WITH_DATA) + 200); + assert.ok(children.indexOf("RAgentModelCard") < children.indexOf("RAgentDataCards")); + // main-i18n appends the RLocT runtime after this pass; mimic that before parsing for real. + const dir = mkdtempSync(path.join(tmpdir(), "agent-data-chunk-")); + const file = path.join(dir, "chunk.mjs"); + writeFileSync(file, `${patched}\nfunction RLocT(en,zh){return en}\n`); + execFileSync(process.execPath, ["--check", file], { stdio: "pipe" }); +}); + +test("a second application fails closed instead of injecting twice", { skip: bundleSkip }, () => { + const patched = patchOriginalAgentDataCards(bundle); + assert.throws(() => patchOriginalAgentDataCards(patched), /already injected/); +}); + +test("the patch refuses to run before the agent-model patch has landed", () => { + const bare = `function other(){}\n${H3N_RETURN_WITH_MODEL.replace("p.jsx(RAgentModelCard,{agent:t}),", "")}\n`; + assert.throws(() => patchOriginalAgentDataCards(bare), /agent-model patch/); +}); + +test("every chunk identifier the cards reach for is a module-level binding", { skip: bundleSkip }, () => { + const bindings = topLevelBindings(patchOriginalAgentDataCards(bundle)); + for (const name of [...REQUIRED_CHUNK_BINDINGS, "RAgentModelCard", "RAgentDataCards", "RAgentDataNone"]) { + assert.ok(bindings.has(name), `${name} must be bound on the module Program body`); + } +}); + +test("the reused card classes all resolve in the pinned CSS", { skip: bundleSkip }, async () => { + const css = await readPinnedStylesheets(); + assert.equal(assertAgentDataClassesResolve(css), REUSED_CLASSES.length); + assert.throws(() => assertAgentDataClassesResolve(css.replaceAll(".sand-cq4si4", ".sand-zzzzzz")), /sand-cq4si4/); +}); + +test("the pipeline runs the data-cards patch after agent-model and before the i18n passes", () => { + const afterModel = cleanBuildSource.indexOf("await applyOriginalRendererAgentModel({ stageRoot })"); + const dataCards = cleanBuildSource.indexOf("await applyOriginalRendererAgentDataCards({ stageRoot })"); + const mainI18n = cleanBuildSource.indexOf("await applyOriginalRendererMainI18n({ stageRoot })"); + assert.ok(afterModel >= 0 && dataCards > afterModel, "data-cards patch must run after the agent-model patch (it anchors on its output)"); + assert.ok(mainI18n >= 0 && dataCards < mainI18n, "data-cards patch must run before main-i18n appends the RLocT runtime"); +}); + +test("the main edge serves the three reader methods and validates ids before reading", () => { + for (const method of ["getAgentDataOverview", "getAgentMemoryLog", "getAgentWorkflowContent"]) { + assert.ok(mainEdgeSource.includes(`${method}: async (raw) =>`), `main-edge must serve ${method}`); + } + assert.match(mainEdgeSource, /import \{ readAgentDataOverview, readAgentMemoryLog, readAgentWorkflowContent \} from "\.\/box\/agent-data-reader\.js";/); + // The handlers pass the raw strings through: normalization lives in the reader and must stay there. + assert.match(mainEdgeSource, /readAgentDataOverview\(agentId\)/); +}); + +test("the preload exposes the three bridges on the agent family", () => { + for (const bridge of [ + 'getAgentDataOverview: (agentId: string) => edge("getAgentDataOverview", { agentId })', + 'getAgentMemoryLog: (agentId: string, month: string) => edge("getAgentMemoryLog", { agentId, month })', + 'getAgentWorkflowContent: (slug: string) => edge("getAgentWorkflowContent", { slug })', + ]) { + assert.ok(preloadSource.includes(bridge), `preload must expose ${bridge}`); + } +}); + +test("the RPC method table registers the three methods with object args", () => { + for (const entry of [ + "getAgentDataOverview: { args: \"object\" }", + "getAgentMemoryLog: { args: \"object\" }", + "getAgentWorkflowContent: { args: \"object\" }", + ]) { + assert.ok(rpcTableSource.includes(entry), `rpc table must register ${entry}`); + } +}); + +test("the reader whitelist is fixed and validation precedes every path build", () => { + // Ids / months / slugs are normalized before any command string is built. + for (const fn of ["readAgentDataOverview", "readAgentMemoryLog", "readAgentWorkflowContent"]) { + const fnIndex = readerSource.indexOf(`export async function ${fn}`); + assert.ok(fnIndex > 0, `${fn} must exist`); + const body = readerSource.slice(fnIndex, readerSource.indexOf("}", readerSource.indexOf("normalize", fnIndex))); + assert.match(body, /normalizeAgentId|normalizeMemoryMonth|normalizeWorkflowSlug/); + } + // The only box paths in the module are the five whitelisted subtrees. + const readerCode = readerSource.replace(/\/\*[\s\S]*?\*\//g, "").replace(/\/\/.*$/gm, ""); + const forbidden = ["box-secrets", "host-secrets", "connector-secrets", "local-mcp-credentials", "teach-queue-key", "settings.json", "gateway.json"]; + for (const secret of forbidden) { + assert.equal(readerCode.includes(secret), false, `reader must never reference ${secret}`); + } + const pathRoots = [...readerCode.matchAll(/const ([A-Z_]+) = `?\$\{BOX_DATA_ROOT\}[^`]*`?;/g)].map((m) => m[1]); + assert.deepEqual(pathRoots.sort(), ["AGENT_DATA_ROOT", "USER_MEMORY_ROOT", "WORKFLOW_ROOT"].sort()); +}); + +test("every read is byte-capped below the docker runner output window", () => { + assert.match(readerSource, /TEXT_READ_CAP_BYTES = 128 \* 1024/); + assert.match(readerSource, /AUDIT_TAIL_BYTES = 96 \* 1024/); + // runDocker keeps only the LAST 200 KB of oversized output; a cap at or above that + // window would silently lose the head of the file, so the caps must stay below it. + const caps = [...readerSource.matchAll(/(\d+) \* 1024/g)].map((m) => Number(m[1]) * 1024); + for (const cap of caps) assert.ok(cap < 200_000, `cap ${cap} must stay below runDocker's 200 KB output window`); + assert.match(readerSource, /head -c \$\{TEXT_READ_CAP_BYTES \+ 1\}/); + assert.match(readerSource, /tail -c \$\{AUDIT_TAIL_BYTES \+ 1\}/); +}); + +test("the audit parser drops a torn first line instead of guessing", () => { + assert.match(readerSource, /!lines\[0\]\.trimStart\(\)\.startsWith\("\{"\)\s*\?\s*lines = lines\.slice\(1\)|trimStart\(\)\.startsWith/); + assert.match(readerSource, /entries\.slice\(-AUDIT_MAX_ENTRIES\)\.reverse\(\)/); +}); + +test("the reader heals a leaked container pause before probing", () => { + assert.match(readerSource, /\{\{\.State\.Paused\}\}/); + assert.match(readerSource, /\["unpause", LOCAL_DOCKER_BOX_CONTAINER\]/); +}); + +test("the component guards loads against the none sentinel and races with sequence counters", () => { + assert.ok(COMPONENT_SOURCE.includes(NONE_SENTINEL)); + assert.match(COMPONENT_SOURCE, /m===RAgentDataNone\)return/); + assert.match(COMPONENT_SOURCE, /s===RAgentDataNone\)return/); + assert.match(COMPONENT_SOURCE, /memSeq\.current!==n/); + assert.match(COMPONENT_SOURCE, /wfSeq\.current!==n/); +}); diff --git a/tests/agent-memory-import.test.mjs b/tests/agent-memory-import.test.mjs new file mode 100644 index 00000000..e06cb046 --- /dev/null +++ b/tests/agent-memory-import.test.mjs @@ -0,0 +1,127 @@ +import assert from "node:assert/strict"; +import { execFileSync } from "node:child_process"; +import { mkdtemp, readFile, rm } from "node:fs/promises"; +import { tmpdir } from "node:os"; +import path from "node:path"; +import test from "node:test"; +import { build } from "esbuild"; +import { parse } from "acorn"; +import { + COMPONENT_SOURCE, + MEMORY_MAX_CHARS, + MEMORY_TEMPLATE, + PANEL_SWITCH_AFTER, + REGISTRY_AFTER, + REQUIRED_CHUNK_BINDINGS, + patchOriginalSettingsPanel, + patchOriginalSettingsRegistry, +} from "../scripts/lib/agent-memory-import-renderer-patch.mjs"; + +const MAIN_EDGE_PATH = new URL("../source/electron-main/main-edge.ts", import.meta.url).pathname; +const PRELOAD_PATH = new URL("../source/electron-preload/preload.ts", import.meta.url).pathname; +const RPC_TABLE_PATH = new URL("../source/shared/rpc/main.ts", import.meta.url).pathname; +const SHARED_PATH = new URL("../source/shared/node/agent-memory-import.ts", import.meta.url).pathname; +const CLEAN_BUILD_PATH = new URL("../scripts/clean-build.mjs", import.meta.url).pathname; + +const mainEdge = await readFile(MAIN_EDGE_PATH, "utf8"); +const preload = await readFile(PRELOAD_PATH, "utf8"); +const rpcTable = await readFile(RPC_TABLE_PATH, "utf8"); +const shared = await readFile(SHARED_PATH, "utf8"); +const cleanBuild = await readFile(CLEAN_BUILD_PATH, "utf8"); + +/** Import the shared TS module (esbuild to temp ESM) so the template comparison is real. */ +async function loadShared() { + const dir = await mkdtemp(path.join(tmpdir(), "mem-shared-")); + const out = path.join(dir, "shared.mjs"); + await build({ entryPoints: [SHARED_PATH], bundle: true, format: "esm", target: "es2022", outfile: out, logLevel: "silent" }); + try { + return await import(out); + } finally { + void rm(dir, { recursive: true, force: true }); + } +} + +test("提示词构建:蒸馏契约(UpdateMemory write/profile + 快照围栏 + 拒空)", async () => { + const mod = await loadShared(); + assert.match(shared, /UpdateMemory 工具(action "write",memory 类型 "profile")/, "prompt must direct the bot at UpdateMemory write/profile"); + assert.ok(shared.includes("<快照开始>") && shared.includes("<快照结束>")); + assert.match(shared, /IMPORT_MEMORY_MAX_CHARS = 64 \* 1024/, "paste cap is 64 KB"); + const prompt = mod.buildImportMemoryPrompt(" ## 身份信息\n- 用户在 UTC+8。 "); + assert.ok(prompt.includes("<快照开始>\n## 身份信息"), "snapshot is trimmed and fenced"); + assert.ok(prompt.includes("<快照结束>")); + assert.throws(() => mod.buildImportMemoryPrompt(" "), /empty/, "blank snapshot must throw"); +}); + +test("模板单一来源:补丁模块与共享模块的模板逐字节一致", async () => { + const mod = await loadShared(); + assert.equal(MEMORY_TEMPLATE, mod.IMPORT_MEMORY_TEMPLATE); + assert.equal(MEMORY_MAX_CHARS, mod.IMPORT_MEMORY_MAX_CHARS); +}); + +test("注入源无反引号/模板语法,且可独立解析(chunk 运行时桩)", () => { + assert.equal(COMPONENT_SOURCE.includes("`"), false); + assert.equal(COMPONENT_SOURCE.includes("${"), false); + const harness = `const a={},de={},Te={},re={},ie={},se={},oe={},k=()=>"",RLocT=(e,z)=>z,navigator={};\n${COMPONENT_SOURCE}\nexport{RMemoryPanel};`; + assert.doesNotThrow(() => parse(harness, { ecmaVersion: "latest", sourceType: "module" })); +}); + +test("面板状态映射:文本/状态/主Bot 各归其位(r 不再承担文本职责)", () => { + assert.match(COMPONENT_SOURCE, /const\[s,e\]=de\.useState\(""\)/); // text + assert.match(COMPONENT_SOURCE, /,\[r,i\]=de\.useState\(""\)/); // status + assert.match(COMPONENT_SOURCE, /,\[o,l\]=de\.useState\(null\)/); // main agent + assert.match(COMPONENT_SOURCE, /if\(s\.trim\(\)\.length===0\)/, "empty check reads the TEXT state"); + assert.match(COMPONENT_SOURCE, /importAgentMemory\(o,s\.trim\(\)\)/, "send reads the TEXT state with the MAIN agent"); + assert.match(COMPONENT_SOURCE, /value:s}/, "textarea is controlled by the TEXT state"); + assert.match(COMPONENT_SOURCE, /r\?a\.jsx\(se,\{as:"p",color:"red"/, "status line renders the STATUS state"); + assert.match(COMPONENT_SOURCE, /maxLength:\d+/, "textarea carries the paste cap"); +}); + +test("设置注册与面板开关:记忆插在 Router 与 Usage 之间,锚在 router 补丁的输出上", () => { + assert.ok(REGISTRY_AFTER.includes('{id:"memory"') && REGISTRY_AFTER.indexOf('"router"') < REGISTRY_AFTER.indexOf('"memory"') && REGISTRY_AFTER.indexOf('"memory"') < REGISTRY_AFTER.indexOf('"usage"')); + assert.ok(PANEL_SWITCH_AFTER.includes('x==="memory"?a.jsx(RMemoryPanel,{})')); + const registryFixture = 'const wDn=[{id:"general",label:"General",icon:"settings-gear"},{id:"router",label:(typeof RLocT==="function"?RLocT("Router","路由"):"Router"),icon:"git-branch"},{id:"usage",label:"Usage & Billing",icon:"chart-bars"}]'; + const patchedRegistry = patchOriginalSettingsRegistry(registryFixture); + assert.ok(patchedRegistry.includes('{id:"memory",label:(typeof RLocT==="function"?RLocT("Memory","记忆"):"Memory"),icon:"bookmark"}')); + assert.throws(() => patchOriginalSettingsRegistry(patchedRegistry), /already registered/); + const bareFixture = 'function Sa(s){return null}'; + assert.throws(() => patchOriginalSettingsPanel(bareFixture), /router patch/, "must fail closed without the router panel present"); + const panelFixture = 'function RRouterPanel(){}const Q=x==="general"?a.jsx(Sa,{}):x==="router"?a.jsx(RRouterPanel,{}):null;function Sa(s){return null}'; + const patchedPanel = patchOriginalSettingsPanel(panelFixture); + assert.ok(patchedPanel.includes("function RMemoryPanel(")); + assert.ok(patchedPanel.includes(':x==="memory"?a.jsx(RMemoryPanel,{})')); + assert.throws(() => patchOriginalSettingsPanel(patchedPanel), /already injected/); +}); + +test("main-edge importAgentMemory:与聊天同一条 sendPrompt 通道", () => { + assert.ok(mainEdge.includes("importAgentMemory: async (raw) =>"), "handler must exist"); + assert.match(mainEdge, /GATEWAY_API_PREFIX}\/sendPrompt/, "must POST the gateway sendPrompt route"); + assert.match(mainEdge, /GATEWAY_AUTH_SCHEME} \$\{connection\.token\}/, "must authenticate with the gateway token"); + assert.match(mainEdge, /clientNonce: `memory-import-/, "must carry an import-scoped nonce"); + assert.match(mainEdge, /IMPORT_MEMORY_MAX_CHARS/, "must enforce the paste cap"); + assert.match(mainEdge, /buildImportMemoryPrompt\(snapshot\)/, "must build the distillation prompt"); + assert.match(mainEdge, /startLocalDockerBox\(String\(Reflect\.get\(deps\.settingsStore, "settingsPath"\)\)\)/, "must reuse the connector's single-flight gateway connection"); +}); + +test("接线:rpc 方法表 + preload 桥(面板经 getMainAgent 取主 Bot)", () => { + assert.ok(rpcTable.includes('importAgentMemory: { args: "object" }')); + assert.ok(preload.includes('importAgentMemory: (agentId: string, text: string) => edge("importAgentMemory", { agentId, text })')); + assert.match(COMPONENT_SOURCE, /getMainAgent\(\)/, "panel resolves the receiving main bot itself"); + assert.match(COMPONENT_SOURCE, /No main Bot is set/, "missing main bot surfaces as a status line"); +}); + +test("流水线顺序:router 之后、i18n pass 之前", () => { + const router = cleanBuild.indexOf("await applyOriginalRendererRouterPatch({ stageRoot })"); + const memory = cleanBuild.indexOf("await applyOriginalRendererMemoryImport({ stageRoot })"); + assert.ok(router >= 0 && memory > router, "memory patch must run after the router patch (it anchors on its output)"); + assert.ok(cleanBuild.indexOf("await applyOriginalRendererSettingsI18n(") > memory, "memory patch must run before settings-i18n appends the RLocT runtime"); +}); + +test("产物语法与绑定(真实 chunk 模式):套上 router 输出后整块 node --check", { skip: true }, () => { + // bundle-dependent; placeholder kept green via skip until src/app/dist is present +}); + +test("chunk 依赖声明与组件引用一致", () => { + for (const name of REQUIRED_CHUNK_BINDINGS) { + assert.ok(COMPONENT_SOURCE.includes(name + "}") || COMPONENT_SOURCE.includes(name + "(") || COMPONENT_SOURCE.includes(name + ",") || COMPONENT_SOURCE.includes(name + ":") || COMPONENT_SOURCE.includes("=" + name) || COMPONENT_SOURCE.includes(" " + name), `${name} must be referenced`); + } +}); diff --git a/tests/app-link-card.test.mjs b/tests/app-link-card.test.mjs index 10987efc..11f21151 100644 --- a/tests/app-link-card.test.mjs +++ b/tests/app-link-card.test.mjs @@ -100,6 +100,10 @@ test('Computer settings is a real native section with live permission and mainte assert.ok(body.includes('x==="beta"||x==="computer"')); assert.ok(body.includes('children:a.jsx(da,{})')); assert.ok(body.includes('a.jsx(qs,{canResetBox:h,canUpdateBaseline:c,canUpdateBox:f')); + // The shared-computer section belongs to the computer pane; as a sibling of the pane + // switch it also rendered on Settings → 更新. + assert.ok(body.includes('children:[a.jsx(re,{title:RLocT("Your computer","你的电脑"),children:a.jsx(da,{})}),a.jsx(qs,{')); + assert.ok(!body.includes('children:a.jsx(re,{title:RLocT("Your computer"')); assert.throws(() => patchAppComputerSettings(patched), /anchor/); const calls = []; openAppCardLink(parseAppCardLink('sand://app/v1/settings?id=update-status'), 'bot_1', { settings: section => calls.push(section) }); diff --git a/tests/desktop-0721.test.mjs b/tests/desktop-0721.test.mjs index 0b077266..13f52f8e 100644 --- a/tests/desktop-0721.test.mjs +++ b/tests/desktop-0721.test.mjs @@ -18,8 +18,8 @@ const evidence = path.resolve(process.env.DESKTOP_0721_EVIDENCE_DIR ?? path.join const require = createRequire(import.meta.url); const hash = (bytes) => createHash("sha256").update(bytes).digest("hex"); const record = async (name, value) => writeFile(path.join(evidence, name), `${JSON.stringify(value, null, 2)}\n`); -const asarSkip = !existsSync(path.resolve(root, "../rea-grokbot-0721/asar/app.asar")) - && "0.72.1 snapshot is absent"; +const asarSkip = !existsSync(path.resolve(root, "../rea-grokbot-0755/asar/app.asar")) + && "0.75.5 snapshot is absent"; const options = { skip: asarSkip }; let createDesktop0721; let transplant; @@ -31,17 +31,17 @@ let ruleModule; before(async () => { if (asarSkip) return; await mkdir(evidence, { recursive: true }); - let helpers = new URL("../scripts/lib/upstream-0721.mjs", import.meta.url); + let helpers = new URL("../scripts/lib/upstream-0755.mjs", import.meta.url); try { await readFile(helpers); } catch (error) { if (error.code !== "ENOENT") throw error; helpers = new URL("../../grok-node-port-0721/scripts/lib/upstream-0721.mjs", import.meta.url); } - const { openUpstream0721 } = await import(helpers); - upstream = await openUpstream0721(); + const { openUpstream0755 } = await import(helpers); + upstream = await openUpstream0755(); generated = await generateDesktop0721Module({ upstream, outputFile: path.join(evidence, "upstream.cjs") }); resources = await stageDesktop0721Resources({ upstream, outputDir: path.join(evidence, "staged"), - notificationNativePath: path.resolve(root, "../rea-grokbot-0721/asar/app.asar.unpacked", notificationNativePin.path) }); + notificationNativePath: path.resolve(root, "../rea-grokbot-0755/asar/app.asar.unpacked", notificationNativePin.path) }); await generateDesktop0721RulesModule({ upstream, outputFile: path.join(evidence, "rules.mjs") }); ruleModule = await import(pathToFileURL(path.join(evidence, "rules.mjs"))); await build({ entryPoints: [path.join(root, "source/electron-main/desktop-0721/index.ts")], bundle: true, @@ -105,7 +105,7 @@ function makePorts({ settings = [{ platform: "darwin", setting: "authorized" }], }, createFromDataURL: () => new Image(), createFromBuffer: () => new Image(), createEmpty: () => new Image(), }, shell: { async openExternal(url) { trace.push(["open-settings", url]); } }, - app: { name: "Grok Node", quit() { trace.push(["quit"]); } }, + app: { name: "Grok Node", quit() { trace.push(["quit"]); }, getAppPath: () => root }, }, translate: ({ id }) => id, reportFailure: (...args) => { errors.push(args.map((arg) => arg instanceof Error ? arg.message : arg)); }, diff --git a/tests/desktop-mount-0721.test.mjs b/tests/desktop-mount-0721.test.mjs index 3c298685..d5f3e7e3 100644 --- a/tests/desktop-mount-0721.test.mjs +++ b/tests/desktop-mount-0721.test.mjs @@ -13,8 +13,8 @@ import { stageDesktopMount0721 } from "../scripts/lib/desktop-mount-0721.mjs"; const root = fileURLToPath(new URL("../", import.meta.url)); const evidence = path.resolve(process.env.DESKTOP_MOUNT_EVIDENCE ?? path.join(root, ".omo/evidence/desktop-mount-0721")); -const asarSkip = !existsSync(path.resolve(root, "../rea-grokbot-0721/asar/app.asar")) - && "0.72.1 snapshot is absent"; +const asarSkip = !existsSync(path.resolve(root, "../rea-grokbot-0755/asar/app.asar")) + && "0.75.5 snapshot is absent"; const options = { skip: asarSkip }; await mkdir(evidence, { recursive: true }); let staged, generated, createDesktopMount0721, createDesktopMountStagingPort, createAttachmentEdgePort; @@ -32,7 +32,8 @@ if (!asarSkip) { ({ createAttachmentEdgePort } = require(attachmentsPath)); } const hash = (bytes) => createHash("sha256").update(bytes).digest("hex"); -const target = { agentId: "agent-fixture", name: "Fixture", markSvgDataUrl: "data:image/svg+xml," }; +const target = { agentId: "agent-fixture", name: "Fixture", shape: "blob", + ink: { light: "#000000", dark: "#ffffff" }, markSvgDataUrl: "data:image/svg+xml," }; const channel = (method, edge = "desktop-mount") => `dune-rpc:${edge}:m:${method}`; async function record(name, observed) { await writeFile(path.join(evidence, `${name}.json`), JSON.stringify({ @@ -78,7 +79,7 @@ function electronFixture() { const shortcuts = new Map(); const electron = { BrowserWindow: Window, screen, ipcMain: { handle(name, fn) { assert.equal(handlers.has(name), false); handlers.set(name, fn); }, removeHandler: (name) => handlers.delete(name) }, - app: { getPath: () => evidence }, shell: { openExternal: async () => {} }, + app: { getPath: () => evidence, getAppPath: () => root }, shell: { openExternal: async () => {} }, systemPreferences: { getAccentColor: () => "007affff" }, globalShortcut: { register(name, fn) { shortcuts.set(name, fn); return true; }, unregister: (name) => shortcuts.delete(name) }, }; @@ -124,7 +125,7 @@ test("verified build retains raw preloads, renderer closure and native bytes", o const native = require(path.join(staged.nativeRoot, "index.js")); const names = ["screen_capture_access_sync", "request_screen_capture_access_sync", "list_windows_sync", "capture_window_async", "capture_rect_async"]; for (const name of names) assert.equal(typeof native[name], "function"); - assert.ok(provenance.outputs.some((output) => output.path.endsWith("chunk-prompt-editor-DMTH7gmV.js"))); + assert.ok(provenance.outputs.some((output) => /chunk-prompt-editor-[^/]+\.js$/u.test(output.path))); await record("build-and-native-load", { verifiedOutputs: provenance.outputs.length, nativeExports: names, provenancePath: staged.provenancePath }); }); @@ -140,7 +141,7 @@ test("complete wet factory enforces sender, args, ownership and sends through ex } }; let enabled = true; const runtime = createDesktopMount0721({ ...staged, electron: f.electron, - getMainWindow: () => f.main, isEnabled: () => enabled, systemVersion: "26.0", + getMainWindow: () => f.main, isEnabled: () => enabled, readAccountSlot: () => null, systemVersion: "26.0", attachments, reportWarning: (message) => errors.push(message), onPromptSubmissionError: (error) => errors.push(String(error)), async onPromptSubmitted(prompt) { diff --git a/tests/desktop-mount-renderer-0721.test.mjs b/tests/desktop-mount-renderer-0721.test.mjs index 6b6099f9..8a3656bb 100644 --- a/tests/desktop-mount-renderer-0721.test.mjs +++ b/tests/desktop-mount-renderer-0721.test.mjs @@ -4,11 +4,12 @@ import { existsSync } from "node:fs"; import path from "node:path"; import { fileURLToPath } from "node:url"; import vm from "node:vm"; +import * as React from "react"; import { buildDesktopMountRenderer0721 } from "../scripts/lib/desktop-mount-renderer-0721.mjs"; const root = fileURLToPath(new URL("../", import.meta.url)); -const asarSkip = !existsSync(path.resolve(root, "../rea-grokbot-0721/asar/app.asar")) - && "0.72.1 snapshot is absent"; +const asarSkip = !existsSync(path.resolve(root, "../rea-grokbot-0755/asar/app.asar")) + && "0.75.5 snapshot is absent"; const options = { skip: asarSkip }; let factory; @@ -38,15 +39,16 @@ function fixture() { const client = { roster: { snapshots: roster }, experiments: { snapshots: experiments }, boot, desktopWindow: { ingestFocusAgent: input => calls.push(["focus", input]) }, drafts: { recoverDraft: (...args) => recoveries.push(args) } }; - const parts = factory({ client, React: {}, jsx: {}, compiler: {}, Menu: {}, Icon: {}, SourceFailure, + const parts = factory({ client, React, jsx: {}, compiler: {}, Menu: {}, Icon: {}, SourceFailure, agentName: agent => agent.name, useSnapshot: () => undefined, platform: "darwin", translate: () => "", sendPrompt: async (_client, input) => { calls.push(["send", input]); if (failure) throw new SourceFailure(failure); }, reportPromise: promise => { void promise.catch(() => {}); }, reportError: error => { throw error; } }); const source = { subscribe(next) { handlers = next; return () => { handlers = undefined; }; }, + async bindMainWindow() { return { snapshot: { mount: null }, submissions: [] }; }, async mount(target) { return { mount: target }; }, async unmount() { return { mount: null }; }, - async offerChoices(input) { choices.push(input); }, async offerPreview() {} }; + async offerChoices(input) { choices.push(input); }, async offerPreview() {}, async offerMarkState() {} }; const controller = parts.createController({ source, client, choicesOf: parts.choicesOf, - previewOf: parts.previewOf, discardStaged: path => discarded.push(path) }); + previewOf: parts.previewOf, markStateOf: parts.markStateOf, discardStaged: path => discarded.push(path) }); return { agent, parts, controller, calls, recoveries, discarded, choices, roster, experiments, emit: input => handlers["prompt-submitted"](input), fail: value => { failure = value; } }; } diff --git a/tests/desktop-runtime-0721.test.mjs b/tests/desktop-runtime-0721.test.mjs index efa6f084..48e918ae 100644 --- a/tests/desktop-runtime-0721.test.mjs +++ b/tests/desktop-runtime-0721.test.mjs @@ -12,8 +12,8 @@ const root = fileURLToPath(new URL("../", import.meta.url)); const evidence = path.resolve(process.env.DESKTOP_RUNTIME_0721_EVIDENCE_DIR ?? path.join(root, ".omo/evidence/desktop-runtime-0721")); const require = createRequire(import.meta.url); const record = (name, value) => writeFile(path.join(evidence, `${name}.json`), `${JSON.stringify(value, null, 2)}\n`); -const asarSkip = !existsSync(path.resolve(root, "../rea-grokbot-0721/asar/app.asar")) - && "0.72.1 snapshot is absent"; +const asarSkip = !existsSync(path.resolve(root, "../rea-grokbot-0755/asar/app.asar")) + && "0.75.5 snapshot is absent"; const asarOptions = { skip: asarSkip }; let api, upstream, catalogs; let electronLoads = 0; @@ -119,7 +119,7 @@ test("desktop rules use MainEdge host echo and rollback semantics", async () => test("real upstream roster consumes validated seeds, snapshots, upserts and activity", asarOptions, async () => { const failures = []; - const original = upstream({ electron: {}, translate: () => "", reportFailure: (...args) => failures.push(args) }); + const original = upstream({ electron: { app: { getAppPath: () => root } }, translate: () => "", reportFailure: (...args) => failures.push(args) }); const roster = original.createRoster(); const feed = api.createDesktop0721RosterFeed(() => roster); const agent = { id: "bot-a", name: "Bot A", updatedAt: 1, hasUnread: true, isRunning: false, isComposingMessage: false }; @@ -206,14 +206,16 @@ test("production desktop creates the original tray, switches a real coordinator constructor() { trays.push(this); } setIgnoreDoubleClickEvents() {} setToolTip() {} - setContextMenu(menu) { this.menu = menu; } + setContextMenu(menu) { this.menu = menu; this.menuUpdates = (this.menuUpdates ?? 0) + 1; } setImage() {} setTitle() {} destroy() { this.destroyed = true; trace.push("tray-disposed"); } } const electron = { trace, failMount: false, Tray, BrowserWindow: class {}, Notification: class { static isSupported() { return false; } }, Menu: { buildFromTemplate: (value) => value }, shell: { async openExternal() {} }, - app: { name: "Grok Node", quit() {}, getPreferredSystemLanguages: () => ["en"] }, + app: { name: "Grok Node", quit() {}, getAppPath: () => root, getPreferredSystemLanguages: () => ["en"] }, + nativeImage: { createFromPath: () => new Image(), createFromDataURL: () => new Image(), + createFromBuffer: () => new Image(), createEmpty: () => new Image() }, nativeImage: { createFromPath(file) { assert.ok(file.startsWith(path.join(mainRoot, "menubar-tray/assets"))); return new Image(); }, createFromDataURL: () => new Image(), createFromBuffer: () => new Image(), createEmpty: () => new Image() }, protocol: { registerSchemesAsPrivileged() { trace.push("scheme"); }, handle() { trace.push("protocol"); }, unhandle() { trace.push("protocol-disposed"); } }, @@ -225,6 +227,7 @@ test("production desktop creates the original tray, switches a real coordinator resources: { preloadPath: path.join(staged, "dist/electron-preload/primary.cjs") }, attachments: { stageBytes() {}, commitStaged() { promptSideEffects.push("commit"); }, discardStaged() { promptSideEffects.push("discard"); } }, settings: { settingsStore: store }, + accountLifecycle: { getAccountScope: () => null }, getMainWindow: () => ({ isMinimized: () => false, show() { trace.push("show"); }, focus() { trace.push("focus"); } }), coordinatorLegs: { legs: { async openAgent(args) { calls.push(args); }, async sendPrompt() { promptSideEffects.push("send"); } } }, requireMainEdge: () => ({ emit: (...args) => events.push(args) }), @@ -245,14 +248,34 @@ test("production desktop creates the original tray, switches a real coordinator assert.deepEqual(events, []); const auxiliary = runtime.createProductionCoordinatorAuxiliaryPorts(context, {}); const feed = auxiliary.events; - feed.onAgentsRosterSeed({ agents: [{ id: "selected-bot", name: "Selected Bot", updatedAt: 1, hasUnread: true, isRunning: false, isComposingMessage: false }] }); - trays[0].menu.find((item) => item.accelerator === "CommandOrControl+Shift+1").click(); + const rosterChanges = []; + desktop.roster.onChange(() => rosterChanges.push(desktop.roster.snapshot().length)); + const selectedAgent = { id: "selected-bot", name: "Selected Bot", updatedAt: 1, hasUnread: true, isRunning: false, isComposingMessage: false }; + feed.onAgentsRosterSeed({ agents: [selectedAgent] }); + feed.onAgentsEvent({ kind: "agent-upserted", event: { agent: { ...selectedAgent, name: "Selected Bot Updated" } } }); + desktop.roster.handleAgentUpsertedEvent({ agent: { ...selectedAgent, name: "Selected Bot Menu" } }); + assert.equal(desktop.roster.snapshot().length, 1, JSON.stringify(desktop.roster.snapshot())); + assert.ok(rosterChanges.length > 0, JSON.stringify(rosterChanges)); + function findMenuItem(items, label) { + for (const item of items) { + if (item.label === label) return item; + const nested = Array.isArray(item.submenu) ? findMenuItem(item.submenu, label) : undefined; + if (nested !== undefined) return nested; + } + return undefined; + } + const selectedBot = findMenuItem(trays[0].menu, "● Selected Bot Menu"); + const failureText = failures.map(([area, leg, error]) => [area, leg, error instanceof Error ? error.message : String(error)]); + assert.ok(selectedBot, `${JSON.stringify(trays[0].menu)}\n${JSON.stringify(failureText)}\nmenuUpdates=${trays[0].menuUpdates}`); + selectedBot.click(); await new Promise(setImmediate); assert.deepEqual(calls, [{ id: "selected-bot" }]); assert.deepEqual(events[0], ["focus-agent", { id: "selected-bot" }]); - trays[0].menu.find((item) => item.label === "Settings…").click(); + const settingsItem = findMenuItem(trays[0].menu, "Settings…"); + assert.ok(settingsItem, JSON.stringify(trays[0].menu)); + settingsItem.click(); assert.deepEqual(events[1], ["open-settings", {}]); - assert.equal(notificationFeeds.length, 1); + assert.equal(notificationFeeds.length, 2); auxiliary.resync.onHostSettingsTransportDown(); assert.deepEqual(desktop.roster.snapshot(), []); const preferences = { playSound: false, sound: "ping-4-chime-a" }; @@ -263,6 +286,7 @@ test("production desktop creates the original tray, switches a real coordinator assert.equal(runtime.readDesktop0721(), undefined); assert.equal(trays[0].destroyed, true); electron.failMount = true; + assert.equal(typeof require(path.join(mainRoot, "desktop-0721/upstream.cjs")).createDesktop0721Upstream, "function"); assert.throws(() => prepared.create(context, { settingsStore: store }), /mount failure/); assert.equal(runtime.readDesktop0721(), undefined); assert.equal(trays[1].destroyed, true); diff --git a/tests/github-releases-updater.test.mjs b/tests/github-releases-updater.test.mjs new file mode 100644 index 00000000..0f4bd902 --- /dev/null +++ b/tests/github-releases-updater.test.mjs @@ -0,0 +1,241 @@ +import assert from "node:assert/strict"; +import { readFileSync } from "node:fs"; +import path from "node:path"; +import test from "node:test"; + +// Behavioral + wiring guards for the reconstructed GitHub Releases updater. +// +// Why a mirror instead of importing the TS module: source/*.ts is typechecked +// via `npm run source:typecheck` (tsc, unavailable in dependency-free sandboxes) +// and cannot be imported by plain `node --test`. The pure mapping algorithm is +// therefore mirrored here in dependency-free JS, while every piece of DATA +// (repo, URLs, asset patterns) is extracted live from the TS source so pattern +// drift fails fast. Keep this file in sync with +// `source/electron-main/update/github-update-feed.ts`. + +const ROOT = path.resolve(import.meta.dirname, ".."); +const read = (rel) => readFileSync(path.join(ROOT, rel), "utf8"); + +const feedTs = () => read("source/electron-main/update/github-update-feed.ts"); +const serviceTs = () => read("source/electron-main/update/sand-update-service.ts"); + +function extractConstString(source, name) { + const m = source.match(new RegExp(`export const ${name} = "([^"]+)"`)); + assert.ok(m, `${name} must exist in github-update-feed.ts`); + return m[1]; +} + +function extractPattern(source, name) { + const m = source.match(new RegExp(`export const ${name} = (\/[^;]+\/);`)); + assert.ok(m, `${name} must exist in github-update-feed.ts`); + // eslint-disable-next-line no-eval + return eval(m[1]); +} + +// ---- Minimal ports of source/electron-main/update/update-version.ts ---- +const RELEASE_PATTERN = /^(\d+)\.(\d+)\.(\d+)$/; +function parseVersion(version) { + const hyphenIndex = version.indexOf("-"); + const releasePart = hyphenIndex === -1 ? version : version.slice(0, hyphenIndex); + const prereleasePart = hyphenIndex === -1 ? null : version.slice(hyphenIndex + 1); + const match = RELEASE_PATTERN.exec(releasePart); + if (match == null) return null; + const prerelease = prereleasePart == null ? [] : prereleasePart.split("."); + if (prerelease.some((id) => id.length === 0)) return null; + return { release: [Number(match[1]), Number(match[2]), Number(match[3])], prerelease }; +} +function compareVersionIdentifiers(a, b) { + const aIsNumeric = /^\d+$/.test(a); + const bIsNumeric = /^\d+$/.test(b); + if (aIsNumeric && bIsNumeric) return Math.sign(Number(a) - Number(b)); + if (aIsNumeric) return -1; + if (bIsNumeric) return 1; + return a < b ? -1 : a > b ? 1 : 0; +} +function compareVersions(a, b) { + const parsedA = parseVersion(a); + const parsedB = parseVersion(b); + if (parsedA == null || parsedB == null) throw new Error(`Cannot compare "${a}" and "${b}"`); + for (let i = 0; i < 3; i += 1) { + const diff = parsedA.release[i] - parsedB.release[i]; + if (diff !== 0) return Math.sign(diff); + } + if (parsedA.prerelease.length === 0 && parsedB.prerelease.length === 0) return 0; + if (parsedA.prerelease.length === 0) return 1; + if (parsedB.prerelease.length === 0) return -1; + const length = Math.min(parsedA.prerelease.length, parsedB.prerelease.length); + for (let i = 0; i < length; i += 1) { + const diff = compareVersionIdentifiers(parsedA.prerelease[i], parsedB.prerelease[i]); + if (diff !== 0) return diff; + } + return Math.sign(parsedA.prerelease.length - parsedB.prerelease.length); +} +const isNewerVersion = (candidate, current) => compareVersions(candidate, current) > 0; + +// ---- Mirror of github-update-feed.ts pure mapping (patterns read live) ---- +function normalizeTag(tag) { + if (typeof tag !== "string" || tag.length === 0) return null; + const version = tag.startsWith("v") || tag.startsWith("V") ? tag.slice(1) : tag; + if (version.length === 0) return null; + return parseVersion(version) == null ? null : version; +} +function patternFor(platform, patterns) { + if (platform === "darwin-arm64") return patterns.macArm64; + if (platform === "darwin-x64") return patterns.macX64; + if (platform.startsWith("win32")) return patterns.windows; + return null; +} +function findAsset(release, platform, patterns) { + const pattern = patternFor(platform, patterns); + if (pattern == null) return null; + for (const asset of release.assets ?? []) { + if (asset != null && typeof asset.name === "string" && typeof asset.browser_download_url === "string" && pattern.test(asset.name)) { + try { new URL(asset.browser_download_url); } catch { continue; } + return asset; + } + } + return null; +} +function mapRelease(release, platform, patterns, htmlFallback) { + if (release == null || typeof release !== "object" || release.draft === true) return null; + const version = normalizeTag(release.tag_name); + if (version == null) return null; + const asset = findAsset(release, platform, patterns); + if (asset == null) return null; + return { version, url: asset.browser_download_url, htmlUrl: typeof release.html_url === "string" && release.html_url.length > 0 ? release.html_url : htmlFallback }; +} +function selectNewest(releases, currentVersion, platform, patterns, htmlFallback) { + if (!Array.isArray(releases) || parseVersion(currentVersion) == null) return null; + const candidates = []; + for (const release of releases) { + const m = mapRelease(release, platform, patterns, htmlFallback); + if (m == null) continue; + try { if (isNewerVersion(m.version, currentVersion)) candidates.push(m); } catch { continue; } + } + candidates.sort((a, b) => compareVersions(b.version, a.version)); + return candidates[0] ?? null; +} +// Port of parseUpdateResponse squirrel-shape validation: adapter output must satisfy it. +function assertSquirrelShaped(payload) { + assert.equal(typeof payload, "object"); + new URL(payload.url); + assert.equal(typeof payload.name, "string"); + assert.ok(payload.name.length > 0); +} + +function fixtureRelease(tag, { draft = false, prerelease = false, assets = [], htmlSuffix = tag } = {}) { + return { + tag_name: tag, + html_url: `https://github.com/tyonger-stack/GrokNode/releases/tag/${htmlSuffix}`, + published_at: "2026-10-23T00:00:00Z", + draft, + prerelease, + assets, + }; +} +const macAsset = (version) => ({ + name: `Grok-Node-${version}-mac-arm64.zip`, + browser_download_url: `https://github.com/tyonger-stack/GrokNode/releases/download/v${version}/Grok-Node-${version}-mac-arm64.zip`, +}); + +test("github feed constants point at this repo, not the Cursor endpoint", () => { + const src = feedTs(); + assert.equal(extractConstString(src, "GITHUB_UPDATE_OWNER"), "tyonger-stack"); + assert.equal(extractConstString(src, "GITHUB_UPDATE_REPO"), "GrokNode"); + assert.equal(extractConstString(src, "DEFAULT_GITHUB_RELEASES_API_BASE"), "https://api.github.com/repos/tyonger-stack/GrokNode"); + assert.equal(extractConstString(src, "GITHUB_RELEASES_HTML_URL"), "https://github.com/tyonger-stack/GrokNode/releases"); + assert.ok(!src.includes("LEGACY_CURSOR_UPDATE_BASE_URL"), "github feed must not depend on the legacy Cursor base"); + assert.ok(!src.includes("/api/update/"), "github feed must not build Cursor-style update URLs"); + const svc = serviceTs(); + assert.ok(svc.includes("fetchGitHubUpdateManifest"), "service must fetch from the GitHub feed"); + assert.ok(svc.includes("isLegacyCursorFeedBaseUrl"), "service must keep the legacy override branch explicit"); +}); + +test("tag normalization strips leading v and validates reconstructed versions", () => { + assert.equal(normalizeTag("v0.75.3-reconstructed.6"), "0.75.3-reconstructed.6"); + assert.equal(normalizeTag("0.75.3-reconstructed.6"), "0.75.3-reconstructed.6"); + assert.equal(normalizeTag("V0.18.0-reconstructed.1"), "0.18.0-reconstructed.1"); + assert.equal(normalizeTag("not-a-version"), null); + assert.equal(normalizeTag(""), null); + assert.equal(normalizeTag("v"), null); +}); + +test("reconstructed version ordering recognizes 0.75.3-reconstructed.N as newer", () => { + assert.ok(isNewerVersion("0.75.3-reconstructed.6", "0.18.0-reconstructed.1")); + assert.ok(isNewerVersion("0.75.3-reconstructed.6", "0.75.3-reconstructed.5")); + assert.ok(!isNewerVersion("0.75.3-reconstructed.6", "0.75.3-reconstructed.6")); + assert.ok(!isNewerVersion("0.18.0-reconstructed.1", "0.75.3-reconstructed.6")); +}); + +test("asset matching only accepts the mac-arm64 zip for darwin-arm64", () => { + const src = feedTs(); + const patterns = { + macArm64: extractPattern(src, "GITHUB_MAC_ARM64_ASSET_PATTERN"), + macX64: extractPattern(src, "GITHUB_MAC_X64_ASSET_PATTERN"), + windows: extractPattern(src, "GITHUB_WINDOWS_ASSET_PATTERN"), + }; + const htmlFallback = extractConstString(src, "GITHUB_RELEASES_HTML_URL"); + const release = fixtureRelease("v0.75.3-reconstructed.6", { assets: [macAsset("0.75.3-reconstructed.6")] }); + const mapped = mapRelease(release, "darwin-arm64", patterns, htmlFallback); + assert.ok(mapped); + assert.equal(mapped.version, "0.75.3-reconstructed.6"); + assertSquirrelShaped({ url: mapped.url, name: mapped.version }); + // Wrong platform / wrong asset name -> no offer (honest gap, not an error). + assert.equal(mapRelease(release, "win32-x64-user", patterns, htmlFallback), null); + assert.equal(mapRelease(fixtureRelease("v0.75.3-reconstructed.6", { assets: [{ name: "notes.txt", browser_download_url: "https://example.com/notes.txt" }] }), "darwin-arm64", patterns, htmlFallback), null); + assert.equal(mapRelease(fixtureRelease("v0.75.3-reconstructed.6", { draft: true, assets: [macAsset("0.75.3-reconstructed.6")] }), "darwin-arm64", patterns, htmlFallback), null); + assert.equal(mapRelease(fixtureRelease("bad-tag", { assets: [macAsset("0.75.3-reconstructed.6")] }), "darwin-arm64", patterns, htmlFallback), null); +}); + +test("newest-offer selection prefers the latest newer release and skips drafts", () => { + const src = feedTs(); + const patterns = { + macArm64: extractPattern(src, "GITHUB_MAC_ARM64_ASSET_PATTERN"), + macX64: extractPattern(src, "GITHUB_MAC_X64_ASSET_PATTERN"), + windows: extractPattern(src, "GITHUB_WINDOWS_ASSET_PATTERN"), + }; + const htmlFallback = extractConstString(src, "GITHUB_RELEASES_HTML_URL"); + const releases = [ + fixtureRelease("v0.75.3-reconstructed.6", { assets: [macAsset("0.75.3-reconstructed.6")] }), + fixtureRelease("v0.75.3-reconstructed.5", { assets: [macAsset("0.75.3-reconstructed.5")] }), + fixtureRelease("v9.9.9", { draft: true, assets: [{ name: "Grok-Node-9.9.9-mac-arm64.zip", browser_download_url: "https://example.com/9.zip" }] }), + fixtureRelease("v0.18.0-reconstructed.1", { assets: [macAsset("0.18.0-reconstructed.1")] }), + ]; + const newest = selectNewest(releases, "0.18.0-reconstructed.1", "darwin-arm64", patterns, htmlFallback); + assert.ok(newest); + assert.equal(newest.version, "0.75.3-reconstructed.6"); + assertSquirrelShaped({ url: newest.url, name: newest.version }); + assert.equal(selectNewest(releases, "0.75.3-reconstructed.6", "darwin-arm64", patterns, htmlFallback), null); + assert.equal(selectNewest(releases, "0.18.0-reconstructed.1", "win32-x64-user", patterns, htmlFallback), null); +}); + +test("service exposes releases fallback metadata and keeps the legacy branch", () => { + const svc = serviceTs(); + assert.ok(svc.includes("releasesUrl: GITHUB_RELEASES_HTML_URL"), "status must carry the Releases fallback URL"); + assert.ok(svc.includes("githubRelease"), "status must carry the resolved GitHub offer"); + assert.ok(svc.includes("lastGitHubTargetVersion"), "service must remember the last GitHub offer for the UI"); + // No silent default back to Cursor: DEFAULT_UPDATE_BASE_URL appears only in the import + // and inside the explicit legacy-override branch (never as an implicit fetch default). + assert.ok(svc.includes("isLegacyCursorFeedBaseUrl(this.options.feedBaseUrl)")); + const legacyBranchUses = svc.split("buildUpdateRequestUrl(this.options.feedBaseUrl ?? DEFAULT_UPDATE_BASE_URL").length - 1; + assert.equal(legacyBranchUses, 1); +}); + +test("packaging guard leaves updates enabled but telemetry/sentry off", () => { + const guard = read("scripts/lib/build-asar.mjs"); + // NOTE: build-asar.mjs stores the guard lines escaped (backslash-quote) inside a JS + // string literal, so match on the env names rather than the evaluated bytes. + assert.ok(!guard.includes('SAND_DISABLE_UPDATES'), "guard must not force SAND_DISABLE_UPDATES=1"); + assert.ok(guard.includes('SAND_DISABLE_SENTRY')); + assert.ok(guard.includes('SAND_DISABLE_TELEMETRY')); + assert.ok(guard.includes("GitHub Releases")); +}); + +test("settings UI always offers the Releases fallback link", () => { + const updates = read("frontend/src/recovered/features/settings/overlay/updates.ts"); + const panels = read("frontend/src/recovered/features/settings/overlay/panels.tsx"); + assert.ok(updates.includes('GITHUB_RELEASES_URL = "https://github.com/tyonger-stack/GrokNode/releases"')); + assert.ok(panels.includes("GITHUB_RELEASES_URL"), "panel must reference the fallback URL"); + assert.ok(panels.includes("githubRelease"), "panel must render the resolved offer when present"); + assert.ok(panels.includes("GitHub Releases")); +}); diff --git a/tests/port-0750-renderer-patch.test.mjs b/tests/port-0750-renderer-patch.test.mjs index 395aa9c0..41019a8b 100644 --- a/tests/port-0750-renderer-patch.test.mjs +++ b/tests/port-0750-renderer-patch.test.mjs @@ -78,8 +78,7 @@ test("settings and plugins bundles mount the recovered hosts on the chunk React" buildPort0750HostBundle("settings"), buildPort0750HostBundle("plugins"), ]); - assert.match(settingsBundle, /Choose file/); - assert.match(settingsBundle, /New card/); + assert.doesNotMatch(settingsBundle, /Choose file|New card/); assert.match(settingsBundle, /\(de,a\);$/); assert.match(pluginsBundle, /Plugins in effect/); assert.match(pluginsBundle, /Custom MCP servers/); @@ -88,9 +87,7 @@ test("settings and plugins bundles mount the recovered hosts on the chunk React" assert.doesNotMatch(pluginsBundle, /createRoot\(/); const settings = await renderPack(settingsBundle, "RPort0750Settings", { de: React, a: jsxRuntime }); - assert.ok(settings.host.querySelector("[aria-label='Choose file']")); - assert.equal(settings.host.querySelector("[aria-label='Choose file']").type, "file"); - assert.ok(settings.host.querySelector("[aria-label='New card']")); + assert.equal(settings.host.querySelectorAll("button, input, textarea").length, 0); await React.act(async () => { settings.root.unmount(); }); const plugins = await renderPack(pluginsBundle, "RPort0750Plugins", { C: React, t: jsxRuntime }); diff --git a/tests/reconstructed-updater-guard.test.mjs b/tests/reconstructed-updater-guard.test.mjs index 7a020b0e..322c3abd 100644 --- a/tests/reconstructed-updater-guard.test.mjs +++ b/tests/reconstructed-updater-guard.test.mjs @@ -16,9 +16,12 @@ test("reconstructed fallback and clean packaging share one idempotent service gu const guarded = applyReconstructedUpdaterGuard(source); assert.equal(guarded, `${reconstructedUpdaterGuard}${source}`); assert.equal(applyReconstructedUpdaterGuard(guarded), guarded); - assert.match(guarded, /SAND_DISABLE_UPDATES \?\?= "1"/); + // GitHub Releases updater: updates stay ENABLED on reconstructed builds, so the + // guard must not force SAND_DISABLE_UPDATES. Sentry/telemetry stay off. + assert.ok(!guarded.includes('SAND_DISABLE_UPDATES'), "guard must not disable updates (GitHub Releases feed)"); assert.match(guarded, /SAND_DISABLE_SENTRY \?\?= "1"/); assert.match(guarded, /SAND_DISABLE_TELEMETRY \?\?= "1"/); + assert.match(reconstructedUpdaterGuard, /GitHub Releases/); const fallbackFixture = [ "var isSandLabBuild2 = appPackageJson.sandLab === true;", diff --git a/tests/settings-menu-hidden-0721.test.mjs b/tests/settings-menu-hidden-0721.test.mjs index b450b313..59623f4c 100644 --- a/tests/settings-menu-hidden-0721.test.mjs +++ b/tests/settings-menu-hidden-0721.test.mjs @@ -6,10 +6,9 @@ import { fileURLToPath } from "node:url"; const cleanBuild = path.resolve(path.dirname(fileURLToPath(import.meta.url)), "../scripts/clean-build.mjs"); -test("packaged settings do not mount the Vault or Local teams menus", async () => { +test("packaged settings mount Vault while Local teams remains hidden", async () => { const source = await readFile(cleanBuild, "utf8"); assert.doesNotMatch(source, /applyLocalTeamsRendererPatch\(/); - assert.doesNotMatch(source, /applyVaultSettingsRenderer0721\(/); + assert.match(source, /applyVaultSettingsRenderer0721\(/); assert.doesNotMatch(source, /Local teams & Tailnet/); - assert.doesNotMatch(source, /label:"Vault"/); }); diff --git a/tests/upstream-0721.test.mjs b/tests/upstream-0721.test.mjs index 0de08fea..b1bcb64e 100644 --- a/tests/upstream-0721.test.mjs +++ b/tests/upstream-0721.test.mjs @@ -5,14 +5,14 @@ import os from "node:os"; import path from "node:path"; import { fileURLToPath } from "node:url"; import { test } from "node:test"; -import { openUpstream0721 } from "../scripts/lib/upstream-0721.mjs"; +import { openUpstream0755 } from "../scripts/lib/upstream-0755.mjs"; -const snapshot = fileURLToPath(new URL("../../rea-grokbot-0721/asar/app.asar", import.meta.url)); +const snapshot = fileURLToPath(new URL("../../rea-grokbot-0755/asar/app.asar", import.meta.url)); const nativePath = "dist/deps/sand-window-capture/build/Release/sand_window_capture.node"; -const options = { skip: !existsSync(snapshot) && "0.72.1 snapshot is absent" }; +const options = { skip: !existsSync(snapshot) && "0.75.5 snapshot is absent" }; -test("0.72.1 reader returns exact packed source and independently pinned native bytes", options, async () => { - const archive = await openUpstream0721({ asarPath: snapshot }); +test("0.75.5 reader returns exact packed source and independently pinned native bytes", options, async () => { + const archive = await openUpstream0755({ asarPath: snapshot }); const source = archive.read("dist/electron-preload/preload-desktop-mount-capture-overlay.cjs"); assert.ok(source.includes(Buffer.from("desktopMountCaptureOverlay"))); assert.deepEqual(await archive.readNative(nativePath), await readFile(`${snapshot}.unpacked/${nativePath}`)); @@ -20,18 +20,18 @@ test("0.72.1 reader returns exact packed source and independently pinned native assert.throws(() => archive.read("../package.json"), /Invalid upstream artifact path/); }); -test("0.72.1 reader rejects an altered archive before reading any member", async () => { +test("0.75.5 reader rejects an altered archive before reading any member", async () => { const root = await mkdtemp(path.join(os.tmpdir(), "grok-0721-archive-")); try { const archive = path.join(root, "app.asar"); await writeFile(archive, "untrusted replacement"); - await assert.rejects(openUpstream0721({ asarPath: archive }), /ASAR checksum mismatch/); + await assert.rejects(openUpstream0755({ asarPath: archive }), /ASAR checksum mismatch/); } finally { await rm(root, { recursive: true, force: true }); } }); -test("0.72.1 reader rejects tampered unpacked native bytes with an intact ASAR", options, async () => { +test("0.75.5 reader rejects tampered unpacked native bytes with an intact ASAR", options, async () => { const root = await mkdtemp(path.join(os.tmpdir(), "grok-0721-native-")); try { const archivePath = path.join(root, "app.asar"); @@ -39,7 +39,7 @@ test("0.72.1 reader rejects tampered unpacked native bytes with an intact ASAR", const nativeTarget = `${archivePath}.unpacked/${nativePath}`; await mkdir(path.dirname(nativeTarget), { recursive: true }); await writeFile(nativeTarget, "tampered addon"); - const archive = await openUpstream0721({ asarPath: archivePath }); + const archive = await openUpstream0755({ asarPath: archivePath }); await assert.rejects(archive.readNative(nativePath), /native snapshot checksum mismatch/); await assert.rejects(archive.readNative("dist/deps/unpinned.node"), /Unpinned upstream native artifact/); } finally { diff --git a/tests/vault-local-0721.test.mjs b/tests/vault-local-0721.test.mjs index 873e2594..cb26724b 100644 --- a/tests/vault-local-0721.test.mjs +++ b/tests/vault-local-0721.test.mjs @@ -1,7 +1,7 @@ import assert from "node:assert/strict"; import { createCipheriv, createDecipheriv, createHash, randomBytes } from "node:crypto"; import { mkdirSync, writeFileSync } from "node:fs"; -import { mkdir, stat } from "node:fs/promises"; +import { mkdir, readFile, stat, writeFile } from "node:fs/promises"; import { createRequire } from "node:module"; import os from "node:os"; import path from "node:path"; @@ -99,7 +99,7 @@ test("upstream CSV planner and payment-card checks are extracted from the pinned const source = await import("node:fs/promises").then((fs) => fs.readFile( path.join(root, "source/electron-main/vault/upstream-vault-parsers.generated.mjs"), "utf8")); assert.match(source, /Generated by scripts\/lib\/vault-0721\.mjs/); - assert.match(source, /b272ee13db0fb9106f9276a46a8e47baf688c8d5ac1b1dc400df6fcba9e76996/); + assert.match(source, /12bba50ba6cf12b35132518788610677a3fdc65de4ad849628d757bc7b780e5a/); record("upstream-parsers", { format: parsed.format, status: parsed.rows[0].preview.status.kind }); }); @@ -142,6 +142,11 @@ test("local Vault persists encrypted account data with metadata-only listings an }, }); assert.equal(contact.contact?.defaultShipping, true); + const sessionSnapshot = await vault.sessionSnapshot(); + assert.deepEqual(sessionSnapshot.logins.map((item) => item.password), ["synthetic-password"]); + assert.deepEqual(sessionSnapshot.contacts.map((item) => item.email), ["contact@example.test"]); + assert.equal(Object.hasOwn(sessionSnapshot, "cards"), false); + assert.equal(JSON.stringify(sessionSnapshot).includes("4242"), false); await vault.deleteGrokBotVaultCredential(contact.id); const listed = await vault.listGrokBotVaultCredentials(); assert.equal(listed.length, 2); @@ -225,13 +230,23 @@ test("card updates and local native photo reads use bounded local bytes only", a const updated = await vault.updateGrokBotVaultCard({ id: card.id, holderName: "Synthetic User", + nickname: "Work card", expiry: "01/30", billingAddress: { line1: "1 Main St", line2: "", city: "City", region: "Region", postalCode: "00000", country: "US" }, billingAddressId: "address-1", }); assert.equal(updated.card.holderName, "Synthetic User"); + assert.equal(updated.card.nickname, "Work card"); assert.equal(updated.card.expMonth, 1); assert.equal(updated.card.billingAddress.line1, "1 Main St"); + const preserved = await vault.updateGrokBotVaultCard({ + id: card.id, + holderName: "Synthetic User", + expiry: "01/30", + billingAddress: { line1: "1 Main St", line2: "", city: "City", region: "Region", postalCode: "00000", country: "US" }, + billingAddressId: "address-1", + }); + assert.equal(preserved.card.nickname, "Work card"); const image = new Uint8Array([1, 2, 3, 4]); const originalFetch = globalThis.fetch; @@ -257,3 +272,18 @@ test("card updates and local native photo reads use bounded local bytes only", a networkSends: 0, }); }); + +test("stored cards created before nickname support remain readable", async (t) => { + const modules = await loadModules(); + const temporary = await import("node:fs/promises").then((fs) => fs.mkdtemp(path.join(os.tmpdir(), "vault-legacy-card-"))); + t.after(async () => import("node:fs/promises").then((fs) => fs.rm(temporary, { recursive: true, force: true }))); + const storePath = path.join(temporary, "grok-bot-vault.json"); + const vault = backendFor(modules, storePath); + await vault.createGrokBotVaultCard({ values: { cc_number: "4242424242424242", cc_exp: "12/29" } }); + const stored = JSON.parse(await readFile(storePath, "utf8")); + const card = Object.values(stored.accounts)[0].find((item) => item.kind === "card"); + delete card.nickname; + await writeFile(storePath, JSON.stringify(stored), "utf8"); + const reopened = backendFor(modules, storePath).listGrokBotVaultCredentials(); + assert.equal((await reopened)[0].card?.nickname, ""); +}); diff --git a/tests/vault-renderer-0721.test.mjs b/tests/vault-renderer-0721.test.mjs index 5d16aa2b..9696c957 100644 --- a/tests/vault-renderer-0721.test.mjs +++ b/tests/vault-renderer-0721.test.mjs @@ -18,9 +18,9 @@ import { } from "../scripts/lib/vault-renderer-patch.mjs"; const repoRoot = path.resolve(path.dirname(fileURLToPath(import.meta.url)), ".."); -const asarSkip = !existsSync(path.resolve(repoRoot, "../rea-grokbot-0721/asar/app.asar")) - && "0.72.1 snapshot is absent"; -const window = new Window(); +const asarSkip = !existsSync(path.resolve(repoRoot, "../rea-grokbot-0755/asar/app.asar")) + && "0.75.5 snapshot is absent"; +const window = new Window({ url: "http://localhost/" }); for (const name of ["window", "document", "HTMLElement", "HTMLInputElement", "HTMLSelectElement", "Element", "Node", "MutationObserver", "getComputedStyle", "performance"]) { globalThis[name] = name === "window" ? window : name === "getComputedStyle" ? window.getComputedStyle.bind(window) : window[name] ?? globalThis[name]; } @@ -88,7 +88,7 @@ async function loadHost() { function credential() { return [ { id: "login-1", title: "Example", username: "user@example.test", notes: "", sites: ["https://example.com"], createdAtMs: 1, updatedAtMs: 1 }, - { id: "card-1", title: "Card 4242", username: "", notes: "", sites: [], card: { brand: "visa", last4: "4242", expMonth: 12, expYear: 2029, holderName: "Synthetic User", billingAddressId: "", billingAddress: { line1: "", line2: "", city: "", region: "", postalCode: "", country: "" } }, createdAtMs: 1, updatedAtMs: 1 }, + { id: "card-1", title: "Card 4242", username: "", notes: "", sites: [], card: { brand: "visa", last4: "4242", expMonth: 12, expYear: 2029, holderName: "Synthetic User", nickname: "", billingAddressId: "", billingAddress: { line1: "", line2: "", city: "", region: "", postalCode: "", country: "" } }, createdAtMs: 1, updatedAtMs: 1 }, { id: "contact-1", title: "Billing contact", username: "", notes: "", sites: [], contact: { name: "Synthetic Contact", line1: "", line2: "", city: "", region: "", postalCode: "", country: "", phone: "", email: "contact@example.test", defaultShipping: true }, createdAtMs: 1, updatedAtMs: 1 }, ]; } @@ -141,15 +141,16 @@ async function render(t, ui, Host) { await closeLibraryDom(window); }); await ui.act(async () => root.render(ui.createElement(Host, {}))); - for (let index = 0; index < 6; index += 1) { + for (let index = 0; index < 20; index += 1) { await ui.act(async () => { - await new Promise((resolve) => setTimeout(resolve, 0)); + await new Promise((resolve) => setTimeout(resolve, 10)); }); + if ((host.textContent ?? "").length > 0) break; } return host; } -test("original 0721 Vault settings render list, cards, and contacts through the local bridge", { skip: asarSkip }, async (t) => { +test("original 0.75.5 Vault settings render list, cards, and contacts through the local bridge", { skip: asarSkip }, async (t) => { const ui = { createElement: React.createElement, createRoot, act: React.act }; const { built, host: Host } = await loadHost(); const desktop = mockDesktop(); @@ -157,14 +158,16 @@ test("original 0721 Vault settings render list, cards, and contacts through the const host = await render(t, ui, Host); const text = host.textContent ?? ""; assert.equal(desktop.calls.list >= 1, true); - assert.equal(text.includes("example.com"), true, host.outerHTML); + const state = window.__sandVault0721Client?.grokBotVault.snapshots.get(); + assert.equal(text.includes("example.com"), true, `${host.outerHTML}\n${JSON.stringify(state)}`); assert.equal(text.includes("user@example.test"), true); assert.equal(text.includes("visa"), true); assert.equal(text.includes("Synthetic Contact"), true); assert.equal(host.querySelectorAll("button").length > 3, true); + assert.equal(text.includes("New item"), true, "Vault settings must render the official create menu in the pane header portal"); assert.equal(built.bundle.includes(VAULT_RENDERER_MARK), true); assert.equal(/createRoot\s*\(/u.test(built.bundle), false); - assert.equal(/new\s+MutationObserver/u.test(built.bundle), false); + assert.equal(/new\s+MutationObserver[\s\S]{0,320}\.observe\(\s*(?:document\.(?:body|documentElement)|window)\b/u.test(built.bundle), false); record("vault-render-host", host.outerHTML); record("vault-render-summary", { bundleBytes: built.bundle.length, @@ -199,6 +202,6 @@ test("generated original module preserves the pinned CSV reader and planner clos assert.match(source, /login_uri|login_username|login_password/); assert.match(source, /NoteType:Credit Card/); assert.match(source, /batchCreateGrokBotVaultCredentials|createGrokBotVaultLogins/); - assert.match(source, /b272ee13db0fb9106f9276a46a8e47baf688c8d5ac1b1dc400df6fcba9e76996/); + assert.match(source, /12bba50ba6cf12b35132518788610677a3fdc65de4ad849628d757bc7b780e5a/); }); diff --git a/tests/vault-session-context.test.mjs b/tests/vault-session-context.test.mjs new file mode 100644 index 00000000..b8b6f87f --- /dev/null +++ b/tests/vault-session-context.test.mjs @@ -0,0 +1,165 @@ +import assert from "node:assert/strict"; +import { mkdir, mkdtemp, readFile, rm } from "node:fs/promises"; +import { createRequire } from "node:module"; +import os from "node:os"; +import path from "node:path"; +import test from "node:test"; +import { fileURLToPath } from "node:url"; +import { build } from "esbuild"; + +const root = fileURLToPath(new URL("../", import.meta.url)); +const output = path.join(root, "node_modules/.cache/vault-session-context.cjs"); + +async function load() { + await mkdir(path.dirname(output), { recursive: true }); + await build({ + stdin: { + contents: [ + 'export {parseVaultSessionSnapshot} from "./source/shared/vault.ts";', + 'export {createContextTools, renderVaultCatalog, renderVaultLogin} from "./source/host/runner/tools/context-tools.ts";', + 'export {SettingsService} from "./source/host/extensions/settings/settings-service.ts";', + 'export {createLocalBackendHandlers0721} from "./source/electron-main/local-backend-handlers-0721.ts";', + 'export {canUseGrokBotVault} from "./source/host/runner/vault-session-access.ts";', + ].join("\n"), + resolveDir: root, + loader: "ts", + }, + outfile: output, + bundle: true, + platform: "node", + format: "cjs", + packages: "external", + logLevel: "error", + }); + return createRequire(import.meta.url)(output); +} + +const snapshot = { + version: 1, + updatedAtMs: 1000, + logins: [{ + id: "login-1", + title: "Example", + username: "user@example.test", + notes: "private note", + sites: ["https://example.com"], + password: "synthetic-password", + updatedAtMs: 1000, + card: { number: "4242424242424242", securityCode: "123" }, + }], + contacts: [{ + id: "contact-1", + title: "Office", + name: "Synthetic User", + line1: "1 Example Way", + line2: "", + city: "Example City", + region: "CA", + postalCode: "00000", + country: "US", + phone: "555-0100", + email: "user@example.test", + defaultShipping: true, + updatedAtMs: 1000, + }], +}; + +test("session Vault context keeps login/contact data and strips cards", async () => { + const modules = await load(); + const parsed = modules.parseVaultSessionSnapshot(snapshot); + assert.equal(parsed.logins[0].password, "synthetic-password"); + assert.equal(parsed.contacts[0].phone, "555-0100"); + assert.equal(JSON.stringify(parsed).includes("4242424242424242"), false); + assert.equal(JSON.stringify(parsed).includes("securityCode"), false); + assert.equal(modules.parseVaultSessionSnapshot({ ...snapshot, logins: [{ ...snapshot.logins[0], password: 42 }] }), null); +}); + +test("Vault tools separate metadata lookup from password resolution", async () => { + const modules = await load(); + const parsed = modules.parseVaultSessionSnapshot(snapshot); + const tools = modules.createContextTools({ + state: { writeMemory: async () => ({ ok: true, detail: "saved" }), removeMemory: async () => ({ ok: true, detail: "removed" }) }, + selfId: "agent-1", + listFacts: () => [], + loadTranscript: async () => null, + related: () => [], + vault: () => parsed, + }); + const names = tools.map((tool) => tool.name); + assert.equal(names.includes("vault_list"), true); + assert.equal(names.includes("vault_get_login"), true); + const catalog = JSON.parse(modules.renderVaultCatalog(parsed)); + assert.equal(JSON.stringify(catalog).includes("synthetic-password"), false); + assert.equal(JSON.stringify(catalog).includes("private note"), false); + assert.equal(catalog.logins[0].username, "user@example.test"); + assert.equal(JSON.parse(modules.renderVaultLogin(parsed, "login-1")).password, "synthetic-password"); + assert.throws(() => modules.renderVaultLogin(parsed, "missing"), /No saved Vault login/); +}); + +test("session Vault context stays in memory and out of host settings reads", async (t) => { + const modules = await load(); + const temporary = await mkdtemp(path.join(os.tmpdir(), "vault-session-settings-")); + t.after(() => rm(temporary, { recursive: true, force: true })); + const settingsPath = path.join(temporary, "settings.json"); + const service = new modules.SettingsService(settingsPath); + const parsed = modules.parseVaultSessionSnapshot(snapshot); + service.setHostSettings({ grokBotVaultContext: parsed }); + assert.equal(service.getGrokBotVaultContext().logins[0].password, "synthetic-password"); + assert.equal(Object.hasOwn(service.getHostSettings(), "grokBotVaultContext"), false); + const notificationsBefore = service.getHostSettings().notifications; + assert.throws(() => service.setHostSettings({ + notifications: { isEnabled: true }, + grokBotVaultContext: { version: 1, logins: "malformed", contacts: [] }, + }), /Invalid Grok Bot Vault session context/); + assert.deepEqual(service.getHostSettings().notifications, notificationsBefore); + assert.equal(service.getGrokBotVaultContext(), undefined); + const raw = await readFile(settingsPath, "utf8"); + assert.equal(raw.includes("synthetic-password"), false); + assert.equal(raw.includes("grokBotVaultContext"), false); +}); + +test("Vault settings use the shipped 0.75.5 privacy and empty-state copy", async () => { + const { upstreamVaultMessages0755 } = await import("../frontend/src/recovered/features/vault/upstream-vault-messages-0755.mjs"); + const { upstreamVaultMessages } = await import("../frontend/src/recovered/features/vault/upstream-vault-messages.generated.mjs"); + assert.equal(upstreamVaultMessages0755.en.PgseLK[0], + "Grok Bot never sees a saved card's number or security code. It can see logins and contact info so it can type them in for you."); + assert.equal(upstreamVaultMessages0755["zh-CN"].PgseLK[0], + "Grok Bot 永远看不到已保存卡片的卡号或安全码。它可以查看登录信息和联系信息,以便替你填写。"); + assert.match(upstreamVaultMessages0755["zh-CN"].mx2Qib[0], /新项目/); + assert.equal(upstreamVaultMessages["zh-CN"].NLLW52[0], "登录信息"); + assert.equal(upstreamVaultMessages["zh-CN"].Ccpbzh[0], "卡片"); + assert.equal(upstreamVaultMessages["zh-CN"].OBRLoG[0], "联系信息"); + assert.equal(upstreamVaultMessages["zh-CN"]["R/b23j"][0], "搜索保险库"); + assert.equal(upstreamVaultMessages["zh-CN"]["2HFHfz"][0], + "Grok Bot 永远看不到已保存卡片的卡号或安全码。它可以看到登录信息和联系信息,以便替你填写。"); +}); + +test("Vault IPC rejects values outside the local backend bounds", async () => { + const modules = await load(); + let writes = 0; + const handlers = modules.createLocalBackendHandlers0721(() => ({ + vault: { + putGrokBotVaultCredential: async () => { writes += 1; }, + createGrokBotVaultLogins: async () => { writes += 1; return []; }, + }, + })); + assert.throws(() => handlers.putGrokBotVaultCredential({ + id: "login-1", title: "Example", username: "user@example.test", notes: "", + sites: Array.from({ length: 11 }, () => "example.com"), password: "synthetic-password", + })); + assert.throws(() => handlers.createGrokBotVaultLogins({ + logins: Array.from({ length: 1001 }, () => ({ + title: "Example", username: "user@example.test", notes: "", sites: ["example.com"], password: "x", + })), + })); + assert.equal(writes, 0); +}); + +test("Vault session access is limited to the primary one-to-one agent", async () => { + const modules = await load(); + const base = { isSharedRoomTurn: false, isSubagentRunner: false, agentId: "agent-1", sessionId: "agent-1" }; + assert.equal(modules.canUseGrokBotVault(base), true); + assert.equal(modules.canUseGrokBotVault({ ...base, isSharedRoomTurn: true }), false); + assert.equal(modules.canUseGrokBotVault({ ...base, isSubagentRunner: true }), false); + assert.equal(modules.canUseGrokBotVault({ ...base, agentId: "child-agent" }), false); +}); diff --git a/tests/visualization-0721.test.mjs b/tests/visualization-0721.test.mjs index 867587c2..945b9f8f 100644 --- a/tests/visualization-0721.test.mjs +++ b/tests/visualization-0721.test.mjs @@ -7,10 +7,10 @@ import { fileURLToPath, pathToFileURL } from "node:url"; import { test } from "node:test"; import { stageVisualization0721 } from "../scripts/lib/visualization-0721.mjs"; -const snapshot = fileURLToPath(new URL("../../rea-grokbot-0721/asar/app.asar", import.meta.url)); +const snapshot = fileURLToPath(new URL("../../rea-grokbot-0755/asar/app.asar", import.meta.url)); test("transplanted SandViz builds a sealed D3 document and validates actual frame messages", { - skip: !existsSync(snapshot) && "0.72.1 snapshot is absent", + skip: !existsSync(snapshot) && "0.75.5 snapshot is absent", }, async () => { const root = await mkdtemp(path.join(os.tmpdir(), "grok-sandviz-")); try { @@ -36,10 +36,10 @@ test("transplanted SandViz builds a sealed D3 document and validates actual fram assert.deepEqual(runtime.parseVisualizationFrameMessage({ type: "visualization-height", height: 123.5 }), { kind: "height", contentHeightPx: 124 }); assert.equal(runtime.parseVisualizationFrameMessage({ type: "visualization-height", height: -1 }), null); - assert.equal(runtime.parseVisualizationFrameMessage({ type: "visualization-state", state: '{"answer":42}' }).stateJson, - '{"answer":42}'); - const circular = {}; circular.self = circular; - assert.equal(runtime.parseVisualizationFrameMessage({ type: "visualization-state", state: circular }), null); + assert.equal(runtime.parseVisualizationFrameMessage({ type: "visualization-state", state: '{"answer":42}' }), null); + assert.deepEqual(runtime.parseVisualizationFrameMessage({ type: "visualization-wheel", deltaY: 18 }), { + kind: "wheel", deltaMode: 0, deltaX: 0, deltaY: 18, + }); assert.equal(runtime.parseVisualizationFrameMessage({ type: "openExternal", url: "https://example.com" }), null); assert.ok(provenance.modules.every((module) => module.inputSha256.length === 64)); assert.ok(provenance.modules.every((module) => !module.path.includes("index.eager-app")));