SmallWidget
A widget with few methods (should stay inline with default threshold).
Usage
SmallWidget()Parameters
name: str-
The widget name.
Methods
| Name | Description |
|---|---|
| render() | Render the widget as HTML. |
| resize() | Resize the widget. |
| toggle() | Toggle the widget visibility. |
render()
Render the widget as HTML.
Usage
render()Returns
str-
HTML representation of the widget.
resize()
Resize the widget.
Usage
resize(width, height)Parameters
width: int-
New width in pixels.
height: int-
New height in pixels.
toggle()
Toggle the widget visibility.
Usage
toggle()Returns
bool-
New visibility state.