How do I create a custom widget in C ++?

Hi, the question is that I want to create a UI with c ++, in the following way.

I have 3 buttons. When you press one, the other 2 are hidden and three more buttons appear
Then when clicking on one of the 3 new buttons appears in the list of materials (images), this is where the problem lies, as this list has to be dynamic and adjusted to the amount of materials that are required. And the above must also be done for objects.
I would appreciate it if they gave me an idea of ​​how to start, or if this can be done simply with blueprints

You probably don’t need a custom widget.
Take a look at SAssetProperty and SArrayProperty, using those will do the bulk of the work for you when picking assets.

Examples of their usage here: