UNPKG

wix-style-react

Version:
18 lines 742 B
import React from 'react'; import PropTypes from 'prop-types'; import { st, classes } from './Affix.st.css'; import InputConsumer from '../InputConsumer'; const Affix = ({ children, value }) => (React.createElement(InputConsumer, { consumerCompName: Affix.displayName }, ({ size, inPrefix, inSuffix, border, disabled, onInputClicked }) => (React.createElement("div", { className: st(classes.root, { size, inPrefix, inSuffix, border, disabled, }), onClick: onInputClicked, "data-hook": "custom-affix" }, value || children)))); Affix.displayName = 'Input.Affix'; Affix.propTypes = { children: PropTypes.node, value: PropTypes.string, }; export default Affix; //# sourceMappingURL=Affix.js.map