Skip to content

Commit

Permalink
fix(Calendar/RangeCalendar): adjust selector for data attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
epr3 committed Feb 3, 2025
1 parent 49cb41a commit 4ea6c60
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/radix-vue/src/Calendar/CalendarCellTrigger.vue
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ const isFocusedDate = computed(() => {
const isSelectedDate = computed(() => rootContext.isDateSelected(props.day))
const SELECTOR
= '[data-radix-vue-calendar-cell-trigger]:not([data-disabled]):not([data-outside-month]):not([data-outside-visible-months])'
= '[data-radix-vue-calendar-cell-trigger]:not([data-disabled]):not([data-outside-view]):not([data-outside-visible-view])'
function changeDate(date: DateValue) {
if (rootContext.readonly.value)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ const isHighlighted = computed(() => rootContext.highlightedRange.value
: false)
const SELECTOR
= '[data-radix-vue-calendar-cell-trigger]:not([data-disabled]):not([data-outside-month]):not([data-outside-visible-months])'
= '[data-radix-vue-calendar-cell-trigger]:not([data-disabled]):not([data-outside-view]):not([data-outside-visible-view])'
const isDateToday = computed(() => {
return isToday(props.day, getLocalTimeZone())
Expand Down Expand Up @@ -208,7 +208,7 @@ function handleArrowKey(e: KeyboardEvent) {
:data-disabled="isDisabled ? '' : undefined"
:data-unavailable="isUnavailable ? '' : undefined"
:data-today="isDateToday ? '' : undefined"
:data-outside-month="isOutsideView ? '' : undefined"
:data-outside-view="isOutsideView ? '' : undefined"
:data-focused="isFocusedDate ? '' : undefined"
:tabindex="isFocusedDate ? 0 : isOutsideView || isDisabled ? undefined : -1"
@click="handleClick"
Expand Down

0 comments on commit 4ea6c60

Please sign in to comment.