@mtkruto/node 0.1.400 → 0.1.500

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.
Files changed (549) hide show
  1. package/esm/0_deps.d.ts +5 -5
  2. package/esm/0_deps.js +6 -6
  3. package/esm/3_types.d.ts +4 -1
  4. package/esm/3_types.js +4 -1
  5. package/esm/client/0_markdown.d.ts +19 -0
  6. package/esm/client/0_markdown.js +19 -1
  7. package/esm/client/0_params.d.ts +4 -0
  8. package/esm/client/0_utilities.js +1 -1
  9. package/esm/client/3_callback_query_manager.d.ts +2 -1
  10. package/esm/client/3_callback_query_manager.js +33 -5
  11. package/esm/client/3_inline_query_manager.d.ts +3 -2
  12. package/esm/client/3_inline_query_manager.js +20 -4
  13. package/esm/client/4_client.d.ts +23 -4
  14. package/esm/client/4_client.js +23 -0
  15. package/esm/storage/0_storage.d.ts +10 -0
  16. package/esm/storage/0_storage.js +42 -0
  17. package/esm/types/0_callback_query_answer.d.ts +30 -0
  18. package/esm/types/0_callback_query_answer.js +26 -0
  19. package/esm/types/0_callback_query_question.d.ts +49 -0
  20. package/esm/types/0_callback_query_question.js +31 -0
  21. package/{script/types/1_input_message_content.d.ts → esm/types/1_message_content.d.ts} +6 -6
  22. package/esm/types/1_photo.d.ts +4 -0
  23. package/esm/types/1_photo.js +12 -26
  24. package/esm/types/4_inline_query_result.d.ts +52 -49
  25. package/esm/types/4_inline_query_result.js +225 -44
  26. package/esm/types/5_inline_query_answer.d.ts +31 -0
  27. package/esm/types/5_inline_query_answer.js +28 -0
  28. package/esm/types/_file_id.d.ts +5 -0
  29. package/esm/types/_file_id.js +32 -1
  30. package/package.json +1 -1
  31. package/script/0_deps.d.ts +5 -5
  32. package/script/0_deps.js +6 -6
  33. package/script/3_types.d.ts +4 -1
  34. package/script/3_types.js +4 -1
  35. package/script/client/0_markdown.d.ts +19 -0
  36. package/script/client/0_markdown.js +19 -1
  37. package/script/client/0_params.d.ts +4 -0
  38. package/script/client/0_utilities.js +1 -1
  39. package/script/client/3_callback_query_manager.d.ts +2 -1
  40. package/script/client/3_callback_query_manager.js +30 -2
  41. package/script/client/3_inline_query_manager.d.ts +3 -2
  42. package/script/client/3_inline_query_manager.js +18 -2
  43. package/script/client/4_client.d.ts +23 -4
  44. package/script/client/4_client.js +23 -0
  45. package/script/storage/0_storage.d.ts +10 -0
  46. package/script/storage/0_storage.js +42 -0
  47. package/script/types/0_callback_query_answer.d.ts +30 -0
  48. package/script/types/0_callback_query_answer.js +30 -0
  49. package/script/types/0_callback_query_question.d.ts +49 -0
  50. package/script/types/0_callback_query_question.js +35 -0
  51. package/{esm/types/1_input_message_content.d.ts → script/types/1_message_content.d.ts} +6 -6
  52. package/script/types/1_photo.d.ts +4 -0
  53. package/script/types/1_photo.js +14 -27
  54. package/script/types/4_inline_query_result.d.ts +52 -49
  55. package/script/types/4_inline_query_result.js +224 -42
  56. package/script/types/5_inline_query_answer.d.ts +31 -0
  57. package/script/types/5_inline_query_answer.js +32 -0
  58. package/script/types/_file_id.d.ts +5 -0
  59. package/script/types/_file_id.js +33 -1
  60. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_constants.d.ts +0 -0
  61. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_constants.js +0 -0
  62. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_diff.d.ts +0 -0
  63. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_diff.js +0 -0
  64. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_format.d.ts +0 -0
  65. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_format.js +0 -0
  66. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert.d.ts +0 -0
  67. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert.js +0 -0
  68. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_almost_equals.d.ts +0 -0
  69. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_almost_equals.js +0 -0
  70. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_array_includes.d.ts +0 -0
  71. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_array_includes.js +0 -0
  72. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_equals.d.ts +0 -0
  73. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_equals.js +0 -0
  74. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_exists.d.ts +0 -0
  75. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_exists.js +0 -0
  76. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_false.d.ts +0 -0
  77. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_false.js +0 -0
  78. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_greater.d.ts +0 -0
  79. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_greater.js +0 -0
  80. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_greater_or_equal.d.ts +0 -0
  81. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_greater_or_equal.js +0 -0
  82. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_instance_of.d.ts +0 -0
  83. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_instance_of.js +0 -0
  84. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_is_error.d.ts +0 -0
  85. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_is_error.js +0 -0
  86. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_less.d.ts +0 -0
  87. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_less.js +0 -0
  88. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_less_or_equal.d.ts +0 -0
  89. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_less_or_equal.js +0 -0
  90. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_match.d.ts +0 -0
  91. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_match.js +0 -0
  92. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_equals.d.ts +0 -0
  93. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_equals.js +0 -0
  94. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_instance_of.d.ts +0 -0
  95. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_instance_of.js +0 -0
  96. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_match.d.ts +0 -0
  97. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_match.js +0 -0
  98. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_strict_equals.d.ts +0 -0
  99. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_strict_equals.js +0 -0
  100. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_object_match.d.ts +0 -0
  101. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_object_match.js +0 -0
  102. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_rejects.d.ts +0 -0
  103. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_rejects.js +0 -0
  104. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_strict_equals.d.ts +0 -0
  105. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_strict_equals.js +0 -0
  106. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_string_includes.d.ts +0 -0
  107. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_string_includes.js +0 -0
  108. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_throws.d.ts +0 -0
  109. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_throws.js +0 -0
  110. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assertion_error.d.ts +0 -0
  111. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assertion_error.js +0 -0
  112. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/equal.d.ts +0 -0
  113. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/equal.js +0 -0
  114. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/fail.d.ts +0 -0
  115. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/fail.js +0 -0
  116. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/mod.d.ts +0 -0
  117. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/mod.js +0 -0
  118. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/unimplemented.d.ts +0 -0
  119. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/unimplemented.js +0 -0
  120. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/unreachable.d.ts +0 -0
  121. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/unreachable.js +0 -0
  122. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/bytes/concat.d.ts +0 -0
  123. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/bytes/concat.js +0 -0
  124. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/encoding/_util.d.ts +0 -0
  125. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/encoding/_util.js +0 -0
  126. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/encoding/base64.d.ts +0 -0
  127. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/encoding/base64.js +0 -0
  128. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/fmt/colors.d.ts +0 -0
  129. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/fmt/colors.js +0 -0
  130. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/_db.d.ts +0 -0
  131. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/_db.js +0 -0
  132. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/_util.d.ts +0 -0
  133. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/_util.js +0 -0
  134. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/content_type.d.ts +0 -0
  135. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/content_type.js +0 -0
  136. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/extension.d.ts +0 -0
  137. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/extension.js +0 -0
  138. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/extensions_by_type.d.ts +0 -0
  139. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/extensions_by_type.js +0 -0
  140. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/format_media_type.d.ts +0 -0
  141. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/format_media_type.js +0 -0
  142. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/get_charset.d.ts +0 -0
  143. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/get_charset.js +0 -0
  144. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/parse_media_type.d.ts +0 -0
  145. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/parse_media_type.js +0 -0
  146. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/type_by_extension.d.ts +0 -0
  147. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/type_by_extension.js +0 -0
  148. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/vendor/mime-db.v1.52.0.d.ts +0 -0
  149. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/vendor/mime-db.v1.52.0.js +0 -0
  150. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/assert_path.d.ts +0 -0
  151. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/assert_path.js +0 -0
  152. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/basename.d.ts +0 -0
  153. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/basename.js +0 -0
  154. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/common.d.ts +0 -0
  155. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/common.js +0 -0
  156. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/constants.d.ts +0 -0
  157. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/constants.js +0 -0
  158. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/dirname.d.ts +0 -0
  159. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/dirname.js +0 -0
  160. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/format.d.ts +0 -0
  161. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/format.js +0 -0
  162. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/from_file_url.d.ts +0 -0
  163. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/from_file_url.js +0 -0
  164. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/glob_to_reg_exp.d.ts +0 -0
  165. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/glob_to_reg_exp.js +0 -0
  166. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/normalize.d.ts +0 -0
  167. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/normalize.js +0 -0
  168. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/normalize_string.d.ts +0 -0
  169. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/normalize_string.js +0 -0
  170. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/relative.d.ts +0 -0
  171. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/relative.js +0 -0
  172. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/strip_trailing_separators.d.ts +0 -0
  173. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/strip_trailing_separators.js +0 -0
  174. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/to_file_url.d.ts +0 -0
  175. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/to_file_url.js +0 -0
  176. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_interface.d.ts +0 -0
  177. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_interface.js +0 -0
  178. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_os.d.ts +0 -0
  179. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_os.js +0 -0
  180. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/basename.d.ts +0 -0
  181. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/basename.js +0 -0
  182. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/common.d.ts +0 -0
  183. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/common.js +0 -0
  184. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/constants.d.ts +0 -0
  185. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/constants.js +0 -0
  186. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/dirname.d.ts +0 -0
  187. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/dirname.js +0 -0
  188. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/extname.d.ts +0 -0
  189. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/extname.js +0 -0
  190. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/format.d.ts +0 -0
  191. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/format.js +0 -0
  192. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/from_file_url.d.ts +0 -0
  193. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/from_file_url.js +0 -0
  194. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/glob_to_regexp.d.ts +0 -0
  195. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/glob_to_regexp.js +0 -0
  196. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/is_absolute.d.ts +0 -0
  197. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/is_absolute.js +0 -0
  198. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/is_glob.d.ts +0 -0
  199. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/is_glob.js +0 -0
  200. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/join.d.ts +0 -0
  201. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/join.js +0 -0
  202. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/join_globs.d.ts +0 -0
  203. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/join_globs.js +0 -0
  204. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/mod.d.ts +0 -0
  205. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/mod.js +0 -0
  206. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/normalize.d.ts +0 -0
  207. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/normalize.js +0 -0
  208. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/normalize_glob.d.ts +0 -0
  209. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/normalize_glob.js +0 -0
  210. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/parse.d.ts +0 -0
  211. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/parse.js +0 -0
  212. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/_util.d.ts +0 -0
  213. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/_util.js +0 -0
  214. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/basename.d.ts +0 -0
  215. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/basename.js +0 -0
  216. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/common.d.ts +0 -0
  217. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/common.js +0 -0
  218. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/constants.d.ts +0 -0
  219. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/constants.js +0 -0
  220. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/dirname.d.ts +0 -0
  221. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/dirname.js +0 -0
  222. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/extname.d.ts +0 -0
  223. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/extname.js +0 -0
  224. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/format.d.ts +0 -0
  225. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/format.js +0 -0
  226. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/from_file_url.d.ts +0 -0
  227. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/from_file_url.js +0 -0
  228. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/glob_to_regexp.d.ts +0 -0
  229. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/glob_to_regexp.js +0 -0
  230. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/is_absolute.d.ts +0 -0
  231. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/is_absolute.js +0 -0
  232. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/is_glob.d.ts +0 -0
  233. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/is_glob.js +0 -0
  234. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/join.d.ts +0 -0
  235. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/join.js +0 -0
  236. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/join_globs.d.ts +0 -0
  237. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/join_globs.js +0 -0
  238. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/mod.d.ts +0 -0
  239. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/mod.js +0 -0
  240. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/normalize.d.ts +0 -0
  241. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/normalize.js +0 -0
  242. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/normalize_glob.d.ts +0 -0
  243. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/normalize_glob.js +0 -0
  244. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/parse.d.ts +0 -0
  245. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/parse.js +0 -0
  246. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/relative.d.ts +0 -0
  247. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/relative.js +0 -0
  248. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/resolve.d.ts +0 -0
  249. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/resolve.js +0 -0
  250. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/to_file_url.d.ts +0 -0
  251. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/to_file_url.js +0 -0
  252. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/to_namespaced_path.d.ts +0 -0
  253. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/to_namespaced_path.js +0 -0
  254. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/relative.d.ts +0 -0
  255. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/relative.js +0 -0
  256. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/resolve.d.ts +0 -0
  257. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/resolve.js +0 -0
  258. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/to_file_url.d.ts +0 -0
  259. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/to_file_url.js +0 -0
  260. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/to_namespaced_path.d.ts +0 -0
  261. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/to_namespaced_path.js +0 -0
  262. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/_util.d.ts +0 -0
  263. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/_util.js +0 -0
  264. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/basename.d.ts +0 -0
  265. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/basename.js +0 -0
  266. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/common.d.ts +0 -0
  267. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/common.js +0 -0
  268. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/constants.d.ts +0 -0
  269. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/constants.js +0 -0
  270. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/dirname.d.ts +0 -0
  271. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/dirname.js +0 -0
  272. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/extname.d.ts +0 -0
  273. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/extname.js +0 -0
  274. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/format.d.ts +0 -0
  275. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/format.js +0 -0
  276. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/from_file_url.d.ts +0 -0
  277. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/from_file_url.js +0 -0
  278. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/glob_to_regexp.d.ts +0 -0
  279. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/glob_to_regexp.js +0 -0
  280. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/is_absolute.d.ts +0 -0
  281. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/is_absolute.js +0 -0
  282. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/is_glob.d.ts +0 -0
  283. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/is_glob.js +0 -0
  284. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/join.d.ts +0 -0
  285. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/join.js +0 -0
  286. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/join_globs.d.ts +0 -0
  287. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/join_globs.js +0 -0
  288. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/mod.d.ts +0 -0
  289. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/mod.js +0 -0
  290. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/normalize.d.ts +0 -0
  291. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/normalize.js +0 -0
  292. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/normalize_glob.d.ts +0 -0
  293. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/normalize_glob.js +0 -0
  294. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/parse.d.ts +0 -0
  295. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/parse.js +0 -0
  296. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/relative.d.ts +0 -0
  297. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/relative.js +0 -0
  298. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/resolve.d.ts +0 -0
  299. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/resolve.js +0 -0
  300. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/to_file_url.d.ts +0 -0
  301. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/to_file_url.js +0 -0
  302. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/to_namespaced_path.d.ts +0 -0
  303. /package/esm/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/to_namespaced_path.js +0 -0
  304. /package/esm/types/{1_input_message_content.js → 1_message_content.js} +0 -0
  305. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_constants.d.ts +0 -0
  306. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_constants.js +0 -0
  307. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_diff.d.ts +0 -0
  308. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_diff.js +0 -0
  309. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_format.d.ts +0 -0
  310. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/_format.js +0 -0
  311. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert.d.ts +0 -0
  312. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert.js +0 -0
  313. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_almost_equals.d.ts +0 -0
  314. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_almost_equals.js +0 -0
  315. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_array_includes.d.ts +0 -0
  316. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_array_includes.js +0 -0
  317. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_equals.d.ts +0 -0
  318. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_equals.js +0 -0
  319. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_exists.d.ts +0 -0
  320. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_exists.js +0 -0
  321. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_false.d.ts +0 -0
  322. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_false.js +0 -0
  323. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_greater.d.ts +0 -0
  324. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_greater.js +0 -0
  325. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_greater_or_equal.d.ts +0 -0
  326. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_greater_or_equal.js +0 -0
  327. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_instance_of.d.ts +0 -0
  328. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_instance_of.js +0 -0
  329. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_is_error.d.ts +0 -0
  330. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_is_error.js +0 -0
  331. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_less.d.ts +0 -0
  332. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_less.js +0 -0
  333. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_less_or_equal.d.ts +0 -0
  334. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_less_or_equal.js +0 -0
  335. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_match.d.ts +0 -0
  336. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_match.js +0 -0
  337. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_equals.d.ts +0 -0
  338. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_equals.js +0 -0
  339. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_instance_of.d.ts +0 -0
  340. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_instance_of.js +0 -0
  341. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_match.d.ts +0 -0
  342. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_match.js +0 -0
  343. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_strict_equals.d.ts +0 -0
  344. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_not_strict_equals.js +0 -0
  345. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_object_match.d.ts +0 -0
  346. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_object_match.js +0 -0
  347. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_rejects.d.ts +0 -0
  348. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_rejects.js +0 -0
  349. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_strict_equals.d.ts +0 -0
  350. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_strict_equals.js +0 -0
  351. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_string_includes.d.ts +0 -0
  352. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_string_includes.js +0 -0
  353. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_throws.d.ts +0 -0
  354. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assert_throws.js +0 -0
  355. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assertion_error.d.ts +0 -0
  356. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/assertion_error.js +0 -0
  357. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/equal.d.ts +0 -0
  358. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/equal.js +0 -0
  359. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/fail.d.ts +0 -0
  360. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/fail.js +0 -0
  361. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/mod.d.ts +0 -0
  362. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/mod.js +0 -0
  363. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/unimplemented.d.ts +0 -0
  364. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/unimplemented.js +0 -0
  365. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/unreachable.d.ts +0 -0
  366. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/assert/unreachable.js +0 -0
  367. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/bytes/concat.d.ts +0 -0
  368. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/bytes/concat.js +0 -0
  369. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/encoding/_util.d.ts +0 -0
  370. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/encoding/_util.js +0 -0
  371. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/encoding/base64.d.ts +0 -0
  372. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/encoding/base64.js +0 -0
  373. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/fmt/colors.d.ts +0 -0
  374. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/fmt/colors.js +0 -0
  375. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/_db.d.ts +0 -0
  376. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/_db.js +0 -0
  377. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/_util.d.ts +0 -0
  378. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/_util.js +0 -0
  379. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/content_type.d.ts +0 -0
  380. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/content_type.js +0 -0
  381. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/extension.d.ts +0 -0
  382. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/extension.js +0 -0
  383. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/extensions_by_type.d.ts +0 -0
  384. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/extensions_by_type.js +0 -0
  385. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/format_media_type.d.ts +0 -0
  386. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/format_media_type.js +0 -0
  387. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/get_charset.d.ts +0 -0
  388. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/get_charset.js +0 -0
  389. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/parse_media_type.d.ts +0 -0
  390. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/parse_media_type.js +0 -0
  391. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/type_by_extension.d.ts +0 -0
  392. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/type_by_extension.js +0 -0
  393. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/vendor/mime-db.v1.52.0.d.ts +0 -0
  394. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/media_types/vendor/mime-db.v1.52.0.js +0 -0
  395. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/assert_path.d.ts +0 -0
  396. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/assert_path.js +0 -0
  397. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/basename.d.ts +0 -0
  398. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/basename.js +0 -0
  399. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/common.d.ts +0 -0
  400. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/common.js +0 -0
  401. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/constants.d.ts +0 -0
  402. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/constants.js +0 -0
  403. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/dirname.d.ts +0 -0
  404. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/dirname.js +0 -0
  405. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/format.d.ts +0 -0
  406. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/format.js +0 -0
  407. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/from_file_url.d.ts +0 -0
  408. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/from_file_url.js +0 -0
  409. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/glob_to_reg_exp.d.ts +0 -0
  410. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/glob_to_reg_exp.js +0 -0
  411. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/normalize.d.ts +0 -0
  412. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/normalize.js +0 -0
  413. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/normalize_string.d.ts +0 -0
  414. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/normalize_string.js +0 -0
  415. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/relative.d.ts +0 -0
  416. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/relative.js +0 -0
  417. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/strip_trailing_separators.d.ts +0 -0
  418. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/strip_trailing_separators.js +0 -0
  419. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/to_file_url.d.ts +0 -0
  420. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_common/to_file_url.js +0 -0
  421. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_interface.d.ts +0 -0
  422. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_interface.js +0 -0
  423. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_os.d.ts +0 -0
  424. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/_os.js +0 -0
  425. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/basename.d.ts +0 -0
  426. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/basename.js +0 -0
  427. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/common.d.ts +0 -0
  428. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/common.js +0 -0
  429. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/constants.d.ts +0 -0
  430. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/constants.js +0 -0
  431. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/dirname.d.ts +0 -0
  432. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/dirname.js +0 -0
  433. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/extname.d.ts +0 -0
  434. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/extname.js +0 -0
  435. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/format.d.ts +0 -0
  436. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/format.js +0 -0
  437. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/from_file_url.d.ts +0 -0
  438. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/from_file_url.js +0 -0
  439. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/glob_to_regexp.d.ts +0 -0
  440. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/glob_to_regexp.js +0 -0
  441. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/is_absolute.d.ts +0 -0
  442. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/is_absolute.js +0 -0
  443. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/is_glob.d.ts +0 -0
  444. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/is_glob.js +0 -0
  445. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/join.d.ts +0 -0
  446. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/join.js +0 -0
  447. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/join_globs.d.ts +0 -0
  448. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/join_globs.js +0 -0
  449. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/mod.d.ts +0 -0
  450. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/mod.js +0 -0
  451. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/normalize.d.ts +0 -0
  452. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/normalize.js +0 -0
  453. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/normalize_glob.d.ts +0 -0
  454. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/normalize_glob.js +0 -0
  455. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/parse.d.ts +0 -0
  456. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/parse.js +0 -0
  457. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/_util.d.ts +0 -0
  458. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/_util.js +0 -0
  459. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/basename.d.ts +0 -0
  460. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/basename.js +0 -0
  461. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/common.d.ts +0 -0
  462. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/common.js +0 -0
  463. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/constants.d.ts +0 -0
  464. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/constants.js +0 -0
  465. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/dirname.d.ts +0 -0
  466. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/dirname.js +0 -0
  467. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/extname.d.ts +0 -0
  468. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/extname.js +0 -0
  469. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/format.d.ts +0 -0
  470. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/format.js +0 -0
  471. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/from_file_url.d.ts +0 -0
  472. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/from_file_url.js +0 -0
  473. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/glob_to_regexp.d.ts +0 -0
  474. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/glob_to_regexp.js +0 -0
  475. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/is_absolute.d.ts +0 -0
  476. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/is_absolute.js +0 -0
  477. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/is_glob.d.ts +0 -0
  478. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/is_glob.js +0 -0
  479. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/join.d.ts +0 -0
  480. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/join.js +0 -0
  481. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/join_globs.d.ts +0 -0
  482. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/join_globs.js +0 -0
  483. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/mod.d.ts +0 -0
  484. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/mod.js +0 -0
  485. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/normalize.d.ts +0 -0
  486. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/normalize.js +0 -0
  487. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/normalize_glob.d.ts +0 -0
  488. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/normalize_glob.js +0 -0
  489. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/parse.d.ts +0 -0
  490. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/parse.js +0 -0
  491. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/relative.d.ts +0 -0
  492. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/relative.js +0 -0
  493. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/resolve.d.ts +0 -0
  494. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/resolve.js +0 -0
  495. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/to_file_url.d.ts +0 -0
  496. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/to_file_url.js +0 -0
  497. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/to_namespaced_path.d.ts +0 -0
  498. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/posix/to_namespaced_path.js +0 -0
  499. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/relative.d.ts +0 -0
  500. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/relative.js +0 -0
  501. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/resolve.d.ts +0 -0
  502. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/resolve.js +0 -0
  503. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/to_file_url.d.ts +0 -0
  504. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/to_file_url.js +0 -0
  505. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/to_namespaced_path.d.ts +0 -0
  506. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/to_namespaced_path.js +0 -0
  507. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/_util.d.ts +0 -0
  508. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/_util.js +0 -0
  509. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/basename.d.ts +0 -0
  510. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/basename.js +0 -0
  511. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/common.d.ts +0 -0
  512. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/common.js +0 -0
  513. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/constants.d.ts +0 -0
  514. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/constants.js +0 -0
  515. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/dirname.d.ts +0 -0
  516. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/dirname.js +0 -0
  517. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/extname.d.ts +0 -0
  518. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/extname.js +0 -0
  519. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/format.d.ts +0 -0
  520. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/format.js +0 -0
  521. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/from_file_url.d.ts +0 -0
  522. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/from_file_url.js +0 -0
  523. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/glob_to_regexp.d.ts +0 -0
  524. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/glob_to_regexp.js +0 -0
  525. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/is_absolute.d.ts +0 -0
  526. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/is_absolute.js +0 -0
  527. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/is_glob.d.ts +0 -0
  528. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/is_glob.js +0 -0
  529. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/join.d.ts +0 -0
  530. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/join.js +0 -0
  531. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/join_globs.d.ts +0 -0
  532. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/join_globs.js +0 -0
  533. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/mod.d.ts +0 -0
  534. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/mod.js +0 -0
  535. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/normalize.d.ts +0 -0
  536. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/normalize.js +0 -0
  537. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/normalize_glob.d.ts +0 -0
  538. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/normalize_glob.js +0 -0
  539. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/parse.d.ts +0 -0
  540. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/parse.js +0 -0
  541. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/relative.d.ts +0 -0
  542. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/relative.js +0 -0
  543. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/resolve.d.ts +0 -0
  544. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/resolve.js +0 -0
  545. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/to_file_url.d.ts +0 -0
  546. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/to_file_url.js +0 -0
  547. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/to_namespaced_path.d.ts +0 -0
  548. /package/script/deps/deno.land/{std@0.222.1 → std@0.223.0}/path/windows/to_namespaced_path.js +0 -0
  549. /package/script/types/{1_input_message_content.js → 1_message_content.js} +0 -0
