UNPKG

@coreui/react

Version:

UI Components Library for React.js

21 lines (18 loc) 899 B
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'; import { CFormLabel } from './CFormLabel.js'; var CFormRange = forwardRef(function (_a, ref) { var className = _a.className, label = _a.label, rest = __rest(_a, ["className", "label"]); return (React.createElement(React.Fragment, null, label && React.createElement(CFormLabel, { htmlFor: rest.id }, label), React.createElement("input", __assign({ type: "range", className: classNames('form-range', className) }, rest, { ref: ref })))); }); CFormRange.propTypes = { className: PropTypes.string, label: PropTypes.oneOfType([PropTypes.node, PropTypes.string]), }; CFormRange.displayName = 'CFormRange'; export { CFormRange }; //# sourceMappingURL=CFormRange.js.map