Introduction
Lors ♥️
@miss_lorsx
I...
For further actions, you may consider blocking this person and/or reporting abuse
I often use these types of selectors, with this I can style all the divs which has a class starting width "grid-".
Nice! I like that - code looks tidy! I guess there are different ways once you become confident enough. Trial and error as they say. 😅
More like practice and experience 🙏 I think I learned this one from bootstrap 3.
Great stuff! Well done!
I often forget about the * selector. Thanks for sharing.
Love your images!!!
Not sure that this fits in basics (just adding to the discussion), but similar to the grouping selector are this (no idea what its called). Here is an example that selects all paragraphs with a class of circle.
Yes it does - I just wanted to share the literal basics of selectors, I’m hoping to go in to more advanced selectors etc soon, but honestly this selectors thing is crippling me every time. 😅
They get complicated and hard to wrap your head around after the basics
Exactly - so with that one il have to take my sweet little time! 😅🙌🏻
Nice article Laura!
A couple of tiny errors would be great to fix to make sure we're not confusing any learners. The divs should have closing '>' after the first line in the first screenshots and the semicolon should go after the rules not the selector closing brace '}' in the one with .circle & #rectangle.
# is also called a hash sign or a pound sign, a hashtag specifically refers to a tagging system using that symbol as a prefix.
I’ve changed them I think - if you want to just have a glance over - apologies! 😅
The CSS one looks great! Sorry, I don't think I worded the first one very well. The two with the divs should look like
<div id="rectangle"></div>
. It was just the one on the very end that was missing originally. :)Do you know I did think that! Il be spending all night changing this. 😂
I’ve changed, I did think originally ‘hold on the div tag stays open when adding the class or Id then I closed it, without adding the >tag after the Id/class doh! Done now! Hopefully!
Perfect. Easy mistake! 😄
Honestly, il get it right myself one day. Thank you so much though for pointing it out! Much appreciated! 😃
Great! Thanks for that. I will fix that!
I've been doing web development for years and I still have a post-it note taped to my monitor that says ID = # CLASS = .
When floats were cool I had 2 sticky notes on my display, on the left side "float:left;" on the right side "float:right;", It is not about that I dont know which side is which... but in the afternoons it was lifesaver
So...floats aren't cool any longer? :-) I have so much to learn!
Nah everybody just flexin with their grids ;)
The idea is also important if you use jQuery / querySelector(All) also.
But is good idea do thinks a like
@media only screen and (max-width: 600px) {
@import url("six.css");
}
@media only screen and (min-width: 700px) {
@import url("other.css");
}
I’m just highlighting the basic CSS selectors, I aim to go more in depth with @media /targeting paragraph classes etc in another article, it was mainly just targeting ID & Classes & a few others for now. 😊
This page has an overview and some useful examples: devopedia.org/css-selectors