@@ -1,9 +1,27 @@
1
1
  "use strict";
2
+ /**
3
+ * MTKruto - Cross-runtime JavaScript library for building Telegram clients
4
+ * Copyright (C) 2023-2024 Roj <https://roj.im/>
5
+ *
6
+ * This file is part of MTKruto.
7
+ *
8
+ * This program is free software: you can redistribute it and/or modify
9
+ * it under the terms of the GNU Lesser General Public License as published by
10
+ * the Free Software Foundation, either version 3 of the License, or
11
+ * (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful,
14
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
+ * GNU Lesser General Public License for more details.
17
+ *
18
+ * You should have received a copy of the GNU Lesser General Public License
19
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
20
+ */
2
21
  Object.defineProperty(exports, "__esModule", { value: true });
3
22
  exports.parseMarkdown = exports.CODEPOINTS = void 0;
4
23
  /**
5
24
  * Copyright (C) 2023 Dunkan
6
- * Copyright (C) 2024 Roj
7
25
  */
8
26
  const _0_deps_js_1 = require("../0_deps.js");
9
27
  const _3_types_js_1 = require("../3_types.js");
@@ -355,3 +355,7 @@ export interface EditMessageLiveLocationParams {
355
355
  /** The reply markup of the message. Bot-only. */
356
356
  replyMarkup?: ReplyMarkup;
357
357
  }
