{"version":3,"file":"vue-datepicker.umd.cjs","sources":["../src/locale/translations/en.js","../src/locale/Language.js","../src/utils/calendarSlots.js","../src/utils/DateUtils.js","../src/mixins/inputProps.vue","../src/components/DateInput.vue","../src/utils/cellUtils.js","../src/utils/DisabledDate.js","../src/mixins/navMixin.vue","../src/components/PickerHeader.vue","../src/mixins/pickerMixin.vue","../src/utils/HighlightedDate.js","../src/components/PickerCells.vue","../src/components/PickerDay.vue","../src/components/PickerMonth.vue","../src/components/PickerYear.vue","../src/components/Popup.vue","../src/components/DatePicker.vue","../src/utils/dom.js"],"sourcesContent":["import Language from '../Language'\n\nexport default new Language(\n  'English',\n  [\n    'January',\n    'February',\n    'March',\n    'April',\n    'May',\n    'June',\n    'July',\n    'August',\n    'September',\n    'October',\n    'November',\n    'December',\n  ],\n  [\n    'Jan',\n    'Feb',\n    'Mar',\n    'Apr',\n    'May',\n    'Jun',\n    'Jul',\n    'Aug',\n    'Sep',\n    'Oct',\n    'Nov',\n    'Dec',\n  ],\n  ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],\n)\n","export default class Language {\n  // eslint-disable-next-line max-params\n  constructor(\n    language,\n    months,\n    monthsAbbr,\n    days,\n    rtl = false,\n    ymd = false,\n    yearSuffix = '',\n  ) {\n    this.language = language\n    this.months = months\n    this.monthsAbbr = monthsAbbr\n    this.days = days\n    this.rtl = rtl\n    this.ymd = ymd\n    this.yearSuffix = yearSuffix\n  }\n\n  /* eslint-disable no-underscore-dangle */\n  get language() {\n    return this._language\n  }\n\n  set language(language) {\n    if (typeof language !== 'string') {\n      throw new TypeError('Language must be a string')\n    }\n    this._language = language\n  }\n\n  get months() {\n    return this._months\n  }\n\n  set months(months) {\n    if (months.length !== 12) {\n      throw new RangeError(\n        `There must be 12 months for ${this.language} language`,\n      )\n    }\n    this._months = months\n  }\n\n  get monthsAbbr() {\n    return this._monthsAbbr\n  }\n\n  set monthsAbbr(monthsAbbr) {\n    if (monthsAbbr.length !== 12) {\n      throw new RangeError(\n        `There must be 12 abbreviated months for ${this.language} language`,\n      )\n    }\n    this._monthsAbbr = monthsAbbr\n  }\n\n  get days() {\n    return this._days\n  }\n\n  set days(days) {\n    if (days.length !== 7) {\n      throw new RangeError(`There must be 7 days for ${this.language} language`)\n    }\n    this._days = days\n  }\n\n  getDaysStartingOn(firstDayOfWeek) {\n    const firstDays = this._days.slice(firstDayOfWeek)\n    const lastDays = this._days.slice(0, firstDayOfWeek)\n\n    return firstDays.concat(lastDays)\n  }\n\n  getMonthByAbbrName(name) {\n    const monthValue = this._monthsAbbr.findIndex((month) => month === name) + 1\n    return monthValue < 10 ? `0${monthValue}` : `${monthValue}`\n  }\n\n  getMonthByName(name) {\n    const monthValue = this._months.findIndex((month) => month === name) + 1\n    return monthValue < 10 ? `0${monthValue}` : `${monthValue}`\n  }\n}\n","export default [\n  'beforeCalendarHeaderDay',\n  'calendarFooterDay',\n  'beforeCalendarHeaderMonth',\n  'calendarFooterMonth',\n  'beforeCalendarHeaderYear',\n  'calendarFooterYear',\n  'nextIntervalBtn',\n  'prevIntervalBtn',\n]\n","import en from '~/locale/translations/en'\n\n/**\n * Attempts to return a parseable date in the format 'yyyy-MM-dd'\n * @param {String} dateStr\n * @param {String} formatStr\n * @param {Object} translation\n * @param {Number} currentYear\n * @param {String} time\n * @return String\n */\n// eslint-disable-next-line complexity,max-statements\nconst getParsableDate = ({\n  dateStr,\n  formatStr,\n  translation,\n  currentYear,\n  time,\n}) => {\n  const splitter = formatStr.match(/-|\\/|\\s|\\./) || ['-']\n  const df = formatStr.split(splitter[0])\n  const ds = dateStr.split(splitter[0])\n  const ymd = [currentYear.toString(), '01', '01']\n\n  for (let i = 0; i < df.length; i += 1) {\n    if (/yyyy/i.test(df[i])) {\n      ymd[0] = ds[i]\n    } else if (/mmmm/i.test(df[i])) {\n      ymd[1] = translation.getMonthByName(ds[i])\n    } else if (/mmm/i.test(df[i])) {\n      ymd[1] = translation.getMonthByAbbrName(ds[i])\n    } else if (/mm/i.test(df[i])) {\n      ymd[1] = ds[i]\n    } else if (/m/i.test(df[i])) {\n      ymd[1] = ds[i]\n    } else if (/dd/i.test(df[i])) {\n      ymd[2] = ds[i]\n    } else if (/d/i.test(df[i])) {\n      const tmp = ds[i].replace(/st|rd|nd|th/g, '')\n      ymd[2] = tmp < 10 ? `0${tmp}` : `${tmp}`\n    }\n  }\n\n  return `${ymd.join('-')}${time}`\n}\n\n/**\n * Parses a date using a function passed in via the `parser` prop\n * @param  {String}   dateStr The string to parse\n * @param  {Function} format  The function that should be used to format the date\n * @param  {Function} parser  The function that should be used to parse the date\n * @return {Date | String}\n */\nfunction parseDateWithLibrary(dateStr, format, parser) {\n  if (typeof parser !== 'function') {\n    throw new Error('Parser needs to be a function')\n  }\n\n  if (typeof format !== 'function') {\n    throw new Error('Format needs to be a function when using a custom parser')\n  }\n\n  return parser(dateStr)\n}\n\nconst utils = {\n  /**\n   * @type {Boolean}\n   */\n  useUtc: false,\n\n  /**\n   * Returns the full year, using UTC or not\n   * @param {Date} date\n   */\n  getFullYear(date) {\n    return this.useUtc ? date.getUTCFullYear() : date.getFullYear()\n  },\n\n  /**\n   * Returns the month, using UTC or not\n   * @param {Date} date\n   */\n  getMonth(date) {\n    return this.useUtc ? date.getUTCMonth() : date.getMonth()\n  },\n\n  /**\n   * Returns the number of days in the month, using UTC or not\n   * @param {Date} date\n   */\n  getDaysInMonth(date) {\n    return this.daysInMonth(this.getFullYear(date), this.getMonth(date))\n  },\n\n  /**\n   * Returns the date, using UTC or not\n   * @param {Date} date\n   */\n  getDate(date) {\n    return this.useUtc ? date.getUTCDate() : date.getDate()\n  },\n\n  /**\n   * Returns the day, using UTC or not\n   * @param {Date} date\n   */\n  getDay(date) {\n    return this.useUtc ? date.getUTCDay() : date.getDay()\n  },\n\n  /**\n   * Returns the hours, using UTC or not\n   * @param {Date} date\n   */\n  getHours(date) {\n    return this.useUtc ? date.getUTCHours() : date.getHours()\n  },\n\n  /**\n   * Returns the minutes, using UTC or not\n   * @param {Date} date\n   */\n  getMinutes(date) {\n    return this.useUtc ? date.getUTCMinutes() : date.getMinutes()\n  },\n\n  /**\n   * Sets the full year, using UTC or not\n   * @param {Date} date\n   * @param {String, Number} value\n   */\n  setFullYear(date, value) {\n    return this.useUtc ? date.setUTCFullYear(value) : date.setFullYear(value)\n  },\n\n  /**\n   * Sets the month, using UTC or not\n   * @param {Date} date\n   * @param {String, Number} value\n   */\n  setMonth(date, value) {\n    return this.useUtc ? date.setUTCMonth(value) : date.setMonth(value)\n  },\n\n  /**\n   * Sets the date, using UTC or not\n   * @param {Date} date\n   * @param {String, Number} value\n   */\n  setDate(date, value) {\n    return this.useUtc ? date.setUTCDate(value) : date.setDate(value)\n  },\n\n  /**\n   * Check if date1 is equivalent to date2, without comparing the time\n   * @see https://stackoverflow.com/a/6202196/4455925\n   * @param {Date|null} date1\n   * @param {Date|null} date2\n   */\n  // eslint-disable-next-line complexity\n  compareDates(date1, date2) {\n    if (date1 === null && date2 === null) {\n      return true\n    }\n\n    if (\n      (date1 !== null && date2 === null) ||\n      (date2 !== null && date1 === null)\n    ) {\n      return false\n    }\n\n    const d1 = new Date(date1.valueOf())\n    const d2 = new Date(date2.valueOf())\n\n    this.resetDateTime(d1)\n    this.resetDateTime(d2)\n    return d1.valueOf() === d2.valueOf()\n  },\n\n  /**\n   * Validates a date object\n   * @param {Date} date - an object instantiated with the new Date constructor\n   * @return {Boolean}\n   */\n  isValidDate(date) {\n    if (Object.prototype.toString.call(date) !== '[object Date]') {\n      return false\n    }\n    return !Number.isNaN(date.valueOf())\n  },\n\n  /**\n   * Return abbreviated week day name\n   * @param {Date} date\n   * @param {Array} days\n   * @return {String}\n   */\n  getDayNameAbbr(date, days) {\n    if (typeof date !== 'object') {\n      throw TypeError('Invalid Type')\n    }\n    return days[this.getDay(date)]\n  },\n\n  /**\n   * Return day number from abbreviated week day name\n   * @param {String} abbr\n   * @return {Number}\n   */\n  getDayFromAbbr(abbr) {\n    for (let i = 0; i < en.days.length; i += 1) {\n      if (abbr.toLowerCase() === en.days[i].toLowerCase()) {\n        return i\n      }\n    }\n    throw TypeError('Invalid week day')\n  },\n\n  /**\n   * Return name of the month\n   * @param {Number|Date} month\n   * @param {Array} months\n   * @return {String}\n   */\n  getMonthName(month, months) {\n    if (!months) {\n      throw Error('missing 2nd parameter Months array')\n    }\n    if (typeof month === 'object') {\n      return months[this.getMonth(month)]\n    }\n    if (typeof month === 'number') {\n      return months[month]\n    }\n    throw TypeError('Invalid type')\n  },\n\n  /**\n   * Return an abbreviated version of the month\n   * @param {Number|Date} month\n   * @param {Array} monthsAbbr\n   * @return {String}\n   */\n  getMonthNameAbbr(month, monthsAbbr) {\n    if (!monthsAbbr) {\n      throw Error('missing 2nd parameter Months array')\n    }\n    if (typeof month === 'object') {\n      return monthsAbbr[this.getMonth(month)]\n    }\n    if (typeof month === 'number') {\n      return monthsAbbr[month]\n    }\n    throw TypeError('Invalid type')\n  },\n\n  /**\n   * Alternative get total number of days in month\n   * @param {Number} year\n   * @param {Number} month\n   * @return {Number}\n   */\n  // eslint-disable-next-line complexity\n  daysInMonth(year, month) {\n    if (/8|3|5|10/.test(month.toString())) {\n      return 30\n    }\n    if (month === 1) {\n      return (!(year % 4) && year % 100) || !(year % 400) ? 29 : 28\n    }\n    return 31\n  },\n\n  /**\n   * Get nth suffix for date\n   * @param {Number} day\n   * @return {String}\n   */\n  // eslint-disable-next-line complexity\n  getNthSuffix(day) {\n    switch (day) {\n      case 1:\n      case 21:\n      case 31:\n        return 'st'\n      case 2:\n      case 22:\n        return 'nd'\n      case 3:\n      case 23:\n        return 'rd'\n      default:\n        return 'th'\n    }\n  },\n\n  /**\n   * Formats date object\n   * @param {Date} date\n   * @param {String} formatStr\n   * @param {Object} translation\n   * @return {String}\n   */\n  formatDate(date, formatStr, translation = en) {\n    const year = this.getFullYear(date)\n    const month = this.getMonth(date) + 1\n    const day = this.getDate(date)\n\n    const matches = {\n      d: day,\n      dd: `0${day}`.slice(-2),\n      E: this.getDayNameAbbr(date, translation.days),\n      o: this.getNthSuffix(this.getDate(date)),\n      M: month,\n      MM: `0${month}`.slice(-2),\n      MMM: this.getMonthNameAbbr(this.getMonth(date), translation.monthsAbbr),\n      MMMM: this.getMonthName(this.getMonth(date), translation.months),\n      yy: String(year).slice(2),\n      yyyy: year,\n    }\n\n    const REGEX_FORMAT = /y{4}|y{2}|M{1,4}|d{1,2}|o|E/g\n\n    return formatStr.replace(REGEX_FORMAT, (match) => matches[match])\n  },\n\n  /**\n   * Parses a date from a string, or returns the original string\n   * @param {String}          dateStr\n   * @param {String|Function} format\n   * @param {Object}          translation\n   * @param {Function}        parser\n   * @return {Date | String}\n   */\n  // eslint-disable-next-line max-params\n  parseDate(dateStr, format, translation = en, parser = null) {\n    if (!(dateStr && format)) {\n      return dateStr\n    }\n\n    if (parser) {\n      return parseDateWithLibrary(dateStr, format, parser)\n    }\n\n    const parseableDate = getParsableDate({\n      dateStr,\n      formatStr: format,\n      translation,\n      currentYear: this.getFullYear(new Date()),\n      time: this.getTime(),\n    })\n    const parsedDate = Date.parse(parseableDate)\n\n    if (Number.isNaN(parsedDate)) {\n      return dateStr\n    }\n\n    return new Date(parsedDate)\n  },\n\n  /**\n   * Parses a string/number to a date, or returns null\n   * @param   {Date|String|Number|undefined} date\n   * @returns {Date|null}\n   */\n  parseAsDate(date) {\n    if (typeof date === 'string' || typeof date === 'number') {\n      const parsed = new Date(date)\n      return this.isValidDate(parsed) ? parsed : null\n    }\n    return this.isValidDate(date) ? date : null\n  },\n\n  getTime() {\n    const time = 'T00:00:00'\n\n    return this.useUtc ? `${time}Z` : time\n  },\n\n  /**\n   * Remove hours/minutes/seconds/milliseconds from a date object\n   * @param {Date} date\n   * @return {Date}\n   */\n  resetDateTime(date) {\n    return new Date(\n      this.useUtc ? date.setUTCHours(0, 0, 0, 0) : date.setHours(0, 0, 0, 0),\n    )\n  },\n\n  /**\n   * Return a new date object with hours/minutes/seconds/milliseconds removed.\n   * Defaults to today's date, if no parameter is provided\n   * @param {Date=} date\n   * @return {Date}\n   */\n  getNewDateObject(date) {\n    return date\n      ? this.resetDateTime(new Date(date))\n      : this.resetDateTime(new Date())\n  },\n\n  /**\n   * Returns the `open date` at a given view\n   * @param {Date|null} openDate   the date on which the datepicker should open\n   * @param {View} view   Either `day`, `month`, or `year`\n   * @return {Date|null}\n   */\n  getOpenDate(openDate, selectedDate, view) {\n    const parsedOpenDate = this.parseAsDate(openDate)\n    const openDateOrToday = this.getNewDateObject(parsedOpenDate)\n    const newOpenDate = selectedDate || openDateOrToday\n\n    return this.adjustDateToView(newOpenDate, view)\n  },\n\n  /**\n   * Converts a date according to a given view\n   * e.g. '2025-05-15' becomes '2025-05-01' at `month view and\n   * '2025-01-01' at `year` view\n   * @param  {Date}   dateToConvert  The date to convert\n   * @param  {String} view           The view for which to adjust the date\n   * @return {Date}\n   */\n  adjustDateToView(dateToConvert, view) {\n    const date = this.getNewDateObject(dateToConvert)\n\n    if (view === 'year') {\n      const resetDay = new Date(this.setDate(date, 1))\n      const resetMonth = this.setMonth(resetDay, 0)\n      return new Date(resetMonth)\n    }\n\n    if (view === 'month') {\n      return new Date(this.setDate(date, 1))\n    }\n\n    return date\n  },\n}\n\nexport default (useUtc) => ({\n  ...utils,\n  useUtc,\n})\n","<script>\nexport default {\n  props: {\n    autofocus: {\n      type: Boolean,\n      default: false,\n    },\n    bootstrapStyling: {\n      type: Boolean,\n      default: false,\n    },\n    clearButton: {\n      type: Boolean,\n      default: null,\n    },\n    calendarButton: {\n      type: Boolean,\n      default: false,\n    },\n    disabled: {\n      type: Boolean,\n      default: false,\n    },\n    format: {\n      type: [String, Function],\n      default: 'dd MMM yyyy',\n    },\n    id: {\n      type: String,\n      default: null,\n    },\n    inline: {\n      type: Boolean,\n      default: false,\n    },\n    inputClass: {\n      type: [String, Object, Array],\n      default: null,\n    },\n    maxlength: {\n      type: [Number, String],\n      default: null,\n    },\n    name: {\n      type: String,\n      default: null,\n    },\n    openDate: {\n      type: [String, Date, Number],\n      default: null,\n    },\n    parser: {\n      type: Function,\n      default: null,\n    },\n    pattern: {\n      type: String,\n      default: null,\n    },\n    placeholder: {\n      type: String,\n      default: null,\n    },\n    refName: {\n      type: String,\n      default: '',\n    },\n    required: {\n      type: Boolean,\n      default: false,\n    },\n    showCalendarOnButtonClick: {\n      type: Boolean,\n      default: false,\n    },\n    showCalendarOnFocus: {\n      type: Boolean,\n      default: false,\n    },\n    tabindex: {\n      type: [Number, String],\n      default: null,\n    },\n    typeable: {\n      type: Boolean,\n      default: false,\n    },\n    useUtc: {\n      type: Boolean,\n      default: false,\n    },\n  },\n}\n</script>\n","<template>\n  <div :class=\"{ 'input-group': bootstrapStyling }\">\n    <slot name=\"beforeDateInput\" />\n    <!-- Calendar Button -->\n    <button\n      v-if=\"calendarButton\"\n      ref=\"calendarButton\"\n      class=\"vdp-datepicker__calendar-button\"\n      :class=\"{ 'btn input-group-prepend': bootstrapStyling }\"\n      data-test-calendar-button\n      :disabled=\"disabled\"\n      type=\"button\"\n      @click=\"toggle('calendarButton')\"\n      @focus=\"handleButtonFocus\"\n    >\n      <span :class=\"{ 'input-group-text': bootstrapStyling }\">\n        <slot name=\"calendarBtn\">&hellip;</slot>\n      </span>\n    </button>\n    <!-- Input -->\n    <input\n      :id=\"id\"\n      :ref=\"refName\"\n      autocomplete=\"off\"\n      :autofocus=\"autofocus\"\n      :class=\"computedInputClass\"\n      :clear-button=\"clearButton\"\n      data-test-input\n      :disabled=\"disabled\"\n      :maxlength=\"maxlength\"\n      :name=\"name\"\n      :pattern=\"pattern\"\n      :placeholder=\"placeholder\"\n      :readonly=\"!typeable\"\n      :required=\"required\"\n      :tabindex=\"tabindex\"\n      :type=\"inline ? 'hidden' : null\"\n      :value=\"formattedValue\"\n      @blur=\"handleInputBlur\"\n      @click=\"handleInputClick\"\n      @focus=\"handleInputFocus\"\n      @keydown.delete=\"handleDelete\"\n      @keydown.down.prevent=\"handleKeydownDown\"\n      @keydown.enter.prevent=\"handleKeydownEnter\"\n      @keydown.esc.prevent=\"handleKeydownEscape\"\n      @keydown.space=\"handleKeydownSpace($event)\"\n      @keydown.tab=\"$emit('tab', $event)\"\n      @keyup=\"handleKeyup($event)\"\n      @keyup.space=\"handleKeyupSpace($event)\"\n    />\n    <!-- Clear Button -->\n    <button\n      v-if=\"clearButton && selectedDate\"\n      class=\"vdp-datepicker__clear-button\"\n      :class=\"{ 'btn input-group-append': bootstrapStyling }\"\n      data-test-clear-button\n      :disabled=\"disabled\"\n      type=\"button\"\n      @click=\"clearDate\"\n    >\n      <span :class=\"{ 'input-group-text': bootstrapStyling }\">\n        <slot name=\"clearBtn\">&times;</slot>\n      </span>\n    </button>\n    <slot name=\"afterDateInput\" />\n  </div>\n</template>\n\n<script>\nimport makeDateUtils from '~/utils/DateUtils'\nimport inputProps from '~/mixins/inputProps.vue'\n\nexport default {\n  name: 'DateInput',\n  mixins: [inputProps],\n  props: {\n    isOpen: {\n      type: Boolean,\n      default: false,\n    },\n    selectedDate: {\n      type: Date,\n      default: null,\n    },\n    slideDuration: {\n      type: Number,\n      default: 250,\n    },\n    translation: {\n      type: Object,\n      default() {\n        return {}\n      },\n    },\n  },\n  emits: {\n    blur: null,\n    clearDate: null,\n    close: null,\n    focus: null,\n    open: null,\n    selectTypedDate: (date) => {\n      return date === null || date instanceof Date\n    },\n    setFocus: (refArray) => {\n      return refArray.every((ref) => {\n        return [\n          'calendarButton',\n          'input',\n          'prev',\n          'up',\n          'next',\n          'tabbableCell',\n        ].includes(ref)\n      })\n    },\n    tab: null,\n    typedDate: (date) => {\n      return date === null || date instanceof Date\n    },\n  },\n  data() {\n    return {\n      input: null,\n      isInputFocused: false,\n      shouldToggleOnFocus: false,\n      shouldToggleOnClick: true,\n      typedDate: '',\n      utils: makeDateUtils(this.useUtc),\n    }\n  },\n  computed: {\n    computedInputClass() {\n      if (this.bootstrapStyling) {\n        if (typeof this.inputClass === 'string') {\n          return [this.inputClass, 'form-control'].join(' ')\n        }\n        return { 'form-control': true, ...this.inputClass }\n      }\n      return this.inputClass\n    },\n    formattedValue() {\n      if (this.typeable) {\n        return this.typedDate\n      }\n\n      return this.formatDate(this.selectedDate)\n    },\n  },\n  watch: {\n    showCalendarOnFocus: {\n      immediate: true,\n      handler(showCalendarOnFocus) {\n        if (showCalendarOnFocus) {\n          this.shouldToggleOnFocus = !this.isOpen\n        }\n      },\n    },\n    isOpen(isOpen, wasOpen) {\n      this.$nextTick(() => {\n        if (isOpen && this.showCalendarOnFocus) {\n          if (wasOpen && !this.isInputFocused) {\n            this.shouldToggleOnFocus = true\n            return\n          }\n          this.shouldToggleOnFocus = false\n        }\n      })\n    },\n    selectedDate: {\n      immediate: true,\n      handler(selectedDate) {\n        if (this.typeable) {\n          this.typedDate = this.formatDate(selectedDate)\n        }\n      },\n    },\n  },\n  mounted() {\n    this.input = this.$el.querySelector('input')\n  },\n  methods: {\n    /**\n     * Emits a `clear-date` event\n     */\n    clearDate() {\n      this.input.value = ''\n      this.$emit('clearDate')\n    },\n    /**\n     * Formats a date\n     * @param {Date} date The date to be formatted\n     * @returns {String}\n     */\n    formatDate(date) {\n      if (!date) {\n        return ''\n      }\n\n      return typeof this.format === 'function'\n        ? this.format(new Date(date))\n        : this.utils.formatDate(new Date(date), this.format, this.translation)\n    },\n    /**\n     * Formats a typed date, or clears it if invalid\n     */\n    formatTypedDate() {\n      const parsedDate = this.parseInput()\n\n      if (this.utils.isValidDate(parsedDate)) {\n        this.typedDate = this.formatDate(parsedDate)\n      } else {\n        this.input.value = ''\n        this.typedDate = ''\n      }\n    },\n    /**\n     * Validates typedDate\n     */\n    handleInputBlur() {\n      if (this.showCalendarOnFocus && !this.isOpen) {\n        this.shouldToggleOnFocus = true\n      }\n\n      if (this.typeable) {\n        this.formatTypedDate()\n      }\n      this.isInputFocused = false\n    },\n    /**\n     * Resets `shouldToggleOnFocus` to true\n     */\n    handleButtonFocus() {\n      if (this.showCalendarOnFocus) {\n        this.shouldToggleOnFocus = true\n      }\n    },\n    /**\n     * Clears the calendar when the `delete` or `backspace` key is pressed\n     */\n    handleDelete() {\n      if (!this.typeable && this.selectedDate) {\n        this.clearDate()\n      }\n    },\n    /**\n     * Toggles the calendar (unless `show-calendar-on-button-click` is true)\n     */\n    handleInputClick() {\n      if (this.showCalendarOnButtonClick) return\n\n      if (this.shouldToggleOnClick) {\n        this.toggle()\n      }\n    },\n    /**\n     * Opens the calendar when `show-calendar-on-focus` is true (unless `show-calendar-on-button-click` is true)\n     */\n    // eslint-disable-next-line complexity\n    handleInputFocus() {\n      if (this.showCalendarOnButtonClick) return\n\n      this.isInputFocused = true\n\n      if (!this.isOpen && this.shouldToggleOnFocus) {\n        this.shouldToggleOnClick = false\n      }\n\n      if (this.shouldToggleOnFocus && !this.isOpen) {\n        this.$emit('open')\n\n        setTimeout(() => {\n          this.shouldToggleOnClick = true\n        }, this.slideDuration)\n      }\n    },\n    /**\n     * Opens the calendar, or sets the focus to the next focusable element down\n     */\n    handleKeydownDown() {\n      if (!this.isOpen) {\n        this.$emit('open')\n      }\n\n      if (!this.typeable) {\n        return\n      }\n\n      this.$emit('setFocus', ['prev', 'up', 'next', 'tabbableCell'])\n    },\n    /**\n     * Selects a typed date and closes the calendar\n     */\n    handleKeydownEnter() {\n      if (!this.typeable) {\n        return\n      }\n\n      if (!this.input.value) {\n        this.$emit('selectTypedDate', null)\n        return\n      }\n\n      const parsedDate = this.parseInput()\n\n      if (this.utils.isValidDate(parsedDate)) {\n        this.$emit('selectTypedDate', parsedDate)\n      }\n    },\n    /**\n     * Closes the calendar\n     */\n    handleKeydownEscape() {\n      if (this.isOpen) {\n        this.$emit('close')\n      }\n    },\n    /**\n     * Prevents scrolling when not typeable\n     */\n    handleKeydownSpace(event) {\n      if (!this.typeable) {\n        event.preventDefault()\n      }\n    },\n    /**\n     * Parses a typed date and emits `typed-date` event, if valid\n     * @param  {object}  event Used to exclude certain keystrokes\n     */\n    handleKeyup(event) {\n      if (\n        !this.typeable ||\n        [\n          'Control',\n          'Escape',\n          'Shift',\n          'Tab',\n          'ArrowUp',\n          'ArrowDown',\n          'ArrowLeft',\n          'ArrowRight',\n        ].includes(event.key)\n      ) {\n        return\n      }\n\n      this.typedDate = this.input.value\n\n      if (!this.input.value) {\n        this.$emit('typedDate', null)\n        return\n      }\n\n      const parsedDate = this.parseInput()\n\n      if (this.utils.isValidDate(parsedDate)) {\n        this.$emit('typedDate', parsedDate)\n      }\n    },\n    /**\n     * Toggles the calendar unless a typed date has been entered or `show-calendar-on-button-click` is true\n     */\n    handleKeyupSpace(event) {\n      if (this.typeable) {\n        if (this.input.value === '') {\n          this.toggle()\n        }\n        return\n      }\n\n      event.preventDefault()\n      if (!this.showCalendarOnButtonClick) {\n        this.toggle()\n      }\n    },\n    /**\n     * Parses the value of the input field\n     */\n    parseInput() {\n      return new Date(\n        this.utils.parseDate(\n          this.input.value.trim(),\n          this.format,\n          this.translation,\n          this.parser,\n        ),\n      )\n    },\n    /**\n     * Opens or closes the calendar\n     */\n    toggle(calendarButton) {\n      if (this.isOpen) {\n        this.$emit('setFocus', [calendarButton || 'input'])\n      }\n\n      this.$emit(this.isOpen ? 'close' : 'open')\n    },\n  },\n}\n</script>\n","const cellUtils = {\n  isDefined(obj, prop) {\n    return obj && typeof obj[prop] !== 'undefined'\n  },\n\n  hasArray(obj, prop) {\n    return obj && Array.isArray(obj[prop])\n  },\n\n  hasDate(obj, prop) {\n    return this.isDefined(obj, prop) && this.utils.isValidDate(obj[prop])\n  },\n\n  dayMonthYear(obj, prop) {\n    const { utils } = this\n    const hasDate = this.hasDate(obj, prop)\n\n    if (!hasDate) {\n      return {\n        day: undefined,\n        month: undefined,\n        year: undefined,\n      }\n    }\n\n    const d = obj[prop]\n\n    return {\n      day: utils.getDate(d),\n      month: utils.getMonth(d),\n      year: utils.getFullYear(d),\n    }\n  },\n}\n\nexport default (utils) => ({\n  ...cellUtils,\n  utils,\n})\n","/* eslint-disable no-underscore-dangle */\n\nimport makeCellUtils from './cellUtils'\n\nexport default class DisabledDate {\n  constructor(utils, disabledDates) {\n    this._utils = utils\n    this._disabledDates = disabledDates\n  }\n\n  get config() {\n    const disabledDates = this._disabledDates\n    const utils = makeCellUtils(this._utils)\n    const has = {\n      customPredictor: utils.isDefined(disabledDates, 'customPredictor'),\n      daysOfMonth: utils.hasArray(disabledDates, 'daysOfMonth'),\n      daysOfWeek: utils.hasArray(disabledDates, 'days'),\n      from: utils.hasDate(disabledDates, 'from'),\n      ranges: utils.hasArray(disabledDates, 'ranges'),\n      specificDates: utils.hasArray(disabledDates, 'dates'),\n      to: utils.hasDate(disabledDates, 'to'),\n    }\n\n    return {\n      to: utils.dayMonthYear(disabledDates, 'to'),\n      from: utils.dayMonthYear(disabledDates, 'from'),\n      has,\n    }\n  }\n\n  daysInMonth(date) {\n    const utils = this._utils\n    const month = utils.getMonth(date)\n    const year = utils.getFullYear(date)\n\n    return utils.daysInMonth(year, month)\n  }\n\n  isDateDisabledVia(date) {\n    const disabledDates = this._disabledDates\n    const { has } = this.config\n\n    return {\n      to: () => {\n        return has.to && date <= disabledDates.to\n      },\n      from: () => {\n        return has.from && date >= disabledDates.from\n      },\n      range: () => {\n        if (!has.ranges) return false\n\n        const { ranges } = disabledDates\n        const u = makeCellUtils(this._utils)\n\n        return ranges.some((thisRange) => {\n          const hasFrom = u.isDefined(thisRange, 'from')\n          const hasTo = u.isDefined(thisRange, 'to')\n\n          return (\n            hasFrom && hasTo && date <= thisRange.to && date >= thisRange.from\n          )\n        })\n      },\n      customPredictor: () => {\n        return has.customPredictor && disabledDates.customPredictor(date)\n      },\n      specificDate: () => {\n        if (!has.specificDates) return false\n\n        return disabledDates.dates.some((d) => {\n          return this._utils.compareDates(date, d)\n        })\n      },\n      daysOfWeek: () => {\n        if (!has.daysOfWeek) return false\n\n        return disabledDates.days.indexOf(this._utils.getDay(date)) !== -1\n      },\n      daysOfMonth: () => {\n        if (!has.daysOfMonth) return false\n\n        return (\n          disabledDates.daysOfMonth.indexOf(this._utils.getDate(date)) !== -1\n        )\n      },\n    }\n  }\n\n  isMonthDisabledVia(date) {\n    const { from, has, to } = this.config\n    const month = this._utils.getMonth(date)\n    const year = this._utils.getFullYear(date)\n\n    return {\n      to: () => {\n        const isYearInPast = has.to && year < to.year\n\n        if (isYearInPast) {\n          return true\n        }\n\n        return has.to && month < to.month && year <= to.year\n      },\n      from: () => {\n        const isYearInFuture = has.from && year > from.year\n\n        if (isYearInFuture) {\n          return true\n        }\n\n        return has.from && month > from.month && year >= from.year\n      },\n    }\n  }\n\n  isYearDisabledVia(date) {\n    const { from, has, to } = this.config\n    const year = this._utils.getFullYear(date)\n\n    return {\n      to: () => {\n        return has.to && year < to.year\n      },\n      from: () => {\n        return has.from && year > from.year\n      },\n    }\n  }\n\n  /**\n   * Checks if the given date should be disabled\n   * @param {Date} date\n   * @return {Boolean}\n   */\n  // eslint-disable-next-line complexity,max-statements\n  isDateDisabled(date) {\n    const isDisabledVia = this.isDateDisabledVia(date)\n\n    return (\n      isDisabledVia.to() ||\n      isDisabledVia.from() ||\n      isDisabledVia.range() ||\n      isDisabledVia.specificDate() ||\n      isDisabledVia.daysOfWeek() ||\n      isDisabledVia.daysOfMonth() ||\n      isDisabledVia.customPredictor()\n    )\n  }\n\n  /**\n   * Checks if the given month should be disabled\n   * @param {Date} date\n   * @return {Boolean}\n   */\n  // eslint-disable-next-line complexity,max-statements\n  isMonthDisabled(date) {\n    const isDisabledVia = this.isMonthDisabledVia(date)\n\n    if (isDisabledVia.to() || isDisabledVia.from()) {\n      return true\n    }\n\n    // now we have to check each day of the month\n    for (let i = 1; i <= this.daysInMonth(date); i += 1) {\n      const dayDate = new Date(date)\n      dayDate.setDate(i)\n      // if at least one day of this month is NOT disabled,\n      // we can conclude that this month SHOULD be selectable\n      if (!this.isDateDisabled(dayDate)) {\n        return false\n      }\n    }\n\n    return true\n  }\n\n  /**\n   * Checks if the given year should be disabled\n   * @param {Date} date\n   * @return {Boolean}\n   */\n  // eslint-disable-next-line complexity,max-statements\n  isYearDisabled(date) {\n    const isDisabledVia = this.isYearDisabledVia(date)\n\n    if (isDisabledVia.to() || isDisabledVia.from()) {\n      return true\n    }\n\n    // now we have to check each month of the year\n    for (let i = 0; i < 12; i += 1) {\n      const monthDate = new Date(date)\n      monthDate.setMonth(i)\n      // if at least one month of this year is NOT disabled,\n      // we can conclude that this year SHOULD be selectable\n      if (!this.isMonthDisabled(monthDate)) {\n        return false\n      }\n    }\n\n    return true\n  }\n\n  getEarliestPossibleDate(date) {\n    if (!date) {\n      return null\n    }\n    const utils = this._utils\n\n    if (this.isDateDisabled(date)) {\n      const nextDate = new Date(\n        utils.getFullYear(date),\n        utils.getMonth(date),\n        utils.getDate(date) + 1,\n      )\n\n      return this.getEarliestPossibleDate(nextDate)\n    }\n\n    return date\n  }\n\n  getLatestPossibleDate(date) {\n    if (!date) {\n      return null\n    }\n    const utils = this._utils\n\n    if (this.isDateDisabled(date)) {\n      const nextDate = new Date(\n        utils.getFullYear(date),\n        utils.getMonth(date),\n        utils.getDate(date) - 1,\n      )\n\n      return this.getLatestPossibleDate(nextDate)\n    }\n\n    return date\n  }\n}\n","<script>\nexport default {\n  data() {\n    return {\n      focus: {\n        delay: 0,\n        refs: [],\n      },\n      inlineTabbableCell: null,\n      isActive: false,\n      isRevertingToOpenDate: false,\n      navElements: [],\n      navElementsFocusedIndex: 0,\n      resetTabbableCell: false,\n      skipReviewFocus: false,\n      tabbableCell: null,\n      transitionName: '',\n    }\n  },\n  computed: {\n    fallbackElementsToFocus() {\n      const elements = ['tabbableCell', 'prev', 'next']\n\n      if (this.typeable) {\n        elements.unshift('input')\n      }\n\n      return elements\n    },\n    focusedDateTimestamp() {\n      const pageDate = new Date(this.pageTimestamp)\n\n      if (this.hasClass(this.tabbableCell, 'day')) {\n        return this.utils.setDate(pageDate, this.tabbableCell.innerHTML.trim())\n      }\n\n      if (this.hasClass(this.tabbableCell, 'month')) {\n        return this.utils.setMonth(pageDate, this.tabbableCellId)\n      }\n\n      const fullYear = this.utils.getFullYear(pageDate) - 1\n      return this.utils.setFullYear(pageDate, fullYear + this.tabbableCellId)\n    },\n    tabbableCellId() {\n      return (\n        this.tabbableCell && Number(this.tabbableCell.getAttribute('data-id'))\n      )\n    },\n  },\n  methods: {\n    /**\n     * Converts a date to first in month for `month` view or first in year for `year` view\n     * @param   {Date} date The date to convert\n     * @returns {Date}\n     */\n    getCellDate(date) {\n      switch (this.view) {\n        case 'month':\n          return new Date(this.utils.setDate(date, 1))\n        case 'year':\n          return new Date(\n            this.utils.setMonth(new Date(this.utils.setDate(date, 1)), 0),\n          )\n        default:\n          return date\n      }\n    },\n    /**\n     * Returns true, unless tabbing should be focus-trapped\n     * @return {Boolean}\n     */\n    allowNormalTabbing(event) {\n      if (!this.isOpen) {\n        return true\n      }\n\n      return this.isTabbingAwayFromInlineDatepicker(event)\n    },\n    /**\n     * Focuses the first non-disabled element found in the `focus.refs` array and sets `navElementsFocusedIndex`\n     */\n    applyFocus() {\n      const focusRefs = [...this.focus.refs, ...this.fallbackElementsToFocus]\n\n      for (let i = 0; i < focusRefs.length; i += 1) {\n        const element = this.getElementByRef(focusRefs[i])\n\n        if (element && element.getAttribute('disabled') === null) {\n          element.focus()\n          this.setNavElementsFocusedIndex()\n          break\n        }\n      }\n    },\n    /**\n     * Ensures the most recently focused tabbable cell is focused when tabbing backwards to an inline calendar\n     * If no element has previously been focused, the tabbable cell is reset and focused\n     */\n    focusInlineTabbableCell() {\n      if (this.inlineTabbableCell) {\n        this.inlineTabbableCell.focus()\n\n        return\n      }\n\n      this.resetTabbableCell = true\n      this.setTabbableCell()\n      this.tabbableCell.focus()\n      this.resetTabbableCell = false\n    },\n    /**\n     * Returns the currently focused cell element, if there is one...\n     */\n    getActiveCell() {\n      const activeElement = this.getActiveElement()\n      const isActiveElementACell = this.hasClass(activeElement, 'cell')\n      const isOnSameView = this.hasClass(activeElement, this.view)\n\n      if (isActiveElementACell && isOnSameView && !this.resetTabbableCell) {\n        return activeElement\n      }\n\n      return null\n    },\n    /**\n     * Returns the currently focused element, using shadowRoot for web-components...\n     */\n    getActiveElement() {\n      return document.activeElement.shadowRoot\n        ? document.activeElement.shadowRoot.activeElement\n        : document.activeElement\n    },\n    /**\n     * Returns the `cellId` for a given a date\n     * @param {Date} date The date for which we need the cellId\n     * @returns {Number|null}\n     */\n    getCellId(date) {\n      if (!date || !this.$refs.picker.$refs.cells) {\n        return null\n      }\n\n      const cellDate = this.getCellDate(date)\n      const { cells } = this.$refs.picker.$refs.cells\n\n      for (let i = 0; i < cells.length; i += 1) {\n        if (cells[i].timestamp === cellDate.valueOf()) {\n          return i\n        }\n      }\n\n      return null\n    },\n    /**\n     * Finds an element by its `ref` attribute\n     * @param {string} ref        The `ref` name of the wanted element\n     * @returns {HTMLElement|Vue} A Vue element\n     */\n    // eslint-disable-next-line complexity,max-statements\n    getElementByRef(ref) {\n      if (ref === 'tabbableCell') {\n        return this.tabbableCell\n      }\n      if (ref === 'input') {\n        return this.$refs.dateInput && this.$refs.dateInput.$refs[this.refName]\n      }\n      if (ref === 'calendarButton') {\n        return this.$refs.dateInput && this.$refs.dateInput.$refs.calendarButton\n      }\n      if (ref === 'openDate') {\n        return this.$refs.picker.$refs.cells.$refs.openDate[0]\n      }\n      if (this.showHeader) {\n        return (\n          this.$refs.picker &&\n          this.$refs.picker.$refs.pickerHeader &&\n          this.$refs.picker.$refs.pickerHeader.$refs[ref]\n        )\n      }\n      return null\n    },\n    /**\n     * Returns an array of all HTML elements which should be focus-trapped in the calendarFooter slot\n     * @returns {Array}   An array of HTML elements\n     */\n    getElementsFromCalendarFooter() {\n      const footerSlotIndex = this.hasSlot('beforeCalendarHeader') ? 2 : 1\n\n      return this.getFocusableElements(\n        this.$refs.view.children[footerSlotIndex],\n      )\n    },\n    /**\n     * Returns an array of all HTML elements which should be focus-trapped in the specified slot\n     * @returns {Array}   An array of HTML elements\n     */\n    getElementsFromSlot(slotName) {\n      if (!this.hasSlot(slotName)) {\n        return []\n      }\n\n      if (slotName === 'beforeCalendarHeader') {\n        return this.getFocusableElements(this.$refs.view.children[0])\n      }\n\n      if (slotName === 'calendarFooter') {\n        return this.getElementsFromCalendarFooter()\n      }\n\n      const isBeforeHeader = slotName.indexOf('beforeCalendarHeader') > -1\n      const picker = this.$refs.picker.$el\n      const index = isBeforeHeader ? 0 : picker.children.length - 1\n\n      return this.getFocusableElements(picker.children[index])\n    },\n    /**\n     * Returns an array of all HTMLButtonElements which should be focus-trapped in the header\n     * @returns {Array}   An array of HTMLButtonElements\n     */\n    getElementsFromHeader() {\n      if (!this.$refs.picker.$refs.pickerHeader) {\n        return []\n      }\n      const header = this.$refs.picker.$refs.pickerHeader.$el\n      const navNodeList = header.querySelectorAll('button:enabled')\n\n      return [...Array.prototype.slice.call(navNodeList)]\n    },\n    /**\n     * Returns an array of focusable elements in a given HTML fragment\n     * @param   {Element} fragment The HTML fragment to search\n     * @returns {Array}\n     */\n    getFocusableElements(fragment) {\n      if (!fragment) {\n        return []\n      }\n\n      const navNodeList = fragment.querySelectorAll(\n        'button:enabled:not([tabindex=\"-1\"]), [href]:not([tabindex=\"-1\"]), input:not([tabindex=\"-1\"]):not([type=hidden]), select:enabled:not([tabindex=\"-1\"]), textarea:enabled:not([tabindex=\"-1\"]), [tabindex]:not([tabindex=\"-1\"])',\n      )\n\n      return [...Array.prototype.slice.call(navNodeList)]\n    },\n    /**\n     * Returns the first focusable element of an inline datepicker\n     * @returns {HTMLElement}\n     */\n    getFirstInlineFocusableElement() {\n      const popupElements = this.getFocusableElements(this.$refs.popup.$el)\n\n      return popupElements[0]\n    },\n    /**\n     * Returns the last focusable element of an inline datepicker\n     * @returns {HTMLElement}\n     */\n    getLastInlineFocusableElement() {\n      const popupElements = this.getFocusableElements(this.$refs.popup.$el)\n\n      return popupElements[popupElements.length - 1]\n    },\n    /**\n     * Returns the input element (when typeable)\n     * @returns {Element}\n     */\n    getInputField() {\n      if (!this.typeable || this.inline) {\n        return null\n      }\n\n      return this.$refs.dateInput.$refs[this.refName]\n    },\n    /**\n     * Used for a typeable datepicker: returns the cell element that corresponds to latestValidTypedDate...\n     */\n    getTypedCell() {\n      if (!this.typeable) {\n        return null\n      }\n\n      const cellId = this.getCellId(this.latestValidTypedDate)\n\n      return cellId ? this.$refs.picker.$refs.cells.$el.children[cellId] : null\n    },\n    /**\n     * Sets `datepickerId` (as a global) and keeps track of focusable elements\n     */\n    handleFocusIn() {\n      document.datepickerId = this.datepickerId\n      this.globalDatepickerId = this.datepickerId\n\n      this.isActive = true\n      this.setInlineTabbableCell()\n      this.setNavElements()\n    },\n    /**\n     * Sets the datepicker's `isActive` state to false and resets `globalDatepickerId`\n     */\n    handleFocusOut() {\n      this.isActive = false\n      this.globalDatepickerId = ''\n    },\n    /**\n     * Returns true if the calendar has been passed the given slot\n     * @param  {String} slotName The name of the slot\n     * @return {Boolean}\n     */\n    hasSlot(slotName) {\n      return !!this.$slots[slotName]\n    },\n    /**\n     * Returns true if the user is tabbing away from an inline datepicker\n     * @return {Boolean}\n     */\n    isTabbingAwayFromInlineDatepicker(event) {\n      if (!this.inline) {\n        return false\n      }\n\n      if (this.isTabbingAwayFromFirstNavElement(event)) {\n        this.tabAwayFromFirstElement()\n\n        return true\n      }\n\n      if (this.isTabbingAwayFromLastNavElement(event)) {\n        this.tabAwayFromLastElement()\n\n        return true\n      }\n\n      return false\n    },\n    /**\n     * Used for inline calendars; returns true if the user tabs backwards from the first focusable element\n     * @param  {object}  event Used to determine whether we are tabbing forwards or backwards\n     * @return {Boolean}\n     */\n    isTabbingAwayFromFirstNavElement(event) {\n      if (!event.shiftKey) {\n        return false\n      }\n\n      const activeElement = this.getActiveElement()\n      const firstNavElement = this.navElements[0]\n\n      return activeElement === firstNavElement\n    },\n    /**\n     * Used for inline calendars; returns true if the user tabs forwards from the last focusable element\n     * @param  {object}  event Used to determine whether we are tabbing forwards or backwards\n     * @return {Boolean}\n     */\n    isTabbingAwayFromLastNavElement(event) {\n      if (event.shiftKey) {\n        return false\n      }\n\n      const activeElement = this.getActiveElement()\n      const lastNavElement = this.navElements[this.navElements.length - 1]\n\n      return activeElement === lastNavElement\n    },\n    /**\n     * Resets the focus to the open date\n     */\n    resetFocusToOpenDate(focusedDateTimestamp) {\n      this.focus.refs = ['openDate']\n      this.setTransitionAndFocusDelay(\n        focusedDateTimestamp,\n        this.computedOpenDate,\n      )\n\n      if (!this.isMinimumView) {\n        this.isRevertingToOpenDate = true\n        this.view = this.minimumView\n      }\n\n      this.setPageDate(this.computedOpenDate)\n      this.reviewFocus()\n    },\n    /**\n     * Sets the correct focus on next tick\n     */\n    reviewFocus() {\n      if (this.skipReviewFocus) {\n        return\n      }\n\n      this.tabbableCell = null\n      this.resetTabbableCell = true\n\n      this.$nextTick(() => {\n        this.setNavElements()\n\n        setTimeout(() => {\n          this.applyFocus()\n        }, this.focus.delay)\n\n        this.resetTabbableCell = false\n      })\n    },\n    /**\n     * Stores the current tabbableCell of an inline datepicker\n     * N.B. This is used when tabbing back (shift + tab) to an inline calendar from further down the page\n     */\n    setInlineTabbableCell() {\n      if (!this.inline) {\n        return\n      }\n\n      this.inlineTabbableCell = this.tabbableCell\n    },\n    /**\n     * Sets the direction of the slide transition and whether or not to delay application of the focus\n     * @param {Date|Number} startDate     The date from which to measure\n     * @param {Date|Number} endDate       Is this before or after the startDate? And is it on the same page?\n     */\n    setTransitionAndFocusDelay(startDate, endDate) {\n      const startPageDate = this.utils.setDate(new Date(startDate), 1)\n      const endPageDate = this.utils.setDate(new Date(endDate), 1)\n      const isInTheFuture = startPageDate < endPageDate\n\n      if (this.isMinimumView) {\n        this.focus.delay = isInTheFuture ? this.slideDuration : 0\n      } else {\n        this.focus.delay = 0\n      }\n\n      this.setTransitionName(endDate - startDate)\n    },\n    /**\n     * Set the focus\n     * @param {Array} refs An array of `refs` to focus (in order of preference)\n     */\n    setFocus(refs) {\n      this.focus.refs = refs\n      this.applyFocus()\n    },\n    /**\n     * Determines which elements in datepicker should be focus-trapped\n     */\n    setNavElements() {\n      if (!this.view) return\n\n      this.updateTabbableCell()\n\n      const view = this.ucFirst(this.view)\n\n      this.navElements = [\n        this.getInputField(),\n        this.getElementsFromSlot('beforeCalendarHeader'),\n        this.getElementsFromSlot(`beforeCalendarHeader${view}`),\n        this.getElementsFromHeader(),\n        this.tabbableCell,\n        this.getElementsFromSlot(`calendarFooter${view}`),\n        this.getElementsFromSlot('calendarFooter'),\n      ]\n        .filter((item) => !!item)\n        .reduce((acc, val) => acc.concat(val), [])\n    },\n    /**\n     * Keeps track of the currently focused index in the navElements array\n     */\n    setNavElementsFocusedIndex() {\n      const activeElement = this.getActiveElement()\n\n      for (let i = 0; i < this.navElements.length; i += 1) {\n        if (activeElement === this.navElements[i]) {\n          this.navElementsFocusedIndex = i\n          return\n        }\n      }\n\n      this.navElementsFocusedIndex = 0\n    },\n    /**\n     * Sets the focus-trapped cell in the picker\n     */\n    // eslint-disable-next-line complexity\n    setTabbableCell() {\n      if (!this.$refs.picker || !this.$refs.picker.$refs.cells) {\n        return\n      }\n\n      const pickerCells = this.$refs.picker.$refs.cells.$el\n\n      this.tabbableCell =\n        this.getActiveCell() ||\n        this.getTypedCell() ||\n        pickerCells.querySelector('button.selected:not(.muted):enabled') ||\n        pickerCells.querySelector('button.open:not(.muted):enabled') ||\n        pickerCells.querySelector('button.today:not(.muted):enabled') ||\n        pickerCells.querySelector('button.cell:not(.muted):enabled')\n    },\n    /**\n     * Sets the direction of the slide transition\n     * @param {Number} plusOrMinus Positive for the future; negative for the past\n     */\n    setTransitionName(plusOrMinus) {\n      const isInTheFuture = plusOrMinus > 0\n\n      if (this.isRtl) {\n        this.transitionName = isInTheFuture ? 'slide-left' : 'slide-right'\n      } else {\n        this.transitionName = isInTheFuture ? 'slide-right' : 'slide-left'\n      }\n    },\n    /**\n     * Focuses the first focusable element of an inline datepicker, so that the previous element on the page will be tabbed to\n     */\n    tabAwayFromFirstElement() {\n      const firstElement = this.getFirstInlineFocusableElement()\n\n      // Keep a record of `tabbableCell` in case `showHeader=false` and this is the first date\n      // in the month (with no edge dates from the previous month) to which we may want to\n      // tab back down to later.\n      this.setInlineTabbableCell()\n\n      firstElement.focus()\n\n      // Reset the tabbableCell as we don't want it to be the `firstElement` if the latter is\n      // an edge date from the previous month\n      this.tabbableCell = this.inlineTabbableCell\n    },\n    /**\n     * Focuses the last focusable element of an inline datepicker, so that the next element on the page will be tabbed to\n     */\n    tabAwayFromLastElement() {\n      const lastElement = this.getLastInlineFocusableElement()\n\n      // Keep a record of `tabbableCell` in case this is the last date in the month\n      // (with no edge dates from the next month) to which we may want to shift+tab\n      // back up to later.\n      this.setInlineTabbableCell()\n\n      lastElement.focus()\n\n      // Reset the tabbableCell as we don't want it to be the `lastElement` if the latter is\n      // an edge date from the next month\n      this.tabbableCell = this.inlineTabbableCell\n    },\n    /**\n     * Tab backwards through the focus-trapped elements\n     */\n    tabBackwards() {\n      this.navElementsFocusedIndex -= 1\n\n      if (this.navElementsFocusedIndex < 0) {\n        this.navElementsFocusedIndex = this.navElements.length - 1\n      }\n\n      this.navElements[this.navElementsFocusedIndex].focus()\n    },\n    /**\n     * Tab forwards through the focus-trapped elements\n     */\n    tabForwards() {\n      this.navElementsFocusedIndex += 1\n\n      if (this.navElementsFocusedIndex >= this.navElements.length) {\n        this.navElementsFocusedIndex = 0\n      }\n\n      this.navElements[this.navElementsFocusedIndex].focus()\n    },\n    /**\n     * Tab through the focus-trapped elements\n     * @param event\n     */\n    tabThroughNavigation(event) {\n      if (this.allowNormalTabbing(event)) {\n        return\n      }\n\n      event.preventDefault()\n\n      if (event.shiftKey) {\n        this.tabBackwards()\n      } else {\n        this.tabForwards()\n      }\n    },\n    /**\n     * Special cases for when tabbing to an inline datepicker\n     */\n    tabToCorrectInlineCell() {\n      const lastElement = this.getLastInlineFocusableElement()\n      const isACell = this.hasClass(lastElement, 'cell')\n      const activeElement = this.getActiveElement()\n      const isLastElementFocused = activeElement === lastElement\n\n      // If there are no focusable elements in the footer slots and the inline datepicker has been tabbed to (backwards)\n      if (isACell && isLastElementFocused) {\n        this.focusInlineTabbableCell()\n        return\n      }\n\n      // If `show-header` is false and the inline datepicker has been tabbed to (forwards)\n      this.$nextTick(() => {\n        const isFirstCell = activeElement.getAttribute('data-id') === '0'\n\n        if (isFirstCell) {\n          this.focusInlineTabbableCell()\n        }\n      })\n    },\n    /**\n     * Update which cell in the picker should be focus-trapped\n     */\n    updateTabbableCell() {\n      const activeElement = this.getActiveElement()\n      const isActiveElementACell = this.hasClass(activeElement, 'cell')\n      const needToUpdate = !this.tabbableCell || isActiveElementACell\n\n      if (needToUpdate) {\n        this.setTabbableCell()\n      }\n    },\n  },\n}\n</script>\n","<template>\n  <header>\n    <button\n      ref=\"prev\"\n      class=\"prev\"\n      :class=\"{ btn: bootstrapStyling, rtl: isRtl }\"\n      data-test-previous-button\n      :disabled=\"isPreviousDisabled\"\n      type=\"button\"\n      @click.stop=\"goToPreviousPage\"\n      @keydown.down.prevent=\"focusTabbableCell\"\n      @keydown.up.prevent=\"focusInput\"\n      @keydown.left.prevent=\"arrowLeftPrev\"\n      @keydown.right.prevent=\"arrowRightPrev\"\n    >\n      <slot name=\"prevIntervalBtn\">\n        <span class=\"default\">&lt;</span>\n      </slot>\n    </button>\n    <button\n      ref=\"up\"\n      class=\"vdp-datepicker__up\"\n      :class=\"{ btn: bootstrapStyling }\"\n      data-test-up-button\n      :disabled=\"isUpDisabled\"\n      type=\"button\"\n      @click=\"selectUpButton\"\n      @keydown.down.prevent=\"focusTabbableCell\"\n      @keydown.up.prevent=\"focusInput\"\n      @keydown.left.prevent=\"focusLeftButton\"\n      @keydown.right.prevent=\"focusRightButton\"\n    >\n      <slot />\n    </button>\n    <button\n      ref=\"next\"\n      class=\"next\"\n      :class=\"{ btn: bootstrapStyling, rtl: isRtl }\"\n      data-test-next-button\n      :disabled=\"isNextDisabled\"\n      type=\"button\"\n      @click.stop=\"goToNextPage\"\n      @keydown.down.prevent=\"focusTabbableCell\"\n      @keydown.up.prevent=\"focusInput\"\n      @keydown.left.prevent=\"arrowLeftNext\"\n      @keydown.right.prevent=\"arrowRightNext\"\n    >\n      <slot name=\"nextIntervalBtn\">\n        <span class=\"default\">&gt;</span>\n      </slot>\n    </button>\n  </header>\n</template>\n\n<script>\nexport default {\n  name: 'PickerHeader',\n  props: {\n    bootstrapStyling: {\n      type: Boolean,\n      default: false,\n    },\n    isNextDisabled: {\n      type: Boolean,\n      required: true,\n    },\n    isPreviousDisabled: {\n      type: Boolean,\n      required: true,\n    },\n    isRtl: {\n      type: Boolean,\n      required: true,\n    },\n    isUpDisabled: {\n      type: Boolean,\n      default: false,\n    },\n    nextViewUp: {\n      type: String,\n      default: null,\n    },\n  },\n  emits: {\n    focusInput: null,\n    pageChange: (page) => {\n      return typeof page === 'object'\n    },\n    setFocus: (refArray) => {\n      return refArray.every((ref) => {\n        return ['input', 'prev', 'up', 'next', 'tabbableCell'].includes(ref)\n      })\n    },\n    setView: (view) => {\n      return ['day', 'month', 'year'].includes(view)\n    },\n  },\n  data() {\n    return {\n      previousPage: { incrementBy: -1, focusRefs: ['prev'] },\n      nextPage: { incrementBy: 1, focusRefs: ['next'] },\n    }\n  },\n  computed: {\n    leftButton() {\n      return [this.isRtl ? 'next' : 'prev']\n    },\n    rightButton() {\n      return [this.isRtl ? 'prev' : 'next']\n    },\n  },\n  methods: {\n    /**\n     * Changes the page, or sets focus to the adjacent button\n     */\n    arrowLeftPrev() {\n      if (this.isRtl) {\n        this.$emit('setFocus', ['up', 'next', 'tabbableCell'])\n        return\n      }\n      this.goToPreviousPage()\n    },\n    /**\n     * Changes the page, or sets focus to the adjacent button\n     */\n    arrowRightPrev() {\n      if (this.isRtl) {\n        this.goToPreviousPage()\n        return\n      }\n      this.$emit('setFocus', ['up', 'next', 'tabbableCell'])\n    },\n    /**\n     * Changes the page, or sets focus to the adjacent button\n     */\n    arrowLeftNext() {\n      if (this.isRtl) {\n        this.goToNextPage()\n        return\n      }\n      this.$emit('setFocus', ['up', 'prev', 'tabbableCell'])\n    },\n    /**\n     * Changes the page, or sets focus to the adjacent button\n     */\n    arrowRightNext() {\n      if (this.isRtl) {\n        this.$emit('setFocus', ['up', 'prev', 'tabbableCell'])\n        return\n      }\n      this.goToNextPage()\n    },\n    focusInput() {\n      this.$emit('focusInput')\n    },\n    focusTabbableCell() {\n      this.$emit('setFocus', ['tabbableCell'])\n    },\n    focusLeftButton() {\n      this.$emit('setFocus', this.leftButton)\n    },\n    focusRightButton() {\n      this.$emit('setFocus', this.rightButton)\n    },\n    goToNextPage() {\n      this.$emit('pageChange', { incrementBy: 1, focusRefs: ['next'] })\n    },\n    goToPreviousPage() {\n      this.$emit('pageChange', { incrementBy: -1, focusRefs: ['prev'] })\n    },\n    selectUpButton() {\n      if (!this.isUpDisabled) {\n        this.$emit('setView', this.nextViewUp)\n      }\n    },\n  },\n}\n</script>\n","<script>\nimport PickerHeader from '~/components/PickerHeader.vue'\nimport makeDateUtils from '~/utils/DateUtils'\nimport DisabledDate from '~/utils/DisabledDate'\n\nexport default {\n  components: { PickerHeader },\n  props: {\n    bootstrapStyling: {\n      type: Boolean,\n      default: false,\n    },\n    disabledDates: {\n      type: Object,\n      default: null,\n    },\n    isRtl: {\n      type: Boolean,\n      default: false,\n    },\n    isTypeable: {\n      type: Boolean,\n      default: false,\n    },\n    isUpDisabled: {\n      type: Boolean,\n      default: false,\n    },\n    isMinimumView: {\n      type: Boolean,\n      default: true,\n    },\n    openDate: {\n      type: [String, Date, Number],\n      default: null,\n    },\n    pageDate: {\n      type: Date,\n      default: null,\n    },\n    selectedDate: {\n      type: Date,\n      default: null,\n    },\n    showHeader: {\n      type: Boolean,\n      default: true,\n    },\n    slideDuration: {\n      type: Number,\n      default: 250,\n    },\n    tabbableCellId: {\n      type: Number,\n      default: null,\n    },\n    transitionName: {\n      type: String,\n      default: '',\n    },\n    translation: {\n      type: Object,\n      default() {\n        return {}\n      },\n    },\n    useUtc: {\n      type: Boolean,\n      default: false,\n    },\n    view: {\n      type: String,\n      default: 'day',\n    },\n  },\n  emits: {\n    pageChange: (config) => {\n      return typeof config === 'object'\n    },\n    select: (cell) => {\n      return typeof cell === 'object'\n    },\n    setFocus: (refArray) => {\n      return refArray === ['input']\n    },\n    setSkipReviewFocus: (value) => {\n      return typeof value === 'boolean'\n    },\n    setTransitionName: (incrementBy) => {\n      return incrementBy === -1 || incrementBy === 1\n    },\n  },\n  data() {\n    return {\n      utils: makeDateUtils(this.useUtc),\n    }\n  },\n  computed: {\n    /**\n     * A look-up object created from 'disabledDates' prop\n     * @return {Object}\n     */\n    disabledConfig() {\n      if (!this.disabledDates) {\n        return {\n          has: {\n            from: false,\n            to: false,\n          },\n        }\n      }\n\n      return new DisabledDate(this.utils, this.disabledDates).config\n    },\n    earliestPossibleDate() {\n      if (!this.disabledDates) return null\n\n      return new DisabledDate(\n        this.utils,\n        this.disabledDates,\n      ).getEarliestPossibleDate(this.disabledDates.to)\n    },\n    latestPossibleDate() {\n      if (!this.disabledDates) return null\n\n      return new DisabledDate(\n        this.utils,\n        this.disabledDates,\n      ).getLatestPossibleDate(this.disabledDates.from)\n    },\n    /**\n     * Returns the current page's full year as an integer.\n     * @return {Number}\n     */\n    pageYear() {\n      return this.utils.getFullYear(this.pageDate)\n    },\n  },\n  methods: {\n    /**\n     * Used when an arrow key press would cause the focus to land on a disabled date\n     * @param {Object} options\n     */\n    addMoreSteps(options) {\n      if (options.stepsRemaining <= 0 && Math.abs(options.delta) > 1) {\n        return Math.abs(options.delta)\n      }\n      return options.stepsRemaining\n    },\n    /**\n     * Changes the page up or down\n     * @param {Number} incrementBy\n     * @param {[String]} focusRefs\n     */\n    changePage({ incrementBy, focusRefs }) {\n      const { pageDate, utils } = this\n      const units =\n        this.view === 'year' ? incrementBy * this.yearRange : incrementBy\n\n      this.$emit('setTransitionName', incrementBy)\n\n      if (this.view === 'day') {\n        utils.setMonth(pageDate, utils.getMonth(pageDate) + units)\n      } else {\n        utils.setFullYear(pageDate, utils.getFullYear(pageDate) + units)\n      }\n\n      this.$emit('pageChange', { focusRefs, pageDate })\n    },\n    /**\n     * Changes the page and focuses the cell that is being 'arrowed' to\n     * @param {Object} options\n     */\n    changePageAndSetFocus(options) {\n      const { delta } = options\n      const isPageDisabled =\n        (delta > 0 && this.isNextDisabled) ||\n        (delta < 0 && this.isPreviousDisabled)\n\n      if (isPageDisabled) {\n        return\n      }\n\n      this.$emit('setSkipReviewFocus', true)\n\n      this.changePage({\n        incrementBy: Math.sign(delta),\n        focusRefs: ['arrow-to-cell'],\n      })\n\n      this.$nextTick(() => {\n        this.setFocusOnNewPage(options)\n        this.$emit('setSkipReviewFocus', false)\n      })\n    },\n    /**\n     * Focuses the input field, if typeable\n     */\n    focusInput() {\n      if (this.isTypeable) {\n        this.$emit('setFocus', ['input'])\n      }\n    },\n    /**\n     * Returns the element that should be focused when navigating via an arrow key\n     * @param  {HTMLButtonElement} currentElement  The element currently being iterated on\n     * @param  {Number}            delta           The number of cells that the focus should move\n     * @param  {Number}            stepsRemaining  The number of steps remaining in the iteration\n     * @return {HTMLButtonElement | void}\n     */\n    // eslint-disable-next-line complexity,max-statements\n    getElement({ currentElement, delta, stepsRemaining }) {\n      const element = this.getElementSibling(currentElement, delta)\n      const options = {\n        currentElement: element,\n        delta,\n        stepsRemaining: stepsRemaining - 1,\n      }\n\n      if (!element) {\n        return this.changePageAndSetFocus(options)\n      }\n\n      if (this.isBeyondPossibleDate(options)) {\n        return this.firstOrLastPossibleDate(options)\n      }\n\n      if (this.isMutedOrDisabled(element)) {\n        options.stepsRemaining = this.addMoreSteps(options)\n\n        return this.getElement(options)\n      }\n\n      if (stepsRemaining > 1 && options.currentElement) {\n        return this.getElement(options)\n      }\n\n      return element\n    },\n    /**\n     * Returns the element directly next to the currentElement\n     * @param  {HTMLButtonElement} currentElement The element currently being iterated on\n     * @param  {Number}            delta          The number of cells that the focus should move\n     * @return {HTMLButtonElement}\n     */\n    getElementSibling(currentElement, delta) {\n      const isNext = delta > 0\n\n      return isNext\n        ? currentElement.nextElementSibling\n        : currentElement.previousElementSibling\n    },\n    /**\n     * Returns the first or last cell, depending on the direction of the search\n     * @param  {Number} delta The number of cells that the focus should move\n     * @return {HTMLButtonElement}\n     */\n    getFirstOrLastElement(delta) {\n      const isNext = delta > 0\n      const elements = this.$refs.cells.$el.children\n\n      return isNext ? elements[0] : elements[elements.length - 1]\n    },\n    /**\n     * Returns the first or last non-disabled date, depending on the direction of the search\n     * @param  {HTMLButtonElement} currentElement  The element currently being iterated on\n     * @param  {Number}            delta           The number of cells that the focus should move\n     */\n    firstOrLastPossibleDate({ currentElement, delta }) {\n      if (delta > 0) {\n        return this.getElementSibling(currentElement, -1)\n      }\n\n      return this.getElementSibling(currentElement, 1)\n    },\n    /**\n     * Moves the focused cell up/down/left/right\n     * @param {Object}\n     */\n    handleArrow({ delta }) {\n      const activeElement = document.activeElement.shadowRoot\n        ? document.activeElement.shadowRoot.activeElement\n        : document.activeElement\n      const stepsRemaining = Math.abs(delta)\n      const options = {\n        currentElement: activeElement,\n        delta,\n        stepsRemaining,\n      }\n\n      this.setFocusToAvailableCell(options)\n    },\n    /**\n     * Determines which transition to use (for edge dates) and emits a 'select' event\n     * @param {Object} cell\n     */\n    select(cell) {\n      if (cell.isPreviousMonth) {\n        this.$emit('setTransitionName', -1)\n      }\n\n      if (cell.isNextMonth) {\n        this.$emit('setTransitionName', 1)\n      }\n\n      this.$emit('select', cell)\n    },\n    /**\n     * Returns true if the given element cannot be focused\n     * @param  {HTMLButtonElement} currentElement  The element currently being iterated on\n     * @param  {Number}            delta           The number of cells that the focus should move\n     * @return {Boolean}\n     */\n    isBeyondPossibleDate({ currentElement, delta }) {\n      if (delta > 0 && this.latestPossibleDate) {\n        return this.isDatePossible(currentElement, delta)\n      }\n\n      if (delta < 0 && this.earliestPossibleDate) {\n        return this.isDatePossible(currentElement, delta)\n      }\n\n      return false\n    },\n    /**\n     * Returns true if the current element's date is NOT possible, given the `disabled-dates`\n     * @param  {HTMLButtonElement} element The element in question\n     * @param  {Number}            delta   Used to determine direction of travel\n     * @return {Boolean}\n     */\n    isDatePossible(element, delta) {\n      const cellId = element.getAttribute('data-id')\n      const cellDate = new Date(this.cells[cellId].timestamp)\n\n      if (delta > 0) {\n        return (\n          cellDate >\n          this.utils.adjustDateToView(this.latestPossibleDate, this.view)\n        )\n      }\n\n      return (\n        cellDate <\n        this.utils.adjustDateToView(this.earliestPossibleDate, this.view)\n      )\n    },\n    /**\n     * Returns true if the given element cannot be focused\n     * @param  {HTMLButtonElement} element The element in question\n     * @return {Boolean}\n     */\n    isMutedOrDisabled(element) {\n      const isMuted = element.classList.value.split(' ').includes('muted')\n      const isDisabled = element.disabled\n\n      return isMuted || isDisabled\n    },\n    /**\n     * Sets the focus on the correct cell following a page change\n     * @param {Object} options\n     */\n    // eslint-disable-next-line max-statements\n    setFocusOnNewPage({ delta, stepsRemaining }) {\n      const currentElement = this.getFirstOrLastElement(delta)\n      const options = {\n        currentElement,\n        delta,\n        stepsRemaining,\n      }\n      const delay = this.slideDuration\n\n      if (stepsRemaining <= 0) {\n        if (this.isMutedOrDisabled(currentElement)) {\n          options.stepsRemaining = Math.abs(options.delta)\n\n          setTimeout(() => {\n            this.setFocusToAvailableCell(options)\n          }, delay)\n\n          return\n        }\n\n        setTimeout(() => {\n          currentElement.focus()\n        }, delay)\n\n        return\n      }\n\n      setTimeout(() => {\n        this.setFocusToAvailableCell(options)\n      }, delay)\n    },\n    /**\n     * Sets the focus on the next focusable cell when an arrow key is pressed\n     * @param {Object} options\n     */\n    setFocusToAvailableCell(options) {\n      const element = this.getElement(options)\n\n      if (element) {\n        element.focus()\n      }\n    },\n  },\n}\n</script>\n","/* eslint-disable no-underscore-dangle */\n\nimport makeCellUtils from './cellUtils'\nimport DisabledDate from './DisabledDate'\n\nexport default class HighlightedDate {\n  constructor(utils, disabledDates, highlighted) {\n    this._utils = utils\n    this._disabledDates = disabledDates\n    this._highlighted = highlighted\n  }\n\n  get config() {\n    const highlightedDates = this._highlighted\n    const utils = makeCellUtils(this._utils)\n    const has = {\n      customPredictor: utils.isDefined(highlightedDates, 'customPredictor'),\n      daysOfMonth: utils.hasArray(highlightedDates, 'daysOfMonth'),\n      daysOfWeek: utils.hasArray(highlightedDates, 'days'),\n      from: utils.hasDate(highlightedDates, 'from'),\n      ranges: utils.hasArray(highlightedDates, 'ranges'),\n      specificDates: utils.hasArray(highlightedDates, 'dates'),\n      to: utils.hasDate(highlightedDates, 'to'),\n      includeDisabled:\n        utils.isDefined(highlightedDates, 'includeDisabled') &&\n        highlightedDates.includeDisabled,\n    }\n\n    return {\n      to: utils.dayMonthYear(highlightedDates, 'to'),\n      from: utils.dayMonthYear(highlightedDates, 'from'),\n      has,\n    }\n  }\n\n  isDateDisabled(date) {\n    const utils = this._utils\n    const disabledDates = this._disabledDates\n\n    return new DisabledDate(utils, disabledDates).isDateDisabled(date)\n  }\n\n  isHighlightingNotPossible(date) {\n    return !this.config.has.includeDisabled && this.isDateDisabled(date)\n  }\n\n  isDateHighlightedVia(date) {\n    const highlightedDates = this._highlighted\n    const { has } = this.config\n\n    return {\n      to: () => {\n        return has.to && date <= highlightedDates.to\n      },\n      from: () => {\n        return has.from && date >= highlightedDates.from\n      },\n      range: () => {\n        if (!has.ranges) return false\n\n        const { ranges } = highlightedDates\n        const u = makeCellUtils(this._utils)\n\n        return ranges.some((thisRange) => {\n          const hasFrom = u.isDefined(thisRange, 'from')\n          const hasTo = u.isDefined(thisRange, 'to')\n\n          return (\n            hasFrom && hasTo && date <= thisRange.to && date >= thisRange.from\n          )\n        })\n      },\n      customPredictor: () => {\n        return has.customPredictor && highlightedDates.customPredictor(date)\n      },\n      specificDate: () => {\n        if (!has.specificDates) return false\n\n        return highlightedDates.dates.some((d) => {\n          return this._utils.compareDates(date, d)\n        })\n      },\n      daysOfWeek: () => {\n        if (!has.daysOfWeek) return false\n\n        return highlightedDates.days.indexOf(this._utils.getDay(date)) !== -1\n      },\n      daysOfMonth: () => {\n        if (!has.daysOfMonth) return false\n\n        return (\n          highlightedDates.daysOfMonth.indexOf(this._utils.getDate(date)) !== -1\n        )\n      },\n    }\n  }\n\n  // eslint-disable-next-line complexity,max-statements\n  isDateHighlighted(date) {\n    if (this.isHighlightingNotPossible(date)) return false\n\n    const isHighlightedVia = this.isDateHighlightedVia(date)\n\n    return (\n      isHighlightedVia.to() ||\n      isHighlightedVia.from() ||\n      isHighlightedVia.range() ||\n      isHighlightedVia.specificDate() ||\n      isHighlightedVia.daysOfWeek() ||\n      isHighlightedVia.daysOfMonth() ||\n      isHighlightedVia.customPredictor()\n    )\n  }\n\n  isHighlightStart(date) {\n    if (!this.config.has.ranges || !this.isDateHighlighted(date)) {\n      return false\n    }\n\n    for (let i = 0; i < this._highlighted.ranges.length; i += 1) {\n      const range = this._highlighted.ranges[i]\n\n      if (range.from.valueOf() === date.valueOf()) {\n        return true\n      }\n    }\n\n    return false\n  }\n\n  isHighlightEnd(date) {\n    if (!this.config.has.ranges || !this.isDateHighlighted(date)) {\n      return false\n    }\n\n    for (let i = 0; i < this._highlighted.ranges.length; i += 1) {\n      const range = this._highlighted.ranges[i]\n\n      if (range.to.valueOf() === date.valueOf()) {\n        return true\n      }\n    }\n\n    return false\n  }\n}\n","<template>\n  <div\n    class=\"picker-cells\"\n    data-test-picker-cells\n  >\n    <button\n      v-for=\"(cell, id) in cells\"\n      :key=\"cell.timestamp\"\n      :ref=\"cell.isOpenDate ? 'openDate' : null\"\n      :class=\"cellClasses(cell)\"\n      :data-id=\"id\"\n      :data-test-tabbable-cell=\"isTabbableCell(cell, id)\"\n      :data-test-open-date=\"cell.isOpenDate || null\"\n      :data-test-today-cell=\"cell.isToday || null\"\n      :disabled=\"cell.isDisabled\"\n      type=\"button\"\n      @click=\"$emit('select', cell)\"\n      @keydown.up.prevent=\"handleArrow(id, -columns)\"\n      @keydown.down.prevent=\"handleArrow(id, columns)\"\n      @keydown.left.prevent=\"handleArrow(id, isRtl ? 1 : -1)\"\n      @keydown.right.prevent=\"handleArrow(id, isRtl ? -1 : 1)\"\n    >\n      <slot :cell=\"cell\" />\n    </button>\n  </div>\n</template>\n\n<script>\nexport default {\n  name: 'PickerCells',\n  props: {\n    bootstrapStyling: {\n      type: Boolean,\n      default: false,\n    },\n    cells: {\n      type: Array,\n      required: true,\n    },\n    isRtl: {\n      type: Boolean,\n      default: false,\n    },\n    showEdgeDates: {\n      type: Boolean,\n      default: true,\n    },\n    tabbableCellId: {\n      type: Number,\n      default: null,\n    },\n    view: {\n      type: String,\n      validator: (val) => ['day', 'month', 'year'].includes(val),\n      required: true,\n    },\n  },\n  emits: {\n    arrow(config) {\n      return typeof config === 'object'\n    },\n    select(cell) {\n      return typeof cell === 'object'\n    },\n  },\n  computed: {\n    /**\n     * The number of columns in the picker\n     * @return {Number}\n     */\n    columns() {\n      return this.view === 'day' ? 7 : 3\n    },\n  },\n  methods: {\n    /**\n     * Set the classes for a specific cell\n     * @return {Array}\n     */\n    // eslint-disable-next-line complexity\n    cellClasses(cell) {\n      return [\n        'cell',\n        this.view,\n        {\n          'btn': this.bootstrapStyling,\n          'disabled': cell.isDisabled,\n          'highlight-start': cell.isHighlightStart,\n          'highlight-end': cell.isHighlightEnd,\n          'highlighted': cell.isHighlighted,\n          'muted': cell.isPreviousMonth || cell.isNextMonth,\n          'open': cell.isOpenDate,\n          'sat': cell.isSaturday,\n          'sun': cell.isSunday,\n          'selected': this.showEdgeDates\n            ? cell.isSelected\n            : cell.isSelected && !cell.isPreviousMonth && !cell.isNextMonth,\n          'today': this.showEdgeDates\n            ? cell.isToday\n            : cell.isToday && !cell.isPreviousMonth && !cell.isNextMonth,\n          'weekend': cell.isWeekend,\n        },\n      ]\n    },\n    /**\n     * Emits an `arrow` event\n     */\n    handleArrow(cellId, delta) {\n      this.$emit('arrow', { cellId, delta })\n    },\n    isTabbableCell(cell, id) {\n      if (!this.tabbableCellId) {\n        return cell.isOpenDate || null\n      }\n\n      return id === this.tabbableCellId || null\n    },\n  },\n}\n</script>\n","<template>\n  <div>\n    <div v-if=\"$slots.beforeCalendarHeaderDay\">\n      <slot name=\"beforeCalendarHeaderDay\" />\n    </div>\n\n    <PickerHeader\n      v-if=\"showHeader\"\n      ref=\"pickerHeader\"\n      :bootstrap-styling=\"bootstrapStyling\"\n      :is-next-disabled=\"isNextDisabled\"\n      :is-previous-disabled=\"isPreviousDisabled\"\n      :is-rtl=\"isRtl\"\n      :is-up-disabled=\"isUpDisabled\"\n      next-view-up=\"month\"\n      @focus-input=\"focusInput\"\n      @page-change=\"changePage($event)\"\n      @set-focus=\"$emit('setFocus', $event)\"\n      @set-view=\"$emit('setView', $event)\"\n    >\n      <template #prevIntervalBtn>\n        <slot name=\"prevIntervalBtn\" />\n      </template>\n      {{ pageTitleDay }}\n      <template #nextIntervalBtn>\n        <slot name=\"nextIntervalBtn\" />\n      </template>\n    </PickerHeader>\n\n    <div>\n      <div class=\"day-header\">\n        <span\n          v-for=\"day in daysOfWeek\"\n          :key=\"day\"\n        >\n          {{ day }}\n        </span>\n      </div>\n\n      <div class=\"cells-wrapper\">\n        <Transition :name=\"transitionName\">\n          <PickerCells\n            ref=\"cells\"\n            :key=\"pageTitleDay\"\n            v-slot=\"{ cell }\"\n            :bootstrap-styling=\"bootstrapStyling\"\n            :cells=\"cells\"\n            :is-rtl=\"isRtl\"\n            :show-edge-dates=\"showEdgeDates\"\n            :tabbable-cell-id=\"tabbableCellId\"\n            view=\"day\"\n            @arrow=\"handleArrow($event)\"\n            @select=\"select($event)\"\n          >\n            <slot\n              name=\"dayCellContent\"\n              :cell=\"cell\"\n            >\n              {{ dayCellContent(cell) }}\n            </slot>\n          </PickerCells>\n        </Transition>\n      </div>\n    </div>\n\n    <div v-if=\"$slots.calendarFooterDay\">\n      <slot name=\"calendarFooterDay\" />\n    </div>\n  </div>\n</template>\n\n<script>\nimport pickerMixin from '~/mixins/pickerMixin.vue'\nimport DisabledDate from '~/utils/DisabledDate'\nimport HighlightedDate from '~/utils/HighlightedDate'\nimport PickerCells from './PickerCells.vue'\n\nexport default {\n  name: 'PickerDay',\n  components: { PickerCells },\n  mixins: [pickerMixin],\n  props: {\n    dayCellContent: {\n      type: Function,\n      default: (day) => day.date,\n    },\n    firstDayOfWeek: {\n      type: String,\n      default: 'sun',\n    },\n    highlighted: {\n      type: Object,\n      default() {\n        return {}\n      },\n    },\n    showFullMonthName: {\n      type: Boolean,\n      default: false,\n    },\n    showEdgeDates: {\n      type: Boolean,\n      default: true,\n    },\n  },\n  emits: {\n    setFocus: (refArray) => {\n      return refArray.every((ref) => {\n        return ['input', 'prev', 'up', 'next', 'tabbableCell'].includes(ref)\n      })\n    },\n    setView: (view) => {\n      return view === 'month'\n    },\n  },\n  computed: {\n    /**\n     * Sets an array with all days to show this month\n     * @return {Array}\n     */\n    cells() {\n      const days = []\n      const daysInCalendar =\n        this.daysFromPrevMonth + this.daysInMonth + this.daysFromNextMonth\n      const dObj = this.firstDayCellDate()\n\n      for (let i = 0; i < daysInCalendar; i += 1) {\n        days.push(this.makeDay(dObj))\n        this.utils.setDate(dObj, this.utils.getDate(dObj) + 1)\n      }\n\n      return days\n    },\n    /**\n     * Gets the name of the month the current page is on\n     * @return {String}\n     */\n    currMonthName() {\n      const monthName = this.showFullMonthName\n        ? this.translation.months\n        : this.translation.monthsAbbr\n\n      return this.utils.getMonthNameAbbr(this.pageMonth, monthName)\n    },\n    /**\n     * Gets the name of the year that current page is on\n     * @return {String}\n     */\n    currYearName() {\n      const { yearSuffix } = this.translation\n      return `${this.pageYear}${yearSuffix}`\n    },\n    /**\n     * Returns an array of day names\n     * @return {String[]}\n     */\n    daysOfWeek() {\n      return this.translation.getDaysStartingOn(this.firstDayOfWeekNumber)\n    },\n    /**\n     * Returns the number of days in this month\n     * @return {String[]}\n     */\n    daysInMonth() {\n      return this.utils.getDaysInMonth(this.pageDate)\n    },\n    /**\n     * Calculates how many days to show from the previous month\n     * @return {number}\n     */\n    daysFromPrevMonth() {\n      const firstOfMonthDayNumber = this.utils.getDay(this.pageDate)\n      return (7 - this.firstDayOfWeekNumber + firstOfMonthDayNumber) % 7\n    },\n    /**\n     * Calculates how many days to show from the next month\n     * @return {number}\n     */\n    daysFromNextMonth() {\n      const daysThisAndPrevMonth = this.daysFromPrevMonth + this.daysInMonth\n      return Math.ceil(daysThisAndPrevMonth / 7) * 7 - daysThisAndPrevMonth\n    },\n    /**\n     * Returns first-day-of-week as a number (Sunday is 0)\n     * @return {Number}\n     */\n    firstDayOfWeekNumber() {\n      return this.utils.getDayFromAbbr(this.firstDayOfWeek)\n    },\n    /**\n     * The first day of the next page's month.\n     * @return {Date}\n     */\n    firstOfNextMonth() {\n      const d = new Date(this.pageDate)\n      return new Date(this.utils.setMonth(d, this.utils.getMonth(d) + 1))\n    },\n    /**\n     * Is the next month disabled?\n     * @return {Boolean}\n     */\n    isNextDisabled() {\n      if (!this.disabledConfig.has.from) {\n        return false\n      }\n\n      return this.latestPossibleDate < this.firstOfNextMonth\n    },\n    /**\n     * Is the previous month disabled?\n     * @return {Boolean}\n     */\n    isPreviousDisabled() {\n      if (!this.disabledConfig.has.to) {\n        return false\n      }\n\n      return this.earliestPossibleDate > this.lastOfPreviousMonth\n    },\n    /**\n     * The first day of the next page's month.\n     * @return {Date}\n     */\n    lastOfPreviousMonth() {\n      const d = new Date(this.pageDate)\n      return new Date(this.utils.setDate(d, 0))\n    },\n    /**\n     * Returns the current page's month as an integer.\n     * @return {Number}\n     */\n    pageMonth() {\n      return this.utils.getMonth(this.pageDate)\n    },\n    /**\n     * Display the current page's month & year as the title.\n     * @return {String}\n     */\n    pageTitleDay() {\n      return this.translation.ymd\n        ? `${this.currYearName} ${this.currMonthName}`\n        : `${this.currMonthName} ${this.currYearName}`\n    },\n  },\n  methods: {\n    /**\n     * Set up a new date object to the first day of the current 'page'\n     * @return {Date}\n     */\n    firstDayCellDate() {\n      const pageDate = new Date(this.pageDate)\n\n      return new Date(this.utils.setDate(pageDate, 1 - this.daysFromPrevMonth))\n    },\n    /**\n     * Whether a day is disabled\n     * @param {Date} date to check if disabled\n     * @return {Boolean}\n     */\n    isDisabledDate(date) {\n      if (!this.disabledDates) return false\n\n      return new DisabledDate(this.utils, this.disabledDates).isDateDisabled(\n        date,\n      )\n    },\n    /**\n     * Whether a day is highlighted (N.B. Disabled dates are not highlighted unless\n     * `highlighted.includeDisabled` is true)\n     * @param {Date} date to check if highlighted\n     * @return {Boolean}\n     */\n    isHighlightedDate(date) {\n      if (!this.highlighted) return false\n\n      return new HighlightedDate(\n        this.utils,\n        this.disabledDates,\n        this.highlighted,\n      ).isDateHighlighted(date)\n    },\n    /**\n     * Whether a date is the last in a range of highlighted dates\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isHighlightEnd(date) {\n      if (!this.highlighted) return false\n\n      return new HighlightedDate(\n        this.utils,\n        this.disabledDates,\n        this.highlighted,\n      ).isHighlightEnd(date)\n    },\n    /**\n     * Whether a date is the first in a range of highlighted dates\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isHighlightStart(date) {\n      if (!this.highlighted) return false\n\n      return new HighlightedDate(\n        this.utils,\n        this.disabledDates,\n        this.highlighted,\n      ).isHighlightStart(date)\n    },\n    /**\n     * Whether a day is selected\n     * @param {Date} dObj to check if selected\n     * @return {Boolean}\n     */\n    isSelectedDate(dObj) {\n      if (!this.selectedDate) return false\n\n      return this.utils.compareDates(this.selectedDate, dObj)\n    },\n    /**\n     * Defines the objects within the days array\n     * @param  {Date} dObj\n     * @return {Object}\n     */\n    // eslint-disable-next-line complexity\n    makeDay(dObj) {\n      const { utils } = this\n      const dayOfWeek = utils.getDay(dObj)\n      const isNextMonth = dObj >= this.firstOfNextMonth\n      const isPreviousMonth = dObj < this.pageDate\n      const isSaturday = dayOfWeek === 6\n      const isSunday = dayOfWeek === 0\n      const showDate = this.showEdgeDates || !(isPreviousMonth || isNextMonth)\n\n      return {\n        date: showDate ? utils.getDate(dObj) : '',\n        timestamp: dObj.valueOf(),\n        isSelected: this.isSelectedDate(dObj),\n        isDisabled: showDate ? this.isDisabledDate(dObj) : true,\n        isHighlighted: this.isHighlightedDate(dObj),\n        isHighlightStart: this.isHighlightStart(dObj),\n        isHighlightEnd: this.isHighlightEnd(dObj),\n        isOpenDate: utils.compareDates(dObj, this.openDate),\n        isToday: utils.compareDates(dObj, utils.getNewDateObject()),\n        isWeekend: isSaturday || isSunday,\n        isSaturday,\n        isSunday,\n        isPreviousMonth,\n        isNextMonth,\n      }\n    },\n  },\n}\n</script>\n","<template>\n  <div>\n    <div v-if=\"$slots.beforeCalendarHeaderMonth\">\n      <slot name=\"beforeCalendarHeaderMonth\" />\n    </div>\n\n    <PickerHeader\n      v-if=\"showHeader\"\n      ref=\"pickerHeader\"\n      :bootstrap-styling=\"bootstrapStyling\"\n      :is-next-disabled=\"isNextDisabled\"\n      :is-previous-disabled=\"isPreviousDisabled\"\n      :is-rtl=\"isRtl\"\n      :is-up-disabled=\"isUpDisabled\"\n      next-view-up=\"year\"\n      @focus-input=\"focusInput\"\n      @page-change=\"changePage($event)\"\n      @set-focus=\"$emit('setFocus', $event)\"\n      @set-view=\"$emit('setView', $event)\"\n    >\n      <template #prevIntervalBtn>\n        <slot name=\"prevIntervalBtn\" />\n      </template>\n      {{ pageTitleMonth }}\n      <template #nextIntervalBtn>\n        <slot name=\"nextIntervalBtn\" />\n      </template>\n    </PickerHeader>\n\n    <div class=\"cells-wrapper\">\n      <Transition :name=\"transitionName\">\n        <PickerCells\n          ref=\"cells\"\n          :key=\"pageTitleMonth\"\n          v-slot=\"{ cell }\"\n          :bootstrap-styling=\"bootstrapStyling\"\n          :cells=\"cells\"\n          :is-rtl=\"isRtl\"\n          :tabbable-cell-id=\"tabbableCellId\"\n          view=\"month\"\n          @arrow=\"handleArrow($event)\"\n          @select=\"select($event)\"\n        >\n          {{ cell.month }}\n        </PickerCells>\n      </Transition>\n    </div>\n\n    <div v-if=\"$slots.calendarFooterMonth\">\n      <slot name=\"calendarFooterMonth\" />\n    </div>\n  </div>\n</template>\n\n<script>\nimport pickerMixin from '~/mixins/pickerMixin.vue'\nimport DisabledDate from '~/utils/DisabledDate'\nimport PickerCells from './PickerCells.vue'\n\nexport default {\n  name: 'PickerMonth',\n  components: { PickerCells },\n  mixins: [pickerMixin],\n  emits: {\n    setFocus: (refArray) => {\n      return refArray.every((ref) => {\n        return ['input', 'prev', 'up', 'next', 'tabbableCell'].includes(ref)\n      })\n    },\n    setView: (view) => {\n      return view === 'year'\n    },\n  },\n  computed: {\n    /**\n     * Sets an array with all months to show this year\n     * @return {Array}\n     */\n    cells() {\n      const { utils } = this\n      const months = []\n      const dObj = this.firstMonthCellDate()\n\n      for (let i = 0; i < 12; i += 1) {\n        months.push({\n          month: utils.getMonthName(i, this.translation.months),\n          timestamp: dObj.valueOf(),\n          isDisabled: this.isDisabledMonth(dObj),\n          isOpenDate: this.isOpenMonth(dObj),\n          isSelected: this.isSelectedMonth(dObj),\n          isToday: this.isTodayMonth(dObj),\n        })\n        utils.setMonth(dObj, utils.getMonth(dObj) + 1)\n      }\n\n      return months\n    },\n    /**\n     * Is the next year disabled?\n     * @return {Boolean}\n     */\n    isNextDisabled() {\n      if (!this.disabledConfig.has.from) {\n        return false\n      }\n      return this.latestPossibleDate <= new Date(this.pageYear, 11, 31)\n    },\n    /**\n     * Is the previous year disabled?\n     * @return {Boolean}\n     */\n    isPreviousDisabled() {\n      if (!this.disabledConfig.has.to) {\n        return false\n      }\n      return this.earliestPossibleDate >= new Date(this.pageYear, 0, 1)\n    },\n    /**\n     * Display the current page's year as the title.\n     * @return {String}\n     */\n    pageTitleMonth() {\n      const { yearSuffix } = this.translation\n      return `${this.pageYear}${yearSuffix}`\n    },\n  },\n  methods: {\n    /**\n     * Set up a new date object to the first month of the current 'page'\n     * @return {Date}\n     */\n    firstMonthCellDate() {\n      const pageDate = new Date(this.pageDate)\n\n      return new Date(this.utils.setMonth(pageDate, 0))\n    },\n    /**\n     * Whether a month is disabled\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isDisabledMonth(date) {\n      if (!this.disabledDates) return false\n\n      return new DisabledDate(this.utils, this.disabledDates).isMonthDisabled(\n        date,\n      )\n    },\n    /**\n     * Should the calendar open on this month?\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isOpenMonth(date) {\n      if (!this.openDate) return false\n\n      const openDateMonth = this.utils.getMonth(this.openDate)\n      const openDateYear = this.utils.getFullYear(this.openDate)\n      const thisDateMonth = this.utils.getMonth(date)\n      const thisDateYear = this.utils.getFullYear(date)\n\n      return openDateMonth === thisDateMonth && openDateYear === thisDateYear\n    },\n    /**\n     * Whether the selected date is in this month\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isSelectedMonth(date) {\n      if (!this.selectedDate) return false\n\n      const month = this.utils.getMonth(date)\n      const year = this.utils.getFullYear(date)\n\n      return (\n        this.selectedDate &&\n        year === this.utils.getFullYear(this.selectedDate) &&\n        month === this.utils.getMonth(this.selectedDate)\n      )\n    },\n    /**\n     * Whether the date has the same month and year as today's date\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isTodayMonth(date) {\n      const { utils } = this\n      const todayMonth = new Date(utils.setDate(utils.getNewDateObject(), 1))\n\n      return utils.compareDates(date, todayMonth)\n    },\n  },\n}\n</script>\n","<template>\n  <div>\n    <div v-if=\"$slots.beforeCalendarHeaderYear\">\n      <slot name=\"beforeCalendarHeaderYear\" />\n    </div>\n\n    <PickerHeader\n      v-if=\"showHeader\"\n      ref=\"pickerHeader\"\n      :bootstrap-styling=\"bootstrapStyling\"\n      :is-next-disabled=\"isNextDisabled\"\n      :is-previous-disabled=\"isPreviousDisabled\"\n      :is-rtl=\"isRtl\"\n      :is-up-disabled=\"true\"\n      @focus-input=\"focusInput\"\n      @page-change=\"changePage($event)\"\n      @set-focus=\"$emit('setFocus', $event)\"\n    >\n      <template #prevIntervalBtn>\n        <slot name=\"prevIntervalBtn\" />\n      </template>\n      {{ pageTitleYear }}\n      <template #nextIntervalBtn>\n        <slot name=\"nextIntervalBtn\" />\n      </template>\n    </PickerHeader>\n\n    <div class=\"cells-wrapper\">\n      <Transition :name=\"transitionName\">\n        <PickerCells\n          ref=\"cells\"\n          :key=\"pageTitleYear\"\n          v-slot=\"{ cell }\"\n          :bootstrap-styling=\"bootstrapStyling\"\n          :cells=\"cells\"\n          :is-rtl=\"isRtl\"\n          :tabbable-cell-id=\"tabbableCellId\"\n          view=\"year\"\n          @arrow=\"handleArrow($event)\"\n          @select=\"select($event)\"\n        >\n          {{ cell.year }}\n        </PickerCells>\n      </Transition>\n    </div>\n\n    <div v-if=\"$slots.calendarFooterYear\">\n      <slot name=\"calendarFooterYear\" />\n    </div>\n  </div>\n</template>\n\n<script>\nimport pickerMixin from '~/mixins/pickerMixin.vue'\nimport DisabledDate from '~/utils/DisabledDate'\nimport PickerCells from './PickerCells.vue'\n\nexport default {\n  name: 'PickerYear',\n  components: { PickerCells },\n  mixins: [pickerMixin],\n  props: {\n    yearRange: {\n      type: Number,\n      default: 10,\n    },\n  },\n  emits: {\n    setFocus: (refArray) => {\n      return refArray.every((ref) => {\n        return ['input', 'prev', 'up', 'next', 'tabbableCell'].includes(ref)\n      })\n    },\n  },\n  computed: {\n    /**\n     * Sets an array with all years to show this decade (or yearRange)\n     * @return {Array}\n     */\n    cells() {\n      const { utils } = this\n      const years = []\n      const dObj = this.firstYearCellDate()\n\n      for (let i = 0; i < this.yearRange; i += 1) {\n        years.push({\n          year: utils.getFullYear(dObj),\n          timestamp: dObj.valueOf(),\n          isDisabled: this.isDisabledYear(dObj),\n          isOpenDate: this.isOpenYear(dObj),\n          isSelected: this.isSelectedYear(dObj),\n          isToday: this.isTodayYear(dObj),\n        })\n        utils.setFullYear(dObj, utils.getFullYear(dObj) + 1)\n      }\n\n      // Fill any remaining cells with blanks to position trailing cells correctly when rtl\n      const cellsInGrid = Math.ceil(this.yearRange / 3) * 3\n      for (let i = years.length; i < cellsInGrid; i += 1) {\n        years.push({\n          id: i,\n          isDisabled: true,\n        })\n      }\n\n      return years\n    },\n    /**\n     * Is the next decade disabled?\n     * @return {Boolean}\n     */\n    isNextDisabled() {\n      if (!this.disabledConfig.has.from) {\n        return false\n      }\n      const firstDayOfNextDecade = new Date(this.pageDecadeEnd + 1, 0, 1)\n      return this.latestPossibleDate < firstDayOfNextDecade\n    },\n    /**\n     * Is the previous decade disabled?\n     * @return {Boolean}\n     */\n    isPreviousDisabled() {\n      if (!this.disabledConfig.has.to) {\n        return false\n      }\n      const lastDayOfPreviousDecade = new Date(this.pageDecadeStart - 1, 11, 31)\n      return this.earliestPossibleDate > lastDayOfPreviousDecade\n    },\n    /**\n     * The year at which the current yearRange starts\n     * @return {Number}\n     */\n    pageDecadeStart() {\n      return Math.floor(this.pageYear / this.yearRange) * this.yearRange\n    },\n    /**\n     * The year at which the current yearRange ends\n     * @return {Number}\n     */\n    pageDecadeEnd() {\n      return this.pageDecadeStart + this.yearRange - 1\n    },\n    /**\n     * Display the current page's decade (or year range) as the title.\n     * @return {String}\n     */\n    pageTitleYear() {\n      const { yearSuffix } = this.translation\n      return `${this.pageDecadeStart} - ${this.pageDecadeEnd}${yearSuffix}`\n    },\n  },\n  methods: {\n    /**\n     * Set up a new date object to the first year of the current 'page'\n     * @return {Date}\n     */\n    firstYearCellDate() {\n      const { utils } = this\n      const pageDate = new Date(this.pageDate)\n      const firstYear =\n        Math.floor(utils.getFullYear(pageDate) / this.yearRange) *\n        this.yearRange\n\n      const date = new Date(utils.setFullYear(pageDate, firstYear))\n\n      return this.utils.adjustDateToView(date, 'year')\n    },\n    /**\n     * Whether a year is disabled\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isDisabledYear(date) {\n      if (!this.disabledDates) return false\n\n      return new DisabledDate(this.utils, this.disabledDates).isYearDisabled(\n        date,\n      )\n    },\n    /**\n     * Should the calendar open on this year?\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isOpenYear(date) {\n      if (!this.openDate) return false\n\n      const openDateYear = this.utils.getFullYear(this.openDate)\n      const thisDateYear = this.utils.getFullYear(date)\n\n      return openDateYear === thisDateYear\n    },\n    /**\n     * Whether the selected date is in this year\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isSelectedYear(date) {\n      if (!this.selectedDate) return false\n\n      const year = this.utils.getFullYear(date)\n\n      return (\n        this.selectedDate && year === this.utils.getFullYear(this.selectedDate)\n      )\n    },\n    /**\n     * Whether the date has the same year as today's date\n     * @param {Date} date\n     * @return {Boolean}\n     */\n    isTodayYear(date) {\n      const { utils } = this\n      const todayYear = utils.getFullYear(utils.getNewDateObject())\n\n      return utils.getFullYear(date) === todayYear\n    },\n  },\n}\n</script>\n","<script>\nimport { h } from 'vue'\nimport { getPopupElementSize, getRelativePosition } from '~/utils/dom'\n\nexport default {\n  // eslint-disable-next-line vue/multi-word-component-names\n  name: 'Popup',\n  props: {\n    appendToBody: {\n      type: Boolean,\n      default: true,\n    },\n    fixedPosition: {\n      type: String,\n      default: '',\n    },\n    inline: {\n      type: Boolean,\n      default: false,\n    },\n    rtl: {\n      type: Boolean,\n      default: false,\n    },\n    visible: {\n      type: Boolean,\n      default: false,\n    },\n  },\n  data() {\n    return {\n      popupRect: null,\n    }\n  },\n  watch: {\n    visible: {\n      immediate: true,\n      handler(val) {\n        if (val) {\n          this.displayPopup()\n        }\n      },\n    },\n  },\n  mounted() {\n    if (this.inline) {\n      return\n    }\n    if (this.appendToBody) {\n      document.body.appendChild(this.$el)\n    }\n  },\n  beforeUnmount() {\n    if (this.inline) {\n      return\n    }\n    if (this.appendToBody && this.$el.parentNode) {\n      this.$el.parentNode.removeChild(this.$el)\n    }\n  },\n  methods: {\n    /**\n     * Adjusts the popup's `top` style attribute when `append-to-body` is true\n     */\n    setTopStyle() {\n      if (this.appendToBody) {\n        const relativeRect = this.$parent.$el.getBoundingClientRect()\n        this.$el.style.top = `${relativeRect.bottom + window.scrollY}px`\n      }\n    },\n    /**\n     * Sets the `left` and `top` style attributes of the popup\n     */\n    displayPopup() {\n      if (this.inline || !this.visible) return\n      this.setTopStyle()\n      const popup = this.$el.children[0]\n      const relativeElement = this.$parent.$el\n      if (!this.popupRect) {\n        this.popupRect = getPopupElementSize(popup)\n      }\n      const { width, height } = this.popupRect\n      const { left, top } = getRelativePosition({\n        el: popup,\n        elRelative: relativeElement,\n        targetWidth: width,\n        targetHeight: height,\n        appendToBody: this.appendToBody,\n        fixedPosition: this.fixedPosition,\n        rtl: this.rtl,\n      })\n\n      popup.style.left = left\n      popup.style.top = top\n    },\n  },\n  render() {\n    return h('div', this.$slots.default()[0].children.default())\n  },\n}\n</script>\n","<template>\n  <div\n    :id=\"datepickerId\"\n    ref=\"datepicker\"\n    class=\"vdp-datepicker\"\n    :class=\"[wrapperClass, { rtl: isRtl }]\"\n    @focusin=\"handleFocusIn($event)\"\n    @focusout=\"handleFocusOut($event)\"\n    @keydown.esc=\"resetOrClose\"\n  >\n    <DateInput\n      :id=\"id\"\n      ref=\"dateInput\"\n      :autofocus=\"autofocus\"\n      :bootstrap-styling=\"bootstrapStyling\"\n      :calendar-button=\"calendarButton\"\n      :clear-button=\"clearButton\"\n      :disabled=\"disabled\"\n      :format=\"format\"\n      :inline=\"inline\"\n      :input-class=\"inputClass\"\n      :is-open=\"isOpen\"\n      :maxlength=\"maxlength\"\n      :name=\"name\"\n      :parser=\"parser\"\n      :pattern=\"pattern\"\n      :placeholder=\"placeholder\"\n      :ref-name=\"refName\"\n      :required=\"required\"\n      :selected-date=\"selectedDate\"\n      :show-calendar-on-button-click=\"showCalendarOnButtonClick\"\n      :show-calendar-on-focus=\"showCalendarOnFocus\"\n      :slide-duration=\"slideDuration\"\n      :tabindex=\"tabindex\"\n      :translation=\"translation\"\n      :typeable=\"typeable\"\n      :use-utc=\"useUtc\"\n      @clear-date=\"clearDate\"\n      @close=\"close\"\n      @open=\"open\"\n      @select-typed-date=\"selectTypedDate\"\n      @set-focus=\"setFocus($event)\"\n      @tab=\"tabThroughNavigation\"\n      @typed-date=\"handleTypedDate\"\n    >\n      <template #beforeDateInput>\n        <slot name=\"beforeDateInput\" />\n      </template>\n\n      <template #afterDateInput>\n        <slot name=\"afterDateInput\" />\n      </template>\n\n      <template #clearBtn>\n        <slot name=\"clearBtn\" />\n      </template>\n\n      <template #calendarBtn>\n        <slot name=\"calendarBtn\" />\n      </template>\n    </DateInput>\n\n    <Popup\n      ref=\"popup\"\n      :append-to-body=\"appendToBody\"\n      :fixed-position=\"fixedPosition\"\n      :inline=\"inline\"\n      :rtl=\"isRtl\"\n      :visible=\"isOpen\"\n      @keydown.delete=\"clearDate\"\n    >\n      <Transition name=\"toggle\">\n        <div\n          v-show=\"isOpen\"\n          class=\"vdp-datepicker__calendar\"\n          :class=\"pickerClasses\"\n          data-test-calendar\n          @mousedown.prevent\n          @focusin.stop=\"handleFocusIn($event)\"\n          @focusout.stop=\"handleFocusOut($event)\"\n          @keydown.esc.stop=\"resetOrClose\"\n          @keydown.tab.stop=\"tabThroughNavigation($event)\"\n        >\n          <Transition name=\"view\">\n            <div\n              ref=\"view\"\n              :key=\"view\"\n            >\n              <div v-if=\"$slots.beforeCalendarHeader\">\n                <slot name=\"beforeCalendarHeader\" />\n              </div>\n              <Component\n                :is=\"picker\"\n                ref=\"picker\"\n                :bootstrap-styling=\"bootstrapStyling\"\n                class=\"picker-view\"\n                :day-cell-content=\"dayCellContent\"\n                :disabled-dates=\"disabledDates\"\n                :first-day-of-week=\"firstDayOfWeek\"\n                :highlighted=\"highlighted\"\n                :is-rtl=\"isRtl\"\n                :is-typeable=\"typeable\"\n                :is-up-disabled=\"isUpDisabled\"\n                :is-minimum-view=\"isMinimumView\"\n                :open-date=\"computedOpenDate\"\n                :page-date=\"pageDate\"\n                :selected-date=\"selectedDate\"\n                :show-edge-dates=\"showEdgeDates\"\n                :show-full-month-name=\"fullMonthName\"\n                :show-header=\"showHeader\"\n                :slide-duration=\"slideDuration\"\n                :tabbable-cell-id=\"tabbableCellId\"\n                :transition-name=\"transitionName\"\n                :translation=\"translation\"\n                :use-utc=\"useUtc\"\n                :view=\"view || computedInitialView\"\n                :year-range=\"yearPickerRange\"\n                @page-change=\"handlePageChange\"\n                @select=\"handleSelect\"\n                @set-focus=\"setFocus($event)\"\n                @set-skip-review-focus=\"skipReviewFocus = $event\"\n                @set-transition-name=\"setTransitionName($event)\"\n                @set-view=\"setView\"\n              >\n                <template\n                  v-for=\"slotKey of usedCalendarSlots\"\n                  #[slotKey]\n                >\n                  <slot :name=\"slotKey\" />\n                </template>\n                <template #dayCellContent=\"{ cell }\">\n                  <slot\n                    v-if=\"cell\"\n                    name=\"dayCellContent\"\n                    :cell=\"cell\"\n                  />\n                </template>\n              </Component>\n              <div v-if=\"$slots.calendarFooter\">\n                <slot name=\"calendarFooter\" />\n              </div>\n            </div>\n          </Transition>\n        </div>\n      </Transition>\n    </Popup>\n  </div>\n</template>\n\n<script>\nimport en from '~/locale/translations/en'\nimport calendarSlots from '~/utils/calendarSlots'\nimport DateInput from '~/components/DateInput.vue'\nimport DisabledDate from '~/utils/DisabledDate'\nimport inputProps from '~/mixins/inputProps.vue'\nimport makeDateUtils from '~/utils/DateUtils'\nimport navMixin from '~/mixins/navMixin.vue'\nimport PickerDay from '~/components/PickerDay.vue'\nimport PickerMonth from '~/components/PickerMonth.vue'\nimport PickerYear from '~/components/PickerYear.vue'\nimport Popup from '~/components/Popup.vue'\n\nexport default {\n  name: 'DatePicker',\n  components: {\n    DateInput,\n    PickerDay,\n    PickerMonth,\n    PickerYear,\n    Popup,\n  },\n  mixins: [inputProps, navMixin],\n  props: {\n    appendToBody: {\n      type: Boolean,\n      default: false,\n    },\n    calendarClass: {\n      type: [String, Object, Array],\n      default: '',\n    },\n    dayCellContent: {\n      type: Function,\n      default: (day) => day.date,\n    },\n    disabledDates: {\n      type: Object,\n      default: null,\n    },\n    firstDayOfWeek: {\n      type: String,\n      default: 'sun',\n    },\n    fixedPosition: {\n      type: String,\n      default: '',\n      validator: (val) => {\n        const possibleValues = [\n          '',\n          'bottom',\n          'bottom-left',\n          'bottom-right',\n          'top',\n          'top-left',\n          'top-right',\n        ]\n        return possibleValues.includes(val)\n      },\n    },\n    fullMonthName: {\n      type: Boolean,\n      default: null,\n    },\n    highlighted: {\n      type: Object,\n      default: null,\n    },\n    initialView: {\n      type: String,\n      default: '',\n    },\n    language: {\n      type: Object,\n      default: () => en,\n    },\n    maximumView: {\n      type: String,\n      default: 'year',\n    },\n    minimumView: {\n      type: String,\n      default: 'day',\n    },\n    modelValue: {\n      type: [String, Date, Number],\n      default: null,\n    },\n    showEdgeDates: {\n      type: Boolean,\n      default: true,\n    },\n    showHeader: {\n      type: Boolean,\n      default: true,\n    },\n    wrapperClass: {\n      type: [String, Object, Array],\n      default: '',\n    },\n    yearPickerRange: {\n      type: Number,\n      default: 10,\n    },\n  },\n  emits: {\n    'blur': null,\n    'changed': null,\n    'cleared': null,\n    'closed': null,\n    'focus': null,\n    'opened': null,\n    'changedMonth': (date) => {\n      return typeof date === 'object'\n    },\n    'changedYear': (date) => {\n      return typeof date === 'object'\n    },\n    'changedDecade': (date) => {\n      return typeof date === 'object'\n    },\n    'selected': (date) => {\n      return date instanceof Date || date === null\n    },\n    'update:modelValue': (date) => {\n      return date instanceof Date || date === null\n    },\n  },\n  data() {\n    const utils = makeDateUtils(this.useUtc)\n    const initialView = this.initialView || this.minimumView\n    const openDate = utils.getOpenDate(\n      this.openDate,\n      this.selectedDate,\n      initialView,\n    )\n\n    const pageTimestamp = utils.setDate(openDate, 1)\n\n    return {\n      calendarHeight: 0,\n      isClickOutside: false,\n      globalDatepickerId: '',\n      /*\n       * The latest valid `typedDate` (used for typeable datepicker)\n       * {Date}\n       */\n      latestValidTypedDate: null,\n      /*\n       * Vue cannot observe changes to a Date Object so date must be stored as a timestamp\n       * This represents the first day of the current viewing month\n       * {Number}\n       */\n      pageTimestamp,\n      /*\n       * Selected Date\n       * {Date}\n       */\n      selectedDate: null,\n      slideDuration: 250,\n      utils,\n      view: '',\n    }\n  },\n  computed: {\n    computedInitialView() {\n      return this.initialView || this.minimumView\n    },\n    computedOpenDate() {\n      return this.utils.getOpenDate(\n        this.openDate,\n        this.selectedDate,\n        this.minimumView,\n      )\n    },\n    datepickerId() {\n      return `vdp-${Math.random().toString(36).slice(-10)}`\n    },\n    isInline() {\n      return !!this.inline\n    },\n    isOpen() {\n      return this.view !== ''\n    },\n    isMinimumView() {\n      return this.view === this.minimumView\n    },\n    isRtl() {\n      return this.translation.rtl\n    },\n    isUpDisabled() {\n      return !this.allowedToShowView(this.nextView.up)\n    },\n    nextView() {\n      const views = ['day', 'month', 'year']\n      const isCurrentView = (view) => view === this.view\n      const viewIndex = views.findIndex(isCurrentView)\n      const nextViewDown = (index) => {\n        return index <= 0 ? undefined : views[index - 1]\n      }\n      const nextViewUp = (index) => {\n        if (index < 0) {\n          return undefined\n        }\n\n        if (index === views.length - 1) {\n          return 'decade'\n        }\n\n        return views[index + 1]\n      }\n\n      return {\n        up: nextViewUp(viewIndex),\n        down: nextViewDown(viewIndex),\n      }\n    },\n    pageDate() {\n      return new Date(this.pageTimestamp)\n    },\n    picker() {\n      const view = this.view || this.computedInitialView\n      return `Picker${this.ucFirst(view)}`\n    },\n    pickerClasses() {\n      return [\n        this.calendarClass,\n        this.isInline && 'vdp-datepicker__calendar--inline',\n        this.isRtl && this.appendToBody && 'rtl',\n      ]\n    },\n    translation() {\n      return this.language\n    },\n    usedCalendarSlots() {\n      return calendarSlots.filter((slot) => this.hasSlot(slot))\n    },\n  },\n  watch: {\n    disabledDates: {\n      // eslint-disable-next-line complexity\n      handler() {\n        const selectedDate =\n          this.selectedDate || this.utils.parseAsDate(this.modelValue)\n\n        if (!selectedDate) {\n          return\n        }\n\n        if (this.isDateDisabled(selectedDate) && selectedDate) {\n          this.selectDate(null)\n          return\n        }\n\n        if (this.dateHasChanged(selectedDate)) {\n          this.selectDate(selectedDate)\n        }\n      },\n      deep: true,\n    },\n    initialView() {\n      if (this.isOpen) {\n        this.setInitialView()\n      }\n    },\n    inline(isInline) {\n      if (!isInline) {\n        this.close()\n      }\n      this.setInitialView()\n    },\n    isActive(hasJustBecomeActive, isNoLongerActive) {\n      if (hasJustBecomeActive) {\n        this.datepickerIsActive()\n      }\n\n      if (isNoLongerActive) {\n        this.datepickerIsInactive()\n      }\n    },\n    latestValidTypedDate(date) {\n      this.setPageDate(date)\n    },\n    modelValue: {\n      handler(newValue, oldValue) {\n        let parsedValue = this.utils.parseAsDate(newValue)\n        const oldParsedValue = this.utils.parseAsDate(oldValue)\n\n        if (!this.utils.compareDates(parsedValue, oldParsedValue)) {\n          const isDateDisabled = parsedValue && this.isDateDisabled(parsedValue)\n\n          if (isDateDisabled) {\n            parsedValue = null\n          }\n          this.setValue(parsedValue)\n        }\n      },\n      immediate: true,\n    },\n    openDate() {\n      this.setPageDate()\n    },\n    view(newView, oldView) {\n      if (oldView === '') {\n        this.setPageDate(this.utils.adjustDateToView(this.computedOpenDate))\n      }\n      this.handleViewChange(newView, oldView)\n    },\n  },\n  mounted() {\n    this.init()\n    document.addEventListener('click', this.handleClickOutside)\n  },\n  beforeUnmount() {\n    document.removeEventListener('click', this.handleClickOutside)\n  },\n  methods: {\n    /**\n     * Are we allowed to show a specific picker view?\n     * @param {String} view\n     * @return {Boolean}\n     */\n    allowedToShowView(view) {\n      const views = ['day', 'month', 'year']\n      const minimumViewIndex = views.indexOf(this.minimumView)\n      const maximumViewIndex = views.indexOf(this.maximumView)\n      const viewIndex = views.indexOf(view)\n\n      return viewIndex >= minimumViewIndex && viewIndex <= maximumViewIndex\n    },\n    /**\n     * Clear the selected date\n     */\n    clearDate() {\n      if (!this.selectedDate) {\n        return\n      }\n\n      const { focusedDateTimestamp } = this\n\n      this.selectDate(null)\n\n      if (this.isInline) {\n        this.resetFocusToOpenDate(focusedDateTimestamp)\n      } else {\n        this.focus.refs = ['input']\n        this.close()\n      }\n\n      this.$emit('cleared')\n    },\n    /**\n     * Close the calendar\n     */\n    close() {\n      if (this.isInline) {\n        return\n      }\n\n      this.view = ''\n\n      if (this.showCalendarOnFocus) {\n        this.$refs.dateInput.shouldToggleOnClick = true\n        this.$refs.dateInput.shouldToggleOnFocus = true\n      }\n\n      if (this.isClickOutside) {\n        this.isClickOutside = false\n      } else {\n        this.reviewFocus()\n      }\n\n      this.$emit('closed')\n    },\n    /**\n     * Returns true if the given date differs from the `selectedDate`\n     * @param   {Date} date The date to check\n     * @returns {Boolean}\n     */\n    dateHasChanged(date) {\n      return !this.utils.compareDates(date, this.selectedDate)\n    },\n    /**\n     * Emits `focus` when the datepicker receives focus (and for an `inline`\n     * datepicker, ensures the correct cell is tabbed to)\n     */\n    datepickerIsActive() {\n      this.$emit('focus')\n\n      if (this.inline) {\n        this.setNavElementsFocusedIndex()\n        this.tabToCorrectInlineCell()\n      }\n    },\n    /**\n     * Emits `blur` when the datepicker loses focus (and selects a typed date)\n     */\n    datepickerIsInactive() {\n      this.$emit('blur')\n\n      if (this.typeable) {\n        this.skipReviewFocus = true\n        this.selectTypedDateOnLosingFocus()\n\n        this.$nextTick(() => {\n          this.skipReviewFocus = false\n        })\n      }\n    },\n    /**\n     * Closes the calendar when no element within it has focus\n     */\n    handleClickOutside() {\n      if (!this.isOpen) {\n        return\n      }\n\n      const closeByClickOutside = () => {\n        this.isClickOutside = true\n        this.close()\n      }\n\n      if (!this.globalDatepickerId) {\n        closeByClickOutside()\n        return\n      }\n\n      if (document.datepickerId.toString() === this.datepickerId) {\n        this.$nextTick(() => {\n          if (!this.isActive) {\n            closeByClickOutside()\n          }\n        })\n      }\n    },\n    /**\n     * Set the new pageDate, focus the relevant element and emit a `changed-<view>` event\n     */\n    handlePageChange({ focusRefs, pageDate }) {\n      this.setPageDate(pageDate)\n      this.focus.refs = focusRefs\n      this.focus.delay = this.slideDuration\n      this.reviewFocus()\n      this.$emit(`changed${this.ucFirst(this.nextView.up)}`, pageDate)\n    },\n    /**\n     * Set the date, or go to the next view down\n     */\n    // eslint-disable-next-line max-statements,complexity\n    handleSelect(cell) {\n      if (this.allowedToShowView(this.nextView.down)) {\n        this.showNextViewDown(cell)\n        return\n      }\n\n      this.$refs.dateInput.typedDate = ''\n      const date = new Date(cell.timestamp)\n\n      if (this.isInline && !this.dateHasChanged(date)) {\n        this.selectedDate = null\n        this.$emit('cleared')\n        return\n      }\n\n      this.selectDate(date)\n      this.focus.delay = cell.isNextMonth ? this.slideDuration : 0\n      this.focus.refs = this.isInline ? ['tabbableCell'] : ['input']\n      this.close()\n\n      if (this.showCalendarOnFocus && !this.inline) {\n        this.$refs.dateInput.shouldToggleOnClick = true\n        this.$refs.dateInput.shouldToggleOnFocus = false\n      } else {\n        this.reviewFocus()\n      }\n    },\n    /**\n     * Updates the page (if necessary) after a 'typedDate' event and sets `tabbableCell` & `latestValidTypedDate`\n     * @param {Date=} date\n     */\n    handleTypedDate(date) {\n      const originalTypedDate = new Date(this.latestValidTypedDate)\n      const originalPageDate = new Date(this.pageDate)\n\n      this.latestValidTypedDate = date || this.computedOpenDate\n      this.setTransitionAndFocusDelay(\n        originalTypedDate,\n        this.latestValidTypedDate,\n      )\n      this.setPageDate(date)\n\n      if (this.isPageChange(originalPageDate)) {\n        this.handlePageChange({\n          focusRefs: [],\n          pageDate: this.pageDate,\n        })\n        return\n      }\n\n      this.setTabbableCell()\n    },\n    /**\n     * Focus the relevant element when the view changes\n     * @param {String} newView\n     * @param {String} oldView\n     */\n    handleViewChange(newView, oldView) {\n      const isClosing = newView === ''\n      const isOpeningInline = oldView === '' && this.isInline\n\n      if (isClosing || isOpeningInline) {\n        return\n      }\n\n      if (!this.isRevertingToOpenDate) {\n        this.setViewChangeFocusRefs(newView, oldView)\n        this.reviewFocus()\n      }\n\n      this.isRevertingToOpenDate = false\n    },\n    /**\n     * Returns true if element has the given className\n     * @param   {HTMLElement} element\n     * @param   {String}      className\n     * @returns {Boolean}\n     */\n    hasClass(element, className) {\n      return element && element.className.split(' ').includes(className)\n    },\n    /**\n     * Used for typeable datepicker: returns true if a typed date causes the page to change\n     * @param   {Date}    originalPageDate\n     * @returns {Boolean}\n     */\n    isPageChange(originalPageDate) {\n      if (!this.isOpen) {\n        return false\n      }\n\n      return originalPageDate.valueOf() !== this.pageDate.valueOf()\n    },\n    /**\n     * Initiate the component\n     */\n    init() {\n      if (this.typeable) {\n        this.latestValidTypedDate = this.selectedDate || this.computedOpenDate\n      }\n\n      if (this.isInline) {\n        this.setInitialView()\n      }\n\n      this.setSlideDuration()\n    },\n    /**\n     * Returns true if a date is disabled\n     * @param {Date} date\n     * @returns {Boolean}\n     */\n    isDateDisabled(date) {\n      if (!this.disabledDates) return false\n\n      return new DisabledDate(this.utils, this.disabledDates).isDateDisabled(\n        date,\n      )\n    },\n    /**\n     * Returns true if we should reset the focus to computedOpenDate\n     * @returns {Boolean}\n     */\n    isResetFocus() {\n      if (!this.isOpen) {\n        return false\n      }\n\n      const activeElement = this.getActiveElement()\n      const isOpenCellFocused =\n        this.hasClass(activeElement, 'cell') &&\n        !this.hasClass(activeElement, 'open')\n\n      return this.isInline || !this.isMinimumView || isOpenCellFocused\n    },\n    /**\n     * Opens the calendar with the relevant view: 'day', 'month', or 'year'\n     */\n    open() {\n      if (this.disabled || this.isInline) {\n        return\n      }\n\n      this.setInitialView()\n      this.reviewFocus()\n\n      this.$emit('opened')\n    },\n    /**\n     * Focus the open date, or close the calendar if already focused\n     */\n    resetOrClose() {\n      if (this.isResetFocus()) {\n        this.resetFocusToOpenDate(this.focusedDateTimestamp)\n        return\n      }\n\n      if (this.isOpen) {\n        this.focus.refs = ['input']\n        this.close()\n      }\n    },\n    /**\n     * Select the date\n     * @param {Date|null} date\n     */\n    selectDate(date) {\n      if (this.dateHasChanged(date)) {\n        this.$emit('changed', date)\n      }\n\n      this.setValue(date)\n      this.$emit('selected', date)\n      this.$emit('update:modelValue', date)\n    },\n    /**\n     * Select the date from a 'selectTypedDate' event\n     * @param {Date=} date\n     */\n    selectTypedDate(date) {\n      this.selectDate(date)\n      this.reviewFocus()\n\n      if (this.isOpen) {\n        this.close()\n      }\n    },\n    /**\n     * Selects the typed date when the datepicker loses focus, provided it's valid and differs from the current selected date\n     */\n    selectTypedDateOnLosingFocus() {\n      const parsedDate = this.$refs.dateInput.parseInput()\n      const date = this.utils.isValidDate(parsedDate) ? parsedDate : null\n\n      if (this.dateHasChanged(date)) {\n        this.selectDate(date)\n      }\n    },\n    /**\n     * Sets the initial picker page view: day, month or year\n     */\n    setInitialView() {\n      const initialView = this.computedInitialView\n\n      if (!this.allowedToShowView(initialView)) {\n        throw new Error(\n          `initialView '${this.initialView}' cannot be rendered based on minimum '${this.minimumView}' and maximum '${this.maximumView}'`,\n        )\n      }\n\n      this.setView(initialView)\n    },\n    /**\n     * Sets the date that the calendar should open on\n     * @param {Date=} date The date to set for the page\n     */\n    setPageDate(date) {\n      const validDate = this.utils.parseAsDate(date) || this.computedOpenDate\n      let dateTemp = this.utils.getNewDateObject(validDate)\n      dateTemp = new Date(this.utils.setDate(dateTemp, 1))\n\n      const pageTimestamp = this.utils\n        .adjustDateToView(dateTemp, this.view)\n        .valueOf()\n\n      this.pageTimestamp = pageTimestamp\n    },\n    /**\n     * Sets the slide duration in milliseconds by looking up the stylesheet\n     */\n    setSlideDuration() {\n      if (!this.$refs.picker || !this.$refs.picker.$refs.cells) {\n        return\n      }\n      const cells = this.$refs.picker.$refs.cells.$el\n      const durationInSecs = window.getComputedStyle(cells).transitionDuration\n\n      this.slideDuration = parseFloat(durationInSecs) * 1000\n    },\n    /**\n     * Set the datepicker modelValue (and, if typeable, update `latestValidTypedDate`)\n     * @param {Date|String|Number|null} date\n     */\n    setValue(date) {\n      this.selectedDate = date || null\n      this.setPageDate(date)\n\n      if (this.typeable) {\n        this.latestValidTypedDate = date || this.computedOpenDate\n      }\n    },\n    /**\n     * Set the picker view\n     * @param {String} view\n     */\n    setView(view) {\n      if (this.allowedToShowView(view)) {\n        this.view = view\n      }\n    },\n    /**\n     * Sets the array of `refs` that might be focused following a view change\n     * @param {String} newView The view being changed to\n     * @param {String} oldView The previous view\n     */\n    setViewChangeFocusRefs(newView, oldView) {\n      if (oldView === '') {\n        this.focus.refs = []\n        return\n      }\n\n      const views = ['day', 'month', 'year']\n      const isNewView = (view) => view === newView\n      const isOldView = (view) => view === oldView\n      const newViewIndex = views.findIndex(isNewView)\n      const oldViewIndex = views.findIndex(isOldView)\n      const isViewChangeUp = newViewIndex - oldViewIndex > 0\n\n      this.focus.refs = isViewChangeUp\n        ? ['up', 'tabbableCell']\n        : ['tabbableCell', 'up']\n    },\n    /**\n     * Set the view to the next view down e.g. from `month` to `day`\n     * @param {Object} cell The currently focused cell\n     */\n    showNextViewDown(cell) {\n      this.setPageDate(new Date(cell.timestamp))\n      this.$emit(`changed${this.ucFirst(this.view)}`, cell)\n      this.setView(this.nextView.down)\n    },\n    /**\n     * Capitalizes the first letter\n     * @param {String} str The string to capitalize\n     * @returns {String}\n     */\n    ucFirst(str) {\n      return str[0].toUpperCase() + str.substring(1)\n    },\n  },\n}\n</script>\n\n<style lang=\"scss\">\n@import '../styles/style.scss';\n</style>\n","/* eslint no-param-reassign: 0 */\n/**\n * get the hidden element width, height\n * @param {HTMLElement} element dom\n */\nexport function getPopupElementSize(element) {\n  const originalDisplay = element.style.display\n  const originalVisibility = element.style.visibility\n  element.style.display = 'block'\n  element.style.visibility = 'hidden'\n  const styles = window.getComputedStyle(element)\n  const width =\n    element.offsetWidth +\n    parseInt(styles.marginLeft, 10) +\n    parseInt(styles.marginRight, 10)\n  const height =\n    element.offsetHeight +\n    parseInt(styles.marginTop, 10) +\n    parseInt(styles.marginBottom, 10)\n  element.style.display = originalDisplay\n  element.style.visibility = originalVisibility\n\n  return {\n    width,\n    height,\n  }\n}\n\n/**\n * get the popup position\n * @param {Element} el element\n * @param {Element} elRelative relative element\n * @param {Number} targetWidth target element's width\n * @param {Number} targetHeight target element's height\n * @param {Boolean} appendToBody\n * @param {String} fixedPosition\n * @param {Boolean} rtl\n */\n// eslint-disable-next-line complexity,max-statements\nexport function getRelativePosition({\n  el,\n  elRelative,\n  targetWidth,\n  targetHeight,\n  appendToBody,\n  fixedPosition,\n  rtl,\n}) {\n  let left = 0\n  let top = 0\n  let offsetX = 0\n  let offsetY = 0\n  const relativeRect = elRelative.getBoundingClientRect()\n  const documentWidth = document.documentElement.clientWidth\n  const documentHeight = document.documentElement.clientHeight\n  if (appendToBody) {\n    offsetX = window.pageXOffset + relativeRect.left\n    offsetY = window.pageYOffset + relativeRect.top\n  }\n\n  const calendarBounding = el.getBoundingClientRect()\n  const outOfBoundsRight = calendarBounding.right > window.innerWidth\n  const outOfBoundsBottom = calendarBounding.bottom > window.innerHeight\n\n  const fixedPositionRight =\n    fixedPosition && fixedPosition.indexOf('right') !== -1\n  const fixedPositionTop = fixedPosition && fixedPosition.indexOf('top') !== -1\n\n  const setLeft = () => {\n    left = offsetX\n  }\n  const setRight = () => {\n    left = offsetX + relativeRect.width - targetWidth\n  }\n  const setBottom = () => {\n    top = offsetY + relativeRect.height\n  }\n  const setTop = () => {\n    top = offsetY - targetHeight\n  }\n\n  if (fixedPosition === '') {\n    if (outOfBoundsRight || rtl) {\n      setRight()\n    } else {\n      setLeft()\n    }\n\n    if (outOfBoundsBottom) {\n      setTop()\n    } else {\n      setBottom()\n    }\n\n    const hasRelativeWidth =\n      documentWidth - relativeRect.left < targetWidth &&\n      relativeRect.right < targetWidth\n\n    const hasRelativeHeight =\n      relativeRect.top <= targetHeight &&\n      documentHeight - relativeRect.bottom <= targetHeight\n\n    if (hasRelativeWidth) {\n      left = offsetX - relativeRect.left + 1\n    }\n\n    if (hasRelativeHeight) {\n      top = offsetY + documentHeight - relativeRect.top - targetHeight\n    }\n  } else {\n    if (fixedPositionRight) {\n      setRight()\n    } else {\n      setLeft()\n    }\n\n    if (fixedPositionTop) {\n      setTop()\n    } else {\n      setBottom()\n    }\n  }\n\n  return {\n    left: `${left}px`,\n    top: `${top}px`,\n  }\n}\n"],"names":["en","constructor","language","months","monthsAbbr","days","rtl","ymd","yearSuffix","this","_language","TypeError","_months","length","RangeError","_monthsAbbr","_days","getDaysStartingOn","firstDayOfWeek","firstDays","slice","lastDays","concat","getMonthByAbbrName","name","monthValue","findIndex","month","getMonthByName","calendarSlots","utils","useUtc","getFullYear","date","getUTCFullYear","getMonth","getUTCMonth","getDaysInMonth","daysInMonth","getDate","getUTCDate","getDay","getUTCDay","getHours","getUTCHours","getMinutes","getUTCMinutes","setFullYear","value","setUTCFullYear","setMonth","setUTCMonth","setDate","setUTCDate","compareDates","date1","date2","d1","Date","valueOf","d2","resetDateTime","isValidDate","Object","prototype","toString","call","Number","isNaN","getDayNameAbbr","getDayFromAbbr","abbr","i","toLowerCase","getMonthName","Error","getMonthNameAbbr","year","test","getNthSuffix","day","formatDate","formatStr","translation","matches","d","dd","E","o","M","MM","MMM","MMMM","yy","String","yyyy","replace","match","parseDate","dateStr","format","parser","parseDateWithLibrary","parseableDate","currentYear","time","splitter","df","split","ds","tmp","join","getParsableDate","getTime","parsedDate","parse","parseAsDate","parsed","setUTCHours","setHours","getNewDateObject","getOpenDate","openDate","selectedDate","view","parsedOpenDate","openDateOrToday","newOpenDate","adjustDateToView","dateToConvert","resetDay","resetMonth","makeDateUtils","__spreadProps","__spreadValues","_sfc_main","props","autofocus","type","Boolean","default","bootstrapStyling","clearButton","calendarButton","disabled","Function","id","inline","inputClass","Array","maxlength","pattern","placeholder","refName","required","showCalendarOnButtonClick","showCalendarOnFocus","tabindex","typeable","mixins","inputProps","isOpen","slideDuration","emits","blur","clearDate","close","focus","open","selectTypedDate","setFocus","refArray","every","ref","includes","tab","typedDate","data","input","isInputFocused","shouldToggleOnFocus","shouldToggleOnClick","computed","computedInputClass","formattedValue","watch","immediate","handler","wasOpen","$nextTick","mounted","$el","querySelector","methods","$emit","formatTypedDate","parseInput","handleInputBlur","handleButtonFocus","handleDelete","handleInputClick","toggle","handleInputFocus","setTimeout","handleKeydownDown","handleKeydownEnter","handleKeydownEscape","handleKeydownSpace","event","preventDefault","handleKeyup","key","handleKeyupSpace","trim","_createElementBlock","createElementBlock","class","_ctx","_renderSlot","$slots","_normalizeClass","normalizeClass","onClick","$options","onFocus","args","_createElementVNode","autocomplete","readonly","onBlur","onKeydown","_cache","_withKeys","$event","withKeys","onKeyup","$props","cellUtils","isDefined","obj","prop","hasArray","isArray","hasDate","dayMonthYear","makeCellUtils","DisabledDate","disabledDates","_utils","_disabledDates","config","has","customPredictor","daysOfMonth","daysOfWeek","from","ranges","specificDates","to","isDateDisabledVia","range","u","some","thisRange","hasFrom","hasTo","specificDate","dates","indexOf","isMonthDisabledVia","isYearDisabledVia","isDateDisabled","isDisabledVia","isMonthDisabled","dayDate","isYearDisabled","monthDate","getEarliestPossibleDate","nextDate","getLatestPossibleDate","delay","refs","inlineTabbableCell","isActive","isRevertingToOpenDate","navElements","navElementsFocusedIndex","resetTabbableCell","skipReviewFocus","tabbableCell","transitionName","fallbackElementsToFocus","elements","unshift","focusedDateTimestamp","pageDate","pageTimestamp","hasClass","innerHTML","tabbableCellId","fullYear","getAttribute","getCellDate","allowNormalTabbing","isTabbingAwayFromInlineDatepicker","applyFocus","focusRefs","element","getElementByRef","setNavElementsFocusedIndex","focusInlineTabbableCell","setTabbableCell","getActiveCell","activeElement","getActiveElement","isActiveElementACell","isOnSameView","document","shadowRoot","getCellId","$refs","picker","cells","cellDate","timestamp","dateInput","showHeader","pickerHeader","getElementsFromCalendarFooter","footerSlotIndex","hasSlot","getFocusableElements","children","getElementsFromSlot","slotName","isBeforeHeader","index","getElementsFromHeader","navNodeList","querySelectorAll","fragment","getFirstInlineFocusableElement","popup","getLastInlineFocusableElement","popupElements","getInputField","getTypedCell","cellId","latestValidTypedDate","handleFocusIn","datepickerId","globalDatepickerId","setInlineTabbableCell","setNavElements","handleFocusOut","isTabbingAwayFromFirstNavElement","tabAwayFromFirstElement","isTabbingAwayFromLastNavElement","tabAwayFromLastElement","shiftKey","resetFocusToOpenDate","setTransitionAndFocusDelay","computedOpenDate","isMinimumView","minimumView","setPageDate","reviewFocus","startDate","endDate","isInTheFuture","setTransitionName","updateTabbableCell","ucFirst","filter","item","reduce","acc","val","pickerCells","plusOrMinus","isRtl","firstElement","lastElement","tabBackwards","tabForwards","tabThroughNavigation","tabToCorrectInlineCell","isACell","isNextDisabled","isPreviousDisabled","isUpDisabled","nextViewUp","focusInput","pageChange","page","setView","previousPage","incrementBy","nextPage","leftButton","rightButton","arrowLeftPrev","goToPreviousPage","arrowRightPrev","arrowLeftNext","goToNextPage","arrowRightNext","focusTabbableCell","focusLeftButton","focusRightButton","selectUpButton","_hoisted_2","_hoisted_5","components","PickerHeader","btn","isTypeable","select","cell","setSkipReviewFocus","disabledConfig","earliestPossibleDate","latestPossibleDate","pageYear","addMoreSteps","options","stepsRemaining","Math","abs","delta","changePage","units","yearRange","changePageAndSetFocus","sign","setFocusOnNewPage","getElement","currentElement","getElementSibling","isBeyondPossibleDate","firstOrLastPossibleDate","isMutedOrDisabled","nextElementSibling","previousElementSibling","getFirstOrLastElement","isNext","handleArrow","setFocusToAvailableCell","isPreviousMonth","isNextMonth","isDatePossible","isMuted","classList","isDisabled","HighlightedDate","highlighted","_highlighted","highlightedDates","includeDisabled","isHighlightingNotPossible","isDateHighlightedVia","isDateHighlighted","isHighlightedVia","isHighlightStart","isHighlightEnd","showEdgeDates","validator","arrow","columns","cellClasses","isHighlighted","muted","isOpenDate","sat","isSaturday","sun","isSunday","selected","isSelected","today","isToday","weekend","isWeekend","isTabbableCell","_openBlock","_hoisted_1","_Fragment","_renderList","renderList","renderSlot","PickerCells","pickerMixin","dayCellContent","showFullMonthName","daysInCalendar","daysFromPrevMonth","daysFromNextMonth","dObj","firstDayCellDate","push","makeDay","currMonthName","monthName","pageMonth","currYearName","firstDayOfWeekNumber","firstOfMonthDayNumber","daysThisAndPrevMonth","ceil","firstOfNextMonth","lastOfPreviousMonth","pageTitleDay","isDisabledDate","isHighlightedDate","isSelectedDate","dayOfWeek","showDate","_hoisted_3","DateInput","PickerDay","beforeCalendarHeaderDay","_createBlock","createBlock","_component_PickerHeader","onFocusInput","onPageChange","onSetFocus","onSetView","prevIntervalBtn","nextIntervalBtn","_toDisplayString","createElementVNode","Fragment","_createVNode","_Transition","_component_PickerCells","onArrow","onSelect","_withCtx","withCtx","_createTextVNode","createTextVNode","toDisplayString","calendarFooterDay","_hoisted_4","PickerMonth","firstMonthCellDate","isDisabledMonth","isOpenMonth","isSelectedMonth","isTodayMonth","pageTitleMonth","openDateMonth","openDateYear","thisDateMonth","thisDateYear","todayMonth","beforeCalendarHeaderMonth","calendarFooterMonth","PickerYear","years","firstYearCellDate","isDisabledYear","isOpenYear","isSelectedYear","isTodayYear","cellsInGrid","firstDayOfNextDecade","pageDecadeEnd","lastDayOfPreviousDecade","pageDecadeStart","floor","pageTitleYear","firstYear","todayYear","beforeCalendarHeaderYear","calendarFooterYear","appendToBody","fixedPosition","visible","popupRect","displayPopup","body","appendChild","beforeUnmount","parentNode","removeChild","setTopStyle","relativeRect","$parent","getBoundingClientRect","style","top","bottom","window","scrollY","relativeElement","originalDisplay","display","originalVisibility","visibility","styles","getComputedStyle","width","offsetWidth","parseInt","marginLeft","marginRight","height","offsetHeight","marginTop","marginBottom","getPopupElementSize","left","el","elRelative","targetWidth","targetHeight","offsetX","offsetY","documentWidth","documentElement","clientWidth","documentHeight","clientHeight","pageXOffset","pageYOffset","calendarBounding","outOfBoundsRight","right","innerWidth","outOfBoundsBottom","innerHeight","fixedPositionRight","fixedPositionTop","setLeft","setRight","setBottom","setTop","hasRelativeWidth","hasRelativeHeight","getRelativePosition","render","h","navMixin","calendarClass","fullMonthName","initialView","maximumView","modelValue","wrapperClass","yearPickerRange","changed","cleared","closed","opened","changedMonth","changedYear","changedDecade","calendarHeight","isClickOutside","computedInitialView","random","isInline","allowedToShowView","nextView","up","views","viewIndex","down","pickerClasses","usedCalendarSlots","slot","selectDate","dateHasChanged","deep","setInitialView","hasJustBecomeActive","isNoLongerActive","datepickerIsActive","datepickerIsInactive","newValue","oldValue","parsedValue","oldParsedValue","setValue","newView","oldView","handleViewChange","init","addEventListener","handleClickOutside","removeEventListener","minimumViewIndex","maximumViewIndex","selectTypedDateOnLosingFocus","closeByClickOutside","handlePageChange","handleSelect","showNextViewDown","handleTypedDate","originalTypedDate","originalPageDate","isPageChange","isClosing","isOpeningInline","setViewChangeFocusRefs","className","setSlideDuration","isResetFocus","isOpenCellFocused","resetOrClose","validDate","dateTemp","durationInSecs","transitionDuration","parseFloat","isViewChangeUp","str","toUpperCase","substring","onFocusin","onFocusout","_component_DateInput","$data","onClearDate","onClose","onOpen","onSelectTypedDate","onTab","onTypedDate","beforeDateInput","afterDateInput","clearBtn","calendarBtn","_component_Popup","Transition","onMousedown","_withModifiers","withModifiers","beforeCalendarHeader","_resolveDynamicComponent","onSetSkipReviewFocus","onSetTransitionName","slotKey","calendarFooter"],"mappings":"oqBAEA,MAAAA,EAAe,ICFA,MAEbC,YACEC,EACAC,EACAC,EACAC,EACAC,GAAM,EACNC,GAAM,EACNC,EAAa,IAEbC,KAAKP,SAAWA,EAChBO,KAAKN,OAASA,EACdM,KAAKL,WAAaA,EAClBK,KAAKJ,KAAOA,EACZI,KAAKH,IAAMA,EACXG,KAAKF,IAAMA,EACXE,KAAKD,WAAaA,CACnB,CAGGN,eACF,OAAOO,KAAKC,SACb,CAEGR,aAASA,GACP,GAAoB,iBAAbA,EACH,MAAA,IAAIS,UAAU,6BAEtBF,KAAKC,UAAYR,CAClB,CAEGC,aACF,OAAOM,KAAKG,OACb,CAEGT,WAAOA,GACL,GAAkB,KAAlBA,EAAOU,OACT,MAAM,IAAIC,WACR,+BAA+BL,KAAKP,qBAGxCO,KAAKG,QAAUT,CAChB,CAEGC,iBACF,OAAOK,KAAKM,WACb,CAEGX,eAAWA,GACT,GAAsB,KAAtBA,EAAWS,OACb,MAAM,IAAIC,WACR,2CAA2CL,KAAKP,qBAGpDO,KAAKM,YAAcX,CACpB,CAEGC,WACF,OAAOI,KAAKO,KACb,CAEGX,SAAKA,GACH,GAAgB,IAAhBA,EAAKQ,OACP,MAAM,IAAIC,WAAW,4BAA4BL,KAAKP,qBAExDO,KAAKO,MAAQX,CACd,CAEDY,kBAAkBC,GAChB,MAAMC,EAAYV,KAAKO,MAAMI,MAAMF,GAC7BG,EAAWZ,KAAKO,MAA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