Following is a layer: pointers anywhere on the page, and a list of what to follow

A pointer is what it points at, not where it is. What goes out is the
element under it, as a path from <body> with where it sits in each element
on the way down, so over a button it is over the watcher's button however
differently the two windows are laid out. In an SVG the point is in the
SVG's own units, so on the stage it stays on the drawing at any zoom. A
path that half resolves dims at the deepest element both pages share; one
scrolled out of a pane waits at its edge. A press shows as a ring.

The ▾ beside the eye says what you follow, each a switch: tab, frame and
play with speed, loop and marks; selection; timeline rows; onion, tracing
and mat; tool and brush; which panels are shut; panel scroll; pointers.
What you let go of you neither take nor send, so looking around never
moves the party, and taking it back catches up.

The pool and the inspector are both `section.pane`, so a path by first
class put a pointer on the pool whenever one window had it shut. A step
now matches on the whole class list, and falls back to the first class
only for state classes like `on` and `selected`.

All of it lives in `arthur.follow` and `follow/`, switched on by one line
in `arthur.core`. Collab no longer knows parties exist: it keeps a roster
of whatever each peer says about itself, and lets a listener hear the room.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Olive Vaughn 2026-10-11 13:38:01 -04:00
parent 7c637576b2
commit 00e94c025a
10 changed files with 684 additions and 294 deletions

View file

@ -5,7 +5,7 @@ socket is read-only for the document, and a dropped socket cannot lose a write.
PRESENCE, which peers gossip between themselves: all the server does is hand out
a connection id and stamp the sender's identity onto every message, so nobody can
post as somebody else. A party — people following each other — is worked out in
the browsers from that gossip (`arthur.domain.party`); nothing here knows of it.
the browsers from that gossip (`arthur.follow`); nothing here knows of it.
"""
import json
import uuid
@ -33,10 +33,10 @@ def broadcast(project_id, delta, kind="delta"):
class ProjectConsumer(AsyncWebsocketConsumer):
# `state` is who you are and which party you carry, and is remembered for
# the next joiner. `nav` and `cursor` are where a party is looking, and are
# stale the moment the next one is sent, so they are only passed on.
RELAYED = ("state", "nav", "cursor")
# `state` is what each of us says about ourselves, and is remembered for the
# next joiner. The rest are `arthur.follow`'s — where a party is looking —
# and are stale the moment the next is sent, so they are only passed on.
RELAYED = ("state", "nav", "cursor", "scroll") # follow: all but "state"
@property
def room(self):