Skip to content

Commit c5f326a

Browse files
authored
Merge pull request espruino#4105 from RKBoss6/icons
Message Icons - Add new icons
2 parents 1c2c6f0 + 145ff3c commit c5f326a

File tree

10 files changed

+22
-2
lines changed

10 files changed

+22
-2
lines changed

apps/messageicons/ChangeLog

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,4 @@
1111
0.10: Fix broken PNG icons
1212
0.11: Add icons for Meshtastic, Gotify. Update icon for Home Assistant. Add icon for "Element Classic" after "Element" has been renamed. (Keeping "Element" as well for backwards compatibility.)
1313
0.12: Add message icon for 'ntfy'
14+
0.13: Add icons for 'shortcuts', 'roborock', 'adp', and 'duolingo'

apps/messageicons/README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# Message Icons
2+
Provides icons for phone apps that are utilized by `message gui` and any other message display app.
3+
4+
## Adding your own icons
5+
- Clone the repo on your local machine, if you haven't done so already.
6+
- Locate the image you want to use as an icon. Make sure it is 24x24px, and has a black foreground and transparent background (you can color the foreground one color only later on)
7+
- Upload it to the `icons` folder in the `messageicons` folder.
8+
- Add your app name and the corresponding image you added to the `icon_names.json` file
9+
- Run the `generate.js` script. Be sure you have the `png-js` dependency needed. (you can install it by running `npm install png-js` in the terminal)
10+
- Once finished generating, navigate to the `lib.js` file, and add the color for your foreground and the corresponding app.

apps/messageicons/icons.img

304 Bytes
Binary file not shown.

apps/messageicons/icons/adp.png

1.18 KB
Loading
1.25 KB
Loading

