There's a difference between visibility into work progress and just mass surveillance of all activity. The only metric that actually matters is the delivery of value.
Monitoring isn't an effective way to lead. It only reinforces employees to optimize for "looking busy" rather than being effective. If you have to audit your employees daily actions to know if they are doing their job, you've failed as a manager at defining their role or hiring the right people.
A good manager defines the what and the when, and leaves the how to the professional being paid to do it.
By "excuses for layoffs" I suspect what they meant was that there was an pre-existing desire to reduce headcount and RTO was used under the expectation that some percentage of employees would quit voluntarily so that the company can avoid going through the relatively more costly process of laying them off.
Of course the downside of this approach is that the company has less control over which employees leave, which may result in them losing the employees who have the best alternatives.
I don't see any reason to get into a discussion about how much an employer should or shouldn't be able to monitor and control their employees. Some businesses are simply more trusting of their employees and allow a great deal of independence, while others aren't. Those that aren't will naturally face greater barriers to monitoring and controlling employees who are working remotely.
> What is an "excuse" for a layoff, exactly?
It's no secret that when the return-to-office movement began, many businesses used it as a means of achieving a headcount reduction. Employees who could not (or would not) return to the office were let go. Parting ways with difficult employees looks much better to investors than layoffs.