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

+11 -4
View File
@@ -17,6 +17,10 @@ import Pagination from "../components/Pagination";
import { downloadCsv } from "../utils/csv";
import { confirmDialog } from "../utils/dialogs";
import IntegrationPageTitle from "../components/IntegrationPageTitle";
import { ErrorNotice } from "../components/Notice";
import { toast } from "../utils/toast";
import { SearchBox } from "../components/TableToolbar";
import { useTableSearch } from "../hooks/useTableSearch";
function proxmoxStatusBadge(status: string) {
return status === "running" ? (
@@ -181,6 +185,7 @@ export default function Proxmox({ user }: { user: CurrentUser }) {
setError(null);
try {
await api.integrations.proxmox[action](selectedId, g.node, g.type, g.vmid);
toast.success(`${{ start: "Started", stop: "Stopped", restart: "Restarted", shutdown: "Shut down" }[action]} ${g.name}.`);
loadGuests(selectedId);
} catch (err) {
setError(err instanceof Error ? err.message : String(err));
@@ -189,7 +194,8 @@ export default function Proxmox({ user }: { user: CurrentUser }) {
}
}
const { sorted: sortedGuests, sortKey: guestSortKey, sortDir: guestSortDir, requestSort: requestGuestSort } = useSortable(data?.guests);
const tableSearch = useTableSearch(data?.guests);
const { sorted: sortedGuests, sortKey: guestSortKey, sortDir: guestSortDir, requestSort: requestGuestSort } = useSortable(tableSearch.filtered);
const { pageItems: guestPageItems, page: guestPage, setPage: setGuestPage, pageCount: guestPageCount, totalCount: guestTotalCount } =
usePagination(sortedGuests);
@@ -205,7 +211,7 @@ export default function Proxmox({ user }: { user: CurrentUser }) {
return (
<>
<IntegrationPageTitle title="Proxmox" integration={selected} />
{error && <div className="alert alert-danger">{error}</div>}
<ErrorNotice error={error} />
{integrations?.length === 0 ? (
<div className="card">
@@ -241,7 +247,7 @@ export default function Proxmox({ user }: { user: CurrentUser }) {
</div>
) : (
<>
{nodeStatsError && <div className="alert alert-danger">{nodeStatsError}</div>}
<ErrorNotice error={nodeStatsError} />
<div className="row row-cards mb-3">
{nodeStats?.map((n) => (
<div className="col-12" key={n.node}>
@@ -355,7 +361,7 @@ export default function Proxmox({ user }: { user: CurrentUser }) {
</div>
</div>
<div className="card-body">
{backupsError && <div className="alert alert-danger mb-3">{backupsError}</div>}
<ErrorNotice error={backupsError} className="mb-3" />
{backupTasks && backupTasks.length > 0 && !backupTasks[0].ok && backupTasks[0].status !== "running" && (
<div className="alert alert-danger">
Most recent backup run on <strong>{backupTasks[0].node}</strong>
@@ -473,6 +479,7 @@ export default function Proxmox({ user }: { user: CurrentUser }) {
</span>
)}
</h3>
<SearchBox value={tableSearch.query} onChange={tableSearch.setQuery} className="ms-3" />
<div className="card-actions">
<button
className="btn btn-sm btn-outline-secondary"