mirror of
https://github.com/jakejarvis/sofa.git
synced 2026-08-29 06:15:39 -04:00
Checks current version against latest GitHub release every 6 hours via cron job, caches result in appSettings, and surfaces updates through a toast notification (once per browser session) and an animated badge in the settings footer. Includes an admin toggle to enable/disable checks (enabled by default). Also renames ServerSection to RegistrationSection now that update checks are in their own card. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
8 lines
213 B
TypeScript
8 lines
213 B
TypeScript
import { atomWithStorage, createJSONStorage } from "jotai/utils";
|
|
|
|
export const updateToastShownAtom = atomWithStorage<boolean>(
|
|
"sofa:update-toast-shown",
|
|
false,
|
|
createJSONStorage(() => sessionStorage),
|
|
);
|