UNPKG

@ark-ui/solid

Version:

A collection of unstyled, accessible UI components for Solid, utilizing state machines for seamless interaction.

31 lines (27 loc) 998 B
import { Accessor, JSX } from 'solid-js'; type RootNode = ShadowRoot | Document | Node; interface UseEnvironmentContext { /** * The root node of the application. * This is used to determine the window and document objects. * @default document */ getRootNode(): RootNode; /** * The document context for the root node. * @default document */ getDocument(): Document; /** * The window context for the root node. * @default window */ getWindow(): Window & typeof globalThis; } declare const useEnvironmentContext: () => Accessor<UseEnvironmentContext>; interface EnvironmentProviderProps { children?: JSX.Element; value?: RootNode | (() => RootNode); } declare const EnvironmentProvider: (props: EnvironmentProviderProps) => JSX.Element; export { type UseEnvironmentContext as EnvironmentContext, EnvironmentProvider, type EnvironmentProviderProps, type RootNode, type UseEnvironmentContext, useEnvironmentContext };