| author | Stephen Paul Weber
<singpolyma@singpolyma.net> 2025-05-12 13:32:43 UTC |
| committer | Stephen Paul Weber
<singpolyma@singpolyma.net> 2025-05-12 13:36:17 UTC |
| parent | dae17ef895f3678ad8b8c24fefc56d8ff64df5dd |
| snikket/ChatMessage.hx | +19 | -0 |
diff --git a/snikket/ChatMessage.hx b/snikket/ChatMessage.hx index e815dbe..8ef52ee 100644 --- a/snikket/ChatMessage.hx +++ b/snikket/ChatMessage.hx @@ -130,6 +130,25 @@ class ChatMessage { @HaxeCBridge.noemit public var reactions(default, null): Map<String, Array<Reaction>>; + #if cpp + /** + List of reactions to this message + **/ + public var reactionKeys(get, never): Array<String>; + + @HaxeCBridge.noemit + public function get_reactionKeys() { + return { iterator: reactions.keys }.array(); + } + + /** + Details of a set of reaction to this message + **/ + public function reactionDetails(reactionKey: String): Array<Reaction> { + return reactions[reactionKey] ?? []; + } + #end + /** Body text of this message or NULL **/