{"version":3,"file":"RangeCalendarRoot.cjs","sources":["../../src/RangeCalendar/RangeCalendarRoot.vue"],"sourcesContent":["<script lang=\"ts\">\nimport { type DateValue, isEqualDay } from '@internationalized/date'\n\nimport type { Ref } from 'vue'\nimport type { PrimitiveProps } from '@/Primitive'\nimport { type Formatter, createContext, isNullish, useDirection, useKbd, useLocale } from '@/shared'\nimport { getDefaultDate, handleCalendarInitialFocus } from '@/shared/date'\nimport { type Grid, type Matcher, type WeekDayFormat, isBefore } from '@/date'\nimport type { DateRange } from '@/shared/date'\nimport { useRangeCalendarState } from './useRangeCalendar'\nimport { useCalendar } from '@/Calendar/useCalendar'\nimport type { Direction } from '@/shared/types'\n\ntype RangeCalendarRootContext = {\n  modelValue: Ref<DateRange>\n  startValue: Ref<DateValue | undefined>\n  endValue: Ref<DateValue | undefined>\n  locale: Ref<string>\n  placeholder: Ref<DateValue>\n  pagedNavigation: Ref<boolean>\n  preventDeselect: Ref<boolean>\n  grid: Ref< Grid<DateValue>[]>\n  weekDays: Ref<string[]>\n  weekStartsOn: Ref<0 | 1 | 2 | 3 | 4 | 5 | 6>\n  weekdayFormat: Ref<WeekDayFormat>\n  fixedWeeks: Ref<boolean>\n  numberOfMonths: Ref<number>\n  disabled: Ref<boolean>\n  readonly: Ref<boolean>\n  initialFocus: Ref<boolean>\n  onPlaceholderChange: (date: DateValue) => void\n  fullCalendarLabel: Ref<string>\n  parentElement: Ref<HTMLElement | undefined>\n  headingValue: Ref<string>\n  isInvalid: Ref<boolean>\n  isDateDisabled: Matcher\n  isDateUnavailable?: Matcher\n  isOutsideVisibleView: (date: DateValue) => boolean\n  highlightedRange: Ref<{ start: DateValue, end: DateValue } | null>\n  focusedValue: Ref<DateValue | undefined>\n  lastPressedDateValue: Ref<DateValue | undefined>\n  isSelected: (date: DateValue) => boolean\n  isSelectionEnd: (date: DateValue) => boolean\n  isSelectionStart: (date: DateValue) => boolean\n  isHighlightedStart: (date: DateValue) => boolean\n  isHighlightedEnd: (date: DateValue) => boolean\n  prevPage: (prevPageFunc?: (date: DateValue) => DateValue) => void\n  nextPage: (nextPageFunc?: (date: DateValue) => DateValue) => void\n  isNextButtonDisabled: (nextPageFunc?: (date: DateValue) => DateValue) => boolean\n  isPrevButtonDisabled: (prevPageFunc?: (date: DateValue) => DateValue) => boolean\n  formatter: Formatter\n  dir: Ref<Direction>\n}\n\nexport interface RangeCalendarRootProps extends PrimitiveProps {\n  /** The default placeholder date */\n  defaultPlaceholder?: DateValue\n  /** The default value for the calendar */\n  defaultValue?: DateRange\n  /** The controlled checked state of the calendar. Can be bound as `v-model`. */\n  modelValue?: DateRange | null\n  /** The placeholder date, which is used to determine what month to display when no date is selected. This updates as the user navigates the calendar and can be used to programmatically control the calendar view */\n  placeholder?: DateValue\n  /** When combined with `isDateUnavailable`, determines whether non-contiguous ranges, i.e. ranges containing unavailable dates, may be selected. */\n  allowNonContiguousRanges?: boolean\n  /** This property causes the previous and next buttons to navigate by the number of months displayed at once, rather than one month */\n  pagedNavigation?: boolean\n  /** Whether or not to prevent the user from deselecting a date without selecting another date first */\n  preventDeselect?: boolean\n  /** The day of the week to start the calendar on */\n  weekStartsOn?: 0 | 1 | 2 | 3 | 4 | 5 | 6\n  /** The format to use for the weekday strings provided via the weekdays slot prop */\n  weekdayFormat?: WeekDayFormat\n  /** The accessible label for the calendar */\n  calendarLabel?: string\n  /** Whether or not to always display 6 weeks in the calendar */\n  fixedWeeks?: boolean\n  /** The maximum date that can be selected */\n  maxValue?: DateValue\n  /** The minimum date that can be selected */\n  minValue?: DateValue\n  /** The locale to use for formatting dates */\n  locale?: string\n  /** The number of months to display at once */\n  numberOfMonths?: number\n  /** Whether or not the calendar is disabled */\n  disabled?: boolean\n  /** Whether or not the calendar is readonly */\n  readonly?: boolean\n  /** If true, the calendar will focus the selected day, today, or the first day of the month depending on what is visible when the calendar is mounted */\n  initialFocus?: boolean\n  /** A function that returns whether or not a date is disabled */\n  isDateDisabled?: Matcher\n  /** A function that returns whether or not a date is unavailable */\n  isDateUnavailable?: Matcher\n  /** The reading direction of the calendar when applicable. <br> If omitted, inherits globally from `ConfigProvider` or assumes LTR (left-to-right) reading mode. */\n  dir?: Direction\n  /** A function that returns the next page of the calendar. It receives the current placeholder as an argument inside the component. */\n  nextPage?: (placeholder: DateValue) => DateValue\n  /** A function that returns the previous page of the calendar. It receives the current placeholder as an argument inside the component. */\n  prevPage?: (placeholder: DateValue) => DateValue\n}\n\nexport type RangeCalendarRootEmits = {\n  /** Event handler called whenever the model value changes */\n  'update:modelValue': [date: DateRange]\n  /** Event handler called whenever the placeholder value changes */\n  'update:placeholder': [date: DateValue]\n  /** Event handler called whenever the start value changes */\n  'update:startValue': [date: DateValue | undefined]\n}\n\nexport const [injectRangeCalendarRootContext, provideRangeCalendarRootContext]\n  = createContext<RangeCalendarRootContext>('RangeCalendarRoot')\n</script>\n\n<script setup lang=\"ts\">\nimport { computed, onMounted, ref, toRefs, watch } from 'vue'\nimport { Primitive, usePrimitiveElement } from '@/Primitive'\nimport { useEventListener, useVModel } from '@vueuse/core'\n\nconst props = withDefaults(defineProps<RangeCalendarRootProps>(), {\n  defaultValue: () => ({ start: undefined, end: undefined }),\n  as: 'div',\n  pagedNavigation: false,\n  preventDeselect: false,\n  weekStartsOn: 0,\n  weekdayFormat: 'narrow',\n  fixedWeeks: false,\n  numberOfMonths: 1,\n  disabled: false,\n  readonly: false,\n  initialFocus: false,\n  placeholder: undefined,\n  isDateDisabled: undefined,\n  isDateUnavailable: undefined,\n  allowNonContiguousRanges: false,\n})\nconst emits = defineEmits<RangeCalendarRootEmits>()\n\ndefineSlots<{\n  default: (props: {\n    /** The current date of the placeholder */\n    date: DateValue\n    /** The grid of dates */\n    grid: Grid<DateValue>[]\n    /** The days of the week */\n    weekDays: string[]\n    /** The start of the week */\n    weekStartsOn: 0 | 1 | 2 | 3 | 4 | 5 | 6\n    /** The calendar locale */\n    locale: string\n    /** Whether or not to always display 6 weeks in the calendar */\n    fixedWeeks: boolean\n    /** The current date range */\n    modelValue: DateRange\n  }) => any\n}>()\n\nconst {\n  disabled,\n  readonly,\n  initialFocus,\n  pagedNavigation,\n  weekStartsOn,\n  weekdayFormat,\n  fixedWeeks,\n  numberOfMonths,\n  preventDeselect,\n  isDateUnavailable: propsIsDateUnavailable,\n  isDateDisabled: propsIsDateDisabled,\n  calendarLabel,\n  maxValue,\n  minValue,\n  dir: propDir,\n  locale: propLocale,\n  nextPage: propsNextPage,\n  prevPage: propsPrevPage,\n  allowNonContiguousRanges,\n} = toRefs(props)\n\nconst { primitiveElement, currentElement: parentElement }\n  = usePrimitiveElement()\nconst dir = useDirection(propDir)\nconst locale = useLocale(propLocale)\n\nconst lastPressedDateValue = ref() as Ref<DateValue | undefined>\nconst focusedValue = ref() as Ref<DateValue | undefined>\nconst isEditing = ref(false)\n\nconst modelValue = useVModel(props, 'modelValue', emits, {\n  defaultValue: props.defaultValue ?? { start: undefined, end: undefined },\n  passive: (props.modelValue === undefined) as false,\n}) as Ref<DateRange>\n\nconst currentModelValue = computed(() => isNullish(modelValue.value) ? { start: undefined, end: undefined } : modelValue.value)\n\nconst defaultDate = getDefaultDate({\n  defaultPlaceholder: props.placeholder,\n  defaultValue: currentModelValue.value.start,\n  locale: props.locale,\n})\n\nconst startValue = ref(currentModelValue.value.start) as Ref<DateValue | undefined>\nconst endValue = ref(currentModelValue.value.end) as Ref<DateValue | undefined>\n\nconst placeholder = useVModel(props, 'placeholder', emits, {\n  defaultValue: props.defaultPlaceholder ?? defaultDate.copy(),\n  passive: (props.placeholder === undefined) as false,\n}) as Ref<DateValue>\n\nfunction onPlaceholderChange(value: DateValue) {\n  placeholder.value = value.copy()\n}\n\nconst {\n  fullCalendarLabel,\n  headingValue,\n  isDateDisabled,\n  isDateUnavailable,\n  isNextButtonDisabled,\n  isPrevButtonDisabled,\n  grid,\n  weekdays,\n  isOutsideVisibleView,\n  nextPage,\n  prevPage,\n  formatter,\n} = useCalendar({\n  locale,\n  placeholder,\n  weekStartsOn,\n  fixedWeeks,\n  numberOfMonths,\n  minValue,\n  maxValue,\n  disabled,\n  weekdayFormat,\n  pagedNavigation,\n  isDateDisabled: propsIsDateDisabled.value,\n  isDateUnavailable: propsIsDateUnavailable.value,\n  calendarLabel,\n  nextPage: propsNextPage,\n  prevPage: propsPrevPage,\n})\n\nconst {\n  isInvalid,\n  isSelected,\n  highlightedRange,\n  isSelectionStart,\n  isSelectionEnd,\n  isHighlightedStart,\n  isHighlightedEnd,\n} = useRangeCalendarState({\n  start: startValue,\n  end: endValue,\n  isDateDisabled,\n  isDateUnavailable,\n  focusedValue,\n  allowNonContiguousRanges,\n})\n\nwatch(modelValue, (_modelValue, _prevValue) => {\n  if ((!_prevValue?.start && _modelValue?.start)\n    || !_modelValue\n    || !_modelValue.start\n    || (startValue.value && !isEqualDay(_modelValue.start, startValue.value))\n  ) {\n    startValue.value = _modelValue?.start?.copy?.()\n  }\n\n  if ((!_prevValue?.end && _modelValue.end)\n    || !_modelValue\n    || !_modelValue.end\n    || (endValue.value && !isEqualDay(_modelValue.end, endValue.value))\n  ) {\n    endValue.value = _modelValue?.end?.copy?.()\n  }\n})\n\nwatch(startValue, (_startValue) => {\n  if (_startValue && !isEqualDay(_startValue, placeholder.value))\n    onPlaceholderChange(_startValue)\n\n  emits('update:startValue', _startValue)\n})\n\nwatch([startValue, endValue], ([_startValue, _endValue]) => {\n  const value = currentModelValue.value\n\n  if (value && value.start && value.end && _startValue && _endValue && isEqualDay(value.start, _startValue) && isEqualDay(value.end, _endValue))\n    return\n\n  isEditing.value = true\n  if (_startValue && _endValue) {\n    isEditing.value = false\n    if (value.start && value.end && isEqualDay(value.start, _startValue) && isEqualDay(value.end, _endValue))\n      return\n    if (isBefore(_endValue, _startValue)) {\n      modelValue.value = {\n        start: _endValue.copy(),\n        end: _startValue.copy(),\n      }\n    }\n    else {\n      modelValue.value = {\n        start: _startValue.copy(),\n        end: _endValue.copy(),\n      }\n    }\n  }\n})\n\nconst kbd = useKbd()\nuseEventListener('keydown', (ev) => {\n  if (ev.key === kbd.ESCAPE && isEditing.value) {\n    // Abort start and end selection\n    startValue.value = modelValue.value.start?.copy()\n    endValue.value = modelValue.value.end?.copy()\n  }\n})\n\nprovideRangeCalendarRootContext({\n  isDateUnavailable,\n  startValue,\n  endValue,\n  formatter,\n  modelValue,\n  placeholder,\n  disabled,\n  initialFocus,\n  pagedNavigation,\n  grid,\n  weekDays: weekdays,\n  weekStartsOn,\n  weekdayFormat,\n  fixedWeeks,\n  numberOfMonths,\n  readonly,\n  preventDeselect,\n  fullCalendarLabel,\n  headingValue,\n  isInvalid,\n  isDateDisabled,\n  highlightedRange,\n  focusedValue,\n  lastPressedDateValue,\n  isSelected,\n  isSelectionEnd,\n  isSelectionStart,\n  isNextButtonDisabled,\n  isPrevButtonDisabled,\n  isOutsideVisibleView,\n  nextPage,\n  prevPage,\n  parentElement,\n  onPlaceholderChange,\n  locale,\n  dir,\n  isHighlightedStart,\n  isHighlightedEnd,\n})\n\nonMounted(() => {\n  if (initialFocus.value)\n    handleCalendarInitialFocus(parentElement.value)\n})\n</script>\n\n<template>\n  <Primitive\n    ref=\"primitiveElement\"\n    :as=\"as\"\n    :as-child=\"asChild\"\n    role=\"application\"\n    :aria-label=\"fullCalendarLabel\"\n    :data-readonly=\"readonly ? '' : undefined\"\n    :data-disabled=\"disabled ? '' : undefined\"\n    :data-invalid=\"isInvalid ? '' : undefined\"\n    :dir=\"dir\"\n  >\n    <div style=\"border: 0px; clip: rect(0px, 0px, 0px, 0px); clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden; padding: 0px; position: absolute; white-space: nowrap; width: 1px;\">\n      <div\n        role=\"heading\"\n        aria-level=\"2\"\n      >\n        {{ fullCalendarLabel }}\n      </div>\n    </div>\n\n    <slot\n      :date=\"placeholder\"\n      :grid=\"grid\"\n      :week-days=\"weekdays\"\n      :week-starts-on=\"weekStartsOn\"\n      :locale=\"locale\"\n      :fixed-weeks=\"fixedWeeks\"\n      :model-value=\"modelValue\"\n    />\n  </Primitive>\n</template>\n"],"names":["createContext","toRefs","usePrimitiveElement","useDirection","useLocale","ref","useVModel","computed","isNullish","getDefaultDate","useCalendar","useRangeCalendarState","watch","isEqualDay","isBefore","useKbd","useEventListener","onMounted","handleCalendarInitialFocus"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAgHO,MAAM,CAAC,8BAAA,EAAgC,+BAA+B,CAAA,GACzEA,mCAAwC,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAQ/D,IAAA,MAAM,KAAQ,GAAA,OAAA;AAiBd,IAAA,MAAM,KAAQ,GAAA,MAAA;AAqBd,IAAM,MAAA;AAAA,MACJ,QAAA;AAAA,MACA,QAAA;AAAA,MACA,YAAA;AAAA,MACA,eAAA;AAAA,MACA,YAAA;AAAA,MACA,aAAA;AAAA,MACA,UAAA;AAAA,MACA,cAAA;AAAA,MACA,eAAA;AAAA,MACA,iBAAmB,EAAA,sBAAA;AAAA,MACnB,cAAgB,EAAA,mBAAA;AAAA,MAChB,aAAA;AAAA,MACA,QAAA;AAAA,MACA,QAAA;AAAA,MACA,GAAK,EAAA,OAAA;AAAA,MACL,MAAQ,EAAA,UAAA;AAAA,MACR,QAAU,EAAA,aAAA;AAAA,MACV,QAAU,EAAA,aAAA;AAAA,MACV;AAAA,KACF,GAAIC,WAAO,KAAK,CAAA;AAEhB,IAAA,MAAM,EAAE,gBAAA,EAAkB,cAAgB,EAAA,aAAA,KACtCC,iDAAoB,EAAA;AACxB,IAAM,MAAA,GAAA,GAAMC,iCAAa,OAAO,CAAA;AAChC,IAAM,MAAA,MAAA,GAASC,2BAAU,UAAU,CAAA;AAEnC,IAAA,MAAM,uBAAuBC,OAAI,EAAA;AACjC,IAAA,MAAM,eAAeA,OAAI,EAAA;AACzB,IAAM,MAAA,SAAA,GAAYA,QAAI,KAAK,CAAA;AAE3B,IAAA,MAAM,UAAa,GAAAC,cAAA,CAAU,KAAO,EAAA,YAAA,EAAc,KAAO,EAAA;AAAA,MAC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