Toasts, logo icons, shared table toolbar with search, and a density toggle

Feedback: toasts confirm common actions, and a page's error or success message
that appears out of view is also shown as a toast. Icons: the tab, app and
home-screen icons are the house from the logo; a dev instance gets a coloured dot
on its tab icon. Tables: Secrets, Admin Links, IP Addresses and Alerts share one
toolbar (search, filters, row count, actions, Export CSV); twelve more tables get
a multi-word search box; long tables keep their column headings in view on wide
screens. Density: Compact / Normal / Roomy in the user menu, remembered per
browser.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
bobbanandClaude Sonnet 5.5 committed 2026-10-14 23:39:19 +02:00
1 parent 7d56ad18b7
commit 617dc1ea2f
56 files changed
+757 -158

No files matched your search

+7 -2
View File
@@ -17,6 +17,8 @@ import { usePagination } from "../hooks/usePagination";
import Pagination from "../components/Pagination";
import { downloadCsv } from "../utils/csv";
import { confirmDialog } from "../utils/dialogs";
import { ErrorNotice } from "../components/Notice";
import { toast } from "../utils/toast";
const PROVIDER_LABELS: Record<DnsProviderType, string> = {
cloudflare: "Cloudflare",
@@ -168,8 +170,10 @@ export default function Dns({ user }: { user: CurrentUser }) {
try {
if (editingRecordId) {
await api.dns.records.update(selectedProviderId, selectedZone.id, editingRecordId, recordForm);
toast.success("Record updated.");
} else {
await api.dns.records.create(selectedProviderId, selectedZone.id, recordForm);
toast.success("Record added.");
}
setRecordForm(null);
setEditingRecordId(null);
@@ -187,6 +191,7 @@ export default function Dns({ user }: { user: CurrentUser }) {
setError(null);
try {
await api.dns.records.remove(selectedProviderId, selectedZone.id, r.id);
toast.success(`Deleted ${r.type} record ${r.name}.`);
loadRecords(selectedProviderId, selectedZone);
} catch (err) {
setError(err instanceof Error ? err.message : String(err));
@@ -270,7 +275,7 @@ export default function Dns({ user }: { user: CurrentUser }) {
</button>
)}
</div>
{error && <div className="alert alert-danger">{error}</div>}
<ErrorNotice error={error} />
{managingProviders ? (
<>
@@ -402,7 +407,7 @@ export default function Dns({ user }: { user: CurrentUser }) {
</button>
</div>
</div>
{zonesError && <div className="alert alert-danger m-3 mb-0">{zonesError}</div>}
<ErrorNotice error={zonesError} className="m-3 mb-0" />
<div className="table-responsive">
<table className="table table-vcenter card-table">
<thead>