Hi, according to your description, I assume you want the button work like this: When a user click on it, the page will be redirected to the opened file in browser.
If that is the desired behavior, simply get the sharing link of that certain document like this, then edit the button web part to the link you get right before.
The link in the screenshot seems to be a URL pointing to a certain view of a document library, which is actually how it works now as you mentioned. And I am not sure about the actual situation here: When I remove the properties from this link, it works again (but it worked before and we don't want to manually change all the links)
If the option I provide above does not fit your requirements, would you like to provide a bit more information about this part and your final goal.
If the response is helpful, please click Accept Answer and upvote it.