442 Commits
Author SHA1 Message Date
CatoandClaude Opus 5.5 5b521645de fix(profile,messages): your own page is one to send; a photo always shows; the Cat answers once (#1865)
* fix(messages): a photo is never drawn as an empty row; one message gets at most one Cat answer

Owner's phone, 2026-11-15, the conversation with Penguin:

- A photo sent at 01:16 showed as an empty row with only a time and a tick.
  The server writes the message and then links its uploads; the realtime
  INSERT made the thread re-read in between, the message came back without
  its files, replaced the sender's copy, and nothing re-read it (linking a
  file is not a change to the message). A message of files without them is
  now held back for up to a minute and re-read every 1.5s until its files
  are on it (`filesStillLinking`); past the window it is shown as it is.
- The Cat answered the same question twice in a row. The queue was already
  one row per message, but two queued messages (two tags, or a tag and a
  follow-up) each produced an answer written from the whole window, so both
  answered the newest question. An answer now records how far it read
  (`answered_through`); a queued message an answer had already read is done
  without writing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(profile): your own page is one to send; listings are rows; edit profile reads clean

Owner's phone, 2026-11-15:

Own profile
- No orange "Pay" aimed at yourself. The owner gets Edit profile and one
  primary action, "Share your page"; a visitor keeps Pay. "Pay Cato" on
  Overview is "Your pay link" (the code and link), not a button to pay
  yourself.
- "What I can offer": one shape. Skills, asked-for, assets and not taking on
  are the same small tags, six then "+N more"; the owner's one action is
  "Create a listing from a skill", a list of rows.
- Project and listing cards: the picture is a square at the start of a row,
  picture or not (the Discover phone shape), so a shelf without photos is a
  list, not a column of tall grey plates. A picture that fails shows the
  kind's icon. Category and status are words above the title. The owner's
  own card offers Edit, not Support.
- Tabs: four up front (Overview, Timeline, Projects, Wallets) and "..." on a
  phone; words only below sm. One row at 390px.
- Contact and Links on your own page say "Only you see this" when hidden
  from visitors.

Edit profile
- The location field leaves room for its pin; a place is shown and picked
  short ("Zurich, Switzerland"). Stored rows are not rewritten.
