telegram-botbuilder 1.1.7 → 1.1.8
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/lib/bot-service.js +3 -3
- package/package.json +1 -1
- package/src/bot-service.ts +3 -3
package/lib/bot-service.js
CHANGED
|
@@ -336,13 +336,13 @@ var BotBuilder = /** @class */ (function () {
|
|
|
336
336
|
_e.label = 12;
|
|
337
337
|
case 12:
|
|
338
338
|
_e.trys.push([12, 14, , 16]);
|
|
339
|
-
return [4 /*yield*/, this._bot.editMessageText(text || "404", { chat_id: chat, message_id: this._userdialogs[chat].lastid, reply_markup: { inline_keyboard: markup || [] }, parse_mode: '
|
|
339
|
+
return [4 /*yield*/, this._bot.editMessageText(text || "404", { chat_id: chat, message_id: this._userdialogs[chat].lastid, reply_markup: { inline_keyboard: markup || [] }, parse_mode: 'HTML' })];
|
|
340
340
|
case 13:
|
|
341
341
|
_e.sent();
|
|
342
342
|
return [3 /*break*/, 16];
|
|
343
343
|
case 14:
|
|
344
344
|
_d = _e.sent();
|
|
345
|
-
return [4 /*yield*/, this._bot.sendMessage(chat, text || "404", { reply_markup: { inline_keyboard: markup || [] }, parse_mode: '
|
|
345
|
+
return [4 /*yield*/, this._bot.sendMessage(chat, text || "404", { reply_markup: { inline_keyboard: markup || [] }, parse_mode: 'HTML' })];
|
|
346
346
|
case 15:
|
|
347
347
|
msg = _e.sent();
|
|
348
348
|
this._userdialogs[chat].lastid = msg.message_id;
|
|
@@ -357,7 +357,7 @@ var BotBuilder = /** @class */ (function () {
|
|
|
357
357
|
this._userdialogs[chat].waiter.statewait = true;
|
|
358
358
|
};
|
|
359
359
|
BotBuilder.prototype.Message = function (chat, content) {
|
|
360
|
-
return this._bot.sendMessage(chat, content, { parse_mode: '
|
|
360
|
+
return this._bot.sendMessage(chat, content, { parse_mode: 'HTML' });
|
|
361
361
|
};
|
|
362
362
|
return BotBuilder;
|
|
363
363
|
}());
|
package/package.json
CHANGED
package/src/bot-service.ts
CHANGED
|
@@ -170,9 +170,9 @@ export class BotBuilder {
|
|
|
170
170
|
if (dialog == undefined) markup = [[{text: "Меню", callback_data: this._schema.start}]]; // FIX RAND BTN
|
|
171
171
|
let text = typeof dialog?.text === 'function' ? await dialog?.text(chat) : dialog?.text;
|
|
172
172
|
try {
|
|
173
|
-
await this._bot.editMessageText(text || "404", {chat_id: chat, message_id: this._userdialogs[chat].lastid, reply_markup: { inline_keyboard: markup || [] }, parse_mode: '
|
|
173
|
+
await this._bot.editMessageText(text || "404", {chat_id: chat, message_id: this._userdialogs[chat].lastid, reply_markup: { inline_keyboard: markup || [] }, parse_mode: 'HTML'})
|
|
174
174
|
} catch {
|
|
175
|
-
let msg = await this._bot.sendMessage(chat, text || "404", {reply_markup: { inline_keyboard: markup || [] }, parse_mode: '
|
|
175
|
+
let msg = await this._bot.sendMessage(chat, text || "404", {reply_markup: { inline_keyboard: markup || [] }, parse_mode: 'HTML'});
|
|
176
176
|
this._userdialogs[chat].lastid = msg.message_id;
|
|
177
177
|
}
|
|
178
178
|
}
|
|
@@ -181,7 +181,7 @@ export class BotBuilder {
|
|
|
181
181
|
this._userdialogs[chat].waiter.statewait = true;
|
|
182
182
|
}
|
|
183
183
|
public Message(chat: number, content: string) {
|
|
184
|
-
return this._bot.sendMessage(chat, content, {parse_mode: '
|
|
184
|
+
return this._bot.sendMessage(chat, content, {parse_mode: 'HTML'});
|
|
185
185
|
}
|
|
186
186
|
}
|
|
187
187
|
|