Download: https://github.com/zxbc/BAR_widgets/blob/main/gui_capslock_camera_pan.lua
This is per a request and a small update to the already in-game widget "Middle Mouse Smooth Scroll". Instead of middle mouse button, this widget uses capslock. Press down capslock to pan camera in the direction of mouse cursor, release capslock to stop. This should provide an alternative way to pan camera and possibly allow for more flexibility in keybind.
Yes, I know, capslock will be on often and people will be typing in caps as a result. Until I find a solution to that (which I think is unlikely from within the game), you'll just have to excuse these folks.