|
|
|
@@ -67,7 +67,7 @@ import { FormattedMessage } from "react-intl"; |
|
|
|
|
|
|
|
const drawerWidth = 300; |
|
|
|
|
|
|
|
const ABOUT_SWITCH_DATE = new Date(2026, 0, 27); // 2026-01-28 |
|
|
|
const ABOUT_SWITCH_DATE = new Date(2025, 11, 17); // 2026-01-28 hardcode |
|
|
|
|
|
|
|
const startOfDay = (d) => new Date(d.getFullYear(), d.getMonth(), d.getDate()); |
|
|
|
|
|
|
|
@@ -75,7 +75,7 @@ const startOfDay = (d) => new Date(d.getFullYear(), d.getMonth(), d.getDate()); |
|
|
|
const isAfterAboutSwitchDate = () => { |
|
|
|
const today = startOfDay(new Date()); |
|
|
|
const switchDay = startOfDay(ABOUT_SWITCH_DATE); |
|
|
|
return today.getTime() > switchDay.getTime(); // strictly AFTER |
|
|
|
return today.getTime() >= switchDay.getTime(); // strictly AFTER |
|
|
|
}; |
|
|
|
|
|
|
|
const getAboutExternalUrlByLocale = () => { |
|
|
|
@@ -83,14 +83,14 @@ const getAboutExternalUrlByLocale = () => { |
|
|
|
|
|
|
|
if (locale === "zh-hk") { |
|
|
|
// TChinese |
|
|
|
return "https://www.gld.gov.hk/en/our-services/printing/advertising-gov-gazette/"; |
|
|
|
return "https://www.gld.gov.hk/zh-hk/our-services/printing/advertising-gov-gazette/"; |
|
|
|
} |
|
|
|
if (locale === "zh-cn") { |
|
|
|
// Simplified Chinese (你未貼,我用 zh-cn 版) |
|
|
|
return "https://www.gld.gov.hk/zh-cn/our-services/printing/advertising-gov-gazette/"; |
|
|
|
} |
|
|
|
// English (en-us) / fallback |
|
|
|
return "https://www.gld.gov.hk/zh-hk/our-services/printing/advertising-gov-gazette/"; |
|
|
|
return "https://www.gld.gov.hk/en/our-services/printing/advertising-gov-gazette/"; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
|