@types/telegram-web-app 9.0.0 → 9.1.0

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.
@@ -8,8 +8,8 @@ This package contains type definitions for telegram-web-app (https://telegram.or
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/telegram-web-app.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Tue, 29 Jul 2025 15:04:17 GMT
11
+ * Last updated: Tue, 25 Nov 2025 10:39:08 GMT
12
12
  * Dependencies: none
13
13
 
14
14
  # Credits
15
- These definitions were written by [KnorpelSenf](https://github.com/KnorpelSenf), [MKRhere](https://github.com/MKRhere), and [deptyped](https://github.com/deptyped).
15
+ These definitions were written by [KnorpelSenf](https://github.com/KnorpelSenf), [MKRhere](https://github.com/MKRhere), [deptyped](https://github.com/deptyped), and [sidorko](https://github.com/sidorko).
@@ -350,6 +350,13 @@ export interface WebApp {
350
350
  * called and the invoice status will be passed as the first argument.
351
351
  */
352
352
  openInvoice(url: string, callback: (status: "paid" | "cancelled" | "failed" | "pending") => void): void;
353
+ /**
354
+ * **Bot API 9.1+**
355
+ *
356
+ * A method that hides the on-screen keyboard, if it is currently visible.
357
+ * Does nothing if the keyboard is not active.
358
+ */
359
+ hideKeyboard(): void;
353
360
  /**
354
361
  * A method that shows a native popup described by the params argument of
355
362
  * the type PopupParams. The Web App will receive the event popupClosed when
@@ -795,23 +802,31 @@ export interface BackButton {
795
802
  */
796
803
  isVisible: boolean;
797
804
  /**
798
- * A method that sets the button press event handler. An alias for
799
- * Telegram.WebApp.onEvent('backButtonClicked', callback)
805
+ * **Bot API 6.1+**
806
+ *
807
+ * A method that sets the button press event handler.
808
+ * An alias for `Telegram.WebApp.onEvent('backButtonClicked', callback)`
800
809
  */
801
810
  onClick(callback: () => void): BackButton;
802
811
  /**
803
- * A method that removes the button press event handler. An alias for
804
- * Telegram.WebApp.offEvent('backButtonClicked', callback)
812
+ * **Bot API 6.1+**
813
+ *
814
+ * A method that removes the button press event handler.
815
+ * An alias for `Telegram.WebApp.offEvent('backButtonClicked', callback)`
805
816
  */
806
817
  offClick(callback: () => void): BackButton;
807
818
  /**
819
+ * **Bot API 6.1+**
820
+ *
808
821
  * A method to make the button active and visible.
809
822
  */
810
- show(): void;
823
+ show(): BackButton;
811
824
  /**
825
+ * **Bot API 6.1+**
826
+ *
812
827
  * A method to hide the button.
813
828
  */
814
- hide(): void;
829
+ hide(): BackButton;
815
830
  }
816
831
 
817
832
  /**
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/telegram-web-app",
3
- "version": "9.0.0",
3
+ "version": "9.1.0",
4
4
  "description": "TypeScript definitions for telegram-web-app",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/telegram-web-app",
6
6
  "license": "MIT",
@@ -19,6 +19,11 @@
19
19
  "name": "deptyped",
20
20
  "githubUsername": "deptyped",
21
21
  "url": "https://github.com/deptyped"
22
+ },
23
+ {
24
+ "name": "sidorko",
25
+ "githubUsername": "sidorko",
26
+ "url": "https://github.com/sidorko"
22
27
  }
23
28
  ],
24
29
  "main": "",
@@ -31,6 +36,6 @@
31
36
  "scripts": {},
32
37
  "dependencies": {},
33
38
  "peerDependencies": {},
34
- "typesPublisherContentHash": "d7b82247812d99fcf54be15de02ee34a9f8303892f0fc6e52b1927018a8f4535",
35
- "typeScriptVersion": "5.1"
39
+ "typesPublisherContentHash": "f446f17f32fcc8ca83f3118a6a869a8e164f6b95797cbd6b80fbddab18adedfe",
40
+ "typeScriptVersion": "5.2"
36
41
  }