@flatbiz/antd
Version:
24 lines (20 loc) • 946 B
JavaScript
/*! @flatjs/forge MIT @flatbiz/antd */
import { b as _objectSpread2 } from './_rollupPluginBabelHelpers-BYm17lo8.js';
import { InputNumber } from 'antd';
import { isUndefinedOrNull, flatbizPrice } from '@flatbiz/utils';
import { jsx } from 'react/jsx-runtime';
var AmountFenInput = function AmountFenInput(props) {
var value = isUndefinedOrNull(props.value) ? undefined : flatbizPrice.fen2yuan(props.value);
return /*#__PURE__*/jsx(InputNumber, _objectSpread2(_objectSpread2({}, props), {}, {
style: _objectSpread2({
width: '100%'
}, props.style),
value: value,
onChange: function onChange(value) {
var _props$onChange;
(_props$onChange = props.onChange) === null || _props$onChange === void 0 || _props$onChange.call(props, isUndefinedOrNull(value) ? undefined : Number(flatbizPrice.yuan2fen(value)));
}
}));
};
export { AmountFenInput as A };
//# sourceMappingURL=amount-fen-input-yhjQwtSI.js.map