I'm also experiencing charging issues with 18.1 - with 17.1 no problems.
I'm using a USB Battery Charging device (basically 5V PSU with shorted data lines:
https://en.wikipedia.org/wiki/USB_hardware#USB_Battery_Charging ).
The first time I read about the charging issue, I tried charging: pluggin cable in, out, in ... averything worked.
Then I really needed to charge it and it displayed: chager connected but no charging. After a restart, charging worked. Now, I tried to charge again and same problem: ohne detects charger but doesn't charge the battery.
I measured the current and it seems that the phone uses the charger to power itself (and not draining the battery) but does not charge the battery. This also complies with my experience: during a map update of OSMand, the battery level didn't fall despite a long time loading data via WiFi.
Phone model: H4113
Baseband: 20191108_BY12O_Daily
LineageOS: 18.1-20210402-NIGHTLY-pioneer
No root, no magisk, no Goole Apps/Services - just plain LineageOS as far as I can tell.
Updated form 17.1 without factory reset.