The updated shipping price and total are reflected in the UI but not the stripe PaymentIntent. This is still a TODO.
A new file called checkout-content.tsx was created to have some allow for "use client" for the majority of the checkout components. This probably should eventually become a shell, but as there was already a checkout-shell deeper in the checkout structure I didn't want to create a second shell to confuse things.
The next.config.js had to be updated because without the changes, there is some sort of hexoid error (which likely has to do with the dependencies introduced with EasyPost).
Getting shipping rates is handled with a server action when the switch for confirming the address is toggled, which makes it so that the Pay button is no longer disabled and shipping rates are rendered. Changing the shipping address resets the confirm switch so that shipping must be recalculated on the next switch toggle.
Currently using the lowest shipping rate, but this can be changed if required.
A few notes about this PR: