tholman / github-corners

A fresher "Fork me on GitHub" callout.
http://tholman.com/github-corners
MIT License
4.93k stars 195 forks source link

Not on top of everything #28

Closed FelixINX closed 8 years ago

FelixINX commented 8 years ago

Hi,

I think that the "ribbon should be on top of everything, but it's looks like its not.

Here is my code :

<div class="github-corner"><a href="https://github.com" title="Fork me on GitHub"><svg viewbox="0 0 100 100" fill="currentColor"><title>Fork me on GitHub</title><path d="M0 0v100h100V0H0zm60 70.2h.2c1 2.7.3 4.7 0 5.2 1.4 1.4 2 3 2 5.2 0 7.4-4.4 9-8.7 9.5.7.7 1.3 2 1.3 3.7V99c0 .5 1.4 1 1.4 1H44s1.2-.5 1.2-1v-3.8c-3.5 1.4-5.2-.8-5.2-.8-1.5-2-3-2-3-2-2-.5-.2-1-.2-1 2-.7 3.5.8 3.5.8 2 1.7 4 1 5 .3.2-1.2.7-2 1.2-2.4-4.3-.4-8.8-2-8.8-9.4 0-2 .7-4 2-5.2-.2-.5-1-2.5.2-5 0 0 1.5-.6 5.2 1.8 1.5-.4 3.2-.6 4.8-.6 1.6 0 3.3.2 4.8.7 2.8-2 4.4-2 5-2z"></path></svg></a></div><style> .github-corner{position:absolute;right:0;top:0;width:120px;height:120px;overflow:hidden;}.github-corner a{position:absolute;right:0;top:0;left:0;bottom:0;transform:translate(50%, -50%) rotate(45deg);color:#fd6c6c;}</style>

And the website is here : http://ppo.felixinx.me/

Thanks

tholman commented 8 years ago

This is more a case of where you put it (since its an absolute element, if its contained in something relative, its position will be different)

And what the z-indexing is like on your page. It'd be silly for the code it gives you to make any assumptions... if you want it on top of things, you'll need to add the z-index: x appropriate for your site :)

FelixINX commented 8 years ago

The problem was with the Bootstrap Navbar, that was on top of everything, sticked at top. Thanks anyway!

Félix Desjardins

2016-04-09 15:17 GMT-04:00 Tim Holman notifications@github.com:

Closed #28 https://github.com/tholman/github-corners/issues/28.

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/tholman/github-corners/issues/28#event-621200617

patarapolw commented 5 years ago

It seems that .github-corner { z-index: 100; } doesn't work. I have to,

.github-corner > svg {
    z-index: 100;
}

Should be mentioned in README, as simple setting the CSS isn't clear.