This can be seen on Enhancer for Youtube, though the extension is proprietary unfortunately so we can't see how they did it.
Perhaps Control + MiddleMouse could then also reset the speed.
If instead of hardcoding these features we want to make them configurable, I think it would be challenging. But the rebinding of mouse input is a lot less useful imo than the rebinding of keyboard shortcuts. Perhaps just add a way to select a modifier key (defaulting to control) and then toggles to enable/disable scrolling and resetting.
This can be seen on Enhancer for Youtube, though the extension is proprietary unfortunately so we can't see how they did it.
Perhaps Control + MiddleMouse could then also reset the speed.
If instead of hardcoding these features we want to make them configurable, I think it would be challenging. But the rebinding of mouse input is a lot less useful imo than the rebinding of keyboard shortcuts. Perhaps just add a way to select a modifier key (defaulting to control) and then toggles to enable/disable scrolling and resetting.