feat(chat/notif): single hover action-pill; sender DP in desktop+mobile notifications
- Message actions (reply/react/edit/delete) consolidated into ONE hover pill anchored to the
bubble's top-right, overlapping it so on short messages the icons no longer float off into
empty space and vanish before you can click.
- Desktop toast + mobile(FCM)/web-background push now show the sender's real DP:
* renderer passes the DP URL through; desktop shell downloads it for the toast icon
(canvas-drawing an external DP tainted it → initials). Desktop bumped to 0.1.4.
* DM push payload carries icon=sender avatar; sw.js already uses it (web background),
sendFcm sets notification.image (Android).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
+3
-1
@@ -53,7 +53,9 @@ async function fcmAccessToken() {
|
||||
}
|
||||
async function sendFcm(token, payload) {
|
||||
const at = await fcmAccessToken();
|
||||
const msg = { message: { token, notification: { title: payload.title || 'Biz Connect', body: payload.body || '' }, data: strData(payload.data || {}) } };
|
||||
const notif = { title: payload.title || 'Biz Connect', body: payload.body || '' };
|
||||
if (payload.icon) notif.image = payload.icon; // sender/group DP shown by Android
|
||||
const msg = { message: { token, notification: notif, data: strData(payload.data || {}) } };
|
||||
const res = await fetch('https://fcm.googleapis.com/v1/projects/' + fcmSA.project_id + '/messages:send', {
|
||||
method: 'POST', headers: { Authorization: 'Bearer ' + at, 'Content-Type': 'application/json' }, body: JSON.stringify(msg),
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user