apps/messageicons/icons/icon_names.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
[
22
{ "app":"default", "icon":"default.png" },
3+
{ "app":"adp", "icon":"adp.png" },
34
{ "app":"airbnb", "icon":"airbnb.png" },
45
{ "app":"agenda", "icon":"agenda.png" },
56
{ "app":"alarm", "icon":"alarm.png" },
@@ -20,6 +21,7 @@
2021
{ "app":"corona-warn", "icon":"coronavirus.png" },
2122
{ "app":"bmo", "icon":"bank.png" },
2223
{ "app":"desjardins", "icon":"bank.png" },
24+
{ "app":"duolingo", "icon":"duolingo.png" },
2325
{ "app":"rbc mobile", "icon":"bank.png" },
2426
{ "app":"nbc", "icon":"bank.png" },
2527
{ "app":"rabobank", "icon":"bank.png" },
@@ -94,9 +96,11 @@
9496
{ "app":"slide", "icon":"reddit.png" },
9597
{ "app":"signal", "icon":"signal.png" },
9698
{ "app":"molly", "icon":"signal.png" },
99+
{ "app":"roborock", "icon":"roborock.png" },
97100
{ "app":"skype", "icon":"skype.png" },
98101
{ "app":"slack", "icon":"slack.png" },
99102
{ "app":"snapchat", "icon":"snapchat.png" },
103+
{ "app":"shortcuts", "icon":"shortcuts.png" },
100104
{ "app":"starbucks", "icon":"cafe.png" },
101105
{ "app":"steam", "icon":"steam.png" },
102106
{ "app":"teams", "icon":"teams.png" },
3.61 KB
Loading
1.37 KB
Loading

apps/messageicons/lib.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ exports.getImage = function(msg) {
44
if (msg.img) return atob(msg.img);
55
let s = (("string"=== typeof msg) ? msg : (msg.src || "")).toLowerCase();
66
if (msg.id=="music") s="music";
7-
let match = ",default|0,airbnb|1,agenda|2,alarm|3,alarmclockreceiver|3,amazon shopping|4,bereal.|5,bibel|6,bitwarden|7,1password|7,lastpass|7,dashlane|7,bring|8,calendar|9,etar|9,chat|10,chrome|11,clock|3,corona-warn|12,bmo|13,desjardins|13,rbc mobile|13,nbc|13,rabobank|13,scotiabank|13,td (canada)|13,davx⁵|14,discord|15,drive|16,element|17,element classic|17,element x|17,facebook|18,messenger|19,firefox|20,firefox beta|20,firefox nightly|20,f-droid|7,neo store|7,aurora droid|7,github|21,gitlab|22,gmail|23,gmx|24,google|25,google home|26,google play store|27,gotify|28,home assistant|29,instagram|30,jira|31,kalender|32,keep notes|33,kleinanzeigen|34,leboncoin|35,lieferando|36,linkedin|37,maps|38,meshtastic|39,organic maps|38,osmand|38,mastodon|40,fedilab|40,tooot|40,tusky|40,mattermost|41,messages|42,n26|43,netflix|44,news|45,cbc news|45,rc info|45,reuters|45,ap news|45,la presse|45,nbc news|45,nextbike|46,nextcloud|47,nina|48,ntfy|49,outlook mail|50,paypal|51,phone|52,plex|53,pocket|54,post & dhl|55,proton mail|56,reddit|57,sync pro|57,sync dev|57,boost|57,infinity|57,slide|57,signal|58,molly|58,skype|59,slack|60,snapchat|61,starbucks|62,steam|63,teams|64,telegram|65,telegram foss|65,threema|66,threema libre|66,thunderbird|67,tiktok|68,to do|69,opentasks|69,tasks|69,transit|70,twitch|71,twitter|72,uber|73,lyft|73,vlc|74,warnapp|75,whatsapp|76,wordfeud|77,youtube|78,newpipe|78,zoom|79,meet|79,music|80,sms message|0,mail|0,".match(new RegExp(`,${s}\\|(\\d+)`))
7+
let match = ",default|0,adp|1,airbnb|2,agenda|3,alarm|4,alarmclockreceiver|4,amazon shopping|5,bereal.|6,bibel|7,bitwarden|8,1password|8,lastpass|8,dashlane|8,bring|9,calendar|10,etar|10,chat|11,chrome|12,clock|4,corona-warn|13,bmo|14,desjardins|14,duolingo|15,rbc mobile|14,nbc|14,rabobank|14,scotiabank|14,td (canada)|14,davx⁵|16,discord|17,drive|18,element|19,element classic|19,element x|19,facebook|20,messenger|21,firefox|22,firefox beta|22,firefox nightly|22,f-droid|8,neo store|8,aurora droid|8,github|23,gitlab|24,gmail|25,gmx|26,google|27,google home|28,google play store|29,gotify|30,home assistant|31,instagram|32,jira|33,kalender|34,keep notes|35,kleinanzeigen|36,leboncoin|37,lieferando|38,linkedin|39,maps|40,meshtastic|41,organic maps|40,osmand|40,mastodon|42,fedilab|42,tooot|42,tusky|42,mattermost|43,messages|44,n26|45,netflix|46,news|47,cbc news|47,rc info|47,reuters|47,ap news|47,la presse|47,nbc news|47,nextbike|48,nextcloud|49,nina|50,ntfy|51,outlook mail|52,paypal|53,phone|54,plex|55,pocket|56,post & dhl|57,proton mail|58,reddit|59,sync pro|59,sync dev|59,boost|59,infinity|59,slide|59,signal|60,molly|60,roborock|61,skype|62,slack|63,snapchat|64,shortcuts|65,starbucks|66,steam|67,teams|68,telegram|69,telegram foss|69,threema|70,threema libre|70,thunderbird|71,tiktok|72,to do|73,opentasks|73,tasks|73,transit|74,twitch|75,twitter|76,uber|77,lyft|77,vlc|78,warnapp|79,whatsapp|80,wordfeud|81,youtube|82,newpipe|82,zoom|83,meet|83,music|84,sms message|0,mail|0,".match(new RegExp(`,${s}\\|(\\d+)`))
88
return require("Storage").read("messageicons.img", (match===null)?0:match[1]*76, 76);
99
};
1010

@@ -17,10 +17,12 @@ exports.getColor = function(msg,options) {
1717
return {
1818
/* generic colors, using B2-safe colors */
1919
"agenda": "#206cd5",
20+
"adp": "#f00",
2021
"airbnb": "#ff385c", // https://news.airbnb.com/media-assets/category/brand/
2122
"mail": "#ff0",
2223
"music": "#f0f",
2324
"phone": "#0f0",
25+
"duolingo": "#58cc02", // https://design.duolingo.com/identity/color#core-brand-colors
2426
"sms message": "#0ff",
2527
"bibel": "#54342c",
2628
"bring": "#455a64",
@@ -54,10 +56,12 @@ exports.getColor = function(msg,options) {
5456
"pocket": "#ef4154f", // https://blog.getpocket.com/press/
5557
"post & dhl": "#f2c101",
5658
"reddit": "#ff4500", // https://www.redditinc.com/brand
59+
"roborock": "#f00",
5760
"signal": "#3a76f0", // https://github.com/signalapp/Signal-Desktop/blob/main/images/signal-logo.svg
5861
"skype": "#0078d4", // https://developer.microsoft.com/en-us/fluentui#/styles/web/colors/products
5962
"slack": "#e51670",
6063
"snapchat": "#ff0",
64+
"shortcuts": "#cc00ff",
6165
"steam": "#171a21",
6266
"teams": "#6264a7", // https://developer.microsoft.com/en-us/fluentui#/styles/web/colors/products
6367
"telegram": "#0088cc",

apps/messageicons/metadata.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
{
22
"id": "messageicons",
33
"name": "Message Icons",
4-
"version": "0.12",
4+
"version": "0.13",
55
"description": "Library containing a list of icons and colors for apps",
66
"icon": "app.png",
77
"type": "module",
88
"tags": "tool,system",
99
"supports": ["BANGLEJS","BANGLEJS2"],
10+
"readme":"README.md",
1011
"provides_modules" : ["messageicons"],
1112
"default": true,
1213
"storage": [

0 commit comments

Comments
 (0)