Webhookのメッセージをカスタマイズできるように

This commit is contained in:
CyberRex
2026-05-27 10:59:58 +09:00
parent 2a4050d442
commit 38acbd35bb
14 changed files with 994 additions and 49 deletions

View File

@@ -0,0 +1,42 @@
export const timezoneOptions = [
{ label: 'Midway, USA (UTC-11:00)', tz: 'Pacific/Midway' },
{ label: 'Honolulu, USA (UTC-10:00)', tz: 'Pacific/Honolulu' },
{ label: 'Anchorage, USA (UTC-09:00)', tz: 'America/Anchorage' },
{ label: 'Los Angeles, USA (UTC-08:00)', tz: 'America/Los_Angeles' },
{ label: 'Denver, USA (UTC-07:00)', tz: 'America/Denver' },
{ label: 'Chicago, USA (UTC-06:00)', tz: 'America/Chicago' },
{ label: 'New York, USA (UTC-05:00)', tz: 'America/New_York' },
{ label: 'Santiago, Chile (UTC-04:00)', tz: 'America/Santiago' },
{ label: 'Sao Paulo, Brazil (UTC-03:00)', tz: 'America/Sao_Paulo' },
{ label: 'South Georgia, UK (UTC-02:00)', tz: 'Atlantic/South_Georgia' },
{ label: 'Azores, Portugal (UTC-01:00)', tz: 'Atlantic/Azores' },
{ label: 'London, UK (UTC+00:00)', tz: 'Europe/London' },
{ label: 'Paris, France (UTC+01:00)', tz: 'Europe/Paris' },
{ label: 'Cairo, Egypt (UTC+02:00)', tz: 'Africa/Cairo' },
{ label: 'Moscow, Russia (UTC+03:00)', tz: 'Europe/Moscow' },
{ label: 'Dubai, UAE (UTC+04:00)', tz: 'Asia/Dubai' },
{ label: 'Karachi, Pakistan (UTC+05:00)', tz: 'Asia/Karachi' },
{ label: 'Dhaka, Bangladesh (UTC+06:00)', tz: 'Asia/Dhaka' },
{ label: 'Bangkok, Thailand (UTC+07:00)', tz: 'Asia/Bangkok' },
{ label: 'Singapore, Singapore (UTC+08:00)', tz: 'Asia/Singapore' },
{ label: 'Tokyo, Japan (UTC+09:00)', tz: 'Asia/Tokyo' },
{ label: 'Sydney, Australia (UTC+10:00)', tz: 'Australia/Sydney' },
{ label: 'Noumea, New Caledonia (UTC+11:00)', tz: 'Pacific/Noumea' },
{ label: 'Auckland, New Zealand (UTC+12:00)', tz: 'Pacific/Auckland' },
{ label: "Nuku'alofa, Tonga (UTC+13:00)", tz: 'Pacific/Tongatapu' },
{ label: 'Kiritimati, Kiribati (UTC+14:00)', tz: 'Pacific/Kiritimati' },
];
export function timezoneOptionLabel(timezone) {
const option = timezoneOptions.find((item) => item.tz === timezone);
return option ? `${option.label} - ${option.tz}` : timezone;
}
export function filterTimezoneOptions(search) {
const query = search.trim().toLowerCase();
if (!query) return timezoneOptions;
return timezoneOptions.filter(
(option) =>
option.label.toLowerCase().includes(query) || option.tz.toLowerCase().includes(query),
);
}