Get widgets on an ESPHome LVGL page
esphome_lvgl_get_page_widgetsLists all LVGL widgets on an ESPHome device page by parsing its YAML, showing type, ID, position, and key properties. Use before adding or removing widgets to inspect the widget tree.
Instructions
Get all LVGL widgets on one page of an ESPHome device.
Parses the device's YAML and summarises each widget on the requested
page: type, ID, position and key properties. Lambda callback values are
shown as the literal string <lambda> (opaque here — use
esphome_get_config to see the full source).
Use when: inspecting an existing page's widget tree before adding or
removing a widget.
Not for: page-level metadata only — use esphome_lvgl_get_pages.
Returns: {"device", "page", "widget_count", "widgets": [...]}.
Errors: {"error": "..."} when the file can't be found/parsed, when
there is no lvgl: section, or when page_id doesn't exist.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| page_id | Yes | LVGL page ID to inspect, from `esphome_lvgl_get_pages`. | |
| device_name | Yes | Device name, with or without the '.yaml' suffix, e.g. 'kitchen_display'. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||