@coreui/react-pro
Version:
UI Components Library for React.js
33 lines (30 loc) • 1.2 kB
JavaScript
import { __rest, __assign } from '../../node_modules/tslib/tslib.es6.js';
import React, { forwardRef } from 'react';
import PropTypes from 'prop-types';
import classNames from '../../_virtual/index.js';
var CListGroup = forwardRef(function (_a, ref) {
var _b;
var children = _a.children, _c = _a.as, Component = _c === void 0 ? 'ul' : _c, className = _a.className, flush = _a.flush, layout = _a.layout, rest = __rest(_a, ["children", "as", "className", "flush", "layout"]);
return (React.createElement(Component, __assign({ className: classNames('list-group', (_b = {
'list-group-flush': flush
},
_b["list-group-".concat(layout)] = layout,
_b), 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