feat: add opt-in daily Discord reminders with quiet hours

This commit is contained in:
syntaxbullet
2026-09-04 18:45:42 +02:00
parent 16d92f171c
commit 1208e93953
22 changed files with 2367 additions and 9 deletions

View File

@@ -1,3 +1,4 @@
import { ReminderSettings } from "./ReminderSettings";
import { useId, useRef, useState } from "react";
import type { PublicUser } from "../shared/user";
import { habitRequest } from "../lib/dashboard";
@@ -29,6 +30,7 @@ export function AccountSettings({ user, onChanged, onClose }: { user: PublicUser
<datalist id={listId}>{["UTC", ...Intl.supportedValuesOf("timeZone")].map(zone => <option key={zone} value={zone} />)}</datalist>
<Button type="submit" disabled={busy}>Save timezone</Button>
</form>
<ReminderSettings timezone={user.timezone} />
<div className="ds-actions">
<ButtonLink href="/api/account/export" download="minabot-export.json">Export my data</ButtonLink>
<Button variant="text" disabled={busy} onClick={() => setDeleting(!deleting)} aria-expanded={deleting}>Delete account</Button>