@mtkruto/node 0.137.0 → 0.139.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.
- package/esm/3_types.d.ts +2 -3
- package/esm/3_types.d.ts.map +1 -1
- package/esm/3_types.js +2 -3
- package/esm/client/0_markdown.d.ts.map +1 -1
- package/esm/client/0_markdown.js +1 -3
- package/esm/client/0_params.d.ts +6 -0
- package/esm/client/0_params.d.ts.map +1 -1
- package/esm/client/1_client_generic.d.ts +14 -9
- package/esm/client/1_client_generic.d.ts.map +1 -1
- package/esm/client/1_client_generic.js +1 -3
- package/esm/client/1_client_plain.d.ts +2 -6
- package/esm/client/1_client_plain.d.ts.map +1 -1
- package/esm/client/1_client_plain.js +1 -3
- package/esm/client/1_types.d.ts +1 -0
- package/esm/client/1_types.d.ts.map +1 -1
- package/esm/client/2_bot_info_manager.js +1 -1
- package/esm/client/2_business_connection_manager.js +1 -1
- package/esm/client/2_file_manager.d.ts.map +1 -1
- package/esm/client/2_file_manager.js +2 -0
- package/esm/client/2_payment_manager.js +1 -1
- package/esm/client/2_reaction_manager.js +4 -4
- package/esm/client/2_story_album_manager.d.ts.map +1 -1
- package/esm/client/2_story_album_manager.js +1 -2
- package/esm/client/2_translations_manager.js +2 -2
- package/esm/client/2_update_manager.js +1 -1
- package/esm/client/3_account_manager.d.ts +2 -1
- package/esm/client/3_account_manager.d.ts.map +1 -1
- package/esm/client/3_account_manager.js +11 -4
- package/esm/client/3_filters.d.ts +94 -18
- package/esm/client/3_filters.d.ts.map +1 -1
- package/esm/client/3_message_manager.d.ts.map +1 -1
- package/esm/client/3_message_manager.js +16 -19
- package/esm/client/3_video_chat_manager.js +1 -1
- package/esm/client/4_callback_query_manager.js +1 -1
- package/esm/client/4_chat_manager.d.ts.map +1 -1
- package/esm/client/4_chat_manager.js +4 -5
- package/esm/client/4_context.d.ts +154 -462
- package/esm/client/4_context.d.ts.map +1 -1
- package/esm/client/4_context.js +220 -505
- package/esm/client/4_inline_query_manager.js +3 -3
- package/esm/client/4_link_preview_manager.js +1 -1
- package/esm/client/4_poll_manager.js +2 -2
- package/esm/client/4_story_manager.js +5 -5
- package/esm/client/6_client.d.ts +13 -14
- package/esm/client/6_client.d.ts.map +1 -1
- package/esm/client/6_client.js +26 -14
- package/esm/client/6_client_dispatcher.d.ts +14 -9
- package/esm/client/6_client_dispatcher.d.ts.map +1 -1
- package/esm/client/6_client_dispatcher.js +15 -6
- package/esm/session/1_session.d.ts +2 -6
- package/esm/session/1_session.d.ts.map +1 -1
- package/esm/types/0_bot_token_check_result.d.ts +0 -1
- package/esm/types/0_bot_token_check_result.d.ts.map +1 -1
- package/esm/types/0_callback_query_question.d.ts +0 -3
- package/esm/types/0_callback_query_question.d.ts.map +1 -1
- package/esm/types/0_chat_action_type.d.ts +0 -13
- package/esm/types/0_chat_action_type.d.ts.map +1 -1
- package/esm/types/0_code_check_result.d.ts +0 -3
- package/esm/types/0_code_check_result.d.ts.map +1 -1
- package/esm/types/0_emoji_status.d.ts +0 -2
- package/esm/types/0_emoji_status.d.ts.map +1 -1
- package/esm/types/0_gift_component_rarity.d.ts +0 -5
- package/esm/types/0_gift_component_rarity.d.ts.map +1 -1
- package/esm/types/0_id.d.ts +1 -3
- package/esm/types/0_id.d.ts.map +1 -1
- package/{script/types/1_inline_query_result_button.d.ts → esm/types/0_inline_query_result_button.d.ts} +3 -4
- package/esm/types/0_inline_query_result_button.d.ts.map +1 -0
- package/esm/types/0_input_emoji_status.d.ts +0 -2
- package/esm/types/0_input_emoji_status.d.ts.map +1 -1
- package/esm/types/0_password_check_result.d.ts +0 -2
- package/esm/types/0_password_check_result.d.ts.map +1 -1
- package/esm/types/0_reaction.d.ts +0 -3
- package/esm/types/0_reaction.d.ts.map +1 -1
- package/esm/types/0_user_status.d.ts +0 -5
- package/esm/types/0_user_status.d.ts.map +1 -1
- package/esm/types/0_video_chat.d.ts +0 -3
- package/esm/types/0_video_chat.d.ts.map +1 -1
- package/esm/types/1_available_reactions.d.ts +0 -3
- package/esm/types/1_available_reactions.d.ts.map +1 -1
- package/esm/types/1_bot_command_scope.d.ts +0 -7
- package/esm/types/1_bot_command_scope.d.ts.map +1 -1
- package/esm/types/1_chat_p.d.ts +1 -7
- package/esm/types/1_chat_p.d.ts.map +1 -1
- package/esm/types/1_inline_keyboard_button.d.ts +25 -42
- package/esm/types/1_inline_keyboard_button.d.ts.map +1 -1
- package/esm/types/1_inline_keyboard_button.js +57 -64
- package/esm/types/1_input_gift.d.ts +0 -3
- package/esm/types/1_input_gift.d.ts.map +1 -1
- package/esm/types/1_input_story_content.d.ts +2 -2
- package/esm/types/1_input_story_content.d.ts.map +1 -1
- package/esm/types/1_keyboard_button.d.ts +33 -34
- package/esm/types/1_keyboard_button.d.ts.map +1 -1
- package/esm/types/1_keyboard_button.js +81 -88
- package/esm/types/2_chat.d.ts +1 -3
- package/esm/types/2_chat.d.ts.map +1 -1
- package/esm/types/2_chat_member.d.ts +6 -24
- package/esm/types/2_chat_member.d.ts.map +1 -1
- package/esm/types/2_message_entity.d.ts +0 -20
- package/esm/types/2_message_entity.d.ts.map +1 -1
- package/esm/types/{0_mini_app_button_info.js → 2_profile_photo_list.d.ts} +10 -2
- package/esm/types/2_profile_photo_list.d.ts.map +1 -0
- package/esm/types/{0_keyboard_button_poll_type.d.ts → 2_profile_photo_list.js} +6 -5
- package/esm/types/2_reply_markup.d.ts +4 -12
- package/esm/types/2_reply_markup.d.ts.map +1 -1
- package/esm/types/2_reply_markup.js +13 -17
- package/esm/types/2_star_transaction_peer.d.ts +0 -8
- package/esm/types/2_star_transaction_peer.d.ts.map +1 -1
- package/esm/types/2_story_album_icon.d.ts +0 -2
- package/esm/types/2_story_album_icon.d.ts.map +1 -1
- package/esm/types/2_story_content.d.ts +3 -4
- package/esm/types/2_story_content.d.ts.map +1 -1
- package/esm/types/2_story_content.js +3 -3
- package/esm/types/2_story_privacy.d.ts +6 -7
- package/esm/types/2_story_privacy.d.ts.map +1 -1
- package/esm/types/2_story_privacy.js +23 -20
- package/esm/types/3_checklist_item.d.ts +2 -8
- package/esm/types/3_checklist_item.d.ts.map +1 -1
- package/esm/types/3_forward_header.d.ts +0 -5
- package/esm/types/3_forward_header.d.ts.map +1 -1
- package/esm/types/3_gift_upgraded_component.d.ts +0 -4
- package/esm/types/3_gift_upgraded_component.d.ts.map +1 -1
- package/esm/types/3_input_media.d.ts +10 -20
- package/esm/types/3_input_media.d.ts.map +1 -1
- package/esm/types/4_gift.d.ts +0 -2
- package/esm/types/4_gift.d.ts.map +1 -1
- package/esm/types/4_reply_to.d.ts +6 -14
- package/esm/types/4_reply_to.d.ts.map +1 -1
- package/esm/types/5_link_preview.d.ts +2 -18
- package/esm/types/5_link_preview.d.ts.map +1 -1
- package/esm/types/6_message.d.ts +90 -179
- package/esm/types/6_message.d.ts.map +1 -1
- package/esm/types/6_message.js +104 -120
- package/esm/types/6_message_content.d.ts +0 -5
- package/esm/types/6_message_content.d.ts.map +1 -1
- package/esm/types/7_inline_query_result.d.ts +10 -47
- package/esm/types/7_inline_query_result.d.ts.map +1 -1
- package/esm/types/7_inline_query_result.js +219 -152
- package/esm/types/8_update.d.ts +58 -105
- package/esm/types/8_update.d.ts.map +1 -1
- package/esm/utilities/0_int.d.ts +1 -3
- package/esm/utilities/0_int.d.ts.map +1 -1
- package/package.json +1 -1
- package/script/3_types.d.ts +2 -3
- package/script/3_types.d.ts.map +1 -1
- package/script/3_types.js +2 -3
- package/script/client/0_markdown.d.ts.map +1 -1
- package/script/client/0_markdown.js +1 -3
- package/script/client/0_params.d.ts +6 -0
- package/script/client/0_params.d.ts.map +1 -1
- package/script/client/1_client_generic.d.ts +14 -9
- package/script/client/1_client_generic.d.ts.map +1 -1
- package/script/client/1_client_generic.js +1 -3
- package/script/client/1_client_plain.d.ts +2 -6
- package/script/client/1_client_plain.d.ts.map +1 -1
- package/script/client/1_client_plain.js +1 -3
- package/script/client/1_types.d.ts +1 -0
- package/script/client/1_types.d.ts.map +1 -1
- package/script/client/2_bot_info_manager.js +1 -1
- package/script/client/2_business_connection_manager.js +1 -1
- package/script/client/2_file_manager.d.ts.map +1 -1
- package/script/client/2_file_manager.js +2 -0
- package/script/client/2_payment_manager.js +1 -1
- package/script/client/2_reaction_manager.js +4 -4
- package/script/client/2_story_album_manager.d.ts.map +1 -1
- package/script/client/2_story_album_manager.js +1 -2
- package/script/client/2_translations_manager.js +2 -2
- package/script/client/2_update_manager.js +1 -1
- package/script/client/3_account_manager.d.ts +2 -1
- package/script/client/3_account_manager.d.ts.map +1 -1
- package/script/client/3_account_manager.js +9 -2
- package/script/client/3_filters.d.ts +94 -18
- package/script/client/3_filters.d.ts.map +1 -1
- package/script/client/3_message_manager.d.ts.map +1 -1
- package/script/client/3_message_manager.js +15 -18
- package/script/client/3_video_chat_manager.js +1 -1
- package/script/client/4_callback_query_manager.js +1 -1
- package/script/client/4_chat_manager.d.ts.map +1 -1
- package/script/client/4_chat_manager.js +4 -5
- package/script/client/4_context.d.ts +154 -462
- package/script/client/4_context.d.ts.map +1 -1
- package/script/client/4_context.js +220 -505
- package/script/client/4_inline_query_manager.js +3 -3
- package/script/client/4_link_preview_manager.js +1 -1
- package/script/client/4_poll_manager.js +2 -2
- package/script/client/4_story_manager.js +5 -5
- package/script/client/6_client.d.ts +13 -14
- package/script/client/6_client.d.ts.map +1 -1
- package/script/client/6_client.js +25 -13
- package/script/client/6_client_dispatcher.d.ts +14 -9
- package/script/client/6_client_dispatcher.d.ts.map +1 -1
- package/script/client/6_client_dispatcher.js +15 -6
- package/script/session/1_session.d.ts +2 -6
- package/script/session/1_session.d.ts.map +1 -1
- package/script/types/0_bot_token_check_result.d.ts +0 -1
- package/script/types/0_bot_token_check_result.d.ts.map +1 -1
- package/script/types/0_callback_query_question.d.ts +0 -3
- package/script/types/0_callback_query_question.d.ts.map +1 -1
- package/script/types/0_chat_action_type.d.ts +0 -13
- package/script/types/0_chat_action_type.d.ts.map +1 -1
- package/script/types/0_code_check_result.d.ts +0 -3
- package/script/types/0_code_check_result.d.ts.map +1 -1
- package/script/types/0_emoji_status.d.ts +0 -2
- package/script/types/0_emoji_status.d.ts.map +1 -1
- package/script/types/0_gift_component_rarity.d.ts +0 -5
- package/script/types/0_gift_component_rarity.d.ts.map +1 -1
- package/script/types/0_id.d.ts +1 -3
- package/script/types/0_id.d.ts.map +1 -1
- package/{esm/types/1_inline_query_result_button.d.ts → script/types/0_inline_query_result_button.d.ts} +3 -4
- package/script/types/0_inline_query_result_button.d.ts.map +1 -0
- package/script/types/0_input_emoji_status.d.ts +0 -2
- package/script/types/0_input_emoji_status.d.ts.map +1 -1
- package/script/types/0_password_check_result.d.ts +0 -2
- package/script/types/0_password_check_result.d.ts.map +1 -1
- package/script/types/0_reaction.d.ts +0 -3
- package/script/types/0_reaction.d.ts.map +1 -1
- package/script/types/0_user_status.d.ts +0 -5
- package/script/types/0_user_status.d.ts.map +1 -1
- package/script/types/0_video_chat.d.ts +0 -3
- package/script/types/0_video_chat.d.ts.map +1 -1
- package/script/types/1_available_reactions.d.ts +0 -3
- package/script/types/1_available_reactions.d.ts.map +1 -1
- package/script/types/1_bot_command_scope.d.ts +0 -7
- package/script/types/1_bot_command_scope.d.ts.map +1 -1
- package/script/types/1_chat_p.d.ts +1 -7
- package/script/types/1_chat_p.d.ts.map +1 -1
- package/script/types/1_inline_keyboard_button.d.ts +25 -42
- package/script/types/1_inline_keyboard_button.d.ts.map +1 -1
- package/script/types/1_inline_keyboard_button.js +57 -64
- package/script/types/1_input_gift.d.ts +0 -3
- package/script/types/1_input_gift.d.ts.map +1 -1
- package/script/types/1_input_story_content.d.ts +2 -2
- package/script/types/1_input_story_content.d.ts.map +1 -1
- package/script/types/1_keyboard_button.d.ts +33 -34
- package/script/types/1_keyboard_button.d.ts.map +1 -1
- package/script/types/1_keyboard_button.js +81 -88
- package/script/types/2_chat.d.ts +1 -3
- package/script/types/2_chat.d.ts.map +1 -1
- package/script/types/2_chat_member.d.ts +6 -24
- package/script/types/2_chat_member.d.ts.map +1 -1
- package/script/types/2_message_entity.d.ts +0 -20
- package/script/types/2_message_entity.d.ts.map +1 -1
- package/script/types/{0_keyboard_button_poll_type.d.ts → 2_profile_photo_list.d.ts} +10 -5
- package/script/types/2_profile_photo_list.d.ts.map +1 -0
- package/script/types/{0_mini_app_button_info.js → 2_profile_photo_list.js} +7 -3
- package/script/types/2_reply_markup.d.ts +4 -12
- package/script/types/2_reply_markup.d.ts.map +1 -1
- package/script/types/2_reply_markup.js +13 -17
- package/script/types/2_star_transaction_peer.d.ts +0 -8
- package/script/types/2_star_transaction_peer.d.ts.map +1 -1
- package/script/types/2_story_album_icon.d.ts +0 -2
- package/script/types/2_story_album_icon.d.ts.map +1 -1
- package/script/types/2_story_content.d.ts +3 -4
- package/script/types/2_story_content.d.ts.map +1 -1
- package/script/types/2_story_content.js +3 -3
- package/script/types/2_story_privacy.d.ts +6 -7
- package/script/types/2_story_privacy.d.ts.map +1 -1
- package/script/types/2_story_privacy.js +23 -20
- package/script/types/3_checklist_item.d.ts +2 -8
- package/script/types/3_checklist_item.d.ts.map +1 -1
- package/script/types/3_forward_header.d.ts +0 -5
- package/script/types/3_forward_header.d.ts.map +1 -1
- package/script/types/3_gift_upgraded_component.d.ts +0 -4
- package/script/types/3_gift_upgraded_component.d.ts.map +1 -1
- package/script/types/3_input_media.d.ts +10 -20
- package/script/types/3_input_media.d.ts.map +1 -1
- package/script/types/4_gift.d.ts +0 -2
- package/script/types/4_gift.d.ts.map +1 -1
- package/script/types/4_reply_to.d.ts +6 -14
- package/script/types/4_reply_to.d.ts.map +1 -1
- package/script/types/5_link_preview.d.ts +2 -18
- package/script/types/5_link_preview.d.ts.map +1 -1
- package/script/types/6_message.d.ts +90 -179
- package/script/types/6_message.d.ts.map +1 -1
- package/script/types/6_message.js +105 -121
- package/script/types/6_message_content.d.ts +0 -5
- package/script/types/6_message_content.d.ts.map +1 -1
- package/script/types/7_inline_query_result.d.ts +10 -47
- package/script/types/7_inline_query_result.d.ts.map +1 -1
- package/script/types/7_inline_query_result.js +219 -152
- package/script/types/8_update.d.ts +58 -105
- package/script/types/8_update.d.ts.map +1 -1
- package/script/utilities/0_int.d.ts +1 -3
- package/script/utilities/0_int.d.ts.map +1 -1
- package/esm/types/0_keyboard_button_poll_type.d.ts.map +0 -1
- package/esm/types/0_mini_app_button_info.d.ts +0 -26
- package/esm/types/0_mini_app_button_info.d.ts.map +0 -1
- package/esm/types/1_inline_query_result_button.d.ts.map +0 -1
- package/esm/types/1_inline_query_result_button.js +0 -20
- package/script/types/0_keyboard_button_poll_type.d.ts.map +0 -1
- package/script/types/0_mini_app_button_info.d.ts +0 -26
- package/script/types/0_mini_app_button_info.d.ts.map +0 -1
- package/script/types/1_inline_query_result_button.d.ts.map +0 -1
- package/script/types/1_inline_query_result_button.js +0 -21
- /package/esm/types/{0_keyboard_button_poll_type.js → 0_inline_query_result_button.js} +0 -0
- /package/script/types/{0_keyboard_button_poll_type.js → 0_inline_query_result_button.js} +0 -0
|
@@ -37,7 +37,6 @@ export interface _VideoChatNotEndedCommon {
|
|
|
37
37
|
* @unlisted
|
|
38
38
|
*/
|
|
39
39
|
export interface VideoChatActive extends _VideoChatCommon, _VideoChatNotEndedCommon {
|
|
40
|
-
/** @discriminator */
|
|
41
40
|
type: "active";
|
|
42
41
|
/** Whether the video chat is being recorded. */
|
|
43
42
|
isRecording: boolean;
|
|
@@ -47,7 +46,6 @@ export interface VideoChatActive extends _VideoChatCommon, _VideoChatNotEndedCom
|
|
|
47
46
|
* @unlisted
|
|
48
47
|
*/
|
|
49
48
|
export interface VideoChatScheduled extends _VideoChatCommon, _VideoChatNotEndedCommon {
|
|
50
|
-
/** @discriminator */
|
|
51
49
|
type: "scheduled";
|
|
52
50
|
/** The point in time in which the video chat will be started. */
|
|
53
51
|
scheduledFor: number;
|
|
@@ -57,7 +55,6 @@ export interface VideoChatScheduled extends _VideoChatCommon, _VideoChatNotEnded
|
|
|
57
55
|
* @unlisted
|
|
58
56
|
*/
|
|
59
57
|
export interface VideoChatEnded extends _VideoChatCommon {
|
|
60
|
-
/** @discriminator */
|
|
61
58
|
type: "ended";
|
|
62
59
|
/** The duration of the video chat in seconds. */
|
|
63
60
|
duration: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"0_video_chat.d.ts","sourceRoot":"","sources":["../../src/types/0_video_chat.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAEjC,gBAAgB;AAChB,MAAM,WAAW,gBAAgB;IAC/B,0CAA0C;IAC1C,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,gBAAgB;AAChB,MAAM,WAAW,wBAAwB;IACvC,8BAA8B;IAC9B,KAAK,EAAE,MAAM,CAAC;IACd,mCAAmC;IACnC,YAAY,EAAE,OAAO,CAAC;IACtB,0CAA0C;IAC1C,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AAED;;;GAGG;AACH,MAAM,WAAW,eAAgB,SAAQ,gBAAgB,EAAE,wBAAwB;IACjF,
|
|
1
|
+
{"version":3,"file":"0_video_chat.d.ts","sourceRoot":"","sources":["../../src/types/0_video_chat.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAEjC,gBAAgB;AAChB,MAAM,WAAW,gBAAgB;IAC/B,0CAA0C;IAC1C,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,gBAAgB;AAChB,MAAM,WAAW,wBAAwB;IACvC,8BAA8B;IAC9B,KAAK,EAAE,MAAM,CAAC;IACd,mCAAmC;IACnC,YAAY,EAAE,OAAO,CAAC;IACtB,0CAA0C;IAC1C,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AAED;;;GAGG;AACH,MAAM,WAAW,eAAgB,SAAQ,gBAAgB,EAAE,wBAAwB;IACjF,IAAI,EAAE,QAAQ,CAAC;IACf,gDAAgD;IAChD,WAAW,EAAE,OAAO,CAAC;CACtB;AAED;;;GAGG;AACH,MAAM,WAAW,kBAAmB,SAAQ,gBAAgB,EAAE,wBAAwB;IACpF,IAAI,EAAE,WAAW,CAAC;IAClB,iEAAiE;IACjE,YAAY,EAAE,MAAM,CAAC;CACtB;AAED;;;GAGG;AACH,MAAM,WAAW,cAAe,SAAQ,gBAAgB;IACtD,IAAI,EAAE,OAAO,CAAC;IACd,iDAAiD;IACjD,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,oBAAoB;AACpB,MAAM,MAAM,SAAS,GAAG,eAAe,GAAG,kBAAkB,GAAG,cAAc,CAAC;AAE9E,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,GAAG,CAAC,SAAS,GAAG,SAAS,CAgCjE"}
|
|
@@ -24,7 +24,6 @@ import { type Reaction } from "./0_reaction.js";
|
|
|
24
24
|
* @unlisted
|
|
25
25
|
*/
|
|
26
26
|
export interface AvailableReactionsNone {
|
|
27
|
-
/** @discriminator */
|
|
28
27
|
type: "none";
|
|
29
28
|
}
|
|
30
29
|
/**
|
|
@@ -32,7 +31,6 @@ export interface AvailableReactionsNone {
|
|
|
32
31
|
* @unlisted
|
|
33
32
|
*/
|
|
34
33
|
export interface AvailableReactionsSome {
|
|
35
|
-
/** @discriminator */
|
|
36
34
|
type: "some";
|
|
37
35
|
/** The allowed reactions. */
|
|
38
36
|
reactions: Reaction[];
|
|
@@ -44,7 +42,6 @@ export interface AvailableReactionsSome {
|
|
|
44
42
|
* @unlisted
|
|
45
43
|
*/
|
|
46
44
|
export interface AvailableReactionsAll {
|
|
47
|
-
/** @discriminator */
|
|
48
45
|
type: "all";
|
|
49
46
|
/** The maximum number of allowed reactions on a single message. */
|
|
50
47
|
maxReactionCount: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"1_available_reactions.d.ts","sourceRoot":"","sources":["../../src/types/1_available_reactions.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,KAAK,QAAQ,EAAsB,MAAM,iBAAiB,CAAC;AAEpE;;;GAGG;AACH,MAAM,WAAW,sBAAsB;IACrC,
|
|
1
|
+
{"version":3,"file":"1_available_reactions.d.ts","sourceRoot":"","sources":["../../src/types/1_available_reactions.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,KAAK,QAAQ,EAAsB,MAAM,iBAAiB,CAAC;AAEpE;;;GAGG;AACH,MAAM,WAAW,sBAAsB;IACrC,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;;GAGG;AACH,MAAM,WAAW,sBAAsB;IACrC,IAAI,EAAE,MAAM,CAAC;IACb,6BAA6B;IAC7B,SAAS,EAAE,QAAQ,EAAE,CAAC;IACtB,mEAAmE;IACnE,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AAED;;;GAGG;AACH,MAAM,WAAW,qBAAqB;IACpC,IAAI,EAAE,KAAK,CAAC;IACZ,mEAAmE;IACnE,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AAED,oCAAoC;AACpC,MAAM,MAAM,kBAAkB,GAAG,sBAAsB,GAAG,sBAAsB,GAAG,qBAAqB,CAAC;AAEzG,wBAAgB,4BAA4B,CAAC,sBAAsB,EAAE,kBAAkB,GAAG,GAAG,CAAC,aAAa,CAS1G"}
|
|
@@ -22,39 +22,32 @@ import type { InputPeerGetter } from "./_getters.js";
|
|
|
22
22
|
import type { ID } from "./0_id.js";
|
|
23
23
|
/** @unlisted */
|
|
24
24
|
export interface BotCommandScopeDefault {
|
|
25
|
-
/** @discriminator */
|
|
26
25
|
type: "default";
|
|
27
26
|
}
|
|
28
27
|
/** @unlisted */
|
|
29
28
|
export interface BotCommandScopeAllPrivateChats {
|
|
30
|
-
/** @discriminator */
|
|
31
29
|
type: "allPrivateChats";
|
|
32
30
|
}
|
|
33
31
|
/** @unlisted */
|
|
34
32
|
export interface BotCommandScopeAllGroupChats {
|
|
35
|
-
/** @discriminator */
|
|
36
33
|
type: "allGroupChats";
|
|
37
34
|
}
|
|
38
35
|
/** @unlisted */
|
|
39
36
|
export interface BotCommandScopeAllChatAdministrators {
|
|
40
|
-
/** @discriminator */
|
|
41
37
|
type: "allChatAdministrators";
|
|
42
38
|
}
|
|
43
39
|
/** @unlisted */
|
|
44
40
|
export interface BotCommandScopeChat {
|
|
45
|
-
/** @discriminator */
|
|
46
41
|
type: "chat";
|
|
47
42
|
chatId: ID;
|
|
48
43
|
}
|
|
49
44
|
/** @unlisted */
|
|
50
45
|
export interface BotCommandScopeChatAdministrators {
|
|
51
|
-
/** @discriminator */
|
|
52
46
|
type: "chatAdministrators";
|
|
53
47
|
chatId: ID;
|
|
54
48
|
}
|
|
55
49
|
/** @unlisted */
|
|
56
50
|
export interface BotCommandScopeChatMember {
|
|
57
|
-
/** @discriminator */
|
|
58
51
|
type: "chatMember";
|
|
59
52
|
chatId: ID;
|
|
60
53
|
userId: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"1_bot_command_scope.d.ts","sourceRoot":"","sources":["../../src/types/1_bot_command_scope.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,WAAW,CAAC;AAEpC,gBAAgB;AAChB,MAAM,WAAW,sBAAsB;IACrC,
|
|
1
|
+
{"version":3,"file":"1_bot_command_scope.d.ts","sourceRoot":"","sources":["../../src/types/1_bot_command_scope.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,WAAW,CAAC;AAEpC,gBAAgB;AAChB,MAAM,WAAW,sBAAsB;IACrC,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,gBAAgB;AAChB,MAAM,WAAW,8BAA8B;IAC7C,IAAI,EAAE,iBAAiB,CAAC;CACzB;AAED,gBAAgB;AAChB,MAAM,WAAW,4BAA4B;IAC3C,IAAI,EAAE,eAAe,CAAC;CACvB;AAED,gBAAgB;AAChB,MAAM,WAAW,oCAAoC;IACnD,IAAI,EAAE,uBAAuB,CAAC;CAC/B;AAED,gBAAgB;AAChB,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,EAAE,CAAC;CACZ;AAED,gBAAgB;AAChB,MAAM,WAAW,iCAAiC;IAChD,IAAI,EAAE,oBAAoB,CAAC;IAC3B,MAAM,EAAE,EAAE,CAAC;CACZ;AAED,gBAAgB;AAChB,MAAM,WAAW,yBAAyB;IACxC,IAAI,EAAE,YAAY,CAAC;IACnB,MAAM,EAAE,EAAE,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,0DAA0D;AAC1D,MAAM,MAAM,eAAe,GAAG,sBAAsB,GAAG,8BAA8B,GAAG,4BAA4B,GAAG,oCAAoC,GAAG,mBAAmB,GAAG,iCAAiC,GAAG,yBAAyB,CAAC;AAElP,wBAAsB,yBAAyB,CAAC,KAAK,EAAE,eAAe,EAAE,YAAY,EAAE,eAAe,GAAG,OAAO,CAAC,GAAG,CAAC,eAAe,CAAC,CAwBnI"}
|
package/esm/types/1_chat_p.d.ts
CHANGED
|
@@ -37,7 +37,6 @@ export interface _ChatPBase {
|
|
|
37
37
|
}
|
|
38
38
|
/** @unlisted */
|
|
39
39
|
export interface ChatPPrivate extends _ChatPBase {
|
|
40
|
-
/** @discriminator */
|
|
41
40
|
type: "private";
|
|
42
41
|
/** Whether this is a bot's chat. */
|
|
43
42
|
isBot: boolean;
|
|
@@ -88,7 +87,6 @@ export interface ChatPPrivate extends _ChatPBase {
|
|
|
88
87
|
}
|
|
89
88
|
/** @unlisted */
|
|
90
89
|
export interface ChatPGroup extends _ChatPBase {
|
|
91
|
-
/** @discriminator */
|
|
92
90
|
type: "group";
|
|
93
91
|
/** The title of the chat. */
|
|
94
92
|
title: string;
|
|
@@ -116,21 +114,17 @@ export interface ChatPChannelBase extends _ChatPBase {
|
|
|
116
114
|
}
|
|
117
115
|
/** @unlisted */
|
|
118
116
|
export interface ChatPChannel extends ChatPChannelBase {
|
|
119
|
-
/** @discriminator */
|
|
120
117
|
type: "channel";
|
|
121
118
|
/** The channel's emoji status. */
|
|
122
119
|
emojiStatus?: EmojiStatus;
|
|
123
120
|
}
|
|
124
121
|
/** @unlisted */
|
|
125
122
|
export interface ChatPSupergroup extends ChatPChannelBase {
|
|
126
|
-
/** @discriminator */
|
|
127
123
|
type: "supergroup";
|
|
128
124
|
/** Whether the chat is a forum. */
|
|
129
125
|
isForum: boolean;
|
|
130
126
|
}
|
|
131
|
-
/**
|
|
132
|
-
* A chat with lesser fields.
|
|
133
|
-
*/
|
|
127
|
+
/** A chat with lesser fields. */
|
|
134
128
|
export type ChatP = ChatPPrivate | ChatPGroup | ChatPSupergroup | ChatPChannel;
|
|
135
129
|
export declare function constructChatP(chat: Api.user): ChatPPrivate;
|
|
136
130
|
export declare function constructChatP(chat: Api.chat | Api.chatForbidden): ChatPGroup;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"1_chat_p.d.ts","sourceRoot":"","sources":["../../src/types/1_chat_p.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAIH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAEjC,OAAO,EAAE,KAAK,SAAS,EAAsB,MAAM,mBAAmB,CAAC;AACvE,OAAO,EAAwB,KAAK,W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GAAG,GAAG,CAAC,gBAAgB,GAAG,eAAe,GAAG,YAAY,CAAC;AACzG,wBAAgB,cAAc,CAAC,IAAI,EAAE,GAAG,CAAC,IAAI,GAAG,GAAG,CAAC,IAAI,GAAG,KAAK,CAAC;AAwHjE,gBAAgB;AAChB,MAAM,WAAW,UAAU;IACzB,CAAC,IAAI,EAAE,GAAG,CAAC,QAAQ,GAAG,CAAC,YAAY,EAAE,MAAM,CAAC,GAAG,IAAI,CAAC;IACpD,CAAC,IAAI,EAAE,GAAG,CAAC,QAAQ,GAAG,CAAC,UAAU,EAAE,MAAM,CAAC,GAAG,IAAI,CAAC;IAClD,CAAC,IAAI,EAAE,GAAG,CAAC,WAAW,GAAG,CAAC,YAAY,GAAG,eAAe,EAAE,MAAM,CAAC,GAAG,IAAI,CAAC;IACzE,CAAC,IAAI,EAAE,GAAG,CAAC,QAAQ,GAAG,GAAG,CAAC,QAAQ,GAAG,GAAG,CAAC,WAAW,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,GAAG,IAAI,CAAC;CAC/E;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,KAAK,GAAG,KAAK,IAAI,YAAY,CAE/D"}
|
|
@@ -21,7 +21,6 @@ import { Api } from "../2_tl.js";
|
|
|
21
21
|
import type { UsernameResolver } from "./_getters.js";
|
|
22
22
|
import { type ButtonStyle } from "./0_button_style.js";
|
|
23
23
|
import type { LoginUrl } from "./0_login_url.js";
|
|
24
|
-
import { type MiniAppButtonInfo } from "./0_mini_app_button_info.js";
|
|
25
24
|
/** @unlisted */
|
|
26
25
|
export interface _InlineKeyboardButtonBase {
|
|
27
26
|
/** The text of the button. */
|
|
@@ -33,10 +32,8 @@ export interface _InlineKeyboardButtonBase {
|
|
|
33
32
|
* @unlisted
|
|
34
33
|
*/
|
|
35
34
|
export interface InlineKeyboardButtonURL extends _InlineKeyboardButtonBase {
|
|
36
|
-
/**
|
|
37
|
-
|
|
38
|
-
* @discriminator
|
|
39
|
-
*/
|
|
35
|
+
/** The URL to open. */
|
|
36
|
+
type: "url";
|
|
40
37
|
url: string;
|
|
41
38
|
}
|
|
42
39
|
/**
|
|
@@ -44,10 +41,8 @@ export interface InlineKeyboardButtonURL extends _InlineKeyboardButtonBase {
|
|
|
44
41
|
* @unlisted
|
|
45
42
|
*/
|
|
46
43
|
export interface InlineKeyboardButtonCallback extends _InlineKeyboardButtonBase {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
* @discriminator
|
|
50
|
-
*/
|
|
44
|
+
type: "callbackData";
|
|
45
|
+
/** The callback data to send back. */
|
|
51
46
|
callbackData: string;
|
|
52
47
|
}
|
|
53
48
|
/**
|
|
@@ -56,21 +51,17 @@ export interface InlineKeyboardButtonCallback extends _InlineKeyboardButtonBase
|
|
|
56
51
|
*/
|
|
57
52
|
/** @unlisted */
|
|
58
53
|
export interface InlineKeyboardButtonMiniApp extends _InlineKeyboardButtonBase {
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
*/
|
|
63
|
-
miniApp: MiniAppButtonInfo;
|
|
54
|
+
type: "miniApp";
|
|
55
|
+
/** An HTTPS URL of the mini app to be opened with additional data. */
|
|
56
|
+
url: string;
|
|
64
57
|
}
|
|
65
58
|
/**
|
|
66
59
|
* An inline keyboard button that, when pressed, logs the user into the specified URL.
|
|
67
60
|
* @unlisted
|
|
68
61
|
*/
|
|
69
62
|
export interface InlineKeyboardButtonLogin extends _InlineKeyboardButtonBase {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
* @discriminator
|
|
73
|
-
*/
|
|
63
|
+
type: "loginUrl";
|
|
64
|
+
/** The URL to log into. */
|
|
74
65
|
loginUrl: LoginUrl;
|
|
75
66
|
}
|
|
76
67
|
/**
|
|
@@ -78,60 +69,52 @@ export interface InlineKeyboardButtonLogin extends _InlineKeyboardButtonBase {
|
|
|
78
69
|
* @unlisted
|
|
79
70
|
*/
|
|
80
71
|
export interface InlineKeyboardButtonSwitchInline extends _InlineKeyboardButtonBase {
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
*/
|
|
85
|
-
switchInlineQuery: string;
|
|
72
|
+
type: "switchInlineQuery";
|
|
73
|
+
/** The query to type into the user's message box once switched to inline. */
|
|
74
|
+
inlineQuery: string;
|
|
86
75
|
}
|
|
87
76
|
/**
|
|
88
77
|
* An inline keyboard button that, when pressed, switches to inline mode in the current chat.
|
|
89
78
|
* @unlisted
|
|
90
79
|
*/
|
|
91
80
|
export interface InlineKeyboardButtonSwitchInlineCurrent extends _InlineKeyboardButtonBase {
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
*/
|
|
96
|
-
switchInlineQueryCurrentChat: string;
|
|
81
|
+
type: "switchInlineQueryCurrentChat";
|
|
82
|
+
/** The query to type into the user's message box once switched to inline. */
|
|
83
|
+
inlineQuery: string;
|
|
97
84
|
}
|
|
98
85
|
/**
|
|
99
86
|
* An inline keyboard button that, when pressed, switches to inline mode in a chat chosen by the user from a limited subset of chats.
|
|
100
87
|
* @unlisted
|
|
101
88
|
*/
|
|
102
89
|
export interface InlineKeyboardButtonSwitchInlineChosen extends _InlineKeyboardButtonBase {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
allowChannels?: boolean;
|
|
110
|
-
};
|
|
90
|
+
type: "switchInlineQueryChosenChats";
|
|
91
|
+
inlineQuery: string;
|
|
92
|
+
isUser?: boolean;
|
|
93
|
+
isBot?: boolean;
|
|
94
|
+
isGroup?: boolean;
|
|
95
|
+
isChannel?: boolean;
|
|
111
96
|
}
|
|
112
97
|
/**
|
|
113
98
|
* An inline keyboard button that, when pressed, launches the bot's game.
|
|
114
99
|
* @unlisted
|
|
115
100
|
*/
|
|
116
101
|
export interface InlineKeyboardButtonGame extends _InlineKeyboardButtonBase {
|
|
117
|
-
|
|
118
|
-
callbackGame: Record<never, never>;
|
|
102
|
+
type: "callbackGame";
|
|
119
103
|
}
|
|
120
104
|
/**
|
|
121
105
|
* An inline keyboard that, when pressed, initiates a payment.
|
|
122
106
|
* @unlisted
|
|
123
107
|
*/
|
|
124
108
|
export interface InlineKeyboardButtonPay extends _InlineKeyboardButtonBase {
|
|
125
|
-
|
|
126
|
-
pay: boolean;
|
|
109
|
+
type: "pay";
|
|
127
110
|
}
|
|
128
111
|
/**
|
|
129
112
|
* An inline keyboard that, when pressed, copies the text inside its `copy` field.
|
|
130
113
|
* @unlisted
|
|
131
114
|
*/
|
|
132
115
|
export interface InlineKeyboardButtonCopy extends _InlineKeyboardButtonBase {
|
|
133
|
-
|
|
134
|
-
|
|
116
|
+
type: "copy";
|
|
117
|
+
textToCopy: string;
|
|
135
118
|
}
|
|
136
119
|
/** A button of an inline keyboard. */
|
|
137
120
|
export type InlineKeyboardButton = InlineKeyboardButtonURL | InlineKeyboardButtonCallback | InlineKeyboardButtonMiniApp | InlineKeyboardButtonLogin | InlineKeyboardButtonSwitchInline | InlineKeyboardButtonSwitchInlineCurrent | InlineKeyboardButtonSwitchInlineChosen | InlineKeyboardButtonGame | InlineKeyboardButtonPay | InlineKeyboardButtonCopy;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"1_inline_keyboard_button.d.ts","sourceRoot":"","sources":["../../src/types/1_inline_keyboard_button.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAKH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACtD,OAAO,EAAE,KAAK,WAAW,EAA+C,MAAM,qBAAqB,CAAC;AACpG,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"1_inline_keyboard_button.d.ts","sourceRoot":"","sources":["../../src/types/1_inline_keyboard_button.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAKH,OAAO,E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IAAI,EAAE,8BAA8B,CAAC;IACrC,WAAW,EAAE,MAAM,CAAC;IACpB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB;AAED;;;GAGG;AACH,MAAM,WAAW,wBAAyB,SAAQ,yBAAyB;IACzE,IAAI,EAAE,cAAc,CAAC;CACtB;AAED;;;GAGG;AACH,MAAM,WAAW,uBAAwB,SAAQ,yBAAyB;IACxE,IAAI,EAAE,KAAK,CAAC;CACb;AAED;;;GAGG;AACH,MAAM,WAAW,wBAAyB,SAAQ,yBAAyB;IACzE,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,sCAAsC;AACtC,MAAM,MAAM,oBAAoB,GAC5B,uBAAuB,GACvB,4BAA4B,GAC5B,2BAA2B,GAC3B,yBAAyB,GACzB,gCAAgC,GAChC,uCAAuC,GACvC,sCAAsC,GACtC,wBAAwB,GACxB,uBAAuB,GACvB,wBAAwB,CAAC;AAE7B,wBAAgB,6BAA6B,CAAC,OAAO,EAAE,GAAG,CAAC,cAAc,GAAG,oBAAoB,CAkC/F;AAED,wBAAsB,8BAA8B,CAAC,MAAM,EAAE,oBAAoB,EAAE,gBAAgB,EAAE,gBAAgB,GAAG,OAAO,CAAC,GAAG,CAAC,cAAc,CAAC,CAqDlJ"}
|
|
@@ -22,44 +22,44 @@ import { InputError } from "../0_errors.js";
|
|
|
22
22
|
import { cleanObject, decodeText, encodeText } from "../1_utilities.js";
|
|
23
23
|
import { Api } from "../2_tl.js";
|
|
24
24
|
import { buttonStyleToTlObject, constructButtonStyle } from "./0_button_style.js";
|
|
25
|
-
import { constructMiniAppButtonInfo } from "./0_mini_app_button_info.js";
|
|
26
25
|
export function constructInlineKeyboardButton(button_) {
|
|
26
|
+
const text = button_.text;
|
|
27
27
|
const style = constructButtonStyle(button_.style);
|
|
28
28
|
if (Api.is("keyboardButtonUrl", button_)) {
|
|
29
|
-
return cleanObject({
|
|
29
|
+
return cleanObject({ type: "url", text, style, url: button_.url });
|
|
30
30
|
}
|
|
31
31
|
else if (Api.is("keyboardButtonCallback", button_)) {
|
|
32
|
-
return cleanObject({
|
|
32
|
+
return cleanObject({ type: "callbackData", text, style, callbackData: decodeText(button_.data) });
|
|
33
33
|
}
|
|
34
34
|
else if (Api.is("keyboardButtonWebView", button_) || Api.is("keyboardButtonSimpleWebView", button_)) {
|
|
35
|
-
return cleanObject({
|
|
35
|
+
return cleanObject({ type: "miniApp", text, style, url: button_.url });
|
|
36
36
|
}
|
|
37
37
|
else if (Api.is("keyboardButtonUrlAuth", button_)) {
|
|
38
|
-
return cleanObject({
|
|
38
|
+
return cleanObject({ type: "loginUrl", text, style, loginUrl: { url: button_.url, forwardText: button_.fwd_text } });
|
|
39
39
|
}
|
|
40
40
|
else if (Api.is("keyboardButtonSwitchInline", button_)) {
|
|
41
41
|
if (button_.same_peer) {
|
|
42
|
-
return cleanObject({
|
|
42
|
+
return cleanObject({ type: "switchInlineQueryCurrentChat", text, style, inlineQuery: button_.query });
|
|
43
43
|
}
|
|
44
44
|
else if (button_.peer_types && button_.peer_types.length) {
|
|
45
45
|
const allowUsers = button_.peer_types.some((v) => v._ === "inlineQueryPeerTypeBotPM") || undefined;
|
|
46
46
|
const allowBots = button_.peer_types.some((v) => v._ === "inlineQueryPeerTypeSameBotPM" || v._ === "inlineQueryPeerTypeBotPM") || undefined;
|
|
47
47
|
const allowGroups = button_.peer_types.some((v) => v._ === "inlineQueryPeerTypeChat" || v._ === "inlineQueryPeerTypeMegagroup") || undefined;
|
|
48
48
|
const allowChannels = button_.peer_types.some((v) => v._ === "inlineQueryPeerTypeBroadcast") || undefined;
|
|
49
|
-
return cleanObject({
|
|
49
|
+
return cleanObject({ type: "switchInlineQueryChosenChats", text, style, inlineQuery: button_.query, allowUsers, allowBots, allowGroups, allowChannels });
|
|
50
50
|
}
|
|
51
51
|
else {
|
|
52
|
-
return cleanObject({
|
|
52
|
+
return cleanObject({ type: "switchInlineQuery", text, style, inlineQuery: button_.query });
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
else if (Api.is("keyboardButtonBuy", button_)) {
|
|
56
|
-
return cleanObject({
|
|
56
|
+
return cleanObject({ type: "pay", text, style });
|
|
57
57
|
}
|
|
58
58
|
else if (Api.is("keyboardButtonGame", button_)) {
|
|
59
|
-
return cleanObject({
|
|
59
|
+
return cleanObject({ type: "callbackGame", text, style });
|
|
60
60
|
}
|
|
61
61
|
else if (Api.is("keyboardButtonCopy", button_)) {
|
|
62
|
-
return cleanObject({
|
|
62
|
+
return cleanObject({ type: "copy", text, style, textToCopy: button_.copy_text });
|
|
63
63
|
}
|
|
64
64
|
else if (Api.is("keyboardButtonRequestPeer", button_)) {
|
|
65
65
|
unreachable();
|
|
@@ -70,59 +70,52 @@ export function constructInlineKeyboardButton(button_) {
|
|
|
70
70
|
}
|
|
71
71
|
export async function inlineKeyboardButtonToTlObject(button, usernameResolver) {
|
|
72
72
|
const style = buttonStyleToTlObject(button.style);
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
73
|
+
switch (button.type) {
|
|
74
|
+
case "url":
|
|
75
|
+
return { _: "keyboardButtonUrl", text: button.text, url: button.url, style };
|
|
76
|
+
case "callbackData":
|
|
77
|
+
return { _: "keyboardButtonCallback", text: button.text, data: encodeText(button.callbackData), style };
|
|
78
|
+
case "miniApp":
|
|
79
|
+
return { _: "keyboardButtonWebView", text: button.text, url: button.url, style };
|
|
80
|
+
case "loginUrl":
|
|
81
|
+
return {
|
|
82
|
+
_: "inputKeyboardButtonUrlAuth",
|
|
83
|
+
text: button.text,
|
|
84
|
+
url: button.loginUrl.url,
|
|
85
|
+
fwd_text: button.loginUrl.forwardText,
|
|
86
|
+
bot: button.loginUrl.botUsername ? await usernameResolver(button.loginUrl.botUsername) : { _: "inputUserSelf" },
|
|
87
|
+
request_write_access: button.loginUrl.requestWriteAccess || undefined,
|
|
88
|
+
style,
|
|
89
|
+
};
|
|
90
|
+
case "switchInlineQuery":
|
|
91
|
+
return { _: "keyboardButtonSwitchInline", text: button.text, query: button.inlineQuery, style };
|
|
92
|
+
case "switchInlineQueryCurrentChat":
|
|
93
|
+
return { _: "keyboardButtonSwitchInline", text: button.text, query: button.inlineQuery, same_peer: true, style };
|
|
94
|
+
case "switchInlineQueryChosenChats": {
|
|
95
|
+
const peerTypes = new Array();
|
|
96
|
+
const { isUser, isBot, isGroup, isChannel } = button;
|
|
97
|
+
if (!isUser && !isBot && !isGroup && !isChannel) {
|
|
98
|
+
throw new InputError("switchInlineQueryChosenChats: At least one chat type must be allowed.");
|
|
99
|
+
}
|
|
100
|
+
if (isUser) {
|
|
101
|
+
peerTypes.push({ _: "inlineQueryPeerTypeBotPM" });
|
|
102
|
+
}
|
|
103
|
+
if (isBot) {
|
|
104
|
+
peerTypes.push({ _: "inlineQueryPeerTypeSameBotPM" }, { _: "inlineQueryPeerTypeBotPM" });
|
|
105
|
+
}
|
|
106
|
+
if (isGroup) {
|
|
107
|
+
peerTypes.push({ _: "inlineQueryPeerTypeChat" }, { _: "inlineQueryPeerTypeMegagroup" });
|
|
108
|
+
}
|
|
109
|
+
if (isChannel) {
|
|
110
|
+
peerTypes.push({ _: "inlineQueryPeerTypeBroadcast" });
|
|
111
|
+
}
|
|
112
|
+
return { _: "keyboardButtonSwitchInline", text: button.text, query: button.inlineQuery, peer_types: peerTypes, style };
|
|
110
113
|
}
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
return { _: "keyboardButtonSwitchInline", text: button.text, query: button.switchInlineQueryChosenChats.query, peer_types: peerTypes, style };
|
|
118
|
-
}
|
|
119
|
-
else if ("pay" in button) {
|
|
120
|
-
return { _: "keyboardButtonBuy", text: button.text, style };
|
|
121
|
-
}
|
|
122
|
-
else if ("copy" in button) {
|
|
123
|
-
return { _: "keyboardButtonCopy", text: button.text, copy_text: button.copy, style };
|
|
124
|
-
}
|
|
125
|
-
else {
|
|
126
|
-
unreachable();
|
|
114
|
+
case "callbackGame":
|
|
115
|
+
return { _: "keyboardButtonGame", text: button.text, style };
|
|
116
|
+
case "pay":
|
|
117
|
+
return { _: "keyboardButtonBuy", text: button.text, style };
|
|
118
|
+
case "copy":
|
|
119
|
+
return { _: "keyboardButtonCopy", text: button.text, copy_text: button.textToCopy, style };
|
|
127
120
|
}
|
|
128
121
|
}
|
|
@@ -25,7 +25,6 @@ import type { ID } from "./0_id.js";
|
|
|
25
25
|
* @unlisted
|
|
26
26
|
*/
|
|
27
27
|
export interface InputGiftSlug {
|
|
28
|
-
/** @discriminator */
|
|
29
28
|
type: "slug";
|
|
30
29
|
slug: string;
|
|
31
30
|
}
|
|
@@ -34,7 +33,6 @@ export interface InputGiftSlug {
|
|
|
34
33
|
* @unlisted
|
|
35
34
|
*/
|
|
36
35
|
export interface InputGiftChat {
|
|
37
|
-
/** @discriminator */
|
|
38
36
|
type: "chat";
|
|
39
37
|
chatId: ID;
|
|
40
38
|
id: string;
|
|
@@ -44,7 +42,6 @@ export interface InputGiftChat {
|
|
|
44
42
|
* @unlisted
|
|
45
43
|
*/
|
|
46
44
|
export interface InputGiftUser {
|
|
47
|
-
/** @discriminator */
|
|
48
45
|
type: "user";
|
|
49
46
|
messageId: number;
|
|
50
47
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"1_input_gift.d.ts","sourceRoot":"","sources":["../../src/types/1_input_gift.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,WAAW,CAAC;AAEpC;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B,
|
|
1
|
+
{"version":3,"file":"1_input_gift.d.ts","sourceRoot":"","sources":["../../src/types/1_input_gift.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,WAAW,CAAC;AAEpC;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,EAAE,CAAC;IACX,EAAE,EAAE,MAAM,CAAC;CACZ;AAED;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,2BAA2B;AAC3B,MAAM,MAAM,SAAS,GAAG,aAAa,GAAG,aAAa,GAAG,aAAa,CAAC;AAEtE,wBAAsB,mBAAmB,CAAC,SAAS,EAAE,SAAS,EAAE,YAAY,EAAE,eAAe,GAAG,OAAO,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAW9H"}
|
|
@@ -20,13 +20,13 @@
|
|
|
20
20
|
import type { FileSource } from "./0_file_source.js";
|
|
21
21
|
/** @unlisted */
|
|
22
22
|
export interface InputStoryContentPhoto {
|
|
23
|
-
|
|
23
|
+
type: "photo";
|
|
24
24
|
photo: FileSource;
|
|
25
25
|
attachedStickerFileIds?: string[];
|
|
26
26
|
}
|
|
27
27
|
/** @unlisted */
|
|
28
28
|
export interface InputStoryContentVideo {
|
|
29
|
-
|
|
29
|
+
type: "video";
|
|
30
30
|
video: FileSource;
|
|
31
31
|
attachedStickerFileIds?: string[];
|
|
32
32
|
duration: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"1_input_story_content.d.ts","sourceRoot":"","sources":["../../src/types/1_input_story_content.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAErD,gBAAgB;AAChB,MAAM,WAAW,sBAAsB;IACrC,
|
|
1
|
+
{"version":3,"file":"1_input_story_content.d.ts","sourceRoot":"","sources":["../../src/types/1_input_story_content.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAErD,gBAAgB;AAChB,MAAM,WAAW,sBAAsB;IACrC,IAAI,EAAE,OAAO,CAAC;IACd,KAAK,EAAE,UAAU,CAAC;IAClB,sBAAsB,CAAC,EAAE,MAAM,EAAE,CAAC;CACnC;AAED,gBAAgB;AAChB,MAAM,WAAW,sBAAsB;IACrC,IAAI,EAAE,OAAO,CAAC;IACd,KAAK,EAAE,UAAU,CAAC;IAClB,sBAAsB,CAAC,EAAE,MAAM,EAAE,CAAC;IAClC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,iDAAiD;AACjD,MAAM,MAAM,iBAAiB,GAAG,sBAAsB,GAAG,sBAAsB,CAAC"}
|
|
@@ -20,56 +20,55 @@
|
|
|
20
20
|
import { Api } from "../2_tl.js";
|
|
21
21
|
import { type ButtonStyle } from "./0_button_style.js";
|
|
22
22
|
import { type ChatAdministratorRights } from "./0_chat_administrator_rights.js";
|
|
23
|
-
|
|
24
|
-
|
|
23
|
+
/** @unlisted */
|
|
24
|
+
export interface _KeyboardButtonBase {
|
|
25
|
+
text: string;
|
|
26
|
+
style?: ButtonStyle;
|
|
27
|
+
}
|
|
25
28
|
/** @unlisted */
|
|
26
29
|
export interface KeyboardButtonText {
|
|
27
|
-
|
|
30
|
+
type: "text";
|
|
28
31
|
text: string;
|
|
29
32
|
style?: ButtonStyle;
|
|
30
33
|
}
|
|
31
34
|
/** @unlisted */
|
|
32
|
-
export interface KeyboardButtonRequestUser extends
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
isPremium?: boolean;
|
|
38
|
-
};
|
|
35
|
+
export interface KeyboardButtonRequestUser extends _KeyboardButtonBase {
|
|
36
|
+
type: "requestUser";
|
|
37
|
+
requestId: number;
|
|
38
|
+
isBot?: boolean;
|
|
39
|
+
isPremium?: boolean;
|
|
39
40
|
}
|
|
40
41
|
/** @unlisted */
|
|
41
|
-
export interface KeyboardButtonRequestChat extends
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
isBotMember?: boolean;
|
|
52
|
-
};
|
|
42
|
+
export interface KeyboardButtonRequestChat extends _KeyboardButtonBase {
|
|
43
|
+
type: "requestChat";
|
|
44
|
+
requestId: number;
|
|
45
|
+
isChannel: boolean;
|
|
46
|
+
isForum?: boolean;
|
|
47
|
+
hasUsername?: boolean;
|
|
48
|
+
isOwner?: boolean;
|
|
49
|
+
userAdministratorRights?: ChatAdministratorRights;
|
|
50
|
+
botAdministratorRights?: ChatAdministratorRights;
|
|
51
|
+
isBotMember?: boolean;
|
|
53
52
|
}
|
|
54
53
|
/** @unlisted */
|
|
55
|
-
export interface KeyboardButtonRequestContact extends
|
|
56
|
-
|
|
57
|
-
requestContact: true;
|
|
54
|
+
export interface KeyboardButtonRequestContact extends _KeyboardButtonBase {
|
|
55
|
+
type: "requestContact";
|
|
58
56
|
}
|
|
59
57
|
/** @unlisted */
|
|
60
|
-
export interface KeyboardButtonRequestLocation extends
|
|
61
|
-
|
|
62
|
-
requestLocation: true;
|
|
58
|
+
export interface KeyboardButtonRequestLocation extends _KeyboardButtonBase {
|
|
59
|
+
type: "requestLocation";
|
|
63
60
|
}
|
|
64
61
|
/** @unlisted */
|
|
65
|
-
export interface KeyboardButtonRequestPoll extends
|
|
66
|
-
|
|
67
|
-
|
|
62
|
+
export interface KeyboardButtonRequestPoll extends _KeyboardButtonBase {
|
|
63
|
+
type: "requestPoll";
|
|
64
|
+
/** If a type is not specified, the user will be allowed to choose either type. */
|
|
65
|
+
pollType?: "regular" | "quiz";
|
|
68
66
|
}
|
|
69
67
|
/** @unlisted */
|
|
70
|
-
export interface KeyboardButtonMiniApp extends
|
|
71
|
-
|
|
72
|
-
|
|
68
|
+
export interface KeyboardButtonMiniApp extends _KeyboardButtonBase {
|
|
69
|
+
type: "miniApp";
|
|
70
|
+
/** An HTTPS URL of the mini app to be opened with additional data. */
|
|
71
|
+
url: string;
|
|
73
72
|
}
|
|
74
73
|
/** A button of a custom keyboard. */
|
|
75
74
|
export type KeyboardButton = KeyboardButtonText | KeyboardButtonRequestUser | KeyboardButtonRequestChat | KeyboardButtonRequestContact | KeyboardButtonRequestLocation | KeyboardButtonRequestPoll | KeyboardButtonMiniApp;
|