~ knotless Search/
↑↓ move↵ open⇧↵ all results

chadtmiller.com/hud

A remote MCP server that shows atproto records as interactive UI inside MCP Apps hosts

0
0

A record with no facets has its links, mentions and tags found

Merged
Merged chadtmiller.com asked to merge into main from chadtmiller.com/hud:render/detect-without-facets

What changes

A RichText with format: "facets" whose facets read nothing (a record written with none at all) has its links, @mentions and #tags found as format: "detect" finds them. Facets given, an empty list too, are drawn as they are. Embedded Bluesky posts (ui/embed.rs) keep their facets alone, as Bluesky draws them.

Why

On next.grain.social, a gallery written by another client (at://did:plc:75dkgvlry7j43jx2v3po7cax/social.grain.gallery/3n2w3kzcaepbt, "River Alde, Snape, Suffolk, 2026") has a description with a URL and three #tags and no facets key; Grain's view draws it with format: "facets", so it showed as plain words. Grain's web (RichText.svelte) and iOS app (RichTextView: "Uses facets if provided, otherwise falls back to regex parsing") both find them, so this matches Grain's apps.

How it was checked

rich_text_reads_its_format_and_times_their_timestamp covers a missing facets key (a link run and a tag run found) and an empty list (plain). fmt, clippy with warnings denied; schemas/json/view.json regenerated for the catalog note.

Shortcomings

Server only: hud-next needs this HUD for Grain's descriptions to change. Coverage is left to the test check.

Asked for changes

With format: "facets", a record that has no facets key now has its links, @mentions and #tags found as detect finds them. An empty list stays plain. The code change is small, and the test covers both the missing and the empty case. The catalog note and schemas/json/view.json are updated to match.

One thing is missing. AGENTS.md says a pull that changes what a tree draws adds a change file under .changeset/ (default: patch, a heading, and a line for app authors). This pull changes how RichText draws, so an app built on HUD will see different output. It adds no change file. Please add one, as knope document-change writes it.

I didn't check the renderers. The resolver emits the runs, so iOS and Android should draw the new output unchanged.

Approved

The change file I asked for is there (default: patch, heading, and a line for app authors). A facets format record with no facets now gets its runs from detected_runs. An empty list stays plain. Embedded Bluesky posts still call facet_runs directly in embed.rs, so they are unchanged. The test covers the missing and empty cases, and the catalog note and view.json match each other. I found nothing else.

Approved

Carried forward: the change this pull makes at 6fe70f55a1eefd3a1b55a84b48541a98f08d7a4d is the one reviewed at 4b0721246d3e70244cbf8546fd89d3d9d6f122e7, so that review stands. What is new comes from its base.

Merged as ae38773