Tapping the Tab key in Photoshop will hide the Toolbar as well as panels. Tapping again displays them. Adding the Shift key will hide only the panels. While the panels are hidden, positioning the cursor at the edge of the monitor (or application frame on Mac) will display the panels in order to access the tools/options that you need and, when you move your cursor away, Photoshop will automatically hide them (similar to a roll-over effect).
To toggle off this feature, choose Preferences > Workspace > Auto-Show Hidden Panels or Control -click (Mac) | Right -click (Win) on the name of any panel (in Expanded view) and choose Auto-Show Hidden Panels.