top | item 36981305

(no title)

PathfinderBot | 2 years ago

In addition to your sibling comments, here's how they're achieving the effect:

1. JS loads from https://cdn.asahilinux.org/.h which contains a list of "blocked browser history entries". It's likely that this code will be used again for future HN posts. Interestingly, this is very generic and this code can be used by anyone to put up customised block lists based on browser history. This can be circumvented by using private browsing, disabling `mix-blend-mode` on `:visited` links, or `:visited` partitioning.

This JS code is used to automatically generate the main anchor element seen in the sibling comment.

2. According to MDN [1]:

> In addition, even for the above styles, you won't be able to change the transparency between unvisited and visited links, as you otherwise would be able to using the alpha parameter to rgb() or hsl(), or the transparent keyword.

So :visited links are not supposed to affect transparency. How did they do it, then? Using `mix-blend-mode`. The background uses `multiply` (also an anchor) is #FFF for normal visitors (transparent) while #000 for blocked visitors (opaque black). The text uses `lighten`, #000 (thus transparent) for normal visitors, while #fff (thus white text) for blocked visitors.

[1] https://developer.mozilla.org/en-US/docs/Web/CSS/Privacy_and...

discuss

order

No comments yet.