My garage and garage apartment has two obsolete 1960s-vintage subpanels which I'd like to replace (photos below). The first one, with 6 breakers, will need to stay where it is since the conduit is the feed from the main panel and it would be an involved task to replace or relocate it.
But for the second panel, with 7 breakers (only 5 currently in use), I'm asking if it would be good practice to strip out the breakers, use the shell of the panel as a junction box, and extend the hots and neutrals from the existing breakers through the 1" EMT to the new panelboard and the relocated breakers within? If I do so, may I keep the grounds (only) on the existing circuits tied to the old ground/neutral bar, perhaps with a green ground tie back to the new subpanel? (Yes, I will be careful not to tie the grounds to the neutrals in the new panel. I'll also properly secure the Romex cables to the box in clamps.) Editing To Add: The two panels are physically only about five feet apart.
At some point I want to have the garage and apartment entirely rewired, but for the time being I want to upgrade these old installations. I've already replaced one subpanel of similar vintage which likewise had grounds tied to neutrals; if I complete this project it would make the entire installation code compliant in that respect.