[dev-tools] Fix flashing of disabled state on indicator (#77727)
This PR adds a better heuristic for detecting whether the dev indicator
is in a disabled state or not. Right now the only way to disable it is
with a `devIndicators: false` in `next.config.js`.
But the flag is read in async, meaning the surface on load always
flashes between the two states (the one with the ℹ icon is the disabled
state):
https://github.com/user-attachments/assets/847615de-9376-431b-855f-50aa6cf4026c
In this PR, we are deferring rendering the indicator until we can
reliably know which state it should be in.
As a bonus, we are also using `state.buildError` to detect whether the
indicator should be in a build error state. Relying on
`runtimeErrors.length` as we did previously is not as reliable since we
also load the runtime errors in async so they will be empty on first
render which does not necessarily indicate a build error.