diff --git a/agent.mail.ru/css/franz.css b/agent.mail.ru/css/franz.css new file mode 100644 index 0000000..0edf85f --- /dev/null +++ b/agent.mail.ru/css/franz.css @@ -0,0 +1,3 @@ +.nwa-header__popup { + display: none; +} diff --git a/agent.mail.ru/icon.png b/agent.mail.ru/icon.png new file mode 100644 index 0000000..5e4a828 Binary files /dev/null and b/agent.mail.ru/icon.png differ diff --git a/agent.mail.ru/icon.svg b/agent.mail.ru/icon.svg new file mode 100644 index 0000000..96ede37 --- /dev/null +++ b/agent.mail.ru/icon.svg @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/agent.mail.ru/index.js b/agent.mail.ru/index.js new file mode 100644 index 0000000..46f936f --- /dev/null +++ b/agent.mail.ru/index.js @@ -0,0 +1,2 @@ +// just pass through Franz +module.exports = Franz => Franz; diff --git a/agent.mail.ru/package.json b/agent.mail.ru/package.json new file mode 100644 index 0000000..ffeb38e --- /dev/null +++ b/agent.mail.ru/package.json @@ -0,0 +1,23 @@ +{ + "name": "Агент Mail.Ru", + "version": "1.0.0", + "description": "Агент Mail.Ru для веб-браузеров – общение с любого компьютера, бесплатные SMS, звонки на телефоны", + "main": "index.js", + "author": "Impeck ", + "license": "MIT", + "config": { + "serviceURL": "http://webagent.mail.ru/webim/agent/popup.html", + "serviceName": "Агент Mail.Ru", + "message": "Веб-Агент – облегченная версия Агента специально для веб-браузеров.", + "popup": [], + "hasNotificationSound": true, + "hasIndirectMessages": false, + "hasTeamID": false, + "customURL": false, + "hostedOnly": false, + "webviewOptions": { + "disablewebsecurity": "" + }, + "openDevTools": false + } +} diff --git a/agent.mail.ru/webview.js b/agent.mail.ru/webview.js new file mode 100644 index 0000000..b82b676 --- /dev/null +++ b/agent.mail.ru/webview.js @@ -0,0 +1,17 @@ +const path = require('path'); + +module.exports = (Franz, options) => { + const getMessages = () => { + var counter = 0; + var matches = document.querySelectorAll("span.nwa-msg-counter"); + for(var i = 0; i < matches.length; i++){ + counter += parseInt(matches[i].innerHTML, 10); + } + Franz.setBadge(counter); + } + + Franz.loop(getMessages); + + Franz.injectCSS(path.join(__dirname, 'css', 'franz.css')); +}; + diff --git a/icq/icon.png b/icq/icon.png new file mode 100644 index 0000000..33d8d57 Binary files /dev/null and b/icq/icon.png differ diff --git a/icq/icon.svg b/icq/icon.svg new file mode 100644 index 0000000..01a5f5d --- /dev/null +++ b/icq/icon.svg @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/icq/index.js b/icq/index.js new file mode 100644 index 0000000..46f936f --- /dev/null +++ b/icq/index.js @@ -0,0 +1,2 @@ +// just pass through Franz +module.exports = Franz => Franz; diff --git a/icq/package.json b/icq/package.json new file mode 100644 index 0000000..4aaad0b --- /dev/null +++ b/icq/package.json @@ -0,0 +1,23 @@ +{ + "name": "ICQ", + "version": "1.0.0", + "description": "Simple way to communicate and nothing extra. New design, free sound and video calls, group chats and much more!", + "main": "index.js", + "author": "Impeck ", + "license": "MIT", + "config": { + "serviceURL": "https://web.icq.com", + "serviceName": "ICQ", + "message": "Simple way to communicate and nothing extra.", + "popup": [], + "hasNotificationSound": false, + "hasIndirectMessages": false, + "hasTeamID": false, + "customURL": false, + "hostedOnly": false, + "webviewOptions": { + "disablewebsecurity": "" + }, + "openDevTools": false + } +} diff --git a/icq/webview.js b/icq/webview.js new file mode 100644 index 0000000..bc1d77f --- /dev/null +++ b/icq/webview.js @@ -0,0 +1,17 @@ +const path = require('path'); + +module.exports = (Franz, options) => { + const getMessages = () => { + if ($('.nwa-msg-counter').css('display') != "none") { + const counter = Number($('.nwa-msg-counter').html()); + Franz.setBadge(counter); + } else { + Franz.setBadge(0); + } + } + + Franz.loop(getMessages); + + //Franz.injectCSS(path.join(__dirname, 'css', 'franz.css')); +}; + diff --git a/mail.ru/css/franz.css b/mail.ru/css/franz.css new file mode 100644 index 0000000..58e0cc5 --- /dev/null +++ b/mail.ru/css/franz.css @@ -0,0 +1,3 @@ +#leftcol-banners{ + display: none; +} \ No newline at end of file diff --git a/mail.ru/icon.png b/mail.ru/icon.png new file mode 100644 index 0000000..72e0e99 Binary files /dev/null and b/mail.ru/icon.png differ diff --git a/mail.ru/icon.svg b/mail.ru/icon.svg new file mode 100644 index 0000000..afbe41e --- /dev/null +++ b/mail.ru/icon.svg @@ -0,0 +1,20 @@ + + + + + + + + + + + + + diff --git a/mail.ru/index.js b/mail.ru/index.js new file mode 100644 index 0000000..46f936f --- /dev/null +++ b/mail.ru/index.js @@ -0,0 +1,2 @@ +// just pass through Franz +module.exports = Franz => Franz; diff --git a/mail.ru/package.json b/mail.ru/package.json new file mode 100644 index 0000000..70a0c39 --- /dev/null +++ b/mail.ru/package.json @@ -0,0 +1,23 @@ +{ + "name": "@MAIL.RU", + "version": "1.0.0", + "description": "@MAIL.RU — ведущая бесплатная почта Рунета", + "main": "index.js", + "author": "Impeck ", + "license": "MIT", + "config": { + "serviceURL": "https://e.mail.ru/messages/inbox/", + "serviceName": "@MAIL.RU", + "message": "Ведущая бесплатная почта Рунета.", + "popup": [], + "hasNotificationSound": true, + "hasIndirectMessages": false, + "hasTeamID": false, + "customURL": false, + "hostedOnly": false, + "webviewOptions": { + "disablewebsecurity": "" + }, + "openDevTools": false + } +} diff --git a/mail.ru/webview.js b/mail.ru/webview.js new file mode 100644 index 0000000..4dc5cdd --- /dev/null +++ b/mail.ru/webview.js @@ -0,0 +1,13 @@ +const path = require('path'); + +module.exports = (Franz, options) => { + const getMessages = () => { + const counter = Number($('#g_mail_events').html()); + Franz.setBadge(counter); + } + + Franz.loop(getMessages); + + Franz.injectCSS(path.join(__dirname, 'css', 'franz.css')); +}; + diff --git a/ok.ru/icon.png b/ok.ru/icon.png new file mode 100644 index 0000000..ba6e47e Binary files /dev/null and b/ok.ru/icon.png differ diff --git a/ok.ru/icon.svg b/ok.ru/icon.svg new file mode 100644 index 0000000..052b03f --- /dev/null +++ b/ok.ru/icon.svg @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/ok.ru/index.js b/ok.ru/index.js new file mode 100644 index 0000000..46f936f --- /dev/null +++ b/ok.ru/index.js @@ -0,0 +1,2 @@ +// just pass through Franz +module.exports = Franz => Franz; diff --git a/ok.ru/package.json b/ok.ru/package.json new file mode 100644 index 0000000..e10feb5 --- /dev/null +++ b/ok.ru/package.json @@ -0,0 +1,23 @@ +{ + "name": "Одноклассники", + "version": "1.0.0", + "description": "Развлекательная социальная сеть для общения с друзьями, просмотра фильмов и сериалов, прослушивания музыки и многого другого.", + "main": "index.js", + "author": "Impeck ", + "license": "MIT", + "config": { + "serviceURL": "https://ok.ru/messages", + "serviceName": "Одноклассники", + "message": "Развлекательная социальная сеть для общения с друзьями, просмотра фильмов и сериалов, прослушивания музыки и многого другого.", + "popup": [], + "hasNotificationSound": false, + "hasIndirectMessages": false, + "hasTeamID": false, + "customURL": false, + "hostedOnly": false, + "webviewOptions": { + "disablewebsecurity": "" + }, + "openDevTools": false + } +} diff --git a/ok.ru/webview.js b/ok.ru/webview.js new file mode 100644 index 0000000..036d5d4 --- /dev/null +++ b/ok.ru/webview.js @@ -0,0 +1,12 @@ +const path = require('path'); + +module.exports = (Franz, options) => { + const getMessages = () => { + const counter = parseInt($("title").html().replace(/\D+/g,"")); + Franz.setBadge(counter); + } + + Franz.loop(getMessages); + + //Franz.injectCSS(path.join(__dirname, 'css', 'franz.css')); +}; diff --git a/tamtam.chat/icon.png b/tamtam.chat/icon.png new file mode 100644 index 0000000..9736c94 Binary files /dev/null and b/tamtam.chat/icon.png differ diff --git a/tamtam.chat/icon.svg b/tamtam.chat/icon.svg new file mode 100644 index 0000000..93c8398 --- /dev/null +++ b/tamtam.chat/icon.svg @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/tamtam.chat/index.js b/tamtam.chat/index.js new file mode 100644 index 0000000..46f936f --- /dev/null +++ b/tamtam.chat/index.js @@ -0,0 +1,2 @@ +// just pass through Franz +module.exports = Franz => Franz; diff --git a/tamtam.chat/package.json b/tamtam.chat/package.json new file mode 100644 index 0000000..81bc60d --- /dev/null +++ b/tamtam.chat/package.json @@ -0,0 +1,23 @@ +{ + "name": "ТамТам", + "version": "1.0.0", + "description": "ТамТам — бесплатный мессенджер для комфортного и повседневного общения.", + "main": "index.js", + "author": "Impeck ", + "license": "MIT", + "config": { + "serviceURL": "https://tamtam.chat", + "serviceName": "ТамТам", + "message": "ТамТам — бесплатный мессенджер для комфортного и повседневного общения!", + "popup": [], + "hasNotificationSound": false, + "hasIndirectMessages": false, + "hasTeamID": false, + "customURL": false, + "hostedOnly": false, + "webviewOptions": { + "disablewebsecurity": "" + }, + "openDevTools": false + } +} diff --git a/tamtam.chat/webview.js b/tamtam.chat/webview.js new file mode 100644 index 0000000..65ee127 --- /dev/null +++ b/tamtam.chat/webview.js @@ -0,0 +1,17 @@ +const path = require('path'); + +module.exports = (Franz, options) => { + const getMessages = () => { + var text = document.getElementsByClassName('__rmw620'); + var sum = 0; + for (var i = 0 ; i < text.length; i++){ + sum += Number(text[i].innerHTML); + //console.log(sum);// внутри цикла выводится - каждую итерацию + } + //console.log(sum);// снаружи цикла выводится - один раз + Franz.setBadge(sum); + } + + Franz.loop(getMessages); + //Franz.injectCSS(path.join(__dirname, 'css', 'franz.css')); +}; diff --git a/yandex-mail/icon.png b/yandex-mail/icon.png new file mode 100644 index 0000000..2c92924 Binary files /dev/null and b/yandex-mail/icon.png differ diff --git a/yandex-mail/icon.svg b/yandex-mail/icon.svg new file mode 100644 index 0000000..3040719 --- /dev/null +++ b/yandex-mail/icon.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + diff --git a/yandex-mail/index.js b/yandex-mail/index.js new file mode 100644 index 0000000..46f936f --- /dev/null +++ b/yandex-mail/index.js @@ -0,0 +1,2 @@ +// just pass through Franz +module.exports = Franz => Franz; diff --git a/yandex-mail/package.json b/yandex-mail/package.json new file mode 100644 index 0000000..2817e7c --- /dev/null +++ b/yandex-mail/package.json @@ -0,0 +1,23 @@ +{ + "name": "Яндекс.Почта", + "version": "1.0.0", + "description": "Яндекс.Почта — бесплатная электронная почта", + "main": "index.js", + "author": "Impeck ", + "license": "MIT", + "config": { + "serviceURL": "https://mail.yandex.ru/touch/", + "serviceName": "Яндекс.Почта", + "message": "Бесплатная электронная почта.", + "popup": [], + "hasNotificationSound": true, + "hasIndirectMessages": false, + "hasTeamID": false, + "customURL": false, + "hostedOnly": false, + "webviewOptions": { + "disablewebsecurity": "" + }, + "openDevTools": false + } +} diff --git a/yandex-mail/webview.js b/yandex-mail/webview.js new file mode 100644 index 0000000..cc705b1 --- /dev/null +++ b/yandex-mail/webview.js @@ -0,0 +1,13 @@ +const path = require('path'); + +module.exports = (Franz, options) => { + const getMessages = () => { + const unreadMail = Number($('.head-item_counter').html()); + Franz.setBadge(unreadMail); + } + + Franz.loop(getMessages); + + //Franz.injectCSS(path.join(__dirname, 'css', 'franz.css')); +}; +