UNPKG

koval-ui

Version:

React components collection with minimalistic design. Supports theming, layout, and input validation.

1 lines 1.59 kB
{"version":3,"file":"Sidebar.cjs","sources":["../../../../src/lib/Layout/Sidebar.tsx"],"sourcesContent":["import {forwardRef} from 'react';\nimport type {ReactNode} from 'react';\nimport classNames from 'classnames';\n\nimport type {DataAttributes, LibraryProps} from '@/internal/LibraryAPI';\nimport type {SizesConfig} from '@/lib/Layout/SizeTypes.tsx';\n\nimport {Col} from './Col.tsx';\nimport classes from './Layout.module.css';\n\nexport type Props = DataAttributes &\n LibraryProps &\n Partial<SizesConfig> & {\n children?: ReactNode;\n };\n\nexport const Sidebar = forwardRef<HTMLDivElement, Props>(\n ({children, className, xs, sm, md, lg, xl, ...restProps}, ref) => {\n return (\n <Col\n {...restProps}\n as=\"aside\"\n xs={xs}\n sm={sm}\n md={md}\n lg={lg}\n xl={xl}\n ref={ref}\n className={classNames(classes.aside, className)}>\n {children}\n </Col>\n );\n }\n);\n\nSidebar.displayName = 'Sidebar';\n"],"names":["Sidebar","forwardRef","children","className","xs","sm","md","lg","xl","restProps","ref","jsx","Col","classNames","classes"],"mappings":"yOAgBaA,EAAUC,EAAA,WACnB,CAAC,CAAC,SAAAC,EAAU,UAAAC,EAAW,GAAAC,EAAI,GAAAC,EAAI,GAAAC,EAAI,GAAAC,EAAI,GAAAC,EAAI,GAAGC,CAAS,EAAGC,IAElDC,EAAA,IAACC,EAAA,IAAA,CACI,GAAGH,EACJ,GAAG,QACH,GAAAL,EACA,GAAAC,EACA,GAAAC,EACA,GAAAC,EACA,GAAAC,EACA,IAAAE,EACA,UAAWG,EAAWC,UAAQ,MAAOX,CAAS,EAC7C,SAAAD,CAAA,CACL,CAGZ,EAEAF,EAAQ,YAAc"}