Files
community-plugins/battery-widget/README.md
T
Yocraft-2000andGitHub 6db8390fd5 Add Battery widget plugin (#178)
* Init

* fix: remove placeholder (weird bugs)

* fix: README

* fix: return if battery not found

* fix: add "Not Charging" status

* fix: insert in content table

* feat: add error color when under 20% and discharging

* feat: add warning color setting

* fix(README): longer plugin description and settings descriptions

* feat: add color and charging color

* fix: default charging color
2026-07-31 23:15:04 -04:00

35 lines
1.4 KiB
Markdown

# Battery Widget
Desktop/lockscreen widget that displays the current battery level and charging status.
## Plugin
| Field | Value |
| --- | --- |
| ID | `yocraft/battery-widget` |
| Entries | Desktop widget: `widget` |
## Usage
Add it to your desktop/lockscreen widgets.
## Settings
| Setting | Type | Default | Description |
| --- | --- | --- | --- |
| `layout` | `select` | `horizontal` | Layout of the widget. |
| `show_glyph` | `bool` | `true` | Show the battery icon. |
| `show_label` | `bool` | `true` | Show text next to the icon. |
| `hide_plugged` | `bool` | `false` | Hide the battery widget when connected to AC power. |
| `hide_full` | `bool` | `false` | Hide the battery widget when fully charged. |
| `color` | `color` | `on_surface` | Color role for this widget's icon and label; fixed hex colors are also supported. |
| `warning_color` | `color` | `error` | Color applied when charge is at or below 20%. |
| `charging_color` | `color` | `on_surface` | Color applied when connected to AC power. |
| `battery` | `select` | `auto` | Detect the battery automatically or set a custom name. |
| `battery_name` | `string` | `BAT0` | Set a custom name for the battery. |
| `refresh_interval` | `int` | `60` | Controls how frequently the widget updates its content. (in seconds) |
## Notes
`hide_full` and `hide_plugged` do not hide the background due to plugin limitations.