358
+ export interface SendInlineQueryParams {
359
+ query?: string;
360
+ offset?: string;
361
+ }
@@ -110,7 +110,7 @@ function getChatListId(chatList) {
110
110
  }
111
111
  exports.getChatListId = getChatListId;
112
112
  function checkMessageId(messageId) {
113
- if (typeof messageId !== "number" || isNaN(messageId) || !messageId) {
113
+ if (typeof messageId !== "number" || isNaN(messageId) || messageId <= 0) {
114
114
  throw new _0_errors_js_1.InputError("Invalid message ID");
115
115
  }
116
116
  return messageId;
@@ -18,7 +18,7 @@
18
18
  * along with this program. If not, see <https://www.gnu.org/licenses/>.
19
19
  */
20
20
  import { enums, types } from "../2_tl.js";
21
- import { Update } from "../3_types.js";
21
+ import { CallbackQueryQuestion, ID, Update } from "../3_types.js";
22
22
  import { AnswerCallbackQueryParams } from "./0_params.js";
23
23
  import { C as C_ } from "./0_types.js";
24
24
  import { MessageManager } from "./2_message_manager.js";
@@ -30,6 +30,7 @@ export declare class CallbackQueryManager {
30
30
  #private;
31
31
  constructor(c: C);
32
32
  answerCallbackQuery(id: string, params?: AnswerCallbackQueryParams): Promise<void>;
33
+ sendCallbackQuery(chatId: ID, messageId: number, question: CallbackQueryQuestion): Promise<import("../3_types.js").CallbackQueryAnswer>;
33
34
  static canHandleUpdate(update: enums.Update): update is CallbackQueryManagerUpdate;
34
35
  handleUpdate(update: CallbackQueryManagerUpdate): Promise<Update>;
35
36
  }
@@ -29,14 +29,16 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
29
29
  if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
30
30
  return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
31
31
  };
32
- var _CallbackQueryManager_c;
32
+ var _CallbackQueryManager_instances, _a, _CallbackQueryManager_c, _CallbackQueryManager_enc, _CallbackQueryManager_isExpired, _CallbackQueryManager_getPasswordCheck;
33
33
  Object.defineProperty(exports, "__esModule", { value: true });
34
34
  exports.CallbackQueryManager = void 0;
35
35
  const _2_tl_js_1 = require("../2_tl.js");
36
36
  const _3_types_js_1 = require("../3_types.js");
37
37
  const _0_utilities_js_1 = require("./0_utilities.js");
38
+ const _0_password_js_1 = require("./0_password.js");
38
39
  class CallbackQueryManager {
39
40
  constructor(c) {
41
+ _CallbackQueryManager_instances.add(this);
40
42
  _CallbackQueryManager_c.set(this, void 0);
41
43
  __classPrivateFieldSet(this, _CallbackQueryManager_c, c, "f");
42
44
  }
@@ -50,6 +52,26 @@ class CallbackQueryManager {
50
52
  alert: params?.alert ? true : undefined,
51
53
  });
52
54
  }
