Refactor metadata and viewport preloading (#77400)
metadata and viewport are attempted to be resolved concurrently even
when async functions are used via `generateMetadata` and
`generateViewport`. We call this preloading because we initiate the
generation ahead of time but if it turns out that any particular
generator requires the parent resolved values we can progressively
reveal these to each pending generator. This PR refactors the code a bit
to simplify and clarify this process. This is setting the stage to later
separate out the resolution of viewport from metadata since only
viewport is now blocking the root.