swicg / swicg/activitypub-e2ee
Emoji reactions
Nobody has claimed this yet.
- Dominant language
- HTML
- Stars
- 78
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Description
Emoji reactions seem pretty essential for our use cases, so I'd like to propose a simple approach based on FEP-c0e0: https://fediverse.codeberg.page/fep/fep/c0e0/
Like with emoji in content for simple reactions:
{
"@context": [
"https://www.w3.org/ns/activitystreams"
],
"actor": "https://alice.social/users/alice",
"content": "🔥",
"id": "https://alice.social/activities/65379d47-b7aa-4ef6-8e4f-41149dda1d2c",
"object": "https://bob.social/objects/57caeb99-424c-4692-b74f-0a6682050932",
"to": [
"https://alice.social/users/alice/followers",
"https://bob.social/users/bob"
],
"type": "Like"
}
EmojiReact activity when using custom emoji:
{
"@context": [
"https://www.w3.org/ns/activitystreams",
{
"toot": "http://joinmastodon.org/ns#",
"Emoji": "toot:Emoji",
"litepub": "http://litepub.social/ns#",
"EmojiReact": "litepub:EmojiReact"
}
],
"actor": "https://alice.social/users/alice",
"content": ":blobwtfnotlikethis:",
"id": "https://alice.social/activities/65379d47-b7aa-4ef6-8e4f-41149dda1d2c",
"object": "https://bob.social/objects/57caeb99-424c-4692-b74f-0a6682050932",
"tag": [
{
"icon": {
"mediaType": "image/png",
"type": "Image",
"url": "https://alice.social/files/1b0510f2-1fb4-43f5-a399-10053bbd8f0f"
},
"id": "https://alice.social/emojis/blobwtfnotlikethis",
"name": ":blobwtfnotlikethis:",
"type": "Emoji",
"updated": "2024-02-07T02:21:46.497Z"
}
],
"to": [
"https://alice.social/users/alice/followers",
"https://bob.social/users/bob"
],
"type": "EmojiReact"
}
I'd suggest adding these examples to the spec along with something along these lines:
Clients MAY send reactions using
Like, optionally including a single Unicode emoji incontent. Clients MAY send custom emoji reactions usingEmojiReact.Upon receiving a
LikeorEmojiReact, clients MUST indicate that the object has been reacted to, and SHOULD display the actors and aggregated counts per emoji.If a
Likeincludes an emoji incontent, clients SHOULD render it as the reaction. ForEmojiReact, clients SHOULD render the referenced emoji, or MAY fall back tocontentor a generic reaction if needed.Clients MUST support undoing reactions via
Undo, where theobjectis the original reaction activity ID (i.e., the encrypted reaction activity, not the transport wrapper).
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the existing specification and the linked FEP-c0e0, then compare its reaction guidance with the Like and EmojiReact examples in this issue. Done means the spec includes the proposed examples, reaction and aggregation requirements, custom-emoji fallback behavior, and Undo semantics for the original reaction activity.
Written by the indexing model from the issue text.
Assessment
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100