As Andrew mentioned, the charge controller inside the phone disconnects the power coming from the charger when battery is fully charged (this information is coming from the battery microcontroller).
Coming from my personal experience with old phones and smartphones:
I have kept some old Nokia phones and Samsung smartphones connected day and night to their chargers for weeks.
All this time they were on, equipped with SIM and connected to the mobile network or WIFI.
I didn't notice any major changes on battery lifespan for months or even years.
As long as the charge controller is doing its job, I will not worry about.
I will be suspicious if I notice the phone heating during charging as long as the WIFI, MOBILE DATA or LOCATION are disabled or the device is in IDLE and/or FAST CHARGING is deactivated on the phone.
I'm no expert in Li-Ion battery, just sharing my long time experience using them.
perfectly true "thumb up "