gramio 0.4.1 → 0.4.3

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/index.d.cts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { CallbackData } from '@gramio/callback-data';
2
2
  export * from '@gramio/callback-data';
3
- import { Context, UpdateName, MaybeArray, ContextType, BotLike, Attachment } from '@gramio/contexts';
3
+ import { Context, UpdateName, ContextType, BotLike, Attachment } from '@gramio/contexts';
4
4
  export * from '@gramio/contexts';
5
5
  import { APIMethods, TelegramResponseParameters, TelegramAPIResponseError, TelegramUser, APIMethodParams, APIMethodReturn, SetWebhookParams, TelegramUpdate, TelegramReactionTypeEmojiEmoji, SetMyCommandsParams, TelegramBotCommand } from '@gramio/types';
6
6
  export * from '@gramio/types';
@@ -26,6 +26,8 @@ declare class TelegramError<T extends keyof APIMethods> extends Error {
26
26
  constructor(error: TelegramAPIResponseError, method: T, params: MaybeSuppressedParams<T>);
27
27
  }
28
28
 
29
+ type MaybeArray<T> = T | T[] | ReadonlyArray<T>;
30
+
29
31
  /** Base-composer without chainable type-safety */
30
32
  declare class Composer {
31
33
  protected composer: Composer$1<Context<AnyBot> & {
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { CallbackData } from '@gramio/callback-data';
2
2
  export * from '@gramio/callback-data';
3
- import { Context, UpdateName, MaybeArray, ContextType, BotLike, Attachment } from '@gramio/contexts';
3
+ import { Context, UpdateName, ContextType, BotLike, Attachment } from '@gramio/contexts';
4
4
  export * from '@gramio/contexts';
5
5
  import { APIMethods, TelegramResponseParameters, TelegramAPIResponseError, TelegramUser, APIMethodParams, APIMethodReturn, SetWebhookParams, TelegramUpdate, TelegramReactionTypeEmojiEmoji, SetMyCommandsParams, TelegramBotCommand } from '@gramio/types';
6
6
  export * from '@gramio/types';
@@ -26,6 +26,8 @@ declare class TelegramError<T extends keyof APIMethods> extends Error {
26
26
  constructor(error: TelegramAPIResponseError, method: T, params: MaybeSuppressedParams<T>);
27
27
  }
28
28
 
29
+ type MaybeArray<T> = T | T[] | ReadonlyArray<T>;
30
+
29
31
  /** Base-composer without chainable type-safety */
30
32
  declare class Composer {
31
33
  protected composer: Composer$1<Context<AnyBot> & {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "gramio",
3
3
  "type": "module",
4
- "version": "0.4.1",
4
+ "version": "0.4.3",
5
5
  "description": "Powerful, extensible and really type-safe Telegram Bot API framework",
6
6
  "main": "dist/index.cjs",
7
7
  "module": "dist/index.js",