diff --git a/src/commands/help.js b/src/commands/help.js index 8d18782..1098cf3 100644 --- a/src/commands/help.js +++ b/src/commands/help.js @@ -11,7 +11,8 @@ async function sendHelpMessage(ctx, isEditing) { [{ text: Strings.mainCommands, callback_data: 'helpMain' }, { text: Strings.usefulCommands, callback_data: 'helpUseful' }], [{ text: Strings.interactiveEmojis, callback_data: 'helpInteractive' }, { text: Strings.funnyCommands, callback_data: 'helpFunny' }], [{ text: Strings.lastFm, callback_data: 'helpLast' }, { text: Strings.animalCommands, callback_data: 'helpAnimals' }], - [{ text: Strings.ytDlp, callback_data: 'helpYouTube' }, { text: Strings.myLittlePony, callback_data: 'helpMLP' }] + [{ text: Strings.ytDlp, callback_data: 'helpYouTube' }, { text: Strings.myLittlePony, callback_data: 'helpMLP' }], + [{ text: Strings.aboutBot, callback_data: 'helpAbout' }] ] } }; @@ -28,6 +29,15 @@ module.exports = (bot) => { await sendHelpMessage(ctx); }); + bot.command("about", spamwatchMiddleware, async (ctx) => { + const Strings = getStrings(ctx.from.language_code); + ctx.reply(Strings.kowalskiAbout, { + parse_mode: 'Markdown', + disable_web_page_preview: true, + reply_to_message_id: ctx.message.message_id + }); + }) + bot.on('callback_query', async (ctx) => { const callbackData = ctx.callbackQuery.data; const Strings = getStrings(ctx.from.language_code); @@ -74,6 +84,10 @@ module.exports = (bot) => { await ctx.answerCbQuery(); await ctx.editMessageText(Strings.myLittlePonyDesc, options); break; + case 'helpAbout': + await ctx.answerCbQuery(); + await ctx.editMessageText(Strings.kowalskiAbout, options); + break; case 'helpBack': await ctx.answerCbQuery(); await sendHelpMessage(ctx, true); diff --git a/src/locales/english.json b/src/locales/english.json index 5960138..7edda1c 100644 --- a/src/locales/english.json +++ b/src/locales/english.json @@ -2,6 +2,8 @@ "kowalskiWelcome": "*Hello! I am Kowalski!*\nI was made with love by some nerds who really love programming!\n\n*Before using, you need to read the privacy policy (/privacy) to understand where your data goes when using this bot.*\n\nAlso, you can use /help to see the bot commands!\n\n*Special thanks to @givfnz2 for his many contributions to the bot!*", "kowalskiHelp": "*Hey, I'm Kowalski, a simple bot made entirely from scratch in Telegraf and Node.js by some nerds who really love programming.*\n\nClick on the buttons below to see which commands you can use!\n", "kowalskiPrivacy": "Check out [this link](https://blog.eleu.me/posts/lynx-privacy-policy) to read the bot's privacy policy.", + "kowalskiAbout": "Kowalski was originally created by [Lucas Gabriel (lucmsilva)](https://github.com/lucmsilva651), now maintained by several people.\n\nThe bot's purpose is to bring fun to your groups here on Telegram in a relaxed and simple way. The bot also features some very useful commands, which you can see using the help command (/help).\n\nSee the source code: [Click here to go to GitHub](https://github.com/abocn/TelegramBot)", + "aboutBot": "About the bot", "unKnown": "Unknown", "varYes": "Yes", "varNo": "No", diff --git a/src/locales/portuguese.json b/src/locales/portuguese.json index e2ff21e..20955ab 100644 --- a/src/locales/portuguese.json +++ b/src/locales/portuguese.json @@ -2,9 +2,11 @@ "kowalskiWelcome": "*Olá! Eu sou o Kowalski!*\nFui feito com carinho por uns nerds que gostam de programação!\n\n*Antes de usar, você precisa ler a política de privacidade (/privacy) para entender onde seus dados vão ao usar este bot.*\n\nAlém disso, você pode usar /help para ver os comandos do bot!\n\n*Agradecimento especial ao @givfnz2 pelas suas várias contribuições ao bot!*", "kowalskiHelp": "*Oi, eu sou o Kowalski, um bot simples feito do zero em Telegraf e Node.js por uns nerds que gostam de programação.*\n\nClique nos botões abaixo para ver quais comandos você pode usar!\n", "kowalskiPrivacy": "Acesse [este link](https://blog.eleu.me/posts/lynx-privacy-policy) para ler a política de privacidade do bot.", + "kowalskiAbout": "Kowalski foi feito originalmente por [Lucas Gabriel (lucmsilva)](https://github.com/lucmsilva651), agora sendo mantido por várias pessoas.\n\nA intenção do bot é trazer diversão para os seus grupos aqui no Telegram de uma maneira bem descontraida e simples. O bot também conta com alguns comandos bem úteis, que você consegue ver com o comando de ajuda (/help).\n\nVeja o código fonte: [Clique aqui para ir ao GitHub](https://github.com/abocn/TelegramBot)", + "aboutBot": "Sobre o bot", "unKnown": "Desconhecido", "varYes": "Sim", - "varNo": "Não", + "varNo": "Nsão", "varNone": "Nenhum", "invalidOption": "Ops! Opção inválida!", "kickingMyself": "*Já que você não precisa de mim, vou sair daqui.*",