Skip to content

Commit

Permalink
fix(VTimePicker): fix types for emit events (#20126)
Browse files Browse the repository at this point in the history
fixes #20085
  • Loading branch information
SonTT19 authored Jul 9, 2024
1 parent aded0dd commit 5385260
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
10 changes: 5 additions & 5 deletions packages/vuetify/src/labs/VTimePicker/VTimePicker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,11 @@ export const VTimePicker = genericComponent<VTimePickerSlots>()({
props: makeVTimePickerProps(),

emits: {
'update:hour': (val: number) => val,
'update:minute': (val: number) => val,
'update:period': (val: Period) => val,
'update:second': (val: number) => val,
'update:modelValue': (val: string) => val,
'update:hour': (val: number) => true,
'update:minute': (val: number) => true,
'update:period': (val: Period) => true,
'update:second': (val: number) => true,
'update:modelValue': (val: string) => true,
},

setup (props, { emit, slots }) {
Expand Down
4 changes: 2 additions & 2 deletions packages/vuetify/src/labs/VTimePicker/VTimePickerClock.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ export const VTimePickerClock = genericComponent()({
props: makeVTimePickerClockProps(),

emits: {
change: (val: number) => val,
input: (val: number) => val,
change: (val: number) => true,
input: (val: number) => true,
},

setup (props, { emit }) {
Expand Down
4 changes: 2 additions & 2 deletions packages/vuetify/src/labs/VTimePicker/VTimePickerControls.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ export const VTimePickerControls = genericComponent()({
props: makeVTimePickerControlsProps(),

emits: {
'update:period': (data: Period) => data,
'update:selecting': (data: 1 | 2 | 3) => data,
'update:period': (data: Period) => true,
'update:selecting': (data: 1 | 2 | 3) => true,
},

setup (props, { emit, slots }) {
Expand Down

0 comments on commit 5385260

Please # to comment.