The pieces of the ChatGPT app the owner put beside ours (2026-10-21), done
once here so Loki, OrangeCat and every chat in the fleet get them:
- `AnswerActions`: the row under an answer. Copy; Listen, reading the answer
as prose (`plainTextForSpeech`, from loki) with the browser's voice or the
`speaker` an app passes (loki's studio voice), with a small player — Stop
and the time so far — while it reads; Share through the system sheet
where one exists. `ChatThread` renders it under every answer.
- Sources on a touch screen are ONE "Sources · n" button that opens a sheet
with every record (label, detail, link); chips stay on a mouse. `Sheet`
(the attach sheet's <dialog>, extracted) and `SourcesRow` are exported.
- `AttachMenu` takes `extra` rows under Camera · Photos · Files, and then
opens the sheet on a mouse too — an app's "one of my things" has no file
dialog to live in.
- The replies instruction makes the model lead: 2–4 replies on every answer,
the recommended next step first, drawn as the lead (`ck-reply-lead`).
- An empty box is one row on the narrowest phone: the placeholder is cut at
the edge, never wrapped into a clipped second line.
Browser checks cover the player, the sources sheet on a touch screen and
chips on a mouse, and the one-row placeholder at 320px.
Claude-Session: https://claude.ai/code/session_018WZnBnaLP6RhwFkLxRTKgE
Co-authored-by: Claude <noreply@anthropic.com>
- `@bitbaum/chatkit/attach`: AttachMenu, ATTACH_SOURCE_INPUT, isTextFile,
acceptFamilies and shrinkImage without the composer, so an app with no chat
(avatars, product photos, receipts) uses the same picker instead of
re-rolling a file input. AttachMenu takes `sources` (an image uploader offers
Camera + Photos; one source skips the sheet) and a `trigger`.
- `chatkit-check-file-inputs` (bin): fails CI on a literal accept that mixes
file families — the shape that hid screenshots on Android in loki, orangecat
and evig. Same rule as the package (acceptFamilies), so there is one
definition; a justified exception is marked on the line.
- shrinkImage moves out of the composer hook into src/image.ts (unchanged).
- README: install releases from npm, never a commit — heidi and substrata
stayed on the broken paperclip because they pinned old versions.
Claude-Session: https://claude.ai/code/session_01BWXjqiHm8jFta4FXuc7Tck
Co-authored-by: Claude <noreply@anthropic.com>
* feat(composer): Camera / Photos / Files sheet instead of one mixed file input
On Android the paperclip opened a chooser of capture apps (Camera, Camera,
Recorder, "Photos & Videos") with no way to the file browser: one input with
a mixed accept (image/*,text/*,audio/*) is answered that way. Attaching a
screenshot to Loki was effectively impossible from a phone.
- AttachMenu: on a touch screen the paperclip opens a bottom sheet with three
sources, each its own input (ATTACH_SOURCE_INPUT is the SSOT): Camera
captures, Photos opens the system photo picker, Files has no accept and
opens the real document browser. With a mouse it opens the dialog directly.
- isTextFile: Files takes anything, so what can be read inline is decided
after the pick. A PDF gets a sentence instead of being pasted as bytes.
- The sheet is portalled to <body> so a composer inside a transformed or
clipped panel still gets a full-screen sheet. react-dom becomes a peer.
- Tests: unit (sources, text detection), SSR (one input per source), browser
(sheet on a phone, 44px targets, Escape, Photos picker accept, PDF note,
direct dialog with a mouse). CHROMIUM_PATH lets the browser suite run
against a preinstalled Chromium.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BWXjqiHm8jFta4FXuc7Tck
* refactor(attach): the sheet is a native <dialog>, not a portal
showModal() renders in the top layer, so a composer inside a transformed or
clipped panel still gets a full-screen sheet without react-dom, and the
browser supplies Escape, the focus trap and focus restore. react-dom is no
longer a peer. A tap on the backdrop closes it (browser-tested).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BWXjqiHm8jFta4FXuc7Tck
---------
Co-authored-by: Claude <noreply@anthropic.com>