Login problem in 20.04 : can't type anything in the login box

Making explicit the solution that was proposed here. I was able to solve the issue by running the following commands:

sudo apt purge light-locker
sudo apt install --reinstall xfce4-screensaver

It seems that I have found a solution (even though I am not sure about the intrinsic mechanisms involved). Following a suggestion here I've typed the following in the terminal (ctrl+alt+t for terminal or ctrl+alt+F1 for a text console):

 sudo nano /etc/systemd/logind.conf

Then I uncommented the lines:

 HandleSuspendKey=suspend
 ...
 HandleLidSwitch=suspend

Then I saved the file and quit nano. Then I entered

 systemctl restart systemd-logind.service

Now the laptop, for some reason, does not respond to the lid closed but wakes up perfectly well after using GUI suspend (tried for three times).