An AI chat in a tiny iPhone, with no build step.
Drop this file on any static host, or run npm run dev and open
localhost:3000/chat-demo.html
so the widget hits same-origin /api/chat. Live hosted copy:
publishd.app/chat-demo.html
— streams from our API; visitors never paste a key (Groq stays in server env). From other domains, set CHAT_WIDGET_ALLOWED_ORIGINS on the host. Offline / blocked → short canned demo.
File in repo: public/chat-demo.html
Stack
One .html file. No bundler, no React — bezel PNG is embedded as base64. Pure HTML + CSS + vanilla JS.
Phone frame
Transparent PNG bezel (embedded as base64). Same 84.33% × 92.5% screen inset as the real site.
Persistence
Messages only in localStorage on the visitor's device. Clear with the refresh icon in the chat header.
Privacy
Each message is sent to the API so Groq can reply — not for Publishd model training. Don’t paste secrets (passwords, keys). See publishd.app/privacy.