This file contains 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: deep-blue; icon-glyph: grimace; | |
// Variables used by Scriptable. | |
// These must be at the very top of the file. Do not edit. | |
// Corona Zahlen Lahn-Dill | https://www.lahn-dill-kreis.de/buergerservice/gesundheitsamt/hygiene-infektion/lahn-dill-kreisdecoronavirus/ | |
// Credits: | |
// kevinkub https://gist.github.com/kevinkub/46caebfebc7e26be63403a7f0587f664 | |
// rphl https://gist.github.com/rphl/0491c5f9cb345bf831248732374c4ef5 | |
// eqsOne https://talk.automators.fm/t/widget-examples/7994/379 |
This file contains 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: red; icon-glyph: briefcase-medical; | |
// Licence: Robert Koch-Institut (RKI), dl-de/by-2-0 | |
// Alte version siehe: https://gist.github.com/rphl/0491c5f9cb345bf831248732374c4ef5/revisions | |
WIDGET WURDE IN EIN REPO VERSCHOBEN, SIEHE: | |
https://github.com/rphl/corona-widget |
This file contains 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
// Licence: Robert Koch-Institut (RKI), dl-de/by-2-0 | |
class IncidenceWidget { | |
constructor() { | |
this.previousDaysToShow = 31; | |
this.apiUrlDistricts = (location) => `https://services7.arcgis.com/mOBPykOjAyBO2ZKk/arcgis/rest/services/RKI_Landkreisdaten/FeatureServer/0/query?where=1%3D1&outFields=RS,GEN,cases7_bl_per_100k,cases7_per_100k,BL&geometry=${location.longitude.toFixed(3)}%2C${location.latitude.toFixed(3)}&geometryType=esriGeometryPoint&inSR=4326&spatialRel=esriSpatialRelWithin&returnGeometry=false&outSR=4326&f=json` | |
this.apiUrlDistrictsHistory = (districtId) => `https://services7.arcgis.com/mOBPykOjAyBO2ZKk/ArcGIS/rest/services/Covid19_hubv/FeatureServer/0/query?where=IdLandkreis%20%3D%20%27${districtId}%27%20AND%20Meldedatum%20%3E%3D%20TIMESTAMP%20%27${this.getDateString(-this.previousDaysToShow)}%2000%3A00%3A00%27%20AND%20Meldedatum%20%3C%3D%20TIMESTAMP%20%27${this.getDateString(1)}%2000%3A00%3A00%27&outFields=Landkreis,Meldedatum,AnzahlFall&outSR=4326&f=json` | |
this.stateToAbbr = { | |
This file contains 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
// insert your Spotify client id and secret here | |
let clientId = "xxx" | |
let clientSecret = "xxx" | |
// optional: the ip of your node-sonos-http-api and room name; use "sonos" as parameter in your widget settings to activate it | |
let sonosUrl = "http://192.168.178.10:5005/Arbeitszimmer" | |
let openWith = args.widgetParameter | |
let widget = new ListWidget() | |
// widget.setPadding(0,0,0,0) |