diff options
author | Oscar Najera <hi@oscarnajera.com> | 2025-02-09 22:04:25 +0100 |
---|---|---|
committer | Oscar Najera <hi@oscarnajera.com> | 2025-02-09 22:04:25 +0100 |
commit | d8711c197de79cb74e2de2c18bb23baeef3387fb (patch) | |
tree | 16aa92decda35c4692233758d06c289b0ea1a0a8 /AoC2022/13/input | |
parent | 5b0e2eb19bb432e4e170d9bdb1cb8169d526801f (diff) | |
download | scratch-d8711c197de79cb74e2de2c18bb23baeef3387fb.tar.gz scratch-d8711c197de79cb74e2de2c18bb23baeef3387fb.tar.bz2 scratch-d8711c197de79cb74e2de2c18bb23baeef3387fb.zip |
[FIX] current targe when link wraps other elements
Many times the A tag wraps many things. It happened that those contained
element where the target and so the link would be undefined as they
don't have href. The correct links resides on event.currentTarget.href.
A second bug happens, on links to externals which I set to open in new
window. Somehow, on the return of register-visit, the event has no
currentTarget and so, it is the correct way to use event.target.target
to figure out if I wanted to open a new window.
Diffstat (limited to 'AoC2022/13/input')
0 files changed, 0 insertions, 0 deletions