Skip to content

Commit 0038702

Browse files
update(start-command) (#10)
* fixed redirect * lint fix * Update dev version (#6) * fix(redirect): Fixed redirect to undefined * fixed redirect * lint fix * Added dev cd pipline --------- Co-authored-by: Mike de Geofroy <[email protected]> * feat(start-command): Updated start command. * updated start command * fix(lint) * fixed lint * modified start command to include media * format-fix --------- Co-authored-by: Alex Dyakonov <[email protected]>
1 parent 52152c2 commit 0038702

File tree

2 files changed

+22
-5
lines changed

2 files changed

+22
-5
lines changed

.env.old

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
BOT_USERNAME=mdg_testing_bot
2+
FRONTEND_URL=http://locahost:5173
3+
BOT_URL=https://1a2f-195-2-92-192.ngrok-free.app

src/commands/start.ts

+19-5
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,35 @@ import { Context, Telegraf } from "telegraf";
33

44
export function setupStartCommand(bot: Telegraf<Context>) {
55
bot.start(async (ctx) => {
6-
const username = ctx.from.username || "unknown";
7-
await ctx.reply(
8-
`Добро пожаловать, @${username}!\nЧтобы воспользоваться ботом, тгени его в любой беседе @${BOT_USERNAME}`,
6+
await ctx.replyWithPhoto(
7+
"https://storage.yandexcloud.net/dishash-s3/assets/bot/cover.png",
98
{
109
reply_markup: {
1110
inline_keyboard: [
1211
[
1312
{
14-
text: "Открыть DishDash 🥪",
15-
switch_inline_query: "",
13+
text: "Открыть DishDash 🤌",
14+
url: `https://t.me/${BOT_USERNAME}/app`,
1615
},
1716
],
1817
],
1918
},
2019
},
2120
);
21+
22+
await ctx.replyWithMediaGroup([
23+
{
24+
type: "photo",
25+
media:
26+
"https://storage.yandexcloud.net/dishash-s3/assets/bot/card_1.jpeg",
27+
caption: `*Как свайпать?*\n\n• Чтобы посмотреть места в одиночку, запустите бота по кнопке ниже\n\n• Чтобы искать места вместе, запустите бота тут и отправьте приглашение в лобби, или тегните @dishdash\\_bot в любом чате`,
28+
parse_mode: "MarkdownV2",
29+
},
30+
{
31+
type: "photo",
32+
media:
33+
"https://storage.yandexcloud.net/dishash-s3/assets/bot/card_2.jpeg",
34+
},
35+
]);
2236
});
2337
}

0 commit comments

Comments
 (0)