55
+ async sendCallbackQuery(chatId, messageId, question) {
56
+ (0, _0_utilities_js_1.checkMessageId)(messageId);
57
+ (0, _3_types_js_1.validateCallbackQueryQuestion)(question);
58
+ const peer = await __classPrivateFieldGet(this, _CallbackQueryManager_c, "f").getInputPeer(chatId), peerId = (0, _2_tl_js_1.peerToChatId)(peer), questionKey = JSON.stringify(question);
59
+ const maybeAnswer = await __classPrivateFieldGet(this, _CallbackQueryManager_c, "f").messageStorage.getCallbackQueryAnswer(peerId, messageId, questionKey);
60
+ if (maybeAnswer != null && !__classPrivateFieldGet(_a, _a, "m", _CallbackQueryManager_isExpired).call(_a, maybeAnswer[1], maybeAnswer[0].cache_time)) {
61
+ return (0, _3_types_js_1.constructCallbackQueryAnswer)(maybeAnswer[0]);
62
+ }
63
+ const answer = await __classPrivateFieldGet(this, _CallbackQueryManager_c, "f").api.messages.getBotCallbackAnswer({
64
+ peer,
65
+ msg_id: messageId,
66
+ data: "data" in question ? __classPrivateFieldGet(_a, _a, "f", _CallbackQueryManager_enc).encode(question.data) : undefined,
67
+ game: question.type == "game" ? true : undefined,
68
+ password: question.type == "password" ? await __classPrivateFieldGet(this, _CallbackQueryManager_instances, "m", _CallbackQueryManager_getPasswordCheck).call(this, question.password) : undefined,
69
+ });
70
+ if (answer.cache_time >= 0) {
71
+ await __classPrivateFieldGet(this, _CallbackQueryManager_c, "f").messageStorage.setCallbackQueryAnswer(peerId, messageId, questionKey, answer);
72
+ }
73
+ return (0, _3_types_js_1.constructCallbackQueryAnswer)(answer);
74
+ }
53
75
  static canHandleUpdate(update) {
54
76
  return update instanceof _2_tl_js_1.types.UpdateBotCallbackQuery || update instanceof _2_tl_js_1.types.UpdateInlineBotCallbackQuery;
55
77
  }
