Source
This app’s code and revision history are public. Download a copy or explore the files below.
Public
The app’s code and revision history are public.
Run it yourself
Take the whole tree and run it on your own machine. The download needs no account. Cloning needs a sign-in.
Download .zip
bounded clone 9383f719c9b37ff76411858f
A copy you download is not bounded. The guarantees this app runs under - declared egress, proven invariants, writes that fail closed - live in the runtime serving this page, not in the files. What you get is auditable source you can read and run, with no runtime guarantees attached.
src/main.tsx
// Monitor's entry. "/" keeps the static landing and mounts the device chooser into its hero;
// the app screens (baby station, parent, watching) hide the landing and use the night look.
import { createRoot } from "react-dom/client";
import { usePath } from "./lib/router";
import { Toaster } from "./ui";
import { Launcher } from "./Launcher";
import { BabyPage, TopBar } from "./Baby";
import { PairLinkPage, ParentPage } from "./Parent";
import { WatchPage } from "./Watch";
import "./styles.css";
function Home() {
return (
<div className="night">
<div className="night-page">
<TopBar title="Monitor" back="/" />
<h1 className="night-h1">Free baby monitor</h1>
<Launcher />
</div>
</div>
);
}
function App() {
const path = usePath();
const watch = path.match(/^\/watch\/([A-Za-z0-9]{4,32})\/?$/);
const screen =
path === "/app" ? <Home />
: path === "/baby" ? <BabyPage />
: path === "/parent" ? <ParentPage />
: path === "/pair" ? <PairLinkPage />
: watch ? <WatchPage pairKey={watch[1]} />
: null;
document.body.classList.toggle("app-mode", Boolean(screen));
return <>{screen}<Toaster /></>;
}
createRoot(document.getElementById("app")!).render(<App />);
const start = document.getElementById("start");
if (start) createRoot(start).render(<Launcher />);
if (import.meta.env.PROD && "serviceWorker" in navigator) {
window.addEventListener("load", () => void navigator.serviceWorker.register("/sw.js").catch(() => null));
}
const head = document.querySelector(".site-head");
const onScroll = () => head?.classList.toggle("scrolled", window.scrollY > 4);
window.addEventListener("scroll", onScroll, { passive: true });
onScroll();
Change history
Move store links to openapps.free
Release with preview
Bind agent address in policy
Use OpenApps service URLs and add contribution strip (retry)
Bounded source sync
Bounded source sync
Bounded source sync
Bounded source sync