clip-path not displaying cssbattle safari imac
Im having trouble understanding how clip-path works. I'm going through the cssbattle and clip-path works sometimes, but mostly doesnt display properly. In this battle, i started with a square container and used clip-path to cut out the object. but i cant get the clip-path to display. I tried the same code in chrome and firefox but yeilded the smae results.
6 Replies
Both <a> and <b> are unclosed, and <b> does not have a height. Also, it is technically legal to have custom tags, but not all emulated environments support them. I don't know if CSS Battle supports them, but it did not work when I tried in codepen. I had to change that into a div with class of b to make it work.
Yeah, cssBattle has lax rules becuase its a game of golf where as the least amount of characters used wins the battle. So they allow <a>'s and dont need to be closed. but I did change them to divs and added height and top:0 and it worked. So i suppose its a cssbattle thats throwing me off.
The height is required. Without it, there is nothing to clip. The exception to this is if there is content, but there isn't any.
CSSBattle
The funnest CSS game for web designers & developers
a different approach, just to let you see what kind of things are possible (maybe useful in future battles)
(i can not check it because i don't have pro subscription, but it should be good/close. maybe adjust the angles if nessesarry)
there probably (most definetly) are shorter solutions, this was what came to mind first