warnUtil.js 490 B

12345678910
  1. import warning from "rc-util/es/warning";
  2. export function legacyPropsWarning(props) {
  3. var picker = props.picker,
  4. disabledHours = props.disabledHours,
  5. disabledMinutes = props.disabledMinutes,
  6. disabledSeconds = props.disabledSeconds;
  7. if (picker === 'time' && (disabledHours || disabledMinutes || disabledSeconds)) {
  8. warning(false, "'disabledHours', 'disabledMinutes', 'disabledSeconds' will be removed in the next major version, please use 'disabledTime' instead.");
  9. }
  10. }