Hacker News Contextual Comments (sticky tree)

Sticks the first line of all comments in the visible comment tree to the top of the screen so you always know where exactly you are. See the screenshots for a better understanding. Also adds the ability to expand/collapse a comment by clicking anywhere on it.

< Σχολιασμός για τον κώδικα Hacker News Contextual Comments (sticky tree)

Αναφορά: Καλός - ο κώδικας λειτουργεί

§
Δημοσιεύτηκε: 18/12/2021

Yes!
Very good idea, Work very well.
Maybe, for a better visibility, you can add a special background to the sticky element?

phil294Δημιουργός
§
Δημοσιεύτηκε: 20/12/2021
Επεξεργάστηκε: 20/12/2021

good idea, but not so easily done. The comments are only css position:sticky'd. This would need some more JS (https://stackoverflow.com/q/25308823)

§
Δημοσιεύτηκε: 20/12/2021

Yes, i try a CSS solution:
not possible.

But the Stackoverflow idea should work:
"It sets the attribute stuck which you can match in CSS with header[stuck]"

Δημοσίευση απάντησης

Συνδεθείτε για να δημοσιεύσετε μια απάντηση.