Edit: I encountered some bugs while using this method. It might not be related to the application, but I ended up changing the keymap from Blender. I made another post about specific settings to do so. Link
Before using Blender 4.2.3, I used game engines such as Unity. So, I wanted to use a right-click and “hold” to pan or rotate within the viewport. I also wanted to use a single right-click to open the options as usual. Lastly, I wanted the changes to only apply to Blender.
Changing keymaps required too many changes (which I know nothing about), so I used an external program to apply practically the same effect.
Here are the instructions.
1. Download and Install X-Mouse Button Control (Free)

Download Link: https://www.highrez.co.uk/downloads/xmousebuttoncontrol.htm
2. Click “Add” and find Blender.exe

3. In the Right-Click section, find Button Held: (undefined)

4. Apply these options

- Normal Click - Middle Click
- Check Held for - 50 ms / Right Click
- Check "Wait until the physical button is released before releasing the last timed action"
- Check "Abort and revert to the normal click action when the mouse moves"
5. Check whether the Button Held is selected and “Apply”

Done! The right-click will act as expected. Drag and hold a right mouse button to pan or rotate within the viewport, and click a right mouse button to open the options. The settings will only apply to Blender as well.