I'm not sure what country you're in, but my country's government (USA) did next to nothing besides issuing hollow advisories. Just a bunch of talk about "please wear a mask" and "pretty please stay at home" and "pretty please with sugar on top, don't go around coughing on each other." But there was almost no enforcement, especially in smaller towns. The only thing pretty consistently enforced was school closures, which obviously wasn't enough.
The USA is a federation, so the laws aren’t the same everywhere. Where I live (NYC) it was absolutely nothing like you describe.
Restaurants and bars were closed until Feb. 2021 (with a brief reprieve in fall 2020) and heavily restricted (capacity restrictions, curfews) for months longer.
Schools were mostly shut down with some brief windows of reopening until Sept. 2021. Yes 2021, so 18 months. Masks were still required in schools for several months longer.
Masks were required on the subway until Sept. 2022. Yes 2022, so 30 months.
So adults were living under severe restrictions for nearly a year, and kids in public school for a year and a half. We were living under some form of restrictions for two and a half years.