@mtkruto/node 0.1.144 → 0.1.145
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/0_deps.d.ts +4 -4
- package/esm/0_deps.js +5 -5
- package/esm/4_constants.d.ts +2 -2
- package/esm/4_constants.js +2 -2
- package/esm/client/0_types.d.ts +1 -0
- package/esm/client/1_update_manager.js +33 -13
- package/esm/client/2_message_manager.d.ts +1 -1
- package/esm/client/2_message_manager.js +15 -15
- package/esm/client/4_client.d.ts +2 -0
- package/esm/client/4_client.js +1 -1
- package/esm/deps/deno.land/std@0.212.0/assert/_constants.js +2 -0
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_diff.js +39 -18
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_format.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_almost_equals.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_array_includes.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_equals.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_exists.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_false.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_greater.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_greater_or_equal.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_instance_of.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_is_error.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_less.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_less_or_equal.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_match.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_equals.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_instance_of.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_match.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_strict_equals.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_object_match.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_rejects.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_strict_equals.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_string_includes.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_throws.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assertion_error.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/equal.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/fail.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/mod.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/unimplemented.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/unreachable.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/encoding/_util.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/encoding/base64.js +1 -1
- package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.212.0}/fmt/colors.d.ts +16 -11
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/fmt/colors.js +14 -11
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/_db.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/_util.js +8 -6
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/content_type.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/extension.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/extensions_by_type.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/format_media_type.js +2 -2
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/get_charset.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/parse_media_type.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/type_by_extension.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/vendor/mime-db.v1.52.0.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/assert_path.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/basename.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/common.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/constants.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/dirname.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/format.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/from_file_url.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/glob_to_reg_exp.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/normalize.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/normalize_string.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/relative.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/strip_trailing_separators.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/to_file_url.js +1 -1
- package/esm/deps/deno.land/std@0.212.0/path/_interface.js +3 -0
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_os.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/basename.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/common.d.ts +2 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/common.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/dirname.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/extname.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/format.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/from_file_url.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/glob_to_regexp.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/is_absolute.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/is_glob.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/join.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/join_globs.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/mod.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/normalize.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/normalize_glob.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/parse.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/_util.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/basename.js +1 -1
- package/{script/deps/deno.land/std@0.210.0/path → esm/deps/deno.land/std@0.212.0/path/posix}/common.d.ts +2 -1
- package/esm/deps/deno.land/{std@0.210.0/path/windows → std@0.212.0/path/posix}/common.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/dirname.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/extname.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/format.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/from_file_url.d.ts +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/from_file_url.js +2 -2
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/glob_to_regexp.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/is_absolute.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/is_glob.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/join.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/join_globs.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/mod.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/normalize.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/normalize_glob.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/parse.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/relative.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/resolve.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/separator.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/to_file_url.d.ts +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/to_file_url.js +2 -2
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/to_namespaced_path.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/relative.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/resolve.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/separator.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/to_file_url.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/to_namespaced_path.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/_util.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/basename.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0/path/posix → std@0.212.0/path/windows}/common.d.ts +2 -1
- package/esm/deps/deno.land/{std@0.210.0/path/posix → std@0.212.0/path/windows}/common.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/dirname.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/extname.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/format.js +1 -1
- package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.212.0}/path/windows/from_file_url.d.ts +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/from_file_url.js +2 -2
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/glob_to_regexp.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/is_absolute.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/is_glob.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/join.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/join_globs.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/mod.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/normalize.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/normalize_glob.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/parse.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/relative.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/resolve.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/separator.js +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/to_file_url.d.ts +1 -1
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/to_file_url.js +2 -2
- package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/to_namespaced_path.js +1 -1
- package/esm/storage/0_storage.d.ts +3 -6
- package/esm/storage/0_storage.js +16 -16
- package/esm/tl/2_types.d.ts +218 -4
- package/esm/tl/2_types.js +632 -19
- package/esm/tl/3_functions.d.ts +232 -0
- package/esm/tl/3_functions.js +608 -4
- package/esm/types/0_message_entity.d.ts +2 -1
- package/esm/types/0_message_entity.js +27 -4
- package/esm/types/1_chat_p.js +1 -1
- package/esm/types/4_inline_query_result.d.ts +1 -1
- package/esm/types/4_inline_query_result.js +2 -2
- package/package.json +1 -1
- package/script/0_deps.d.ts +4 -4
- package/script/0_deps.js +5 -5
- package/script/4_constants.d.ts +2 -2
- package/script/4_constants.js +2 -2
- package/script/client/0_types.d.ts +1 -0
- package/script/client/1_update_manager.js +33 -13
- package/script/client/2_message_manager.d.ts +1 -1
- package/script/client/2_message_manager.js +15 -15
- package/script/client/4_client.d.ts +2 -0
- package/script/client/4_client.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_constants.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_diff.js +39 -18
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_format.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_almost_equals.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_array_includes.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_equals.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_exists.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_false.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_greater.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_greater_or_equal.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_instance_of.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_is_error.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_less.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_less_or_equal.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_match.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_equals.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_instance_of.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_match.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_strict_equals.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_object_match.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_rejects.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_strict_equals.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_string_includes.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_throws.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assertion_error.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/equal.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/fail.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/mod.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/unimplemented.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/unreachable.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/encoding/_util.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/encoding/base64.js +1 -1
- package/{esm/deps/deno.land/std@0.210.0 → script/deps/deno.land/std@0.212.0}/fmt/colors.d.ts +16 -11
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/fmt/colors.js +14 -11
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/_db.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/_util.js +8 -6
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/content_type.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/extension.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/extensions_by_type.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/format_media_type.js +2 -2
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/get_charset.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/parse_media_type.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/type_by_extension.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/vendor/mime-db.v1.52.0.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/assert_path.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/basename.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/common.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/constants.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/dirname.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/format.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/from_file_url.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/glob_to_reg_exp.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/normalize.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/normalize_string.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/relative.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/strip_trailing_separators.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/to_file_url.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_interface.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_os.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/basename.js +1 -1
- package/{esm/deps/deno.land/std@0.210.0/path/windows → script/deps/deno.land/std@0.212.0/path}/common.d.ts +2 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/common.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/dirname.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/extname.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/format.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/from_file_url.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/glob_to_regexp.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/is_absolute.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/is_glob.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/join.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/join_globs.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/mod.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/normalize.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/normalize_glob.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/parse.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/_util.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/basename.js +1 -1
- package/script/deps/deno.land/std@0.212.0/path/posix/common.d.ts +14 -0
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/common.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/dirname.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/extname.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/format.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/from_file_url.d.ts +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/from_file_url.js +2 -2
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/glob_to_regexp.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/is_absolute.js +1 -1
- package/script/deps/deno.land/{std@0.210.0/path/windows → std@0.212.0/path/posix}/is_glob.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/join.js +1 -1
- package/script/deps/deno.land/{std@0.210.0/path/windows → std@0.212.0/path/posix}/join_globs.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/mod.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/normalize.js +1 -1
- package/script/deps/deno.land/{std@0.210.0/path/windows → std@0.212.0/path/posix}/normalize_glob.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/parse.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/relative.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/resolve.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/separator.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/to_file_url.d.ts +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/to_file_url.js +2 -2
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/to_namespaced_path.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/relative.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/resolve.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/separator.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/to_file_url.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/to_namespaced_path.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/_util.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/basename.js +1 -1
- package/script/deps/deno.land/std@0.212.0/path/windows/common.d.ts +14 -0
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/common.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/dirname.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/extname.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/format.js +1 -1
- package/{esm/deps/deno.land/std@0.210.0 → script/deps/deno.land/std@0.212.0}/path/windows/from_file_url.d.ts +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/from_file_url.js +2 -2
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/glob_to_regexp.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/is_absolute.js +1 -1
- package/script/deps/deno.land/{std@0.210.0/path/posix → std@0.212.0/path/windows}/is_glob.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/join.js +1 -1
- package/script/deps/deno.land/{std@0.210.0/path/posix → std@0.212.0/path/windows}/join_globs.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/mod.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/normalize.js +1 -1
- package/script/deps/deno.land/{std@0.210.0/path/posix → std@0.212.0/path/windows}/normalize_glob.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/parse.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/relative.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/resolve.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/separator.js +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/to_file_url.d.ts +1 -1
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/to_file_url.js +2 -2
- package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/to_namespaced_path.js +1 -1
- package/script/storage/0_storage.d.ts +3 -6
- package/script/storage/0_storage.js +16 -16
- package/script/tl/2_types.d.ts +218 -4
- package/script/tl/2_types.js +674 -44
- package/script/tl/3_functions.d.ts +232 -0
- package/script/tl/3_functions.js +629 -14
- package/script/types/0_message_entity.d.ts +2 -1
- package/script/types/0_message_entity.js +27 -4
- package/script/types/1_chat_p.js +1 -1
- package/script/types/4_inline_query_result.d.ts +1 -1
- package/script/types/4_inline_query_result.js +2 -2
- package/esm/deps/deno.land/std@0.210.0/assert/_constants.js +0 -2
- package/esm/deps/deno.land/std@0.210.0/path/_interface.js +0 -3
- package/script/deps/deno.land/std@0.210.0/path/posix/common.d.ts +0 -13
- package/script/deps/deno.land/std@0.210.0/path/windows/common.d.ts +0 -13
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_constants.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_diff.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_almost_equals.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_array_includes.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_equals.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_exists.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_false.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_greater.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_greater_or_equal.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_instance_of.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_is_error.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_less.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_less_or_equal.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_match.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_equals.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_instance_of.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_match.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_strict_equals.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_object_match.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_rejects.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_strict_equals.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_string_includes.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_throws.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assertion_error.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/equal.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/fail.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/mod.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/unimplemented.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/unreachable.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/encoding/_util.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/encoding/base64.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/_db.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/_util.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/content_type.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/extension.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/extensions_by_type.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/format_media_type.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/get_charset.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/parse_media_type.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/type_by_extension.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/vendor/mime-db.v1.52.0.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/assert_path.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/basename.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/common.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/constants.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/dirname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/from_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/glob_to_reg_exp.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/normalize.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/normalize_string.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/relative.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/strip_trailing_separators.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/to_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_interface.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_os.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/basename.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/dirname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/extname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/from_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/glob_to_regexp.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/is_absolute.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/is_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/join.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/join_globs.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/mod.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/normalize.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/normalize_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/parse.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/_util.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/basename.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/dirname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/extname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/glob_to_regexp.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/is_absolute.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/is_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/join.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/join_globs.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/mod.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/normalize.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/normalize_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/parse.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/relative.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/resolve.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/separator.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/to_namespaced_path.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/relative.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/resolve.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/separator.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/to_file_url.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/to_namespaced_path.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/_util.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/basename.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/dirname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/extname.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/format.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/glob_to_regexp.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/is_absolute.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/is_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/join.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/join_globs.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/mod.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/normalize.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/normalize_glob.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/parse.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/relative.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/resolve.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/separator.d.ts +0 -0
- /package/esm/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/to_namespaced_path.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_constants.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_diff.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/_format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_almost_equals.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_array_includes.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_equals.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_exists.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_false.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_greater.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_greater_or_equal.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_instance_of.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_is_error.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_less.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_less_or_equal.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_match.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_equals.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_instance_of.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_match.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_not_strict_equals.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_object_match.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_rejects.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_strict_equals.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_string_includes.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assert_throws.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/assertion_error.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/equal.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/fail.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/mod.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/unimplemented.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/assert/unreachable.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/encoding/_util.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/encoding/base64.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/_db.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/_util.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/content_type.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/extension.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/extensions_by_type.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/format_media_type.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/get_charset.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/parse_media_type.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/type_by_extension.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/media_types/vendor/mime-db.v1.52.0.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/assert_path.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/basename.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/common.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/constants.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/dirname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/from_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/glob_to_reg_exp.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/normalize.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/normalize_string.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/relative.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/strip_trailing_separators.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_common/to_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_interface.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/_os.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/basename.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/dirname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/extname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/from_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/glob_to_regexp.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/is_absolute.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/is_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/join.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/join_globs.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/mod.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/normalize.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/normalize_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/parse.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/_util.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/basename.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/dirname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/extname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/glob_to_regexp.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/is_absolute.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/is_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/join.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/join_globs.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/mod.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/normalize.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/normalize_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/parse.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/relative.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/resolve.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/separator.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/posix/to_namespaced_path.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/relative.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/resolve.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/separator.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/to_file_url.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/to_namespaced_path.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/_util.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/basename.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/dirname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/extname.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/format.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/glob_to_regexp.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/is_absolute.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/is_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/join.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/join_globs.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/mod.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/normalize.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/normalize_glob.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/parse.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/relative.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/resolve.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/separator.d.ts +0 -0
- /package/script/deps/deno.land/{std@0.210.0 → std@0.212.0}/path/windows/to_namespaced_path.d.ts +0 -0
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { enums } from "../2_tl.js";
|
|
2
|
+
import { EntityGetter } from "./1__getters.js";
|
|
2
3
|
/** @unlisted */
|
|
3
4
|
export type MessageEntityType = "mention" | "hashtag" | "botCommand" | "url" | "email" | "bold" | "italic" | "code" | "pre" | "textLink" | "textMention" | "cashtag" | "phoneNumber" | "underline" | "strikethrough" | "blockquote" | "bankCard" | "spoiler" | "customEmoji";
|
|
4
5
|
/** @unlisted */
|
|
@@ -94,4 +95,4 @@ export interface MessageEntityCustomEmoji extends _MessageEntityBase {
|
|
|
94
95
|
/** A single entity of a message's text or caption. */
|
|
95
96
|
export type MessageEntity = MessageEntityMention | MessageEntityHashtag | MessageEntityBotCommand | MessageEntityURL | MessageEntityEmailAddress | MessageEntityBold | MessageEntityItalic | MessageEntityCode | MessageEntityPre | MessageEntityTextLink | MessageEntityTextMention | MessageEntityCashtag | MessageEntityPhoneNumber | MessageEntityUnderline | MessageEntityStrikethrough | MessageEntityBlockquote | MessageEntityBankCard | MessageEntitySpoiler | MessageEntityCustomEmoji;
|
|
96
97
|
export declare function constructMessageEntity(obj: enums.MessageEntity): MessageEntity | null;
|
|
97
|
-
export declare function messageEntityToTlObject(entity: MessageEntity): import("../tl/2_types.js").MessageEntityMention_ | import("../tl/2_types.js").MessageEntityHashtag_ | import("../tl/2_types.js").MessageEntityBotCommand_ | import("../tl/2_types.js").MessageEntityUrl_ | import("../tl/2_types.js").MessageEntityEmail_ | import("../tl/2_types.js").MessageEntityBold_ | import("../tl/2_types.js").MessageEntityItalic_ | import("../tl/2_types.js").MessageEntityCode_ | import("../tl/2_types.js").MessageEntityPre_ | import("../tl/2_types.js").MessageEntityTextUrl_ | import("../tl/2_types.js").
|
|
98
|
+
export declare function messageEntityToTlObject(entity: MessageEntity, getEntity: EntityGetter): Promise<import("../tl/2_types.js").MessageEntityMention_ | import("../tl/2_types.js").MessageEntityHashtag_ | import("../tl/2_types.js").MessageEntityBotCommand_ | import("../tl/2_types.js").MessageEntityUrl_ | import("../tl/2_types.js").MessageEntityEmail_ | import("../tl/2_types.js").MessageEntityBold_ | import("../tl/2_types.js").MessageEntityItalic_ | import("../tl/2_types.js").MessageEntityCode_ | import("../tl/2_types.js").MessageEntityPre_ | import("../tl/2_types.js").MessageEntityTextUrl_ | import("../tl/2_types.js").InputMessageEntityMentionName_ | import("../tl/2_types.js").MessageEntityPhone_ | import("../tl/2_types.js").MessageEntityCashtag_ | import("../tl/2_types.js").MessageEntityUnderline_ | import("../tl/2_types.js").MessageEntityStrike_ | import("../tl/2_types.js").MessageEntityBankCard_ | import("../tl/2_types.js").MessageEntitySpoiler_ | import("../tl/2_types.js").MessageEntityCustomEmoji_ | import("../tl/2_types.js").MessageEntityBlockquote_>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { UNREACHABLE } from "../1_utilities.js";
|
|
1
2
|
import { types } from "../2_tl.js";
|
|
2
3
|
export function constructMessageEntity(obj) {
|
|
3
4
|
if (obj instanceof types.MessageEntityMention) {
|
|
@@ -61,7 +62,7 @@ export function constructMessageEntity(obj) {
|
|
|
61
62
|
return null;
|
|
62
63
|
}
|
|
63
64
|
}
|
|
64
|
-
export function messageEntityToTlObject(entity) {
|
|
65
|
+
export async function messageEntityToTlObject(entity, getEntity) {
|
|
65
66
|
const { offset, length } = entity;
|
|
66
67
|
switch (entity.type) {
|
|
67
68
|
case "mention":
|
|
@@ -82,10 +83,32 @@ export function messageEntityToTlObject(entity) {
|
|
|
82
83
|
return new types.MessageEntityCode({ offset, length });
|
|
83
84
|
case "pre":
|
|
84
85
|
return new types.MessageEntityPre({ offset, length, language: entity.language });
|
|
85
|
-
case "textLink":
|
|
86
|
+
case "textLink": {
|
|
87
|
+
try {
|
|
88
|
+
const url = new URL(entity.url);
|
|
89
|
+
if (url.protocol == "tg:" && url.hostname == "user" && (url.pathname == "/" || url.pathname == "")) {
|
|
90
|
+
const id = Number(url.searchParams.get("id"));
|
|
91
|
+
if (!isNaN(id)) {
|
|
92
|
+
const entity_ = await getEntity(new types.PeerUser({ user_id: BigInt(id) }));
|
|
93
|
+
if (!entity_) {
|
|
94
|
+
UNREACHABLE();
|
|
95
|
+
}
|
|
96
|
+
return new types.InputMessageEntityMentionName({ offset, length, user_id: new types.InputUser({ user_id: entity_.id, access_hash: entity_.access_hash ?? 0n }) });
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
catch {
|
|
101
|
+
//
|
|
102
|
+
}
|
|
86
103
|
return new types.MessageEntityTextUrl({ offset, length, url: entity.url });
|
|
87
|
-
|
|
88
|
-
|
|
104
|
+
}
|
|
105
|
+
case "textMention": {
|
|
106
|
+
const entity_ = await getEntity(new types.PeerUser({ user_id: BigInt(entity.userId) }));
|
|
107
|
+
if (!entity_) {
|
|
108
|
+
UNREACHABLE();
|
|
109
|
+
}
|
|
110
|
+
return new types.InputMessageEntityMentionName({ offset, length, user_id: new types.InputUser({ user_id: entity_.id, access_hash: entity_.access_hash ?? 0n }) });
|
|
111
|
+
}
|
|
89
112
|
case "cashtag":
|
|
90
113
|
return new types.MessageEntityCashtag({ offset, length });
|
|
91
114
|
case "phoneNumber":
|
package/esm/types/1_chat_p.js
CHANGED
|
@@ -36,7 +36,7 @@ export function constructChatP(chat) {
|
|
|
36
36
|
}
|
|
37
37
|
return cleanObject(chat_);
|
|
38
38
|
}
|
|
39
|
-
else if (chat instanceof types.Channel || types.ChannelForbidden) {
|
|
39
|
+
else if (chat instanceof types.Channel || chat instanceof types.ChannelForbidden) {
|
|
40
40
|
let chat_;
|
|
41
41
|
const id = ZERO_CHANNEL_ID + -Number(chat.id);
|
|
42
42
|
if (chat instanceof types.ChannelForbidden) {
|
|
@@ -189,5 +189,5 @@ export type InlineQueryResult = InlineQueryResultCachedAudio | InlineQueryResult
|
|
|
189
189
|
export declare function inlineQueryResultToTlObject(result_: InlineQueryResult, parseText: (text: string, params?: {
|
|
190
190
|
parseMode?: ParseMode;
|
|
191
191
|
entities?: MessageEntity[];
|
|
192
|
-
}) => readonly [string, any[] | undefined]
|
|
192
|
+
}) => Promise<readonly [string, any[] | undefined]>, usernameResolver: UsernameResolver): Promise<import("../tl/2_types.js").InputBotInlineResult_ | import("../tl/2_types.js").InputBotInlineResultDocument_>;
|
|
193
193
|
export {};
|
|
@@ -148,7 +148,7 @@ export async function inlineQueryResultToTlObject(result_, parseText, usernameRe
|
|
|
148
148
|
}
|
|
149
149
|
let ret = ["", []];
|
|
150
150
|
if ("caption" in result_ && result_.caption) {
|
|
151
|
-
ret = parseText(result_.caption, { parseMode: result_.parseMode, entities: result_.captionEntities });
|
|
151
|
+
ret = await parseText(result_.caption, { parseMode: result_.parseMode, entities: result_.captionEntities });
|
|
152
152
|
}
|
|
153
153
|
const { type, id } = result_;
|
|
154
154
|
const [message, entities] = ret;
|
|
@@ -223,7 +223,7 @@ export async function inlineQueryResultToTlObject(result_, parseText, usernameRe
|
|
|
223
223
|
if (!("messageText" in result_.inputMessageContent)) {
|
|
224
224
|
UNREACHABLE();
|
|
225
225
|
}
|
|
226
|
-
const [message, entities] = parseText(result_.inputMessageContent.messageText, { entities: result_.inputMessageContent.entities, parseMode: result_.inputMessageContent.parseMode });
|
|
226
|
+
const [message, entities] = await parseText(result_.inputMessageContent.messageText, { entities: result_.inputMessageContent.entities, parseMode: result_.inputMessageContent.parseMode });
|
|
227
227
|
return new types.InputBotInlineResult({
|
|
228
228
|
id,
|
|
229
229
|
type,
|
package/package.json
CHANGED
package/script/0_deps.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export * from "./deps/deno.land/std@0.
|
|
2
|
-
export * as path from "./deps/deno.land/std@0.
|
|
3
|
-
export { decodeBase64, encodeBase64 } from "./deps/deno.land/std@0.
|
|
4
|
-
export { contentType } from "./deps/deno.land/std@0.
|
|
1
|
+
export * from "./deps/deno.land/std@0.212.0/assert/mod.js";
|
|
2
|
+
export * as path from "./deps/deno.land/std@0.212.0/path/mod.js";
|
|
3
|
+
export { decodeBase64, encodeBase64 } from "./deps/deno.land/std@0.212.0/encoding/base64.js";
|
|
4
|
+
export { contentType } from "./deps/deno.land/std@0.212.0/media_types/content_type.js";
|
|
5
5
|
export declare function extension(mimeType: string): string;
|
|
6
6
|
export { ctr256, factorize, ige256Decrypt, ige256Encrypt, init as initTgCrypto } from "./deps/deno.land/x/tgcrypto@0.3.3/mod.js";
|
|
7
7
|
export { gunzip, gzip } from "./deps/raw.githubusercontent.com/MTKruto/compress/main/gzip/gzip.js";
|
package/script/0_deps.js
CHANGED
|
@@ -27,14 +27,14 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
29
|
exports.debug = exports.Parser = exports.Mutex = exports.gzip = exports.gunzip = exports.initTgCrypto = exports.ige256Encrypt = exports.ige256Decrypt = exports.factorize = exports.ctr256 = exports.extension = exports.contentType = exports.encodeBase64 = exports.decodeBase64 = exports.path = void 0;
|
|
30
|
-
__exportStar(require("./deps/deno.land/std@0.
|
|
31
|
-
exports.path = __importStar(require("./deps/deno.land/std@0.
|
|
32
|
-
var base64_js_1 = require("./deps/deno.land/std@0.
|
|
30
|
+
__exportStar(require("./deps/deno.land/std@0.212.0/assert/mod.js"), exports);
|
|
31
|
+
exports.path = __importStar(require("./deps/deno.land/std@0.212.0/path/mod.js"));
|
|
32
|
+
var base64_js_1 = require("./deps/deno.land/std@0.212.0/encoding/base64.js");
|
|
33
33
|
Object.defineProperty(exports, "decodeBase64", { enumerable: true, get: function () { return base64_js_1.decodeBase64; } });
|
|
34
34
|
Object.defineProperty(exports, "encodeBase64", { enumerable: true, get: function () { return base64_js_1.encodeBase64; } });
|
|
35
|
-
var content_type_js_1 = require("./deps/deno.land/std@0.
|
|
35
|
+
var content_type_js_1 = require("./deps/deno.land/std@0.212.0/media_types/content_type.js");
|
|
36
36
|
Object.defineProperty(exports, "contentType", { enumerable: true, get: function () { return content_type_js_1.contentType; } });
|
|
37
|
-
const extension_js_1 = require("./deps/deno.land/std@0.
|
|
37
|
+
const extension_js_1 = require("./deps/deno.land/std@0.212.0/media_types/extension.js");
|
|
38
38
|
function extension(mimeType) {
|
|
39
39
|
if (mimeType == "application/x-tgsticker") {
|
|
40
40
|
return "tgs";
|
package/script/4_constants.d.ts
CHANGED
|
@@ -3,8 +3,8 @@ export declare const ACK_THRESHOLD = 10;
|
|
|
3
3
|
export type PublicKeys = readonly [bigint, [bigint, bigint]][];
|
|
4
4
|
export declare const PUBLIC_KEYS: PublicKeys;
|
|
5
5
|
export declare const INITIAL_DC: DC;
|
|
6
|
-
export declare const LAYER =
|
|
7
|
-
export declare const APP_VERSION = "MTKruto 0.1.
|
|
6
|
+
export declare const LAYER = 172;
|
|
7
|
+
export declare const APP_VERSION = "MTKruto 0.1.145";
|
|
8
8
|
export declare const DEVICE_MODEL: string;
|
|
9
9
|
export declare const LANG_CODE: string;
|
|
10
10
|
export declare const LANG_PACK = "";
|
package/script/4_constants.js
CHANGED
|
@@ -78,8 +78,8 @@ exports.PUBLIC_KEYS = Object.freeze([
|
|
|
78
78
|
],
|
|
79
79
|
]);
|
|
80
80
|
exports.INITIAL_DC = "2";
|
|
81
|
-
exports.LAYER =
|
|
82
|
-
exports.APP_VERSION = "MTKruto 0.1.
|
|
81
|
+
exports.LAYER = 172;
|
|
82
|
+
exports.APP_VERSION = "MTKruto 0.1.145";
|
|
83
83
|
// @ts-ignore: lib
|
|
84
84
|
exports.DEVICE_MODEL = typeof dntShim.Deno === "undefined" ? typeof navigator === "undefined" ? typeof process === "undefined" ? "Unknown" : process.platform + "-" + process.arch : navigator.userAgent.split(" ")[0] : dntShim.Deno.build.os + "-" + dntShim.Deno.build.arch;
|
|
85
85
|
exports.LANG_CODE = typeof navigator === "undefined" ? "en" : navigator.language.split("-")[0];
|
|
@@ -10,7 +10,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
10
10
|
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");
|
|
11
11
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
12
12
|
};
|
|
13
|
-
var _UpdateManager_instances, _a, _UpdateManager_c, _UpdateManager_updateState, _UpdateManager_updateHandler, _UpdateManager_handleUpdateQueues, _UpdateManager_checkGap, _UpdateManager_checkChannelGap, _UpdateManager_channelUpdateQueues, _UpdateManager_processChannelPtsUpdateInner, _UpdateManager_queueUpdate, _UpdateManager_processChannelPtsUpdate, _UpdateManager_processPtsUpdateInner, _UpdateManager_ptsUpdateQueue, _UpdateManager_processPtsUpdate, _UpdateManager_processUpdatesQueue, _UpdateManager_processUpdates, _UpdateManager_setUpdateStateDate, _UpdateManager_setUpdatePts, _UpdateManager_getLocalState, _UpdateManager_recoverChannelUpdateGap, _UpdateManager_handleUpdatesSet, _UpdateManager_handleStoredUpdates, _UpdateManager_handleUpdate;
|
|
13
|
+
var _UpdateManager_instances, _a, _UpdateManager_c, _UpdateManager_updateState, _UpdateManager_updateHandler, _UpdateManager_defaultDropPendingUpdates, _UpdateManager_mustDropPendingUpdates, _UpdateManager_handleUpdateQueues, _UpdateManager_nonFirst, _UpdateManager_getChannelPtsWithDropPendingUpdatesCheck, _UpdateManager_checkGap, _UpdateManager_checkChannelGap, _UpdateManager_channelUpdateQueues, _UpdateManager_processChannelPtsUpdateInner, _UpdateManager_queueUpdate, _UpdateManager_processChannelPtsUpdate, _UpdateManager_processPtsUpdateInner, _UpdateManager_ptsUpdateQueue, _UpdateManager_processPtsUpdate, _UpdateManager_processUpdatesQueue, _UpdateManager_processUpdates, _UpdateManager_setUpdateStateDate, _UpdateManager_setUpdatePts, _UpdateManager_getLocalState, _UpdateManager_recoverChannelUpdateGap, _UpdateManager_handleUpdatesSet, _UpdateManager_handleStoredUpdates, _UpdateManager_handleUpdate;
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.UpdateManager = void 0;
|
|
16
16
|
const _0_deps_js_1 = require("../0_deps.js");
|
|
@@ -27,7 +27,9 @@ class UpdateManager {
|
|
|
27
27
|
_UpdateManager_c.set(this, void 0);
|
|
28
28
|
_UpdateManager_updateState.set(this, void 0);
|
|
29
29
|
_UpdateManager_updateHandler.set(this, void 0);
|
|
30
|
+
_UpdateManager_defaultDropPendingUpdates.set(this, null);
|
|
30
31
|
_UpdateManager_handleUpdateQueues.set(this, new Map());
|
|
32
|
+
_UpdateManager_nonFirst.set(this, new Set());
|
|
31
33
|
_UpdateManager_channelUpdateQueues.set(this, new Map());
|
|
32
34
|
_UpdateManager_ptsUpdateQueue.set(this, new _1_utilities_js_1.Queue("ptsUpdate"));
|
|
33
35
|
_UpdateManager_processUpdatesQueue.set(this, new _1_utilities_js_1.Queue("UpdateManager/processUpdates"));
|
|
@@ -38,25 +40,24 @@ class UpdateManager {
|
|
|
38
40
|
const state = await __classPrivateFieldGet(this, _UpdateManager_c, "f").api.updates.getState();
|
|
39
41
|
__classPrivateFieldSet(this, _UpdateManager_updateState, state, "f");
|
|
40
42
|
d("state fetched [%s]", source);
|
|
43
|
+
if (await __classPrivateFieldGet(this, _UpdateManager_instances, "m", _UpdateManager_mustDropPendingUpdates).call(this)) {
|
|
44
|
+
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.setState(state);
|
|
45
|
+
}
|
|
41
46
|
}
|
|
42
47
|
async processChats(chats) {
|
|
43
48
|
for (const chat of chats) {
|
|
44
|
-
if (chat instanceof _2_tl_js_1.types.Channel
|
|
49
|
+
if (chat instanceof _2_tl_js_1.types.Channel || chat instanceof _2_tl_js_1.types.ChannelForbidden) {
|
|
45
50
|
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.setEntity(chat);
|
|
46
|
-
|
|
47
|
-
if (chat.username) {
|
|
51
|
+
if ("username" in chat && chat.username) {
|
|
48
52
|
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.updateUsernames("channel", chat.id, [chat.username]);
|
|
49
53
|
}
|
|
50
|
-
if (chat.usernames) {
|
|
54
|
+
if ("usernames" in chat && chat.usernames) {
|
|
51
55
|
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.updateUsernames("channel", chat.id, chat.usernames.map((v) => v.username));
|
|
52
56
|
}
|
|
53
57
|
}
|
|
54
|
-
else if (chat instanceof _2_tl_js_1.types.Chat) {
|
|
58
|
+
else if (chat instanceof _2_tl_js_1.types.Chat || chat instanceof _2_tl_js_1.types.ChatForbidden) {
|
|
55
59
|
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.setEntity(chat);
|
|
56
60
|
}
|
|
57
|
-
else if (chat instanceof _2_tl_js_1.types.ChannelForbidden || chat instanceof _2_tl_js_1.types.ChatForbidden) {
|
|
58
|
-
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.removeEntity(chat);
|
|
59
|
-
}
|
|
60
61
|
}
|
|
61
62
|
}
|
|
62
63
|
async processResult(result) {
|
|
@@ -120,7 +121,6 @@ class UpdateManager {
|
|
|
120
121
|
for (const user of users) {
|
|
121
122
|
if (user instanceof _2_tl_js_1.types.User && user.access_hash) {
|
|
122
123
|
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.setEntity(user);
|
|
123
|
-
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.setUserAccessHash(user.id, user.access_hash);
|
|
124
124
|
if (user.username) {
|
|
125
125
|
await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.updateUsernames("user", user.id, [user.username]);
|
|
126
126
|
}
|
|
@@ -197,13 +197,33 @@ class UpdateManager {
|
|
|
197
197
|
}
|
|
198
198
|
}
|
|
199
199
|
exports.UpdateManager = UpdateManager;
|
|
200
|
-
_a = UpdateManager, _UpdateManager_c = new WeakMap(), _UpdateManager_updateState = new WeakMap(), _UpdateManager_updateHandler = new WeakMap(), _UpdateManager_handleUpdateQueues = new WeakMap(), _UpdateManager_channelUpdateQueues = new WeakMap(), _UpdateManager_ptsUpdateQueue = new WeakMap(), _UpdateManager_processUpdatesQueue = new WeakMap(), _UpdateManager_handleUpdatesSet = new WeakMap(), _UpdateManager_instances = new WeakSet(),
|
|
200
|
+
_a = UpdateManager, _UpdateManager_c = new WeakMap(), _UpdateManager_updateState = new WeakMap(), _UpdateManager_updateHandler = new WeakMap(), _UpdateManager_defaultDropPendingUpdates = new WeakMap(), _UpdateManager_handleUpdateQueues = new WeakMap(), _UpdateManager_nonFirst = new WeakMap(), _UpdateManager_channelUpdateQueues = new WeakMap(), _UpdateManager_ptsUpdateQueue = new WeakMap(), _UpdateManager_processUpdatesQueue = new WeakMap(), _UpdateManager_handleUpdatesSet = new WeakMap(), _UpdateManager_instances = new WeakSet(), _UpdateManager_mustDropPendingUpdates = async function _UpdateManager_mustDropPendingUpdates() {
|
|
201
|
+
if (typeof __classPrivateFieldGet(this, _UpdateManager_c, "f").dropPendingUpdates === "boolean") {
|
|
202
|
+
return __classPrivateFieldGet(this, _UpdateManager_c, "f").dropPendingUpdates;
|
|
203
|
+
}
|
|
204
|
+
if (__classPrivateFieldGet(this, _UpdateManager_defaultDropPendingUpdates, "f") == null) {
|
|
205
|
+
__classPrivateFieldSet(this, _UpdateManager_defaultDropPendingUpdates, await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.getAccountType() == "bot", "f");
|
|
206
|
+
}
|
|
207
|
+
return __classPrivateFieldGet(this, _UpdateManager_defaultDropPendingUpdates, "f");
|
|
208
|
+
}, _UpdateManager_getChannelPtsWithDropPendingUpdatesCheck = async function _UpdateManager_getChannelPtsWithDropPendingUpdatesCheck(channelId) {
|
|
209
|
+
if (!(await __classPrivateFieldGet(this, _UpdateManager_instances, "m", _UpdateManager_mustDropPendingUpdates).call(this))) {
|
|
210
|
+
return await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.getChannelPts(channelId);
|
|
211
|
+
}
|
|
212
|
+
const first = !__classPrivateFieldGet(this, _UpdateManager_nonFirst, "f").has(channelId);
|
|
213
|
+
if (first) {
|
|
214
|
+
__classPrivateFieldGet(this, _UpdateManager_nonFirst, "f").add(channelId);
|
|
215
|
+
return null;
|
|
216
|
+
}
|
|
217
|
+
else {
|
|
218
|
+
return await __classPrivateFieldGet(this, _UpdateManager_c, "f").storage.getChannelPts(channelId);
|
|
219
|
+
}
|
|
220
|
+
}, _UpdateManager_checkGap = async function _UpdateManager_checkGap(pts, ptsCount) {
|
|
201
221
|
const localState = await __classPrivateFieldGet(this, _UpdateManager_instances, "m", _UpdateManager_getLocalState).call(this);
|
|
202
222
|
if (localState.pts + ptsCount < pts) {
|
|
203
223
|
await this.recoverUpdateGap("processUpdates");
|
|
204
224
|
}
|
|
205
225
|
}, _UpdateManager_checkChannelGap = async function _UpdateManager_checkChannelGap(channelId, pts, ptsCount) {
|
|
206
|
-
let localPts = await __classPrivateFieldGet(this,
|
|
226
|
+
let localPts = await __classPrivateFieldGet(this, _UpdateManager_instances, "m", _UpdateManager_getChannelPtsWithDropPendingUpdatesCheck).call(this, channelId);
|
|
207
227
|
if (!localPts) {
|
|
208
228
|
localPts = pts - ptsCount;
|
|
209
229
|
}
|
|
@@ -224,7 +244,7 @@ _a = UpdateManager, _UpdateManager_c = new WeakMap(), _UpdateManager_updateState
|
|
|
224
244
|
if (checkGap) {
|
|
225
245
|
await __classPrivateFieldGet(this, _UpdateManager_instances, "m", _UpdateManager_checkChannelGap).call(this, channelId, update.pts, ptsCount);
|
|
226
246
|
}
|
|
227
|
-
let currentPts = await __classPrivateFieldGet(this,
|
|
247
|
+
let currentPts = await __classPrivateFieldGet(this, _UpdateManager_instances, "m", _UpdateManager_getChannelPtsWithDropPendingUpdatesCheck).call(this, channelId);
|
|
228
248
|
currentPts ??= update.pts - ptsCount;
|
|
229
249
|
if (currentPts + ptsCount > update.pts) {
|
|
230
250
|
return;
|
|
@@ -16,7 +16,7 @@ export declare class MessageManager {
|
|
|
16
16
|
parseText(text: string, params?: {
|
|
17
17
|
parseMode?: ParseMode;
|
|
18
18
|
entities?: MessageEntity[];
|
|
19
|
-
}): readonly [string, (import("../tl/2_types.js").MessageEntityMention_ | import("../tl/2_types.js").MessageEntityHashtag_ | import("../tl/2_types.js").MessageEntityBotCommand_ | import("../tl/2_types.js").MessageEntityUrl_ | import("../tl/2_types.js").MessageEntityEmail_ | import("../tl/2_types.js").MessageEntityBold_ | import("../tl/2_types.js").MessageEntityItalic_ | import("../tl/2_types.js").MessageEntityCode_ | import("../tl/2_types.js").MessageEntityPre_ | import("../tl/2_types.js").MessageEntityTextUrl_ | import("../tl/2_types.js").
|
|
19
|
+
}): Promise<readonly [string, (import("../tl/2_types.js").MessageEntityMention_ | import("../tl/2_types.js").MessageEntityHashtag_ | import("../tl/2_types.js").MessageEntityBotCommand_ | import("../tl/2_types.js").MessageEntityUrl_ | import("../tl/2_types.js").MessageEntityEmail_ | import("../tl/2_types.js").MessageEntityBold_ | import("../tl/2_types.js").MessageEntityItalic_ | import("../tl/2_types.js").MessageEntityCode_ | import("../tl/2_types.js").MessageEntityPre_ | import("../tl/2_types.js").MessageEntityTextUrl_ | import("../tl/2_types.js").InputMessageEntityMentionName_ | import("../tl/2_types.js").MessageEntityPhone_ | import("../tl/2_types.js").MessageEntityCashtag_ | import("../tl/2_types.js").MessageEntityUnderline_ | import("../tl/2_types.js").MessageEntityStrike_ | import("../tl/2_types.js").MessageEntityBankCard_ | import("../tl/2_types.js").MessageEntitySpoiler_ | import("../tl/2_types.js").MessageEntityCustomEmoji_ | import("../tl/2_types.js").MessageEntityBlockquote_)[] | undefined]>;
|
|
20
20
|
getStickerSetName(inputStickerSet: types.InputStickerSetID, hash?: number): Promise<string>;
|
|
21
21
|
constructMessage(message_: enums.Message, r?: boolean): Promise<Message>;
|
|
22
22
|
forwardMessages(from: ID, to: ID, messageIds: number[], params?: ForwardMessagesParams): Promise<Message[]>;
|
|
@@ -86,7 +86,7 @@ class MessageManager {
|
|
|
86
86
|
const messages = await this.getMessages(chatId, [messageId]);
|
|
87
87
|
return messages[0] ?? null;
|
|
88
88
|
}
|
|
89
|
-
parseText(text, params) {
|
|
89
|
+
async parseText(text, params) {
|
|
90
90
|
const entities_ = params?.entities ?? [];
|
|
91
91
|
const parseMode = params?.parseMode ?? __classPrivateFieldGet(this, _MessageManager_c, "f").parseMode;
|
|
92
92
|
switch (parseMode) {
|
|
@@ -103,7 +103,7 @@ class MessageManager {
|
|
|
103
103
|
default:
|
|
104
104
|
(0, _1_utilities_js_1.UNREACHABLE)();
|
|
105
105
|
}
|
|
106
|
-
const entities = entities_?.length > 0 ? entities_.map((v) => (0, _3_types_js_1.messageEntityToTlObject)(v)) : undefined;
|
|
106
|
+
const entities = entities_?.length > 0 ? await Promise.all(entities_.map((v) => (0, _3_types_js_1.messageEntityToTlObject)(v, __classPrivateFieldGet(this, _MessageManager_c, "f").getEntity))) : undefined;
|
|
107
107
|
return [text, entities];
|
|
108
108
|
}
|
|
109
109
|
async getStickerSetName(inputStickerSet, hash = 0) {
|
|
@@ -180,7 +180,7 @@ class MessageManager {
|
|
|
180
180
|
return messages;
|
|
181
181
|
}
|
|
182
182
|
async sendMessage(chatId, text, params) {
|
|
183
|
-
const [message, entities] = this.parseText(text, params);
|
|
183
|
+
const [message, entities] = await this.parseText(text, params);
|
|
184
184
|
const replyMarkup = await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyMarkup).call(this, params);
|
|
185
185
|
const peer = await __classPrivateFieldGet(this, _MessageManager_c, "f").getInputPeer(chatId);
|
|
186
186
|
const randomId = (0, _1_utilities_js_1.getRandomId)();
|
|
@@ -195,7 +195,7 @@ class MessageManager {
|
|
|
195
195
|
no_webpage: noWebpage,
|
|
196
196
|
silent,
|
|
197
197
|
noforwards,
|
|
198
|
-
reply_to: __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
198
|
+
reply_to: await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
199
199
|
send_as: sendAs,
|
|
200
200
|
entities,
|
|
201
201
|
reply_markup: replyMarkup,
|
|
@@ -215,7 +215,7 @@ class MessageManager {
|
|
|
215
215
|
random_id: randomId,
|
|
216
216
|
silent,
|
|
217
217
|
noforwards,
|
|
218
|
-
reply_to: __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
218
|
+
reply_to: await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
219
219
|
send_as: sendAs,
|
|
220
220
|
reply_markup: replyMarkup,
|
|
221
221
|
media: new _2_tl_js_1.types.InputMediaVenue({
|
|
@@ -246,7 +246,7 @@ class MessageManager {
|
|
|
246
246
|
random_id: randomId,
|
|
247
247
|
silent,
|
|
248
248
|
noforwards,
|
|
249
|
-
reply_to: __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
249
|
+
reply_to: await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
250
250
|
send_as: sendAs,
|
|
251
251
|
reply_markup: replyMarkup,
|
|
252
252
|
media: new _2_tl_js_1.types.InputMediaContact({
|
|
@@ -272,7 +272,7 @@ class MessageManager {
|
|
|
272
272
|
random_id: randomId,
|
|
273
273
|
silent,
|
|
274
274
|
noforwards,
|
|
275
|
-
reply_to: __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
275
|
+
reply_to: await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
276
276
|
send_as: sendAs,
|
|
277
277
|
reply_markup: replyMarkup,
|
|
278
278
|
media: new _2_tl_js_1.types.InputMediaDice({
|
|
@@ -295,7 +295,7 @@ class MessageManager {
|
|
|
295
295
|
random_id: randomId,
|
|
296
296
|
silent,
|
|
297
297
|
noforwards,
|
|
298
|
-
reply_to: __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
298
|
+
reply_to: await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
299
299
|
send_as: sendAs,
|
|
300
300
|
reply_markup: replyMarkup,
|
|
301
301
|
media: params?.livePeriod !== undefined
|
|
@@ -411,7 +411,7 @@ class MessageManager {
|
|
|
411
411
|
const sendAs = params?.sendAs ? await __classPrivateFieldGet(this, _MessageManager_c, "f").getInputPeer(params.sendAs) : undefined; // TODO: check default sendAs
|
|
412
412
|
const replyMarkup = await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyMarkup).call(this, params);
|
|
413
413
|
const explanation = params?.explanation;
|
|
414
|
-
const parseResult = explanation !== undefined ? this.parseText(explanation, { parseMode: params?.explanationParseMode, entities: params?.explanationEntities }) : undefined;
|
|
414
|
+
const parseResult = explanation !== undefined ? await this.parseText(explanation, { parseMode: params?.explanationParseMode, entities: params?.explanationEntities }) : undefined;
|
|
415
415
|
const solution = parseResult === undefined ? undefined : parseResult[0];
|
|
416
416
|
const solutionEntities = parseResult === undefined ? undefined : parseResult[1];
|
|
417
417
|
const answers = options.map((v, i) => new _2_tl_js_1.types.PollAnswer({ option: new Uint8Array([i]), text: v }));
|
|
@@ -438,7 +438,7 @@ class MessageManager {
|
|
|
438
438
|
silent,
|
|
439
439
|
noforwards,
|
|
440
440
|
reply_markup: replyMarkup,
|
|
441
|
-
reply_to: __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
441
|
+
reply_to: await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
442
442
|
send_as: sendAs,
|
|
443
443
|
media,
|
|
444
444
|
message: "",
|
|
@@ -456,7 +456,7 @@ class MessageManager {
|
|
|
456
456
|
return message_;
|
|
457
457
|
}
|
|
458
458
|
async editMessageText(chatId, messageId, text, params) {
|
|
459
|
-
const [message, entities] = this.parseText(text, params);
|
|
459
|
+
const [message, entities] = await this.parseText(text, params);
|
|
460
460
|
const result = await __classPrivateFieldGet(this, _MessageManager_c, "f").api.messages.editMessage({
|
|
461
461
|
id: messageId,
|
|
462
462
|
peer: await __classPrivateFieldGet(this, _MessageManager_c, "f").getInputPeer(chatId),
|
|
@@ -794,10 +794,10 @@ _MessageManager_c = new WeakMap(), _MessageManager_instances = new WeakSet(), _M
|
|
|
794
794
|
await __classPrivateFieldGet(this, _MessageManager_c, "f").storage.assertUser("sendAs");
|
|
795
795
|
return sendAs ? await __classPrivateFieldGet(this, _MessageManager_c, "f").getInputPeer(sendAs) : undefined;
|
|
796
796
|
}
|
|
797
|
-
}, _MessageManager_constructReplyTo = function _MessageManager_constructReplyTo(params) {
|
|
797
|
+
}, _MessageManager_constructReplyTo = async function _MessageManager_constructReplyTo(params) {
|
|
798
798
|
const topMsgId = params?.messageThreadId;
|
|
799
799
|
const replyToMsgId = params?.replyToMessageId;
|
|
800
|
-
return replyToMsgId !== undefined ? new _2_tl_js_1.types.InputReplyToMessage({ reply_to_msg_id: replyToMsgId, top_msg_id: topMsgId, quote_text: params?.replyQuote?.text, quote_entities: params?.replyQuote?.entities.map(_3_types_js_1.messageEntityToTlObject), quote_offset: params?.replyQuote?.offset }) : undefined;
|
|
800
|
+
return replyToMsgId !== undefined ? new _2_tl_js_1.types.InputReplyToMessage({ reply_to_msg_id: replyToMsgId, top_msg_id: topMsgId, quote_text: params?.replyQuote?.text, quote_entities: await Promise.all(params?.replyQuote?.entities.map((v) => (0, _3_types_js_1.messageEntityToTlObject)(v, __classPrivateFieldGet(this, _MessageManager_c, "f").getEntity)) ?? []), quote_offset: params?.replyQuote?.offset }) : undefined;
|
|
801
801
|
}, _MessageManager_sendDocumentInner = async function _MessageManager_sendDocumentInner(chatId, document, params, fileType, otherAttribs, urlSupported = false) {
|
|
802
802
|
let media = null;
|
|
803
803
|
const spoiler = params?.hasSpoiler ? true : undefined;
|
|
@@ -846,7 +846,7 @@ _MessageManager_c = new WeakMap(), _MessageManager_instances = new WeakSet(), _M
|
|
|
846
846
|
const sendAs = params?.sendAs ? await __classPrivateFieldGet(this, _MessageManager_c, "f").getInputPeer(params.sendAs) : undefined; // TODO: check default sendAs
|
|
847
847
|
const replyMarkup = await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyMarkup).call(this, params);
|
|
848
848
|
const caption_ = params?.caption;
|
|
849
|
-
const parseResult = caption_ !== undefined ? this.parseText(caption_, { parseMode: params?.parseMode, entities: params?.captionEntities }) : undefined;
|
|
849
|
+
const parseResult = caption_ !== undefined ? await this.parseText(caption_, { parseMode: params?.parseMode, entities: params?.captionEntities }) : undefined;
|
|
850
850
|
const caption = parseResult === undefined ? undefined : parseResult[0];
|
|
851
851
|
const captionEntities = parseResult === undefined ? undefined : parseResult[1];
|
|
852
852
|
const result = await __classPrivateFieldGet(this, _MessageManager_c, "f").api.messages.sendMedia({
|
|
@@ -855,7 +855,7 @@ _MessageManager_c = new WeakMap(), _MessageManager_instances = new WeakSet(), _M
|
|
|
855
855
|
silent,
|
|
856
856
|
noforwards,
|
|
857
857
|
reply_markup: replyMarkup,
|
|
858
|
-
reply_to: __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
858
|
+
reply_to: await __classPrivateFieldGet(this, _MessageManager_instances, "m", _MessageManager_constructReplyTo).call(this, params),
|
|
859
859
|
send_as: sendAs,
|
|
860
860
|
media,
|
|
861
861
|
message: caption ?? "",
|
|
@@ -158,6 +158,8 @@ export interface ClientParams extends ClientPlainParams {
|
|
|
158
158
|
prefixes?: string | string[];
|
|
159
159
|
/** Whether to guarantee that order-sensitive updates are delivered at least once before delivering next ones. Useful mainly for clients providing a user interface à la Telegram Desktop. Defaults to `false`. */
|
|
160
160
|
guaranteeUpdateDelivery?: boolean;
|
|
161
|
+
/** Whether to not handle updates received when the client was not running. Defaults to `true` for bots, and `false` for users. */
|
|
162
|
+
dropPendingUpdates?: boolean;
|
|
161
163
|
}
|
|
162
164
|
export declare class Client<C extends Context = Context> extends ClientAbstract {
|
|
163
165
|
#private;
|
|
@@ -570,6 +570,7 @@ class Client extends _0_client_abstract_js_1.ClientAbstract {
|
|
|
570
570
|
},
|
|
571
571
|
cdn: params?.cdn ?? false,
|
|
572
572
|
ignoreOutgoing: __classPrivateFieldGet(this, _Client_ignoreOutgoing, "f"),
|
|
573
|
+
dropPendingUpdates: params?.dropPendingUpdates,
|
|
573
574
|
};
|
|
574
575
|
__classPrivateFieldSet(this, _Client_updateManager, new _1_update_manager_js_1.UpdateManager(c), "f");
|
|
575
576
|
__classPrivateFieldSet(this, _Client_networkStatisticsManager, new _1_network_statistics_manager_js_1.NetworkStatisticsManager(c), "f");
|
|
@@ -922,7 +923,6 @@ class Client extends _0_client_abstract_js_1.ClientAbstract {
|
|
|
922
923
|
}
|
|
923
924
|
else {
|
|
924
925
|
inputPeer.access_hash = await __classPrivateFieldGet(this, _Client_instances, "m", _Client_getUserAccessHash).call(this, inputPeer.user_id);
|
|
925
|
-
await this.storage.setUserAccessHash(inputPeer.user_id, inputPeer.access_hash);
|
|
926
926
|
}
|
|
927
927
|
}
|
|
928
928
|
return inputPeer;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.CAN_NOT_DISPLAY = void 0;
|
|
4
|
-
// Copyright 2018-
|
|
4
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
5
5
|
exports.CAN_NOT_DISPLAY = "[Cannot display]";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// Copyright 2018-
|
|
2
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
3
3
|
// This module is browser compatible.
|
|
4
4
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
5
|
exports.buildMessage = exports.diffstr = exports.diff = exports.DiffType = void 0;
|
|
@@ -17,8 +17,10 @@ function createCommon(A, B, reverse) {
|
|
|
17
17
|
if (A.length === 0 || B.length === 0)
|
|
18
18
|
return [];
|
|
19
19
|
for (let i = 0; i < Math.min(A.length, B.length); i += 1) {
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
const a = reverse ? A[A.length - i - 1] : A[i];
|
|
21
|
+
const b = reverse ? B[B.length - i - 1] : B[i];
|
|
22
|
+
if (a !== undefined && a === b) {
|
|
23
|
+
common.push(a);
|
|
22
24
|
}
|
|
23
25
|
else {
|
|
24
26
|
return common;
|
|
@@ -26,6 +28,12 @@ function createCommon(A, B, reverse) {
|
|
|
26
28
|
}
|
|
27
29
|
return common;
|
|
28
30
|
}
|
|
31
|
+
function ensureDefined(item) {
|
|
32
|
+
if (item === undefined) {
|
|
33
|
+
throw Error("Unexpected missing FarthestPoint");
|
|
34
|
+
}
|
|
35
|
+
return item;
|
|
36
|
+
}
|
|
29
37
|
/**
|
|
30
38
|
* Renders the differences between the actual and expected values
|
|
31
39
|
* @param A Actual value
|
|
@@ -112,22 +120,26 @@ function diff(A, B) {
|
|
|
112
120
|
if (slide && slide.y === -1 && down && down.y === -1) {
|
|
113
121
|
return { y: 0, id: 0 };
|
|
114
122
|
}
|
|
115
|
-
|
|
123
|
+
const isAdding = (down?.y === -1) ||
|
|
116
124
|
k === M ||
|
|
117
|
-
(slide
|
|
125
|
+
(slide?.y || 0) > (down?.y || 0) + 1;
|
|
126
|
+
if (slide && isAdding) {
|
|
118
127
|
const prev = slide.id;
|
|
119
128
|
ptr++;
|
|
120
129
|
routes[ptr] = prev;
|
|
121
130
|
routes[ptr + diffTypesPtrOffset] = ADDED;
|
|
122
131
|
return { y: slide.y, id: ptr };
|
|
123
132
|
}
|
|
124
|
-
else {
|
|
133
|
+
else if (down && !isAdding) {
|
|
125
134
|
const prev = down.id;
|
|
126
135
|
ptr++;
|
|
127
136
|
routes[ptr] = prev;
|
|
128
137
|
routes[ptr + diffTypesPtrOffset] = REMOVED;
|
|
129
138
|
return { y: down.y + 1, id: ptr };
|
|
130
139
|
}
|
|
140
|
+
else {
|
|
141
|
+
throw new Error("Unexpected missing FarthestPoint");
|
|
142
|
+
}
|
|
131
143
|
}
|
|
132
144
|
function snake(k, slide, down, _offset, A, B) {
|
|
133
145
|
const M = A.length;
|
|
@@ -145,7 +157,8 @@ function diff(A, B) {
|
|
|
145
157
|
}
|
|
146
158
|
return fp;
|
|
147
159
|
}
|
|
148
|
-
|
|
160
|
+
let currentFP = ensureDefined(fp[delta + offset]);
|
|
161
|
+
while (currentFP && currentFP.y < N) {
|
|
149
162
|
p = p + 1;
|
|
150
163
|
for (let k = -p; k < delta; ++k) {
|
|
151
164
|
fp[k + offset] = snake(k, fp[k - 1 + offset], fp[k + 1 + offset], offset, A, B);
|
|
@@ -154,10 +167,11 @@ function diff(A, B) {
|
|
|
154
167
|
fp[k + offset] = snake(k, fp[k - 1 + offset], fp[k + 1 + offset], offset, A, B);
|
|
155
168
|
}
|
|
156
169
|
fp[delta + offset] = snake(delta, fp[delta - 1 + offset], fp[delta + 1 + offset], offset, A, B);
|
|
170
|
+
currentFP = ensureDefined(fp[delta + offset]);
|
|
157
171
|
}
|
|
158
172
|
return [
|
|
159
173
|
...prefixCommon.map((c) => ({ type: exports.DiffType.common, value: c })),
|
|
160
|
-
...backTrace(A, B,
|
|
174
|
+
...backTrace(A, B, currentFP, swapped),
|
|
161
175
|
...suffixCommon.map((c) => ({ type: exports.DiffType.common, value: c })),
|
|
162
176
|
];
|
|
163
177
|
}
|
|
@@ -188,9 +202,14 @@ function diffstr(A, B) {
|
|
|
188
202
|
const words = /^[a-zA-Z\u{C0}-\u{FF}\u{D8}-\u{F6}\u{F8}-\u{2C6}\u{2C8}-\u{2D7}\u{2DE}-\u{2FF}\u{1E00}-\u{1EFF}]+$/u;
|
|
189
203
|
// Join boundary splits that we do not consider to be boundaries and merge empty strings surrounded by word chars
|
|
190
204
|
for (let i = 0; i < tokens.length - 1; i++) {
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
205
|
+
const token = tokens[i];
|
|
206
|
+
const tokenPlusTwo = tokens[i + 2];
|
|
207
|
+
if (!tokens[i + 1] &&
|
|
208
|
+
token &&
|
|
209
|
+
tokenPlusTwo &&
|
|
210
|
+
words.test(token) &&
|
|
211
|
+
words.test(tokenPlusTwo)) {
|
|
212
|
+
tokens[i] += tokenPlusTwo;
|
|
194
213
|
tokens.splice(i + 1, 2);
|
|
195
214
|
i--;
|
|
196
215
|
}
|
|
@@ -199,18 +218,19 @@ function diffstr(A, B) {
|
|
|
199
218
|
}
|
|
200
219
|
else {
|
|
201
220
|
// Split string on new lines symbols
|
|
202
|
-
const tokens = []
|
|
221
|
+
const tokens = [];
|
|
222
|
+
const lines = string.split(/(\n|\r\n)/);
|
|
203
223
|
// Ignore final empty token when text ends with a newline
|
|
204
224
|
if (!lines[lines.length - 1]) {
|
|
205
225
|
lines.pop();
|
|
206
226
|
}
|
|
207
227
|
// Merge the content and line separators into single tokens
|
|
208
|
-
for (
|
|
228
|
+
for (const [i, line] of lines.entries()) {
|
|
209
229
|
if (i % 2) {
|
|
210
|
-
tokens[tokens.length - 1] +=
|
|
230
|
+
tokens[tokens.length - 1] += line;
|
|
211
231
|
}
|
|
212
232
|
else {
|
|
213
|
-
tokens.push(
|
|
233
|
+
tokens.push(line);
|
|
214
234
|
}
|
|
215
235
|
}
|
|
216
236
|
return tokens;
|
|
@@ -220,11 +240,12 @@ function diffstr(A, B) {
|
|
|
220
240
|
// and merge "space-diff" if surrounded by word-diff for cleaner displays
|
|
221
241
|
function createDetails(line, tokens) {
|
|
222
242
|
return tokens.filter(({ type }) => type === line.type || type === exports.DiffType.common).map((result, i, t) => {
|
|
223
|
-
|
|
224
|
-
|
|
243
|
+
const token = t[i - 1];
|
|
244
|
+
if ((result.type === exports.DiffType.common) && token &&
|
|
245
|
+
(token.type === t[i + 1]?.type) && /\s+/.test(result.value)) {
|
|
225
246
|
return {
|
|
226
247
|
...result,
|
|
227
|
-
type:
|
|
248
|
+
type: token.type,
|
|
228
249
|
};
|
|
229
250
|
}
|
|
230
251
|
return result;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
// Copyright 2018-
|
|
2
|
+
// Copyright 2018-2024 the Deno authors. All rights reserved. MIT license.
|
|
3
3
|
// This module is browser compatible.
|
|
4
4
|
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
5
5
|
if (k2 === undefined) k2 = k;
|