Skip to content

Commit

Permalink
Open Telegram links within Ferdium (#394)
Browse files Browse the repository at this point in the history
  • Loading branch information
victorbnl committed Jul 19, 2023
1 parent fd169b7 commit c0146ce
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion recipes/telegram/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "telegram",
"name": "Telegram",
"version": "3.3.5",
"version": "3.3.6",
"license": "MIT",
"config": {
"serviceURL": "https://web.telegram.org",
Expand Down
6 changes: 5 additions & 1 deletion recipes/telegram/webview.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,11 @@ module.exports = (Ferdium, settings) => {
event.preventDefault();
event.stopPropagation();

if (settings.trapLinkClicks === true) {
if (
settings.trapLinkClicks === true
|| url.includes('t.me')
|| url.includes('web.telegram.org')
) {
window.location.href = url;
} else {
Ferdium.openNewWindow(url);
Expand Down

0 comments on commit c0146ce

Please sign in to comment.