Skip to content

Instantly share code, notes, and snippets.

@JoeGit42
JoeGit42 / forked-telekom.js
Last active January 9, 2022 23:02 — forked from LupusArgentum/telekom-widget-link.md
iOS-Widget für Datenverbrauch im Telekom-Netz (Forked from Sillium/telekom.js)
// Variables used by Scriptable.
// These must be at the very top of the file. Do not edit.
// icon-color: pink; icon-glyph: signal;
// creator: https://github.com/Sillium | changed by https://github.com/LupusArgentum | change again by me, https://github.com/JoeGit42
const apiUrl = "https://pass.telekom.de/api/service/generic/v1/status"
const logoIsWanted = (args.widgetParameter == "logo")
const colorTimeToSignalEndOfMonth = false
const showIndicationIfAPIOffline = false
const showAvailableVolume = true
// 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 Lockdown Zahlen | https://covid.9digits.de/lockdown/26655
// 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
const apiUrl = "https://pass.telekom.de/api/service/generic/v1/status"
let widget = await createWidget()
widget.backgroundColor = new Color("#777777")
if (!config.runsInWidget) {
await widget.presentSmall()
}
Script.setWidget(widget)
Script.complete()