The remote work law in the European Union is here https://eur-lex.europa.eu/legal-content/FR/TXT/?uri=LEGISSUM...
The specific article in question is:
* "If any kind of monitoring system is put in place, it needs to be proportionate to the objective and introduced in accordance with Directive 90/270 on visual display units;"
It is legal but there is a big "if" in there.