Claude Code has an elegant solution to the problem you mention, without trying to cram everything into a single nested pane (which feels wrong to me).
In Claude Code, when you edit a file independent from the agent, it automatically notices and says something like "I see you've made a change. Let me take a look."
I wish Gemini CLI would've taken a similar approach, since it seems to fit better with a CLI and its associated Unix philosophy.