The bug
When the player is hit by an enemy that deals negative damage, the golden heart bug (MCPE-56836) appears. Whether negative damage is the source of MCPE-56836 is unknown, but it's a 100% reliable way of experiencing an identical effect.
How to reproduce
Download the attached world
Get attacked by the zombie repeatedly (behavior pack changes zombie attack damage to -1)
→ ❌ Your health gets buggy, absorption hearts appear from nowhere on the bottom row, etc
Expected result
Negative damage is treated the same as 0 damage
This is consistent with the explanation I suggested for MCPE-56836 in my comments there.