@websy/websy-designs 1.2.13 → 1.2.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -392,10 +392,11 @@ class WebsyDatePicker {
392
392
  this.validDates = []
393
393
  this.validYears = []
394
394
  this.validHours = []
395
- this.customRangeSelected = true
395
+ this.customRangeSelected = true
396
396
  this.shiftPressed = false
397
397
  const DEFAULTS = {
398
398
  defaultRange: 0,
399
+ dateFormat: '%_m/%_d/%Y',
399
400
  allowClear: true,
400
401
  hideRanges: false,
401
402
  minAllowedDate: this.floorDate(new Date(new Date((new Date().setFullYear(new Date().getFullYear() - 1))).setDate(1))),
@@ -594,10 +595,10 @@ class WebsyDatePicker {
594
595
  this.updateRange()
595
596
  }
596
597
  else {
597
- this.selectedRangeDates = [...this.priorSelectedDates]
598
+ this.selectedRangeDates = [...(this.priorSelectedDates || [])]
598
599
  this.selectedRange = this.priorSelectedRange
599
600
  this.customRangeSelected = this.priorCustomRangeSelected
600
- this.currentselection = [...this.priorselection]
601
+ this.currentselection = [...(this.priorselection || [])]
601
602
  this.highlightRange()
602
603
  }
603
604
  }
@@ -495,6 +495,7 @@ var WebsyDatePicker = /*#__PURE__*/function () {
495
495
  this.shiftPressed = false;
496
496
  var DEFAULTS = {
497
497
  defaultRange: 0,
498
+ dateFormat: '%_m/%_d/%Y',
498
499
  allowClear: true,
499
500
  hideRanges: false,
500
501
  minAllowedDate: this.floorDate(new Date(new Date(new Date().setFullYear(new Date().getFullYear() - 1)).setDate(1))),
@@ -664,10 +665,10 @@ var WebsyDatePicker = /*#__PURE__*/function () {
664
665
 
665
666
  this.updateRange();
666
667
  } else {
667
- this.selectedRangeDates = _toConsumableArray(this.priorSelectedDates);
668
+ this.selectedRangeDates = _toConsumableArray(this.priorSelectedDates || []);
668
669
  this.selectedRange = this.priorSelectedRange;
669
670
  this.customRangeSelected = this.priorCustomRangeSelected;
670
- this.currentselection = _toConsumableArray(this.priorselection);
671
+ this.currentselection = _toConsumableArray(this.priorselection || []);
671
672
  this.highlightRange();
672
673
  }
673
674
  }