This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Variables used by Scriptable. | |
// These must be at the very top of the file. Do not edit. | |
// icon-color: brown; icon-glyph: magic; | |
const API_URL = 'https://www.edg.de/JsonHandler.ashx?cmd=findtrash&feiertag=0' | |
const TITLE_ICON = '🗑️' | |
const TITLE = 'EDG' | |
const ENTRIES = 3 | |
const getTrashTypeColor = type => { | |
if (type === 'Wertstoffe') { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Variables used by Scriptable. | |
// These must be at the very top of the file. Do not edit. | |
// icon-color: brown; icon-glyph: magic; | |
const getUsageColor = (usage) => { | |
usage = parseInt(usage) | |
if (usage >= 90) { | |
return Color.red(); | |
} else if (usage >= 75) { | |
return Color.orange(); | |
} else { |