@@ -58,4 +80,10 @@ class CallbackQueryManager {
58
80
  }
59
81
  }
60
82
  exports.CallbackQueryManager = CallbackQueryManager;
61
- _CallbackQueryManager_c = new WeakMap();
83
+ _a = CallbackQueryManager, _CallbackQueryManager_c = new WeakMap(), _CallbackQueryManager_instances = new WeakSet(), _CallbackQueryManager_isExpired = function _CallbackQueryManager_isExpired(date, cacheTime) {
84
+ return (Date.now() - date.getTime()) / 1000 > cacheTime;
85
+ }, _CallbackQueryManager_getPasswordCheck = async function _CallbackQueryManager_getPasswordCheck(password) {
86
+ const ap = await __classPrivateFieldGet(this, _CallbackQueryManager_c, "f").api.account.getPassword();
87
+ return await (0, _0_password_js_1.checkPassword)(password, ap);
88
+ };
89
+ _CallbackQueryManager_enc = { value: new TextEncoder() };
@@ -18,8 +18,8 @@
18
18
  * along with this program. If not, see <https://www.gnu.org/licenses/>.
19
19
  */
20
20
  import { enums, types } from "../2_tl.js";
21
- import { InlineQueryResult, Update } from "../3_types.js";
22
- import { AnswerInlineQueryParams } from "./0_params.js";
21
+ import { ID, InlineQueryResult, Update } from "../3_types.js";
22
+ import { AnswerInlineQueryParams, SendInlineQueryParams } from "./0_params.js";
23
23
  import { C as C_ } from "./0_types.js";
24
24
  import { MessageManager } from "./2_message_manager.js";
25
25
  type C = C_ & {
@@ -32,5 +32,6 @@ export declare class InlineQueryManager {
32
32
  answerInlineQuery(id: string, results: InlineQueryResult[], params?: AnswerInlineQueryParams): Promise<void>;
33
33
  static canHandleUpdate(update: enums.Update): update is InlineQueryManagerUpdate;
34
34
  handleUpdate(update: InlineQueryManagerUpdate): Promise<Update>;
35
+ sendInlineQuery(userId: ID, chatId: ID, params?: SendInlineQueryParams): Promise<import("../3_types.js").InlineQueryAnswer>;
35
36
  }
36
37
  export {};
@@ -29,7 +29,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
29
29
  if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
30
30
  return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
31
31
  };
32
- var _InlineQueryManager_c;
32
+ var _a, _InlineQueryManager_c, _InlineQueryManager_isExpired;
33
33
  Object.defineProperty(exports, "__esModule", { value: true });
34
34
  exports.InlineQueryManager = void 0;
35
35
  const _0_deps_js_1 = require("../0_deps.js");
@@ -69,6 +69,22 @@ class InlineQueryManager {
69
69
  (0, _0_deps_js_1.unreachable)();
70
70
  }
71
71
  }
72
+ async sendInlineQuery(userId, chatId, params) {
73
+ const bot = await __classPrivateFieldGet(this, _InlineQueryManager_c, "f").getInputUser(userId), peer = await __classPrivateFieldGet(this, _InlineQueryManager_c, "f").getInputPeer(chatId), query = params?.query ?? "", offset = params?.offset ?? "";
74
+ const botId = (0, _2_tl_js_1.peerToChatId)(bot), peerId = (0, _2_tl_js_1.peerToChatId)(peer);
75
+ const maybeResults = await __classPrivateFieldGet(this, _InlineQueryManager_c, "f").messageStorage.getInlineQueryAnswer(botId, peerId, query, offset);
76
+ if (maybeResults != null && !__classPrivateFieldGet(_a, _a, "m", _InlineQueryManager_isExpired).call(_a, maybeResults[1], maybeResults[0].cache_time)) {
77
+ return (0, _3_types_js_1.constructInlineQueryAnswer)(maybeResults[0]);
78
+ }
79
+ const then = new Date();
80
+ const results = await __classPrivateFieldGet(this, _InlineQueryManager_c, "f").api.messages.getInlineBotResults({ bot, peer, query, offset });
81
+ if (results.cache_time > 0) {
82
+ await __classPrivateFieldGet(this, _InlineQueryManager_c, "f").messageStorage.setInlineQueryAnswer(botId, peerId, query, offset, results, then);
83
+ }
84
+ return (0, _3_types_js_1.constructInlineQueryAnswer)(results);
85
+ }
72
86
  }
73
87
  exports.InlineQueryManager = InlineQueryManager;
74
- _InlineQueryManager_c = new WeakMap();
88
+ _a = InlineQueryManager, _InlineQueryManager_c = new WeakMap(), _InlineQueryManager_isExpired = function _InlineQueryManager_isExpired(date, cacheTime) {
89
+ return (Date.now() - date.getTime()) / 1000 > cacheTime;
90
+ };
@@ -21,9 +21,9 @@ import { MaybePromise } from "../1_utilities.js";
21
21
  import { enums, functions, types } from "../2_tl.js";
22
22
  import { Storage } from "../3_storage.js";
23
23
  import { DC } from "../3_transport.js";
24
- import { BotCommand, BusinessConnection, Chat, ChatAction, ChatMember, ChatP, FileSource, ID, InactiveChat, InlineQueryResult, InputMedia, InputStoryContent, InviteLink, Message, MessageAnimation, MessageAudio, MessageContact, MessageDice, MessageDocument, MessageLocation, MessagePhoto, MessagePoll, MessageSticker, MessageText, MessageVenue, MessageVideo, MessageVideoNote, MessageVoice, NetworkStatistics, ParseMode, Poll, Reaction, Sticker, Story, Update, User } from "../3_types.js";
24
+ import { BotCommand, BusinessConnection, CallbackQueryAnswer, CallbackQueryQuestion, Chat, ChatAction, ChatMember, ChatP, FileSource, ID, InactiveChat, InlineQueryAnswer, InlineQueryResult, InputMedia, InputStoryContent, InviteLink, Message, MessageAnimation, MessageAudio, MessageContact, MessageDice, MessageDocument, MessageLocation, MessagePhoto, MessagePoll, MessageSticker, MessageText, MessageVenue, MessageVideo, MessageVideoNote, MessageVoice, NetworkStatistics, ParseMode, Poll, Reaction, Sticker, Story, Update, User } from "../3_types.js";
25
25
  import { Migrate } from "../4_errors.js";