- Plain words for the location group ("a group name you share with others").
- The Save bar on a phone is pinned above the tab bar with a spacer of its
  height at the end of the form, and fills down behind the tab bar, so
  nothing shows through or hides under it. One bar.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(cat): answer-once test mocks the Cat's thinking step from main

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): own profile, edit profile, Messages

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(cat): a failed answer-once check never silences the Cat

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-12-02 20:38:52 +01:00
e8dc1c87c2 feat(articles): cover pictures, charts and writing suggestions you accept or reject (#1780)
* fix(community): a QA run's posts and listings stay off the public shelves

Live after #1736, /community opened with "QA test post from A" by
"QA Grok A", and Discover's first product, "Old Road Bike", was that QA
account's too, its share card reading "by QA Grok A".

- The community feed drops posts whose author's display name is a fixture
  name (NOT_A_FIXTURE_AUTHOR, the People directory's rule on the view's
  actor_data); checked read-only against production.
- 20261113201500 marks the QA account's remaining products, services,
  projects and causes is_test (matched by id and its QA name; nothing
  deleted; rollback in the file).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(timeline): sign every post author through one byline helper

A minted user_<hex> handle was still printed as name and @handle on
/community, in quotes, reposts, the reply placeholder and the post's
share text. postAuthor() (src/utils/byline.ts) is now the one rule:
chosen name, else chosen handle, else the neutral phrase; no @line for
a minted handle; the avatar plate shows a person glyph, not its letter.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(companions): no bot face is orange; check:one-orange covers the pigments

orange and amber are replaced in place by two shared map-scale token
values (indigo, steel), so every other name keeps the face it had. A
stored face URL with hue=orange/amber resolves to its replacement.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(cat): one face for the Cat, used everywhere it is drawn

CatAvatar draws the brand icon tile; CAT_AVATAR_PATH is the same drawing
for slots that only take a URL. Feed, quotes, the answering row, the
mention menu, the profile, follow lists, Messages (list, picker, thread)
and the profile share card all use it. The answering row's AI chip is
neutral like the post header's, not orange.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(not-found): one not-found page for every kind

components/ui/NotFound.tsx is the only 404 design: 'This {kind} isn't
here', one sentence, a search that goes to Discover, the kind's own
shelf and Home. Every public detail route has a not-found.tsx naming
its kind (products, services, events and others fell through to 'Page
Not Found'), wallets no longer have their own layout, and tab titles
come from notFoundTitle() in sentence case with registry names.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* refactor(cat): name the Cat's picture a src, not a path

audit:routes reads a *_PATH string constant as a page link and failed on
the static icon. It is an image source.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(legal): read the operator from one unset constant

LEGAL_OPERATOR (src/config/legal.ts) is null: the legal entity is not
known and is not guessed. While null, /terms and /privacy say what they
said before and stay marked Draft. Once filled in, the opening sentence
and Contact section of both carry the legal name, address and contact.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* style(projects): merge a duplicate import to stay inside the size limit

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(ci): cover the bot-face check in the one-orange gate fixtures

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(cat): one real answer for a visitor, and a pay-link name check

POST /api/cat/first-answer answers a visitor's own sentence before they
have an account, on the visitor budget (general per-IP, then 3 an hour of
its own), for the page's own origin only. Nothing is stored.
GET /api/pay/name says whether a pay-link name is free to claim.
The door helpers carry a typed sentence through sign-up to the Cat.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(faq): say about Cat Credits what the pricing card says

The FAQ offered credits as open while /pricing badged them "Not open
yet". Both sentences are now built in cat-plans.ts from
CAT_CREDITS_ON_SALE. The free plan no longer calls Gemini open-source.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(home): the home page sells the outcome, in one promise

The hero is the promise and one action: claim orangecat.ch/pay/<name>,
with the page that name makes shown as it is typed. Under it, Discover's
own "Just listed" rows instead of the studio grid and the small counts,
then the Cat's door, which answers a visitor's sentence once and invites
them to sign up with the sentence kept (the account screen shows it).

The promise is written once in config/brand.ts and read by the hero, the
titles and descriptions, the share card, the sign-in panel, About and the
footer. /pricing opens on "0% to sell"; the Cat plans follow.
The start action is named for what you get: "Get your page".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(entities): one cover picture for every kind, in every create and edit form

ENTITY_COVER (src/config/entity-cover.ts) names each kind's cover column
once. base-config-factory puts the same picture field under the description
of every form (and into the wizard step that shows the description), the
schemas accept it, creates write it through coverColumn and updates through
coverFieldMapping, which also lets a removed picture clear the column.

Five kinds had no column to keep a picture in (service, cause, asset, loan,
research): one migration adds a nullable cover_image_url to each and makes
public_documents() read every kind's cover first, so Discover and search
show it. Rollback is in the migration.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(discover): the cover is the hero, the card and the share picture; no picture shows the kind's icon

The public page's hero, the Discover and search card, the dashboard card, a
profile's shelves and the share card all read the kind's cover through
entityCoverImages. Without a picture a listing shows its kind's icon on a
token surface (EntityCoverPlaceholder) on every list, replacing three
different letter plates; a bot wears the face its name picks and a person
keeps a round initial.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): home sells the outcome, a picture for every kind, one byline

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(messages): the Cat answers every message in a conversation with only the Cat

A one-to-one with the Cat stayed silent unless the message tagged @cat: only
a tag queued a reply. Alone with it there is nobody else a message could be
for, so a message there is owed an answer without a tag. In company the Cat
still waits to be tagged.

- isAloneWithCat(): one person and the Cat, asked by the write path and by
  the reply.
- The reply is worded for it (nothing was tagged) and carries no
  requested_by: there is nobody else it answered for.
- A message of only files asks nothing.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(messages): New opens on the Cat, your bots, recent people and people you follow

The New message sheet opened on the viewer's own bots only, so for anyone
without a bot it was empty until they typed. It now offers the Cat first, then
their bots, the people of their latest one-to-one conversations and the people
they follow (eight people at most, nobody twice, no unnamed placeholder
accounts). Typing still replaces the list with the search.

- The Cat found by search is shown as an agent, with its own face.
- Alone with the Cat, a sent message shows it writing and looks for its
  answer, as with a bot.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(payments): one payment flow, purchases as orders, services booked first

One flow. Paying a person, supporting a page, investing, buying and paying a
booking now share /pay's words, steps and receipt:
- src/config/payment-flow.ts and pay-words.ts are the one vocabulary (the verb
  and the figure, "Waiting for the payment…", "Change amount", "Paid").
- PaySteps draws the code, the claim, expired and failed once; PayFlow, the
  support card, the purchase dialog, the ticket card and the booking use it.
- Every success is MoneyReceipt (To / For / When). "Tip" becomes "Support".

A purchase is an order. A signed-out buyer was shown the seller's bare address
and typed the price by hand; nothing recorded the sale. Now they give a name
and get a code for the price, minted on the seller's wallet, with an order row
(buyer_id NULL). Orders have a page (/dashboard/orders) for seller and buyer.

A service is booked first. The service page has no purchase; once the provider
accepts, the booking asks for the payment through the same flow, and settlement
marks the booking paid (orders.booking_id). No escrow: the money goes straight
to the provider's wallet.

Who is paid and what is charged are unchanged: resolveSellerWallet and
resolveAmount (the booking's own price_btc for a booking).

Migration 20261114091700: orders.buyer_id nullable, orders.booking_id.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(bookings): a booking's money is server-written, paid once, and never "paid" by the customer's own hand

- Migration 20261114104100: clients lose INSERT and table-wide UPDATE on
  bookings and keep UPDATE on the five columns confirm/reject/complete/cancel
  write; the customer's policy only allows cancelling. createBooking inserts
  through the service role.
- Paying a booking reads the price with the service role and what is paid
  from the booking's paid orders, never from the client-visible row.
- One live invoice: an open request is checked against its rail and handed
  back instead of minting a second; nothing is minted while a claim or an
  on-chain confirmation is pending.
- Settlement recomputes total_paid_btc from the paid orders (no read-then-add).
  A payment landing on a cancelled, declined or no-show booking is recorded on
  the order, not applied to the booking, and both sides are told.
- An unpaid booking can still be paid after it is marked complete.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(payments): a pass is not sold without an account

A Supporter or Loki pass is granted to the buyer's account at settlement; a
guest has none, so the money arrived and nothing was granted. The guest
purchase refuses such products before any invoice, and the page offers
sign-in in place of the guest panel, saying why.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(payments): booked-first holds on the server; a guest buyer is named; a request never made is not a failed payment

- POST /api/payments refuses a service and points to the booking; so does
  /api/v1/payments for a person's session. A key or OIDC caller keeps it:
  Loki pays a builder booked on its own side through a service.
- The seller's email names a buyer without an account instead of looking a
  profile up by a null id; a claimed purchase is "a buyer", not "a supporter".
- An initiation error (no wallet, nothing left to pay) is titled "This could
  not be started", not "This payment did not go through".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): one way to pay, guest orders, booked first, the Cat alone

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(migrations): say why dropping NOT NULL on orders.buyer_id is rollback-safe

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(messages): suggestions read the follow list through the shared reader

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(discover): a person's card never prints a minted handle

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(listings): the seller card never prints a minted handle

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(share): one look for an article everywhere it is shared

The same article looked two ways on the timeline: the publish post was an
ARTICLE card, the post made by "Post on OrangeCat" was its title above a
bare "orangecat.ch/articles/scythia-notes-towa...". Sharing that post to X
sent the post URL, not the article's, with "Cato: “...”" in front of Cato's
own words.

- Links to our own pages unfurl from our own data: /api/unfurl resolves
  articles, posts, profiles, pay links, projects, groups and every entity
  with a public page (sessionless read, each page's public rule) into one
  LinkCard. The publish post and any post linking to the article draw the
  same card; a post that only restates the title shows just the card.
  External links print as host + path, cut at a boundary.
- The share intent no longer types out the title of one of our pages above
  its link (the card shows it).
- Share on a post: an article post (or a post that is only a link to one of
  our pages) shares that page's URL with its title and one line; your own
  post goes out as your words, someone else's quoted and credited.
- /post/<id> of an article post previews as the article (title, dek,
  canonical, /api/og/article card); /api/og/post draws it as an article.
- The article share card carries the dek, the author's face and name, and
  the cover picture beside the words when the article has one.
- Share cards read the image format from the bytes: our storage serves
  avatars as application/octet-stream, which dropped every face from every
  card.
- ShareRow passes `text` through to @bitbaum/bip-kit (used from 0.10.0,
  ignored by the pinned 0.9.1).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): one look for an article everywhere it is shared

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(articles): cover pictures up front, charts drawn by chartkit, and Cat's writing help as suggestions

- Editor: "Add a cover picture" sits under the title (search, generate or
  upload in one picker); picture and chart buttons lead the toolbar (one row
  that scrolls on a phone); inline pictures land as figures with their credit
- Charts: a ```chart block (writingkit's spec, JSON or CSV) is drawn by
  @bitbaum/chartkit on the article page and in Preview; the fence is renamed
  before bip-kit parses it, so a block a person typed can no longer throw and
  take the article page down; a broken block tells the writer why
- Ask Cat proposes, the writer decides: every answer (improve, tighten,
  clearer, grammar, tone, continue, outline, draft, title + summary) is a
  suggestion shown as what changes, with Use this / Keep mine; accepting
  after the text moved on is refused, not applied
- New: "Make it clearer", "Suggest a title and summary", "Suggest a picture
  or chart" (a chart only from the writer's own numbers, checked; otherwise
  an illustration with search terms and a generation prompt that seed the
  picker), "Outline it" from one sentence
- Share card: /api/og/article/<slug> draws the cover beside the title
  (fetched through the pinned public-only GET, cropped by sharp); the
  article's og:image is always that card
- deriveExcerpt skips a leading chart or lone picture
- src/lib/writing-next/ carries writingkit 0.3.0's new core until it is
  published (then delete it and import from @bitbaum/writingkit)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): article pictures, charts and writing suggestions

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Cato <cato@orangecat.ch>
2026-12-02 07:03:00 +01:00
b2da8561b7 refactor(brand): marks come from @bitbaum/design-tokens/marks (#1584)
* refactor(brand): marks come from @bitbaum/design-tokens/marks

Every product's mark now lives in the design-tokens package (1.6.0), so
a logo is replaced once and OrangeCat, Solon and Loki follow. The local
copies (loki, orangecat, solon) and the source writer are gone;
src/config/marks, mark-svg and svg-to-mark re-export the package, so no
call site changed. The cat generator stays here and the brand test holds
the package's cat equal to it. `brand:import` now prints where to import
a mark instead of writing a copy that would drift.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsX15QgjkDp9MQaQ92

* docs(brand): name the package's import script without claiming it here

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsX15QgjkDp9MQaQ92

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Cato <cato@orangecat.ch>
2026-11-28 22:56:37 +01:00
CatoandClaude 88b06e8adc Public pictures straight from R2; the box stops resizing them (#1861)
Public pictures still passed through the app box: storage-api answered
every supabase.orangecat.ch/storage/v1/object/public/... request, and
next/image fetched, resized and cached them there. orangecat-media holds
private files too, so it never gets a public domain; public pictures go
to the separate public bucket fleet-media under orangecat/<bucket>/<path>,
served from MEDIA_PUBLIC_BASE.

- src/lib/media/public-url.ts: the one URL helper. Direct address only
  for objects known to be copied (listing every 10 min + own writes),
  otherwise the Supabase address. Unset base: unchanged.
- New uploads: server-side ones are written to fleet-media as stored;
  browser uploads ask POST /api/media/mirror. Stored URL is the direct one
  or, on any failure, the Supabase one.
- Background copy from instrumentation: idempotent, throttled
  (MEDIA_BACKFILL_KBPS, 512), one process at a time under a lease taken
  with a Postgres advisory lock (new migration). Only buckets declared
  public in code AND marked public in storage.buckets. Removes copies of
  deleted originals after a complete scan, capped at a tenth per run.
- next/image: with the base set at build, a custom loader draws R2
  pictures unoptimized and sends Supabase public pictures to
  /api/media/object, which redirects to R2 once copied, else to the
  optimizer as before.
- Docs: STORAGE_R2_BACKEND.md (how, switch-on, rollback, the pre-move
  disk copy an operator may remove), .env.example; three docs that named
  the removed auto-merge.yml now name the forge merge check.


Claude-Session: https://claude.ai/code/session_019MDtmvb6xi489TfZMg7n9T

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-26 20:49:44 +01:00
29285fafe5 fix(cat): four fixes from the 15 Nov live retest, in one PR (#1858)
* feat(cat): add calendar_move to move or change an own calendar entry

The Cat could add and remove entries in the person's own calendar but not
move one, so live it told an owner it could not move calendar entries.

- calendar_move changes the start, and optionally the length, end, title
  or place, of one own entry (the calendar source: made by the person,
  the Cat or a bot). A new start with no end or length keeps the length.
- Times go through parseWhen in the person's zone, as calendar_add does.
- The write is filtered to the user's own rows on top of RLS, as
  calendar_remove is. An entry from a linked calendar, Google, a booking,
  an event or the to-do list is refused with a sentence saying where it
  is changed.
- Registered beside calendar_remove: cat-actions, summaries, action
  descriptions, companion labels and hands, planner hands and handlers,
  plus the "move" verb in the tool labels. Same permission level.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* fix(chat): Listen reads answers in a server voice, browser voice as fallback

Listen under a Cat answer (and under every bot answer) made no network
call: chatkit's useSpeech was given no speaker, so it used only the
browser's speechSynthesis. Reproduced live on /companions/talk?with=cat:
the press called speechSynthesis.speak("391") with 0 voices available and
the utterance ended with error "synthesis-failed"; the button flipped back
with no message. With a stubbed working engine the same press plays for
the full length, so the app wiring was fine: the voice was missing.

- POST /api/voice/speak: one piece of text -> audio/wav through Groq's
  speech endpoint on the platform GROQ_API_KEY (counted against the
  daily Groq cap); 503 / 502 carry the reason (no key, terms, bad key,
  limit, vendor down) and the vendor detail goes to the server log.
- createListenSpeaker: chatkit Speaker that cuts the answer into ~200
  character pieces, fetches one ahead, plays through an AudioContext made
  inside the tap, and hands the rest to the browser voice on any refusal
  (backing off two minutes). German text stays on the browser voice.
- Passed to the Cat (ChatApp thread.speaker) and ChatFrame (companions,
  fleet bots, rooms).
- rateLimitListen: 120 pieces / 10 min per person.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* fix(cat): page reads are cut to fit the free Groq link instead of losing it

Live, 2026-11-15: "What happened in the news today?" found six sources,
the page reads pushed the prompt past the free Groq per-minute cap, the
pre-flight skipped Groq, the free fallbacks were rate-limited, and the
person got "Cat couldn't reach an AI model". On the platform Groq link
the longest tool results are now shortened until the prompt fits, and
the pre-flight checks the shortened prompt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* fix(ai): an OpenRouter refusal inside the stream is an error with its code

Production diagnostics after the live retest (2026-11-15) showed six
OpenRouter failures with no status. OpenRouter can refuse after the 200,
as an error object inside the stream; that chunk was skipped as
malformed, so a rate limit read as an empty answer. It now throws
OpenRouterAPIError with its code (429 is a rate limit), and the
diagnostics report the provider's error type next to its class.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Cato <cato@orangecat.ch>
2026-11-26 17:40:44 +01:00
CatoandClaude Opus 5.5 58d5d99546 fix(articles): the editor Preview shows Under the hood sections as the page does (#1856)
The composer Preview skipped toSegments, so every ```deep section previewed
as a raw code box while the published article shows a closed <details>.
Found while previewing an article before publishing it. The preview now
segments exactly like LongformBody; a jsdom test pins it (fails on the old
file, passes on this one).

Signed-off-by: Cato <41178744+catomean@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-20 16:39:59 +01:00
CatoandClaude Opus 5.5 22693ba4b0 fix(cat): "from my account" still sets the page up for the person; cards never show as JSON (#1854)
Dogfooded 2026-11-20: "set this up for my friend Kelly Goy, but from my
account" got a create_entity owned by the asker, so Kelly had nothing to
claim. "From my account" means the user does the setting up; that is
exactly what create_project_for_person does (asker stewards, person
claims). The prompt now says so, and the section also loads for a named
person or "from/under my account" without the word "friend".

The same turn showed its ```action block as raw JSON while streaming,
then failed mid-stream and was stored ending inside the fence. Card
fences are now hidden while streaming (closed, open, or still being
typed) and when a failed turn is reopened.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-20 11:12:49 +01:00
Cato be046c4f93 fix(todo): To-do at the top of the sidebar; send a task to your own bots (#1843)
* fix(todo): To-do at the top of the sidebar; send a task to your own bots

- Sidebar: To-do sits right after Calendar at the top level (it was folded
  inside 'Money and work'). 'What you can do' moves to More so the primary
  list stays at nine rows.
- Task page: 'Request' becomes 'Send to…'. On your own task it lists your own
  bots first (e.g. Hendlar), then people. Picking a bot hands the task over:
  it lands in that bot's chat, the bot works on it and reports back on the
  task, with a notification.
- Handing over no longer refuses without an own AI key: the turn runs like any
  chat with the bot, on the free daily allowance with its cap; a used-up
  allowance is named on the task.

* fix(todo): Send to… lists the Cat and your own bots, narrowed by what you type

Typing 'Cat' offers the Cat itself (not only the person @cato); typing a bot's
name narrows to it. Sending to the Cat opens the Cat with the task's title,
notes and address, sent once its chat is ready (askCatOnOpen +
usePendingCatAsk, the same send path as typing). Sending to an own bot hands
the task over into that bot's thread as before.
2026-11-20 00:25:29 +01:00
CatoandClaude fac8ea21e6 Accept client_secret_post/basic at DCR, register as public (#1849)
claude.ai custom connectors register with token_endpoint_auth_method
"client_secret_post"; /oauth/register refused anything but "none", so
adding the Loki connector with automatic registration failed.

Per RFC 7591 §3.2.1 the server may replace requested metadata: accept
none, client_secret_post and client_secret_basic, always register a
public client, answer token_endpoint_auth_method "none", issue no
secret. PKCE S256 stays required at /oauth/authorize. Other methods
(private_key_jwt, ...) are still refused.

/oauth/token now reads client credentials from a Basic header as well as
the form (moved to services/auth/tokenClientAuth.ts), and ignores a
secret a public client sends rather than refusing it. Confidential
clients still need theirs. Metadata advertises client_secret_basic.


Claude-Session: https://claude.ai/code/session_019MDtmuhWfFPT9wKangtTyJ

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-19 22:00:51 +01:00
CatoandClaude Opus 5.5 3a952e3a3e feat(cat,apps): the Cat in Messages acts; Messages and Calendar open inside OrangeCat (#1842)
The Cat in Messages had no tools. "Reschedule to 7pm" was answered
"Done. Visit Anja is now at 7:00 PM Monday." and nothing moved. Asked
why, it said it had no live path into Loki or the calendar. Both were
true only of this path: the Cat chat has had these hands for months.

- cat-acts.ts: in a person's own conversation with the Cat, the newest
  message runs through a tool loop over the bots' hands
  (COMPANION_HANDS: calendar, to-do, Loki, mail and GitHub reads, own
  entities). Each call goes through CatActionExecutor as the sender,
  with permissions, confirmations and the action log as in the Cat
  chat. The reply is written from what happened. In rooms with other
  people it never acts, because a calendar read would be read out to
  everyone there.
- A reply that opens with "Done"/"Moved"/... when no tool completed is
  replaced. This applies to the tool-less fallback too.
- calendar_move: a new hand that moves an own entry and keeps its
  length (services/planner/calendar-move.ts). Before, there was add and
  remove only. Bots get it too.
- Separate apps open in OrangeCat: /messages, /dashboard/calendar,
  /dashboard/tasks and /studio wear OrangeCat's chrome unless the
  window was launched as the installed app. The manifest start_url
  carries ?app=<id>, which is remembered per window in sessionStorage
  (useLaunchedOwnApp).
- Prompt budget 8,110 -> 8,230 for calendar_move, recorded in the test.

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-19 16:47:20 +01:00
CatoandClaude Opus 5.5 7f1dc4198d AI article writing: long text fitted, not refused; throw everything in and Cat writes it (#1838)
* fix(ai): fit long briefs instead of refusing them; actionable input errors

A pasted chat in Ask Cat's "What would you like to write about?" box hit a
300-character zod cap and answered "Invalid request". AI routes now fit free
text to the model budget (ai-kit fitPromptText) and explain real refusals
by field, limit and fix (ai-kit explainInputIssues).

Needs @bitbaum/ai-kit with the input module (bitbaum/ai-kit#119).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

* feat(articles): AI-first writing — throw everything in, Cat writes it

An empty article now opens with "Write with Cat": thoughts, speech, a
pasted chat, links, notes and pictures go in; one button writes a cited,
illustrated article that opens in the editor for changes.

- POST /api/ai/writing/compose: thin route over services/cat/writing-compose,
  which binds writingkit's composeArticle to OrangeCat's adapters — ai-kit
  readPage (SSRF-checked), the platform serving chain, vision through the
  same chain (describePlatformImage), Openverse for illustrations, and the
  writer's recent posts for voice.
- ArticlePile: writingkit's PileComposer with OrangeCat's words, mic and
  picture storage.

Needs @bitbaum/ai-kit 1.31 and @bitbaum/writingkit 0.4.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

* chore(deps): @bitbaum/ai-kit ^1.31.0 (fitPromptText, explainInputIssues)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

* fix(types): AI input and compose pass strict exactOptionalPropertyTypes

Absent optional fields are left out instead of set to undefined
(toPileItems, labels, credit, voice, fetch signal).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

* feat(articles): an empty article leads with Write with Cat

The article-writing browser test guarded "editor visible near the top" —
the title-first assumption the owner retired on 15 Nov 2026 (AI-first:
throw everything in, Cat writes it). It now guards the new rule: Write with
Cat near the top on a phone, the editor still on the page, and the Ask Cat
draft flow, overflow and 44px checks unchanged. The pile's one action is
ink, not the accent (One orange).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsN9mz8QfGDCrNhY9p

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-19 16:18:51 +01:00
CatoandClaude 33602c2b93 feat(bots): every bot is a rotorelief in the Cat's family, with a picture its owner can change (#1818)
The default bot face (a shape with two eyes) read as Grok's bots. OrangeCat's
mark is a Duchamp rotorelief (off-centre rings in a cat's head) and Loki's
is the coil, so every other bot now gets a disc of its own in that family:

- Four figures after Duchamp's discs (rings, coil, corolla, lantern), each
  bot's figure, colour, count and drift drawn from its name
  (config/marks/generators/bot-rotorelief.ts). Twelve deep colours, none
  orange: the Cat stays the only orange one and the only one with ears.
- A bot is a rounded square, a person a circle; the initial sits in the
  disc's eye from 28px up, and the disc turns at the Cat's thinking speed
  while the bot answers (chat header; in a group chat, the one writing).
- Picture sheet with three tabs: Generated (its own disc, seven more,
  Shuffle), Upload (our storage), Describe (the person's own AI key, as in
  the Studio; without one it offers Upload). Used for a new bot, a group
  chat's picture, and a new "Change the picture" row on the owner's bot.
- The server takes a disc token or a picture in our own public storage,
  never another URL (lib/companions/picture.ts). A bot's picture is saved
  by its own route, since the bot's whole PUT fills defaults for what it
  is not sent.
- Faces stored before (?shape=&hue=) draw as the disc their old pair keys,
  so bots told apart then stay apart. Product bots keep their own marks.


Claude-Session: https://claude.ai/code/session_019MDtmtCeJSbD69gBDGaLAE

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-15 17:09:51 +01:00
CatoandClaude 1e153fe6ff feat(blog): searchable index, a short topic row and one card shape (#1814)
/blog put all 59 topics in one sideways row, so most were off screen,
plus nine overlapping date filters, uneven cards and tag pills that
looked like buttons but did nothing. The article page used the old
share sheet instead of the ShareRow every other article uses.

- The list is a listkit query (blogList.ts): a topic facet, search over
  title, topics and summary, newest first. The URL codec, counts and
  matching rules come from the package, which replaces the
  hand-written URL and date code in useBlogFilters.
- BlogTopics: "All posts", a "Topics" toggle, then the six most used
  topics (and the chosen one). The full index is a grid list with
  counts. Chips and the search field reuse Discover's classes.
- BlogPostCard: one anatomy (topic, title, 3-line summary, date and
  length on the card's floor). The newest post leads at full width
  while nothing is filtered.
- Article: topic, title, summary and one byline line. The footer has
  topic links, the shared ShareRow, older/newer posts and
  BlogNewsletter, the same follow box as the index. Drops the
  Featured badge, BlogShareButton, getFeaturedPost and getAllTags.
- Fixes a doubled blockquote marker in governing-without-the-jargon.


Claude-Session: https://claude.ai/code/session_019MDtmtwEdUXtezpStDjHte

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-15 16:29:04 +01:00
Cato 72a24214bd fix(og): read card images up to the cap, never whole; watchdog checks every 5s (#1800)
The memory watchdog restarted the app at 11:06 UTC: memory went from
~390 to 774 MiB inside one 30s check gap, 151 MiB of it ArrayBuffers,
so something buffered a very large body at once. loadCardImage read any
linked image whole with res.arrayBuffer() and only then compared it to
its 4 MiB cap, so one share card pointing at a huge file put all of it
in memory. Read in chunks and drop at the cap, skipping a declared
oversize length unread.

The watchdog now reads RSS alone every 5s (cheap) and takes the full
breakdown only for its log line, so a spike is caught before it passes
memory.high.
2026-11-15 13:27:45 +01:00
Cato 11909ac2c3 fix(app): restart cleanly before the kernel throttles the server on memory (#1788)
Memory still creeps with V8's heap capped at 512M (523 MiB at 39 min,
639 MiB at 102 min after the 07:36 deploy), so part of it is outside the
JS heap and the cap alone does not keep the app under the unit's 768M
memory.high. Over that line the kernel throttles instead of killing:
the app hangs for hours, as it did six times on 14-15 Nov.

A watchdog started from instrumentation checks resident memory every 30s.
At 704 MiB it logs heap vs external memory and sends the server SIGTERM;
Restart=always is back in 3s. Every 15 min it logs one sample line, and
Cat diagnostics labels both, so the next run shows where the memory goes.
2026-11-15 11:01:08 +01:00
CatoandClaude Opus 5.5 0074ad831f feat(messages): bots and the Cat see photos and hear voice; @ calls bots in (#1783)
* feat(messages): bots and the Cat see photos and hear voice messages

- A voice message gets a transcript, made once and kept
  (message_attachments.transcript), on the asker's own Groq or OpenAI key
  first, else the shared speech key on their free allowance.
  POST /api/messages/attachments/[id]/transcript serves it.
- A bot or the Cat asked about a message is shown its photos and those of
  the message it replies to, and hears their voice notes. A reply that names
  a bot hands it the quoted message.
- A voice message that opens with a bot's name, or the Cat's, counts as
  naming it. In a one-to-one with a bot or the Cat, voice and photo messages
  are answered.
- The Cat in Messages answers on the asker's own key first, from any saved
  provider, else on their counted free allowance (cat-think.ts).
- The free chain skips models that cannot see when a turn carries a photo,
  and says so when none can.
- The @ menu offers the person's own bots and public bots; picking one
  brings it into the conversation (callBotIds). Someone else's private bot
  is never brought in.
- Bots answering each other: bounded rounds, behind MESSAGES_BOTS_TALK,
  off by default.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsmMXvM981mcszxEA6

* feat(messages): @ offers the conversation's members first, no outsiders

In Messages the @ menu lists who is in the conversation, then the Cat, the
person's own bots and, once something is typed, public bots. People outside
the conversation are no longer offered: naming them there did nothing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsmMXvM981mcszxEA6

* docs(roadmap): media for bots, calling bots in, bots talking (off)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsmMXvM981mcszxEA6

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-15 04:25:02 +01:00
CatoandClaude Opus 5.5 fc59a4a832 feat(share): one look for an article everywhere it is shared (#1778)
* fix(community): a QA run's posts and listings stay off the public shelves

Live after #1736, /community opened with "QA test post from A" by
"QA Grok A", and Discover's first product, "Old Road Bike", was that QA
account's too, its share card reading "by QA Grok A".

- The community feed drops posts whose author's display name is a fixture
  name (NOT_A_FIXTURE_AUTHOR, the People directory's rule on the view's
  actor_data); checked read-only against production.
- 20261113201500 marks the QA account's remaining products, services,
  projects and causes is_test (matched by id and its QA name; nothing
  deleted; rollback in the file).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(timeline): sign every post author through one byline helper

A minted user_<hex> handle was still printed as name and @handle on
/community, in quotes, reposts, the reply placeholder and the post's
share text. postAuthor() (src/utils/byline.ts) is now the one rule:
chosen name, else chosen handle, else the neutral phrase; no @line for
a minted handle; the avatar plate shows a person glyph, not its letter.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(companions): no bot face is orange; check:one-orange covers the pigments

orange and amber are replaced in place by two shared map-scale token
values (indigo, steel), so every other name keeps the face it had. A
stored face URL with hue=orange/amber resolves to its replacement.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(cat): one face for the Cat, used everywhere it is drawn

CatAvatar draws the brand icon tile; CAT_AVATAR_PATH is the same drawing
for slots that only take a URL. Feed, quotes, the answering row, the
mention menu, the profile, follow lists, Messages (list, picker, thread)
and the profile share card all use it. The answering row's AI chip is
neutral like the post header's, not orange.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(not-found): one not-found page for every kind

components/ui/NotFound.tsx is the only 404 design: 'This {kind} isn't
here', one sentence, a search that goes to Discover, the kind's own
shelf and Home. Every public detail route has a not-found.tsx naming
its kind (products, services, events and others fell through to 'Page
Not Found'), wallets no longer have their own layout, and tab titles
come from notFoundTitle() in sentence case with registry names.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* refactor(cat): name the Cat's picture a src, not a path

audit:routes reads a *_PATH string constant as a page link and failed on
the static icon. It is an image source.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(legal): read the operator from one unset constant

LEGAL_OPERATOR (src/config/legal.ts) is null: the legal entity is not
known and is not guessed. While null, /terms and /privacy say what they
said before and stay marked Draft. Once filled in, the opening sentence
and Contact section of both carry the legal name, address and contact.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* style(projects): merge a duplicate import to stay inside the size limit

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(ci): cover the bot-face check in the one-orange gate fixtures

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(cat): one real answer for a visitor, and a pay-link name check

POST /api/cat/first-answer answers a visitor's own sentence before they
have an account, on the visitor budget (general per-IP, then 3 an hour of
its own), for the page's own origin only. Nothing is stored.
GET /api/pay/name says whether a pay-link name is free to claim.
The door helpers carry a typed sentence through sign-up to the Cat.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(faq): say about Cat Credits what the pricing card says

The FAQ offered credits as open while /pricing badged them "Not open
yet". Both sentences are now built in cat-plans.ts from
CAT_CREDITS_ON_SALE. The free plan no longer calls Gemini open-source.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(home): the home page sells the outcome, in one promise

The hero is the promise and one action: claim orangecat.ch/pay/<name>,
with the page that name makes shown as it is typed. Under it, Discover's
own "Just listed" rows instead of the studio grid and the small counts,
then the Cat's door, which answers a visitor's sentence once and invites
them to sign up with the sentence kept (the account screen shows it).

The promise is written once in config/brand.ts and read by the hero, the
titles and descriptions, the share card, the sign-in panel, About and the
footer. /pricing opens on "0% to sell"; the Cat plans follow.
The start action is named for what you get: "Get your page".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(entities): one cover picture for every kind, in every create and edit form

ENTITY_COVER (src/config/entity-cover.ts) names each kind's cover column
once. base-config-factory puts the same picture field under the description
of every form (and into the wizard step that shows the description), the
schemas accept it, creates write it through coverColumn and updates through
coverFieldMapping, which also lets a removed picture clear the column.

Five kinds had no column to keep a picture in (service, cause, asset, loan,
research): one migration adds a nullable cover_image_url to each and makes
public_documents() read every kind's cover first, so Discover and search
show it. Rollback is in the migration.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(discover): the cover is the hero, the card and the share picture; no picture shows the kind's icon

The public page's hero, the Discover and search card, the dashboard card, a
profile's shelves and the share card all read the kind's cover through
entityCoverImages. Without a picture a listing shows its kind's icon on a
token surface (EntityCoverPlaceholder) on every list, replacing three
different letter plates; a bot wears the face its name picks and a person
keeps a round initial.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): home sells the outcome, a picture for every kind, one byline

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(messages): the Cat answers every message in a conversation with only the Cat

A one-to-one with the Cat stayed silent unless the message tagged @cat: only
a tag queued a reply. Alone with it there is nobody else a message could be
for, so a message there is owed an answer without a tag. In company the Cat
still waits to be tagged.

- isAloneWithCat(): one person and the Cat, asked by the write path and by
  the reply.
- The reply is worded for it (nothing was tagged) and carries no
  requested_by: there is nobody else it answered for.
- A message of only files asks nothing.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(messages): New opens on the Cat, your bots, recent people and people you follow

The New message sheet opened on the viewer's own bots only, so for anyone
without a bot it was empty until they typed. It now offers the Cat first, then
their bots, the people of their latest one-to-one conversations and the people
they follow (eight people at most, nobody twice, no unnamed placeholder
accounts). Typing still replaces the list with the search.

- The Cat found by search is shown as an agent, with its own face.
- Alone with the Cat, a sent message shows it writing and looks for its
  answer, as with a bot.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(payments): one payment flow, purchases as orders, services booked first

One flow. Paying a person, supporting a page, investing, buying and paying a
booking now share /pay's words, steps and receipt:
- src/config/payment-flow.ts and pay-words.ts are the one vocabulary (the verb
  and the figure, "Waiting for the payment…", "Change amount", "Paid").
- PaySteps draws the code, the claim, expired and failed once; PayFlow, the
  support card, the purchase dialog, the ticket card and the booking use it.
- Every success is MoneyReceipt (To / For / When). "Tip" becomes "Support".

A purchase is an order. A signed-out buyer was shown the seller's bare address
and typed the price by hand; nothing recorded the sale. Now they give a name
and get a code for the price, minted on the seller's wallet, with an order row
(buyer_id NULL). Orders have a page (/dashboard/orders) for seller and buyer.

A service is booked first. The service page has no purchase; once the provider
accepts, the booking asks for the payment through the same flow, and settlement
marks the booking paid (orders.booking_id). No escrow: the money goes straight
to the provider's wallet.

Who is paid and what is charged are unchanged: resolveSellerWallet and
resolveAmount (the booking's own price_btc for a booking).

Migration 20261114091700: orders.buyer_id nullable, orders.booking_id.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(bookings): a booking's money is server-written, paid once, and never "paid" by the customer's own hand

- Migration 20261114104100: clients lose INSERT and table-wide UPDATE on
  bookings and keep UPDATE on the five columns confirm/reject/complete/cancel
  write; the customer's policy only allows cancelling. createBooking inserts
  through the service role.
- Paying a booking reads the price with the service role and what is paid
  from the booking's paid orders, never from the client-visible row.
- One live invoice: an open request is checked against its rail and handed
  back instead of minting a second; nothing is minted while a claim or an
  on-chain confirmation is pending.
- Settlement recomputes total_paid_btc from the paid orders (no read-then-add).
  A payment landing on a cancelled, declined or no-show booking is recorded on
  the order, not applied to the booking, and both sides are told.
- An unpaid booking can still be paid after it is marked complete.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(payments): a pass is not sold without an account

A Supporter or Loki pass is granted to the buyer's account at settlement; a
guest has none, so the money arrived and nothing was granted. The guest
purchase refuses such products before any invoice, and the page offers
sign-in in place of the guest panel, saying why.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(payments): booked-first holds on the server; a guest buyer is named; a request never made is not a failed payment

- POST /api/payments refuses a service and points to the booking; so does
  /api/v1/payments for a person's session. A key or OIDC caller keeps it:
  Loki pays a builder booked on its own side through a service.
- The seller's email names a buyer without an account instead of looking a
  profile up by a null id; a claimed purchase is "a buyer", not "a supporter".
- An initiation error (no wallet, nothing left to pay) is titled "This could
  not be started", not "This payment did not go through".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): one way to pay, guest orders, booked first, the Cat alone

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(migrations): say why dropping NOT NULL on orders.buyer_id is rollback-safe

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(messages): suggestions read the follow list through the shared reader

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(discover): a person's card never prints a minted handle

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(listings): the seller card never prints a minted handle

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(share): one look for an article everywhere it is shared

The same article looked two ways on the timeline: the publish post was an
ARTICLE card, the post made by "Post on OrangeCat" was its title above a
bare "orangecat.ch/articles/scythia-notes-towa...". Sharing that post to X
sent the post URL, not the article's, with "Cato: “...”" in front of Cato's
own words.

- Links to our own pages unfurl from our own data: /api/unfurl resolves
  articles, posts, profiles, pay links, projects, groups and every entity
  with a public page (sessionless read, each page's public rule) into one
  LinkCard. The publish post and any post linking to the article draw the
  same card; a post that only restates the title shows just the card.
  External links print as host + path, cut at a boundary.
- The share intent no longer types out the title of one of our pages above
  its link (the card shows it).
- Share on a post: an article post (or a post that is only a link to one of
  our pages) shares that page's URL with its title and one line; your own
  post goes out as your words, someone else's quoted and credited.
- /post/<id> of an article post previews as the article (title, dek,
  canonical, /api/og/article card); /api/og/post draws it as an article.
- The article share card carries the dek, the author's face and name, and
  the cover picture beside the words when the article has one.
- Share cards read the image format from the bytes: our storage serves
  avatars as application/octet-stream, which dropped every face from every
  card.
- ShareRow passes `text` through to @bitbaum/bip-kit (used from 0.10.0,
  ignored by the pinned 0.9.1).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): one look for an article everywhere it is shared

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-15 02:23:11 +01:00
CatoandClaude Opus 5.5 6b2a3e3546 fix(calendar): linked calendar reads hold memory flat (still paused) (#1773)
* fix(calendar): pause linked calendar reads again; the app stalled on memory

With reads in a time-limited worker (#1770) the app stalled within 25 min of
the 23:03 start. Cat diagnostics: main thread in state D waiting in
__mem_cgroup_handle_over_high (throttled at the box's memory ceiling),
869 MiB and climbing, 35 outbound HTTPS sockets in CLOSE-WAIT. While reads
were paused (21:42-22:50) every stop was clean.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* fix(calendar): linked calendar reads hold memory flat (one at a time, failures remembered)

Reproduced the 14 Nov stall locally: a 2.5 MB calendar (4,000 weekly
series since 2015) timed out every read, nothing remembered the failure,
and six page views ran six workers at once: 52 -> 430 MB.

- reads run one at a time; at most 8 wait, the rest are told to retry
- a file that failed is not fetched or parsed again for 30 minutes
- one read per file and span at a time; a second view shares it
- the step budget (60k) and time limit (6 s) fit each other; worker heap 64 MB
- the file cache drops expired files and holds at most 24 MB of text
- the fetcher uses no socket pool (agent: false), so nothing is left in CLOSE-WAIT

Load test, same file, six concurrent views x three rounds: every read
complete, memory 86 -> 140 -> 143 -> 144 MB. Reads stay paused here; turning
them back on is a separate one-line change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-15 01:03:36 +01:00
CatoandClaude Opus 5.5 f6241d3230 feat(calendar): link Google, Apple and Outlook calendars, and subscribe to yours (#1760)
* feat(planner): a real calendar: month, week and list views, a microphone, and the Cat adding what you ask

The owner: "The calendar is disastrously bad. There is no real month view.
The week view is bad. There is no way to easily add events with just a
microphone, here or through the chat." Rebuilt.

- Month: seven columns of whole weeks, today ringed, the chosen day filled;
  dots on a phone, the first entries by time and title on a wide screen;
  the chosen day's entries beside or under the grid.
- Week: one column per day (seven wide, three on a phone), hours down the
  side, each entry a block from start to end, side by side where two
  overlap, all-day entries in a row above, a line at the current time. A
  tap on an empty hour adds at that hour.
- List: the next thirty days.
- Microphone: a button always in reach; what is said is read
  (planner/quick-add) and added at once on the day in view unless it names
  one, with Undo. Typing is the Add sheet, which starts from the tapped day
  and hour.
- Chat: "put dentist on Monday at 9 in my calendar" is carried out in code
  before the Cat's model answers (planner/calendar-intent, chat-write), in
  the person's own zone (the chat now sends the browser's), only where
  calendar_add is allowed. The model is told what was added and not to add
  it again.
- GET /api/calendar takes from/to (up to 45 days, past included); each row
  carries its start and end minute for the grid.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* fix(calendar): hour labels in the week view use the 12px scale size

The arbitrary 11px raised the type-scale ratchet and failed CI.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* feat(calendar): link Google, Apple and Outlook calendars, and subscribe to yours

Paste a calendar's private iCal link and its events show in the OrangeCat
calendar (recurrences, moved and cancelled occurrences handled, read-only).
One private webcal/https link puts the OrangeCat calendar into Apple
Calendar, Google Calendar or Outlook. Both live behind a new link button
on the calendar.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* fix(calendar): the feed's all-day dates use whenkit's day-in-zone, not a browser locale

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-14 15:36:06 +01:00
CatoandClaude 56f7d2e62e feat(pay): one payment flow; a purchase is an order; a service is booked first; the Cat answers when alone (#1754)
* fix(community): a QA run's posts and listings stay off the public shelves

Live after #1736, /community opened with "QA test post from A" by
"QA Grok A", and Discover's first product, "Old Road Bike", was that QA
account's too, its share card reading "by QA Grok A".

- The community feed drops posts whose author's display name is a fixture
  name (NOT_A_FIXTURE_AUTHOR, the People directory's rule on the view's
  actor_data); checked read-only against production.
- 20261113201500 marks the QA account's remaining products, services,
  projects and causes is_test (matched by id and its QA name; nothing
  deleted; rollback in the file).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(timeline): sign every post author through one byline helper

A minted user_<hex> handle was still printed as name and @handle on
/community, in quotes, reposts, the reply placeholder and the post's
share text. postAuthor() (src/utils/byline.ts) is now the one rule:
chosen name, else chosen handle, else the neutral phrase; no @line for
a minted handle; the avatar plate shows a person glyph, not its letter.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(companions): no bot face is orange; check:one-orange covers the pigments

orange and amber are replaced in place by two shared map-scale token
values (indigo, steel), so every other name keeps the face it had. A
stored face URL with hue=orange/amber resolves to its replacement.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(cat): one face for the Cat, used everywhere it is drawn

CatAvatar draws the brand icon tile; CAT_AVATAR_PATH is the same drawing
for slots that only take a URL. Feed, quotes, the answering row, the
mention menu, the profile, follow lists, Messages (list, picker, thread)
and the profile share card all use it. The answering row's AI chip is
neutral like the post header's, not orange.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(not-found): one not-found page for every kind

components/ui/NotFound.tsx is the only 404 design: 'This {kind} isn't
here', one sentence, a search that goes to Discover, the kind's own
shelf and Home. Every public detail route has a not-found.tsx naming
its kind (products, services, events and others fell through to 'Page
Not Found'), wallets no longer have their own layout, and tab titles
come from notFoundTitle() in sentence case with registry names.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* refactor(cat): name the Cat's picture a src, not a path

audit:routes reads a *_PATH string constant as a page link and failed on
the static icon. It is an image source.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(legal): read the operator from one unset constant

LEGAL_OPERATOR (src/config/legal.ts) is null: the legal entity is not
known and is not guessed. While null, /terms and /privacy say what they
said before and stay marked Draft. Once filled in, the opening sentence
and Contact section of both carry the legal name, address and contact.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* style(projects): merge a duplicate import to stay inside the size limit

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(ci): cover the bot-face check in the one-orange gate fixtures

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(cat): one real answer for a visitor, and a pay-link name check

POST /api/cat/first-answer answers a visitor's own sentence before they
have an account, on the visitor budget (general per-IP, then 3 an hour of
its own), for the page's own origin only. Nothing is stored.
GET /api/pay/name says whether a pay-link name is free to claim.
The door helpers carry a typed sentence through sign-up to the Cat.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(faq): say about Cat Credits what the pricing card says

The FAQ offered credits as open while /pricing badged them "Not open
yet". Both sentences are now built in cat-plans.ts from
CAT_CREDITS_ON_SALE. The free plan no longer calls Gemini open-source.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(home): the home page sells the outcome, in one promise

The hero is the promise and one action: claim orangecat.ch/pay/<name>,
with the page that name makes shown as it is typed. Under it, Discover's
own "Just listed" rows instead of the studio grid and the small counts,
then the Cat's door, which answers a visitor's sentence once and invites
them to sign up with the sentence kept (the account screen shows it).

The promise is written once in config/brand.ts and read by the hero, the
titles and descriptions, the share card, the sign-in panel, About and the
footer. /pricing opens on "0% to sell"; the Cat plans follow.
The start action is named for what you get: "Get your page".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(entities): one cover picture for every kind, in every create and edit form

ENTITY_COVER (src/config/entity-cover.ts) names each kind's cover column
once. base-config-factory puts the same picture field under the description
of every form (and into the wizard step that shows the description), the
schemas accept it, creates write it through coverColumn and updates through
coverFieldMapping, which also lets a removed picture clear the column.

Five kinds had no column to keep a picture in (service, cause, asset, loan,
research): one migration adds a nullable cover_image_url to each and makes
public_documents() read every kind's cover first, so Discover and search
show it. Rollback is in the migration.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(discover): the cover is the hero, the card and the share picture; no picture shows the kind's icon

The public page's hero, the Discover and search card, the dashboard card, a
profile's shelves and the share card all read the kind's cover through
entityCoverImages. Without a picture a listing shows its kind's icon on a
token surface (EntityCoverPlaceholder) on every list, replacing three
different letter plates; a bot wears the face its name picks and a person
keeps a round initial.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): home sells the outcome, a picture for every kind, one byline

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(messages): the Cat answers every message in a conversation with only the Cat

A one-to-one with the Cat stayed silent unless the message tagged @cat: only
a tag queued a reply. Alone with it there is nobody else a message could be
for, so a message there is owed an answer without a tag. In company the Cat
still waits to be tagged.

- isAloneWithCat(): one person and the Cat, asked by the write path and by
  the reply.
- The reply is worded for it (nothing was tagged) and carries no
  requested_by: there is nobody else it answered for.
- A message of only files asks nothing.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(messages): New opens on the Cat, your bots, recent people and people you follow

The New message sheet opened on the viewer's own bots only, so for anyone
without a bot it was empty until they typed. It now offers the Cat first, then
their bots, the people of their latest one-to-one conversations and the people
they follow (eight people at most, nobody twice, no unnamed placeholder
accounts). Typing still replaces the list with the search.

- The Cat found by search is shown as an agent, with its own face.
- Alone with the Cat, a sent message shows it writing and looks for its
  answer, as with a bot.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(payments): one payment flow, purchases as orders, services booked first

One flow. Paying a person, supporting a page, investing, buying and paying a
booking now share /pay's words, steps and receipt:
- src/config/payment-flow.ts and pay-words.ts are the one vocabulary (the verb
  and the figure, "Waiting for the payment…", "Change amount", "Paid").
- PaySteps draws the code, the claim, expired and failed once; PayFlow, the
  support card, the purchase dialog, the ticket card and the booking use it.
- Every success is MoneyReceipt (To / For / When). "Tip" becomes "Support".

A purchase is an order. A signed-out buyer was shown the seller's bare address
and typed the price by hand; nothing recorded the sale. Now they give a name
and get a code for the price, minted on the seller's wallet, with an order row
(buyer_id NULL). Orders have a page (/dashboard/orders) for seller and buyer.

A service is booked first. The service page has no purchase; once the provider
accepts, the booking asks for the payment through the same flow, and settlement
marks the booking paid (orders.booking_id). No escrow: the money goes straight
to the provider's wallet.

Who is paid and what is charged are unchanged: resolveSellerWallet and
resolveAmount (the booking's own price_btc for a booking).

Migration 20261114091700: orders.buyer_id nullable, orders.booking_id.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(bookings): a booking's money is server-written, paid once, and never "paid" by the customer's own hand

- Migration 20261114104100: clients lose INSERT and table-wide UPDATE on
  bookings and keep UPDATE on the five columns confirm/reject/complete/cancel
  write; the customer's policy only allows cancelling. createBooking inserts
  through the service role.
- Paying a booking reads the price with the service role and what is paid
  from the booking's paid orders, never from the client-visible row.
- One live invoice: an open request is checked against its rail and handed
  back instead of minting a second; nothing is minted while a claim or an
  on-chain confirmation is pending.
- Settlement recomputes total_paid_btc from the paid orders (no read-then-add).
  A payment landing on a cancelled, declined or no-show booking is recorded on
  the order, not applied to the booking, and both sides are told.
- An unpaid booking can still be paid after it is marked complete.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(payments): a pass is not sold without an account

A Supporter or Loki pass is granted to the buyer's account at settlement; a
guest has none, so the money arrived and nothing was granted. The guest
purchase refuses such products before any invoice, and the page offers
sign-in in place of the guest panel, saying why.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(payments): booked-first holds on the server; a guest buyer is named; a request never made is not a failed payment

- POST /api/payments refuses a service and points to the booking; so does
  /api/v1/payments for a person's session. A key or OIDC caller keeps it:
  Loki pays a builder booked on its own side through a service.
- The seller's email names a buyer without an account instead of looking a
  profile up by a null id; a claimed purchase is "a buyer", not "a supporter".
- An initiation error (no wallet, nothing left to pay) is titled "This could
  not be started", not "This payment did not go through".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): one way to pay, guest orders, booked first, the Cat alone

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(migrations): say why dropping NOT NULL on orders.buyer_id is rollback-safe

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(messages): suggestions read the follow list through the shared reader

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(discover): a person's card never prints a minted handle

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-14 12:16:13 +01:00
CatoandClaude ad012dfaf5 feat(home): the home page sells the outcome; a picture for every kind; one byline, one Cat face, one not-found (#1751)
* fix(community): a QA run's posts and listings stay off the public shelves

Live after #1736, /community opened with "QA test post from A" by
"QA Grok A", and Discover's first product, "Old Road Bike", was that QA
account's too, its share card reading "by QA Grok A".

- The community feed drops posts whose author's display name is a fixture
  name (NOT_A_FIXTURE_AUTHOR, the People directory's rule on the view's
  actor_data); checked read-only against production.
- 20261113201500 marks the QA account's remaining products, services,
  projects and causes is_test (matched by id and its QA name; nothing
  deleted; rollback in the file).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(timeline): sign every post author through one byline helper

A minted user_<hex> handle was still printed as name and @handle on
/community, in quotes, reposts, the reply placeholder and the post's
share text. postAuthor() (src/utils/byline.ts) is now the one rule:
chosen name, else chosen handle, else the neutral phrase; no @line for
a minted handle; the avatar plate shows a person glyph, not its letter.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(companions): no bot face is orange; check:one-orange covers the pigments

orange and amber are replaced in place by two shared map-scale token
values (indigo, steel), so every other name keeps the face it had. A
stored face URL with hue=orange/amber resolves to its replacement.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(cat): one face for the Cat, used everywhere it is drawn

CatAvatar draws the brand icon tile; CAT_AVATAR_PATH is the same drawing
for slots that only take a URL. Feed, quotes, the answering row, the
mention menu, the profile, follow lists, Messages (list, picker, thread)
and the profile share card all use it. The answering row's AI chip is
neutral like the post header's, not orange.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(not-found): one not-found page for every kind

components/ui/NotFound.tsx is the only 404 design: 'This {kind} isn't
here', one sentence, a search that goes to Discover, the kind's own
shelf and Home. Every public detail route has a not-found.tsx naming
its kind (products, services, events and others fell through to 'Page
Not Found'), wallets no longer have their own layout, and tab titles
come from notFoundTitle() in sentence case with registry names.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* refactor(cat): name the Cat's picture a src, not a path

audit:routes reads a *_PATH string constant as a page link and failed on
the static icon. It is an image source.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(legal): read the operator from one unset constant

LEGAL_OPERATOR (src/config/legal.ts) is null: the legal entity is not
known and is not guessed. While null, /terms and /privacy say what they
said before and stay marked Draft. Once filled in, the opening sentence
and Contact section of both carry the legal name, address and contact.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* style(projects): merge a duplicate import to stay inside the size limit

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(ci): cover the bot-face check in the one-orange gate fixtures

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(cat): one real answer for a visitor, and a pay-link name check

POST /api/cat/first-answer answers a visitor's own sentence before they
have an account, on the visitor budget (general per-IP, then 3 an hour of
its own), for the page's own origin only. Nothing is stored.
GET /api/pay/name says whether a pay-link name is free to claim.
The door helpers carry a typed sentence through sign-up to the Cat.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(faq): say about Cat Credits what the pricing card says

The FAQ offered credits as open while /pricing badged them "Not open
yet". Both sentences are now built in cat-plans.ts from
CAT_CREDITS_ON_SALE. The free plan no longer calls Gemini open-source.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(home): the home page sells the outcome, in one promise

The hero is the promise and one action: claim orangecat.ch/pay/<name>,
with the page that name makes shown as it is typed. Under it, Discover's
own "Just listed" rows instead of the studio grid and the small counts,
then the Cat's door, which answers a visitor's sentence once and invites
them to sign up with the sentence kept (the account screen shows it).

The promise is written once in config/brand.ts and read by the hero, the
titles and descriptions, the share card, the sign-in panel, About and the
footer. /pricing opens on "0% to sell"; the Cat plans follow.
The start action is named for what you get: "Get your page".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(entities): one cover picture for every kind, in every create and edit form

ENTITY_COVER (src/config/entity-cover.ts) names each kind's cover column
once. base-config-factory puts the same picture field under the description
of every form (and into the wizard step that shows the description), the
schemas accept it, creates write it through coverColumn and updates through
coverFieldMapping, which also lets a removed picture clear the column.

Five kinds had no column to keep a picture in (service, cause, asset, loan,
research): one migration adds a nullable cover_image_url to each and makes
public_documents() read every kind's cover first, so Discover and search
show it. Rollback is in the migration.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(discover): the cover is the hero, the card and the share picture; no picture shows the kind's icon

The public page's hero, the Discover and search card, the dashboard card, a
profile's shelves and the share card all read the kind's cover through
entityCoverImages. Without a picture a listing shows its kind's icon on a
token surface (EntityCoverPlaceholder) on every list, replacing three
different letter plates; a bot wears the face its name picks and a person
keeps a round initial.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): home sells the outcome, a picture for every kind, one byline

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-14 11:38:41 +01:00
CatoandClaude 8e7b275042 feat(messages): the top of Messages says which of your names you are writing as (#1740)
ADR-0015 build order 4 (D5). Somebody who holds more than one identity sees
the one in use above their conversations, the count waiting in the others
and a switch that lands back on Messages. Nobody else sees the row. Nothing
in a conversation links one name to another.


Claude-Session: https://claude.ai/code/session_019MDtmsmMXvM981mcszxEA6

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 21:02:56 +01:00
CatoandClaude Opus 5.5 383a98692f feat(sharing): one share row everywhere, from @bitbaum/bip-kit (#1731)
* feat(sharing): one share row everywhere, from @bitbaum/bip-kit

The share row on wall posts and articles was a local copy of bip-kit's
ShareRow; profiles, projects, entities and blog posts still used an old
wrapping grid of platform tiles. Every share surface now renders
ShareRow from @bitbaum/bip-kit/react (^0.9.1):

- Wall post: "Repost on OrangeCat" opens the repost flow in place
  (crossPost.onClick); signed out it goes to sign-up and back, in the tab.
- Article: "Post on OrangeCat" via /share, in the tab (newTab: false).
- Content that is not public uses audience="restricted": cross-post and
  Copy link only, with the package's note.
- ShareContent (profiles, projects, entities, blog) keeps its panel and
  phone dialog but its body is the same row.

The row is themed with OrangeCat's tokens through the existing --bp-*
mapping in longform.css (adds --bp-on-fg, transparent action fill,
overlay hover, control radius). Removed: the local ShareRow/shareLinks
copies, PostShareRow, sharePlatforms and the sharing BrandIcons. The
share block is recorded in package-plan.json.

Claude-Session: https://claude.ai/code/session_019MDtmvPuHDQeZwXtasWfSx

* test(sharing): hold the bip-kit share row to the share sheet's promises

Main added share-sheet tests against the hand-built sheet (#1722). The sheet is now @bitbaum/bip-kit's ShareRow: its readable primary ink is tested in bip-kit, and its X link carries the title and the URL, so a post always fits. The two close-button tests stand unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvPuHDQeZwXtasWfSx

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 21:01:58 +01:00
CatoandClaude Opus 5.5 8dc855ce77 fix(ux): the full-path review — share cards for everything, bots as makers, honest deletes, money trust, one name, clean feeds (#1736)
* fix(create): money fields are checked when they lose focus

FormField did not hand onBlur to CurrencyInput, so a negative price or
CHF 0.001 got no message until submit. Blur now runs the schema like every
other field, and a fiat amount finer than its currency's cent says it looks
like a Bitcoin amount. The input carries aria-invalid with the error.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(requests): no asking for money without a wallet to receive it

/requests let a person with no wallet send a request; the payer then met
"hasn't added a Bitcoin wallet yet". The screen now runs the same receive
check as payments to them and, without a wallet, shows "Add a wallet to get
paid" with one tap to /receive instead of the form (their lists stay). The
server refuses the same case (requester_cannot_receive) before anyone is
asked or notified. useSellerPaymentMethods no longer answers a new profile
with the previous verdict while it checks.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(timeline): the composer's send button stays on screen on a phone

At 390px, opening the timeline composer or an article's comment box widened
the page to 463px and cut the Post / Comment button off: the action row did
not wrap and the three visibility chips sat in a non-wrapping group.

- The action row wraps; the tools group may shrink (min-w-0), the send group
  cannot (shrink-0, ml-auto), so the button drops to its own line instead.
- The visibility chips move to ComposerVisibilityControl: they wrap, keep
  each label on one line ("Only me" no longer breaks), and reach 44px on
  touch screens.
- A reply (a comment under an article or post) no longer offers a visibility
  choice; it follows the post it answers.
- Tests pin the wrapping structure and the reply case.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(images): a photo-search outage no longer reads as "No images found"

searchOpenverse returned [] for an error status, a timeout and a network
failure alike, so the cover picker told writers "No images found. Try a
different search term" while the service was down. Checked 2026-11-13: the
request is well-formed (page_size=1 answers 200 in 0.1 s, /v1/ and
/v1/audio/ are up), but anonymous image searches with a larger page answer
504 after 8-15 s. The outage is upstream, not in our request.

- searchOpenverse throws ImageSearchUnavailableError when Openverse does not
  answer, and bounds the wait at 10 s; [] now means a real empty result.
- /api/ai/images/suggest returns what any query found; only when none
  answered does it reply 503 with IMAGE_SEARCH_DOWN_MESSAGE.
- The picker's failure state offers "Try again" and "Upload your own".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(community): keep Loki's build updates off the public and newcomer feeds

/community and the dashboard's "From people on OrangeCat" preview were
Loki's CI log ("orangecat: e2e ok — no changes", PR lists, commit hashes),
all posted as external publishes with metadata.source = 'loki'.

- config/external-publish.ts: AUTOMATED_PUBLISH_SOURCES (loki; not ai_app,
  which posts at a person's request), isAutomatedPublish(), and a PostgREST
  .or() filter that excludes them while keeping posts with no source.
- getCommunityFeed applies that filter on the view query.
- The dashboard preview drops other people's automated publishes; the
  viewer's own stay. Everything remains on the project's wall and /timeline.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(ecosystem): a Live now tile never links to a project page that is gone

Loki's studio map pointed Bitbaum at an OrangeCat project nobody can open,
so the first tile on the home page and /ecosystem was a 404.
fetchStudioMapForPublicPage checks every /projects/<id> link in the map
against the projects anonymous RLS lets a visitor read (one query per map),
and drops dead ones so projectHref falls back to the product's own site.
If the check fails, links are dropped rather than trusted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(pay): amount fields open empty, or at a round minimum

The tip dialog opened at CHF 5.77, project support at CHF 5.76 and an
investment at CHF 57.78: BTC round numbers turned into unround francs.
Every amount field now opens empty, as /pay does, with the presets in the
payer's currency. Where terms state a minimum it opens there, rounded up to
a whole unit of the payer's currency (CHF 58), never below the minimum or
above the maximum. An empty contribution button says "Enter an amount".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(investments): render the terms as Markdown

The section a backer reads before sending irreversible money printed
"## The deal" and "- Pre-revenue" as characters. It now goes through the
app's block Markdown renderer (headings, lists, quotes), as chat replies do.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(articles): a minted user_<hex> handle is never printed as a byline

The newest essay on /articles, its page, its article:author and its share
card were all signed `user_df091395b2ca`: the byline fell back to the
auto-generated handle, and the profile editor copies that handle into
`name` when none is given.

- bylineName (src/utils/byline.ts): the profile name, else a handle the
  person chose, else "An OrangeCat member". The byline still links to the
  profile. Every article read (page, list, share card, JSON-LD) goes
  through it.
- Before the first publish, a writer who would be signed anonymously is
  asked "How should your byline read?" in the publish bar. A typed name is
  saved as their profile name; leaving it empty publishes with the neutral
  fallback.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(loans): amounts in the viewer's currency, and a new loan is not a refinance

The loan page printed "$500.00" to a franc viewer with no Bitcoin figure.
Its amounts now go through ViewerAmount: converted through Bitcoin at the
live rate to the viewer's preference, marked "≈", with "Listed as USD 500.00
· ₿…" under the headline so the terms stay visible; without a rate the
stored amount shows as stored. A new request reads "Asking for" with no
"Original" line; "Remaining balance" stays for a refinance. The loan type
label is "New loan" (was "Request New Loan"), and JSON-LD defaults to the
platform currency instead of BTC.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(pay): the code screen shows the BTC and keeps the "For" note

After "Pay CHF 10.00" the Lightning code screen showed only the franc
figure, while the wallet that opens next shows Bitcoin: the BTC amount now
sits under the headline (a BTC reader is not shown it twice; on-chain keeps
"must arrive in full"). A pay link's "For: Coffee" no longer disappears on
the code step: PayFlow renders noteSlot above the code as on the amount step.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(entities): a delete that removes nothing says so; a published event can be taken offline

Deleting a published event returned 200 "Event deleted successfully" and
redirected, while the event stayed live with tickets on sale: RLS only lets an
owner delete a draft event, and the generic delete never checked that a row
was removed.

- createDeleteHandler: refuse with 409 before touching anything when the
  type can only be deleted in some statuses (ENTITY_DELETE_RULES: events as
  drafts, mirroring the RLS policy), and return 409 when the DELETE removes
  zero rows for any entity (`.select('id')` on the delete), with no wallet
  link cleanup and no post-delete hook.
- The owner bar gets Unpublish (or "Cancel event" where draft is not an
  allowed move, e.g. a full event) for a live event; ticket sales stop
  because the ticket functions only open on published/open/full/ongoing.
- Delete on a live event opens a dialog that says it must go offline first
  and offers that move, instead of a Delete that would remove nothing.
- Dashboard delete and bulk delete show the server's reason instead of
  "Please try again", and bulk delete refreshes after a partial failure.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(people): Everyone is filtered before it pages, and its search reaches the server

People -> Everyone read the 100 newest profiles and dropped fixtures after
the range, so the page that reached the browser was a set of nameless
`user_…` accounts, and its search filtered those rows in the browser:
"marco" could never find Marco Rossi.

- onlyPublicPeople (src/domain/people/publicPeopleFilter.ts) applies the
  public directory's rules as query filters before the range: fixture
  handles, exact fixture names, fixture display names, and nameless shells
  (a minted `user_<hex>` handle with no display name). A chosen handle with
  no name stays.
- The fixture display-name rule is one pattern read by both JS and
  PostgREST `imatch`, and now also covers "E2E User" and "… Test … User"
  accounts seen in production's list.
- Everyone's search calls /api/profiles?search= (handle or display name);
  the follow lists still filter in the browser. Checked read-only against
  production: 19 people instead of nameless shells, and "marco" finds
  Marco Rossi.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(notifications): the bell's filters are categories, not one type each

Payments matched only `payment`, so "Someone tried to tip you Bitcoin"
(tip_dead_end) showed under All and vanished under Payments; Social matched
only `follow`, never a mention, a comment or a group invite.

- NOTIFICATION_TYPE_CATEGORY (config/notification-types.ts) files every
  in-app type under payments / social / messages / other; a Record over the
  type list, so a new type is a build error until it has one. Organization
  invites sit under Social.
- GET /api/notifications takes a category as `filter` and selects every type
  in it; a single type still works.
- A live arrival joins the open list only if that filter would have fetched
  it (matchesNotificationFilter, the API's own rule).
- notificationActionLabel: the words a card shows for where it leads (used
  by the next commit).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(notifications): a notification is a button you can Tab to, and says what it opens

The card was a clickable div with no role and no tabindex, so a keyboard
could not open it, and nothing on it said what opening it does. Its icon
buttons were named by `title` only.

- The title and message are a real <button> with a focus ring; its ::after
  covers the card, so a tap anywhere still opens it, and the small actions
  sit above that layer.
- A visible line says where it leads ("Add a wallet" for a tip that found
  no wallet, "Open messages", "See the event"; "Open" otherwise), shown
  only when it leads somewhere.
- Ask the Cat, Mark as read and Delete get aria-labels and focus rings.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(events): the host is told when someone takes a free ticket

A guest took a free ticket and the host's page silently said "1 ticket":
notify.ts told only the ticket holder and the crew. A paid ticket already
reaches the seller as a payment; a free one reached nobody.

- notifyHostTicketTaken (domain/events/notify.ts) sends the host an in-app
  `ticket` notification ("Anna is coming to <event>", linking the event
  page, where the door list is), using the existing type, so no schema
  change. A guest is named by the name they gave, an account by its
  profile name; a host taking their own ticket is not told.
- POST /api/events/[id]/ticket calls it after a free ticket (signed in) and
  after a guest ticket, only once the claim succeeded.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(events): /events lists upcoming public events before a location is given

"What's on near you" showed nothing until a visitor allowed location or
typed a place, so online events never showed and a visitor who did neither
saw an empty section.

- GET /api/events/nearby with no lat and no lng returns every upcoming
  public event (listUpcomingEvents, domain/events/upcoming.ts): the same
  live statuses and test-row filter as search_events_nearby, the same genre
  match, and "over" by eventHasEnded, the rule the ticket functions share.
  Online first, then by date.
- EventsNearYou loads that list on open; Near me or a place narrows it,
  nearest first, with "Show everywhere" to go back. An online event reads
  "Online" where a distance would be; an empty list says nothing is coming
  up and links to hosting one.

Checked read-only against production: today the only public event is past,
so the list is (correctly) empty.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(companions): a public bot can be supported, wears its face, and signs what it makes

- A public companion's page shows the existing support card, "Support <name>",
  paying the wallet its owner chose under "Pay into" through the same
  non-custodial public-support flow other pages use. The registry marks
  ai_assistant supportable with no purchase pattern. Visitors see no card when
  no wallet can be reached; the owner sees how to connect one. Private bots get
  no card, and there is no sticky bar above Talk.
- Creator copy: drop "earn you Bitcoin via Lightning", "portable" and the
  per-message price promise, since no price field exists. Hide the unused
  Compute Provider choice (the column is kept). "Pay into" now says what
  happens to the money. Fix the 95%/5% comment in assistant-charge.
- The bot page shows its face (picture, picked face, or the face its name
  picks) instead of the robot icon, and "Active" only to its owner. The share
  card never carries an SVG face, so generateEntityMetadata falls back to the
  entity card.
- Provenance: a new entity_provenance table (service role only, rollback
  note in the migration). The Cat's executor records the maker of every
  create_<entity type> action: the bot if the action came from one of the
  person's bot conversations, otherwise the Cat. Entity pages show a
  "Made with <bot>" byline that links to a public bot, "Made with Cat" for
  the Cat, or "Made with a bot" for a bot that is private or deleted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(share): every entity and public post gets its own share card

Eight of eleven entity kinds and every wall post shared as the generic
site card or with no image at all (create#2, media#4). A DJ sending his
service page sent an OrangeCat ad.

- /api/og/entity/[type]/[id]: one card for every kind whose page is the
  generic entity page, driven by ENTITY_REGISTRY (kind name, icon). It
  shows the item's own picture (fetched and checked first; WebP, missing
  files and slow hosts fall back to the kind's icon), the title, the
  maker's chosen name (never a minted user_<hex> handle), and one figure:
  price, goal, or date and city. Fiat amounts stay in the maker's
  currency (CHF when none is set). BTC-kept amounts are shown in CHF when
  a rate is available. Amounts raised are never printed.
- /api/og/post/[id]: author and first words of a public post.
- Both read with a sessionless client and the page's own visibility
  rule. A draft, a private, followers-only or inactive item, or an
  unknown type or id gets the plain brand card.
- generateEntityMetadata always points og:image and twitter:image at the
  entity card, with width, height and alt. Post metadata now carries its
  card and uses summary_large_image.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(nav): Discover is a top-level sidebar item, and one word everywhere

Signed in, Discover sat under "More" next to About: two clicks away, and on
/discover nothing in the sidebar lit up because its group was collapsed. It
now sits in the primary section right after Home (the phone drawer's top
level too), named from PUBLIC_PAGES. The signed-in phone tab bar stays at
five slots: Create is the only way to create below the header's sm
breakpoint. The visitor tab bar's "Explore" is now "Discover", like the page.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(dashboard): one skeleton of the real column, no full-screen spinner

/dashboard showed three loading states in a row (a stats-grid skeleton the
page no longer has, a full-screen "Loading your account" spinner, then the
page), CLS 0.378 on a phone. loading.tsx and the page's pre-account state now
draw the same DashboardSkeleton (greeting, door, setup card, a section). The
setup card holds its place while recommendations load when it is expected,
remembered per account on the device, so it neither pushes the column down
for a new account nor leaves a gap for a finished one.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(copy): every kind goes by its registry name — Bot, Organization, Document, Research

The agent kind had five names (Bots, Companions, "AI Assistant Not Found",
"Create a companion", "a being", "My Companions"). ENTITY_REGISTRY.ai_assistant
is now Bot / Bots (ADR-0015, the sidebar, the Talk home) and every visible
label reads it: Discover chip, My Bots, page and 404 titles, Create menu,
form, empty state, Talk home, templates, Cat action, recommendations, and the
API errors a person sees. Type, tables, API path and /companions URLs stay.

Organization, Document and Research get the same treatment: "Start an
organization" (one spelling), the form title and labels, share card, settings
and layout titles read the registry; "Cat Context" / "Create Cat Context" and
"DeSci Research" become Documents / Add a document / Research.

A test pins the names and keeps the retired labels out of src/.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* refactor(pay): one hook holds a chosen amount over its opening

PaymentDialog and PublicSupportPanel both held "what the payer chose, else
the rounded opening"; useChosenAmountBtc keeps that once, and brings
PaymentDialog back under the 300-line component limit.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(nav): the visitor tab bar's Discover slot is called Discover

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(audit): the full-path review — seven areas, seven questions, 123 findings, what this fixes

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(articles): the byline prompt reads the account through useAuth

The byline hook imported the auth store directly, which pulled the real
Supabase client into the article-writing browser fixture (it stubs
useAuth, the composer's seam to the account), so the editor never
mounted. One seam: the hook reads profile and updateProfile from useAuth.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 20:12:07 +01:00
CatoandClaude Opus 5.5 a772acefdf fix(ux): close the UX audit and the UI/UX handoff — Studio drafts in every form, pay, sharing, groups, events (#1722)
* feat(ux): chatkit 0.31.3 and accountkit 0.30.0 — starters in one column, the Appearance row only on phones

- chatkit 0.31.3: the Cat's empty-state starters are one column at every
  width, not a wrapping row of pills (auth-firstrun#5).
- accountkit 0.30.0: the account menu's Appearance row is `shown: 'narrow'`,
  hidden by the package stylesheet from 768px up where the header carries
  its own theme toggle. The useMediaQuery width read, wrong on the server
  render and flashing on load, is gone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(audit): the package fixes are released — starters, the Appearance row and the feedback tab

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(audit): close the audit — triage of the eight findings left partly fixed

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(pay): paying someone on-chain shows their address and the BTC that must arrive, and Copy copies the address

On production, /pay/Penguin (receive-info says on-chain) at 390px, dark and
light, and at 1366px: after choosing CHF 10 the code screen read only
"CHF 9.98 / On-chain Bitcoin · no deadline / Open in wallet / Copy invoice".
No BTC figure and no address anywhere in the text; on a phone the only place
the address exists is the QR, behind a second tap. "Copy invoice" put
`bitcoin:bc1q…?amount=0.00016314&label=Tip+for+Penguin` on the clipboard, which
an exchange's or a bare-address wallet's send field does not take. On-chain
detection needs the full amount to arrive (mempool.ts), so a payer who converts
the CHF headline and rounds down is never seen. (The invoice request was
answered in the browser, so nothing was minted.)

PaymentQRCode, the one code screen behind /pay, the support panel and the
payment dialog, now reads the BIP21 URI with @bitbaum/paykit's settledRail.
When it is on-chain it says "0.00016314 BTC must arrive in full" under the
headline (displayBTC), shows the address in mono under the buttons, and the
button is "Copy address" and copies the bare address. Open in wallet keeps the
whole URI. Lightning is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(notifications): on a phone the item actions show and the words get the full width

Each notification held Ask the Cat, Mark as read and Delete at opacity 0.
Tailwind keeps group-hover behind @media (hover: hover), so a phone never
showed them, yet each was a live 44px target beside the unread dot, and their
140px squeezed the title and message into a narrow column.

The actions now sit on the time's line under the message, so the words use
the card's full width. They are hidden only for a fine pointer, shown on hover
there and while one has keyboard focus. The filter row was already fixed on
main; the test pins both.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(events): an event that is over says so and sells no more tickets

Measured on orangecat.ch on 2026-11-12 (390px, light and dark, signed out
and signed in): the one public event, dated Sunday, September 13, 2026,
still showed "Free entry", a name field and "Get a free ticket", and
nothing on the page said it was over. The ticket box, the sticky "Buy a
ticket" bar and the pay panel decided from status alone, and nothing ever
moves a past event to 'completed'. claim_free_ticket and
claim_guest_ticket checked status alone too, and checkout for a paid
ticket never looked at the date.

- eventHasEnded (src/domain/events/time.ts): over once its end has
  passed (its start when it has none; an all-day event at midnight after
  its last day on the venue's clock), or once marked completed.
- Event page: the ticket box says "This event has ended." and offers no
  free or paid ticket; visitors see an "Ended" badge; no pay panel and no
  sticky "Buy a ticket". A ticket someone holds stays, without "show this
  at the door" or give-it-back. The organizer is told nobody can get a
  ticket instead of being handed the invite link.
- Checkout (initiatePayment, initiateGuestTicketPurchase) refuses an
  ended event before an invoice exists; the payment routes answer "This
  event has ended." instead of a generic failure.
- Migration 20261113163700: public.event_has_ended(event) holds the same
  rule; claim_free_ticket and claim_guest_ticket refuse with P0002. The
  paid issuers are left alone on purpose: they run at settlement, after
  the money has moved. Applied twice to a scratch Postgres 16 after the
  three ticket migrations and exercised as anon, authenticated and
  service_role.

Re-applied on current main; the migration is re-timestamped after the
newest one there.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(assets): a rental's minimum and maximum period read "1 day", not "1 Per Day"

On orangecat.ch, the Availability card of a studio rented by the day read
"Minimum Period 1 Per Day" (390px and 1366px, dark and light). The rows
glued the count to the form select's cadence label, so a two-day maximum
would have read "2 Per Days", and the price row read "/ Per Day".

RENTAL_PERIODS now carries the unit each cadence is counted in (hour, day,
week, month) next to its select label. The asset page counts periods in
that unit ("1 day", "2 days", "3 weeks") and prices "/ day". An unknown
cadence still reads "period".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(pay): the pay button says what it does; invoices say "Payment to"

Measured on orangecat.ch (2026-11-12, iPhone 13 390px, light and dark):
the button beside "Pay from my wallet" read "Show the code" and the
article Tip dialog's "Show tip QR", while a phone is shown Open in wallet
first and the code behind a second tap; /pay said the link and
your-name@orangecat.ch "are the same door", though the address refuses an
on-chain-only wallet; the article Tip button was 34px tall; every payment
from /pay, the Tip dialog and Receive was minted as "Tip for <name>".

Now:
- "Pay with a Bitcoin wallet" / "Tip with a Bitcoin wallet", and
  "Pay/Tip from another wallet" beside "Pay from my wallet". /pay's single
  action keeps main's "Pay CHF 20" / "Enter an amount".
- /pay's first point is "Two ways in".
- TipButton is min-h-11.
- The description is "Payment to <name>", plus ": <note>" when the payment
  answers an open request; a Lightning-address callback gets a comment no
  longer than the provider's commentAllowed.

Already on main, so not repeated here: both actions disabled outside
TIP_MIN/MAX (PayFlow amountReady), and the tertiary-text contrast
(--text-tertiary is now 42% light, 5.3:1 on white).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(pay): your own pay page without a wallet shows where to add one, not a message to yourself

On orangecat.ch (2026-11-12, iPhone 13 390px, dark and light), signed in
as an account with no wallet, /pay/<own handle> showed the payer's dead
end: "<handle> hasn't added a Bitcoin wallet yet, so a payment has nowhere
to land. Nothing was charged." and one link, "Message <handle> to suggest
adding one", whose href was /messages?to=<the viewer's own profile
id>&draft=add-wallet. Nothing led to /receive, where a wallet is added.

PayPageClient now reads the viewer with useAuth(). When the viewer is the
recipient and the page has no way to pay, it shows an owner line ("This is
your pay page. Nobody can pay you here yet. Add a wallet and payments land
in it.") with an "Add a wallet" button to /receive. Every other visitor,
signed in or out, still gets the nudge. The words live in PAY_COPY.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(share): a shared page says its own title, shows an image, and X says the same

The root layout's openGraph/twitter carried the homepage's title,
description and URL, so pages without their own shared as the homepage;
pages that set an openGraph dropped the root card image; descriptions of
entities, profiles, groups, articles and posts went out untrimmed.

- root layout keeps only type/locale/siteName and card; the homepage sets
  its own title, og:url and canonical
- pageMetadata() in src/lib/seo/metadata.ts: canonical, feed link, og and
  twitter in one shape, with the root card unless a page names one and
  descriptions cut by metaDescription(); generateEntityMetadata uses it
- /pay, /pay/<name>, /blog, /steal, /ecosystem, /community use it;
  profile, group, article and post descriptions are trimmed and X uses the
  same title as og:title

Re-applied from claude/orangecat-page-share-metadata (#1649) on current
main; /technology is now a redirect to /docs, so it needs no metadata.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(groups): Discover counts the groups it lists; dashboard shows real member counts

Re-applies the closed #1675 on current main:
- fixture group names live once (FIXTURE_GROUP_NAME_PATTERNS) and travel to
  search_public / public_counts / public_search_text as p_exclude_group_names
  (new migration 20261113160000, rollback note inside), so count, total and
  rows agree;
- browse "Show more" only when rows lie past what the page asked for;
- the dashboard's groups queries drop fixture groups (imatch) and embed
  member_count; GroupCard says "1 member"/"N members", never "0 members".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(profile): the Cat's profile leads to its chat, not a direct message it would not answer

/profiles/cat showed "Message", linked to /messages?to=<the Cat's id>. A
direct message to the Cat's account is answered only when it tags @cat, so an
ordinary question there got no reply and no error. The button now reads
"Talk to Cat" and opens the Cat's own chat, until a one-to-one with a bot
answers every message (ADR-0015 D3).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(design): Bitcoin-orange words clear 4.5:1 in light (text-bitcoin-text)

#f7931a as text measured 2.01-2.30:1 on every light surface and
1.95-2.12:1 on the bitcoinOrange/10 chips, so BTC amounts, "Primary"
chips and Bitcoin labels were unreadable in the light theme.

- globals.css mirrors @bitbaum/design-tokens --bitcoin-orange-text
  (Unreleased, after 1.7.1): #9d5906 in light (4.75-5.43:1 on surfaces,
  4.61-5.01:1 on the orange/10 chip), the true orange in dark (6.14-8.17:1).
- tailwind maps it as `bitcoin-text`, the package preset's name.
- The 15 places that draw orange WORDS switch to text-bitcoin-text;
  icons, fills and borders keep bitcoinOrange.
- check:token-contrast measures the new token on all six surfaces and on
  the orange/10 chip in both themes (142 pairs, was 124), and requires
  .dark to set it.

Positive green already passes (light 145 60% 29%: 4.91-5.61:1; dark
145 55% 50%: 6.36-8.46:1), so it is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(a11y): Discover's focus rings show whole; the unread badge carries no label of its own

Re-applies the part of the closed Discover/badge contrast fix that main
still lacks. The chip counts (no more opacity-60) and the badge's ink
(text-fg-inverted) already shipped with the UX audit.

Measured on orangecat.ch, 2026-11-13: tabbing Discover, every chip and
every rail card had its 4px focus ring cut by the row that scrolls (54
of 54 at 390px, 13 of 13 at 1280px, light and dark); overflow-x: auto
clips overflow-y too, and since the chips now scroll at every width the
first chip lost its left edge from sm as well.

- .oc-discover-chips keeps 4px of padding on every side the ring reaches
  and gives it back in margin (-mb-1 mt-4 py-1, sm:-mx-1 sm:px-1); the
  mouse scrollbar's bottom padding keeps its old net spacing.
- .oc-discover-rail-track keeps 4px above its cards on a phone (-mt-1
  pt-1); from sm it is a grid and clips nothing.
- NotificationBadge drops aria-label: not allowed on a plain span, and
  the bell and tab already say "(3 unread)" in their own names.

With this branch's compiled CSS swapped into production /discover: 0
rings clipped at 390px and 1280px in both themes; the first chip and
first card sit at the same y as before.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(cat): Cat settings checks for local runtimes only when asked

Re-applies the closed fix on current main. LocalRuntimePanel probed
http://localhost:11434 and http://localhost:1234 on mount, so every visit
to Cat settings (every phone included) made two refused connections and
logged two console errors, and a public site reaching for localhost is
what Chrome gates behind a local-network permission prompt.

- Nothing is probed until "Check this computer" is pressed; until then
  each runtime shows its install link and start command. After a check
  the button reads "Check again" and the result line is announced
  (aria-live). The check and Copy buttons are 44px on touch.
- The Cat page already has its h1 on main; it now takes the name from
  CAT_HUB_COPY.title instead of a literal.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(groups): a public group's Events and Activity tabs answer a signed-out visitor

Re-applies the closed #1678 on current main. GET events and activities use
withOptionalAuth (row policies decide what is listed); activities tells a
non-member membersOnly: true without reading the table, and the feed says
"Activity is visible to members", with a Sign in link back to the group
when signed out, instead of "Could not load" or a false "No activity yet".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(share): share cards only say what is true, and X fits one post

- project card draws "Back it in Bitcoin" only when the page's own wallet
  check (resolveSellerReceiveInfo) finds somewhere to receive; on no
  wallet or a failed lookup the line is left off
- profile and group cards use shareLine() instead of .slice(0, 180), so
  bios no longer stop mid-word
- a profile or group name with no row gets brandOnlyCard(), not a branded
  card built from the URL; the group card drops the "/<slug>" pill that
  pointed at a 404 (StatPill had no other user)
- xPostText() builds title + shareLine() + hashtags and drops hashtags,
  then the line, until the post fits 280 next to the link, counting CJK
  and emoji as X does; the X share target uses it

Re-applied from claude/orangecat-share-cards-and-sheet (#1650) on current
main. The sheet's dark-theme contrast and double close button were
already fixed on main (GRADIENTS ink fills carry text-fg-inverted; the
card hides its close inside the Dialog); the sheet test now guards them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(community): the footer's Community feed opens for signed-out visitors

The footer links "Community" from every public page, but signed out
/community showed only "Please sign in / You need to be signed in to view
this page" (orangecat.ch, 390px and 1440px, 2026-11-13). The feed's view,
community_timeline_no_duplicates, holds public posts only
(visibility = 'public') and is granted to anon: the data was public, only
the page refused to read it.

The community feed now loads signed out, and the composer's place shows the
"Sign in to post" prompt that profile and project timelines already use,
extracted into SignInToPost so it is one shape. Its sign-in returns to the
page (/auth?from=/community). The reader's own feeds (timeline, following)
still need a reader.

Re-applied from claude/orangecat-community-feed-signed-out onto current main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(public-copy): say which settings and payments are really public

- /faq ("Who can see my activity?") and /docs ("Visibility control") said
  every entity has a public / followers-only / private setting. Listings
  have "Show on Public Profile"; that three-way choice exists for posts and
  articles. Both pages now show one wording, ENTITY_VISIBILITY_SUMMARY in
  src/config/public-visibility.ts (faq.md takes it as a placeholder).
- /how-it-works and /security said every transaction is publicly
  verifiable on the Bitcoin blockchain. Lightning settles off-chain (the
  privacy policy in legal-content.ts says so). Both now show
  SETTLEMENT_TRANSPARENCY_CLAIM, kept next to FEE_CLAIMS.

The step-mark contrast half of the original branch is already fixed on
main (#1634 moved the steps to oc-icon-tile and a token pill; 7.8:1 in
both themes on orangecat.ch), and /technology is now a redirect to /docs,
so neither is carried over.

Re-applied from claude/orangecat-public-copy-truth onto current main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(groups,circles): no multisig promise; an empty kind says what it is

Re-applies what is still open from the closed #1680 on current main (the
Discover zero state, singular counts and the dashboard create button
already landed in #1716):
- the create panel no longer offers "multi-signature Bitcoin wallets";
  the treasury is the organization's own addresses, shown to its members,
  and multisig stays only as advice; the panel names the kind from
  ENTITY_REGISTRY ("Why organizations?") instead of "Group";
- Discover's empty kind adds the kind's plain verb and definition;
- the circles empty state says what a circle is;
- the dashboard adds its create button to the empty state only while the
  header's Create is hidden, so a screen never shows two.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(ux): Loki on a phone, the model menu inside the panel, Bitcoin icons coloured; bip-kit 0.8.2; record the handoff

- The Loki chip shows on phones as its hammer alone (44px, named "Loki").
- The model menu opened upward hangs from the trigger's right edge.
- Five icons used text-bitcoin-orange, which is no class; they now use
  text-bitcoinOrange.
- @bitbaum/bip-kit ^0.8.2: readable Mermaid labels and a gutter that counts
  from the screen edge.
- The audit records the handoff of 19 closed PRs, item by item.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* docs(changelog): claim only the community feed

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(migrations): one version per migration — the groups count and the timeline view move off 20261113160000

Three files shared 20261113160000, which the Supabase ledger keys on. Both
renamed migrations are safe to run again (a guarded constraint drop / a view
option with its own check), and the deploy ledger keys on filename.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(studio): every form drafts, not only music; visitors can create

On production every Studio form but music failed with "could not finish"
in about 350ms: the prompt shows a score example, so a poem came back with
"score": null and the strict schema discarded the whole draft. The route now
reads a draft the way the Studio means it (readCreativeDraft: a score for
music only, lines joined, the work under its form's name) and tries once
more on an unusable answer.

A visitor's draft no longer ends at a sign-in wall in a new tab: drafts run
on the per-IP budgets (general, then 6 per 10 minutes), the same shape as
dictation, now shared as visitorOrUserBudget.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(studio): the route test mocks the optional sign-in and the visitor budgets

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* refactor(studio): the one retry is a bounded loop, not a repeated expression

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* chore(deps): keep chatkit 0.31.2 and bip-kit 0.6.1 until the rollout gate clears them

The fleet's shared-package rollout gate holds a PR that moves to a package
version not yet proven in its canary product (bitbaum/kivvi), and it held
this one on chatkit 0.31.3 and bip-kit 0.8.2. The Studio, pay, sharing,
groups and event fixes here do not depend on either; the two bumps follow
on their own once the gate clears them. accountkit 0.30.0 is not held.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 17:58:09 +01:00
CatoandClaude Fable 5.2 be275ad6db feat(companions): Talk, several routines per bot, suggestion chips, a group chat's own picture (#1723)
* feat(companions): Talk: a spoken conversation with a bot

A "Talk" button in the header of a bot's chat opens chatkit's VoiceMode:
listen, send, read the answer aloud, listen again. A spoken turn is the same
send as a typed one (useCompanionTalk ask), so it is in the thread with its
cards and steps, and what is read aloud is what the thread shows.

Held back from #1717 until chatkit carried VoiceMode here; main is on
chatkit 0.31.2 since #1718, so it needs no version bump of its own.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* feat(companions): a bot can have several routines

A bot held one routine per person: a morning brief or a site check, never
both. It now holds up to five, each with its own time or interval and its
own question. The details sheet shows one row per routine and a last row
that adds another; Stop takes the one that is open.

The pair (user_id, assistant_id) stops being unique (migration); how many is
the store's rule. The route's answers carry the whole list and, as before,
the first routine, so a page loaded before the deploy still reads it.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* feat(companions): suggestion chips above your own bot's message box

One tap writes the start of the sentence into the box ("Check this site and
tell me what is broken: ") and the person finishes it. A chip is there only
while its ability is switched on for that bot, and a bot still waiting for
its job shows its first question instead.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* feat(companions): a group chat can have a picture of its own

A group wore the faces of its first two members and nothing else. Its
details now have "Change the picture": a shape and a colour, as for a bot,
or back to its members' faces. The client sends the two ids and the server
writes the face; the list, the header and the sheet draw it.

The shape and colour rows are one component now (FacePicker), shared with
the new-bot sheet.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* docs(companions): the parity table, the decision record and the changelog say what a bot can do now

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* refactor(companions): the routine list the details read is built in one service

The route was over its size limit with the list-builder inline. It moves to
services/companions/routines-view.ts, and the own-key pin follows it there.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

* fix(migrations): the routines migration says why lifting the uniqueness rule is safe to deploy

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmwF5V6xdaNTSbg9ouh

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 13:18:10 +01:00
CatoandClaude 8d9f6cc649 feat(posts): public posts readable signed out, with previews and one share row (#1721)
A shared link to a public wall post sent a signed-out reader to sign-in, so
every share died at the door. /post/<id> now renders for anyone the database
lets see the post: it moves out of the auth-gated group, and the middleware
no longer requires a session for it.

- Access: the page reads timeline_events (RLS) with the reader's own session.
  getEventById also stops reading enriched_timeline_events, a view that runs
  with its owner's rights and returned followers-only and private posts to
  anyone holding the id.
- Signed out: the post, its author and thread, and "Join OrangeCat" / "Sign
  in" in the reply box's place, both returning to the post (?from=). A post
  that is not visible says "Sign in to see this post" with the same way back.
- Previews: generateMetadata gives a public post "Author: “first line”", its
  text as description, a canonical URL, og:type article and a Twitter card.
  Any other post gets a title that names nothing and noindex. Articles drop
  their text from metadata when not public, and gain siteName.
- Sharing: one ShareRow (repost here, the device sheet, Copy link, X,
  LinkedIn, Bluesky, Hacker News, WhatsApp, Telegram, email), verbs, one
  sideways-scrolling row, 44px targets, used by wall posts (in a sheet) and
  articles (replacing ShareButton). A non-public post offers Copy link only,
  with a note. shareLinks and ShareRow mirror @bitbaum/bip-kit 0.8.1 and are
  marked to be replaced by it once it is on npm.

Claude-Session: https://claude.ai/code/session_019MDtmvPuHDQeZwXtasWfSx

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 13:02:37 +01:00
CatoandClaude Opus 5.5 03f40fd4e9 feat(ux): the four open audit decisions — visitors can dictate, one name for organizations, /channel stays, a new loan is not asked what it still owes (#1719)
* feat(ux): the four open audit decisions — visitors can dictate, one name for organizations, /channel stays, a new loan is not asked what it still owes

- /api/cat/transcribe takes a visitor's take on a per-IP budget (12 per
  10 minutes, on top of the general limiter) and up to ~4 minutes of audio;
  the door, /raise, /feedback and /studio show the same microphone to
  everyone, and the browser-only fallback is gone.
- The group kind is named from the registry ("Organization") in the
  context switcher, loading screen, list page and join button.
- "Remaining balance" is asked only of a loan being refinanced, as
  "Still owed" (optional); a new loan's is set to the loan amount.
- /channel stays: its waitlist is live.

Audit docs and CHANGELOG record each decision and why.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* refactor(api): the dictation budget in its own module, so the route stays thin

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(groups): the join button says what it joins

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 12:39:36 +01:00
CatoandClaude Opus 5.5 142f21eb1b fix(ux): the rest of the UX/UI audit — sign-up, phone navigation, money, listings, settings, create, public pages (#1716)
* fix(design): the rest of the orange; a gate keeps it to Bitcoin and the sign-up action

The orange was still decoration and words across signed-in screens: Save
buttons in the room, deck and money-route editors, the AI key and onboarding
steps, passkeys, the profile wizard, Create Group, Cat memory import; focus
rings and borders on inputs, hover colour on article titles, drag-over and
selected outlines, AI sparkles and integration icons, the "Your plan" badge.
As text it is 2.0-2.3:1 on light surfaces.

Those in-app buttons are now variant="primary"; orange ink, borders and rings
are ink tokens (text-fg-primary/-secondary, border-fg-primary, ring-ring);
hover on titles underlines. Orange stays on Bitcoin (Pay, Fund, invoice,
ticket payment) and on the public sign-up / sign-in-to-act buttons.

New scripts/check-one-orange.mjs ratchets variant="accent" under
src/app/(authenticated) and (text|border|ring)-accent-warm anywhere in src,
both at a baseline of 0; registered as check:one-orange in package.json and
both verify lists, with a fixture test.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(create): open every create page on the form, templates behind a button

Ten create pages opened on a template gallery with "Start from scratch"
pre-ticked and no Continue, and on a phone that was up to 50 full-height
cards before the first field. The project wizard had a template step of its
own with Previous, Skip and Next (two of them doing the same thing).

Now the form is always first. Where a type has templates, the page header
offers "Start from a template", which opens the picker in a dialog; picking
one fills only the fields not typed into yet and closes it. The picker
shows a check only for a template someone picked, and below sm it is one
bordered list of rows instead of cards. The project wizard loses its
template step.

The create header (single form and wizard alike) is now FormHeader, drawn
by PageHeader: breadcrumb, title, subtitle, owner picker and template
offer as actions. The palette-coloured type icon and the wizard's own
Cancel + h1 row are gone. The wizard's card header that repeated each
step's group heading is gone, and the AI prefill bar shows on the first
wizard step only instead of above every step.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): one name per public page; Product and About split in the header

The header's "Product" menu held the company pages (about, roadmap, docs,
governance) and the top-level "Support" opened the page where people fund
OrangeCat, not where they get help. The header and footer labelled the same
routes independently, so Pricing was "Cat plans" in the footer and Docs was
"Documentation".

PUBLIC_PAGES in src/config/navigation.ts now holds each public page's name
and one-line description, keyed by route, and the header, the visitor menu
and the footer are all built from it. Product = How it works, What you can do,
Discover, Get paid; Pricing and Blog are top level; About = About & mission,
Roadmap, Changelog, Docs, Whitepaper, Governance, Support OrangeCat.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): the search palette finds public pages and stops sending visitors to sign-in

buildPages() indexed only the sidebar and the entity lists, so "Pricing" or
"Docs" found nothing, and a signed-out visitor's default rows (Cat, Home, My
things...) and the Create group all ended at the sign-in form.

The palette now also indexes every public page (PUBLIC_PAGES, with keywords
such as "plans" for Pricing). Signed out, public pages lead, nothing behind
sign-in is offered, the Create group is hidden, and "Search Discover for ..."
replaces "Ask your Cat". The empty line reads "No page or listing matches".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(cat-settings): permission rows speak to the person, and say what is really on

What was wrong:
- Each permission row rendered CatAction.description, which is the tool
  prompt the model reads: other tool ids, NOT/STARTED in capitals, "the user".
- Risk tiles used raw palette classes with no dark value.
- A brand-new account (Connect Wallet and Explain Transaction on by default)
  saw Payments switched on under "Send Bitcoin and fund projects", a bare
  "2/8", and a warning that something high-risk was enabled.
- Presets applied on one tap, replaced every individual choice without
  asking, never showed which one was active, and the fourth was a ghost link.

What it does now:
- src/config/cat-action-summaries.ts holds one plain sentence per action;
  the permissions API sends it instead of the model description. A test
  fails when an action has no summary or a summary reads like a prompt.
- RISK_COLORS use the status tokens.
- Categories read "2 of 8 on"; a partly-on category names what is on and
  starts open. Category names: "My things", "Memory and notes"; Payments is
  "Wallets, bookings and payments".
- The high-risk note names the actions that are on; it is a plain note
  unless an action that spends Bitcoin (send_payment, fund_project) is on.
- Turning on a whole category that would let Cat spend asks first; turning
  anything off never does. What a permission allows is unchanged.
- Presets are one radiogroup of four equal cells (Off, Minimal, Creator,
  Power) marking the active one ("Custom" otherwise); switching asks first
  and confirms with a toast.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(cat-settings): spending caps are entered in the person's own currency

The two caps were raw number inputs labelled '(BTC)' with an eight-decimal
step, so people who see every other amount in CHF had to type a Bitcoin
decimal. They now use the shared AmountField (entry in the display currency,
the BTC figure always shown, value still stored in BTC), labelled 'Most Cat
may pay at once' and 'Most Cat may pay in a day', each with the saved value
under it and a 'No cap' button. 'Save caps' stays the card's one button.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(sharing): the share sheet on a phone has one frame and one close button

On a phone the share card was rendered, with its own border, shadow and X,
inside a dialog that brings its own frame and X: two close buttons, one
inside the other. In the dialog the card now drops its frame and its X, so
the dialog's are the only ones; as a desktop dropdown it keeps both. The
platform grid is four equal cells for the four platforms (a fifth column
sat empty from sm up), and the labels are sentence case: 'Copy link',
'Share profile'. The 'Share via…' ink was already fixed in #1634.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(content): placeholder and duplicate pages lead somewhere real; Builders says it leaves

/pages sent a visitor to the signed-in project dashboard, which only bounced
them to sign-in; it now redirects to Discover. /technology was an unlinked
copy of the Technology Stack section on /docs and now redirects there.
/company/about was a second About page; it redirects to /about, which now
links its one unique door, the ways in (/company/careers).

/channel keeps its waitlist, but Discover People went to the signed-in people
dashboard and Share My Profile opened a share sheet for an empty username for
a visitor. Discover People now opens Discover's people list, sharing shows
only for someone with a profile (as an outline button, not the orange), and
"Bitcoin tipping" reads "Bitcoin payments".

The footer's Builders link pointed at /builders, which only redirects off-site
to bitbaum; it now links there directly, marked external. The e2e route
contract lists the three new redirects.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): the header stays put on desktop and comes back for keyboard focus

useHeaderScroll hid the header on scroll-down at every width, while from lg up
the sidebar is pinned at the header's height, so a hidden header left a 64px
empty band above the sidebar. The header now hides only below lg
(useIsDesktop). Focus that moves into .app-header also clears the hidden
state, so sticky bars pinned below the header move back with it (the CSS
already kept a focused header on screen).

useMediaQuery returns early where window.matchMedia does not exist (jsdom),
so the shell tests that render the header still run.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): the phone drawer's close row is named "Close menu"

The close row at the bottom of the signed-in drawer reused the desktop
"Collapse sidebar" label as its aria-label, so a screen reader announced a
different action than the row shows. It now carries only its visible text,
"Close menu". (The drawer already ends above the tab bar via
.app-sidebar[data-above-mobile-nav].)

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(create): one create list for /create, the phone sheet and the header menu

The three create choosers had three anatomies (a list, a name-only grid,
a flat menu), none of them used the registry's plain copy, and they
grouped by an internal category. The phone's Create tab opened the
name-only grid.

CREATE_OPTIONS now reads each entity's plain.verb and plain.example, keeps
the type name as a small trailing label, and groups by plain.intent under
the intents' own titles. One CreateOptionList renders the rows; /create,
MobileCreateSheet and HeaderCreateButton all use it (the header wraps each
row in a menu item so arrow keys still work). "Need money for something?"
is the first row and "Not sure which one?" the last in all three.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): closing search, notifications or the Cat returns focus to its button

Each overlay is opened from outside state rather than a Radix Dialog.Trigger,
so on close Radix had nothing to focus and keyboard focus fell to the top of
the page.

- palette-store remembers what had focus when the palette opened and gives
  it back once the dialog lets go (unless something else has taken focus or
  the element is gone).
- The header hands the bell to NotificationCenter (returnFocusRef), which
  refocuses it in onCloseAutoFocus, as MobileCreateSheet already does.
- GlobalCatLauncher keeps its button mounted (invisible) while the panel is
  open and wraps the panel in FocusLock with returnFocus; the panel is now
  aria-modal.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(content): links in running text look like links, and the legal pages end with a way to ask

Links inside sentences were styled four ways: the paragraph's own grey with
an underline only on hover (roadmap goal records), grey with an underline
(changelog, roadmap), a bare underline, or an underline in ink (governance).
One class, .oc-text-link in globals.css (ink, underline in border-strong,
darker on hover), now styles every one of them.

/privacy and /terms rendered every paragraph as a plain string, so the
contact address in their Contact sections could not be tapped. Paragraphs
and bullets now go through linkify(), which turns email and web addresses
into links (unit-tested), and both documents close with "A question about
this? Ask the Cat, or write to" the contact address.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(pay): the pay page shows who is paid — face, name and @handle

The pay page named the payee by display name alone; the avatar never
reached it because the recipient lookup did not select avatar_url, and
the face + name + handle block was private to ReceiveCode. A payer could
not tell one "Anna" from another on the page that sends her money.

The block is now PayeeIdentity, drawn by Receive above the code and by
the pay page under its "Pay" eyebrow (the name as the h1, the @handle a
44px link to the public profile). resolveLnurlRecipient selects and
returns avatarUrl on both the current-handle and renamed-handle paths.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(money): pay waits for an amount it can pay, says "Pay CHF 20", and owns the one orange

- An amount outside the limits showed a red line but left the committing
  button live: every action tested only `amount <= 0`. One predicate,
  isAmountInRange (next to the amount field), now gates Pay, "Pay from my
  wallet", "Show the code", Send's Review and Request's Send request.
- The pay page's one action read "Show the code" and sat as a dimmed
  orange slab under a brighter header "Get Started". It now reads "Pay
  CHF 20" once an amount is in range and "Enter an amount" before, is
  accent only when it can act (monochrome disabled otherwise), and
  getRouteChrome().quietHeaderSignup turns the header's sign-up to outline
  on /pay/<username> (not on the /pay landing).
- The amount plate drew the global focus rectangle around its digits. The
  input cancels the ring; the plate carries it at AA strength.
- In BTC entry the four suggestions read "0.0001 B…": the rung now shows
  the number alone, with "0.0001 BTC" as its accessible name.

Also adds ROUTES.DASHBOARD.WALLETS_FOR_SEND, used by the next commit.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(money): one frame on all three tabs; Send leads to the field it needs; Ask works signed out

- Frame: Receive's first run built its own column with a raw h1, Send's
  no-wallet state put its headline in the page title, and all three
  loading states returned a bare spinner, so title and tabs jumped. Every
  state now renders inside MoneyPage with the tab's own title; first run
  and no-wallet use MoneyPrompt (question as an h2, one sentence). Send's
  subtitle is one line at 390px.
- Send with no wallet linked to /dashboard/wallets with no context, in
  protocol words the page never repeated, to a form titled "Get paid in
  Bitcoin" with the connection field under "Other ways to get paid
  (advanced)". It now links to ?for=send, says "connect a Lightning
  wallet with a wallet connection link", and the wallet form opens with
  that field visible and focused under "Connect a wallet to send".
- Wallet form: toggles read "Add an on-chain address or a wallet
  connection" and "Name and details" (no "(optional)"/"(advanced)"); a
  `bare` prop drops the card when /receive hosts it; two actions are two
  equal cells ("Save wallet" / "Not now" on first run).
- Requests: two actions beside the text squeezed the note to "Dinn…";
  Pay and Decline now sit under it as two equal cells. The status line
  lost its stray paragraph margin, and Send request sits in
  MoneyActionBar like Send's button. Both gate on isAmountInRange.
- "Ask" on a way to pay shared on request: signed out, the row says
  asking needs a free account and the button goes to registration with
  `from` set; the conversation opens with an 'ask-payment-details' draft
  instead of an empty composer.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(finances): empty cards lead somewhere; "Add a wallet" opens the wallets page

"Add a wallet" pointed at a hardcoded '/wallets' — the public directory,
where no wallet can be added. It now goes to ROUTES.DASHBOARD.WALLETS.
The "Came in" empty state named its actions as prose; it now has one
link, "Get paid by link" to Receive, and the tax card repeats "Declare
it" where the estimate needs a place. Stacked paragraphs get mb-0, the
section label is the money surface's (text-sm tracking-caps), and the
two totals are MoneyFigures.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(wallets): the wallets page reads like the money tabs it is linked from

- Header: PageHeading instead of an icon and a raw h1; "Receive" is
  outline, a way out rather than the page's action.
- Empty state: "Add a wallet" is the primary action (was outline, Title
  Case), body "Add a Bitcoin wallet so people can pay you.", an arrow
  instead of the external-link glyph on an internal link, and the invalid
  `bg-surface-raised/40/50` class fixed.
- With no wallets the outer card is gone, so the empty state or the add
  form is the only surface.
- Reads ?for=send (from Send's "Connect a wallet") and opens the add form
  on the wallet connection field.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(settings): split Account into named frames, move preferences out, and recognise an account with no email

What was wrong:
- Settings → Account was one card titled "Account & Security" holding
  thirteen sections and three save behaviours, thousands of pixels long.
  Currency and date format shared one "Save preferences" button; the theme
  was three large cards; currency was editable in the profile editor too.
- An account with no email (anonymous) read "the email address associated
  with your account" above an empty field, was offered a password it could
  never sign in with, saw an empty list of ways to sign in, and its profile
  said "Unknown" and "Not verified".

What it does now:
- Account is five frames with one header shape: Sign-in (email, password,
  two-factor, passkeys, ways to sign in, Nostr behind "Connect Nostr"),
  Devices, Identities, Your data, Delete account. Buttons are 44px and none
  is filled among peers; section text is max-w-prose.
- New Settings → Preferences (/settings/preferences, in SETTINGS_SECTIONS):
  currency and date format save on change with the notifications page's
  status line; the theme is a SegmentedControl. The profile editor links to
  it instead of carrying a second currency picker.
- With no email: "Add an email" with the page's one primary button, the
  password form waits until there is an email, the sign-in list says "This
  browser only" with a warning that names the fix, the profile shows
  "None yet" with an "Add an email" link and omits "Email Verified".
- "Memories … managed under Memory" (was "in AI settings").

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(content): the changelog shows each entry's headline and folds older months

Every entry is written "**Lead.** The rest." but the fleet map drops the bold,
so /changelog printed each one as a single grey paragraph: about fifty phone
screens with nothing to scan. Each line now leads with its first sentence as
a heading (ink, semibold) and the rest beneath in secondary ink.

The rail dot was offset by the wrong amount (it landed 19-23px inside the
rail) and was orange as decoration; it now sits on the rail in fg-tertiary.
The per-line bullet used bg-strong, which is not a utility, so it rendered
only as an indent; it is removed and every line shares one left edge.

The newest 30 days stay open; older days are grouped per month in a
<details> ("October 2026, 14 changes"). splitLead and groupChangelog live in
src/lib/development/changelog-view.ts with unit tests.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): a visitor on Discover gets the site's navigation and footer, not Create

On app surfaces (Discover, events, public listings) the header turned the
marketing nav off even for nobody signed in, showed the "+" Create button
without checking auth, the visitor tab bar raised Create as its loudest slot,
and the footer was limited to public surfaces. A visitor had no way to the
rest of the site and every loud control led to the sign-in form.

- Header: the marketing nav and visitor menu show whenever nobody is signed
  in (on app surfaces once auth has settled, so it never flashes for a
  signed-in person); the "+" needs a signed-in user.
- Visitor tab bar: Home, Explore, How it works, Sign in; no raised slot.
- Footer: also on app surfaces for visitors (showsSiteFooter); the tab-bar
  clearance moves from main to below the footer there.
- A signed-out visitor bounced from a create form lands on the register tab
  (signInModeFor in the middleware).

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(funnel): a first-time visitor who taps Start sees the register form

The hero's "Meet your Cat" linked /auth with no mode, and the auth form
defaults to sign-in, so a newcomer was greeted with "Welcome back". Every
other public Start points at a protected path, and the middleware sent
every signed-out visit there to mode=login as well.

The hero now links /auth?mode=register (the header's target). The
middleware picks the form from the browser: no Supabase cookie means this
device has never signed in, so it gets the register form (which offers
"Already have an account?"); a browser with one, an expired session, gets
sign-in. from= is kept as before.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(profile, civic-split): orange only for Bitcoin and top-of-funnel

Profile progress bars used GRADIENTS.progressBitcoin (Bitcoin orange) and
the civic split coloured the locality share and the slider thumbs with the
warm accent, under a comment saying 'nothing chromatic'. They are ink
(bg-fg-primary, accent-fg-primary) now. The settings tab and theme tick
were already fixed in #1634.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(funnel): the studio grid shows products, not every entry in the fleet map

Home: the "Live now" grid listed every live studio project, the three
pillars again included, about 4,100px on a phone. It now shows six
products that are not pillars (homeFleetPreview) and links to
"All N live products" on /ecosystem.

/ecosystem: "Everything built on it" rendered the whole fleet map,
prospects, demos and "next" ideas named by sentence-casing their slug,
some with no description and no link. It now shows live projects in the
studio and client layers that the map describes; the sentence above it
says so. The home selection and the hero's live count drop undescribed
entries too, so the count still matches what is shown.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(funnel): pricing's one warm action is on the free plan

The orange "Add your key" sat on Bring your own key, and the founding
band was an orange-tinted card with an orange icon and an orange button,
so the page had several warm actions and none on the plan that brings a
newcomer in. Free's "Start chatting" is now the accent; every paid or
set-up action is outline; the founding band is a neutral surface with a
primary button. "Available now" badges get a positive dot. The prose said
"two honest ways" over a list of three; it says three. From lg up each
card is a four-row subgrid so name, price, bullets and button line up.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(settings): one shape for on/off rows, named by their words

On/off rows came in five shapes: a bare checkbox with 'On'/'Off' beside it
(notifications), a card around one switch (Cat proactivity, civic split),
and privacy rows labelled 'Website' where on meant hidden. A shared
SettingToggleRow (src/components/ui) now holds them all: name and one line
of detail on the left, the switch on the right, the whole row a 44px label,
the switch named by the visible words and described by the detail. Privacy
rows say the action: 'Hide website', 'Hide phone number'.

Also:
- Civic split: 'Declare my split' is the in-app primary (was the warm
  accent), and while it is disabled a line says what is missing.
- Profile tabs: panels claimed role=tabpanel labelled by tab ids nothing
  had; they are named regions now, matching the nav + aria-current strip.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(create): one filled button per create form, and an equal action pair

The wallet box inside an entity form rendered a full-width filled "Save"
right above "Create Product": two primary buttons, the wider one not the
one that finishes the form. Its heading was derived from the button label
(`submitLabel === 'Save'`), so the label could not change without changing
the heading.

WalletForm now takes `title` (default "Get paid in Bitcoin") and
`submitVariant`. Inside an entity form the box says "Use this wallet" in
an outline button, so the form keeps one filled button. The wallet edit
card titles itself "Edit wallet" instead of "Save Changes".

FormActions lays Create/Cancel and the wizard's Previous/Next out as a
two-column grid of full-width 44px buttons (commit first); Skip is a
full-width ghost button under them.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(tasks): say whose tasks these are and give the empty list a way forward

The visibility leak itself was closed by the RLS migration
20261113120000 (a task is seen by its creator and whoever is asked). The
page still described itself as "Manage and complete team tasks", showed
four zero stat cards on an empty list, and its empty state said "Create
your first task" with no button.

The subtitle now names the scope ("Tasks you made, and tasks someone
asked of you"), the stat cards show only when there are tasks, and the
empty list is the shared EmptyState with a Create Task action, or Clear
filters when filters hide everything.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(funnel): one Cat door with a microphone, and capability cards a thumb can use

The public map's "What do you want to do?" was a hand-rolled text input
with no microphone, while the signed-in door (DashboardIntent) was
chatkit's Composer. TheDoor is now that composer, used on the dashboard,
My things and the public map; DashboardIntent is retired. The transcribe
route needs a session, so a signed-out visitor's microphone is the
browser's recogniser (SIGNED_OUT_VOICE; ChatInput takes a voice prop),
and chatkit says in words when a browser has none.

Capability cards: "Start" was a 36px text link; it is a 44px outline
button. "See yours" was offered to visitors with no account and nothing
to see; it now renders only for a signed-in user. The compact variant is
gone with its only caller.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(forms): tag input keeps its Add button, task actions in order, ink radios

The task form's tag input was flex-1 without min-w-0, so on a phone it
kept its intrinsic width and pushed "Add" out of the row. Task actions
were Cancel then Save, content-width; they are now the create forms'
equal 44px pair with the commit first. Radios and checkboxes in create
forms were 13px browser-blue natives; they are 20px with accent-color
bound to the ink token, on 44px label rows.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(funnel): one way to end a public page; How it works says how; About says who

One action had six names ("Meet your Cat", "Create Free Account", "Get
Started Free", "Get Started", ...) and every page closed differently: a
gradient card, a near-black band, and /what-you-can-do ended on a link
to another product. PublicStartBand is the home band, shared: one
sentence, the warm action CTA_LABELS.primaryAction to the register form.
Home, How it works, What you can do and About end on it; the header's
sign-up button uses the same label and target. CTA_LABELS.createAccount
and the "Get Started Free" literal are gone.

How it works: the title was "Meet Your Cat" with a hardcoded lede; it is
"How it works" with the configured subtitle. Step titles say what the
person does, in sentence case. The compact copy of the capability cards
is one row per intent, each a link into that section of What you can do
(PublicLinkList). Cards that were not links lose their hover styling,
and the "Need more help?" buttons are gone.

What you can do: the on-page index was a second row of wrapping pills
that looked like the example sentences; it is plain text links in one
row that scrolls.

About: it stated values and stopped. "Who builds it" lists the studio
(/company/about, now ROUTES.COMPANY_ABOUT), the MIT source on GitHub
(SOURCE_REPO_URL, also used by the footer), the stack and the contact
address, rows of one anatomy. The identity value's icon is Lock, as on
the home page, not a tree.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(content): the say-it-in-one-box pages take a voice, and /raise's disabled button is not a faded orange

/raise, /feedback and /studio each open on one box to say what you need, and
none had a microphone. Each now shows the shared DictationButton beside the
box for a signed-in person (the transcription endpoint is signed-in only, so
a visitor types, as before); what is said is appended to what is written.

/raise's Price it pill faded to 40% orange while empty; it is now a neutral
raised pill with tertiary ink until there is a sentence, then the orange.
The helper line under the box and the character count on /feedback are in
secondary ink. /feedback's Send is primary (with the one-orange sweep).

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(profile): edit profile opens on the form on a phone, and Save stays in reach

What was wrong (390px):
- A completion checklist printed every missing field above a hand-built
  header, so no field was in the first screen; the bar was Bitcoin orange.
- Save sat at the very end of the form, about 3,800px down, not pinned.
- The form paid for three nested paddings, so four of the eight 'How can
  others help?' options were truncated mid-word.
- The handle was silently written into Name while completion still counted
  Name as missing, and the percentage ignored its declared weights.
- The avatar picker was a round User icon; the profile shows a rounded
  square with the cat mark.

What it does now:
- The page uses EntityListShell ('Edit profile', 'Back to profile').
  Completion moves below the form on phones, closed until wanted
  ('Profile N% complete — see what is missing').
- Cancel / Save profile are two equal 44px cells in a bar that sticks above
  the mobile tab bar and settles in place from lg up.
- The form padding is p-3 on phones; help options wrap to two lines in
  equal-height cells (still two columns).
- Name stays empty until given; completion is weighted.
- The avatar picker is a rounded square with DefaultAvatar and a visible
  'Add photo' button. DefaultAvatar (shared) sets an inline size only when
  'size' is passed, so responsive classes work; every caller passes one.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): hover, open and selected states are visible in light theme; buttons have a pressed state

Every chrome state painted bg-surface-raised on the page surface. In light
theme that is 96% on a 97% page, so hovering a header button, opening a nav
dropdown or moving through the search palette showed nothing; and no button
variant had a pressed state.

States that sit on the page now use the existing surface-overlay token (94%
light, 17% dark): the header rail (HeaderIconButton), header nav and its
dropdowns, the visitor menu, the footer buttons, the search trigger and
palette rows, the tab bar's press, and the sidebar's hover/active constants
and rows. In design-system.ts the ghost, outline and secondary button
variants hover to surface-overlay, and every button and icon-button variant
has an active: state (overlay for ghost/outline/secondary, muted-strong for
primary, accent-warm-hover for accent).

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): the notifications panel shows one state, and its filters fit a phone

A failed first load drew the raw error message above the filter row and "No
notifications found" below it, so the panel said both. The five filters were
a hand-built row of flex-1 pills that ran off a 390px screen.

A failed load with nothing loaded is now one state: "Could not load your
notifications." with an outline "Try again", no filters, no empty state. A
failed refresh keeps the list with a short notice. The filters are the shared
SegmentedControl (44px segments) in one line that scrolls sideways when five
labels do not fit.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(dashboards): every empty list ends in its create action, first

Wishlists, circles and documents said "create your first one" with no way
to do it: their configs had no empty-state action, and each config that
did brought its own button with its own colour class. Bookings said "No
bookings found" and stopped there. On My Projects the "Open Loki" card sat
above an empty list, so on a phone it was the only button on arrival.

- emptyStateWithCreate: the dashboard shell adds `Create <name>` (or the
  page's createButtonLabel) to any entity empty state without its own
  action; the per-config buttons and their GRADIENTS classes are gone. A
  tab's own empty state (Favorites) is left as written.
- EntityDashboardPage renders headerContent after the list while the list
  is empty, above it otherwise.
- Loans (its own page) uses the same empty state, hides the header Create
  while "My loans" is empty so the screen has one Create, gives each tab
  one label at every width, and makes the tabs 44px.
- Bookings: each empty tab says bookings appear when someone books one of
  your services, with "Create a service"; the first tab is "Requests".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(content): the blog's filters are two rows, not a wall of 71 pills; choice-rows sees them

From md up the blog showed every tag and every month as a wrapping pill
(about 71) before the first post. The time filter is now a SegmentedControl
of four ranges (all time, this year, last 6 months, this month) and the
per-month pills are gone; topics are one line that scrolls sideways, limited
to topics two or more posts share (sharedTopics, unit-tested; the selected
one always stays), each pill 44px tall with aria-pressed. Both rows show at
every width, so the phone's "Filter posts" toggle is gone.

The /study-bitcoin level filter is a SegmentedControl; the /studio forms are
an even two-column grid of radio cells.

check:choice-rows only looked for aria-pressed, role="radio" and role="tab",
so none of these counted. It now also catches native radios and buttons that
set a selection (onClick={() => setSelectedX(...)}), with a fixture test.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(discover): public listing pages give every visitor one way forward

What was wrong:
- A priced listing whose owner has no wallet showed a price and stock, then a
  bare "hasn't connected a wallet yet" and no sticky bar on a phone.
- Product and service pages kept price and action below the first phone
  screen; a product had a second, orange "Buy now" beside the pay panel; a
  service's sticky "Book this service" scrolled to the pay panel; fixed-price
  listings appended a full support form under the purchase.
- PriceDisplay appended "/ hr" after the BTC equivalent, so it wrapped away.
- The breadcrumb started at "Home" (the dashboard), which sends a signed-out
  visitor to the sign-in form.
- Descriptions were titled three ways and the raw "active" status was shown
  to buyers.

What it does now:
- The no-wallet card says who cannot be paid and offers "Ask how to pay", a
  message to the owner about the listing through sign-in; the sticky bar
  becomes that action instead of disappearing. One link builder
  (lib/navigation/inquiryHref) serves it and the owner card.
- Price (and stock / the Book button) lead product and service pages via
  renderLead; the extra "Buy now" is gone; the service bar leads to #book;
  the pay bar reads "Buy now · CHF 20.00"; BookEntityButton is primary.
- On fixed-price listings support sits behind "Add extra support".
- PriceDisplay keeps amount and unit together, the equivalent on its own line.
- Breadcrumb takes a root; public listing pages start at Discover.
- "About this <kind>" comes from the registry name; product, service and
  cause show their status to the owner only.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(groups): Join where a visitor lands; the overview is not the owner's settings

What was wrong: a group page offered Join only inside the Members tab, so a
visitor on the Overview tab had no way in; the Overview and sidebar showed
the owner's "Suggested Features", label, visibility and listing flags to
everyone; one tab carried an icon; "1 Members"; and the page had no way back
to the list it came from.

What it does now: GroupJoinButton (one component, used in the header and the
Members tab) offers "Join group" to a signed-in non-member of an open group
and "Sign in to join" (back to the group) when signed out. Suggested
features and the label/visibility/listed rows are owner-only; counts are
singular for one; the Events tab has no icon. The header starts with a
Discover > <groups> breadcrumb (PageHeader and EntityDetailLayout pass a
breadcrumb root through).

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(projects): one way back, no "be the first" when nobody can pay, sign-in links that return

What was wrong: the project page opened with a Back button (which leaves the
site for anyone arriving from a shared link) where every other listing has
a breadcrumb; "Created by" took the global paragraph margin; the summary
rail said "No contributions yet — be the first." on a project with no wallet;
the timeline told a visitor to sign in with nothing to tap; and the project
room, deck and own-profile redirects sent `redirect=`, which /auth never
reads, so people landed on the dashboard.

What it does now: a Discover > Projects breadcrumb; mb-0 on "Created by";
the rail says "Not open for funding yet." when the project is not payable;
the timeline's "Sign in" is a link back to the project; the redirects send
`from=`.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(discover): a kind's page says which kind, never ends in a wall, and links into it work

What was wrong:
- /events was an organiser sales page at the events address (accent "Near
  me", icon-only search, `redirect=` sign-in, an overridden final button).
- Cards without a picture were a big letter on a grey plate half the card's
  height; on a phone two listings fit a screen. Stacked <p>/<h3> kept the
  global margins.
- "QA test…" listings and the "QA Grok A" profile led the live shelf.
- A kind's page was headed "Discover"; "1 products"; an empty kind showed
  nothing; the chosen chip could sit off screen; a failed search call was
  cached for two minutes as an empty shelf.
- /projects and three dashboard buttons sent `?section=`, which Discover
  ignored; category tiles searched display names that match nothing.
- From sm up rails hide cards five to eight, but "See all" only appeared when
  more existed than were fetched.
- The row of kinds wrapped (10 + 3) on desktop.
- Card prices were grey mono text, unlike the detail page.
- /jobs ended with no link or button, its second line below AA contrast.

What it does now:
- /events redirects to Discover's events, with "What's on near you" above
  the grid (outline button, visible "Search" label).
- The media plate is 2:1 with a 48px bordered monogram tile; in the phone
  grid a card is a row with a 96px square face. Card text has mb-0.
- QA title patterns and display names are fixtures (SQL filter and
  isFixtureHit share the list).
- Browse mode heads with the kind under a "Discover" link and titles the
  page "<Kinds> — Discover"; singular counts; "No <kinds> listed yet." with
  "List the first one" and Just listed; the current chip scrolls into view;
  the shelf and browse reads are strict, so a failure reaches the error page.
- `section` is read as `type`; links use ROUTES.DISCOVER_TYPE; each category
  group has a searchTerm.
- DISCOVER_RAIL_VISIBLE = 4 (mirrors the CSS) decides "See all".
- The chip row is one sideways line at every width, thin scrollbar for mice.
- Card prices are a MoneyFigure in the listing's own currency.
- /jobs offers "Start a group" and "See groups".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(create): form copy that does not leak the implementation

The product form asked for "-1 for unlimited" stock and had a second
"Default Currency" select under the Price field's own currency selector.
The project form's hints began "Optional:" and one explained "Currency
selector is included in this field". Investment amounts had
Bitcoin-scale placeholders (1.0, 0.01, 0.5) in fields that default to
francs.

- FieldConfig.emptyValue: a number field shows its sentinel as empty and
  sends it when cleared. Inventory uses it (-1 = unlimited) with the
  placeholder "Unlimited" and "Leave empty if you can always make more."
  The product guidance panel says the same.
- The product's separate currency select is removed; the selector on
  Price sets `currency`.
- Project hints lose "Optional:" and the selector note; the funding goal
  says "Leave empty if there is no target."
- Investment placeholders are 50000 / 500 / 10000.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(create): a failed submit scrolls to and focuses the first field in error

Field errors were set and nothing moved: on a phone form thousands of
pixels long the person stayed at the button, far from the red. Now the
first failing field, in the form's own order and on screen, is scrolled
to the middle and focused, both on a wizard step and on the final submit.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(profile): a new owner's profile shows first steps, not a blank panel

What was wrong:
- Overview always pushed the owner's support card into its list; an element
  is truthy, so the empty state could never render, while the card itself
  rendered nothing until a wallet could receive: a blank panel.
- The offerings block's filled 'Make offerings public' button published an
  empty card; the way to fill it was a text-xs link.
- The owner saw every tab, empty ones too, with zero passed as a badge; Info
  carried a second Edit button and inline editor beside the header's.
- With no banner the banner area kept its full photo height.

What it does now:
- The support card is included only when the wallet can receive. An empty
  owner Overview offers three list rows of one anatomy: add a wallet, add a
  photo and a bio, create your first project.
- With nothing to share, the offerings block shows the empty card with
  'Ask Cat to help me figure this out' as the primary button.
- Owners get the visitor's has-content tab filter (Overview, Timeline and
  Info always stay); a zero is not a badge. Info's duplicate editor is gone;
  editing is the header's 'Edit profile'.
- No banner: h-20 sm:h-24; the default avatar sizes by class.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(content): a blog post reads in the same frame as a community article

A blog post put its header in a 4xl column and its text in bip-kit's
.bp-article, which centres itself at 70ch and adds 1rem of padding on
phones, so the title and the first line of text sat on different left
edges. It now uses the article frame (/articles/[slug]): one 680px column
holds the back link, the header and the body, with the TOC on a rail to the
right on xl; both readers drop .bp-article's extra padding so title, byline
and text share one edge at 390. The community article title takes the
heading face, like the blog's.

The end of a post had two buttons to /blog ("Back to Blog" and "Read More
Articles") on an orange gradient; it now offers the previous and next posts
and one Join button. Dates: the post card printed the raw string and the
post used toLocaleDateString; both go through FormattedDate now.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(chrome): one name per signed-in destination; the avatar menu follows the sidebar

ROUTES.RECEIVE was "Money" in the sidebar and "Receive" in the tab bar; the
tab bar's create slot relabelled itself "Post" on Messages; and the avatar
menu hard-coded "Dashboard", "My projects", "Your page" and "Edit profile"
for places the sidebar calls Home, My things and Profile.

- The tab bar's money slot is "Money", and every slot prints its own name;
  only where Create leads stays contextual.
- The avatar menu is Home, My things, Profile, Settings, taken from the
  sidebar's entries (getAccountMenuPlaces) with their names and icons.
- Its Appearance row is hidden from md up, where the header has its own
  theme toggle.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(auth): one orange button per side, the mode switch under the title, errors under their fields

Sign-in showed two orange buttons, and the first one ("Start instantly")
created a new anonymous account for someone who came back to sign in. The
switch between signing in and creating an account was a 24px text link
below the provider buttons, and every failure, an empty field included,
landed in one banner with a "Try Again" that could only fail the same way.

Now:
- One accent per side. Signing in: only "Sign in"; the no-email way in sits
  at the foot as an outline "Try it without an account". Creating an
  account: only "Start instantly"; "Create account", the emailed-code
  buttons and "Send reset email" are primary. The anonymous button has its
  own loading flag, so the spinner shows on the button that was pressed.
- A SegmentedControl ("Sign in" / "Create account") under the title, kept in
  step with ?mode=; the bottom switch is gone.
- Provider buttons keep their names unless four share the row, take the
  default border, and are labelled only when they are icons alone.
- The form is noValidate: each field says what is wrong under itself
  (authErrors.ts). The banner offers "Try again" only for timeouts and
  server or connection failures; credentials, unconfirmed email, an existing
  account and callback errors do not. Timeout copy is plain; the loader says
  "Opening OrangeCat…" instead of "Welcome back!" to a new account.
- The auth column is bg-surface-page in both themes (it was a 40% raised
  tint in light); the anonymous help line is text-fg-secondary.
- Password and anonymous sign-in decide where to land through one rule
  (lib/auth/landing.ts): an own-origin `from`, else the Cat welcome for a new
  account and the dashboard for a returning one.

Findings auth-firstrun #0, #1 (client half), #4, #7 (auth half), #8, #9, #10.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(auth): every way in lands on the same first screen

A new person's first screen depended on which button they used: password
and anonymous sign-in went to /dashboard, Google/GitHub and the email
confirmation to the Cat welcome, and "/" sent anyone not yet onboarded to
the onboarding form, on every visit, logo included. The callback and the
confirmation also greeted a returning person as new, because "new" was read
from the URL.

Now the Google/GitHub callback and the email confirmation decide through
the same rule as the sign-in form (landingForSession → landingAfterSignIn):
an own-origin `next`, else the Cat welcome for an anonymous or not-yet-
onboarded account and the dashboard for a returning one. "/" sends a
not-yet-onboarded person to the Cat welcome; the onboarding form is linked
from there (next commit), not forced.

Finding auth-firstrun #1.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(auth): password recovery in the sign-in page's own frame

The three recovery screens each had their own frame: a Card with an icon
tile, Title Case headings ("Enter Your Reset Code", "Reset Link Invalid",
"Password Updated Successfully"), buttons at a different height from /auth,
an unpadded "Back to Login" next to the sign-in page's "Sign in", and the
tab title "Account".

Now every step uses the same AuthTitle block and centred column as /auth
(AuthStepPage): no card, no icon tile, sentence case ("Enter your reset
code", "Choose a new password", "Password updated"), 48px fields and
buttons, "Send a new reset email", and one 44px "Back to sign in" link
(BackToSignIn). The reset page has its own title, "Reset password". The
MFA step says "Back to sign in" as well.

Finding auth-firstrun #13 (the field labels were already added by #1656).

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(onboarding): a full-width description field, whole examples, no orange on in-app actions

The onboarding description field was 241px wide in a 462px column:
Textarea wraps itself in a block div, which sat in a flex row without
flex-1 and shrink-wrapped to the browser's default 20 columns. The examples
were six wrapping pills clamped to two lines, under a grey "Examples" label
below AA. The main button was the warm accent, disabled orange on arrival,
and so were each offer's button, the pay step's retry and "Create" on My
things.

Now the field's wrapper is `min-w-0 flex-1`; three examples show as whole
sentences, one full-width 44px row each, under a text-fg-secondary label.
In-app actions are primary: "See what Cat suggests", the pay retry, "Create"
on My things (the shared Button), and the first offer (the others are
outline, one primary per screen). A unit test keeps `variant="accent"` and
the solid accent fill out of the signed-in pages and onboarding.

Findings auth-firstrun #2 and #7.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(dashboard): first-run copy and a setup checklist with one row per destination

The first dashboard spoke to someone who already had things: "No pending
Cat approvals." under the greeting, a feed titled "Recent activity" that was
mostly other people's, and a filled "Share" inviting friends to a profile
still called "User". The setup checklist showed three rows that opened the
same profile form, sorted the Cat's "Set me up" row last (out of the two
shown), drew a border per row inside its card, and its row titles, as bare
h4s, outranked the card's own title.

Now:
- The status line says nothing to a named account with nothing waiting; to
  a person not yet named it says "Say what you want to do. Your Cat drafts
  it and asks before anything goes live."
- The feed is titled "From people on OrangeCat".
- The invite card is hidden while the name is a placeholder, and its Share
  is outline.
- "Let your Cat set you up" leads the high rows; bio and photo are one row,
  "Add a bio and a photo" → "Edit profile", held back while the name row
  (same form) shows. Titles and labels are sentence case.
- Rows are a divide-y list, titles text-sm.

The percentage the finding also named was already replaced by a count
(#1653). Findings auth-firstrun #3 and #6.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(cat): a new person is offered the door's own sentences, and told what to say

The Cat's first-run starters were built from entity-registry nouns ("Help me
create my first product"), and the dashboard door showed no examples at all,
so a new person met a greeting, an empty box and the names of tables.

Now getStarterChips() returns the first three DOOR_EXAMPLES, the same
sentences the "What do you want to do?" box offers; the dashboard door shows
them while the person has no projects or drafts; and the Cat's welcome adds
one line under its title ("Say it in a sentence. Cat drafts it and asks
before anything goes live.") and a 44px link to the "who are you" form,
which "/" no longer forces on anyone.

Finding auth-firstrun #5. Not done here: the starter list's wrapping layout
lives in @bitbaum/chatkit (.ck-starters-list) and needs a package release.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(what-you-can-do): keep the app shell and the app's door for a signed-in person

"What you can do" is in the app's navigation, but its route is public, so a
signed-in person who opened it lost the sidebar and the tab bar, and met the
native signed-out door with no microphone. Its section pills were 30px tall
in a wrapping box.

Now getShellSurface(pathname, signedIn) (src/config/routes.ts) treats that
page as 'app' for a signed-in person; AppShell and MobileBottomNav read it.
The page's door is DashboardIntent (chatkit composer, dictation) when signed
in and TheDoor's no-JavaScript GET form otherwise (WhatYouCanDoDoor). The
section links are 44px and one row that scrolls sideways.

Finding auth-firstrun #12. The shared DoorExamples component and 44px chips
had already landed. Not done: a microphone on the signed-out door, since
transcription is behind sign-in.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(app-shell): sidebar drawer, collapsed rail and one name per place

The phone drawer stayed open after picking a destination (AppShell never
passed onNavigate) and was saved to localStorage, so it reopened over the
page after every reload. It now closes on navigation and on any path
change, and is never persisted; a value written by an older build is
cleared on load. Only the desktop collapse is a saved preference.

Visiting the Cat wrote "collapsed" into that saved preference, so one
visit collapsed the sidebar everywhere and hid the People, Work and More
groups. A focus route now shows the rail collapsed without writing
anything (expanding there lasts until the next page), and a collapsed
rail that hides groups ends with a "More" button that expands it.

Navigation vocabulary: Profile, Settings and Help leave the sidebar for
the account menu (config/navigation accountNavItems, also read by the
palette so "setings" still finds Settings); the account menu drops
Dashboard and My projects, which the sidebar calls Home and My things.
The sidebar regroups as People (People, Timeline, Community, Collaborate,
Set up for someone), Money and work (Finances, Deals, Civic split, Tasks,
Bookings, Analytics) and More (Bots, Discover, About); Deals no longer
wears Collaborate's handshake, Explore is named Discover after its page,
and each row is one line without the description under it.

Active state: a nav item can own other paths (activeFor). Money is lit on
Receive, Send and Requests in the sidebar and the tab bar, whose slot is
now called Money too; My things is lit on every type's own list.

Signed in, the logo leads to the dashboard rather than "/", which only
redirects a member to the Cat. The context switcher's chevron and menu
rows are 44px; the search shortcut hint uses secondary text.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(app-shell): one Create, in plain verbs, on every page

The header's plus and the phone's sheet listed seventeen entity nouns
("Product", "Organization") while the command palette said the same
things in plain verbs. Create options now take the registry's plain copy
(verb and one line); the noun stays as `kind`, which the Cat's editor
links match on. Both surfaces draw one row shape (CreateOptionRow: icon
tile, verb, one line, 44px), grouped under the existing category labels,
and both end with the link to "What you can do". The sheet is no longer
a grid of bare nouns.

The tab bar's plus changed its name and behaviour from page to page: it
read "Product" on the store and jumped to a form, and on Messages it
opened the public post composer. It is now always "Create" and always
opens the sheet; the page's own kind (a group, on Groups) is the first,
highlighted row inside it. contextual-create now only answers which kind
a page is about, matching a base path and its sub-paths, not a prefix.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(manage): one header frame and one name per type on create and list pages

Project Analytics hand-built its breadcrumb and a smaller title in all
three of its states; it now renders through EntityListShell (PageHeader),
with the time range as a SegmentedControl and a 44px project select in
the header actions. My Companions now says what a companion is ("Beings
with their own voice that remember whoever talks to them") instead of
"Build and monetize autonomous AI services".

The organisation form took the name "Group" while the chooser and the
registry say "Organization"; it now reads the registry's name and plain
description, and the organisations list (GroupsDashboard) says the same
word, with its in-app Create as the primary button instead of the orange
accent. The loan form is "Create Loan", not "Create Loan Listing".

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(dashboard): first run leads with the door, not a checklist

A new account's dashboard opened on "No pending Cat approvals." and two
profile chores in Title Case, with an empty "Your projects" box that
singled out one of the many kinds. Now:

- with no projects, the door shows its examples (as My things does) and
  the line under the greeting explains it: "Say what you want to do. Your
  Cat drafts it and asks before anything goes out." With nothing waiting
  and something owned, the line is simply absent;
- the empty "Your projects" section is gone; the door covers starting one;
- "Let your Cat set you up" leads the recommended tasks (a `leads` flag
  sorted ahead of priority), so the visible pair is not two chores;
- every task title is sentence case.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(app-shell): social surfaces share one frame, one primary, honest states

Feeds: "Home", "My Timeline" and "Community" were three pages showing the
same feed under different names, and /home was linked from nowhere.
Signed in, each now carries one pick-one row (All · Following · Everyone,
the shared SegmentedControl) under one title, "Timeline"; each view keeps
its own address. An empty Following feed says "Nobody you follow has
posted yet." with one primary "Find people". The Timeline header's second
"Share Update" is gone; the composer is the first thing on the page.

One primary per screen, never orange inside the app:
- My things and Collaborate use the shared PageHeader with a primary
  action, in the dashboard's single column (Collaborate's title had its
  own size, typeface and an icon);
- Groups' header action is primary and appears only once the list has
  something; the empty state owns the one button;
- Messages keeps the header's New as its one primary: the list's "Start
  New Conversation" became a line, the empty pane's two buttons are
  outline and say "New";
- People keeps "Discover people" in the header only.
- A search match is underlined in ink, not the warm accent.

People at 390px: the invite card is two equal cells, Copy link and Share
(the third button ran "Copy Link" off the screen), and the three tabs are
the shared SegmentedControl, the count under it. A failed load now reads
"People could not be loaded." with Try again (fetchFollowListOrNull tells
a failure from an empty list) instead of "No connections yet".

Notifications: the five filters are five equal 44px cells that fit a
phone, and a failed load shows only the error and Retry, not the error
over "No notifications found". Discover's shelf with nothing in it says
nothing could be loaded, with Try again, instead of "That's everything".

PageHeading's page size now matches .oc-page-title (no md:text-4xl), so a
signed-in page's name is one size everywhere. The feed's end line and
Collaborate's helper text use secondary text, not the tertiary token.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(create): match the phone sheet's Article and Post rows by their start

The rows now carry a one-line description, so their accessible names are
"Article…" and "Post…" rather than the bare word.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* refactor: six components back under the 300-line limit

Merging the audit fixes pushed six components a few lines over the component
size limit. Each now moves one cohesive piece into a sibling file (task header
actions, the select and choice fields, the signed-out purchase card, two send
states, the share platform list, the wallet goal block). No behaviour, markup
or copy changes.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(nav): the account menu test names the places it now holds

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(discover, a11y): a failed count no longer takes Discover down; two controls named and sized

- Discover's chip counts are read strictly so a failure is not cached as
  zero, then caught: the page draws without numbers instead of falling to the
  error page. The listings themselves still go to the error page with Try
  again. Test: view-counts-degrade.test.ts.
- The currency picker beside a price has an accessible name (axe
  select-name on the create form).
- The xpub help toggle on Wallets is a 44px target (it was 16px tall).
- Docs: the audit gains the fourth batch, every finding's status, and the
  remaining work; CHANGELOG has 2026-11-13.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(create, cat): keep the product form's fixes after merging main; summaries for the two new Cat actions

Main brought the product form's separate currency field back on purpose (so
Fill with AI can set a price in BTC); it stays, and the test that asked for
one currency control is dropped. The inventory field still shows unlimited as
empty, and the hints no longer explain the implementation.

walk_site and use_browser arrived on main without the plain-language summary
the permissions page now shows for every action.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(search): palette tests fit main's palette

- The visitor check skips pages the public footer also links (Community).
- "Settings is found from the palette" asks as a signed-in person.
- The store-focus test of the replaced palette store is dropped; main's
  command-palette-keyboard test covers returning focus.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(create): spell out the hint checks instead of a mis-anchored regex

CodeQL (js/regex/missing-regexp-anchor): in /^Optional:|-1|selector is
included/ the ^ anchors only the first alternative. The test meant exactly
that, but three explicit checks say it without the ambiguity.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(auth): a protected page asks a signed-out visitor to sign in; only the Cat and create forms start on sign-up

The merged rule sent any browser without a session cookie to the sign-up
form, so /dashboard, /settings or /messages opened on a new device showed
"Create account" to a returning person, and the route contract
(tests/e2e/route-contract.spec.ts) failed on all five protected pages.

Sign-up is now the default only where a newcomer is the likely visitor: a
create form, and the Cat (where the public "What do you want to do?" box
sends its sentence) when this browser has never held a session. Everything
else asks to sign in. A middleware test pins the five-page case.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* test(e2e): sign in through the form's own button, not the Sign in / Create account switch

The sign-in page now has a segmented switch whose first option is also
named "Sign in", so a role lookup for that button matched the switch and
the form was never submitted.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 11:28:01 +01:00
CatoandClaude 2e3e9346ba fix(create): number fields say what to fix, template-only pages start unticked, button icons keep their size (#1712)
Measured on orangecat.ch (2026-11-12, 390px):
- On blur, number fields showed zod's developer text: Inventory Count "Too
  small: expected number to be >=-1", Interest Rate 150 "Too big: expected
  number to be <=100", Minimum Rental Period 1.5 "Invalid input: expected
  int, received number". The same held for estimated value, maximum rental
  period and service duration.
- Store, services, events, wishlists, loans and assets create pages opened
  with "Start from scratch" already ticked and no Continue button. The card
  that looked chosen was the only way on (assets has 47 cards).
- The loan form's Add Asset / Add Wallet icons were squeezed to 4.19px and
  0.84px wide in their flex-1 buttons.

Now:
- base.ts has positiveNumber(), wholeNumber({ min, max }) and percentage(),
  each with a plain message ("Must be more than 0", "Use a whole number",
  "Must be 100 or less"). The rules above use them. Inventory says "Use a
  number of items, or -1 for unlimited". This is per rule, not a global zod
  error map, so API validation messages elsewhere are unchanged.
- WizardTemplatePicker takes preselectScratch (default true, as the wizard
  with Next wants). The template-only view passes false and says "Pick a
  starting point to continue."
- The shared Button base has [&_svg]:shrink-0. The two collateral icons drop
  their redundant mr-2 (the base already has gap-2).

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 09:58:15 +01:00
CatoandClaude f45342b35c fix(projects): a funding goal can be 0.5 BTC or CHF 2500.50, not only a whole number (#1676)
* style(tests): format the legacy project-validation test, no change in what it checks

The file predates lint-staged and was never formatted. The next commit
changes one of its tests; formatting it here keeps that diff readable.
Prettier only: semicolons, trailing commas and line wraps.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

* fix(projects): a funding goal can be 0.5 BTC or CHF 2500.50, not only a whole number

On orangecat.ch (iPhone 13, dark and light) the project wizard's Funding
step answered "Funding goal must be a whole number" to 0.5 BTC, to
10000 CHF switched to BTC (0.16498655 BTC), and to CHF 2500.50. Measured
with Next only; no request was sent. The same schema guards
POST /api/projects and PUT /api/projects/[id], so the API refused them
too, and anyone whose currency is BTC could not set a realistic goal.

The cause was a sats-era .int() on goal_amount, the same leftover the
wishlist schema already dropped. It is gone; the goal stays positive and
is capped at 1,000,000,000 like the wallet goal. The column
projects.goal_amount is numeric(20,8) (baseline, never altered), so no
migration is needed.

Two places followed the old rule: the raise flow dropped a BTC goal
(a project goal "cannot be" below 1) and now keeps it, and the MCP
create-project tool told agents the goal is a whole number. A legacy
test that expected Number.MAX_SAFE_INTEGER to pass now expects the cap's
message: that number would have overflowed the column.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 08:36:01 +01:00
CatoandClaude 52b83dbef3 fix(cat): the chat says only what is true; Loki templates wait to be finished, credits are offered only when on sale (#1704)
Measured on orangecat.ch (2026-11-12, 390px):
- The Loki sheet's "Send one task to several projects" sent "Send this to my
  Loki projects orangecat and loki: " at once, with nothing after the colon.
  It spent one of the day's free messages and named two projects the person
  does not own. It did the same on an account not linked to Loki.
- The model menu said "Add credits or connect a key to unlock" under 11 locked
  models, while Cat settings show credits as "Not open yet" with top-up
  switched off.
- On Edit Profile, the Cat's footnote read "Looking at your profile editor
  (offer to fill it in with update_profile)". The label reaches only the
  reader, never the model.
- The empty Cat Credits ledger read "Once top-up is live to run Cat on frontier
  models; purchases and usage will show here."

Now:
- askCat takes `send: false`, and the panel then fills chatkit's box
  (ChatAppHandle.fill) instead of sending. The Loki examples fill the box for
  the person to finish, the first one names no projects, and an unlinked
  account is offered only "Connect Loki".
- CAT_CREDITS_ON_SALE (cat-plans) names "credits can be bought". The plan
  cards and the model menu read it. Until it is true, the menu says
  "Connect your own key to unlock" and a locked model "needs your own API key".
- The footnote label is "your profile editor".
- The ledger's empty state is a whole sentence either way.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 08:04:18 +01:00
CatoandClaude 6ce2f2d1fd fix(settings): Export my data holds what it promises, and settings copy says what the product does (#1703)
Measured on orangecat.ch (2026-11-12):
- "Export my data" promised "the data we store about you". GET
  /api/account/export returned ten tables (profile, Cat history, credits,
  preferences, sent messages) and nothing the person made: no pages,
  wallets, posts, follows, memberships, payments or notifications.
- "Delete all Cat conversations" sent people to "AI settings" for memories.
  Memories live on the Memory tab, and /settings/ai has no memory controls.
- The public contact email said "Defaults to your registration email". Since
  #1589 it is never pre-filled.
- Integrations told developers to verify webhooks with @orangecat/sdk, which
  is not published (npm answers 404).

Now:
- The export is gathered in src/domain/account/exportAccount.ts. It adds every
  page the person owns, found through ENTITY_REGISTRY by each type's owner
  column, so a new type is exported without touching it. Wallets are read
  through WALLET_CLIENT_COLUMNS, without the connection secret. It also adds
  posts (under the user id or an actor), follows both ways, group memberships,
  payment requests and orders where the person is a party, notifications and
  Cat interest topics. Embedding vectors stay out. A failed read still fails
  the whole export rather than handing over a partial file. The route is a
  thin wrapper.
- The export copy names what the file holds and what it leaves out.
- The memories sentence links to the Memory tab.
- The contact email help says it stays empty unless filled in and that the
  sign-in email is never shown. The guidance tip claiming a default is gone.
- Integrations states the signing scheme (X-OrangeCat-Signature, HMAC-SHA-256
  of `${t}.${raw body}`, five-minute tolerance), and the API conventions doc
  says the SDK is not published.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 07:49:00 +01:00
CatoandClaude 3808aad2ea fix(settings): a "Start instantly" account is told it has no way back in, and sign-out asks first (#1702)
On production (2026-11-12, 390px, light and dark) an anonymous account
(is_anonymous, no email, no identities) saw on /settings: an empty bordered
"Ways to sign in" list (0 items, 2px tall) under "Only one way in. If you
lose it, only support can get you back"; an Email Address section describing
"the email address associated with your account" over an empty field; and a
"Sign out all devices" button that signs out globally on one tap with no
confirmation, which leaves such an account with no way to sign in again.

Now:
- Ways to sign in draws no empty list. With no way in at all it says so
  ("No way back in yet. This account lives only in this browser ...") and
  offers "Add an email", which moves to the email field; Link Google/GitHub
  stay. The one-way-in warning shows only for exactly one, and neither shows
  when the list could not be read.
- Email Address asks such an account to add one, and the submit says
  "Add an email". The success toast promises a confirmation email only when
  the address is actually pending one.
- Sign out everywhere warns in place, offers "Add an email" beside the button,
  and puts the sign-out behind the shared ConfirmDialog. Accounts with a way
  in sign out at once, as before.
- The copy lives once, in NO_WAY_IN (src/lib/auth/sign-in-methods.ts).

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 07:32:54 +01:00
CatoandClaude d6b68f94d8 fix(loans): Contact lister messages the lister, and a cancelled loan stops being public (#1701)
Measured on orangecat.ch at 390px (2026-11-12):
- Signed in, /loans/c0a19931… showed "Contact Lister: Sign in to contact
  the loan lister or make an offer" and a sticky "Contact lister" bar. Both
  linked to /auth?mode=login&from=/loans/c0a19931…, and following the link
  as a signed-in visitor landed back on the same loan. Nothing on the page
  made an offer.
- /loans/e16ab177… and /loans/73edf4dd… (cancelled, is_public) answered 200
  to a stranger with a Cancelled badge. All three loans were in sitemap.xml,
  while search and Discover show only the active one.

What changed:
- renderSidebarExtra and mobileStickyCTA now receive who is looking
  (isOwner, isSignedIn) and contactHref. contactHref is the message link
  that the owner card's "Ask … about this" uses, built by one helper
  (inquiryHref). On a loan, Contact Lister and the phone's bar open that
  message. Signed out, they go through sign-in and on into the message. The
  owner sees neither. The card no longer promises an offer.
- A visibility filter can now be a list of rules, all of which must hold.
  A loan is public when is_public AND status is active, the same rule
  search uses. The page, its metadata, the sitemap and the capital lend
  rail all read PUBLIC_VISIBILITY.loan. The owner still previews a
  cancelled loan through the existing owner fallback.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 07:21:40 +01:00
CatoandClaude Fable 5.2 24820f09e2 feat(companions): walk_site and use_browser: a QA walk, and a browser of its own for every bot, through Loki (#1697)
* fix(migrations): the vendor daily cap takes its own version, 20261112202000

#1672 and the members-only groups migration landed on main with the same
version, 20261112200000. schema_migrations.version is a primary key, so
check:migration-versions and Migration Replay failed on main and the deploy
did not run. The cap's migration had not been applied anywhere (its deploy was
the one that stopped), so it takes an unused version; nothing else changes.

Unit suite locally: 718 files, 5841 tests passed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi

* feat(companions): walk_site, a QA hand that opens a live site in Loki's browser and says what is wrong

Cat Bot's first missing row against Grok Bot (docs/PARITY.md, plan step 1):
headless browser testing. A bot proposes walk_site with one to three full
addresses and, optionally, phrases each page must show. Loki opens each page
at phone size in its own guarded browser (bitbaum/loki #1696) and answers
per page: it loads, shows what it must, does not scroll sideways, has no
broken picture. The thread keeps Loki's own sentences; nothing is filed, and
a problem is filed with file_loki_finding.

- services/loki/site-walk.ts: the call over the signed rail, the parsing of
  what a bot names, and the lines the thread keeps. Nothing is opened
  without a full address or for more than three pages; a refusal is Loki's
  sentence; an answer that cannot be read is never reported as a walk.
- One body in LOKI_HANDS, so the Cat's card and a bot's own work loop run
  the same thing; read-only, so it can be switched to "on its own".
- Registered in cat-actions, the Loki connection, the bot's hands and their
  labels, and the chat's progress words.
- The prompt budget is raised 7,080 -> 7,230 for one clause and two
  parameter names, with the reason beside it.
- docs/PARITY.md: the row is in progress, and step 1 says what is still to
  do (the picture in the thread; a walk that clicks through a flow).

__tests__/unit/cat/loki-site-walk.test.ts. Unit suite: 730 files, 5924 tests.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi

* feat(companions): use_browser, a browser of its own for every bot; a failed page's picture in the thread

Cat Bot's computer use against Grok Bot's (docs/PARITY.md, plan step 2),
OrangeCat's half; Loki's is bitbaum/loki #1697.

A bot proposes one step at a time: open, click, type, press, scroll, back,
look, close. Loki takes the step in that bot's own Chromium (its own
cookies, kept out of the private network) and answers with what the page
now shows. The thread keeps the picture, the address, what the page says,
and what can be clicked or typed into, numbered, so a model that cannot see
pictures drives by number. Loki never types a password or a card: that step
stops and says the owner does it.

- services/loki/browser.ts: the step a bot wrote becomes the step Loki is
  asked for, or a sentence saying what is missing; nothing is sent for a
  step that cannot be one. A stopped or failed step is its sentence, never
  a success; an unreadable answer is never a page.
- Whose browser is the server's to say: hands-server stamps bot_id from the
  bot whose turn it is and drops whatever a model wrote there. The Cat,
  which is no bot, uses the person's own.
- One body in LOKI_HANDS, so a card and a bot working on its own run the
  same thing.
- walk_site now shows the picture of a page that failed.
- Prompt budget 7,230 -> 7,440, with the reason beside it. PARITY rows
  updated.

__tests__/unit/cat/loki-browser.test.ts. Unit suite: 731 files, 5935 tests.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 07:02:54 +01:00
CatoandClaude cabdc55d30 fix(create): a currency switch converts every amount instead of re-labelling it; prices start empty (#1677)
* fix(create): a currency switch converts every amount instead of re-labelling it; prices start empty

Measured on orangecat.ch at 390px, dark and light, nothing submitted
(BTC at about CHF 60,600):
- Product: Price 25 CHF, then "Default Currency" set to BTC: the field
  read 25 BTC; switched back to CHF it read 1515625.00.
- Loan: 10000 CHF and 8000 CHF; Loan Amount's switch to BTC gave
  0.16494845 BTC next to a Remaining Balance of "8000 BTC".
- Price, Loan Amount and Remaining Balance showed "0.00": a tap and "25"
  entered 0.0025 and read "0.00" on blur; 10000 entered 0.0010000.
- Asset: sale, rental and deposit prices were bare "(BTC)" number inputs;
  the Rental Apartment template asked 0.025 BTC a day (about CHF 1,500).
- The currency select was an unnamed combobox: one on products, two on
  loans, one on services, one on events.

What changed:
- The form converts every amount held in its currency when the currency
  changes, from whichever control changed it, at today's rate and rounded
  to what the field shows. Without a rate the switch is refused with a
  message, never written as 0. A field's own switch no longer converts
  only itself.
- Price, Loan Amount and Remaining Balance start empty and say "Enter a
  price" / "Enter the loan amount" / "Enter the remaining balance" when
  left empty. A fiat amount with more than two decimals is shown, not
  rounded away.
- The asset's estimated value, sale, rental and deposit prices use the
  same currency field as every other amount. The three *_btc prices are
  stored in BTC (storedIn) and typed and shown in the form's currency.
  Rental Apartment: 0.05 BTC a month, deposit 0.1 BTC.
- The product's "Default Currency" is "Currency" and says it converts
  the price; the asset's Currency says the same of the estimated value.
- Every currency select is named after its field ("Price currency").

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

* fix(create): an amount keeps the unit it was typed in, and BTC prices round to what is stored

Review of #1677:
- The entry currency of a money field was worked out on every keystroke from
  the live rate. A rate expiring mid-edit flipped it to the stored unit and the
  whole typed string was read again in BTC: 30000 typed as CHF became 30000 BTC.
  The unit is now fixed when the edit starts and released on blur or when the
  owner switches currency.
- A converted amount is rounded to the stored unit's places (eight for BTC)
  before it reaches the form, and the asset schema refuses a sale, rental or
  deposit amount kept in BTC that rounds to 0.00000000 BTC.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 06:44:21 +01:00
CatoandClaude 2f5346cac5 fix(tasks, cat, home): the five owner decisions from the UX/UI audit (#1695)
The owner handed the audit's five decisions over on 2026-11-12. Each is
decided here, except the token values, which go to the package itself
(bitbaum/design-tokens#64).

- Tasks are seen and changed by their creator and by the person a request
  names. Any signed-in account could read and update every non-archived task,
  read every completion and flag, and read requests sent to "everyone".
  Migration 20261113120000 scopes tasks, completions, flags and requests;
  SECURITY DEFINER helpers keep the two tables' policies from recursing.
  Tested against Postgres 16 as creator, person asked and stranger.
- A request names one person, picked with the money screens' people picker.
  The request and flag routes no longer notify every account on the platform;
  the broadcast helper is removed. PeoplePicker passes the person as a second
  argument to onPick.
- Saving a Cat spending cap keeps the payments row's on/off state (or the
  category default, off). It wrote granted: true, so Send Payment and five
  more moved from Off to "Ask first" on accounts that never chose. The new
  test fails on the old code.
- Migration 20261113121000 marks the three hand-made QA listings as test data
  by id; nothing is deleted.
- The home page shows "What it solves" before the studio.

Docs: the audit's decisions section records what was decided; CHANGELOG.


Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-13 00:20:28 +01:00
CatoandClaude 45d3f8d0fc feat(public): every public page opens with one header; the visitor menu lists the header's links and a way to sign in (#1689)
* fix(nav): the visitor menu on a phone lists the header's links and a way to sign in

On a phone the public menu showed "Blog" and "Support", dropped the Product
and Ecosystem groups (items with children and no href rendered nothing),
listed the whole footer in their place (27 links, 1,681px in a 780px panel)
and offered no Sign in anywhere in the public chrome. It was a plain div: no
dialog role, no close control, and the button that opened it did not say it
was open.

- The menu lists the header's own destinations in their groups, each with the
  line that says what it is; Blog and Support get that line in the config.
  A hairline separates a group from the plain links after it.
- It ends with Sign In and Get Started as two equal cells. The footer is not
  repeated; it is on the page.
- It is a modal dialog: a close button, a dimmed page behind it, focus kept
  inside while it is open and returned to the menu button after. The menu
  button carries aria-expanded and aria-controls, and closes the menu too.
- HeaderNavigation keeps only the desktop bar and is under its size limit, so
  its exemption is removed.

Measured at 390px in both themes with the menu open: no axe violation.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* feat(public): every public page opens with one header

Thirty public pages each built their own first screen: titles from 24px to
60px, centred on some and left on others, an icon above one title, a pill
above another, a raised band behind a third, and six content widths. Fleet
rule "One shape per kind": siblings share one frame.

- PublicPageHeader (src/components/layout/PublicPageHeader.tsx) owns the title
  scale (30/36/48px), the lead line, the space above and below, and the
  alignment: centred for a page about OrangeCat, start-aligned for a document
  read top to bottom. An optional label above the title, small print under
  the lead line, and a slot for buttons or a short form. No icon, pill or
  band, on purpose.
- PUBLIC_PAGE_WIDTH gives a page one of two widths, reading (768px) and wide
  (1152px), in place of six.
- 26 pages and the legal document renderer use it. Titles and lead lines are
  unchanged. The shield, cat, briefcase and play icons, the bitbaum logo above
  its title and three pills are removed; "Founding supporters" and "Open
  source · MIT" stay as the label.
- Articles, a blog post and "What do you need?" set their title in the
  heading face.
- check:public-frame (in verify) fails a page under src/app/(public) that
  writes its own h1, uses PageHeading directly or wraps itself in PageLayout;
  five pages are exempt by name with the reason.
- The code samples on "Sign in with OrangeCat" and the command on "Steal the
  cat" take focus, so a keyboard can scroll them. The first section heading
  on How it works is one step smaller than the page title.

Measured on 30 pages at 390px and 1440px in light and 390px in dark: no
sideways scroll, one h1 each, no axe violation.

Docs: the audit gains a "Second batch" section with before and after images;
CHANGELOG and AGENTS.md name the frame and the gate.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(nav): the visitor menu's id lives with the header constants

#1663 added a test that replaces MobileMenu with a stub. Header imported
VISITOR_MENU_ID from MobileMenu, so the stub took the id away and the header
threw while rendering a 404 (11 tests, after main was merged into this
branch). The id now lives in src/constants/header.ts beside the other header
constants; MobileMenu and Header both read it from there.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 22:28:33 +01:00
CatoandClaude f2ff015325 fix(sitemap): a database that does not answer costs the sitemap its database URLs, not the build (#1685)
* fix(sitemap): a database that does not answer costs the sitemap its database URLs, not the build

/sitemap.xml is prerendered at build time and reads the database for its
profile, entity and article URLs. On 2026-11-12, while the self-hosted box was
out of memory, those reads hung: Next.js gave the route 60 s three times and
then failed the whole export ("Export encountered an error on
/sitemap.xml/route"). Every CI build failed this way for as long as the box was
down, and a deploy in that window would have failed too. The existing
try/catch could not help, because nothing threw; the queries just never
answered.

- The article read and the profile/entity walk run at the same time, and each
  gets the same 15 s budget. A section that misses it is left out of this
  generation and logged, exactly as a failing query already was. The hourly
  revalidation fills the URLs back in once the database answers.
- Static and blog URLs never depend on the database.

Test: with every database read hanging, the sitemap resolves at 15 s with its
static and blog URLs and logs both omissions. Against main the same test hangs
until it times out. With a database that answers, every URL is present and
nothing is logged.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

* fix(roadmap): a database that does not answer drops the capital card, not the build

The same CI build that waited on /sitemap.xml also failed on /roadmap
("Failed to build /(public)/roadmap/page ... because it took more than 60
seconds", three times, then "Export encountered an error"). /roadmap is
prerendered and reads the open-capital rails from the database; with the
self-hosted box out of memory those reads hung, and nothing threw.

- withinDbBudget moves to src/lib/supabase/within-budget.ts, one helper for
  both prerendered pages.
- /roadmap gives the capital read the same 15 s. Past it, the capital card is
  left out of that render and logged; the page already renders without it, and
  revalidation (5 min) brings it back.

Test: with the capital read hanging, the page renders at 15 s and logs the
omission; against main the same test hangs until it times out.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 20:31:49 +01:00
CatoandClaude d2c754786e fix(a11y): keyboard focus is no longer hidden under the phone's tab bar or the header (#1668)
Measured on orangecat.ch at 390px (iPhone 13, dark and light, 2026-11-12),
tabbing through each page and sampling a 5x5 grid of elementFromPoint over
every focus stop:

- Tab: /timeline's Reply, Repost, Like, Dislike and Share took focus at
  y=609, wholly under the tab bar (y=583-664): 11 of 60 stops on /timeline,
  18 of 56 on /dashboard/things (the composer suggestions too). The browser
  scrolls focus only to the viewport's edge, and nothing told it the bar
  covers that edge.
- Shift+Tab: the same controls landed at y=0, under the header that
  scrolling up brings back (8 of 50 stops on /timeline, 7 on /dashboard).
- Past the last stop, Tab wraps to the header's own controls (Toggle
  sidebar, Open search, Notifications, User menu; Get Started signed out on
  /pay/cato and a project page) while the header was still slid away for
  the scroll-down: focused at y=-51 with nothing on screen.

What changed:

- globals.css: scroll-padding-bottom of the tab bar's clearance while the
  bar is on the page (phone widths), and scroll-padding-top of the header's
  height (its row, the status-bar inset it pads, the email banner) while
  focus is keyboard-visible. Only then, so a tap that jumps to an in-page
  anchor that already clears the header with scroll-margin (#pay, the
  settings sections) lands where it always has.
- header-utils: the hidden header carries has-focus-visible:translate-y-0,
  so it comes back while keyboard focus is inside it.
- MobileBottomNav: the bar's box is .app-mobile-nav, the element the
  scroll-padding rule names.

The same rules, injected into production with the two classes mirrored,
left no fully hidden stop tabbing /timeline (60 stops), /dashboard (59)
and /dashboard/things (56) signed in, or /pay/cato (58) and a project page
(54) signed out; tabbing back up /timeline and /dashboard, none under the
header.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 18:39:04 +01:00
CatoandClaude ea3b50252f fix(onboarding): skipping the bio sticks, Back stays on the site, the copy says what Create does (#1665)
On orangecat.ch (390px, dark and light, signed in) the header logo and a
fresh visit to / both landed on /onboarding/intelligent. Step 1 had no
skip; "See what Cat suggests" stays disabled until a name and a bio are
given, and in a fresh tab the page's Back went to about:blank. The copy
said Cat would "set them up" and that offers are created "in one click";
"Create this" opened /dashboard/services/create with only the description
filled in (title and category empty, nothing saved). The example chips were
cut at 50 characters ("start sellin…") while already two lines tall.

- Step 1 has "Skip for now": it records onboarding_completed with
  onboarding_method 'skipped' (the value the column already allows), then
  goes to the Cat.
- / heals a stale flag for anyone who owns any registered entity (a
  wallet, a product, a group...), counted by the registry's owner column;
  only projects counted before.
- Back on step 1 goes to the Cat when the page behind is not ours
  (Navigation API canGoBack, else history plus a same-origin referrer).
- The copy says Cat suggests ways to earn and writes a first description
  for each; the button reads "Fill in the rest".
- Example chips show the whole sentence, clamped to two lines by CSS.

The chips and the skip moved into their own small components to keep
IntelligentOnboarding under the 300-line gate.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 18:28:14 +01:00
CatoandClaude 1d29cb4c47 fix(a11y): text that reads in both themes, ink that follows its fill, 44px targets, Send's button above the tab bar (#1634)
* docs(agents): keep the Next.js agent-rules block as next dev writes it

next dev regenerates the block between the nextjs-agent-rules markers and
now writes its heading one level down. Committing it keeps the tree clean,
as the block itself asks.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(a11y): text that reads in both themes, ink that follows its fill, 44px targets

A measured audit (99 pages, 390 and 1440, dark and light) found 1,729
elements under 4.5:1, text that was invisible in the default dark theme,
and 1,438 tap targets under 44px on a phone. This fixes the causes rather
than the instances, and adds a gate for each class.

Colour
- Text ramp: secondary and tertiary now clear 4.5:1 on every surface in
  both themes (tertiary alone caused 81% of the failures). Primary is
  unchanged. check:token-contrast holds 124 pairs.
- Status colours are tuned to be read as words; `bg-status-*` paints new
  fill tokens, so a danger button stays red and a warning bar stays amber.
- `text-on-public` for the band that is near-black in both themes: the
  closing banner on About, Docs, Security and Domains showed only its
  button in dark.
- Fills that flip with the theme carry `text-fg-inverted`, not white: the
  step badges on How it works, the share sheet label, the wallet stats
  header. Orange fills carry `text-on-accent`.
- `text-fg-muted` and resting alpha on copy are gone (65 lines).
  check:accent-ink now holds six ink rules, across multi-line cn() calls.
- Article and FAQ links are ink with a full-strength underline.

Structure and touch
- Footer: 44px links on touch, two columns on a phone, no duplicated
  bottom bar. check:tap-targets holds every compact height.
- Switch: 44x44 hit area, off is an outline and on is a fill; the Cat
  permission switches and expanders are named.
- One h1 on sign-in, the Cat chat, the 404 and route errors; no nested
  <main>; one home link in the header; progress bars announce a value.
- The 404 names the failed address (read in the browser only, since the
  build prerenders it once), and offers search, home and Discover.
- Entity list tabs that pointed at panels which do not exist are a
  segmented control; its selected cell has an edge in dark.

Motion and focus
- A focus outline in forced-colours mode (the ring is a box-shadow).
- Smooth scrolling only without prefers-reduced-motion, in CSS and at
  every scripted scroll (src/lib/scroll-behavior.ts).

Also
- Headings no longer auto-hyphenate ("permission-less").
- The status page drops a hard-coded "Bitcoin Integration" row that drew
  as an outage, and its headline follows the worst row shown.
- 10px text on phones is 12px.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(a11y): say only what is held; menu rows and the last in-app orange in touched files

Review of the previous commit:
- The changelog said every text colour clears 4.5:1. Grey text and the
  status colours do, and a gate holds them; orange words elsewhere do not
  yet. The entry says the former, and keyboard and screen-reader work has
  its own line.
- AGENTS.md and the frontend rules said a status fill takes
  text-fg-inverted; the warning fill is amber in both themes and takes
  text-warning-foreground, which is what the gate enforces.
- Dropdown menu rows are 44px on touch, as select rows are.
- Pricing: the plan card and its badge are neutral; orange is the action.
- Profile claims, the Loki chip, "Read article" and the model picker's
  unlock lines are ink: they are in-app, and as text the orange is 2.1:1
  in light.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(send): the committing button stays above the phone tab bar

MoneyActionBar stuck to the bottom of the viewport, which is where the
fixed tab bar is drawn, at a higher z-index. After choosing a person and
an amount, "Review payment" sat at y 787-831 of 844 under the bar (763-844)
and its centre hit-tested to the bar's Receive button; the same at 390x667
and 320x568.

It now sticks at the tab bar's clearance. While the software keyboard is
up the tab bar is not rendered, so the bar returns to the bottom edge and
takes the home-indicator inset itself.

Measured after, field blurred: button 707-751, bar 763-844, hit = button,
at all three sizes; keyboard open: button at the bottom edge, hit = button.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(ci): check:broken-words opens the pages it did before

build-and-smoke was cancelled at its 25-minute limit on this branch. The
step that never finished was check:broken-words: this branch had added
seven public pages to it, 39 screens in place of 18, and it ran for 20
minutes without output before the job was stopped.

The page list is main's again. What the extra pages were there to hold,
that headings do not auto-hyphenate, is pinned by the unit test on
globals.css. AGENTS.md records the budget so the next addition is made
with it in mind.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

* fix(a11y): the hand-over page does not nest a second main landmark

The identity hand-over page (#1609) wraps its content in <main>, and the
app shell already renders <main id="main-content"> around every route, so
the page had two. Its wrapper is a div; the heading and layout are
unchanged. Caught by the page-structure test this branch adds.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 16:43:10 +01:00
CatoandClaude b59ad809c5 fix(wallets): a balance nobody has read shows as not checked, not CHF 0.00 (#1638)
* fix(wallets): a balance nobody has read shows as not checked, not CHF 0.00

The reported "stale balance": the wallet balance column defaults to 0,
so a wallet whose address no one has looked up carries 0. The owner's
own profile then said "Current Balance CHF 0.00", and the wallet list
said "0.0% funded" right beside "Not checked yet" (production,
2026-11-12).

measuredBalanceBtc() in lib/wallet-goal.ts is the one rule: the balance
counts only when balance_updated_at records a chain lookup; otherwise
it is unknown. The profile's balance block says "Not checked yet" and
both goal bars (profile and wallet card) give no percentage until the
balance is read. A visitor's payload carries neither field, unchanged.

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

* test(wallets): a fetched balance carries the time it was read; an unread one says so

Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 16:26:50 +01:00
CatoandClaude Opus 5.5 a343b91af2 feat(identities): shared account menu, hand-over, unread counts, person tags, operator circle (#1609)
* refactor(menu): the account menu is accountkit's AccountMenu

OrangeCat ran its own account menu (UserProfileDropdown, its panel, a
dropdown hook) while every other product uses @bitbaum/accountkit's
AccountMenu. The identity switcher was then added to the local one, which
is the copy the fleet rules say not to write. The switcher now lives in
accountkit 0.28.0, and OrangeCat mounts the shared menu.

- AccountMenuControl supplies what is OrangeCat's: the person, the places,
  the other identities (ADR-0014) and what a tap does. Layout, keyboard
  handling and the sign-out and switch failure states are the package's.
- A failed sign-out or switch is passed on as a rejection, which is how the
  menu knows to stay open and say so. The toasts are gone.
- Appearance stays reachable from the menu, for phones.
- --acct-line maps to the default border: the subtle border is the same
  shade as the overlay the menu sits on, so in light mode its groups ran
  together.
- Removed: UserProfileDropdown, UserProfileDropdownPanel,
  IdentitySwitcherRows, ThemeModeRow, useDropdown.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* feat(identities): an identity can be handed over (ADR-0014 D9)

The holder creates a hand-over link for one identity. Whoever opens it gives
an email address and accepts; the identity is then an ordinary account on
that address, with everything it owns, and that browser is signed in to it.
The former holder can no longer switch to it.

- The link is the credential, as a claim link is (ADR-0004). It is shown
  once and only the SHA-256 of its token is stored (identity_handovers,
  service-role only). One open offer per identity, seven days, withdrawable.
- Reading the accept page spends nothing; only the form's submit accepts.
- The order of acceptance is the safety property: the link to the holder is
  deleted BEFORE the identity is given its address. If the address is taken,
  the link and the offer are put back and nothing has changed.
- The former holder's sessions in the identity are ended on acceptance.
- The accept endpoint is public by design (the person accepting has no
  session in the account yet), rate limited per IP, and recorded with its
  reason in the route-guard allowlist.
- The link is built from the site's public address, not the request's.

Also: the consent screen no longer promises an app 'Read your email
address' for an identity, which has none to share.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* feat(identities): one person is one tag to an app (ADR-0014 D7)

An app that gives every account a say (Solon) gives a person with several
identities several. To refuse the second seat it must learn that two
accounts are one person, and nothing else.

POST /oauth/person-tags answers a confidential client OrangeCat trusts
with a tag per account: two accounts share a tag exactly when one person
holds both. The tag is HMAC-SHA256(key, client || scope || holder), so it
differs per app and per scope the app names, and cannot be computed or
reversed without the key.

- The key is generated by the database when the migration is applied. It
  is never in the repository or an environment file, no API role can read
  it (not the service role either), and it does not leave the database:
  identity_person_tags() does the keyed step. One row, written once,
  because changing it would unmatch every tag an app has stored.
- A self-registered app cannot ask at all.
- An account with no tag could not be told apart; it is not someone else.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* feat(identities): see what waits in your other identities; an operator can resolve a circle

D8. GET /api/identities gives each other member the unread count the bell
shows, read on the service role and only ever for the caller's own circle.
The menu shows it on that identity's row and as a dot on the avatar
(@bitbaum/accountkit 0.29.0, waiting on an account); Settings shows it on
the row. A count that cannot be read is left out, not shown as zero.

D10a. identity_circle_of(handle) returns the holder and every identity it
holds, for any handle in the circle. Service role only, so it adds no way
for one user to learn another's identities. It reads; it does not act.
OrangeCat has no suspension mechanism today, so a circle-wide ban has
nothing to switch on yet; when it does, it starts here.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* test(identities): the person-tags route decides who may ask

POST /oauth/person-tags had tests for the function it calls and for the
database function behind it, but none for the route, which is where the
decision about who may ask is made. Pinned here:

- a trusted confidential client gets its tags, with no-store, and the
  registered client id is what is passed on;
- an unknown app, a public app and a wrong secret get one identical 401,
  and none of them reaches a lookup;
- a client that authenticates but is not trusted gets 403 before a lookup;
- rate limited before anything is read;
- a failed lookup is 503 and never an empty set of tags.

The suite-wide next/server mock stubs NextResponse.json to return nothing,
so this file gives it a real one.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* fix(identities): close the boundaries an adversarial review found

Critical: an identity entered with a way in of its own (a password or
passkey given in its own settings, its login handed to someone) could
regain the whole circle. Its withheld circle still listed itself, and no
switch path but the API route refused a switch to yourself: calling the
consent screen's 'Continue as' with its own id minted a fresh one-time-code
session, which the gate then read as a switch. mintSwitchCode now refuses a
withheld caller and a switch to yourself, in the one function every switch
goes through.

- Losing the circle is permanent: the first change to an identity's email
  or password stamps identity_links.lost_circle_at (trigger on auth.users),
  and a stamped identity never has its circle again. Before, setting an
  unreachable address back let it in.
- A handed-over identity keeps no way in. Acceptance now spends the offer
  atomically (two people opening one link: one gets through; a withdrawn
  link finds nothing), cuts the link, removes every way in the former
  holder could have put on it (identity_strip_ways_in: every GoTrue table
  tied to the user, found from the catalog, plus linked providers; the
  connected apps' tokens and consents; the password, replaced by one nobody
  knows), and sets the new address last. Any failure before that puts the
  link and the offer back. An address error the auth server applied anyway
  is counted as done, not relinked.
- Person tags are answered only for accounts that granted the asking app:
  a trusted app could otherwise map every circle on the platform.
- getCircle throws on a failed read instead of reading it as 'no
  identities' (which let account deletion orphan identities).
- The handle check escapes LIKE wildcards ('_' is allowed in a handle).
- The identity limit holds when creates race: a create past the limit in
  creation order gives way.
- Switching moved to src/domain/identities/switching.ts (the service passed
  the 500-line limit).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* fix(identities): interface and mail after review

- Mail for an identity reaches the person: one recipient rule
  (recipientEmail.ts) for the email service, dispatcher and seller
  notification; an identity's mail goes to the account that holds it,
  never to its undeliverable address.
- Wishlist proofs accept any actor the caller holds (userHoldsActor).
- The account menu reloads identities when they change (event + tab focus)
  and reports a failed switch; settings show a retry when the list fails,
  and say plainly when an identity cannot manage the circle.
- Hand-over: "Not now", a new link for an open offer, and an accept page
  that ends on "It is yours" with sign-in instead of a silent redirect.
- Settings for an identity explain it has no email or password of its own;
  the delete dialog says what deleting removes.
- Consent "Continue as" says when the switch did not happen.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 13:44:24 +01:00
CatoandClaude 247814ec2e fix(status): /status no longer shows Bitcoin as an outage nothing measured (#1630)
On orangecat.ch/status (390px, dark and light) the headline read "All
Systems Operational" while the Services list showed "Bitcoin Integration"
with a red XCircle and a red "Outage" badge. /api/health at the same moment
reported services.bitcoin_integration: "unknown": the row was hard-coded in
checkHealth() and nothing ever probed it, and the page's StatusBadge and
StatusIcon drew every status other than operational/degraded as an outage.

- checkHealth() drops the unprobed Bitcoin row, as it already does for the
  cache. Nothing reads services.bitcoin_integration: uptime.yml reads only
  services.authentication, the cat-health timer is retired, no test uses it.
- /status draws states from one map keyed by every ServiceStatus, so a
  missing state is a type error, not a fall-through to red. 'unknown' reads
  "Not checked" in neutral tones; a real outage is still red.

Tests: checkHealth with every dependency up reports every row operational;
/status draws an 'unknown' row as "Not checked" and an outage as Outage.
Claude-Session: https://claude.ai/code/session_019MDtmw3MnN44QwEv4M52CS

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 11:13:10 +01:00
CatoandClaude Opus 5.5 69cef759c7 fix(companions): a bot follows the run it started to its answer, and every step is checked and logged (#1622)
* fix(companions): a reply the output cap cut is continued once and never stored mid-sentence

A bot's answer ended "If you treat me…". Its cap was 1,000 tokens, a
reasoning model spends part of that thinking, and the vendor's
finish_reason=length was stored as if the answer were whole.

- the owner's turn with their own bot gets room for 3,000 tokens (a
  creator's own setting still stands for anyone else, whose price is per
  token); Groq keeps its measured 1,024, whose per-minute budget counts
  reserved output
- a reply cut by the cap is continued once on the model that wrote it, and
  the halves are joined
- one that is still cut, or whose continuation fails, goes back to its last
  finished sentence and says how to get the rest; an open code fence is closed

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

* perf(companions): a bot reads its owner's grants once, and each turn logs where its time went

A bot took a long time to answer "Hi". Before the model was asked, the turn
checked every hand with its own read of the person's grants, one after
another: a dozen database round trips, growing with each hand added. Memory
recall waited for those to finish, and nothing recorded which step was slow.

- handsFor reads the grants once and checks every hand against that copy, at
  the same time (checkPermission takes the stored grants)
- memory recall and hands are read together
- every turn logs 'companion turn timing': checks, context, model and store
  in milliseconds, with the model, output tokens and prompt size. The reply
  is not streamed, so the model phase is the time to the first word

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

* feat(companions): a bot works on its own in its owner's Loki, with a switch per ability

A bot could propose one step and then waited for a tap, so it could not do a
job: start an agent session, wait, read the answer, report it. Every bot of a
person was also offered the same hands.

- companion_hand_grants: per bot and per hand, the owner sets off, ask me or
  on its own. The row 'What it can do' in the bot's details is the switch
- only the hands that work in the owner's Loki can run on their own. Anything
  a bot makes on OrangeCat still waits for a tap, so nothing told to a bot in
  confidence is published unseen
- the work loop: an on-its-own hand runs at once, its result is written into
  the thread and handed back to the bot, and the bot takes the next step, up
  to six steps or two and a half minutes a turn
- a task it sends is followed in code: the run is waited for and the
  session's conversation read, so the bot reports the agent's answer
- routines run the same turn, so a scheduled bot can do a job unattended
- the Loki hand bodies moved to services/loki/hands.ts, one body for the
  Cat's card and the bot's own step. A step never goes through the Cat's
  executor or handlers: the import-boundary test is unchanged and passes

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

* feat(companions): filing a finding and reading it back can run on their own too

The finding hands landed on main (#1613). Their bodies join the shared Loki
hands, so a bot whose owner switched them on can file what it found on a
live app and read the report's status as steps of a job.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

* feat(companions): a bot reads how every project is doing, and can ask a one-off in a fresh session

- project_status: every Loki project of the owner in one read. What it is
  doing and what waits in its inbox (Loki's actor status), its latest run and
  pull request (Loki's sessions), and whether its live site answers right now
  (a request made here: never to a private address, never following a
  redirect). A site that was not asked reads 'not checked', never 'up'
- fresh_session on send_task_to_loki: a busy project starts a separate agent
  session for a one-off question instead of refusing it or folding it into
  the open run (Loki's separateSession, bitbaum/loki#1646)

Both are Loki abilities, so a bot's owner can switch them to run on their own.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

* fix(companions): a bot follows the run it started to its answer, and every step is checked and logged

Following a run:
- the follow reads THAT run, not the project's latest open run: its first
  poll asks Loki to watch the run's session for the whole wait, and the last
  read is the run's own session (bitbaum/loki#1658)
- the agent's handoff is shown and handed to the bot ("The agent reported:
  ..."), so a one-off session that closed still has its answer
- an older copy of a conversation is said to be one
- a run read back while it is still going is followed too

Steps a bot runs on its own:
- the owner's Cat permission is checked for every step (a daily limit holds
  across a job), and every step is a row in the action log
- a step proposed to run on its own that the turn could not run becomes the
  ordinary card instead of being dropped; one that ran is never queued again

From review:
- project_status reads Loki now, not the Cat's five-minute copy, and its
  live-site check can only connect to a public address on the default port
  (the lookup is the connection's own, so DNS rebinding cannot reach inside);
  a name that does not resolve is down, not 'not checked'
- a finding carries a retry key: the same finding filed again the same day
  is the same report, and a timeout says a retry is safe
- a task is signed with issuedAt so Loki can refuse a replayed one

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

* fix(companions): a follower polls lightly, and the words say what the code does

From review:
- the follow's polls ask Loki for the run's own facts only (poll: true), so
  following a run every six seconds never spends the owner's GitHub budget
- the line a person reads after a task is sent no longer carries the bot's
  tool instructions
- hands.ts and ADR-0013 D10 now say what happens: a high-risk hand waits for
  a tap unless the owner switched it on for that bot, and a step already
  started can run past the two and a half minutes

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 09:28:26 +01:00
CatoandClaude Fable 5.2 0275875588 feat(companions): a bot files a finding into a Loki project's feedback inbox, and reads it back (#1613)
* feat(companions): every bot can read Loki sessions and runs, and send its agents a task

A bot could only ask Loki and mint a handoff link. It could not start work in
the owner's projects, and it could not read what an agent answered.

Three more hands, offered to every bot of the owner (the set is the
platform's, not one bot's), each proposed as a card and run only on a tap:
- loki_sessions: every session's state, task, run and PR; with a project,
  the last lines of its agent's conversation, quoted
- loki_run_status: one run on its way to live, by runId
- send_task_to_loki: start or task an agent session, optionally on the cloud
  runner. High risk: a tap can never grant it, and it is confirmed each time

The task result now carries the runId Loki opened, in the summary and in the
line the thread keeps, so the next turn can read the run back.

Loki answers as the Loki account linked to the owner's actor, so a bot never
reaches anyone else's projects. Reads go to /api/orangecat/sessions
(bitbaum/loki#1644); until that is live the two read hands answer with Loki's
refusal in words.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

* feat(cat): a task to Loki can queue behind a busy session

Loki now refuses a task for a project that already has an open run, with a
sentence (bitbaum/loki#1646). queue_if_busy sends it behind the open run
instead; without it the person reads Loki's sentence and nothing is sent.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

* feat(companions): a bot files a finding into a Loki project's feedback inbox, and reads it back

A bot that checks a live app had nowhere to put what it found.

- file_loki_finding (medium risk, always a card and a tap): the finding goes
  into that project's feedback inbox in Loki, through Loki's own machine
  filing contract, as the Loki account linked to the bot's owner. Filed, not
  fixed: the line the thread keeps says so and carries the report id
- loki_finding_status (read): the report's canonical state and reason

Both are in the hands every bot of the owner is offered. Loki decides the
project, the seat and the replay rule (bitbaum/loki#1648); a refusal comes
back as Loki's own sentence.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmsQh5BSKKaJXnf4KjU

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 06:09:37 +01:00
CatoandClaude Fable 5.2 6fea306678 feat(identities): switch from the user menu; the identity row reads on a phone (#1606)
* fix(identities): the identity row keeps its name, its face and its label on a phone

Walked on the live site at 390px after #1605 deployed:

- The face was an empty broken ring. The avatar component always renders an
  image element, and with no picture that draws a broken frame and squeezes
  the initial out of the circle. The image is rendered only when there is one.
- The name was cut to 'Alberto C…' because Delete and Switch shared its row.
  A row now has one action; deleting is its own line underneath, where the
  confirmation also appears.
- 'Main account' was truncated off the end of a long handle. The label leads.

Row extracted to IdentityRow.tsx. Checked at 390px and 320px: no sideways
scroll, every button 44px tall.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* docs(adr-0014): record what the live walks verified

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* docs(adr-0014): the escalation gate holds on the live site

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* feat(identities): switch identity from the user menu

The other members of a person's circle are rows of the menu under their
picture; one tap switches. Nothing is rendered for a person with a single
identity, so the menu is unchanged for everyone who has not added one.

- src/lib/identities/client.ts holds the list and switch calls, used by
  both the menu and the settings section.
- The menu no longer shows an identity's unreachable address under its
  name: a made-up mailbox where an email belongs.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 01:12:34 +01:00
CatoandClaude Fable 5.2 e5481369ea feat(identities): a person can hold more than one name (ADR-0014) (#1605)
* fix(actors): a person with several actors keeps their counts, their voice and their own wishlist

Nothing makes a user's actor unique, and six places still read that as
impossible:

- listingCounts, the messaging actor picker and the Cat's runtime context
  used maybeSingle() on user_id. For a person with duplicate actors that
  errors, which read as 'no actor': listing counts of zero, no way to
  write as yourself, no current actor for the Cat.
- bookings picked the customer actor with an unordered limit(1), so the
  'cannot book your own listing' check could miss.
- three wishlist owner checks compared wishlists.actor_id to the auth
  user id. An actor id is never a user id, so the owner could rate their
  own wishlist and never saw 'add proof'.
- claim_placeholder_actor chose the claimer's actor with an unordered
  SELECT INTO; a claim could land on an actor every reader ignores.

All now follow the one rule (oldest actor is primary) through
src/domain/actors, with userHoldsActor for 'is this actor mine'. The
guard test is widened to the shape these copies shared.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* feat(identities): a person can hold more than one name (ADR-0014)

An identity is a whole account of its own: its own profile, page, wallet,
timeline, inbox and sign-in to Loki and Solon. What makes it one of a
person's identities is one private row naming the account that holds it.
Nothing an identity owns points at its holder, so two identities of one
person cannot be joined from any public row.

- identity_links: service-role only (RLS on, no policy). One level, written
  once, a database ceiling behind the product limit.
- /api/identities: list, create, delete. /api/identities/switch replaces the
  session with one for another member of the caller's circle, using the
  same generate-then-verify mechanism as sign-in by emailed code. Cookie
  session only.
- An identity sits on an unreachable address with no password; the holder
  needs a real address first. Apps are not handed the address.
- Sign out everywhere ends every member's sessions and connected apps;
  deleting the holder deletes its identities first.
- Settings gains the section to add, switch and delete.

Rejected: more user actors under one login. 44 RLS policies and a NOT NULL
user_id on eight entity tables key on the login, so a second actor either
cannot act or publishes its holder on every row.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

* fix(identities): an identity with a way in of its own loses the circle

An identity can be given a password, a passkey or a real address from its
own settings, and its login can then be handed to someone else. Without a
gate that person is one request away from the holder's main account and
every other identity.

An identity may now use its circle only while it is still the holder's
alone: its address is still unreachable AND its session came from a switch
(the amr method of the verified access token). Otherwise it stands alone:
it cannot switch, list, create, delete or sign the others out. The holder
is never gated. The session methods are an allowlist, so a sign-in method
nobody thought of fails closed.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019MDtmubu4vMeqp2pdae1Zy

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-11-12 00:10:49 +01:00