Notification preferencesPro
Channel-by-event matrix with column toggles, quiet hours and unsaved-changes bar.
What's inside
- Event × channel matrix
- Column select-all
- Quiet hours
- Unsaved-changes bar
When to use
- Notification settings in any product that emails, pushes or posts to chat.
When not to use
- One or two toggles: use switches.
Installation
Usage
Import it from @/components/blocks/notification-preferences after installing. It ships with sample data, so it renders straight away; swap in your own data when you're ready.
import { NotificationPreferences } from "@/components/blocks/notification-preferences";
export default function Page() {
return (
<main className="mx-auto max-w-6xl p-6">
<NotificationPreferences />
</main>
);
}API reference
NotificationPreferences
A channel-by-event matrix with select-all per channel, a required row, quiet hours, pause all and an unsaved-changes bar. Also the default export. No props: sample data sits at the top of the file, ready to swap for your own.
No props.
Keyboard interactions
| Keys | Action |
|---|---|
| Tab | Move through checkboxes |
| Space | Toggle |
Accessibility
- A table with row and column headers; every checkbox is labelled "<event> by <channel>".
- Column checkboxes show a mixed state.
Motion
- Quiet hours expand by height; the save bar slides up when something changes.
Responsive behavior
- The matrix scrolls horizontally under 448px.
Performance
- Sample data is plain arrays at the top of the file. Replace them with your API data and keep the shapes.
Notes for AI
- Security emails are locked on by design; keep at least one required channel for them.
This page as Markdown, for assistants and coding agents:
/blocks/notification-preferences/markdownThe full library index for assistants is at /llms.txt.
Lode222 doc pagesllms.txt