If Tesla making the service manuals free is due to the Massachusetts right-to-repair law, then how do other manufacturers (eg: Ford) still get away with not doing so?
I don't think there's a requirement that they give access for free but they are alone i think in doing so.
Here in the UK (where i also have free tesla repair manual access) i have to pay a daily rate (there are annual subscriptions available) for other marques and i would say it's not cheap.
For example, ford charges me £20/hour or £75/day for access to manuals, wiring diagrams, online connected diagnostics (which sounds more impressive than it is, the UI will show vehicle status like fuel tank level or error codes reported by the various ECUs, without physically connecting to the vehicle, i.e. it's done over the vehicle telemetry link), and the ability to connect via a data link connector device for diagnostics and some reflashing activities. Security activities like key coding require a further (chargeable) registration).
The same setup is available by at least VAG, BMW and Fiat Chrysler (the latter has an annoying extra device registration step the others don't). All chargeable.