diff options
Diffstat (limited to 'src/features')
| -rw-r--r-- | src/features/gifts.js | 7 | ||||
| -rw-r--r-- | src/features/messages.js | 6 |
2 files changed, 7 insertions, 6 deletions
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 diff --git a/src/features/messages.js b/src/features/messages.js index f2a3f8e..afb8a0a 100644 --- a/src/features/messages.js +++ b/src/features/messages.js @@ -4116,7 +4116,7 @@ export function messagesFeature(ctx) { const sendFace = cls.includes('send-avatar'); // A profile page's own face is the same: the one big picture on the // page, never punk art while that person's lookup is still running. - const pageFace = cls.includes('profile-avatar'); + const pageFace = cls.includes('profile-avatar') || cls.includes('wait-face'); const waiting = (p === null || (p && p.loading && !p.picture)) && (sendFace || pageFace ? p === null || profQueue.has(pk) || profInFlight.has(pk) || fullInFlight.has(pk) : faceWaiting(pk)); const node = feedPaint && !p.picture @@ -20013,13 +20013,15 @@ export function messagesFeature(ctx) { async saveProfileDraft(e) { const id = await identity(); return withKind0Lock(() => saveProfileNow(id, { name: '', about: '', picture: '', banner: '', ...e })); }, // opens the profile, unless the caller has a step to take first (the // Accounts page switches to that identity before showing its profile) + // size 'wait': a small chip whose face stays blank until that person's + // lookup settles, never punk art first (a gift's sender, 2026-12-06) profileChip(pk, size, onOpen) { const big = size === 'lg'; return h(big ? 'button' : 'span', { class: big ? 'send-person' : 'zap-chip', type: big ? 'button' : undefined, onClick: (e) => { e.stopPropagation(); if (onOpen) onOpen(); else openProfile(pk); }, - }, avatar(pk, 'chat-avatar ' + (big ? 'send-avatar' : 'mini'), false), + }, avatar(pk, 'chat-avatar ' + (big ? 'send-avatar' : size === 'wait' ? 'mini wait-face' : 'mini'), false), h('span', { class: big ? '' : 'small' }, displayName(pk))); }, // a gift link names its sender: sign its template as us (gifts.js) |
