draw things
doodl.waow.tech
draw
atproto
2.9 kB
69 lines
1# doodl
2
3draw something, save it as an image blob on your PDS, share it, and use drawings
4as the app's own iconography. the app itself is client-side — no app backend, no
5aggregator. an explore page reads everyone's drawings straight from their PDSes
6via your relay + slingshot, so it's a little stale by design.
7
8Lives at **https://doodl.waow.tech** (static site on your PDS via wisp, custom
9domain on Cloudflare).
10
11Collections:
12
13- `tech.waow.doodl.drawing` — every doodle is an image blob record
14- `tech.waow.doodl.iconset` — singleton `self`, mapping UI slots to drawing
15 strongRefs
16- `tech.waow.doodl.botConsent` — optional singleton `self`; presence lets the
17 doodl bot feature your drawings
18
19## how it works
20
21- **draw** — minimal freehand canvas (pen, color, stroke size, undo, clear),
22 exports PNG. stroke controls live in a bottom sheet so the mobile toolbar stays
23 one row tall.
24- **save** — `com.atproto.repo.uploadBlob` → a `tech.waow.doodl.drawing` record
25 referencing the blob
26- **icons** — settings writes a `tech.waow.doodl.iconset/self` record whose
27 assignments point at drawing records; the app renders those slots with the
28 chosen drawings. any slot in the registry can be drawn over, including nav,
29 toolbar, settings, theme, and stroke controls.
30- **icon sets** — settings can preview someone else's whole iconset across the
31 app. trying one on is local-only until you save it as your own.
32- **auth** — in-browser AT Protocol OAuth, minimal scopes
33 `atproto repo:tech.waow.doodl.drawing?action=create&action=delete
34 repo:tech.waow.doodl.iconset?action=create&action=update
35 repo:tech.waow.doodl.botConsent?action=create&action=update&action=delete
36 blob:*/*`
37- **explore** — UFOs `/records?collection=tech.waow.doodl.drawing`
38 (CORS-enabled, firehose-indexed) for the records, then slingshot
39 `resolveMiniDoc` per repo to build each blob's `getBlob` URL. (a raw relay's
40 `listReposByCollection` has no CORS, so it can't be called from the browser.)
41- **share** — `/l/<did>/<rkey>` preview pages are served by the Cloudflare Worker
42 in `worker/` so crawlers get per-drawing Open Graph image tags
43- **bot** — optional, opt-in, and deliberately small: `bot/` runs the
44 @doodl.waow.tech feature bot for consenting users.
45
46## dev
47
48```bash
49bun install
50bun run dev # localhost uses the atproto loopback OAuth client (no hosted metadata)
51```
52
53## deploy
54
55### one-time: custom domain
56
57```bash
58wispctl domain claim zzstoatzz.io --domain doodl.waow.tech # prints DNS records
59# set those records on the waow.tech Cloudflare zone, then:
60wispctl domain add-site zzstoatzz.io --domain doodl.waow.tech --site doodl
61```
62
63### each release
64
65```bash
66bun run deploy # writes oauth-client-metadata.json, builds, wispctl deploy --spa
67bunx wrangler deploy --config worker/wrangler.jsonc # share/preview worker
68# optional: bunx wrangler deploy --config bot/wrangler.jsonc
69```