Custom MQTT components

I’m looking to create a custom component with a group of input controls that publish/subscribe MQTT topics.

For example, the MQTT light component has a toggle button, a brightness slider and an RGB color picker, each with a command and a status topic.

I would like to create components with my own collection of controls.

So first off, am I right in thinking this requires me to write a custom component?

Next, can someone point me to the best way to get started?

I have read the Cookbook -> Custom Python Component Examples -> Basic MQTT Example. It describes the python code for the underlying logic, but I fail to see how the GUI side of the component is configured.

Hi,

Did you ever work this out as I am struggling to find documentation on how the controls in the front end display cards are selected for a custom component.

I understand that I can create a custom card but in many respects I am just looking to display a simple toggle switch or slider control.

Thanks

Stuart