UNPKG

@coreui/react-pro

Version:

UI Components Library for React.js

31 lines (28 loc) 1.07 kB
import { __rest } from '../../node_modules/tslib/tslib.es6.js'; import React, { forwardRef } from 'react'; import PropTypes from 'prop-types'; import classNames from '../../_virtual/index.js'; const CListGroup = forwardRef((_a, ref) => { var { children, as: Component = 'ul', className, flush, layout } = _a, rest = __rest(_a, ["children", "as", "className", "flush", "layout"]); return (React.createElement(Component, Object.assign({ className: classNames('list-group', { 'list-group-flush': flush, [`list-group-${layout}`]: layout, }, className) }, rest, { ref: ref }), children)); }); CListGroup.propTypes = { as: PropTypes.elementType, children: PropTypes.node, className: PropTypes.string, flush: PropTypes.bool, layout: PropTypes.oneOf([ 'horizontal', 'horizontal-sm', 'horizontal-md', 'horizontal-lg', 'horizontal-xl', 'horizontal-xxl', ]), }; CListGroup.displayName = 'CListGroup'; export { CListGroup }; //# sourceMappingURL=CListGroup.js.map