create-airjam 0.1.8 → 0.2.1
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/dist/index.js +17 -4
- package/package.json +10 -8
- package/templates/pong/.env.example +9 -2
- package/templates/pong/{AI_INSTRUCTIONS.md → AGENTS.md} +9 -2
- package/templates/pong/README.md +43 -6
- package/templates/pong/_gitignore +5 -0
- package/templates/pong/airjam-docs/for-agents/page.md +27 -0
- package/templates/pong/airjam-docs/getting-started/architecture/page.md +4 -1
- package/templates/pong/airjam-docs/getting-started/quick-start/page.md +24 -3
- package/templates/pong/airjam-docs/sdk/hooks/page.md +2 -1
- package/templates/pong/airjam-docs/sdk/networked-state/page.md +1 -1
- package/templates/pong/package.json +6 -3
- package/templates/pong/scripts/dev-secure.mjs +177 -0
- package/templates/pong/scripts/secure-init.mjs +134 -0
- package/templates/pong/src/App.tsx +2 -0
- package/templates/pong/src/vite-env.d.ts +1 -0
- package/templates/pong/vercel.json +19 -0
- package/templates/pong/vite.config.ts +9 -0
- package/templates/pong/dist/assets/index-BwJ4uU20.js +0 -269
- package/templates/pong/dist/assets/index-D42jDbB5.css +0 -1
- package/templates/pong/dist/index.html +0 -19
- package/templates/pong/node_modules/.bin/air-jam-server +0 -17
- package/templates/pong/node_modules/.bin/eslint +0 -17
- package/templates/pong/node_modules/.bin/eslint-config-prettier +0 -17
- package/templates/pong/node_modules/.bin/tsc +0 -17
- package/templates/pong/node_modules/.bin/tsserver +0 -17
- package/templates/pong/node_modules/.bin/vite +0 -17
- package/templates/pong/node_modules/.vite/deps/@radix-ui_react-dialog.js +0 -1680
- package/templates/pong/node_modules/.vite/deps/@radix-ui_react-dialog.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/@radix-ui_react-slider.js +0 -638
- package/templates/pong/node_modules/.vite/deps/@radix-ui_react-slider.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/@radix-ui_react-slot.js +0 -129
- package/templates/pong/node_modules/.vite/deps/@radix-ui_react-slot.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/@radix-ui_react-tabs.js +0 -434
- package/templates/pong/node_modules/.vite/deps/@radix-ui_react-tabs.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/_metadata.json +0 -163
- package/templates/pong/node_modules/.vite/deps/chunk-6G72RLJL.js +0 -1004
- package/templates/pong/node_modules/.vite/deps/chunk-6G72RLJL.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/chunk-BHOBIW4J.js +0 -99
- package/templates/pong/node_modules/.vite/deps/chunk-BHOBIW4J.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/chunk-E44IQKDY.js +0 -49
- package/templates/pong/node_modules/.vite/deps/chunk-E44IQKDY.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/chunk-E5X4SHYG.js +0 -21
- package/templates/pong/node_modules/.vite/deps/chunk-E5X4SHYG.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/chunk-G3PMV62Z.js +0 -35
- package/templates/pong/node_modules/.vite/deps/chunk-G3PMV62Z.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/chunk-LI6KBZ3D.js +0 -292
- package/templates/pong/node_modules/.vite/deps/chunk-LI6KBZ3D.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/chunk-MDNXVKSA.js +0 -337
- package/templates/pong/node_modules/.vite/deps/chunk-MDNXVKSA.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/chunk-METQ356G.js +0 -280
- package/templates/pong/node_modules/.vite/deps/chunk-METQ356G.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/chunk-NPTAWNEA.js +0 -171
- package/templates/pong/node_modules/.vite/deps/chunk-NPTAWNEA.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/class-variance-authority.js +0 -51
- package/templates/pong/node_modules/.vite/deps/class-variance-authority.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/clsx.js +0 -9
- package/templates/pong/node_modules/.vite/deps/clsx.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/howler.js +0 -2241
- package/templates/pong/node_modules/.vite/deps/howler.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/html5-qrcode.js +0 -29350
- package/templates/pong/node_modules/.vite/deps/html5-qrcode.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/lucide-react.js +0 -28662
- package/templates/pong/node_modules/.vite/deps/lucide-react.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/package.json +0 -3
- package/templates/pong/node_modules/.vite/deps/qrcode.js +0 -2083
- package/templates/pong/node_modules/.vite/deps/qrcode.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/react-dom.js +0 -6
- package/templates/pong/node_modules/.vite/deps/react-dom.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/react-dom_client.js +0 -20217
- package/templates/pong/node_modules/.vite/deps/react-dom_client.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/react-router-dom.js +0 -13900
- package/templates/pong/node_modules/.vite/deps/react-router-dom.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/react.js +0 -5
- package/templates/pong/node_modules/.vite/deps/react.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/react_jsx-dev-runtime.js +0 -278
- package/templates/pong/node_modules/.vite/deps/react_jsx-dev-runtime.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/react_jsx-runtime.js +0 -6
- package/templates/pong/node_modules/.vite/deps/react_jsx-runtime.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/socket__io-client.js +0 -3422
- package/templates/pong/node_modules/.vite/deps/socket__io-client.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/tailwind-merge.js +0 -2534
- package/templates/pong/node_modules/.vite/deps/tailwind-merge.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/zod.js +0 -13810
- package/templates/pong/node_modules/.vite/deps/zod.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/zustand.js +0 -56
- package/templates/pong/node_modules/.vite/deps/zustand.js.map +0 -7
- package/templates/pong/node_modules/.vite/deps/zustand_react_shallow.js +0 -77
- package/templates/pong/node_modules/.vite/deps/zustand_react_shallow.js.map +0 -7
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../../../node_modules/.pnpm/@radix-ui+primitive@1.1.3/node_modules/@radix-ui/primitive/src/primitive.tsx", "../../../../../../../node_modules/.pnpm/@radix-ui+react-context@1.1.2_@types+react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-context/src/create-context.tsx", "../../../../../../../node_modules/.pnpm/@radix-ui+react-slot@1.2.3_@types+react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-slot/src/slot.tsx", "../../../../../../../node_modules/.pnpm/@radix-ui+react-primitive@2.1.3_@types+react-dom@19.2.3_@types+react@19.2.6__@types+react@19._hl7njqfk7lmwklmajdqgwqj6ci/node_modules/@radix-ui/react-primitive/src/primitive.tsx", "../../../../../../../node_modules/.pnpm/@radix-ui+react-use-controllable-state@1.2.2_@types+react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-controllable-state/src/use-controllable-state.tsx", "../../../../../../../node_modules/.pnpm/@radix-ui+react-use-controllable-state@1.2.2_@types+react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-controllable-state/src/use-controllable-state-reducer.tsx", "../../../../../../../node_modules/.pnpm/@radix-ui+react-use-layout-effect@1.1.1_@types+react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-layout-effect/src/use-layout-effect.tsx", "../../../../../../../node_modules/.pnpm/@radix-ui+react-use-effect-event@0.0.2_@types+react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-effect-event/src/use-effect-event.tsx"],
|
|
4
|
-
"sourcesContent": ["/* eslint-disable no-restricted-properties */\n\n/* eslint-disable no-restricted-globals */\nexport const canUseDOM = !!(\n typeof window !== 'undefined' &&\n window.document &&\n window.document.createElement\n);\n/* eslint-enable no-restricted-globals */\n\nexport function composeEventHandlers<E extends { defaultPrevented: boolean }>(\n originalEventHandler?: (event: E) => void,\n ourEventHandler?: (event: E) => void,\n { checkForDefaultPrevented = true } = {}\n) {\n return function handleEvent(event: E) {\n originalEventHandler?.(event);\n\n if (checkForDefaultPrevented === false || !event.defaultPrevented) {\n return ourEventHandler?.(event);\n }\n };\n}\n\nexport function getOwnerWindow(element: Node | null | undefined) {\n if (!canUseDOM) {\n throw new Error('Cannot access window outside of the DOM');\n }\n // eslint-disable-next-line no-restricted-globals\n return element?.ownerDocument?.defaultView ?? window;\n}\n\nexport function getOwnerDocument(element: Node | null | undefined) {\n if (!canUseDOM) {\n throw new Error('Cannot access document outside of the DOM');\n }\n // eslint-disable-next-line no-restricted-globals\n return element?.ownerDocument ?? document;\n}\n\n/**\n * Lifted from https://github.com/ariakit/ariakit/blob/main/packages/ariakit-core/src/utils/dom.ts#L37\n * MIT License, Copyright (c) AriaKit.\n */\nexport function getActiveElement(\n node: Node | null | undefined,\n activeDescendant = false\n): HTMLElement | null {\n const { activeElement } = getOwnerDocument(node);\n if (!activeElement?.nodeName) {\n // `activeElement` might be an empty object if we're interacting with elements\n // inside of an iframe.\n return null;\n }\n\n if (isFrame(activeElement) && activeElement.contentDocument) {\n return getActiveElement(activeElement.contentDocument.body, activeDescendant);\n }\n\n if (activeDescendant) {\n const id = activeElement.getAttribute('aria-activedescendant');\n if (id) {\n const element = getOwnerDocument(activeElement).getElementById(id);\n if (element) {\n return element;\n }\n }\n }\n\n return activeElement as HTMLElement | null;\n}\n\nexport function isFrame(element: Element): element is HTMLIFrameElement {\n return element.tagName === 'IFRAME';\n}\n", "import * as React from 'react';\n\nfunction createContext<ContextValueType extends object | null>(\n rootComponentName: string,\n defaultContext?: ContextValueType\n) {\n const Context = React.createContext<ContextValueType | undefined>(defaultContext);\n\n const Provider: React.FC<ContextValueType & { children: React.ReactNode }> = (props) => {\n const { children, ...context } = props;\n // Only re-memoize when prop values change\n // eslint-disable-next-line react-hooks/exhaustive-deps\n const value = React.useMemo(() => context, Object.values(context)) as ContextValueType;\n return <Context.Provider value={value}>{children}</Context.Provider>;\n };\n\n Provider.displayName = rootComponentName + 'Provider';\n\n function useContext(consumerName: string) {\n const context = React.useContext(Context);\n if (context) return context;\n if (defaultContext !== undefined) return defaultContext;\n // if a defaultContext wasn't specified, it's a required context.\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``);\n }\n\n return [Provider, useContext] as const;\n}\n\n/* -------------------------------------------------------------------------------------------------\n * createContextScope\n * -----------------------------------------------------------------------------------------------*/\n\ntype Scope<C = any> = { [scopeName: string]: React.Context<C>[] } | undefined;\ntype ScopeHook = (scope: Scope) => { [__scopeProp: string]: Scope };\ninterface CreateScope {\n scopeName: string;\n (): ScopeHook;\n}\n\nfunction createContextScope(scopeName: string, createContextScopeDeps: CreateScope[] = []) {\n let defaultContexts: any[] = [];\n\n /* -----------------------------------------------------------------------------------------------\n * createContext\n * ---------------------------------------------------------------------------------------------*/\n\n function createContext<ContextValueType extends object | null>(\n rootComponentName: string,\n defaultContext?: ContextValueType\n ) {\n const BaseContext = React.createContext<ContextValueType | undefined>(defaultContext);\n const index = defaultContexts.length;\n defaultContexts = [...defaultContexts, defaultContext];\n\n const Provider: React.FC<\n ContextValueType & { scope: Scope<ContextValueType>; children: React.ReactNode }\n > = (props) => {\n const { scope, children, ...context } = props;\n const Context = scope?.[scopeName]?.[index] || BaseContext;\n // Only re-memoize when prop values change\n // eslint-disable-next-line react-hooks/exhaustive-deps\n const value = React.useMemo(() => context, Object.values(context)) as ContextValueType;\n return <Context.Provider value={value}>{children}</Context.Provider>;\n };\n\n Provider.displayName = rootComponentName + 'Provider';\n\n function useContext(consumerName: string, scope: Scope<ContextValueType | undefined>) {\n const Context = scope?.[scopeName]?.[index] || BaseContext;\n const context = React.useContext(Context);\n if (context) return context;\n if (defaultContext !== undefined) return defaultContext;\n // if a defaultContext wasn't specified, it's a required context.\n throw new Error(`\\`${consumerName}\\` must be used within \\`${rootComponentName}\\``);\n }\n\n return [Provider, useContext] as const;\n }\n\n /* -----------------------------------------------------------------------------------------------\n * createScope\n * ---------------------------------------------------------------------------------------------*/\n\n const createScope: CreateScope = () => {\n const scopeContexts = defaultContexts.map((defaultContext) => {\n return React.createContext(defaultContext);\n });\n return function useScope(scope: Scope) {\n const contexts = scope?.[scopeName] || scopeContexts;\n return React.useMemo(\n () => ({ [`__scope${scopeName}`]: { ...scope, [scopeName]: contexts } }),\n [scope, contexts]\n );\n };\n };\n\n createScope.scopeName = scopeName;\n return [createContext, composeContextScopes(createScope, ...createContextScopeDeps)] as const;\n}\n\n/* -------------------------------------------------------------------------------------------------\n * composeContextScopes\n * -----------------------------------------------------------------------------------------------*/\n\nfunction composeContextScopes(...scopes: CreateScope[]) {\n const baseScope = scopes[0];\n if (scopes.length === 1) return baseScope;\n\n const createScope: CreateScope = () => {\n const scopeHooks = scopes.map((createScope) => ({\n useScope: createScope(),\n scopeName: createScope.scopeName,\n }));\n\n return function useComposedScopes(overrideScopes) {\n const nextScopes = scopeHooks.reduce((nextScopes, { useScope, scopeName }) => {\n // We are calling a hook inside a callback which React warns against to avoid inconsistent\n // renders, however, scoping doesn't have render side effects so we ignore the rule.\n // eslint-disable-next-line react-hooks/rules-of-hooks\n const scopeProps = useScope(overrideScopes);\n const currentScope = scopeProps[`__scope${scopeName}`];\n return { ...nextScopes, ...currentScope };\n }, {});\n\n return React.useMemo(() => ({ [`__scope${baseScope.scopeName}`]: nextScopes }), [nextScopes]);\n };\n };\n\n createScope.scopeName = baseScope.scopeName;\n return createScope;\n}\n\n/* -----------------------------------------------------------------------------------------------*/\n\nexport { createContext, createContextScope };\nexport type { CreateScope, Scope };\n", "import * as React from 'react';\nimport { composeRefs } from '@radix-ui/react-compose-refs';\n\n/* -------------------------------------------------------------------------------------------------\n * Slot\n * -----------------------------------------------------------------------------------------------*/\n\ninterface SlotProps extends React.HTMLAttributes<HTMLElement> {\n children?: React.ReactNode;\n}\n\n/* @__NO_SIDE_EFFECTS__ */ export function createSlot(ownerName: string) {\n const SlotClone = createSlotClone(ownerName);\n const Slot = React.forwardRef<HTMLElement, SlotProps>((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n const childrenArray = React.Children.toArray(children);\n const slottable = childrenArray.find(isSlottable);\n\n if (slottable) {\n // the new element to render is the one passed as a child of `Slottable`\n const newElement = slottable.props.children;\n\n const newChildren = childrenArray.map((child) => {\n if (child === slottable) {\n // because the new element will be the one rendered, we are only interested\n // in grabbing its children (`newElement.props.children`)\n if (React.Children.count(newElement) > 1) return React.Children.only(null);\n return React.isValidElement(newElement)\n ? (newElement.props as { children: React.ReactNode }).children\n : null;\n } else {\n return child;\n }\n });\n\n return (\n <SlotClone {...slotProps} ref={forwardedRef}>\n {React.isValidElement(newElement)\n ? React.cloneElement(newElement, undefined, newChildren)\n : null}\n </SlotClone>\n );\n }\n\n return (\n <SlotClone {...slotProps} ref={forwardedRef}>\n {children}\n </SlotClone>\n );\n });\n\n Slot.displayName = `${ownerName}.Slot`;\n return Slot;\n}\n\nconst Slot = createSlot('Slot');\n\n/* -------------------------------------------------------------------------------------------------\n * SlotClone\n * -----------------------------------------------------------------------------------------------*/\n\ninterface SlotCloneProps {\n children: React.ReactNode;\n}\n\n/* @__NO_SIDE_EFFECTS__ */ function createSlotClone(ownerName: string) {\n const SlotClone = React.forwardRef<any, SlotCloneProps>((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n\n if (React.isValidElement(children)) {\n const childrenRef = getElementRef(children);\n const props = mergeProps(slotProps, children.props as AnyProps);\n // do not pass ref to React.Fragment for React 19 compatibility\n if (children.type !== React.Fragment) {\n props.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;\n }\n return React.cloneElement(children, props);\n }\n\n return React.Children.count(children) > 1 ? React.Children.only(null) : null;\n });\n\n SlotClone.displayName = `${ownerName}.SlotClone`;\n return SlotClone;\n}\n\n/* -------------------------------------------------------------------------------------------------\n * Slottable\n * -----------------------------------------------------------------------------------------------*/\n\nconst SLOTTABLE_IDENTIFIER = Symbol('radix.slottable');\n\ninterface SlottableProps {\n children: React.ReactNode;\n}\n\ninterface SlottableComponent extends React.FC<SlottableProps> {\n __radixId: symbol;\n}\n\n/* @__NO_SIDE_EFFECTS__ */ export function createSlottable(ownerName: string) {\n const Slottable: SlottableComponent = ({ children }) => {\n return <>{children}</>;\n };\n Slottable.displayName = `${ownerName}.Slottable`;\n Slottable.__radixId = SLOTTABLE_IDENTIFIER;\n return Slottable;\n}\n\nconst Slottable = createSlottable('Slottable');\n\n/* ---------------------------------------------------------------------------------------------- */\n\ntype AnyProps = Record<string, any>;\n\nfunction isSlottable(\n child: React.ReactNode\n): child is React.ReactElement<SlottableProps, typeof Slottable> {\n return (\n React.isValidElement(child) &&\n typeof child.type === 'function' &&\n '__radixId' in child.type &&\n child.type.__radixId === SLOTTABLE_IDENTIFIER\n );\n}\n\nfunction mergeProps(slotProps: AnyProps, childProps: AnyProps) {\n // all child props should override\n const overrideProps = { ...childProps };\n\n for (const propName in childProps) {\n const slotPropValue = slotProps[propName];\n const childPropValue = childProps[propName];\n\n const isHandler = /^on[A-Z]/.test(propName);\n if (isHandler) {\n // if the handler exists on both, we compose them\n if (slotPropValue && childPropValue) {\n overrideProps[propName] = (...args: unknown[]) => {\n const result = childPropValue(...args);\n slotPropValue(...args);\n return result;\n };\n }\n // but if it exists only on the slot, we use only this one\n else if (slotPropValue) {\n overrideProps[propName] = slotPropValue;\n }\n }\n // if it's `style`, we merge them\n else if (propName === 'style') {\n overrideProps[propName] = { ...slotPropValue, ...childPropValue };\n } else if (propName === 'className') {\n overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(' ');\n }\n }\n\n return { ...slotProps, ...overrideProps };\n}\n\n// Before React 19 accessing `element.props.ref` will throw a warning and suggest using `element.ref`\n// After React 19 accessing `element.ref` does the opposite.\n// https://github.com/facebook/react/pull/28348\n//\n// Access the ref using the method that doesn't yield a warning.\nfunction getElementRef(element: React.ReactElement) {\n // React <=18 in DEV\n let getter = Object.getOwnPropertyDescriptor(element.props, 'ref')?.get;\n let mayWarn = getter && 'isReactWarning' in getter && getter.isReactWarning;\n if (mayWarn) {\n return (element as any).ref;\n }\n\n // React 19 in DEV\n getter = Object.getOwnPropertyDescriptor(element, 'ref')?.get;\n mayWarn = getter && 'isReactWarning' in getter && getter.isReactWarning;\n if (mayWarn) {\n return (element.props as { ref?: React.Ref<unknown> }).ref;\n }\n\n // Not DEV\n return (element.props as { ref?: React.Ref<unknown> }).ref || (element as any).ref;\n}\n\nexport {\n Slot,\n Slottable,\n //\n Slot as Root,\n};\nexport type { SlotProps };\n", "import * as React from 'react';\nimport * as ReactDOM from 'react-dom';\nimport { createSlot } from '@radix-ui/react-slot';\n\nconst NODES = [\n 'a',\n 'button',\n 'div',\n 'form',\n 'h2',\n 'h3',\n 'img',\n 'input',\n 'label',\n 'li',\n 'nav',\n 'ol',\n 'p',\n 'select',\n 'span',\n 'svg',\n 'ul',\n] as const;\n\ntype Primitives = { [E in (typeof NODES)[number]]: PrimitiveForwardRefComponent<E> };\ntype PrimitivePropsWithRef<E extends React.ElementType> = React.ComponentPropsWithRef<E> & {\n asChild?: boolean;\n};\n\ninterface PrimitiveForwardRefComponent<E extends React.ElementType>\n extends React.ForwardRefExoticComponent<PrimitivePropsWithRef<E>> {}\n\n/* -------------------------------------------------------------------------------------------------\n * Primitive\n * -----------------------------------------------------------------------------------------------*/\n\nconst Primitive = NODES.reduce((primitive, node) => {\n const Slot = createSlot(`Primitive.${node}`);\n const Node = React.forwardRef((props: PrimitivePropsWithRef<typeof node>, forwardedRef: any) => {\n const { asChild, ...primitiveProps } = props;\n const Comp: any = asChild ? Slot : node;\n\n if (typeof window !== 'undefined') {\n (window as any)[Symbol.for('radix-ui')] = true;\n }\n\n return <Comp {...primitiveProps} ref={forwardedRef} />;\n });\n\n Node.displayName = `Primitive.${node}`;\n\n return { ...primitive, [node]: Node };\n}, {} as Primitives);\n\n/* -------------------------------------------------------------------------------------------------\n * Utils\n * -----------------------------------------------------------------------------------------------*/\n\n/**\n * Flush custom event dispatch\n * https://github.com/radix-ui/primitives/pull/1378\n *\n * React batches *all* event handlers since version 18, this introduces certain considerations when using custom event types.\n *\n * Internally, React prioritises events in the following order:\n * - discrete\n * - continuous\n * - default\n *\n * https://github.com/facebook/react/blob/a8a4742f1c54493df00da648a3f9d26e3db9c8b5/packages/react-dom/src/events/ReactDOMEventListener.js#L294-L350\n *\n * `discrete` is an important distinction as updates within these events are applied immediately.\n * React however, is not able to infer the priority of custom event types due to how they are detected internally.\n * Because of this, it's possible for updates from custom events to be unexpectedly batched when\n * dispatched by another `discrete` event.\n *\n * In order to ensure that updates from custom events are applied predictably, we need to manually flush the batch.\n * This utility should be used when dispatching a custom event from within another `discrete` event, this utility\n * is not necessary when dispatching known event types, or if dispatching a custom type inside a non-discrete event.\n * For example:\n *\n * dispatching a known click \uD83D\uDC4E\n * target.dispatchEvent(new Event(\u2018click\u2019))\n *\n * dispatching a custom type within a non-discrete event \uD83D\uDC4E\n * onScroll={(event) => event.target.dispatchEvent(new CustomEvent(\u2018customType\u2019))}\n *\n * dispatching a custom type within a `discrete` event \uD83D\uDC4D\n * onPointerDown={(event) => dispatchDiscreteCustomEvent(event.target, new CustomEvent(\u2018customType\u2019))}\n *\n * Note: though React classifies `focus`, `focusin` and `focusout` events as `discrete`, it's not recommended to use\n * this utility with them. This is because it's possible for those handlers to be called implicitly during render\n * e.g. when focus is within a component as it is unmounted, or when managing focus on mount.\n */\n\nfunction dispatchDiscreteCustomEvent<E extends CustomEvent>(target: E['target'], event: E) {\n if (target) ReactDOM.flushSync(() => target.dispatchEvent(event));\n}\n\n/* -----------------------------------------------------------------------------------------------*/\n\nconst Root = Primitive;\n\nexport {\n Primitive,\n //\n Root,\n //\n dispatchDiscreteCustomEvent,\n};\nexport type { PrimitivePropsWithRef };\n", "import * as React from 'react';\nimport { useLayoutEffect } from '@radix-ui/react-use-layout-effect';\n\n// Prevent bundlers from trying to optimize the import\nconst useInsertionEffect: typeof useLayoutEffect =\n (React as any)[' useInsertionEffect '.trim().toString()] || useLayoutEffect;\n\ntype ChangeHandler<T> = (state: T) => void;\ntype SetStateFn<T> = React.Dispatch<React.SetStateAction<T>>;\n\ninterface UseControllableStateParams<T> {\n prop?: T | undefined;\n defaultProp: T;\n onChange?: ChangeHandler<T>;\n caller?: string;\n}\n\nexport function useControllableState<T>({\n prop,\n defaultProp,\n onChange = () => {},\n caller,\n}: UseControllableStateParams<T>): [T, SetStateFn<T>] {\n const [uncontrolledProp, setUncontrolledProp, onChangeRef] = useUncontrolledState({\n defaultProp,\n onChange,\n });\n const isControlled = prop !== undefined;\n const value = isControlled ? prop : uncontrolledProp;\n\n // OK to disable conditionally calling hooks here because they will always run\n // consistently in the same environment. Bundlers should be able to remove the\n // code block entirely in production.\n /* eslint-disable react-hooks/rules-of-hooks */\n if (process.env.NODE_ENV !== 'production') {\n const isControlledRef = React.useRef(prop !== undefined);\n React.useEffect(() => {\n const wasControlled = isControlledRef.current;\n if (wasControlled !== isControlled) {\n const from = wasControlled ? 'controlled' : 'uncontrolled';\n const to = isControlled ? 'controlled' : 'uncontrolled';\n console.warn(\n `${caller} is changing from ${from} to ${to}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`\n );\n }\n isControlledRef.current = isControlled;\n }, [isControlled, caller]);\n }\n /* eslint-enable react-hooks/rules-of-hooks */\n\n const setValue = React.useCallback<SetStateFn<T>>(\n (nextValue) => {\n if (isControlled) {\n const value = isFunction(nextValue) ? nextValue(prop) : nextValue;\n if (value !== prop) {\n onChangeRef.current?.(value);\n }\n } else {\n setUncontrolledProp(nextValue);\n }\n },\n [isControlled, prop, setUncontrolledProp, onChangeRef]\n );\n\n return [value, setValue];\n}\n\nfunction useUncontrolledState<T>({\n defaultProp,\n onChange,\n}: Omit<UseControllableStateParams<T>, 'prop'>): [\n Value: T,\n setValue: React.Dispatch<React.SetStateAction<T>>,\n OnChangeRef: React.RefObject<ChangeHandler<T> | undefined>,\n] {\n const [value, setValue] = React.useState(defaultProp);\n const prevValueRef = React.useRef(value);\n\n const onChangeRef = React.useRef(onChange);\n useInsertionEffect(() => {\n onChangeRef.current = onChange;\n }, [onChange]);\n\n React.useEffect(() => {\n if (prevValueRef.current !== value) {\n onChangeRef.current?.(value);\n prevValueRef.current = value;\n }\n }, [value, prevValueRef]);\n\n return [value, setValue, onChangeRef];\n}\n\nfunction isFunction(value: unknown): value is (...args: any[]) => any {\n return typeof value === 'function';\n}\n", "import * as React from 'react';\nimport { useEffectEvent } from '@radix-ui/react-use-effect-event';\n\ntype ChangeHandler<T> = (state: T) => void;\n\ninterface UseControllableStateParams<T> {\n prop: T | undefined;\n defaultProp: T;\n onChange: ChangeHandler<T> | undefined;\n caller: string;\n}\n\ninterface AnyAction {\n type: string;\n}\n\nconst SYNC_STATE = Symbol('RADIX:SYNC_STATE');\n\ninterface SyncStateAction<T> {\n type: typeof SYNC_STATE;\n state: T;\n}\n\nexport function useControllableStateReducer<T, S extends {}, A extends AnyAction>(\n reducer: (prevState: S & { state: T }, action: A) => S & { state: T },\n userArgs: UseControllableStateParams<T>,\n initialState: S\n): [S & { state: T }, React.Dispatch<A>];\n\nexport function useControllableStateReducer<T, S extends {}, I, A extends AnyAction>(\n reducer: (prevState: S & { state: T }, action: A) => S & { state: T },\n userArgs: UseControllableStateParams<T>,\n initialArg: I,\n init: (i: I & { state: T }) => S\n): [S & { state: T }, React.Dispatch<A>];\n\nexport function useControllableStateReducer<T, S extends {}, A extends AnyAction>(\n reducer: (prevState: S & { state: T }, action: A) => S & { state: T },\n userArgs: UseControllableStateParams<T>,\n initialArg: any,\n init?: (i: any) => Omit<S, 'state'>\n): [S & { state: T }, React.Dispatch<A>] {\n const { prop: controlledState, defaultProp, onChange: onChangeProp, caller } = userArgs;\n const isControlled = controlledState !== undefined;\n\n const onChange = useEffectEvent(onChangeProp);\n\n // OK to disable conditionally calling hooks here because they will always run\n // consistently in the same environment. Bundlers should be able to remove the\n // code block entirely in production.\n /* eslint-disable react-hooks/rules-of-hooks */\n if (process.env.NODE_ENV !== 'production') {\n const isControlledRef = React.useRef(controlledState !== undefined);\n React.useEffect(() => {\n const wasControlled = isControlledRef.current;\n if (wasControlled !== isControlled) {\n const from = wasControlled ? 'controlled' : 'uncontrolled';\n const to = isControlled ? 'controlled' : 'uncontrolled';\n console.warn(\n `${caller} is changing from ${from} to ${to}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`\n );\n }\n isControlledRef.current = isControlled;\n }, [isControlled, caller]);\n }\n /* eslint-enable react-hooks/rules-of-hooks */\n\n type InternalState = S & { state: T };\n const args: [InternalState] = [{ ...initialArg, state: defaultProp }];\n if (init) {\n // @ts-expect-error\n args.push(init);\n }\n\n const [internalState, dispatch] = React.useReducer(\n (state: InternalState, action: A | SyncStateAction<T>): InternalState => {\n if (action.type === SYNC_STATE) {\n return { ...state, state: action.state };\n }\n\n const next = reducer(state, action);\n if (isControlled && !Object.is(next.state, state.state)) {\n onChange(next.state);\n }\n return next;\n },\n ...args\n );\n\n const uncontrolledState = internalState.state;\n const prevValueRef = React.useRef(uncontrolledState);\n React.useEffect(() => {\n if (prevValueRef.current !== uncontrolledState) {\n prevValueRef.current = uncontrolledState;\n if (!isControlled) {\n onChange(uncontrolledState);\n }\n }\n }, [onChange, uncontrolledState, prevValueRef, isControlled]);\n\n const state = React.useMemo(() => {\n const isControlled = controlledState !== undefined;\n if (isControlled) {\n return { ...internalState, state: controlledState };\n }\n\n return internalState;\n }, [internalState, controlledState]);\n\n React.useEffect(() => {\n // Sync internal state for controlled components so that reducer is called\n // with the correct state values\n if (isControlled && !Object.is(controlledState, internalState.state)) {\n dispatch({ type: SYNC_STATE, state: controlledState });\n }\n }, [controlledState, internalState.state, isControlled]);\n\n return [state, dispatch as React.Dispatch<A>];\n}\n", "import * as React from 'react';\n\n/**\n * On the server, React emits a warning when calling `useLayoutEffect`.\n * This is because neither `useLayoutEffect` nor `useEffect` run on the server.\n * We use this safe version which suppresses the warning by replacing it with a noop on the server.\n *\n * See: https://reactjs.org/docs/hooks-reference.html#uselayouteffect\n */\nconst useLayoutEffect = globalThis?.document ? React.useLayoutEffect : () => {};\n\nexport { useLayoutEffect };\n", "/* eslint-disable react-hooks/rules-of-hooks */\nimport { useLayoutEffect } from '@radix-ui/react-use-layout-effect';\nimport * as React from 'react';\n\ntype AnyFunction = (...args: any[]) => any;\n\n// See https://github.com/webpack/webpack/issues/14814\nconst useReactEffectEvent = (React as any)[' useEffectEvent '.trim().toString()];\nconst useReactInsertionEffect = (React as any)[' useInsertionEffect '.trim().toString()];\n\n/**\n * Designed to approximate the behavior on `experimental_useEffectEvent` as best\n * as possible until its stable release, and back-fill it as a shim as needed.\n */\nexport function useEffectEvent<T extends AnyFunction>(callback?: T): T {\n if (typeof useReactEffectEvent === 'function') {\n return useReactEffectEvent(callback);\n }\n\n const ref = React.useRef<AnyFunction | undefined>(() => {\n throw new Error('Cannot call an event handler while rendering.');\n });\n // See https://github.com/webpack/webpack/issues/14814\n if (typeof useReactInsertionEffect === 'function') {\n useReactInsertionEffect(() => {\n ref.current = callback;\n });\n } else {\n useLayoutEffect(() => {\n ref.current = callback;\n });\n }\n\n // https://github.com/facebook/react/issues/19240\n return React.useMemo(() => ((...args) => ref.current?.(...args)) as T, []);\n}\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;AAGO,IAAM,YAAY,CAAC,EACxB,OAAO,WAAW,eAClB,OAAO,YACP,OAAO,SAAS;AAIX,SAAS,qBACd,sBACA,iBACA,EAAE,2BAA2B,KAAK,IAAI,CAAC,GACvC;AACA,SAAO,SAAS,YAAY,OAAU;AACpC,iEAAuB;AAEvB,QAAI,6BAA6B,SAAS,CAAC,MAAM,kBAAkB;AACjE,aAAO,mDAAkB;IAC3B;EACF;AACF;;;ACtBA,YAAuB;AAaZ,yBAAA;AAXX,SAASA,eACP,mBACA,gBACA;AAC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AAW,OAAkD;AACpE,SAAO,OAAO,UAAU;AAC1B;AC/EA,IAAM,aAAa,OAAO,kBAAkB;",
|
|
6
|
-
"names": ["createContext", "useContext", "createScope", "nextScopes", "React", "import_jsx_runtime", "Slot", "props", "Slottable", "Fragment", "React", "import_jsx_runtime", "Slot", "React", "React", "useLayoutEffect", "React2", "React", "React", "value"]
|
|
7
|
-
}
|
|
@@ -1,280 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
require_react
|
|
3
|
-
} from "./chunk-6G72RLJL.js";
|
|
4
|
-
import {
|
|
5
|
-
__commonJS
|
|
6
|
-
} from "./chunk-G3PMV62Z.js";
|
|
7
|
-
|
|
8
|
-
// ../../../../node_modules/.pnpm/react-dom@19.2.0_react@19.2.0/node_modules/react-dom/cjs/react-dom.development.js
|
|
9
|
-
var require_react_dom_development = __commonJS({
|
|
10
|
-
"../../../../node_modules/.pnpm/react-dom@19.2.0_react@19.2.0/node_modules/react-dom/cjs/react-dom.development.js"(exports) {
|
|
11
|
-
"use strict";
|
|
12
|
-
(function() {
|
|
13
|
-
function noop() {
|
|
14
|
-
}
|
|
15
|
-
function testStringCoercion(value) {
|
|
16
|
-
return "" + value;
|
|
17
|
-
}
|
|
18
|
-
function createPortal$1(children, containerInfo, implementation) {
|
|
19
|
-
var key = 3 < arguments.length && void 0 !== arguments[3] ? arguments[3] : null;
|
|
20
|
-
try {
|
|
21
|
-
testStringCoercion(key);
|
|
22
|
-
var JSCompiler_inline_result = false;
|
|
23
|
-
} catch (e) {
|
|
24
|
-
JSCompiler_inline_result = true;
|
|
25
|
-
}
|
|
26
|
-
JSCompiler_inline_result && (console.error(
|
|
27
|
-
"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
|
|
28
|
-
"function" === typeof Symbol && Symbol.toStringTag && key[Symbol.toStringTag] || key.constructor.name || "Object"
|
|
29
|
-
), testStringCoercion(key));
|
|
30
|
-
return {
|
|
31
|
-
$$typeof: REACT_PORTAL_TYPE,
|
|
32
|
-
key: null == key ? null : "" + key,
|
|
33
|
-
children,
|
|
34
|
-
containerInfo,
|
|
35
|
-
implementation
|
|
36
|
-
};
|
|
37
|
-
}
|
|
38
|
-
function getCrossOriginStringAs(as, input) {
|
|
39
|
-
if ("font" === as) return "";
|
|
40
|
-
if ("string" === typeof input)
|
|
41
|
-
return "use-credentials" === input ? input : "";
|
|
42
|
-
}
|
|
43
|
-
function getValueDescriptorExpectingObjectForWarning(thing) {
|
|
44
|
-
return null === thing ? "`null`" : void 0 === thing ? "`undefined`" : "" === thing ? "an empty string" : 'something with type "' + typeof thing + '"';
|
|
45
|
-
}
|
|
46
|
-
function getValueDescriptorExpectingEnumForWarning(thing) {
|
|
47
|
-
return null === thing ? "`null`" : void 0 === thing ? "`undefined`" : "" === thing ? "an empty string" : "string" === typeof thing ? JSON.stringify(thing) : "number" === typeof thing ? "`" + thing + "`" : 'something with type "' + typeof thing + '"';
|
|
48
|
-
}
|
|
49
|
-
function resolveDispatcher() {
|
|
50
|
-
var dispatcher = ReactSharedInternals.H;
|
|
51
|
-
null === dispatcher && console.error(
|
|
52
|
-
"Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\n1. You might have mismatching versions of React and the renderer (such as React DOM)\n2. You might be breaking the Rules of Hooks\n3. You might have more than one copy of React in the same app\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem."
|
|
53
|
-
);
|
|
54
|
-
return dispatcher;
|
|
55
|
-
}
|
|
56
|
-
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
|
|
57
|
-
var React = require_react(), Internals = {
|
|
58
|
-
d: {
|
|
59
|
-
f: noop,
|
|
60
|
-
r: function() {
|
|
61
|
-
throw Error(
|
|
62
|
-
"Invalid form element. requestFormReset must be passed a form that was rendered by React."
|
|
63
|
-
);
|
|
64
|
-
},
|
|
65
|
-
D: noop,
|
|
66
|
-
C: noop,
|
|
67
|
-
L: noop,
|
|
68
|
-
m: noop,
|
|
69
|
-
X: noop,
|
|
70
|
-
S: noop,
|
|
71
|
-
M: noop
|
|
72
|
-
},
|
|
73
|
-
p: 0,
|
|
74
|
-
findDOMNode: null
|
|
75
|
-
}, REACT_PORTAL_TYPE = Symbol.for("react.portal"), ReactSharedInternals = React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;
|
|
76
|
-
"function" === typeof Map && null != Map.prototype && "function" === typeof Map.prototype.forEach && "function" === typeof Set && null != Set.prototype && "function" === typeof Set.prototype.clear && "function" === typeof Set.prototype.forEach || console.error(
|
|
77
|
-
"React depends on Map and Set built-in types. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"
|
|
78
|
-
);
|
|
79
|
-
exports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = Internals;
|
|
80
|
-
exports.createPortal = function(children, container) {
|
|
81
|
-
var key = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : null;
|
|
82
|
-
if (!container || 1 !== container.nodeType && 9 !== container.nodeType && 11 !== container.nodeType)
|
|
83
|
-
throw Error("Target container is not a DOM element.");
|
|
84
|
-
return createPortal$1(children, container, null, key);
|
|
85
|
-
};
|
|
86
|
-
exports.flushSync = function(fn) {
|
|
87
|
-
var previousTransition = ReactSharedInternals.T, previousUpdatePriority = Internals.p;
|
|
88
|
-
try {
|
|
89
|
-
if (ReactSharedInternals.T = null, Internals.p = 2, fn)
|
|
90
|
-
return fn();
|
|
91
|
-
} finally {
|
|
92
|
-
ReactSharedInternals.T = previousTransition, Internals.p = previousUpdatePriority, Internals.d.f() && console.error(
|
|
93
|
-
"flushSync was called from inside a lifecycle method. React cannot flush when React is already rendering. Consider moving this call to a scheduler task or micro task."
|
|
94
|
-
);
|
|
95
|
-
}
|
|
96
|
-
};
|
|
97
|
-
exports.preconnect = function(href, options) {
|
|
98
|
-
"string" === typeof href && href ? null != options && "object" !== typeof options ? console.error(
|
|
99
|
-
"ReactDOM.preconnect(): Expected the `options` argument (second) to be an object but encountered %s instead. The only supported option at this time is `crossOrigin` which accepts a string.",
|
|
100
|
-
getValueDescriptorExpectingEnumForWarning(options)
|
|
101
|
-
) : null != options && "string" !== typeof options.crossOrigin && console.error(
|
|
102
|
-
"ReactDOM.preconnect(): Expected the `crossOrigin` option (second argument) to be a string but encountered %s instead. Try removing this option or passing a string value instead.",
|
|
103
|
-
getValueDescriptorExpectingObjectForWarning(options.crossOrigin)
|
|
104
|
-
) : console.error(
|
|
105
|
-
"ReactDOM.preconnect(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.",
|
|
106
|
-
getValueDescriptorExpectingObjectForWarning(href)
|
|
107
|
-
);
|
|
108
|
-
"string" === typeof href && (options ? (options = options.crossOrigin, options = "string" === typeof options ? "use-credentials" === options ? options : "" : void 0) : options = null, Internals.d.C(href, options));
|
|
109
|
-
};
|
|
110
|
-
exports.prefetchDNS = function(href) {
|
|
111
|
-
if ("string" !== typeof href || !href)
|
|
112
|
-
console.error(
|
|
113
|
-
"ReactDOM.prefetchDNS(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.",
|
|
114
|
-
getValueDescriptorExpectingObjectForWarning(href)
|
|
115
|
-
);
|
|
116
|
-
else if (1 < arguments.length) {
|
|
117
|
-
var options = arguments[1];
|
|
118
|
-
"object" === typeof options && options.hasOwnProperty("crossOrigin") ? console.error(
|
|
119
|
-
"ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. It looks like the you are attempting to set a crossOrigin property for this DNS lookup hint. Browsers do not perform DNS queries using CORS and setting this attribute on the resource hint has no effect. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.",
|
|
120
|
-
getValueDescriptorExpectingEnumForWarning(options)
|
|
121
|
-
) : console.error(
|
|
122
|
-
"ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.",
|
|
123
|
-
getValueDescriptorExpectingEnumForWarning(options)
|
|
124
|
-
);
|
|
125
|
-
}
|
|
126
|
-
"string" === typeof href && Internals.d.D(href);
|
|
127
|
-
};
|
|
128
|
-
exports.preinit = function(href, options) {
|
|
129
|
-
"string" === typeof href && href ? null == options || "object" !== typeof options ? console.error(
|
|
130
|
-
"ReactDOM.preinit(): Expected the `options` argument (second) to be an object with an `as` property describing the type of resource to be preinitialized but encountered %s instead.",
|
|
131
|
-
getValueDescriptorExpectingEnumForWarning(options)
|
|
132
|
-
) : "style" !== options.as && "script" !== options.as && console.error(
|
|
133
|
-
'ReactDOM.preinit(): Expected the `as` property in the `options` argument (second) to contain a valid value describing the type of resource to be preinitialized but encountered %s instead. Valid values for `as` are "style" and "script".',
|
|
134
|
-
getValueDescriptorExpectingEnumForWarning(options.as)
|
|
135
|
-
) : console.error(
|
|
136
|
-
"ReactDOM.preinit(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.",
|
|
137
|
-
getValueDescriptorExpectingObjectForWarning(href)
|
|
138
|
-
);
|
|
139
|
-
if ("string" === typeof href && options && "string" === typeof options.as) {
|
|
140
|
-
var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin), integrity = "string" === typeof options.integrity ? options.integrity : void 0, fetchPriority = "string" === typeof options.fetchPriority ? options.fetchPriority : void 0;
|
|
141
|
-
"style" === as ? Internals.d.S(
|
|
142
|
-
href,
|
|
143
|
-
"string" === typeof options.precedence ? options.precedence : void 0,
|
|
144
|
-
{
|
|
145
|
-
crossOrigin,
|
|
146
|
-
integrity,
|
|
147
|
-
fetchPriority
|
|
148
|
-
}
|
|
149
|
-
) : "script" === as && Internals.d.X(href, {
|
|
150
|
-
crossOrigin,
|
|
151
|
-
integrity,
|
|
152
|
-
fetchPriority,
|
|
153
|
-
nonce: "string" === typeof options.nonce ? options.nonce : void 0
|
|
154
|
-
});
|
|
155
|
-
}
|
|
156
|
-
};
|
|
157
|
-
exports.preinitModule = function(href, options) {
|
|
158
|
-
var encountered = "";
|
|
159
|
-
"string" === typeof href && href || (encountered += " The `href` argument encountered was " + getValueDescriptorExpectingObjectForWarning(href) + ".");
|
|
160
|
-
void 0 !== options && "object" !== typeof options ? encountered += " The `options` argument encountered was " + getValueDescriptorExpectingObjectForWarning(options) + "." : options && "as" in options && "script" !== options.as && (encountered += " The `as` option encountered was " + getValueDescriptorExpectingEnumForWarning(options.as) + ".");
|
|
161
|
-
if (encountered)
|
|
162
|
-
console.error(
|
|
163
|
-
"ReactDOM.preinitModule(): Expected up to two arguments, a non-empty `href` string and, optionally, an `options` object with a valid `as` property.%s",
|
|
164
|
-
encountered
|
|
165
|
-
);
|
|
166
|
-
else
|
|
167
|
-
switch (encountered = options && "string" === typeof options.as ? options.as : "script", encountered) {
|
|
168
|
-
case "script":
|
|
169
|
-
break;
|
|
170
|
-
default:
|
|
171
|
-
encountered = getValueDescriptorExpectingEnumForWarning(encountered), console.error(
|
|
172
|
-
'ReactDOM.preinitModule(): Currently the only supported "as" type for this function is "script" but received "%s" instead. This warning was generated for `href` "%s". In the future other module types will be supported, aligning with the import-attributes proposal. Learn more here: (https://github.com/tc39/proposal-import-attributes)',
|
|
173
|
-
encountered,
|
|
174
|
-
href
|
|
175
|
-
);
|
|
176
|
-
}
|
|
177
|
-
if ("string" === typeof href)
|
|
178
|
-
if ("object" === typeof options && null !== options) {
|
|
179
|
-
if (null == options.as || "script" === options.as)
|
|
180
|
-
encountered = getCrossOriginStringAs(
|
|
181
|
-
options.as,
|
|
182
|
-
options.crossOrigin
|
|
183
|
-
), Internals.d.M(href, {
|
|
184
|
-
crossOrigin: encountered,
|
|
185
|
-
integrity: "string" === typeof options.integrity ? options.integrity : void 0,
|
|
186
|
-
nonce: "string" === typeof options.nonce ? options.nonce : void 0
|
|
187
|
-
});
|
|
188
|
-
} else null == options && Internals.d.M(href);
|
|
189
|
-
};
|
|
190
|
-
exports.preload = function(href, options) {
|
|
191
|
-
var encountered = "";
|
|
192
|
-
"string" === typeof href && href || (encountered += " The `href` argument encountered was " + getValueDescriptorExpectingObjectForWarning(href) + ".");
|
|
193
|
-
null == options || "object" !== typeof options ? encountered += " The `options` argument encountered was " + getValueDescriptorExpectingObjectForWarning(options) + "." : "string" === typeof options.as && options.as || (encountered += " The `as` option encountered was " + getValueDescriptorExpectingObjectForWarning(options.as) + ".");
|
|
194
|
-
encountered && console.error(
|
|
195
|
-
'ReactDOM.preload(): Expected two arguments, a non-empty `href` string and an `options` object with an `as` property valid for a `<link rel="preload" as="..." />` tag.%s',
|
|
196
|
-
encountered
|
|
197
|
-
);
|
|
198
|
-
if ("string" === typeof href && "object" === typeof options && null !== options && "string" === typeof options.as) {
|
|
199
|
-
encountered = options.as;
|
|
200
|
-
var crossOrigin = getCrossOriginStringAs(
|
|
201
|
-
encountered,
|
|
202
|
-
options.crossOrigin
|
|
203
|
-
);
|
|
204
|
-
Internals.d.L(href, encountered, {
|
|
205
|
-
crossOrigin,
|
|
206
|
-
integrity: "string" === typeof options.integrity ? options.integrity : void 0,
|
|
207
|
-
nonce: "string" === typeof options.nonce ? options.nonce : void 0,
|
|
208
|
-
type: "string" === typeof options.type ? options.type : void 0,
|
|
209
|
-
fetchPriority: "string" === typeof options.fetchPriority ? options.fetchPriority : void 0,
|
|
210
|
-
referrerPolicy: "string" === typeof options.referrerPolicy ? options.referrerPolicy : void 0,
|
|
211
|
-
imageSrcSet: "string" === typeof options.imageSrcSet ? options.imageSrcSet : void 0,
|
|
212
|
-
imageSizes: "string" === typeof options.imageSizes ? options.imageSizes : void 0,
|
|
213
|
-
media: "string" === typeof options.media ? options.media : void 0
|
|
214
|
-
});
|
|
215
|
-
}
|
|
216
|
-
};
|
|
217
|
-
exports.preloadModule = function(href, options) {
|
|
218
|
-
var encountered = "";
|
|
219
|
-
"string" === typeof href && href || (encountered += " The `href` argument encountered was " + getValueDescriptorExpectingObjectForWarning(href) + ".");
|
|
220
|
-
void 0 !== options && "object" !== typeof options ? encountered += " The `options` argument encountered was " + getValueDescriptorExpectingObjectForWarning(options) + "." : options && "as" in options && "string" !== typeof options.as && (encountered += " The `as` option encountered was " + getValueDescriptorExpectingObjectForWarning(options.as) + ".");
|
|
221
|
-
encountered && console.error(
|
|
222
|
-
'ReactDOM.preloadModule(): Expected two arguments, a non-empty `href` string and, optionally, an `options` object with an `as` property valid for a `<link rel="modulepreload" as="..." />` tag.%s',
|
|
223
|
-
encountered
|
|
224
|
-
);
|
|
225
|
-
"string" === typeof href && (options ? (encountered = getCrossOriginStringAs(
|
|
226
|
-
options.as,
|
|
227
|
-
options.crossOrigin
|
|
228
|
-
), Internals.d.m(href, {
|
|
229
|
-
as: "string" === typeof options.as && "script" !== options.as ? options.as : void 0,
|
|
230
|
-
crossOrigin: encountered,
|
|
231
|
-
integrity: "string" === typeof options.integrity ? options.integrity : void 0
|
|
232
|
-
})) : Internals.d.m(href));
|
|
233
|
-
};
|
|
234
|
-
exports.requestFormReset = function(form) {
|
|
235
|
-
Internals.d.r(form);
|
|
236
|
-
};
|
|
237
|
-
exports.unstable_batchedUpdates = function(fn, a) {
|
|
238
|
-
return fn(a);
|
|
239
|
-
};
|
|
240
|
-
exports.useFormState = function(action, initialState, permalink) {
|
|
241
|
-
return resolveDispatcher().useFormState(action, initialState, permalink);
|
|
242
|
-
};
|
|
243
|
-
exports.useFormStatus = function() {
|
|
244
|
-
return resolveDispatcher().useHostTransitionStatus();
|
|
245
|
-
};
|
|
246
|
-
exports.version = "19.2.0";
|
|
247
|
-
"undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
|
|
248
|
-
})();
|
|
249
|
-
}
|
|
250
|
-
});
|
|
251
|
-
|
|
252
|
-
// ../../../../node_modules/.pnpm/react-dom@19.2.0_react@19.2.0/node_modules/react-dom/index.js
|
|
253
|
-
var require_react_dom = __commonJS({
|
|
254
|
-
"../../../../node_modules/.pnpm/react-dom@19.2.0_react@19.2.0/node_modules/react-dom/index.js"(exports, module) {
|
|
255
|
-
if (false) {
|
|
256
|
-
checkDCE();
|
|
257
|
-
module.exports = null;
|
|
258
|
-
} else {
|
|
259
|
-
module.exports = require_react_dom_development();
|
|
260
|
-
}
|
|
261
|
-
}
|
|
262
|
-
});
|
|
263
|
-
|
|
264
|
-
export {
|
|
265
|
-
require_react_dom
|
|
266
|
-
};
|
|
267
|
-
/*! Bundled license information:
|
|
268
|
-
|
|
269
|
-
react-dom/cjs/react-dom.development.js:
|
|
270
|
-
(**
|
|
271
|
-
* @license React
|
|
272
|
-
* react-dom.development.js
|
|
273
|
-
*
|
|
274
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
275
|
-
*
|
|
276
|
-
* This source code is licensed under the MIT license found in the
|
|
277
|
-
* LICENSE file in the root directory of this source tree.
|
|
278
|
-
*)
|
|
279
|
-
*/
|
|
280
|
-
//# sourceMappingURL=chunk-METQ356G.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../../../../../../node_modules/.pnpm/react-dom@19.2.0_react@19.2.0/node_modules/react-dom/cjs/react-dom.development.js", "../../../../../../../node_modules/.pnpm/react-dom@19.2.0_react@19.2.0/node_modules/react-dom/index.js"],
|
|
4
|
-
"sourcesContent": ["/**\n * @license React\n * react-dom.development.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\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function noop() {}\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function createPortal$1(children, containerInfo, implementation) {\n var key =\n 3 < arguments.length && void 0 !== arguments[3] ? arguments[3] : null;\n try {\n testStringCoercion(key);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n JSCompiler_inline_result &&\n (console.error(\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n key[Symbol.toStringTag]) ||\n key.constructor.name ||\n \"Object\"\n ),\n testStringCoercion(key));\n return {\n $$typeof: REACT_PORTAL_TYPE,\n key: null == key ? null : \"\" + key,\n children: children,\n containerInfo: containerInfo,\n implementation: implementation\n };\n }\n function getCrossOriginStringAs(as, input) {\n if (\"font\" === as) return \"\";\n if (\"string\" === typeof input)\n return \"use-credentials\" === input ? input : \"\";\n }\n function getValueDescriptorExpectingObjectForWarning(thing) {\n return null === thing\n ? \"`null`\"\n : void 0 === thing\n ? \"`undefined`\"\n : \"\" === thing\n ? \"an empty string\"\n : 'something with type \"' + typeof thing + '\"';\n }\n function getValueDescriptorExpectingEnumForWarning(thing) {\n return null === thing\n ? \"`null`\"\n : void 0 === thing\n ? \"`undefined`\"\n : \"\" === thing\n ? \"an empty string\"\n : \"string\" === typeof thing\n ? JSON.stringify(thing)\n : \"number\" === typeof thing\n ? \"`\" + thing + \"`\"\n : 'something with type \"' + typeof thing + '\"';\n }\n function resolveDispatcher() {\n var dispatcher = ReactSharedInternals.H;\n null === dispatcher &&\n console.error(\n \"Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\\n1. You might have mismatching versions of React and the renderer (such as React DOM)\\n2. You might be breaking the Rules of Hooks\\n3. You might have more than one copy of React in the same app\\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.\"\n );\n return dispatcher;\n }\n \"undefined\" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&\n \"function\" ===\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart &&\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());\n var React = require(\"react\"),\n Internals = {\n d: {\n f: noop,\n r: function () {\n throw Error(\n \"Invalid form element. requestFormReset must be passed a form that was rendered by React.\"\n );\n },\n D: noop,\n C: noop,\n L: noop,\n m: noop,\n X: noop,\n S: noop,\n M: noop\n },\n p: 0,\n findDOMNode: null\n },\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;\n (\"function\" === typeof Map &&\n null != Map.prototype &&\n \"function\" === typeof Map.prototype.forEach &&\n \"function\" === typeof Set &&\n null != Set.prototype &&\n \"function\" === typeof Set.prototype.clear &&\n \"function\" === typeof Set.prototype.forEach) ||\n console.error(\n \"React depends on Map and Set built-in types. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills\"\n );\n exports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =\n Internals;\n exports.createPortal = function (children, container) {\n var key =\n 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : null;\n if (\n !container ||\n (1 !== container.nodeType &&\n 9 !== container.nodeType &&\n 11 !== container.nodeType)\n )\n throw Error(\"Target container is not a DOM element.\");\n return createPortal$1(children, container, null, key);\n };\n exports.flushSync = function (fn) {\n var previousTransition = ReactSharedInternals.T,\n previousUpdatePriority = Internals.p;\n try {\n if (((ReactSharedInternals.T = null), (Internals.p = 2), fn))\n return fn();\n } finally {\n (ReactSharedInternals.T = previousTransition),\n (Internals.p = previousUpdatePriority),\n Internals.d.f() &&\n console.error(\n \"flushSync was called from inside a lifecycle method. React cannot flush when React is already rendering. Consider moving this call to a scheduler task or micro task.\"\n );\n }\n };\n exports.preconnect = function (href, options) {\n \"string\" === typeof href && href\n ? null != options && \"object\" !== typeof options\n ? console.error(\n \"ReactDOM.preconnect(): Expected the `options` argument (second) to be an object but encountered %s instead. The only supported option at this time is `crossOrigin` which accepts a string.\",\n getValueDescriptorExpectingEnumForWarning(options)\n )\n : null != options &&\n \"string\" !== typeof options.crossOrigin &&\n console.error(\n \"ReactDOM.preconnect(): Expected the `crossOrigin` option (second argument) to be a string but encountered %s instead. Try removing this option or passing a string value instead.\",\n getValueDescriptorExpectingObjectForWarning(options.crossOrigin)\n )\n : console.error(\n \"ReactDOM.preconnect(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.\",\n getValueDescriptorExpectingObjectForWarning(href)\n );\n \"string\" === typeof href &&\n (options\n ? ((options = options.crossOrigin),\n (options =\n \"string\" === typeof options\n ? \"use-credentials\" === options\n ? options\n : \"\"\n : void 0))\n : (options = null),\n Internals.d.C(href, options));\n };\n exports.prefetchDNS = function (href) {\n if (\"string\" !== typeof href || !href)\n console.error(\n \"ReactDOM.prefetchDNS(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.\",\n getValueDescriptorExpectingObjectForWarning(href)\n );\n else if (1 < arguments.length) {\n var options = arguments[1];\n \"object\" === typeof options && options.hasOwnProperty(\"crossOrigin\")\n ? console.error(\n \"ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. It looks like the you are attempting to set a crossOrigin property for this DNS lookup hint. Browsers do not perform DNS queries using CORS and setting this attribute on the resource hint has no effect. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.\",\n getValueDescriptorExpectingEnumForWarning(options)\n )\n : console.error(\n \"ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.\",\n getValueDescriptorExpectingEnumForWarning(options)\n );\n }\n \"string\" === typeof href && Internals.d.D(href);\n };\n exports.preinit = function (href, options) {\n \"string\" === typeof href && href\n ? null == options || \"object\" !== typeof options\n ? console.error(\n \"ReactDOM.preinit(): Expected the `options` argument (second) to be an object with an `as` property describing the type of resource to be preinitialized but encountered %s instead.\",\n getValueDescriptorExpectingEnumForWarning(options)\n )\n : \"style\" !== options.as &&\n \"script\" !== options.as &&\n console.error(\n 'ReactDOM.preinit(): Expected the `as` property in the `options` argument (second) to contain a valid value describing the type of resource to be preinitialized but encountered %s instead. Valid values for `as` are \"style\" and \"script\".',\n getValueDescriptorExpectingEnumForWarning(options.as)\n )\n : console.error(\n \"ReactDOM.preinit(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.\",\n getValueDescriptorExpectingObjectForWarning(href)\n );\n if (\n \"string\" === typeof href &&\n options &&\n \"string\" === typeof options.as\n ) {\n var as = options.as,\n crossOrigin = getCrossOriginStringAs(as, options.crossOrigin),\n integrity =\n \"string\" === typeof options.integrity ? options.integrity : void 0,\n fetchPriority =\n \"string\" === typeof options.fetchPriority\n ? options.fetchPriority\n : void 0;\n \"style\" === as\n ? Internals.d.S(\n href,\n \"string\" === typeof options.precedence\n ? options.precedence\n : void 0,\n {\n crossOrigin: crossOrigin,\n integrity: integrity,\n fetchPriority: fetchPriority\n }\n )\n : \"script\" === as &&\n Internals.d.X(href, {\n crossOrigin: crossOrigin,\n integrity: integrity,\n fetchPriority: fetchPriority,\n nonce: \"string\" === typeof options.nonce ? options.nonce : void 0\n });\n }\n };\n exports.preinitModule = function (href, options) {\n var encountered = \"\";\n (\"string\" === typeof href && href) ||\n (encountered +=\n \" The `href` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(href) +\n \".\");\n void 0 !== options && \"object\" !== typeof options\n ? (encountered +=\n \" The `options` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options) +\n \".\")\n : options &&\n \"as\" in options &&\n \"script\" !== options.as &&\n (encountered +=\n \" The `as` option encountered was \" +\n getValueDescriptorExpectingEnumForWarning(options.as) +\n \".\");\n if (encountered)\n console.error(\n \"ReactDOM.preinitModule(): Expected up to two arguments, a non-empty `href` string and, optionally, an `options` object with a valid `as` property.%s\",\n encountered\n );\n else\n switch (\n ((encountered =\n options && \"string\" === typeof options.as ? options.as : \"script\"),\n encountered)\n ) {\n case \"script\":\n break;\n default:\n (encountered =\n getValueDescriptorExpectingEnumForWarning(encountered)),\n console.error(\n 'ReactDOM.preinitModule(): Currently the only supported \"as\" type for this function is \"script\" but received \"%s\" instead. This warning was generated for `href` \"%s\". In the future other module types will be supported, aligning with the import-attributes proposal. Learn more here: (https://github.com/tc39/proposal-import-attributes)',\n encountered,\n href\n );\n }\n if (\"string\" === typeof href)\n if (\"object\" === typeof options && null !== options) {\n if (null == options.as || \"script\" === options.as)\n (encountered = getCrossOriginStringAs(\n options.as,\n options.crossOrigin\n )),\n Internals.d.M(href, {\n crossOrigin: encountered,\n integrity:\n \"string\" === typeof options.integrity\n ? options.integrity\n : void 0,\n nonce:\n \"string\" === typeof options.nonce ? options.nonce : void 0\n });\n } else null == options && Internals.d.M(href);\n };\n exports.preload = function (href, options) {\n var encountered = \"\";\n (\"string\" === typeof href && href) ||\n (encountered +=\n \" The `href` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(href) +\n \".\");\n null == options || \"object\" !== typeof options\n ? (encountered +=\n \" The `options` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options) +\n \".\")\n : (\"string\" === typeof options.as && options.as) ||\n (encountered +=\n \" The `as` option encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options.as) +\n \".\");\n encountered &&\n console.error(\n 'ReactDOM.preload(): Expected two arguments, a non-empty `href` string and an `options` object with an `as` property valid for a `<link rel=\"preload\" as=\"...\" />` tag.%s',\n encountered\n );\n if (\n \"string\" === typeof href &&\n \"object\" === typeof options &&\n null !== options &&\n \"string\" === typeof options.as\n ) {\n encountered = options.as;\n var crossOrigin = getCrossOriginStringAs(\n encountered,\n options.crossOrigin\n );\n Internals.d.L(href, encountered, {\n crossOrigin: crossOrigin,\n integrity:\n \"string\" === typeof options.integrity ? options.integrity : void 0,\n nonce: \"string\" === typeof options.nonce ? options.nonce : void 0,\n type: \"string\" === typeof options.type ? options.type : void 0,\n fetchPriority:\n \"string\" === typeof options.fetchPriority\n ? options.fetchPriority\n : void 0,\n referrerPolicy:\n \"string\" === typeof options.referrerPolicy\n ? options.referrerPolicy\n : void 0,\n imageSrcSet:\n \"string\" === typeof options.imageSrcSet\n ? options.imageSrcSet\n : void 0,\n imageSizes:\n \"string\" === typeof options.imageSizes\n ? options.imageSizes\n : void 0,\n media: \"string\" === typeof options.media ? options.media : void 0\n });\n }\n };\n exports.preloadModule = function (href, options) {\n var encountered = \"\";\n (\"string\" === typeof href && href) ||\n (encountered +=\n \" The `href` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(href) +\n \".\");\n void 0 !== options && \"object\" !== typeof options\n ? (encountered +=\n \" The `options` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options) +\n \".\")\n : options &&\n \"as\" in options &&\n \"string\" !== typeof options.as &&\n (encountered +=\n \" The `as` option encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options.as) +\n \".\");\n encountered &&\n console.error(\n 'ReactDOM.preloadModule(): Expected two arguments, a non-empty `href` string and, optionally, an `options` object with an `as` property valid for a `<link rel=\"modulepreload\" as=\"...\" />` tag.%s',\n encountered\n );\n \"string\" === typeof href &&\n (options\n ? ((encountered = getCrossOriginStringAs(\n options.as,\n options.crossOrigin\n )),\n Internals.d.m(href, {\n as:\n \"string\" === typeof options.as && \"script\" !== options.as\n ? options.as\n : void 0,\n crossOrigin: encountered,\n integrity:\n \"string\" === typeof options.integrity\n ? options.integrity\n : void 0\n }))\n : Internals.d.m(href));\n };\n exports.requestFormReset = function (form) {\n Internals.d.r(form);\n };\n exports.unstable_batchedUpdates = function (fn, a) {\n return fn(a);\n };\n exports.useFormState = function (action, initialState, permalink) {\n return resolveDispatcher().useFormState(action, initialState, permalink);\n };\n exports.useFormStatus = function () {\n return resolveDispatcher().useHostTransitionStatus();\n };\n exports.version = \"19.2.0\";\n \"undefined\" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&\n \"function\" ===\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());\n })();\n", "'use strict';\n\nfunction checkDCE() {\n /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */\n if (\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined' ||\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE !== 'function'\n ) {\n return;\n }\n if (process.env.NODE_ENV !== 'production') {\n // This branch is unreachable because this function is only called\n // in production, but the condition is true only in development.\n // Therefore if the branch is still here, dead code elimination wasn't\n // properly applied.\n // Don't change the message. React DevTools relies on it. Also make sure\n // this message doesn't occur elsewhere in this function, or it will cause\n // a false positive.\n throw new Error('^_^');\n }\n try {\n // Verify that the code above has been dead code eliminated (DCE'd).\n __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE);\n } catch (err) {\n // DevTools shouldn't crash React, no matter what.\n // We should still report in case we break this code.\n console.error(err);\n }\n}\n\nif (process.env.NODE_ENV === 'production') {\n // DCE check should happen before ReactDOM bundle executes so that\n // DevTools can report bad minification during injection.\n checkDCE();\n module.exports = require('./cjs/react-dom.production.js');\n} else {\n module.exports = require('./cjs/react-dom.development.js');\n}\n"],
|
|
5
|
-
"mappings": ";;;;;;;;AAAA;AAAA;AAAA;AAWA,KACG,WAAY;AACX,eAAS,OAAO;AAAA,MAAC;AACjB,eAAS,mBAAmB,OAAO;AACjC,eAAO,KAAK;AAAA,MACd;AACA,eAAS,eAAe,UAAU,eAAe,gBAAgB;AAC/D,YAAI,MACF,IAAI,UAAU,UAAU,WAAW,UAAU,CAAC,IAAI,UAAU,CAAC,IAAI;AACnE,YAAI;AACF,6BAAmB,GAAG;AACtB,cAAI,2BAA2B;AAAA,QACjC,SAAS,GAAG;AACV,qCAA2B;AAAA,QAC7B;AACA,qCACG,QAAQ;AAAA,UACP;AAAA,UACC,eAAe,OAAO,UACrB,OAAO,eACP,IAAI,OAA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;AAAA,UACR,QAAQ;AAAA,QACV,GACA,UAAU,EAAE,EAAE,MAAM;AAAA,UAClB,IACE,aAAa,OAAO,QAAQ,MAAM,aAAa,QAAQ,KACnD,QAAQ,KACR;AAAA,UACN,aAAa;AAAA,UACb,WACE,aAAa,OAAO,QAAQ,YACxB,QAAQ,YACR;AAAA,QACR,CAAC,KACD,UAAU,EAAE,EAAE,IAAI;AAAA,MAC1B;AACA,cAAQ,mBAAmB,SAAU,MAAM;AACzC,kBAAU,EAAE,EAAE,IAAI;AAAA,MACpB;AACA,cAAQ,0BAA0B,SAAU,IAAI,GAAG;AACjD,eAAO,GAAG,CAAC;AAAA,MACb;AACA,cAAQ,eAAe,SAAU,QAAQ,cAAc,WAAW;AAChE,eAAO,kBAAkB,EAAE,aAAa,QAAQ,cAAc,SAAS;AAAA,MACzE;AACA,cAAQ,gBAAgB,WAAY;AAClC,eAAO,kBAAkB,EAAE,wBAAwB;AAAA,MACrD;AACA,cAAQ,UAAU;AAClB,sBAAgB,OAAO,kCACrB,eACE,OAAO,+BAA+B,8BACxC,+BAA+B,2BAA2B,MAAM,CAAC;AAAA,IACrE,GAAG;AAAA;AAAA;;;ACvaL;AAAA;AA8BA,QAAI,OAAuC;AAGzC,eAAS;AACT,aAAO,UAAU;AAAA,IACnB,OAAO;AACL,aAAO,UAAU;AAAA,IACnB;AAAA;AAAA;",
|
|
6
|
-
"names": []
|
|
7
|
-
}
|
|
@@ -1,171 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
useLayoutEffect2
|
|
3
|
-
} from "./chunk-MDNXVKSA.js";
|
|
4
|
-
import {
|
|
5
|
-
useComposedRefs
|
|
6
|
-
} from "./chunk-E44IQKDY.js";
|
|
7
|
-
import {
|
|
8
|
-
require_react
|
|
9
|
-
} from "./chunk-6G72RLJL.js";
|
|
10
|
-
import {
|
|
11
|
-
__toESM
|
|
12
|
-
} from "./chunk-G3PMV62Z.js";
|
|
13
|
-
|
|
14
|
-
// ../../../../node_modules/.pnpm/@radix-ui+react-id@1.1.1_@types+react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-id/dist/index.mjs
|
|
15
|
-
var React = __toESM(require_react(), 1);
|
|
16
|
-
var useReactId = React[" useId ".trim().toString()] || (() => void 0);
|
|
17
|
-
var count = 0;
|
|
18
|
-
function useId(deterministicId) {
|
|
19
|
-
const [id, setId] = React.useState(useReactId());
|
|
20
|
-
useLayoutEffect2(() => {
|
|
21
|
-
if (!deterministicId) setId((reactId) => reactId ?? String(count++));
|
|
22
|
-
}, [deterministicId]);
|
|
23
|
-
return deterministicId || (id ? `radix-${id}` : "");
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
// ../../../../node_modules/.pnpm/@radix-ui+react-presence@1.1.5_@types+react-dom@19.2.3_@types+react@19.2.6__@types+react@19.2_rii4oxcboqou5jdzqabmnzdadm/node_modules/@radix-ui/react-presence/dist/index.mjs
|
|
27
|
-
var React2 = __toESM(require_react(), 1);
|
|
28
|
-
var React3 = __toESM(require_react(), 1);
|
|
29
|
-
function useStateMachine(initialState, machine) {
|
|
30
|
-
return React3.useReducer((state, event) => {
|
|
31
|
-
const nextState = machine[state][event];
|
|
32
|
-
return nextState ?? state;
|
|
33
|
-
}, initialState);
|
|
34
|
-
}
|
|
35
|
-
var Presence = (props) => {
|
|
36
|
-
const { present, children } = props;
|
|
37
|
-
const presence = usePresence(present);
|
|
38
|
-
const child = typeof children === "function" ? children({ present: presence.isPresent }) : React2.Children.only(children);
|
|
39
|
-
const ref = useComposedRefs(presence.ref, getElementRef(child));
|
|
40
|
-
const forceMount = typeof children === "function";
|
|
41
|
-
return forceMount || presence.isPresent ? React2.cloneElement(child, { ref }) : null;
|
|
42
|
-
};
|
|
43
|
-
Presence.displayName = "Presence";
|
|
44
|
-
function usePresence(present) {
|
|
45
|
-
const [node, setNode] = React2.useState();
|
|
46
|
-
const stylesRef = React2.useRef(null);
|
|
47
|
-
const prevPresentRef = React2.useRef(present);
|
|
48
|
-
const prevAnimationNameRef = React2.useRef("none");
|
|
49
|
-
const initialState = present ? "mounted" : "unmounted";
|
|
50
|
-
const [state, send] = useStateMachine(initialState, {
|
|
51
|
-
mounted: {
|
|
52
|
-
UNMOUNT: "unmounted",
|
|
53
|
-
ANIMATION_OUT: "unmountSuspended"
|
|
54
|
-
},
|
|
55
|
-
unmountSuspended: {
|
|
56
|
-
MOUNT: "mounted",
|
|
57
|
-
ANIMATION_END: "unmounted"
|
|
58
|
-
},
|
|
59
|
-
unmounted: {
|
|
60
|
-
MOUNT: "mounted"
|
|
61
|
-
}
|
|
62
|
-
});
|
|
63
|
-
React2.useEffect(() => {
|
|
64
|
-
const currentAnimationName = getAnimationName(stylesRef.current);
|
|
65
|
-
prevAnimationNameRef.current = state === "mounted" ? currentAnimationName : "none";
|
|
66
|
-
}, [state]);
|
|
67
|
-
useLayoutEffect2(() => {
|
|
68
|
-
const styles = stylesRef.current;
|
|
69
|
-
const wasPresent = prevPresentRef.current;
|
|
70
|
-
const hasPresentChanged = wasPresent !== present;
|
|
71
|
-
if (hasPresentChanged) {
|
|
72
|
-
const prevAnimationName = prevAnimationNameRef.current;
|
|
73
|
-
const currentAnimationName = getAnimationName(styles);
|
|
74
|
-
if (present) {
|
|
75
|
-
send("MOUNT");
|
|
76
|
-
} else if (currentAnimationName === "none" || (styles == null ? void 0 : styles.display) === "none") {
|
|
77
|
-
send("UNMOUNT");
|
|
78
|
-
} else {
|
|
79
|
-
const isAnimating = prevAnimationName !== currentAnimationName;
|
|
80
|
-
if (wasPresent && isAnimating) {
|
|
81
|
-
send("ANIMATION_OUT");
|
|
82
|
-
} else {
|
|
83
|
-
send("UNMOUNT");
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
prevPresentRef.current = present;
|
|
87
|
-
}
|
|
88
|
-
}, [present, send]);
|
|
89
|
-
useLayoutEffect2(() => {
|
|
90
|
-
if (node) {
|
|
91
|
-
let timeoutId;
|
|
92
|
-
const ownerWindow = node.ownerDocument.defaultView ?? window;
|
|
93
|
-
const handleAnimationEnd = (event) => {
|
|
94
|
-
const currentAnimationName = getAnimationName(stylesRef.current);
|
|
95
|
-
const isCurrentAnimation = currentAnimationName.includes(CSS.escape(event.animationName));
|
|
96
|
-
if (event.target === node && isCurrentAnimation) {
|
|
97
|
-
send("ANIMATION_END");
|
|
98
|
-
if (!prevPresentRef.current) {
|
|
99
|
-
const currentFillMode = node.style.animationFillMode;
|
|
100
|
-
node.style.animationFillMode = "forwards";
|
|
101
|
-
timeoutId = ownerWindow.setTimeout(() => {
|
|
102
|
-
if (node.style.animationFillMode === "forwards") {
|
|
103
|
-
node.style.animationFillMode = currentFillMode;
|
|
104
|
-
}
|
|
105
|
-
});
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
};
|
|
109
|
-
const handleAnimationStart = (event) => {
|
|
110
|
-
if (event.target === node) {
|
|
111
|
-
prevAnimationNameRef.current = getAnimationName(stylesRef.current);
|
|
112
|
-
}
|
|
113
|
-
};
|
|
114
|
-
node.addEventListener("animationstart", handleAnimationStart);
|
|
115
|
-
node.addEventListener("animationcancel", handleAnimationEnd);
|
|
116
|
-
node.addEventListener("animationend", handleAnimationEnd);
|
|
117
|
-
return () => {
|
|
118
|
-
ownerWindow.clearTimeout(timeoutId);
|
|
119
|
-
node.removeEventListener("animationstart", handleAnimationStart);
|
|
120
|
-
node.removeEventListener("animationcancel", handleAnimationEnd);
|
|
121
|
-
node.removeEventListener("animationend", handleAnimationEnd);
|
|
122
|
-
};
|
|
123
|
-
} else {
|
|
124
|
-
send("ANIMATION_END");
|
|
125
|
-
}
|
|
126
|
-
}, [node, send]);
|
|
127
|
-
return {
|
|
128
|
-
isPresent: ["mounted", "unmountSuspended"].includes(state),
|
|
129
|
-
ref: React2.useCallback((node2) => {
|
|
130
|
-
stylesRef.current = node2 ? getComputedStyle(node2) : null;
|
|
131
|
-
setNode(node2);
|
|
132
|
-
}, [])
|
|
133
|
-
};
|
|
134
|
-
}
|
|
135
|
-
function getAnimationName(styles) {
|
|
136
|
-
return (styles == null ? void 0 : styles.animationName) || "none";
|
|
137
|
-
}
|
|
138
|
-
function getElementRef(element) {
|
|
139
|
-
var _a, _b;
|
|
140
|
-
let getter = (_a = Object.getOwnPropertyDescriptor(element.props, "ref")) == null ? void 0 : _a.get;
|
|
141
|
-
let mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
|
|
142
|
-
if (mayWarn) {
|
|
143
|
-
return element.ref;
|
|
144
|
-
}
|
|
145
|
-
getter = (_b = Object.getOwnPropertyDescriptor(element, "ref")) == null ? void 0 : _b.get;
|
|
146
|
-
mayWarn = getter && "isReactWarning" in getter && getter.isReactWarning;
|
|
147
|
-
if (mayWarn) {
|
|
148
|
-
return element.props.ref;
|
|
149
|
-
}
|
|
150
|
-
return element.props.ref || element.ref;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
// ../../../../node_modules/.pnpm/@radix-ui+react-use-callback-ref@1.1.1_@types+react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs
|
|
154
|
-
var React4 = __toESM(require_react(), 1);
|
|
155
|
-
function useCallbackRef(callback) {
|
|
156
|
-
const callbackRef = React4.useRef(callback);
|
|
157
|
-
React4.useEffect(() => {
|
|
158
|
-
callbackRef.current = callback;
|
|
159
|
-
});
|
|
160
|
-
return React4.useMemo(() => (...args) => {
|
|
161
|
-
var _a;
|
|
162
|
-
return (_a = callbackRef.current) == null ? void 0 : _a.call(callbackRef, ...args);
|
|
163
|
-
}, []);
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
export {
|
|
167
|
-
useId,
|
|
168
|
-
useCallbackRef,
|
|
169
|
-
Presence
|
|
170
|
-
};
|
|
171
|
-
//# sourceMappingURL=chunk-NPTAWNEA.js.map
|