Skip to content

Commit 69f56b9

Browse files
authored
Merge pull request #5 from aboutbits/date-local-time-zone
use local time-zone instead of utc for min/max date
2 parents 4574f5d + 945dcc2 commit 69f56b9

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

src/zod/makeZodErrorMap.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,15 +74,14 @@ export function getDescriptorItem<T>(
7474
}
7575

7676
const timeOptions: FormatDateOptions | null =
77-
date.getUTCHours() === 0 && date.getUTCMinutes() === 0
77+
date.getHours() === 0 && date.getMinutes() === 0
7878
? null
7979
: {
8080
hour: '2-digit',
8181
minute: '2-digit',
8282
}
8383

8484
value = intl.formatDate(value, {
85-
timeZone: 'UTC',
8685
...dateOptions,
8786
...timeOptions,
8887
})

0 commit comments

Comments
 (0)