My favorite is the local tax office charges extra for paying online vs going in to the office to pay in person. At first, I thought it was a way to recoup the processing fees as you're obviously paying by card online. The last time I paid in person with a card, that fee was not added on though. So they are charging you extra for not having to pay an employee to process your account.
Until a few years ago merchants were not allowed to charge credit card fees. In that case, online fees make a legally-allowable proxy for credit card surcharges.
the whole allowed to/not allowed to charge extra to cover the processing fees is a yo-yo. One of the best known examples is gas stations showing you different prices for credit/cash on their signs. So the "until a few years ago" seems like some internet trope as I can remember the gas station signs showing cash/credit from back when I was a kid, and let's just all agree that wasn't "a few years ago"
It might also be that you’re just hearing from people in different states. More than half of the states allow surcharges, but that can change: for example, Oklahoma removed the ban just last year:
https://legiscan.com/OK/text/SB677/id/3231564