A lot of times, the projects tell you what to do but not why. I have researched and found answers to some of my questions, but I still have a few questions about clip and clip-path.
First, the syntax clip: rect(1px, 1px, 1px, 1px); seems to be the general convention for completely hiding an element based on the little that I’ve seen. Is there a reason not to instead use clip: rect(0, 0, 0, 0)? Wouldn’t that be the correct way to completely hide an object?
Second, what is “-webkit-clip-path”? Everywhere I’ve looked for information on clip-path, the webkit property is not mentioned.
I am not sure which lesson is that in html css. I just also explained why the lessons are not giving answers. New policy is still followed, they are forcing us to learn what companys expect. we are expected if hired to do exactly what you have been doing. Even after you do this for a living this will be common just like here self taught. So that is why videos were removed from new classes.
Not that I know of, but you would need to provide us with more context on where
clip: rect(1px, 1px, 1px, 1px) is being used. I can tell you that the standard for visually hiding text on the page is to use
clip: rect(0 0 0 0). But even that is being phased out with
clip-path: inset(50%). The
clip property is just being kept around for IE.
This is a common convention by browser makers to introduce a new property that is not standard yet. So in the very early days, before all browsers supported
clip-path you could use
webkit-clip-path to experiment with the property in any webkit browsers. You don’t need this now because all browsers have supported
clip-path for quite some time.
Thanks. That answers at least some of it…I did understand about clip vs clip-path, but your explanation helps with why
webkit was hard to find. My question stems from Step 31 of “Learn More About CSS Pseudo Selectors By Building A Balance Sheet”. As to the standard that I referenced seeming to be using “1px”, when I searched for info about the clip property, that is what I saw a few times. With it also being listed here, I assumed that was the convention.
My reply to bbsmooth above references which lesson. I probably should have included it in the original post. As to being self-taught, that makes sense. It would have been nice for that to be mentioned, but maybe it was somewhere, and I missed it. This is my first freeCodeCamp certification, so I didn’t even know some of the topics had videos