In similar vein ESPHome and Tasmota are 2 independent FOSS projects that can replace proprietary firmware on many commercial smart devices based on ESP32.
Some WiFi-based smart devices like those made by Shelly work without internet access and integrate with HA via local HTTP API.
Fully local smart home is possible, but you'll need to research what you're buying - as a general rule, you should avoid WiFi-based smart devices unless they offer a local API. Everything else (ZigBee, Z-Wave) should work offline without proprietary hubs, though I'm sure there are exceptions.