Download chakra-ui/packages/react/src/components/empty-state/empty-state.ts from Devendra174/react-code-dataset: direct link, hf CLI and curl.
- Browser
- Download file 2.09 kB
-
https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/f5071caa249115f3b590492f1c8eb471e02aae4b/chakra-ui/packages/react/src/components/empty-state/empty-state.ts
- Command line
-
hf download hf://datasets/Devendra174/react-code-dataset@f5071caa249115f3b590492f1c8eb471e02aae4b/chakra-ui/packages/react/src/components/empty-state/empty-state.ts
-
curl -L -o empty-state.ts https://huggingface.co/datasets/Devendra174/react-code-dataset/resolve/f5071caa249115f3b590492f1c8eb471e02aae4b/chakra-ui/packages/react/src/components/empty-state/empty-state.ts
2.09 kB
| "use client" | |
| import { | |
| type HTMLChakraProps, | |
| type SlotRecipeProps, | |
| type UnstyledProp, | |
| createSlotRecipeContext, | |
| } from "../../styled-system" | |
| //////////////////////////////////////////////////////////////////////////////////// | |
| const { | |
| withProvider, | |
| withContext, | |
| useStyles: useEmptyStateStyles, | |
| PropsProvider, | |
| } = createSlotRecipeContext({ key: "emptyState" }) | |
| export { useEmptyStateStyles } | |
| //////////////////////////////////////////////////////////////////////////////////// | |
| export interface EmptyStateRootBaseProps | |
| extends SlotRecipeProps<"emptyState">, | |
| UnstyledProp {} | |
| export interface EmptyStateRootProps | |
| extends HTMLChakraProps<"div", EmptyStateRootBaseProps> {} | |
| export const EmptyStateRoot = withProvider<HTMLDivElement, EmptyStateRootProps>( | |
| "div", | |
| "root", | |
| ) | |
| //////////////////////////////////////////////////////////////////////////////////// | |
| export const EmptyStatePropsProvider = | |
| PropsProvider as React.Provider<EmptyStateRootBaseProps> | |
| //////////////////////////////////////////////////////////////////////////////////// | |
| export interface EmptyStateContentProps extends HTMLChakraProps<"div"> {} | |
| export const EmptyStateContent = withContext< | |
| HTMLDivElement, | |
| EmptyStateContentProps | |
| >("div", "content") | |
| //////////////////////////////////////////////////////////////////////////////////// | |
| export interface EmptyStateIndicatorProps extends HTMLChakraProps<"div"> {} | |
| export const EmptyStateIndicator = withContext< | |
| HTMLDivElement, | |
| EmptyStateIndicatorProps | |
| >("div", "indicator") | |
| //////////////////////////////////////////////////////////////////////////////////// | |
| export interface EmptyStateTitleProps extends HTMLChakraProps<"h3"> {} | |
| export const EmptyStateTitle = withContext< | |
| HTMLHeadingElement, | |
| EmptyStateTitleProps | |
| >("h3", "title") | |
| //////////////////////////////////////////////////////////////////////////////////// | |
| export interface EmptyStateDescriptionProps extends HTMLChakraProps<"p"> {} | |
| export const EmptyStateDescription = withContext< | |
| HTMLParagraphElement, | |
| EmptyStateDescriptionProps | |
| >("p", "description") | |