26
- import { AddReactionParams, AnswerCallbackQueryParams, AnswerInlineQueryParams, AuthorizeUserParams, BanChatMemberParams, CreateInviteLinkParams, CreateStoryParams, DeleteMessageParams, DeleteMessagesParams, DownloadParams, EditMessageLiveLocationParams, EditMessageMediaParams, EditMessageParams, EditMessageReplyMarkupParams, ForwardMessagesParams, GetChatsParams, GetCreatedInviteLinksParams, GetHistoryParams, GetMyCommandsParams, PinMessageParams, ReplyParams, SearchMessagesParams, SendAnimationParams, SendAudioParams, SendContactParams, SendDiceParams, SendDocumentParams, SendLocationParams, SendMessageParams, SendPhotoParams, SendPollParams, SendStickerParams, SendVenueParams, SendVideoNoteParams, SendVideoParams, SendVoiceParams, SetChatMemberRightsParams, SetChatPhotoParams, SetMyCommandsParams, SetReactionsParams, StopPollParams } from "./0_params.js";
26
+ import { AddReactionParams, AnswerCallbackQueryParams, AnswerInlineQueryParams, AuthorizeUserParams, BanChatMemberParams, CreateInviteLinkParams, CreateStoryParams, DeleteMessageParams, DeleteMessagesParams, DownloadParams, EditMessageLiveLocationParams, EditMessageMediaParams, EditMessageParams, EditMessageReplyMarkupParams, ForwardMessagesParams, GetChatsParams, GetCreatedInviteLinksParams, GetHistoryParams, GetMyCommandsParams, PinMessageParams, ReplyParams, SearchMessagesParams, SendAnimationParams, SendAudioParams, SendContactParams, SendDiceParams, SendDocumentParams, SendInlineQueryParams, SendLocationParams, SendMessageParams, SendPhotoParams, SendPollParams, SendStickerParams, SendVenueParams, SendVideoNoteParams, SendVideoParams, SendVoiceParams, SetChatMemberRightsParams, SetChatPhotoParams, SetMyCommandsParams, SetReactionsParams, StopPollParams } from "./0_params.js";
27
27
  import { Api } from "./0_types.js";
28
28
  import { ClientPlainParams } from "./1_client_plain.js";
29
29
  import { Composer as Composer_, NextFunction } from "./1_composer.js";
@@ -184,9 +184,9 @@ export declare const restartAuth: unique symbol;
184
184
  export declare const handleMigrationError: unique symbol;
185
185
  declare const getEntity: unique symbol;
