diff options
Diffstat (limited to 'recipes/slack')
-rw-r--r-- | recipes/slack/index.js | 2 | ||||
-rw-r--r-- | recipes/slack/package.json | 2 | ||||
-rw-r--r-- | recipes/slack/webview.js | 12 |
3 files changed, 8 insertions, 8 deletions
diff --git a/recipes/slack/index.js b/recipes/slack/index.js index 23607bd..dd41f72 100644 --- a/recipes/slack/index.js +++ b/recipes/slack/index.js | |||
@@ -1 +1 @@ | |||
module.exports = Ferdi => Ferdi; | module.exports = Ferdium => Ferdium; | ||
diff --git a/recipes/slack/package.json b/recipes/slack/package.json index d55842a..5420c5b 100644 --- a/recipes/slack/package.json +++ b/recipes/slack/package.json | |||
@@ -1,7 +1,7 @@ | |||
1 | { | 1 | { |
2 | "id": "slack", | 2 | "id": "slack", |
3 | "name": "Slack", | 3 | "name": "Slack", |
4 | "version": "1.3.5", | 4 | "version": "1.4.0", |
5 | "license": "MIT", | 5 | "license": "MIT", |
6 | "config": { | 6 | "config": { |
7 | "serviceURL": "https://{teamId}.slack.com", | 7 | "serviceURL": "https://{teamId}.slack.com", |
diff --git a/recipes/slack/webview.js b/recipes/slack/webview.js index 924784d..b3722f0 100644 --- a/recipes/slack/webview.js +++ b/recipes/slack/webview.js | |||
@@ -7,7 +7,7 @@ function _interopRequireDefault(obj) { | |||
7 | const SELECTOR_CHANNELS_UNREAD = | 7 | const SELECTOR_CHANNELS_UNREAD = |
8 | '.p-channel_sidebar__channel--unread:not(.p-channel_sidebar__channel--muted)'; | 8 | '.p-channel_sidebar__channel--unread:not(.p-channel_sidebar__channel--muted)'; |
9 | 9 | ||
10 | module.exports = Ferdi => { | 10 | module.exports = Ferdium => { |
11 | const getMessages = () => { | 11 | const getMessages = () => { |
12 | const directMessages = document.querySelectorAll( | 12 | const directMessages = document.querySelectorAll( |
13 | `${SELECTOR_CHANNELS_UNREAD} .p-channel_sidebar__badge, .p-channel_sidebar__link--unread:not([data-sidebar-link-id="Punreads"]):not([data-sidebar-link-id="Pdrafts"]):not([data-sidebar-link-id="Pdms"])`, | 13 | `${SELECTOR_CHANNELS_UNREAD} .p-channel_sidebar__badge, .p-channel_sidebar__link--unread:not([data-sidebar-link-id="Punreads"]):not([data-sidebar-link-id="Pdrafts"]):not([data-sidebar-link-id="Pdms"])`, |
@@ -15,7 +15,7 @@ module.exports = Ferdi => { | |||
15 | const allMessages = | 15 | const allMessages = |
16 | document.querySelectorAll(SELECTOR_CHANNELS_UNREAD).length - | 16 | document.querySelectorAll(SELECTOR_CHANNELS_UNREAD).length - |
17 | directMessages; | 17 | directMessages; |
18 | Ferdi.setBadge(directMessages, allMessages); | 18 | Ferdium.setBadge(directMessages, allMessages); |
19 | }; | 19 | }; |
20 | 20 | ||
21 | const getActiveDialogTitle = () => { | 21 | const getActiveDialogTitle = () => { |
@@ -23,7 +23,7 @@ module.exports = Ferdi => { | |||
23 | '.p-channel_sidebar__channel--selected .p-channel_sidebar__name', | 23 | '.p-channel_sidebar__channel--selected .p-channel_sidebar__name', |
24 | ); | 24 | ); |
25 | 25 | ||
26 | Ferdi.setDialogTitle( | 26 | Ferdium.setDialogTitle( |
27 | element && element.firstChild ? element.firstChild.textContent : null, | 27 | element && element.firstChild ? element.firstChild.textContent : null, |
28 | ); | 28 | ); |
29 | }; | 29 | }; |
@@ -33,7 +33,7 @@ module.exports = Ferdi => { | |||
33 | getActiveDialogTitle(); | 33 | getActiveDialogTitle(); |
34 | }; | 34 | }; |
35 | 35 | ||
36 | Ferdi.loop(loopFunc); | 36 | Ferdium.loop(loopFunc); |
37 | 37 | ||
38 | const getTeamIcon = function getTeamIcon(count = 0) { | 38 | const getTeamIcon = function getTeamIcon(count = 0) { |
39 | let countTeamIconCheck = count; | 39 | let countTeamIconCheck = count; |
@@ -62,7 +62,7 @@ module.exports = Ferdi => { | |||
62 | countTeamIconCheck += 1; | 62 | countTeamIconCheck += 1; |
63 | 63 | ||
64 | if (bgUrl) { | 64 | if (bgUrl) { |
65 | Ferdi.setAvatarImage(bgUrl); | 65 | Ferdium.setAvatarImage(bgUrl); |
66 | } else if (countTeamIconCheck <= 5) { | 66 | } else if (countTeamIconCheck <= 5) { |
67 | setTimeout(() => { | 67 | setTimeout(() => { |
68 | getTeamIcon(countTeamIconCheck + 1); | 68 | getTeamIcon(countTeamIconCheck + 1); |
@@ -74,5 +74,5 @@ module.exports = Ferdi => { | |||
74 | getTeamIcon(); | 74 | getTeamIcon(); |
75 | }, 4000); | 75 | }, 4000); |
76 | 76 | ||
77 | Ferdi.injectCSS(_path.default.join(__dirname, 'service.css')); | 77 | Ferdium.injectCSS(_path.default.join(__dirname, 'service.css')); |
78 | }; | 78 | }; |