Braking used to be pressing the pedal and clearly ( I'm presuming I don't need to source the construction and use regs for that, but it's Schedule 1, Road vehicles lighting regs 1989)
brake lights needed to light to show you were braking.
Conveniently hand signals existed for those old cars during the crossover and didn't have lights of that nature.
Now we have the car braking, either with actual brakes or the electric motor you can get there's laws to cover that.
"Regulation No 13-H of the Economic Commission for Europe of the United Nations (UN/ECE) — Uniform provisions concerning the approval of passenger cars with regard to braking [2015/2364]", a brake signal is required beyond 1.3m/s².
And there it is to cover our electric friends.
Ofcourse there's due care if it's bad and failing to maintain your vehicle if your brake lights don't come on as designed and numerous other construction and use issues if your vehicle doesn't work as built.
Legally you are supposed to indicate you are slowing down, brake lights (and I do wonder why anyone would challenge such a thing), for the traditional system and a minimum retardation for the rest of the system (the electric part) because I would suggest you may have a minimal retardation at times with regen.