In the end, countries are nuanced enough to understand American political dynamics. They see Orbans, they see Le Pens, they see Trump, and they know what is behind it. I am quite sure that Ukraine did not expect anything else from the Trump faction of the Republican party. His victory was not unlikely and he is a simple creature. If different factions win, they will be eager to work with America again, with less trust and reliance.
Realistically, it is for the best if countries are resilient to US failure. It will make Americans generationally poorer, but the world will be better off for it.