calendar.js 858 B

12345678910111213141516171819202122232425262728
  1. 'use strict';
  2. Object.defineProperty(exports, '__esModule', { value: true });
  3. require('../../../utils/index.js');
  4. require('../../../constants/index.js');
  5. var shared = require('@vue/shared');
  6. var runtime = require('../../../utils/vue/props/runtime.js');
  7. var event = require('../../../constants/event.js');
  8. const isValidRange = (range) => shared.isArray(range) && range.length === 2 && range.every((item) => shared.isDate(item));
  9. const calendarProps = runtime.buildProps({
  10. modelValue: {
  11. type: Date
  12. },
  13. range: {
  14. type: runtime.definePropType(Array),
  15. validator: isValidRange
  16. }
  17. });
  18. const calendarEmits = {
  19. [event.UPDATE_MODEL_EVENT]: (value) => shared.isDate(value),
  20. [event.INPUT_EVENT]: (value) => shared.isDate(value)
  21. };
  22. exports.calendarEmits = calendarEmits;
  23. exports.calendarProps = calendarProps;
  24. //# sourceMappingURL=calendar.js.map