Auto-hide button when panel open

I’ve got a nice setup with a right panel, set up to be always visible on or above 768px.

I also included a nice FAB to trigger the panel, in case it’s hidden. But how do I hide the FAB when the panel is open (either by default or because I just opened it with said button)?

From the docs
panel.opened
Boolean property indicating whether it is opened or not.

Make a function to detect when it’s open, and hide the fab when it’s true.