@mtkruto/node 0.145.0 → 0.147.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm/3_types.d.ts +2 -0
- package/esm/3_types.d.ts.map +1 -1
- package/esm/3_types.js +2 -0
- package/esm/client/1_client_generic.d.ts +43 -1
- package/esm/client/1_client_generic.d.ts.map +1 -1
- package/esm/client/2_bot_info_manager.d.ts.map +1 -1
- package/esm/client/2_bot_info_manager.js +1 -2
- package/esm/client/2_update_manager.d.ts.map +1 -1
- package/esm/client/2_update_manager.js +22 -23
- package/esm/client/3_account_manager.d.ts +3 -0
- package/esm/client/3_account_manager.d.ts.map +1 -1
- package/esm/client/3_account_manager.js +14 -1
- package/esm/client/3_message_manager.d.ts +3 -1
- package/esm/client/3_message_manager.d.ts.map +1 -1
- package/esm/client/3_message_manager.js +14 -0
- package/esm/client/3_sticker_set_manager.d.ts +1 -0
- package/esm/client/3_sticker_set_manager.d.ts.map +1 -1
- package/esm/client/3_sticker_set_manager.js +4 -0
- package/esm/client/3_video_chat_manager.d.ts.map +1 -1
- package/esm/client/3_video_chat_manager.js +1 -2
- package/esm/client/6_client.d.ts +43 -1
- package/esm/client/6_client.d.ts.map +1 -1
- package/esm/client/6_client.js +56 -3
- package/esm/client/6_client_dispatcher.d.ts +43 -1
- package/esm/client/6_client_dispatcher.d.ts.map +1 -1
- package/esm/client/6_client_dispatcher.js +54 -0
- package/esm/deps/jsr.io/@std/assert/1.0.19/equals.js +4 -4
- package/esm/deps/jsr.io/@std/internal/1.0.14/_os.d.ts.map +1 -0
- package/esm/deps/jsr.io/@std/internal/1.0.14/_os.js +14 -0
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/build_message.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff.js +4 -3
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff_str.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff_str.js +8 -9
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/format.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/styles.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/types.d.ts.map +1 -1
- package/esm/deps/jsr.io/@std/path/1.1.4/basename.js +1 -1
- package/esm/deps/jsr.io/@std/path/1.1.4/extname.js +1 -1
- package/esm/deps/jsr.io/@std/path/1.1.4/is_absolute.js +1 -1
- package/esm/deps/jsr.io/@std/path/1.1.4/join.js +1 -1
- package/esm/deps/jsr.io/@std/path/1.1.4/to_file_url.js +1 -1
- package/esm/types/0_authorization_session.d.ts +43 -0
- package/esm/types/0_authorization_session.d.ts.map +1 -0
- package/esm/types/0_authorization_session.js +41 -0
- package/esm/types/0_message_counters.d.ts +29 -0
- package/esm/types/0_message_counters.d.ts.map +1 -0
- package/esm/types/0_message_counters.js +20 -0
- package/esm/types/1_chat_action.d.ts +1 -1
- package/esm/types/1_chat_action.d.ts.map +1 -1
- package/esm/types/1_chat_action.js +3 -3
- package/esm/types/1_chat_p.d.ts.map +1 -1
- package/esm/types/1_chat_p.js +2 -3
- package/esm/types/2_story_interactive_area.d.ts.map +1 -1
- package/esm/types/2_story_interactive_area.js +1 -2
- package/esm/types/3_bot_access_settings.d.ts +2 -2
- package/esm/types/3_bot_access_settings.d.ts.map +1 -1
- package/esm/types/3_message_draft.d.ts.map +1 -1
- package/esm/types/3_message_draft.js +1 -2
- package/esm/types/7_saved_chat.d.ts +2 -3
- package/esm/types/7_saved_chat.d.ts.map +1 -1
- package/esm/types/7_saved_chat.js +3 -3
- package/package.json +1 -1
- package/script/3_types.d.ts +2 -0
- package/script/3_types.d.ts.map +1 -1
- package/script/3_types.js +2 -0
- package/script/client/1_client_generic.d.ts +43 -1
- package/script/client/1_client_generic.d.ts.map +1 -1
- package/script/client/2_bot_info_manager.d.ts.map +1 -1
- package/script/client/2_bot_info_manager.js +1 -2
- package/script/client/2_update_manager.d.ts.map +1 -1
- package/script/client/2_update_manager.js +22 -23
- package/script/client/3_account_manager.d.ts +3 -0
- package/script/client/3_account_manager.d.ts.map +1 -1
- package/script/client/3_account_manager.js +13 -0
- package/script/client/3_message_manager.d.ts +3 -1
- package/script/client/3_message_manager.d.ts.map +1 -1
- package/script/client/3_message_manager.js +14 -0
- package/script/client/3_sticker_set_manager.d.ts +1 -0
- package/script/client/3_sticker_set_manager.d.ts.map +1 -1
- package/script/client/3_sticker_set_manager.js +4 -0
- package/script/client/3_video_chat_manager.d.ts.map +1 -1
- package/script/client/3_video_chat_manager.js +1 -2
- package/script/client/6_client.d.ts +43 -1
- package/script/client/6_client.d.ts.map +1 -1
- package/script/client/6_client.js +56 -3
- package/script/client/6_client_dispatcher.d.ts +43 -1
- package/script/client/6_client_dispatcher.d.ts.map +1 -1
- package/script/client/6_client_dispatcher.js +54 -0
- package/script/deps/jsr.io/@std/assert/1.0.19/equals.js +4 -4
- package/script/deps/jsr.io/@std/internal/1.0.14/_os.d.ts.map +1 -0
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/_os.js +7 -5
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/build_message.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff.js +4 -3
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff_str.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff_str.js +8 -9
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/format.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/styles.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/types.d.ts.map +1 -1
- package/script/deps/jsr.io/@std/path/1.1.4/basename.js +1 -1
- package/script/deps/jsr.io/@std/path/1.1.4/extname.js +1 -1
- package/script/deps/jsr.io/@std/path/1.1.4/is_absolute.js +1 -1
- package/script/deps/jsr.io/@std/path/1.1.4/join.js +1 -1
- package/script/deps/jsr.io/@std/path/1.1.4/to_file_url.js +1 -1
- package/script/types/0_authorization_session.d.ts +43 -0
- package/script/types/0_authorization_session.d.ts.map +1 -0
- package/script/types/0_authorization_session.js +44 -0
- package/script/types/0_message_counters.d.ts +29 -0
- package/script/types/0_message_counters.d.ts.map +1 -0
- package/script/types/0_message_counters.js +21 -0
- package/script/types/1_chat_action.d.ts +1 -1
- package/script/types/1_chat_action.d.ts.map +1 -1
- package/script/types/1_chat_action.js +3 -3
- package/script/types/1_chat_p.d.ts.map +1 -1
- package/script/types/1_chat_p.js +2 -3
- package/script/types/2_story_interactive_area.d.ts.map +1 -1
- package/script/types/2_story_interactive_area.js +1 -2
- package/script/types/3_bot_access_settings.d.ts +2 -2
- package/script/types/3_bot_access_settings.d.ts.map +1 -1
- package/script/types/3_message_draft.d.ts.map +1 -1
- package/script/types/3_message_draft.js +1 -2
- package/script/types/7_saved_chat.d.ts +2 -3
- package/script/types/7_saved_chat.d.ts.map +1 -1
- package/script/types/7_saved_chat.js +3 -3
- package/esm/deps/jsr.io/@std/internal/1.0.13/_os.d.ts.map +0 -1
- package/esm/deps/jsr.io/@std/internal/1.0.13/_os.js +0 -12
- package/script/deps/jsr.io/@std/internal/1.0.13/_os.d.ts.map +0 -1
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/_os.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/build_message.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/build_message.js +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff_str.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/format.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/format.js +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.js +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/styles.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/styles.js +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/types.d.ts +0 -0
- /package/esm/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/types.js +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/_os.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/build_message.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/build_message.js +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/diff_str.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/format.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/format.js +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/os.js +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/styles.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/styles.js +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/types.d.ts +0 -0
- /package/script/deps/jsr.io/@std/internal/{1.0.13 → 1.0.14}/types.js +0 -0
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* MTKruto - Cross-runtime JavaScript library for building Telegram clients
|
|
3
|
+
* Copyright (C) 2023-2026 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 type { Api } from "../2_tl.js";
|
|
21
|
+
/** An authorization session. */
|
|
22
|
+
export interface AuthorizationSession {
|
|
23
|
+
id: string;
|
|
24
|
+
date: number;
|
|
25
|
+
lastActivity: number;
|
|
26
|
+
isCurrent: boolean;
|
|
27
|
+
isOfficialApp: boolean;
|
|
28
|
+
isPasswordPending: boolean;
|
|
29
|
+
isEncryptedRequestsDisabled: boolean;
|
|
30
|
+
isCallRequestsDisabled: boolean;
|
|
31
|
+
isUnconfirmed: boolean;
|
|
32
|
+
deviceModel: string;
|
|
33
|
+
platform: string;
|
|
34
|
+
systemVersion: string;
|
|
35
|
+
apiId: number;
|
|
36
|
+
appName: string;
|
|
37
|
+
appVersion: string;
|
|
38
|
+
ipAddress: string;
|
|
39
|
+
country: string;
|
|
40
|
+
region: string;
|
|
41
|
+
}
|
|
42
|
+
export declare function constructAuthorizationSession(authorization: Api.Authorization): AuthorizationSession;
|
|
43
|
+
//# sourceMappingURL=0_authorization_session.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"0_authorization_session.d.ts","sourceRoot":"","sources":["../../src/types/0_authorization_session.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAEtC,gCAAgC;AAChC,MAAM,WAAW,oBAAoB;IACnC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;IACrB,SAAS,EAAE,OAAO,CAAC;IACnB,aAAa,EAAE,OAAO,CAAC;IACvB,iBAAiB,EAAE,OAAO,CAAC;IAC3B,2BAA2B,EAAE,OAAO,CAAC;IACrC,sBAAsB,EAAE,OAAO,CAAC;IAChC,aAAa,EAAE,OAAO,CAAC;IACvB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,aAAa,EAAE,MAAM,CAAC;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,wBAAgB,6BAA6B,CAAC,aAAa,EAAE,GAAG,CAAC,aAAa,GAAG,oBAAoB,CAqBpG"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* MTKruto - Cross-runtime JavaScript library for building Telegram clients
|
|
4
|
+
* Copyright (C) 2023-2026 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.constructAuthorizationSession = constructAuthorizationSession;
|
|
23
|
+
function constructAuthorizationSession(authorization) {
|
|
24
|
+
return {
|
|
25
|
+
id: String(authorization.hash),
|
|
26
|
+
date: authorization.date_created,
|
|
27
|
+
lastActivity: authorization.date_active,
|
|
28
|
+
isCurrent: authorization.current || false,
|
|
29
|
+
isOfficialApp: authorization.official_app || false,
|
|
30
|
+
isPasswordPending: authorization.password_pending || false,
|
|
31
|
+
isEncryptedRequestsDisabled: authorization.encrypted_requests_disabled || false,
|
|
32
|
+
isCallRequestsDisabled: authorization.call_requests_disabled || false,
|
|
33
|
+
isUnconfirmed: authorization.unconfirmed || false,
|
|
34
|
+
deviceModel: authorization.device_model,
|
|
35
|
+
platform: authorization.platform,
|
|
36
|
+
systemVersion: authorization.system_version,
|
|
37
|
+
apiId: authorization.api_id,
|
|
38
|
+
appName: authorization.app_name,
|
|
39
|
+
appVersion: authorization.app_version,
|
|
40
|
+
ipAddress: authorization.ip,
|
|
41
|
+
country: authorization.country,
|
|
42
|
+
region: authorization.region,
|
|
43
|
+
};
|
|
44
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* MTKruto - Cross-runtime JavaScript library for building Telegram clients
|
|
3
|
+
* Copyright (C) 2023-2026 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
|
+
/** The counters of a message. */
|
|
21
|
+
export interface MessageCounters {
|
|
22
|
+
/** The number of times the message was viewed. */
|
|
23
|
+
views: number;
|
|
24
|
+
/** The number of replies made to the messages. */
|
|
25
|
+
replies: number;
|
|
26
|
+
/** The number of times the message was forwarded. */
|
|
27
|
+
forwards: number;
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=0_message_counters.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"0_message_counters.d.ts","sourceRoot":"","sources":["../../src/types/0_message_counters.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,iCAAiC;AACjC,MAAM,WAAW,eAAe;IAC9B,kDAAkD;IAClD,KAAK,EAAE,MAAM,CAAC;IACd,kDAAkD;IAClD,OAAO,EAAE,MAAM,CAAC;IAChB,qDAAqD;IACrD,QAAQ,EAAE,MAAM,CAAC;CAClB"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* MTKruto - Cross-runtime JavaScript library for building Telegram clients
|
|
4
|
+
* Copyright (C) 2023-2026 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 });
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
* You should have received a copy of the GNU Lesser General Public License
|
|
18
18
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
19
19
|
*/
|
|
20
|
-
import
|
|
20
|
+
import { Api } from "../2_tl.js";
|
|
21
21
|
import { type ChatActionType } from "./0_chat_action_type.js";
|
|
22
22
|
/** A sign of a possible action by a member of a conversation. */
|
|
23
23
|
export interface ChatAction {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"1_chat_action.d.ts","sourceRoot":"","sources":["../../src/types/1_chat_action.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,
|
|
1
|
+
{"version":3,"file":"1_chat_action.d.ts","sourceRoot":"","sources":["../../src/types/1_chat_action.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAAE,KAAK,cAAc,EAA2B,MAAM,yBAAyB,CAAC;AAEvF,iEAAiE;AACjE,MAAM,WAAW,UAAU;IACzB,8BAA8B;IAC9B,IAAI,EAAE,cAAc,CAAC;IACrB,4DAA4D;IAC5D,MAAM,EAAE,MAAM,CAAC;IACf,kDAAkD;IAClD,MAAM,EAAE,MAAM,CAAC;IACf,4DAA4D;IAC5D,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,GAAG,CAAC,gBAAgB,GAAG,GAAG,CAAC,oBAAoB,GAAG,GAAG,CAAC,uBAAuB,GAAG,UAAU,GAAG,IAAI,CAY5I"}
|
|
@@ -21,15 +21,15 @@
|
|
|
21
21
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
22
|
exports.constructChatAction = constructChatAction;
|
|
23
23
|
const _1_utilities_js_1 = require("../1_utilities.js");
|
|
24
|
-
const
|
|
24
|
+
const _2_tl_js_1 = require("../2_tl.js");
|
|
25
25
|
const _0_chat_action_type_js_1 = require("./0_chat_action_type.js");
|
|
26
26
|
function constructChatAction(update) {
|
|
27
27
|
const type = (0, _0_chat_action_type_js_1.constructChatActionType)(update.action);
|
|
28
28
|
if (type === null) {
|
|
29
29
|
return null;
|
|
30
30
|
}
|
|
31
|
-
const chatId =
|
|
32
|
-
const fromId =
|
|
31
|
+
const chatId = _2_tl_js_1.Api.peerToChatId(update);
|
|
32
|
+
const fromId = _2_tl_js_1.Api.peerToChatId("user_id" in update ? { _: "peerUser", user_id: update.user_id } : update.from_id);
|
|
33
33
|
const messageThreadId = "top_msg_id" in update ? update.top_msg_id : undefined;
|
|
34
34
|
return (0, _1_utilities_js_1.cleanObject)({ type, chatId, fromId, messageThreadId });
|
|
35
35
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"1_chat_p.d.ts","sourceRoot":"","sources":["../../src/types/1_chat_p.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAIH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"1_chat_p.d.ts","sourceRoot":"","sources":["../../src/types/1_chat_p.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAIH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAAE,KAAK,SAAS,EAAsB,MAAM,mBAAmB,CAAC;AACvE,OAAO,EAAwB,KAAK,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAC7E,OAAO,EAA8B,KAAK,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAC/F,OAAO,EAAuB,KAAK,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAE1E,gBAAgB;AAChB,MAAM,MAAM,QAAQ,GAChB,SAAS,GACT,OAAO,GACP,YAAY,GACZ,SAAS,CAAC;AAEd,gBAAgB;AAChB,MAAM,WAAW,UAAU;IACzB,kCAAkC;IAClC,EAAE,EAAE,MAAM,CAAC;IACX,4BAA4B;IAC5B,IAAI,EAAE,QAAQ,CAAC;IACf,+EAA+E;IAC/E,KAAK,EAAE,MAAM,CAAC;IACd,wBAAwB;IACxB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB;AAED,gBAAgB;AAChB,MAAM,WAAW,YAAa,SAAQ,UAAU;IAC9C,IAAI,EAAE,SAAS,CAAC;IAChB,oCAAoC;IACpC,KAAK,EAAE,OAAO,CAAC;IACf,kCAAkC;IAClC,SAAS,EAAE,MAAM,CAAC;IAClB,iCAAiC;IACjC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,gCAAgC;IAChC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,+BAA+B;IAC/B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,uCAAuC;IACvC,IAAI,CAAC,EAA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,GAAG,CAAC,UAAU,EAAE,MAAM,CAAC,GAAG,IAAI,CAAC;IAClD,CAAC,IAAI,EAAE,GAAG,CAAC,WAAW,GAAG,CAAC,YAAY,GAAG,eAAe,EAAE,MAAM,CAAC,GAAG,IAAI,CAAC;IACzE,CAAC,IAAI,EAAE,GAAG,CAAC,QAAQ,GAAG,GAAG,CAAC,QAAQ,GAAG,GAAG,CAAC,WAAW,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,GAAG,IAAI,CAAC;CAC/E;AAED,wBAAgB,WAAW,CAAC,KAAK,EAAE,KAAK,GAAG,KAAK,IAAI,YAAY,CAE/D"}
|
package/script/types/1_chat_p.js
CHANGED
|
@@ -24,7 +24,6 @@ exports.isChatPUser = isChatPUser;
|
|
|
24
24
|
const _0_deps_js_1 = require("../0_deps.js");
|
|
25
25
|
const _1_utilities_js_1 = require("../1_utilities.js");
|
|
26
26
|
const _2_tl_js_1 = require("../2_tl.js");
|
|
27
|
-
const _2_telegram_js_1 = require("../tl/2_telegram.js");
|
|
28
27
|
const _0_chat_photo_js_1 = require("./0_chat_photo.js");
|
|
29
28
|
const _0_emoji_status_js_1 = require("./0_emoji_status.js");
|
|
30
29
|
const _0_restriction_reason_js_1 = require("./0_restriction_reason.js");
|
|
@@ -69,7 +68,7 @@ function constructChatP(chat) {
|
|
|
69
68
|
return (0, _1_utilities_js_1.cleanObject)(chat_);
|
|
70
69
|
}
|
|
71
70
|
else if (_2_tl_js_1.Api.is("chat", chat) || _2_tl_js_1.Api.is("chatForbidden", chat)) {
|
|
72
|
-
const id =
|
|
71
|
+
const id = _2_tl_js_1.Api.peerToChatId(chat);
|
|
73
72
|
const chat_ = {
|
|
74
73
|
id,
|
|
75
74
|
type: "group",
|
|
@@ -87,7 +86,7 @@ function constructChatP(chat) {
|
|
|
87
86
|
}
|
|
88
87
|
else if (_2_tl_js_1.Api.is("channel", chat) || _2_tl_js_1.Api.is("channelForbidden", chat)) {
|
|
89
88
|
let chat_;
|
|
90
|
-
const id =
|
|
89
|
+
const id = _2_tl_js_1.Api.peerToChatId(chat);
|
|
91
90
|
if (_2_tl_js_1.Api.is("channelForbidden", chat)) {
|
|
92
91
|
const { title } = chat;
|
|
93
92
|
if (chat.megagroup) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"2_story_interactive_area.d.ts","sourceRoot":"","sources":["../../src/types/2_story_interactive_area.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"2_story_interactive_area.d.ts","sourceRoot":"","sources":["../../src/types/2_story_interactive_area.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAAqB,KAAK,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AACnE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,EAAqB,KAAK,QAAQ,EAAsB,MAAM,iBAAiB,CAAC;AACvF,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAChD,OAAO,EAAkB,KAAK,KAAK,EAAE,MAAM,cAAc,CAAC;AAE1D,gBAAgB;AAChB,MAAM,WAAW,4BAA4B;IAC3C,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;IACxB,gBAAgB,EAAE,MAAM,CAAC;IACzB,aAAa,EAAE,MAAM,CAAC;CACvB;AAED,gBAAgB;AAChB,MAAM,WAAW,mCAAmC;IAClD,QAAQ,EAAE,4BAA4B,CAAC;CACxC;AAED,gBAAgB;AAChB,MAAM,WAAW,4BAA6B,SAAQ,mCAAmC;IACvF,IAAI,EAAE,UAAU,CAAC;IACjB,QAAQ,EAAE,QAAQ,CAAC;CACpB;AAED,gBAAgB;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@@ -23,7 +23,6 @@ exports.constructStoryInteractiveArea = constructStoryInteractiveArea;
|
|
|
23
23
|
exports.storyInteractiveAreaToTlObject = storyInteractiveAreaToTlObject;
|
|
24
24
|
const _0_deps_js_1 = require("../0_deps.js");
|
|
25
25
|
const _2_tl_js_1 = require("../2_tl.js");
|
|
26
|
-
const _2_telegram_js_1 = require("../tl/2_telegram.js");
|
|
27
26
|
const _0_location_js_1 = require("./0_location.js");
|
|
28
27
|
const _0_reaction_js_1 = require("./0_reaction.js");
|
|
29
28
|
const _1_venue_js_1 = require("./1_venue.js");
|
|
@@ -129,7 +128,7 @@ function storyInteractiveAreaToTlObject(area, getPeer) {
|
|
|
129
128
|
if (!peer || peer[0].type !== "channel") {
|
|
130
129
|
(0, _0_deps_js_1.unreachable)();
|
|
131
130
|
}
|
|
132
|
-
const channel = { _: "inputChannel", channel_id:
|
|
131
|
+
const channel = { _: "inputChannel", channel_id: _2_tl_js_1.Api.chatIdToPeerId(peer[0].id), access_hash: peer[1] };
|
|
133
132
|
return { _: "inputMediaAreaChannelPost", coordinates, channel, msg_id: area.messageReference.messageId };
|
|
134
133
|
}
|
|
135
134
|
case "link":
|
|
@@ -17,11 +17,11 @@
|
|
|
17
17
|
* You should have received a copy of the GNU Lesser General Public License
|
|
18
18
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
19
19
|
*/
|
|
20
|
-
import
|
|
20
|
+
import { Api } from "../2_tl.js";
|
|
21
21
|
import { type User } from "./2_user.js";
|
|
22
22
|
export interface BotAccessSettings {
|
|
23
23
|
isAccessRestricted: boolean;
|
|
24
24
|
usersWithAccess: User[];
|
|
25
25
|
}
|
|
26
|
-
export declare function constructBotAccessSettings(accessSettings: bots_accessSettings): BotAccessSettings;
|
|
26
|
+
export declare function constructBotAccessSettings(accessSettings: Api.bots_accessSettings): BotAccessSettings;
|
|
27
27
|
//# sourceMappingURL=3_bot_access_settings.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"3_bot_access_settings.d.ts","sourceRoot":"","sources":["../../src/types/3_bot_access_settings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;
|
|
1
|
+
{"version":3,"file":"3_bot_access_settings.d.ts","sourceRoot":"","sources":["../../src/types/3_bot_access_settings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAAiB,KAAK,IAAI,EAAE,MAAM,aAAa,CAAC;AAEvD,MAAM,WAAW,iBAAiB;IAChC,kBAAkB,EAAE,OAAO,CAAC;IAC5B,eAAe,EAAE,IAAI,EAAE,CAAC;CACzB;AAED,wBAAgB,0BAA0B,CAAC,cAAc,EAAE,GAAG,CAAC,mBAAmB,GAAG,iBAAiB,CAKrG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"3_message_draft.d.ts","sourceRoot":"","sources":["../../src/types/3_message_draft.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"3_message_draft.d.ts","sourceRoot":"","sources":["../../src/types/3_message_draft.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAA0B,KAAK,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAEnF,uBAAuB;AACvB,MAAM,WAAW,YAAY;IAC3B,2BAA2B;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,8DAA8D;IAC9D,MAAM,EAAE,MAAM,CAAC;IACf,wBAAwB;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,iCAAiC;IACjC,QAAQ,EAAE,aAAa,EAAE,CAAC;IAC1B,2DAA2D;IAC3D,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,GAAG,CAAC,gBAAgB,GAAG,YAAY,GAAG,IAAI,CAmBvF"}
|
|
@@ -22,13 +22,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
22
22
|
exports.constructMessageDraft = constructMessageDraft;
|
|
23
23
|
const _1_utilities_js_1 = require("../1_utilities.js");
|
|
24
24
|
const _2_tl_js_1 = require("../2_tl.js");
|
|
25
|
-
const _2_telegram_js_1 = require("../tl/2_telegram.js");
|
|
26
25
|
const _2_message_entity_js_1 = require("./2_message_entity.js");
|
|
27
26
|
function constructMessageDraft(action) {
|
|
28
27
|
if (!_2_tl_js_1.Api.is("sendMessageTextDraftAction", action.action)) {
|
|
29
28
|
return null;
|
|
30
29
|
}
|
|
31
|
-
const fromId =
|
|
30
|
+
const fromId = _2_tl_js_1.Api.peerToChatId(action);
|
|
32
31
|
const id = String(action.action.random_id);
|
|
33
32
|
const text = action.action.text.text;
|
|
34
33
|
const entities = action.action.text.entities.map((v) => (0, _2_message_entity_js_1.constructMessageEntity)(v)).filter((v) => v !== null);
|
|
@@ -17,8 +17,7 @@
|
|
|
17
17
|
* You should have received a copy of the GNU Lesser General Public License
|
|
18
18
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
19
19
|
*/
|
|
20
|
-
import
|
|
21
|
-
import type { SavedDialog } from "../tl/1_telegram_api.js";
|
|
20
|
+
import { Api } from "../2_tl.js";
|
|
22
21
|
import { type ChatP, type PeerGetter } from "./1_chat_p.js";
|
|
23
22
|
import type { StickerSetNameGetter } from "./1_sticker.js";
|
|
24
23
|
import { type Message, type MessageGetter } from "./6_message.js";
|
|
@@ -31,5 +30,5 @@ export interface SavedChat {
|
|
|
31
30
|
/** Whether the chat is pinned. */
|
|
32
31
|
isPinned: boolean;
|
|
33
32
|
}
|
|
34
|
-
export declare function constructSavedChat(dialog: SavedDialog, result: Api.messages_savedDialogs | Api.messages_savedDialogsSlice, getPeer: PeerGetter, getMessage: MessageGetter, getStickerSetName: StickerSetNameGetter): Promise<SavedChat>;
|
|
33
|
+
export declare function constructSavedChat(dialog: Api.SavedDialog, result: Api.messages_savedDialogs | Api.messages_savedDialogsSlice, getPeer: PeerGetter, getMessage: MessageGetter, getStickerSetName: StickerSetNameGetter): Promise<SavedChat>;
|
|
35
34
|
//# sourceMappingURL=7_saved_chat.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"7_saved_chat.d.ts","sourceRoot":"","sources":["../../src/types/7_saved_chat.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,
|
|
1
|
+
{"version":3,"file":"7_saved_chat.d.ts","sourceRoot":"","sources":["../../src/types/7_saved_chat.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAAE,KAAK,KAAK,EAAkB,KAAK,UAAU,EAAE,MAAM,eAAe,CAAC;AAC5E,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,EAAoB,KAAK,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAEpF,mCAAmC;AACnC,MAAM,WAAW,SAAS;IACxB,gBAAgB;IAChB,IAAI,EAAE,KAAK,CAAC;IACZ,qCAAqC;IACrC,WAAW,EAAE,OAAO,CAAC;IACrB,kCAAkC;IAClC,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,wBAAsB,kBAAkB,CAAC,MAAM,EAAE,GAAG,CAAC,WAAW,EAAE,MAAM,EAAE,GAAG,CAAC,qBAAqB,GAAG,GAAG,CAAC,0BAA0B,EAAE,OAAO,EAAE,UAAU,EAAE,UAAU,EAAE,aAAa,EAAE,iBAAiB,EAAE,oBAAoB,GAAG,OAAO,CAAC,SAAS,CAAC,CAkBjP"}
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
22
22
|
exports.constructSavedChat = constructSavedChat;
|
|
23
23
|
const _0_deps_js_1 = require("../0_deps.js");
|
|
24
|
-
const
|
|
24
|
+
const _2_tl_js_1 = require("../2_tl.js");
|
|
25
25
|
const _1_chat_p_js_1 = require("./1_chat_p.js");
|
|
26
26
|
const _6_message_js_1 = require("./6_message.js");
|
|
27
27
|
async function constructSavedChat(dialog, result, getPeer, getMessage, getStickerSetName) {
|
|
@@ -29,8 +29,8 @@ async function constructSavedChat(dialog, result, getPeer, getMessage, getSticke
|
|
|
29
29
|
if (message === undefined) {
|
|
30
30
|
(0, _0_deps_js_1.unreachable)();
|
|
31
31
|
}
|
|
32
|
-
const dialogId =
|
|
33
|
-
const chat_ = (dialog.peer._ === "peerUser" ? result.users : result.chats).find((v) =>
|
|
32
|
+
const dialogId = _2_tl_js_1.Api.peerToChatId(dialog.peer);
|
|
33
|
+
const chat_ = (dialog.peer._ === "peerUser" ? result.users : result.chats).find((v) => _2_tl_js_1.Api.peerToChatId(v) === dialogId);
|
|
34
34
|
if (chat_ === undefined) {
|
|
35
35
|
(0, _0_deps_js_1.unreachable)();
|
|
36
36
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"_os.d.ts","sourceRoot":"","sources":["../../../../../../src/deps/jsr.io/@std/internal/1.0.13/_os.ts"],"names":[],"mappings":"AAIA,wBAAgB,YAAY,IAAI,OAAO,CAUtC"}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
// Copyright 2018-2026 the Deno authors. MIT license.
|
|
2
|
-
import * as dntShim from "../../../../../_dnt.shims.js";
|
|
3
|
-
export function checkWindows() {
|
|
4
|
-
// deno-lint-ignore no-explicit-any
|
|
5
|
-
const global = dntShim.dntGlobalThis;
|
|
6
|
-
const os = global.Deno?.build?.os;
|
|
7
|
-
// Check Deno, then the remaining runtimes (e.g. Node, Bun and the browser)
|
|
8
|
-
return typeof os === "string"
|
|
9
|
-
? os === "windows"
|
|
10
|
-
: global.navigator?.platform?.startsWith("Win") ??
|
|
11
|
-
global.process?.platform?.startsWith("win") ?? false;
|
|
12
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"_os.d.ts","sourceRoot":"","sources":["../../../../../../src/deps/jsr.io/@std/internal/1.0.13/_os.ts"],"names":[],"mappings":"AAIA,wBAAgB,YAAY,IAAI,OAAO,CAUtC"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|