From 161adb250e4273d0bcaa160516bc950f5f46310f Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Mon, 3 Aug 2026 07:42:24 -0700 Subject: Self-host the punks; skipping avatar still publishes your punk MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit coinos.io serves 502 for a third of the punk set (both the numbered and hash endpoints), which is why a default avatar could come up blank. The 64 webps now ship with the app (53 salvaged, 11 gaps filled with donors) and every reference is same-origin. Skipping the avatar step publishes the deterministic punk as the kind-0 picture — your face is the same on every nostr client. Success screen: checkmark now sits below the title, bigger. Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01Wvj4aoeMZwA7VUGdJP9Swi --- src/recipient-search.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/recipient-search.js') diff --git a/src/recipient-search.js b/src/recipient-search.js index 2594488..553673e 100644 --- a/src/recipient-search.js +++ b/src/recipient-search.js @@ -13,8 +13,10 @@ import { queryOn, parseNostrPubkey, npubOf, PROFILE_RELAYS } from './nostr.js'; // coinos punks: the deterministic default avatar — same formula the coinos // app uses (last byte of the pubkey picks one of 64). Initials show through // if the image can't load (offline). +// Self-hosted (dist/punks) — coinos.io's own copies 502 for a third of the +// set. Same deterministic formula the coinos app uses. export const punkUrl = (pk) => - `https://coinos.io/api/public/punks/${Math.floor((parseInt(pk.slice(-2), 16) / 256) * 64) + 1}.webp`; + `punks/${Math.floor((parseInt(pk.slice(-2), 16) / 256) * 64) + 1}.webp`; export const fallbackAvatar = (h, pk, name, cls) => h('div', { class: cls + ' fallback' }, -- cgit v1.2.3