multichat-ts 0.0.5 → 0.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/twitch.js CHANGED
@@ -257,6 +257,10 @@ function parseIRCLine(line) {
257
257
  componentIndex++;
258
258
  }
259
259
  }
260
+ if (params[0])
261
+ params[0] = String.raw `${params[0]}`.replaceAll(new RegExp(`\\\\.+ACTION (.*)\\\\.+`, 'g'), function (_original, text_only) {
262
+ return text_only;
263
+ });
260
264
  const tags = raw_tags_component ? parseTags(raw_tags_component, command) : undefined;
261
265
  return {
262
266
  channel,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "multichat-ts",
3
- "version": "0.0.5",
3
+ "version": "0.0.6",
4
4
  "type": "module",
5
5
  "description": "Receive type-safe realtime events for chat-related messages on multiple platforms (Twitch, Kick)",
6
6
  "repository": {
package/src/twitch.ts CHANGED
@@ -324,6 +324,15 @@ function parseIRCLine(line: string): IRC_Message {
324
324
  }
325
325
  }
326
326
 
327
+ // TODO: handle message actions like "/me"
328
+ if (params[0])
329
+ params[0] = String.raw`${params[0]}`.replaceAll(
330
+ new RegExp(`\\\\.+ACTION (.*)\\\\.+`, 'g'),
331
+ function (_original, text_only) {
332
+ return text_only;
333
+ },
334
+ );
335
+
327
336
  const tags = raw_tags_component ? parseTags(raw_tags_component, command) : undefined;
328
337
 
329
338
  return {