@yamada-ui/react
Version:
React UI components of the Yamada, by the Yamada, for the Yamada built with React and Emotion
1 lines • 1.58 kB
Source Map (JSON)
{"version":3,"file":"scroll-area.cjs","names":["createComponent","scrollAreaStyle","useScrollArea","styled"],"sources":["../../../../src/components/scroll-area/scroll-area.tsx"],"sourcesContent":["\"use client\"\n\nimport type { HTMLStyledProps, ThemeProps } from \"../../core\"\nimport type { ScrollAreaStyle } from \"./scroll-area.style\"\nimport type { UseScrollAreaProps } from \"./use-scroll-area\"\nimport { createComponent, styled } from \"../../core\"\nimport { scrollAreaStyle } from \"./scroll-area.style\"\nimport { useScrollArea } from \"./use-scroll-area\"\n\nexport interface ScrollAreaProps\n extends HTMLStyledProps,\n ThemeProps<ScrollAreaStyle>,\n UseScrollAreaProps {}\n\nconst {\n PropsContext: ScrollAreaPropsContext,\n usePropsContext: useScrollAreaPropsContext,\n withContext,\n} = createComponent<ScrollAreaProps, ScrollAreaStyle>(\n \"scroll-area\",\n scrollAreaStyle,\n)\n\nexport { ScrollAreaPropsContext, useScrollAreaPropsContext }\n\n/**\n * `ScrollArea` is a component that displays a customized scrollbar.\n *\n * @see https://yamada-ui.com/docs/components/scroll-area\n */\nexport const ScrollArea = withContext<\"div\", ScrollAreaProps>(\n ({ children, ...rest }) => {\n const { getRootProps } = useScrollArea(rest)\n\n return <styled.div {...getRootProps()}>{children}</styled.div>\n },\n)()\n"],"mappings":";;;;;;;;;;;;AAcA,MAAM,EACJ,cAAc,wBACd,iBAAiB,2BACjB,gBACEA,yCACF,eACAC,0CACD;;;;;;AASD,MAAa,aAAa,aACvB,EAAE,SAAU,GAAG,WAAW;CACzB,MAAM,EAAE,iBAAiBC,sCAAc,KAAK;AAE5C,QAAO,2CAACC,uBAAO;EAAI,GAAI,cAAc;EAAG;GAAsB;EAEjE,EAAE"}