Changeset 00f669b in Klonkt for src/services
- Timestamp:
- 06/24/2026 03:27:49 PM (3 months ago)
- Branches:
- main
- Children:
- d0cab9d
- Parents:
- d988fa0
- Location:
- src/services
- Files:
-
- 2 edited
-
ActivityPubService.js (modified) (2 diffs)
-
i18n.js (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/services/ActivityPubService.js
rd988fa0 r00f669b 737 737 } 738 738 739 // Notifications inbox: new followers + replies/likes/boosts on this site's posts. 740 export function getNotifications(slug, limit) { 741 const out = []; 742 try { 743 for (const f of db.prepare('SELECT actor_uri, created_at FROM ap_followers WHERE slug = ? ORDER BY created_at DESC LIMIT 50').all(slug)) { 744 out.push({ type: 'follow', handle: deriveHandle(f.actor_uri), url: f.actor_uri, created_at: f.created_at }); 745 } 746 } catch { /* ignore */ } 747 try { 748 const rows = db.prepare(` 749 SELECT i.kind, i.actor_name, i.actor_handle, i.actor_url, i.content, i.created_at, 750 p.slug AS post_slug, p.title AS post_title 751 FROM ap_interactions i LEFT JOIN posts p ON p.id = i.post_id 752 WHERE p.site_id = (SELECT id FROM sites WHERE slug = ?) 753 ORDER BY i.created_at DESC LIMIT 80 754 `).all(slug); 755 for (const r of rows) out.push({ 756 type: r.kind, name: r.actor_name, handle: r.actor_handle, url: r.actor_url, 757 content: r.content, post_slug: r.post_slug, post_title: r.post_title, created_at: r.created_at, 758 }); 759 } catch { /* ignore */ } 760 out.sort((a, b) => new Date(b.created_at) - new Date(a.created_at)); 761 return out.slice(0, limit || 60); 762 } 763 739 764 export default { 740 765 getOrCreateKeys, apWants, sendAP, actorId, noteId, … … 744 769 listOutbox, deliverOutboxDelete, 745 770 webfingerResolve, followActor, unfollowActor, listFollowing, getTimeline, sendInteraction, 771 getNotifications, 746 772 }; -
src/services/i18n.js
rd988fa0 r00f669b 26 26 'nav.language': 'Taal', 27 27 'nav.notifications': 'Meldingen', 28 'notif.title': 'Meldingen', 'notif.empty': 'Nog geen meldingen.', 'notif.someone': 'Iemand', 28 'notif.title': 'Meldingen', 'notif.empty': 'Nog geen meldingen.', 'notif.someone': 'Iemand', 'notif.followed': 'volgt je nu', 'notif.liked': 'likete je post', 'notif.boosted': 'boostte je post', 'notif.replied': 'reageerde op', 29 29 'notif.reply': '{actor} reageerde op je reactie', 'notif.comment': '{actor} reageerde op je post', 'notif.like': '{actor} vindt je post leuk', 30 30 'switch.agenda': 'Agenda', … … 1029 1029 'nav.language': 'Language', 1030 1030 'nav.notifications': 'Notifications', 1031 'notif.title': 'Notifications', 'notif.empty': 'No notifications yet.', 'notif.someone': 'Someone', 1031 'notif.title': 'Notifications', 'notif.empty': 'No notifications yet.', 'notif.someone': 'Someone', 'notif.followed': 'followed you', 'notif.liked': 'liked your post', 'notif.boosted': 'boosted your post', 'notif.replied': 'replied to', 1032 1032 'notif.reply': '{actor} replied to your comment', 'notif.comment': '{actor} commented on your post', 'notif.like': '{actor} liked your post', 1033 1033 'switch.agenda': 'Agenda', … … 2023 2023 'nav.language': 'Sprache', 2024 2024 'nav.notifications': 'Benachrichtigungen', 2025 'notif.title': 'Benachrichtigungen', 'notif.empty': 'Noch keine Benachrichtigungen.', 'notif.someone': 'Jemand', 2025 'notif.title': 'Benachrichtigungen', 'notif.empty': 'Noch keine Benachrichtigungen.', 'notif.someone': 'Jemand', 'notif.followed': 'folgt dir jetzt', 'notif.liked': 'gefällt dein Beitrag', 'notif.boosted': 'teilte deinen Beitrag', 'notif.replied': 'antwortete auf', 2026 2026 'notif.reply': '{actor} hat auf deinen Kommentar geantwortet', 'notif.comment': '{actor} hat deinen Beitrag kommentiert', 'notif.like': '{actor} gefällt dein Beitrag', 2027 2027 'switch.agenda': 'Termine',
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)