Yes, that's also another large part of it. Steel/aluminum/copper went up with the tariffs, plastics went up with COVID and adverse weather, and they never came back down.
The cost isn't only passed on to the customer, the supply base who buys the raw materials to manufacture the components for these vehicles are also being squeezed as well.
But for the EVs; don't forget that these car companies are basically building all new assembly plants just to manufacture the batteries. Those are billion dollar investments. Normally when you launch a new vehicle you have a pre-existing plant to build it in or can modify one, that's often not the case for these batteries.