Skip to content

Conversation

@ikushum
Copy link
Member

@ikushum ikushum commented Jan 2, 2026

fixes #22428

Description

Emit any events from the day button.

Markup:

<template>
  <v-app>
    <v-container>
      <v-date-picker @click:day="onClickDay" @dblclick:day="onDblClickDay" />
    </v-container>
  </v-app>
</template>

<script setup>
  const onDblClickDay = (e, day) => {
    console.log('dblclick', day)
  }

  const onClickDay = (e, day) => {
    console.log('click', day)
  }
</script>

@KaelWD
Copy link
Member

KaelWD commented Jan 2, 2026

Calendar and datatable use getPrefixedEventHandlers for this which works with any event

{ ...getPrefixedEventHandlers(attrs, ':groupHeader', () => slotProps) }

@ikushum ikushum force-pushed the feat/date-picker-events branch 2 times, most recently from ea0c51c to e4259b6 Compare January 2, 2026 11:46
@ikushum ikushum force-pushed the feat/date-picker-events branch from e4259b6 to c958c93 Compare January 2, 2026 11:54
@ikushum ikushum marked this pull request as ready for review January 2, 2026 11:55
@ikushum ikushum force-pushed the feat/date-picker-events branch from 66f6d93 to c958c93 Compare January 2, 2026 11:56
@ikushum ikushum requested review from a team, J-Sek and KaelWD January 2, 2026 11:57
@ikushum ikushum self-assigned this Jan 2, 2026
@ikushum ikushum changed the title feat(VDatePicker): add event click:day feat(VDatePicker): add prefixed day events handler Jan 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants