beadscope 0.5.0 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.next/BUILD_ID +1 -1
- package/.next/build-manifest.json +3 -3
- package/.next/fallback-build-manifest.json +3 -3
- package/.next/next-server.js.nft.json +1 -1
- package/.next/prerender-manifest.json +4 -4
- package/.next/required-server-files.js +8 -8
- package/.next/required-server-files.json +8 -8
- package/.next/server/app/_global-error.html +1 -1
- package/.next/server/app/_global-error.rsc +1 -1
- package/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/server/app/_not-found/page.js.nft.json +1 -1
- package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/server/app/_not-found.html +2 -2
- package/.next/server/app/_not-found.rsc +4 -4
- package/.next/server/app/_not-found.segments/_full.segment.rsc +4 -4
- package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +4 -4
- package/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/.next/server/app/api/config/route.js.nft.json +1 -1
- package/.next/server/app/api/fs/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/activity/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/attachments/[...path]/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/attachments/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/[id]/archive/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/[id]/assist/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/[id]/comments/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/[id]/deps/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/[id]/gate/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/[id]/human/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/[id]/status/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/beads/stream/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/doctor/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/gamification/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/insights/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/order/route.js.nft.json +1 -1
- package/.next/server/app/api/p/[projectId]/publish/route.js.nft.json +1 -1
- package/.next/server/app/api/projects/[id]/route.js.nft.json +1 -1
- package/.next/server/app/api/projects/route.js.nft.json +1 -1
- package/.next/server/app/api/telemetry/route.js.nft.json +1 -1
- package/.next/server/app/api/update/check/route.js +3 -3
- package/.next/server/app/api/update/check/route.js.nft.json +1 -1
- package/.next/server/app/api/update/run/route.js +3 -3
- package/.next/server/app/api/update/run/route.js.nft.json +1 -1
- package/.next/server/app/api/viewer-mode/route.js.nft.json +1 -1
- package/.next/server/app/index.html +2 -2
- package/.next/server/app/index.rsc +7 -7
- package/.next/server/app/index.segments/__PAGE__.segment.rsc +7 -7
- package/.next/server/app/index.segments/_full.segment.rsc +7 -7
- package/.next/server/app/index.segments/_tree.segment.rsc +2 -2
- package/.next/server/app/p/[projectId]/page.js.nft.json +1 -1
- package/.next/server/app/p/[projectId]/page_client-reference-manifest.js +1 -1
- package/.next/server/app/page.js.nft.json +1 -1
- package/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/server/chunks/[root-of-the-server]__0190u3x31o2kc._.js +1 -1
- package/.next/server/chunks/[root-of-the-server]__0190u3x31o2kc._.js.map +1 -1
- package/.next/server/chunks/[root-of-the-server]__1-f7qk3-8a266._.js +1 -1
- package/.next/server/chunks/[root-of-the-server]__1zrubp2jc8bi0._.js +1 -1
- package/.next/server/chunks/_004qegokrf7fy._.js +1 -1
- package/.next/server/chunks/_004qegokrf7fy._.js.map +1 -1
- package/.next/server/chunks/_0vx1iev9xu_vx._.js +1 -1
- package/.next/server/chunks/_0vx1iev9xu_vx._.js.map +1 -1
- package/.next/server/chunks/_10s9tyeasgb0i._.js +1 -1
- package/.next/server/chunks/_10s9tyeasgb0i._.js.map +1 -1
- package/.next/server/chunks/_146xyuw6iu78n._.js +1 -1
- package/.next/server/chunks/_146xyuw6iu78n._.js.map +1 -1
- package/.next/server/chunks/_1n-6yntr59hz-._.js +1 -1
- package/.next/server/chunks/_1n-6yntr59hz-._.js.map +1 -1
- package/.next/server/chunks/_1tji4d-rsralm._.js +1 -1
- package/.next/server/chunks/lib_beads-view_ts_1fvxcrevh9zu_._.js +1 -1
- package/.next/server/chunks/lib_beads-view_ts_1fvxcrevh9zu_._.js.map +1 -1
- package/.next/server/chunks/lib_config_ts_0zrjxh_mm8sv8._.js +1 -1
- package/.next/server/chunks/lib_config_ts_0zrjxh_mm8sv8._.js.map +1 -1
- package/.next/server/chunks/lib_self-update_ts_1s_0im4leryko._.js +1 -1
- package/.next/server/chunks/lib_self-update_ts_1s_0im4leryko._.js.map +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__10sjsc4ko7y98._.js +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__10sjsc4ko7y98._.js.map +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__1xizcyi5hek65._.js +7 -7
- package/.next/server/chunks/ssr/[root-of-the-server]__1xizcyi5hek65._.js.map +1 -1
- package/.next/server/chunks/ssr/_0_ky_k50rh6-9._.js +1 -1
- package/.next/server/chunks/ssr/_0_ky_k50rh6-9._.js.map +1 -1
- package/.next/server/chunks/ssr/_16j7dxy5pqj44._.js +291 -0
- package/.next/server/chunks/ssr/_16j7dxy5pqj44._.js.map +1 -0
- package/.next/server/chunks/ssr/_1bulx6_unf6c7._.js +3 -0
- package/.next/server/chunks/ssr/_1bulx6_unf6c7._.js.map +1 -0
- package/.next/server/chunks/ssr/_1mzldxegsozij._.js +1 -1
- package/.next/server/chunks/ssr/_1mzldxegsozij._.js.map +1 -1
- package/.next/server/chunks/ssr/_1obdc2e416ry-._.js +3 -0
- package/.next/server/chunks/ssr/_1obdc2e416ry-._.js.map +1 -0
- package/.next/server/chunks/ssr/components_launcher_tsx_1i40oht1v6miz._.js +1 -1
- package/.next/server/chunks/ssr/components_launcher_tsx_1i40oht1v6miz._.js.map +1 -1
- package/.next/server/chunks/ssr/components_providers_tsx_0thx-xfvr_dtx._.js.map +1 -1
- package/.next/server/middleware-build-manifest.js +3 -3
- package/.next/server/middleware.js.nft.json +1 -1
- package/.next/server/pages/404.html +2 -2
- package/.next/server/pages/500.html +1 -1
- package/.next/server/preview-props.json +3 -3
- package/.next/server/server-reference-manifest.js +1 -1
- package/.next/server/server-reference-manifest.json +1 -1
- package/.next/static/chunks/0gexf4-utluu4.js +1 -0
- package/.next/static/chunks/23nopl40nheqr.js +1 -0
- package/.next/static/chunks/2c10hhzk7mgkf.js +58 -0
- package/.next/static/chunks/2n4lv4u0xo5oz.css +3 -0
- package/.next/static/chunks/3m8u_309a1_fw.js +1 -0
- package/.next/static/chunks/3tepw2noo82tm.js +1 -0
- package/README.md +91 -25
- package/bin/beadscope.mjs +75 -32
- package/package.json +2 -1
- package/.next/server/chunks/ssr/_02mwe4ucwaopu._.js +0 -291
- package/.next/server/chunks/ssr/_02mwe4ucwaopu._.js.map +0 -1
- package/.next/server/chunks/ssr/_1020o02v8ucmf._.js +0 -3
- package/.next/server/chunks/ssr/_1020o02v8ucmf._.js.map +0 -1
- package/.next/server/chunks/ssr/_1i_x4qkev3tax._.js +0 -3
- package/.next/server/chunks/ssr/_1i_x4qkev3tax._.js.map +0 -1
- package/.next/static/chunks/07balm4l-kilq.js +0 -1
- package/.next/static/chunks/0lf_v5uyq3i9q.js +0 -1
- package/.next/static/chunks/21v6r4y8vgqng.css +0 -3
- package/.next/static/chunks/2xh00k9l33qnb.js +0 -1
- package/.next/static/chunks/3yk880zca6oid.js +0 -58
- package/.next/static/chunks/3yqhmu1hny1_2.js +0 -1
- /package/.next/static/{CNwJGIAhEiVMAkf3ebvok → BoR0CvHf7BXhmN1hRjwWk}/_buildManifest.js +0 -0
- /package/.next/static/{CNwJGIAhEiVMAkf3ebvok → BoR0CvHf7BXhmN1hRjwWk}/_clientMiddlewareManifest.js +0 -0
- /package/.next/static/{CNwJGIAhEiVMAkf3ebvok → BoR0CvHf7BXhmN1hRjwWk}/_ssgManifest.js +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../components/theme-provider.tsx","../../../../lib/themes.ts","../../../../node_modules/clsx/dist/clsx.mjs","../../../../node_modules/tailwind-merge/src/lib/utils.ts","../../../../lib/utils.ts","../../../../node_modules/tailwind-merge/src/lib/class-group-utils.ts","../../../../node_modules/tailwind-merge/src/lib/lru-cache.ts","../../../../node_modules/tailwind-merge/src/lib/parse-class-name.ts","../../../../node_modules/tailwind-merge/src/lib/sort-modifiers.ts","../../../../node_modules/tailwind-merge/src/lib/config-utils.ts","../../../../node_modules/tailwind-merge/src/lib/merge-classlist.ts","../../../../node_modules/tailwind-merge/src/lib/tw-join.ts","../../../../node_modules/tailwind-merge/src/lib/create-tailwind-merge.ts","../../../../node_modules/tailwind-merge/src/lib/from-theme.ts","../../../../node_modules/tailwind-merge/src/lib/validators.ts","../../../../node_modules/tailwind-merge/src/lib/default-config.ts","../../../../node_modules/tailwind-merge/src/lib/merge-configs.ts","../../../../node_modules/tailwind-merge/src/lib/extend-tailwind-merge.ts","../../../../node_modules/tailwind-merge/src/lib/tw-merge.ts","../../../../node_modules/%40base-ui/react/floating-ui-react/components/FloatingPortal.mjs","../../../../node_modules/%40base-ui/react/internals/constants.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/components/FloatingRootStore.mjs","../../../../node_modules/%40base-ui/utils/store/ReactStore.mjs","../../../../node_modules/%40base-ui/utils/store/useStore.mjs","../../../../node_modules/%40base-ui/utils/store/Store.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/components/FloatingTree.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/createEventEmitter.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/components/FloatingTreeStore.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/hooks/useDismiss.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/hooks/useSyncedFloatingRootContext.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/element.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/constants.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/event.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/nodes.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/tabbable.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/composite.mjs","../../../../node_modules/%40base-ui/react/internals/createBaseUIEventDetails.mjs","../../../../node_modules/%40base-ui/react/internals/getStateAttributesProps.mjs","../../../../node_modules/%40base-ui/react/utils/resolveClassName.mjs","../../../../node_modules/%40base-ui/react/utils/resolveStyle.mjs","../../../../node_modules/%40base-ui/react/internals/reason-parts.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/createAttribute.mjs","../../../../node_modules/%40base-ui/react/internals/shadowDom.mjs","../../../../node_modules/%40base-ui/react/internals/stateAttributesMapping.mjs","../../../../node_modules/%40base-ui/react/internals/useBaseUiId.mjs","../../../../node_modules/%40base-ui/react/internals/useOpenChangeComplete.mjs","../../../../node_modules/%40base-ui/react/internals/useAnimationsFinished.mjs","../../../../node_modules/%40base-ui/react/internals/useRenderElement.mjs","../../../../node_modules/%40base-ui/react/internals/useTransitionStatus.mjs","../../../../node_modules/%40base-ui/react/merge-props/mergeProps.mjs","../../../../node_modules/%40base-ui/react/utils/FocusGuard.mjs","../../../../node_modules/%40base-ui/utils/visuallyHidden.mjs","../../../../node_modules/%40base-ui/react/utils/popupStateMapping.mjs","../../../../node_modules/%40base-ui/react/utils/popups/popupStoreUtils.mjs","../../../../node_modules/%40base-ui/react/utils/popups/popupTriggerMap.mjs","../../../../node_modules/%40base-ui/react/utils/popups/store.mjs","../../../../node_modules/%40base-ui/react/floating-ui-react/utils/getEmptyRootContext.mjs","../../../../node_modules/%40base-ui/react/utils/resolveRef.mjs","../../../../node_modules/%40base-ui/utils/addEventListener.mjs","../../../../node_modules/%40base-ui/utils/empty.mjs","../../../../node_modules/%40base-ui/utils/fastHooks.mjs","../../../../node_modules/%40base-ui/utils/formatErrorMessage.mjs","../../../../node_modules/%40base-ui/utils/getReactElementRef.mjs","../../../../node_modules/%40base-ui/utils/mergeCleanups.mjs","../../../../node_modules/%40base-ui/utils/mergeObjects.mjs","../../../../node_modules/%40base-ui/utils/owner.mjs","../../../../node_modules/%40base-ui/utils/platform/shared.mjs","../../../../node_modules/%40base-ui/utils/platform/os.mjs","../../../../node_modules/%40base-ui/utils/platform/engine.mjs","../../../../node_modules/%40base-ui/utils/platform/screen-reader.mjs","../../../../node_modules/%40base-ui/utils/platform/env.mjs","../../../../node_modules/%40base-ui/utils/reactVersion.mjs","../../../../node_modules/%40base-ui/utils/store/createSelector.mjs","../../../../node_modules/%40base-ui/utils/useAnimationFrame.mjs","../../../../node_modules/%40base-ui/utils/useId.mjs","../../../../node_modules/%40base-ui/utils/useIsoLayoutEffect.mjs","../../../../node_modules/%40base-ui/utils/useMergedRefs.mjs","../../../../node_modules/%40base-ui/utils/useOnFirstRender.mjs","../../../../node_modules/%40base-ui/utils/useOnMount.mjs","../../../../node_modules/%40base-ui/utils/useRefWithInit.mjs","../../../../node_modules/%40base-ui/utils/safeReact.mjs","../../../../node_modules/%40base-ui/utils/useStableCallback.mjs","../../../../node_modules/%40base-ui/utils/useTimeout.mjs","../../../../node_modules/%40base-ui/utils/useValueAsRef.mjs","../../../../node_modules/%40base-ui/utils/warn.mjs","../../../../node_modules/%40floating-ui/utils/dist/floating-ui.utils.dom.mjs","../../../../node_modules/%40swc/helpers/cjs/_interop_require_wildcard.cjs","../../../../node_modules/%40tanstack/query-core/src/environmentManager.ts","../../../../node_modules/%40tanstack/query-core/build/modern/subscribable.js","../../../../node_modules/%40tanstack/query-core/build/modern/thenable.js","../../../../node_modules/%40tanstack/query-core/build/modern/focusManager.js","../../../../node_modules/%40tanstack/query-core/build/modern/onlineManager.js","../../../../node_modules/%40tanstack/query-core/src/mutation.ts","../../../../node_modules/%40tanstack/query-core/src/mutationObserver.ts","../../../../node_modules/%40tanstack/query-core/src/notifyManager.ts","../../../../node_modules/%40tanstack/query-core/build/modern/query.js","../../../../node_modules/%40tanstack/query-core/build/modern/infiniteQueryBehavior.js","../../../../node_modules/%40tanstack/query-core/src/removable.ts","../../../../node_modules/%40tanstack/query-core/src/retryer.ts","../../../../node_modules/%40tanstack/query-core/src/timeoutManager.ts","../../../../node_modules/%40tanstack/query-core/src/utils.ts","../../../../node_modules/%40tanstack/react-query/src/QueryClientProvider.tsx","../../../../node_modules/%40tanstack/react-query/src/useMutation.ts","../../../../node_modules/%40tanstack/react-query/build/modern/useQuery.js","../../../../node_modules/%40tanstack/query-core/build/modern/queryObserver.js","../../../../node_modules/%40tanstack/react-query/build/modern/QueryErrorResetBoundary.js","../../../../node_modules/%40tanstack/react-query/build/modern/errorBoundaryUtils.js","../../../../node_modules/%40tanstack/react-query/build/modern/IsRestoringProvider.js","../../../../node_modules/%40tanstack/react-query/build/modern/suspense.js","../../../../node_modules/%40tanstack/react-query/build/modern/useBaseQuery.js","../../../../node_modules/shared/src/utils/hasA11yProp.ts","../../../../node_modules/shared/src/utils/toKebabCase.ts","../../../../node_modules/shared/src/utils/mergeClasses.ts","../../../../node_modules/shared/src/utils/toCamelCase.ts","../../../../node_modules/lucide-react/src/defaultAttributes.ts","../../../../node_modules/shared/src/utils/toPascalCase.ts","../../../../node_modules/lucide-react/src/createLucideIcon.ts","../../../../node_modules/lucide-react/src/Icon.ts","../../../../node_modules/lucide-react/src/icons/loader-circle.ts","../../../../node_modules/lucide-react/src/icons/triangle-alert.ts","../../../../node_modules/next/src/client/components/forbidden.ts","../../../../node_modules/next/src/client/components/hooks-server-context.ts","../../../../node_modules/next/src/client/components/http-access-fallback/http-access-fallback.ts","../../../../node_modules/next/src/client/components/is-next-router-error.ts","../../../../node_modules/next/src/client/components/navigation-dynamic-rendering.ts","../../../../node_modules/next/src/client/components/navigation.ts","../../../../node_modules/next/src/client/components/navigation.react-server.ts","../../../../node_modules/next/src/client/components/not-found.ts","../../../../node_modules/next/src/client/components/readonly-url-search-params.ts","../../../../node_modules/next/src/client/components/redirect-error.ts","../../../../node_modules/next/src/client/components/redirect-status-code.ts","../../../../node_modules/next/src/client/components/redirect.ts","../../../../node_modules/next/src/client/components/static-generation-bailout.ts","../../../../node_modules/next/src/client/components/unauthorized.ts","../../../../node_modules/next/src/client/components/unrecognized-action-error.ts","../../../../node_modules/next/src/client/components/unstable-rethrow.ts","../../../../node_modules/next/src/lib/framework/boundary-constants.tsx","../../../../node_modules/next/src/lib/scheduler.ts","../../../../node_modules/next/src/server/app-render/blocking-route-messages.ts","../../../../node_modules/next/src/server/app-render/dynamic-rendering-client.ts","../../../../node_modules/next/src/server/app-render/dynamic-rendering.ts","../../../../node_modules/next/src/server/app-render/instant-validation/boundary-constants.ts","../../../../node_modules/next/src/server/app-render/instant-validation/boundary-tracking.tsx","../../../../node_modules/next/src/server/app-render/segment-config/ensure-static.ts","../../../../node_modules/next/src/server/app-render/staged-rendering.ts","../../../../node_modules/next/src/server/dynamic-rendering-utils.ts","../../../../node_modules/next/src/server/lib/app-dir-module.ts","../../../../node_modules/next/src/shared/lib/instant-messages.ts","../../../../node_modules/next/src/shared/lib/invariant-error.ts","../../../../node_modules/next/src/shared/lib/lazy-dynamic/bailout-to-csr.ts","../../../../node_modules/next/src/shared/lib/lazy-dynamic/react-browser-bailout.ts","../../../../node_modules/next/src/shared/lib/promise-with-resolvers.ts","../../../../node_modules/next/src/shared/lib/router/utils/parse-loader-tree.ts","../../../../node_modules/next/src/shared/lib/segment.ts","../../../../node_modules/sonner/dist/index.mjs","../../../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js","../../../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js","../../../../node_modules/use-sync-external-store/shim/index.js","../../../../node_modules/use-sync-external-store/shim/with-selector.js","../../../../node_modules/next/navigation.js"],"sourcesContent":["\"use client\";\nimport * as React from \"react\";\nimport { usePathname } from \"next/navigation\";\nimport {\n DEFAULT_CHOICE_ID,\n getChoiceId,\n resolveChoice,\n type ThemeDef,\n type ThemeMode,\n} from \"@/lib/themes\";\n\n/**\n * Per-project theme (bead 81k). The chosen theme is stored per-device\n * in localStorage, keyed by the active project so different projects look different\n * and don't get confused. Project identity comes from the /p/<projectId> URL; the\n * launcher (no project) uses a shared key.\n */\nconst THEME_EVENT = \"beadscope:theme\";\nconst DARK_QUERY = \"(prefers-color-scheme: dark)\";\n\nfunction subscribe(callback: () => void) {\n window.addEventListener(THEME_EVENT, callback);\n window.addEventListener(\"storage\", callback);\n return () => {\n window.removeEventListener(THEME_EVENT, callback);\n window.removeEventListener(\"storage\", callback);\n };\n}\n\nfunction serverSnapshot(): string {\n return \"light\";\n}\n\n// The OS appearance is its own external store: only the \"system\" choice reads it,\n// but subscribing unconditionally keeps the hook order fixed and the cost is nil.\nfunction subscribeDark(callback: () => void) {\n const mq = window.matchMedia(DARK_QUERY);\n mq.addEventListener(\"change\", callback);\n return () => mq.removeEventListener(\"change\", callback);\n}\n\nfunction prefersDark(): boolean {\n return typeof window !== \"undefined\" && window.matchMedia(DARK_QUERY).matches;\n}\n\nfunction serverPrefersDark(): boolean {\n return false;\n}\n\nfunction storageKey(projectId: string | null): string {\n return projectId ? `beadscope.theme.${projectId}` : \"beadscope.theme\";\n}\n\n/**\n * localStorage when in a browser, else undefined. Reached via `globalThis` on\n * purpose: a `typeof window === \"undefined\"` guard gets constant-folded to `true`\n * in the server bundle, which dead-code-eliminates the project-keyed read and\n * leaves the minifier emitting a temp before its declaration (TDZ during SSR).\n *\n * Node >= 22 exposes a `globalThis.localStorage` stub during SSR that lacks the\n * Storage methods unless the process was started with `--localstorage-file`\n * (calling `getItem` on it throws \"is not a function\"), so the object is only\n * usable if it actually implements Storage. Both methods are checked, not just\n * `getItem`: the read path and the two `setItem` writers share this one guard,\n * so a partial stub would still throw on save.\n */\nfunction getStore(): Storage | undefined {\n const store = (globalThis as { localStorage?: Storage }).localStorage;\n return typeof store?.getItem === \"function\" && typeof store.setItem === \"function\"\n ? store\n : undefined;\n}\n\nfunction projectIdFromPath(pathname: string | null): string | null {\n const m = pathname?.match(/^\\/p\\/([^/]+)/);\n return m ? decodeURIComponent(m[1]) : null;\n}\n\n/**\n * Reads the saved *choice* for a project (a palette id or \"system\"), falling back\n * to the default. This is what the user picked, not what is\n * painted — resolve it with resolveChoice() when the OS preference matters.\n */\nfunction readChoiceId(projectId: string | null): string {\n try {\n const store = getStore();\n const stored = store\n ? store.getItem(storageKey(projectId))\n : null;\n return getChoiceId(stored);\n } catch {\n return DEFAULT_CHOICE_ID;\n }\n}\n\ninterface ThemeContextValue {\n /** The palette actually painted (System already resolved to Light/Dark). */\n theme: ThemeDef;\n /** What the user picked: a palette id, or \"system\". Drives the picker's selection. */\n choice: string;\n mode: ThemeMode;\n setTheme: (id: string) => void;\n toggle: () => void;\n}\n\n// Plain-literal default (no module-load-time function call — keeps the bundler's\n// scope-hoisting from tripping a TDZ during SSR). Only used if a consumer renders\n// with no provider mounted, which doesn't happen in practice.\nconst ThemeContext = React.createContext<ThemeContextValue>({\n theme: { id: \"light\", name: \"Light\", mode: \"light\", swatch: [\"#f6f6f8\", \"#ffffff\", \"#6d5ef0\"] },\n choice: \"light\",\n mode: \"light\",\n setTheme: () => {},\n toggle: () => {},\n});\n\nexport function ThemeProvider({ children }: { children: React.ReactNode }) {\n const pathname = usePathname();\n const projectId = projectIdFromPath(pathname);\n\n // Hydration must match the server's light snapshot before reading browser\n // preferences. React then applies the saved project theme and subscribes to changes.\n const choice = React.useSyncExternalStore(\n subscribe,\n () => readChoiceId(projectId),\n serverSnapshot,\n );\n const osDark = React.useSyncExternalStore(subscribeDark, prefersDark, serverPrefersDark);\n const theme = resolveChoice(choice, osDark);\n\n // Apply to <html>: data-theme drives the palette; .dark drives Tailwind/shadcn.\n React.useEffect(() => {\n document.documentElement.dataset.theme = theme.id;\n document.documentElement.classList.toggle(\"dark\", theme.mode === \"dark\");\n }, [theme.id, theme.mode]);\n\n // Plain handlers (no manual memoization — React Compiler handles it, and the\n // provider updates from the external store). Notify this tab after saving;\n // the native storage event handles other tabs.\n function setTheme(id: string) {\n getStore()?.setItem(storageKey(projectId), getChoiceId(id));\n window.dispatchEvent(new Event(THEME_EVENT));\n }\n // Quick flip to the opposite of what is on screen (sidebar button, T shortcut,\n // launcher). From \"system\" it saves an explicit Light/Dark, so the user can opt\n // out of following the OS; pick System again in Settings to re-follow it.\n function toggle() {\n const showing = resolveChoice(readChoiceId(projectId), prefersDark());\n const next = showing.mode === \"dark\" ? \"light\" : \"dark\";\n getStore()?.setItem(storageKey(projectId), next);\n window.dispatchEvent(new Event(THEME_EVENT));\n }\n\n return (\n <ThemeContext.Provider value={{ theme, choice, mode: theme.mode, setTheme, toggle }}>\n {children}\n </ThemeContext.Provider>\n );\n}\n\nexport const useTheme = () => React.useContext(ThemeContext);\n","/**\n * Theme registry — metadata only. The actual colors live in app/globals.css as\n * `html[data-theme=\"<id>\"]` blocks; this module is what the provider and pickers\n * use to enumerate themes, validate ids, and render swatches. `mode` decides\n * whether the `.dark` class is applied (so Tailwind `dark:` + shadcn tokens work).\n */\nexport type ThemeMode = \"light\" | \"dark\";\n\nexport interface ThemeDef {\n /** Stable id — also the html[data-theme] value and the localStorage value. */\n id: string;\n /** Human label for the picker. */\n name: string;\n /** Drives the `.dark` class. All custom themes here are dark; only Light is light. */\n mode: ThemeMode;\n /** Three representative hexes [bg, surface, accent] for the picker preview. */\n swatch: [string, string, string];\n}\n\nexport const THEMES: ThemeDef[] = [\n { id: \"light\", name: \"Light\", mode: \"light\", swatch: [\"#f6f6f8\", \"#ffffff\", \"#6d5ef0\"] },\n { id: \"dark\", name: \"Dark\", mode: \"dark\", swatch: [\"#0c0c0f\", \"#1d1d22\", \"#8b7cf8\"] },\n { id: \"dracula\", name: \"Dracula\", mode: \"dark\", swatch: [\"#282a36\", \"#44475a\", \"#bd93f9\"] },\n { id: \"nord\", name: \"Nord\", mode: \"dark\", swatch: [\"#2e3440\", \"#3b4252\", \"#88c0d0\"] },\n { id: \"solarized-dark\", name: \"Solarized Dark\", mode: \"dark\", swatch: [\"#002b36\", \"#073642\", \"#268bd2\"] },\n { id: \"gruvbox-dark\", name: \"Gruvbox Dark\", mode: \"dark\", swatch: [\"#282828\", \"#3c3836\", \"#fabd2f\"] },\n { id: \"tokyo-night\", name: \"Tokyo Night\", mode: \"dark\", swatch: [\"#1a1b26\", \"#24283b\", \"#7aa2f7\"] },\n { id: \"catppuccin-mocha\", name: \"Catppuccin Mocha\", mode: \"dark\", swatch: [\"#1e1e2e\", \"#313244\", \"#cba6f7\"] },\n { id: \"rose-pine\", name: \"Rosé Pine\", mode: \"dark\", swatch: [\"#191724\", \"#26233a\", \"#c4a7e7\"] },\n];\n\nexport const DEFAULT_THEME_ID = \"light\";\n\nconst BY_ID = new Map(THEMES.map((t) => [t.id, t]));\n\nexport function isThemeId(id: string): boolean {\n return BY_ID.has(id);\n}\n\n/** Returns the theme for `id`, or the default theme for unknown/empty ids. */\nexport function getTheme(id: string | null | undefined): ThemeDef {\n return (id ? BY_ID.get(id) : undefined) ?? BY_ID.get(DEFAULT_THEME_ID)!;\n}\n\n/**\n * \"System\" is a *choice*, not a palette: it has no `html[data-theme]` block of\n * its own and resolves to Light or Dark from the OS `prefers-color-scheme`.\n * It lives outside THEMES so palette enumerations stay palettes-only; the\n * picker prepends it explicitly.\n */\nexport const SYSTEM_CHOICE_ID = \"system\";\n\nexport const SYSTEM_CHOICE: ThemeDef = {\n id: SYSTEM_CHOICE_ID,\n name: \"System\",\n mode: \"light\",\n // Left half light, right half dark so the swatch reads as \"follows the OS\".\n swatch: [\"#f6f6f8\", \"#1d1d22\", \"#6d5ef0\"],\n};\n\n/** What a project uses until the user picks something. */\nexport const DEFAULT_CHOICE_ID = SYSTEM_CHOICE_ID;\n\n/** Normalizes a stored value to a valid choice id (palette id or \"system\"). */\nexport function getChoiceId(stored: string | null | undefined): string {\n if (stored === SYSTEM_CHOICE_ID) return SYSTEM_CHOICE_ID;\n return stored && BY_ID.has(stored) ? stored : DEFAULT_CHOICE_ID;\n}\n\n/** Resolves a choice to a concrete palette, given the OS preference. */\nexport function resolveChoice(choice: string, prefersDark: boolean): ThemeDef {\n return choice === SYSTEM_CHOICE_ID\n ? BY_ID.get(prefersDark ? \"dark\" : \"light\")!\n : getTheme(choice);\n}\n","function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=\" \"),n+=f)}else for(f in e)e[f]&&(n&&(n+=\" \"),n+=f);return n}export function clsx(){for(var e,t,f=0,n=\"\",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=\" \"),n+=t);return n}export default clsx;","/**\n * Concatenates two arrays faster than the array spread operator.\n */\nexport const concatArrays = <T, U>(\n array1: readonly T[],\n array2: readonly U[],\n): readonly (T | U)[] => {\n // Pre-allocate for better V8 optimization\n const combinedArray: (T | U)[] = new Array(array1.length + array2.length)\n for (let i = 0; i < array1.length; i++) {\n combinedArray[i] = array1[i]!\n }\n for (let i = 0; i < array2.length; i++) {\n combinedArray[array1.length + i] = array2[i]!\n }\n return combinedArray\n}\n","import { clsx, type ClassValue } from \"clsx\"\nimport { twMerge } from \"tailwind-merge\"\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs))\n}\n","import {\n AnyClassGroupIds,\n AnyConfig,\n AnyThemeGroupIds,\n ClassGroup,\n ClassValidator,\n Config,\n ThemeGetter,\n ThemeObject,\n} from './types'\nimport { concatArrays } from './utils'\n\nexport interface ClassPartObject {\n nextPart: Map<string, ClassPartObject>\n validators: ClassValidatorObject[] | null\n classGroupId: AnyClassGroupIds | undefined // Always define optional props for consistent shape\n}\n\ninterface ClassValidatorObject {\n classGroupId: AnyClassGroupIds\n validator: ClassValidator\n}\n\n// Factory function ensures consistent object shapes\nconst createClassValidatorObject = (\n classGroupId: AnyClassGroupIds,\n validator: ClassValidator,\n): ClassValidatorObject => ({\n classGroupId,\n validator,\n})\n\n// Factory ensures consistent ClassPartObject shape\nconst createClassPartObject = (\n nextPart: Map<string, ClassPartObject> = new Map(),\n validators: ClassValidatorObject[] | null = null,\n classGroupId?: AnyClassGroupIds,\n): ClassPartObject => ({\n nextPart,\n validators,\n classGroupId,\n})\n\nconst CLASS_PART_SEPARATOR = '-'\n\nconst EMPTY_CONFLICTS: readonly AnyClassGroupIds[] = []\n// I use two dots here because one dot is used as prefix for class groups in plugins\nconst ARBITRARY_PROPERTY_PREFIX = 'arbitrary..'\n\nexport const createClassGroupUtils = (config: AnyConfig) => {\n const classMap = createClassMap(config)\n const { conflictingClassGroups, conflictingClassGroupModifiers } = config\n\n const getClassGroupId = (className: string) => {\n if (className.startsWith('[') && className.endsWith(']')) {\n return getGroupIdForArbitraryProperty(className)\n }\n\n const classParts = className.split(CLASS_PART_SEPARATOR)\n // Classes like `-inset-1` produce an empty string as first classPart. We assume that classes for negative values are used correctly and skip it.\n const startIndex = classParts[0] === '' && classParts.length > 1 ? 1 : 0\n return getGroupRecursive(classParts, startIndex, classMap)\n }\n\n const getConflictingClassGroupIds = (\n classGroupId: AnyClassGroupIds,\n hasPostfixModifier: boolean,\n ): readonly AnyClassGroupIds[] => {\n if (hasPostfixModifier) {\n const modifierConflicts = conflictingClassGroupModifiers[classGroupId]\n const baseConflicts = conflictingClassGroups[classGroupId]\n\n if (modifierConflicts) {\n if (baseConflicts) {\n // Merge base conflicts with modifier conflicts\n return concatArrays(baseConflicts, modifierConflicts)\n }\n // Only modifier conflicts\n return modifierConflicts\n }\n // Fall back to without postfix if no modifier conflicts\n return baseConflicts || EMPTY_CONFLICTS\n }\n\n return conflictingClassGroups[classGroupId] || EMPTY_CONFLICTS\n }\n\n return {\n getClassGroupId,\n getConflictingClassGroupIds,\n }\n}\n\nconst getGroupRecursive = (\n classParts: string[],\n startIndex: number,\n classPartObject: ClassPartObject,\n): AnyClassGroupIds | undefined => {\n const classPathsLength = classParts.length - startIndex\n if (classPathsLength === 0) {\n return classPartObject.classGroupId\n }\n\n const currentClassPart = classParts[startIndex]!\n const nextClassPartObject = classPartObject.nextPart.get(currentClassPart)\n\n if (nextClassPartObject) {\n const result = getGroupRecursive(classParts, startIndex + 1, nextClassPartObject)\n if (result) return result\n }\n\n const validators = classPartObject.validators\n if (validators === null) {\n return undefined\n }\n\n // Build classRest string efficiently by joining from startIndex onwards\n const classRest =\n startIndex === 0\n ? classParts.join(CLASS_PART_SEPARATOR)\n : classParts.slice(startIndex).join(CLASS_PART_SEPARATOR)\n const validatorsLength = validators.length\n\n for (let i = 0; i < validatorsLength; i++) {\n const validatorObj = validators[i]!\n if (validatorObj.validator(classRest)) {\n return validatorObj.classGroupId\n }\n }\n\n return undefined\n}\n\n/**\n * Get the class group ID for an arbitrary property.\n *\n * @param className - The class name to get the group ID for. Is expected to be string starting with `[` and ending with `]`.\n */\nconst getGroupIdForArbitraryProperty = (className: string): AnyClassGroupIds | undefined =>\n className.slice(1, -1).indexOf(':') === -1\n ? undefined\n : (() => {\n const content = className.slice(1, -1)\n const colonIndex = content.indexOf(':')\n const property = content.slice(0, colonIndex)\n return property ? ARBITRARY_PROPERTY_PREFIX + property : undefined\n })()\n\n/**\n * Exported for testing only\n */\nexport const createClassMap = (config: Config<AnyClassGroupIds, AnyThemeGroupIds>) => {\n const { theme, classGroups } = config\n return processClassGroups(classGroups, theme)\n}\n\n// Split into separate functions to maintain monomorphic call sites\nconst processClassGroups = (\n classGroups: Record<AnyClassGroupIds, ClassGroup<AnyThemeGroupIds>>,\n theme: ThemeObject<AnyThemeGroupIds>,\n): ClassPartObject => {\n const classMap = createClassPartObject()\n\n for (const classGroupId in classGroups) {\n const group = classGroups[classGroupId]!\n processClassesRecursively(group, classMap, classGroupId, theme)\n }\n\n return classMap\n}\n\nconst processClassesRecursively = (\n classGroup: ClassGroup<AnyThemeGroupIds>,\n classPartObject: ClassPartObject,\n classGroupId: AnyClassGroupIds,\n theme: ThemeObject<AnyThemeGroupIds>,\n) => {\n const len = classGroup.length\n for (let i = 0; i < len; i++) {\n const classDefinition = classGroup[i]!\n processClassDefinition(classDefinition, classPartObject, classGroupId, theme)\n }\n}\n\n// Split into separate functions for each type to maintain monomorphic call sites\nconst processClassDefinition = (\n classDefinition: ClassGroup<AnyThemeGroupIds>[number],\n classPartObject: ClassPartObject,\n classGroupId: AnyClassGroupIds,\n theme: ThemeObject<AnyThemeGroupIds>,\n) => {\n if (typeof classDefinition === 'string') {\n processStringDefinition(classDefinition, classPartObject, classGroupId)\n return\n }\n\n if (typeof classDefinition === 'function') {\n processFunctionDefinition(classDefinition, classPartObject, classGroupId, theme)\n return\n }\n\n processObjectDefinition(\n classDefinition as Record<string, ClassGroup<AnyThemeGroupIds>>,\n classPartObject,\n classGroupId,\n theme,\n )\n}\n\nconst processStringDefinition = (\n classDefinition: string,\n classPartObject: ClassPartObject,\n classGroupId: AnyClassGroupIds,\n) => {\n const classPartObjectToEdit =\n classDefinition === '' ? classPartObject : getPart(classPartObject, classDefinition)\n classPartObjectToEdit.classGroupId = classGroupId\n}\n\nconst processFunctionDefinition = (\n classDefinition: Function,\n classPartObject: ClassPartObject,\n classGroupId: AnyClassGroupIds,\n theme: ThemeObject<AnyThemeGroupIds>,\n) => {\n if (isThemeGetter(classDefinition)) {\n processClassesRecursively(classDefinition(theme), classPartObject, classGroupId, theme)\n return\n }\n\n if (classPartObject.validators === null) {\n classPartObject.validators = []\n }\n classPartObject.validators.push(\n createClassValidatorObject(classGroupId, classDefinition as ClassValidator),\n )\n}\n\nconst processObjectDefinition = (\n classDefinition: Record<string, ClassGroup<AnyThemeGroupIds>>,\n classPartObject: ClassPartObject,\n classGroupId: AnyClassGroupIds,\n theme: ThemeObject<AnyThemeGroupIds>,\n) => {\n const entries = Object.entries(classDefinition)\n const len = entries.length\n for (let i = 0; i < len; i++) {\n const [key, value] = entries[i]!\n processClassesRecursively(value, getPart(classPartObject, key), classGroupId, theme)\n }\n}\n\nconst getPart = (classPartObject: ClassPartObject, path: string): ClassPartObject => {\n let current = classPartObject\n const parts = path.split(CLASS_PART_SEPARATOR)\n const len = parts.length\n\n for (let i = 0; i < len; i++) {\n const part = parts[i]!\n\n let next = current.nextPart.get(part)\n if (!next) {\n next = createClassPartObject()\n current.nextPart.set(part, next)\n }\n current = next\n }\n\n return current\n}\n\n// Type guard maintains monomorphic check\nconst isThemeGetter = (func: Function): func is ThemeGetter =>\n 'isThemeGetter' in func && (func as ThemeGetter).isThemeGetter === true\n","// Export is needed because TypeScript complains about an error otherwise:\n// Error: …/tailwind-merge/src/config-utils.ts(8,17): semantic error TS4058: Return type of exported function has or is using name 'LruCache' from external module \"…/tailwind-merge/src/lru-cache\" but cannot be named.\nexport interface LruCache<Key extends string, Value> {\n get(key: Key): Value | undefined\n set(key: Key, value: Value): void\n}\n\n// LRU cache implementation using plain objects for simplicity\nexport const createLruCache = <Key extends string, Value>(\n maxCacheSize: number,\n): LruCache<Key, Value> => {\n if (maxCacheSize < 1) {\n return {\n get: () => undefined,\n set: () => {},\n }\n }\n\n let cacheSize = 0\n let cache: Record<Key, Value> = Object.create(null)\n let previousCache: Record<Key, Value> = Object.create(null)\n\n const update = (key: Key, value: Value) => {\n cache[key] = value\n cacheSize++\n\n if (cacheSize > maxCacheSize) {\n cacheSize = 0\n previousCache = cache\n cache = Object.create(null)\n }\n }\n\n return {\n get(key) {\n let value = cache[key]\n\n if (value !== undefined) {\n return value\n }\n if ((value = previousCache[key]) !== undefined) {\n update(key, value)\n return value\n }\n },\n set(key, value) {\n if (key in cache) {\n cache[key] = value\n } else {\n update(key, value)\n }\n },\n }\n}\n","import { AnyConfig, ParsedClassName } from './types'\n\nexport const IMPORTANT_MODIFIER = '!'\n\nconst MODIFIER_SEPARATOR = ':'\nconst EMPTY_MODIFIERS: string[] = []\n\n// Pre-allocated result object shape for consistency\nconst createResultObject = (\n modifiers: string[],\n hasImportantModifier: boolean,\n baseClassName: string,\n maybePostfixModifierPosition?: number,\n isExternal?: boolean,\n): ParsedClassName => ({\n modifiers,\n hasImportantModifier,\n baseClassName,\n maybePostfixModifierPosition,\n isExternal,\n})\n\nexport const createParseClassName = (config: AnyConfig) => {\n const { prefix, experimentalParseClassName } = config\n\n /**\n * Parse class name into parts.\n *\n * Inspired by `splitAtTopLevelOnly` used in Tailwind CSS\n * @see https://github.com/tailwindlabs/tailwindcss/blob/v3.2.2/src/util/splitAtTopLevelOnly.js\n */\n let parseClassName = (className: string): ParsedClassName => {\n // Use simple array with push for better performance\n const modifiers: string[] = []\n\n let bracketDepth = 0\n let parenDepth = 0\n let modifierStart = 0\n let postfixModifierPosition: number | undefined\n\n const len = className.length\n for (let index = 0; index < len; index++) {\n const currentCharacter = className[index]!\n\n if (bracketDepth === 0 && parenDepth === 0) {\n if (currentCharacter === MODIFIER_SEPARATOR) {\n modifiers.push(className.slice(modifierStart, index))\n modifierStart = index + 1\n continue\n }\n\n if (currentCharacter === '/') {\n postfixModifierPosition = index\n continue\n }\n }\n\n if (currentCharacter === '[') bracketDepth++\n else if (currentCharacter === ']') bracketDepth--\n else if (currentCharacter === '(') parenDepth++\n else if (currentCharacter === ')') parenDepth--\n }\n\n const baseClassNameWithImportantModifier =\n modifiers.length === 0 ? className : className.slice(modifierStart)\n\n // Inline important modifier check\n let baseClassName = baseClassNameWithImportantModifier\n let hasImportantModifier = false\n\n if (baseClassNameWithImportantModifier.endsWith(IMPORTANT_MODIFIER)) {\n baseClassName = baseClassNameWithImportantModifier.slice(0, -1)\n hasImportantModifier = true\n } else if (\n /**\n * In Tailwind CSS v3 the important modifier was at the start of the base class name. This is still supported for legacy reasons.\n * @see https://github.com/dcastil/tailwind-merge/issues/513#issuecomment-2614029864\n */\n baseClassNameWithImportantModifier.startsWith(IMPORTANT_MODIFIER)\n ) {\n baseClassName = baseClassNameWithImportantModifier.slice(1)\n hasImportantModifier = true\n }\n\n const maybePostfixModifierPosition =\n postfixModifierPosition && postfixModifierPosition > modifierStart\n ? postfixModifierPosition - modifierStart\n : undefined\n\n return createResultObject(\n modifiers,\n hasImportantModifier,\n baseClassName,\n maybePostfixModifierPosition,\n )\n }\n\n if (prefix) {\n const fullPrefix = prefix + MODIFIER_SEPARATOR\n const parseClassNameOriginal = parseClassName\n parseClassName = (className: string) =>\n className.startsWith(fullPrefix)\n ? parseClassNameOriginal(className.slice(fullPrefix.length))\n : createResultObject(EMPTY_MODIFIERS, false, className, undefined, true)\n }\n\n if (experimentalParseClassName) {\n const parseClassNameOriginal = parseClassName\n parseClassName = (className: string) =>\n experimentalParseClassName({ className, parseClassName: parseClassNameOriginal })\n }\n\n return parseClassName\n}\n","import { AnyConfig } from './types'\n\n/**\n * Sorts modifiers according to following schema:\n * - Predefined modifiers are sorted alphabetically\n * - When an arbitrary variant appears, it must be preserved which modifiers are before and after it\n */\nexport const createSortModifiers = (config: AnyConfig) => {\n // Pre-compute weights for all known modifiers for O(1) comparison\n const modifierWeights = new Map<string, number>()\n\n // Assign weights to sensitive modifiers (highest priority, but preserve order)\n config.orderSensitiveModifiers.forEach((mod, index) => {\n modifierWeights.set(mod, 1000000 + index) // High weights for sensitive mods\n })\n\n return (modifiers: readonly string[]): string[] => {\n const result: string[] = []\n let currentSegment: string[] = []\n\n // Process modifiers in one pass\n for (let i = 0; i < modifiers.length; i++) {\n const modifier = modifiers[i]!\n\n // Check if modifier is sensitive (starts with '[' or in orderSensitiveModifiers)\n const isArbitrary = modifier[0] === '['\n const isOrderSensitive = modifierWeights.has(modifier)\n\n if (isArbitrary || isOrderSensitive) {\n // Sort and flush current segment alphabetically\n if (currentSegment.length > 0) {\n currentSegment.sort()\n result.push(...currentSegment)\n currentSegment = []\n }\n result.push(modifier)\n } else {\n // Regular modifier - add to current segment for batch sorting\n currentSegment.push(modifier)\n }\n }\n\n // Sort and add any remaining segment items\n if (currentSegment.length > 0) {\n currentSegment.sort()\n result.push(...currentSegment)\n }\n\n return result\n }\n}\n","import { createClassGroupUtils } from './class-group-utils'\nimport { createLruCache } from './lru-cache'\nimport { createParseClassName } from './parse-class-name'\nimport { createSortModifiers } from './sort-modifiers'\nimport { AnyClassGroupIds, AnyConfig } from './types'\n\nexport type ConfigUtils = ReturnType<typeof createConfigUtils>\n\nexport const createConfigUtils = (config: AnyConfig) => ({\n cache: createLruCache<string, string>(config.cacheSize),\n parseClassName: createParseClassName(config),\n sortModifiers: createSortModifiers(config),\n postfixLookupClassGroupIds: createPostfixLookupClassGroupIds(config),\n ...createClassGroupUtils(config),\n})\n\nconst createPostfixLookupClassGroupIds = (config: AnyConfig) => {\n const lookup: Partial<Record<AnyClassGroupIds, true>> = Object.create(null)\n const classGroupIds = config.postfixLookupClassGroups\n\n if (classGroupIds) {\n for (let i = 0; i < classGroupIds.length; i++) {\n lookup[classGroupIds[i]!] = true\n }\n }\n\n return lookup\n}\n","import { ConfigUtils } from './config-utils'\nimport { IMPORTANT_MODIFIER } from './parse-class-name'\n\nconst SPLIT_CLASSES_REGEX = /\\s+/\n\nexport const mergeClassList = (classList: string, configUtils: ConfigUtils) => {\n const {\n parseClassName,\n getClassGroupId,\n getConflictingClassGroupIds,\n sortModifiers,\n postfixLookupClassGroupIds,\n } = configUtils\n\n /**\n * Set of classGroupIds in following format:\n * `{importantModifier}{variantModifiers}{classGroupId}`\n * @example 'float'\n * @example 'hover:focus:bg-color'\n * @example 'md:!pr'\n */\n const classGroupsInConflict: string[] = []\n const classNames = classList.trim().split(SPLIT_CLASSES_REGEX)\n\n let result = ''\n\n for (let index = classNames.length - 1; index >= 0; index -= 1) {\n const originalClassName = classNames[index]!\n\n const {\n isExternal,\n modifiers,\n hasImportantModifier,\n baseClassName,\n maybePostfixModifierPosition,\n } = parseClassName(originalClassName)\n\n if (isExternal) {\n result = originalClassName + (result.length > 0 ? ' ' + result : result)\n continue\n }\n\n let hasPostfixModifier = !!maybePostfixModifierPosition\n let classGroupId: ReturnType<typeof getClassGroupId>\n\n if (hasPostfixModifier) {\n const baseClassNameWithoutPostfix = baseClassName.substring(\n 0,\n maybePostfixModifierPosition,\n )\n classGroupId = getClassGroupId(baseClassNameWithoutPostfix)\n\n const classGroupIdWithPostfix =\n classGroupId && postfixLookupClassGroupIds[classGroupId]\n ? getClassGroupId(baseClassName)\n : undefined\n if (classGroupIdWithPostfix && classGroupIdWithPostfix !== classGroupId) {\n classGroupId = classGroupIdWithPostfix\n hasPostfixModifier = false\n }\n } else {\n classGroupId = getClassGroupId(baseClassName)\n }\n\n if (!classGroupId) {\n if (!hasPostfixModifier) {\n // Not a Tailwind class\n result = originalClassName + (result.length > 0 ? ' ' + result : result)\n continue\n }\n\n classGroupId = getClassGroupId(baseClassName)\n\n if (!classGroupId) {\n // Not a Tailwind class\n result = originalClassName + (result.length > 0 ? ' ' + result : result)\n continue\n }\n\n hasPostfixModifier = false\n }\n\n // Fast path: skip sorting for empty or single modifier\n const variantModifier =\n modifiers.length === 0\n ? ''\n : modifiers.length === 1\n ? modifiers[0]!\n : sortModifiers(modifiers).join(':')\n\n const modifierId = hasImportantModifier\n ? variantModifier + IMPORTANT_MODIFIER\n : variantModifier\n\n const classId = modifierId + classGroupId\n\n if (classGroupsInConflict.indexOf(classId) > -1) {\n // Tailwind class omitted due to conflict\n continue\n }\n\n classGroupsInConflict.push(classId)\n\n const conflictGroups = getConflictingClassGroupIds(classGroupId, hasPostfixModifier)\n for (let i = 0; i < conflictGroups.length; ++i) {\n const group = conflictGroups[i]!\n classGroupsInConflict.push(modifierId + group)\n }\n\n // Tailwind class not in conflict\n result = originalClassName + (result.length > 0 ? ' ' + result : result)\n }\n\n return result\n}\n","/**\n * The code in this file is copied from https://github.com/lukeed/clsx and modified to suit the needs of tailwind-merge better.\n *\n * Specifically:\n * - Runtime code from https://github.com/lukeed/clsx/blob/v1.2.1/src/index.js\n * - TypeScript types from https://github.com/lukeed/clsx/blob/v1.2.1/clsx.d.ts\n *\n * Original code has MIT license: Copyright (c) Luke Edwards <luke.edwards05@gmail.com> (lukeed.com)\n */\n\nexport type ClassNameValue = ClassNameArray | string | null | undefined | 0 | 0n | false\ntype ClassNameArray = readonly ClassNameValue[]\n\nexport const twJoin = (...classLists: ClassNameValue[]): string => {\n let index = 0\n let argument: ClassNameValue\n let resolvedValue: string\n let string = ''\n\n while (index < classLists.length) {\n if ((argument = classLists[index++])) {\n if ((resolvedValue = toValue(argument))) {\n string && (string += ' ')\n string += resolvedValue\n }\n }\n }\n return string\n}\n\nconst toValue = (mix: ClassNameArray | string): string => {\n // Fast path for strings\n if (typeof mix === 'string') {\n return mix\n }\n\n let resolvedValue: string\n let string = ''\n\n for (let k = 0; k < mix.length; k++) {\n if (mix[k]) {\n if ((resolvedValue = toValue(mix[k] as ClassNameArray | string))) {\n string && (string += ' ')\n string += resolvedValue\n }\n }\n }\n\n return string\n}\n","import { createConfigUtils } from './config-utils'\nimport { mergeClassList } from './merge-classlist'\nimport { ClassNameValue, twJoin } from './tw-join'\nimport { AnyConfig } from './types'\n\ntype CreateConfigFirst = () => AnyConfig\ntype CreateConfigSubsequent = (config: AnyConfig) => AnyConfig\ntype TailwindMerge = (...classLists: ClassNameValue[]) => string\ntype ConfigUtils = ReturnType<typeof createConfigUtils>\n\nexport const createTailwindMerge = (\n createConfigFirst: CreateConfigFirst,\n ...createConfigRest: CreateConfigSubsequent[]\n): TailwindMerge => {\n let configUtils: ConfigUtils\n let cacheGet: ConfigUtils['cache']['get']\n let cacheSet: ConfigUtils['cache']['set']\n let functionToCall: (classList: string) => string\n\n const initTailwindMerge = (classList: string) => {\n const config = createConfigRest.reduce(\n (previousConfig, createConfigCurrent) => createConfigCurrent(previousConfig),\n createConfigFirst() as AnyConfig,\n )\n\n configUtils = createConfigUtils(config)\n cacheGet = configUtils.cache.get\n cacheSet = configUtils.cache.set\n functionToCall = tailwindMerge\n\n return tailwindMerge(classList)\n }\n\n const tailwindMerge = (classList: string) => {\n const cachedResult = cacheGet(classList)\n\n if (cachedResult) {\n return cachedResult\n }\n\n const result = mergeClassList(classList, configUtils)\n cacheSet(classList, result)\n\n return result\n }\n\n functionToCall = initTailwindMerge\n\n return (...args: ClassNameValue[]) => functionToCall(twJoin(...args))\n}\n","import { DefaultThemeGroupIds, NoInfer, ThemeGetter, ThemeObject } from './types'\n\nconst fallbackThemeArr: ThemeObject<DefaultThemeGroupIds>[DefaultThemeGroupIds] = []\n\nexport const fromTheme = <\n AdditionalThemeGroupIds extends string = never,\n DefaultThemeGroupIdsInner extends string = DefaultThemeGroupIds,\n>(\n key: NoInfer<DefaultThemeGroupIdsInner | AdditionalThemeGroupIds>,\n): ThemeGetter => {\n const themeGetter = (theme: ThemeObject<DefaultThemeGroupIdsInner | AdditionalThemeGroupIds>) =>\n theme[key] || fallbackThemeArr\n\n themeGetter.isThemeGetter = true as const\n\n return themeGetter\n}\n","const arbitraryValueRegex = /^\\[(?:(\\w[\\w-]*):)?(.+)\\]$/i\nconst arbitraryVariableRegex = /^\\((?:(\\w[\\w-]*):)?(.+)\\)$/i\nconst fractionRegex = /^\\d+(?:\\.\\d+)?\\/\\d+(?:\\.\\d+)?$/\nconst tshirtUnitRegex = /^(\\d+(\\.\\d+)?)?(xs|sm|md|lg|xl)$/\nconst lengthUnitRegex =\n /\\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\\b(calc|min|max|clamp)\\(.+\\)|^0$/\nconst colorFunctionRegex = /^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\\(.+\\)$/\n// Shadow always begins with x and y offset separated by underscore optionally prepended by inset\nconst shadowRegex = /^(inset_)?-?((\\d+)?\\.?(\\d+)[a-z]+|0)_-?((\\d+)?\\.?(\\d+)[a-z]+|0)/\nconst imageRegex =\n /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\\(.+\\)$/\n\nexport const isFraction = (value: string) => fractionRegex.test(value)\n\nexport const isNumber = (value: string) => !!value && !Number.isNaN(Number(value))\n\nexport const isInteger = (value: string) => !!value && Number.isInteger(Number(value))\n\nexport const isPercent = (value: string) => value.endsWith('%') && isNumber(value.slice(0, -1))\n\nexport const isTshirtSize = (value: string) => tshirtUnitRegex.test(value)\n\nexport const isAny = () => true\n\nconst isLengthOnly = (value: string) =>\n // `colorFunctionRegex` check is necessary because color functions can have percentages in them which which would be incorrectly classified as lengths.\n // For example, `hsl(0 0% 0%)` would be classified as a length without this check.\n // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.\n lengthUnitRegex.test(value) && !colorFunctionRegex.test(value)\n\nconst isNever = () => false\n\nconst isShadow = (value: string) => shadowRegex.test(value)\n\nconst isImage = (value: string) => imageRegex.test(value)\n\nexport const isAnyNonArbitrary = (value: string) =>\n !isArbitraryValue(value) && !isArbitraryVariable(value)\n\nexport const isNamedContainerQuery = (value: string) =>\n value.startsWith('@container') &&\n ((value[10] === '/' && value[11] !== undefined) ||\n (value[11] === 's' && value[16] !== undefined && value.startsWith('-size/', 10)) ||\n (value[11] === 'n' && value[18] !== undefined && value.startsWith('-normal/', 10)))\n\nexport const isArbitrarySize = (value: string) => getIsArbitraryValue(value, isLabelSize, isNever)\n\nexport const isArbitraryValue = (value: string) => arbitraryValueRegex.test(value)\n\nexport const isArbitraryLength = (value: string) =>\n getIsArbitraryValue(value, isLabelLength, isLengthOnly)\n\nexport const isArbitraryNumber = (value: string) =>\n getIsArbitraryValue(value, isLabelNumber, isNumber)\n\nexport const isArbitraryWeight = (value: string) => getIsArbitraryValue(value, isLabelWeight, isAny)\n\nexport const isArbitraryFamilyName = (value: string) =>\n getIsArbitraryValue(value, isLabelFamilyName, isNever)\n\nexport const isArbitraryPosition = (value: string) =>\n getIsArbitraryValue(value, isLabelPosition, isNever)\n\nexport const isArbitraryImage = (value: string) => getIsArbitraryValue(value, isLabelImage, isImage)\n\nexport const isArbitraryShadow = (value: string) =>\n getIsArbitraryValue(value, isLabelShadow, isShadow)\n\nexport const isArbitraryVariable = (value: string) => arbitraryVariableRegex.test(value)\n\nexport const isArbitraryVariableLength = (value: string) =>\n getIsArbitraryVariable(value, isLabelLength)\n\nexport const isArbitraryVariableFamilyName = (value: string) =>\n getIsArbitraryVariable(value, isLabelFamilyName)\n\nexport const isArbitraryVariablePosition = (value: string) =>\n getIsArbitraryVariable(value, isLabelPosition)\n\nexport const isArbitraryVariableSize = (value: string) => getIsArbitraryVariable(value, isLabelSize)\n\nexport const isArbitraryVariableImage = (value: string) =>\n getIsArbitraryVariable(value, isLabelImage)\n\nexport const isArbitraryVariableShadow = (value: string) =>\n getIsArbitraryVariable(value, isLabelShadow, true)\n\nexport const isArbitraryVariableWeight = (value: string) =>\n getIsArbitraryVariable(value, isLabelWeight, true)\n\n// Helpers\n\nconst getIsArbitraryValue = (\n value: string,\n testLabel: (label: string) => boolean,\n testValue: (value: string) => boolean,\n) => {\n const result = arbitraryValueRegex.exec(value)\n\n if (result) {\n if (result[1]) {\n return testLabel(result[1])\n }\n\n return testValue(result[2]!)\n }\n\n return false\n}\n\nconst getIsArbitraryVariable = (\n value: string,\n testLabel: (label: string) => boolean,\n shouldMatchNoLabel = false,\n) => {\n const result = arbitraryVariableRegex.exec(value)\n\n if (result) {\n if (result[1]) {\n return testLabel(result[1])\n }\n return shouldMatchNoLabel\n }\n\n return false\n}\n\n// Labels\n\nconst isLabelPosition = (label: string) => label === 'position' || label === 'percentage'\n\nconst isLabelImage = (label: string) => label === 'image' || label === 'url'\n\nconst isLabelSize = (label: string) => label === 'length' || label === 'size' || label === 'bg-size'\n\nconst isLabelLength = (label: string) => label === 'length'\n\nconst isLabelNumber = (label: string) => label === 'number'\n\nconst isLabelFamilyName = (label: string) => label === 'family-name'\n\nconst isLabelWeight = (label: string) => label === 'number' || label === 'weight'\n\nconst isLabelShadow = (label: string) => label === 'shadow'\n","import { fromTheme } from './from-theme'\nimport { Config, DefaultClassGroupIds, DefaultThemeGroupIds } from './types'\nimport {\n isAny,\n isAnyNonArbitrary,\n isArbitraryFamilyName,\n isArbitraryImage,\n isArbitraryLength,\n isArbitraryNumber,\n isArbitraryPosition,\n isArbitraryShadow,\n isArbitrarySize,\n isArbitraryValue,\n isArbitraryVariable,\n isArbitraryVariableFamilyName,\n isArbitraryVariableImage,\n isArbitraryVariableLength,\n isArbitraryVariablePosition,\n isArbitraryVariableShadow,\n isArbitraryVariableSize,\n isArbitraryVariableWeight,\n isArbitraryWeight,\n isFraction,\n isInteger,\n isNamedContainerQuery,\n isNumber,\n isPercent,\n isTshirtSize,\n} from './validators'\n\nexport const getDefaultConfig = () => {\n /**\n * Theme getters for theme variable namespaces\n * @see https://tailwindcss.com/docs/theme#theme-variable-namespaces\n */\n /***/\n\n const themeColor = fromTheme('color')\n const themeFont = fromTheme('font')\n const themeText = fromTheme('text')\n const themeFontWeight = fromTheme('font-weight')\n const themeTracking = fromTheme('tracking')\n const themeLeading = fromTheme('leading')\n const themeBreakpoint = fromTheme('breakpoint')\n const themeContainer = fromTheme('container')\n const themeSpacing = fromTheme('spacing')\n const themeRadius = fromTheme('radius')\n const themeShadow = fromTheme('shadow')\n const themeInsetShadow = fromTheme('inset-shadow')\n const themeTextShadow = fromTheme('text-shadow')\n const themeDropShadow = fromTheme('drop-shadow')\n const themeBlur = fromTheme('blur')\n const themePerspective = fromTheme('perspective')\n const themeAspect = fromTheme('aspect')\n const themeEase = fromTheme('ease')\n const themeAnimate = fromTheme('animate')\n\n /**\n * Helpers to avoid repeating the same scales\n *\n * We use functions that create a new array every time they're called instead of static arrays.\n * This ensures that users who modify any scale by mutating the array (e.g. with `array.push(element)`) don't accidentally mutate arrays in other parts of the config.\n */\n /***/\n\n const scaleBreak = () =>\n ['auto', 'avoid', 'all', 'avoid-page', 'page', 'left', 'right', 'column'] as const\n const scalePosition = () =>\n [\n 'center',\n 'top',\n 'bottom',\n 'left',\n 'right',\n 'top-left',\n // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378\n 'left-top',\n 'top-right',\n // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378\n 'right-top',\n 'bottom-right',\n // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378\n 'right-bottom',\n 'bottom-left',\n // Deprecated since Tailwind CSS v4.1.0, see https://github.com/tailwindlabs/tailwindcss/pull/17378\n 'left-bottom',\n ] as const\n const scalePositionWithArbitrary = () =>\n [...scalePosition(), isArbitraryVariable, isArbitraryValue] as const\n const scaleOverflow = () => ['auto', 'hidden', 'clip', 'visible', 'scroll'] as const\n const scaleOverscroll = () => ['auto', 'contain', 'none'] as const\n const scaleUnambiguousSpacing = () =>\n [isArbitraryVariable, isArbitraryValue, themeSpacing] as const\n const scaleInset = () => [isFraction, 'full', 'auto', ...scaleUnambiguousSpacing()] as const\n const scaleGridTemplateColsRows = () =>\n [isInteger, 'none', 'subgrid', isArbitraryVariable, isArbitraryValue] as const\n const scaleGridColRowStartAndEnd = () =>\n [\n 'auto',\n { span: ['full', isInteger, isArbitraryVariable, isArbitraryValue] },\n isInteger,\n isArbitraryVariable,\n isArbitraryValue,\n ] as const\n const scaleGridColRowStartOrEnd = () =>\n [isInteger, 'auto', isArbitraryVariable, isArbitraryValue] as const\n const scaleGridAutoColsRows = () =>\n ['auto', 'min', 'max', 'fr', isArbitraryVariable, isArbitraryValue] as const\n const scaleAlignPrimaryAxis = () =>\n [\n 'start',\n 'end',\n 'center',\n 'between',\n 'around',\n 'evenly',\n 'stretch',\n 'baseline',\n 'center-safe',\n 'end-safe',\n ] as const\n const scaleAlignSecondaryAxis = () =>\n ['start', 'end', 'center', 'stretch', 'center-safe', 'end-safe'] as const\n const scaleMargin = () => ['auto', ...scaleUnambiguousSpacing()] as const\n const scaleSizing = () =>\n [\n isFraction,\n 'auto',\n 'full',\n 'dvw',\n 'dvh',\n 'lvw',\n 'lvh',\n 'svw',\n 'svh',\n 'min',\n 'max',\n 'fit',\n ...scaleUnambiguousSpacing(),\n ] as const\n const scaleSizingInline = () =>\n [\n isFraction,\n 'screen',\n 'full',\n 'dvw',\n 'lvw',\n 'svw',\n 'min',\n 'max',\n 'fit',\n ...scaleUnambiguousSpacing(),\n ] as const\n const scaleSizingBlock = () =>\n [\n isFraction,\n 'screen',\n 'full',\n 'lh',\n 'dvh',\n 'lvh',\n 'svh',\n 'min',\n 'max',\n 'fit',\n ...scaleUnambiguousSpacing(),\n ] as const\n const scaleColor = () => [themeColor, isArbitraryVariable, isArbitraryValue] as const\n const scaleBgPosition = () =>\n [\n ...scalePosition(),\n isArbitraryVariablePosition,\n isArbitraryPosition,\n { position: [isArbitraryVariable, isArbitraryValue] },\n ] as const\n const scaleBgRepeat = () => ['no-repeat', { repeat: ['', 'x', 'y', 'space', 'round'] }] as const\n const scaleBgSize = () =>\n [\n 'auto',\n 'cover',\n 'contain',\n isArbitraryVariableSize,\n isArbitrarySize,\n { size: [isArbitraryVariable, isArbitraryValue] },\n ] as const\n const scaleGradientStopPosition = () =>\n [isPercent, isArbitraryVariableLength, isArbitraryLength] as const\n const scaleRadius = () =>\n [\n // Deprecated since Tailwind CSS v4.0.0\n '',\n 'none',\n 'full',\n themeRadius,\n isArbitraryVariable,\n isArbitraryValue,\n ] as const\n const scaleBorderWidth = () =>\n ['', isNumber, isArbitraryVariableLength, isArbitraryLength] as const\n const scaleLineStyle = () => ['solid', 'dashed', 'dotted', 'double'] as const\n const scaleBlendMode = () =>\n [\n 'normal',\n 'multiply',\n 'screen',\n 'overlay',\n 'darken',\n 'lighten',\n 'color-dodge',\n 'color-burn',\n 'hard-light',\n 'soft-light',\n 'difference',\n 'exclusion',\n 'hue',\n 'saturation',\n 'color',\n 'luminosity',\n ] as const\n const scaleMaskImagePosition = () =>\n [isNumber, isPercent, isArbitraryVariablePosition, isArbitraryPosition] as const\n const scaleBlur = () =>\n [\n // Deprecated since Tailwind CSS v4.0.0\n '',\n 'none',\n themeBlur,\n isArbitraryVariable,\n isArbitraryValue,\n ] as const\n const scaleRotate = () => ['none', isNumber, isArbitraryVariable, isArbitraryValue] as const\n const scaleScale = () => ['none', isNumber, isArbitraryVariable, isArbitraryValue] as const\n const scaleSkew = () => [isNumber, isArbitraryVariable, isArbitraryValue] as const\n const scaleTranslate = () => [isFraction, 'full', ...scaleUnambiguousSpacing()] as const\n\n return {\n cacheSize: 500,\n theme: {\n animate: ['spin', 'ping', 'pulse', 'bounce'],\n aspect: ['video'],\n blur: [isTshirtSize],\n breakpoint: [isTshirtSize],\n color: [isAny],\n container: [isTshirtSize],\n 'drop-shadow': [isTshirtSize],\n ease: ['in', 'out', 'in-out'],\n font: [isAnyNonArbitrary],\n 'font-weight': [\n 'thin',\n 'extralight',\n 'light',\n 'normal',\n 'medium',\n 'semibold',\n 'bold',\n 'extrabold',\n 'black',\n ],\n 'inset-shadow': [isTshirtSize],\n leading: ['none', 'tight', 'snug', 'normal', 'relaxed', 'loose'],\n perspective: ['dramatic', 'near', 'normal', 'midrange', 'distant', 'none'],\n radius: [isTshirtSize],\n shadow: [isTshirtSize],\n spacing: ['px', isNumber],\n text: [isTshirtSize],\n 'text-shadow': [isTshirtSize],\n tracking: ['tighter', 'tight', 'normal', 'wide', 'wider', 'widest'],\n },\n classGroups: {\n // --------------\n // --- Layout ---\n // --------------\n\n /**\n * Aspect Ratio\n * @see https://tailwindcss.com/docs/aspect-ratio\n */\n aspect: [\n {\n aspect: [\n 'auto',\n 'square',\n isFraction,\n isArbitraryValue,\n isArbitraryVariable,\n themeAspect,\n ],\n },\n ],\n /**\n * Container\n * @see https://tailwindcss.com/docs/container\n * @deprecated since Tailwind CSS v4.0.0\n */\n container: ['container'],\n /**\n * Container Type\n * @see https://tailwindcss.com/docs/responsive-design#container-queries\n */\n 'container-type': [\n { '@container': ['', 'normal', 'size', isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Container Name\n * @see https://tailwindcss.com/docs/responsive-design#named-containers\n */\n 'container-named': [isNamedContainerQuery],\n /**\n * Columns\n * @see https://tailwindcss.com/docs/columns\n */\n columns: [\n { columns: [isNumber, isArbitraryValue, isArbitraryVariable, themeContainer] },\n ],\n /**\n * Break After\n * @see https://tailwindcss.com/docs/break-after\n */\n 'break-after': [{ 'break-after': scaleBreak() }],\n /**\n * Break Before\n * @see https://tailwindcss.com/docs/break-before\n */\n 'break-before': [{ 'break-before': scaleBreak() }],\n /**\n * Break Inside\n * @see https://tailwindcss.com/docs/break-inside\n */\n 'break-inside': [{ 'break-inside': ['auto', 'avoid', 'avoid-page', 'avoid-column'] }],\n /**\n * Box Decoration Break\n * @see https://tailwindcss.com/docs/box-decoration-break\n */\n 'box-decoration': [{ 'box-decoration': ['slice', 'clone'] }],\n /**\n * Box Sizing\n * @see https://tailwindcss.com/docs/box-sizing\n */\n box: [{ box: ['border', 'content'] }],\n /**\n * Display\n * @see https://tailwindcss.com/docs/display\n */\n display: [\n 'block',\n 'inline-block',\n 'inline',\n 'flex',\n 'inline-flex',\n 'table',\n 'inline-table',\n 'table-caption',\n 'table-cell',\n 'table-column',\n 'table-column-group',\n 'table-footer-group',\n 'table-header-group',\n 'table-row-group',\n 'table-row',\n 'flow-root',\n 'grid',\n 'inline-grid',\n 'contents',\n 'list-item',\n 'hidden',\n ],\n /**\n * Screen Reader Only\n * @see https://tailwindcss.com/docs/display#screen-reader-only\n */\n sr: ['sr-only', 'not-sr-only'],\n /**\n * Floats\n * @see https://tailwindcss.com/docs/float\n */\n float: [{ float: ['right', 'left', 'none', 'start', 'end'] }],\n /**\n * Clear\n * @see https://tailwindcss.com/docs/clear\n */\n clear: [{ clear: ['left', 'right', 'both', 'none', 'start', 'end'] }],\n /**\n * Isolation\n * @see https://tailwindcss.com/docs/isolation\n */\n isolation: ['isolate', 'isolation-auto'],\n /**\n * Object Fit\n * @see https://tailwindcss.com/docs/object-fit\n */\n 'object-fit': [{ object: ['contain', 'cover', 'fill', 'none', 'scale-down'] }],\n /**\n * Object Position\n * @see https://tailwindcss.com/docs/object-position\n */\n 'object-position': [{ object: scalePositionWithArbitrary() }],\n /**\n * Overflow\n * @see https://tailwindcss.com/docs/overflow\n */\n overflow: [{ overflow: scaleOverflow() }],\n /**\n * Overflow X\n * @see https://tailwindcss.com/docs/overflow\n */\n 'overflow-x': [{ 'overflow-x': scaleOverflow() }],\n /**\n * Overflow Y\n * @see https://tailwindcss.com/docs/overflow\n */\n 'overflow-y': [{ 'overflow-y': scaleOverflow() }],\n /**\n * Overscroll Behavior\n * @see https://tailwindcss.com/docs/overscroll-behavior\n */\n overscroll: [{ overscroll: scaleOverscroll() }],\n /**\n * Overscroll Behavior X\n * @see https://tailwindcss.com/docs/overscroll-behavior\n */\n 'overscroll-x': [{ 'overscroll-x': scaleOverscroll() }],\n /**\n * Overscroll Behavior Y\n * @see https://tailwindcss.com/docs/overscroll-behavior\n */\n 'overscroll-y': [{ 'overscroll-y': scaleOverscroll() }],\n /**\n * Position\n * @see https://tailwindcss.com/docs/position\n */\n position: ['static', 'fixed', 'absolute', 'relative', 'sticky'],\n /**\n * Inset\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n inset: [{ inset: scaleInset() }],\n /**\n * Inset Inline\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n 'inset-x': [{ 'inset-x': scaleInset() }],\n /**\n * Inset Block\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n 'inset-y': [{ 'inset-y': scaleInset() }],\n /**\n * Inset Inline Start\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n * @todo class group will be renamed to `inset-s` in next major release\n */\n start: [\n {\n 'inset-s': scaleInset(),\n /**\n * @deprecated since Tailwind CSS v4.2.0 in favor of `inset-s-*` utilities.\n * @see https://github.com/tailwindlabs/tailwindcss/pull/19613\n */\n start: scaleInset(),\n },\n ],\n /**\n * Inset Inline End\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n * @todo class group will be renamed to `inset-e` in next major release\n */\n end: [\n {\n 'inset-e': scaleInset(),\n /**\n * @deprecated since Tailwind CSS v4.2.0 in favor of `inset-e-*` utilities.\n * @see https://github.com/tailwindlabs/tailwindcss/pull/19613\n */\n end: scaleInset(),\n },\n ],\n /**\n * Inset Block Start\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n 'inset-bs': [{ 'inset-bs': scaleInset() }],\n /**\n * Inset Block End\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n 'inset-be': [{ 'inset-be': scaleInset() }],\n /**\n * Top\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n top: [{ top: scaleInset() }],\n /**\n * Right\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n right: [{ right: scaleInset() }],\n /**\n * Bottom\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n bottom: [{ bottom: scaleInset() }],\n /**\n * Left\n * @see https://tailwindcss.com/docs/top-right-bottom-left\n */\n left: [{ left: scaleInset() }],\n /**\n * Visibility\n * @see https://tailwindcss.com/docs/visibility\n */\n visibility: ['visible', 'invisible', 'collapse'],\n /**\n * Z-Index\n * @see https://tailwindcss.com/docs/z-index\n */\n z: [{ z: [isInteger, 'auto', isArbitraryVariable, isArbitraryValue] }],\n\n // ------------------------\n // --- Flexbox and Grid ---\n // ------------------------\n\n /**\n * Flex Basis\n * @see https://tailwindcss.com/docs/flex-basis\n */\n basis: [\n {\n basis: [\n isFraction,\n 'full',\n 'auto',\n themeContainer,\n ...scaleUnambiguousSpacing(),\n ],\n },\n ],\n /**\n * Flex Direction\n * @see https://tailwindcss.com/docs/flex-direction\n */\n 'flex-direction': [{ flex: ['row', 'row-reverse', 'col', 'col-reverse'] }],\n /**\n * Flex Wrap\n * @see https://tailwindcss.com/docs/flex-wrap\n */\n 'flex-wrap': [{ flex: ['nowrap', 'wrap', 'wrap-reverse'] }],\n /**\n * Flex\n * @see https://tailwindcss.com/docs/flex\n */\n flex: [{ flex: [isNumber, isFraction, 'auto', 'initial', 'none', isArbitraryValue] }],\n /**\n * Flex Grow\n * @see https://tailwindcss.com/docs/flex-grow\n */\n grow: [{ grow: ['', isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Flex Shrink\n * @see https://tailwindcss.com/docs/flex-shrink\n */\n shrink: [{ shrink: ['', isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Order\n * @see https://tailwindcss.com/docs/order\n */\n order: [\n {\n order: [\n isInteger,\n 'first',\n 'last',\n 'none',\n isArbitraryVariable,\n isArbitraryValue,\n ],\n },\n ],\n /**\n * Grid Template Columns\n * @see https://tailwindcss.com/docs/grid-template-columns\n */\n 'grid-cols': [{ 'grid-cols': scaleGridTemplateColsRows() }],\n /**\n * Grid Column Start / End\n * @see https://tailwindcss.com/docs/grid-column\n */\n 'col-start-end': [{ col: scaleGridColRowStartAndEnd() }],\n /**\n * Grid Column Start\n * @see https://tailwindcss.com/docs/grid-column\n */\n 'col-start': [{ 'col-start': scaleGridColRowStartOrEnd() }],\n /**\n * Grid Column End\n * @see https://tailwindcss.com/docs/grid-column\n */\n 'col-end': [{ 'col-end': scaleGridColRowStartOrEnd() }],\n /**\n * Grid Template Rows\n * @see https://tailwindcss.com/docs/grid-template-rows\n */\n 'grid-rows': [{ 'grid-rows': scaleGridTemplateColsRows() }],\n /**\n * Grid Row Start / End\n * @see https://tailwindcss.com/docs/grid-row\n */\n 'row-start-end': [{ row: scaleGridColRowStartAndEnd() }],\n /**\n * Grid Row Start\n * @see https://tailwindcss.com/docs/grid-row\n */\n 'row-start': [{ 'row-start': scaleGridColRowStartOrEnd() }],\n /**\n * Grid Row End\n * @see https://tailwindcss.com/docs/grid-row\n */\n 'row-end': [{ 'row-end': scaleGridColRowStartOrEnd() }],\n /**\n * Grid Auto Flow\n * @see https://tailwindcss.com/docs/grid-auto-flow\n */\n 'grid-flow': [{ 'grid-flow': ['row', 'col', 'dense', 'row-dense', 'col-dense'] }],\n /**\n * Grid Auto Columns\n * @see https://tailwindcss.com/docs/grid-auto-columns\n */\n 'auto-cols': [{ 'auto-cols': scaleGridAutoColsRows() }],\n /**\n * Grid Auto Rows\n * @see https://tailwindcss.com/docs/grid-auto-rows\n */\n 'auto-rows': [{ 'auto-rows': scaleGridAutoColsRows() }],\n /**\n * Gap\n * @see https://tailwindcss.com/docs/gap\n */\n gap: [{ gap: scaleUnambiguousSpacing() }],\n /**\n * Gap X\n * @see https://tailwindcss.com/docs/gap\n */\n 'gap-x': [{ 'gap-x': scaleUnambiguousSpacing() }],\n /**\n * Gap Y\n * @see https://tailwindcss.com/docs/gap\n */\n 'gap-y': [{ 'gap-y': scaleUnambiguousSpacing() }],\n /**\n * Justify Content\n * @see https://tailwindcss.com/docs/justify-content\n */\n 'justify-content': [{ justify: [...scaleAlignPrimaryAxis(), 'normal'] }],\n /**\n * Justify Items\n * @see https://tailwindcss.com/docs/justify-items\n */\n 'justify-items': [{ 'justify-items': [...scaleAlignSecondaryAxis(), 'normal'] }],\n /**\n * Justify Self\n * @see https://tailwindcss.com/docs/justify-self\n */\n 'justify-self': [{ 'justify-self': ['auto', ...scaleAlignSecondaryAxis()] }],\n /**\n * Align Content\n * @see https://tailwindcss.com/docs/align-content\n */\n 'align-content': [{ content: ['normal', ...scaleAlignPrimaryAxis()] }],\n /**\n * Align Items\n * @see https://tailwindcss.com/docs/align-items\n */\n 'align-items': [{ items: [...scaleAlignSecondaryAxis(), { baseline: ['', 'last'] }] }],\n /**\n * Align Self\n * @see https://tailwindcss.com/docs/align-self\n */\n 'align-self': [\n { self: ['auto', ...scaleAlignSecondaryAxis(), { baseline: ['', 'last'] }] },\n ],\n /**\n * Place Content\n * @see https://tailwindcss.com/docs/place-content\n */\n 'place-content': [{ 'place-content': scaleAlignPrimaryAxis() }],\n /**\n * Place Items\n * @see https://tailwindcss.com/docs/place-items\n */\n 'place-items': [{ 'place-items': [...scaleAlignSecondaryAxis(), 'baseline'] }],\n /**\n * Place Self\n * @see https://tailwindcss.com/docs/place-self\n */\n 'place-self': [{ 'place-self': ['auto', ...scaleAlignSecondaryAxis()] }],\n // Spacing\n /**\n * Padding\n * @see https://tailwindcss.com/docs/padding\n */\n p: [{ p: scaleUnambiguousSpacing() }],\n /**\n * Padding Inline\n * @see https://tailwindcss.com/docs/padding\n */\n px: [{ px: scaleUnambiguousSpacing() }],\n /**\n * Padding Block\n * @see https://tailwindcss.com/docs/padding\n */\n py: [{ py: scaleUnambiguousSpacing() }],\n /**\n * Padding Inline Start\n * @see https://tailwindcss.com/docs/padding\n */\n ps: [{ ps: scaleUnambiguousSpacing() }],\n /**\n * Padding Inline End\n * @see https://tailwindcss.com/docs/padding\n */\n pe: [{ pe: scaleUnambiguousSpacing() }],\n /**\n * Padding Block Start\n * @see https://tailwindcss.com/docs/padding\n */\n pbs: [{ pbs: scaleUnambiguousSpacing() }],\n /**\n * Padding Block End\n * @see https://tailwindcss.com/docs/padding\n */\n pbe: [{ pbe: scaleUnambiguousSpacing() }],\n /**\n * Padding Top\n * @see https://tailwindcss.com/docs/padding\n */\n pt: [{ pt: scaleUnambiguousSpacing() }],\n /**\n * Padding Right\n * @see https://tailwindcss.com/docs/padding\n */\n pr: [{ pr: scaleUnambiguousSpacing() }],\n /**\n * Padding Bottom\n * @see https://tailwindcss.com/docs/padding\n */\n pb: [{ pb: scaleUnambiguousSpacing() }],\n /**\n * Padding Left\n * @see https://tailwindcss.com/docs/padding\n */\n pl: [{ pl: scaleUnambiguousSpacing() }],\n /**\n * Margin\n * @see https://tailwindcss.com/docs/margin\n */\n m: [{ m: scaleMargin() }],\n /**\n * Margin Inline\n * @see https://tailwindcss.com/docs/margin\n */\n mx: [{ mx: scaleMargin() }],\n /**\n * Margin Block\n * @see https://tailwindcss.com/docs/margin\n */\n my: [{ my: scaleMargin() }],\n /**\n * Margin Inline Start\n * @see https://tailwindcss.com/docs/margin\n */\n ms: [{ ms: scaleMargin() }],\n /**\n * Margin Inline End\n * @see https://tailwindcss.com/docs/margin\n */\n me: [{ me: scaleMargin() }],\n /**\n * Margin Block Start\n * @see https://tailwindcss.com/docs/margin\n */\n mbs: [{ mbs: scaleMargin() }],\n /**\n * Margin Block End\n * @see https://tailwindcss.com/docs/margin\n */\n mbe: [{ mbe: scaleMargin() }],\n /**\n * Margin Top\n * @see https://tailwindcss.com/docs/margin\n */\n mt: [{ mt: scaleMargin() }],\n /**\n * Margin Right\n * @see https://tailwindcss.com/docs/margin\n */\n mr: [{ mr: scaleMargin() }],\n /**\n * Margin Bottom\n * @see https://tailwindcss.com/docs/margin\n */\n mb: [{ mb: scaleMargin() }],\n /**\n * Margin Left\n * @see https://tailwindcss.com/docs/margin\n */\n ml: [{ ml: scaleMargin() }],\n /**\n * Space Between X\n * @see https://tailwindcss.com/docs/margin#adding-space-between-children\n */\n 'space-x': [{ 'space-x': scaleUnambiguousSpacing() }],\n /**\n * Space Between X Reverse\n * @see https://tailwindcss.com/docs/margin#adding-space-between-children\n */\n 'space-x-reverse': ['space-x-reverse'],\n /**\n * Space Between Y\n * @see https://tailwindcss.com/docs/margin#adding-space-between-children\n */\n 'space-y': [{ 'space-y': scaleUnambiguousSpacing() }],\n /**\n * Space Between Y Reverse\n * @see https://tailwindcss.com/docs/margin#adding-space-between-children\n */\n 'space-y-reverse': ['space-y-reverse'],\n\n // --------------\n // --- Sizing ---\n // --------------\n\n /**\n * Size\n * @see https://tailwindcss.com/docs/width#setting-both-width-and-height\n */\n size: [{ size: scaleSizing() }],\n /**\n * Inline Size\n * @see https://tailwindcss.com/docs/width\n */\n 'inline-size': [{ inline: ['auto', ...scaleSizingInline()] }],\n /**\n * Min-Inline Size\n * @see https://tailwindcss.com/docs/min-width\n */\n 'min-inline-size': [{ 'min-inline': ['auto', ...scaleSizingInline()] }],\n /**\n * Max-Inline Size\n * @see https://tailwindcss.com/docs/max-width\n */\n 'max-inline-size': [{ 'max-inline': ['none', ...scaleSizingInline()] }],\n /**\n * Block Size\n * @see https://tailwindcss.com/docs/height\n */\n 'block-size': [{ block: ['auto', ...scaleSizingBlock()] }],\n /**\n * Min-Block Size\n * @see https://tailwindcss.com/docs/min-height\n */\n 'min-block-size': [{ 'min-block': ['auto', ...scaleSizingBlock()] }],\n /**\n * Max-Block Size\n * @see https://tailwindcss.com/docs/max-height\n */\n 'max-block-size': [{ 'max-block': ['none', ...scaleSizingBlock()] }],\n /**\n * Width\n * @see https://tailwindcss.com/docs/width\n */\n w: [{ w: [themeContainer, 'screen', ...scaleSizing()] }],\n /**\n * Min-Width\n * @see https://tailwindcss.com/docs/min-width\n */\n 'min-w': [\n {\n 'min-w': [\n themeContainer,\n 'screen',\n /** Deprecated. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */\n 'none',\n ...scaleSizing(),\n ],\n },\n ],\n /**\n * Max-Width\n * @see https://tailwindcss.com/docs/max-width\n */\n 'max-w': [\n {\n 'max-w': [\n themeContainer,\n 'screen',\n 'none',\n /** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */\n 'prose',\n /** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */\n { screen: [themeBreakpoint] },\n ...scaleSizing(),\n ],\n },\n ],\n /**\n * Height\n * @see https://tailwindcss.com/docs/height\n */\n h: [{ h: ['screen', 'lh', ...scaleSizing()] }],\n /**\n * Min-Height\n * @see https://tailwindcss.com/docs/min-height\n */\n 'min-h': [{ 'min-h': ['screen', 'lh', 'none', ...scaleSizing()] }],\n /**\n * Max-Height\n * @see https://tailwindcss.com/docs/max-height\n */\n 'max-h': [{ 'max-h': ['screen', 'lh', ...scaleSizing()] }],\n\n // ------------------\n // --- Typography ---\n // ------------------\n\n /**\n * Font Size\n * @see https://tailwindcss.com/docs/font-size\n */\n 'font-size': [\n { text: ['base', themeText, isArbitraryVariableLength, isArbitraryLength] },\n ],\n /**\n * Font Smoothing\n * @see https://tailwindcss.com/docs/font-smoothing\n */\n 'font-smoothing': ['antialiased', 'subpixel-antialiased'],\n /**\n * Font Style\n * @see https://tailwindcss.com/docs/font-style\n */\n 'font-style': ['italic', 'not-italic'],\n /**\n * Font Weight\n * @see https://tailwindcss.com/docs/font-weight\n */\n 'font-weight': [\n {\n font: [themeFontWeight, isArbitraryVariableWeight, isArbitraryWeight],\n },\n ],\n /**\n * Font Stretch\n * @see https://tailwindcss.com/docs/font-stretch\n */\n 'font-stretch': [\n {\n 'font-stretch': [\n 'ultra-condensed',\n 'extra-condensed',\n 'condensed',\n 'semi-condensed',\n 'normal',\n 'semi-expanded',\n 'expanded',\n 'extra-expanded',\n 'ultra-expanded',\n isPercent,\n isArbitraryValue,\n ],\n },\n ],\n /**\n * Font Family\n * @see https://tailwindcss.com/docs/font-family\n */\n 'font-family': [\n { font: [isArbitraryVariableFamilyName, isArbitraryFamilyName, themeFont] },\n ],\n /**\n * Font Feature Settings\n * @see https://tailwindcss.com/docs/font-feature-settings\n */\n 'font-features': [{ 'font-features': [isArbitraryValue] }],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-normal': ['normal-nums'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-ordinal': ['ordinal'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-slashed-zero': ['slashed-zero'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-figure': ['lining-nums', 'oldstyle-nums'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-spacing': ['proportional-nums', 'tabular-nums'],\n /**\n * Font Variant Numeric\n * @see https://tailwindcss.com/docs/font-variant-numeric\n */\n 'fvn-fraction': ['diagonal-fractions', 'stacked-fractions'],\n /**\n * Letter Spacing\n * @see https://tailwindcss.com/docs/letter-spacing\n */\n tracking: [{ tracking: [themeTracking, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Line Clamp\n * @see https://tailwindcss.com/docs/line-clamp\n */\n 'line-clamp': [\n { 'line-clamp': [isNumber, 'none', isArbitraryVariable, isArbitraryNumber] },\n ],\n /**\n * Line Height\n * @see https://tailwindcss.com/docs/line-height\n */\n leading: [\n {\n leading: [\n /** Deprecated since Tailwind CSS v4.0.0. @see https://github.com/tailwindlabs/tailwindcss.com/issues/2027#issuecomment-2620152757 */\n themeLeading,\n ...scaleUnambiguousSpacing(),\n ],\n },\n ],\n /**\n * List Style Image\n * @see https://tailwindcss.com/docs/list-style-image\n */\n 'list-image': [{ 'list-image': ['none', isArbitraryVariable, isArbitraryValue] }],\n /**\n * List Style Position\n * @see https://tailwindcss.com/docs/list-style-position\n */\n 'list-style-position': [{ list: ['inside', 'outside'] }],\n /**\n * List Style Type\n * @see https://tailwindcss.com/docs/list-style-type\n */\n 'list-style-type': [\n { list: ['disc', 'decimal', 'none', isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Text Alignment\n * @see https://tailwindcss.com/docs/text-align\n */\n 'text-alignment': [{ text: ['left', 'center', 'right', 'justify', 'start', 'end'] }],\n /**\n * Placeholder Color\n * @deprecated since Tailwind CSS v3.0.0\n * @see https://v3.tailwindcss.com/docs/placeholder-color\n */\n 'placeholder-color': [{ placeholder: scaleColor() }],\n /**\n * Text Color\n * @see https://tailwindcss.com/docs/text-color\n */\n 'text-color': [{ text: scaleColor() }],\n /**\n * Text Decoration\n * @see https://tailwindcss.com/docs/text-decoration\n */\n 'text-decoration': ['underline', 'overline', 'line-through', 'no-underline'],\n /**\n * Text Decoration Style\n * @see https://tailwindcss.com/docs/text-decoration-style\n */\n 'text-decoration-style': [{ decoration: [...scaleLineStyle(), 'wavy'] }],\n /**\n * Text Decoration Thickness\n * @see https://tailwindcss.com/docs/text-decoration-thickness\n */\n 'text-decoration-thickness': [\n {\n decoration: [\n isNumber,\n 'from-font',\n 'auto',\n isArbitraryVariable,\n isArbitraryLength,\n ],\n },\n ],\n /**\n * Text Decoration Color\n * @see https://tailwindcss.com/docs/text-decoration-color\n */\n 'text-decoration-color': [{ decoration: scaleColor() }],\n /**\n * Text Underline Offset\n * @see https://tailwindcss.com/docs/text-underline-offset\n */\n 'underline-offset': [\n { 'underline-offset': [isNumber, 'auto', isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Text Transform\n * @see https://tailwindcss.com/docs/text-transform\n */\n 'text-transform': ['uppercase', 'lowercase', 'capitalize', 'normal-case'],\n /**\n * Text Overflow\n * @see https://tailwindcss.com/docs/text-overflow\n */\n 'text-overflow': ['truncate', 'text-ellipsis', 'text-clip'],\n /**\n * Text Wrap\n * @see https://tailwindcss.com/docs/text-wrap\n */\n 'text-wrap': [{ text: ['wrap', 'nowrap', 'balance', 'pretty'] }],\n /**\n * Text Indent\n * @see https://tailwindcss.com/docs/text-indent\n */\n indent: [{ indent: scaleUnambiguousSpacing() }],\n /**\n * Tab Size\n * @see https://tailwindcss.com/docs/tab-size\n */\n 'tab-size': [{ tab: [isInteger, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Vertical Alignment\n * @see https://tailwindcss.com/docs/vertical-align\n */\n 'vertical-align': [\n {\n align: [\n 'baseline',\n 'top',\n 'middle',\n 'bottom',\n 'text-top',\n 'text-bottom',\n 'sub',\n 'super',\n isArbitraryVariable,\n isArbitraryValue,\n ],\n },\n ],\n /**\n * Whitespace\n * @see https://tailwindcss.com/docs/whitespace\n */\n whitespace: [\n { whitespace: ['normal', 'nowrap', 'pre', 'pre-line', 'pre-wrap', 'break-spaces'] },\n ],\n /**\n * Word Break\n * @see https://tailwindcss.com/docs/word-break\n */\n break: [{ break: ['normal', 'words', 'all', 'keep'] }],\n /**\n * Overflow Wrap\n * @see https://tailwindcss.com/docs/overflow-wrap\n */\n wrap: [{ wrap: ['break-word', 'anywhere', 'normal'] }],\n /**\n * Hyphens\n * @see https://tailwindcss.com/docs/hyphens\n */\n hyphens: [{ hyphens: ['none', 'manual', 'auto'] }],\n /**\n * Content\n * @see https://tailwindcss.com/docs/content\n */\n content: [{ content: ['none', isArbitraryVariable, isArbitraryValue] }],\n\n // -------------------\n // --- Backgrounds ---\n // -------------------\n\n /**\n * Background Attachment\n * @see https://tailwindcss.com/docs/background-attachment\n */\n 'bg-attachment': [{ bg: ['fixed', 'local', 'scroll'] }],\n /**\n * Background Clip\n * @see https://tailwindcss.com/docs/background-clip\n */\n 'bg-clip': [{ 'bg-clip': ['border', 'padding', 'content', 'text'] }],\n /**\n * Background Origin\n * @see https://tailwindcss.com/docs/background-origin\n */\n 'bg-origin': [{ 'bg-origin': ['border', 'padding', 'content'] }],\n /**\n * Background Position\n * @see https://tailwindcss.com/docs/background-position\n */\n 'bg-position': [{ bg: scaleBgPosition() }],\n /**\n * Background Repeat\n * @see https://tailwindcss.com/docs/background-repeat\n */\n 'bg-repeat': [{ bg: scaleBgRepeat() }],\n /**\n * Background Size\n * @see https://tailwindcss.com/docs/background-size\n */\n 'bg-size': [{ bg: scaleBgSize() }],\n /**\n * Background Image\n * @see https://tailwindcss.com/docs/background-image\n */\n 'bg-image': [\n {\n bg: [\n 'none',\n {\n linear: [\n { to: ['t', 'tr', 'r', 'br', 'b', 'bl', 'l', 'tl'] },\n isInteger,\n isArbitraryVariable,\n isArbitraryValue,\n ],\n radial: ['', isArbitraryVariable, isArbitraryValue],\n conic: [isInteger, isArbitraryVariable, isArbitraryValue],\n },\n isArbitraryVariableImage,\n isArbitraryImage,\n ],\n },\n ],\n /**\n * Background Color\n * @see https://tailwindcss.com/docs/background-color\n */\n 'bg-color': [{ bg: scaleColor() }],\n /**\n * Gradient Color Stops From Position\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-from-pos': [{ from: scaleGradientStopPosition() }],\n /**\n * Gradient Color Stops Via Position\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-via-pos': [{ via: scaleGradientStopPosition() }],\n /**\n * Gradient Color Stops To Position\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-to-pos': [{ to: scaleGradientStopPosition() }],\n /**\n * Gradient Color Stops From\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-from': [{ from: scaleColor() }],\n /**\n * Gradient Color Stops Via\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-via': [{ via: scaleColor() }],\n /**\n * Gradient Color Stops To\n * @see https://tailwindcss.com/docs/gradient-color-stops\n */\n 'gradient-to': [{ to: scaleColor() }],\n\n // ---------------\n // --- Borders ---\n // ---------------\n\n /**\n * Border Radius\n * @see https://tailwindcss.com/docs/border-radius\n */\n rounded: [{ rounded: scaleRadius() }],\n /**\n * Border Radius Start\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-s': [{ 'rounded-s': scaleRadius() }],\n /**\n * Border Radius End\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-e': [{ 'rounded-e': scaleRadius() }],\n /**\n * Border Radius Top\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-t': [{ 'rounded-t': scaleRadius() }],\n /**\n * Border Radius Right\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-r': [{ 'rounded-r': scaleRadius() }],\n /**\n * Border Radius Bottom\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-b': [{ 'rounded-b': scaleRadius() }],\n /**\n * Border Radius Left\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-l': [{ 'rounded-l': scaleRadius() }],\n /**\n * Border Radius Start Start\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-ss': [{ 'rounded-ss': scaleRadius() }],\n /**\n * Border Radius Start End\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-se': [{ 'rounded-se': scaleRadius() }],\n /**\n * Border Radius End End\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-ee': [{ 'rounded-ee': scaleRadius() }],\n /**\n * Border Radius End Start\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-es': [{ 'rounded-es': scaleRadius() }],\n /**\n * Border Radius Top Left\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-tl': [{ 'rounded-tl': scaleRadius() }],\n /**\n * Border Radius Top Right\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-tr': [{ 'rounded-tr': scaleRadius() }],\n /**\n * Border Radius Bottom Right\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-br': [{ 'rounded-br': scaleRadius() }],\n /**\n * Border Radius Bottom Left\n * @see https://tailwindcss.com/docs/border-radius\n */\n 'rounded-bl': [{ 'rounded-bl': scaleRadius() }],\n /**\n * Border Width\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w': [{ border: scaleBorderWidth() }],\n /**\n * Border Width Inline\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-x': [{ 'border-x': scaleBorderWidth() }],\n /**\n * Border Width Block\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-y': [{ 'border-y': scaleBorderWidth() }],\n /**\n * Border Width Inline Start\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-s': [{ 'border-s': scaleBorderWidth() }],\n /**\n * Border Width Inline End\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-e': [{ 'border-e': scaleBorderWidth() }],\n /**\n * Border Width Block Start\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-bs': [{ 'border-bs': scaleBorderWidth() }],\n /**\n * Border Width Block End\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-be': [{ 'border-be': scaleBorderWidth() }],\n /**\n * Border Width Top\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-t': [{ 'border-t': scaleBorderWidth() }],\n /**\n * Border Width Right\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-r': [{ 'border-r': scaleBorderWidth() }],\n /**\n * Border Width Bottom\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-b': [{ 'border-b': scaleBorderWidth() }],\n /**\n * Border Width Left\n * @see https://tailwindcss.com/docs/border-width\n */\n 'border-w-l': [{ 'border-l': scaleBorderWidth() }],\n /**\n * Divide Width X\n * @see https://tailwindcss.com/docs/border-width#between-children\n */\n 'divide-x': [{ 'divide-x': scaleBorderWidth() }],\n /**\n * Divide Width X Reverse\n * @see https://tailwindcss.com/docs/border-width#between-children\n */\n 'divide-x-reverse': ['divide-x-reverse'],\n /**\n * Divide Width Y\n * @see https://tailwindcss.com/docs/border-width#between-children\n */\n 'divide-y': [{ 'divide-y': scaleBorderWidth() }],\n /**\n * Divide Width Y Reverse\n * @see https://tailwindcss.com/docs/border-width#between-children\n */\n 'divide-y-reverse': ['divide-y-reverse'],\n /**\n * Border Style\n * @see https://tailwindcss.com/docs/border-style\n */\n 'border-style': [{ border: [...scaleLineStyle(), 'hidden', 'none'] }],\n /**\n * Divide Style\n * @see https://tailwindcss.com/docs/border-style#setting-the-divider-style\n */\n 'divide-style': [{ divide: [...scaleLineStyle(), 'hidden', 'none'] }],\n /**\n * Border Color\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color': [{ border: scaleColor() }],\n /**\n * Border Color Inline\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-x': [{ 'border-x': scaleColor() }],\n /**\n * Border Color Block\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-y': [{ 'border-y': scaleColor() }],\n /**\n * Border Color Inline Start\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-s': [{ 'border-s': scaleColor() }],\n /**\n * Border Color Inline End\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-e': [{ 'border-e': scaleColor() }],\n /**\n * Border Color Block Start\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-bs': [{ 'border-bs': scaleColor() }],\n /**\n * Border Color Block End\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-be': [{ 'border-be': scaleColor() }],\n /**\n * Border Color Top\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-t': [{ 'border-t': scaleColor() }],\n /**\n * Border Color Right\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-r': [{ 'border-r': scaleColor() }],\n /**\n * Border Color Bottom\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-b': [{ 'border-b': scaleColor() }],\n /**\n * Border Color Left\n * @see https://tailwindcss.com/docs/border-color\n */\n 'border-color-l': [{ 'border-l': scaleColor() }],\n /**\n * Divide Color\n * @see https://tailwindcss.com/docs/divide-color\n */\n 'divide-color': [{ divide: scaleColor() }],\n /**\n * Outline Style\n * @see https://tailwindcss.com/docs/outline-style\n */\n 'outline-style': [{ outline: [...scaleLineStyle(), 'none', 'hidden'] }],\n /**\n * Outline Offset\n * @see https://tailwindcss.com/docs/outline-offset\n */\n 'outline-offset': [\n { 'outline-offset': [isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Outline Width\n * @see https://tailwindcss.com/docs/outline-width\n */\n 'outline-w': [\n { outline: ['', isNumber, isArbitraryVariableLength, isArbitraryLength] },\n ],\n /**\n * Outline Color\n * @see https://tailwindcss.com/docs/outline-color\n */\n 'outline-color': [{ outline: scaleColor() }],\n\n // ---------------\n // --- Effects ---\n // ---------------\n\n /**\n * Box Shadow\n * @see https://tailwindcss.com/docs/box-shadow\n */\n shadow: [\n {\n shadow: [\n // Deprecated since Tailwind CSS v4.0.0\n '',\n 'none',\n themeShadow,\n isArbitraryVariableShadow,\n isArbitraryShadow,\n ],\n },\n ],\n /**\n * Box Shadow Color\n * @see https://tailwindcss.com/docs/box-shadow#setting-the-shadow-color\n */\n 'shadow-color': [{ shadow: scaleColor() }],\n /**\n * Inset Box Shadow\n * @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-shadow\n */\n 'inset-shadow': [\n {\n 'inset-shadow': [\n 'none',\n themeInsetShadow,\n isArbitraryVariableShadow,\n isArbitraryShadow,\n ],\n },\n ],\n /**\n * Inset Box Shadow Color\n * @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-shadow-color\n */\n 'inset-shadow-color': [{ 'inset-shadow': scaleColor() }],\n /**\n * Ring Width\n * @see https://tailwindcss.com/docs/box-shadow#adding-a-ring\n */\n 'ring-w': [{ ring: scaleBorderWidth() }],\n /**\n * Ring Width Inset\n * @see https://v3.tailwindcss.com/docs/ring-width#inset-rings\n * @deprecated since Tailwind CSS v4.0.0\n * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158\n */\n 'ring-w-inset': ['ring-inset'],\n /**\n * Ring Color\n * @see https://tailwindcss.com/docs/box-shadow#setting-the-ring-color\n */\n 'ring-color': [{ ring: scaleColor() }],\n /**\n * Ring Offset Width\n * @see https://v3.tailwindcss.com/docs/ring-offset-width\n * @deprecated since Tailwind CSS v4.0.0\n * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158\n */\n 'ring-offset-w': [{ 'ring-offset': [isNumber, isArbitraryLength] }],\n /**\n * Ring Offset Color\n * @see https://v3.tailwindcss.com/docs/ring-offset-color\n * @deprecated since Tailwind CSS v4.0.0\n * @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158\n */\n 'ring-offset-color': [{ 'ring-offset': scaleColor() }],\n /**\n * Inset Ring Width\n * @see https://tailwindcss.com/docs/box-shadow#adding-an-inset-ring\n */\n 'inset-ring-w': [{ 'inset-ring': scaleBorderWidth() }],\n /**\n * Inset Ring Color\n * @see https://tailwindcss.com/docs/box-shadow#setting-the-inset-ring-color\n */\n 'inset-ring-color': [{ 'inset-ring': scaleColor() }],\n /**\n * Text Shadow\n * @see https://tailwindcss.com/docs/text-shadow\n */\n 'text-shadow': [\n {\n 'text-shadow': [\n 'none',\n themeTextShadow,\n isArbitraryVariableShadow,\n isArbitraryShadow,\n ],\n },\n ],\n /**\n * Text Shadow Color\n * @see https://tailwindcss.com/docs/text-shadow#setting-the-shadow-color\n */\n 'text-shadow-color': [{ 'text-shadow': scaleColor() }],\n /**\n * Opacity\n * @see https://tailwindcss.com/docs/opacity\n */\n opacity: [{ opacity: [isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Mix Blend Mode\n * @see https://tailwindcss.com/docs/mix-blend-mode\n */\n 'mix-blend': [{ 'mix-blend': [...scaleBlendMode(), 'plus-darker', 'plus-lighter'] }],\n /**\n * Background Blend Mode\n * @see https://tailwindcss.com/docs/background-blend-mode\n */\n 'bg-blend': [{ 'bg-blend': scaleBlendMode() }],\n /**\n * Mask Clip\n * @see https://tailwindcss.com/docs/mask-clip\n */\n 'mask-clip': [\n { 'mask-clip': ['border', 'padding', 'content', 'fill', 'stroke', 'view'] },\n 'mask-no-clip',\n ],\n /**\n * Mask Composite\n * @see https://tailwindcss.com/docs/mask-composite\n */\n 'mask-composite': [{ mask: ['add', 'subtract', 'intersect', 'exclude'] }],\n /**\n * Mask Image\n * @see https://tailwindcss.com/docs/mask-image\n */\n 'mask-image-linear-pos': [{ 'mask-linear': [isNumber] }],\n 'mask-image-linear-from-pos': [{ 'mask-linear-from': scaleMaskImagePosition() }],\n 'mask-image-linear-to-pos': [{ 'mask-linear-to': scaleMaskImagePosition() }],\n 'mask-image-linear-from-color': [{ 'mask-linear-from': scaleColor() }],\n 'mask-image-linear-to-color': [{ 'mask-linear-to': scaleColor() }],\n 'mask-image-t-from-pos': [{ 'mask-t-from': scaleMaskImagePosition() }],\n 'mask-image-t-to-pos': [{ 'mask-t-to': scaleMaskImagePosition() }],\n 'mask-image-t-from-color': [{ 'mask-t-from': scaleColor() }],\n 'mask-image-t-to-color': [{ 'mask-t-to': scaleColor() }],\n 'mask-image-r-from-pos': [{ 'mask-r-from': scaleMaskImagePosition() }],\n 'mask-image-r-to-pos': [{ 'mask-r-to': scaleMaskImagePosition() }],\n 'mask-image-r-from-color': [{ 'mask-r-from': scaleColor() }],\n 'mask-image-r-to-color': [{ 'mask-r-to': scaleColor() }],\n 'mask-image-b-from-pos': [{ 'mask-b-from': scaleMaskImagePosition() }],\n 'mask-image-b-to-pos': [{ 'mask-b-to': scaleMaskImagePosition() }],\n 'mask-image-b-from-color': [{ 'mask-b-from': scaleColor() }],\n 'mask-image-b-to-color': [{ 'mask-b-to': scaleColor() }],\n 'mask-image-l-from-pos': [{ 'mask-l-from': scaleMaskImagePosition() }],\n 'mask-image-l-to-pos': [{ 'mask-l-to': scaleMaskImagePosition() }],\n 'mask-image-l-from-color': [{ 'mask-l-from': scaleColor() }],\n 'mask-image-l-to-color': [{ 'mask-l-to': scaleColor() }],\n 'mask-image-x-from-pos': [{ 'mask-x-from': scaleMaskImagePosition() }],\n 'mask-image-x-to-pos': [{ 'mask-x-to': scaleMaskImagePosition() }],\n 'mask-image-x-from-color': [{ 'mask-x-from': scaleColor() }],\n 'mask-image-x-to-color': [{ 'mask-x-to': scaleColor() }],\n 'mask-image-y-from-pos': [{ 'mask-y-from': scaleMaskImagePosition() }],\n 'mask-image-y-to-pos': [{ 'mask-y-to': scaleMaskImagePosition() }],\n 'mask-image-y-from-color': [{ 'mask-y-from': scaleColor() }],\n 'mask-image-y-to-color': [{ 'mask-y-to': scaleColor() }],\n 'mask-image-radial': [{ 'mask-radial': [isArbitraryVariable, isArbitraryValue] }],\n 'mask-image-radial-from-pos': [{ 'mask-radial-from': scaleMaskImagePosition() }],\n 'mask-image-radial-to-pos': [{ 'mask-radial-to': scaleMaskImagePosition() }],\n 'mask-image-radial-from-color': [{ 'mask-radial-from': scaleColor() }],\n 'mask-image-radial-to-color': [{ 'mask-radial-to': scaleColor() }],\n 'mask-image-radial-shape': [{ 'mask-radial': ['circle', 'ellipse'] }],\n 'mask-image-radial-size': [\n { 'mask-radial': [{ closest: ['side', 'corner'], farthest: ['side', 'corner'] }] },\n ],\n 'mask-image-radial-pos': [{ 'mask-radial-at': scalePosition() }],\n 'mask-image-conic-pos': [{ 'mask-conic': [isNumber] }],\n 'mask-image-conic-from-pos': [{ 'mask-conic-from': scaleMaskImagePosition() }],\n 'mask-image-conic-to-pos': [{ 'mask-conic-to': scaleMaskImagePosition() }],\n 'mask-image-conic-from-color': [{ 'mask-conic-from': scaleColor() }],\n 'mask-image-conic-to-color': [{ 'mask-conic-to': scaleColor() }],\n /**\n * Mask Mode\n * @see https://tailwindcss.com/docs/mask-mode\n */\n 'mask-mode': [{ mask: ['alpha', 'luminance', 'match'] }],\n /**\n * Mask Origin\n * @see https://tailwindcss.com/docs/mask-origin\n */\n 'mask-origin': [\n { 'mask-origin': ['border', 'padding', 'content', 'fill', 'stroke', 'view'] },\n ],\n /**\n * Mask Position\n * @see https://tailwindcss.com/docs/mask-position\n */\n 'mask-position': [{ mask: scaleBgPosition() }],\n /**\n * Mask Repeat\n * @see https://tailwindcss.com/docs/mask-repeat\n */\n 'mask-repeat': [{ mask: scaleBgRepeat() }],\n /**\n * Mask Size\n * @see https://tailwindcss.com/docs/mask-size\n */\n 'mask-size': [{ mask: scaleBgSize() }],\n /**\n * Mask Type\n * @see https://tailwindcss.com/docs/mask-type\n */\n 'mask-type': [{ 'mask-type': ['alpha', 'luminance'] }],\n /**\n * Mask Image\n * @see https://tailwindcss.com/docs/mask-image\n */\n 'mask-image': [{ mask: ['none', isArbitraryVariable, isArbitraryValue] }],\n\n // ---------------\n // --- Filters ---\n // ---------------\n\n /**\n * Filter\n * @see https://tailwindcss.com/docs/filter\n */\n filter: [\n {\n filter: [\n // Deprecated since Tailwind CSS v3.0.0\n '',\n 'none',\n isArbitraryVariable,\n isArbitraryValue,\n ],\n },\n ],\n /**\n * Blur\n * @see https://tailwindcss.com/docs/blur\n */\n blur: [{ blur: scaleBlur() }],\n /**\n * Brightness\n * @see https://tailwindcss.com/docs/brightness\n */\n brightness: [{ brightness: [isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Contrast\n * @see https://tailwindcss.com/docs/contrast\n */\n contrast: [{ contrast: [isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Drop Shadow\n * @see https://tailwindcss.com/docs/drop-shadow\n */\n 'drop-shadow': [\n {\n 'drop-shadow': [\n // Deprecated since Tailwind CSS v4.0.0\n '',\n 'none',\n themeDropShadow,\n isArbitraryVariableShadow,\n isArbitraryShadow,\n ],\n },\n ],\n /**\n * Drop Shadow Color\n * @see https://tailwindcss.com/docs/filter-drop-shadow#setting-the-shadow-color\n */\n 'drop-shadow-color': [{ 'drop-shadow': scaleColor() }],\n /**\n * Grayscale\n * @see https://tailwindcss.com/docs/grayscale\n */\n grayscale: [{ grayscale: ['', isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Hue Rotate\n * @see https://tailwindcss.com/docs/hue-rotate\n */\n 'hue-rotate': [{ 'hue-rotate': [isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Invert\n * @see https://tailwindcss.com/docs/invert\n */\n invert: [{ invert: ['', isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Saturate\n * @see https://tailwindcss.com/docs/saturate\n */\n saturate: [{ saturate: [isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Sepia\n * @see https://tailwindcss.com/docs/sepia\n */\n sepia: [{ sepia: ['', isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Backdrop Filter\n * @see https://tailwindcss.com/docs/backdrop-filter\n */\n 'backdrop-filter': [\n {\n 'backdrop-filter': [\n // Deprecated since Tailwind CSS v3.0.0\n '',\n 'none',\n isArbitraryVariable,\n isArbitraryValue,\n ],\n },\n ],\n /**\n * Backdrop Blur\n * @see https://tailwindcss.com/docs/backdrop-blur\n */\n 'backdrop-blur': [{ 'backdrop-blur': scaleBlur() }],\n /**\n * Backdrop Brightness\n * @see https://tailwindcss.com/docs/backdrop-brightness\n */\n 'backdrop-brightness': [\n { 'backdrop-brightness': [isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Backdrop Contrast\n * @see https://tailwindcss.com/docs/backdrop-contrast\n */\n 'backdrop-contrast': [\n { 'backdrop-contrast': [isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Backdrop Grayscale\n * @see https://tailwindcss.com/docs/backdrop-grayscale\n */\n 'backdrop-grayscale': [\n { 'backdrop-grayscale': ['', isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Backdrop Hue Rotate\n * @see https://tailwindcss.com/docs/backdrop-hue-rotate\n */\n 'backdrop-hue-rotate': [\n { 'backdrop-hue-rotate': [isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Backdrop Invert\n * @see https://tailwindcss.com/docs/backdrop-invert\n */\n 'backdrop-invert': [\n { 'backdrop-invert': ['', isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Backdrop Opacity\n * @see https://tailwindcss.com/docs/backdrop-opacity\n */\n 'backdrop-opacity': [\n { 'backdrop-opacity': [isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Backdrop Saturate\n * @see https://tailwindcss.com/docs/backdrop-saturate\n */\n 'backdrop-saturate': [\n { 'backdrop-saturate': [isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Backdrop Sepia\n * @see https://tailwindcss.com/docs/backdrop-sepia\n */\n 'backdrop-sepia': [\n { 'backdrop-sepia': ['', isNumber, isArbitraryVariable, isArbitraryValue] },\n ],\n\n // --------------\n // --- Tables ---\n // --------------\n\n /**\n * Border Collapse\n * @see https://tailwindcss.com/docs/border-collapse\n */\n 'border-collapse': [{ border: ['collapse', 'separate'] }],\n /**\n * Border Spacing\n * @see https://tailwindcss.com/docs/border-spacing\n */\n 'border-spacing': [{ 'border-spacing': scaleUnambiguousSpacing() }],\n /**\n * Border Spacing X\n * @see https://tailwindcss.com/docs/border-spacing\n */\n 'border-spacing-x': [{ 'border-spacing-x': scaleUnambiguousSpacing() }],\n /**\n * Border Spacing Y\n * @see https://tailwindcss.com/docs/border-spacing\n */\n 'border-spacing-y': [{ 'border-spacing-y': scaleUnambiguousSpacing() }],\n /**\n * Table Layout\n * @see https://tailwindcss.com/docs/table-layout\n */\n 'table-layout': [{ table: ['auto', 'fixed'] }],\n /**\n * Caption Side\n * @see https://tailwindcss.com/docs/caption-side\n */\n caption: [{ caption: ['top', 'bottom'] }],\n\n // ---------------------------------\n // --- Transitions and Animation ---\n // ---------------------------------\n\n /**\n * Transition Property\n * @see https://tailwindcss.com/docs/transition-property\n */\n transition: [\n {\n transition: [\n '',\n 'all',\n 'colors',\n 'opacity',\n 'shadow',\n 'transform',\n 'none',\n isArbitraryVariable,\n isArbitraryValue,\n ],\n },\n ],\n /**\n * Transition Behavior\n * @see https://tailwindcss.com/docs/transition-behavior\n */\n 'transition-behavior': [{ transition: ['normal', 'discrete'] }],\n /**\n * Transition Duration\n * @see https://tailwindcss.com/docs/transition-duration\n */\n duration: [{ duration: [isNumber, 'initial', isArbitraryVariable, isArbitraryValue] }],\n /**\n * Transition Timing Function\n * @see https://tailwindcss.com/docs/transition-timing-function\n */\n ease: [\n { ease: ['linear', 'initial', themeEase, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Transition Delay\n * @see https://tailwindcss.com/docs/transition-delay\n */\n delay: [{ delay: [isNumber, isArbitraryVariable, isArbitraryValue] }],\n /**\n * Animation\n * @see https://tailwindcss.com/docs/animation\n */\n animate: [{ animate: ['none', themeAnimate, isArbitraryVariable, isArbitraryValue] }],\n\n // ------------------\n // --- Transforms ---\n // ------------------\n\n /**\n * Backface Visibility\n * @see https://tailwindcss.com/docs/backface-visibility\n */\n backface: [{ backface: ['hidden', 'visible'] }],\n /**\n * Perspective\n * @see https://tailwindcss.com/docs/perspective\n */\n perspective: [\n { perspective: [themePerspective, isArbitraryVariable, isArbitraryValue] },\n ],\n /**\n * Perspective Origin\n * @see https://tailwindcss.com/docs/perspective-origin\n */\n 'perspective-origin': [{ 'perspective-origin': scalePositionWithArbitrary() }],\n /**\n * Rotate\n * @see https://tailwindcss.com/docs/rotate\n */\n rotate: [{ rotate: scaleRotate() }],\n /**\n * Rotate X\n * @see https://tailwindcss.com/docs/rotate\n */\n 'rotate-x': [{ 'rotate-x': scaleRotate() }],\n /**\n * Rotate Y\n * @see https://tailwindcss.com/docs/rotate\n */\n 'rotate-y': [{ 'rotate-y': scaleRotate() }],\n /**\n * Rotate Z\n * @see https://tailwindcss.com/docs/rotate\n */\n 'rotate-z': [{ 'rotate-z': scaleRotate() }],\n /**\n * Scale\n * @see https://tailwindcss.com/docs/scale\n */\n scale: [{ scale: scaleScale() }],\n /**\n * Scale X\n * @see https://tailwindcss.com/docs/scale\n */\n 'scale-x': [{ 'scale-x': scaleScale() }],\n /**\n * Scale Y\n * @see https://tailwindcss.com/docs/scale\n */\n 'scale-y': [{ 'scale-y': scaleScale() }],\n /**\n * Scale Z\n * @see https://tailwindcss.com/docs/scale\n */\n 'scale-z': [{ 'scale-z': scaleScale() }],\n /**\n * Scale 3D\n * @see https://tailwindcss.com/docs/scale\n */\n 'scale-3d': ['scale-3d'],\n /**\n * Skew\n * @see https://tailwindcss.com/docs/skew\n */\n skew: [{ skew: scaleSkew() }],\n /**\n * Skew X\n * @see https://tailwindcss.com/docs/skew\n */\n 'skew-x': [{ 'skew-x': scaleSkew() }],\n /**\n * Skew Y\n * @see https://tailwindcss.com/docs/skew\n */\n 'skew-y': [{ 'skew-y': scaleSkew() }],\n /**\n * Transform\n * @see https://tailwindcss.com/docs/transform\n */\n transform: [\n { transform: [isArbitraryVariable, isArbitraryValue, '', 'none', 'gpu', 'cpu'] },\n ],\n /**\n * Transform Origin\n * @see https://tailwindcss.com/docs/transform-origin\n */\n 'transform-origin': [{ origin: scalePositionWithArbitrary() }],\n /**\n * Transform Style\n * @see https://tailwindcss.com/docs/transform-style\n */\n 'transform-style': [{ transform: ['3d', 'flat'] }],\n /**\n * Translate\n * @see https://tailwindcss.com/docs/translate\n */\n translate: [{ translate: scaleTranslate() }],\n /**\n * Translate X\n * @see https://tailwindcss.com/docs/translate\n */\n 'translate-x': [{ 'translate-x': scaleTranslate() }],\n /**\n * Translate Y\n * @see https://tailwindcss.com/docs/translate\n */\n 'translate-y': [{ 'translate-y': scaleTranslate() }],\n /**\n * Translate Z\n * @see https://tailwindcss.com/docs/translate\n */\n 'translate-z': [{ 'translate-z': scaleTranslate() }],\n /**\n * Translate None\n * @see https://tailwindcss.com/docs/translate\n */\n 'translate-none': ['translate-none'],\n /**\n * Zoom\n * @see https://tailwindcss.com/docs/zoom\n */\n zoom: [{ zoom: [isInteger, isArbitraryVariable, isArbitraryValue] }],\n\n // ---------------------\n // --- Interactivity ---\n // ---------------------\n\n /**\n * Accent Color\n * @see https://tailwindcss.com/docs/accent-color\n */\n accent: [{ accent: scaleColor() }],\n /**\n * Appearance\n * @see https://tailwindcss.com/docs/appearance\n */\n appearance: [{ appearance: ['none', 'auto'] }],\n /**\n * Caret Color\n * @see https://tailwindcss.com/docs/just-in-time-mode#caret-color-utilities\n */\n 'caret-color': [{ caret: scaleColor() }],\n /**\n * Color Scheme\n * @see https://tailwindcss.com/docs/color-scheme\n */\n 'color-scheme': [\n { scheme: ['normal', 'dark', 'light', 'light-dark', 'only-dark', 'only-light'] },\n ],\n /**\n * Cursor\n * @see https://tailwindcss.com/docs/cursor\n */\n cursor: [\n {\n cursor: [\n 'auto',\n 'default',\n 'pointer',\n 'wait',\n 'text',\n 'move',\n 'help',\n 'not-allowed',\n 'none',\n 'context-menu',\n 'progress',\n 'cell',\n 'crosshair',\n 'vertical-text',\n 'alias',\n 'copy',\n 'no-drop',\n 'grab',\n 'grabbing',\n 'all-scroll',\n 'col-resize',\n 'row-resize',\n 'n-resize',\n 'e-resize',\n 's-resize',\n 'w-resize',\n 'ne-resize',\n 'nw-resize',\n 'se-resize',\n 'sw-resize',\n 'ew-resize',\n 'ns-resize',\n 'nesw-resize',\n 'nwse-resize',\n 'zoom-in',\n 'zoom-out',\n isArbitraryVariable,\n isArbitraryValue,\n ],\n },\n ],\n /**\n * Field Sizing\n * @see https://tailwindcss.com/docs/field-sizing\n */\n 'field-sizing': [{ 'field-sizing': ['fixed', 'content'] }],\n /**\n * Pointer Events\n * @see https://tailwindcss.com/docs/pointer-events\n */\n 'pointer-events': [{ 'pointer-events': ['auto', 'none'] }],\n /**\n * Resize\n * @see https://tailwindcss.com/docs/resize\n */\n resize: [{ resize: ['none', '', 'y', 'x'] }],\n /**\n * Scroll Behavior\n * @see https://tailwindcss.com/docs/scroll-behavior\n */\n 'scroll-behavior': [{ scroll: ['auto', 'smooth'] }],\n /**\n * Scrollbar Thumb Color\n * @see https://tailwindcss.com/docs/scrollbar-color\n */\n 'scrollbar-thumb-color': [{ 'scrollbar-thumb': scaleColor() }],\n /**\n * Scrollbar Track Color\n * @see https://tailwindcss.com/docs/scrollbar-color\n */\n 'scrollbar-track-color': [{ 'scrollbar-track': scaleColor() }],\n /**\n * Scrollbar Gutter\n * @see https://tailwindcss.com/docs/scrollbar-gutter\n */\n 'scrollbar-gutter': [{ 'scrollbar-gutter': ['auto', 'stable', 'both'] }],\n /**\n * Scrollbar Width\n * @see https://tailwindcss.com/docs/scrollbar-width\n */\n 'scrollbar-w': [{ scrollbar: ['auto', 'thin', 'none'] }],\n /**\n * Scroll Margin\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-m': [{ 'scroll-m': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Inline\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mx': [{ 'scroll-mx': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Block\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-my': [{ 'scroll-my': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Inline Start\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-ms': [{ 'scroll-ms': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Inline End\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-me': [{ 'scroll-me': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Block Start\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mbs': [{ 'scroll-mbs': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Block End\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mbe': [{ 'scroll-mbe': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Top\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mt': [{ 'scroll-mt': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Right\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mr': [{ 'scroll-mr': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Bottom\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-mb': [{ 'scroll-mb': scaleUnambiguousSpacing() }],\n /**\n * Scroll Margin Left\n * @see https://tailwindcss.com/docs/scroll-margin\n */\n 'scroll-ml': [{ 'scroll-ml': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-p': [{ 'scroll-p': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Inline\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-px': [{ 'scroll-px': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Block\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-py': [{ 'scroll-py': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Inline Start\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-ps': [{ 'scroll-ps': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Inline End\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pe': [{ 'scroll-pe': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Block Start\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pbs': [{ 'scroll-pbs': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Block End\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pbe': [{ 'scroll-pbe': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Top\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pt': [{ 'scroll-pt': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Right\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pr': [{ 'scroll-pr': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Bottom\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pb': [{ 'scroll-pb': scaleUnambiguousSpacing() }],\n /**\n * Scroll Padding Left\n * @see https://tailwindcss.com/docs/scroll-padding\n */\n 'scroll-pl': [{ 'scroll-pl': scaleUnambiguousSpacing() }],\n /**\n * Scroll Snap Align\n * @see https://tailwindcss.com/docs/scroll-snap-align\n */\n 'snap-align': [{ snap: ['start', 'end', 'center', 'align-none'] }],\n /**\n * Scroll Snap Stop\n * @see https://tailwindcss.com/docs/scroll-snap-stop\n */\n 'snap-stop': [{ snap: ['normal', 'always'] }],\n /**\n * Scroll Snap Type\n * @see https://tailwindcss.com/docs/scroll-snap-type\n */\n 'snap-type': [{ snap: ['none', 'x', 'y', 'both'] }],\n /**\n * Scroll Snap Type Strictness\n * @see https://tailwindcss.com/docs/scroll-snap-type\n */\n 'snap-strictness': [{ snap: ['mandatory', 'proximity'] }],\n /**\n * Touch Action\n * @see https://tailwindcss.com/docs/touch-action\n */\n touch: [{ touch: ['auto', 'none', 'manipulation'] }],\n /**\n * Touch Action X\n * @see https://tailwindcss.com/docs/touch-action\n */\n 'touch-x': [{ 'touch-pan': ['x', 'left', 'right'] }],\n /**\n * Touch Action Y\n * @see https://tailwindcss.com/docs/touch-action\n */\n 'touch-y': [{ 'touch-pan': ['y', 'up', 'down'] }],\n /**\n * Touch Action Pinch Zoom\n * @see https://tailwindcss.com/docs/touch-action\n */\n 'touch-pz': ['touch-pinch-zoom'],\n /**\n * User Select\n * @see https://tailwindcss.com/docs/user-select\n */\n select: [{ select: ['none', 'text', 'all', 'auto'] }],\n /**\n * Will Change\n * @see https://tailwindcss.com/docs/will-change\n */\n 'will-change': [\n {\n 'will-change': [\n 'auto',\n 'scroll',\n 'contents',\n 'transform',\n isArbitraryVariable,\n isArbitraryValue,\n ],\n },\n ],\n\n // -----------\n // --- SVG ---\n // -----------\n\n /**\n * Fill\n * @see https://tailwindcss.com/docs/fill\n */\n fill: [{ fill: ['none', ...scaleColor()] }],\n /**\n * Stroke Width\n * @see https://tailwindcss.com/docs/stroke-width\n */\n 'stroke-w': [\n {\n stroke: [\n isNumber,\n isArbitraryVariableLength,\n isArbitraryLength,\n isArbitraryNumber,\n ],\n },\n ],\n /**\n * Stroke\n * @see https://tailwindcss.com/docs/stroke\n */\n stroke: [{ stroke: ['none', ...scaleColor()] }],\n\n // ---------------------\n // --- Accessibility ---\n // ---------------------\n\n /**\n * Forced Color Adjust\n * @see https://tailwindcss.com/docs/forced-color-adjust\n */\n 'forced-color-adjust': [{ 'forced-color-adjust': ['auto', 'none'] }],\n },\n conflictingClassGroups: {\n 'container-named': ['container-type'],\n overflow: ['overflow-x', 'overflow-y'],\n overscroll: ['overscroll-x', 'overscroll-y'],\n inset: [\n 'inset-x',\n 'inset-y',\n 'inset-bs',\n 'inset-be',\n 'start',\n 'end',\n 'top',\n 'right',\n 'bottom',\n 'left',\n ],\n 'inset-x': ['right', 'left'],\n 'inset-y': ['top', 'bottom'],\n flex: ['basis', 'grow', 'shrink'],\n gap: ['gap-x', 'gap-y'],\n p: ['px', 'py', 'ps', 'pe', 'pbs', 'pbe', 'pt', 'pr', 'pb', 'pl'],\n px: ['pr', 'pl'],\n py: ['pt', 'pb'],\n m: ['mx', 'my', 'ms', 'me', 'mbs', 'mbe', 'mt', 'mr', 'mb', 'ml'],\n mx: ['mr', 'ml'],\n my: ['mt', 'mb'],\n size: ['w', 'h'],\n 'font-size': ['leading'],\n 'fvn-normal': [\n 'fvn-ordinal',\n 'fvn-slashed-zero',\n 'fvn-figure',\n 'fvn-spacing',\n 'fvn-fraction',\n ],\n 'fvn-ordinal': ['fvn-normal'],\n 'fvn-slashed-zero': ['fvn-normal'],\n 'fvn-figure': ['fvn-normal'],\n 'fvn-spacing': ['fvn-normal'],\n 'fvn-fraction': ['fvn-normal'],\n 'line-clamp': ['display', 'overflow'],\n rounded: [\n 'rounded-s',\n 'rounded-e',\n 'rounded-t',\n 'rounded-r',\n 'rounded-b',\n 'rounded-l',\n 'rounded-ss',\n 'rounded-se',\n 'rounded-ee',\n 'rounded-es',\n 'rounded-tl',\n 'rounded-tr',\n 'rounded-br',\n 'rounded-bl',\n ],\n 'rounded-s': ['rounded-ss', 'rounded-es'],\n 'rounded-e': ['rounded-se', 'rounded-ee'],\n 'rounded-t': ['rounded-tl', 'rounded-tr'],\n 'rounded-r': ['rounded-tr', 'rounded-br'],\n 'rounded-b': ['rounded-br', 'rounded-bl'],\n 'rounded-l': ['rounded-tl', 'rounded-bl'],\n 'border-spacing': ['border-spacing-x', 'border-spacing-y'],\n 'border-w': [\n 'border-w-x',\n 'border-w-y',\n 'border-w-s',\n 'border-w-e',\n 'border-w-bs',\n 'border-w-be',\n 'border-w-t',\n 'border-w-r',\n 'border-w-b',\n 'border-w-l',\n ],\n 'border-w-x': ['border-w-r', 'border-w-l'],\n 'border-w-y': ['border-w-t', 'border-w-b'],\n 'border-color': [\n 'border-color-x',\n 'border-color-y',\n 'border-color-s',\n 'border-color-e',\n 'border-color-bs',\n 'border-color-be',\n 'border-color-t',\n 'border-color-r',\n 'border-color-b',\n 'border-color-l',\n ],\n 'border-color-x': ['border-color-r', 'border-color-l'],\n 'border-color-y': ['border-color-t', 'border-color-b'],\n translate: ['translate-x', 'translate-y', 'translate-none'],\n 'translate-none': ['translate', 'translate-x', 'translate-y', 'translate-z'],\n 'scroll-m': [\n 'scroll-mx',\n 'scroll-my',\n 'scroll-ms',\n 'scroll-me',\n 'scroll-mbs',\n 'scroll-mbe',\n 'scroll-mt',\n 'scroll-mr',\n 'scroll-mb',\n 'scroll-ml',\n ],\n 'scroll-mx': ['scroll-mr', 'scroll-ml'],\n 'scroll-my': ['scroll-mt', 'scroll-mb'],\n 'scroll-p': [\n 'scroll-px',\n 'scroll-py',\n 'scroll-ps',\n 'scroll-pe',\n 'scroll-pbs',\n 'scroll-pbe',\n 'scroll-pt',\n 'scroll-pr',\n 'scroll-pb',\n 'scroll-pl',\n ],\n 'scroll-px': ['scroll-pr', 'scroll-pl'],\n 'scroll-py': ['scroll-pt', 'scroll-pb'],\n touch: ['touch-x', 'touch-y', 'touch-pz'],\n 'touch-x': ['touch'],\n 'touch-y': ['touch'],\n 'touch-pz': ['touch'],\n },\n conflictingClassGroupModifiers: {\n 'font-size': ['leading'],\n },\n postfixLookupClassGroups: ['container-type'],\n orderSensitiveModifiers: [\n '*',\n '**',\n 'after',\n 'backdrop',\n 'before',\n 'details-content',\n 'file',\n 'first-letter',\n 'first-line',\n 'marker',\n 'placeholder',\n 'selection',\n ],\n } as const satisfies Config<DefaultClassGroupIds, DefaultThemeGroupIds>\n}\n","import { AnyConfig, ConfigExtension, NoInfer } from './types'\n\n/**\n * @param baseConfig Config where other config will be merged into. This object will be mutated.\n * @param configExtension Partial config to merge into the `baseConfig`.\n */\nexport const mergeConfigs = <ClassGroupIds extends string, ThemeGroupIds extends string = never>(\n baseConfig: AnyConfig,\n {\n cacheSize,\n prefix,\n experimentalParseClassName,\n extend = {},\n override = {},\n }: ConfigExtension<ClassGroupIds, ThemeGroupIds>,\n) => {\n overrideProperty(baseConfig, 'cacheSize', cacheSize)\n overrideProperty(baseConfig, 'prefix', prefix)\n overrideProperty(baseConfig, 'experimentalParseClassName', experimentalParseClassName)\n\n overrideConfigProperties(baseConfig.theme, override.theme)\n overrideConfigProperties(baseConfig.classGroups, override.classGroups)\n overrideConfigProperties(baseConfig.conflictingClassGroups, override.conflictingClassGroups)\n overrideConfigProperties(\n baseConfig.conflictingClassGroupModifiers,\n override.conflictingClassGroupModifiers,\n )\n overrideProperty(baseConfig, 'postfixLookupClassGroups', override.postfixLookupClassGroups)\n overrideProperty(baseConfig, 'orderSensitiveModifiers', override.orderSensitiveModifiers)\n\n mergeConfigProperties(baseConfig.theme, extend.theme)\n mergeConfigProperties(baseConfig.classGroups, extend.classGroups)\n mergeConfigProperties(baseConfig.conflictingClassGroups, extend.conflictingClassGroups)\n mergeConfigProperties(\n baseConfig.conflictingClassGroupModifiers,\n extend.conflictingClassGroupModifiers,\n )\n mergeArrayProperties(baseConfig, extend, 'postfixLookupClassGroups')\n mergeArrayProperties(baseConfig, extend, 'orderSensitiveModifiers')\n\n return baseConfig\n}\n\nconst overrideProperty = <T extends object, K extends keyof T>(\n baseObject: T,\n overrideKey: K,\n overrideValue: T[K] | undefined,\n) => {\n if (overrideValue !== undefined) {\n baseObject[overrideKey] = overrideValue\n }\n}\n\nconst overrideConfigProperties = (\n baseObject: Partial<Record<string, readonly unknown[]>>,\n overrideObject: Partial<Record<string, readonly unknown[]>> | undefined,\n) => {\n if (overrideObject) {\n for (const key in overrideObject) {\n overrideProperty(baseObject, key, overrideObject[key])\n }\n }\n}\n\nconst mergeConfigProperties = (\n baseObject: Partial<Record<string, readonly unknown[]>>,\n mergeObject: Partial<Record<string, readonly unknown[]>> | undefined,\n) => {\n if (mergeObject) {\n for (const key in mergeObject) {\n mergeArrayProperties(baseObject, mergeObject, key)\n }\n }\n}\n\nconst mergeArrayProperties = <Key extends string>(\n baseObject: Partial<Record<NoInfer<Key>, readonly unknown[]>>,\n mergeObject: Partial<Record<NoInfer<Key>, readonly unknown[]>>,\n key: Key,\n) => {\n const mergeValue = mergeObject[key]\n\n if (mergeValue !== undefined) {\n baseObject[key] = baseObject[key] ? baseObject[key].concat(mergeValue) : mergeValue\n }\n}\n","import { createTailwindMerge } from './create-tailwind-merge'\nimport { getDefaultConfig } from './default-config'\nimport { mergeConfigs } from './merge-configs'\nimport { AnyConfig, ConfigExtension, DefaultClassGroupIds, DefaultThemeGroupIds } from './types'\n\ntype CreateConfigSubsequent = (config: AnyConfig) => AnyConfig\n\nexport const extendTailwindMerge = <\n AdditionalClassGroupIds extends string = never,\n AdditionalThemeGroupIds extends string = never,\n>(\n configExtension:\n | ConfigExtension<\n DefaultClassGroupIds | AdditionalClassGroupIds,\n DefaultThemeGroupIds | AdditionalThemeGroupIds\n >\n | CreateConfigSubsequent,\n ...createConfig: CreateConfigSubsequent[]\n) =>\n typeof configExtension === 'function'\n ? createTailwindMerge(getDefaultConfig, configExtension, ...createConfig)\n : createTailwindMerge(\n () => mergeConfigs(getDefaultConfig(), configExtension),\n ...createConfig,\n )\n","import { createTailwindMerge } from './create-tailwind-merge'\nimport { getDefaultConfig } from './default-config'\n\nexport const twMerge = createTailwindMerge(getDefaultConfig)\n","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport { isNode } from '@floating-ui/utils/dom';\nimport { addEventListener } from '@base-ui/utils/addEventListener';\nimport { mergeCleanups } from '@base-ui/utils/mergeCleanups';\nimport { useId } from '@base-ui/utils/useId';\nimport { useIsoLayoutEffect } from '@base-ui/utils/useIsoLayoutEffect';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nimport { EMPTY_OBJECT } from '@base-ui/utils/empty';\nimport { FocusGuard } from \"../../utils/FocusGuard.mjs\";\nimport { enableFocusInside, disableFocusInside, getPreviousTabbable, getNextTabbable, isOutsideEvent } from \"../utils/tabbable.mjs\";\nimport { createChangeEventDetails } from \"../../internals/createBaseUIEventDetails.mjs\";\nimport { REASONS } from \"../../internals/reasons.mjs\";\nimport { createAttribute } from \"../utils/createAttribute.mjs\";\nimport { useRenderElement } from \"../../internals/useRenderElement.mjs\";\nimport { ownerVisuallyHidden } from \"../../internals/constants.mjs\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst PortalContext = /*#__PURE__*/React.createContext(null);\nif (process.env.NODE_ENV !== \"production\") PortalContext.displayName = \"PortalContext\";\nexport const usePortalContext = () => React.useContext(PortalContext);\nconst attr = createAttribute('portal');\nexport function useFloatingPortalNode(props = {}) {\n const {\n ref,\n container: containerProp,\n componentProps = EMPTY_OBJECT,\n elementProps\n } = props;\n const uniqueId = useId();\n const portalContext = usePortalContext();\n const parentPortalNode = portalContext?.portalNode;\n const [containerElement, setContainerElement] = React.useState(null);\n const [portalNode, setPortalNode] = React.useState(null);\n const setPortalNodeRef = useStableCallback(node => {\n if (node !== null) {\n // the useIsoLayoutEffect below watching containerProp / parentPortalNode\n // sets setPortalNode(null) when the container becomes null or changes.\n // So even though the ref callback now ignores null, the portal node still gets cleared.\n setPortalNode(node);\n }\n });\n const containerRef = React.useRef(null);\n useIsoLayoutEffect(() => {\n // Wait for the container to be resolved if explicitly `null`.\n if (containerProp === null) {\n if (containerRef.current) {\n containerRef.current = null;\n setPortalNode(null);\n setContainerElement(null);\n }\n return;\n }\n\n // React 17 does not use React.useId().\n if (uniqueId == null) {\n return;\n }\n const resolvedContainer = (containerProp && (isNode(containerProp) ? containerProp : containerProp.current)) ?? parentPortalNode ?? document.body;\n if (resolvedContainer == null) {\n if (containerRef.current) {\n containerRef.current = null;\n setPortalNode(null);\n setContainerElement(null);\n }\n return;\n }\n if (containerRef.current !== resolvedContainer) {\n containerRef.current = resolvedContainer;\n setPortalNode(null);\n setContainerElement(resolvedContainer);\n }\n }, [containerProp, parentPortalNode, uniqueId]);\n const portalElement = useRenderElement('div', componentProps, {\n ref: [ref, setPortalNodeRef],\n props: [{\n id: uniqueId,\n [attr]: ''\n }, elementProps]\n });\n\n // This `createPortal` call injects `portalElement` into the `container`.\n // Another call inside `FloatingPortal`/`FloatingPortalLite` then injects the children into `portalElement`.\n const portalSubtree = containerElement && portalElement ? /*#__PURE__*/ReactDOM.createPortal(portalElement, containerElement) : null;\n return {\n portalNode,\n portalSubtree\n };\n}\n\n/**\n * Portals the floating element into a given container element — by default,\n * outside of the app root and into the body.\n * This is necessary to ensure the floating element can appear outside any\n * potential parent containers that cause clipping (such as `overflow: hidden`),\n * while retaining its location in the React tree.\n * @see https://floating-ui.com/docs/FloatingPortal\n * @internal\n */\nexport const FloatingPortal = /*#__PURE__*/React.forwardRef(function FloatingPortal(componentProps, forwardedRef) {\n const {\n render,\n className,\n style,\n children,\n container,\n renderGuards,\n ...elementProps\n } = componentProps;\n const {\n portalNode,\n portalSubtree\n } = useFloatingPortalNode({\n container,\n ref: forwardedRef,\n componentProps,\n elementProps\n });\n const beforeOutsideRef = React.useRef(null);\n const afterOutsideRef = React.useRef(null);\n const beforeInsideRef = React.useRef(null);\n const afterInsideRef = React.useRef(null);\n const [focusManagerState, setFocusManagerState] = React.useState(null);\n const focusInsideDisabledRef = React.useRef(false);\n const modal = focusManagerState?.modal;\n const open = focusManagerState?.open;\n const shouldRenderGuards = typeof renderGuards === 'boolean' ? renderGuards : !!focusManagerState && !focusManagerState.modal && focusManagerState.open && !!portalNode;\n\n // https://codesandbox.io/s/tabbable-portal-f4tng?file=/src/TabbablePortal.tsx\n React.useEffect(() => {\n if (!portalNode || modal) {\n return undefined;\n }\n\n // Make sure elements inside the portal element are tabbable only when the\n // portal has already been focused, either by tabbing into a focus trap\n // element outside or using the mouse.\n function onFocus(event) {\n if (portalNode && event.relatedTarget && isOutsideEvent(event)) {\n if (event.type === 'focusin') {\n if (focusInsideDisabledRef.current) {\n enableFocusInside(portalNode);\n focusInsideDisabledRef.current = false;\n }\n } else {\n disableFocusInside(portalNode);\n focusInsideDisabledRef.current = true;\n }\n }\n }\n\n // Listen to the event on the capture phase so they run before the focus\n // trap elements onFocus prop is called.\n return mergeCleanups(addEventListener(portalNode, 'focusin', onFocus, true), addEventListener(portalNode, 'focusout', onFocus, true));\n }, [portalNode, modal]);\n useIsoLayoutEffect(() => {\n if (!portalNode || open !== true || !focusInsideDisabledRef.current) {\n return;\n }\n\n // Restore tabbability before the focus manager's queued focus-on-open step runs.\n enableFocusInside(portalNode);\n focusInsideDisabledRef.current = false;\n }, [open, portalNode]);\n const portalContextValue = React.useMemo(() => ({\n beforeOutsideRef,\n afterOutsideRef,\n beforeInsideRef,\n afterInsideRef,\n portalNode,\n setFocusManagerState\n }), [portalNode]);\n return /*#__PURE__*/_jsxs(React.Fragment, {\n children: [portalSubtree, /*#__PURE__*/_jsxs(PortalContext.Provider, {\n value: portalContextValue,\n children: [shouldRenderGuards && portalNode && /*#__PURE__*/_jsx(FocusGuard, {\n \"data-type\": \"outside\",\n ref: beforeOutsideRef,\n onFocus: event => {\n if (isOutsideEvent(event, portalNode)) {\n beforeInsideRef.current?.focus();\n } else {\n const domReference = focusManagerState ? focusManagerState.domReference : null;\n const prevTabbable = getPreviousTabbable(domReference);\n prevTabbable?.focus();\n }\n }\n }), shouldRenderGuards && portalNode && /*#__PURE__*/_jsx(\"span\", {\n \"aria-owns\": portalNode.id,\n style: ownerVisuallyHidden\n }), portalNode && /*#__PURE__*/ReactDOM.createPortal(children, portalNode), shouldRenderGuards && portalNode && /*#__PURE__*/_jsx(FocusGuard, {\n \"data-type\": \"outside\",\n ref: afterOutsideRef,\n onFocus: event => {\n if (isOutsideEvent(event, portalNode)) {\n afterInsideRef.current?.focus();\n } else {\n const domReference = focusManagerState ? focusManagerState.domReference : null;\n const nextTabbable = getNextTabbable(domReference);\n nextTabbable?.focus();\n if (focusManagerState?.closeOnFocusOut) {\n focusManagerState?.onOpenChange(false, createChangeEventDetails(REASONS.focusOut, event.nativeEvent));\n }\n }\n }\n })]\n })]\n });\n});\nif (process.env.NODE_ENV !== \"production\") FloatingPortal.displayName = \"FloatingPortal\";","export const TYPEAHEAD_RESET_MS = 500;\nexport const PATIENT_CLICK_THRESHOLD = 500;\nexport const DISABLED_TRANSITIONS_STYLE = {\n style: {\n transition: 'none'\n }\n};\nexport const CLICK_TRIGGER_IDENTIFIER = 'data-base-ui-click-trigger';\nexport const BASE_UI_SWIPE_IGNORE_ATTRIBUTE = 'data-base-ui-swipe-ignore';\nexport const LEGACY_SWIPE_IGNORE_ATTRIBUTE = 'data-swipe-ignore';\nexport const BASE_UI_SWIPE_IGNORE_SELECTOR = `[${BASE_UI_SWIPE_IGNORE_ATTRIBUTE}]`;\nexport const LEGACY_SWIPE_IGNORE_SELECTOR = `[${LEGACY_SWIPE_IGNORE_ATTRIBUTE}]`;\n\n/**\n * Used for dropdowns that usually strictly prefer top/bottom placements and\n * use `var(--available-height)` to limit their height.\n */\nexport const DROPDOWN_COLLISION_AVOIDANCE = {\n fallbackAxisSide: 'none'\n};\n\n/**\n * Used by regular popups that usually aren't scrollable and are allowed to\n * freely flip to any axis of placement.\n */\nexport const POPUP_COLLISION_AVOIDANCE = {\n fallbackAxisSide: 'end'\n};\n\n/**\n * Special visually hidden styles for the aria-owns owner element to ensure owned element\n * accessibility in iOS/Safari/VoiceControl.\n * The owner element is an empty span, so most of the common visually hidden styles are not needed.\n * @see https://github.com/floating-ui/floating-ui/issues/3403\n */\nexport const ownerVisuallyHidden = {\n clipPath: 'inset(50%)',\n position: 'fixed',\n top: 0,\n left: 0\n};","import { createSelector, ReactStore } from '@base-ui/utils/store';\nimport { createEventEmitter } from \"../utils/createEventEmitter.mjs\";\nimport { isClickLikeEvent } from \"../utils.mjs\";\nconst selectors = {\n open: createSelector(state => state.open),\n transitionStatus: createSelector(state => state.transitionStatus),\n domReferenceElement: createSelector(state => state.domReferenceElement),\n referenceElement: createSelector(state => state.positionReference ?? state.referenceElement),\n floatingElement: createSelector(state => state.floatingElement),\n floatingId: createSelector(state => state.floatingId)\n};\nexport class FloatingRootStore extends ReactStore {\n constructor(options) {\n const {\n syncOnly,\n nested,\n onOpenChange,\n triggerElements,\n ...initialState\n } = options;\n super({\n ...initialState,\n positionReference: initialState.referenceElement,\n domReferenceElement: initialState.referenceElement\n }, {\n onOpenChange,\n dataRef: {\n current: {}\n },\n events: createEventEmitter(),\n nested,\n triggerElements\n }, selectors);\n this.syncOnly = syncOnly;\n }\n\n /**\n * Syncs the event used by hover logic to distinguish hover-open from click-like interaction.\n */\n syncOpenEvent = (newOpen, event) => {\n if (!newOpen || !this.state.open ||\n // Prevent a pending hover-open from overwriting a click-open event, while allowing\n // click events to upgrade a hover-open.\n event != null && isClickLikeEvent(event)) {\n this.context.dataRef.current.openEvent = newOpen ? event : undefined;\n }\n };\n\n /**\n * Runs the root-owned side effects for an open state change.\n */\n dispatchOpenChange = (newOpen, eventDetails) => {\n this.syncOpenEvent(newOpen, eventDetails.event);\n const details = {\n open: newOpen,\n reason: eventDetails.reason,\n nativeEvent: eventDetails.event,\n nested: this.context.nested,\n triggerElement: eventDetails.trigger\n };\n this.context.events.emit('openchange', details);\n };\n\n /**\n * Emits the `openchange` event through the internal event emitter and calls the `onOpenChange` handler with the provided arguments.\n *\n * @param newOpen The new open state.\n * @param eventDetails Details about the event that triggered the open state change.\n */\n setOpen = (newOpen, eventDetails) => {\n if (this.syncOnly) {\n this.context.onOpenChange?.(newOpen, eventDetails);\n return;\n }\n this.dispatchOpenChange(newOpen, eventDetails);\n this.context.onOpenChange?.(newOpen, eventDetails);\n };\n}","/* False positives - ESLint thinks we're calling a hook from a class component. */\n/* eslint-disable react-hooks/rules-of-hooks */\n'use client';\n\nimport * as React from 'react';\nimport { Store } from \"./Store.mjs\";\nimport { useStore } from \"./useStore.mjs\";\nimport { useStableCallback } from \"../useStableCallback.mjs\";\nimport { useIsoLayoutEffect } from \"../useIsoLayoutEffect.mjs\";\nimport { NOOP } from \"../empty.mjs\";\n\n/**\n * A Store that supports controlled state keys, non-reactive values and provides utility methods for React.\n */\nexport class ReactStore extends Store {\n /**\n * Creates a new ReactStore instance.\n *\n * @param state Initial state of the store.\n * @param context Non-reactive context values.\n * @param selectors Optional selectors for use with `useState`.\n */\n constructor(state, context = {}, selectors) {\n super(state);\n this.context = context;\n this.selectors = selectors;\n }\n\n /**\n * Non-reactive values such as refs, callbacks, etc.\n */\n\n /**\n * Synchronizes a single external value into the store.\n *\n * Note that the while the value in `state` is updated immediately, the value returned\n * by `useState` is updated before the next render (similarly to React's `useState`).\n */\n useSyncedValue(key, value) {\n React.useDebugValue(key);\n // eslint-disable-next-line consistent-this\n const store = this;\n useIsoLayoutEffect(() => {\n if (store.state[key] !== value) {\n store.set(key, value);\n }\n }, [store, key, value]);\n }\n\n /**\n * Synchronizes a single external value into the store and\n * cleans it up (sets to `undefined`) on unmount.\n *\n * Note that the while the value in `state` is updated immediately, the value returned\n * by `useState` is updated before the next render (similarly to React's `useState`).\n */\n useSyncedValueWithCleanup(key, value) {\n // eslint-disable-next-line consistent-this\n const store = this;\n useIsoLayoutEffect(() => {\n if (store.state[key] !== value) {\n store.set(key, value);\n }\n return () => {\n store.set(key, undefined);\n };\n }, [store, key, value]);\n }\n\n /**\n * Synchronizes multiple external values into the store.\n *\n * Note that the while the values in `state` are updated immediately, the values returned\n * by `useState` are updated before the next render (similarly to React's `useState`).\n */\n useSyncedValues(statePart) {\n // eslint-disable-next-line consistent-this\n const store = this;\n if (process.env.NODE_ENV !== 'production') {\n // Check that an object with the same shape is passed on every render\n React.useDebugValue(statePart, p => Object.keys(p));\n const keys = React.useRef(Object.keys(statePart)).current;\n const nextKeys = Object.keys(statePart);\n if (keys.length !== nextKeys.length || keys.some((key, index) => key !== nextKeys[index])) {\n console.error('ReactStore.useSyncedValues expects the same prop keys on every render. Keys should be stable.');\n }\n }\n const dependencies = Object.values(statePart);\n useIsoLayoutEffect(() => {\n store.update(statePart);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [store, ...dependencies]);\n }\n\n /**\n * Registers a controllable prop pair (`controlled`, `defaultValue`) for a specific key. If `controlled`\n * is non-undefined, the store's state at `key` is updated to match `controlled`.\n */\n useControlledProp(key, controlled) {\n React.useDebugValue(key);\n // eslint-disable-next-line consistent-this\n const store = this;\n const isControlled = controlled !== undefined;\n useIsoLayoutEffect(() => {\n if (isControlled && !Object.is(store.state[key], controlled)) {\n // Set the internal state to match the controlled value.\n store.setState({\n ...store.state,\n [key]: controlled\n });\n }\n }, [store, key, controlled, isControlled]);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line\n const cache = this.controlledValues ??= new Map();\n if (!cache.has(key)) {\n cache.set(key, isControlled);\n }\n const previouslyControlled = cache.get(key);\n if (previouslyControlled !== undefined && previouslyControlled !== isControlled) {\n console.error(`A component is changing the ${isControlled ? '' : 'un'}controlled state of ${key.toString()} to be ${isControlled ? 'un' : ''}controlled. Elements should not switch from uncontrolled to controlled (or vice versa).`);\n }\n }\n }\n\n /** Gets the current value from the store using a selector with the provided key.\n *\n * @param key Key of the selector to use.\n */\n\n select(key, a1, a2, a3) {\n const selector = this.selectors[key];\n return selector(this.state, a1, a2, a3);\n }\n\n /**\n * Returns a value from the store's state using a selector function.\n * Used to subscribe to specific parts of the state.\n * This methods causes a rerender whenever the selected state changes.\n *\n * @param key Key of the selector to use.\n */\n\n useState(key, a1, a2, a3) {\n React.useDebugValue(key);\n return useStore(this, this.selectors[key], a1, a2, a3);\n }\n\n /**\n * Wraps a function with `useStableCallback` to ensure it has a stable reference\n * and assigns it to the context.\n *\n * @param key Key of the event callback. Must be a function in the context.\n * @param fn Function to assign.\n */\n useContextCallback(key, fn) {\n React.useDebugValue(key);\n const stableFunction = useStableCallback(fn ?? NOOP);\n this.context[key] = stableFunction;\n }\n\n /**\n * Returns a stable setter function for a specific key in the store's state.\n * It's commonly used to pass as a ref callback to React elements.\n *\n * @param key Key of the state to set.\n */\n useStateSetter(key) {\n const ref = React.useRef(undefined);\n if (ref.current === undefined) {\n ref.current = value => {\n this.set(key, value);\n };\n }\n return ref.current;\n }\n\n /**\n * Observes changes derived from the store's selectors and calls the listener when the selected value changes.\n *\n * @param key Key of the selector to observe.\n * @param listener Listener function called when the selector result changes.\n */\n\n observe(selector, listener) {\n let selectFn;\n if (typeof selector === 'function') {\n selectFn = selector;\n } else {\n selectFn = this.selectors[selector];\n }\n let prevValue = selectFn(this.state);\n listener(prevValue, prevValue, this);\n return this.subscribe(nextState => {\n const nextValue = selectFn(nextState);\n if (!Object.is(prevValue, nextValue)) {\n const oldValue = prevValue;\n prevValue = nextValue;\n listener(nextValue, oldValue, this);\n }\n });\n }\n}","import * as React from 'react';\n/* We need to import the shim because React 17 does not support the `useSyncExternalStore` API.\n * More info: https://github.com/mui/mui-x/issues/18303#issuecomment-2958392341 */\nimport { useSyncExternalStore } from 'use-sync-external-store/shim';\nimport { useSyncExternalStoreWithSelector } from 'use-sync-external-store/shim/with-selector';\nimport { isReactVersionAtLeast } from \"../reactVersion.mjs\";\nimport { register, getInstance } from \"../fastHooks.mjs\";\n/* Some tests fail in R18 with the raw useSyncExternalStore. It may be possible to make it work\n * but for now we only enable it for R19+. */\nconst canUseRawUseSyncExternalStore = isReactVersionAtLeast(19);\nconst useStoreImplementation = canUseRawUseSyncExternalStore ? useStoreFast : useStoreLegacy;\nexport function useStore(store, selector, a1, a2, a3) {\n return useStoreImplementation(store, selector, a1, a2, a3);\n}\nfunction useStoreR19(store, selector, a1, a2, a3) {\n const getSelection = React.useCallback(() => selector(store.getSnapshot(), a1, a2, a3), [store, selector, a1, a2, a3]);\n return useSyncExternalStore(store.subscribe, getSelection, getSelection);\n}\nregister({\n before(instance) {\n instance.syncIndex = 0;\n if (!instance.didInitialize) {\n instance.syncTick = 1;\n instance.syncHooks = [];\n instance.didChangeStore = true;\n instance.getSnapshot = () => {\n let didChange = false;\n for (let i = 0; i < instance.syncHooks.length; i += 1) {\n const hook = instance.syncHooks[i];\n const value = hook.selector(hook.store.state, hook.a1, hook.a2, hook.a3);\n if (!Object.is(hook.value, value)) {\n didChange = true;\n hook.value = value;\n }\n }\n if (didChange) {\n instance.syncTick += 1;\n }\n return instance.syncTick;\n };\n }\n },\n after(instance) {\n if (instance.syncHooks.length > 0) {\n if (instance.didChangeStore) {\n instance.didChangeStore = false;\n instance.subscribe = onStoreChange => {\n const stores = new Set();\n for (const hook of instance.syncHooks) {\n stores.add(hook.store);\n }\n const unsubscribes = [];\n for (const store of stores) {\n unsubscribes.push(store.subscribe(onStoreChange));\n }\n return () => {\n for (const unsubscribe of unsubscribes) {\n unsubscribe();\n }\n };\n };\n }\n // eslint-disable-next-line react-hooks/rules-of-hooks\n useSyncExternalStore(instance.subscribe, instance.getSnapshot, instance.getSnapshot);\n }\n }\n});\nfunction useStoreFast(store, selector, a1, a2, a3) {\n const instance = getInstance();\n if (!instance) {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n return useStoreR19(store, selector, a1, a2, a3);\n }\n const index = instance.syncIndex;\n instance.syncIndex += 1;\n let hook;\n if (!instance.didInitialize) {\n hook = {\n store,\n selector,\n a1,\n a2,\n a3,\n value: selector(store.getSnapshot(), a1, a2, a3)\n };\n instance.syncHooks.push(hook);\n } else {\n hook = instance.syncHooks[index];\n if (hook.store !== store || hook.selector !== selector || !Object.is(hook.a1, a1) || !Object.is(hook.a2, a2) || !Object.is(hook.a3, a3)) {\n if (hook.store !== store) {\n instance.didChangeStore = true;\n }\n hook.store = store;\n hook.selector = selector;\n hook.a1 = a1;\n hook.a2 = a2;\n hook.a3 = a3;\n hook.value = selector(store.getSnapshot(), a1, a2, a3);\n }\n }\n return hook.value;\n}\nfunction useStoreLegacy(store, selector, a1, a2, a3) {\n return useSyncExternalStoreWithSelector(store.subscribe, store.getSnapshot, store.getSnapshot, state => selector(state, a1, a2, a3));\n}","import { useStore } from \"./useStore.mjs\";\n/**\n * A data store implementation that allows subscribing to state changes and updating the state.\n * It uses an observer pattern to notify subscribers when the state changes.\n */\nexport class Store {\n /**\n * The current state of the store.\n * This property is updated immediately when the state changes as a result of calling {@link setState}, {@link update}, or {@link set}.\n * To subscribe to state changes, use the {@link useState} method. The value returned by {@link useState} is updated after the component renders (similarly to React's useState).\n * The values can be used directly (to avoid subscribing to the store) in effects or event handlers.\n *\n * Do not modify properties in state directly. Instead, use the provided methods to ensure proper state management and listener notification.\n */\n\n // Internal state to handle recursive `setState()` calls\n\n constructor(state) {\n this.state = state;\n this.listeners = new Set();\n this.updateTick = 0;\n }\n\n /**\n * Registers a listener that will be called whenever the store's state changes.\n *\n * @param fn The listener function to be called on state changes.\n * @returns A function to unsubscribe the listener.\n */\n subscribe = fn => {\n this.listeners.add(fn);\n return () => {\n this.listeners.delete(fn);\n };\n };\n\n /**\n * Returns the current state of the store.\n */\n getSnapshot = () => {\n return this.state;\n };\n\n /**\n * Updates the entire store's state and notifies all registered listeners.\n *\n * @param newState The new state to set for the store.\n */\n setState(newState) {\n if (this.state === newState) {\n return;\n }\n this.state = newState;\n this.updateTick += 1;\n const currentTick = this.updateTick;\n for (const listener of this.listeners) {\n if (currentTick !== this.updateTick) {\n // If the tick has changed, a recursive `setState` call has been made,\n // and it has already notified all listeners.\n return;\n }\n listener(newState);\n }\n }\n\n /**\n * Merges the provided changes into the current state and notifies listeners if there are changes.\n *\n * @param changes An object containing the changes to apply to the current state.\n */\n update(changes) {\n for (const key in changes) {\n if (!Object.is(this.state[key], changes[key])) {\n this.setState({\n ...this.state,\n ...changes\n });\n return;\n }\n }\n }\n\n /**\n * Sets a specific key in the store's state to a new value and notifies listeners if the value has changed.\n *\n * @param key The key in the store's state to update.\n * @param value The new value to set for the specified key.\n */\n set(key, value) {\n if (!Object.is(this.state[key], value)) {\n this.setState({\n ...this.state,\n [key]: value\n });\n }\n }\n\n /**\n * Gives the state a new reference and updates all registered listeners.\n */\n notifyAll() {\n const newState = {\n ...this.state\n };\n this.setState(newState);\n }\n use(selector, a1, a2, a3) {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n return useStore(this, selector, a1, a2, a3);\n }\n}","'use client';\n\nimport * as React from 'react';\nimport { useId } from '@base-ui/utils/useId';\nimport { useIsoLayoutEffect } from '@base-ui/utils/useIsoLayoutEffect';\nimport { useRefWithInit } from '@base-ui/utils/useRefWithInit';\nimport { FloatingTreeStore } from \"./FloatingTreeStore.mjs\";\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst FloatingNodeContext = /*#__PURE__*/React.createContext(null);\nif (process.env.NODE_ENV !== \"production\") FloatingNodeContext.displayName = \"FloatingNodeContext\";\nconst FloatingTreeContext = /*#__PURE__*/React.createContext(null);\n\n/**\n * Returns the parent node id for nested floating elements, if available.\n * Returns `null` for top-level floating elements.\n */\nif (process.env.NODE_ENV !== \"production\") FloatingTreeContext.displayName = \"FloatingTreeContext\";\nexport const useFloatingParentNodeId = () => React.useContext(FloatingNodeContext)?.id || null;\n\n/**\n * Returns the nearest floating tree context, if available.\n */\nexport const useFloatingTree = externalTree => {\n const contextTree = React.useContext(FloatingTreeContext);\n return externalTree ?? contextTree;\n};\n\n/**\n * Registers a node into the `FloatingTree`, returning its id.\n * @see https://floating-ui.com/docs/FloatingTree\n */\nexport function useFloatingNodeId(externalTree) {\n const id = useId();\n const tree = useFloatingTree(externalTree);\n const parentId = useFloatingParentNodeId();\n useIsoLayoutEffect(() => {\n if (!id) {\n return undefined;\n }\n const node = {\n id,\n parentId\n };\n tree?.addNode(node);\n return () => {\n tree?.removeNode(node);\n };\n }, [tree, id, parentId]);\n return id;\n}\n/**\n * Provides parent node context for nested floating elements.\n * @see https://floating-ui.com/docs/FloatingTree\n * @internal\n */\nexport function FloatingNode(props) {\n const {\n children,\n id\n } = props;\n const parentId = useFloatingParentNodeId();\n return /*#__PURE__*/_jsx(FloatingNodeContext.Provider, {\n value: React.useMemo(() => ({\n id,\n parentId\n }), [id, parentId]),\n children: children\n });\n}\n/**\n * Provides context for nested floating elements when they are not children of\n * each other on the DOM.\n * This is not necessary in all cases, except when there must be explicit communication between parent and child floating elements. It is necessary for:\n * - The `bubbles` option in the `useDismiss()` Hook\n * - Nested virtual list navigation\n * - Nested floating elements that each open on hover\n * - Custom communication between parent and child floating elements\n * @see https://floating-ui.com/docs/FloatingTree\n * @internal\n */\nexport function FloatingTree(props) {\n const {\n children,\n externalTree\n } = props;\n const tree = useRefWithInit(() => externalTree ?? new FloatingTreeStore()).current;\n return /*#__PURE__*/_jsx(FloatingTreeContext.Provider, {\n value: tree,\n children: children\n });\n}","export function createEventEmitter() {\n const map = new Map();\n return {\n emit(event, data) {\n map.get(event)?.forEach(listener => listener(data));\n },\n on(event, listener) {\n if (!map.has(event)) {\n map.set(event, new Set());\n }\n map.get(event).add(listener);\n },\n off(event, listener) {\n map.get(event)?.delete(listener);\n }\n };\n}","import { createEventEmitter } from \"../utils/createEventEmitter.mjs\";\n\n/**\n * Stores and manages floating elements in a tree structure.\n * This is a backing store for the `FloatingTree` component.\n */\nexport class FloatingTreeStore {\n nodesRef = {\n current: []\n };\n events = createEventEmitter();\n addNode(node) {\n this.nodesRef.current.push(node);\n }\n removeNode(node) {\n const index = this.nodesRef.current.findIndex(n => n === node);\n if (index !== -1) {\n this.nodesRef.current.splice(index, 1);\n }\n }\n}","'use client';\n\n/* eslint-disable no-underscore-dangle */\nimport * as React from 'react';\nimport { addEventListener } from '@base-ui/utils/addEventListener';\nimport { mergeCleanups } from '@base-ui/utils/mergeCleanups';\nimport { ownerDocument } from '@base-ui/utils/owner';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nimport { Timeout, useTimeout } from '@base-ui/utils/useTimeout';\nimport { getComputedStyle, getParentNode, isElement, isHTMLElement, isLastTraversableNode, isShadowRoot } from '@floating-ui/utils/dom';\nimport { platform } from '@base-ui/utils/platform';\nimport { useFloatingTree } from \"../components/FloatingTree.mjs\";\nimport { createChangeEventDetails } from \"../../internals/createBaseUIEventDetails.mjs\";\nimport { REASONS } from \"../../internals/reasons.mjs\";\nimport { createAttribute } from \"../utils/createAttribute.mjs\";\nimport { contains, getTarget, isEventTargetWithin, isRootElement } from \"../utils/element.mjs\";\nimport { isReactEvent } from \"../utils/event.mjs\";\nimport { getNodeChildren } from \"../utils/nodes.mjs\";\nfunction alwaysFalse() {\n return false;\n}\nexport function normalizeProp(normalizable) {\n return {\n escapeKey: typeof normalizable === 'boolean' ? normalizable : normalizable?.escapeKey ?? false,\n outsidePress: typeof normalizable === 'boolean' ? normalizable : normalizable?.outsidePress ?? true\n };\n}\n/**\n * Closes the floating element when a dismissal is requested — by default, when\n * the user presses the `escape` key or outside of the floating element.\n * @see https://floating-ui.com/docs/useDismiss\n */\nexport function useDismiss(context, props = {}) {\n const {\n enabled = true,\n escapeKey = true,\n outsidePress: outsidePressProp = true,\n outsidePressEvent = 'sloppy',\n referencePress = alwaysFalse,\n bubbles,\n externalTree\n } = props;\n const store = 'rootStore' in context ? context.rootStore : context;\n const open = store.useState('open');\n const floatingElement = store.useState('floatingElement');\n const {\n dataRef\n } = store.context;\n const tree = useFloatingTree(externalTree);\n const outsidePressFn = useStableCallback(typeof outsidePressProp === 'function' ? outsidePressProp : () => false);\n const outsidePress = typeof outsidePressProp === 'function' ? outsidePressFn : outsidePressProp;\n const outsidePressEnabled = outsidePress !== false;\n const getOutsidePressEventProp = useStableCallback(() => outsidePressEvent);\n const {\n escapeKey: escapeKeyBubbles,\n outsidePress: outsidePressBubbles\n } = normalizeProp(bubbles);\n const pressStartedInsideRef = React.useRef(false);\n const pressStartPreventedRef = React.useRef(false);\n // Ignore only the very next outside click after dragging from inside to outside.\n const suppressNextOutsideClickRef = React.useRef(false);\n const isComposingRef = React.useRef(false);\n const currentPointerTypeRef = React.useRef('');\n const touchStateRef = React.useRef(null);\n const cancelDismissOnEndTimeout = useTimeout();\n const clearInsideReactTreeTimeout = useTimeout();\n const clearInsideReactTree = useStableCallback(() => {\n clearInsideReactTreeTimeout.clear();\n dataRef.current.insideReactTree = false;\n });\n const hasBlockingChild = useStableCallback(bubbleKey => {\n const nodeId = dataRef.current.floatingContext?.nodeId;\n const children = tree ? getNodeChildren(tree.nodesRef.current, nodeId) : [];\n return children.some(child => child.context?.open && !child.context.dataRef.current[bubbleKey]);\n });\n const isEventWithinOwnElements = useStableCallback(event => {\n return isEventTargetWithin(event, store.select('floatingElement')) || isEventTargetWithin(event, store.select('domReferenceElement'));\n });\n const closeOnReferencePress = useStableCallback(event => {\n if (!referencePress()) {\n return;\n }\n store.setOpen(false, createChangeEventDetails(REASONS.triggerPress, event.nativeEvent));\n });\n const closeOnEscapeKeyDown = useStableCallback(event => {\n if (!open || !enabled || !escapeKey || event.key !== 'Escape') {\n return;\n }\n\n // Wait until IME is settled. Pressing `Escape` while composing should\n // close the compose menu, but not the floating element.\n if (isComposingRef.current) {\n return;\n }\n if (!escapeKeyBubbles && hasBlockingChild('__escapeKeyBubbles')) {\n return;\n }\n const native = isReactEvent(event) ? event.nativeEvent : event;\n const eventDetails = createChangeEventDetails(REASONS.escapeKey, native);\n store.setOpen(false, eventDetails);\n if (!eventDetails.isCanceled) {\n event.preventDefault();\n }\n if (!escapeKeyBubbles && !eventDetails.isPropagationAllowed) {\n event.stopPropagation();\n }\n });\n const markInsideReactTree = useStableCallback(() => {\n dataRef.current.insideReactTree = true;\n clearInsideReactTreeTimeout.start(0, clearInsideReactTree);\n });\n const markPressStartedInsideReactTree = useStableCallback(event => {\n if (!open || !enabled || event.button !== 0) {\n return;\n }\n const target = getTarget(event.nativeEvent);\n\n // Only treat presses that start within the floating DOM subtree as inside.\n // This avoids suppressing parent dismissal when interacting with nested portals.\n if (!contains(store.select('floatingElement'), target)) {\n return;\n }\n if (!pressStartedInsideRef.current) {\n pressStartedInsideRef.current = true;\n pressStartPreventedRef.current = false;\n }\n });\n const markInsidePressStartPrevented = useStableCallback(event => {\n if (!open || !enabled) {\n return;\n }\n if (!(event.defaultPrevented || event.nativeEvent.defaultPrevented)) {\n return;\n }\n if (pressStartedInsideRef.current) {\n pressStartPreventedRef.current = true;\n }\n });\n React.useEffect(() => {\n if (!open || !enabled) {\n return undefined;\n }\n dataRef.current.__escapeKeyBubbles = escapeKeyBubbles;\n dataRef.current.__outsidePressBubbles = outsidePressBubbles;\n const compositionTimeout = new Timeout();\n const preventedPressSuppressionTimeout = new Timeout();\n function handleCompositionStart() {\n compositionTimeout.clear();\n isComposingRef.current = true;\n }\n function handleCompositionEnd() {\n // Safari fires `compositionend` before `keydown`, so we need to wait\n // until the next tick to set `isComposing` to `false`.\n // https://bugs.webkit.org/show_bug.cgi?id=165004\n compositionTimeout.start(\n // 0ms or 1ms don't work in Safari. 5ms appears to consistently work.\n // Only apply to WebKit for the test to remain 0ms.\n platform.engine.webkit ? 5 : 0, () => {\n isComposingRef.current = false;\n });\n }\n function suppressImmediateOutsideClickAfterPreventedStart() {\n suppressNextOutsideClickRef.current = true;\n // Firefox can emit the synthetic outside click in a later task after\n // pointer lock exit, so microtask clearing is too early here.\n preventedPressSuppressionTimeout.start(0, () => {\n suppressNextOutsideClickRef.current = false;\n });\n }\n function resetPressStartState() {\n pressStartedInsideRef.current = false;\n pressStartPreventedRef.current = false;\n }\n function getOutsidePressEvent() {\n const type = currentPointerTypeRef.current;\n const computedType = type === 'pen' || !type ? 'mouse' : type;\n const outsidePressEventValue = getOutsidePressEventProp();\n const resolved = typeof outsidePressEventValue === 'function' ? outsidePressEventValue() : outsidePressEventValue;\n if (typeof resolved === 'string') {\n return resolved;\n }\n return resolved[computedType];\n }\n function shouldIgnoreEvent(event) {\n const computedOutsidePressEvent = getOutsidePressEvent();\n return computedOutsidePressEvent === 'intentional' && event.type !== 'click' || computedOutsidePressEvent === 'sloppy' && event.type === 'click';\n }\n function isEventWithinFloatingTree(event) {\n const nodeId = dataRef.current.floatingContext?.nodeId;\n const targetIsInsideChildren = tree && getNodeChildren(tree.nodesRef.current, nodeId).some(node => isEventTargetWithin(event, node.context?.elements.floating));\n return isEventWithinOwnElements(event) || targetIsInsideChildren;\n }\n function closeOnPressOutside(event) {\n if (shouldIgnoreEvent(event)) {\n // A new press began outside the floating element and its trigger. Clear any\n // leftover drag-out suppression so this press's eventual click can dismiss.\n if (event.type !== 'click' && !isEventWithinOwnElements(event)) {\n preventedPressSuppressionTimeout.clear();\n suppressNextOutsideClickRef.current = false;\n }\n clearInsideReactTree();\n return;\n }\n if (dataRef.current.insideReactTree) {\n clearInsideReactTree();\n return;\n }\n const target = getTarget(event);\n const inertSelector = `[${createAttribute('inert')}]`;\n const targetRoot = isElement(target) ? target.getRootNode() : null;\n const markers = Array.from((isShadowRoot(targetRoot) ? targetRoot : ownerDocument(store.select('floatingElement'))).querySelectorAll(inertSelector));\n const triggers = store.context.triggerElements;\n\n // If another trigger is clicked, don't close the floating element.\n if (target && (triggers.hasElement(target) || triggers.hasMatchingElement(trigger => contains(trigger, target)))) {\n return;\n }\n let targetRootAncestor = isElement(target) ? target : null;\n while (targetRootAncestor && !isLastTraversableNode(targetRootAncestor)) {\n const nextParent = getParentNode(targetRootAncestor);\n if (isLastTraversableNode(nextParent) || !isElement(nextParent)) {\n break;\n }\n targetRootAncestor = nextParent;\n }\n\n // Check if the click occurred on a third-party element injected after the\n // floating element rendered.\n if (markers.length && isElement(target) && !isRootElement(target) &&\n // Clicked on a direct ancestor (e.g. FloatingOverlay).\n !contains(target, store.select('floatingElement')) &&\n // If the target root element contains none of the markers, then the\n // element was injected after the floating element rendered.\n markers.every(marker => !contains(targetRootAncestor, marker))) {\n return;\n }\n\n // Check if the click occurred on the scrollbar\n // Skip for touch events: scrollbars don't receive touch events on most platforms\n if (isHTMLElement(target) && !('touches' in event)) {\n const lastTraversableNode = isLastTraversableNode(target);\n const style = getComputedStyle(target);\n const scrollRe = /auto|scroll/;\n const isScrollableX = lastTraversableNode || scrollRe.test(style.overflowX);\n const isScrollableY = lastTraversableNode || scrollRe.test(style.overflowY);\n const canScrollX = isScrollableX && target.clientWidth > 0 && target.scrollWidth > target.clientWidth;\n const canScrollY = isScrollableY && target.clientHeight > 0 && target.scrollHeight > target.clientHeight;\n const isRTL = style.direction === 'rtl';\n\n // Check click position relative to scrollbar.\n // In some browsers it is possible to change the <body> (or window)\n // scrollbar to the left side, but is very rare and is difficult to\n // check for. Plus, for modal dialogs with backdrops, it is more\n // important that the backdrop is checked but not so much the window.\n const pressedVerticalScrollbar = canScrollY && (isRTL ? event.offsetX <= target.offsetWidth - target.clientWidth : event.offsetX > target.clientWidth);\n const pressedHorizontalScrollbar = canScrollX && event.offsetY > target.clientHeight;\n if (pressedVerticalScrollbar || pressedHorizontalScrollbar) {\n return;\n }\n }\n if (isEventWithinFloatingTree(event)) {\n return;\n }\n\n // In intentional mode, a press that starts inside and ends outside gets\n // one suppressed outside click. Run this after inside-target checks so\n // inside clicks don't consume the one-shot suppression.\n if (getOutsidePressEvent() === 'intentional' && suppressNextOutsideClickRef.current) {\n preventedPressSuppressionTimeout.clear();\n suppressNextOutsideClickRef.current = false;\n return;\n }\n if (typeof outsidePress === 'function' && !outsidePress(event)) {\n return;\n }\n if (hasBlockingChild('__outsidePressBubbles')) {\n return;\n }\n store.setOpen(false, createChangeEventDetails(REASONS.outsidePress, event));\n clearInsideReactTree();\n }\n function handlePointerDown(event) {\n if (getOutsidePressEvent() !== 'sloppy' || event.pointerType === 'touch' || !store.select('open') || !enabled || isEventWithinOwnElements(event)) {\n return;\n }\n closeOnPressOutside(event);\n }\n function handleTouchStart(event) {\n if (getOutsidePressEvent() !== 'sloppy' || !store.select('open') || !enabled || isEventWithinOwnElements(event)) {\n return;\n }\n const touch = event.touches[0];\n if (touch) {\n touchStateRef.current = {\n startTime: Date.now(),\n startX: touch.clientX,\n startY: touch.clientY,\n dismissOnTouchEnd: false,\n dismissOnMouseDown: true\n };\n cancelDismissOnEndTimeout.start(1000, () => {\n if (touchStateRef.current) {\n touchStateRef.current.dismissOnTouchEnd = false;\n touchStateRef.current.dismissOnMouseDown = false;\n }\n });\n }\n }\n function addTargetEventListenerOnce(event, listener) {\n const target = getTarget(event);\n if (!target) {\n return;\n }\n const unsubscribe = addEventListener(target, event.type, () => {\n listener(event);\n unsubscribe();\n });\n }\n function handleTouchStartCapture(event) {\n currentPointerTypeRef.current = 'touch';\n addTargetEventListenerOnce(event, handleTouchStart);\n }\n function closeOnPressOutsideCapture(event) {\n cancelDismissOnEndTimeout.clear();\n if (event.type === 'pointerdown') {\n currentPointerTypeRef.current = event.pointerType;\n }\n if (event.type === 'mousedown' && touchStateRef.current && !touchStateRef.current.dismissOnMouseDown) {\n return;\n }\n addTargetEventListenerOnce(event, targetEvent => {\n if (targetEvent.type === 'pointerdown') {\n handlePointerDown(targetEvent);\n } else {\n closeOnPressOutside(targetEvent);\n }\n });\n }\n function handlePressEndCapture(event) {\n if (!pressStartedInsideRef.current) {\n return;\n }\n const pressStartedInsideDefaultPrevented = pressStartPreventedRef.current;\n resetPressStartState();\n if (getOutsidePressEvent() !== 'intentional') {\n return;\n }\n if (event.type === 'pointercancel') {\n if (pressStartedInsideDefaultPrevented) {\n suppressImmediateOutsideClickAfterPreventedStart();\n }\n return;\n }\n if (isEventWithinFloatingTree(event)) {\n return;\n }\n\n // If pointerdown was prevented, no click may be generated for that\n // interaction. However, Firefox may still emit an immediate click after\n // pointerup (e.g. NumberField scrub with pointer lock), so suppress for\n // one tick to absorb that synthetic click only.\n if (pressStartedInsideDefaultPrevented) {\n suppressImmediateOutsideClickAfterPreventedStart();\n return;\n }\n\n // Avoid suppressing when outsidePress explicitly ignores this target.\n if (typeof outsidePress === 'function' && !outsidePress(event)) {\n return;\n }\n preventedPressSuppressionTimeout.clear();\n suppressNextOutsideClickRef.current = true;\n clearInsideReactTree();\n }\n function handleTouchMove(event) {\n if (getOutsidePressEvent() !== 'sloppy' || !touchStateRef.current || isEventWithinOwnElements(event)) {\n return;\n }\n const touch = event.touches[0];\n if (!touch) {\n return;\n }\n const deltaX = Math.abs(touch.clientX - touchStateRef.current.startX);\n const deltaY = Math.abs(touch.clientY - touchStateRef.current.startY);\n const distance = Math.sqrt(deltaX * deltaX + deltaY * deltaY);\n if (distance > 5) {\n touchStateRef.current.dismissOnTouchEnd = true;\n }\n if (distance > 10) {\n closeOnPressOutside(event);\n cancelDismissOnEndTimeout.clear();\n touchStateRef.current = null;\n }\n }\n function handleTouchMoveCapture(event) {\n addTargetEventListenerOnce(event, handleTouchMove);\n }\n function handleTouchEnd(event) {\n if (getOutsidePressEvent() !== 'sloppy' || !touchStateRef.current || isEventWithinOwnElements(event)) {\n return;\n }\n if (touchStateRef.current.dismissOnTouchEnd) {\n closeOnPressOutside(event);\n }\n cancelDismissOnEndTimeout.clear();\n touchStateRef.current = null;\n }\n function handleTouchEndCapture(event) {\n addTargetEventListenerOnce(event, handleTouchEnd);\n }\n const doc = ownerDocument(floatingElement);\n const unsubscribe = mergeCleanups(escapeKey && mergeCleanups(addEventListener(doc, 'keydown', closeOnEscapeKeyDown), addEventListener(doc, 'compositionstart', handleCompositionStart), addEventListener(doc, 'compositionend', handleCompositionEnd)), outsidePressEnabled && mergeCleanups(addEventListener(doc, 'click', closeOnPressOutsideCapture, true), addEventListener(doc, 'pointerdown', closeOnPressOutsideCapture, true), addEventListener(doc, 'pointerup', handlePressEndCapture, true), addEventListener(doc, 'pointercancel', handlePressEndCapture, true), addEventListener(doc, 'mousedown', closeOnPressOutsideCapture, true), addEventListener(doc, 'mouseup', handlePressEndCapture, true), addEventListener(doc, 'touchstart', handleTouchStartCapture, true), addEventListener(doc, 'touchmove', handleTouchMoveCapture, true), addEventListener(doc, 'touchend', handleTouchEndCapture, true)));\n return () => {\n unsubscribe();\n compositionTimeout.clear();\n preventedPressSuppressionTimeout.clear();\n resetPressStartState();\n suppressNextOutsideClickRef.current = false;\n };\n }, [dataRef, floatingElement, escapeKey, outsidePressEnabled, outsidePress, open, enabled, escapeKeyBubbles, outsidePressBubbles, closeOnEscapeKeyDown, clearInsideReactTree, getOutsidePressEventProp, hasBlockingChild, isEventWithinOwnElements, tree, store, cancelDismissOnEndTimeout]);\n React.useEffect(clearInsideReactTree, [outsidePress, clearInsideReactTree]);\n const reference = React.useMemo(() => ({\n onKeyDown: closeOnEscapeKeyDown,\n onPointerDown: closeOnReferencePress,\n onClick: closeOnReferencePress\n }), [closeOnEscapeKeyDown, closeOnReferencePress]);\n const floating = React.useMemo(() => ({\n onKeyDown: closeOnEscapeKeyDown,\n // `onMouseDown` may be blocked if `event.preventDefault()` is called in\n // `onPointerDown`, such as with <NumberField.ScrubArea>.\n // See https://github.com/mui/base-ui/pull/3379\n onPointerDown: markInsidePressStartPrevented,\n onMouseDown: markInsidePressStartPrevented,\n onClickCapture: markInsideReactTree,\n onMouseDownCapture(event) {\n markInsideReactTree();\n markPressStartedInsideReactTree(event);\n },\n onPointerDownCapture(event) {\n markInsideReactTree();\n markPressStartedInsideReactTree(event);\n },\n onMouseUpCapture: markInsideReactTree,\n onTouchEndCapture: markInsideReactTree,\n onTouchMoveCapture: markInsideReactTree\n }), [closeOnEscapeKeyDown, markInsideReactTree, markPressStartedInsideReactTree, markInsidePressStartPrevented]);\n return React.useMemo(() => enabled ? {\n reference,\n floating,\n trigger: reference\n } : {}, [enabled, reference, floating]);\n}","'use client';\n\nimport * as React from 'react';\nimport { useIsoLayoutEffect } from '@base-ui/utils/useIsoLayoutEffect';\nimport { isElement } from '@floating-ui/utils/dom';\nimport { FloatingRootStore } from \"../components/FloatingRootStore.mjs\";\n/**\n * Keeps a FloatingRootStore in sync with the provided PopupStore.\n * Uses the provided FloatingRootStore when one exists, otherwise creates one once and updates it on every render.\n */\nexport function useSyncedFloatingRootContext(options) {\n const {\n popupStore,\n treatPopupAsFloatingElement = false,\n floatingRootContext: floatingRootContextProp,\n floatingId,\n nested,\n onOpenChange\n } = options;\n const open = popupStore.useState('open');\n const referenceElement = popupStore.useState('activeTriggerElement');\n const floatingElement = popupStore.useState(treatPopupAsFloatingElement ? 'popupElement' : 'positionerElement');\n const triggerElements = popupStore.context.triggerElements;\n const handleOpenChange = onOpenChange;\n const internalStoreRef = React.useRef(null);\n if (floatingRootContextProp === undefined && internalStoreRef.current === null) {\n internalStoreRef.current = new FloatingRootStore({\n open,\n transitionStatus: undefined,\n referenceElement,\n floatingElement,\n triggerElements,\n onOpenChange: handleOpenChange,\n floatingId,\n syncOnly: true,\n nested\n });\n }\n const store = floatingRootContextProp ?? internalStoreRef.current;\n popupStore.useSyncedValue('floatingId', floatingId);\n useIsoLayoutEffect(() => {\n const valuesToSync = {\n open,\n floatingId,\n referenceElement,\n floatingElement\n };\n if (isElement(referenceElement)) {\n valuesToSync.domReferenceElement = referenceElement;\n }\n if (store.state.positionReference === store.state.referenceElement) {\n valuesToSync.positionReference = referenceElement;\n }\n store.update(valuesToSync);\n }, [open, floatingId, referenceElement, floatingElement, store]);\n\n // Keep non-reactive context values fresh for interactions that call `store.setOpen`.\n store.context.onOpenChange = handleOpenChange;\n store.context.nested = nested;\n return store;\n}","import { isElement, isHTMLElement } from '@floating-ui/utils/dom';\nimport { platform } from '@base-ui/utils/platform';\nimport { FOCUSABLE_ATTRIBUTE, TYPEABLE_SELECTOR } from \"./constants.mjs\";\nimport { activeElement, contains, getTarget } from \"../../internals/shadowDom.mjs\";\nexport { activeElement, contains, getTarget };\nexport function isTargetInsideEnabledTrigger(target, triggerElements) {\n if (!isElement(target)) {\n return false;\n }\n const targetElement = target;\n if (triggerElements.hasElement(targetElement)) {\n return !targetElement.hasAttribute('data-trigger-disabled');\n }\n for (const [, trigger] of triggerElements.entries()) {\n if (contains(trigger, targetElement)) {\n return !trigger.hasAttribute('data-trigger-disabled');\n }\n }\n return false;\n}\nexport function isEventTargetWithin(event, node) {\n if (node == null) {\n return false;\n }\n if ('composedPath' in event) {\n return event.composedPath().includes(node);\n }\n\n // TS thinks `event` is of type never as it assumes all browsers support composedPath, but browsers without shadow dom don't\n const eventAgain = event;\n return eventAgain.target != null && node.contains(eventAgain.target);\n}\nexport function isRootElement(element) {\n return element.matches('html,body');\n}\nexport function isTypeableElement(element) {\n return isHTMLElement(element) && element.matches(TYPEABLE_SELECTOR);\n}\nexport function isInteractiveElement(element) {\n return element?.closest(`button,a[href],[role=\"button\"],select,[tabindex]:not([tabindex=\"-1\"]),${TYPEABLE_SELECTOR}`) != null;\n}\nexport function isTypeableCombobox(element) {\n if (!element) {\n return false;\n }\n return element.getAttribute('role') === 'combobox' && isTypeableElement(element);\n}\nexport function matchesFocusVisible(element) {\n // We don't want to block focus from working with `visibleOnly`\n // (JSDOM doesn't match `:focus-visible` when the element has `:focus`)\n if (!element || platform.env.jsdom) {\n return true;\n }\n try {\n return element.matches(':focus-visible');\n } catch (_e) {\n return true;\n }\n}\nexport function getFloatingFocusElement(floatingElement) {\n if (!floatingElement) {\n return null;\n }\n // Try to find the element that has `{...getFloatingProps()}` spread on it.\n // This indicates the floating element is acting as a positioning wrapper, and\n // so focus should be managed on the child element with the event handlers and\n // aria props.\n return floatingElement.hasAttribute(FOCUSABLE_ATTRIBUTE) ? floatingElement : floatingElement.querySelector(`[${FOCUSABLE_ATTRIBUTE}]`) || floatingElement;\n}","export const FOCUSABLE_ATTRIBUTE = 'data-base-ui-focusable';\nexport const ACTIVE_KEY = 'active';\nexport const SELECTED_KEY = 'selected';\nexport const TYPEABLE_SELECTOR = \"input:not([type='hidden']):not([disabled]),\" + \"[contenteditable]:not([contenteditable='false']),textarea:not([disabled])\";\nexport const ARROW_LEFT = 'ArrowLeft';\nexport const ARROW_RIGHT = 'ArrowRight';\nexport const ARROW_UP = 'ArrowUp';\nexport const ARROW_DOWN = 'ArrowDown';","import { platform } from '@base-ui/utils/platform';\nexport function stopEvent(event) {\n event.preventDefault();\n event.stopPropagation();\n}\nexport function isReactEvent(event) {\n return 'nativeEvent' in event;\n}\n\n// License: https://github.com/adobe/react-spectrum/blob/main/packages/@react-aria/utils/src/isVirtualEvent.ts\nexport function isVirtualClick(event) {\n if (event.pointerType === '' && event.isTrusted) {\n return true;\n }\n if (platform.os.android && event.pointerType) {\n return event.type === 'click' && event.buttons === 1;\n }\n return event.detail === 0 && !event.pointerType;\n}\nexport function isVirtualPointerEvent(event) {\n if (platform.env.jsdom) {\n return false;\n }\n return !platform.os.android && event.width === 0 && event.height === 0 || platform.os.android && event.width === 1 && event.height === 1 && event.pressure === 0 && event.detail === 0 && event.pointerType === 'mouse' ||\n // iOS VoiceOver returns 0.333• for width/height.\n event.width < 1 && event.height < 1 && event.pressure === 0 && event.detail === 0 && event.pointerType === 'touch';\n}\nexport function isMouseLikePointerType(pointerType, strict) {\n // On some Linux machines with Chromium, mouse inputs return a `pointerType`\n // of \"pen\": https://github.com/floating-ui/floating-ui/issues/2015\n const values = ['mouse', 'pen'];\n if (!strict) {\n values.push('', undefined);\n }\n return values.includes(pointerType);\n}\nexport function isClickLikeEvent(event) {\n const type = event.type;\n return type === 'click' || type === 'mousedown' || type === 'keydown' || type === 'keyup';\n}","/* eslint-disable @typescript-eslint/no-loop-func */\n\nexport function getNodeChildren(nodes, id, onlyOpenChildren = true) {\n const directChildren = nodes.filter(node => node.parentId === id);\n return directChildren.flatMap(child => [...(!onlyOpenChildren || child.context?.open ? [child] : []), ...getNodeChildren(nodes, child.id, onlyOpenChildren)]);\n}\nexport function getDeepestNode(nodes, id) {\n let deepestNodeId;\n let maxDepth = -1;\n function findDeepest(nodeId, depth) {\n if (depth > maxDepth) {\n deepestNodeId = nodeId;\n maxDepth = depth;\n }\n const children = getNodeChildren(nodes, nodeId);\n children.forEach(child => {\n findDeepest(child.id, depth + 1);\n });\n }\n findDeepest(id, 0);\n return nodes.find(node => node.id === deepestNodeId);\n}\nexport function getNodeAncestors(nodes, id) {\n let allAncestors = [];\n let currentParentId = nodes.find(node => node.id === id)?.parentId;\n while (currentParentId) {\n const currentNode = nodes.find(node => node.id === currentParentId);\n currentParentId = currentNode?.parentId;\n if (currentNode) {\n allAncestors = allAncestors.concat(currentNode);\n }\n }\n return allAncestors;\n}","import { getComputedStyle, getNodeName, isHTMLElement, isShadowRoot } from '@floating-ui/utils/dom';\nimport { ownerDocument } from '@base-ui/utils/owner';\nimport { activeElement, contains } from \"./element.mjs\";\nimport { isElementVisible } from \"./composite.mjs\";\nconst CANDIDATE_SELECTOR = 'a[href],button,input,select,textarea,summary,details,iframe,object,embed,[tabindex],[contenteditable]:not([contenteditable=\"false\"]),audio[controls],video[controls]';\nfunction getParentElement(element) {\n const assignedSlot = element.assignedSlot;\n if (assignedSlot) {\n return assignedSlot;\n }\n if (element.parentElement) {\n return element.parentElement;\n }\n const rootNode = element.getRootNode();\n return isShadowRoot(rootNode) ? rootNode.host : null;\n}\nfunction getDetailsSummary(details) {\n for (const child of Array.from(details.children)) {\n if (getNodeName(child) === 'summary') {\n return child;\n }\n }\n return null;\n}\nfunction isWithinOpenDetailsSummary(element, details) {\n const summary = getDetailsSummary(details);\n return !!summary && (element === summary || contains(summary, element));\n}\nfunction isFocusableCandidate(element) {\n const nodeName = element ? getNodeName(element) : '';\n return element != null && element.matches(CANDIDATE_SELECTOR) && (nodeName !== 'summary' || element.parentElement != null && getNodeName(element.parentElement) === 'details' && getDetailsSummary(element.parentElement) === element) && (nodeName !== 'details' || getDetailsSummary(element) == null) && (nodeName !== 'input' || element.type !== 'hidden');\n}\nfunction isFocusableElement(element) {\n if (!isFocusableCandidate(element) || !element.isConnected || element.matches(':disabled')) {\n return false;\n }\n for (let current = element; current; current = getParentElement(current)) {\n const isAncestor = current !== element;\n const isSlot = getNodeName(current) === 'slot';\n if (current.hasAttribute('inert')) {\n return false;\n }\n if (isAncestor && getNodeName(current) === 'details' && !current.open && !isWithinOpenDetailsSummary(element, current) || current.hasAttribute('hidden') || !isSlot && !isVisibleInTabbableTree(current, isAncestor)) {\n return false;\n }\n }\n return true;\n}\nfunction isVisibleInTabbableTree(element, isAncestor) {\n const styles = getComputedStyle(element);\n if (!isAncestor) {\n return isElementVisible(element, styles);\n }\n return styles.display !== 'none';\n}\nfunction getTabIndex(element) {\n const tabIndex = element.tabIndex;\n if (tabIndex < 0) {\n const nodeName = getNodeName(element);\n if (nodeName === 'details' || nodeName === 'audio' || nodeName === 'video' || isHTMLElement(element) && element.isContentEditable) {\n return 0;\n }\n }\n return tabIndex;\n}\nfunction getNamedRadioInput(element) {\n if (getNodeName(element) !== 'input') {\n return null;\n }\n const input = element;\n return input.type === 'radio' && input.name !== '' ? input : null;\n}\nfunction isTabbableRadio(element, candidates) {\n const input = getNamedRadioInput(element);\n if (!input) {\n return true;\n }\n const checkedRadio = candidates.find(candidate => {\n const radio = getNamedRadioInput(candidate);\n return radio?.name === input.name && radio.form === input.form && radio.checked;\n });\n if (checkedRadio) {\n return checkedRadio === input;\n }\n return candidates.find(candidate => {\n const radio = getNamedRadioInput(candidate);\n return radio?.name === input.name && radio.form === input.form;\n }) === input;\n}\nfunction getComposedChildren(container) {\n if (isHTMLElement(container) && getNodeName(container) === 'slot') {\n const assignedElements = container.assignedElements({\n flatten: true\n });\n if (assignedElements.length > 0) {\n return assignedElements;\n }\n }\n if (isHTMLElement(container) && container.shadowRoot) {\n return Array.from(container.shadowRoot.children);\n }\n return Array.from(container.children);\n}\nfunction appendCandidates(container, list) {\n getComposedChildren(container).forEach(child => {\n if (isFocusableCandidate(child)) {\n list.push(child);\n }\n appendCandidates(child, list);\n });\n}\nfunction appendMatchingElements(container, selector, list) {\n getComposedChildren(container).forEach(child => {\n if (isHTMLElement(child) && child.matches(selector)) {\n list.push(child);\n }\n appendMatchingElements(child, selector, list);\n });\n}\nexport function isTabbable(element) {\n return isFocusableElement(element) && getTabIndex(element) >= 0;\n}\nexport function focusable(container) {\n const candidates = [];\n appendCandidates(container, candidates);\n return candidates.filter(isFocusableElement);\n}\nexport function tabbable(container) {\n const candidates = focusable(container);\n return candidates.filter(element => getTabIndex(element) >= 0 && isTabbableRadio(element, candidates));\n}\nfunction getTabbableIn(container, dir) {\n const list = tabbable(container);\n const len = list.length;\n if (len === 0) {\n return undefined;\n }\n const active = activeElement(ownerDocument(container));\n const index = list.indexOf(active);\n // eslint-disable-next-line no-nested-ternary\n const nextIndex = index === -1 ? dir === 1 ? 0 : len - 1 : index + dir;\n return list[nextIndex];\n}\nexport function getNextTabbable(referenceElement) {\n return getTabbableIn(ownerDocument(referenceElement).body, 1) || referenceElement;\n}\nexport function getPreviousTabbable(referenceElement) {\n return getTabbableIn(ownerDocument(referenceElement).body, -1) || referenceElement;\n}\nfunction getTabbableNearElement(referenceElement, dir) {\n if (!referenceElement) {\n return null;\n }\n const list = tabbable(ownerDocument(referenceElement).body);\n const elementCount = list.length;\n if (elementCount === 0) {\n return null;\n }\n const index = list.indexOf(referenceElement);\n if (index === -1) {\n return null;\n }\n const nextIndex = (index + dir + elementCount) % elementCount;\n return list[nextIndex];\n}\nexport function getTabbableAfterElement(referenceElement) {\n return getTabbableNearElement(referenceElement, 1);\n}\nexport function getTabbableBeforeElement(referenceElement) {\n return getTabbableNearElement(referenceElement, -1);\n}\nexport function isOutsideEvent(event, container) {\n const containerElement = container || event.currentTarget;\n const relatedTarget = event.relatedTarget;\n return !relatedTarget || !contains(containerElement, relatedTarget);\n}\nexport function disableFocusInside(container) {\n const tabbableElements = tabbable(container);\n tabbableElements.forEach(element => {\n element.dataset.tabindex = element.getAttribute('tabindex') || '';\n element.setAttribute('tabindex', '-1');\n });\n}\nexport function enableFocusInside(container) {\n const elements = [];\n appendMatchingElements(container, '[data-tabindex]', elements);\n elements.forEach(element => {\n const tabindex = element.dataset.tabindex;\n delete element.dataset.tabindex;\n if (tabindex) {\n element.setAttribute('tabindex', tabindex);\n } else {\n element.removeAttribute('tabindex');\n }\n });\n}","import { floor } from '@floating-ui/utils';\nimport { getComputedStyle } from '@floating-ui/utils/dom';\nimport { stopEvent } from \"./event.mjs\";\nimport { ARROW_DOWN, ARROW_LEFT, ARROW_RIGHT, ARROW_UP } from \"./constants.mjs\";\nexport function isDifferentGridRow(index, cols, prevRow) {\n return Math.floor(index / cols) !== prevRow;\n}\nexport function isIndexOutOfListBounds(list, index) {\n return index < 0 || index >= list.length;\n}\nexport function getMinListIndex(listRef, disabledIndices) {\n return findNonDisabledListIndex(listRef.current, {\n disabledIndices\n });\n}\nexport function getMaxListIndex(listRef, disabledIndices) {\n return findNonDisabledListIndex(listRef.current, {\n decrement: true,\n startingIndex: listRef.current.length,\n disabledIndices\n });\n}\nexport function findNonDisabledListIndex(list, {\n startingIndex = -1,\n decrement = false,\n disabledIndices,\n amount = 1\n} = {}) {\n let index = startingIndex;\n do {\n index += decrement ? -amount : amount;\n } while (index >= 0 && index <= list.length - 1 && isListIndexDisabled(list, index, disabledIndices));\n return index;\n}\nexport function getGridNavigatedIndex(list, {\n event,\n orientation,\n loopFocus,\n onLoop,\n rtl,\n cols,\n disabledIndices,\n minIndex,\n maxIndex,\n prevIndex,\n stopEvent: stop = false\n}) {\n let nextIndex = prevIndex;\n let verticalDirection;\n if (event.key === ARROW_UP) {\n verticalDirection = 'up';\n } else if (event.key === ARROW_DOWN) {\n verticalDirection = 'down';\n }\n if (verticalDirection) {\n // -------------------------------------------------------------------------\n // Detect row structure only when handling vertical navigation. This keeps\n // the non-vertical key paths free from row inference work.\n // -------------------------------------------------------------------------\n const rows = [];\n const rowIndexMap = [];\n let hasRoleRow = false;\n let visibleItemCount = 0;\n {\n let currentRowEl = null;\n let currentRowIndex = -1;\n list.forEach((el, idx) => {\n if (el == null) {\n return;\n }\n visibleItemCount += 1;\n const rowEl = el.closest('[role=\"row\"]');\n if (rowEl) {\n hasRoleRow = true;\n }\n if (rowEl !== currentRowEl || currentRowIndex === -1) {\n currentRowEl = rowEl;\n currentRowIndex += 1;\n rows[currentRowIndex] = [];\n }\n rows[currentRowIndex].push(idx);\n rowIndexMap[idx] = currentRowIndex;\n });\n }\n let hasDomRows = false;\n let inferredDomCols = 0;\n if (hasRoleRow) {\n for (const row of rows) {\n const rowLength = row.length;\n if (rowLength > inferredDomCols) {\n inferredDomCols = rowLength;\n }\n if (rowLength !== cols) {\n hasDomRows = true;\n }\n }\n }\n const hasVirtualizedGaps = hasDomRows && visibleItemCount < list.length;\n const verticalCols = inferredDomCols || cols;\n const navigateVertically = direction => {\n if (!hasDomRows || prevIndex === -1) {\n return undefined;\n }\n const currentRow = rowIndexMap[prevIndex];\n if (currentRow == null) {\n return undefined;\n }\n const colInRow = rows[currentRow].indexOf(prevIndex);\n const step = direction === 'up' ? -1 : 1;\n for (let nextRow = currentRow + step, i = 0; i < rows.length; i += 1, nextRow += step) {\n if (nextRow < 0 || nextRow >= rows.length) {\n if (!loopFocus || hasVirtualizedGaps) {\n return undefined;\n }\n nextRow = nextRow < 0 ? rows.length - 1 : 0;\n if (onLoop) {\n const clampedCol = Math.min(colInRow, rows[nextRow].length - 1);\n const targetItemIndex = rows[nextRow][clampedCol] ?? rows[nextRow][0];\n const returnedItemIndex = onLoop(event, prevIndex, targetItemIndex);\n nextRow = rowIndexMap[returnedItemIndex] ?? nextRow;\n }\n }\n const targetRow = rows[nextRow];\n for (let col = Math.min(colInRow, targetRow.length - 1); col >= 0; col -= 1) {\n const candidate = targetRow[col];\n if (!isListIndexDisabled(list, candidate, disabledIndices)) {\n return candidate;\n }\n }\n }\n return undefined;\n };\n const navigateVerticallyWithInferredRows = direction => {\n if (!hasVirtualizedGaps || prevIndex === -1) {\n return undefined;\n }\n const colInRow = prevIndex % verticalCols;\n const rowStep = direction === 'up' ? -verticalCols : verticalCols;\n const lastRowStart = maxIndex - maxIndex % verticalCols;\n const rowCount = floor(maxIndex / verticalCols) + 1;\n for (let rowStart = prevIndex - colInRow + rowStep, i = 0; i < rowCount; i += 1, rowStart += rowStep) {\n if (rowStart < 0 || rowStart > maxIndex) {\n if (!loopFocus) {\n return undefined;\n }\n rowStart = rowStart < 0 ? lastRowStart : 0;\n }\n const rowEnd = Math.min(rowStart + verticalCols - 1, maxIndex);\n for (let candidate = Math.min(rowStart + colInRow, rowEnd); candidate >= rowStart; candidate -= 1) {\n if (!isListIndexDisabled(list, candidate, disabledIndices)) {\n return candidate;\n }\n }\n }\n return undefined;\n };\n if (stop) {\n stopEvent(event);\n }\n const verticalCandidate = navigateVertically(verticalDirection) ?? navigateVerticallyWithInferredRows(verticalDirection);\n if (verticalCandidate !== undefined) {\n nextIndex = verticalCandidate;\n } else if (prevIndex === -1) {\n nextIndex = verticalDirection === 'up' ? maxIndex : minIndex;\n } else {\n nextIndex = findNonDisabledListIndex(list, {\n startingIndex: prevIndex,\n amount: verticalCols,\n decrement: verticalDirection === 'up',\n disabledIndices\n });\n if (loopFocus) {\n if (verticalDirection === 'up' && (prevIndex - verticalCols < minIndex || nextIndex < 0)) {\n const col = prevIndex % verticalCols;\n const maxCol = maxIndex % verticalCols;\n const offset = maxIndex - (maxCol - col);\n if (maxCol === col) {\n nextIndex = maxIndex;\n } else {\n nextIndex = maxCol > col ? offset : offset - verticalCols;\n }\n if (onLoop) {\n nextIndex = onLoop(event, prevIndex, nextIndex);\n }\n }\n if (verticalDirection === 'down' && prevIndex + verticalCols > maxIndex) {\n nextIndex = findNonDisabledListIndex(list, {\n startingIndex: prevIndex % verticalCols - verticalCols,\n amount: verticalCols,\n disabledIndices\n });\n if (onLoop) {\n nextIndex = onLoop(event, prevIndex, nextIndex);\n }\n }\n }\n }\n if (isIndexOutOfListBounds(list, nextIndex)) {\n nextIndex = prevIndex;\n }\n }\n\n // Remains on the same row/column.\n if (orientation === 'both') {\n const prevRow = floor(prevIndex / cols);\n if (event.key === (rtl ? ARROW_LEFT : ARROW_RIGHT)) {\n if (stop) {\n stopEvent(event);\n }\n if (prevIndex % cols !== cols - 1) {\n nextIndex = findNonDisabledListIndex(list, {\n startingIndex: prevIndex,\n disabledIndices\n });\n if (loopFocus && isDifferentGridRow(nextIndex, cols, prevRow)) {\n nextIndex = findNonDisabledListIndex(list, {\n startingIndex: prevIndex - prevIndex % cols - 1,\n disabledIndices\n });\n if (onLoop) {\n nextIndex = onLoop(event, prevIndex, nextIndex);\n }\n }\n } else if (loopFocus) {\n nextIndex = findNonDisabledListIndex(list, {\n startingIndex: prevIndex - prevIndex % cols - 1,\n disabledIndices\n });\n if (onLoop) {\n nextIndex = onLoop(event, prevIndex, nextIndex);\n }\n }\n if (isDifferentGridRow(nextIndex, cols, prevRow)) {\n nextIndex = prevIndex;\n }\n }\n if (event.key === (rtl ? ARROW_RIGHT : ARROW_LEFT)) {\n if (stop) {\n stopEvent(event);\n }\n if (prevIndex % cols !== 0) {\n nextIndex = findNonDisabledListIndex(list, {\n startingIndex: prevIndex,\n decrement: true,\n disabledIndices\n });\n if (loopFocus && isDifferentGridRow(nextIndex, cols, prevRow)) {\n nextIndex = findNonDisabledListIndex(list, {\n startingIndex: prevIndex + (cols - prevIndex % cols),\n decrement: true,\n disabledIndices\n });\n if (onLoop) {\n nextIndex = onLoop(event, prevIndex, nextIndex);\n }\n }\n } else if (loopFocus) {\n nextIndex = findNonDisabledListIndex(list, {\n startingIndex: prevIndex + (cols - prevIndex % cols),\n decrement: true,\n disabledIndices\n });\n if (onLoop) {\n nextIndex = onLoop(event, prevIndex, nextIndex);\n }\n }\n if (isDifferentGridRow(nextIndex, cols, prevRow)) {\n nextIndex = prevIndex;\n }\n }\n const lastRow = floor(maxIndex / cols) === prevRow;\n if (isIndexOutOfListBounds(list, nextIndex)) {\n if (loopFocus && lastRow) {\n nextIndex = event.key === (rtl ? ARROW_RIGHT : ARROW_LEFT) ? maxIndex : findNonDisabledListIndex(list, {\n startingIndex: prevIndex - prevIndex % cols - 1,\n disabledIndices\n });\n if (onLoop) {\n nextIndex = onLoop(event, prevIndex, nextIndex);\n }\n } else {\n nextIndex = prevIndex;\n }\n }\n }\n return nextIndex;\n}\n\n/** For each cell index, gets the item index that occupies that cell */\nexport function createGridCellMap(sizes, cols, dense) {\n const cellMap = [];\n let startIndex = 0;\n sizes.forEach(({\n width,\n height\n }, index) => {\n if (width > cols) {\n if (process.env.NODE_ENV !== 'production') {\n // TODO: fix mui/no-guarded-throw\n // eslint-disable-next-line mui/no-guarded-throw\n throw new Error(`[Floating UI]: Invalid grid - item width at index ${index} is greater than grid columns`);\n }\n }\n let itemPlaced = false;\n if (dense) {\n startIndex = 0;\n }\n while (!itemPlaced) {\n const targetCells = [];\n for (let i = 0; i < width; i += 1) {\n for (let j = 0; j < height; j += 1) {\n targetCells.push(startIndex + i + j * cols);\n }\n }\n if (startIndex % cols + width <= cols && targetCells.every(cell => cellMap[cell] == null)) {\n targetCells.forEach(cell => {\n cellMap[cell] = index;\n });\n itemPlaced = true;\n } else {\n startIndex += 1;\n }\n }\n });\n\n // convert into a non-sparse array\n return [...cellMap];\n}\n\n/** Gets cell index of an item's corner or -1 when index is -1. */\nexport function getGridCellIndexOfCorner(index, sizes, cellMap, cols, corner) {\n if (index === -1) {\n return -1;\n }\n const firstCellIndex = cellMap.indexOf(index);\n const sizeItem = sizes[index];\n switch (corner) {\n case 'tl':\n return firstCellIndex;\n case 'tr':\n if (!sizeItem) {\n return firstCellIndex;\n }\n return firstCellIndex + sizeItem.width - 1;\n case 'bl':\n if (!sizeItem) {\n return firstCellIndex;\n }\n return firstCellIndex + (sizeItem.height - 1) * cols;\n case 'br':\n return cellMap.lastIndexOf(index);\n default:\n return -1;\n }\n}\n\n/** Gets all cell indices that correspond to the specified indices */\nexport function getGridCellIndices(indices, cellMap) {\n return cellMap.flatMap((index, cellIndex) => indices.includes(index) ? [cellIndex] : []);\n}\nexport function isListIndexDisabled(list, index, disabledIndices) {\n const isExplicitlyDisabled = typeof disabledIndices === 'function' ? disabledIndices(index) : disabledIndices?.includes(index) ?? false;\n if (isExplicitlyDisabled) {\n return true;\n }\n const element = list[index];\n if (!element) {\n return false;\n }\n if (!isElementVisible(element)) {\n return true;\n }\n return !disabledIndices && (element.hasAttribute('disabled') || element.getAttribute('aria-disabled') === 'true');\n}\nexport function isHiddenByStyles(styles) {\n return styles.visibility === 'hidden' || styles.visibility === 'collapse';\n}\nexport function isElementVisible(element, styles = element ? getComputedStyle(element) : null) {\n if (!element || !element.isConnected || !styles || isHiddenByStyles(styles)) {\n return false;\n }\n if (typeof element.checkVisibility === 'function') {\n return element.checkVisibility();\n }\n return styles.display !== 'none' && styles.display !== 'contents';\n}","import { EMPTY_OBJECT } from '@base-ui/utils/empty';\nimport { REASONS } from \"./reasons.mjs\";\n\n/**\n * Maps a change `reason` string to the corresponding native event type.\n */\n\n/**\n * Details of custom change events emitted by Base UI components.\n */\n\n/**\n * Details of custom generic events emitted by Base UI components.\n */\n\n/**\n * Creates a Base UI event details object with the given reason and utilities\n * for preventing Base UI's internal event handling.\n */\nexport function createChangeEventDetails(reason, event, trigger, customProperties) {\n let canceled = false;\n let allowPropagation = false;\n const custom = customProperties ?? EMPTY_OBJECT;\n const details = {\n reason,\n event: event ?? new Event('base-ui'),\n cancel() {\n canceled = true;\n },\n allowPropagation() {\n allowPropagation = true;\n },\n get isCanceled() {\n return canceled;\n },\n get isPropagationAllowed() {\n return allowPropagation;\n },\n trigger,\n ...custom\n };\n return details;\n}\nexport function createGenericEventDetails(reason, event, customProperties) {\n const custom = customProperties ?? EMPTY_OBJECT;\n const details = {\n reason,\n event: event ?? new Event('base-ui'),\n ...custom\n };\n return details;\n}","export function getStateAttributesProps(state, customMapping) {\n const props = {};\n\n /* eslint-disable-next-line guard-for-in */\n for (const key in state) {\n const value = state[key];\n if (customMapping?.hasOwnProperty(key)) {\n const customProps = customMapping[key](value);\n if (customProps != null) {\n Object.assign(props, customProps);\n }\n continue;\n }\n if (value === true) {\n props[`data-${key.toLowerCase()}`] = '';\n } else if (value) {\n props[`data-${key.toLowerCase()}`] = value.toString();\n }\n }\n return props;\n}","/**\n * If the provided className is a string, it will be returned as is.\n * Otherwise, the function will call the className function with the state as the first argument.\n *\n * @param className\n * @param state\n */\nexport function resolveClassName(className, state) {\n return typeof className === 'function' ? className(state) : className;\n}","/**\n * If the provided style is an object, it will be returned as is.\n * Otherwise, the function will call the style function with the state as the first argument.\n *\n * @param style\n * @param state\n */\nexport function resolveStyle(style, state) {\n return typeof style === 'function' ? style(state) : style;\n}","export const none = 'none';\nexport const triggerPress = 'trigger-press';\nexport const triggerHover = 'trigger-hover';\nexport const triggerFocus = 'trigger-focus';\nexport const outsidePress = 'outside-press';\nexport const itemPress = 'item-press';\nexport const closePress = 'close-press';\nexport const linkPress = 'link-press';\nexport const clearPress = 'clear-press';\nexport const chipRemovePress = 'chip-remove-press';\nexport const trackPress = 'track-press';\nexport const incrementPress = 'increment-press';\nexport const decrementPress = 'decrement-press';\nexport const inputChange = 'input-change';\nexport const inputClear = 'input-clear';\nexport const inputBlur = 'input-blur';\nexport const inputPaste = 'input-paste';\nexport const inputPress = 'input-press';\nexport const focusOut = 'focus-out';\nexport const escapeKey = 'escape-key';\nexport const closeWatcher = 'close-watcher';\nexport const listNavigation = 'list-navigation';\nexport const keyboard = 'keyboard';\nexport const pointer = 'pointer';\nexport const drag = 'drag';\nexport const wheel = 'wheel';\nexport const scrub = 'scrub';\nexport const cancelOpen = 'cancel-open';\nexport const siblingOpen = 'sibling-open';\nexport const disabled = 'disabled';\nexport const missing = 'missing';\nexport const initial = 'initial';\nexport const imperativeAction = 'imperative-action';\nexport const swipe = 'swipe';\nexport const windowResize = 'window-resize';","export function createAttribute(name) {\n return `data-base-ui-${name}`;\n}","import { isShadowRoot } from '@floating-ui/utils/dom';\nexport function activeElement(doc) {\n let element = doc.activeElement;\n while (element?.shadowRoot?.activeElement != null) {\n element = element.shadowRoot.activeElement;\n }\n return element;\n}\nexport function contains(parent, child) {\n if (!parent || !child) {\n return false;\n }\n const rootNode = child.getRootNode?.();\n\n // First, attempt with the faster native method.\n if (parent.contains(child)) {\n return true;\n }\n\n // Then fall back to traversing out of shadow roots when needed.\n if (rootNode && isShadowRoot(rootNode)) {\n let next = child;\n while (next) {\n if (parent === next) {\n return true;\n }\n next = next.parentNode || next.host;\n }\n }\n return false;\n}\nexport function getTarget(event) {\n if ('composedPath' in event) {\n return event.composedPath()[0];\n }\n\n // TS assumes `composedPath()` always exists, but older browsers without\n // shadow DOM support still fall back to `target`.\n return event.target;\n}","export let TransitionStatusDataAttributes = /*#__PURE__*/function (TransitionStatusDataAttributes) {\n /**\n * Present when the component is animating in.\n */\n TransitionStatusDataAttributes[\"startingStyle\"] = \"data-starting-style\";\n /**\n * Present when the component is animating out.\n */\n TransitionStatusDataAttributes[\"endingStyle\"] = \"data-ending-style\";\n return TransitionStatusDataAttributes;\n}({});\nconst STARTING_HOOK = {\n [TransitionStatusDataAttributes.startingStyle]: ''\n};\nconst ENDING_HOOK = {\n [TransitionStatusDataAttributes.endingStyle]: ''\n};\nexport const transitionStatusMapping = {\n transitionStatus(value) {\n if (value === 'starting') {\n return STARTING_HOOK;\n }\n if (value === 'ending') {\n return ENDING_HOOK;\n }\n return null;\n }\n};","'use client';\n\nimport { useId } from '@base-ui/utils/useId';\n\n/**\n * Wraps `useId` and prefixes generated `id`s with `base-ui-`\n * @param {string | undefined} idOverride overrides the generated id when provided\n * @returns {string | undefined}\n */\nexport function useBaseUiId(idOverride) {\n return useId(idOverride, 'base-ui');\n}","'use client';\n\nimport * as React from 'react';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nimport { useAnimationsFinished } from \"./useAnimationsFinished.mjs\";\n\n/**\n * Calls the provided function when the CSS open/close animation or transition completes.\n */\nexport function useOpenChangeComplete(parameters) {\n const {\n enabled = true,\n open,\n ref,\n onComplete: onCompleteParam\n } = parameters;\n const onComplete = useStableCallback(onCompleteParam);\n const runOnceAnimationsFinish = useAnimationsFinished(ref, open, false);\n React.useEffect(() => {\n if (!enabled) {\n return undefined;\n }\n const abortController = new AbortController();\n runOnceAnimationsFinish(onComplete, abortController.signal);\n return () => {\n abortController.abort();\n };\n }, [enabled, open, onComplete, runOnceAnimationsFinish]);\n}","'use client';\n\nimport * as ReactDOM from 'react-dom';\nimport { useAnimationFrame } from '@base-ui/utils/useAnimationFrame';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nimport { resolveRef } from \"../utils/resolveRef.mjs\";\nimport { TransitionStatusDataAttributes } from \"./stateAttributesMapping.mjs\";\n\n/**\n * Executes a function once all animations have finished on the provided element.\n * @param elementOrRef - The element to watch for animations.\n * @param waitForStartingStyleRemoved - Whether to wait for [data-starting-style] to be removed before checking for animations.\n * @param treatAbortedAsFinished - Whether to treat aborted animations as finished. If `false`, and there are aborted animations,\n * the function will check again if any new animations have started and wait for them to finish.\n * @returns A function that takes a callback to execute once all animations have finished, and an optional AbortSignal to abort the callback\n */\nexport function useAnimationsFinished(elementOrRef, waitForStartingStyleRemoved = false, treatAbortedAsFinished = true) {\n const frame = useAnimationFrame();\n return useStableCallback((fnToExecute,\n /**\n * An optional [AbortSignal](https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal) that\n * can be used to abort `fnToExecute` before all the animations have finished.\n * @default null\n */\n signal = null) => {\n frame.cancel();\n const element = resolveRef(elementOrRef);\n if (element == null) {\n return;\n }\n const resolvedElement = element;\n const done = () => {\n // Synchronously flush the unmounting of the component so that the browser doesn't\n // paint: https://github.com/mui/base-ui/issues/979\n ReactDOM.flushSync(fnToExecute);\n };\n if (typeof resolvedElement.getAnimations !== 'function' || globalThis.BASE_UI_ANIMATIONS_DISABLED) {\n fnToExecute();\n return;\n }\n function exec() {\n Promise.all(resolvedElement.getAnimations().map(animation => animation.finished)).then(() => {\n if (!signal?.aborted) {\n done();\n }\n }).catch(() => {\n if (treatAbortedAsFinished) {\n if (!signal?.aborted) {\n done();\n }\n return;\n }\n const currentAnimations = resolvedElement.getAnimations();\n if (!signal?.aborted && currentAnimations.length > 0 && currentAnimations.some(animation => animation.pending || animation.playState !== 'finished')) {\n // Sometimes animations can be aborted because a property they depend on changes while the animation plays.\n // In such cases, we need to re-check if any new animations have started.\n exec();\n }\n });\n }\n if (waitForStartingStyleRemoved) {\n const startingStyleAttribute = TransitionStatusDataAttributes.startingStyle;\n\n // If `[data-starting-style]` isn't present, fall back to waiting one more frame\n // to give \"open\" animations a chance to be registered.\n if (!resolvedElement.hasAttribute(startingStyleAttribute)) {\n frame.request(exec);\n return;\n }\n\n // Wait for `[data-starting-style]` to have been removed.\n const attributeObserver = new MutationObserver(() => {\n if (!resolvedElement.hasAttribute(startingStyleAttribute)) {\n attributeObserver.disconnect();\n exec();\n }\n });\n attributeObserver.observe(resolvedElement, {\n attributes: true,\n attributeFilter: [startingStyleAttribute]\n });\n signal?.addEventListener('abort', () => attributeObserver.disconnect(), {\n once: true\n });\n return;\n }\n frame.request(exec);\n });\n}","import _formatErrorMessage from \"@base-ui/utils/formatErrorMessage\";\nimport * as React from 'react';\nimport { useMergedRefs, useMergedRefsN } from '@base-ui/utils/useMergedRefs';\nimport { getReactElementRef } from '@base-ui/utils/getReactElementRef';\nimport { mergeObjects } from '@base-ui/utils/mergeObjects';\nimport { warn } from '@base-ui/utils/warn';\nimport { EMPTY_OBJECT } from '@base-ui/utils/empty';\nimport { getStateAttributesProps } from \"./getStateAttributesProps.mjs\";\nimport { resolveClassName } from \"../utils/resolveClassName.mjs\";\nimport { resolveStyle } from \"../utils/resolveStyle.mjs\";\nimport { mergeProps, mergePropsN, mergeClassNames } from \"../merge-props/index.mjs\";\nimport { createElement as _createElement } from \"react\";\n/**\n * Renders a Base UI element.\n *\n * @param element The default HTML element to render. Can be overridden by the `render` prop.\n * @param componentProps An object containing the `render` and `className` props to be used for element customization. Other props are ignored.\n * @param params Additional parameters for rendering the element.\n */\nexport function useRenderElement(element, componentProps, params = {}) {\n const renderProp = componentProps.render;\n const outProps = useRenderElementProps(componentProps, params);\n if (params.enabled === false) {\n return null;\n }\n const state = params.state ?? EMPTY_OBJECT;\n return evaluateRenderProp(element, renderProp, outProps, state);\n}\n\n/**\n * Computes render element final props.\n */\nfunction useRenderElementProps(componentProps, params = {}) {\n const {\n className: classNameProp,\n style: styleProp,\n render: renderProp\n } = componentProps;\n const {\n state = EMPTY_OBJECT,\n ref,\n props,\n stateAttributesMapping,\n enabled = true\n } = params;\n const className = enabled ? resolveClassName(classNameProp, state) : undefined;\n const style = enabled ? resolveStyle(styleProp, state) : undefined;\n const stateProps = enabled ? getStateAttributesProps(state, stateAttributesMapping) : EMPTY_OBJECT;\n const resolvedProps = enabled && props ? resolveRenderFunctionProps(props) : undefined;\n\n // Ensure outProps is always a new mutable object when enabled, never EMPTY_OBJECT.\n // This prevents potential TypeError when setting ref, className, or style properties,\n // since EMPTY_OBJECT is frozen and mutations would fail in strict mode.\n const outProps = enabled ? mergeObjects(stateProps, resolvedProps) ?? {} : EMPTY_OBJECT;\n\n // SAFETY: The `useMergedRefs` functions use a single hook to store the same value,\n // switching between them at runtime is safe. If this assertion fails, React will\n // throw at runtime anyway.\n // This also skips the `useMergedRefs` call on the server, which is fine because\n // refs are not used on the server side.\n /* eslint-disable react-hooks/rules-of-hooks */\n if (typeof document !== 'undefined') {\n if (!enabled) {\n useMergedRefs(null, null);\n } else if (Array.isArray(ref)) {\n outProps.ref = useMergedRefsN([outProps.ref, getReactElementRef(renderProp), ...ref]);\n } else {\n outProps.ref = useMergedRefs(outProps.ref, getReactElementRef(renderProp), ref);\n }\n }\n if (!enabled) {\n return EMPTY_OBJECT;\n }\n if (className !== undefined) {\n outProps.className = mergeClassNames(outProps.className, className);\n }\n if (style !== undefined) {\n outProps.style = mergeObjects(outProps.style, style);\n }\n return outProps;\n}\nfunction resolveRenderFunctionProps(props) {\n if (Array.isArray(props)) {\n return mergePropsN(props);\n }\n return mergeProps(undefined, props);\n}\n\n// The symbol React uses internally for lazy components\n// https://github.com/facebook/react/blob/a0566250b210499b4c5677f5ac2eedbd71d51a1b/packages/shared/ReactSymbols.js#L31\n//\n// TODO delete once https://github.com/facebook/react/issues/32392 is fixed\nconst REACT_LAZY_TYPE = Symbol.for('react.lazy');\nconst COMPONENT_IDENTIFIER_PATTERN = /^[A-Z][A-Za-z0-9$]*$/;\nconst LOWERCASE_CHARACTER_PATTERN = /[a-z]/;\nfunction evaluateRenderProp(element, render, props, state) {\n if (render) {\n if (typeof render === 'function') {\n if (process.env.NODE_ENV !== 'production') {\n warnIfRenderPropLooksLikeComponent(render);\n }\n return render(props, state);\n }\n const mergedProps = mergeProps(props, render.props);\n mergedProps.ref = props.ref;\n let newElement = render;\n\n // Workaround for https://github.com/facebook/react/issues/32392\n // This works because the toArray() logic unwrap lazy element type in\n // https://github.com/facebook/react/blob/a0566250b210499b4c5677f5ac2eedbd71d51a1b/packages/react/src/ReactChildren.js#L186\n if (newElement?.$$typeof === REACT_LAZY_TYPE) {\n const children = React.Children.toArray(render);\n newElement = children[0];\n }\n\n // There is a high number of indirections, the error message thrown by React.cloneElement() is\n // hard to use for developers, this logic provides a better context.\n //\n // Our general guideline is to never change the control flow depending on the environment.\n // However, React.cloneElement() throws if React.isValidElement() is false,\n // so we can throw before with custom message.\n if (process.env.NODE_ENV !== 'production') {\n if (! /*#__PURE__*/React.isValidElement(newElement)) {\n // TODO: fix mui/no-guarded-throw\n // eslint-disable-next-line mui/no-guarded-throw\n throw new Error(['Base UI: The `render` prop was provided an invalid React element as `React.isValidElement(render)` is `false`.', 'A valid React element must be provided to the `render` prop because it is cloned with props to replace the default element.', 'https://base-ui.com/r/invalid-render-prop'].join('\\n'));\n }\n }\n return /*#__PURE__*/React.cloneElement(newElement, mergedProps);\n }\n if (element) {\n if (typeof element === 'string') {\n return renderTag(element, props);\n }\n }\n // Unreachable, but the typings on `useRenderElement` need to be reworked\n // to annotate it correctly.\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'Base UI: Render element or function are not defined.' : _formatErrorMessage(8));\n}\nfunction warnIfRenderPropLooksLikeComponent(renderFn) {\n const functionName = renderFn.name;\n if (functionName.length === 0) {\n return;\n }\n if (!COMPONENT_IDENTIFIER_PATTERN.test(functionName)) {\n return;\n }\n if (!LOWERCASE_CHARACTER_PATTERN.test(functionName)) {\n return;\n }\n warn(`The \\`render\\` prop received a function named \\`${functionName}\\` that starts with an uppercase letter.`, 'This usually means a React component was passed directly as `render={Component}`.', 'Base UI calls `render` as a plain function, which can break the Rules of Hooks during reconciliation.', 'If this is an intentional render callback, rename it to start with a lowercase letter.', 'Use `render={<Component />}` or `render={(props) => <Component {...props} />}` instead.', 'https://base-ui.com/r/invalid-render-prop');\n}\nfunction renderTag(Tag, props) {\n if (Tag === 'button') {\n return /*#__PURE__*/_createElement(\"button\", {\n type: \"button\",\n ...props,\n key: props.key\n });\n }\n if (Tag === 'img') {\n return /*#__PURE__*/_createElement(\"img\", {\n alt: \"\",\n ...props,\n key: props.key\n });\n }\n return /*#__PURE__*/React.createElement(Tag, props);\n}","'use client';\n\nimport * as React from 'react';\nimport { useIsoLayoutEffect } from '@base-ui/utils/useIsoLayoutEffect';\nimport { AnimationFrame } from '@base-ui/utils/useAnimationFrame';\n/**\n * Provides a status string for CSS animations.\n * @param open - a boolean that determines if the element is open.\n * @param enableIdleState - a boolean that enables the `'idle'` state between `'starting'` and `'ending'`\n */\nexport function useTransitionStatus(open, enableIdleState = false, deferEndingState = false) {\n const [transitionStatus, setTransitionStatus] = React.useState(open && enableIdleState ? 'idle' : undefined);\n const [mounted, setMounted] = React.useState(open);\n if (open && !mounted) {\n setMounted(true);\n setTransitionStatus('starting');\n }\n if (!open && mounted && transitionStatus !== 'ending' && !deferEndingState) {\n setTransitionStatus('ending');\n }\n if (!open && !mounted && transitionStatus === 'ending') {\n setTransitionStatus(undefined);\n }\n useIsoLayoutEffect(() => {\n if (!open && mounted && transitionStatus !== 'ending' && deferEndingState) {\n const frame = AnimationFrame.request(() => {\n setTransitionStatus('ending');\n });\n return () => {\n AnimationFrame.cancel(frame);\n };\n }\n return undefined;\n }, [open, mounted, transitionStatus, deferEndingState]);\n useIsoLayoutEffect(() => {\n if (!open || enableIdleState) {\n return undefined;\n }\n const frame = AnimationFrame.request(() => {\n // Avoid `flushSync` here due to Firefox.\n // See https://github.com/mui/base-ui/pull/3424\n setTransitionStatus(undefined);\n });\n return () => {\n AnimationFrame.cancel(frame);\n };\n }, [enableIdleState, open]);\n useIsoLayoutEffect(() => {\n if (!open || !enableIdleState) {\n return undefined;\n }\n if (open && mounted && transitionStatus !== 'idle') {\n setTransitionStatus('starting');\n }\n const frame = AnimationFrame.request(() => {\n setTransitionStatus('idle');\n });\n return () => {\n AnimationFrame.cancel(frame);\n };\n }, [enableIdleState, open, mounted, transitionStatus]);\n return {\n mounted,\n setMounted,\n transitionStatus\n };\n}","import { mergeObjects } from '@base-ui/utils/mergeObjects';\nconst EMPTY_PROPS = {};\n\n/* eslint-disable id-denylist */\n/**\n * Merges multiple sets of React props. It follows the Object.assign pattern where the rightmost object's fields overwrite\n * the conflicting ones from others. This doesn't apply to event handlers, `className` and `style` props.\n *\n * Event handlers are merged and called in right-to-left order (rightmost handler executes first, leftmost last).\n * For React synthetic events, the rightmost handler can prevent prior (left-positioned) handlers from executing\n * by calling `event.preventBaseUIHandler()`. For non-synthetic events (custom events with primitive/object values),\n * all handlers always execute without prevention capability.\n *\n * The `className` prop is merged by concatenating classes in right-to-left order (rightmost class appears first in the string).\n * The `style` prop is merged with rightmost styles overwriting the prior ones.\n *\n * Props can either be provided as objects or as functions that take the previous props as an argument.\n * The function will receive the merged props up to that point (going from left to right):\n * so in the case of `(obj1, obj2, fn, obj3)`, `fn` will receive the merged props of `obj1` and `obj2`.\n * The function is responsible for chaining event handlers if needed (that is, we don't run the merge logic).\n *\n * Event handlers returned by the functions are not automatically prevented when `preventBaseUIHandler` is called.\n * They must check `event.baseUIHandlerPrevented` themselves and bail out if it's true.\n *\n * @important **`ref` is not merged.**\n * @param a Props object to merge.\n * @param b Props object to merge. The function will overwrite conflicting props from `a`.\n * @param c Props object to merge. The function will overwrite conflicting props from previous parameters.\n * @param d Props object to merge. The function will overwrite conflicting props from previous parameters.\n * @param e Props object to merge. The function will overwrite conflicting props from previous parameters.\n * @returns The merged props.\n * @public\n */\n\nexport function mergeProps(a, b, c, d, e) {\n if (!c && !d && !e && !a) {\n return createInitialMergedProps(b);\n }\n\n // We need to mutably own `merged`.\n let merged = createInitialMergedProps(a);\n if (b) {\n merged = mergeInto(merged, b);\n }\n if (c) {\n merged = mergeInto(merged, c);\n }\n if (d) {\n merged = mergeInto(merged, d);\n }\n if (e) {\n merged = mergeInto(merged, e);\n }\n return merged;\n}\n/* eslint-enable id-denylist */\n\n/**\n * Merges an arbitrary number of React props using the same logic as {@link mergeProps}.\n * This function accepts an array of props instead of individual arguments.\n *\n * This has slightly lower performance than {@link mergeProps} due to accepting an array\n * instead of a fixed number of arguments. Prefer {@link mergeProps} when merging 5 or\n * fewer prop sets for better performance.\n *\n * @param props Array of props to merge.\n * @returns The merged props.\n * @see mergeProps\n * @public\n */\nexport function mergePropsN(props) {\n if (props.length === 0) {\n return EMPTY_PROPS;\n }\n if (props.length === 1) {\n return createInitialMergedProps(props[0]);\n }\n\n // We need to mutably own `merged`.\n let merged = createInitialMergedProps(props[0]);\n for (let i = 1; i < props.length; i += 1) {\n merged = mergeInto(merged, props[i]);\n }\n return merged;\n}\nfunction createInitialMergedProps(inputProps) {\n if (isPropsGetter(inputProps)) {\n // Getter-returned handlers intentionally keep their existing semantics.\n return {\n ...resolvePropsGetter(inputProps, EMPTY_PROPS)\n };\n }\n return copyInitialProps(inputProps);\n}\nfunction mergeInto(merged, inputProps) {\n if (isPropsGetter(inputProps)) {\n return resolvePropsGetter(inputProps, merged);\n }\n return mutablyMergeInto(merged, inputProps);\n}\nfunction copyInitialProps(inputProps) {\n const copiedProps = {\n ...inputProps\n };\n\n // `copiedProps` is our fresh own-object copy, so iterating with `for...in` is safe here.\n // eslint-disable-next-line guard-for-in\n for (const propName in copiedProps) {\n const propValue = copiedProps[propName];\n if (isEventHandler(propName, propValue)) {\n copiedProps[propName] = wrapEventHandler(propValue);\n }\n }\n return copiedProps;\n}\n\n/**\n * Merges two sets of props. In case of conflicts, the external props take precedence.\n */\nfunction mutablyMergeInto(mergedProps, externalProps) {\n if (!externalProps) {\n return mergedProps;\n }\n\n // eslint-disable-next-line guard-for-in\n for (const propName in externalProps) {\n const externalPropValue = externalProps[propName];\n switch (propName) {\n case 'style':\n {\n mergedProps[propName] = mergeObjects(mergedProps.style, externalPropValue);\n break;\n }\n case 'className':\n {\n mergedProps[propName] = mergeClassNames(mergedProps.className, externalPropValue);\n break;\n }\n default:\n {\n if (isEventHandler(propName, externalPropValue)) {\n mergedProps[propName] = mergeEventHandlers(mergedProps[propName], externalPropValue);\n } else {\n mergedProps[propName] = externalPropValue;\n }\n }\n }\n }\n return mergedProps;\n}\nfunction isEventHandler(key, value) {\n // This approach is more efficient than using a regex.\n const code0 = key.charCodeAt(0);\n const code1 = key.charCodeAt(1);\n const code2 = key.charCodeAt(2);\n return code0 === 111 /* o */ && code1 === 110 /* n */ && code2 >= 65 /* A */ && code2 <= 90 /* Z */ && (typeof value === 'function' || typeof value === 'undefined');\n}\nfunction isPropsGetter(inputProps) {\n return typeof inputProps === 'function';\n}\nfunction resolvePropsGetter(inputProps, previousProps) {\n if (isPropsGetter(inputProps)) {\n return inputProps(previousProps);\n }\n return inputProps ?? EMPTY_PROPS;\n}\nfunction mergeEventHandlers(ourHandler, theirHandler) {\n if (!theirHandler) {\n return ourHandler;\n }\n if (!ourHandler) {\n return wrapEventHandler(theirHandler);\n }\n return (...args) => {\n const event = args[0];\n if (isSyntheticEvent(event)) {\n const baseUIEvent = event;\n makeEventPreventable(baseUIEvent);\n const result = theirHandler(...args);\n if (!baseUIEvent.baseUIHandlerPrevented) {\n ourHandler?.(...args);\n }\n return result;\n }\n const result = theirHandler(...args);\n ourHandler?.(...args);\n return result;\n };\n}\nfunction wrapEventHandler(handler) {\n if (!handler) {\n return handler;\n }\n return (...args) => {\n const event = args[0];\n if (isSyntheticEvent(event)) {\n makeEventPreventable(event);\n }\n return handler(...args);\n };\n}\nexport function makeEventPreventable(event) {\n event.preventBaseUIHandler = () => {\n event.baseUIHandlerPrevented = true;\n };\n return event;\n}\nexport function mergeClassNames(ourClassName, theirClassName) {\n if (theirClassName) {\n if (ourClassName) {\n // eslint-disable-next-line prefer-template\n return theirClassName + ' ' + ourClassName;\n }\n return theirClassName;\n }\n return ourClassName;\n}\nfunction isSyntheticEvent(event) {\n return event != null && typeof event === 'object' && 'nativeEvent' in event;\n}","'use client';\n\nimport * as React from 'react';\nimport { useIsoLayoutEffect } from '@base-ui/utils/useIsoLayoutEffect';\nimport { platform } from '@base-ui/utils/platform';\nimport { visuallyHidden } from '@base-ui/utils/visuallyHidden';\n\n/**\n * @internal\n */\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nexport const FocusGuard = /*#__PURE__*/React.forwardRef(function FocusGuard(props, ref) {\n const [role, setRole] = React.useState();\n useIsoLayoutEffect(() => {\n // Unlike NVDA and JAWS, VoiceOver's virtual cursor triggers `onFocus` as\n // it moves — but only on focusable/role-button elements through WebKit's\n // NSAccessibility path. Setting `role=\"button\"` lets the focus trap catch\n // the cursor.\n if (platform.screenReader.voiceOver && platform.engine.webkit) {\n setRole('button');\n }\n }, []);\n const restProps = {\n tabIndex: 0,\n // Role is only for VoiceOver\n role\n };\n return /*#__PURE__*/_jsx(\"span\", {\n ...props,\n ref: ref,\n style: visuallyHidden,\n \"aria-hidden\": role ? undefined : true,\n ...restProps,\n \"data-base-ui-focus-guard\": \"\"\n });\n});\nif (process.env.NODE_ENV !== \"production\") FocusGuard.displayName = \"FocusGuard\";","const visuallyHiddenBase = {\n clipPath: 'inset(50%)',\n overflow: 'hidden',\n whiteSpace: 'nowrap',\n border: 0,\n padding: 0,\n width: 1,\n height: 1,\n margin: -1\n};\nexport const visuallyHidden = {\n ...visuallyHiddenBase,\n position: 'fixed',\n top: 0,\n left: 0\n};\nexport const visuallyHiddenInput = {\n ...visuallyHiddenBase,\n position: 'absolute'\n};","import { TransitionStatusDataAttributes } from \"../internals/stateAttributesMapping.mjs\";\nexport let CommonPopupDataAttributes = function (CommonPopupDataAttributes) {\n /**\n * Present when the popup is open.\n */\n CommonPopupDataAttributes[\"open\"] = \"data-open\";\n /**\n * Present when the popup is closed.\n */\n CommonPopupDataAttributes[\"closed\"] = \"data-closed\";\n /**\n * Present when the popup is animating in.\n */\n CommonPopupDataAttributes[CommonPopupDataAttributes[\"startingStyle\"] = TransitionStatusDataAttributes.startingStyle] = \"startingStyle\";\n /**\n * Present when the popup is animating out.\n */\n CommonPopupDataAttributes[CommonPopupDataAttributes[\"endingStyle\"] = TransitionStatusDataAttributes.endingStyle] = \"endingStyle\";\n /**\n * Present when the anchor is hidden.\n */\n CommonPopupDataAttributes[\"anchorHidden\"] = \"data-anchor-hidden\";\n /**\n * Indicates which side the popup is positioned relative to the trigger.\n * @type { 'top' | 'bottom' | 'left' | 'right' | 'inline-end' | 'inline-start'}\n */\n CommonPopupDataAttributes[\"side\"] = \"data-side\";\n /**\n * Indicates how the popup is aligned relative to specified side.\n * @type {'start' | 'center' | 'end'}\n */\n CommonPopupDataAttributes[\"align\"] = \"data-align\";\n return CommonPopupDataAttributes;\n}({});\nexport let CommonTriggerDataAttributes = /*#__PURE__*/function (CommonTriggerDataAttributes) {\n /**\n * Present when the popup is open.\n */\n CommonTriggerDataAttributes[\"popupOpen\"] = \"data-popup-open\";\n /**\n * Present when a pressable trigger is pressed.\n */\n CommonTriggerDataAttributes[\"pressed\"] = \"data-pressed\";\n return CommonTriggerDataAttributes;\n}({});\nconst TRIGGER_HOOK = {\n [CommonTriggerDataAttributes.popupOpen]: ''\n};\nconst PRESSABLE_TRIGGER_HOOK = {\n [CommonTriggerDataAttributes.popupOpen]: '',\n [CommonTriggerDataAttributes.pressed]: ''\n};\nconst POPUP_OPEN_HOOK = {\n [CommonPopupDataAttributes.open]: ''\n};\nconst POPUP_CLOSED_HOOK = {\n [CommonPopupDataAttributes.closed]: ''\n};\nconst ANCHOR_HIDDEN_HOOK = {\n [CommonPopupDataAttributes.anchorHidden]: ''\n};\nexport const triggerOpenStateMapping = {\n open(value) {\n if (value) {\n return TRIGGER_HOOK;\n }\n return null;\n }\n};\nexport const pressableTriggerOpenStateMapping = {\n open(value) {\n if (value) {\n return PRESSABLE_TRIGGER_HOOK;\n }\n return null;\n }\n};\nexport const popupStateMapping = {\n open(value) {\n if (value) {\n return POPUP_OPEN_HOOK;\n }\n return POPUP_CLOSED_HOOK;\n },\n anchorHidden(value) {\n if (value) {\n return ANCHOR_HIDDEN_HOOK;\n }\n return null;\n }\n};","'use client';\n\nimport * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport { EMPTY_OBJECT } from '@base-ui/utils/empty';\nimport { useId } from '@base-ui/utils/useId';\nimport { useStableCallback } from '@base-ui/utils/useStableCallback';\nimport { useIsoLayoutEffect } from '@base-ui/utils/useIsoLayoutEffect';\nimport { useOnFirstRender } from '@base-ui/utils/useOnFirstRender';\nimport { FOCUSABLE_ATTRIBUTE } from \"../../floating-ui-react/utils/constants.mjs\";\nimport { useFloatingParentNodeId } from \"../../floating-ui-react/components/FloatingTree.mjs\";\nimport { useSyncedFloatingRootContext } from \"../../floating-ui-react/hooks/useSyncedFloatingRootContext.mjs\";\nimport { useTransitionStatus } from \"../../internals/useTransitionStatus.mjs\";\nimport { useOpenChangeComplete } from \"../../internals/useOpenChangeComplete.mjs\";\nimport { createChangeEventDetails } from \"../../internals/createBaseUIEventDetails.mjs\";\nimport { REASONS } from \"../../internals/reasons.mjs\";\nexport const FOCUSABLE_POPUP_PROPS = {\n tabIndex: -1,\n [FOCUSABLE_ATTRIBUTE]: ''\n};\n\n/**\n * Returns the default `initialFocus` resolver for a popup. When opened by touch it focuses the\n * popup element itself to prevent the virtual keyboard from opening (required for Android\n * specifically; iOS handles this automatically). Otherwise it falls back to the default behavior.\n */\nexport function createDefaultInitialFocus(popupRef) {\n return interactionType => interactionType === 'touch' ? popupRef.current : true;\n}\nexport function usePopupStore(externalStore, createStore, treatPopupAsFloatingElement = false) {\n const floatingId = useId();\n const nested = useFloatingParentNodeId() != null;\n const internalStoreRef = React.useRef(null);\n if (externalStore === undefined && internalStoreRef.current === null) {\n internalStoreRef.current = createStore(floatingId, nested);\n }\n const store = externalStore ?? internalStoreRef.current;\n useSyncedFloatingRootContext({\n popupStore: store,\n treatPopupAsFloatingElement,\n floatingRootContext: store.state.floatingRootContext,\n floatingId,\n nested,\n onOpenChange: store.setOpen\n });\n return {\n store,\n internalStore: internalStoreRef.current\n };\n}\n\n/**\n * Returns a callback ref that registers/unregisters the trigger element in the store.\n *\n * @param store The Store instance where the trigger should be registered.\n */\nexport function useTriggerRegistration(id, store) {\n // Keep track of the currently registered element to unregister it on unmount or id change.\n const registeredElementIdRef = React.useRef(null);\n const registeredElementRef = React.useRef(null);\n return React.useCallback(element => {\n if (id === undefined) {\n return;\n }\n let shouldSyncTriggerCount = false;\n if (registeredElementIdRef.current !== null) {\n const registeredId = registeredElementIdRef.current;\n const registeredElement = registeredElementRef.current;\n const currentElement = store.context.triggerElements.getById(registeredId);\n if (registeredElement && currentElement === registeredElement) {\n store.context.triggerElements.delete(registeredId);\n shouldSyncTriggerCount = true;\n }\n registeredElementIdRef.current = null;\n registeredElementRef.current = null;\n }\n if (element !== null) {\n registeredElementIdRef.current = id;\n registeredElementRef.current = element;\n store.context.triggerElements.add(id, element);\n shouldSyncTriggerCount = true;\n }\n if (shouldSyncTriggerCount) {\n const triggerCount = store.context.triggerElements.size;\n if (store.select('open') && store.state.triggerCount !== triggerCount) {\n store.set('triggerCount', triggerCount);\n }\n }\n }, [store, id]);\n}\nexport function setPopupOpenState(state, open, trigger, preventUnmountOnClose = false) {\n if (open) {\n // Opening starts a new close cycle, so clear any previous request to keep the popup mounted.\n state.preventUnmountingOnClose = false;\n } else if (preventUnmountOnClose) {\n state.preventUnmountingOnClose = true;\n }\n const triggerId = trigger?.id ?? null;\n\n // If a popup is closing, the `trigger` may be undefined.\n // We want to keep the previous value so that exit animations are played and focus is returned correctly.\n if (triggerId || open) {\n state.activeTriggerId = triggerId;\n state.activeTriggerElement = trigger ?? null;\n }\n}\nexport function attachPreventUnmountOnClose(eventDetails) {\n let preventUnmountOnClose = false;\n eventDetails.preventUnmountOnClose = () => {\n preventUnmountOnClose = true;\n };\n return () => preventUnmountOnClose;\n}\n\n/**\n * Runs the shared open-change sequence for a popup store: notifies `onOpenChange`,\n * honors cancellation, dispatches the floating root change, maps the reason to an\n * `instantType`, and commits the state update (synchronously for hover so\n * `getAnimations()` observes it). Stores supply their own differences via\n * `extraState` (e.g. the last change reason) and `onBeforeDispatch` (e.g. updating\n * inline-rect coordinates).\n */\nexport function applyPopupOpenChange(store, nextOpen, eventDetails, options = {}) {\n const reason = eventDetails.reason;\n const isHover = reason === REASONS.triggerHover;\n const isFocusOpen = nextOpen && reason === REASONS.triggerFocus;\n const isDismissClose = !nextOpen && (reason === REASONS.triggerPress || reason === REASONS.escapeKey);\n const shouldPreventUnmountOnClose = attachPreventUnmountOnClose(eventDetails);\n store.context.onOpenChange?.(nextOpen, eventDetails);\n if (eventDetails.isCanceled) {\n return;\n }\n options.onBeforeDispatch?.();\n store.state.floatingRootContext.dispatchOpenChange(nextOpen, eventDetails);\n const changeState = () => {\n // Spread `extraState` first so `open` always reflects `nextOpen`, keeping it in\n // sync with the value already passed to `dispatchOpenChange`/`setPopupOpenState`.\n const updatedState = {\n ...options.extraState,\n open: nextOpen\n };\n if (isFocusOpen) {\n updatedState.instantType = 'focus';\n } else if (isDismissClose) {\n updatedState.instantType = 'dismiss';\n } else if (isHover) {\n updatedState.instantType = undefined;\n }\n setPopupOpenState(updatedState, nextOpen, eventDetails.trigger, shouldPreventUnmountOnClose());\n store.update(updatedState);\n };\n if (isHover) {\n // Flush synchronously for hover so `node.getAnimations()` sees the new state.\n ReactDOM.flushSync(changeState);\n } else {\n changeState();\n }\n}\nexport function useInitialOpenSync(store, openProp, defaultOpen, defaultTriggerId) {\n useOnFirstRender(() => {\n if (openProp === undefined && store.state.open === false && defaultOpen) {\n // Avoid notifying detached trigger subscribers while the Root is rendering.\n store.state = {\n ...store.state,\n open: true,\n activeTriggerId: defaultTriggerId,\n preventUnmountingOnClose: false\n };\n }\n });\n}\n\n/**\n * Sets up trigger data forwarding to the store.\n *\n * @param triggerId Id of the trigger.\n * @param triggerElementRef Ref for the trigger DOM element.\n * @param store The Store instance managing the popup state.\n * @param stateUpdates An object with state updates to apply when the trigger is active.\n */\nexport function useTriggerDataForwarding(triggerId, triggerElementRef, store, stateUpdates) {\n const isMountedByThisTrigger = store.useState('isMountedByTrigger', triggerId);\n const baseRegisterTrigger = useTriggerRegistration(triggerId, store);\n const registerTrigger = useStableCallback(element => {\n baseRegisterTrigger(element);\n if (!element) {\n return;\n }\n const open = store.select('open');\n const activeTriggerId = store.select('activeTriggerId');\n if (activeTriggerId === triggerId) {\n store.update({\n activeTriggerElement: element,\n ...(open ? stateUpdates : null)\n });\n return;\n }\n if (activeTriggerId == null && open) {\n // If a popup is already open, a detached trigger can mount before any active trigger\n // has been established. Claim the first registered trigger so trigger-owned focus\n // management and ARIA relationships work.\n store.update({\n activeTriggerId: triggerId,\n activeTriggerElement: element,\n ...stateUpdates\n });\n }\n });\n useIsoLayoutEffect(() => {\n if (isMountedByThisTrigger) {\n store.update({\n activeTriggerElement: triggerElementRef.current,\n ...stateUpdates\n });\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [isMountedByThisTrigger, store, triggerElementRef, ...Object.values(stateUpdates)]);\n return {\n registerTrigger,\n isMountedByThisTrigger\n };\n}\n/**\n * Keeps trigger registration state synchronized while the popup is open.\n *\n * When a popup opens without an explicit trigger id and exactly one trigger is registered, that\n * trigger is claimed as the active trigger. When the active trigger id is still registered but its\n * element changed, the active element is refreshed. When the active trigger unregisters, the\n * default path preserves existing ownership so non-closing popup families do not silently claim a\n * different trigger while staying open.\n *\n * If `closeOnActiveTriggerUnmount` is enabled, unregistering the active trigger requests a close\n * after a microtask so a same-tick replacement trigger with the same id can register first.\n *\n * This should be called on the Root part.\n *\n * @param store The Store instance managing the popup state.\n * @param options Options for active trigger unmount behavior.\n */\nexport function useImplicitActiveTrigger(store, options = {}) {\n const {\n closeOnActiveTriggerUnmount = false\n } = options;\n const open = store.useState('open');\n const reactiveTriggerCount = store.useState('triggerCount');\n useIsoLayoutEffect(() => {\n if (!open) {\n if (store.state.triggerCount !== 0) {\n store.set('triggerCount', 0);\n }\n return;\n }\n const triggerCount = store.context.triggerElements.size;\n const stateUpdates = {};\n if (store.state.triggerCount !== triggerCount) {\n stateUpdates.triggerCount = triggerCount;\n }\n const activeTriggerId = store.select('activeTriggerId');\n let lostActiveTriggerId = null;\n if (activeTriggerId) {\n const activeTriggerElement = store.context.triggerElements.getById(activeTriggerId);\n if (!activeTriggerElement) {\n lostActiveTriggerId = activeTriggerId;\n } else if (activeTriggerElement !== store.state.activeTriggerElement) {\n stateUpdates.activeTriggerElement = activeTriggerElement;\n }\n }\n if (!lostActiveTriggerId && !activeTriggerId && triggerCount === 1) {\n const iteratorResult = store.context.triggerElements.entries().next();\n if (!iteratorResult.done) {\n const [implicitTriggerId, implicitTriggerElement] = iteratorResult.value;\n stateUpdates.activeTriggerId = implicitTriggerId;\n stateUpdates.activeTriggerElement = implicitTriggerElement;\n }\n }\n if (stateUpdates.triggerCount !== undefined || stateUpdates.activeTriggerId !== undefined || stateUpdates.activeTriggerElement !== undefined) {\n store.update(stateUpdates);\n }\n if (lostActiveTriggerId) {\n if (closeOnActiveTriggerUnmount) {\n // Defer so a same-tick replacement trigger with the same id can register first.\n queueMicrotask(() => {\n if (store.select('open') && store.select('activeTriggerId') === lostActiveTriggerId && !store.context.triggerElements.getById(lostActiveTriggerId)) {\n const eventDetails = createChangeEventDetails(REASONS.none);\n store.setOpen(false, eventDetails);\n // If closing is canceled, keep the previous active trigger ownership for the\n // still-open popup instead of claiming another trigger implicitly.\n if (!eventDetails.isCanceled) {\n store.update({\n activeTriggerId: null,\n activeTriggerElement: null\n });\n }\n }\n });\n }\n }\n }, [open, store, reactiveTriggerCount, closeOnActiveTriggerUnmount]);\n}\n\n/**\n * Manages the mounted state of the popup.\n * Sets up the transition status listeners and handles unmounting when needed.\n * Updates the `mounted`, `transitionStatus`, and `preventUnmountingOnClose` states in the store.\n *\n * @param open Whether the popup is open.\n * @param store The Store instance managing the popup state.\n * @param onUnmount Optional callback to be called when the popup is unmounted.\n *\n * @returns A function to forcibly unmount the popup.\n */\nexport function useOpenStateTransitions(open, store, onUnmount) {\n const {\n mounted,\n setMounted,\n transitionStatus\n } = useTransitionStatus(open);\n const preventUnmountingOnClose = store.useState('preventUnmountingOnClose');\n // Opening starts a new close cycle. Clear during render so the close-completion hook below\n // reads the synchronized value on the same pass.\n const syncedPreventUnmountingOnClose = open ? false : preventUnmountingOnClose;\n store.useSyncedValues({\n mounted,\n transitionStatus,\n preventUnmountingOnClose: syncedPreventUnmountingOnClose\n });\n const forceUnmount = useStableCallback(() => {\n setMounted(false);\n store.update({\n activeTriggerId: null,\n activeTriggerElement: null,\n mounted: false,\n preventUnmountingOnClose: false\n });\n onUnmount?.();\n store.context.onOpenChangeComplete?.(false);\n });\n useOpenChangeComplete({\n enabled: mounted && !open && !syncedPreventUnmountingOnClose,\n open,\n ref: store.context.popupRef,\n onComplete() {\n if (!open) {\n forceUnmount();\n }\n }\n });\n return {\n forceUnmount,\n transitionStatus\n };\n}\nexport function usePopupInteractionProps(store, statePart) {\n store.useSyncedValues(statePart);\n useIsoLayoutEffect(() => () => {\n store.update({\n activeTriggerProps: EMPTY_OBJECT,\n inactiveTriggerProps: EMPTY_OBJECT,\n popupProps: EMPTY_OBJECT\n });\n }, [store]);\n}\nexport function usePopupRootSync(store, open) {\n useIsoLayoutEffect(() => {\n if (!open && store.state.openMethod !== null) {\n store.set('openMethod', null);\n }\n }, [open, store]);\n useIsoLayoutEffect(() => () => {\n if (store.state.openMethod !== null) {\n store.set('openMethod', null);\n }\n }, [store]);\n}","/**\n * Data structure to keep track of popup trigger elements by their IDs.\n * Uses both a set of Elements and a map of IDs to Elements for efficient lookups.\n */\nexport class PopupTriggerMap {\n constructor() {\n this.elementsSet = new Set();\n this.idMap = new Map();\n }\n\n /**\n * Adds a trigger element with the given ID.\n *\n * Note: The provided element is assumed to not be registered under multiple IDs.\n */\n add(id, element) {\n const existingElement = this.idMap.get(id);\n if (existingElement === element) {\n return;\n }\n if (existingElement !== undefined) {\n // We assume that the same element won't be registered under multiple ids.\n // This is safe considering how useTriggerRegistration is implemented.\n this.elementsSet.delete(existingElement);\n }\n this.elementsSet.add(element);\n this.idMap.set(id, element);\n if (process.env.NODE_ENV !== 'production') {\n if (this.elementsSet.size !== this.idMap.size) {\n // TODO: fix mui/no-guarded-throw\n // eslint-disable-next-line mui/no-guarded-throw\n throw new Error('Base UI: A trigger element cannot be registered under multiple IDs in PopupTriggerMap.');\n }\n }\n }\n\n /**\n * Removes the trigger element with the given ID.\n */\n delete(id) {\n const element = this.idMap.get(id);\n if (element) {\n this.elementsSet.delete(element);\n this.idMap.delete(id);\n }\n }\n\n /**\n * Whether the given element is registered as a trigger.\n */\n hasElement(element) {\n return this.elementsSet.has(element);\n }\n\n /**\n * Whether there is a registered trigger element matching the given predicate.\n */\n hasMatchingElement(predicate) {\n for (const element of this.elementsSet) {\n if (predicate(element)) {\n return true;\n }\n }\n return false;\n }\n\n /**\n * Returns the trigger element associated with the given ID, or undefined if no such element exists.\n */\n getById(id) {\n return this.idMap.get(id);\n }\n\n /**\n * Returns an iterable of all registered trigger entries, where each entry is a tuple of [id, element].\n */\n entries() {\n return this.idMap.entries();\n }\n\n /**\n * Returns an iterable of all registered trigger elements.\n */\n elements() {\n return this.elementsSet.values();\n }\n\n /**\n * Returns the number of registered trigger elements.\n */\n get size() {\n return this.idMap.size;\n }\n}","import { createSelector } from '@base-ui/utils/store';\nimport { EMPTY_OBJECT } from '@base-ui/utils/empty';\nimport { FloatingRootStore } from \"../../floating-ui-react/components/FloatingRootStore.mjs\";\nimport { getEmptyRootContext } from \"../../floating-ui-react/utils/getEmptyRootContext.mjs\";\n\n/**\n * State common to all popup stores.\n */\n\nexport function createInitialPopupStoreState() {\n return {\n open: false,\n openProp: undefined,\n mounted: false,\n transitionStatus: undefined,\n floatingRootContext: getEmptyRootContext(),\n floatingId: undefined,\n triggerCount: 0,\n preventUnmountingOnClose: false,\n payload: undefined,\n activeTriggerId: null,\n activeTriggerElement: null,\n triggerIdProp: undefined,\n popupElement: null,\n positionerElement: null,\n activeTriggerProps: EMPTY_OBJECT,\n inactiveTriggerProps: EMPTY_OBJECT,\n popupProps: EMPTY_OBJECT\n };\n}\nexport function createPopupFloatingRootContext(triggerElements, floatingId, nested = false) {\n return new FloatingRootStore({\n open: false,\n transitionStatus: undefined,\n floatingElement: null,\n referenceElement: null,\n triggerElements,\n floatingId,\n syncOnly: true,\n nested,\n onOpenChange: undefined\n });\n}\nconst activeTriggerIdSelector = createSelector(state => state.triggerIdProp ?? state.activeTriggerId);\nconst openSelector = createSelector(state => state.openProp ?? state.open);\nconst popupIdSelector = createSelector(state => {\n const popupId = state.popupElement?.id ?? state.floatingId;\n return popupId || undefined;\n});\nfunction triggerOwnsOpenPopup(state, triggerId) {\n return triggerId !== undefined && openSelector(state) && activeTriggerIdSelector(state) === triggerId;\n}\nfunction triggerOwnsOpenPopupOrIsOnlyTrigger(state, triggerId) {\n if (triggerOwnsOpenPopup(state, triggerId)) {\n return true;\n }\n return triggerId !== undefined && openSelector(state) && activeTriggerIdSelector(state) == null && state.triggerCount === 1;\n}\nexport const popupStoreSelectors = {\n open: openSelector,\n mounted: createSelector(state => state.mounted),\n transitionStatus: createSelector(state => state.transitionStatus),\n floatingRootContext: createSelector(state => state.floatingRootContext),\n triggerCount: createSelector(state => state.triggerCount),\n preventUnmountingOnClose: createSelector(state => state.preventUnmountingOnClose),\n payload: createSelector(state => state.payload),\n activeTriggerId: activeTriggerIdSelector,\n activeTriggerElement: createSelector(state => state.mounted ? state.activeTriggerElement : null),\n popupId: popupIdSelector,\n /**\n * Whether the trigger with the given ID was used to open the popup.\n */\n isTriggerActive: createSelector((state, triggerId) => triggerId !== undefined && activeTriggerIdSelector(state) === triggerId),\n /**\n * Whether the popup is open and was activated by a trigger with the given ID.\n */\n isOpenedByTrigger: createSelector((state, triggerId) => triggerOwnsOpenPopup(state, triggerId)),\n /**\n * Whether the popup is mounted and was activated by a trigger with the given ID.\n */\n isMountedByTrigger: createSelector((state, triggerId) => triggerId !== undefined && activeTriggerIdSelector(state) === triggerId && state.mounted),\n triggerProps: createSelector((state, isActive) => isActive ? state.activeTriggerProps : state.inactiveTriggerProps),\n /**\n * Popup id for the trigger that currently owns the open popup.\n */\n triggerPopupId: createSelector((state, triggerId) => triggerOwnsOpenPopupOrIsOnlyTrigger(state, triggerId) ? popupIdSelector(state) : undefined),\n popupProps: createSelector(state => state.popupProps),\n popupElement: createSelector(state => state.popupElement),\n positionerElement: createSelector(state => state.positionerElement)\n};","import { PopupTriggerMap } from \"../../utils/popups/index.mjs\";\nimport { FloatingRootStore } from \"../components/FloatingRootStore.mjs\";\nexport function getEmptyRootContext() {\n return new FloatingRootStore({\n open: false,\n transitionStatus: undefined,\n floatingElement: null,\n referenceElement: null,\n triggerElements: new PopupTriggerMap(),\n floatingId: undefined,\n syncOnly: false,\n nested: false,\n onOpenChange: undefined\n });\n}","/**\n * If the provided argument is a ref object, returns its `current` value.\n * Otherwise, returns the argument itself.\n */\nexport function resolveRef(maybeRef) {\n if (maybeRef == null) {\n return maybeRef;\n }\n return 'current' in maybeRef ? maybeRef.current : maybeRef;\n}","/**\n * Adds an event listener and returns a cleanup function to remove it.\n */\n\nexport function addEventListener(target, type, listener, options) {\n target.addEventListener(type, listener, options);\n return () => {\n target.removeEventListener(type, listener, options);\n };\n}","export function NOOP() {}\nexport const EMPTY_ARRAY = Object.freeze([]);\nexport const EMPTY_OBJECT = Object.freeze({});","import * as React from 'react';\nimport { useRefWithInit } from \"./useRefWithInit.mjs\";\nconst hooks = [];\nlet currentInstance = undefined;\nexport function getInstance() {\n return currentInstance;\n}\nexport function setInstance(instance) {\n currentInstance = instance;\n}\nexport function register(hook) {\n hooks.push(hook);\n}\nexport function fastComponent(fn) {\n const FastComponent = (props, forwardedRef) => {\n const instance = useRefWithInit(createInstance).current;\n let result;\n try {\n currentInstance = instance;\n for (const hook of hooks) {\n hook.before(instance);\n }\n result = fn(props, forwardedRef);\n for (const hook of hooks) {\n hook.after(instance);\n }\n instance.didInitialize = true;\n } finally {\n currentInstance = undefined;\n }\n return result;\n };\n FastComponent.displayName = fn.displayName || fn.name;\n return FastComponent;\n}\nexport function fastComponentRef(fn) {\n return /*#__PURE__*/React.forwardRef(fastComponent(fn));\n}\nfunction createInstance() {\n return {\n didInitialize: false\n };\n}","/**\n * Creates a formatErrorMessage function with a custom URL and prefix.\n * @param baseUrl - The base URL for the error page (e.g., 'https://base-ui.com/production-error')\n * @param prefix - The prefix for the error message (e.g., 'Base UI')\n * @returns A function that formats error messages with the given URL and prefix\n */\nexport function createFormatErrorMessage(baseUrl, prefix) {\n return function formatErrorMessage(code, ...args) {\n const url = new URL(baseUrl);\n url.searchParams.set('code', code.toString());\n args.forEach(arg => url.searchParams.append('args[]', arg));\n return `${prefix} error #${code}; visit ${url} for the full message.`;\n };\n}\n\n/**\n * WARNING: Don't import this directly. It's imported by the code generated by\n * `@mui/internal-babel-plugin-minify-errors`. Make sure to always use string literals in `Error`\n * constructors to ensure the plugin works as expected. Supported patterns include:\n * throw new Error('My message');\n * throw new Error(`My message: ${foo}`);\n * throw new Error(`My message: ${foo}` + 'another string');\n * ...\n */\nconst formatErrorMessage = createFormatErrorMessage('https://base-ui.com/production-error', 'Base UI');\nexport default formatErrorMessage;","import * as React from 'react';\nimport { isReactVersionAtLeast } from \"./reactVersion.mjs\";\n\n/**\n * Extracts the `ref` from a React element, handling different React versions.\n */\nexport function getReactElementRef(element) {\n if (! /*#__PURE__*/React.isValidElement(element)) {\n return null;\n }\n const reactElement = element;\n const propsWithRef = reactElement.props;\n return (isReactVersionAtLeast(19) ? propsWithRef?.ref : reactElement.ref) ?? null;\n}","/**\n * Combines multiple cleanup functions into a single cleanup function.\n */\nexport function mergeCleanups(...cleanups) {\n return () => {\n for (let i = 0; i < cleanups.length; i += 1) {\n const cleanup = cleanups[i];\n if (cleanup) {\n cleanup();\n }\n }\n };\n}","export function mergeObjects(a, b) {\n if (a && !b) {\n return a;\n }\n if (!a && b) {\n return b;\n }\n if (a || b) {\n return {\n ...a,\n ...b\n };\n }\n return undefined;\n}","export { getWindow as ownerWindow } from '@floating-ui/utils/dom';\nexport function ownerDocument(node) {\n return node?.ownerDocument || document;\n}","/**\n * Reads `navigator.userAgent` / `navigator.platform` (legacy but universally\n * supported) into a normalized shape. In development, prefers the modern\n * `navigator.userAgentData` API on Chromium to avoid DevTools warnings about\n * the deprecated reads; that branch is dead-code-eliminated in production\n * builds to keep the bundle small.\n *\n * Returns empty/zero values when `navigator` is undefined (SSR), so every\n * derived flag safely evaluates to `false`.\n */\nfunction readRawData() {\n if (typeof navigator === 'undefined') {\n return {\n userAgent: '',\n platform: '',\n maxTouchPoints: 0\n };\n }\n if (process.env.NODE_ENV !== 'production') {\n const uaData = navigator.userAgentData;\n if (uaData && Array.isArray(uaData.brands)) {\n return {\n userAgent: uaData.brands.map(({\n brand,\n version\n }) => `${brand}/${version}`).join(' '),\n platform: uaData.platform ?? navigator.platform ?? '',\n maxTouchPoints: navigator.maxTouchPoints ?? 0\n };\n }\n }\n return {\n userAgent: navigator.userAgent,\n platform: navigator.platform ?? '',\n maxTouchPoints: navigator.maxTouchPoints ?? 0\n };\n}\nconst {\n userAgent,\n platform,\n maxTouchPoints\n} = readRawData();\nexport const lowerUserAgent = userAgent.toLowerCase();\nexport const lowerPlatform = platform.toLowerCase();\nexport { maxTouchPoints };","import { lowerUserAgent, lowerPlatform, maxTouchPoints } from \"./shared.mjs\";\n\n// iPadOS 13+ reports `MacIntel` for `navigator.platform`; disambiguated via\n// `maxTouchPoints` so iPad is classified as iOS, not macOS.\n// https://github.com/mui/base-ui/issues/1309\n/** iPhone, iPad (including iPadOS 13+ reporting as macOS), iPod. */\nexport const ios = /^i(os$|p)/.test(lowerPlatform) || lowerPlatform === 'macintel' && maxTouchPoints > 1;\n\n/** Android phones, tablets, and embedded Android browsers. */\nconst ANDROID_STRING = 'android';\nexport const android = lowerPlatform === ANDROID_STRING || lowerUserAgent.includes(ANDROID_STRING);\n\n/** macOS desktop. Excludes iPadOS, which reports as `MacIntel`. */\nexport const mac = !ios && lowerPlatform.startsWith('mac');\n\n/** Windows desktop. */\nexport const windows = lowerPlatform.startsWith('win');\n\n/** Linux desktop (including Chrome OS). */\nexport const linux = !android && /^(linux|chrome os)/.test(lowerPlatform);\n\n/** Any Apple OS (`mac || ios`). */\nexport const apple = mac || ios;","import { lowerUserAgent } from \"./shared.mjs\";\n\n// WebKit (Safari, all iOS browsers, GNOME Web). Distinguished from Blink by\n// the legacy `-webkit-backdrop-filter` name — Blink forked from WebKit in 2013\n// and only ships the unprefixed `backdrop-filter`.\n/** WebKit: Safari, all iOS browsers, GNOME Web. Excludes Blink. */\nexport const webkit = typeof CSS !== 'undefined' && !!CSS.supports?.('-webkit-backdrop-filter:none');\n\n// Anchored to `!webkit` so engines are mutually exclusive by construction.\n// Firefox-on-iOS uses WebKit (its UA marker is `FxiOS/`, not `Firefox/`); the\n// `!webkit` prefix also defends against future iOS-browser UA changes that\n// might inject `Firefox` into a WebKit-based UA.\n/** Gecko: Firefox. */\nexport const gecko = !webkit && lowerUserAgent.includes('firefox');\n\n// All Chromium-based browsers ship `Chrome/` or `Chromium/` in their UA — both\n// share the `chrom` prefix, so a single substring check covers Chrome, Edge,\n// Opera, Brave, etc. Chrome-on-iOS uses `CriOS/` and stays WebKit. The positive\n// UA check also makes this SSR-safe — an empty UA matches nothing.\n/** Blink: Chrome, Edge, Opera, Brave, and other Chromium-based browsers. */\nexport const blink = !webkit && lowerUserAgent.includes('chrom');","import { apple } from \"./os.mjs\";\n\n// Whether a screen reader is *actually* running cannot be detected. These flags\n// identify platforms where a specific screen reader could be active. VoiceOver\n// is the system screen reader on Apple platforms and works with every browser\n// there, so the flag is purely an OS check; engine-specific quirks (e.g. the\n// NSAccessibility virtual-cursor focus path) should be gated at the call site.\n/**\n * The user *may* be using VoiceOver — actual activation is not detectable.\n * True on any Apple platform (macOS, iOS, iPadOS).\n */\nexport const voiceOver = apple;","import { lowerUserAgent } from \"./shared.mjs\";\n\n/** Running in jsdom or HappyDOM (used by unit tests). */\nexport const jsdom = /jsdom|happydom/.test(lowerUserAgent);","import * as React from 'react';\nconst majorVersion = parseInt(React.version, 10);\nexport function isReactVersionAtLeast(reactVersionToCheck) {\n return majorVersion >= reactVersionToCheck;\n}","import _formatErrorMessage from \"../formatErrorMessage.mjs\";\n/**\n * The NoOptionalParams type is a utility type that checks if a function has optional or default parameters.\n * If the function has optional or default parameters, it returns a string literal type with an error message.\n * Otherwise, it returns the original function type.\n *\n * This is used to enforce that the combiner function passed to createSelector does not have optional or default parameters,\n * as memoization relies on the Function.length property, which does not account for optional or default parameters.\n */\n\n/**\n * Creates a selector function that can be used to derive values from the store's state.\n *\n * The combiner function can have up to three additional parameters, but it **cannot have optional or default parameters**.\n *\n * This function accepts up to six functions and combines them into a single selector function.\n * The resulting selector will take the state from the combined selectors and any additional parameters required by the combiner.\n *\n * The return type of the resulting selector is determined by the return type of the combiner function.\n *\n * @example\n * const selector = createSelector(\n * (state) => state.disabled\n * );\n *\n * @example\n * const selector = createSelector(\n * (state) => state.disabled,\n * (state) => state.open,\n * (disabled, open) => ({ disabled, open })\n * );\n */\n/* eslint-disable id-denylist */\nexport const createSelector = (a, b, c, d, e, f, ...other) => {\n if (other.length > 0) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? 'Unsupported number of selectors' : _formatErrorMessage(1));\n }\n let selector;\n if (a && b && c && d && e && f) {\n selector = (state, a1, a2, a3) => {\n const va = a(state, a1, a2, a3);\n const vb = b(state, a1, a2, a3);\n const vc = c(state, a1, a2, a3);\n const vd = d(state, a1, a2, a3);\n const ve = e(state, a1, a2, a3);\n return f(va, vb, vc, vd, ve, a1, a2, a3);\n };\n } else if (a && b && c && d && e) {\n selector = (state, a1, a2, a3) => {\n const va = a(state, a1, a2, a3);\n const vb = b(state, a1, a2, a3);\n const vc = c(state, a1, a2, a3);\n const vd = d(state, a1, a2, a3);\n return e(va, vb, vc, vd, a1, a2, a3);\n };\n } else if (a && b && c && d) {\n selector = (state, a1, a2, a3) => {\n const va = a(state, a1, a2, a3);\n const vb = b(state, a1, a2, a3);\n const vc = c(state, a1, a2, a3);\n return d(va, vb, vc, a1, a2, a3);\n };\n } else if (a && b && c) {\n selector = (state, a1, a2, a3) => {\n const va = a(state, a1, a2, a3);\n const vb = b(state, a1, a2, a3);\n return c(va, vb, a1, a2, a3);\n };\n } else if (a && b) {\n selector = (state, a1, a2, a3) => {\n const va = a(state, a1, a2, a3);\n return b(va, a1, a2, a3);\n };\n } else if (a) {\n selector = a;\n } else {\n throw /* minify-error-disabled */new Error('Missing arguments');\n }\n return selector;\n};\n/* eslint-enable id-denylist */","'use client';\n\nimport { useRefWithInit } from \"./useRefWithInit.mjs\";\nimport { useOnMount } from \"./useOnMount.mjs\";\n/** Unlike `setTimeout`, rAF doesn't guarantee a positive integer return value, so we can't have\n * a monomorphic `uint` type with `0` meaning empty.\n * See warning note at:\n * https://developer.mozilla.org/en-US/docs/Web/API/Window/requestAnimationFrame#return_value */\nconst EMPTY = null;\nlet LAST_RAF = globalThis.requestAnimationFrame;\nclass Scheduler {\n /* This implementation uses an array as a backing data-structure for frame callbacks.\n * It allows `O(1)` callback cancelling by inserting a `null` in the array, though it\n * never calls the native `cancelAnimationFrame` if there are no frames left. This can\n * be much more efficient if there is a call pattern that alterns as\n * \"request-cancel-request-cancel-…\".\n * But in the case of \"request-request-…-cancel-cancel-…\", it leaves the final animation\n * frame to run anyway. We turn that frame into a `O(1)` no-op via `callbacksCount`. */\n\n callbacks = [];\n callbacksCount = 0;\n nextId = 1;\n startId = 1;\n isScheduled = false;\n tick = timestamp => {\n this.isScheduled = false;\n const currentCallbacks = this.callbacks;\n const currentCallbacksCount = this.callbacksCount;\n\n // Update these before iterating, callbacks could call `requestAnimationFrame` again.\n this.callbacks = [];\n this.callbacksCount = 0;\n this.startId = this.nextId;\n if (currentCallbacksCount > 0) {\n for (let i = 0; i < currentCallbacks.length; i += 1) {\n currentCallbacks[i]?.(timestamp);\n }\n }\n };\n request(fn) {\n const id = this.nextId;\n this.nextId += 1;\n this.callbacks.push(fn);\n this.callbacksCount += 1;\n\n /* In a test environment with fake timers, a fake `requestAnimationFrame` can be called\n * but there's no guarantee that the animation frame will actually run before the fake\n * timers are teared, which leaves `isScheduled` set, but won't run our `tick()`. */\n const didRAFChange = process.env.NODE_ENV !== 'production' && LAST_RAF !== requestAnimationFrame && (LAST_RAF = requestAnimationFrame, true);\n if (!this.isScheduled || didRAFChange) {\n requestAnimationFrame(this.tick);\n this.isScheduled = true;\n }\n return id;\n }\n cancel(id) {\n const index = id - this.startId;\n if (index < 0 || index >= this.callbacks.length) {\n return;\n }\n this.callbacks[index] = null;\n this.callbacksCount -= 1;\n }\n}\nconst scheduler = new Scheduler();\nexport class AnimationFrame {\n static create() {\n return new AnimationFrame();\n }\n static request(fn) {\n return scheduler.request(fn);\n }\n static cancel(id) {\n return scheduler.cancel(id);\n }\n currentId = EMPTY;\n\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n request(fn) {\n this.cancel();\n this.currentId = scheduler.request(() => {\n this.currentId = EMPTY;\n fn();\n });\n }\n cancel = () => {\n if (this.currentId !== EMPTY) {\n scheduler.cancel(this.currentId);\n this.currentId = EMPTY;\n }\n };\n disposeEffect = () => {\n return this.cancel;\n };\n}\n\n/**\n * A `requestAnimationFrame` with automatic cleanup and guard.\n */\nexport function useAnimationFrame() {\n const timeout = useRefWithInit(AnimationFrame.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\nimport * as React from 'react';\nimport { SafeReact } from \"./safeReact.mjs\";\nlet globalId = 0;\n\n// TODO React 17: Remove `useGlobalId` once React 17 support is removed\nfunction useGlobalId(idOverride, prefix = 'mui') {\n const [defaultId, setDefaultId] = React.useState(idOverride);\n const id = idOverride || defaultId;\n React.useEffect(() => {\n if (defaultId == null) {\n // Fallback to this default id when possible.\n // Use the incrementing value for client-side rendering only.\n // We can't use it server-side.\n // If you want to use random values please consider the Birthday Problem: https://en.wikipedia.org/wiki/Birthday_problem\n globalId += 1;\n setDefaultId(`${prefix}-${globalId}`);\n }\n }, [defaultId, prefix]);\n return id;\n}\nconst maybeReactUseId = SafeReact.useId;\n\n/**\n *\n * @example <div id={useId()} />\n * @param idOverride\n * @returns {string}\n */\nexport function useId(idOverride, prefix) {\n // React.useId() is only available from React 17.0.0.\n if (maybeReactUseId !== undefined) {\n const reactId = maybeReactUseId();\n return idOverride ?? (prefix ? `${prefix}-${reactId}` : reactId);\n }\n\n // TODO: uncomment once we enable eslint-plugin-react-compiler // eslint-disable-next-line react-compiler/react-compiler\n // eslint-disable-next-line react-hooks/rules-of-hooks -- `React.useId` is invariant at runtime.\n return useGlobalId(idOverride, prefix);\n}","'use client';\n\nimport * as React from 'react';\nconst noop = () => {};\nexport const useIsoLayoutEffect = typeof document !== 'undefined' ? React.useLayoutEffect : noop;","import { useRefWithInit } from \"./useRefWithInit.mjs\";\n\n/**\n * Merges refs into a single memoized callback ref or `null`.\n * This makes sure multiple refs are updated together and have the same value.\n *\n * This function accepts up to four refs. If you need to merge more, or have an unspecified number of refs to merge,\n * use `useMergedRefsN` instead.\n */\n\nexport function useMergedRefs(a, b, c, d) {\n const forkRef = useRefWithInit(createForkRef).current;\n if (didChange(forkRef, a, b, c, d)) {\n update(forkRef, [a, b, c, d]);\n }\n return forkRef.callback;\n}\n\n/**\n * Merges an array of refs into a single memoized callback ref or `null`.\n *\n * If you need to merge a fixed number (up to four) of refs, use `useMergedRefs` instead for better performance.\n */\nexport function useMergedRefsN(refs) {\n const forkRef = useRefWithInit(createForkRef).current;\n if (didChangeN(forkRef, refs)) {\n update(forkRef, refs);\n }\n return forkRef.callback;\n}\nfunction createForkRef() {\n return {\n callback: null,\n cleanup: null,\n refs: []\n };\n}\nfunction didChange(forkRef, a, b, c, d) {\n // prettier-ignore\n return forkRef.refs[0] !== a || forkRef.refs[1] !== b || forkRef.refs[2] !== c || forkRef.refs[3] !== d;\n}\nfunction didChangeN(forkRef, newRefs) {\n return forkRef.refs.length !== newRefs.length || forkRef.refs.some((ref, index) => ref !== newRefs[index]);\n}\nfunction update(forkRef, refs) {\n forkRef.refs = refs;\n if (refs.every(ref => ref == null)) {\n forkRef.callback = null;\n return;\n }\n forkRef.callback = instance => {\n if (forkRef.cleanup) {\n forkRef.cleanup();\n forkRef.cleanup = null;\n }\n if (instance != null) {\n const cleanupCallbacks = Array(refs.length).fill(null);\n for (let i = 0; i < refs.length; i += 1) {\n const ref = refs[i];\n if (ref == null) {\n continue;\n }\n switch (typeof ref) {\n case 'function':\n {\n const refCleanup = ref(instance);\n if (typeof refCleanup === 'function') {\n cleanupCallbacks[i] = refCleanup;\n }\n break;\n }\n case 'object':\n {\n ref.current = instance;\n break;\n }\n default:\n }\n }\n forkRef.cleanup = () => {\n for (let i = 0; i < refs.length; i += 1) {\n const ref = refs[i];\n if (ref == null) {\n continue;\n }\n switch (typeof ref) {\n case 'function':\n {\n const cleanupCallback = cleanupCallbacks[i];\n if (typeof cleanupCallback === 'function') {\n cleanupCallback();\n } else {\n ref(null);\n }\n break;\n }\n case 'object':\n {\n ref.current = null;\n break;\n }\n default:\n }\n }\n };\n }\n };\n}","'use client';\n\nimport * as React from 'react';\nexport function useOnFirstRender(fn) {\n const ref = React.useRef(true);\n if (ref.current) {\n ref.current = false;\n fn();\n }\n}","'use client';\n\nimport * as React from 'react';\nconst EMPTY = [];\n\n/**\n * A React.useEffect equivalent that runs once, when the component is mounted.\n */\nexport function useOnMount(fn) {\n // TODO: uncomment once we enable eslint-plugin-react-compiler // eslint-disable-next-line react-compiler/react-compiler -- no need to put `fn` in the dependency array\n /* eslint-disable react-hooks/exhaustive-deps */\n React.useEffect(fn, EMPTY);\n /* eslint-enable react-hooks/exhaustive-deps */\n}","'use client';\n\nimport * as React from 'react';\nconst UNINITIALIZED = {};\n\n/**\n * A React.useRef() that is initialized with a function. Note that it accepts an optional\n * initialization argument, so the initialization function doesn't need to be an inline closure.\n *\n * @usage\n * const ref = useRefWithInit(sortColumns, columns)\n */\n\nexport function useRefWithInit(init, initArg) {\n const ref = React.useRef(UNINITIALIZED);\n if (ref.current === UNINITIALIZED) {\n ref.current = init(initArg);\n }\n return ref;\n}","import * as React from 'react';\n\n/**\n * A clone of the React namespace for reading APIs that may be missing in older\n * supported React versions. Bundlers can rewrite direct `React.someNewApi`\n * reads into named imports, which breaks React 17. Reading from this cloned\n * object keeps those lookups optional.\n *\n * @see https://github.com/mui/material-ui/issues/41190#issuecomment-2040873379\n */\nexport const SafeReact = {\n ...React\n};","'use client';\n\nimport { SafeReact } from \"./safeReact.mjs\";\nimport { useRefWithInit } from \"./useRefWithInit.mjs\";\nconst useInsertionEffect = SafeReact.useInsertionEffect;\nconst useSafeInsertionEffect =\n// React 17 doesn't have useInsertionEffect.\nuseInsertionEffect &&\n// Preact replaces useInsertionEffect with useLayoutEffect and fires too late.\nuseInsertionEffect !== SafeReact.useLayoutEffect ? useInsertionEffect : fn => fn();\n/**\n * Stabilizes the function passed so it's always the same between renders.\n *\n * The function becomes non-reactive to any values it captures.\n * It can safely be passed as a dependency of `React.useMemo` and `React.useEffect` without re-triggering them if its captured values change.\n *\n * The function must only be called inside effects and event handlers, never during render (which throws an error).\n *\n * This hook is a more permissive version of React 19.2's `React.useEffectEvent` in that it can be passed through contexts and called in event handler props, not just effects.\n */\nexport function useStableCallback(callback) {\n const stable = useRefWithInit(createStableCallback).current;\n stable.next = callback;\n useSafeInsertionEffect(stable.effect);\n return stable.trampoline;\n}\nfunction createStableCallback() {\n const stable = {\n next: undefined,\n callback: assertNotCalled,\n trampoline: (...args) => stable.callback?.(...args),\n effect: () => {\n stable.callback = stable.next;\n }\n };\n return stable;\n}\nfunction assertNotCalled() {\n if (process.env.NODE_ENV !== 'production') {\n // TODO: fix mui/no-guarded-throw\n // eslint-disable-next-line mui/no-guarded-throw\n throw /* minify-error-disabled */new Error('Base UI: Cannot call an event handler while rendering.');\n }\n}","'use client';\n\nimport { useRefWithInit } from \"./useRefWithInit.mjs\";\nimport { useOnMount } from \"./useOnMount.mjs\";\nconst EMPTY = 0;\nexport class Timeout {\n static create() {\n return new Timeout();\n }\n currentId = EMPTY;\n\n /**\n * Executes `fn` after `delay`, clearing any previously scheduled call.\n */\n start(delay, fn) {\n this.clear();\n this.currentId = setTimeout(() => {\n this.currentId = EMPTY;\n fn();\n }, delay); /* Node.js types are enabled in development */\n }\n isStarted() {\n return this.currentId !== EMPTY;\n }\n clear = () => {\n if (this.currentId !== EMPTY) {\n clearTimeout(this.currentId);\n this.currentId = EMPTY;\n }\n };\n disposeEffect = () => {\n return this.clear;\n };\n}\n\n/**\n * A `setTimeout` with automatic cleanup and guard.\n */\nexport function useTimeout() {\n const timeout = useRefWithInit(Timeout.create).current;\n useOnMount(timeout.disposeEffect);\n return timeout;\n}","'use client';\n\nimport { useIsoLayoutEffect } from \"./useIsoLayoutEffect.mjs\";\nimport { useRefWithInit } from \"./useRefWithInit.mjs\";\n\n/**\n * Untracks the provided value by turning it into a ref to remove its reactivity.\n *\n * Used to access the passed value inside `React.useEffect` without causing the effect to re-run when the value changes.\n */\nexport function useValueAsRef(value) {\n const latest = useRefWithInit(createLatestRef, value).current;\n latest.next = value;\n\n // eslint-disable-next-line react-hooks/exhaustive-deps\n useIsoLayoutEffect(latest.effect);\n return latest;\n}\nfunction createLatestRef(value) {\n const latest = {\n current: value,\n next: value,\n effect: () => {\n latest.current = latest.next;\n }\n };\n return latest;\n}","let set;\nif (process.env.NODE_ENV !== 'production') {\n set = new Set();\n}\nexport function warn(...messages) {\n if (process.env.NODE_ENV !== 'production') {\n const messageKey = messages.join(' ');\n if (!set.has(messageKey)) {\n set.add(messageKey);\n console.warn(`Base UI: ${messageKey}`);\n }\n }\n}","function hasWindow() {\n return typeof window !== 'undefined';\n}\nfunction getNodeName(node) {\n if (isNode(node)) {\n return (node.nodeName || '').toLowerCase();\n }\n // Mocked nodes in testing environments may not be instances of Node. By\n // returning `#document` an infinite loop won't occur.\n // https://github.com/floating-ui/floating-ui/issues/2317\n return '#document';\n}\nfunction getWindow(node) {\n var _node$ownerDocument;\n return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;\n}\nfunction getDocumentElement(node) {\n var _ref;\n return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;\n}\nfunction isNode(value) {\n if (!hasWindow()) {\n return false;\n }\n return value instanceof Node || value instanceof getWindow(value).Node;\n}\nfunction isElement(value) {\n if (!hasWindow()) {\n return false;\n }\n return value instanceof Element || value instanceof getWindow(value).Element;\n}\nfunction isHTMLElement(value) {\n if (!hasWindow()) {\n return false;\n }\n return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;\n}\nfunction isShadowRoot(value) {\n if (!hasWindow() || typeof ShadowRoot === 'undefined') {\n return false;\n }\n return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;\n}\nfunction isOverflowElement(element) {\n const {\n overflow,\n overflowX,\n overflowY,\n display\n } = getComputedStyle(element);\n return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && display !== 'inline' && display !== 'contents';\n}\nfunction isTableElement(element) {\n return /^(table|td|th)$/.test(getNodeName(element));\n}\nfunction isTopLayer(element) {\n try {\n if (element.matches(':popover-open')) {\n return true;\n }\n } catch (_e) {\n // no-op\n }\n try {\n return element.matches(':modal');\n } catch (_e) {\n return false;\n }\n}\nconst willChangeRe = /transform|translate|scale|rotate|perspective|filter/;\nconst containRe = /paint|layout|strict|content/;\nconst isNotNone = value => !!value && value !== 'none';\nlet isWebKitValue;\nfunction isContainingBlock(elementOrCss) {\n const css = isElement(elementOrCss) ? getComputedStyle(elementOrCss) : elementOrCss;\n\n // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block\n // https://drafts.csswg.org/css-transforms-2/#individual-transforms\n return isNotNone(css.transform) || isNotNone(css.translate) || isNotNone(css.scale) || isNotNone(css.rotate) || isNotNone(css.perspective) || !isWebKit() && (isNotNone(css.backdropFilter) || isNotNone(css.filter)) || willChangeRe.test(css.willChange || '') || containRe.test(css.contain || '');\n}\nfunction getContainingBlock(element) {\n let currentNode = getParentNode(element);\n while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {\n if (isContainingBlock(currentNode)) {\n return currentNode;\n } else if (isTopLayer(currentNode)) {\n return null;\n }\n currentNode = getParentNode(currentNode);\n }\n return null;\n}\nfunction isWebKit() {\n if (isWebKitValue == null) {\n isWebKitValue = typeof CSS !== 'undefined' && CSS.supports && CSS.supports('-webkit-backdrop-filter', 'none');\n }\n return isWebKitValue;\n}\nfunction isLastTraversableNode(node) {\n return /^(html|body|#document)$/.test(getNodeName(node));\n}\nfunction getComputedStyle(element) {\n return getWindow(element).getComputedStyle(element);\n}\nfunction getNodeScroll(element) {\n if (isElement(element)) {\n return {\n scrollLeft: element.scrollLeft,\n scrollTop: element.scrollTop\n };\n }\n return {\n scrollLeft: element.scrollX,\n scrollTop: element.scrollY\n };\n}\nfunction getParentNode(node) {\n if (getNodeName(node) === 'html') {\n return node;\n }\n const result =\n // Step into the shadow DOM of the parent of a slotted node.\n node.assignedSlot ||\n // DOM Element detected.\n node.parentNode ||\n // ShadowRoot detected.\n isShadowRoot(node) && node.host ||\n // Fallback.\n getDocumentElement(node);\n return isShadowRoot(result) ? result.host : result;\n}\nfunction getNearestOverflowAncestor(node) {\n const parentNode = getParentNode(node);\n if (isLastTraversableNode(parentNode)) {\n return node.ownerDocument ? node.ownerDocument.body : node.body;\n }\n if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {\n return parentNode;\n }\n return getNearestOverflowAncestor(parentNode);\n}\nfunction getOverflowAncestors(node, list, traverseIframes) {\n var _node$ownerDocument2;\n if (list === void 0) {\n list = [];\n }\n if (traverseIframes === void 0) {\n traverseIframes = true;\n }\n const scrollableAncestor = getNearestOverflowAncestor(node);\n const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);\n const win = getWindow(scrollableAncestor);\n if (isBody) {\n const frameElement = getFrameElement(win);\n return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);\n } else {\n return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));\n }\n}\nfunction getFrameElement(win) {\n return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;\n}\n\nexport { getComputedStyle, getContainingBlock, getDocumentElement, getFrameElement, getNearestOverflowAncestor, getNodeName, getNodeScroll, getOverflowAncestors, getParentNode, getWindow, isContainingBlock, isElement, isHTMLElement, isLastTraversableNode, isNode, isOverflowElement, isShadowRoot, isTableElement, isTopLayer, isWebKit };\n","\"use strict\";\n\nfunction _getRequireWildcardCache(nodeInterop) {\n if (typeof WeakMap !== \"function\") return null;\n\n var cacheBabelInterop = new WeakMap();\n var cacheNodeInterop = new WeakMap();\n\n return (_getRequireWildcardCache = function(nodeInterop) {\n return nodeInterop ? cacheNodeInterop : cacheBabelInterop;\n })(nodeInterop);\n}\nfunction _interop_require_wildcard(obj, nodeInterop) {\n if (!nodeInterop && obj && obj.__esModule) return obj;\n if (obj === null || typeof obj !== \"object\" && typeof obj !== \"function\") return { default: obj };\n\n var cache = _getRequireWildcardCache(nodeInterop);\n\n if (cache && cache.has(obj)) return cache.get(obj);\n\n var newObj = { __proto__: null };\n var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;\n\n for (var key in obj) {\n if (key !== \"default\" && Object.prototype.hasOwnProperty.call(obj, key)) {\n var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;\n if (desc && (desc.get || desc.set)) Object.defineProperty(newObj, key, desc);\n else newObj[key] = obj[key];\n }\n }\n\n newObj.default = obj;\n\n if (cache) cache.set(obj, newObj);\n\n return newObj;\n}\nexports._ = _interop_require_wildcard;\n","import { isServer } from './utils'\n\nexport type IsServerValue = () => boolean\n\n/**\n * Manages environment detection used by TanStack Query internals.\n */\nexport const environmentManager = (() => {\n let isServerFn: IsServerValue = () => isServer\n\n return {\n /**\n * Returns whether the current runtime should be treated as a server environment.\n */\n isServer(): boolean {\n return isServerFn()\n },\n /**\n * Overrides the server check globally.\n */\n setIsServer(isServerValue: IsServerValue): void {\n isServerFn = isServerValue\n },\n }\n})()\n","// src/subscribable.ts\nvar Subscribable = class {\n constructor() {\n this.listeners = /* @__PURE__ */ new Set();\n this.subscribe = this.subscribe.bind(this);\n }\n subscribe(listener) {\n this.listeners.add(listener);\n this.onSubscribe();\n return () => {\n this.listeners.delete(listener);\n this.onUnsubscribe();\n };\n }\n hasListeners() {\n return this.listeners.size > 0;\n }\n onSubscribe() {\n }\n onUnsubscribe() {\n }\n};\nexport {\n Subscribable\n};\n//# sourceMappingURL=subscribable.js.map","// src/thenable.ts\nimport { noop } from \"./utils.js\";\nfunction pendingThenable() {\n let resolve;\n let reject;\n const thenable = new Promise((_resolve, _reject) => {\n resolve = _resolve;\n reject = _reject;\n });\n thenable.status = \"pending\";\n thenable.catch(() => {\n });\n function finalize(data) {\n Object.assign(thenable, data);\n delete thenable.resolve;\n delete thenable.reject;\n }\n thenable.resolve = (value) => {\n finalize({\n status: \"fulfilled\",\n value\n });\n resolve(value);\n };\n thenable.reject = (reason) => {\n finalize({\n status: \"rejected\",\n reason\n });\n reject(reason);\n };\n return thenable;\n}\nfunction tryResolveSync(promise) {\n let data;\n promise.then((result) => {\n data = result;\n return result;\n }, noop)?.catch(noop);\n if (data !== void 0) {\n return { data };\n }\n return void 0;\n}\nexport {\n pendingThenable,\n tryResolveSync\n};\n//# sourceMappingURL=thenable.js.map","// src/focusManager.ts\nimport { Subscribable } from \"./subscribable.js\";\nvar FocusManager = class extends Subscribable {\n #focused;\n #cleanup;\n #setup;\n constructor() {\n super();\n this.#setup = (onFocus) => {\n if (typeof window !== \"undefined\" && window.addEventListener) {\n const listener = () => onFocus();\n window.addEventListener(\"visibilitychange\", listener, false);\n return () => {\n window.removeEventListener(\"visibilitychange\", listener);\n };\n }\n return;\n };\n }\n onSubscribe() {\n if (!this.#cleanup) {\n this.setEventListener(this.#setup);\n }\n }\n onUnsubscribe() {\n if (!this.hasListeners()) {\n this.#cleanup?.();\n this.#cleanup = void 0;\n }\n }\n setEventListener(setup) {\n this.#setup = setup;\n this.#cleanup?.();\n this.#cleanup = setup((focused) => {\n if (typeof focused === \"boolean\") {\n this.setFocused(focused);\n } else {\n this.onFocus();\n }\n });\n }\n setFocused(focused) {\n const changed = this.#focused !== focused;\n if (changed) {\n this.#focused = focused;\n this.onFocus();\n }\n }\n onFocus() {\n const isFocused = this.isFocused();\n this.listeners.forEach((listener) => {\n listener(isFocused);\n });\n }\n isFocused() {\n if (typeof this.#focused === \"boolean\") {\n return this.#focused;\n }\n return globalThis.document?.visibilityState !== \"hidden\";\n }\n};\nvar focusManager = new FocusManager();\nexport {\n FocusManager,\n focusManager\n};\n//# sourceMappingURL=focusManager.js.map","// src/onlineManager.ts\nimport { Subscribable } from \"./subscribable.js\";\nvar OnlineManager = class extends Subscribable {\n #online = true;\n #cleanup;\n #setup;\n constructor() {\n super();\n this.#setup = (onOnline) => {\n if (typeof window !== \"undefined\" && window.addEventListener) {\n const onlineListener = () => onOnline(true);\n const offlineListener = () => onOnline(false);\n window.addEventListener(\"online\", onlineListener, false);\n window.addEventListener(\"offline\", offlineListener, false);\n return () => {\n window.removeEventListener(\"online\", onlineListener);\n window.removeEventListener(\"offline\", offlineListener);\n };\n }\n return;\n };\n }\n onSubscribe() {\n if (!this.#cleanup) {\n this.setEventListener(this.#setup);\n }\n }\n onUnsubscribe() {\n if (!this.hasListeners()) {\n this.#cleanup?.();\n this.#cleanup = void 0;\n }\n }\n setEventListener(setup) {\n this.#setup = setup;\n this.#cleanup?.();\n this.#cleanup = setup(this.setOnline.bind(this));\n }\n setOnline(online) {\n const changed = this.#online !== online;\n if (changed) {\n this.#online = online;\n this.listeners.forEach((listener) => {\n listener(online);\n });\n }\n }\n isOnline() {\n return this.#online;\n }\n};\nvar onlineManager = new OnlineManager();\nexport {\n OnlineManager,\n onlineManager\n};\n//# sourceMappingURL=onlineManager.js.map","import { notifyManager } from './notifyManager'\nimport { Removable } from './removable'\nimport { createRetryer } from './retryer'\nimport type {\n DefaultError,\n MutationFunctionContext,\n MutationMeta,\n MutationOptions,\n MutationStatus,\n} from './types'\nimport type { MutationCache } from './mutationCache'\nimport type { MutationObserver } from './mutationObserver'\nimport type { Retryer } from './retryer'\nimport type { QueryClient } from './queryClient'\n\n// TYPES\n\ninterface MutationConfig<TData, TError, TVariables, TOnMutateResult> {\n client: QueryClient\n mutationId: number\n mutationCache: MutationCache\n options: MutationOptions<TData, TError, TVariables, TOnMutateResult>\n state?: MutationState<TData, TError, TVariables, TOnMutateResult>\n}\n\nexport interface MutationState<\n TData = unknown,\n TError = DefaultError,\n TVariables = unknown,\n TOnMutateResult = unknown,\n> {\n context: TOnMutateResult | undefined\n data: TData | undefined\n error: TError | null\n failureCount: number\n failureReason: TError | null\n isPaused: boolean\n status: MutationStatus\n variables: TVariables | undefined\n submittedAt: number\n}\n\ninterface FailedAction<TError> {\n type: 'failed'\n failureCount: number\n error: TError | null\n}\n\ninterface PendingAction<TVariables, TOnMutateResult> {\n type: 'pending'\n isPaused: boolean\n variables?: TVariables\n context?: TOnMutateResult\n}\n\ninterface SuccessAction<TData> {\n type: 'success'\n data: TData\n}\n\ninterface ErrorAction<TError> {\n type: 'error'\n error: TError\n}\n\ninterface PauseAction {\n type: 'pause'\n}\n\ninterface ContinueAction {\n type: 'continue'\n}\n\nexport type Action<TData, TError, TVariables, TOnMutateResult> =\n | ContinueAction\n | ErrorAction<TError>\n | FailedAction<TError>\n | PendingAction<TVariables, TOnMutateResult>\n | PauseAction\n | SuccessAction<TData>\n\n// CLASS\n\nexport class Mutation<\n TData = unknown,\n TError = DefaultError,\n TVariables = unknown,\n TOnMutateResult = unknown,\n> extends Removable {\n state: MutationState<TData, TError, TVariables, TOnMutateResult>\n options!: MutationOptions<TData, TError, TVariables, TOnMutateResult>\n readonly mutationId: number\n\n #client: QueryClient\n #observers: Array<\n MutationObserver<TData, TError, TVariables, TOnMutateResult>\n >\n #mutationCache: MutationCache\n #retryer?: Retryer<TData>\n\n constructor(\n config: MutationConfig<TData, TError, TVariables, TOnMutateResult>,\n ) {\n super()\n\n this.#client = config.client\n this.mutationId = config.mutationId\n this.#mutationCache = config.mutationCache\n this.#observers = []\n this.state = config.state || getDefaultState()\n\n this.setOptions(config.options)\n this.scheduleGc()\n }\n\n setOptions(\n options: MutationOptions<TData, TError, TVariables, TOnMutateResult>,\n ): void {\n this.options = options\n\n this.updateGcTime(this.options.gcTime)\n }\n\n get meta(): MutationMeta | undefined {\n return this.options.meta\n }\n\n addObserver(observer: MutationObserver<any, any, any, any>): void {\n if (!this.#observers.includes(observer)) {\n this.#observers.push(observer)\n\n // Stop the mutation from being garbage collected\n this.clearGcTimeout()\n\n this.#mutationCache.notify({\n type: 'observerAdded',\n mutation: this,\n observer,\n })\n }\n }\n\n removeObserver(observer: MutationObserver<any, any, any, any>): void {\n this.#observers = this.#observers.filter((x) => x !== observer)\n\n this.scheduleGc()\n\n this.#mutationCache.notify({\n type: 'observerRemoved',\n mutation: this,\n observer,\n })\n }\n\n protected optionalRemove() {\n if (!this.#observers.length) {\n if (this.state.status === 'pending') {\n this.scheduleGc()\n } else {\n this.#mutationCache.remove(this)\n }\n }\n }\n\n continue(): Promise<unknown> {\n return (\n this.#retryer?.continue() ??\n // continuing a mutation assumes that variables are set, mutation must have been dehydrated before\n this.execute(this.state.variables!)\n )\n }\n\n async execute(variables: TVariables): Promise<TData> {\n const onContinue = () => {\n this.#dispatch({ type: 'continue' })\n }\n\n const mutationFnContext = {\n client: this.#client,\n meta: this.options.meta,\n mutationKey: this.options.mutationKey,\n } satisfies MutationFunctionContext\n\n this.#retryer = createRetryer({\n fn: () => {\n if (!this.options.mutationFn) {\n return Promise.reject(new Error('No mutationFn found'))\n }\n\n return this.options.mutationFn(variables, mutationFnContext)\n },\n onFail: (failureCount, error) => {\n this.#dispatch({ type: 'failed', failureCount, error })\n },\n onPause: () => {\n this.#dispatch({ type: 'pause' })\n },\n onContinue,\n retry: this.options.retry ?? 0,\n retryDelay: this.options.retryDelay,\n networkMode: this.options.networkMode,\n canRun: () => this.#mutationCache.canRun(this),\n })\n\n const restored = this.state.status === 'pending'\n const isPaused = !this.#retryer.canStart()\n\n try {\n if (restored) {\n // Dispatch continue action to unpause restored mutation\n onContinue()\n } else {\n this.#dispatch({ type: 'pending', variables, isPaused })\n // Notify cache callback\n if (this.#mutationCache.config.onMutate) {\n await this.#mutationCache.config.onMutate(\n variables,\n this as Mutation<unknown, unknown, unknown, unknown>,\n mutationFnContext,\n )\n }\n const context = await this.options.onMutate?.(\n variables,\n mutationFnContext,\n )\n if (context !== this.state.context) {\n this.#dispatch({\n type: 'pending',\n context,\n variables,\n isPaused,\n })\n }\n }\n const data = await this.#retryer.start()\n\n // Notify cache callback\n await this.#mutationCache.config.onSuccess?.(\n data,\n variables,\n this.state.context,\n this as Mutation<unknown, unknown, unknown, unknown>,\n mutationFnContext,\n )\n\n await this.options.onSuccess?.(\n data,\n variables,\n this.state.context!,\n mutationFnContext,\n )\n\n // Notify cache callback\n await this.#mutationCache.config.onSettled?.(\n data,\n null,\n this.state.variables,\n this.state.context,\n this as Mutation<unknown, unknown, unknown, unknown>,\n mutationFnContext,\n )\n\n await this.options.onSettled?.(\n data,\n null,\n variables,\n this.state.context,\n mutationFnContext,\n )\n\n this.#dispatch({ type: 'success', data })\n return data\n } catch (error) {\n try {\n // Notify cache callback\n await this.#mutationCache.config.onError?.(\n error as any,\n variables,\n this.state.context,\n this as Mutation<unknown, unknown, unknown, unknown>,\n mutationFnContext,\n )\n } catch (e) {\n void Promise.reject(e)\n }\n\n try {\n await this.options.onError?.(\n error as TError,\n variables,\n this.state.context,\n mutationFnContext,\n )\n } catch (e) {\n void Promise.reject(e)\n }\n\n try {\n // Notify cache callback\n await this.#mutationCache.config.onSettled?.(\n undefined,\n error as any,\n this.state.variables,\n this.state.context,\n this as Mutation<unknown, unknown, unknown, unknown>,\n mutationFnContext,\n )\n } catch (e) {\n void Promise.reject(e)\n }\n\n try {\n await this.options.onSettled?.(\n undefined,\n error as TError,\n variables,\n this.state.context,\n mutationFnContext,\n )\n } catch (e) {\n void Promise.reject(e)\n }\n\n this.#dispatch({ type: 'error', error: error as TError })\n throw error\n } finally {\n this.#mutationCache.runNext(this)\n }\n }\n\n #dispatch(action: Action<TData, TError, TVariables, TOnMutateResult>): void {\n const reducer = (\n state: MutationState<TData, TError, TVariables, TOnMutateResult>,\n ): MutationState<TData, TError, TVariables, TOnMutateResult> => {\n switch (action.type) {\n case 'failed':\n return {\n ...state,\n failureCount: action.failureCount,\n failureReason: action.error,\n }\n case 'pause':\n return {\n ...state,\n isPaused: true,\n }\n case 'continue':\n return {\n ...state,\n isPaused: false,\n }\n case 'pending':\n return {\n ...state,\n context: action.context,\n data: undefined,\n failureCount: 0,\n failureReason: null,\n error: null,\n isPaused: action.isPaused,\n status: 'pending',\n variables: action.variables,\n submittedAt: Date.now(),\n }\n case 'success':\n return {\n ...state,\n data: action.data,\n failureCount: 0,\n failureReason: null,\n error: null,\n status: 'success',\n isPaused: false,\n }\n case 'error':\n return {\n ...state,\n data: undefined,\n error: action.error,\n failureCount: state.failureCount + 1,\n failureReason: action.error,\n isPaused: false,\n status: 'error',\n }\n }\n }\n this.state = reducer(this.state)\n\n notifyManager.batch(() => {\n this.#observers.forEach((observer) => {\n observer.onMutationUpdate(action)\n })\n this.#mutationCache.notify({\n mutation: this,\n type: 'updated',\n action,\n })\n })\n }\n}\n\nexport function getDefaultState<\n TData,\n TError,\n TVariables,\n TOnMutateResult,\n>(): MutationState<TData, TError, TVariables, TOnMutateResult> {\n return {\n context: undefined,\n data: undefined,\n error: null,\n failureCount: 0,\n failureReason: null,\n isPaused: false,\n status: 'idle',\n variables: undefined,\n submittedAt: 0,\n }\n}\n","import { getDefaultState } from './mutation'\nimport { notifyManager } from './notifyManager'\nimport { Subscribable } from './subscribable'\nimport { hashKey, shallowEqualObjects } from './utils'\nimport type { QueryClient } from './queryClient'\nimport type {\n DefaultError,\n MutateOptions,\n MutationFunctionContext,\n MutationObserverOptions,\n MutationObserverResult,\n} from './types'\nimport type { Action, Mutation } from './mutation'\n\n// TYPES\n\ntype MutationObserverListener<TData, TError, TVariables, TOnMutateResult> = (\n result: MutationObserverResult<TData, TError, TVariables, TOnMutateResult>,\n) => void\n\n// CLASS\n\nexport class MutationObserver<\n TData = unknown,\n TError = DefaultError,\n TVariables = void,\n TOnMutateResult = unknown,\n> extends Subscribable<\n MutationObserverListener<TData, TError, TVariables, TOnMutateResult>\n> {\n options!: MutationObserverOptions<TData, TError, TVariables, TOnMutateResult>\n\n #client: QueryClient\n #currentResult: MutationObserverResult<\n TData,\n TError,\n TVariables,\n TOnMutateResult\n > = undefined!\n #currentMutation?: Mutation<TData, TError, TVariables, TOnMutateResult>\n #mutateOptions?: MutateOptions<TData, TError, TVariables, TOnMutateResult>\n\n constructor(\n client: QueryClient,\n options: MutationObserverOptions<\n TData,\n TError,\n TVariables,\n TOnMutateResult\n >,\n ) {\n super()\n\n this.#client = client\n this.setOptions(options)\n this.bindMethods()\n this.#updateResult()\n }\n\n protected bindMethods(): void {\n this.mutate = this.mutate.bind(this)\n this.reset = this.reset.bind(this)\n }\n\n setOptions(\n options: MutationObserverOptions<\n TData,\n TError,\n TVariables,\n TOnMutateResult\n >,\n ) {\n const prevOptions = this.options as\n | MutationObserverOptions<TData, TError, TVariables, TOnMutateResult>\n | undefined\n this.options = this.#client.defaultMutationOptions(options)\n if (!shallowEqualObjects(this.options, prevOptions)) {\n this.#client.getMutationCache().notify({\n type: 'observerOptionsUpdated',\n mutation: this.#currentMutation,\n observer: this,\n })\n }\n\n if (\n prevOptions?.mutationKey &&\n this.options.mutationKey &&\n hashKey(prevOptions.mutationKey) !== hashKey(this.options.mutationKey)\n ) {\n this.reset()\n } else if (this.#currentMutation?.state.status === 'pending') {\n this.#currentMutation.setOptions(this.options)\n }\n }\n\n protected onUnsubscribe(): void {\n if (!this.hasListeners()) {\n this.#currentMutation?.removeObserver(this)\n }\n }\n\n onMutationUpdate(\n action: Action<TData, TError, TVariables, TOnMutateResult>,\n ): void {\n this.#updateResult()\n\n this.#notify(action)\n }\n\n getCurrentResult(): MutationObserverResult<\n TData,\n TError,\n TVariables,\n TOnMutateResult\n > {\n return this.#currentResult\n }\n\n reset(): void {\n // reset needs to remove the observer from the mutation because there is no way to \"get it back\"\n // another mutate call will yield a new mutation!\n this.#currentMutation?.removeObserver(this)\n this.#currentMutation = undefined\n this.#updateResult()\n this.#notify()\n }\n\n mutate(\n variables: TVariables,\n options?: MutateOptions<TData, TError, TVariables, TOnMutateResult>,\n ): Promise<TData> {\n this.#mutateOptions = options\n\n this.#currentMutation?.removeObserver(this)\n\n this.#currentMutation = this.#client\n .getMutationCache()\n .build(this.#client, this.options)\n\n this.#currentMutation.addObserver(this)\n\n return this.#currentMutation.execute(variables)\n }\n\n #updateResult(): void {\n const state =\n this.#currentMutation?.state ??\n getDefaultState<TData, TError, TVariables, TOnMutateResult>()\n\n this.#currentResult = {\n ...state,\n isPending: state.status === 'pending',\n isSuccess: state.status === 'success',\n isError: state.status === 'error',\n isIdle: state.status === 'idle',\n mutate: this.mutate,\n reset: this.reset,\n } as MutationObserverResult<TData, TError, TVariables, TOnMutateResult>\n }\n\n #notify(action?: Action<TData, TError, TVariables, TOnMutateResult>): void {\n notifyManager.batch(() => {\n // First trigger the mutate callbacks\n if (this.#mutateOptions && this.hasListeners()) {\n const variables = this.#currentResult.variables!\n const onMutateResult = this.#currentResult.context\n\n const context = {\n client: this.#client,\n meta: this.options.meta,\n mutationKey: this.options.mutationKey,\n } satisfies MutationFunctionContext\n\n if (action?.type === 'success') {\n try {\n this.#mutateOptions.onSuccess?.(\n action.data,\n variables,\n onMutateResult,\n context,\n )\n } catch (e) {\n void Promise.reject(e)\n }\n try {\n this.#mutateOptions.onSettled?.(\n action.data,\n null,\n variables,\n onMutateResult,\n context,\n )\n } catch (e) {\n void Promise.reject(e)\n }\n } else if (action?.type === 'error') {\n try {\n this.#mutateOptions.onError?.(\n action.error,\n variables,\n onMutateResult,\n context,\n )\n } catch (e) {\n void Promise.reject(e)\n }\n try {\n this.#mutateOptions.onSettled?.(\n undefined,\n action.error,\n variables,\n onMutateResult,\n context,\n )\n } catch (e) {\n void Promise.reject(e)\n }\n }\n }\n\n // Then trigger the listeners\n this.listeners.forEach((listener) => {\n listener(this.#currentResult)\n })\n })\n }\n}\n","// TYPES\n\nimport { systemSetTimeoutZero } from './timeoutManager'\n\ntype NotifyCallback = () => void\n\ntype NotifyFunction = (callback: () => void) => void\n\ntype BatchNotifyFunction = (callback: () => void) => void\n\ntype BatchCallsCallback<T extends Array<unknown>> = (...args: T) => void\n\ntype ScheduleFunction = (callback: () => void) => void\n\nexport const defaultScheduler: ScheduleFunction = systemSetTimeoutZero\n\nexport function createNotifyManager() {\n let queue: Array<NotifyCallback> = []\n let transactions = 0\n let notifyFn: NotifyFunction = (callback) => {\n callback()\n }\n let batchNotifyFn: BatchNotifyFunction = (callback: () => void) => {\n callback()\n }\n let scheduleFn = defaultScheduler\n\n const schedule = (callback: NotifyCallback): void => {\n if (transactions) {\n queue.push(callback)\n } else {\n scheduleFn(() => {\n notifyFn(callback)\n })\n }\n }\n const flush = (): void => {\n const originalQueue = queue\n queue = []\n if (originalQueue.length) {\n scheduleFn(() => {\n batchNotifyFn(() => {\n originalQueue.forEach((callback) => {\n notifyFn(callback)\n })\n })\n })\n }\n }\n\n return {\n batch: <T>(callback: () => T): T => {\n let result\n transactions++\n try {\n result = callback()\n } finally {\n transactions--\n if (!transactions) {\n flush()\n }\n }\n return result\n },\n /**\n * All calls to the wrapped function will be batched.\n */\n batchCalls: <T extends Array<unknown>>(\n callback: BatchCallsCallback<T>,\n ): BatchCallsCallback<T> => {\n return (...args) => {\n schedule(() => {\n callback(...args)\n })\n }\n },\n schedule,\n /**\n * Use this method to set a custom notify function.\n * This can be used to for example wrap notifications with `React.act` while running tests.\n */\n setNotifyFunction: (fn: NotifyFunction) => {\n notifyFn = fn\n },\n /**\n * Use this method to set a custom function to batch notifications together into a single tick.\n * By default React Query will use the batch function provided by ReactDOM or React Native.\n */\n setBatchNotifyFunction: (fn: BatchNotifyFunction) => {\n batchNotifyFn = fn\n },\n setScheduler: (fn: ScheduleFunction) => {\n scheduleFn = fn\n },\n } as const\n}\n\n// SINGLETON\nexport const notifyManager = createNotifyManager()\n","// src/query.ts\nimport {\n ensureQueryFn,\n noop,\n replaceData,\n resolveQueryBoolean,\n resolveStaleTime,\n skipToken,\n timeUntilStale\n} from \"./utils.js\";\nimport { notifyManager } from \"./notifyManager.js\";\nimport { CancelledError, canFetch, createRetryer } from \"./retryer.js\";\nimport { Removable } from \"./removable.js\";\nimport { infiniteQueryBehavior } from \"./infiniteQueryBehavior.js\";\nvar Query = class extends Removable {\n #queryType;\n #initialState;\n #revertState;\n #cache;\n #client;\n #retryer;\n #defaultOptions;\n #abortSignalConsumed;\n constructor(config) {\n super();\n this.#abortSignalConsumed = false;\n this.#defaultOptions = config.defaultOptions;\n this.setOptions(config.options);\n this.observers = [];\n this.#client = config.client;\n this.#cache = this.#client.getQueryCache();\n this.queryKey = config.queryKey;\n this.queryHash = config.queryHash;\n this.#initialState = getDefaultState(this.options);\n this.state = config.state ?? this.#initialState;\n this.scheduleGc();\n }\n get meta() {\n return this.options.meta;\n }\n get queryType() {\n return this.#queryType;\n }\n get promise() {\n return this.#retryer?.promise;\n }\n setOptions(options) {\n this.options = { ...this.#defaultOptions, ...options };\n if (options?._type) {\n this.#queryType = options._type;\n }\n this.updateGcTime(this.options.gcTime);\n if (this.state && this.state.data === void 0) {\n const defaultState = getDefaultState(this.options);\n if (defaultState.data !== void 0) {\n this.setState(\n successState(defaultState.data, defaultState.dataUpdatedAt)\n );\n this.#initialState = defaultState;\n }\n }\n }\n optionalRemove() {\n if (!this.observers.length && this.state.fetchStatus === \"idle\") {\n this.#cache.remove(this);\n }\n }\n setData(newData, options) {\n const data = replaceData(this.state.data, newData, this.options);\n this.#dispatch({\n data,\n type: \"success\",\n dataUpdatedAt: options?.updatedAt,\n manual: options?.manual\n });\n return data;\n }\n setState(state) {\n this.#dispatch({ type: \"setState\", state });\n }\n cancel(options) {\n const promise = this.#retryer?.promise;\n this.#retryer?.cancel(options);\n return promise ? promise.then(noop).catch(noop) : Promise.resolve();\n }\n destroy() {\n super.destroy();\n this.cancel({ silent: true });\n }\n get resetState() {\n return this.#initialState;\n }\n reset() {\n this.destroy();\n this.setState(this.resetState);\n }\n isActive() {\n return this.observers.some(\n (observer) => resolveQueryBoolean(observer.options.enabled, this) !== false\n );\n }\n isDisabled() {\n if (this.getObserversCount() > 0) {\n return !this.isActive();\n }\n return this.options.queryFn === skipToken || !this.isFetched();\n }\n isFetched() {\n return this.state.dataUpdateCount + this.state.errorUpdateCount > 0;\n }\n isStatic() {\n if (this.getObserversCount() > 0) {\n return this.observers.some(\n (observer) => resolveStaleTime(observer.options.staleTime, this) === \"static\"\n );\n }\n return false;\n }\n isStale() {\n if (this.getObserversCount() > 0) {\n return this.observers.some(\n (observer) => observer.getCurrentResult().isStale\n );\n }\n return this.state.data === void 0 || this.state.isInvalidated;\n }\n isStaleByTime(staleTime = 0) {\n if (this.state.data === void 0) {\n return true;\n }\n if (staleTime === \"static\") {\n return false;\n }\n if (this.state.isInvalidated) {\n return true;\n }\n return !timeUntilStale(this.state.dataUpdatedAt, staleTime);\n }\n onFocus() {\n const observer = this.observers.find((x) => x.shouldFetchOnWindowFocus());\n observer?.refetch({ cancelRefetch: false });\n this.#retryer?.continue();\n }\n onOnline() {\n const observer = this.observers.find((x) => x.shouldFetchOnReconnect());\n observer?.refetch({ cancelRefetch: false });\n this.#retryer?.continue();\n }\n addObserver(observer) {\n if (!this.observers.includes(observer)) {\n this.observers.push(observer);\n this.clearGcTimeout();\n this.#cache.notify({ type: \"observerAdded\", query: this, observer });\n }\n }\n removeObserver(observer) {\n if (this.observers.includes(observer)) {\n this.observers = this.observers.filter((x) => x !== observer);\n if (!this.observers.length) {\n if (this.#retryer) {\n if (this.#abortSignalConsumed || this.#isInitialPausedFetch()) {\n this.#retryer.cancel({ revert: true });\n } else {\n this.#retryer.cancelRetry();\n }\n }\n this.scheduleGc();\n }\n this.#cache.notify({ type: \"observerRemoved\", query: this, observer });\n }\n }\n getObserversCount() {\n return this.observers.length;\n }\n #isInitialPausedFetch() {\n return this.state.fetchStatus === \"paused\" && this.state.status === \"pending\";\n }\n invalidate() {\n if (!this.state.isInvalidated) {\n this.#dispatch({ type: \"invalidate\" });\n }\n }\n async fetch(options, fetchOptions) {\n if (this.state.fetchStatus !== \"idle\" && // If the promise in the retryer is already rejected, we have to definitely\n // re-start the fetch; there is a chance that the query is still in a\n // pending state when that happens\n this.#retryer?.status() !== \"rejected\") {\n if (this.state.data !== void 0 && fetchOptions?.cancelRefetch) {\n this.cancel({ silent: true });\n } else if (this.#retryer) {\n this.#retryer.continueRetry();\n return this.#retryer.promise;\n }\n }\n if (options) {\n this.setOptions(options);\n }\n if (!this.options.queryFn) {\n const observer = this.observers.find((x) => x.options.queryFn);\n if (observer) {\n this.setOptions(observer.options);\n }\n }\n if (process.env.NODE_ENV !== \"production\") {\n if (!Array.isArray(this.options.queryKey)) {\n console.error(\n `As of v4, queryKey needs to be an Array. If you are using a string like 'repoData', please change it to an Array, e.g. ['repoData']`\n );\n }\n }\n const abortController = new AbortController();\n const addSignalProperty = (object) => {\n Object.defineProperty(object, \"signal\", {\n enumerable: true,\n get: () => {\n this.#abortSignalConsumed = true;\n return abortController.signal;\n }\n });\n };\n const fetchFn = () => {\n const queryFn = ensureQueryFn(this.options, fetchOptions);\n const createQueryFnContext = () => {\n const queryFnContext2 = {\n client: this.#client,\n queryKey: this.queryKey,\n meta: this.meta\n };\n addSignalProperty(queryFnContext2);\n return queryFnContext2;\n };\n const queryFnContext = createQueryFnContext();\n this.#abortSignalConsumed = false;\n if (this.options.persister) {\n return this.options.persister(\n queryFn,\n queryFnContext,\n this\n );\n }\n return queryFn(queryFnContext);\n };\n const createFetchContext = () => {\n const context2 = {\n fetchOptions,\n options: this.options,\n queryKey: this.queryKey,\n client: this.#client,\n state: this.state,\n fetchFn\n };\n addSignalProperty(context2);\n return context2;\n };\n const context = createFetchContext();\n const behavior = this.#queryType === \"infinite\" ? infiniteQueryBehavior(\n this.options.pages\n ) : this.options.behavior;\n behavior?.onFetch(context, this);\n this.#revertState = this.state;\n if (this.state.fetchStatus === \"idle\" || this.state.fetchMeta !== context.fetchOptions?.meta) {\n this.#dispatch({ type: \"fetch\", meta: context.fetchOptions?.meta });\n }\n this.#retryer = createRetryer({\n initialPromise: fetchOptions?.initialPromise,\n fn: context.fetchFn,\n onCancel: (error) => {\n if (error instanceof CancelledError && error.revert) {\n this.setState({\n ...this.#revertState,\n fetchStatus: \"idle\"\n });\n }\n abortController.abort();\n },\n onFail: (failureCount, error) => {\n this.#dispatch({ type: \"failed\", failureCount, error });\n },\n onPause: () => {\n this.#dispatch({ type: \"pause\" });\n },\n onContinue: () => {\n this.#dispatch({ type: \"continue\" });\n },\n retry: context.options.retry,\n retryDelay: context.options.retryDelay,\n networkMode: context.options.networkMode,\n canRun: () => true\n });\n try {\n const data = await this.#retryer.start();\n if (data === void 0) {\n if (process.env.NODE_ENV !== \"production\") {\n console.error(\n `Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: ${this.queryHash}`\n );\n }\n throw new Error(`${this.queryHash} data is undefined`);\n }\n this.setData(data);\n this.#cache.config.onSuccess?.(data, this);\n this.#cache.config.onSettled?.(\n data,\n this.state.error,\n this\n );\n return data;\n } catch (error) {\n if (error instanceof CancelledError) {\n if (error.silent) {\n return this.#retryer.promise;\n } else if (error.revert) {\n if (this.state.data === void 0) {\n throw error;\n }\n return this.state.data;\n }\n }\n this.#dispatch({\n type: \"error\",\n error\n });\n this.#cache.config.onError?.(\n error,\n this\n );\n this.#cache.config.onSettled?.(\n this.state.data,\n error,\n this\n );\n throw error;\n } finally {\n this.scheduleGc();\n }\n }\n #dispatch(action) {\n const reducer = (state) => {\n switch (action.type) {\n case \"failed\":\n return {\n ...state,\n fetchFailureCount: action.failureCount,\n fetchFailureReason: action.error\n };\n case \"pause\":\n return {\n ...state,\n fetchStatus: \"paused\"\n };\n case \"continue\":\n return {\n ...state,\n fetchStatus: \"fetching\"\n };\n case \"fetch\":\n return {\n ...state,\n ...fetchState(state.data, this.options),\n fetchMeta: action.meta ?? null\n };\n case \"success\":\n const newState = {\n ...state,\n ...successState(action.data, action.dataUpdatedAt),\n dataUpdateCount: state.dataUpdateCount + 1,\n ...!action.manual && {\n fetchStatus: \"idle\",\n fetchFailureCount: 0,\n fetchFailureReason: null\n }\n };\n this.#revertState = action.manual ? newState : void 0;\n return newState;\n case \"error\":\n const error = action.error;\n return {\n ...state,\n error,\n errorUpdateCount: state.errorUpdateCount + 1,\n errorUpdatedAt: Date.now(),\n fetchFailureCount: state.fetchFailureCount + 1,\n fetchFailureReason: error,\n fetchStatus: \"idle\",\n status: \"error\",\n // flag existing data as invalidated if we get a background error\n // note that \"no data\" always means stale so we can set unconditionally here\n isInvalidated: true\n };\n case \"invalidate\":\n return {\n ...state,\n isInvalidated: true\n };\n case \"setState\":\n return {\n ...state,\n ...action.state\n };\n }\n };\n this.state = reducer(this.state);\n notifyManager.batch(() => {\n this.observers.forEach((observer) => {\n observer.onQueryUpdate();\n });\n this.#cache.notify({ query: this, type: \"updated\", action });\n });\n }\n};\nfunction fetchState(data, options) {\n return {\n fetchFailureCount: 0,\n fetchFailureReason: null,\n fetchStatus: canFetch(options.networkMode) ? \"fetching\" : \"paused\",\n ...data === void 0 && {\n error: null,\n status: \"pending\"\n }\n };\n}\nfunction successState(data, dataUpdatedAt) {\n return {\n data,\n dataUpdatedAt: dataUpdatedAt ?? Date.now(),\n error: null,\n isInvalidated: false,\n status: \"success\"\n };\n}\nfunction getDefaultState(options) {\n const data = typeof options.initialData === \"function\" ? options.initialData() : options.initialData;\n const hasData = data !== void 0;\n const initialDataUpdatedAt = hasData ? typeof options.initialDataUpdatedAt === \"function\" ? options.initialDataUpdatedAt() : options.initialDataUpdatedAt : 0;\n return {\n data,\n dataUpdateCount: 0,\n dataUpdatedAt: hasData ? initialDataUpdatedAt ?? Date.now() : 0,\n error: null,\n errorUpdateCount: 0,\n errorUpdatedAt: 0,\n fetchFailureCount: 0,\n fetchFailureReason: null,\n fetchMeta: null,\n isInvalidated: false,\n status: hasData ? \"success\" : \"pending\",\n fetchStatus: \"idle\"\n };\n}\nexport {\n Query,\n fetchState\n};\n//# sourceMappingURL=query.js.map","// src/infiniteQueryBehavior.ts\nimport {\n addConsumeAwareSignal,\n addToEnd,\n addToStart,\n ensureQueryFn\n} from \"./utils.js\";\nfunction infiniteQueryBehavior(pages) {\n return {\n onFetch: (context, query) => {\n const options = context.options;\n const direction = context.fetchOptions?.meta?.fetchMore?.direction;\n const oldPages = context.state.data?.pages || [];\n const oldPageParams = context.state.data?.pageParams || [];\n let result = { pages: [], pageParams: [] };\n let currentPage = 0;\n const fetchFn = async () => {\n let cancelled = false;\n const addSignalProperty = (object) => {\n addConsumeAwareSignal(\n object,\n () => context.signal,\n () => cancelled = true\n );\n };\n const queryFn = ensureQueryFn(context.options, context.fetchOptions);\n const fetchPage = async (data, param, previous) => {\n if (cancelled) {\n return Promise.reject(context.signal.reason);\n }\n if (param == null && data.pages.length) {\n return Promise.resolve(data);\n }\n const createQueryFnContext = () => {\n const queryFnContext2 = {\n client: context.client,\n queryKey: context.queryKey,\n pageParam: param,\n direction: previous ? \"backward\" : \"forward\",\n meta: context.options.meta\n };\n addSignalProperty(queryFnContext2);\n return queryFnContext2;\n };\n const queryFnContext = createQueryFnContext();\n const page = await queryFn(queryFnContext);\n const { maxPages } = context.options;\n const addTo = previous ? addToStart : addToEnd;\n return {\n pages: addTo(data.pages, page, maxPages),\n pageParams: addTo(data.pageParams, param, maxPages)\n };\n };\n if (direction && oldPages.length) {\n const previous = direction === \"backward\";\n const pageParamFn = previous ? getPreviousPageParam : getNextPageParam;\n const oldData = {\n pages: oldPages,\n pageParams: oldPageParams\n };\n const param = pageParamFn(options, oldData);\n result = await fetchPage(oldData, param, previous);\n } else {\n const remainingPages = pages ?? oldPages.length;\n do {\n const param = currentPage === 0 ? oldPageParams[0] ?? options.initialPageParam : getNextPageParam(options, result);\n if (currentPage > 0 && param == null) {\n break;\n }\n result = await fetchPage(result, param);\n currentPage++;\n } while (currentPage < remainingPages);\n }\n return result;\n };\n if (context.options.persister) {\n context.fetchFn = () => {\n return context.options.persister?.(\n fetchFn,\n {\n client: context.client,\n queryKey: context.queryKey,\n meta: context.options.meta,\n signal: context.signal\n },\n query\n );\n };\n } else {\n context.fetchFn = fetchFn;\n }\n }\n };\n}\nfunction getNextPageParam(options, { pages, pageParams }) {\n const lastIndex = pages.length - 1;\n return pages.length > 0 ? options.getNextPageParam(\n pages[lastIndex],\n pages,\n pageParams[lastIndex],\n pageParams\n ) : void 0;\n}\nfunction getPreviousPageParam(options, { pages, pageParams }) {\n return pages.length > 0 ? options.getPreviousPageParam?.(pages[0], pages, pageParams[0], pageParams) : void 0;\n}\nfunction hasNextPage(options, data) {\n if (!data) return false;\n return getNextPageParam(options, data) != null;\n}\nfunction hasPreviousPage(options, data) {\n if (!data || !options.getPreviousPageParam) return false;\n return getPreviousPageParam(options, data) != null;\n}\nexport {\n hasNextPage,\n hasPreviousPage,\n infiniteQueryBehavior\n};\n//# sourceMappingURL=infiniteQueryBehavior.js.map","import { timeoutManager } from './timeoutManager'\nimport { environmentManager } from './environmentManager'\nimport { isValidTimeout } from './utils'\nimport type { ManagedTimerId } from './timeoutManager'\n\nexport abstract class Removable {\n gcTime!: number\n #gcTimeout?: ManagedTimerId\n\n destroy(): void {\n this.clearGcTimeout()\n }\n\n protected scheduleGc(): void {\n this.clearGcTimeout()\n\n if (isValidTimeout(this.gcTime)) {\n this.#gcTimeout = timeoutManager.setTimeout(() => {\n this.optionalRemove()\n }, this.gcTime)\n }\n }\n\n protected updateGcTime(newGcTime: number | undefined): void {\n // Default to 5 minutes (Infinity for server-side) if no gcTime is set\n this.gcTime = Math.max(\n this.gcTime || 0,\n newGcTime ?? (environmentManager.isServer() ? Infinity : 5 * 60 * 1000),\n )\n }\n\n protected clearGcTimeout() {\n if (this.#gcTimeout !== undefined) {\n timeoutManager.clearTimeout(this.#gcTimeout)\n this.#gcTimeout = undefined\n }\n }\n\n protected abstract optionalRemove(): void\n}\n","import { focusManager } from './focusManager'\nimport { onlineManager } from './onlineManager'\nimport { pendingThenable } from './thenable'\nimport { environmentManager } from './environmentManager'\nimport { sleep } from './utils'\nimport type { Thenable } from './thenable'\nimport type { CancelOptions, DefaultError, NetworkMode } from './types'\n\n// TYPES\n\ninterface RetryerConfig<TData = unknown, TError = DefaultError> {\n fn: () => TData | Promise<TData>\n initialPromise?: Promise<TData>\n onCancel?: (error: TError) => void\n onFail?: (failureCount: number, error: TError) => void\n onPause?: () => void\n onContinue?: () => void\n retry?: RetryValue<TError>\n retryDelay?: RetryDelayValue<TError>\n networkMode: NetworkMode | undefined\n canRun: () => boolean\n}\n\nexport interface Retryer<TData = unknown> {\n promise: Promise<TData>\n cancel: (cancelOptions?: CancelOptions) => void\n continue: () => Promise<unknown>\n cancelRetry: () => void\n continueRetry: () => void\n canStart: () => boolean\n start: () => Promise<TData>\n status: () => 'pending' | 'resolved' | 'rejected'\n}\n\nexport type RetryValue<TError> = boolean | number | ShouldRetryFunction<TError>\n\ntype ShouldRetryFunction<TError = DefaultError> = (\n failureCount: number,\n error: TError,\n) => boolean\n\nexport type RetryDelayValue<TError> = number | RetryDelayFunction<TError>\n\ntype RetryDelayFunction<TError = DefaultError> = (\n failureCount: number,\n error: TError,\n) => number\n\nfunction defaultRetryDelay(failureCount: number) {\n return Math.min(1000 * 2 ** failureCount, 30000)\n}\n\nexport function canFetch(networkMode: NetworkMode | undefined): boolean {\n return (networkMode ?? 'online') === 'online'\n ? onlineManager.isOnline()\n : true\n}\n\nexport class CancelledError extends Error {\n revert?: boolean\n silent?: boolean\n constructor(options?: CancelOptions) {\n super('CancelledError')\n this.revert = options?.revert\n this.silent = options?.silent\n }\n}\n\n/**\n * @deprecated Use instanceof `CancelledError` instead.\n */\nexport function isCancelledError(value: any): value is CancelledError {\n return value instanceof CancelledError\n}\n\nexport function createRetryer<TData = unknown, TError = DefaultError>(\n config: RetryerConfig<TData, TError>,\n): Retryer<TData> {\n let isRetryCancelled = false\n let failureCount = 0\n let continueFn: ((value?: unknown) => void) | undefined\n\n const thenable = pendingThenable<TData>()\n\n const isResolved = () =>\n (thenable.status as Thenable<TData>['status']) !== 'pending'\n\n const cancel = (cancelOptions?: CancelOptions): void => {\n if (!isResolved()) {\n const error = new CancelledError(cancelOptions) as TError\n reject(error)\n\n config.onCancel?.(error)\n }\n }\n const cancelRetry = () => {\n isRetryCancelled = true\n }\n\n const continueRetry = () => {\n isRetryCancelled = false\n }\n\n const canContinue = () =>\n focusManager.isFocused() &&\n (config.networkMode === 'always' || onlineManager.isOnline()) &&\n config.canRun()\n\n const canStart = () => canFetch(config.networkMode) && config.canRun()\n\n const resolve = (value: any) => {\n if (!isResolved()) {\n continueFn?.()\n thenable.resolve(value)\n }\n }\n\n const reject = (value: any) => {\n if (!isResolved()) {\n continueFn?.()\n thenable.reject(value)\n }\n }\n\n const pause = () => {\n return new Promise((continueResolve) => {\n continueFn = (value) => {\n if (isResolved() || canContinue()) {\n continueResolve(value)\n }\n }\n config.onPause?.()\n }).then(() => {\n continueFn = undefined\n if (!isResolved()) {\n config.onContinue?.()\n }\n })\n }\n\n // Create loop function\n const run = () => {\n // Do nothing if already resolved\n if (isResolved()) {\n return\n }\n\n let promiseOrValue: any\n\n // we can re-use config.initialPromise on the first call of run()\n const initialPromise =\n failureCount === 0 ? config.initialPromise : undefined\n\n // Execute query\n try {\n promiseOrValue = initialPromise ?? config.fn()\n } catch (error) {\n promiseOrValue = Promise.reject(error)\n }\n\n Promise.resolve(promiseOrValue)\n .then(resolve)\n .catch((error) => {\n // Stop if the fetch is already resolved\n if (isResolved()) {\n return\n }\n\n // Do we need to retry the request?\n const retry = config.retry ?? (environmentManager.isServer() ? 0 : 3)\n const retryDelay = config.retryDelay ?? defaultRetryDelay\n const delay =\n typeof retryDelay === 'function'\n ? retryDelay(failureCount, error)\n : retryDelay\n const shouldRetry =\n retry === true ||\n (typeof retry === 'number' && failureCount < retry) ||\n (typeof retry === 'function' && retry(failureCount, error))\n\n if (isRetryCancelled || !shouldRetry) {\n // We are done if the query does not need to be retried\n reject(error)\n return\n }\n\n failureCount++\n\n // Notify on fail\n config.onFail?.(failureCount, error)\n\n // Delay\n sleep(delay)\n // Pause if the document is not visible or when the device is offline\n .then(() => {\n return canContinue() ? undefined : pause()\n })\n .then(() => {\n if (isRetryCancelled) {\n reject(error)\n } else {\n run()\n }\n })\n })\n }\n\n return {\n promise: thenable,\n status: () => thenable.status,\n cancel,\n continue: () => {\n continueFn?.()\n return thenable\n },\n cancelRetry,\n continueRetry,\n canStart,\n start: () => {\n // Start loop\n if (canStart()) {\n run()\n } else {\n pause().then(run)\n }\n return thenable\n },\n }\n}\n","/**\n * {@link TimeoutManager} does not support passing arguments to the callback.\n *\n * `(_: void)` is the argument type inferred by TypeScript's default typings for\n * `setTimeout(cb, number)`.\n * If we don't accept a single void argument, then\n * `new Promise(resolve => timeoutManager.setTimeout(resolve, N))` is a type error.\n */\nexport type TimeoutCallback = (_: void) => void\n\n/**\n * Wrapping `setTimeout` is awkward from a typing perspective because platform\n * typings may extend the return type of `setTimeout`. For example, NodeJS\n * typings add `NodeJS.Timeout`; but a non-default `timeoutManager` may not be\n * able to return such a type.\n */\nexport type ManagedTimerId = number | { [Symbol.toPrimitive]: () => number }\n\n/**\n * Backend for timer functions.\n */\nexport type TimeoutProvider<TTimerId extends ManagedTimerId = ManagedTimerId> =\n {\n readonly setTimeout: (callback: TimeoutCallback, delay: number) => TTimerId\n readonly clearTimeout: (timeoutId: TTimerId | undefined) => void\n\n readonly setInterval: (callback: TimeoutCallback, delay: number) => TTimerId\n readonly clearInterval: (intervalId: TTimerId | undefined) => void\n }\n\ntype SystemTimerId = ReturnType<typeof setTimeout>\n\nexport const defaultTimeoutProvider: TimeoutProvider = {\n // We need the wrapper function syntax below instead of direct references to\n // global setTimeout etc.\n //\n // BAD: `setTimeout: setTimeout`\n // GOOD: `setTimeout: (cb, delay) => setTimeout(cb, delay)`\n //\n // If we use direct references here, then anything that wants to spy on or\n // replace the global setTimeout (like tests) won't work since we'll already\n // have a hard reference to the original implementation at the time when this\n // file was imported.\n setTimeout: (callback, delay) => setTimeout(callback, delay),\n clearTimeout: (timeoutId) =>\n clearTimeout(timeoutId as SystemTimerId | undefined),\n\n setInterval: (callback, delay) => setInterval(callback, delay),\n clearInterval: (intervalId) =>\n clearInterval(intervalId as SystemTimerId | undefined),\n}\n\n/**\n * Allows customization of how timeouts are created.\n *\n * @tanstack/query-core makes liberal use of timeouts to implement `staleTime`\n * and `gcTime`. The default TimeoutManager provider uses the platform's global\n * `setTimeout` implementation, which is known to have scalability issues with\n * thousands of timeouts on the event loop.\n *\n * If you hit this limitation, consider providing a custom TimeoutProvider that\n * coalesces timeouts.\n */\nexport class TimeoutManager implements Omit<TimeoutProvider, 'name'> {\n // We cannot have TimeoutManager<T> as we must instantiate it with a concrete\n // type at app boot; and if we leave that type, then any new timer provider\n // would need to support the default provider's concrete timer ID, which is\n // infeasible across environments.\n //\n // We settle for type safety for the TimeoutProvider type, and accept that\n // this class is unsafe internally to allow for extension.\n #provider: TimeoutProvider<any> = defaultTimeoutProvider\n #providerCalled = false\n\n setTimeoutProvider<TTimerId extends ManagedTimerId>(\n provider: TimeoutProvider<TTimerId>,\n ): void {\n if (process.env.NODE_ENV !== 'production') {\n if (this.#providerCalled && provider !== this.#provider) {\n // After changing providers, `clearTimeout` will not work as expected for\n // timeouts from the previous provider.\n //\n // Since they may allocate the same timeout ID, clearTimeout may cancel an\n // arbitrary different timeout, or unexpected no-op.\n //\n // We could protect against this by mixing the timeout ID bits\n // deterministically with some per-provider bits.\n //\n // We could internally queue `setTimeout` calls to `TimeoutManager` until\n // some API call to set the initial provider.\n console.error(\n `[timeoutManager]: Switching provider after calls to previous provider might result in unexpected behavior.`,\n { previous: this.#provider, provider },\n )\n }\n }\n\n this.#provider = provider\n if (process.env.NODE_ENV !== 'production') {\n this.#providerCalled = false\n }\n }\n\n setTimeout(callback: TimeoutCallback, delay: number): ManagedTimerId {\n if (process.env.NODE_ENV !== 'production') {\n this.#providerCalled = true\n }\n return this.#provider.setTimeout(callback, delay)\n }\n\n clearTimeout(timeoutId: ManagedTimerId | undefined): void {\n this.#provider.clearTimeout(timeoutId)\n }\n\n setInterval(callback: TimeoutCallback, delay: number): ManagedTimerId {\n if (process.env.NODE_ENV !== 'production') {\n this.#providerCalled = true\n }\n return this.#provider.setInterval(callback, delay)\n }\n\n clearInterval(intervalId: ManagedTimerId | undefined): void {\n this.#provider.clearInterval(intervalId)\n }\n}\n\nexport const timeoutManager = new TimeoutManager()\n\n/**\n * In many cases code wants to delay to the next event loop tick; this is not\n * mediated by {@link timeoutManager}.\n *\n * This function is provided to make auditing the `tanstack/query-core` for\n * incorrect use of system `setTimeout` easier.\n */\nexport function systemSetTimeoutZero(callback: TimeoutCallback): void {\n setTimeout(callback, 0)\n}\n","import { timeoutManager } from './timeoutManager'\nimport type {\n DefaultError,\n FetchStatus,\n MutationKey,\n MutationStatus,\n QueryBooleanOption,\n QueryFunction,\n QueryKey,\n QueryOptions,\n StaleTime,\n StaleTimeFunction,\n} from './types'\nimport type { Mutation } from './mutation'\nimport type { FetchOptions, Query } from './query'\n\n// TYPES\n\ntype DropLast<T extends ReadonlyArray<unknown>> = T extends readonly [\n ...infer R,\n unknown,\n]\n ? readonly [...R]\n : never\n\ntype TuplePrefixes<T extends ReadonlyArray<unknown>> = T extends readonly []\n ? readonly []\n : TuplePrefixes<DropLast<T>> | T\n\nexport interface QueryFilters<TQueryKey extends QueryKey = QueryKey> {\n /**\n * Filter to active queries, inactive queries or all queries\n */\n type?: QueryTypeFilter\n /**\n * Match query key exactly\n */\n exact?: boolean\n /**\n * Include queries matching this predicate function\n */\n predicate?: (query: Query) => boolean\n /**\n * Include queries matching this query key\n */\n queryKey?: TQueryKey | TuplePrefixes<TQueryKey>\n /**\n * Include or exclude stale queries\n */\n stale?: boolean\n /**\n * Include queries matching their fetchStatus\n */\n fetchStatus?: FetchStatus\n}\n\nexport interface MutationFilters<\n TData = unknown,\n TError = DefaultError,\n TVariables = unknown,\n TOnMutateResult = unknown,\n> {\n /**\n * Match mutation key exactly\n */\n exact?: boolean\n /**\n * Include mutations matching this predicate function\n */\n predicate?: (\n mutation: Mutation<TData, TError, TVariables, TOnMutateResult>,\n ) => boolean\n /**\n * Include mutations matching this mutation key\n */\n mutationKey?: TuplePrefixes<MutationKey>\n /**\n * Filter by mutation status\n */\n status?: MutationStatus\n}\n\nexport type Updater<TInput, TOutput> = TOutput | ((input: TInput) => TOutput)\n\nexport type QueryTypeFilter = 'all' | 'active' | 'inactive'\n\n// UTILS\n\n/** @deprecated\n * use `environmentManager.isServer()` instead.\n */\nexport const isServer = typeof window === 'undefined' || 'Deno' in globalThis\n\nexport function noop(): void\nexport function noop(): undefined\nexport function noop() {}\n\nexport function functionalUpdate<TInput, TOutput>(\n updater: Updater<TInput, TOutput>,\n input: TInput,\n): TOutput {\n return typeof updater === 'function'\n ? (updater as (_: TInput) => TOutput)(input)\n : updater\n}\n\nexport function isValidTimeout(value: unknown): value is number {\n return typeof value === 'number' && value >= 0 && value !== Infinity\n}\n\nexport function timeUntilStale(updatedAt: number, staleTime?: number): number {\n return Math.max(updatedAt + (staleTime || 0) - Date.now(), 0)\n}\n\nexport function resolveStaleTime<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n staleTime:\n | undefined\n | StaleTimeFunction<TQueryFnData, TError, TData, TQueryKey>,\n query: Query<TQueryFnData, TError, TData, TQueryKey>,\n): StaleTime | undefined {\n return typeof staleTime === 'function' ? staleTime(query) : staleTime\n}\n\nexport function resolveQueryBoolean<\n TQueryFnData = unknown,\n TError = DefaultError,\n TData = TQueryFnData,\n TQueryKey extends QueryKey = QueryKey,\n>(\n option:\n | undefined\n | QueryBooleanOption<TQueryFnData, TError, TData, TQueryKey>,\n query: Query<TQueryFnData, TError, TData, TQueryKey>,\n): boolean | undefined {\n return typeof option === 'function' ? option(query) : option\n}\n\nexport function matchQuery(\n filters: QueryFilters,\n query: Query<any, any, any, any>,\n): boolean {\n const {\n type = 'all',\n exact,\n fetchStatus,\n predicate,\n queryKey,\n stale,\n } = filters\n\n if (queryKey) {\n if (exact) {\n if (query.queryHash !== hashQueryKeyByOptions(queryKey, query.options)) {\n return false\n }\n } else if (!partialMatchKey(query.queryKey, queryKey)) {\n return false\n }\n }\n\n if (type !== 'all') {\n const isActive = query.isActive()\n if (type === 'active' && !isActive) {\n return false\n }\n if (type === 'inactive' && isActive) {\n return false\n }\n }\n\n if (typeof stale === 'boolean' && query.isStale() !== stale) {\n return false\n }\n\n if (fetchStatus && fetchStatus !== query.state.fetchStatus) {\n return false\n }\n\n if (predicate && !predicate(query)) {\n return false\n }\n\n return true\n}\n\nexport function matchMutation(\n filters: MutationFilters,\n mutation: Mutation<any, any>,\n): boolean {\n const { exact, status, predicate, mutationKey } = filters\n if (mutationKey) {\n if (!mutation.options.mutationKey) {\n return false\n }\n if (exact) {\n if (hashKey(mutation.options.mutationKey) !== hashKey(mutationKey)) {\n return false\n }\n } else if (!partialMatchKey(mutation.options.mutationKey, mutationKey)) {\n return false\n }\n }\n\n if (status && mutation.state.status !== status) {\n return false\n }\n\n if (predicate && !predicate(mutation)) {\n return false\n }\n\n return true\n}\n\nexport function hashQueryKeyByOptions<TQueryKey extends QueryKey = QueryKey>(\n queryKey: TQueryKey,\n options?: Pick<QueryOptions<any, any, any, any>, 'queryKeyHashFn'>,\n): string {\n const hashFn = options?.queryKeyHashFn || hashKey\n return hashFn(queryKey)\n}\n\n/**\n * Default query & mutation keys hash function.\n * Hashes the value into a stable hash.\n */\nexport function hashKey(queryKey: QueryKey | MutationKey): string {\n return JSON.stringify(queryKey, (_, val) =>\n isPlainObject(val)\n ? Object.keys(val)\n .sort()\n .reduce((result, key) => {\n result[key] = val[key]\n return result\n }, {} as any)\n : val,\n )\n}\n\n/**\n * Checks if key `b` partially matches with key `a`.\n */\nexport function partialMatchKey(a: QueryKey, b: QueryKey): boolean\nexport function partialMatchKey(a: any, b: any): boolean {\n if (a === b) {\n return true\n }\n\n if (typeof a !== typeof b) {\n return false\n }\n\n if (a && b && typeof a === 'object' && typeof b === 'object') {\n return Object.keys(b).every((key) => partialMatchKey(a[key], b[key]))\n }\n\n return false\n}\n\nconst hasOwn = Object.prototype.hasOwnProperty\n\n/**\n * This function returns `a` if `b` is deeply equal.\n * If not, it will replace any deeply equal children of `b` with those of `a`.\n * This can be used for structural sharing between JSON values for example.\n */\nexport function replaceEqualDeep<T>(a: unknown, b: T, depth?: number): T\nexport function replaceEqualDeep(a: any, b: any, depth = 0): any {\n if (a === b) {\n return a\n }\n\n if (depth > 500) return b\n\n const array = isPlainArray(a) && isPlainArray(b)\n\n if (!array && !(isPlainObject(a) && isPlainObject(b))) return b\n\n const aItems = array ? a : Object.keys(a)\n const aSize = aItems.length\n const bItems = array ? b : Object.keys(b)\n const bSize = bItems.length\n const copy: any = array ? new Array(bSize) : {}\n\n let equalItems = 0\n\n for (let i = 0; i < bSize; i++) {\n const key: any = array ? i : bItems[i]\n const aItem = a[key]\n const bItem = b[key]\n\n if (aItem === bItem) {\n copy[key] = aItem\n if (array ? i < aSize : hasOwn.call(a, key)) equalItems++\n continue\n }\n\n if (\n aItem === null ||\n bItem === null ||\n typeof aItem !== 'object' ||\n typeof bItem !== 'object'\n ) {\n copy[key] = bItem\n continue\n }\n\n const v = replaceEqualDeep(aItem, bItem, depth + 1)\n copy[key] = v\n if (v === aItem) equalItems++\n }\n\n return aSize === bSize && equalItems === aSize ? a : copy\n}\n\n/**\n * Shallow compare objects.\n */\nexport function shallowEqualObjects<T extends Record<string, any>>(\n a: T,\n b: T | undefined,\n): boolean {\n if (!b || Object.keys(a).length !== Object.keys(b).length) {\n return false\n }\n\n for (const key in a) {\n if (a[key] !== b[key]) {\n return false\n }\n }\n\n return true\n}\n\nexport function isPlainArray(value: unknown): value is Array<unknown> {\n return Array.isArray(value) && value.length === Object.keys(value).length\n}\n\n// Copied from: https://github.com/jonschlinkert/is-plain-object\nexport function isPlainObject(o: any): o is Record<PropertyKey, unknown> {\n if (!hasObjectPrototype(o)) {\n return false\n }\n\n // If has no constructor\n const ctor = o.constructor\n if (ctor === undefined) {\n return true\n }\n\n // If has modified prototype\n const prot = ctor.prototype\n if (!hasObjectPrototype(prot)) {\n return false\n }\n\n // If constructor does not have an Object-specific method\n if (!prot.hasOwnProperty('isPrototypeOf')) {\n return false\n }\n\n // Handles Objects created by Object.create(<arbitrary prototype>)\n if (Object.getPrototypeOf(o) !== Object.prototype) {\n return false\n }\n\n // Most likely a plain Object\n return true\n}\n\nfunction hasObjectPrototype(o: any): boolean {\n return Object.prototype.toString.call(o) === '[object Object]'\n}\n\nexport function sleep(timeout: number): Promise<void> {\n return new Promise((resolve) => {\n timeoutManager.setTimeout(resolve, timeout)\n })\n}\n\nexport function replaceData<\n TData,\n TOptions extends QueryOptions<any, any, any, any>,\n>(prevData: TData | undefined, data: TData, options: TOptions): TData {\n if (typeof options.structuralSharing === 'function') {\n return options.structuralSharing(prevData, data) as TData\n } else if (options.structuralSharing !== false) {\n if (process.env.NODE_ENV !== 'production') {\n try {\n return replaceEqualDeep(prevData, data)\n } catch (error) {\n console.error(\n `Structural sharing requires data to be JSON serializable. To fix this, turn off structuralSharing or return JSON-serializable data from your queryFn. [${options.queryHash}]: ${error}`,\n )\n\n // Prevent the replaceEqualDeep from being called again down below.\n throw error\n }\n }\n // Structurally share data between prev and new data if needed\n return replaceEqualDeep(prevData, data)\n }\n return data\n}\n\nexport function keepPreviousData<T>(\n previousData: T | undefined,\n): T | undefined {\n return previousData\n}\n\nexport function addToEnd<T>(items: Array<T>, item: T, max = 0): Array<T> {\n const newItems = [...items, item]\n return max && newItems.length > max ? newItems.slice(1) : newItems\n}\n\nexport function addToStart<T>(items: Array<T>, item: T, max = 0): Array<T> {\n const newItems = [item, ...items]\n return max && newItems.length > max ? newItems.slice(0, -1) : newItems\n}\n\nexport const skipToken = Symbol()\nexport type SkipToken = typeof skipToken\n\nexport function ensureQueryFn<\n TQueryFnData = unknown,\n TQueryKey extends QueryKey = QueryKey,\n>(\n options: {\n queryFn?: QueryFunction<TQueryFnData, TQueryKey> | SkipToken\n queryHash?: string\n },\n fetchOptions?: FetchOptions<TQueryFnData>,\n): QueryFunction<TQueryFnData, TQueryKey> {\n if (process.env.NODE_ENV !== 'production') {\n if (options.queryFn === skipToken) {\n console.error(\n `Attempted to invoke queryFn when set to skipToken. This is likely a configuration error. Query hash: '${options.queryHash}'`,\n )\n }\n }\n\n // if we attempt to retry a fetch that was triggered from an initialPromise\n // when we don't have a queryFn yet, we can't retry, so we just return the already rejected initialPromise\n // if an observer has already mounted, we will be able to retry with that queryFn\n if (!options.queryFn && fetchOptions?.initialPromise) {\n return () => fetchOptions.initialPromise!\n }\n\n if (!options.queryFn || options.queryFn === skipToken) {\n return () =>\n Promise.reject(new Error(`Missing queryFn: '${options.queryHash}'`))\n }\n\n return options.queryFn\n}\n\nexport function shouldThrowError<T extends (...args: Array<any>) => boolean>(\n throwOnError: boolean | T | undefined,\n params: Parameters<T>,\n): boolean {\n // Allow throwOnError function to override throwing behavior on a per-error basis\n if (typeof throwOnError === 'function') {\n return throwOnError(...params)\n }\n\n return !!throwOnError\n}\n\nexport function addConsumeAwareSignal<T>(\n object: T,\n getSignal: () => AbortSignal,\n onCancelled: VoidFunction,\n): T & { signal: AbortSignal } {\n let consumed = false\n let signal: AbortSignal | undefined\n\n Object.defineProperty(object, 'signal', {\n enumerable: true,\n get: () => {\n signal ??= getSignal()\n if (consumed) {\n return signal\n }\n\n consumed = true\n if (signal.aborted) {\n onCancelled()\n } else {\n signal.addEventListener('abort', onCancelled, { once: true })\n }\n\n return signal\n },\n })\n\n return object as T & { signal: AbortSignal }\n}\n","'use client'\nimport * as React from 'react'\n\nimport type { QueryClient } from '@tanstack/query-core'\n\nexport const QueryClientContext = React.createContext<QueryClient | undefined>(\n undefined,\n)\n\nexport const useQueryClient = (queryClient?: QueryClient) => {\n const client = React.useContext(QueryClientContext)\n\n if (queryClient) {\n return queryClient\n }\n\n if (!client) {\n throw new Error('No QueryClient set, use QueryClientProvider to set one')\n }\n\n return client\n}\n\nexport type QueryClientProviderProps = {\n client: QueryClient\n children?: React.ReactNode\n}\n\nexport const QueryClientProvider = ({\n client,\n children,\n}: QueryClientProviderProps): React.JSX.Element => {\n React.useEffect(() => {\n client.mount()\n return () => {\n client.unmount()\n }\n }, [client])\n\n return (\n <QueryClientContext.Provider value={client}>\n {children}\n </QueryClientContext.Provider>\n )\n}\n","'use client'\nimport * as React from 'react'\nimport {\n MutationObserver,\n noop,\n notifyManager,\n shouldThrowError,\n} from '@tanstack/query-core'\nimport { useQueryClient } from './QueryClientProvider'\nimport type {\n UseMutateFunction,\n UseMutationOptions,\n UseMutationResult,\n} from './types'\nimport type { DefaultError, QueryClient } from '@tanstack/query-core'\n\n// HOOK\n\nexport function useMutation<\n TData = unknown,\n TError = DefaultError,\n TVariables = void,\n TOnMutateResult = unknown,\n>(\n options: UseMutationOptions<TData, TError, TVariables, TOnMutateResult>,\n queryClient?: QueryClient,\n): UseMutationResult<TData, TError, TVariables, TOnMutateResult> {\n const client = useQueryClient(queryClient)\n\n const [observer] = React.useState(\n () =>\n new MutationObserver<TData, TError, TVariables, TOnMutateResult>(\n client,\n options,\n ),\n )\n\n React.useEffect(() => {\n observer.setOptions(options)\n }, [observer, options])\n\n const result = React.useSyncExternalStore(\n React.useCallback(\n (onStoreChange) =>\n observer.subscribe(notifyManager.batchCalls(onStoreChange)),\n [observer],\n ),\n () => observer.getCurrentResult(),\n () => observer.getCurrentResult(),\n )\n\n const mutate = React.useCallback<\n UseMutateFunction<TData, TError, TVariables, TOnMutateResult>\n >(\n (variables, mutateOptions) => {\n observer.mutate(variables, mutateOptions).catch(noop)\n },\n [observer],\n )\n\n if (\n result.error &&\n shouldThrowError(observer.options.throwOnError, [result.error])\n ) {\n throw result.error\n }\n\n return { ...result, mutate, mutateAsync: result.mutate }\n}\n","\"use client\";\n\n// src/useQuery.ts\nimport { QueryObserver } from \"@tanstack/query-core\";\nimport { useBaseQuery } from \"./useBaseQuery.js\";\nfunction useQuery(options, queryClient) {\n return useBaseQuery(options, QueryObserver, queryClient);\n}\nexport {\n useQuery\n};\n//# sourceMappingURL=useQuery.js.map","// src/queryObserver.ts\nimport { focusManager } from \"./focusManager.js\";\nimport { environmentManager } from \"./environmentManager.js\";\nimport { notifyManager } from \"./notifyManager.js\";\nimport { fetchState } from \"./query.js\";\nimport { Subscribable } from \"./subscribable.js\";\nimport { pendingThenable } from \"./thenable.js\";\nimport {\n isValidTimeout,\n noop,\n replaceData,\n resolveQueryBoolean,\n resolveStaleTime,\n shallowEqualObjects,\n timeUntilStale\n} from \"./utils.js\";\nimport { timeoutManager } from \"./timeoutManager.js\";\nvar QueryObserver = class extends Subscribable {\n constructor(client, options) {\n super();\n this.options = options;\n this.#client = client;\n this.#selectError = null;\n this.#currentThenable = pendingThenable();\n this.bindMethods();\n this.setOptions(options);\n }\n #client;\n #currentQuery = void 0;\n #currentQueryInitialState = void 0;\n #currentResult = void 0;\n #currentResultState;\n #currentResultOptions;\n #currentThenable;\n #selectError;\n #selectFn;\n #selectResult;\n // This property keeps track of the last query with defined data.\n // It will be used to pass the previous data and query to the placeholder function between renders.\n #lastQueryWithDefinedData;\n #staleTimeoutId;\n #refetchIntervalId;\n #currentRefetchInterval;\n #trackedProps = /* @__PURE__ */ new Set();\n bindMethods() {\n this.refetch = this.refetch.bind(this);\n }\n onSubscribe() {\n if (this.listeners.size === 1) {\n this.#currentQuery.addObserver(this);\n if (shouldFetchOnMount(this.#currentQuery, this.options)) {\n this.#executeFetch();\n } else {\n this.updateResult();\n }\n this.#updateTimers();\n }\n }\n onUnsubscribe() {\n if (!this.hasListeners()) {\n this.destroy();\n }\n }\n shouldFetchOnReconnect() {\n return shouldFetchOn(\n this.#currentQuery,\n this.options,\n this.options.refetchOnReconnect\n );\n }\n shouldFetchOnWindowFocus() {\n return shouldFetchOn(\n this.#currentQuery,\n this.options,\n this.options.refetchOnWindowFocus\n );\n }\n destroy() {\n this.listeners = /* @__PURE__ */ new Set();\n this.#clearStaleTimeout();\n this.#clearRefetchInterval();\n this.#currentQuery.removeObserver(this);\n }\n setOptions(options) {\n const prevOptions = this.options;\n const prevQuery = this.#currentQuery;\n this.options = this.#client.defaultQueryOptions(options);\n if (this.options.enabled !== void 0 && typeof this.options.enabled !== \"boolean\" && typeof this.options.enabled !== \"function\" && typeof resolveQueryBoolean(this.options.enabled, this.#currentQuery) !== \"boolean\") {\n throw new Error(\n \"Expected enabled to be a boolean or a callback that returns a boolean\"\n );\n }\n this.#updateQuery();\n this.#currentQuery.setOptions(this.options);\n if (prevOptions._defaulted && !shallowEqualObjects(this.options, prevOptions)) {\n this.#client.getQueryCache().notify({\n type: \"observerOptionsUpdated\",\n query: this.#currentQuery,\n observer: this\n });\n }\n const mounted = this.hasListeners();\n if (mounted && shouldFetchOptionally(\n this.#currentQuery,\n prevQuery,\n this.options,\n prevOptions\n )) {\n this.#executeFetch();\n }\n this.updateResult();\n if (mounted && (this.#currentQuery !== prevQuery || resolveQueryBoolean(this.options.enabled, this.#currentQuery) !== resolveQueryBoolean(prevOptions.enabled, this.#currentQuery) || resolveStaleTime(this.options.staleTime, this.#currentQuery) !== resolveStaleTime(prevOptions.staleTime, this.#currentQuery))) {\n this.#updateStaleTimeout();\n }\n const nextRefetchInterval = this.#computeRefetchInterval();\n if (mounted && (this.#currentQuery !== prevQuery || resolveQueryBoolean(this.options.enabled, this.#currentQuery) !== resolveQueryBoolean(prevOptions.enabled, this.#currentQuery) || nextRefetchInterval !== this.#currentRefetchInterval)) {\n this.#updateRefetchInterval(nextRefetchInterval);\n }\n }\n getOptimisticResult(options) {\n const query = this.#client.getQueryCache().build(this.#client, options);\n const result = this.createResult(query, options);\n if (shouldAssignObserverCurrentProperties(this, result)) {\n this.#currentResult = result;\n this.#currentResultOptions = this.options;\n this.#currentResultState = this.#currentQuery.state;\n }\n return result;\n }\n getCurrentResult() {\n return this.#currentResult;\n }\n trackResult(result, onPropTracked) {\n return new Proxy(result, {\n get: (target, key) => {\n this.trackProp(key);\n onPropTracked?.(key);\n if (key === \"promise\") {\n this.trackProp(\"data\");\n if (!this.options.experimental_prefetchInRender && this.#currentThenable.status === \"pending\") {\n this.#currentThenable.reject(\n new Error(\n \"experimental_prefetchInRender feature flag is not enabled\"\n )\n );\n }\n }\n return Reflect.get(target, key);\n }\n });\n }\n trackProp(key) {\n this.#trackedProps.add(key);\n }\n getCurrentQuery() {\n return this.#currentQuery;\n }\n refetch({ ...options } = {}) {\n return this.fetch({\n ...options\n });\n }\n fetchOptimistic(options) {\n const defaultedOptions = this.#client.defaultQueryOptions(options);\n const query = this.#client.getQueryCache().build(this.#client, defaultedOptions);\n return query.fetch().then(() => this.createResult(query, defaultedOptions));\n }\n fetch(fetchOptions) {\n return this.#executeFetch({\n ...fetchOptions,\n cancelRefetch: fetchOptions.cancelRefetch ?? true\n }).then(() => {\n this.updateResult();\n return this.#currentResult;\n });\n }\n #executeFetch(fetchOptions) {\n this.#updateQuery();\n let promise = this.#currentQuery.fetch(\n this.options,\n fetchOptions\n );\n if (!fetchOptions?.throwOnError) {\n promise = promise.catch(noop);\n }\n return promise;\n }\n #updateStaleTimeout() {\n this.#clearStaleTimeout();\n const staleTime = resolveStaleTime(\n this.options.staleTime,\n this.#currentQuery\n );\n if (environmentManager.isServer() || this.#currentResult.isStale || !isValidTimeout(staleTime)) {\n return;\n }\n const time = timeUntilStale(this.#currentResult.dataUpdatedAt, staleTime);\n const timeout = time + 1;\n this.#staleTimeoutId = timeoutManager.setTimeout(() => {\n if (!this.#currentResult.isStale) {\n this.updateResult();\n }\n }, timeout);\n }\n #computeRefetchInterval() {\n return (typeof this.options.refetchInterval === \"function\" ? this.options.refetchInterval(this.#currentQuery) : this.options.refetchInterval) ?? false;\n }\n #updateRefetchInterval(nextInterval) {\n this.#clearRefetchInterval();\n this.#currentRefetchInterval = nextInterval;\n if (environmentManager.isServer() || resolveQueryBoolean(this.options.enabled, this.#currentQuery) === false || !isValidTimeout(this.#currentRefetchInterval) || this.#currentRefetchInterval === 0) {\n return;\n }\n this.#refetchIntervalId = timeoutManager.setInterval(() => {\n if (this.options.refetchIntervalInBackground || focusManager.isFocused()) {\n this.#executeFetch();\n }\n }, this.#currentRefetchInterval);\n }\n #updateTimers() {\n this.#updateStaleTimeout();\n this.#updateRefetchInterval(this.#computeRefetchInterval());\n }\n #clearStaleTimeout() {\n if (this.#staleTimeoutId !== void 0) {\n timeoutManager.clearTimeout(this.#staleTimeoutId);\n this.#staleTimeoutId = void 0;\n }\n }\n #clearRefetchInterval() {\n if (this.#refetchIntervalId !== void 0) {\n timeoutManager.clearInterval(this.#refetchIntervalId);\n this.#refetchIntervalId = void 0;\n }\n }\n createResult(query, options) {\n const prevQuery = this.#currentQuery;\n const prevOptions = this.options;\n const prevResult = this.#currentResult;\n const prevResultState = this.#currentResultState;\n const prevResultOptions = this.#currentResultOptions;\n const queryChange = query !== prevQuery;\n const queryInitialState = queryChange ? query.state : this.#currentQueryInitialState;\n const { state } = query;\n let newState = { ...state };\n let isPlaceholderData = false;\n let data;\n if (options._optimisticResults) {\n const mounted = this.hasListeners();\n const fetchOnMount = !mounted && shouldFetchOnMount(query, options);\n const fetchOptionally = mounted && shouldFetchOptionally(query, prevQuery, options, prevOptions);\n if (fetchOnMount || fetchOptionally) {\n newState = {\n ...newState,\n ...fetchState(state.data, query.options)\n };\n }\n if (options._optimisticResults === \"isRestoring\") {\n newState.fetchStatus = \"idle\";\n }\n }\n let { error, errorUpdatedAt, status } = newState;\n data = newState.data;\n let skipSelect = false;\n if (options.placeholderData !== void 0 && data === void 0 && status === \"pending\") {\n let placeholderData;\n if (prevResult?.isPlaceholderData && options.placeholderData === prevResultOptions?.placeholderData) {\n placeholderData = prevResult.data;\n skipSelect = true;\n } else {\n placeholderData = typeof options.placeholderData === \"function\" ? options.placeholderData(\n this.#lastQueryWithDefinedData?.state.data,\n this.#lastQueryWithDefinedData\n ) : options.placeholderData;\n }\n if (placeholderData !== void 0) {\n status = \"success\";\n data = replaceData(\n prevResult?.data,\n placeholderData,\n options\n );\n isPlaceholderData = true;\n }\n }\n if (options.select && data !== void 0 && !skipSelect) {\n if (prevResult && data === prevResultState?.data && options.select === this.#selectFn) {\n data = this.#selectResult;\n } else {\n try {\n this.#selectFn = options.select;\n data = options.select(data);\n data = replaceData(prevResult?.data, data, options);\n this.#selectResult = data;\n this.#selectError = null;\n } catch (selectError) {\n this.#selectError = selectError;\n }\n }\n }\n if (this.#selectError) {\n error = this.#selectError;\n data = this.#selectResult;\n errorUpdatedAt = Date.now();\n status = \"error\";\n }\n const isFetching = newState.fetchStatus === \"fetching\";\n const isPending = status === \"pending\";\n const isError = status === \"error\";\n const isLoading = isPending && isFetching;\n const hasData = data !== void 0;\n const result = {\n status,\n fetchStatus: newState.fetchStatus,\n isPending,\n isSuccess: status === \"success\",\n isError,\n isInitialLoading: isLoading,\n isLoading,\n data,\n dataUpdatedAt: newState.dataUpdatedAt,\n error,\n errorUpdatedAt,\n failureCount: newState.fetchFailureCount,\n failureReason: newState.fetchFailureReason,\n errorUpdateCount: newState.errorUpdateCount,\n isFetched: query.isFetched(),\n isFetchedAfterMount: newState.dataUpdateCount > queryInitialState.dataUpdateCount || newState.errorUpdateCount > queryInitialState.errorUpdateCount,\n isFetching,\n isRefetching: isFetching && !isPending,\n isLoadingError: isError && !hasData,\n isPaused: newState.fetchStatus === \"paused\",\n isPlaceholderData,\n isRefetchError: isError && hasData,\n isStale: isStale(query, options),\n refetch: this.refetch,\n promise: this.#currentThenable,\n isEnabled: resolveQueryBoolean(options.enabled, query) !== false\n };\n const nextResult = result;\n if (this.options.experimental_prefetchInRender) {\n const hasResultData = nextResult.data !== void 0;\n const isErrorWithoutData = nextResult.status === \"error\" && !hasResultData;\n const finalizeThenableIfPossible = (thenable) => {\n if (isErrorWithoutData) {\n thenable.reject(nextResult.error);\n } else if (hasResultData) {\n thenable.resolve(nextResult.data);\n }\n };\n const recreateThenable = () => {\n const pending = this.#currentThenable = nextResult.promise = pendingThenable();\n finalizeThenableIfPossible(pending);\n };\n const prevThenable = this.#currentThenable;\n switch (prevThenable.status) {\n case \"pending\":\n if (query.queryHash === prevQuery.queryHash) {\n finalizeThenableIfPossible(prevThenable);\n }\n break;\n case \"fulfilled\":\n if (isErrorWithoutData || nextResult.data !== prevThenable.value) {\n recreateThenable();\n }\n break;\n case \"rejected\":\n if (!isErrorWithoutData || nextResult.error !== prevThenable.reason) {\n recreateThenable();\n }\n break;\n }\n }\n return nextResult;\n }\n updateResult() {\n const prevResult = this.#currentResult;\n const nextResult = this.createResult(this.#currentQuery, this.options);\n this.#currentResultState = this.#currentQuery.state;\n this.#currentResultOptions = this.options;\n if (this.#currentResultState.data !== void 0) {\n this.#lastQueryWithDefinedData = this.#currentQuery;\n }\n if (shallowEqualObjects(nextResult, prevResult)) {\n return;\n }\n this.#currentResult = nextResult;\n const shouldNotifyListeners = () => {\n if (!prevResult) {\n return true;\n }\n const { notifyOnChangeProps } = this.options;\n const notifyOnChangePropsValue = typeof notifyOnChangeProps === \"function\" ? notifyOnChangeProps() : notifyOnChangeProps;\n if (notifyOnChangePropsValue === \"all\" || !notifyOnChangePropsValue && !this.#trackedProps.size) {\n return true;\n }\n const includedProps = new Set(\n notifyOnChangePropsValue ?? this.#trackedProps\n );\n if (this.options.throwOnError) {\n includedProps.add(\"error\");\n }\n return Object.keys(this.#currentResult).some((key) => {\n const typedKey = key;\n const changed = this.#currentResult[typedKey] !== prevResult[typedKey];\n return changed && includedProps.has(typedKey);\n });\n };\n this.#notify({ listeners: shouldNotifyListeners() });\n }\n #updateQuery() {\n const query = this.#client.getQueryCache().build(this.#client, this.options);\n if (query === this.#currentQuery) {\n return;\n }\n const prevQuery = this.#currentQuery;\n this.#currentQuery = query;\n this.#currentQueryInitialState = query.state;\n if (this.hasListeners()) {\n prevQuery?.removeObserver(this);\n query.addObserver(this);\n }\n }\n onQueryUpdate() {\n this.updateResult();\n if (this.hasListeners()) {\n this.#updateTimers();\n }\n }\n #notify(notifyOptions) {\n notifyManager.batch(() => {\n if (notifyOptions.listeners) {\n this.listeners.forEach((listener) => {\n listener(this.#currentResult);\n });\n }\n this.#client.getQueryCache().notify({\n query: this.#currentQuery,\n type: \"observerResultsUpdated\"\n });\n });\n }\n};\nfunction shouldLoadOnMount(query, options) {\n return resolveQueryBoolean(options.enabled, query) !== false && query.state.data === void 0 && !(query.state.status === \"error\" && resolveQueryBoolean(options.retryOnMount, query) === false);\n}\nfunction shouldFetchOnMount(query, options) {\n return shouldLoadOnMount(query, options) || query.state.data !== void 0 && shouldFetchOn(query, options, options.refetchOnMount);\n}\nfunction shouldFetchOn(query, options, field) {\n if (resolveQueryBoolean(options.enabled, query) !== false && resolveStaleTime(options.staleTime, query) !== \"static\") {\n const value = typeof field === \"function\" ? field(query) : field;\n return value === \"always\" || value !== false && isStale(query, options);\n }\n return false;\n}\nfunction shouldFetchOptionally(query, prevQuery, options, prevOptions) {\n return (query !== prevQuery || resolveQueryBoolean(prevOptions.enabled, query) === false) && (!options.suspense || query.state.status !== \"error\") && isStale(query, options);\n}\nfunction isStale(query, options) {\n return resolveQueryBoolean(options.enabled, query) !== false && query.isStaleByTime(resolveStaleTime(options.staleTime, query));\n}\nfunction shouldAssignObserverCurrentProperties(observer, optimisticResult) {\n if (!shallowEqualObjects(observer.getCurrentResult(), optimisticResult)) {\n return true;\n }\n return false;\n}\nexport {\n QueryObserver\n};\n//# sourceMappingURL=queryObserver.js.map","\"use client\";\n\n// src/QueryErrorResetBoundary.tsx\nimport * as React from \"react\";\nimport { jsx } from \"react/jsx-runtime\";\nfunction createValue() {\n let isReset = false;\n return {\n clearReset: () => {\n isReset = false;\n },\n reset: () => {\n isReset = true;\n },\n isReset: () => {\n return isReset;\n }\n };\n}\nvar QueryErrorResetBoundaryContext = React.createContext(createValue());\nvar useQueryErrorResetBoundary = () => React.useContext(QueryErrorResetBoundaryContext);\nvar QueryErrorResetBoundary = ({\n children\n}) => {\n const [value] = React.useState(() => createValue());\n return /* @__PURE__ */ jsx(QueryErrorResetBoundaryContext.Provider, { value, children: typeof children === \"function\" ? children(value) : children });\n};\nexport {\n QueryErrorResetBoundary,\n useQueryErrorResetBoundary\n};\n//# sourceMappingURL=QueryErrorResetBoundary.js.map","\"use client\";\n\n// src/errorBoundaryUtils.ts\nimport * as React from \"react\";\nimport { shouldThrowError } from \"@tanstack/query-core\";\nvar ensurePreventErrorBoundaryRetry = (options, errorResetBoundary, query) => {\n const throwOnError = query?.state.error && typeof options.throwOnError === \"function\" ? shouldThrowError(options.throwOnError, [query.state.error, query]) : options.throwOnError;\n if (options.suspense || options.experimental_prefetchInRender || throwOnError) {\n if (!errorResetBoundary.isReset()) {\n options.retryOnMount = false;\n }\n }\n};\nvar useClearResetErrorBoundary = (errorResetBoundary) => {\n React.useEffect(() => {\n errorResetBoundary.clearReset();\n }, [errorResetBoundary]);\n};\nvar getHasError = ({\n result,\n errorResetBoundary,\n throwOnError,\n query,\n suspense\n}) => {\n return result.isError && !errorResetBoundary.isReset() && !result.isFetching && query && (suspense && result.data === void 0 || shouldThrowError(throwOnError, [result.error, query]));\n};\nexport {\n ensurePreventErrorBoundaryRetry,\n getHasError,\n useClearResetErrorBoundary\n};\n//# sourceMappingURL=errorBoundaryUtils.js.map","\"use client\";\n\n// src/IsRestoringProvider.ts\nimport * as React from \"react\";\nvar IsRestoringContext = React.createContext(false);\nvar useIsRestoring = () => React.useContext(IsRestoringContext);\nvar IsRestoringProvider = IsRestoringContext.Provider;\nexport {\n IsRestoringProvider,\n useIsRestoring\n};\n//# sourceMappingURL=IsRestoringProvider.js.map","// src/suspense.ts\nvar defaultThrowOnError = (_error, query) => query.state.data === void 0;\nvar ensureSuspenseTimers = (defaultedOptions) => {\n if (defaultedOptions.suspense) {\n const MIN_SUSPENSE_TIME_MS = 1e3;\n const clamp = (value) => value === \"static\" ? value : Math.max(value ?? MIN_SUSPENSE_TIME_MS, MIN_SUSPENSE_TIME_MS);\n const originalStaleTime = defaultedOptions.staleTime;\n defaultedOptions.staleTime = typeof originalStaleTime === \"function\" ? (...args) => clamp(originalStaleTime(...args)) : clamp(originalStaleTime);\n if (typeof defaultedOptions.gcTime === \"number\") {\n defaultedOptions.gcTime = Math.max(\n defaultedOptions.gcTime,\n MIN_SUSPENSE_TIME_MS\n );\n }\n }\n};\nvar willFetch = (result, isRestoring) => result.isLoading && result.isFetching && !isRestoring;\nvar shouldSuspend = (defaultedOptions, result) => defaultedOptions?.suspense && result.isPending;\nvar fetchOptimistic = (defaultedOptions, observer, errorResetBoundary) => observer.fetchOptimistic(defaultedOptions).catch(() => {\n errorResetBoundary.clearReset();\n});\nexport {\n defaultThrowOnError,\n ensureSuspenseTimers,\n fetchOptimistic,\n shouldSuspend,\n willFetch\n};\n//# sourceMappingURL=suspense.js.map","\"use client\";\n\n// src/useBaseQuery.ts\nimport * as React from \"react\";\nimport { environmentManager, noop, notifyManager } from \"@tanstack/query-core\";\nimport { useQueryClient } from \"./QueryClientProvider.js\";\nimport { useQueryErrorResetBoundary } from \"./QueryErrorResetBoundary.js\";\nimport {\n ensurePreventErrorBoundaryRetry,\n getHasError,\n useClearResetErrorBoundary\n} from \"./errorBoundaryUtils.js\";\nimport { useIsRestoring } from \"./IsRestoringProvider.js\";\nimport {\n ensureSuspenseTimers,\n fetchOptimistic,\n shouldSuspend,\n willFetch\n} from \"./suspense.js\";\nfunction useBaseQuery(options, Observer, queryClient) {\n if (process.env.NODE_ENV !== \"production\") {\n if (typeof options !== \"object\" || Array.isArray(options)) {\n throw new Error(\n 'Bad argument type. Starting with v5, only the \"Object\" form is allowed when calling query related functions. Please use the error stack to find the culprit call. More info here: https://tanstack.com/query/latest/docs/react/guides/migrating-to-v5#supports-a-single-signature-one-object'\n );\n }\n }\n const isRestoring = useIsRestoring();\n const errorResetBoundary = useQueryErrorResetBoundary();\n const client = useQueryClient(queryClient);\n const defaultedOptions = client.defaultQueryOptions(options);\n client.getDefaultOptions().queries?._experimental_beforeQuery?.(\n defaultedOptions\n );\n const query = client.getQueryCache().get(defaultedOptions.queryHash);\n if (process.env.NODE_ENV !== \"production\") {\n if (!defaultedOptions.queryFn) {\n console.error(\n `[${defaultedOptions.queryHash}]: No queryFn was passed as an option, and no default queryFn was found. The queryFn parameter is only optional when using a default queryFn. More info here: https://tanstack.com/query/latest/docs/framework/react/guides/default-query-function`\n );\n }\n }\n const subscribed = options.subscribed !== false;\n defaultedOptions._optimisticResults = isRestoring ? \"isRestoring\" : subscribed ? \"optimistic\" : void 0;\n ensureSuspenseTimers(defaultedOptions);\n ensurePreventErrorBoundaryRetry(defaultedOptions, errorResetBoundary, query);\n useClearResetErrorBoundary(errorResetBoundary);\n const isNewCacheEntry = !client.getQueryCache().get(defaultedOptions.queryHash);\n const [observer] = React.useState(\n () => new Observer(\n client,\n defaultedOptions\n )\n );\n const result = observer.getOptimisticResult(defaultedOptions);\n const shouldSubscribe = !isRestoring && subscribed;\n React.useSyncExternalStore(\n React.useCallback(\n (onStoreChange) => {\n const unsubscribe = shouldSubscribe ? observer.subscribe(notifyManager.batchCalls(onStoreChange)) : noop;\n observer.updateResult();\n return unsubscribe;\n },\n [observer, shouldSubscribe]\n ),\n () => observer.getCurrentResult(),\n () => observer.getCurrentResult()\n );\n React.useEffect(() => {\n observer.setOptions(defaultedOptions);\n }, [defaultedOptions, observer]);\n if (shouldSuspend(defaultedOptions, result)) {\n throw fetchOptimistic(defaultedOptions, observer, errorResetBoundary);\n }\n if (getHasError({\n result,\n errorResetBoundary,\n throwOnError: defaultedOptions.throwOnError,\n query,\n suspense: defaultedOptions.suspense\n })) {\n throw result.error;\n }\n ;\n client.getDefaultOptions().queries?._experimental_afterQuery?.(\n defaultedOptions,\n result\n );\n if (defaultedOptions.experimental_prefetchInRender && !environmentManager.isServer() && willFetch(result, isRestoring)) {\n const promise = isNewCacheEntry ? (\n // Fetch immediately on render in order to ensure `.promise` is resolved even if the component is unmounted\n fetchOptimistic(defaultedOptions, observer, errorResetBoundary)\n ) : (\n // subscribe to the \"cache promise\" so that we can finalize the currentThenable once data comes in\n query?.promise\n );\n promise?.catch(noop).finally(() => {\n observer.updateResult();\n });\n }\n return !defaultedOptions.notifyOnChangeProps ? observer.trackResult(result) : result;\n}\nexport {\n useBaseQuery\n};\n//# sourceMappingURL=useBaseQuery.js.map","/**\n * Check if a component has an accessibility prop\n *\n * @param {object} props\n * @returns {boolean} Whether the component has an accessibility prop\n */\nexport const hasA11yProp = (props: Record<string, any>) => {\n for (const prop in props) {\n if (prop.startsWith('aria-') || prop === 'role' || prop === 'title') {\n return true;\n }\n }\n\n return false;\n};\n","/**\n * Converts string to kebab case\n *\n * @param {string} string\n * @returns {string} A kebabized string\n */\nexport const toKebabCase = (string: string) =>\n string.replace(/([a-z0-9])([A-Z])/g, '$1-$2').toLowerCase();\n","/**\n * Merges classes into a single string\n *\n * @param {array} classes\n * @returns {string} A string of classes\n */\nexport const mergeClasses = <ClassType = string | undefined | null>(...classes: ClassType[]) =>\n classes\n .filter((className, index, array) => {\n return (\n Boolean(className) &&\n (className as string).trim() !== '' &&\n array.indexOf(className) === index\n );\n })\n .join(' ')\n .trim();\n","/**\n * Converts string to camel case\n *\n * @param {string} string\n * @returns {string} A camelized string\n */\nexport const toCamelCase = <T extends string>(string: T) =>\n string.replace(/^([A-Z])|[\\s-_]+(\\w)/g, (match, p1, p2) =>\n p2 ? p2.toUpperCase() : p1.toLowerCase(),\n );\n","export default {\n xmlns: 'http://www.w3.org/2000/svg',\n width: 24,\n height: 24,\n viewBox: '0 0 24 24',\n fill: 'none',\n stroke: 'currentColor',\n strokeWidth: 2,\n strokeLinecap: 'round',\n strokeLinejoin: 'round',\n};\n","import { CamelToPascal } from '../utility-types';\nimport { toCamelCase } from './toCamelCase';\n\n/**\n * Converts string to pascal case\n *\n * @param {string} string\n * @returns {string} A pascalized string\n */\nexport const toPascalCase = <T extends string>(string: T): CamelToPascal<T> => {\n const camelCase = toCamelCase(string);\n\n return (camelCase.charAt(0).toUpperCase() + camelCase.slice(1)) as CamelToPascal<T>;\n};\n","import { createElement, forwardRef } from 'react';\nimport { mergeClasses, toKebabCase, toPascalCase } from '@lucide/shared';\nimport { IconNode, LucideProps } from './types';\nimport Icon from './Icon';\n\n/**\n * Create a Lucide icon component\n * @param {string} iconName\n * @param {array} iconNode\n * @returns {ForwardRefExoticComponent} LucideIcon\n */\nconst createLucideIcon = (iconName: string, iconNode: IconNode) => {\n const Component = forwardRef<SVGSVGElement, LucideProps>(({ className, ...props }, ref) =>\n createElement(Icon, {\n ref,\n iconNode,\n className: mergeClasses(\n `lucide-${toKebabCase(toPascalCase(iconName))}`,\n `lucide-${iconName}`,\n className,\n ),\n ...props,\n }),\n );\n\n Component.displayName = toPascalCase(iconName);\n\n return Component;\n};\n\nexport default createLucideIcon;\n","'use client';\n\nimport { createElement, forwardRef } from 'react';\nimport defaultAttributes from './defaultAttributes';\nimport { IconNode, LucideProps } from './types';\nimport { mergeClasses, hasA11yProp } from '@lucide/shared';\nimport { useLucideContext } from './context';\n\ninterface IconComponentProps extends LucideProps {\n iconNode: IconNode;\n}\n\n/**\n * Lucide icon component\n *\n * @component Icon\n * @param {object} props\n * @param {string} props.color - The color of the icon\n * @param {number} props.size - The size of the icon\n * @param {number} props.strokeWidth - The stroke width of the icon\n * @param {boolean} props.absoluteStrokeWidth - Whether to use absolute stroke width\n * @param {string} props.className - The class name of the icon\n * @param {IconNode} props.children - The children of the icon\n * @param {IconNode} props.iconNode - The icon node of the icon\n *\n * @returns {ForwardRefExoticComponent} LucideIcon\n */\nconst Icon = forwardRef<SVGSVGElement, IconComponentProps>(\n (\n { color, size, strokeWidth, absoluteStrokeWidth, className = '', children, iconNode, ...rest },\n ref,\n ) => {\n const {\n size: contextSize = 24,\n strokeWidth: contextStrokeWidth = 2,\n absoluteStrokeWidth: contextAbsoluteStrokeWidth = false,\n color: contextColor = 'currentColor',\n className: contextClass = '',\n } = useLucideContext() ?? {};\n\n const calculatedStrokeWidth =\n absoluteStrokeWidth ?? contextAbsoluteStrokeWidth\n ? (Number(strokeWidth ?? contextStrokeWidth) * 24) / Number(size ?? contextSize)\n : strokeWidth ?? contextStrokeWidth;\n\n return createElement(\n 'svg',\n {\n ref,\n ...defaultAttributes,\n width: size ?? contextSize ?? defaultAttributes.width,\n height: size ?? contextSize ?? defaultAttributes.height,\n stroke: color ?? contextColor,\n strokeWidth: calculatedStrokeWidth,\n className: mergeClasses('lucide', contextClass, className),\n ...(!children && !hasA11yProp(rest) && { 'aria-hidden': 'true' }),\n ...rest,\n },\n [\n ...iconNode.map(([tag, attrs]) => createElement(tag, attrs)),\n ...(Array.isArray(children) ? children : [children]),\n ],\n );\n },\n);\n\nexport default Icon;\n","import createLucideIcon from '../createLucideIcon';\nimport { IconNode } from '../types';\n\nexport const __iconNode: IconNode = [['path', { d: 'M21 12a9 9 0 1 1-6.219-8.56', key: '13zald' }]];\n\n/**\n * @component @name LoaderCircle\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview  - https://lucide.dev/icons/loader-circle\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst LoaderCircle = createLucideIcon('loader-circle', __iconNode);\n\nexport default LoaderCircle;\n","import createLucideIcon from '../createLucideIcon';\nimport { IconNode } from '../types';\n\nexport const __iconNode: IconNode = [\n [\n 'path',\n {\n d: 'm21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3',\n key: 'wmoenq',\n },\n ],\n ['path', { d: 'M12 9v4', key: 'juzpu7' }],\n ['path', { d: 'M12 17h.01', key: 'p32p05' }],\n];\n\n/**\n * @component @name TriangleAlert\n * @description Lucide SVG icon component, renders SVG Element with children.\n *\n * @preview  - https://lucide.dev/icons/triangle-alert\n * @see https://lucide.dev/guide/packages/lucide-react - Documentation\n *\n * @param {Object} props - Lucide icons props and any valid SVG attribute\n * @returns {JSX.Element} JSX Element\n *\n */\nconst TriangleAlert = createLucideIcon('triangle-alert', __iconNode);\n\nexport default TriangleAlert;\n","import {\n HTTP_ERROR_FALLBACK_ERROR_CODE,\n type HTTPAccessFallbackError,\n} from './http-access-fallback/http-access-fallback'\n\n// TODO: Add `forbidden` docs\n/**\n * @experimental\n * This function allows you to render the [forbidden.js file](https://nextjs.org/docs/app/api-reference/file-conventions/forbidden)\n * within a route segment as well as inject a tag.\n *\n * `forbidden()` can be used in\n * [Server Components](https://nextjs.org/docs/app/building-your-application/rendering/server-components),\n * [Route Handlers](https://nextjs.org/docs/app/building-your-application/routing/route-handlers), and\n * [Server Actions](https://nextjs.org/docs/app/building-your-application/data-fetching/server-actions-and-mutations).\n *\n * Read more: [Next.js Docs: `forbidden`](https://nextjs.org/docs/app/api-reference/functions/forbidden)\n */\n\nconst DIGEST = `${HTTP_ERROR_FALLBACK_ERROR_CODE};403`\n\nexport function forbidden(): never {\n if (!process.env.__NEXT_EXPERIMENTAL_AUTH_INTERRUPTS) {\n throw new Error(\n `\\`forbidden()\\` is experimental and only allowed to be enabled when \\`experimental.authInterrupts\\` is enabled.`\n )\n }\n\n const error = new Error(DIGEST) as HTTPAccessFallbackError\n ;(error as HTTPAccessFallbackError).digest = DIGEST\n throw error\n}\n","const DYNAMIC_ERROR_CODE = 'DYNAMIC_SERVER_USAGE'\n\nexport class DynamicServerError extends Error {\n digest: typeof DYNAMIC_ERROR_CODE = DYNAMIC_ERROR_CODE\n\n constructor(public readonly description: string) {\n super(`Dynamic server usage: ${description}`)\n }\n}\n\nexport function isDynamicServerError(err: unknown): err is DynamicServerError {\n if (\n typeof err !== 'object' ||\n err === null ||\n !('digest' in err) ||\n typeof err.digest !== 'string'\n ) {\n return false\n }\n\n return err.digest === DYNAMIC_ERROR_CODE\n}\n","export const HTTPAccessErrorStatus = {\n NOT_FOUND: 404,\n FORBIDDEN: 403,\n UNAUTHORIZED: 401,\n}\n\nconst ALLOWED_CODES = new Set(Object.values(HTTPAccessErrorStatus))\n\nexport const HTTP_ERROR_FALLBACK_ERROR_CODE = 'NEXT_HTTP_ERROR_FALLBACK'\n\nexport type HTTPAccessFallbackError = Error & {\n digest: `${typeof HTTP_ERROR_FALLBACK_ERROR_CODE};${string}`\n}\n\n/**\n * Checks an error to determine if it's an error generated by\n * the HTTP navigation APIs `notFound()`, `forbidden()` or `unauthorized()`.\n *\n * @param error the error that may reference a HTTP access error\n * @returns true if the error is a HTTP access error\n */\nexport function isHTTPAccessFallbackError(\n error: unknown\n): error is HTTPAccessFallbackError {\n if (\n typeof error !== 'object' ||\n error === null ||\n !('digest' in error) ||\n typeof error.digest !== 'string'\n ) {\n return false\n }\n const [prefix, httpStatus] = error.digest.split(';')\n\n return (\n prefix === HTTP_ERROR_FALLBACK_ERROR_CODE &&\n ALLOWED_CODES.has(Number(httpStatus))\n )\n}\n\nexport function getAccessFallbackHTTPStatus(\n error: HTTPAccessFallbackError\n): number {\n const httpStatus = error.digest.split(';')[1]\n return Number(httpStatus)\n}\n\nexport function getAccessFallbackErrorTypeByStatus(\n status: number\n): 'not-found' | 'forbidden' | 'unauthorized' | undefined {\n switch (status) {\n case 401:\n return 'unauthorized'\n case 403:\n return 'forbidden'\n case 404:\n return 'not-found'\n default:\n return\n }\n}\n","import {\n isHTTPAccessFallbackError,\n type HTTPAccessFallbackError,\n} from './http-access-fallback/http-access-fallback'\nimport { isRedirectError, type RedirectError } from './redirect-error'\n\n/**\n * Returns true if the error is a navigation signal error. These errors are\n * thrown by user code to perform navigation operations and interrupt the React\n * render.\n */\nexport function isNextRouterError(\n error: unknown\n): error is RedirectError | HTTPAccessFallbackError {\n return isRedirectError(error) || isHTTPAccessFallbackError(error)\n}\n","// Client-safe access to the server-only dynamic-rendering hooks used by the\n// navigation hooks. On the server these re-export the real implementations; in\n// the browser bundle this module is aliased to\n// `./navigation-dynamic-rendering.browser` (see\n// scripts/generate-browser-variant-aliases.mjs), which exports `undefined` so\n// the server module is not bundled into the client. Callers use optional calls\n// (`useDynamicRouteParams?.(...)`), so the browser stub is a no-op.\nexport {\n useDynamicRouteParams,\n useDynamicSearchParams,\n} from '../../server/app-render/dynamic-rendering-client'\n","import type { Params } from '../../server/request/params'\n\nimport React, { useContext, useMemo, use } from 'react'\nimport {\n AppRouterContext,\n LayoutRouterContext,\n type AppRouterInstance,\n} from '../../shared/lib/app-router-context.shared-runtime'\nimport {\n SearchParamsContext,\n PathnameContext,\n PathParamsContext,\n NavigationPromisesContext,\n ReadonlyURLSearchParams,\n} from '../../shared/lib/hooks-client-context.shared-runtime'\nimport {\n computeSelectedLayoutSegment,\n getSelectedLayoutSegmentPath,\n} from '../../shared/lib/segment'\n\nimport {\n useDynamicRouteParams,\n useDynamicSearchParams,\n} from './navigation-dynamic-rendering'\n\nconst {\n instrumentParamsForClientValidation,\n instrumentSearchParamsForClientValidation,\n expectCompleteParamsInClientValidation,\n} = process.env.__NEXT_CACHE_COMPONENTS\n ? (require('./instant-samples') as typeof import('./instant-samples'))\n : {}\n\n/**\n * A [Client Component](https://nextjs.org/docs/app/building-your-application/rendering/client-components) hook\n * that lets you *read* the current URL's search parameters.\n *\n * Learn more about [`URLSearchParams` on MDN](https://developer.mozilla.org/docs/Web/API/URLSearchParams)\n *\n * @example\n * ```ts\n * \"use client\"\n * import { useSearchParams } from 'next/navigation'\n *\n * export default function Page() {\n * const searchParams = useSearchParams()\n * searchParams.get('foo') // returns 'bar' when ?foo=bar\n * // ...\n * }\n * ```\n *\n * Read more: [Next.js Docs: `useSearchParams`](https://nextjs.org/docs/app/api-reference/functions/use-search-params)\n */\n// Client components API\nexport function useSearchParams(): ReadonlyURLSearchParams {\n useDynamicSearchParams?.('useSearchParams()')\n\n const searchParams = useContext(SearchParamsContext)\n\n // In the case where this is `null`, the compat types added in\n // `next-env.d.ts` will add a new overload that changes the return type to\n // include `null`.\n const readonlySearchParams = useMemo((): ReadonlyURLSearchParams => {\n if (!searchParams) {\n // When the router is not ready in pages, we won't have the search params\n // available.\n return null!\n }\n\n return new ReadonlyURLSearchParams(searchParams)\n }, [searchParams])\n\n // During build-time instant validation, wrap with an proxy\n // so that accessing undeclared search params throws an error.\n if (\n typeof window === 'undefined' &&\n process.env.__NEXT_CACHE_COMPONENTS &&\n readonlySearchParams\n ) {\n return instrumentSearchParamsForClientValidation!(readonlySearchParams)\n }\n\n // Instrument with Suspense DevTools (dev-only)\n if (process.env.NODE_ENV !== 'production' && 'use' in React) {\n const navigationPromises = use(NavigationPromisesContext)\n if (navigationPromises) {\n return use(navigationPromises.searchParams)\n }\n }\n\n return readonlySearchParams\n}\n\n/**\n * A [Client Component](https://nextjs.org/docs/app/building-your-application/rendering/client-components) hook\n * that lets you read the current URL's pathname.\n *\n * @example\n * ```ts\n * \"use client\"\n * import { usePathname } from 'next/navigation'\n *\n * export default function Page() {\n * const pathname = usePathname() // returns \"/dashboard\" on /dashboard?foo=bar\n * // ...\n * }\n * ```\n *\n * Read more: [Next.js Docs: `usePathname`](https://nextjs.org/docs/app/api-reference/functions/use-pathname)\n */\n// Client components API\nexport function usePathname(): string {\n useDynamicRouteParams?.('usePathname()')\n\n // In the case where this is `null`, the compat types added in `next-env.d.ts`\n // will add a new overload that changes the return type to include `null`.\n const pathname = useContext(PathnameContext) as string\n\n // During build-time instant validation, error if fallback params exist\n // because usePathname() can't return a sensible value without all params.\n if (\n typeof window === 'undefined' &&\n process.env.__NEXT_CACHE_COMPONENTS &&\n pathname\n ) {\n expectCompleteParamsInClientValidation!('usePathname()')\n return pathname\n }\n\n // Instrument with Suspense DevTools (dev-only)\n if (process.env.NODE_ENV !== 'production' && 'use' in React) {\n const navigationPromises = use(NavigationPromisesContext)\n if (navigationPromises) {\n return use(navigationPromises.pathname)\n }\n }\n\n return pathname\n}\n\n// Client components API\nexport {\n ServerInsertedHTMLContext,\n useServerInsertedHTML,\n} from '../../shared/lib/server-inserted-html.shared-runtime'\n\n/**\n *\n * This hook allows you to programmatically change routes inside [Client Component](https://nextjs.org/docs/app/building-your-application/rendering/client-components).\n *\n * @example\n * ```ts\n * \"use client\"\n * import { useRouter } from 'next/navigation'\n *\n * export default function Page() {\n * const router = useRouter()\n * // ...\n * router.push('/dashboard') // Navigate to /dashboard\n * }\n * ```\n *\n * Read more: [Next.js Docs: `useRouter`](https://nextjs.org/docs/app/api-reference/functions/use-router)\n */\n// Client components API\nexport function useRouter(): AppRouterInstance {\n const router = useContext(AppRouterContext)\n if (router === null) {\n throw new Error('invariant expected app router to be mounted')\n }\n\n // Read the bfcacheId of the closest CacheNode and merge it into the\n // returned router instance. This is contextual: callers in a shared\n // layout get the layout's id; callers in a leaf segment get the leaf's.\n // The id is stored on the CacheNode as a number and materialized as a\n // string here. The format mirrors React's `useId()` (e.g. `_r_0_`) with\n // a `b` prefix, so the id can be safely concatenated with other keys\n // without collision.\n const layout = useContext(LayoutRouterContext)\n const bfcacheIdNumber = layout?.parentRenderTree.data.bfcacheId ?? 0\n return useMemo<AppRouterInstance>(\n () => ({\n back: router.back,\n forward: router.forward,\n refresh: router.refresh,\n hmrRefresh: router.hmrRefresh,\n push: router.push,\n replace: router.replace,\n prefetch: router.prefetch,\n experimental_gesturePush: router.experimental_gesturePush,\n bfcacheId: '_b_' + bfcacheIdNumber + '_',\n }),\n [router, bfcacheIdNumber]\n )\n}\n\n/**\n * A [Client Component](https://nextjs.org/docs/app/building-your-application/rendering/client-components) hook\n * that lets you read a route's dynamic params filled in by the current URL.\n *\n * @example\n * ```ts\n * \"use client\"\n * import { useParams } from 'next/navigation'\n *\n * export default function Page() {\n * // on /dashboard/[team] where pathname is /dashboard/nextjs\n * const { team } = useParams() // team === \"nextjs\"\n * }\n * ```\n *\n * Read more: [Next.js Docs: `useParams`](https://nextjs.org/docs/app/api-reference/functions/use-params)\n */\n// Client components API\nexport function useParams<T extends Params = Params>(): T {\n useDynamicRouteParams?.('useParams()')\n\n const params = useContext(PathParamsContext) as T\n\n // During build-time instant validation, wrap with a proxy\n // so that accessing undeclared params throws an error.\n if (\n typeof window === 'undefined' &&\n process.env.__NEXT_CACHE_COMPONENTS &&\n params\n ) {\n return instrumentParamsForClientValidation!(params)\n }\n\n // Instrument with Suspense DevTools (dev-only)\n if (process.env.NODE_ENV !== 'production' && 'use' in React) {\n const navigationPromises = use(NavigationPromisesContext)\n if (navigationPromises) {\n return use(navigationPromises.params) as T\n }\n }\n\n return params\n}\n\n/**\n * A [Client Component](https://nextjs.org/docs/app/building-your-application/rendering/client-components) hook\n * that lets you read the active route segments **below** the Layout it is called from.\n *\n * @example\n * ```ts\n * 'use client'\n *\n * import { useSelectedLayoutSegments } from 'next/navigation'\n *\n * export default function ExampleClientComponent() {\n * const segments = useSelectedLayoutSegments()\n *\n * return (\n * <ul>\n * {segments.map((segment, index) => (\n * <li key={index}>{segment}</li>\n * ))}\n * </ul>\n * )\n * }\n * ```\n *\n * Read more: [Next.js Docs: `useSelectedLayoutSegments`](https://nextjs.org/docs/app/api-reference/functions/use-selected-layout-segments)\n */\n// Client components API\nexport function useSelectedLayoutSegments(\n parallelRouteKey: string = 'children'\n): string[] {\n useDynamicRouteParams?.('useSelectedLayoutSegments()')\n\n const context = useContext(LayoutRouterContext)\n // @ts-expect-error This only happens in `pages`. Type is overwritten in navigation.d.ts\n if (!context) return null\n\n // During build-time instant validation, error if fallback params exist\n // because useSelectedLayoutSegments() can't return a sensible value without all params.\n if (\n typeof window === 'undefined' &&\n process.env.__NEXT_CACHE_COMPONENTS &&\n context\n ) {\n expectCompleteParamsInClientValidation!('useSelectedLayoutSegments()')\n }\n\n // Instrument with Suspense DevTools (dev-only)\n if (process.env.NODE_ENV !== 'production' && 'use' in React) {\n const navigationPromises = use(NavigationPromisesContext)\n if (navigationPromises) {\n const promise =\n navigationPromises.selectedLayoutSegmentsPromises?.get(parallelRouteKey)\n if (promise) {\n // We should always have a promise here, but if we don't, it's not worth erroring over.\n // We just won't be able to instrument it, but can still provide the value.\n return use(promise)\n }\n }\n }\n\n return getSelectedLayoutSegmentPath(context.parentTree, parallelRouteKey)\n}\n\n/**\n * A [Client Component](https://nextjs.org/docs/app/building-your-application/rendering/client-components) hook\n * that lets you read the active route segment **one level below** the Layout it is called from.\n *\n * @example\n * ```ts\n * 'use client'\n * import { useSelectedLayoutSegment } from 'next/navigation'\n *\n * export default function ExampleClientComponent() {\n * const segment = useSelectedLayoutSegment()\n *\n * return <p>Active segment: {segment}</p>\n * }\n * ```\n *\n * Read more: [Next.js Docs: `useSelectedLayoutSegment`](https://nextjs.org/docs/app/api-reference/functions/use-selected-layout-segment)\n */\n// Client components API\nexport function useSelectedLayoutSegment(\n parallelRouteKey: string = 'children'\n): string | null {\n useDynamicRouteParams?.('useSelectedLayoutSegment()')\n const navigationPromises = useContext(NavigationPromisesContext)\n const selectedLayoutSegments = useSelectedLayoutSegments(parallelRouteKey)\n\n // During build-time instant validation, error if fallback params exist\n // because useSelectedLayoutSegment() can't return a sensible value without all params.\n if (typeof window === 'undefined' && process.env.__NEXT_CACHE_COMPONENTS) {\n expectCompleteParamsInClientValidation!('useSelectedLayoutSegment()')\n }\n\n // Instrument with Suspense DevTools (dev-only)\n if (\n process.env.NODE_ENV !== 'production' &&\n navigationPromises &&\n 'use' in React\n ) {\n const promise =\n navigationPromises.selectedLayoutSegmentPromises?.get(parallelRouteKey)\n if (promise) {\n // We should always have a promise here, but if we don't, it's not worth erroring over.\n // We just won't be able to instrument it, but can still provide the value.\n return use(promise)\n }\n }\n\n return computeSelectedLayoutSegment(selectedLayoutSegments, parallelRouteKey)\n}\n\nexport { unstable_isUnrecognizedActionError } from './unrecognized-action-error'\n\n// Shared components APIs\nexport {\n // We need the same class that was used to instantiate the context value\n // Otherwise instanceof checks will fail in usercode\n ReadonlyURLSearchParams,\n}\nexport {\n notFound,\n forbidden,\n unauthorized,\n redirect,\n permanentRedirect,\n RedirectType,\n unstable_rethrow,\n} from './navigation.react-server'\n","import { ReadonlyURLSearchParams } from './readonly-url-search-params'\n\nexport function unstable_isUnrecognizedActionError(): boolean {\n throw new Error(\n '`unstable_isUnrecognizedActionError` can only be used on the client.'\n )\n}\n\nexport { redirect, permanentRedirect } from './redirect'\nexport { notFound } from './not-found'\nexport { forbidden } from './forbidden'\nexport { unauthorized } from './unauthorized'\nexport { unstable_rethrow } from './unstable-rethrow'\nexport { ReadonlyURLSearchParams }\n\nexport const RedirectType = {\n push: 'push',\n replace: 'replace',\n} as const\n","import {\n HTTP_ERROR_FALLBACK_ERROR_CODE,\n type HTTPAccessFallbackError,\n} from './http-access-fallback/http-access-fallback'\n\n/**\n * This function allows you to render the [not-found.js file](https://nextjs.org/docs/app/api-reference/file-conventions/not-found)\n * within a route segment as well as inject a tag.\n *\n * `notFound()` can be used in\n * [Server Components](https://nextjs.org/docs/app/building-your-application/rendering/server-components),\n * [Route Handlers](https://nextjs.org/docs/app/building-your-application/routing/route-handlers), and\n * [Server Actions](https://nextjs.org/docs/app/building-your-application/data-fetching/server-actions-and-mutations).\n *\n * - In a Server Component, this will insert a `<meta name=\"robots\" content=\"noindex\" />` meta tag and set the status code to 404.\n * - In a Route Handler or Server Action, it will serve a 404 to the caller.\n *\n * Read more: [Next.js Docs: `notFound`](https://nextjs.org/docs/app/api-reference/functions/not-found)\n */\n\nconst DIGEST = `${HTTP_ERROR_FALLBACK_ERROR_CODE};404`\n\nexport function notFound(): never {\n const error = new Error(DIGEST) as HTTPAccessFallbackError\n ;(error as HTTPAccessFallbackError).digest = DIGEST\n\n throw error\n}\n","/**\n * ReadonlyURLSearchParams implementation shared between client and server.\n * This file is intentionally not marked as 'use client' or 'use server'\n * so it can be imported by both environments.\n */\n\n/** @internal */\nclass ReadonlyURLSearchParamsError extends Error {\n constructor() {\n super(\n 'Method unavailable on `ReadonlyURLSearchParams`. Read more: https://nextjs.org/docs/app/api-reference/functions/use-search-params#updating-searchparams'\n )\n }\n}\n\n/**\n * A read-only version of URLSearchParams that throws errors when mutation methods are called.\n * This ensures that the URLSearchParams returned by useSearchParams() cannot be mutated.\n */\nexport class ReadonlyURLSearchParams extends URLSearchParams {\n /** @deprecated Method unavailable on `ReadonlyURLSearchParams`. Read more: https://nextjs.org/docs/app/api-reference/functions/use-search-params#updating-searchparams */\n append() {\n throw new ReadonlyURLSearchParamsError()\n }\n /** @deprecated Method unavailable on `ReadonlyURLSearchParams`. Read more: https://nextjs.org/docs/app/api-reference/functions/use-search-params#updating-searchparams */\n delete() {\n throw new ReadonlyURLSearchParamsError()\n }\n /** @deprecated Method unavailable on `ReadonlyURLSearchParams`. Read more: https://nextjs.org/docs/app/api-reference/functions/use-search-params#updating-searchparams */\n set() {\n throw new ReadonlyURLSearchParamsError()\n }\n /** @deprecated Method unavailable on `ReadonlyURLSearchParams`. Read more: https://nextjs.org/docs/app/api-reference/functions/use-search-params#updating-searchparams */\n sort() {\n throw new ReadonlyURLSearchParamsError()\n }\n}\n","import { RedirectStatusCode } from './redirect-status-code'\n\nexport const REDIRECT_ERROR_CODE = 'NEXT_REDIRECT'\n\nexport type RedirectType = 'push' | 'replace'\n\nexport type RedirectError = Error & {\n digest: `${typeof REDIRECT_ERROR_CODE};${RedirectType};${string};${RedirectStatusCode};`\n}\n\n/**\n * Checks an error to determine if it's an error generated by the\n * `redirect(url)` helper.\n *\n * @param error the error that may reference a redirect error\n * @returns true if the error is a redirect error\n */\nexport function isRedirectError(error: unknown): error is RedirectError {\n if (\n typeof error !== 'object' ||\n error === null ||\n !('digest' in error) ||\n typeof error.digest !== 'string'\n ) {\n return false\n }\n\n const digest = error.digest.split(';')\n const [errorCode, type] = digest\n const destination = digest.slice(2, -2).join(';')\n const status = digest.at(-2)\n\n const statusCode = Number(status)\n\n return (\n errorCode === REDIRECT_ERROR_CODE &&\n (type === 'replace' || type === 'push') &&\n typeof destination === 'string' &&\n !isNaN(statusCode) &&\n statusCode in RedirectStatusCode\n )\n}\n","export enum RedirectStatusCode {\n SeeOther = 303,\n TemporaryRedirect = 307,\n PermanentRedirect = 308,\n}\n","import { RedirectStatusCode } from './redirect-status-code'\nimport {\n type RedirectType,\n type RedirectError,\n isRedirectError,\n REDIRECT_ERROR_CODE,\n} from './redirect-error'\nimport { actionAsyncStorage } from './server-async-storage'\n\nexport function getRedirectError(\n url: string,\n type: RedirectType,\n statusCode: RedirectStatusCode = RedirectStatusCode.TemporaryRedirect\n): RedirectError {\n const error = new Error(REDIRECT_ERROR_CODE) as RedirectError\n error.digest = `${REDIRECT_ERROR_CODE};${type};${url};${statusCode};`\n return error\n}\n\n/**\n * This function allows you to redirect the user to another URL. It can be used in\n * [Server Components](https://nextjs.org/docs/app/building-your-application/rendering/server-components),\n * [Route Handlers](https://nextjs.org/docs/app/building-your-application/routing/route-handlers), and\n * [Server Actions](https://nextjs.org/docs/app/building-your-application/data-fetching/server-actions-and-mutations).\n *\n * - In a Server Component, this will insert a meta tag to redirect the user to the target page.\n * - In a Route Handler, it will serve a 307 to the caller.\n * - In a Server Action, it will perform a client-side navigation when JavaScript is available or serve a 303 for a progressive enhancement form submission.\n * - In a Server Action, type defaults to 'push' and 'replace' elsewhere.\n *\n * Read more: [Next.js Docs: `redirect`](https://nextjs.org/docs/app/api-reference/functions/redirect)\n */\nexport function redirect(\n /** The URL to redirect to */\n url: string,\n type?: RedirectType\n): never {\n type ??= actionAsyncStorage?.getStore()?.isAction ? 'push' : 'replace'\n\n throw getRedirectError(url, type, RedirectStatusCode.TemporaryRedirect)\n}\n\n/**\n * This function allows you to redirect the user to another URL. It can be used in\n * [Server Components](https://nextjs.org/docs/app/building-your-application/rendering/server-components),\n * [Route Handlers](https://nextjs.org/docs/app/building-your-application/routing/route-handlers), and\n * [Server Actions](https://nextjs.org/docs/app/building-your-application/data-fetching/server-actions-and-mutations).\n *\n * - In a Server Component, this will insert a meta tag to redirect the user to the target page.\n * - In a Route Handler, it will serve a 308 to the caller.\n * - In a Server Action, it will perform a client-side navigation when JavaScript is available or serve a 303 for a progressive enhancement form submission.\n *\n * Read more: [Next.js Docs: `redirect`](https://nextjs.org/docs/app/api-reference/functions/redirect)\n */\nexport function permanentRedirect(\n /** The URL to redirect to */\n url: string,\n type: RedirectType = 'replace'\n): never {\n throw getRedirectError(url, type, RedirectStatusCode.PermanentRedirect)\n}\n\n/**\n * Returns the encoded URL from the error if it's a RedirectError, null\n * otherwise. Note that this does not validate the URL returned.\n *\n * @param error the error that may be a redirect error\n * @return the url if the error was a redirect error\n */\nexport function getURLFromRedirectError(error: RedirectError): string\nexport function getURLFromRedirectError(error: unknown): string | null {\n if (!isRedirectError(error)) return null\n\n // Slices off the beginning of the digest that contains the code and the\n // separating ';'.\n return error.digest.split(';').slice(2, -2).join(';')\n}\n\nexport function getRedirectTypeFromError(error: RedirectError): RedirectType {\n if (!isRedirectError(error)) {\n throw new Error('Not a redirect error')\n }\n\n return error.digest.split(';', 2)[1] as RedirectType\n}\n\nexport function getRedirectStatusCodeFromError(error: RedirectError): number {\n if (!isRedirectError(error)) {\n throw new Error('Not a redirect error')\n }\n\n return Number(error.digest.split(';').at(-2))\n}\n","const NEXT_STATIC_GEN_BAILOUT = 'NEXT_STATIC_GEN_BAILOUT'\n\nexport class StaticGenBailoutError extends Error {\n public readonly code = NEXT_STATIC_GEN_BAILOUT\n}\n\nexport function isStaticGenBailoutError(\n error: unknown\n): error is StaticGenBailoutError {\n if (typeof error !== 'object' || error === null || !('code' in error)) {\n return false\n }\n\n return error.code === NEXT_STATIC_GEN_BAILOUT\n}\n","import {\n HTTP_ERROR_FALLBACK_ERROR_CODE,\n type HTTPAccessFallbackError,\n} from './http-access-fallback/http-access-fallback'\n\n// TODO: Add `unauthorized` docs\n/**\n * @experimental\n * This function allows you to render the [unauthorized.js file](https://nextjs.org/docs/app/api-reference/file-conventions/unauthorized)\n * within a route segment as well as inject a tag.\n *\n * `unauthorized()` can be used in\n * [Server Components](https://nextjs.org/docs/app/building-your-application/rendering/server-components),\n * [Route Handlers](https://nextjs.org/docs/app/building-your-application/routing/route-handlers), and\n * [Server Actions](https://nextjs.org/docs/app/building-your-application/data-fetching/server-actions-and-mutations).\n *\n *\n * Read more: [Next.js Docs: `unauthorized`](https://nextjs.org/docs/app/api-reference/functions/unauthorized)\n */\n\nconst DIGEST = `${HTTP_ERROR_FALLBACK_ERROR_CODE};401`\n\nexport function unauthorized(): never {\n if (!process.env.__NEXT_EXPERIMENTAL_AUTH_INTERRUPTS) {\n throw new Error(\n `\\`unauthorized()\\` is experimental and only allowed to be used when \\`experimental.authInterrupts\\` is enabled.`\n )\n }\n\n const error = new Error(DIGEST) as HTTPAccessFallbackError\n ;(error as HTTPAccessFallbackError).digest = DIGEST\n throw error\n}\n","export class UnrecognizedActionError extends Error {\n constructor(...args: ConstructorParameters<typeof Error>) {\n super(...args)\n this.name = 'UnrecognizedActionError'\n }\n}\n\n/**\n * Check whether a server action call failed because the server action was not recognized by the server.\n * This can happen if the client and the server are not from the same deployment.\n *\n * Example usage:\n * ```ts\n * try {\n * await myServerAction();\n * } catch (err) {\n * if (unstable_isUnrecognizedActionError(err)) {\n * // The client is from a different deployment than the server.\n * // Reloading the page will fix this mismatch.\n * window.alert(\"Please refresh the page and try again\");\n * return;\n * }\n * }\n * ```\n * */\nexport function unstable_isUnrecognizedActionError(\n error: unknown\n): error is UnrecognizedActionError {\n return !!(\n error &&\n typeof error === 'object' &&\n error instanceof UnrecognizedActionError\n )\n}\n","import { isHangingPromiseRejectionError } from '../../server/dynamic-rendering-utils'\nimport { isBailoutToCSRError } from '../../shared/lib/lazy-dynamic/bailout-to-csr'\nimport { isNextRouterError } from './is-next-router-error'\nimport { isPrerenderInterruptedError } from '../../server/app-render/dynamic-rendering'\nimport { isDynamicServerError } from './hooks-server-context'\n\n/**\n * This function should be used to rethrow internal Next.js errors so that they can be handled by the framework.\n * When wrapping an API that uses errors to interrupt control flow, you should use this function before you do any error handling.\n * This function will rethrow the error if it is a Next.js error so it can be handled, otherwise it will do nothing.\n *\n * In the browser bundle this module is aliased to `./unstable-rethrow.browser`, which performs a\n * subset of these checks (the server-only ones can never occur in the browser). This default\n * module holds the full server logic and is used on every server runtime (Node, edge) and in any\n * context where the alias does not apply.\n *\n * Read more: [Next.js Docs: `unstable_rethrow`](https://nextjs.org/docs/app/api-reference/functions/unstable_rethrow)\n */\nexport function unstable_rethrow(error: unknown): void {\n if (\n isNextRouterError(error) ||\n isBailoutToCSRError(error) ||\n isDynamicServerError(error) ||\n isHangingPromiseRejectionError(error) ||\n isPrerenderInterruptedError(error)\n ) {\n throw error\n }\n\n if (error instanceof Error && 'cause' in error) {\n unstable_rethrow(error.cause)\n }\n}\n","export const METADATA_BOUNDARY_NAME = '__next_metadata_boundary__'\nexport const VIEWPORT_BOUNDARY_NAME = '__next_viewport_boundary__'\nexport const OUTLET_BOUNDARY_NAME = '__next_outlet_boundary__'\nexport const ROOT_LAYOUT_BOUNDARY_NAME = '__next_root_layout_boundary__'\n","export type ScheduledFn<T = void> = () => T | PromiseLike<T>\nexport type SchedulerFn<T = void> = (cb: ScheduledFn<T>) => void\n\n/**\n * Schedules a function to be called on the next tick after the other promises\n * have been resolved.\n *\n * @param cb the function to schedule\n */\nexport const scheduleOnNextTick = (cb: ScheduledFn<void>) => {\n // We use Promise.resolve().then() here so that the operation is scheduled at\n // the end of the promise job queue, we then add it to the next process tick\n // to ensure it's evaluated afterwards.\n //\n // This was inspired by the implementation of the DataLoader interface: https://github.com/graphql/dataloader/blob/d336bd15282664e0be4b4a657cb796f09bafbc6b/src/index.js#L213-L255\n //\n Promise.resolve().then(() => {\n if (process.env.NEXT_RUNTIME === 'edge') {\n setTimeout(cb, 0)\n } else {\n process.nextTick(cb)\n }\n })\n}\n\n/**\n * Schedules a function to be called using `setImmediate` or `setTimeout` if\n * `setImmediate` is not available (like in the Edge runtime).\n *\n * @param cb the function to schedule\n */\nexport const scheduleImmediate = (cb: ScheduledFn<void>): void => {\n if (process.env.NEXT_RUNTIME === 'edge') {\n setTimeout(cb, 0)\n } else {\n setImmediate(cb)\n }\n}\n\n/**\n * returns a promise than resolves in a future task. There is no guarantee that the task it resolves in\n * will be the next task but if you await it you can at least be sure that the current task is over and\n * most usefully that the entire microtask queue of the current task has been emptied.\n */\nexport function atLeastOneTask() {\n return new Promise<void>((resolve) => scheduleImmediate(resolve))\n}\n\n/**\n * This utility function is extracted to make it easier to find places where we are doing\n * specific timing tricks to try to schedule work after React has rendered. This is especially\n * important at the moment because Next.js uses the edge builds of React which use setTimeout to\n * schedule work when you might expect that something like setImmediate would do the trick.\n *\n * Long term we should switch to the node versions of React rendering when possible and then\n * update this to use setImmediate rather than setTimeout\n */\nexport function waitAtLeastOneReactRenderTask(): Promise<void> {\n if (process.env.NEXT_RUNTIME === 'edge') {\n return new Promise((r) => setTimeout(r, 0))\n } else {\n return new Promise((r) => setImmediate(r))\n }\n}\n","export function createRuntimeBodyError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered runtime data during prerendering.\\n\\n` +\n `\\`cookies()\\`, \\`headers()\\`, \\`params\\`, or \\`searchParams\\` accessed outside of \\`<Suspense>\\` prevents the route from being prerendered, blocking the page load and leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Provide a placeholder with \\`<Suspense fallback={...}>\\` around the data access\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-runtime`\n )\n}\n\nexport function createDynamicBodyError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached data during prerendering.\\n\\n` +\n `\\`fetch(...)\\` or \\`connection()\\` accessed outside of \\`<Suspense>\\` prevents the route from being prerendered, blocking the page load and leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Provide a placeholder with \\`<Suspense fallback={...}>\\` around the data access\\n` +\n ` - [cache] Cache the data access with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-dynamic`\n )\n}\n\nexport function createRuntimeBodyErrorInNavigation(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered runtime data during prerendering or a navigation.\\n\\n` +\n `\\`cookies()\\`, \\`headers()\\`, \\`params\\`, or \\`searchParams\\` accessed outside of \\`<Suspense>\\` prevents the route from being prerendered or the navigation from being instant, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Provide a placeholder with \\`<Suspense fallback={...}>\\` around the data access\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-runtime`\n )\n}\n\nexport function createLinkBodyErrorInNavigation(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered URL data during prerendering or a navigation.\\n\\n` +\n `\\`params\\` or \\`searchParams\\` accessed outside of \\`<Suspense>\\` may prevent the navigation from being instant, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Provide a placeholder with \\`<Suspense fallback={...}>\\` around the data access\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/instant-shell-url-data`\n )\n}\n\nexport function createNavigationBodyErrorInNavigation(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered \\`navigation()\\` during prerendering or a navigation.\\n\\n` +\n `\\`navigation()\\` called outside of \\`<Suspense>\\` may prevent the navigation from being instant, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Provide a placeholder with \\`<Suspense fallback={...}>\\` around the component that calls \\`navigation()\\`\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/instant-navigation-stage`\n )\n}\n\nexport function createPrefetchBodyErrorInNavigation(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered \\`prefetch()\\` during prerendering or a navigation.\\n\\n` +\n `\\`prefetch()\\` called outside of \\`<Suspense>\\` may prevent the navigation from being instant, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Provide a placeholder with \\`<Suspense fallback={...}>\\` around the component that calls \\`prefetch()\\`\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/instant-navigation-stage`\n )\n}\n\nexport function createDynamicBodyErrorInNavigation(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached data during prerendering or a navigation.\\n\\n` +\n `\\`fetch(...)\\` or \\`connection()\\` accessed outside of \\`<Suspense>\\` prevents the route from being prerendered or the navigation from being instant, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Provide a placeholder with \\`<Suspense fallback={...}>\\` around the data access\\n` +\n ` - [cache] Cache the data access with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-dynamic`\n )\n}\n\n/**\n * NOTE: Prefer `createRuntimeBodyError` or `createDynamicBodyError`.\n * Only use this in situations like build-time static validation, where\n * we can't pinpoint a more specific reason.\n */\nexport function createDynamicOrRuntimeBodyError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached or runtime data during prerendering.\\n\\n` +\n `\\`fetch(...)\\`, \\`cookies()\\`, \\`headers()\\`, \\`params\\`, \\`searchParams\\`, or \\`connection()\\` accessed outside of \\`<Suspense>\\` prevents the route from being prerendered, blocking the page load and leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Provide a placeholder with \\`<Suspense fallback={...}>\\` around the data access\\n` +\n ` - [cache] For uncached data (\\`fetch\\`, database calls): cache the access with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-dynamic`\n )\n}\n\nexport function createLinkMetadataError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered URL data in \\`generateMetadata()\\`.\\n\\n` +\n `This route's metadata is blocked, but the rest of its content can be prefetched. \\`params\\` or \\`searchParams\\` accessed in \\`generateMetadata()\\` prevent it from being prefetched.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [static] Use a static metadata export instead of \\`generateMetadata()\\`\\n` +\n ` - [dynamic] Render a marker component that calls \\`await connection()\\` inside \\`<Suspense>\\` on the page\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-metadata-runtime`\n )\n}\n\nexport function createRuntimeMetadataError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered runtime data in \\`generateMetadata()\\`.\\n\\n` +\n `This route's metadata is blocked, but the rest of its content can be prerendered. \\`cookies()\\`, \\`headers()\\`, \\`params\\`, or \\`searchParams\\` accessed in \\`generateMetadata()\\` cause it to run dynamically.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [static] Use a static metadata export instead of \\`generateMetadata()\\`\\n` +\n ` - [dynamic] Render a marker component that calls \\`await connection()\\` inside \\`<Suspense>\\` on the page\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-metadata-runtime`\n )\n}\n\nexport function createNavigationMetadataError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered \\`navigation()\\` in \\`generateMetadata()\\`.\\n\\n` +\n `Metadata can already stream without blocking the route's UI, so delaying it until navigation may be unintentional.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [remove] Remove \\`navigation()\\` from \\`generateMetadata()\\`\\n` +\n ` - [mark] Render a marker component that calls \\`await navigation()\\` inside \\`<Suspense>\\` on the page\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/instant-navigation-stage-metadata`\n )\n}\n\nexport function createPrefetchMetadataError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered \\`prefetch()\\` in \\`generateMetadata()\\`.\\n\\n` +\n `Metadata can already stream without blocking the route's UI, so delaying it until a per-link prefetch or navigation may be unintentional.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [remove] Remove \\`prefetch()\\` from \\`generateMetadata()\\`\\n` +\n ` - [mark] Render a marker component that calls \\`await prefetch()\\` inside \\`<Suspense>\\` on the page\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/instant-navigation-stage-metadata`\n )\n}\n\nexport function createDynamicMetadataError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached data in \\`generateMetadata()\\`.\\n\\n` +\n `This route's metadata is blocked, but the rest of its content can be prerendered. \\`fetch(...)\\` or \\`connection()\\` accessed in \\`generateMetadata()\\` cause it to run dynamically.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [cache] Cache the metadata with \\`\"use cache\"\\` in \\`generateMetadata()\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [dynamic] Render a marker component that calls \\`await connection()\\` inside \\`<Suspense>\\` on the page\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-metadata-dynamic`\n )\n}\n\nexport function createLinkViewportError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered URL data in \\`generateViewport()\\`.\\n\\n` +\n `\\`params\\` or \\`searchParams\\` in \\`generateViewport()\\` prevents the page from being prerendered, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [static] Use a static viewport export instead of \\`generateViewport()\\`\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-viewport-runtime`\n )\n}\n\nexport function createRuntimeViewportError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered runtime data in \\`generateViewport()\\`.\\n\\n` +\n `\\`cookies()\\`, \\`headers()\\`, \\`params\\`, or \\`searchParams\\` in \\`generateViewport()\\` prevents the page from being prerendered, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [static] Use a static viewport export instead of \\`generateViewport()\\`\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-viewport-runtime`\n )\n}\n\nexport function createNavigationViewportError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered \\`navigation()\\` in \\`generateViewport()\\`.\\n\\n` +\n `This prevents Next.js from creating the App Shell, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [remove] Remove \\`navigation()\\` from \\`generateViewport()\\`\\n` +\n ` - [ignore] Set \\`export const instant = false\\` to disable validation for this segment\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/instant-navigation-stage-viewport`\n )\n}\n\nexport function createPrefetchViewportError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered \\`prefetch()\\` in \\`generateViewport()\\`.\\n\\n` +\n `This prevents Next.js from creating the App Shell, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [remove] Remove \\`prefetch()\\` from \\`generateViewport()\\`\\n` +\n ` - [ignore] Set \\`export const instant = false\\` to disable validation for this segment\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/instant-navigation-stage-viewport`\n )\n}\n\nexport function createDynamicViewportError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached data in \\`generateViewport()\\`.\\n\\n` +\n `\\`fetch(...)\\` or \\`connection()\\` in \\`generateViewport()\\` prevents the page from being prerendered, leading to a slower user experience.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [cache] Cache the viewport data with \\`\"use cache\"\\` in \\`generateViewport()\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-viewport-dynamic`\n )\n}\n\n/**\n * NOTE: Prefer `createRuntimeViewportError` or `createDynamicViewportError`.\n * Only use this in situations like build-time static validation, where\n * we can't pinpoint a more specific reason.\n */\nexport function createDynamicOrRuntimeViewportError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached or runtime data in \\`generateViewport()\\`.\\n\\n` +\n `This prevents the page from being prerendered, leading to a slower user experience. Unlike metadata, viewport cannot be streamed behind \\`<Suspense>\\` because it affects the initial page load.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [static] Use a static viewport export instead of \\`generateViewport()\\`\\n` +\n ` - [cache] For uncached data (\\`fetch\\`, database calls): cache the viewport with \\`\"use cache\"\\` in \\`generateViewport()\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-viewport-runtime`\n )\n}\n\n/**\n * NOTE: Prefer `createRuntimeMetadataError` or `createDynamicMetadataError`.\n * Only use this in situations like build-time static validation, where\n * we can't pinpoint a more specific reason.\n */\nexport function createDynamicOrRuntimeMetadataError(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached or runtime data in \\`generateMetadata()\\`.\\n\\n` +\n `This route's metadata is blocked, but the rest of its content can be prerendered.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [static] Use a static metadata export instead of \\`generateMetadata()\\`\\n` +\n ` - [cache] Cache the metadata with \\`\"use cache\"\\` in \\`generateMetadata()\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [dynamic] Render a marker component that calls \\`await connection()\\` inside \\`<Suspense>\\` on the page\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-metadata-runtime`\n )\n}\n\n//====================================================\n// Static routes (with `ensureStatic = \"navigation\"`)\n//====================================================\n\nexport function createRuntimeBodyErrorInStaticRoute(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered runtime data on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but runtime data from \\`cookies()\\`, \\`headers()\\`, \\`params\\`, \\`searchParams\\`, or a short-lived cache requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [remove] Remove the data access\\n` +\n ` - [client] Read the data on the client\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-route-runtime`\n )\n}\n\nexport function createDynamicBodyErrorInStaticRoute(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached data on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but an uncached \\`fetch(...)\\`, database call, or \\`connection()\\` requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [cache] Cache the data access with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [remove] Remove the data access\\n` +\n ` - [client] Read the data on the client\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-route-dynamic`\n )\n}\n\nexport function createNonPrerenderableBodyErrorInStaticRoute(\n route: string\n): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached or runtime data on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but some data requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [cache] For uncached data (\\`fetch\\`, database calls): cache the access with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [remove] Remove the data access\\n` +\n ` - [client] Read the data on the client\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-route-dynamic`\n )\n}\n\nexport function createRuntimeMetadataErrorInStaticRoute(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered runtime data in \\`generateMetadata()\\` on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but runtime data from \\`cookies()\\`, \\`headers()\\`, \\`params\\`, \\`searchParams\\`, or a short-lived cache requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [static] Replace the dynamic data used by \\`generateMetadata()\\` with static data\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-metadata-runtime`\n )\n}\n\nexport function createDynamicMetadataErrorInStaticRoute(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached data in \\`generateMetadata()\\` on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but an uncached \\`fetch(...)\\`, database call, or \\`connection()\\` requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [cache] Cache the data used by \\`generateMetadata()\\` with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [static] Replace the dynamic data used by \\`generateMetadata()\\` with static data\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-metadata-dynamic`\n )\n}\n\nexport function createNonPrerenderableMetadataErrorInStaticRoute(\n route: string\n): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached or runtime data in \\`generateMetadata()\\` on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but some data requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [cache] For uncached data: cache the data used by \\`generateMetadata()\\` with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [static] Replace the dynamic data used by \\`generateMetadata()\\` with static data\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-metadata-dynamic`\n )\n}\n\nexport function createRuntimeViewportErrorInStaticRoute(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered runtime data in \\`generateViewport()\\` on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but runtime data from \\`cookies()\\`, \\`headers()\\`, \\`params\\`, \\`searchParams\\`, or a short-lived cache requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [static] Replace the dynamic data used by \\`generateViewport()\\` with static data\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-viewport-runtime`\n )\n}\n\nexport function createDynamicViewportErrorInStaticRoute(route: string): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached data in \\`generateViewport()\\` on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but an uncached \\`fetch(...)\\`, database call, or \\`connection()\\` requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [cache] Cache the data used by \\`generateViewport()\\` with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [static] Replace the dynamic data used by \\`generateViewport()\\` with static data\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-viewport-dynamic`\n )\n}\n\nexport function createNonPrerenderableViewportErrorInStaticRoute(\n route: string\n): Error {\n return new Error(\n `Route \"${route}\": Next.js encountered uncached or runtime data in \\`generateViewport()\\` on a route that must be fully static.\\n\\n` +\n `This route is configured to be fully static, but some data requires rendering at request time.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [cache] For uncached data: cache the data used by \\`generateViewport()\\` with \\`\"use cache\"\\` (does not apply to \\`connection()\\`)\\n` +\n ` - [static] Replace the dynamic data used by \\`generateViewport()\\` with static data\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/static-viewport-dynamic`\n )\n}\n\nexport function logBuildDebugHint(route: string): void {\n if (process.env.NODE_ENV !== 'development') {\n console.error(\n `To get a more detailed stack trace and pinpoint the issue, try one of the following:\\n` +\n ` - Start the app in development mode by running \\`next dev\\`, then open \"${route}\" in your browser to investigate the error.\\n` +\n ` - Rerun the production build with \\`next build --debug-prerender\\` to generate better stack traces.`\n )\n } else if (!process.env.__NEXT_DEV_SERVER) {\n console.error(\n `To debug the issue, start the app in development mode by running \\`next dev\\`, then open \"${route}\" in your browser to investigate the error.`\n )\n }\n}\n","import React from 'react'\nimport { browser } from 'react-dom'\nimport {\n throwForMissingRequestStore,\n workUnitAsyncStorage,\n} from './work-unit-async-storage.external'\nimport { workAsyncStorage } from '../app-render/work-async-storage.external'\nimport {\n ClientHookDynamicError,\n makeClientHookHangingPromise,\n} from '../dynamic-rendering-utils'\nimport { InvariantError } from '../../shared/lib/invariant-error'\nimport { BailoutToCSRError } from '../../shared/lib/lazy-dynamic/bailout-to-csr'\nimport { createReactBrowserBailoutReason } from '../../shared/lib/lazy-dynamic/react-browser-bailout'\n\nconst getUseSearchParamsBailoutReason = createReactBrowserBailoutReason.bind(\n null,\n 'useSearchParams()'\n)\n\n// TODO(veil): This module is separated from `dynamic-rendering.ts` as a workaround.\n// When these hooks were part of `dynamic-rendering.ts, the source location of these\n// `React.use()` calls would show up in Webpack snapshots in `client-hook-abort-reasons.test.ts`,\n// which makes changes to the surrounding file needlessly churn the snapshots.\n// Until the ignore-listing is fixed, we can make this less annoying by keeping these hooks in a separate file.\n\nexport function useDynamicRouteParams(expression: string) {\n const workStore = workAsyncStorage.getStore()\n const workUnitStore = workUnitAsyncStorage.getStore()\n if (workStore && workUnitStore) {\n switch (workUnitStore.type) {\n case 'prerender-client': {\n const fallbackParams = workUnitStore.fallbackRouteParams\n\n if (fallbackParams && fallbackParams.size > 0) {\n // We are in a prerender with cacheComponents semantics. We are going to\n // hang here and never resolve. This will cause the currently\n // rendering component to effectively be a dynamic hole.\n React.use(\n makeClientHookHangingPromise(\n workUnitStore.renderSignal,\n new ClientHookDynamicError(workStore.route, expression)\n )\n )\n }\n break\n }\n case 'prerender':\n throw new InvariantError(\n `\\`${expression}\\` was called from a Server Component. Next.js should be preventing ${expression} from being included in server components statically, but did not in this case.`\n )\n case 'validation-client': {\n // Don't check fallbackRouteParams here. We handle params that weren't\n // provided in the samples using a proxy that throws when accessed.\n break\n }\n case 'prerender-runtime':\n throw new InvariantError(\n `\\`${expression}\\` was called during a runtime prerender. Next.js should be preventing ${expression} from being included in server components statically, but did not in this case.`\n )\n case 'cache':\n case 'private-cache':\n throw new InvariantError(\n `\\`${expression}\\` was called inside a cache scope. Next.js should be preventing ${expression} from being included in server components statically, but did not in this case.`\n )\n case 'build-time-generator':\n throw new InvariantError(\n `\\`${expression}\\` was called in \\`${workUnitStore.functionName}\\`. Next.js should be preventing ${expression} from being included in server component files statically, but did not in this case.`\n )\n case 'prerender-legacy':\n case 'request':\n case 'unstable-cache':\n break\n default:\n workUnitStore satisfies never\n }\n }\n}\n\nexport function useDynamicSearchParams(expression: string) {\n const workStore = workAsyncStorage.getStore()\n const workUnitStore = workUnitAsyncStorage.getStore()\n\n if (!workStore) {\n // We assume pages router context and just return\n return\n }\n\n if (!workUnitStore) {\n throwForMissingRequestStore(expression)\n }\n\n switch (workUnitStore.type) {\n case 'validation-client':\n // During instant validation we try to behave as close to client as possible,\n // so this shouldn't hang during SSR.\n return\n case 'prerender-client': {\n React.use(\n makeClientHookHangingPromise(\n workUnitStore.renderSignal,\n new ClientHookDynamicError(workStore.route, expression)\n )\n )\n break\n }\n case 'prerender-legacy': {\n if (workStore.forceStatic) {\n return\n }\n if (process.env.__NEXT_EXPERIMENTAL_REACT_BROWSER_BAILOUT) {\n // @ts-expect-error TODO: Update @types/react-dom to include the reason argument.\n React.use(browser(getUseSearchParamsBailoutReason))\n return\n } else {\n throw new BailoutToCSRError(expression)\n }\n }\n case 'prerender':\n case 'prerender-runtime':\n throw new InvariantError(\n `\\`${expression}\\` was called from a Server Component. Next.js should be preventing ${expression} from being included in server components statically, but did not in this case.`\n )\n case 'cache':\n case 'unstable-cache':\n case 'private-cache':\n throw new InvariantError(\n `\\`${expression}\\` was called inside a cache scope. Next.js should be preventing ${expression} from being included in server components statically, but did not in this case.`\n )\n case 'build-time-generator':\n throw new InvariantError(\n `\\`${expression}\\` was called in \\`${workUnitStore.functionName}\\`. Next.js should be preventing ${expression} from being included in server component files statically, but did not in this case.`\n )\n case 'request':\n return\n default:\n workUnitStore satisfies never\n }\n}\n","/**\n * The functions provided by this module are used to communicate certain properties\n * about the currently running code so that Next.js can make decisions on how to handle\n * the current execution in different rendering modes such as pre-rendering, resuming, and SSR.\n *\n * Today Next.js treats all code as potentially static. Certain APIs may only make sense when dynamically rendering.\n * Traditionally this meant deopting the entire render to dynamic however with PPR we can now deopt parts\n * of a React tree as dynamic while still keeping other parts static. There are really two different kinds of\n * Dynamic indications.\n *\n * The first is simply an intention to be dynamic. unstable_noStore is an example of this where\n * the currently executing code simply declares that the current scope is dynamic but if you use it\n * inside unstable_cache it can still be cached. This type of indication can be removed if we ever\n * make the default dynamic to begin with because the only way you would ever be static is inside\n * a cache scope which this indication does not affect.\n *\n * The second is an indication that a dynamic data source was read. This is a stronger form of dynamic\n * because it means that it is inappropriate to cache this at all. using a dynamic data source inside\n * unstable_cache should error. If you want to use some dynamic data inside unstable_cache you should\n * read that data outside the cache and pass it in as an argument to the cached function.\n */\n\nimport type { WorkStore } from './work-async-storage.external'\nimport type {\n RequestStore,\n WorkUnitStore,\n PrerenderStoreLegacy,\n PrerenderStoreModern,\n ValidationStoreClient,\n PrerenderStoreModernServer,\n} from './work-unit-async-storage.external'\n\n// Once postpone is in stable we should switch to importing the postpone export directly\nimport React from 'react'\n\nimport { DynamicServerError } from '../../client/components/hooks-server-context'\nimport { StaticGenBailoutError } from '../../client/components/static-generation-bailout'\nimport { getStagedRenderingController } from './work-unit-async-storage.external'\nimport { isClientHookDynamicError } from '../dynamic-rendering-utils'\nimport {\n METADATA_BOUNDARY_NAME,\n VIEWPORT_BOUNDARY_NAME,\n OUTLET_BOUNDARY_NAME,\n ROOT_LAYOUT_BOUNDARY_NAME,\n} from '../../lib/framework/boundary-constants'\nimport { scheduleOnNextTick } from '../../lib/scheduler'\nimport {\n createRuntimeBodyError,\n createDynamicBodyError,\n createRuntimeBodyErrorInNavigation,\n createNavigationBodyErrorInNavigation,\n createPrefetchBodyErrorInNavigation,\n createDynamicBodyErrorInNavigation,\n createDynamicOrRuntimeBodyError,\n createRuntimeMetadataError,\n createDynamicMetadataError,\n createRuntimeViewportError,\n createNavigationViewportError,\n createPrefetchViewportError,\n createDynamicViewportError,\n createDynamicOrRuntimeViewportError,\n createDynamicOrRuntimeMetadataError,\n logBuildDebugHint,\n createLinkBodyErrorInNavigation,\n createLinkMetadataError,\n createLinkViewportError,\n createNavigationMetadataError,\n createPrefetchMetadataError,\n createNonPrerenderableMetadataErrorInStaticRoute,\n createNonPrerenderableViewportErrorInStaticRoute,\n createNonPrerenderableBodyErrorInStaticRoute,\n createRuntimeBodyErrorInStaticRoute,\n createDynamicBodyErrorInStaticRoute,\n createRuntimeMetadataErrorInStaticRoute,\n createDynamicMetadataErrorInStaticRoute,\n createRuntimeViewportErrorInStaticRoute,\n createDynamicViewportErrorInStaticRoute,\n} from './blocking-route-messages'\nimport { InvariantError } from '../../shared/lib/invariant-error'\nimport {\n INSTANT_VALIDATION_BOUNDARY_NAME,\n INSTANT_SLOT_MARKER_PREFIX,\n INSTANT_SLOT_MARKER_SUFFIX,\n} from './instant-validation/boundary-constants'\nimport {\n type ValidationBoundaryTracking,\n allRequiredBoundariesRendered,\n} from './instant-validation/boundary-tracking'\nimport type { InstantValidationSampleTracking } from './instant-validation/instant-samples'\nimport { createUnrenderedSegmentError } from '../../shared/lib/instant-messages'\nimport { getReactBrowserBailoutReason } from '../../shared/lib/lazy-dynamic/react-browser-bailout'\n\nexport type DynamicAccess = {\n /**\n * If debugging, this will contain the stack trace of where the dynamic access\n * occurred. This is used to provide more information to the user about why\n * their page is being rendered dynamically.\n */\n stack?: string\n\n /**\n * The expression that was accessed dynamically.\n */\n expression: string\n}\n\n// Stores dynamic reasons used during an RSC render.\nexport type DynamicTrackingState = {\n /**\n * When true, stack information will also be tracked during dynamic access.\n */\n readonly isDebugDynamicAccesses: boolean | undefined\n\n /**\n * The dynamic accesses that occurred during the render.\n */\n readonly dynamicAccesses: Array<DynamicAccess>\n\n syncDynamicErrorWithStack: null | Error\n syncDynamicErrorWithStackPostMicrotask: boolean\n}\n\n// Stores dynamic reasons used during an SSR render.\nexport type DynamicValidationState = {\n hasSuspenseAboveBody: boolean\n hasDynamicMetadata: boolean\n dynamicMetadata: null | Error\n hasDynamicViewport: boolean\n hasAllowedDynamic: boolean\n dynamicErrors: Array<Error>\n}\n\nexport function createDynamicTrackingState(\n isDebugDynamicAccesses: boolean | undefined\n): DynamicTrackingState {\n return {\n isDebugDynamicAccesses,\n dynamicAccesses: [],\n syncDynamicErrorWithStack: null,\n syncDynamicErrorWithStackPostMicrotask: false,\n }\n}\n\nexport function createDynamicValidationState(): DynamicValidationState {\n return {\n hasSuspenseAboveBody: false,\n hasDynamicMetadata: false,\n dynamicMetadata: null,\n hasDynamicViewport: false,\n hasAllowedDynamic: false,\n dynamicErrors: [],\n }\n}\n\nfunction getPendingClientSyncDynamicError(\n clientDynamic: DynamicTrackingState\n): null | Error {\n return clientDynamic.syncDynamicErrorWithStackPostMicrotask\n ? null\n : clientDynamic.syncDynamicErrorWithStack\n}\n\nexport function getFirstDynamicReason(\n trackingState: DynamicTrackingState\n): undefined | string {\n return trackingState.dynamicAccesses[0]?.expression\n}\n\n/**\n * This function communicates that the current scope should be treated as dynamic.\n *\n * In most cases this function is a no-op but if called during\n * a PPR prerender it will postpone the current sub-tree and calling\n * it during a normal prerender will cause the entire prerender to abort\n */\nexport function markCurrentScopeAsDynamic(\n store: WorkStore,\n workUnitStore: undefined | Exclude<WorkUnitStore, PrerenderStoreModern>,\n expression: string\n): void {\n if (workUnitStore) {\n switch (workUnitStore.type) {\n case 'cache':\n case 'unstable-cache':\n // Inside cache scopes, marking a scope as dynamic has no effect,\n // because the outer cache scope creates a cache boundary. This is\n // subtly different from reading a dynamic data source, which is\n // forbidden inside a cache scope.\n return\n case 'private-cache':\n // A private cache scope is already dynamic by definition.\n return\n case 'prerender-legacy':\n case 'request':\n case 'build-time-generator':\n break\n default:\n workUnitStore satisfies never\n }\n }\n\n // If we're forcing dynamic rendering or we're forcing static rendering, we\n // don't need to do anything here because the entire page is already dynamic\n // or it's static and it should not throw or postpone here.\n if (store.forceDynamic || store.forceStatic) return\n\n if (store.dynamicShouldError) {\n throw new StaticGenBailoutError(\n `Route ${store.route} with \\`dynamic = \"error\"\\` couldn't be rendered statically because it used \\`${expression}\\`. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering`\n )\n }\n\n if (workUnitStore) {\n switch (workUnitStore.type) {\n case 'prerender-legacy':\n workUnitStore.revalidate = 0\n\n // We aren't prerendering, but we are generating a static page. We need\n // to bail out of static generation.\n const err = new DynamicServerError(\n `Route ${store.route} couldn't be rendered statically because it used ${expression}. See more info here: https://nextjs.org/docs/messages/dynamic-server-error`\n )\n store.dynamicUsageDescription = expression\n store.dynamicUsageStack = err.stack\n\n throw err\n case 'request':\n markRequestStoreAsDynamic(workUnitStore)\n break\n case 'build-time-generator':\n break\n default:\n workUnitStore satisfies never\n }\n }\n}\n\n/**\n * This function is meant to be used when prerendering without cacheComponents or PPR.\n * When called during a build it will cause Next.js to consider the route as dynamic.\n *\n * @internal\n */\nexport function throwToInterruptStaticGeneration(\n expression: string,\n store: WorkStore,\n prerenderStore: PrerenderStoreLegacy\n): never {\n // We aren't prerendering but we are generating a static page. We need to bail out of static generation\n const err = new DynamicServerError(\n `Route ${store.route} couldn't be rendered statically because it used \\`${expression}\\`. See more info here: https://nextjs.org/docs/messages/dynamic-server-error`\n )\n\n prerenderStore.revalidate = 0\n\n store.dynamicUsageDescription = expression\n store.dynamicUsageStack = err.stack\n\n throw err\n}\n\n/**\n * This function should be used to track whether something dynamic happened even when\n * we are in a dynamic render. This is useful for Dev where all renders are dynamic but\n * we still track whether dynamic APIs were accessed for helpful messaging\n *\n * @internal\n */\nexport function trackDynamicDataInDynamicRender(workUnitStore: WorkUnitStore) {\n switch (workUnitStore.type) {\n case 'cache':\n case 'unstable-cache':\n // Inside cache scopes, marking a scope as dynamic has no effect,\n // because the outer cache scope creates a cache boundary. This is\n // subtly different from reading a dynamic data source, which is\n // forbidden inside a cache scope.\n return\n case 'private-cache':\n // A private cache scope is already dynamic by definition.\n return\n case 'prerender':\n case 'prerender-runtime':\n case 'prerender-legacy':\n case 'prerender-client':\n case 'validation-client':\n case 'build-time-generator':\n break\n case 'request':\n markRequestStoreAsDynamic(workUnitStore)\n break\n default:\n workUnitStore satisfies never\n }\n}\n\nfunction markRequestStoreAsDynamic(requestStore: RequestStore): void {\n if (process.env.__NEXT_DEV_SERVER && requestStore.phase === 'render') {\n requestStore.usedDynamic = true\n }\n}\n\nfunction abortOnSynchronousDynamicDataAccess(\n route: string,\n expression: string,\n prerenderStore: PrerenderStoreModern\n): void {\n const reason = `Route ${route} needs to bail out of prerendering at this point because it used ${expression}.`\n\n const error = createPrerenderInterruptedError(reason)\n\n prerenderStore.controller.abort(error)\n\n const dynamicTracking = prerenderStore.dynamicTracking\n if (dynamicTracking) {\n dynamicTracking.dynamicAccesses.push({\n // When we aren't debugging, we don't need to create another error for the\n // stack trace.\n stack: dynamicTracking.isDebugDynamicAccesses\n ? new Error().stack\n : undefined,\n expression,\n })\n }\n}\n\nexport function abortOnSynchronousPlatformIOAccess(\n route: string,\n expression: string,\n errorWithStack: Error,\n prerenderStore: PrerenderStoreModern\n): void {\n const dynamicTracking = prerenderStore.dynamicTracking\n\n if (dynamicTracking && dynamicTracking.syncDynamicErrorWithStack === null) {\n dynamicTracking.syncDynamicErrorWithStack = errorWithStack\n // React completes the task that is currently rendering before scheduled\n // abort cleanup. Client tracking can attribute the sync IO only during\n // that current task; server tracking keeps the error regardless.\n queueMicrotask(() => {\n dynamicTracking.syncDynamicErrorWithStackPostMicrotask = true\n })\n }\n\n abortOnSynchronousDynamicDataAccess(route, expression, prerenderStore)\n}\n\n/**\n * use this function when prerendering with cacheComponents. If we are doing a\n * prospective prerender we don't actually abort because we want to discover\n * all caches for the shell. If this is the actual prerender we do abort.\n *\n * This function accepts a prerenderStore but the caller should ensure we're\n * actually running in cacheComponents mode.\n *\n * @internal\n */\nexport function abortAndThrowOnSynchronousRequestDataAccess(\n route: string,\n expression: string,\n errorWithStack: Error,\n prerenderStore: PrerenderStoreModern\n): never {\n const prerenderSignal = prerenderStore.controller.signal\n if (prerenderSignal.aborted === false) {\n // TODO it would be better to move this aborted check into the callsite so we can avoid making\n // the error object when it isn't relevant to the aborting of the prerender however\n // since we need the throw semantics regardless of whether we abort it is easier to land\n // this way. See how this was handled with `abortOnSynchronousPlatformIOAccess` for a closer\n // to ideal implementation\n abortOnSynchronousDynamicDataAccess(route, expression, prerenderStore)\n // Preserve the exact server-side dynamic access for final validation after\n // interrupting this render.\n const dynamicTracking = prerenderStore.dynamicTracking\n if (dynamicTracking) {\n if (dynamicTracking.syncDynamicErrorWithStack === null) {\n dynamicTracking.syncDynamicErrorWithStack = errorWithStack\n }\n }\n }\n throw createPrerenderInterruptedError(\n `Route ${route} needs to bail out of prerendering at this point because it used ${expression}.`\n )\n}\n\nconst NEXT_PRERENDER_INTERRUPTED = 'NEXT_PRERENDER_INTERRUPTED'\n\nfunction createPrerenderInterruptedError(message: string): Error {\n const error = new Error(message)\n ;(error as any).digest = NEXT_PRERENDER_INTERRUPTED\n return error\n}\n\ntype DigestError = Error & {\n digest: string\n}\n\nexport function isPrerenderInterruptedError(\n error: unknown\n): error is DigestError {\n return (\n typeof error === 'object' &&\n error !== null &&\n (error as any).digest === NEXT_PRERENDER_INTERRUPTED &&\n 'name' in error &&\n 'message' in error &&\n error instanceof Error\n )\n}\n\nexport function accessedDynamicData(\n dynamicAccesses: Array<DynamicAccess>\n): boolean {\n return dynamicAccesses.length > 0\n}\n\nexport function consumeDynamicAccess(\n serverDynamic: DynamicTrackingState,\n clientDynamic: DynamicTrackingState\n): DynamicTrackingState['dynamicAccesses'] {\n // We mutate because we only call this once we are no longer writing\n // to the dynamicTrackingState and it's more efficient than creating a new\n // array.\n serverDynamic.dynamicAccesses.push(...clientDynamic.dynamicAccesses)\n return serverDynamic.dynamicAccesses\n}\n\nexport function formatDynamicAPIAccesses(\n dynamicAccesses: Array<DynamicAccess>\n): string[] {\n return dynamicAccesses\n .filter(\n (access): access is Required<DynamicAccess> =>\n typeof access.stack === 'string' && access.stack.length > 0\n )\n .map(({ expression, stack }) => {\n stack = stack\n .split('\\n')\n // Remove the \"Error: \" prefix from the first line of the stack trace as\n // well as the first 4 lines of the stack trace which is the distance\n // from the user code and the `new Error().stack` call.\n .slice(4)\n .filter((line) => {\n // Exclude Next.js internals from the stack trace.\n if (line.includes('node_modules/next/')) {\n return false\n }\n\n // Exclude anonymous functions from the stack trace.\n if (line.includes(' (<anonymous>)')) {\n return false\n }\n\n // Exclude Node.js internals from the stack trace.\n if (line.includes(' (node:')) {\n return false\n }\n\n return true\n })\n .join('\\n')\n return `Dynamic API Usage Debug - ${expression}:\\n${stack}`\n })\n}\n\n/**\n * In a prerender, we may end up with hanging Promises as inputs due them\n * stalling on connection() or because they're loading dynamic data. In that\n * case we need to abort the encoding of arguments since they'll never complete.\n */\nexport function createHangingInputAbortSignal(\n workUnitStore: PrerenderStoreModernServer\n): AbortSignal\nexport function createHangingInputAbortSignal(\n workUnitStore: WorkUnitStore\n): AbortSignal | undefined\nexport function createHangingInputAbortSignal(\n workUnitStore: WorkUnitStore\n): AbortSignal | undefined {\n switch (workUnitStore.type) {\n case 'prerender':\n case 'prerender-runtime':\n const controller = new AbortController()\n\n if (workUnitStore.cacheSignal) {\n // If we have a cacheSignal it means we're in a prospective render. If\n // the input we're waiting on is coming from another cache, we do want\n // to wait for it so that we can resolve this cache entry too.\n workUnitStore.cacheSignal.inputReady().then(() => {\n controller.abort()\n })\n } else {\n // Otherwise we're in the final render and we should already have all\n // our caches filled.\n // If the prerender uses stages, we have wait until the final stage.\n // if an input didn't resolve at that point, then we can assume it never will.\n //\n // We might still be waiting on some microtasks so we\n // wait one tick before giving up. When we give up, we still want to\n // render the content of this cache as deeply as we can so that we can\n // suspend as deeply as possible in the tree or not at all if we don't\n // end up waiting for the input.\n\n const stagedRendering = getStagedRenderingController(workUnitStore)\n if (stagedRendering && stagedRendering.finalStage !== null) {\n stagedRendering\n .waitForStage(stagedRendering.finalStage)\n .then(() => scheduleOnNextTick(() => controller.abort()), noop)\n } else {\n scheduleOnNextTick(() => controller.abort())\n }\n }\n\n return controller.signal\n case 'prerender-client':\n case 'validation-client':\n case 'prerender-legacy':\n case 'request':\n case 'cache':\n case 'private-cache':\n case 'unstable-cache':\n case 'build-time-generator':\n return undefined\n default:\n workUnitStore satisfies never\n }\n}\n\nfunction noop() {}\n\nexport function annotateDynamicAccess(\n expression: string,\n prerenderStore: PrerenderStoreModern | ValidationStoreClient\n) {\n const dynamicTracking = prerenderStore.dynamicTracking\n if (dynamicTracking) {\n dynamicTracking.dynamicAccesses.push({\n stack: dynamicTracking.isDebugDynamicAccesses\n ? new Error().stack\n : undefined,\n expression,\n })\n }\n}\n\nconst hasSuspenseRegex = /\\n\\s+at Suspense \\(<anonymous>\\)/\n\n// Common implicit body tags that React will treat as body when placed directly in html\nconst bodyAndImplicitTags =\n 'body|div|main|section|article|aside|header|footer|nav|form|p|span|h1|h2|h3|h4|h5|h6'\n\n// Detects when RootLayoutBoundary (our framework marker component) appears\n// after Suspense in the component stack, indicating the root layout is wrapped\n// within a Suspense boundary. Ensures no body/html/implicit-body components are in between.\n//\n// Example matches:\n// at Suspense (<anonymous>)\n// at __next_root_layout_boundary__ (<anonymous>)\n//\n// Or with other components in between (but not body/html/implicit-body):\n// at Suspense (<anonymous>)\n// at SomeComponent (<anonymous>)\n// at __next_root_layout_boundary__ (<anonymous>)\nconst hasSuspenseBeforeRootLayoutWithoutBodyOrImplicitBodyRegex = new RegExp(\n `\\\\n\\\\s+at Suspense \\\\(<anonymous>\\\\)(?:(?!\\\\n\\\\s+at (?:${bodyAndImplicitTags}) \\\\(<anonymous>\\\\))[\\\\s\\\\S])*?\\\\n\\\\s+at ${ROOT_LAYOUT_BOUNDARY_NAME} \\\\([^\\\\n]*\\\\)`\n)\n\nconst hasMetadataRegex = new RegExp(\n `\\\\n\\\\s+at ${METADATA_BOUNDARY_NAME}[\\\\n\\\\s]`\n)\nconst hasViewportRegex = new RegExp(\n `\\\\n\\\\s+at ${VIEWPORT_BOUNDARY_NAME}[\\\\n\\\\s]`\n)\nconst hasOutletRegex = new RegExp(`\\\\n\\\\s+at ${OUTLET_BOUNDARY_NAME}[\\\\n\\\\s]`)\n\nconst hasInstantValidationBoundaryRegex = new RegExp(\n `\\\\n\\\\s+at ${INSTANT_VALIDATION_BOUNDARY_NAME}[\\\\n\\\\s]`\n)\nconst slotMarkerRegex = new RegExp(\n `\\\\n\\\\s+at ${INSTANT_SLOT_MARKER_PREFIX}(\\\\d+)${INSTANT_SLOT_MARKER_SUFFIX}[\\\\n\\\\s]`\n)\n\n/** Look up the config factory for the slot this error belongs to.\n * Checks the component stack for a slot marker (__next_instant_slot_N__)\n * and returns the config at that index. Falls back to index 0 (root\n * config) when no slot marker is found or the slot has no config. */\nfunction resolveInstantStack(\n componentStack: string,\n dynamicValidation: InstantValidationState\n): (() => Error) | null {\n const { slotStacks } = dynamicValidation\n if (slotStacks.length > 1) {\n const match = slotMarkerRegex.exec(componentStack)\n if (match) {\n // Slot markers are 0-indexed in the component name but\n // slotStacks is 1-indexed (index 0 is the root config).\n const slotIndex = parseInt(match[1], 10) + 1\n const slotStack = slotStacks[slotIndex]\n if (slotStack != null) {\n return slotStack\n }\n }\n }\n // Fall back to root config (index 0)\n return slotStacks[0] ?? null\n}\n\n/**\n * Inspects the component stack of an outlet boundary to discover whether the\n * user placed a Suspense boundary above the document body, and records the\n * opt-in on `dynamicValidation.hasSuspenseAboveBody` if so.\n *\n * The outlet itself isn't a meaningful source of dynamic — it only resolves\n * when metadata/viewport are dynamic, which we track via their own boundaries.\n * However, the outlet renders alongside the page content, so its stack passes\n * through the user's layout chain (typically reaching into `<body>` via the\n * root layout). That makes the outlet stack our best opportunity to spot a\n * Suspense boundary above the body, even when no real body content is dynamic.\n * Without this, a route whose only dynamic source is `generateViewport()` would\n * miss the Suspense-above-body opt-in, because the viewport's stack lives in\n * the head and never sees the user's root layout.\n *\n * We deliberately only set `hasSuspenseAboveBody`, not `hasAllowedDynamic`. The\n * latter tracks whether the body has dynamic content that's been wrapped in\n * Suspense (i.e., the page is partially dynamic). The outlet rendering tells us\n * about the structural opt-in for an empty shell, not about the body being\n * partially dynamic. The distinction matters because dynamic metadata is only\n * acceptable when the page is partially dynamic (via real body holes), and we\n * don't want this outlet-based detection to mask that case.\n */\nfunction trackOutletSuspenseAboveBody(\n componentStack: string,\n dynamicValidation: DynamicValidationState\n): void {\n if (\n hasSuspenseBeforeRootLayoutWithoutBodyOrImplicitBodyRegex.test(\n componentStack\n )\n ) {\n dynamicValidation.hasSuspenseAboveBody = true\n }\n}\n\nexport function trackDynamicAccessInStaticRoute(\n dynamicReason: unknown,\n workStore: WorkStore,\n componentStack: string,\n dynamicValidation: DynamicValidationState,\n clientDynamic: DynamicTrackingState,\n isServerPartial: boolean,\n kind: StaticValidationHoleKind\n) {\n const syncDynamicError = getPendingClientSyncDynamicError(clientDynamic)\n\n if (hasOutletRegex.test(componentStack)) {\n trackOutletSuspenseAboveBody(componentStack, dynamicValidation)\n return\n }\n if (hasMetadataRegex.test(componentStack)) {\n dynamicValidation.dynamicErrors.push(\n addErrorContext(\n createMetadataErrorInStaticRoute(kind, workStore.route),\n componentStack,\n null\n )\n )\n return\n }\n if (hasViewportRegex.test(componentStack)) {\n dynamicValidation.dynamicErrors.push(\n addErrorContext(\n createViewportErrorInStaticRoute(kind, workStore.route),\n componentStack,\n null\n )\n )\n return\n }\n\n let hasSuspense = false\n if (\n hasSuspenseBeforeRootLayoutWithoutBodyOrImplicitBodyRegex.test(\n componentStack\n )\n ) {\n // this error had a Suspense boundary above it, and it's above the body as well.\n dynamicValidation.hasSuspenseAboveBody = true\n hasSuspense = true\n } else if (hasSuspenseRegex.test(componentStack)) {\n // this error had a Suspense boundary above it.\n hasSuspense = true\n }\n\n if (hasSuspense) {\n if (!isServerPartial) {\n // If we don't have holes caused by server data, then any holes must be caused\n // by client-only code, which is allowed.\n dynamicValidation.hasAllowedDynamic = true\n return\n }\n\n // We have holes that may be caused by server data.\n if (syncDynamicError || isClientHookDynamicError(dynamicReason)) {\n // We know this hole wasn't caused by server data, so it's allowed\n // (because it's wrapped in a Suspense)\n dynamicValidation.hasAllowedDynamic = true\n return\n }\n\n // Any remaining hole may be caused by a server hole.\n // These are not allowed even with Suspense.\n // (NOTE: this may misreport valid client dynamic holes as server holes)\n dynamicValidation.dynamicErrors.push(\n addErrorContext(\n createBodyErrorInStaticRoute(kind, workStore.route),\n componentStack,\n null\n )\n )\n return\n }\n\n if (syncDynamicError) {\n dynamicValidation.dynamicErrors.push(syncDynamicError)\n return\n }\n\n if (isClientHookDynamicError(dynamicReason)) {\n dynamicValidation.dynamicErrors.push(\n addErrorContext(dynamicReason, componentStack, null)\n )\n return\n }\n\n const error = addErrorContext(\n isServerPartial\n ? // This hole may be caused by server data.\n // (NOTE: this may misreport client dynamic holes as server holes)\n createBodyErrorInStaticRoute(kind, workStore.route)\n : // TODO(ensure-static): this could be something client-specific because we know\n // that server data is complete\n createBodyError(kind, workStore.route),\n componentStack,\n null\n )\n dynamicValidation.dynamicErrors.push(error)\n}\n\nexport function trackAllowedDynamicAccess(\n dynamicReason: unknown,\n workStore: WorkStore,\n componentStack: string,\n dynamicValidation: DynamicValidationState,\n clientDynamic: DynamicTrackingState\n) {\n const dynamicHoleKind = DynamicHoleKind.RuntimeOrDynamic\n\n const syncDynamicError = getPendingClientSyncDynamicError(clientDynamic)\n\n if (hasOutletRegex.test(componentStack)) {\n trackOutletSuspenseAboveBody(componentStack, dynamicValidation)\n return\n } else if (hasMetadataRegex.test(componentStack)) {\n dynamicValidation.hasDynamicMetadata = true\n return\n } else if (hasViewportRegex.test(componentStack)) {\n dynamicValidation.hasDynamicViewport = true\n return\n } else if (\n hasSuspenseBeforeRootLayoutWithoutBodyOrImplicitBodyRegex.test(\n componentStack\n )\n ) {\n // For Suspense within body, the prelude wouldn't be empty so it wouldn't violate the empty static shells rule.\n // But if you have Suspense above body, the prelude is empty but we allow that because having Suspense\n // is an explicit signal from the user that they acknowledge the empty shell and want dynamic rendering.\n dynamicValidation.hasAllowedDynamic = true\n dynamicValidation.hasSuspenseAboveBody = true\n return\n } else if (hasSuspenseRegex.test(componentStack)) {\n // this error had a Suspense boundary above it so we don't need to report it as a source\n // of disallowed\n dynamicValidation.hasAllowedDynamic = true\n return\n } else if (syncDynamicError) {\n dynamicValidation.dynamicErrors.push(syncDynamicError)\n return\n }\n\n if (isClientHookDynamicError(dynamicReason)) {\n dynamicValidation.dynamicErrors.push(\n addErrorContext(dynamicReason, componentStack, null)\n )\n return\n }\n\n const error = addErrorContext(\n createBodyError(dynamicHoleKind, workStore.route),\n componentStack,\n null\n )\n dynamicValidation.dynamicErrors.push(error)\n return\n}\n\nexport enum DynamicHoleKind {\n /** We know that this hole is caused by runtime data. */\n Runtime = 1,\n /** We know that this hole is caused by link data. */\n Link = 2,\n /** We know that this hole is caused by navigation(). */\n Navigation = 3,\n /** We know that this hole is caused by prefetch(). */\n Prefetch = 4,\n /** We know that this hole is caused by dynamic data. */\n Dynamic = 5,\n /** We know that this hole is caused by runtime or dynamic data, but don't know which. */\n RuntimeOrDynamic = 6,\n}\n\n// In Instant Validation we can always discriminate between runtime and dynamic.\nexport type InstantValidationHoleKind = Exclude<\n DynamicHoleKind,\n DynamicHoleKind.RuntimeOrDynamic\n>\n\nexport type StaticValidationHoleKind =\n // During dev-time static validation we can discriminate runtime and dynamic.\n | DynamicHoleKind.Runtime\n | DynamicHoleKind.Dynamic\n // During build-time static validation we can't discriminate runtime and dynamic.\n | DynamicHoleKind.RuntimeOrDynamic\n\n/** Stores dynamic reasons used during an SSR render in instant validation. */\nexport type InstantValidationState = {\n hasDynamicMetadata: boolean\n hasAllowedClientDynamicAboveBoundary: boolean\n dynamicMetadata: null | Error\n hasDynamicViewport: boolean\n hasAllowedDynamic: boolean\n dynamicErrors: Array<Error>\n validationPreventingErrors: Array<Error>\n thrownErrorsOutsideBoundary: Array<unknown>\n /** Per-slot config factories. Index 0 is the root config (fallback).\n * Indices 1+ correspond to slot marker components in the tree. */\n slotStacks: Array<(() => Error) | null>\n}\n\nexport function createInstantValidationState(\n slotStacks: Array<(() => Error) | null>\n): InstantValidationState {\n return {\n hasDynamicMetadata: false,\n hasAllowedClientDynamicAboveBoundary: false,\n dynamicMetadata: null,\n hasDynamicViewport: false,\n hasAllowedDynamic: false,\n dynamicErrors: [],\n validationPreventingErrors: [],\n thrownErrorsOutsideBoundary: [],\n slotStacks,\n }\n}\n\nexport function trackDynamicHoleInNavigation(\n dynamicReason: unknown,\n workStore: WorkStore,\n componentStack: string,\n dynamicValidation: InstantValidationState,\n clientDynamic: DynamicTrackingState,\n kind: InstantValidationHoleKind,\n boundaryState: ValidationBoundaryTracking\n) {\n const syncDynamicError = getPendingClientSyncDynamicError(clientDynamic)\n\n if (hasOutletRegex.test(componentStack)) {\n // We don't need to track that this is dynamic. It is only so when something else is also dynamic.\n return\n }\n // Resolve the config stack for this specific error. If the error\n // is inside a slot marker, use that slot's config. Otherwise fall\n // back to the default.\n const effectiveCreateInstantStack = resolveInstantStack(\n componentStack,\n dynamicValidation\n )\n\n if (hasMetadataRegex.test(componentStack)) {\n const error = addErrorContext(\n createMetadataError(kind, workStore.route),\n componentStack,\n effectiveCreateInstantStack\n )\n dynamicValidation.dynamicMetadata = error\n return\n }\n if (hasViewportRegex.test(componentStack)) {\n const error = addErrorContext(\n createViewportError(kind, workStore.route),\n componentStack,\n effectiveCreateInstantStack\n )\n dynamicValidation.dynamicErrors.push(error)\n return\n }\n\n const boundaryLocation =\n hasInstantValidationBoundaryRegex.exec(componentStack)\n if (!boundaryLocation) {\n // We don't see the validation boundary in the component stack,\n // so this hole must be coming from a shared parent.\n // Shared parents are fully resolved and don't have RSC holes,\n // but they can still suspend in a client component during SSR.\n\n // If we managed to render all the validation boundaries, that means\n // that the client holes aren't blocking validation and we can disregard them.\n // Note that we don't even care whether they have suspense or not.\n if (allRequiredBoundariesRendered(boundaryState)) {\n dynamicValidation.hasAllowedClientDynamicAboveBoundary = true\n dynamicValidation.hasAllowedDynamic = true // Holes outside the boundary contribute to allowing dynamic metadata\n return\n } else {\n // TODO(instant-validation) TODO(NAR-787)\n // If shared parents blocked us from validating, we should only log\n // the errors from the innermost (segments), i.e. omit layouts whose\n // slots managed to render (because clearly they didn't block validation)\n const message = `Route \"${workStore.route}\": Could not validate \\`instant\\` because a Client Component in a parent segment prevented the page from rendering.`\n const error = addErrorContext(\n new Error(message),\n componentStack,\n effectiveCreateInstantStack\n )\n dynamicValidation.validationPreventingErrors.push(error)\n return\n }\n } else {\n // The hole originates inside the validation boundary.\n //\n // Check if we have a Suspense above the hole, but below the validation boundary.\n // If we do, then this dynamic usage wouldn't block a navigation to this subtree.\n // Conversely, if the nearest suspense is above the validation boundary, then this subtree would block.\n //\n // Note that in the component stack, children come before parents.\n //\n // Valid:\n // ...\n // at Suspense\n // ...\n // at __next_prefetch_validation_boundary__\n //\n // Invalid:\n // ...\n // at __next_prefetch_validation_boundary__\n // ...\n // at Suspense\n //\n const suspenseLocation = hasSuspenseRegex.exec(componentStack)\n if (suspenseLocation) {\n if (suspenseLocation.index < boundaryLocation.index) {\n dynamicValidation.hasAllowedDynamic = true\n return\n } else {\n // invalid - fallthrough\n }\n }\n }\n\n if (syncDynamicError) {\n if (\n effectiveCreateInstantStack !== null &&\n syncDynamicError.cause === undefined\n ) {\n syncDynamicError.cause = effectiveCreateInstantStack()\n }\n dynamicValidation.dynamicErrors.push(syncDynamicError)\n return\n }\n\n if (isClientHookDynamicError(dynamicReason)) {\n dynamicValidation.dynamicErrors.push(\n addErrorContext(\n dynamicReason,\n componentStack,\n effectiveCreateInstantStack\n )\n )\n return\n }\n\n const error = addErrorContext(\n createBodyErrorInNavigation(kind, workStore.route),\n componentStack,\n effectiveCreateInstantStack\n )\n dynamicValidation.dynamicErrors.push(error)\n return\n}\n\nfunction createBodyError(kind: StaticValidationHoleKind, route: string): Error {\n switch (kind) {\n case DynamicHoleKind.Runtime:\n return createRuntimeBodyError(route)\n case DynamicHoleKind.Dynamic:\n return createDynamicBodyError(route)\n case DynamicHoleKind.RuntimeOrDynamic:\n return createDynamicOrRuntimeBodyError(route)\n }\n}\n\nfunction createBodyErrorInNavigation(\n kind: InstantValidationHoleKind,\n route: string\n): Error {\n switch (kind) {\n case DynamicHoleKind.Runtime:\n return createRuntimeBodyErrorInNavigation(route)\n case DynamicHoleKind.Link:\n return createLinkBodyErrorInNavigation(route)\n case DynamicHoleKind.Navigation:\n return createNavigationBodyErrorInNavigation(route)\n case DynamicHoleKind.Prefetch:\n return createPrefetchBodyErrorInNavigation(route)\n case DynamicHoleKind.Dynamic:\n return createDynamicBodyErrorInNavigation(route)\n }\n}\n\nfunction createMetadataError(kind: DynamicHoleKind, route: string): Error {\n switch (kind) {\n case DynamicHoleKind.Runtime:\n return createRuntimeMetadataError(route)\n case DynamicHoleKind.Link:\n return createLinkMetadataError(route)\n case DynamicHoleKind.Navigation:\n return createNavigationMetadataError(route)\n case DynamicHoleKind.Prefetch:\n return createPrefetchMetadataError(route)\n case DynamicHoleKind.Dynamic:\n return createDynamicMetadataError(route)\n case DynamicHoleKind.RuntimeOrDynamic:\n return createDynamicOrRuntimeMetadataError(route)\n }\n}\n\nfunction createViewportError(kind: DynamicHoleKind, route: string): Error {\n switch (kind) {\n case DynamicHoleKind.Runtime:\n return createRuntimeViewportError(route)\n case DynamicHoleKind.Link:\n return createLinkViewportError(route)\n case DynamicHoleKind.Navigation:\n return createNavigationViewportError(route)\n case DynamicHoleKind.Prefetch:\n return createPrefetchViewportError(route)\n case DynamicHoleKind.Dynamic:\n return createDynamicViewportError(route)\n case DynamicHoleKind.RuntimeOrDynamic:\n return createDynamicOrRuntimeViewportError(route)\n }\n}\n\nfunction createBodyErrorInStaticRoute(\n kind: StaticValidationHoleKind,\n route: string\n): Error {\n switch (kind) {\n case DynamicHoleKind.Runtime:\n return createRuntimeBodyErrorInStaticRoute(route)\n case DynamicHoleKind.Dynamic:\n return createDynamicBodyErrorInStaticRoute(route)\n case DynamicHoleKind.RuntimeOrDynamic:\n return createNonPrerenderableBodyErrorInStaticRoute(route)\n }\n}\n\nfunction createMetadataErrorInStaticRoute(\n kind: StaticValidationHoleKind,\n route: string\n) {\n switch (kind) {\n case DynamicHoleKind.Runtime:\n return createRuntimeMetadataErrorInStaticRoute(route)\n case DynamicHoleKind.Dynamic:\n return createDynamicMetadataErrorInStaticRoute(route)\n case DynamicHoleKind.RuntimeOrDynamic:\n return createNonPrerenderableMetadataErrorInStaticRoute(route)\n }\n}\n\nfunction createViewportErrorInStaticRoute(\n kind: StaticValidationHoleKind,\n route: string\n) {\n switch (kind) {\n case DynamicHoleKind.Runtime:\n return createRuntimeViewportErrorInStaticRoute(route)\n case DynamicHoleKind.Dynamic:\n return createDynamicViewportErrorInStaticRoute(route)\n case DynamicHoleKind.RuntimeOrDynamic:\n return createNonPrerenderableViewportErrorInStaticRoute(route)\n }\n}\n\nexport function trackThrownErrorInNavigation(\n workStore: WorkStore,\n dynamicValidation: InstantValidationState,\n thrownValue: unknown,\n componentStack: string,\n reactBrowserBailout: boolean\n) {\n const boundaryLocation =\n hasInstantValidationBoundaryRegex.exec(componentStack)\n if (!boundaryLocation) {\n // There's no validation boundary on the component stack.\n // This error may have blocked a boundary from rendering.\n\n // Wrap the error to provide component context.\n // This helps for errors from node_modules which would otherwise\n // have no useful stack information due to ignore-listing,\n // e.g. next/dynamic with `ssr: false`.\n if (reactBrowserBailout) {\n // React preserves Next's branded bailout reason as the error cause.\n // Replace the internal wrapper before storing the user-facing diagnostic.\n const browserBailoutReason = getReactBrowserBailoutReason(thrownValue)\n if (browserBailoutReason !== undefined) {\n const browserBailoutError = thrownValue as Error\n browserBailoutError.cause = browserBailoutReason\n }\n }\n\n const error = addErrorContext(\n new Error(\n 'An error occurred while attempting to validate instant UI. This error may be preventing the validation from completing.',\n { cause: thrownValue }\n ),\n componentStack,\n null\n )\n dynamicValidation.thrownErrorsOutsideBoundary.push(error)\n } else {\n // There's validation boundary on the component stack,\n // so we know this error didn't block a validation boundary from rendering.\n // However, this error might be hiding be hiding dynamic content that would\n // cause validation to fail.\n const suspenseLocation = hasSuspenseRegex.exec(componentStack)\n if (suspenseLocation) {\n if (suspenseLocation.index < boundaryLocation.index) {\n // There's a Suspense below the validation boundary but above this error's location.\n // This subtree can't fail instant validation because any potential\n // dynamic holes would be guarded by the Suspense anyway,\n // so we can allow this.\n return\n } else {\n // invalid - fallthrough\n }\n }\n if (reactBrowserBailout) {\n // React preserves Next's branded bailout reason as the error cause.\n // Replace the internal wrapper before storing the user-facing diagnostic.\n const browserBailoutReason = getReactBrowserBailoutReason(thrownValue)\n if (browserBailoutReason !== undefined) {\n const browserBailoutError = thrownValue as Error\n browserBailoutError.cause = browserBailoutReason\n }\n }\n\n const message = `Route \"${workStore.route}\": Could not validate \\`instant\\` because an error prevented the target segment from rendering.`\n const error = addErrorContext(\n new Error(message, { cause: thrownValue }),\n componentStack,\n null // TODO(instant-validation-build): conflicting use of cause\n )\n dynamicValidation.validationPreventingErrors.push(error)\n }\n}\n\nexport function trackDynamicHoleInStaticShell(\n dynamicReason: unknown,\n workStore: WorkStore,\n componentStack: string,\n dynamicValidation: DynamicValidationState,\n clientDynamic: DynamicTrackingState,\n kind: DynamicHoleKind.Runtime | DynamicHoleKind.Dynamic\n) {\n const syncDynamicError = getPendingClientSyncDynamicError(clientDynamic)\n\n if (hasOutletRegex.test(componentStack)) {\n trackOutletSuspenseAboveBody(componentStack, dynamicValidation)\n return\n } else if (hasMetadataRegex.test(componentStack)) {\n const error = addErrorContext(\n createMetadataError(kind, workStore.route),\n componentStack,\n null\n )\n dynamicValidation.dynamicMetadata = error\n return\n } else if (hasViewportRegex.test(componentStack)) {\n const error = addErrorContext(\n createViewportError(kind, workStore.route),\n componentStack,\n null\n )\n dynamicValidation.dynamicErrors.push(error)\n return\n } else if (\n hasSuspenseBeforeRootLayoutWithoutBodyOrImplicitBodyRegex.test(\n componentStack\n )\n ) {\n // For Suspense within body, the prelude wouldn't be empty so it wouldn't violate the empty static shells rule.\n // But if you have Suspense above body, the prelude is empty but we allow that because having Suspense\n // is an explicit signal from the user that they acknowledge the empty shell and want dynamic rendering.\n dynamicValidation.hasAllowedDynamic = true\n dynamicValidation.hasSuspenseAboveBody = true\n return\n } else if (hasSuspenseRegex.test(componentStack)) {\n // this error had a Suspense boundary above it so we don't need to report it as a source\n // of disallowed\n dynamicValidation.hasAllowedDynamic = true\n return\n } else if (syncDynamicError) {\n dynamicValidation.dynamicErrors.push(syncDynamicError)\n return\n }\n\n if (isClientHookDynamicError(dynamicReason)) {\n dynamicValidation.dynamicErrors.push(\n addErrorContext(dynamicReason, componentStack, null)\n )\n return\n }\n\n const error = addErrorContext(\n kind === DynamicHoleKind.Runtime\n ? createRuntimeBodyError(workStore.route)\n : createDynamicBodyError(workStore.route),\n componentStack,\n null\n )\n dynamicValidation.dynamicErrors.push(error)\n return\n}\n\n/**\n * In dev mode, we prefer using the owner stack, otherwise the provided\n * component stack is used.\n */\nfunction addErrorContext(\n error: Error,\n componentStack: string,\n createInstantStack: (() => Error) | null\n) {\n const ownerStack =\n process.env.NODE_ENV !== 'production' && React.captureOwnerStack\n ? React.captureOwnerStack()\n : null\n\n if (createInstantStack !== null) {\n error.cause = createInstantStack()\n }\n // TODO go back to owner stack here if available. This is temporarily using componentStack to get the right\n //\n error.stack =\n error.name + ': ' + error.message + (ownerStack || componentStack)\n return error\n}\n\nexport enum PreludeState {\n Full = 0,\n Empty = 1,\n Errored = 2,\n}\n\nexport function logDisallowedDynamicError(\n workStore: WorkStore,\n error: Error\n): void {\n console.error(error)\n logBuildDebugHint(workStore.route)\n}\n\nexport function throwIfSyncIOUsed(\n workStore: WorkStore,\n serverDynamic: DynamicTrackingState\n) {\n if (serverDynamic.syncDynamicErrorWithStack) {\n logDisallowedDynamicError(\n workStore,\n serverDynamic.syncDynamicErrorWithStack\n )\n throw new StaticGenBailoutError()\n }\n}\n\nexport function throwIfDisallowedDynamic(\n workStore: WorkStore,\n prelude: PreludeState,\n dynamicValidation: DynamicValidationState,\n serverDynamic: DynamicTrackingState,\n allowEmptyStaticShell: boolean\n): void {\n const dynamicHoleKind = DynamicHoleKind.RuntimeOrDynamic\n\n throwIfSyncIOUsed(workStore, serverDynamic)\n\n // The dynamic metadata error is a mistake-detection signal. It fires when the\n // rest of the shell is otherwise fully static apart from metadata, suggesting\n // the dynamic data access in `generateMetadata` was probably unintentional.\n // That condition is independent of whether the user or build phase accepted\n // an empty shell, so we surface it before any opt-in bypass.\n if (\n prelude === PreludeState.Full &&\n dynamicValidation.hasAllowedDynamic === false &&\n dynamicValidation.hasDynamicMetadata\n ) {\n console.error(createMetadataError(dynamicHoleKind, workStore.route).message)\n throw new StaticGenBailoutError()\n }\n\n // Either flag expresses \"this shell is allowed to be empty/blocking\":\n // - `allowEmptyStaticShell` covers `instant = false` (user opt-in)\n // and the build-phase fallback-shell case.\n // - `hasSuspenseAboveBody` is the structural opt-in inside the user's root\n // layout.\n // Treat them as synonyms for the purpose of bypassing shell-failure errors.\n if (allowEmptyStaticShell || dynamicValidation.hasSuspenseAboveBody) {\n return\n }\n\n if (prelude !== PreludeState.Full) {\n // We didn't have any sync bailouts but there may be user code which\n // blocked the root. We would have captured these during the prerender\n // and can log them here and then terminate the build/validating render\n const dynamicErrors = dynamicValidation.dynamicErrors\n if (dynamicErrors.length > 0) {\n for (let i = 0; i < dynamicErrors.length; i++) {\n logDisallowedDynamicError(workStore, dynamicErrors[i])\n }\n\n throw new StaticGenBailoutError()\n }\n\n // If we got this far then the only other thing that could be blocking\n // the root is dynamic Viewport. If this is dynamic then\n // you need to opt into that by adding a Suspense boundary above the body\n // to indicate your are ok with fully dynamic rendering.\n if (dynamicValidation.hasDynamicViewport) {\n console.error(\n createViewportError(dynamicHoleKind, workStore.route).message\n )\n throw new StaticGenBailoutError()\n }\n\n if (prelude === PreludeState.Empty) {\n // If we ever get this far then we messed up the tracking of invalid dynamic.\n // We still adhere to the constraint that you must produce a shell but invite the\n // user to report this as a bug in Next.js.\n console.error(\n `Route \"${workStore.route}\" did not produce a static shell and Next.js was unable to determine a reason. This is a bug in Next.js.`\n )\n throw new StaticGenBailoutError()\n }\n }\n}\n\nexport function throwIfDisallowedDynamicInStaticRoute(\n workStore: WorkStore,\n prelude: PreludeState,\n dynamicValidation: DynamicValidationState,\n serverDynamic: DynamicTrackingState,\n isFallbackShell: boolean,\n allowEmptyStaticShell: boolean,\n isServerPartial: boolean\n): void {\n const reasons = getDisallowedReasonsInStaticRoute(\n workStore,\n prelude,\n dynamicValidation,\n serverDynamic,\n isFallbackShell,\n allowEmptyStaticShell,\n isServerPartial\n )\n if (reasons.length > 0) {\n for (const reason of reasons) {\n logDisallowedDynamicError(workStore, reason)\n }\n throw new StaticGenBailoutError()\n }\n}\n\nexport function getDisallowedReasonsInStaticRoute(\n workStore: WorkStore,\n prelude: PreludeState,\n dynamicValidation: DynamicValidationState,\n serverDynamic: DynamicTrackingState | null,\n isFallbackShell: boolean,\n allowEmptyStaticShell: boolean,\n isServerPartial: boolean\n): Error[] {\n if (serverDynamic && serverDynamic.syncDynamicErrorWithStack) {\n return [serverDynamic.syncDynamicErrorWithStack]\n }\n\n // We do a fallback shell prerender, but it's not meant to be validated --\n // we just need it to create the relevant prerender outputs.\n if (isFallbackShell) {\n return []\n }\n\n // Suspense-above-body and `instant = false` bypass reporting\n // that the shell is blocked. However, if we have non-prerenderable server\n // data, we still have to error, regardless of those two.\n if (\n !isServerPartial &&\n (allowEmptyStaticShell || dynamicValidation.hasSuspenseAboveBody)\n ) {\n return []\n }\n\n const { dynamicErrors } = dynamicValidation\n if (dynamicErrors.length > 0) {\n return dynamicErrors\n }\n\n // Dynamic data may have been passed into a client component without calling `use()`,\n // in which case we wouldn't see it during the prerender, but still need to error.\n // Fall back to a generic error message.\n if (isServerPartial) {\n return [\n new Error(\n `Route \"${workStore.route}\": Next.js encountered data that is not available during a static prerender, but is unable to provide a location.`\n ),\n ]\n }\n\n if (prelude === PreludeState.Empty || prelude === PreludeState.Errored) {\n // We've somehow ended up with an empty prelude but no dynamic errors.\n // We must've messed up the tracking somehow.\n return [\n new InvariantError(\n `Route \"${workStore.route}\" did not produce a static shell and Next.js was unable to determine a reason.`\n ),\n ]\n }\n return []\n}\n\nexport function getStaticShellDisallowedDynamicReasons(\n workStore: WorkStore,\n prelude: PreludeState,\n dynamicValidation: DynamicValidationState,\n allowEmptyStaticShell: boolean\n): Array<Error> {\n // The dynamic metadata error is a mistake-detection signal. It fires when the\n // rest of the shell is otherwise fully static apart from metadata, suggesting\n // the dynamic data access in `generateMetadata` was probably unintentional.\n // That condition is independent of whether the user or build phase accepted\n // an empty shell, so we surface it before any opt-in bypass.\n if (\n prelude === PreludeState.Full &&\n dynamicValidation.hasAllowedDynamic === false &&\n dynamicValidation.dynamicErrors.length === 0 &&\n dynamicValidation.dynamicMetadata\n ) {\n return [dynamicValidation.dynamicMetadata]\n }\n\n // Either flag expresses \"this shell is allowed to be empty/blocking\":\n // - `allowEmptyStaticShell` covers `instant = false` (user opt-in)\n // and the build-phase fallback-shell case.\n // - `hasSuspenseAboveBody` is the structural opt-in inside the user's root\n // layout.\n // Treat them as synonyms for the purpose of bypassing shell-failure errors.\n if (allowEmptyStaticShell || dynamicValidation.hasSuspenseAboveBody) {\n return []\n }\n\n if (prelude !== PreludeState.Full) {\n // We didn't have any sync bailouts but there may be user code which\n // blocked the root. We would have captured these during the prerender\n // and can log them here and then terminate the build/validating render\n const dynamicErrors = dynamicValidation.dynamicErrors\n if (dynamicErrors.length > 0) {\n return dynamicErrors\n }\n\n if (prelude === PreludeState.Empty) {\n // If we ever get this far then we messed up the tracking of invalid dynamic.\n // We still adhere to the constraint that you must produce a shell but invite the\n // user to report this as a bug in Next.js.\n return [\n new InvariantError(\n `Route \"${workStore.route}\" did not produce a static shell and Next.js was unable to determine a reason.`\n ),\n ]\n }\n }\n // We had a non-empty prelude and there are no dynamic holes\n return []\n}\n\n/**\n * `errors` are validation failures that should be surfaced immediately.\n * `deferredFallback` carries a missing-boundary explanation that the caller\n * should hold back until *every* validation depth has been tried — a missing\n * boundary often just means a parent layout intentionally omitted a slot, and\n * a different depth's validation may surface a more meaningful error.\n */\nexport type NavigationValidationResult =\n // instances that block instant navigation\n | Array<Error>\n // validation was blocked with zero or more reasons\n | Error\n | AggregateError\n\nexport function getNavigationDisallowedDynamicReasons(\n workStore: WorkStore,\n prelude: PreludeState,\n dynamicValidation: InstantValidationState,\n validationSampleTracking: InstantValidationSampleTracking | null,\n boundaryState: ValidationBoundaryTracking,\n devRenderDidError: boolean\n): NavigationValidationResult {\n // If we have errors related to missing samples, those should take precedence over everything else.\n if (validationSampleTracking) {\n const { missingSampleErrors } = validationSampleTracking\n if (missingSampleErrors.length > 0) {\n return missingSampleErrors\n }\n }\n\n const { validationPreventingErrors } = dynamicValidation\n if (validationPreventingErrors.length > 0) {\n if (process.env.__NEXT_DEV_SERVER && devRenderDidError) {\n // The dev render already surfaced server errors to the user.\n // The same errors likely caused validation to be inconclusive,\n // so reporting them again as validation failures would be noisy.\n return []\n }\n return validationPreventingErrors\n }\n\n // NOTE: We don't care about Suspense above body here,\n // we're only concerned with the validation boundary\n if (prelude !== PreludeState.Full) {\n const dynamicErrors = dynamicValidation.dynamicErrors\n if (dynamicErrors.length > 0) {\n return dynamicErrors\n }\n\n if (\n prelude === PreludeState.Empty &&\n !dynamicValidation.hasAllowedClientDynamicAboveBoundary &&\n allRequiredBoundariesRendered(boundaryState)\n ) {\n // If we ever get this far then we messed up the tracking of invalid\n // dynamic. (When boundaries are missing the deferred fallback below\n // will surface a more useful error.)\n return new InvariantError(\n `Route \"${workStore.route}\" failed to render during instant validation and Next.js was unable to determine a reason.`\n )\n }\n } else {\n const dynamicErrors = dynamicValidation.dynamicErrors\n if (dynamicErrors.length > 0) {\n return dynamicErrors\n }\n\n if (\n dynamicValidation.hasAllowedDynamic === false &&\n dynamicValidation.dynamicMetadata\n ) {\n return [dynamicValidation.dynamicMetadata]\n }\n }\n\n // Missing boundaries on their own aren't a strong signal — a parent\n // layout may legitimately omit a slot. Defer this so the caller can\n // try shallower validation depths first; if every depth comes up\n // empty we still want to surface this so the user is made aware that\n // validation didn't complete. When we add a markers API, the\n // marker-based variant of this check can become strict again.\n if (!allRequiredBoundariesRendered(boundaryState)) {\n const { thrownErrorsOutsideBoundary } = dynamicValidation\n const rootInstantStack = dynamicValidation.slotStacks[0]\n if (thrownErrorsOutsideBoundary.length === 0) {\n const missingFiles: string[] = []\n for (const [id, filePaths] of boundaryState.requiredIds) {\n if (!boundaryState.renderedIds.has(id)) {\n for (const filePath of filePaths) {\n let normalized = filePath\n .replace(/^\\[project\\][\\\\/]?/, '')\n .replace(process.cwd() + '/', '')\n .replace(process.cwd() + '\\\\', '')\n missingFiles.push(normalized)\n }\n }\n }\n missingFiles.sort()\n return createUnrenderedSegmentError(workStore.route, missingFiles)\n } else if (process.env.__NEXT_DEV_SERVER && devRenderDidError) {\n // Errors outside the boundary likely blocked it from rendering,\n // but they're already being reported to the user via the dev\n // render. Suppress the validation failure to avoid noise.\n return []\n } else if (thrownErrorsOutsideBoundary.length === 1) {\n const message = `Route \"${workStore.route}\": Could not validate \\`instant\\` because the target segment was prevented from rendering, likely due to the following error.`\n const error = rootInstantStack !== null ? rootInstantStack() : new Error()\n error.name = 'Error'\n error.message = message\n return new AggregateError([\n error,\n thrownErrorsOutsideBoundary[0] as Error,\n ])\n } else {\n const message = `Route \"${workStore.route}\": Could not validate \\`instant\\` because the target segment was prevented from rendering, likely due to one of the following errors.`\n const error = rootInstantStack !== null ? rootInstantStack() : new Error()\n error.name = 'Error'\n error.message = message\n return new AggregateError([\n error,\n ...(thrownErrorsOutsideBoundary as Error[]),\n ])\n }\n }\n\n // We had a non-empty prelude and there are no dynamic holes\n return []\n}\n","export const INSTANT_VALIDATION_BOUNDARY_NAME =\n '__next_instant_validation_boundary__'\n\nexport const INSTANT_SLOT_MARKER_PREFIX = '__next_instant_slot_'\nexport const INSTANT_SLOT_MARKER_SUFFIX = '__'\n","export type ValidationBoundaryTracking = {\n /**\n * Map from boundary id (the SegmentPath where a validation boundary is\n * placed) to the file paths of modules inside that boundary's subtree.\n * When the boundary spans multiple parallel slots, each slot contributes\n * its own first-found module path so all unrendered segments can be\n * reported together.\n */\n requiredIds: Map<string, string[]>\n renderedIds: Set<string>\n}\n\nexport function createValidationBoundaryTracking(\n /** Pass if the render is expected to render the same IDs as a previous one. */\n matchPrevious?: ValidationBoundaryTracking\n): ValidationBoundaryTracking {\n return {\n requiredIds: matchPrevious ? new Map(matchPrevious.requiredIds) : new Map(),\n renderedIds: new Set(),\n }\n}\n\nexport function allRequiredBoundariesRendered(\n state: ValidationBoundaryTracking\n): boolean {\n for (const id of state.requiredIds.keys()) {\n if (!state.renderedIds.has(id)) {\n return false\n }\n }\n return true\n}\n","import type {\n AppSegmentConfig,\n EnsureStatic,\n} from '../../../build/segment-config/app/app-segment-config'\nimport { parseLoaderTree } from '../../../shared/lib/router/utils/parse-loader-tree'\nimport {\n getLayoutOrPageModule,\n type LoaderTree,\n} from '../../lib/app-dir-module'\n\n/**\n * The outcome of resolving a route's `ensureStatic` config.\n * The ordering is intentional -- higher values indicate a\n * more constrained route that forces more request kinds to be static.\n *\n * A constraint also implies all its predecessors:\n * - `Prefetch` implies `Shell`, i.e. if prefetches are static, so are shells.\n * - `Navigation` implies `Prefetch` and `Shell`, i.e. if the whole page is static,\n * then so are its shells and prefetches.\n *\n * Note that this flattens `\"auto\"` and `false` into `None`.\n * This is because rendering code does not need to distinguish them --\n * both indicate that the route follows normal Partial Prefetching semantics\n * and does not force anything to be static.\n * However, it is only correct to collapse them into one *after* resolving the\n * config for the entire route, because they have different interactions with\n * configs from other segments on the same route.\n */\nexport enum EnsureStaticLevel {\n /** The route follows standard Partial Prefetching semantics. */\n None = 0,\n /** The route requires that app shells must be statically prerendered. */\n Shell = 1,\n /** The route requires that app shells and prefetches must be statically prerendered. */\n Prefetch = 2,\n /** The route requires that app shells, prefetches, and the whole page must be statically prerendered. */\n Navigation = 3,\n}\n\nfunction getEnsureStaticLevel(ensureStatic: EnsureStatic) {\n switch (ensureStatic) {\n case 'auto':\n case false: {\n return EnsureStaticLevel.None\n }\n case 'shell': {\n return EnsureStaticLevel.Shell\n }\n case 'prefetch': {\n return EnsureStaticLevel.Prefetch\n }\n case 'navigation': {\n return EnsureStaticLevel.Navigation\n }\n }\n}\n\nexport async function resolveEnsureStaticLevel(\n tree: LoaderTree,\n partialPrefetching: boolean\n): Promise<EnsureStaticLevel> {\n return getEnsureStaticLevel(\n await resolveEnsureStaticConfig(tree, partialPrefetching)\n )\n}\n\nexport async function resolveEnsureStaticConfig(\n tree: LoaderTree,\n partialPrefetching: boolean\n): Promise<Exclude<EnsureStatic, false>> {\n let { config, filePath } = await resolveEnsureStaticConfigImpl(tree)\n\n if (!partialPrefetching) {\n // If Partial Prefetching is not enabled for this route, we only support\n // a subset of `ensureStatic` values.\n // (We error in `getAppPageStaticInfo` if `ensureStatic` is used without enabling\n // Cache Components, so we don't have to assert that here)\n switch (config) {\n case 'auto': {\n // Default to the equivalent of Cache Components prefetching behavior.\n config = 'prefetch'\n break\n }\n case false:\n case 'shell': {\n // Not meaningful in Cache Components without Partial Prefetching\n const originalConfig = config\n config = 'prefetch'\n console.warn(\n `${formatEnsureStaticExport(originalConfig)} has no effect unless the route is using Partial Prefetching.` +\n `\\n (from: ${filePath})`\n )\n break\n }\n case 'prefetch':\n // Equivalent to regular Cache Components behavior, so we allow it\n // without warning to avoid noise when doing gradual opt-in\n break\n case 'navigation':\n // Meaningful in Cache Components, even without Partial Prefetching\n break\n default:\n config satisfies never\n }\n }\n\n if (config === false) {\n // `false` and \"auto\" are equivalent once resolved.\n return 'auto'\n } else {\n return config\n }\n}\n\ntype EnsureStaticWithSource = {\n config: EnsureStatic\n filePath: string | null\n}\n\nasync function resolveEnsureStaticConfigImpl(\n tree: LoaderTree\n): Promise<EnsureStaticWithSource> {\n const { mod: layoutOrPageMod, filePath } = await getLayoutOrPageModule(tree)\n\n const config = getEnsureStaticConfigForModule(layoutOrPageMod)\n\n const parentResult: EnsureStaticWithSource = {\n config,\n filePath: filePath ?? null,\n }\n\n // Walk the slots if any and validate that they don't have incompatible configs\n // with each other. If compatible, pick the most constrained value from the slots.\n let slotsResult: EnsureStaticWithSource | null = null\n let slotResultKey: string | null = null\n const { parallelRoutes } = parseLoaderTree(tree)\n for (const parallelRouteKey in parallelRoutes) {\n const parallelRoute = parallelRoutes[parallelRouteKey]\n const childResult = await resolveEnsureStaticConfigImpl(parallelRoute)\n if (!slotsResult) {\n slotsResult = childResult\n slotResultKey = parallelRouteKey\n } else {\n // Check if the child is compatible with the current result for the slots.\n switch (compareEnsureStatic(childResult.config, slotsResult.config)) {\n case Comparison.Compatible: {\n // 'auto' is compatible with anything, but if the current result is 'auto' and the new one isn't,\n // we want to use the more specific result.\n if (slotsResult.config === 'auto' && childResult.config !== 'auto') {\n slotsResult = childResult\n slotResultKey = parallelRouteKey\n }\n break\n }\n case Comparison.Incompatible:\n case Comparison.LessConstrained:\n case Comparison.MoreConstrained: {\n throw new Error(\n `Parallel slots cannot have incompatible \\`ensureStatic\\`.` +\n `\\n ${formatParallelSlot(slotResultKey!)}: ` +\n `\\n ${formatEnsureStaticExport(slotsResult.config)}` +\n `\\n (from: ${slotsResult.filePath})` +\n `\\n` +\n `\\n ${formatParallelSlot(parallelRouteKey)}: ` +\n `\\n ${formatEnsureStaticExport(childResult.config)}` +\n `\\n (from: ${childResult.filePath})` +\n `\\n` +\n `\\n Possible fixes:` +\n `\\n - Remove one of the \\`ensureStatic\\` exports` +\n `\\n - Change one of the \\`ensureStatic\\` exports to match the other`\n )\n }\n }\n }\n }\n\n // Child segments can override the config from the parent with a more constrained value,\n // but they cannot have a less constrained value.\n if (!slotsResult) {\n return parentResult\n } else {\n const comparison = compareEnsureStatic(\n slotsResult.config,\n parentResult.config\n )\n switch (comparison) {\n case Comparison.Compatible: {\n // 'auto' is compatible with anything, but if the parent result is 'auto' and the slots one isn't,\n // we want to use the more constrained result.\n if (parentResult.config === 'auto' && slotsResult.config !== 'auto') {\n return slotsResult\n } else {\n return parentResult\n }\n }\n case Comparison.MoreConstrained: {\n return slotsResult\n }\n case Comparison.LessConstrained:\n case Comparison.Incompatible: {\n throw new Error(\n (comparison === Comparison.LessConstrained\n ? `A child segment cannot override a parent segment with a less-constrained \\`ensureStatic\\`.`\n : `A child segment cannot override a parent segment with an incompatible \\`ensureStatic\\`.`) +\n `\\n Parent has: ` +\n `\\n ${formatEnsureStaticExport(parentResult.config)}` +\n `\\n (from: ${parentResult.filePath})` +\n `\\n Child has: ` +\n `\\n ${formatEnsureStaticExport(slotsResult.config)}` +\n `\\n (from: ${slotsResult.filePath})` +\n `\\n` +\n `\\n Possible fixes:` +\n `\\n - Remove one of the \\`ensureStatic\\` exports` +\n `\\n - Change one of the \\`ensureStatic\\` exports to match the other`\n )\n }\n }\n }\n}\n\nfunction formatParallelSlot(slot: string) {\n return slot === 'children' ? slot : `@${slot}`\n}\n\nfunction formatEnsureStaticExport(config: EnsureStatic) {\n return `export const ensureStatic = ${JSON.stringify(config)}`\n}\n\nenum Comparison {\n LessConstrained = 1,\n Compatible = 2,\n MoreConstrained = 3,\n Incompatible = 4,\n}\n\nconst ENSURE_STATIC_ORDER: Exclude<EnsureStatic, 'auto' | false>[] = [\n 'shell',\n 'prefetch',\n 'navigation',\n]\n\nfunction compareEnsureStatic(\n left: EnsureStatic,\n right: EnsureStatic\n): Comparison {\n // 'auto' is compatible with everything.\n if (left === 'auto' || right === 'auto') {\n return Comparison.Compatible\n }\n\n // `false` is compatible with false.\n if (left === false && right === false) {\n return Comparison.Compatible\n }\n // If only one of the values is `false` (we know it's not both), it's incompatible.\n if (left === false || right === false) {\n return Comparison.Incompatible\n }\n\n const leftSort = ENSURE_STATIC_ORDER.indexOf(left)\n const rightSort = ENSURE_STATIC_ORDER.indexOf(right)\n return leftSort < rightSort\n ? Comparison.LessConstrained\n : leftSort === rightSort\n ? Comparison.Compatible\n : Comparison.MoreConstrained\n}\n\nfunction getEnsureStaticConfigForModule(\n mod: Record<string, any> | undefined\n): EnsureStatic {\n return (mod ? (mod as AppSegmentConfig).ensureStatic : undefined) ?? 'auto'\n}\n","import { InvariantError } from '../../shared/lib/invariant-error'\nimport { createPromiseWithResolvers } from '../../shared/lib/promise-with-resolvers'\n\nexport enum RenderStage {\n Before = 1,\n //\n ShellStatic = 10,\n /** Discrimination-only stage: `prefetch()` in validation renders (static) */\n PrefetchStatic_prefetchApi = 11,\n PrefetchStatic = 12,\n NavigationStatic = 13,\n Static = 14,\n //\n ShellRuntime = 20,\n /** Discrimination-only stage: `prefetch()` in validation renders (runtime) */\n PrefetchRuntime_prefetchApi = 21,\n PrefetchRuntime = 22,\n NavigationRuntime = 23,\n //\n Dynamic = 30,\n Abandoned = 40,\n}\n\nexport type AdvanceableRenderStage = Exclude<\n RenderStage,\n RenderStage.Before | RenderStage.Abandoned\n>\n\nexport const RENDER_STAGE_ADVANCE_ORDER: AdvanceableRenderStage[] = [\n RenderStage.ShellStatic,\n RenderStage.PrefetchStatic_prefetchApi,\n RenderStage.PrefetchStatic,\n RenderStage.NavigationStatic,\n RenderStage.Static,\n //\n RenderStage.ShellRuntime,\n RenderStage.PrefetchRuntime_prefetchApi,\n RenderStage.PrefetchRuntime,\n RenderStage.NavigationRuntime,\n //\n RenderStage.Dynamic,\n]\n\nexport function getNextStage(\n stage: Exclude<AdvanceableRenderStage, RenderStage.Dynamic>\n) {\n return RENDER_STAGE_ADVANCE_ORDER[\n RENDER_STAGE_ADVANCE_ORDER.indexOf(stage) + 1\n ]\n}\n\nexport function isAdvanceableRenderStage(\n stage: RenderStage\n): stage is AdvanceableRenderStage {\n return RenderStage.Before < stage && stage <= RenderStage.Dynamic\n}\n\nexport enum SyncIOMode {\n /** Sync IO does not error in any stage. */\n Untracked = 1,\n /** Before `partialPrefetching`: Sync IO errors in static stages, and is allowed otherwise. */\n AllowedInRuntimeOrDynamic = 2,\n /** After `partialPrefetching`: Sync IO errors in all stages other than dynamic. */\n AllowedInDynamic = 3,\n}\n\nexport class StagedRenderingController {\n private abortSignal: AbortSignal | null\n private abandonController: AbortController | null\n private syncIOMode: SyncIOMode\n public readonly finalStage: AdvanceableRenderStage | null\n\n currentStage: RenderStage = RenderStage.Before\n\n syncInterruptReason: Error | null = null\n\n triggers: Record<AdvanceableRenderStage, StageTrigger> =\n createAdvanceableStageTriggers()\n\n constructor({\n abortSignal,\n abandonController,\n syncIO,\n finalStage,\n }: {\n abortSignal: AbortSignal | null\n abandonController: AbortController | null\n syncIO: SyncIOMode\n finalStage: AdvanceableRenderStage | null\n }) {\n this.abortSignal = abortSignal\n this.abandonController = abandonController\n this.syncIOMode = syncIO\n this.finalStage = finalStage\n\n if (abortSignal) {\n abortSignal.addEventListener(\n 'abort',\n () => {\n // Reject all stage promises that haven't already been resolved.\n // `cancelStageTrigger` is a noop if the trigger already resolved.\n const { reason } = abortSignal\n for (const trigger of Object.values(this.triggers)) {\n cancelStageTrigger(trigger, reason)\n }\n },\n { once: true }\n )\n }\n\n if (abandonController) {\n abandonController.signal.addEventListener(\n 'abort',\n () => {\n this.abandonRender()\n },\n { once: true }\n )\n }\n }\n\n /**\n * Schedules a callback that will execute synchronously when the controller is advanced\n * to `stage` or past it, before any promises for that stage are resolved.\n * If the controller is already past `stage`, the callback is executed immediately.\n * */\n onStage(stage: AdvanceableRenderStage, callback: () => void) {\n addSyncTriggerListener(this.triggers[stage], callback)\n }\n\n shouldTrackSyncInterrupt(): boolean {\n const { syncIOMode, currentStage } = this\n switch (syncIOMode) {\n case SyncIOMode.Untracked: {\n return false\n }\n case SyncIOMode.AllowedInRuntimeOrDynamic: {\n // Legacy: track Sync IO only in static stages.\n // Do not track it before the render, or in runtime/dynamic stages.\n return (\n currentStage > RenderStage.Before &&\n currentStage <= RenderStage.Static\n )\n }\n case SyncIOMode.AllowedInDynamic: {\n // Track sync IO in all cacheable stages.\n // This means all stages except:\n // - before the render\n // - in the dynamic stage\n return (\n currentStage > RenderStage.Before &&\n currentStage < RenderStage.Dynamic\n )\n }\n }\n }\n\n /** Note: only call this if `shouldTrackSyncInterrupt()` returned true */\n syncInterruptCurrentStageWithReason(reason: Error) {\n const { currentStage } = this\n if (\n currentStage === RenderStage.Before ||\n currentStage === RenderStage.Dynamic ||\n currentStage === RenderStage.Abandoned\n ) {\n // Not interruptible. Defensive noop.\n return\n }\n\n // If Sync IO occurs during an abandonable render, we trigger the abandon.\n // The abandon listener will call abandonRender which advances through\n // stages to let caches fill before marking as Abandoned.\n if (this.abandonController) {\n this.abandonController.abort()\n return\n }\n\n if (this.abortSignal) {\n // If this is an abortable render, we capture the interruption reason and stop advancing.\n // We don't release any more promises.\n // The caller is expected to abort the signal.\n this.syncInterruptReason = reason\n this.currentStage = RenderStage.Abandoned\n return\n }\n\n // If we're in a non-abandonable & non-abortable render,\n // we need to advance to the Dynamic stage and capture the interruption reason.\n // (in dev, this will be the restarted render)\n this.syncInterruptReason = reason\n this.advanceStage(RenderStage.Dynamic)\n }\n\n getSyncInterruptReason() {\n return this.syncInterruptReason\n }\n\n getStageEndTime(stage: Exclude<AdvanceableRenderStage, RenderStage.Dynamic>) {\n return this.triggers[getNextStage(stage)].triggeredAt ?? Infinity\n }\n\n private abandonRender() {\n // In staged rendering, only the initial render is abandonable.\n // We can abandon the initial render if\n // 1. We notice a cache miss, and need to wait for caches to fill\n // 2. A sync IO error occurs, and the render should be interrupted\n // (this might be a lazy intitialization of a module,\n // so we still want to restart in this case and see if it still occurs)\n // In either case, we'll be doing another render after this one,\n // so we only want to unblock the next stage, not Dynamic, because\n // unblocking the dynamic stage would likely lead to wasted (uncached) IO.\n\n const { currentStage } = this\n\n if (currentStage === RenderStage.Before) {\n throw new InvariantError(\n \"A render that hasn't started yet cannot be abandoned\"\n )\n }\n if (\n currentStage === RenderStage.Dynamic ||\n currentStage === RenderStage.Abandoned\n ) {\n // We shouldn't ever trigger an abandon in these. Defensive noop.\n return\n }\n\n // Resolve all stages after the current one, up to runtime (excluding dynamic)\n const nextStageIx = RENDER_STAGE_ADVANCE_ORDER.indexOf(currentStage) + 1\n const dynamicStageIx = RENDER_STAGE_ADVANCE_ORDER.indexOf(\n RenderStage.Dynamic\n )\n for (let i = nextStageIx; i < dynamicStageIx; i++) {\n this.resolveStage(RENDER_STAGE_ADVANCE_ORDER[i])\n }\n\n this.currentStage = RenderStage.Abandoned\n }\n\n advanceStage(targetStage: AdvanceableRenderStage) {\n if (this.finalStage !== null && targetStage > this.finalStage) {\n throw new InvariantError(\n `Attempted to advance to stage ${RenderStage[targetStage]} but the render is limited to ${RenderStage[this.finalStage]}`\n )\n }\n const { currentStage } = this\n\n if (\n currentStage === RenderStage.Dynamic ||\n currentStage === RenderStage.Abandoned\n ) {\n // Terminal stages, nowhere left to advance.\n return\n }\n\n // If we're already at the target stage or beyond, do nothing.\n if (targetStage <= currentStage) {\n return\n }\n\n this.currentStage = targetStage\n\n // Resolve all stages between the current stage and the target.\n const nextStageIx =\n currentStage === RenderStage.Before\n ? 0\n : RENDER_STAGE_ADVANCE_ORDER.indexOf(currentStage) + 1\n const targetStageIx = RENDER_STAGE_ADVANCE_ORDER.indexOf(targetStage)\n for (let i = nextStageIx; i <= targetStageIx; i++) {\n this.resolveStage(RENDER_STAGE_ADVANCE_ORDER[i])\n }\n }\n\n private resolveStage(stage: AdvanceableRenderStage) {\n fireStageTrigger(this.triggers[stage])\n }\n\n private getStagePromise(stage: AdvanceableRenderStage): Promise<void> {\n return this.triggers[stage].promise\n }\n\n waitForStage(stage: AdvanceableRenderStage) {\n return this.getStagePromise(stage)\n }\n\n delayUntilStage<T>(\n stage: AdvanceableRenderStage,\n displayName: string | undefined,\n resolvedValue: T\n ): Promise<T> {\n const stagePromise = this.getStagePromise(stage)\n\n const promise =\n process.env.NODE_ENV === 'development'\n ? makeDevtoolsIOPromiseFromIOTrigger(\n stagePromise,\n displayName,\n resolvedValue\n )\n : stagePromise.then(() => resolvedValue)\n\n // Analogously to `makeDynamicHangingPromise`, we might reject this promise if the signal is invoked.\n // (e.g. in the case where we don't want want the render to proceed to the dynamic stage and abort it).\n // We shouldn't consider this an unhandled rejection, so we attach a noop catch handler here to suppress this warning.\n if (this.abortSignal) {\n promise.catch(ignoreReject)\n }\n return promise\n }\n}\n\nfunction createAdvanceableStageTriggers(): Record<\n AdvanceableRenderStage,\n StageTrigger\n> {\n const triggers: Partial<Record<AdvanceableRenderStage, StageTrigger>> = {}\n for (const stage of RENDER_STAGE_ADVANCE_ORDER) {\n triggers[stage] = createStageTrigger()\n }\n return triggers as Record<AdvanceableRenderStage, StageTrigger>\n}\n\nfunction ignoreReject() {}\n\n// TODO(restart-on-cache-miss): the layering of `delayUntilStage`,\n// `makeDevtoolsIOPromiseFromIOTrigger` and and `makeDevtoolsIOAwarePromise`\n// is confusing, we should clean it up.\nfunction makeDevtoolsIOPromiseFromIOTrigger<T>(\n ioTrigger: Promise<any>,\n displayName: string | undefined,\n resolvedValue: T\n): Promise<T> {\n // If we create a `new Promise` and give it a displayName\n // (with no userspace code above us in the stack)\n // React Devtools will use it as the IO cause when determining \"suspended by\".\n // In particular, it should shadow any inner IO that resolved/rejected the promise\n // (in case of staged rendering, this will be the `setTimeout` that triggers the relevant stage)\n const promise = new Promise<T>((resolve, reject) => {\n ioTrigger.then(resolve.bind(null, resolvedValue), reject)\n })\n if (displayName !== undefined) {\n // @ts-expect-error\n promise.displayName = displayName\n }\n return promise\n}\n\ntype StageTrigger = {\n state: 'pending' | 'triggered' | 'cancelled'\n triggeredAt: number | null\n promise: Promise<void>\n _listeners: Array<() => void>\n _resolvePromise: () => void\n _rejectPromise: (reason: unknown) => void\n}\n\nfunction addSyncTriggerListener(trigger: StageTrigger, listener: () => void) {\n if (trigger.state === 'pending') {\n trigger._listeners.push(listener)\n } else {\n listener()\n }\n}\n\nfunction createStageTrigger(): StageTrigger {\n const { promise, resolve, reject } = createPromiseWithResolvers<void>()\n return {\n state: 'pending',\n triggeredAt: null,\n promise,\n _listeners: [],\n _resolvePromise: resolve,\n _rejectPromise: reject,\n }\n}\n\nfunction fireStageTrigger(trigger: StageTrigger) {\n if (trigger.state !== 'pending') {\n return\n }\n trigger.state = 'triggered'\n trigger.triggeredAt = performance.now() + performance.timeOrigin\n try {\n const { _listeners: listeners } = trigger\n for (let i = 0; i < listeners.length; i++) {\n listeners[i]()\n }\n listeners.length = 0\n } finally {\n trigger._resolvePromise()\n }\n}\n\nfunction cancelStageTrigger(trigger: StageTrigger, reason: unknown) {\n if (trigger.state !== 'pending') {\n return\n }\n trigger.state = 'cancelled'\n // we didn't trigger, so don't save `triggeredAt`.\n\n // We're not gonna fire the listeners, we may as well free them.\n trigger._listeners.length = 0\n\n // Suppress unhandled rejection warnings for promises that no one is awaiting.\n trigger.promise.catch(ignoreReject)\n trigger._rejectPromise(reason)\n}\n","import { InvariantError } from '../shared/lib/invariant-error'\nimport { createPromiseWithResolvers } from '../shared/lib/promise-with-resolvers'\nimport { EnsureStaticLevel } from './app-render/segment-config/ensure-static'\nimport {\n RenderStage,\n type StagedRenderingController,\n type AdvanceableRenderStage,\n} from './app-render/staged-rendering'\nimport { workAsyncStorage } from './app-render/work-async-storage.external'\nimport type {\n RequestStore,\n WorkUnitStore,\n} from './app-render/work-unit-async-storage.external'\nimport { workUnitAsyncStorage } from './app-render/work-unit-async-storage.external'\nimport { getServerReact, getClientReact } from './runtime-reacts.external'\n\nexport function isHangingPromiseRejectionError(\n err: unknown\n): err is HangingPromiseRejectionError {\n if (typeof err !== 'object' || err === null || !('digest' in err)) {\n return false\n }\n\n return err.digest === HANGING_PROMISE_REJECTION\n}\n\nconst HANGING_PROMISE_REJECTION = 'HANGING_PROMISE_REJECTION'\n\nclass HangingPromiseRejectionError extends Error {\n public readonly digest = HANGING_PROMISE_REJECTION\n\n constructor(\n public readonly route: string,\n public readonly expression: string\n ) {\n super(\n `During prerendering, ${expression} rejects when the prerender is complete. Typically these errors are handled by React but if you move ${expression} to a different context by using \\`setTimeout\\`, \\`after\\`, or similar functions you may observe this error and you should handle it in that context. This occurred at route \"${route}\".`\n )\n }\n}\n\nconst CLIENT_HOOK_DYNAMIC = 'CLIENT_HOOK_DYNAMIC'\n\nexport class ClientHookDynamicError extends Error {\n public readonly digest = CLIENT_HOOK_DYNAMIC\n\n constructor(route: string, expression: string) {\n super(\n `Route \"${route}\": Next.js encountered URL data \\`${expression}\\` in a Client Component outside of \\`<Suspense>\\`.\\n\\n` +\n `This blocks prerendering because the value is only available at runtime.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [stream] Wrap the component in \\`<Suspense fallback={...}>\\` so the hook value streams in after prerendering\\n` +\n ` - [block] Set \\`export const instant = false\\` to allow a blocking route\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/blocking-prerender-client-hook`\n )\n }\n}\n\nexport function isClientHookDynamicError(\n err: unknown\n): err is ClientHookDynamicError {\n if (typeof err !== 'object' || err === null || !('digest' in err)) {\n return false\n }\n\n return err.digest === CLIENT_HOOK_DYNAMIC\n}\n\ntype AbortListeners = Array<() => void>\nconst abortListenersBySignal = new WeakMap<AbortSignal, AbortListeners>()\n\n/**\n * Constructs a promise that never resolves, standing in for *dynamic* data:\n * data that is only available during a real dynamic request and hangs in\n * every kind of prerender — `io()`, `connection()`, uncached `fetch()`.\n *\n * This is primarily useful for cacheComponents where we use promise\n * resolution timing to determine which parts of a render can be included in a\n * prerender.\n *\n * Records nothing on the prerender store: the promise's holes are only ever\n * filled by a real dynamic request, so a runtime prefetch response would have\n * the same holes as the static one. If the data source would resolve during a\n * runtime prerender, use `makeRuntimeHangingPromise` instead.\n */\nexport function makeDynamicHangingPromise<T>(\n signal: AbortSignal,\n route: string,\n expression: string\n): Promise<T> {\n return makeHangingPromiseWithError(\n signal,\n new HangingPromiseRejectionError(route, expression)\n )\n}\n\nexport function makeUntrackedHangingPromise<T>(\n signal: AbortSignal,\n route: string,\n expression: string\n): Promise<T> {\n return makeHangingPromiseWithError(\n signal,\n new HangingPromiseRejectionError(route, expression)\n )\n}\n\n/**\n * Constructs a promise that never resolves, standing in for session data\n * (which a runtime shell can access).\n * Examples: cookies, headers\n *\n * Awaiting one of these during a static prerender records on the prerender\n * store that a runtime shell would produce more content than the static\n * static shell, which the segment prefetch encoding uses\n * to tell the client whether a runtime request could be skipped.\n *\n * When unsure whether data is dynamic or runtime, prefer this method — the\n * cost of over-recording is a redundant runtime prefetch request; the cost of\n * under-recording is a permanently missing one.\n *\n * For fallback-param data — data a concrete (ISR-upgraded) prerender would\n * resolve — use `makeFallbackParamsHangingPromise` instead, so the access\n * is recorded with the right effect on the static-prefetch hint.\n */\nexport function makeSessionDataHangingPromise<T>(\n signal: AbortSignal,\n route: string,\n expression: string,\n workUnitStore: WorkUnitStore\n): Promise<T> {\n const promise = makeHangingPromiseWithError<T>(\n signal,\n new HangingPromiseRejectionError(route, expression)\n )\n return trackPromiseUsed(\n promise,\n trackSessionDataAccessed.bind(null, workUnitStore, expression)\n )\n}\n\n/**\n * Constructs a promise that never resolves, standing in for URL data,\n * which can be accessed in a runtime prefetch (but not a runtime shell).\n * Examples: fallback params, searchParams\n *\n * Awaiting one of these during a static prerender records on the prerender\n * store that a runtime prefetch would produce more content than the static\n * response, which the segment prefetch encoding uses\n * to tell the client whether a runtime prefetch request could be skipped.\n *\n * When unsure whether data is dynamic or runtime, prefer this method — the\n * cost of over-recording is a redundant runtime prefetch request; the cost of\n * under-recording is a permanently missing one.\n *\n * `workUnitStore` may be null ONLY when the caller tracks the access itself.\n * Such a caller MUST call `trackURLDataAccessed` from every path that\n * observes the promise (e.g. the proxy traps for `then`/`status`),\n * against the work unit store active at access time.\n *\n * For fallback-param data — data a concrete (ISR-upgraded) prerender would\n * resolve — use `makeFallbackParamsHangingPromise` instead, so the access\n * is recorded with the right effect on the static-prefetch hint.\n */\nexport function makeURLDataHangingPromise<T>(\n signal: AbortSignal,\n route: string,\n expression: string,\n workUnitStore: WorkUnitStore | null\n): Promise<T> {\n const promise = makeHangingPromiseWithError<T>(\n signal,\n new HangingPromiseRejectionError(route, expression)\n )\n if (workUnitStore === null) {\n return promise\n }\n return trackPromiseUsed(\n promise,\n trackURLDataAccessed.bind(null, workUnitStore, expression)\n )\n}\n\n/**\n * Creates a promise that stands in for a result that will either be session data\n * or URL data, but we don't know which.\n */\nexport function makeUnknownRuntimeDataHangingPromise<T>(\n signal: AbortSignal,\n route: string,\n expression: string,\n workUnitStore: WorkUnitStore\n): Promise<T> {\n // We don't know if this is session or URL data, i.e. if it should affect the shell\n // or only the prefetch. Track it conservatively as affecting both.\n return makeSessionDataHangingPromise(signal, route, expression, workUnitStore)\n}\n\n/**\n * Constructs a promise that never resolves, standing in for data that is only\n * accessible in the prefetch, but not in the shell, e.g. `prefetch()`.\n * This usage does *not* indicate that a runtime request is needed,\n * only that the data is not available in a shell.\n *\n * @internal\n */\nexport function makePrefetchHangingPromise<T>(\n signal: AbortSignal,\n route: string,\n expression: string\n): Promise<T> {\n return makeUntrackedHangingPromise(signal, route, expression)\n}\n\n/**\n * Variant of `makeRuntimeHangingPromise` for *fallback-param* data: fallback\n * route params and values derived solely from them (`params`, `rootParams`,\n * `pathname` during a fallback prerender). Like every runtime data access,\n * awaiting it records the access on the prerender store's response-level flag,\n * but its effect on the build-time static-prefetch hint differs — on a\n * fallback-upgradeable route the access is transient (a concrete prerender\n * resolves it), so it leaves the hint intact. See `trackFallbackParamsAccessed`.\n *\n * As with `makeRuntimeHangingPromise`, `workUnitStore` may be null ONLY when\n * the caller tracks the access itself by calling `trackFallbackParamsAccessed`\n * from every path that observes the promise.\n */\nexport function makeFallbackParamsHangingPromise<T>(\n signal: AbortSignal,\n route: string,\n expression: string,\n workUnitStore: WorkUnitStore | null\n): Promise<T> {\n const promise = makeHangingPromiseWithError<T>(\n signal,\n new HangingPromiseRejectionError(route, expression)\n )\n if (workUnitStore === null) {\n return promise\n }\n return trackPromiseUsed(\n promise,\n trackFallbackParamsAccessed.bind(null, workUnitStore, expression)\n )\n}\n\nexport type PrerenderDataTracking = {\n /**\n * Records when the render has accessed a request data source\n * that hangs during a static prerender but would resolve during a runtime\n * prerender — cookies, headers, fallback params, searchParams, and cache\n * entries excluded only from static prerenders.\n *\n * The client uses this promise as the actual source of truth for whether a segment\n * needs a runtime request. Prefetch hints can become stale after a revalidation,\n * so if a hint says a static request should be enough but `runtimeDataAccessed`\n * resolves to `true`, a follow-up runtime request will be issued.\n * This applies to both shells and prefetches.\n *\n * The promise is embedded in the RSC payload (`InitialRSCPayload['u']`),\n * and is meant to be rewindable. This means that the shell might not have\n * any runtime data accesses, even when the prefetch does.\n * (this has some subtleties; see `markRuntimeDataAccessWhenStageReached`\n * for more)\n *\n * After the prerender, the promise is consumed by `collectSegmentData` and each\n * static prefetch will contain it (`PrefetchFlightResponse['u']`).\n * However, all the segments for a route will use the same promise (because we're\n * only tracking this on the page level) so if one segment needs runtime data, then\n * all segments will be marked as such.\n * However, on the client `isPartial` takes precedence over `runtimeDataAccessed`,\n * so complete segments will not end up being deopted.\n */\n readonly runtimeDataAccessed: PromiseWithResolvers<boolean>\n\n /** Corresponds to `PrefetchHint.ShouldAttemptStaticShell`. */\n shouldAttemptStaticShell: boolean\n /** Corresponds to `PrefetchHint.ShouldAttemptStaticPrefetch`. */\n shouldAttemptStaticPrefetch: boolean\n}\n\nexport function createPrerenderDataTracking(): PrerenderDataTracking {\n return {\n runtimeDataAccessed: createPromiseWithResolvers(),\n shouldAttemptStaticShell: true,\n shouldAttemptStaticPrefetch: true,\n }\n}\n\nexport function finishPrerenderDataTracking(\n prerenderDataTracking: PrerenderDataTracking\n) {\n // If a runtime data access already resolved this promise, this is a no-op.\n prerenderDataTracking.runtimeDataAccessed.resolve(false)\n}\n\n/**\n * Records on a static prerender store that the render accessed a data source\n * which would have resolved in a runtime shell (or runtime prefetch).\n * No-op for all other store types.\n *\n * Prefer `makeRuntimeHangingPromise`. Use this function only when implementing\n * similar tracking and that one is not enough.\n */\nfunction trackSessionDataAccessed(\n workUnitStore: WorkUnitStore,\n expression: string\n): void {\n trackRuntimeDataAccessed(\n workUnitStore,\n PrerenderDataKind.SessionData,\n expression\n )\n}\n\n/**\n * Records on a static prerender store that the render accessed a data source\n * which would have resolved in a runtime prefetch (but NOT in a runtime shell)\n * No-op for all other store types.\n *\n * Prefer `makeRuntimeHangingPromise`. Use this function only when implementing\n * similar tracking and that one is not enough.\n *\n * For fallback-param data, use `trackFallbackParamsAccessed` instead. When\n * unsure, this is the conservative choice.\n */\nexport function trackURLDataAccessed(\n workUnitStore: WorkUnitStore,\n expression: string\n): void {\n trackRuntimeDataAccessed(workUnitStore, PrerenderDataKind.UrlData, expression)\n}\n\n/**\n * Fallback-param variant of `trackRuntimeDataAccessed`, for accesses of\n * fallback route params and values derived solely from them. It records the\n * response-level flag all the same, but only clears the build-time\n * static-prefetch hint when the route is not fallback-upgradeable — on an\n * upgradeable route the access is transient, since ISR later produces a\n * concrete prerender that resolves it.\n */\nexport function trackFallbackParamsAccessed(\n workUnitStore: WorkUnitStore,\n expression: string\n): void {\n trackRuntimeDataAccessed(\n workUnitStore,\n PrerenderDataKind.FallbackParams,\n expression\n )\n}\n\nconst enum PrerenderDataKind {\n SessionData = 1,\n UrlData = 2,\n FallbackParams = 3,\n}\n\nfunction trackRuntimeDataAccessed(\n workUnitStore: WorkUnitStore,\n dataKind: PrerenderDataKind,\n expression: string\n): void {\n switch (workUnitStore.type) {\n case 'prerender': {\n const { prerenderDataTracking, stagedRendering } = workUnitStore\n if (!prerenderDataTracking || !stagedRendering) {\n return\n }\n const { currentStage } = stagedRendering\n if (currentStage === RenderStage.Before) {\n console.error(\n new InvariantError(\n 'Unexpected trackRuntimeDataAccessed in the Before stage.'\n )\n )\n return\n }\n if (currentStage >= RenderStage.NavigationStatic) {\n // Ignore any accesses that happen after `navigation()` resolves.\n // The purpose of this tracking is to judge whether a runtime prefetch\n // would give us a more complete result than a static one.\n // But `navigation()` wouldn't have resolved in a runtime prefetch,\n // so e.g. `await navigation(); await cookies()` wouldn't have more content\n // in those, and we shouldn't count it.\n return\n }\n\n const ensureStaticLevel =\n workUnitStore.ensureStaticLevel ?? EnsureStaticLevel.None\n\n // NOTE: In general, we keep hints in sync with `needsRuntimeRequest`, but they\n // don't have to always match. The client re-uses hints for the entire route,\n // while `needsRuntimeRequest` can vary across individual prerendered param values\n // (e.g. if cookies are accessed depending on a param value).\n // Hints can also become outdated if a route only starts using runtime data\n // after a revalidation, so we have to expect this and be resilient to it.\n // Also see the upgradeable fallback params case below, which deliberately\n // puts them out of sync.\n\n switch (dataKind) {\n case PrerenderDataKind.SessionData: {\n // Potentially deopt both the shell and the prefetch,\n // because if the shell accessed runtime data, so does the prefetch.\n // However, if we're already past the shell stage, the shell is not affected.\n // (which makes e.g. `await prefetch(); await cookies()` only affect the prefetch)\n let firstAffectedStage:\n | RenderStage.ShellStatic\n | RenderStage.PrefetchStatic\n | null = null\n\n if (\n currentStage <= RenderStage.ShellStatic &&\n // Only track if we're not forcing the shell to be static.\n ensureStaticLevel < EnsureStaticLevel.Shell\n ) {\n prerenderDataTracking.shouldAttemptStaticShell = false\n firstAffectedStage ??= RenderStage.ShellStatic\n logRuntimeDeopt?.(expression, 'shell')\n }\n\n if (\n currentStage <= RenderStage.PrefetchStatic &&\n // Only track if we're not forcing the prefetch to be static.\n ensureStaticLevel < EnsureStaticLevel.Prefetch\n ) {\n prerenderDataTracking.shouldAttemptStaticPrefetch = false\n // NOTE: if the shell is affected, don't override it.\n firstAffectedStage ??= RenderStage.PrefetchStatic\n logRuntimeDeopt?.(expression, 'prefetch')\n }\n\n if (firstAffectedStage !== null) {\n markRuntimeDataAccessWhenStageReached(\n prerenderDataTracking,\n stagedRendering,\n firstAffectedStage\n )\n }\n break\n }\n case PrerenderDataKind.FallbackParams: {\n if (workUnitStore.isFallbackUpgradeable) {\n // An fallback-param access is transient when the route is\n // fallback-upgradeable (i.e. ISR later produces the concrete prerender a\n // static prefetch would hit) so it does not indicate the need for a runtime\n // request and thus does not affect the static hints.\n //\n // If runtime prefetches are not disallowed by `ensureStatic`, then we still\n // set `runtimeDataAccessed` (while keeping the hints static). This means that\n // if the concrete prerender isn't ready yet and we served the fallback, then\n // the client knows it can use a *runtime* prefetch for speculative links --\n // a runtime prefetch can provide the same content (or more) as the concrete\n // prerender would.\n if (ensureStaticLevel < EnsureStaticLevel.Prefetch) {\n markRuntimeDataAccessWhenStageReached(\n prerenderDataTracking,\n stagedRendering,\n // `params` are URL data, so they only affect the prefetch\n RenderStage.PrefetchStatic\n )\n logRuntimeUpgradeableFallback?.()\n }\n break\n }\n // not an upgradeable fallback param access, so we treat it as URL data.\n // intentional fallthrough\n }\n case PrerenderDataKind.UrlData: {\n // Only deopt the prefetch, not the shell, which cannot access URL data anyway.\n if (\n currentStage <= RenderStage.PrefetchStatic &&\n ensureStaticLevel < EnsureStaticLevel.Prefetch\n ) {\n prerenderDataTracking.shouldAttemptStaticPrefetch = false\n logRuntimeDeopt?.(expression, 'prefetch')\n\n markRuntimeDataAccessWhenStageReached(\n prerenderDataTracking,\n stagedRendering,\n RenderStage.PrefetchStatic\n )\n }\n break\n }\n }\n\n break\n }\n case 'prerender-client':\n case 'prerender-legacy':\n case 'prerender-runtime':\n case 'validation-client':\n case 'request':\n case 'cache':\n case 'private-cache':\n case 'unstable-cache':\n case 'build-time-generator':\n // Only the modern server prerender tracks this; see the field docs on\n // PrerenderStoreModernServer.\n break\n default:\n workUnitStore satisfies never\n }\n}\n\n/**\n * Tracks a runtime data access on the `runtimeDataAccessed` promise,\n * but with a delay until `targetStage`.\n *\n * When we encounter a URL data access like `await params`, we need to mark the\n * *prefetch* as needing runtime data, but the *shell* should remain unaffected\n * (because it cannot access params anyway).\n *\n * However, the shell and the prefetch share one `runtimeDataAccessed` promise,\n * and it needs to be accurately rewindable by the client\n * In other words, we need to make sure that it reads as `false` when rewound\n * to a shell, but as `true` in the final response (the prefetch).\n *\n * This means that if the `await params` is encountered during the shell stage, we\n * cannot resolve `runtimeDataAccessed` immediately.\n * Instead, we delay the resolution until the PrefetchStatic stage, so the promise\n * will remain unresolved when rewound to the shell stage (which reads as `false`).\n */\nfunction markRuntimeDataAccessWhenStageReached(\n prerenderDataTracking: PrerenderDataTracking,\n stageController: StagedRenderingController,\n targetStage: AdvanceableRenderStage\n) {\n const { runtimeDataAccessed } = prerenderDataTracking\n // NOTE: If we're already in or past the target stage, we can avoid allocating a closure,\n // because `onStage` would've executed the callback immediately anyway.\n if (stageController.currentStage >= targetStage) {\n runtimeDataAccessed.resolve(true)\n } else {\n stageController.onStage(\n targetStage,\n runtimeDataAccessed.resolve.bind(null, true)\n )\n }\n}\n\nconst logRuntimeDeopt = process.env.NEXT_PRIVATE_DEBUG_RUNTIME_DATA\n ? (expression: string, kind: 'shell' | 'prefetch') => {\n const { route } = workAsyncStorage.getStore()!\n console.log(\n `Route '${route}': deopting to a runtime ${kind} because it used ${expression}`\n )\n }\n : undefined\n\nconst logRuntimeUpgradeableFallback = process.env\n .NEXT_PRIVATE_DEBUG_RUNTIME_DATA\n ? () => {\n const { route } = workAsyncStorage.getStore()!\n console.log(\n `Route '${route}': marking upgradeable fallback as runtime prefetchable`\n )\n }\n : undefined\n\n/**\n * Signals that we cannot recover both a runtime shell and a static (PPR) shell\n * from the same render. Use this whenever the stage of a promise varies on\n * `RequestStore.needsRuntimeShell`.\n * */\nexport function trackIncompatibleShellContent(\n workUnitStore: RequestStore,\n reason: string\n) {\n const { stagedRendering } = workUnitStore\n if (!stagedRendering) {\n return\n }\n\n // TODO(app-shells): optimize this to only consider stages that are relevant for validation.\n // We should only track incompatible content when it can affect them.\n // For now, we simply exclude everything that happens in the dynamic stage.\n // (Note that we also need to account for cache misses that move things to a\n // different stage -- those should also preemptively set `hasIncompatibleShellContent`\n // because there's a chance that a render with warm caches would set it)\n const { currentStage } = stagedRendering\n if (\n currentStage === RenderStage.Dynamic ||\n currentStage === RenderStage.Abandoned\n ) {\n return\n }\n if (process.env.NEXT_PRIVATE_DEBUG_VALIDATION) {\n const workStore = workAsyncStorage.getStore()!\n console.log(\n `Route ${workStore.route}: Incompatible shell content: ${reason}`\n )\n }\n workUnitStore.hasIncompatibleShellContent = true\n}\n\nexport function makeClientHookHangingPromise<T>(\n signal: AbortSignal,\n error: ClientHookDynamicError\n): Promise<T> {\n return makeHangingPromiseWithError(signal, error)\n}\n\nfunction makeHangingPromiseWithError<T>(\n signal: AbortSignal,\n error: Error\n): Promise<T> {\n if (signal.aborted) {\n return Promise.reject(error)\n } else {\n const hangingPromise = new Promise<T>((_, reject) => {\n const boundRejection = reject.bind(null, error)\n let currentListeners = abortListenersBySignal.get(signal)\n if (currentListeners) {\n currentListeners.push(boundRejection)\n } else {\n const listeners = [boundRejection]\n abortListenersBySignal.set(signal, listeners)\n signal.addEventListener(\n 'abort',\n () => {\n for (let i = 0; i < listeners.length; i++) {\n listeners[i]()\n }\n },\n { once: true }\n )\n }\n })\n // We are fine if no one actually awaits this promise. We shouldn't consider this an unhandled rejection so\n // we attach a noop catch handler here to suppress this warning. If you actually await somewhere or construct\n // your own promise out of it you'll need to ensure you handle the error when it rejects.\n hangingPromise.catch(ignoreReject)\n return hangingPromise\n }\n}\n\nfunction ignoreReject() {}\n\n/**\n * Creates a promise that will be triggered when another promise resolves.\n * It will not emit unhandled rejections, which is important if the trigger\n * is a promise that might itself get rejected (e.g. when a prerender/render\n * are aborted due to sync IO)\n */\nexport function makePromiseFromTrigger<T>(\n trigger: Promise<any>,\n value: T\n): Promise<T> {\n const promise = trigger.then(() => value)\n promise.catch(ignoreReject)\n return promise\n}\n\nexport function makeDevtoolsIOAwarePromise<T>(\n underlying: T,\n requestStore: RequestStore,\n stage: AdvanceableRenderStage\n): Promise<T> {\n if (requestStore.stagedRendering) {\n // We resolve each stage in a timeout, so React DevTools will pick this up as IO.\n return requestStore.stagedRendering.delayUntilStage(\n stage,\n undefined,\n underlying\n )\n }\n // in React DevTools if we resolve in a setTimeout we will observe\n // the promise resolution as something that can suspend a boundary or root.\n return new Promise<T>((resolve) => {\n // Must use setTimeout to be considered IO React DevTools. setImmediate will not work.\n setTimeout(() => {\n resolve(underlying)\n }, 0)\n })\n}\n\n/**\n * Invokes `onUse` whenever `then()/catch()/finally()` are called on the promise\n * or when the promise is awaited. */\nexport function trackPromiseUsed<T>(\n promise: Promise<T>,\n onUse: () => void\n): Promise<T> {\n // We can instrument `.then()/.catch()/.finally()` in one go by using a Promise subclass\n // that implements a custom `.then()`, because `catch` and `finally` delegate to it.\n //\n // Alternative implementation ideas that were tried and rejected:\n //\n // 1. Patching the methods directly via `promise.then = (..args) => { ... }`:\n // doesn't work, because Node does not call the monkeypatched methods for native `await`:\n // > Native Promise [...]: The promise is directly used and awaited natively, without calling `then()`.\n // > https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/await#description\n //\n // 2. Wrapping in a proxy that returns a custom `then/catch/finally`:\n // breaks async stacks in React's IO tracking (stack becomes `Promise.then`)\n return TrackedPromise.from<T>(promise, onUse)\n}\n\nclass TrackedPromise<T> extends Promise<T> {\n #onUse: (() => void) | null = null\n\n // We don't need derived promises to also be a TrackedPromise.\n // We only care about the first level of `.then()`.\n static get [Symbol.species]() {\n return Promise\n }\n\n static from<T>(promise: Promise<T>, onUse: () => void): TrackedPromise<T> {\n // Whenever the promise we're tracking resolves/rejects, we should follow.\n const tracked = new TrackedPromise<T>(promise.then.bind(promise))\n\n tracked.#onUse = onUse\n\n // Hanging promises catch rejections when created. Tracked promises are generally derived\n // from promises that may hang & reject, so we need to do the same.\n // However, we have to bypass the tracking we do in `TrackedPromise.then`.\n // (we're using `then` directly, because `catch` ends up delegating `TrackedPromise.then`)\n Promise.prototype.then.call(tracked, undefined, ignoreReject)\n\n return tracked\n }\n\n then<TResult1, TResult2>(\n onFulfilled?: (value: T) => TResult1 | PromiseLike<TResult1>,\n onRejected?: (reason: unknown) => TResult2 | PromiseLike<TResult2>\n ): Promise<TResult1 | TResult2> {\n const onUse = this.#onUse\n if (onUse) {\n try {\n onUse()\n } catch (err) {\n // We don't want to break the method even if our tracking errored.\n console.error(err)\n }\n }\n\n return Promise.prototype.then.call(\n this,\n onFulfilled,\n onRejected\n ) as Promise<TResult1 | TResult2>\n }\n}\n\nexport const RENDER_STAGES_BY_DATA_KIND = {\n sessionData: RenderStage.ShellRuntime as const,\n /**\n * Statically-prerenderable URL data, like static `params`.\n * It may need to be pushed to a runtime stage in a runtime prerender,\n * but it's semantically distinct from `runtimeUrlData` like `searchParams`,\n * which is always excluded from static prerenders.\n * */\n staticUrlData: {\n /**\n * From that app's point of view, `prefetch()` is semantically the same as\n * `staticUrlData`, because it does not resolve in a shell but resolves in\n * a prefetch (even a static one).\n * We handle it separately to provide a specialized error in validation renders.\n */\n prefetchApi: {\n static: RenderStage.PrefetchStatic_prefetchApi as const,\n runtime: RenderStage.PrefetchRuntime_prefetchApi as const,\n },\n static: RenderStage.PrefetchStatic as const,\n runtime: RenderStage.PrefetchRuntime as const,\n },\n /**\n * URL data that is never statically-prerenderable, like static `searchParams`.\n * */\n runtimeUrlData: RenderStage.PrefetchRuntime as const,\n}\n\nexport function applyOwnerStack(error: Error): Error {\n if (process.env.NODE_ENV !== 'production') {\n let ownerStack: string | undefined | null\n const workUnitStore = workUnitAsyncStorage.getStore()\n\n // captureOwnerStack() returns the owner stack for the current React\n // rendering context. Inside a cache scope this only includes the inner\n // component tree. The outer owner stack (captured before entering the\n // cache boundary in use-cache-wrapper.ts) is stored on the cache store.\n // We concatenate both to get the full component tree.\n const innerOwnerStack =\n getClientReact()?.captureOwnerStack?.() ??\n getServerReact()?.captureOwnerStack?.()\n\n switch (workUnitStore?.type) {\n case 'cache':\n case 'private-cache':\n ownerStack =\n (innerOwnerStack || '') + (workUnitStore.outerOwnerStack || '') ||\n undefined\n break\n case 'unstable-cache':\n case 'request':\n case 'prerender':\n case 'prerender-legacy':\n case 'prerender-runtime':\n case 'prerender-client':\n case 'validation-client':\n case 'build-time-generator':\n case undefined:\n ownerStack = innerOwnerStack\n break\n default:\n workUnitStore satisfies never\n }\n\n if (ownerStack) {\n let stack = ownerStack\n\n if (error.stack) {\n const frames: string[] = []\n\n for (const frame of error.stack.split('\\n').slice(1)) {\n if (frame.includes('react_stack_bottom_frame')) {\n break\n }\n\n frames.push(frame)\n }\n\n stack = '\\n' + frames.join('\\n') + stack\n }\n\n error.stack = error.name + ': ' + error.message + stack\n }\n }\n\n return error\n}\n","import type { AppDirModules } from '../../build/webpack/loaders/next-app-loader'\nimport { DEFAULT_SEGMENT_KEY } from '../../shared/lib/segment'\n\n/**\n * LoaderTree is generated in next-app-loader.\n */\nexport type LoaderTree = [\n segment: string,\n parallelRoutes: { [parallelRouterKey: string]: LoaderTree },\n modules: AppDirModules,\n /**\n * At build time, for each dynamic segment, we compute the list of static\n * sibling segments that exist at the same URL path level. This is used by\n * the client router to determine if a prefetch can be reused.\n *\n * For example, given the following file structure:\n * /app/(group1)/products/sale/page.tsx -> /products/sale\n * /app/(group2)/products/[id]/page.tsx -> /products/[id]\n *\n * The [id] segment would have staticSiblings: ['sale']\n *\n * This accounts for route groups, which may place sibling routes in\n * different parts of the file system tree but at the same URL level.\n *\n * A value of `null` means the static siblings are unknown (e.g., in webpack\n * dev mode where routes are compiled on-demand).\n */\n staticSiblings: readonly string[] | null,\n]\n\nexport async function getLayoutOrPageModule(loaderTree: LoaderTree) {\n const { layout, page, defaultPage } = loaderTree[2]\n const isLayout = typeof layout !== 'undefined'\n const isPage = typeof page !== 'undefined'\n const isDefaultPage =\n typeof defaultPage !== 'undefined' && loaderTree[0] === DEFAULT_SEGMENT_KEY\n\n let mod = undefined\n let modType: 'layout' | 'page' | undefined = undefined\n let filePath = undefined\n\n if (isLayout) {\n mod = await layout[0]()\n modType = 'layout'\n filePath = layout[1]\n } else if (isPage) {\n mod = await page[0]()\n modType = 'page'\n filePath = page[1]\n } else if (isDefaultPage) {\n mod = await defaultPage[0]()\n modType = 'page'\n filePath = defaultPage[1]\n }\n\n return { mod, modType, filePath }\n}\n\nexport async function getComponentTypeModule(\n loaderTree: LoaderTree,\n moduleType: 'layout' | 'not-found' | 'forbidden' | 'unauthorized'\n) {\n const { [moduleType]: module } = loaderTree[2]\n if (typeof module !== 'undefined') {\n return await module[0]()\n }\n return undefined\n}\n","export function createUnrenderedSegmentError(\n route: string,\n missingFiles: readonly string[]\n): Error {\n let message = `Route \"${route}\": Could not validate that a segment in your UI has instant navigation.`\n if (missingFiles.length > 0) {\n const label =\n missingFiles.length === 1 ? 'Dropped segment' : 'Dropped segments'\n message +=\n `\\n\\nThis segment was dropped from rendering. Issues that would prevent instant navigation will go undetected.` +\n `\\n\\n${label}:\\n${missingFiles.map((p) => ` ${p}`).join('\\n')}` +\n `\\n\\nWays to fix this:` +\n `\\n - [render] Render the dropped segment` +\n `\\n - [ignore] Set \\`export const instant = false\\` to opt the dropped segment out of instant-navigation validation` +\n `\\n\\nLearn more: https://nextjs.org/docs/messages/instant-unrendered-segment`\n }\n return new Error(message)\n}\n\nexport function createLinkPrefetchPartialError(pathname: string): Error {\n return new Error(\n `Next.js encountered dynamic data during prefetching for \"${pathname}\".\\n\\n` +\n `This will lead to slower, more expensive prefetches.\\n\\n` +\n `Ways to fix this:\\n` +\n ` - [upgrade] Opt into Partial Prefetching by exporting \\`const prefetch = 'partial'\\` from the page or layout, or by setting \\`partialPrefetching: true\\` in next.config to opt the whole app in\\n` +\n ` - [disable] Remove \\`prefetch={true}\\` from the <Link> to use the default prefetch\\n` +\n ` - [ignore] Set \\`export const instant = false\\` to opt the route out of instant-navigation validation\\n\\n` +\n `Learn more: https://nextjs.org/docs/messages/instant-link-prefetch-partial`\n )\n}\n","export class InvariantError extends Error {\n constructor(message: string, options?: ErrorOptions) {\n super(\n `Invariant: ${message.endsWith('.') ? message : message + '.'} This is a bug in Next.js.`,\n options\n )\n this.name = 'InvariantError'\n }\n}\n","// This has to be a shared module which is shared between client component error boundary and dynamic component\nconst BAILOUT_TO_CSR = 'BAILOUT_TO_CLIENT_SIDE_RENDERING'\n\n/** An error that should be thrown when we want to bail out to client-side rendering. */\nexport class BailoutToCSRError extends Error {\n public readonly digest = BAILOUT_TO_CSR\n\n constructor(public readonly reason: string) {\n super(`Bail out to client-side rendering: ${reason}`)\n }\n}\n\n/** Checks if a passed argument is an error that is thrown if we want to bail out to client-side rendering. */\nexport function isBailoutToCSRError(err: unknown): err is BailoutToCSRError {\n if (typeof err !== 'object' || err === null || !('digest' in err)) {\n return false\n }\n\n return err.digest === BAILOUT_TO_CSR\n}\n","// This module is bundled separately into user code and the precompiled App\n// Router runtime. Use the global symbol registry so both copies recognize the\n// same browser bailout reason.\nconst REACT_BROWSER_BAILOUT_REASON = Symbol.for('next.browser-bailout-reason')\n\ntype ReactBrowserBailoutReason = {\n $$typeof: symbol\n reason: string\n}\n\nexport function createReactBrowserBailoutReason(\n reason: string\n): ReactBrowserBailoutReason {\n return {\n $$typeof: REACT_BROWSER_BAILOUT_REASON,\n reason,\n }\n}\n\nexport function getReactBrowserBailoutReason(\n error: unknown\n): string | undefined {\n const cause = (error as Error)?.cause as ReactBrowserBailoutReason | undefined\n\n return cause?.$$typeof === REACT_BROWSER_BAILOUT_REASON\n ? cause.reason\n : undefined\n}\n\nexport function isNextBrowserBailoutError(error: unknown): boolean {\n return getReactBrowserBailoutReason(error) !== undefined\n}\n","export function createPromiseWithResolvers<T>(): PromiseWithResolvers<T> {\n // Shim of Stage 4 Promise.withResolvers proposal\n let resolve: (value: T | PromiseLike<T>) => void\n let reject: (reason: any) => void\n const promise = new Promise<T>((res, rej) => {\n resolve = res\n reject = rej\n })\n return { resolve: resolve!, reject: reject!, promise }\n}\n","import { DEFAULT_SEGMENT_KEY } from '../../segment'\nimport type { LoaderTree } from '../../../../server/lib/app-dir-module'\n\nexport function parseLoaderTree(tree: LoaderTree) {\n const [segment, parallelRoutes, modules, staticSiblings] = tree\n const { layout, template } = modules\n let { page } = modules\n // a __DEFAULT__ segment means that this route didn't match any of the\n // segments in the route, so we should use the default page\n page = segment === DEFAULT_SEGMENT_KEY ? modules.defaultPage : page\n\n const conventionPath = layout?.[1] || template?.[1] || page?.[1]\n\n return {\n page,\n segment,\n modules,\n /* it can be either layout / template / page */\n conventionPath,\n parallelRoutes,\n staticSiblings,\n }\n}\n","import type { FlightRouterState, Segment } from './app-router-types'\n\nexport function getSegmentValue(segment: Segment) {\n return Array.isArray(segment) ? segment[1] : segment\n}\n\nexport function isGroupSegment(segment: string) {\n // Use array[0] for performant purpose\n return segment[0] === '(' && segment.endsWith(')')\n}\n\nexport function isParallelRouteSegment(segment: string) {\n return segment.startsWith('@') && segment !== '@children'\n}\n\nexport function computeSelectedLayoutSegment(\n segments: string[] | null,\n parallelRouteKey: string\n): string | null {\n if (!segments || segments.length === 0) {\n return null\n }\n\n // For 'children', use first segment; for other parallel routes, use last segment\n const rawSegment =\n parallelRouteKey === 'children'\n ? segments[0]\n : segments[segments.length - 1]\n\n // If the default slot is showing, return null since it's not technically \"selected\" (it's a fallback)\n // Returning an internal value like `__DEFAULT__` would be confusing\n return rawSegment === DEFAULT_SEGMENT_KEY ? null : rawSegment\n}\n\n/** Get the canonical parameters from the current level to the leaf node. */\nexport function getSelectedLayoutSegmentPath(\n tree: FlightRouterState,\n parallelRouteKey: string,\n first = true,\n segmentPath: string[] = []\n): string[] {\n let node: FlightRouterState\n if (first) {\n // Use the provided parallel route key on the first parallel route\n node = tree[1][parallelRouteKey]\n } else {\n // After first parallel route prefer children, if there's no children pick the first parallel route.\n const parallelRoutes = tree[1]\n node = parallelRoutes.children ?? Object.values(parallelRoutes)[0]\n }\n\n if (!node) return segmentPath\n const segment = node[0]\n\n let segmentValue = getSegmentValue(segment)\n\n if (!segmentValue || segmentValue === PAGE_SEGMENT_KEY) {\n return segmentPath\n }\n\n segmentPath.push(segmentValue)\n\n return getSelectedLayoutSegmentPath(\n node,\n parallelRouteKey,\n false,\n segmentPath\n )\n}\n\nexport const PAGE_SEGMENT_KEY = '__PAGE__'\nexport const DEFAULT_SEGMENT_KEY = '__DEFAULT__'\nexport const NOT_FOUND_SEGMENT_KEY = '/_not-found'\n","'use client';\nfunction __insertCSS(code) {\n if (!code || typeof document == 'undefined') return\n let head = document.head || document.getElementsByTagName('head')[0]\n let style = document.createElement('style')\n style.type = 'text/css'\n head.appendChild(style)\n ;style.styleSheet ? (style.styleSheet.cssText = code) : style.appendChild(document.createTextNode(code))\n}\n\nimport React from 'react';\nimport ReactDOM from 'react-dom';\n\nconst getAsset = (type)=>{\n switch(type){\n case 'success':\n return SuccessIcon;\n case 'info':\n return InfoIcon;\n case 'warning':\n return WarningIcon;\n case 'error':\n return ErrorIcon;\n default:\n return null;\n }\n};\nconst bars = Array(12).fill(0);\nconst Loader = ({ visible, className })=>{\n return /*#__PURE__*/ React.createElement(\"div\", {\n className: [\n 'sonner-loading-wrapper',\n className\n ].filter(Boolean).join(' '),\n \"data-visible\": visible\n }, /*#__PURE__*/ React.createElement(\"div\", {\n className: \"sonner-spinner\"\n }, bars.map((_, i)=>/*#__PURE__*/ React.createElement(\"div\", {\n className: \"sonner-loading-bar\",\n key: `spinner-bar-${i}`\n }))));\n};\nconst SuccessIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 20 20\",\n fill: \"currentColor\",\n height: \"20\",\n width: \"20\"\n}, /*#__PURE__*/ React.createElement(\"path\", {\n fillRule: \"evenodd\",\n d: \"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z\",\n clipRule: \"evenodd\"\n}));\nconst WarningIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 24 24\",\n fill: \"currentColor\",\n height: \"20\",\n width: \"20\"\n}, /*#__PURE__*/ React.createElement(\"path\", {\n fillRule: \"evenodd\",\n d: \"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z\",\n clipRule: \"evenodd\"\n}));\nconst InfoIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 20 20\",\n fill: \"currentColor\",\n height: \"20\",\n width: \"20\"\n}, /*#__PURE__*/ React.createElement(\"path\", {\n fillRule: \"evenodd\",\n d: \"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z\",\n clipRule: \"evenodd\"\n}));\nconst ErrorIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n viewBox: \"0 0 20 20\",\n fill: \"currentColor\",\n height: \"20\",\n width: \"20\"\n}, /*#__PURE__*/ React.createElement(\"path\", {\n fillRule: \"evenodd\",\n d: \"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z\",\n clipRule: \"evenodd\"\n}));\nconst CloseIcon = /*#__PURE__*/ React.createElement(\"svg\", {\n xmlns: \"http://www.w3.org/2000/svg\",\n width: \"12\",\n height: \"12\",\n viewBox: \"0 0 24 24\",\n fill: \"none\",\n stroke: \"currentColor\",\n strokeWidth: \"1.5\",\n strokeLinecap: \"round\",\n strokeLinejoin: \"round\"\n}, /*#__PURE__*/ React.createElement(\"line\", {\n x1: \"18\",\n y1: \"6\",\n x2: \"6\",\n y2: \"18\"\n}), /*#__PURE__*/ React.createElement(\"line\", {\n x1: \"6\",\n y1: \"6\",\n x2: \"18\",\n y2: \"18\"\n}));\n\nconst useIsDocumentHidden = ()=>{\n const [isDocumentHidden, setIsDocumentHidden] = React.useState(document.hidden);\n React.useEffect(()=>{\n const callback = ()=>{\n setIsDocumentHidden(document.hidden);\n };\n document.addEventListener('visibilitychange', callback);\n return ()=>window.removeEventListener('visibilitychange', callback);\n }, []);\n return isDocumentHidden;\n};\n\nlet toastsCounter = 1;\nclass Observer {\n constructor(){\n // We use arrow functions to maintain the correct `this` reference\n this.subscribe = (subscriber)=>{\n this.subscribers.push(subscriber);\n return ()=>{\n const index = this.subscribers.indexOf(subscriber);\n this.subscribers.splice(index, 1);\n };\n };\n this.publish = (data)=>{\n this.subscribers.forEach((subscriber)=>subscriber(data));\n };\n this.addToast = (data)=>{\n this.publish(data);\n this.toasts = [\n ...this.toasts,\n data\n ];\n };\n this.create = (data)=>{\n var _data_id;\n const { message, ...rest } = data;\n const id = typeof (data == null ? void 0 : data.id) === 'number' || ((_data_id = data.id) == null ? void 0 : _data_id.length) > 0 ? data.id : toastsCounter++;\n const alreadyExists = this.toasts.find((toast)=>{\n return toast.id === id;\n });\n const dismissible = data.dismissible === undefined ? true : data.dismissible;\n if (this.dismissedToasts.has(id)) {\n this.dismissedToasts.delete(id);\n }\n if (alreadyExists) {\n this.toasts = this.toasts.map((toast)=>{\n if (toast.id === id) {\n this.publish({\n ...toast,\n ...data,\n id,\n title: message\n });\n return {\n ...toast,\n ...data,\n id,\n dismissible,\n title: message\n };\n }\n return toast;\n });\n } else {\n this.addToast({\n title: message,\n ...rest,\n dismissible,\n id\n });\n }\n return id;\n };\n this.dismiss = (id)=>{\n if (id) {\n this.dismissedToasts.add(id);\n requestAnimationFrame(()=>this.subscribers.forEach((subscriber)=>subscriber({\n id,\n dismiss: true\n })));\n } else {\n this.toasts.forEach((toast)=>{\n this.subscribers.forEach((subscriber)=>subscriber({\n id: toast.id,\n dismiss: true\n }));\n });\n }\n return id;\n };\n this.message = (message, data)=>{\n return this.create({\n ...data,\n message\n });\n };\n this.error = (message, data)=>{\n return this.create({\n ...data,\n message,\n type: 'error'\n });\n };\n this.success = (message, data)=>{\n return this.create({\n ...data,\n type: 'success',\n message\n });\n };\n this.info = (message, data)=>{\n return this.create({\n ...data,\n type: 'info',\n message\n });\n };\n this.warning = (message, data)=>{\n return this.create({\n ...data,\n type: 'warning',\n message\n });\n };\n this.loading = (message, data)=>{\n return this.create({\n ...data,\n type: 'loading',\n message\n });\n };\n this.promise = (promise, data)=>{\n if (!data) {\n // Nothing to show\n return;\n }\n let id = undefined;\n if (data.loading !== undefined) {\n id = this.create({\n ...data,\n promise,\n type: 'loading',\n message: data.loading,\n description: typeof data.description !== 'function' ? data.description : undefined\n });\n }\n const p = Promise.resolve(promise instanceof Function ? promise() : promise);\n let shouldDismiss = id !== undefined;\n let result;\n const originalPromise = p.then(async (response)=>{\n result = [\n 'resolve',\n response\n ];\n const isReactElementResponse = React.isValidElement(response);\n if (isReactElementResponse) {\n shouldDismiss = false;\n this.create({\n id,\n type: 'default',\n message: response\n });\n } else if (isHttpResponse(response) && !response.ok) {\n shouldDismiss = false;\n const promiseData = typeof data.error === 'function' ? await data.error(`HTTP error! status: ${response.status}`) : data.error;\n const description = typeof data.description === 'function' ? await data.description(`HTTP error! status: ${response.status}`) : data.description;\n const isExtendedResult = typeof promiseData === 'object' && !React.isValidElement(promiseData);\n const toastSettings = isExtendedResult ? promiseData : {\n message: promiseData\n };\n this.create({\n id,\n type: 'error',\n description,\n ...toastSettings\n });\n } else if (response instanceof Error) {\n shouldDismiss = false;\n const promiseData = typeof data.error === 'function' ? await data.error(response) : data.error;\n const description = typeof data.description === 'function' ? await data.description(response) : data.description;\n const isExtendedResult = typeof promiseData === 'object' && !React.isValidElement(promiseData);\n const toastSettings = isExtendedResult ? promiseData : {\n message: promiseData\n };\n this.create({\n id,\n type: 'error',\n description,\n ...toastSettings\n });\n } else if (data.success !== undefined) {\n shouldDismiss = false;\n const promiseData = typeof data.success === 'function' ? await data.success(response) : data.success;\n const description = typeof data.description === 'function' ? await data.description(response) : data.description;\n const isExtendedResult = typeof promiseData === 'object' && !React.isValidElement(promiseData);\n const toastSettings = isExtendedResult ? promiseData : {\n message: promiseData\n };\n this.create({\n id,\n type: 'success',\n description,\n ...toastSettings\n });\n }\n }).catch(async (error)=>{\n result = [\n 'reject',\n error\n ];\n if (data.error !== undefined) {\n shouldDismiss = false;\n const promiseData = typeof data.error === 'function' ? await data.error(error) : data.error;\n const description = typeof data.description === 'function' ? await data.description(error) : data.description;\n const isExtendedResult = typeof promiseData === 'object' && !React.isValidElement(promiseData);\n const toastSettings = isExtendedResult ? promiseData : {\n message: promiseData\n };\n this.create({\n id,\n type: 'error',\n description,\n ...toastSettings\n });\n }\n }).finally(()=>{\n if (shouldDismiss) {\n // Toast is still in load state (and will be indefinitely — dismiss it)\n this.dismiss(id);\n id = undefined;\n }\n data.finally == null ? void 0 : data.finally.call(data);\n });\n const unwrap = ()=>new Promise((resolve, reject)=>originalPromise.then(()=>result[0] === 'reject' ? reject(result[1]) : resolve(result[1])).catch(reject));\n if (typeof id !== 'string' && typeof id !== 'number') {\n // cannot Object.assign on undefined\n return {\n unwrap\n };\n } else {\n return Object.assign(id, {\n unwrap\n });\n }\n };\n this.custom = (jsx, data)=>{\n const id = (data == null ? void 0 : data.id) || toastsCounter++;\n this.create({\n jsx: jsx(id),\n id,\n ...data\n });\n return id;\n };\n this.getActiveToasts = ()=>{\n return this.toasts.filter((toast)=>!this.dismissedToasts.has(toast.id));\n };\n this.subscribers = [];\n this.toasts = [];\n this.dismissedToasts = new Set();\n }\n}\nconst ToastState = new Observer();\n// bind this to the toast function\nconst toastFunction = (message, data)=>{\n const id = (data == null ? void 0 : data.id) || toastsCounter++;\n ToastState.addToast({\n title: message,\n ...data,\n id\n });\n return id;\n};\nconst isHttpResponse = (data)=>{\n return data && typeof data === 'object' && 'ok' in data && typeof data.ok === 'boolean' && 'status' in data && typeof data.status === 'number';\n};\nconst basicToast = toastFunction;\nconst getHistory = ()=>ToastState.toasts;\nconst getToasts = ()=>ToastState.getActiveToasts();\n// We use `Object.assign` to maintain the correct types as we would lose them otherwise\nconst toast = Object.assign(basicToast, {\n success: ToastState.success,\n info: ToastState.info,\n warning: ToastState.warning,\n error: ToastState.error,\n custom: ToastState.custom,\n message: ToastState.message,\n promise: ToastState.promise,\n dismiss: ToastState.dismiss,\n loading: ToastState.loading\n}, {\n getHistory,\n getToasts\n});\n\n__insertCSS(\"[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}\");\n\nfunction isAction(action) {\n return action.label !== undefined;\n}\n\n// Visible toasts amount\nconst VISIBLE_TOASTS_AMOUNT = 3;\n// Viewport padding\nconst VIEWPORT_OFFSET = '24px';\n// Mobile viewport padding\nconst MOBILE_VIEWPORT_OFFSET = '16px';\n// Default lifetime of a toasts (in ms)\nconst TOAST_LIFETIME = 4000;\n// Default toast width\nconst TOAST_WIDTH = 356;\n// Default gap between toasts\nconst GAP = 14;\n// Threshold to dismiss a toast\nconst SWIPE_THRESHOLD = 45;\n// Equal to exit animation duration\nconst TIME_BEFORE_UNMOUNT = 200;\nfunction cn(...classes) {\n return classes.filter(Boolean).join(' ');\n}\nfunction getDefaultSwipeDirections(position) {\n const [y, x] = position.split('-');\n const directions = [];\n if (y) {\n directions.push(y);\n }\n if (x) {\n directions.push(x);\n }\n return directions;\n}\nconst Toast = (props)=>{\n var _toast_classNames, _toast_classNames1, _toast_classNames2, _toast_classNames3, _toast_classNames4, _toast_classNames5, _toast_classNames6, _toast_classNames7, _toast_classNames8;\n const { invert: ToasterInvert, toast, unstyled, interacting, setHeights, visibleToasts, heights, index, toasts, expanded, removeToast, defaultRichColors, closeButton: closeButtonFromToaster, style, cancelButtonStyle, actionButtonStyle, className = '', descriptionClassName = '', duration: durationFromToaster, position, gap, expandByDefault, classNames, icons, closeButtonAriaLabel = 'Close toast' } = props;\n const [swipeDirection, setSwipeDirection] = React.useState(null);\n const [swipeOutDirection, setSwipeOutDirection] = React.useState(null);\n const [mounted, setMounted] = React.useState(false);\n const [removed, setRemoved] = React.useState(false);\n const [swiping, setSwiping] = React.useState(false);\n const [swipeOut, setSwipeOut] = React.useState(false);\n const [isSwiped, setIsSwiped] = React.useState(false);\n const [offsetBeforeRemove, setOffsetBeforeRemove] = React.useState(0);\n const [initialHeight, setInitialHeight] = React.useState(0);\n const remainingTime = React.useRef(toast.duration || durationFromToaster || TOAST_LIFETIME);\n const dragStartTime = React.useRef(null);\n const toastRef = React.useRef(null);\n const isFront = index === 0;\n const isVisible = index + 1 <= visibleToasts;\n const toastType = toast.type;\n const dismissible = toast.dismissible !== false;\n const toastClassname = toast.className || '';\n const toastDescriptionClassname = toast.descriptionClassName || '';\n // Height index is used to calculate the offset as it gets updated before the toast array, which means we can calculate the new layout faster.\n const heightIndex = React.useMemo(()=>heights.findIndex((height)=>height.toastId === toast.id) || 0, [\n heights,\n toast.id\n ]);\n const closeButton = React.useMemo(()=>{\n var _toast_closeButton;\n return (_toast_closeButton = toast.closeButton) != null ? _toast_closeButton : closeButtonFromToaster;\n }, [\n toast.closeButton,\n closeButtonFromToaster\n ]);\n const duration = React.useMemo(()=>toast.duration || durationFromToaster || TOAST_LIFETIME, [\n toast.duration,\n durationFromToaster\n ]);\n const closeTimerStartTimeRef = React.useRef(0);\n const offset = React.useRef(0);\n const lastCloseTimerStartTimeRef = React.useRef(0);\n const pointerStartRef = React.useRef(null);\n const [y, x] = position.split('-');\n const toastsHeightBefore = React.useMemo(()=>{\n return heights.reduce((prev, curr, reducerIndex)=>{\n // Calculate offset up until current toast\n if (reducerIndex >= heightIndex) {\n return prev;\n }\n return prev + curr.height;\n }, 0);\n }, [\n heights,\n heightIndex\n ]);\n const isDocumentHidden = useIsDocumentHidden();\n const invert = toast.invert || ToasterInvert;\n const disabled = toastType === 'loading';\n offset.current = React.useMemo(()=>heightIndex * gap + toastsHeightBefore, [\n heightIndex,\n toastsHeightBefore\n ]);\n React.useEffect(()=>{\n remainingTime.current = duration;\n }, [\n duration\n ]);\n React.useEffect(()=>{\n // Trigger enter animation without using CSS animation\n setMounted(true);\n }, []);\n React.useEffect(()=>{\n const toastNode = toastRef.current;\n if (toastNode) {\n const height = toastNode.getBoundingClientRect().height;\n // Add toast height to heights array after the toast is mounted\n setInitialHeight(height);\n setHeights((h)=>[\n {\n toastId: toast.id,\n height,\n position: toast.position\n },\n ...h\n ]);\n return ()=>setHeights((h)=>h.filter((height)=>height.toastId !== toast.id));\n }\n }, [\n setHeights,\n toast.id\n ]);\n React.useLayoutEffect(()=>{\n // Keep height up to date with the content in case it updates\n if (!mounted) return;\n const toastNode = toastRef.current;\n const originalHeight = toastNode.style.height;\n toastNode.style.height = 'auto';\n const newHeight = toastNode.getBoundingClientRect().height;\n toastNode.style.height = originalHeight;\n setInitialHeight(newHeight);\n setHeights((heights)=>{\n const alreadyExists = heights.find((height)=>height.toastId === toast.id);\n if (!alreadyExists) {\n return [\n {\n toastId: toast.id,\n height: newHeight,\n position: toast.position\n },\n ...heights\n ];\n } else {\n return heights.map((height)=>height.toastId === toast.id ? {\n ...height,\n height: newHeight\n } : height);\n }\n });\n }, [\n mounted,\n toast.title,\n toast.description,\n setHeights,\n toast.id,\n toast.jsx,\n toast.action,\n toast.cancel\n ]);\n const deleteToast = React.useCallback(()=>{\n // Save the offset for the exit swipe animation\n setRemoved(true);\n setOffsetBeforeRemove(offset.current);\n setHeights((h)=>h.filter((height)=>height.toastId !== toast.id));\n setTimeout(()=>{\n removeToast(toast);\n }, TIME_BEFORE_UNMOUNT);\n }, [\n toast,\n removeToast,\n setHeights,\n offset\n ]);\n React.useEffect(()=>{\n if (toast.promise && toastType === 'loading' || toast.duration === Infinity || toast.type === 'loading') return;\n let timeoutId;\n // Pause the timer on each hover\n const pauseTimer = ()=>{\n if (lastCloseTimerStartTimeRef.current < closeTimerStartTimeRef.current) {\n // Get the elapsed time since the timer started\n const elapsedTime = new Date().getTime() - closeTimerStartTimeRef.current;\n remainingTime.current = remainingTime.current - elapsedTime;\n }\n lastCloseTimerStartTimeRef.current = new Date().getTime();\n };\n const startTimer = ()=>{\n // setTimeout(, Infinity) behaves as if the delay is 0.\n // As a result, the toast would be closed immediately, giving the appearance that it was never rendered.\n // See: https://github.com/denysdovhan/wtfjs?tab=readme-ov-file#an-infinite-timeout\n if (remainingTime.current === Infinity) return;\n closeTimerStartTimeRef.current = new Date().getTime();\n // Let the toast know it has started\n timeoutId = setTimeout(()=>{\n toast.onAutoClose == null ? void 0 : toast.onAutoClose.call(toast, toast);\n deleteToast();\n }, remainingTime.current);\n };\n if (expanded || interacting || isDocumentHidden) {\n pauseTimer();\n } else {\n startTimer();\n }\n return ()=>clearTimeout(timeoutId);\n }, [\n expanded,\n interacting,\n toast,\n toastType,\n isDocumentHidden,\n deleteToast\n ]);\n React.useEffect(()=>{\n if (toast.delete) {\n deleteToast();\n toast.onDismiss == null ? void 0 : toast.onDismiss.call(toast, toast);\n }\n }, [\n deleteToast,\n toast.delete\n ]);\n function getLoadingIcon() {\n var _toast_classNames;\n if (icons == null ? void 0 : icons.loading) {\n var _toast_classNames1;\n return /*#__PURE__*/ React.createElement(\"div\", {\n className: cn(classNames == null ? void 0 : classNames.loader, toast == null ? void 0 : (_toast_classNames1 = toast.classNames) == null ? void 0 : _toast_classNames1.loader, 'sonner-loader'),\n \"data-visible\": toastType === 'loading'\n }, icons.loading);\n }\n return /*#__PURE__*/ React.createElement(Loader, {\n className: cn(classNames == null ? void 0 : classNames.loader, toast == null ? void 0 : (_toast_classNames = toast.classNames) == null ? void 0 : _toast_classNames.loader),\n visible: toastType === 'loading'\n });\n }\n const icon = toast.icon || (icons == null ? void 0 : icons[toastType]) || getAsset(toastType);\n var _toast_richColors, _icons_close;\n return /*#__PURE__*/ React.createElement(\"li\", {\n tabIndex: 0,\n ref: toastRef,\n className: cn(className, toastClassname, classNames == null ? void 0 : classNames.toast, toast == null ? void 0 : (_toast_classNames = toast.classNames) == null ? void 0 : _toast_classNames.toast, classNames == null ? void 0 : classNames.default, classNames == null ? void 0 : classNames[toastType], toast == null ? void 0 : (_toast_classNames1 = toast.classNames) == null ? void 0 : _toast_classNames1[toastType]),\n \"data-sonner-toast\": \"\",\n \"data-rich-colors\": (_toast_richColors = toast.richColors) != null ? _toast_richColors : defaultRichColors,\n \"data-styled\": !Boolean(toast.jsx || toast.unstyled || unstyled),\n \"data-mounted\": mounted,\n \"data-promise\": Boolean(toast.promise),\n \"data-swiped\": isSwiped,\n \"data-removed\": removed,\n \"data-visible\": isVisible,\n \"data-y-position\": y,\n \"data-x-position\": x,\n \"data-index\": index,\n \"data-front\": isFront,\n \"data-swiping\": swiping,\n \"data-dismissible\": dismissible,\n \"data-type\": toastType,\n \"data-invert\": invert,\n \"data-swipe-out\": swipeOut,\n \"data-swipe-direction\": swipeOutDirection,\n \"data-expanded\": Boolean(expanded || expandByDefault && mounted),\n \"data-testid\": toast.testId,\n style: {\n '--index': index,\n '--toasts-before': index,\n '--z-index': toasts.length - index,\n '--offset': `${removed ? offsetBeforeRemove : offset.current}px`,\n '--initial-height': expandByDefault ? 'auto' : `${initialHeight}px`,\n ...style,\n ...toast.style\n },\n onDragEnd: ()=>{\n setSwiping(false);\n setSwipeDirection(null);\n pointerStartRef.current = null;\n },\n onPointerDown: (event)=>{\n if (event.button === 2) return; // Return early on right click\n if (disabled || !dismissible) return;\n dragStartTime.current = new Date();\n setOffsetBeforeRemove(offset.current);\n // Ensure we maintain correct pointer capture even when going outside of the toast (e.g. when swiping)\n event.target.setPointerCapture(event.pointerId);\n if (event.target.tagName === 'BUTTON') return;\n setSwiping(true);\n pointerStartRef.current = {\n x: event.clientX,\n y: event.clientY\n };\n },\n onPointerUp: ()=>{\n var _toastRef_current, _toastRef_current1, _dragStartTime_current;\n if (swipeOut || !dismissible) return;\n pointerStartRef.current = null;\n const swipeAmountX = Number(((_toastRef_current = toastRef.current) == null ? void 0 : _toastRef_current.style.getPropertyValue('--swipe-amount-x').replace('px', '')) || 0);\n const swipeAmountY = Number(((_toastRef_current1 = toastRef.current) == null ? void 0 : _toastRef_current1.style.getPropertyValue('--swipe-amount-y').replace('px', '')) || 0);\n const timeTaken = new Date().getTime() - ((_dragStartTime_current = dragStartTime.current) == null ? void 0 : _dragStartTime_current.getTime());\n const swipeAmount = swipeDirection === 'x' ? swipeAmountX : swipeAmountY;\n const velocity = Math.abs(swipeAmount) / timeTaken;\n if (Math.abs(swipeAmount) >= SWIPE_THRESHOLD || velocity > 0.11) {\n setOffsetBeforeRemove(offset.current);\n toast.onDismiss == null ? void 0 : toast.onDismiss.call(toast, toast);\n if (swipeDirection === 'x') {\n setSwipeOutDirection(swipeAmountX > 0 ? 'right' : 'left');\n } else {\n setSwipeOutDirection(swipeAmountY > 0 ? 'down' : 'up');\n }\n deleteToast();\n setSwipeOut(true);\n return;\n } else {\n var _toastRef_current2, _toastRef_current3;\n (_toastRef_current2 = toastRef.current) == null ? void 0 : _toastRef_current2.style.setProperty('--swipe-amount-x', `0px`);\n (_toastRef_current3 = toastRef.current) == null ? void 0 : _toastRef_current3.style.setProperty('--swipe-amount-y', `0px`);\n }\n setIsSwiped(false);\n setSwiping(false);\n setSwipeDirection(null);\n },\n onPointerMove: (event)=>{\n var _window_getSelection, // Apply transform using both x and y values\n _toastRef_current, _toastRef_current1;\n if (!pointerStartRef.current || !dismissible) return;\n const isHighlighted = ((_window_getSelection = window.getSelection()) == null ? void 0 : _window_getSelection.toString().length) > 0;\n if (isHighlighted) return;\n const yDelta = event.clientY - pointerStartRef.current.y;\n const xDelta = event.clientX - pointerStartRef.current.x;\n var _props_swipeDirections;\n const swipeDirections = (_props_swipeDirections = props.swipeDirections) != null ? _props_swipeDirections : getDefaultSwipeDirections(position);\n // Determine swipe direction if not already locked\n if (!swipeDirection && (Math.abs(xDelta) > 1 || Math.abs(yDelta) > 1)) {\n setSwipeDirection(Math.abs(xDelta) > Math.abs(yDelta) ? 'x' : 'y');\n }\n let swipeAmount = {\n x: 0,\n y: 0\n };\n const getDampening = (delta)=>{\n const factor = Math.abs(delta) / 20;\n return 1 / (1.5 + factor);\n };\n // Only apply swipe in the locked direction\n if (swipeDirection === 'y') {\n // Handle vertical swipes\n if (swipeDirections.includes('top') || swipeDirections.includes('bottom')) {\n if (swipeDirections.includes('top') && yDelta < 0 || swipeDirections.includes('bottom') && yDelta > 0) {\n swipeAmount.y = yDelta;\n } else {\n // Smoothly transition to dampened movement\n const dampenedDelta = yDelta * getDampening(yDelta);\n // Ensure we don't jump when transitioning to dampened movement\n swipeAmount.y = Math.abs(dampenedDelta) < Math.abs(yDelta) ? dampenedDelta : yDelta;\n }\n }\n } else if (swipeDirection === 'x') {\n // Handle horizontal swipes\n if (swipeDirections.includes('left') || swipeDirections.includes('right')) {\n if (swipeDirections.includes('left') && xDelta < 0 || swipeDirections.includes('right') && xDelta > 0) {\n swipeAmount.x = xDelta;\n } else {\n // Smoothly transition to dampened movement\n const dampenedDelta = xDelta * getDampening(xDelta);\n // Ensure we don't jump when transitioning to dampened movement\n swipeAmount.x = Math.abs(dampenedDelta) < Math.abs(xDelta) ? dampenedDelta : xDelta;\n }\n }\n }\n if (Math.abs(swipeAmount.x) > 0 || Math.abs(swipeAmount.y) > 0) {\n setIsSwiped(true);\n }\n (_toastRef_current = toastRef.current) == null ? void 0 : _toastRef_current.style.setProperty('--swipe-amount-x', `${swipeAmount.x}px`);\n (_toastRef_current1 = toastRef.current) == null ? void 0 : _toastRef_current1.style.setProperty('--swipe-amount-y', `${swipeAmount.y}px`);\n }\n }, closeButton && !toast.jsx && toastType !== 'loading' ? /*#__PURE__*/ React.createElement(\"button\", {\n \"aria-label\": closeButtonAriaLabel,\n \"data-disabled\": disabled,\n \"data-close-button\": true,\n onClick: disabled || !dismissible ? ()=>{} : ()=>{\n deleteToast();\n toast.onDismiss == null ? void 0 : toast.onDismiss.call(toast, toast);\n },\n className: cn(classNames == null ? void 0 : classNames.closeButton, toast == null ? void 0 : (_toast_classNames2 = toast.classNames) == null ? void 0 : _toast_classNames2.closeButton)\n }, (_icons_close = icons == null ? void 0 : icons.close) != null ? _icons_close : CloseIcon) : null, (toastType || toast.icon || toast.promise) && toast.icon !== null && ((icons == null ? void 0 : icons[toastType]) !== null || toast.icon) ? /*#__PURE__*/ React.createElement(\"div\", {\n \"data-icon\": \"\",\n className: cn(classNames == null ? void 0 : classNames.icon, toast == null ? void 0 : (_toast_classNames3 = toast.classNames) == null ? void 0 : _toast_classNames3.icon)\n }, toast.promise || toast.type === 'loading' && !toast.icon ? toast.icon || getLoadingIcon() : null, toast.type !== 'loading' ? icon : null) : null, /*#__PURE__*/ React.createElement(\"div\", {\n \"data-content\": \"\",\n className: cn(classNames == null ? void 0 : classNames.content, toast == null ? void 0 : (_toast_classNames4 = toast.classNames) == null ? void 0 : _toast_classNames4.content)\n }, /*#__PURE__*/ React.createElement(\"div\", {\n \"data-title\": \"\",\n className: cn(classNames == null ? void 0 : classNames.title, toast == null ? void 0 : (_toast_classNames5 = toast.classNames) == null ? void 0 : _toast_classNames5.title)\n }, toast.jsx ? toast.jsx : typeof toast.title === 'function' ? toast.title() : toast.title), toast.description ? /*#__PURE__*/ React.createElement(\"div\", {\n \"data-description\": \"\",\n className: cn(descriptionClassName, toastDescriptionClassname, classNames == null ? void 0 : classNames.description, toast == null ? void 0 : (_toast_classNames6 = toast.classNames) == null ? void 0 : _toast_classNames6.description)\n }, typeof toast.description === 'function' ? toast.description() : toast.description) : null), /*#__PURE__*/ React.isValidElement(toast.cancel) ? toast.cancel : toast.cancel && isAction(toast.cancel) ? /*#__PURE__*/ React.createElement(\"button\", {\n \"data-button\": true,\n \"data-cancel\": true,\n style: toast.cancelButtonStyle || cancelButtonStyle,\n onClick: (event)=>{\n // We need to check twice because typescript\n if (!isAction(toast.cancel)) return;\n if (!dismissible) return;\n toast.cancel.onClick == null ? void 0 : toast.cancel.onClick.call(toast.cancel, event);\n deleteToast();\n },\n className: cn(classNames == null ? void 0 : classNames.cancelButton, toast == null ? void 0 : (_toast_classNames7 = toast.classNames) == null ? void 0 : _toast_classNames7.cancelButton)\n }, toast.cancel.label) : null, /*#__PURE__*/ React.isValidElement(toast.action) ? toast.action : toast.action && isAction(toast.action) ? /*#__PURE__*/ React.createElement(\"button\", {\n \"data-button\": true,\n \"data-action\": true,\n style: toast.actionButtonStyle || actionButtonStyle,\n onClick: (event)=>{\n // We need to check twice because typescript\n if (!isAction(toast.action)) return;\n toast.action.onClick == null ? void 0 : toast.action.onClick.call(toast.action, event);\n if (event.defaultPrevented) return;\n deleteToast();\n },\n className: cn(classNames == null ? void 0 : classNames.actionButton, toast == null ? void 0 : (_toast_classNames8 = toast.classNames) == null ? void 0 : _toast_classNames8.actionButton)\n }, toast.action.label) : null);\n};\nfunction getDocumentDirection() {\n if (typeof window === 'undefined') return 'ltr';\n if (typeof document === 'undefined') return 'ltr'; // For Fresh purpose\n const dirAttribute = document.documentElement.getAttribute('dir');\n if (dirAttribute === 'auto' || !dirAttribute) {\n return window.getComputedStyle(document.documentElement).direction;\n }\n return dirAttribute;\n}\nfunction assignOffset(defaultOffset, mobileOffset) {\n const styles = {};\n [\n defaultOffset,\n mobileOffset\n ].forEach((offset, index)=>{\n const isMobile = index === 1;\n const prefix = isMobile ? '--mobile-offset' : '--offset';\n const defaultValue = isMobile ? MOBILE_VIEWPORT_OFFSET : VIEWPORT_OFFSET;\n function assignAll(offset) {\n [\n 'top',\n 'right',\n 'bottom',\n 'left'\n ].forEach((key)=>{\n styles[`${prefix}-${key}`] = typeof offset === 'number' ? `${offset}px` : offset;\n });\n }\n if (typeof offset === 'number' || typeof offset === 'string') {\n assignAll(offset);\n } else if (typeof offset === 'object') {\n [\n 'top',\n 'right',\n 'bottom',\n 'left'\n ].forEach((key)=>{\n if (offset[key] === undefined) {\n styles[`${prefix}-${key}`] = defaultValue;\n } else {\n styles[`${prefix}-${key}`] = typeof offset[key] === 'number' ? `${offset[key]}px` : offset[key];\n }\n });\n } else {\n assignAll(defaultValue);\n }\n });\n return styles;\n}\nfunction useSonner() {\n const [activeToasts, setActiveToasts] = React.useState([]);\n React.useEffect(()=>{\n return ToastState.subscribe((toast)=>{\n if (toast.dismiss) {\n setTimeout(()=>{\n ReactDOM.flushSync(()=>{\n setActiveToasts((toasts)=>toasts.filter((t)=>t.id !== toast.id));\n });\n });\n return;\n }\n // Prevent batching, temp solution.\n setTimeout(()=>{\n ReactDOM.flushSync(()=>{\n setActiveToasts((toasts)=>{\n const indexOfExistingToast = toasts.findIndex((t)=>t.id === toast.id);\n // Update the toast if it already exists\n if (indexOfExistingToast !== -1) {\n return [\n ...toasts.slice(0, indexOfExistingToast),\n {\n ...toasts[indexOfExistingToast],\n ...toast\n },\n ...toasts.slice(indexOfExistingToast + 1)\n ];\n }\n return [\n toast,\n ...toasts\n ];\n });\n });\n });\n });\n }, []);\n return {\n toasts: activeToasts\n };\n}\nconst Toaster = /*#__PURE__*/ React.forwardRef(function Toaster(props, ref) {\n const { id, invert, position = 'bottom-right', hotkey = [\n 'altKey',\n 'KeyT'\n ], expand, closeButton, className, offset, mobileOffset, theme = 'light', richColors, duration, style, visibleToasts = VISIBLE_TOASTS_AMOUNT, toastOptions, dir = getDocumentDirection(), gap = GAP, icons, containerAriaLabel = 'Notifications' } = props;\n const [toasts, setToasts] = React.useState([]);\n const filteredToasts = React.useMemo(()=>{\n if (id) {\n return toasts.filter((toast)=>toast.toasterId === id);\n }\n return toasts.filter((toast)=>!toast.toasterId);\n }, [\n toasts,\n id\n ]);\n const possiblePositions = React.useMemo(()=>{\n return Array.from(new Set([\n position\n ].concat(filteredToasts.filter((toast)=>toast.position).map((toast)=>toast.position))));\n }, [\n filteredToasts,\n position\n ]);\n const [heights, setHeights] = React.useState([]);\n const [expanded, setExpanded] = React.useState(false);\n const [interacting, setInteracting] = React.useState(false);\n const [actualTheme, setActualTheme] = React.useState(theme !== 'system' ? theme : typeof window !== 'undefined' ? window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light' : 'light');\n const listRef = React.useRef(null);\n const hotkeyLabel = hotkey.join('+').replace(/Key/g, '').replace(/Digit/g, '');\n const lastFocusedElementRef = React.useRef(null);\n const isFocusWithinRef = React.useRef(false);\n const removeToast = React.useCallback((toastToRemove)=>{\n setToasts((toasts)=>{\n var _toasts_find;\n if (!((_toasts_find = toasts.find((toast)=>toast.id === toastToRemove.id)) == null ? void 0 : _toasts_find.delete)) {\n ToastState.dismiss(toastToRemove.id);\n }\n return toasts.filter(({ id })=>id !== toastToRemove.id);\n });\n }, []);\n React.useEffect(()=>{\n return ToastState.subscribe((toast)=>{\n if (toast.dismiss) {\n // Prevent batching of other state updates\n requestAnimationFrame(()=>{\n setToasts((toasts)=>toasts.map((t)=>t.id === toast.id ? {\n ...t,\n delete: true\n } : t));\n });\n return;\n }\n // Prevent batching, temp solution.\n setTimeout(()=>{\n ReactDOM.flushSync(()=>{\n setToasts((toasts)=>{\n const indexOfExistingToast = toasts.findIndex((t)=>t.id === toast.id);\n // Update the toast if it already exists\n if (indexOfExistingToast !== -1) {\n return [\n ...toasts.slice(0, indexOfExistingToast),\n {\n ...toasts[indexOfExistingToast],\n ...toast\n },\n ...toasts.slice(indexOfExistingToast + 1)\n ];\n }\n return [\n toast,\n ...toasts\n ];\n });\n });\n });\n });\n }, [\n toasts\n ]);\n React.useEffect(()=>{\n if (theme !== 'system') {\n setActualTheme(theme);\n return;\n }\n if (theme === 'system') {\n // check if current preference is dark\n if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) {\n // it's currently dark\n setActualTheme('dark');\n } else {\n // it's not dark\n setActualTheme('light');\n }\n }\n if (typeof window === 'undefined') return;\n const darkMediaQuery = window.matchMedia('(prefers-color-scheme: dark)');\n try {\n // Chrome & Firefox\n darkMediaQuery.addEventListener('change', ({ matches })=>{\n if (matches) {\n setActualTheme('dark');\n } else {\n setActualTheme('light');\n }\n });\n } catch (error) {\n // Safari < 14\n darkMediaQuery.addListener(({ matches })=>{\n try {\n if (matches) {\n setActualTheme('dark');\n } else {\n setActualTheme('light');\n }\n } catch (e) {\n console.error(e);\n }\n });\n }\n }, [\n theme\n ]);\n React.useEffect(()=>{\n // Ensure expanded is always false when no toasts are present / only one left\n if (toasts.length <= 1) {\n setExpanded(false);\n }\n }, [\n toasts\n ]);\n React.useEffect(()=>{\n const handleKeyDown = (event)=>{\n var _listRef_current;\n const isHotkeyPressed = hotkey.every((key)=>event[key] || event.code === key);\n if (isHotkeyPressed) {\n var _listRef_current1;\n setExpanded(true);\n (_listRef_current1 = listRef.current) == null ? void 0 : _listRef_current1.focus();\n }\n if (event.code === 'Escape' && (document.activeElement === listRef.current || ((_listRef_current = listRef.current) == null ? void 0 : _listRef_current.contains(document.activeElement)))) {\n setExpanded(false);\n }\n };\n document.addEventListener('keydown', handleKeyDown);\n return ()=>document.removeEventListener('keydown', handleKeyDown);\n }, [\n hotkey\n ]);\n React.useEffect(()=>{\n if (listRef.current) {\n return ()=>{\n if (lastFocusedElementRef.current) {\n lastFocusedElementRef.current.focus({\n preventScroll: true\n });\n lastFocusedElementRef.current = null;\n isFocusWithinRef.current = false;\n }\n };\n }\n }, [\n listRef.current\n ]);\n return(// Remove item from normal navigation flow, only available via hotkey\n /*#__PURE__*/ React.createElement(\"section\", {\n ref: ref,\n \"aria-label\": `${containerAriaLabel} ${hotkeyLabel}`,\n tabIndex: -1,\n \"aria-live\": \"polite\",\n \"aria-relevant\": \"additions text\",\n \"aria-atomic\": \"false\",\n suppressHydrationWarning: true\n }, possiblePositions.map((position, index)=>{\n var _heights_;\n const [y, x] = position.split('-');\n if (!filteredToasts.length) return null;\n return /*#__PURE__*/ React.createElement(\"ol\", {\n key: position,\n dir: dir === 'auto' ? getDocumentDirection() : dir,\n tabIndex: -1,\n ref: listRef,\n className: className,\n \"data-sonner-toaster\": true,\n \"data-sonner-theme\": actualTheme,\n \"data-y-position\": y,\n \"data-x-position\": x,\n style: {\n '--front-toast-height': `${((_heights_ = heights[0]) == null ? void 0 : _heights_.height) || 0}px`,\n '--width': `${TOAST_WIDTH}px`,\n '--gap': `${gap}px`,\n ...style,\n ...assignOffset(offset, mobileOffset)\n },\n onBlur: (event)=>{\n if (isFocusWithinRef.current && !event.currentTarget.contains(event.relatedTarget)) {\n isFocusWithinRef.current = false;\n if (lastFocusedElementRef.current) {\n lastFocusedElementRef.current.focus({\n preventScroll: true\n });\n lastFocusedElementRef.current = null;\n }\n }\n },\n onFocus: (event)=>{\n const isNotDismissible = event.target instanceof HTMLElement && event.target.dataset.dismissible === 'false';\n if (isNotDismissible) return;\n if (!isFocusWithinRef.current) {\n isFocusWithinRef.current = true;\n lastFocusedElementRef.current = event.relatedTarget;\n }\n },\n onMouseEnter: ()=>setExpanded(true),\n onMouseMove: ()=>setExpanded(true),\n onMouseLeave: ()=>{\n // Avoid setting expanded to false when interacting with a toast, e.g. swiping\n if (!interacting) {\n setExpanded(false);\n }\n },\n onDragEnd: ()=>setExpanded(false),\n onPointerDown: (event)=>{\n const isNotDismissible = event.target instanceof HTMLElement && event.target.dataset.dismissible === 'false';\n if (isNotDismissible) return;\n setInteracting(true);\n },\n onPointerUp: ()=>setInteracting(false)\n }, filteredToasts.filter((toast)=>!toast.position && index === 0 || toast.position === position).map((toast, index)=>{\n var _toastOptions_duration, _toastOptions_closeButton;\n return /*#__PURE__*/ React.createElement(Toast, {\n key: toast.id,\n icons: icons,\n index: index,\n toast: toast,\n defaultRichColors: richColors,\n duration: (_toastOptions_duration = toastOptions == null ? void 0 : toastOptions.duration) != null ? _toastOptions_duration : duration,\n className: toastOptions == null ? void 0 : toastOptions.className,\n descriptionClassName: toastOptions == null ? void 0 : toastOptions.descriptionClassName,\n invert: invert,\n visibleToasts: visibleToasts,\n closeButton: (_toastOptions_closeButton = toastOptions == null ? void 0 : toastOptions.closeButton) != null ? _toastOptions_closeButton : closeButton,\n interacting: interacting,\n position: position,\n style: toastOptions == null ? void 0 : toastOptions.style,\n unstyled: toastOptions == null ? void 0 : toastOptions.unstyled,\n classNames: toastOptions == null ? void 0 : toastOptions.classNames,\n cancelButtonStyle: toastOptions == null ? void 0 : toastOptions.cancelButtonStyle,\n actionButtonStyle: toastOptions == null ? void 0 : toastOptions.actionButtonStyle,\n closeButtonAriaLabel: toastOptions == null ? void 0 : toastOptions.closeButtonAriaLabel,\n removeToast: removeToast,\n toasts: filteredToasts.filter((t)=>t.position == toast.position),\n heights: heights.filter((h)=>h.position == toast.position),\n setHeights: setHeights,\n expandByDefault: expand,\n gap: gap,\n expanded: expanded,\n swipeDirections: props.swipeDirections\n });\n }));\n })));\n});\n\nexport { Toaster, toast, useSonner };\n","/**\n * @license React\n * use-sync-external-store-shim.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar React = require(\"react\");\nfunction is(x, y) {\n return (x === y && (0 !== x || 1 / x === 1 / y)) || (x !== x && y !== y);\n}\nvar objectIs = \"function\" === typeof Object.is ? Object.is : is,\n useState = React.useState,\n useEffect = React.useEffect,\n useLayoutEffect = React.useLayoutEffect,\n useDebugValue = React.useDebugValue;\nfunction useSyncExternalStore$2(subscribe, getSnapshot) {\n var value = getSnapshot(),\n _useState = useState({ inst: { value: value, getSnapshot: getSnapshot } }),\n inst = _useState[0].inst,\n forceUpdate = _useState[1];\n useLayoutEffect(\n function () {\n inst.value = value;\n inst.getSnapshot = getSnapshot;\n checkIfSnapshotChanged(inst) && forceUpdate({ inst: inst });\n },\n [subscribe, value, getSnapshot]\n );\n useEffect(\n function () {\n checkIfSnapshotChanged(inst) && forceUpdate({ inst: inst });\n return subscribe(function () {\n checkIfSnapshotChanged(inst) && forceUpdate({ inst: inst });\n });\n },\n [subscribe]\n );\n useDebugValue(value);\n return value;\n}\nfunction checkIfSnapshotChanged(inst) {\n var latestGetSnapshot = inst.getSnapshot;\n inst = inst.value;\n try {\n var nextValue = latestGetSnapshot();\n return !objectIs(inst, nextValue);\n } catch (error) {\n return !0;\n }\n}\nfunction useSyncExternalStore$1(subscribe, getSnapshot) {\n return getSnapshot();\n}\nvar shim =\n \"undefined\" === typeof window ||\n \"undefined\" === typeof window.document ||\n \"undefined\" === typeof window.document.createElement\n ? useSyncExternalStore$1\n : useSyncExternalStore$2;\nexports.useSyncExternalStore =\n void 0 !== React.useSyncExternalStore ? React.useSyncExternalStore : shim;\n","/**\n * @license React\n * use-sync-external-store-shim/with-selector.production.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\nvar React = require(\"react\"),\n shim = require(\"use-sync-external-store/shim\");\nfunction is(x, y) {\n return (x === y && (0 !== x || 1 / x === 1 / y)) || (x !== x && y !== y);\n}\nvar objectIs = \"function\" === typeof Object.is ? Object.is : is,\n useSyncExternalStore = shim.useSyncExternalStore,\n useRef = React.useRef,\n useEffect = React.useEffect,\n useMemo = React.useMemo,\n useDebugValue = React.useDebugValue;\nexports.useSyncExternalStoreWithSelector = function (\n subscribe,\n getSnapshot,\n getServerSnapshot,\n selector,\n isEqual\n) {\n var instRef = useRef(null);\n if (null === instRef.current) {\n var inst = { hasValue: !1, value: null };\n instRef.current = inst;\n } else inst = instRef.current;\n instRef = useMemo(\n function () {\n function memoizedSelector(nextSnapshot) {\n if (!hasMemo) {\n hasMemo = !0;\n memoizedSnapshot = nextSnapshot;\n nextSnapshot = selector(nextSnapshot);\n if (void 0 !== isEqual && inst.hasValue) {\n var currentSelection = inst.value;\n if (isEqual(currentSelection, nextSnapshot))\n return (memoizedSelection = currentSelection);\n }\n return (memoizedSelection = nextSnapshot);\n }\n currentSelection = memoizedSelection;\n if (objectIs(memoizedSnapshot, nextSnapshot)) return currentSelection;\n var nextSelection = selector(nextSnapshot);\n if (void 0 !== isEqual && isEqual(currentSelection, nextSelection))\n return (memoizedSnapshot = nextSnapshot), currentSelection;\n memoizedSnapshot = nextSnapshot;\n return (memoizedSelection = nextSelection);\n }\n var hasMemo = !1,\n memoizedSnapshot,\n memoizedSelection,\n maybeGetServerSnapshot =\n void 0 === getServerSnapshot ? null : getServerSnapshot;\n return [\n function () {\n return memoizedSelector(getSnapshot());\n },\n null === maybeGetServerSnapshot\n ? void 0\n : function () {\n return memoizedSelector(maybeGetServerSnapshot());\n }\n ];\n },\n [getSnapshot, getServerSnapshot, selector, isEqual]\n );\n var value = useSyncExternalStore(subscribe, instRef[0], instRef[1]);\n useEffect(\n function () {\n inst.hasValue = !0;\n inst.value = value;\n },\n [value]\n );\n useDebugValue(value);\n return value;\n};\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('../cjs/use-sync-external-store-shim.production.js');\n} else {\n module.exports = require('../cjs/use-sync-external-store-shim.development.js');\n}\n","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('../cjs/use-sync-external-store-shim/with-selector.production.js');\n} else {\n module.exports = require('../cjs/use-sync-external-store-shim/with-selector.development.js');\n}\n","module.exports = require('./dist/client/components/navigation')\n"],"names":["THEMES","id","name","mode","swatch","DEFAULT_THEME_ID","BY_ID","Map","map","t","isThemeId","has","getTheme","get","undefined","SYSTEM_CHOICE_ID","SYSTEM_CHOICE","DEFAULT_CHOICE_ID","getChoiceId","stored","resolveChoice","choice","prefersDark","r","e","f","n","Array","isArray","o","length","clsx","arguments","concatArrays","array1","array2","combinedArray","i","createClassValidatorObject","classGroupId","validator","createClassPartObject","nextPart","validators","CLASS_PART_SEPARATOR","EMPTY_CONFLICTS","ARBITRARY_PROPERTY_PREFIX","createClassGroupUtils","config","classMap","createClassMap","conflictingClassGroups","conflictingClassGroupModifiers","getClassGroupId","className","startsWith","endsWith","getGroupIdForArbitraryProperty","classParts","split","startIndex","getGroupRecursive","getConflictingClassGroupIds","hasPostfixModifier","modifierConflicts","baseConflicts","classPartObject","classPathsLength","currentClassPart","nextClassPartObject","result","classRest","join","slice","validatorsLength","validatorObj","indexOf","content","colonIndex","property","theme","classGroups","processClassGroups","group","processClassesRecursively","classGroup","len","classDefinition","processClassDefinition","processStringDefinition","processFunctionDefinition","processObjectDefinition","classPartObjectToEdit","getPart","isThemeGetter","push","entries","Object","key","value","path","current","parts","part","next","set","func","createLruCache","maxCacheSize","cacheSize","cache","create","previousCache","update","IMPORTANT_MODIFIER","MODIFIER_SEPARATOR","EMPTY_MODIFIERS","createResultObject","modifiers","hasImportantModifier","baseClassName","maybePostfixModifierPosition","isExternal","createParseClassName","prefix","experimentalParseClassName","parseClassName","bracketDepth","parenDepth","modifierStart","postfixModifierPosition","index","currentCharacter","baseClassNameWithImportantModifier","fullPrefix","parseClassNameOriginal","createSortModifiers","modifierWeights","orderSensitiveModifiers","forEach","mod","currentSegment","modifier","isArbitrary","isOrderSensitive","sort","createConfigUtils","sortModifiers","postfixLookupClassGroupIds","createPostfixLookupClassGroupIds","lookup","classGroupIds","postfixLookupClassGroups","SPLIT_CLASSES_REGEX","mergeClassList","classList","configUtils","classGroupsInConflict","classNames","trim","originalClassName","baseClassNameWithoutPostfix","substring","classGroupIdWithPostfix","variantModifier","modifierId","classId","conflictGroups","twJoin","classLists","argument","resolvedValue","string","toValue","mix","k","createTailwindMerge","createConfigFirst","createConfigRest","cacheGet","cacheSet","functionToCall","initTailwindMerge","reduce","previousConfig","createConfigCurrent","tailwindMerge","cachedResult","args","fallbackThemeArr","fromTheme","themeGetter","arbitraryValueRegex","arbitraryVariableRegex","fractionRegex","tshirtUnitRegex","lengthUnitRegex","colorFunctionRegex","shadowRegex","imageRegex","isFraction","test","isNumber","Number","isNaN","isInteger","isPercent","isTshirtSize","isAny","isLengthOnly","isNever","isShadow","isImage","isAnyNonArbitrary","isArbitraryValue","isArbitraryVariable","isNamedContainerQuery","isArbitrarySize","getIsArbitraryValue","isLabelSize","isArbitraryLength","isLabelLength","isArbitraryNumber","isLabelNumber","isArbitraryWeight","isLabelWeight","isArbitraryFamilyName","isLabelFamilyName","isArbitraryPosition","isLabelPosition","isArbitraryImage","isLabelImage","isArbitraryShadow","isLabelShadow","isArbitraryVariableLength","getIsArbitraryVariable","isArbitraryVariableFamilyName","isArbitraryVariablePosition","isArbitraryVariableSize","isArbitraryVariableImage","isArbitraryVariableShadow","isArbitraryVariableWeight","testLabel","testValue","exec","shouldMatchNoLabel","label","getDefaultConfig","themeColor","themeFont","themeText","themeFontWeight","themeTracking","themeLeading","themeBreakpoint","themeContainer","themeSpacing","themeRadius","themeShadow","themeInsetShadow","themeTextShadow","themeDropShadow","themeBlur","themePerspective","themeAspect","themeEase","themeAnimate","scaleBreak","scalePosition","scalePositionWithArbitrary","scaleOverflow","scaleOverscroll","scaleUnambiguousSpacing","scaleInset","scaleGridTemplateColsRows","scaleGridColRowStartAndEnd","span","scaleGridColRowStartOrEnd","scaleGridAutoColsRows","scaleAlignPrimaryAxis","scaleAlignSecondaryAxis","scaleMargin","scaleSizing","scaleSizingInline","scaleSizingBlock","scaleColor","scaleBgPosition","position","scaleBgRepeat","repeat","scaleBgSize","size","scaleGradientStopPosition","scaleRadius","scaleBorderWidth","scaleLineStyle","scaleBlendMode","scaleMaskImagePosition","scaleBlur","scaleRotate","scaleScale","scaleSkew","scaleTranslate","animate","aspect","blur","breakpoint","color","container","ease","font","leading","perspective","radius","shadow","spacing","text","tracking","columns","box","display","sr","float","clear","isolation","object","overflow","overscroll","inset","start","end","top","right","bottom","left","visibility","z","basis","flex","grow","shrink","order","col","row","gap","justify","items","baseline","self","p","px","py","ps","pe","pbs","pbe","pt","pr","pb","pl","m","mx","my","ms","me","mbs","mbe","mt","mr","mb","ml","inline","block","w","screen","h","list","placeholder","decoration","indent","tab","align","whitespace","break","wrap","hyphens","bg","linear","to","radial","conic","from","via","rounded","border","divide","outline","ring","opacity","mask","closest","farthest","filter","brightness","contrast","grayscale","invert","saturate","sepia","table","caption","transition","duration","delay","backface","rotate","scale","skew","transform","origin","translate","zoom","accent","appearance","caret","scheme","cursor","resize","scroll","scrollbar","snap","touch","select","fill","stroke","mergeConfigs","baseConfig","extend","override","overrideProperty","overrideConfigProperties","mergeConfigProperties","mergeArrayProperties","baseObject","overrideKey","overrideValue","overrideObject","mergeObject","mergeValue","concat","extendTailwindMerge","configExtension","createConfig","twMerge","TYPEAHEAD_RESET_MS","PATIENT_CLICK_THRESHOLD","DISABLED_TRANSITIONS_STYLE","style","CLICK_TRIGGER_IDENTIFIER","BASE_UI_SWIPE_IGNORE_ATTRIBUTE","LEGACY_SWIPE_IGNORE_ATTRIBUTE","BASE_UI_SWIPE_IGNORE_SELECTOR","LEGACY_SWIPE_IGNORE_SELECTOR","DROPDOWN_COLLISION_AVOIDANCE","fallbackAxisSide","POPUP_COLLISION_AVOIDANCE","ownerVisuallyHidden","clipPath","canUseRawUseSyncExternalStore","useStoreImplementation","useStoreFast","useStoreLegacy","useStore","store","selector","a1","a2","a3","useStoreR19","getSelection","getSnapshot","subscribe","before","instance","syncIndex","didInitialize","syncTick","syncHooks","didChangeStore","didChange","hook","state","is","after","onStoreChange","stores","Set","add","unsubscribes","unsubscribe","createEventEmitter","emit","event","data","listener","on","off","delete","alwaysFalse","normalizeProp","normalizable","escapeKey","outsidePress","useDismiss","context","props","enabled","outsidePressProp","outsidePressEvent","referencePress","bubbles","externalTree","rootStore","open","useState","floatingElement","dataRef","tree","outsidePressFn","outsidePressEnabled","getOutsidePressEventProp","escapeKeyBubbles","outsidePressBubbles","pressStartedInsideRef","pressStartPreventedRef","suppressNextOutsideClickRef","isComposingRef","currentPointerTypeRef","touchStateRef","cancelDismissOnEndTimeout","clearInsideReactTreeTimeout","clearInsideReactTree","insideReactTree","hasBlockingChild","bubbleKey","nodeId","floatingContext","children","nodesRef","some","child","isEventWithinOwnElements","closeOnReferencePress","setOpen","triggerPress","nativeEvent","closeOnEscapeKeyDown","native","eventDetails","isCanceled","preventDefault","isPropagationAllowed","stopPropagation","markInsideReactTree","markPressStartedInsideReactTree","button","target","markInsidePressStartPrevented","defaultPrevented","__escapeKeyBubbles","__outsidePressBubbles","compositionTimeout","preventedPressSuppressionTimeout","handleCompositionStart","handleCompositionEnd","engine","webkit","suppressImmediateOutsideClickAfterPreventedStart","resetPressStartState","getOutsidePressEvent","type","computedType","outsidePressEventValue","resolved","shouldIgnoreEvent","computedOutsidePressEvent","isEventWithinFloatingTree","targetIsInsideChildren","node","elements","floating","closeOnPressOutside","inertSelector","targetRoot","getRootNode","markers","querySelectorAll","triggers","triggerElements","hasElement","hasMatchingElement","trigger","targetRootAncestor","nextParent","every","marker","lastTraversableNode","scrollRe","isScrollableX","overflowX","isScrollableY","overflowY","canScrollX","clientWidth","scrollWidth","canScrollY","clientHeight","scrollHeight","isRTL","direction","pressedVerticalScrollbar","offsetX","offsetWidth","pressedHorizontalScrollbar","offsetY","handlePointerDown","pointerType","handleTouchStart","touches","startTime","Date","now","startX","clientX","startY","clientY","dismissOnTouchEnd","dismissOnMouseDown","addTargetEventListenerOnce","handleTouchStartCapture","closeOnPressOutsideCapture","targetEvent","handlePressEndCapture","pressStartedInsideDefaultPrevented","handleTouchMove","deltaX","Math","abs","deltaY","distance","sqrt","handleTouchMoveCapture","handleTouchEnd","handleTouchEndCapture","doc","reference","onKeyDown","onPointerDown","onClick","onMouseDown","onClickCapture","onMouseDownCapture","onPointerDownCapture","onMouseUpCapture","onTouchEndCapture","onTouchMoveCapture","useSyncedFloatingRootContext","options","popupStore","treatPopupAsFloatingElement","floatingRootContext","floatingRootContextProp","floatingId","nested","onOpenChange","referenceElement","handleOpenChange","internalStoreRef","transitionStatus","syncOnly","useSyncedValue","valuesToSync","domReferenceElement","positionReference","FOCUSABLE_ATTRIBUTE","ACTIVE_KEY","SELECTED_KEY","TYPEABLE_SELECTOR","ARROW_LEFT","ARROW_RIGHT","ARROW_UP","ARROW_DOWN","stopEvent","isReactEvent","isVirtualClick","isTrusted","os","android","buttons","detail","isVirtualPointerEvent","env","jsdom","width","height","pressure","isMouseLikePointerType","strict","values","includes","isClickLikeEvent","getNodeChildren","nodes","onlyOpenChildren","directChildren","parentId","flatMap","getDeepestNode","deepestNodeId","maxDepth","findDeepest","depth","find","getNodeAncestors","allAncestors","currentParentId","currentNode","isDifferentGridRow","cols","prevRow","floor","isIndexOutOfListBounds","getMinListIndex","listRef","disabledIndices","findNonDisabledListIndex","getMaxListIndex","decrement","startingIndex","amount","isListIndexDisabled","getGridNavigatedIndex","orientation","loopFocus","onLoop","rtl","minIndex","maxIndex","prevIndex","stop","nextIndex","verticalDirection","rows","rowIndexMap","hasRoleRow","visibleItemCount","currentRowEl","currentRowIndex","el","idx","rowEl","hasDomRows","inferredDomCols","rowLength","hasVirtualizedGaps","verticalCols","navigateVertically","currentRow","colInRow","step","nextRow","clampedCol","min","targetItemIndex","returnedItemIndex","targetRow","candidate","navigateVerticallyWithInferredRows","rowStep","lastRowStart","rowCount","rowStart","rowEnd","verticalCandidate","maxCol","offset","lastRow","createGridCellMap","sizes","dense","cellMap","itemPlaced","targetCells","j","cell","getGridCellIndexOfCorner","corner","firstCellIndex","sizeItem","lastIndexOf","getGridCellIndices","indices","cellIndex","isExplicitlyDisabled","element","isElementVisible","hasAttribute","getAttribute","isHiddenByStyles","styles","isConnected","checkVisibility","createChangeEventDetails","reason","customProperties","canceled","allowPropagation","custom","details","Event","cancel","createGenericEventDetails","getStateAttributesProps","customMapping","hasOwnProperty","customProps","assign","toLowerCase","toString","none","triggerHover","triggerFocus","itemPress","closePress","linkPress","clearPress","chipRemovePress","trackPress","incrementPress","decrementPress","inputChange","inputClear","inputBlur","inputPaste","inputPress","focusOut","closeWatcher","listNavigation","keyboard","pointer","drag","wheel","scrub","cancelOpen","siblingOpen","disabled","missing","initial","imperativeAction","swipe","windowResize","activeElement","shadowRoot","contains","parent","rootNode","parentNode","host","getTarget","composedPath","TransitionStatusDataAttributes","STARTING_HOOK","startingStyle","ENDING_HOOK","endingStyle","transitionStatusMapping","useBaseUiId","idOverride","useAnimationsFinished","elementOrRef","waitForStartingStyleRemoved","treatAbortedAsFinished","frame","fnToExecute","signal","resolvedElement","done","getAnimations","globalThis","BASE_UI_ANIMATIONS_DISABLED","Promise","all","animation","finished","then","aborted","catch","currentAnimations","pending","playState","startingStyleAttribute","request","attributeObserver","MutationObserver","disconnect","observe","attributes","attributeFilter","addEventListener","once","useRenderElement","componentProps","params","renderProp","render","outProps","useRenderElementProps","evaluateRenderProp","classNameProp","styleProp","ref","stateAttributesMapping","stateProps","resolvedProps","resolveRenderFunctionProps","document","REACT_LAZY_TYPE","Symbol","for","COMPONENT_IDENTIFIER_PATTERN","LOWERCASE_CHARACTER_PATTERN","mergedProps","newElement","$$typeof","toArray","renderTag","Error","warnIfRenderPropLooksLikeComponent","renderFn","functionName","Tag","alt","useTransitionStatus","enableIdleState","deferEndingState","setTransitionStatus","mounted","setMounted","EMPTY_PROPS","mergeProps","a","b","c","d","createInitialMergedProps","merged","mergeInto","mergePropsN","inputProps","isPropsGetter","resolvePropsGetter","copyInitialProps","mutablyMergeInto","copiedProps","propName","propValue","isEventHandler","wrapEventHandler","externalProps","externalPropValue","mergeClassNames","mergeEventHandlers","code0","charCodeAt","code1","code2","previousProps","ourHandler","theirHandler","isSyntheticEvent","baseUIEvent","makeEventPreventable","baseUIHandlerPrevented","handler","preventBaseUIHandler","ourClassName","theirClassName","CommonPopupDataAttributes","CommonTriggerDataAttributes","TRIGGER_HOOK","popupOpen","PRESSABLE_TRIGGER_HOOK","pressed","POPUP_OPEN_HOOK","POPUP_CLOSED_HOOK","closed","ANCHOR_HIDDEN_HOOK","anchorHidden","triggerOpenStateMapping","pressableTriggerOpenStateMapping","popupStateMapping","PopupTriggerMap","elementsSet","idMap","existingElement","predicate","getById","getEmptyRootContext","resolveRef","maybeRef","removeEventListener","NOOP","EMPTY_ARRAY","freeze","EMPTY_OBJECT","hooks","currentInstance","getInstance","setInstance","register","fastComponent","fn","FastComponent","forwardedRef","createInstance","displayName","fastComponentRef","createFormatErrorMessage","baseUrl","formatErrorMessage","code","url","URL","searchParams","arg","append","getReactElementRef","reactElement","propsWithRef","mergeCleanups","cleanups","cleanup","mergeObjects","ownerDocument","readRawData","navigator","userAgent","platform","maxTouchPoints","lowerUserAgent","lowerPlatform","majorVersion","parseInt","isReactVersionAtLeast","reactVersionToCheck","createSelector","other","va","vb","vc","vd","ve","EMPTY","LAST_RAF","requestAnimationFrame","Scheduler","callbacks","callbacksCount","nextId","startId","isScheduled","tick","timestamp","currentCallbacks","currentCallbacksCount","didRAFChange","scheduler","AnimationFrame","currentId","disposeEffect","useAnimationFrame","timeout","globalId","useGlobalId","defaultId","setDefaultId","maybeReactUseId","useId","reactId","noop","useIsoLayoutEffect","useMergedRefs","forkRef","createForkRef","callback","useMergedRefsN","refs","didChangeN","newRefs","cleanupCallbacks","refCleanup","cleanupCallback","useOnFirstRender","useOnMount","UNINITIALIZED","useRefWithInit","init","initArg","SafeReact","imported module 72131","Timeout","setTimeout","isStarted","clearTimeout","useTimeout","useValueAsRef","latest","createLatestRef","effect","warn","messages","hasWindow","getNodeName","isNode","nodeName","getWindow","_node$ownerDocument","defaultView","window","getDocumentElement","_ref","documentElement","isElement","isHTMLElement","isShadowRoot","ShadowRoot","isOverflowElement","getComputedStyle","isTableElement","isTopLayer","matches","_e","willChangeRe","containRe","isNotNone","isWebKitValue","isContainingBlock","elementOrCss","css","isWebKit","backdropFilter","willChange","contain","getContainingBlock","getParentNode","isLastTraversableNode","CSS","supports","getNodeScroll","scrollLeft","scrollTop","scrollX","scrollY","assignedSlot","getNearestOverflowAncestor","body","getOverflowAncestors","traverseIframes","_node$ownerDocument2","scrollableAncestor","isBody","win","frameElement","getFrameElement","visualViewport","getPrototypeOf","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","_interop_require_wildcard","obj","__esModule","default","newObj","__proto__","hasPropertyDescriptor","defineProperty","getOwnPropertyDescriptor","prototype","call","desc","exports","_","Subscribable","listeners","bind","onSubscribe","onUnsubscribe","hasListeners","infiniteQueryBehavior","pages","onFetch","query","fetchOptions","meta","fetchMore","oldPages","oldPageParams","pageParams","currentPage","fetchFn","cancelled","addSignalProperty","queryFn","fetchPage","param","previous","reject","resolve","createQueryFnContext","queryFnContext2","client","queryKey","pageParam","queryFnContext","page","maxPages","addTo","pageParamFn","getPreviousPageParam","getNextPageParam","oldData","remainingPages","initialPageParam","persister","lastIndex","hasNextPage","hasPreviousPage","QueryObserver","setOptions","bindMethods","refetch","removeObserver","addObserver","shouldFetchOnMount","updateResult","destroy","shouldFetchOnReconnect","shouldFetchOn","prevOptions","refetchOnReconnect","shouldFetchOnWindowFocus","refetchOnWindowFocus","prevQuery","defaultQueryOptions","_defaulted","getQueryCache","notify","observer","shouldFetchOptionally","staleTime","nextRefetchInterval","getOptimisticResult","build","createResult","shouldAssignObserverCurrentProperties","getCurrentResult","trackResult","onPropTracked","Proxy","trackProp","experimental_prefetchInRender","status","Reflect","getCurrentQuery","fetch","fetchOptimistic","defaultedOptions","cancelRefetch","promise","throwOnError","isServer","isStale","time","dataUpdatedAt","refetchInterval","nextInterval","setInterval","refetchIntervalInBackground","isFocused","clearInterval","prevResult","prevResultState","prevResultOptions","queryChange","queryInitialState","newState","isPlaceholderData","_optimisticResults","fetchOnMount","fetchOptionally","fetchStatus","error","errorUpdatedAt","skipSelect","placeholderData","selectError","isFetching","isPending","isError","isLoading","hasData","isSuccess","isInitialLoading","failureCount","fetchFailureCount","failureReason","fetchFailureReason","errorUpdateCount","isFetched","isFetchedAfterMount","dataUpdateCount","isRefetching","isLoadingError","isPaused","isRefetchError","isEnabled","nextResult","hasResultData","isErrorWithoutData","finalizeThenableIfPossible","thenable","recreateThenable","prevThenable","queryHash","shouldNotifyListeners","notifyOnChangeProps","notifyOnChangePropsValue","includedProps","keys","typedKey","changed","onQueryUpdate","notifyOptions","batch","shouldLoadOnMount","retryOnMount","refetchOnMount","field","suspense","isStaleByTime","optimisticResult","forbidden","DIGEST","HTTP_ERROR_FALLBACK_ERROR_CODE","process","__NEXT_EXPERIMENTAL_AUTH_INTERRUPTS","digest","DynamicServerError","isDynamicServerError","DYNAMIC_ERROR_CODE","constructor","description","err","HTTPAccessErrorStatus","getAccessFallbackErrorTypeByStatus","getAccessFallbackHTTPStatus","isHTTPAccessFallbackError","NOT_FOUND","FORBIDDEN","UNAUTHORIZED","ALLOWED_CODES","httpStatus","isNextRouterError","isRedirectError","useDynamicRouteParams","useDynamicSearchParams","ReadonlyURLSearchParams","RedirectType","ServerInsertedHTMLContext","notFound","permanentRedirect","redirect","unauthorized","unstable_isUnrecognizedActionError","unstable_rethrow","useParams","usePathname","useRouter","useSearchParams","useSelectedLayoutSegment","useSelectedLayoutSegments","useServerInsertedHTML","instrumentParamsForClientValidation","instrumentSearchParamsForClientValidation","expectCompleteParamsInClientValidation","__NEXT_CACHE_COMPONENTS","require","useContext","SearchParamsContext","readonlySearchParams","useMemo","NODE_ENV","React","navigationPromises","use","NavigationPromisesContext","pathname","PathnameContext","router","AppRouterContext","layout","LayoutRouterContext","bfcacheIdNumber","parentRenderTree","bfcacheId","back","forward","refresh","hmrRefresh","replace","prefetch","experimental_gesturePush","PathParamsContext","parallelRouteKey","selectedLayoutSegmentsPromises","getSelectedLayoutSegmentPath","parentTree","selectedLayoutSegments","selectedLayoutSegmentPromises","computeSelectedLayoutSegment","ReadonlyURLSearchParamsError","URLSearchParams","REDIRECT_ERROR_CODE","errorCode","destination","at","statusCode","RedirectStatusCode","getRedirectError","getRedirectStatusCodeFromError","getRedirectTypeFromError","getURLFromRedirectError","TemporaryRedirect","actionAsyncStorage","getStore","isAction","PermanentRedirect","StaticGenBailoutError","isStaticGenBailoutError","NEXT_STATIC_GEN_BAILOUT","UnrecognizedActionError","isBailoutToCSRError","isHangingPromiseRejectionError","isPrerenderInterruptedError","cause","METADATA_BOUNDARY_NAME","OUTLET_BOUNDARY_NAME","ROOT_LAYOUT_BOUNDARY_NAME","VIEWPORT_BOUNDARY_NAME","atLeastOneTask","scheduleImmediate","scheduleOnNextTick","waitAtLeastOneReactRenderTask","cb","NEXT_RUNTIME","nextTick","setImmediate","createDynamicBodyError","createDynamicBodyErrorInNavigation","createDynamicBodyErrorInStaticRoute","createDynamicMetadataError","createDynamicMetadataErrorInStaticRoute","createDynamicOrRuntimeBodyError","createDynamicOrRuntimeMetadataError","createDynamicOrRuntimeViewportError","createDynamicViewportError","createDynamicViewportErrorInStaticRoute","createLinkBodyErrorInNavigation","createLinkMetadataError","createLinkViewportError","createNavigationBodyErrorInNavigation","createNavigationMetadataError","createNavigationViewportError","createNonPrerenderableBodyErrorInStaticRoute","createNonPrerenderableMetadataErrorInStaticRoute","createNonPrerenderableViewportErrorInStaticRoute","createPrefetchBodyErrorInNavigation","createPrefetchMetadataError","createPrefetchViewportError","createRuntimeBodyError","createRuntimeBodyErrorInNavigation","createRuntimeBodyErrorInStaticRoute","createRuntimeMetadataError","createRuntimeMetadataErrorInStaticRoute","createRuntimeViewportError","createRuntimeViewportErrorInStaticRoute","logBuildDebugHint","route","console","__NEXT_DEV_SERVER","getUseSearchParamsBailoutReason","createReactBrowserBailoutReason","expression","workStore","workAsyncStorage","workUnitStore","workUnitAsyncStorage","fallbackParams","fallbackRouteParams","makeClientHookHangingPromise","renderSignal","ClientHookDynamicError","InvariantError","throwForMissingRequestStore","forceStatic","__NEXT_EXPERIMENTAL_REACT_BROWSER_BAILOUT","browser","BailoutToCSRError","DynamicHoleKind","PreludeState","abortAndThrowOnSynchronousRequestDataAccess","abortOnSynchronousPlatformIOAccess","accessedDynamicData","annotateDynamicAccess","consumeDynamicAccess","createDynamicTrackingState","createDynamicValidationState","createHangingInputAbortSignal","createInstantValidationState","formatDynamicAPIAccesses","getDisallowedReasonsInStaticRoute","getFirstDynamicReason","getNavigationDisallowedDynamicReasons","getStaticShellDisallowedDynamicReasons","logDisallowedDynamicError","markCurrentScopeAsDynamic","throwIfDisallowedDynamic","throwIfDisallowedDynamicInStaticRoute","throwIfSyncIOUsed","throwToInterruptStaticGeneration","trackAllowedDynamicAccess","trackDynamicAccessInStaticRoute","trackDynamicDataInDynamicRender","trackDynamicHoleInNavigation","trackDynamicHoleInStaticShell","trackThrownErrorInNavigation","isDebugDynamicAccesses","dynamicAccesses","syncDynamicErrorWithStack","syncDynamicErrorWithStackPostMicrotask","hasSuspenseAboveBody","hasDynamicMetadata","dynamicMetadata","hasDynamicViewport","hasAllowedDynamic","dynamicErrors","getPendingClientSyncDynamicError","clientDynamic","trackingState","forceDynamic","dynamicShouldError","revalidate","dynamicUsageDescription","dynamicUsageStack","stack","markRequestStoreAsDynamic","prerenderStore","requestStore","phase","usedDynamic","abortOnSynchronousDynamicDataAccess","createPrerenderInterruptedError","controller","abort","dynamicTracking","errorWithStack","queueMicrotask","prerenderSignal","NEXT_PRERENDER_INTERRUPTED","message","serverDynamic","access","line","AbortController","cacheSignal","inputReady","stagedRendering","getStagedRenderingController","finalStage","waitForStage","hasSuspenseRegex","bodyAndImplicitTags","hasSuspenseBeforeRootLayoutWithoutBodyOrImplicitBodyRegex","RegExp","hasMetadataRegex","hasViewportRegex","hasOutletRegex","hasInstantValidationBoundaryRegex","INSTANT_VALIDATION_BOUNDARY_NAME","slotMarkerRegex","INSTANT_SLOT_MARKER_PREFIX","INSTANT_SLOT_MARKER_SUFFIX","resolveInstantStack","componentStack","dynamicValidation","slotStacks","match","slotIndex","slotStack","trackOutletSuspenseAboveBody","dynamicReason","isServerPartial","kind","syncDynamicError","addErrorContext","createMetadataErrorInStaticRoute","createViewportErrorInStaticRoute","hasSuspense","isClientHookDynamicError","createBodyErrorInStaticRoute","createBodyError","dynamicHoleKind","hasAllowedClientDynamicAboveBoundary","validationPreventingErrors","thrownErrorsOutsideBoundary","boundaryState","effectiveCreateInstantStack","createMetadataError","createViewportError","boundaryLocation","allRequiredBoundariesRendered","suspenseLocation","createBodyErrorInNavigation","thrownValue","reactBrowserBailout","browserBailoutReason","getReactBrowserBailoutReason","browserBailoutError","createInstantStack","ownerStack","captureOwnerStack","prelude","allowEmptyStaticShell","isFallbackShell","reasons","validationSampleTracking","devRenderDidError","missingSampleErrors","rootInstantStack","missingFiles","filePaths","requiredIds","renderedIds","filePath","normalized","cwd","createUnrenderedSegmentError","AggregateError","createValidationBoundaryTracking","matchPrevious","EnsureStaticLevel","resolveEnsureStaticConfig","resolveEnsureStaticLevel","getEnsureStaticLevel","ensureStatic","partialPrefetching","resolveEnsureStaticConfigImpl","originalConfig","formatEnsureStaticExport","layoutOrPageMod","getLayoutOrPageModule","getEnsureStaticConfigForModule","parentResult","slotsResult","slotResultKey","parallelRoutes","parseLoaderTree","parallelRoute","childResult","compareEnsureStatic","formatParallelSlot","comparison","slot","JSON","stringify","Comparison","ENSURE_STATIC_ORDER","leftSort","rightSort","RENDER_STAGE_ADVANCE_ORDER","RenderStage","StagedRenderingController","SyncIOMode","getNextStage","isAdvanceableRenderStage","stage","abortSignal","abandonController","syncIO","currentStage","syncInterruptReason","createAdvanceableStageTriggers","syncIOMode","cancelStageTrigger","abandonRender","onStage","addSyncTriggerListener","shouldTrackSyncInterrupt","syncInterruptCurrentStageWithReason","advanceStage","getSyncInterruptReason","getStageEndTime","triggeredAt","Infinity","nextStageIx","dynamicStageIx","resolveStage","targetStage","targetStageIx","fireStageTrigger","getStagePromise","delayUntilStage","stagePromise","makeDevtoolsIOPromiseFromIOTrigger","ignoreReject","createStageTrigger","ioTrigger","_listeners","createPromiseWithResolvers","_resolvePromise","_rejectPromise","performance","timeOrigin","RENDER_STAGES_BY_DATA_KIND","applyOwnerStack","createPrerenderDataTracking","finishPrerenderDataTracking","makeDevtoolsIOAwarePromise","makeDynamicHangingPromise","makeFallbackParamsHangingPromise","makePrefetchHangingPromise","makePromiseFromTrigger","makeSessionDataHangingPromise","makeURLDataHangingPromise","makeUnknownRuntimeDataHangingPromise","makeUntrackedHangingPromise","trackFallbackParamsAccessed","trackIncompatibleShellContent","trackPromiseUsed","trackURLDataAccessed","HANGING_PROMISE_REJECTION","HangingPromiseRejectionError","CLIENT_HOOK_DYNAMIC","abortListenersBySignal","makeHangingPromiseWithError","trackSessionDataAccessed","runtimeDataAccessed","shouldAttemptStaticShell","shouldAttemptStaticPrefetch","prerenderDataTracking","trackRuntimeDataAccessed","dataKind","Before","NavigationStatic","ensureStaticLevel","None","firstAffectedStage","ShellStatic","Shell","logRuntimeDeopt","PrefetchStatic","Prefetch","markRuntimeDataAccessWhenStageReached","isFallbackUpgradeable","logRuntimeUpgradeableFallback","stageController","NEXT_PRIVATE_DEBUG_RUNTIME_DATA","log","Dynamic","Abandoned","NEXT_PRIVATE_DEBUG_VALIDATION","hasIncompatibleShellContent","hangingPromise","boundRejection","currentListeners","underlying","onUse","TrackedPromise","species","tracked","onFulfilled","onRejected","sessionData","ShellRuntime","staticUrlData","prefetchApi","static","PrefetchStatic_prefetchApi","runtime","PrefetchRuntime_prefetchApi","PrefetchRuntime","runtimeUrlData","getClientReact","getServerReact","innerOwnerStack","outerOwnerStack","frames","getComponentTypeModule","loaderTree","defaultPage","isLayout","isPage","isDefaultPage","DEFAULT_SEGMENT_KEY","modType","moduleType","module","createLinkPrefetchPartialError","BAILOUT_TO_CSR","isNextBrowserBailoutError","REACT_BROWSER_BAILOUT_REASON","res","rej","segment","modules","staticSiblings","template","conventionPath","NOT_FOUND_SEGMENT_KEY","PAGE_SEGMENT_KEY","getSegmentValue","isGroupSegment","isParallelRouteSegment","segments","rawSegment","first","segmentPath","segmentValue","__insertCSS","head","getElementsByTagName","createElement","appendChild","styleSheet","cssText","createTextNode","getAsset","SuccessIcon","InfoIcon","WarningIcon","ErrorIcon","bars","Loader","visible","Boolean","xmlns","viewBox","fillRule","clipRule","CloseIcon","strokeWidth","strokeLinecap","strokeLinejoin","x1","y1","x2","y2","useIsDocumentHidden","isDocumentHidden","setIsDocumentHidden","hidden","useEffect","toastsCounter","Observer","subscriber","subscribers","splice","publish","addToast","toasts","_data_id","rest","alreadyExists","toast","dismissible","dismissedToasts","title","dismiss","success","info","warning","loading","Function","shouldDismiss","originalPromise","response","isReactElementResponse","isValidElement","isHttpResponse","ok","promiseData","isExtendedResult","toastSettings","finally","unwrap","jsx","getActiveToasts","ToastState","toastFunction","basicToast","getHistory","getToasts","action","VISIBLE_TOASTS_AMOUNT","VIEWPORT_OFFSET","MOBILE_VIEWPORT_OFFSET","TOAST_LIFETIME","TOAST_WIDTH","GAP","SWIPE_THRESHOLD","TIME_BEFORE_UNMOUNT","cn","classes","getDefaultSwipeDirections","y","x","directions","Toast","_toast_classNames","_toast_classNames1","_toast_classNames2","_toast_classNames3","_toast_classNames4","_toast_classNames5","_toast_classNames6","_toast_classNames7","_toast_classNames8","ToasterInvert","unstyled","interacting","setHeights","visibleToasts","heights","expanded","removeToast","defaultRichColors","closeButton","closeButtonFromToaster","cancelButtonStyle","actionButtonStyle","descriptionClassName","durationFromToaster","expandByDefault","icons","closeButtonAriaLabel","swipeDirection","setSwipeDirection","swipeOutDirection","setSwipeOutDirection","removed","setRemoved","swiping","setSwiping","swipeOut","setSwipeOut","isSwiped","setIsSwiped","offsetBeforeRemove","setOffsetBeforeRemove","initialHeight","setInitialHeight","remainingTime","useRef","dragStartTime","toastRef","isFront","isVisible","toastType","toastClassname","toastDescriptionClassname","heightIndex","findIndex","toastId","_toast_closeButton","closeTimerStartTimeRef","lastCloseTimerStartTimeRef","pointerStartRef","toastsHeightBefore","prev","curr","reducerIndex","toastNode","getBoundingClientRect","useLayoutEffect","originalHeight","newHeight","deleteToast","useCallback","timeoutId","pauseTimer","elapsedTime","getTime","startTimer","onAutoClose","onDismiss","getLoadingIcon","loader","icon","_toast_richColors","_icons_close","tabIndex","richColors","testId","onDragEnd","setPointerCapture","pointerId","tagName","onPointerUp","_toastRef_current","_toastRef_current1","_dragStartTime_current","swipeAmountX","getPropertyValue","swipeAmountY","timeTaken","swipeAmount","velocity","_toastRef_current2","_toastRef_current3","setProperty","onPointerMove","_window_getSelection","isHighlighted","yDelta","xDelta","_props_swipeDirections","swipeDirections","getDampening","delta","factor","dampenedDelta","close","cancelButton","actionButton","getDocumentDirection","dirAttribute","assignOffset","defaultOffset","mobileOffset","isMobile","defaultValue","assignAll","useSonner","activeToasts","setActiveToasts","flushSync","indexOfExistingToast","Toaster","forwardRef","hotkey","expand","toastOptions","dir","containerAriaLabel","setToasts","filteredToasts","toasterId","possiblePositions","setExpanded","setInteracting","actualTheme","setActualTheme","hotkeyLabel","lastFocusedElementRef","isFocusWithinRef","toastToRemove","_toasts_find","matchMedia","darkMediaQuery","handleKeyDown","_listRef_current","isHotkeyPressed","_listRef_current1","focus","preventScroll","suppressHydrationWarning","_heights_","onBlur","currentTarget","relatedTarget","onFocus","isNotDismissible","HTMLElement","dataset","onMouseEnter","onMouseMove","onMouseLeave","_toastOptions_duration","_toastOptions_closeButton","objectIs","useDebugValue","useSyncExternalStore$2","_useState","inst","forceUpdate","checkIfSnapshotChanged","latestGetSnapshot","nextValue","useSyncExternalStore$1","shim","useSyncExternalStore","useSyncExternalStoreWithSelector","getServerSnapshot","isEqual","instRef","hasValue","memoizedSelector","nextSnapshot","hasMemo","memoizedSnapshot","currentSelection","memoizedSelection","nextSelection","maybeGetServerSnapshot"],"mappings":"iDACA,EAAA,EAAA,CAAA,CAAA,OACA,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,GAC5B,OAAQI,EAAoBD,CAChC,CACA,OAAQC,EAAoBJ,CAC9B,CAEA,GADAG,EAAmBC,EACftB,EAASoB,EAAkBF,GAAe,OAAOG,EACrD,IAAIE,EAAgBnnD,EAAS8mD,UAC7B,AAAI,KAAK,IAAMJ,GAAWA,EAAQO,EAAkBE,IAC1CH,EAAmBF,EAAeG,CAAAA,GAC5CD,EAAmBF,EACXI,AAFN,EAE0BC,EAC9B,CACA,IACEH,EACAE,EAFEH,EAAU,CAAC,EAGbK,EACE,KAAK,IAAMX,EAAoB,KAAOA,EAC1C,MAAO,CACL,WACE,OAAOI,EAAiBvmD,IAC1B,EACA,OAAS8mD,EACL,KAAK,EACL,WACE,OAAOP,EAAiBO,IAC1B,EACL,AACH,EACA,CAAC9mD,EAAammD,EAAmBzmD,EAAU0mD,GAAQ,CAEF,CAAC,EAAE,CAAEC,CAAO,CAAC,EAAE,EASlE,OARAnP,EACE,WACEwO,EAAKY,QAAQ,CAAG,CAAC,EACjBZ,EAAKv9D,KAAK,CAAGA,CACf,EACA,CAACA,EAAM,EAETo9D,EAAcp9D,GACPA,CACT,mBCjFEwrD,EAAOlnB,OAAO,CAAA,EAAA,CAAA,CAAA,wBCAdknB,EAAOlnB,OAAO,CAAA,EAAA,CAAA,CAAA,yBCHhBknB,EAAOlnB,OAAO,CAAA,EAAA,CAAA,CAAA","ignoreList":[2,3,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,88,89,90,91,95,96,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159]}
|