186
186
  export interface ClientParams extends ClientPlainParams {
187
- /** A parse mode to use when the `parseMode` parameter is not specified when sending or editing messages. Defauls to `ParseMode.None`. */
187
+ /** A parse mode to use when the `parseMode` parameter is not specified when sending or editing messages. Defaults to `ParseMode.None`. */
188
188
  parseMode?: ParseMode;
189
- /** The app_version parameter to be passed to initConnection when calling `authorize`. It is recommended that this parameter is changed if users are authorized. Defaults to "MTKruto" followed by this version of MTKruto. */
189
+ /** The app_version parameter to be passed to initConnection when calling `authorize`. It is recommended that this parameter is changed if users are authorized. Defaults to _MTKruto_. */
190
190
  appVersion?: string;
191
191
  /** The device_version parameter to be passed to initConnection when calling `authorize`. The default varies by the current runtime. */
192
192
  deviceModel?: string;
@@ -865,6 +865,16 @@ export declare class Client<C extends Context = Context> extends Composer<C> {
865
865
  * @returns The newly created invite link.
866
866
  */
867
867
  createInviteLink(chatId: ID, params?: CreateInviteLinkParams): Promise<InviteLink>;
868
+ /**
869
+ * Send a callback query. User-only.
870
+ *
871
+ * @method cq
872
+ * @param chatId The chat that includes the messsage.
873
+ * @param messageId The message that includes at a button responsible for the callback query question.
874
+ * @param question The callback query's question.
875
+ * @returns The bot's answer to the callback query.
876
+ */
877
+ sendCallbackQuery(chatId: ID, messageId: number, question: CallbackQueryQuestion): Promise<CallbackQueryAnswer>;
868
878
  /**
869
879
  * Answer a callback query. Bot-only.
870
880
  *
@@ -872,6 +882,15 @@ export declare class Client<C extends Context = Context> extends Composer<C> {
872
882
  * @param id ID of the callback query to answer.
873
883
  */
874
884
  answerCallbackQuery(id: string, params?: AnswerCallbackQueryParams): Promise<void>;
885
+ /**
886
+ * Send an inline query. User-only.
887
+ *
888
+ * @method iq
889
+ * @param userId The ID of the bot to send the inline query to.
890
+ * @param chatId The ID of the chat from which the inline query is sent.
891
+ * @returns The bot's answer to the inline query.
892
+ */
893
+ sendInlineQuery(userId: ID, chatId: ID, params?: SendInlineQueryParams): Promise<InlineQueryAnswer>;
875
894
  /**
876
895
  * Answer an inline query. Bot-only.
877
896
  *
@@ -2015,6 +2015,18 @@ class Client extends Composer {
2015
2015
  //
2016
2016
  // ========================= CALLBACK QUERIES ========================= //
2017
2017
  //
2018
+ /**
2019
+ * Send a callback query. User-only.
2020
+ *
2021
+ * @method cq
2022
+ * @param chatId The chat that includes the messsage.
2023
+ * @param messageId The message that includes at a button responsible for the callback query question.
2024
+ * @param question The callback query's question.
2025
+ * @returns The bot's answer to the callback query.
2026
+ */
2027
+ async sendCallbackQuery(chatId, messageId, question) {
2028
+ return await __classPrivateFieldGet(this, _Client_callbackQueryManager, "f").sendCallbackQuery(chatId, messageId, question);
2029
+ }
2018
2030
  /**
2019
2031
  * Answer a callback query. Bot-only.
2020
2032
  *
@@ -2027,6 +2039,17 @@ class Client extends Composer {
2027
2039
  //
2028
2040
  // ========================= INLINE QUERIES ========================= //
2029
2041
  //
2042
+ /**
2043
+ * Send an inline query. User-only.
2044
+ *
2045
+ * @method iq
2046
+ * @param userId The ID of the bot to send the inline query to.
2047
+ * @param chatId The ID of the chat from which the inline query is sent.
2048
+ * @returns The bot's answer to the inline query.
2049
+ */
2050
+ async sendInlineQuery(userId, chatId, params) {
2051
+ return await __classPrivateFieldGet(this, _Client_inlineQueryManager, "f").sendInlineQuery(userId, chatId, params);
2052
+ }
2030
2053
  /**
2031
2054
  * Answer an inline query. Bot-only.
2032
2055
  *
@@ -60,6 +60,10 @@ export declare const K: {
60
60
  customEmojiDocument: (id: bigint) => StorageKeyPart[];
61
61
  businessConnections: () => StorageKeyPart[];
62
62
  businessConnection: (id: string) => StorageKeyPart[];
63
+ inlineQueryAnswers: () => StorageKeyPart[];
64
+ inlineQueryAnswer: (userId: number, chatId: number, query: string, offset: string) => StorageKeyPart[];
65
+ callbackQueryAnswers: () => StorageKeyPart[];
66
+ callbackQueryAnswer: (chatId: number, messageId: number, question: string) => StorageKeyPart[];
63
67
  };
64
68
  messages: {
65
69
  P: (string: string) => string;
@@ -149,6 +153,10 @@ export declare abstract class Storage {
149
153
  getCustomEmojiDocument(id: bigint): Promise<[types.Document, Date] | null>;
150
154
  setBusinessConnection(id: string, connection: types.BotBusinessConnection | null): Promise<void>;
151
155
  getBusinessConnection(id: string): Promise<types.BotBusinessConnection | null>;
156
+ setInlineQueryAnswer(userId: number, chatId: number, query: string, offset: string, results: types.messages.BotResults, date: Date): Promise<void>;
157
+ getInlineQueryAnswer(userId: number, chatId: number, query: string, offset: string): Promise<[types.messages.BotResults, Date] | null>;
158
+ setCallbackQueryAnswer(chatId: number, messageId: number, question: string, answer: types.messages.BotCallbackAnswer): Promise<void>;
159
+ getCallbackQueryAnswer(chatId: number, messageId: number, question: string): Promise<[types.messages.BotCallbackAnswer, Date] | null>;
152
160
  setUpdate(boxId: bigint, update: enums.Update): Promise<void>;
153
161
  deleteUpdates(): Promise<void>;
154
162
  getFirstUpdate(boxId: bigint): Promise<[readonly StorageKeyPart[], enums.Update] | null>;
@@ -157,6 +165,8 @@ export declare abstract class Storage {
157
165
  deleteFiles(): Promise<void>;
158
166
  deleteCustomEmojiDocuments(): Promise<void>;
159
167
  deleteBusinessConnections(): Promise<void>;
168
+ deleteInlineQueryAnswers(): Promise<void>;
169
+ deleteCallbackQueryAnswers(): Promise<void>;
160
170
  deleteStickerSetNames(): Promise<void>;
161
171
  deletePeers(): Promise<void>;
162
172
  deleteUsernames(): Promise<void>;
@@ -76,6 +76,10 @@ exports.K = {
76
76
  customEmojiDocument: (id) => [...exports.K.cache.customEmojiDocuments(), id],
77
77
  businessConnections: () => [exports.K.cache.P("businessConnections")],
78
78
  businessConnection: (id) => [...exports.K.cache.businessConnections(), id],
79
+ inlineQueryAnswers: () => [exports.K.cache.P("inlineQueryResults")],
80
+ inlineQueryAnswer: (userId, chatId, query, offset) => [...exports.K.cache.inlineQueryAnswers(), userId, chatId, query, offset],
81
+ callbackQueryAnswers: () => [exports.K.cache.P("callbackQueryAnswers")],
82
+ callbackQueryAnswer: (chatId, messageId, question) => [...exports.K.cache.callbackQueryAnswers(), chatId, messageId, question],
79
83
  },
80
84
  messages: {
81
85
  P: (string) => `messages.${string}`,
@@ -404,6 +408,32 @@ class Storage {
404
408
  return null;
405
409
  }
406
410
  }
411
+ async setInlineQueryAnswer(userId, chatId, query, offset, results, date) {
412
+ await this.set(exports.K.cache.inlineQueryAnswer(userId, chatId, query, offset), [this.isMemoryStorage ? results : (0, _1_utilities_js_1.rleEncode)(results[_2_tl_js_1.serialize]()), date]);
413
+ }
414
+ async getInlineQueryAnswer(userId, chatId, query, offset) {
415
+ const peer_ = await this.get(exports.K.cache.inlineQueryAnswer(userId, chatId, query, offset));
416
+ if (peer_ != null) {
417
+ const [obj_, date] = peer_;
418
+ return [await this.getTlObject(obj_), date];
419
+ }
420
+ else {
421
+ return null;
422
+ }
423
+ }
424
+ async setCallbackQueryAnswer(chatId, messageId, question, answer) {
425
+ await this.set(exports.K.cache.callbackQueryAnswer(chatId, messageId, question), [this.isMemoryStorage ? answer : (0, _1_utilities_js_1.rleEncode)(answer[_2_tl_js_1.serialize]()), new Date()]);
426
+ }
427
+ async getCallbackQueryAnswer(chatId, messageId, question) {
428
+ const peer_ = await this.get(exports.K.cache.callbackQueryAnswer(chatId, messageId, question));
429
+ if (peer_ != null) {
430
+ const [obj_, date] = peer_;
431
+ return [await this.getTlObject(obj_), date];
432
+ }
433
+ else {
434
+ return null;
435
+ }
436
+ }
407
437
  async setUpdate(boxId, update) {
408
438
  await this.setTlObject(exports.K.updates.update(boxId, __classPrivateFieldGet(this, _Storage_instances, "m", _Storage_getUpdateId).call(this, update)), update);
409
439
  }
@@ -451,6 +481,16 @@ class Storage {
451
481
  await this.set(key, null);
452
482
  }
453
483
  }
484
+ async deleteInlineQueryAnswers() {
485
+ for await (const [key] of await this.getMany({ prefix: exports.K.cache.inlineQueryAnswers() })) {
486
+ await this.set(key, null);
487
+ }
488
+ }
489
+ async deleteCallbackQueryAnswers() {
490
+ for await (const [key] of await this.getMany({ prefix: exports.K.cache.callbackQueryAnswers() })) {
491
+ await this.set(key, null);
492
+ }
493
+ }
454
494
  async deleteStickerSetNames() {
455
495
  for await (const [key] of await this.getMany({ prefix: exports.K.cache.stickerSetNames() })) {
456
496
  await this.set(key, null);
@@ -475,6 +515,8 @@ class Storage {
475
515
  this.deleteFiles(),
476
516
  this.deleteCustomEmojiDocuments(),
477
517
  this.deleteBusinessConnections(),
518
+ this.deleteInlineQueryAnswers(),
519
+ this.deleteCallbackQueryAnswers(),
478
520
  this.deleteStickerSetNames(),
479
521
  this.deletePeers(),
480
522
  this.deleteUsernames(),
@@ -0,0 +1,30 @@
1
+ /**
2
+ * MTKruto - Cross-runtime JavaScript library for building Telegram clients
3
+ * Copyright (C) 2023-2024 Roj <https://roj.im/>
4
+ *
5
+ * This file is part of MTKruto.
6
+ *
7
+ * This program is free software: you can redistribute it and/or modify
8
+ * it under the terms of the GNU Lesser General Public License as published by
9
+ * the Free Software Foundation, either version 3 of the License, or
10
+ * (at your option) any later version.
11
+ *
12
+ * This program is distributed in the hope that it will be useful,
13
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
+ * GNU Lesser General Public License for more details.
16
+ *
17
+ * You should have received a copy of the GNU Lesser General Public License
18
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
19
+ */
20
+ import { types } from "../2_tl.js";
21
+ /** An answer to a callback query. */
22
+ export interface CallbackQueryAnswer {
23
+ /** Whether the answer should be shown as an alert. */
24
+ alert: boolean;
25
+ /** The text of the answer. */
26
+ text: string;
27
+ /** A potential URL that is to be opened. */
28
+ url: string;
29
+ }
30
+ export declare function constructCallbackQueryAnswer(answer: types.messages.BotCallbackAnswer): CallbackQueryAnswer;
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ /**
3
+ * MTKruto - Cross-runtime JavaScript library for building Telegram clients
4
+ * Copyright (C) 2023-2024 Roj <https://roj.im/>
5
+ *
6
+ * This file is part of MTKruto.
7
+ *
8
+ * This program is free software: you can redistribute it and/or modify
9
+ * it under the terms of the GNU Lesser General Public License as published by
10
+ * the Free Software Foundation, either version 3 of the License, or
11
+ * (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful,
14
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
+ * GNU Lesser General Public License for more details.
17
+ *
18
+ * You should have received a copy of the GNU Lesser General Public License
19
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
20
+ */
21
+ Object.defineProperty(exports, "__esModule", { value: true });
22
+ exports.constructCallbackQueryAnswer = void 0;
23
+ function constructCallbackQueryAnswer(answer) {
24
+ return {
25
+ alert: !!answer.alert,
26
+ text: answer.message ?? "",
27
+ url: answer.url ?? "",
28
+ };
29
+ }
30
+ exports.constructCallbackQueryAnswer = constructCallbackQueryAnswer;
@@ -0,0 +1,49 @@
1
+ /**
2
+ * MTKruto - Cross-runtime JavaScript library for building Telegram clients
3
+ * Copyright (C) 2023-2024 Roj <https://roj.im/>
4
+ *
5
+ * This file is part of MTKruto.
6
+ *
7
+ * This program is free software: you can redistribute it and/or modify
8
+ * it under the terms of the GNU Lesser General Public License as published by
9
+ * the Free Software Foundation, either version 3 of the License, or
10
+ * (at your option) any later version.
11
+ *
12
+ * This program is distributed in the hope that it will be useful,
13
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
+ * GNU Lesser General Public License for more details.
16
+ *
17
+ * You should have received a copy of the GNU Lesser General Public License
18
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
19
+ */
20
+ /**
21
+ * A reference to a button for opening the bot's game.
22
+ * @unlisted
23
+ */
24
+ export interface CallbackQueryQuestionGame {
25
+ type: "game";
26
+ }
27
+ /**
28
+ * A reference to a password confirmation button.
29
+ * @unlisted
30
+ */
31
+ export interface CallbackQueryQuestionPassword {
32
+ type: "password";
33
+ /** The target button's callback data. */
34
+ data: string;
35
+ /** The account's password. */
36
+ password: string;
37
+ }
38
+ /**
39
+ * A reference to a usual button.
40
+ * @unlisted
41
+ */
42
+ export interface CallbackQueryQuestionButton {
43
+ type: "button";
44
+ /** The target button's callback data. */
45
+ data: string;
46
+ }
47
+ /** A reference to a button that is to be clicked by a user. */
48
+ export type CallbackQueryQuestion = CallbackQueryQuestionGame | CallbackQueryQuestionPassword | CallbackQueryQuestionButton;
49
+ export declare function validateCallbackQueryQuestion(q: CallbackQueryQuestion): void;
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+ /**
3
+ * MTKruto - Cross-runtime JavaScript library for building Telegram clients
4
+ * Copyright (C) 2023-2024 Roj <https://roj.im/>
5
+ *
6
+ * This file is part of MTKruto.
7
+ *
8
+ * This program is free software: you can redistribute it and/or modify
9
+ * it under the terms of the GNU Lesser General Public License as published by
10
+ * the Free Software Foundation, either version 3 of the License, or
11
+ * (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful,
14
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
+ * GNU Lesser General Public License for more details.
17
+ *
18
+ * You should have received a copy of the GNU Lesser General Public License
19
+ * along with this program. If not, see <https://www.gnu.org/licenses/>.
20
+ */
21
+ Object.defineProperty(exports, "__esModule", { value: true });
22
+ exports.validateCallbackQueryQuestion = void 0;
23
+ const _0_errors_js_1 = require("../0_errors.js");
24
+ function validateCallbackQueryQuestion(q) {
25
+ if (!["game", "password", "button"].includes(q.type)) {
26
+ throw new _0_errors_js_1.InputError("Got invalid callback query question type.");
27
+ }
28
+ if (q.type == "password" && (typeof q.password !== "string" || !q.password)) {
29
+ throw new _0_errors_js_1.InputError("Got empty password.");
30
+ }
31
+ if ((q.type == "button" || q.type == "password") && (typeof q.data !== "string" || !q.data)) {
32
+ throw new _0_errors_js_1.InputError("Got empty button data.");
33
+ }
34
+ }
35
+ exports.validateCallbackQueryQuestion = validateCallbackQueryQuestion;
@@ -25,7 +25,7 @@ import { PriceTag } from "./0_price_tag.js";
25
25
  * A message content that shares a contact.
26
26
  * @unlisted
27
27
  */
28
- export interface InputMessageContentContact {
28
+ export interface MessageContentContact {
29
29
  /** The contact's phone number. */
30
30
  phoneNumber: string;
31
31
  /** The contact's first name. */
@@ -39,7 +39,7 @@ export interface InputMessageContentContact {
39
39
  * A message content that shares a location.
40
40
  * @unlisted
41
41
  */
42
- export interface InputMessageContentLocation {
42
+ export interface MessageContentLocation {
43
43
  /** The latitude of the location. */
44
44
  latitude: number;
45
45
  /** The longitude of the location. */
@@ -57,7 +57,7 @@ export interface InputMessageContentLocation {
57
57
  * A message content that shares a venue.
58
58
  * @unlisted
59
59
  */
60
- export interface InputMessageContentVenue {
60
+ export interface MessageContentVenue {
61
61
  /** The latitude of the venue. */
62
62
  latitude: number;
63
63
  /** The longitude of the venue. */
@@ -76,7 +76,7 @@ export interface InputMessageContentVenue {
76
76
  googlePlaceType?: string;
77
77
  }
78
78
  /** @unlisted */
79
- export interface InputMessageContentText {
79
+ export interface MessageContentText {
80
80
  /** The message's text. */
81
81
  messageText: string;
82
82
  /** The parse mode to use. If not provided, the default parse mode will be used. */
@@ -87,7 +87,7 @@ export interface InputMessageContentText {
87
87
  linkPreview?: LinkPreview;
88
88
  }
89
89
  /** @unlisted */
90
- export interface InputMessageContentInvoice {
90
+ export interface MessageContentInvoice {
91
91
  title: string;
92
92
  description: string;
93
93
  payload: string;
@@ -110,4 +110,4 @@ export interface InputMessageContentInvoice {
110
110
  isFlexible?: boolean;
111
111
  }
112
112
  /** The content of a message to be returned as an inline query result. */
113
- export type InputMessageContent = InputMessageContentText | InputMessageContentLocation | InputMessageContentVenue | InputMessageContentContact | InputMessageContentInvoice;
113
+ export type MessageContent = MessageContentText | MessageContentLocation | MessageContentVenue | MessageContentContact | MessageContentInvoice;
@@ -34,3 +34,7 @@ export interface Photo {
34
34
  thumbnails: Thumbnail[];
35
35
  }
36
36
  export declare function constructPhoto(photo: types.Photo): Photo;
37
+ export declare function getPhotoSizes(photo: types.Photo): {
38
+ sizes: types.PhotoSize[];
39
+ largest: types.PhotoSize;
40
+ };
@@ -19,12 +19,22 @@
19
19
  * along with this program. If not, see <https://www.gnu.org/licenses/>.
20
20
  */
21
21
  Object.defineProperty(exports, "__esModule", { value: true });
22
- exports.constructPhoto = void 0;
22
+ exports.getPhotoSizes = exports.constructPhoto = void 0;
23
23
  const _2_tl_js_1 = require("../2_tl.js");
24
24
  const _file_id_js_1 = require("./_file_id.js");
25
- const _file_id_js_2 = require("./_file_id.js");
26
25
  const _0_thumbnail_js_1 = require("./0_thumbnail.js");
27
26
  function constructPhoto(photo) {
27
+ const { sizes, largest } = getPhotoSizes(photo);
28
+ return {
29
+ ...(0, _file_id_js_1.getPhotoFileId)(photo),
30
+ width: largest.w,
31
+ height: largest.h,
32
+ fileSize: largest.size,
33
+ thumbnails: sizes.slice(0, -1).map((v) => (0, _0_thumbnail_js_1.constructThumbnail)(v, photo)),
34
+ };
35
+ }
36
+ exports.constructPhoto = constructPhoto;
37
+ function getPhotoSizes(photo) {
28
38
  const sizes = photo.sizes
29
39
  .map((v) => {
30
40
  if (v instanceof _2_tl_js_1.types.PhotoSizeProgressive) {
@@ -37,29 +47,6 @@ function constructPhoto(photo) {
37
47
  .filter((v) => v instanceof _2_tl_js_1.types.PhotoSize)
38
48
  .sort((a, b) => a.size - b.size);
39
49
  const largest = sizes.slice(-1)[0];
40
- const { dc_id: dcId, id, access_hash: accessHash, file_reference: fileReference } = photo;
41
- const fileId_ = {
42
- type: _file_id_js_2.FileType.Photo,
43
- dcId,
44
- fileReference,
45
- location: {
46
- type: "photo",
47
- id,
48
- accessHash,
49
- source: {
50
- type: _file_id_js_1.PhotoSourceType.Thumbnail,
51
- fileType: _file_id_js_2.FileType.Photo,
52
- thumbnailType: largest.type.charCodeAt(0),
53
- },
54
- },
55
- };
56
- return {
57
- fileId: (0, _file_id_js_2.serializeFileId)(fileId_),
58
- fileUniqueId: (0, _file_id_js_2.toUniqueFileId)(fileId_),
59
- width: largest.w,
60
- height: largest.h,
61
- fileSize: largest.size,
62
- thumbnails: sizes.slice(0, -1).map((v) => (0, _0_thumbnail_js_1.constructThumbnail)(v, photo)),
63
- };
50
+ return { sizes, largest };
64
51
  }
65
- exports.constructPhoto = constructPhoto;
52
+ exports.getPhotoSizes = getPhotoSizes;