refactor: update match time utilities and improve local match window logic

- Introduced new functions `isInLocalTodayMatchWindow` and `isAfterLocalTodayMatchWindow` to enhance match time checks.
- Replaced the deprecated `dayKeyInTimeZone` function with `isInLocalTodayMatchWindow` in the PlayerController.
- Updated related tests and utility exports to reflect the new naming conventions.
- Improved handling of local match windows in various components for better accuracy.
This commit is contained in:
wchino
2026-06-13 18:20:26 +08:00
parent 7b33d9f9fa
commit 21dd9957f0
5 changed files with 99 additions and 22 deletions

View File

@@ -1,5 +1,5 @@
export {
isAfterLocalToday as isAfterTodayMatchWindow,
isInLocalToday as isInTodayMatchWindow,
isAfterLocalTodayMatchWindow as isAfterTodayMatchWindow,
isInLocalTodayMatchWindow as isInTodayMatchWindow,
isSameLocalCalendarDay as isSameCalendarDay,
} from '@thebet365/shared';

View File

@@ -11,8 +11,8 @@ import GoldSpinner from '../components/GoldSpinner.vue';
import { usePullToRefresh } from '../composables/usePullToRefresh';
import type { MatchPhase } from '../utils/matchPhase';
import {
isAfterLocalToday as isAfterTodayMatchWindow,
isInLocalToday as isInTodayMatchWindow,
isAfterLocalTodayMatchWindow as isAfterTodayMatchWindow,
isInLocalTodayMatchWindow as isInTodayMatchWindow,
} from '@thebet365/shared';
type MainTab = 'matches' | 'outright';