@mtcute/dispatcher 0.23.0 → 0.24.2

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.
@@ -1,4 +1,4 @@
1
- import { _RepliedMessageAssertionsByOrigin, Audio, Contact, Dice, Document, Game, Invoice, LiveLocation, Location, MaybeArray, Message, MessageAction, MessageMediaType, Peer, Photo, Poll, RepliedMessageInfo, RepliedMessageOrigin, Sticker, StickerSourceType, StickerType, Story, User, Venue, Video, Voice, WebPage, RawDocument } from '@mtcute/core';
1
+ import { _RepliedMessageAssertionsByOrigin, Audio, Contact, Dice, Document, Game, Invoice, LiveLocation, Location, MaybeArray, Message, MessageAction, MessageMediaType, Peer, Photo, Poll, RepliedMessageInfo, RepliedMessageOrigin, Sticker, StickerSourceType, StickerType, Story, User, Venue, Video, Voice, WebPageMedia, RawDocument } from '@mtcute/core';
2
2
  import { BusinessMessageContext } from '../context/business-message.js';
3
3
  import { MessageContext } from '../index.js';
4
4
  import { Modify, UpdateFilter } from './types.js';
@@ -98,7 +98,7 @@ export declare const game: UpdateFilter<Message, {
98
98
  }>;
99
99
  /** Filter messages containing a web page */
100
100
  export declare const webpage: UpdateFilter<Message, {
101
- media: WebPage;
101
+ media: WebPageMedia;
102
102
  }>;
103
103
  /** Filter messages containing a venue */
104
104
  export declare const venue: UpdateFilter<Message, {
@@ -1,4 +1,4 @@
1
- import { _RepliedMessageAssertionsByOrigin, Audio, Contact, Dice, Document, Game, Invoice, LiveLocation, Location, MaybeArray, Message, MessageAction, MessageMediaType, Peer, Photo, Poll, RepliedMessageInfo, RepliedMessageOrigin, Sticker, StickerSourceType, StickerType, Story, User, Venue, Video, Voice, WebPage, RawDocument } from '@mtcute/core';
1
+ import { _RepliedMessageAssertionsByOrigin, Audio, Contact, Dice, Document, Game, Invoice, LiveLocation, Location, MaybeArray, Message, MessageAction, MessageMediaType, Peer, Photo, Poll, RepliedMessageInfo, RepliedMessageOrigin, Sticker, StickerSourceType, StickerType, Story, User, Venue, Video, Voice, WebPageMedia, RawDocument } from '@mtcute/core';
2
2
  import { BusinessMessageContext } from '../context/business-message.js';
3
3
  import { MessageContext } from '../index.js';
4
4
  import { Modify, UpdateFilter } from './types.js';
@@ -98,7 +98,7 @@ export declare const game: UpdateFilter<Message, {
98
98
  }>;
99
99
  /** Filter messages containing a web page */
100
100
  export declare const webpage: UpdateFilter<Message, {
101
- media: WebPage;
101
+ media: WebPageMedia;
102
102
  }>;
103
103
  /** Filter messages containing a venue */
104
104
  export declare const venue: UpdateFilter<Message, {
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@mtcute/dispatcher",
3
3
  "type": "module",
4
- "version": "0.23.0",
4
+ "version": "0.24.2",
5
5
  "description": "Updates dispatcher and bot framework for @mtcute/client",
6
6
  "license": "MIT",
7
7
  "scripts": {},
8
8
  "dependencies": {
9
- "@mtcute/core": "^0.23.0",
9
+ "@mtcute/core": "^0.24.2",
10
10
  "@fuman/utils": "0.0.14"
11
11
  },
12
12
  "exports": {
package/state/key.cjs CHANGED
@@ -18,6 +18,7 @@ const defaultStateKeyDelegate = (upd) => {
18
18
  case "group":
19
19
  case "supergroup":
20
20
  case "gigagroup":
21
+ case "monoforum":
21
22
  return `${upd.chat.id}_${upd.sender.id}`;
22
23
  default:
23
24
  core.assertNever(upd.chat.chatType);
package/state/key.js CHANGED
@@ -11,6 +11,7 @@ const defaultStateKeyDelegate = (upd) => {
11
11
  case "group":
12
12
  case "supergroup":
13
13
  case "gigagroup":
14
+ case "monoforum":
14
15
  return `${upd.chat.id}_${upd.sender.id}`;
15
16
  default:
16
17
  assertNever(upd.chat.chatType);