Sticky navigation starting at special point

hypeDocument.setElementProperties is only a wrapper to the Hype API function hypeDocument.setElementProperty meaning it only supports the attributes listed in the help of that native function.

You can always change the display with = "fixed" with element being a reference to the element you want to change.

Thanks. It would be really great if it can be changed by a Javascript with class name, by this way, the element or a group of elements can be set as the following dynamically:

Do you think it is possible please?


Classes can set the display property but they can’t „see“ the scroll offset. So until now no real way todo it with only CSS.

css sticky toggles ‘scroll’ and ‘fix’ …
… but won’t wait for an animation to be finished

disable scroll on the body may be an option …

1 Like

Thanks @MaxZieb and @h_classen,

I realize it is not easy :grinning:
Have you checked this before please?


I just suppose this Javascript is by IntersectionObserver, is it possible to do by IntersectionObserver if CSS is not the right way please?

Also, I found this resource, and it really look like what I expect:

Really expect your professional comments, thanks in advance.

How to do this multiple Layouts? can we use class instead of element ID?