This is a very handy feature!
The default key is the ~ ("tilde") key, unshifted, normally found below the "Esc" key. But to select the panel to be expanded you must click on its left-hand tab, the one where its name appears - you can't click just anywhere in the panel to select it for this purpose.
For instance, if you click on the tab of the waveform or track display labeled "Main" and then press the ~ key, it will temporarily expand to fill the whole window. Press the ~ key again and it goes back to its previous size. This can be very useful if your monitor is not very large and you have many panels displayed at once.
The keyboard shortcut can be changed using "Edit>Keyboard shortcuts" if you wish.