Tribute Page. Feedback is welcome. Thanks!

Tribute Page. Feedback is welcome. Thanks!
0.0 0

#1

Hey! :grinning::

I just finish the tribute page. Is about a great man Jose de San Martin.

Tribute page Jose de San Martin at codepen.io

All feedback is welcome :wink:. Thanks.


#2

This is a very impressive tribute page - Well done!

How did you animate the nav-bar scroll?


#3

m-bettertOn: Thanks for the feedback.

To animate the nav-bar I used jquery .outerHeight() && .scrollTop() && .offset().

The script works like this:
The Height of the class nav(navigation bar) gets saved in the variable NavigationHeight ( outerHeight() + 15px).
When a click is made on elements with class .smooth-scrolling. The default action gets blocked, saves the link information on the variable linkFromHref.
Then with scrollTop and offset the script calculates the animation from the top of the body to the linkFromHref - navigationHeight.

In the penview(editor View) you can take a look at the script. I hope the description was useful. Thanks again.


#4

I’ll take a look, thanks