Use CTRL-[ to close command-T, similar to how it also exists insert mode.