Files
dify/web/utils/timezone.ts
2026-06-29 02:41:30 +00:00

15 lines
303 B
TypeScript

import tz from './timezone.json'
type Item = {
value: number | string
name: string
}
export const timezones: Item[] = tz
export const getBrowserTimezone = () => {
if (typeof Intl === 'undefined')
return undefined
return new Intl.DateTimeFormat().resolvedOptions().timeZone || undefined
}