Useful research for someone using the custom components to make leaves. These notes are so shitty, sorry in advance. Things are a bit more complicated than the wiki lets on.
The way leaves work is they have a persistent bit and an update bit.
Naturally placed leaves have persistent set to false. Player placed leaves have that set to true.
Only non-persistent leaves consider the update bit. The update bit is set to false by default via world-gen. When a leaf is broken, all leaves in the 3 by 3 by 3 centered on where that leaf was have their update bit set to true. When a log is broken, all leaves in the 9 by 9 by 9 centered on where that log was have their update bit set to true.
Once update bit is true, the leaves will be randomly ticked. When randomly ticked, if there isn't a log (seemingly, of any type, even a mismatched type) within 4 blocks taxicab distance, the leaf will turn to air and drop its loot.
Need to see what type of leaves and logs the update bit going from false to true is affected by. I know those 2 are at least affected by command block removals, not just
onPlayerDestroyed. Update: it's any kind of leaves or any kind of logs.