From 6c355c4abe8f5c0d707292ec87d4b2105612a743 Mon Sep 17 00:00:00 2001 From: Nikolay Tatarinov Date: Wed, 18 Feb 2026 00:13:59 +0300 Subject: [PATCH] Enhance Telegram WebApp integration and update CSS styles - Added functionality to set background and header colors for the Telegram WebApp to improve visual consistency. - Updated CSS to hide scrollbars and enhance the overall user experience by preventing overscroll behavior. - Adjusted box-shadow for the calendar sticky header for a more refined appearance. --- webapp/app.js | 7 +++++++ webapp/style.css | 13 ++++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/webapp/app.js b/webapp/app.js index 46df0a0..e325d4c 100644 --- a/webapp/app.js +++ b/webapp/app.js @@ -448,6 +448,13 @@ if (window.Telegram.WebApp.expand) { window.Telegram.WebApp.expand(); } + var bg = "#1a1b26"; + if (window.Telegram.WebApp.setBackgroundColor) { + window.Telegram.WebApp.setBackgroundColor(bg); + } + if (window.Telegram.WebApp.setHeaderColor) { + window.Telegram.WebApp.setHeaderColor(bg); + } setTimeout(cb, 0); } else { cb(); diff --git a/webapp/style.css b/webapp/style.css index ba2c492..13414a4 100644 --- a/webapp/style.css +++ b/webapp/style.css @@ -8,6 +8,17 @@ --today: #bb9af7; } +html { + scrollbar-gutter: stable; + scrollbar-width: none; + -ms-overflow-style: none; + overscroll-behavior: none; +} + +html::-webkit-scrollbar { + display: none; +} + * { box-sizing: border-box; } @@ -84,7 +95,7 @@ body { } .calendar-sticky.is-scrolled { - box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25); + box-shadow: 0 4px 6px -4px rgba(0, 0, 0, 0.25); } .calendar {