Files
wtr/types/notifications.ts
zv 2182297adc
All checks were successful
CI / Lint, typecheck and build (push) Successful in 9m54s
feat: add global weather support
2026-06-14 15:59:14 +02:00

36 lines
952 B
TypeScript

import type { Language } from "@/lib/i18n";
import type { Province } from "@/types/province";
import type { TemperatureUnit, WindSpeedUnit } from "@/types/units";
import type { WeatherRegion } from "@/types/weather-region";
export interface PushSubscriptionKeys {
p256dh: string;
auth: string;
}
export interface BrowserPushSubscription {
endpoint: string;
expirationTime?: number | null;
keys: PushSubscriptionKeys;
}
export interface WarningPushSubscription {
endpoint: string;
subscription: BrowserPushSubscription;
province: Province | null;
region: WeatherRegion;
language: Language;
enabled: boolean;
morningBriefEnabled: boolean;
tomorrowBriefEnabled: boolean;
latitude: number | null;
longitude: number | null;
locationName: string | null;
timezone: string | null;
countyTeryt: string | null;
temperatureUnit: TemperatureUnit;
windSpeedUnit: WindSpeedUnit;
createdAt: string;
updatedAt: string;
}