add icon, also misc improvments

This commit is contained in:
zach committed 2025-12-30 20:04:53 -07:00
1 parent baf92ef672
commit dc9f172d01
41 files changed
+609 -145

No files matched your search

+22
View File
@@ -0,0 +1,22 @@
class ReactionInfo {
final String targetMessageId;
final String emoji;
ReactionInfo({
required this.targetMessageId,
required this.emoji,
});
}
class ReactionHelper {
/// Parse reaction format: r:[messageId]:[emoji]
static ReactionInfo? parseReaction(String text) {
final regex = RegExp(r'^r:([^:]+):(.+)$');
final match = regex.firstMatch(text);
if (match == null) return null;
return ReactionInfo(
targetMessageId: match.group(1)!,
emoji: match.group(2)!,
);
}
}