The browser tab is closed and restored using Ctrl + Shift + T.
At the time of its closure or recovery is required to perform some actions.
But it is not necessary to process the transition to other pages, so beforeunload not suitable.
It is guaranteed that the site is open in no more than one tab.
How can this be implemented?