Animation on Navigation Bar
Hi guys, I am trying to create an animation similar to the one Kevin Powell made (refer to the attached picture). However, the issue is that I am unable to replicate it exactly because it's in my navigation bar and not a simple rectangle. Additionally, I would like to implement a diagonal animation, as shown in the attached paint picture. Could you please assist me with this?
8 Replies
You would need to spell the issues out one by one.
Then, break them down so we can tackle them on their own merit.
So, if I'm correct, you have ONLY 2 major issues:
1. Replicating the border and glow effect on your nav
2. Making a diagonal border also on your nav
Is that right?
Yes thats my issues
Alright.
1. The effect is basically a div with a nested div, arranged in such a way that the nested div is just a little smaller than the parent div and it is centered within the parent div. The background of the parent div is a gradient. While the background of the child div is a solid color.
And with that, your border is set.
For the glow, you can just play with
box-shadow
and you can generate it to any extent.
Of course, remember to set the background of the main wrapper (body or div)
2. I think a clearer demo of what exactly you want to achieve would be needed.
In order to know what to utilize and how to approach it.How would i be able to make a diagonal div connected with the other div so it follow the same line ?
From what I understand you are trying to do, you will need to play a lot with absolute positioning.
Where you have another div rotated and conjoined in some way to the original one.
I can only be very specific if I see the code to start with.
Thanks i’ll try this but it looks very complicated for my level. I’ll give it a try