In the Doctor Who episode Journey to the Center of the TARDIS, The Doctor turned off the shield of TARDIS and suddenly scavengers zapped it and pulled it inside. When they dumped the TARDIS, the gate of TARDIS was still closed, but The Doctor was outside. How? As I recalled, opening the doors required efforts, too (meaning doors weren't soft shut).
Since the show script is no help, if I had to hazard a guess I'd say that when the TARDIS detected the exploding console, it transported the Doctor and Clara to the nearest safe point outside the blast radius. Since the Doctor had his back to the door, it moved him outside and into the pressurised hangar. Because the explosion was between Clara and the Doctor, it moved her in the opposite direction into an adjacent corridor a similar distance away from the explosion (but still inside the TARDIS).
We see an almost identical situation in "The Doctor's Wife", albeit in reverse, removing the inhabitants of a room in danger and moving them into main control room:
The four of them materialize in the console room.
DOCTOR: Yes. I mean you could do that, but it just won't work. Hardwired fail-safe. Living things from rooms that are deleted are automatically deposited in the main control room. But thanks for the lift!