This example shows how to show/hide views (i.e. Toolbar or FAB) when a list is scrolled up/down.
There is a blog post explaining the code:
part 1 - outdated
part 2 - outdated
part 3