mirror of
https://github.com/HKUDS/DeepTutor.git
synced 2026-12-04 22:29:25 +08:00
_remove_element used parent.remove(el), which in lxml also drops el.tail,
so text after a stripped button, icon or aria-hidden span was lost
("The answer is <span aria-hidden>*</span>42." became "The answer is").
Move the tail onto the previous sibling or the parent before removing.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>