Disable Firefox Forward/Back key mappings for Mouse4 and Mouse5 (wayland)

I am on Fedora running GNOME 41 on Wayland. I want to disable Mouse4/Mouse5(BTN_SIDE and BTN_EXTRA) button mapping which by default executes page back and page forward action on browsers.

I cannot use xinput to do this as it will do it only for XWayland applications and Firefox/Chrome run in native Wayland mode.

Any ideas?

Hi, I search on internet some said that mousebutton config in Firefox Linux about:config are not available, but when I tried, it’s actually available. May be you want to try about:config on Firefox and search for mousebutton.

For Chromium base browser, for now I’m still can’t find any information about it even in their docs.

Update:

Btw there an app name input-mapper. Maybe you want give it a try. Bellow are on how to install it on Fedora Linux:

sudo dnf install python3-devel python3-pydbus python3-evdev gtksourceview4
git clone https://github.com/sezanzeb/input-remapper.git
cd input-remapper
sudo python3 setup.py install
sudo systemctl enable input-remapper
sudo systemctl start input-remapper

Then open the app from the app list. Let me know if you unable (failed) to build and install it.

Hello there!

So many thank you for “how to” install of input-mapper!

I have just install Fedora, and it’s a new world on “how to” for me,
since I am use to use EndeavourOS (Arch), and I must say, so far,
I like what i see! - Fedora feels away faster some how…