From 427eb66162dc3482e3cfba2613aa87b06f5340d7 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Sun, 6 Dec 2026 12:35:13 -0700 Subject: Gift sender chip: the hat isn't cut off, the face waits for the real picture, and no "Claiming it follows them" line. "Hat cut off here and also the avatar showed a punk first before the right one appeared can we fix that so it loads the right avatar right away? Also let's remove the text about how claiming follows" (Adam, 2026-12-06, a 5 CAD gift from him on the claim screen). The chip's `.zap-chip > span { overflow: hidden }` (meant for the name) also clipped the .hat-wrap span; it now skips .hat-wrap. A small face gave up after 1 s and drew punk art while the sender's profile was still loading; profileChip's new 'wait' size makes the face wait for the lookup like a profile page's does (quiet circle, then the real picture; punk only if they have none). The follows line is gone from the screen and all locales (claiming still follows the sender). gift-from-test checks all three; features-smoke passes. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01VMan6WoqaQDYdpWkatPCar --- src/features/gifts.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/features/gifts.js') diff --git a/src/features/gifts.js b/src/features/gifts.js index 30b8d5e..49b18db 100644 --- a/src/features/gifts.js +++ b/src/features/gifts.js @@ -185,14 +185,13 @@ export function giftsFeature(ctx) { } const GIFT_ANON_KEY = 'giftAnon'; const giftAnon = () => { try { return localStorage.getItem(GIFT_ANON_KEY) === '1'; } catch { return false; } }; - // who sent it, and that claiming follows them + // who sent it const giftFromView = () => (ui.claimFrom ? h('div', { class: 'col', style: 'align-items:center;gap:4px' }, h('div', { class: 'row gap6', style: 'align-items:center;justify-content:center' }, h('span', { class: 'small muted' }, t('giftFrom')), - hook('profileChip', ui.claimFrom, undefined, () => {}) - || h('span', { class: 'small mono' }, (npubOf(ui.claimFrom) || '').slice(0, 16) + '…')), - h('div', { class: 'small faint' }, t('giftClaimFollows'))) + hook('profileChip', ui.claimFrom, 'wait', () => {}) + || h('span', { class: 'small mono' }, (npubOf(ui.claimFrom) || '').slice(0, 16) + '…'))) : null); // the sender's words, quoted above the amount wherever the gift is opened const giftNoteView = () => (ui.claimNote -- cgit v1.2.3