diff options
| author | Adam Soltys <[email protected]> | 2026-09-04 08:55:45 -0700 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2026-09-04 08:55:45 -0700 |
| commit | a6851ae954d819b116aae6b19b175525f1488928 (patch) | |
| tree | cc7768cd754b2cb6077b2390e18cdbf3501ca289 /src/community.js | |
| parent | 174ce1027327230154b37b80e44c6b2d45929101 (diff) | |
| download | coinosv3-a6851ae954d819b116aae6b19b175525f1488928.tar.gz coinosv3-a6851ae954d819b116aae6b19b175525f1488928.zip | |
Public read-only coinos community chat at /chat — a share-anywhere link that shows the live chat history to anyone, logged in or not, with a "Sign in to chat" button ("Open coinos" when the device already has an account). No server-side decoder needed: the community's join material was already public by construction (baked into the client bundle — every coinos user is meant to be a member), so the page derives the stream keys and decrypts wraps client-side exactly like the app's Chat tab, worker-offloaded with the same sliced fallback. Renders messages + edits + deletes + reactions and honors the folded control state's ban list; presence/typing/guestbook deliberately omitted. Profiles come from ONE batched kind-0 query per burst (a REQ per author tripped relay concurrency limits). Plumbing: the join material moved to src/community.js (shared with messages.js so they can never drift), /chat is excluded from the single-segment profile deep-link (which was eating the path and rewriting the URL before the route ran), and app renders stand down in public-chat mode so a feature-init render can't paint onboarding over the page. Verified headless against the live relays: 59 messages decrypt, ban-fold applies, names resolve
Co-Authored-By: Claude Fable 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01MGzU12QrAA4G6BYGzGVdXz
Diffstat (limited to 'src/community.js')
| -rw-r--r-- | src/community.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/community.js b/src/community.js new file mode 100644 index 0000000..544cd43 --- /dev/null +++ b/src/community.js @@ -0,0 +1,17 @@ +// The default coinos community's join material (CORD-02 §8) — genesis output +// of tools/concord-genesis.js. The community_root here is deliberately +// public-ish: every coinos user is meant to be a member, and the public +// read-only chat page (/chat) decrypts with it too. Shared by the messages +// feature and src/public-chat.js so the two can never drift. +export const COMMUNITY = { + community_id: 'b517fb4ba04c4c4eac2bd486ee800d1a8644fcdca5c5643098062e7733ee4986', + owner: '98ae4da926c471c23fd12d1ebdd5839ba82917baa618e184e0c9916d93dcf4f7', + owner_salt: '466450cd6cd0e6991a5acea091c5bc9e9a1c1ba27a970e64d2af4860e7f60cb1', + community_root: '58b2ce26eba30fbd19d9a57bce4c61e65838686998f10bba1d3e822fb72b372e', + root_epoch: 0, + channels: [{ id: '56bf8b96c1a3768c85444873df507cdbc3275fcbc21996af09e60003f850f85c', name: 'general' }], + relays: ['wss://relay.coinos.io', 'wss://nos.lol'], + name: 'coinos', +}; + +export const EPOCH = 0; |
