After leaving the edge of the screen for a certain distance

After leaving the edge of the screen for a certain distance, trigger a certain action, so that the dock can achieve the effect of auto-hide
(Currently, it is only possible to execute an action immediately after leaving)

You seem to be on a very old version. On current versions you can use this action: