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
/* | |
* SIMPLE CALENDAR BOILERPLATE | |
* this is not meant to be a stantalone widget but to be a starter template to jumpstart your calendar widget (or any widget with a calendar). | |
* dates can be difficult to work with, so this template is here to make it easier | |
*/ | |
/* | |
* BASE WIDGET STYLING | |
* change the below variables to customize your calendar style | |
*/ |
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
/* | |
* progressCircle(on: Stack or Widget, value: number, colour: string, background: string, size: number, barWidth: number) : Promise<Stack> | |
* | |
* PARAMS | |
* on - the stack or widget to add the progress circle to | |
* value - a number between 1 and 100 to be the circle percentage or a number between 0 and 1 to be the circle percentage | |
* colour - a HTML supported (hex, rgb, hsl) colour for the progress of the circle. Alternitively, it can be two HTML supported colours seperated by a hyphen (white-black) for the first colour to be active on light mode and second on dark mode | |
* background - a HTML supported (hex, rgb, hsl) colour for the unfilled progress of the circle. Alternitively, it can be two HTML supported colours seperated by a hyphen (white-black) for the first colour to be active on light mode and second on dark mode | |
* size - the size of the progress circle | |
* barWidth - the width of the circular progress bar |
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
function parseXML(string) { | |
/* | |
* Part 1 | |
* | |
* Parse the xml into a DOM-like json | |
* | |
* Input: <tag attribute="value">text node<inline>text node</inline>text node</tag> | |
* | |
* Output: | |
* { |
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
/* | |
* HTMLGradient | |
* | |
* HTMLGradient(gradient: string): Promis<gradient> | |
* | |
* example | |
* ------------ | |
* const widget = new ListWidget() | |
* widget.backgroundGradient = await HTMLGradient("to left, red, green 25%, blue-yellow") | |
* widget.presentSmall() |
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
/* | |
Call | |
ListWidget.addHr() | |
WidgetStack.addHr() | |
Return | |
WidgetHorizontalRule | |
Properties | |
color: Color |