Changes the default styling of UL
and OL
lists
list-style-type
- changes the icon/value used in the listlist-style-position
- changes the position of the list. Accepts inside and outsidelist-style-img
- changes bullets to image. Accepts none or a valid URLlist-style: type position img
See the Pen UA - ITR-list styles by Jon (@Middaugh) on CodePen.
A pseudo-class is used to define a special state of an element
w3schools info
/* unvisited link */
a:link {
color: green;
}
/* visited link */
a:visited {
color: red;
}
Unvisited link: w3schools.com
Visited link: w3schools.com
Common button pseudo-classes:
CSS3 is the largest batch of changes to CSS.
Vendor prefixes are considered 'experimental' properties and should be used with caution.
div{
/* Safari 3-4, iOS 1-3.2, Android 1.6- */
-webkit-border-radius: 12px;
/* Firefox 1-3.6 */
-moz-border-radius: 12px;
/* Opera 10.5, IE 9, Safari 5, Chrome, Firefox 4, iOS 4, Android 2.1+ */
border-radius: 12px;
}
Rounded Corners will probably the most commonly used CSS3 property.
.round {
border-radius: 5px 10px 15px 20px; /* top left, top right, bottom right, bottom left */
}
.round {
border-radius: 50%; /*Creates a circle if length equals height*/
}
See the Pen UA-ITR-Rounded Corners by Jon (@Middaugh) on CodePen.
CSS3 opened up more possibilities for colors and opacity in our CSS
Red, Green, Blue, and Alpha
p{
background-color:rgba(255, 0, 0, 0.5); /*Red with 50% opacity*/
}
a{
color:rgba(255, 0, 0, 0.5); /*Text will be red with 50% opacity */
}
You can change the full element opacity by using the opacity
property.
p{
/*Red with 50% opacity*/
background-color:#ff0000;
opacity:0.5;
}
CSS gradients allow you to display a transition from one color to another. Gradients are one of the most vendor prefix heavy CSS properties we will use.
.button{
/* Permalink - use to edit and share this gradient: http://colorzilla.com/gradient-editor/#1e5799+0,7db9e8+100 */
background: #1e5799; /* Old browsers */
background: -moz-linear-gradient(top, #1e5799 0%, #7db9e8 100%); /* FF3.6-15 */
background: -webkit-linear-gradient(top, #1e5799 0%,#7db9e8 100%); /* Chrome10-25,Safari5.1-6 */
background: linear-gradient(to bottom, #1e5799 0%,#7db9e8 100%); /* W3C, IE10+, FF16+, Chrome26+, Opera12+, Safari7+ */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#1e5799', endColorstr='#7db9e8',GradientType=0 ); /* IE6-9 */
}
See the Pen UA-ITR-Gradients by Jon (@Middaugh) on CodePen.
Descendant selectors create a more specific groups of styled content.
div p{
color:#ff0000;
}
Any paragraph inside of a div will have red text.
See the Pen UA-ITR-Descendant Selectors by Jon (@Middaugh) on CodePen.
See the Pen UA-ITR-Descendant by Jon (@Middaugh) on CodePen.
Start thinking about a primary color you like and want to use in your future websites.
You can use a tool like this to generate a color scheme. Color Calculator
The Super Basics
Use tab to auto complete commands and paths. It will save you a lot of time.
ls or dir
MAC
$ ls
front-end-development-course-info/docs
Windows
$ dir
front-end-development-course-info\docs
cd
#list directory
$ ls
front-end-development-course-info/docs
#change directory into docs
$ cd docs/
$ ls
index.html
sessions
....
cd
#list directory
$ dir
front-end-development-course-info/docs
#change directory into docs
$ cd docs/
$ dir
index.html
sessions
....
..
- Parent Directory/
- RootGot lost in your console? Use the print working directory command to get a full path of your current location
pwd
$ pwd
c/users/jisajmb
Got lost in your console? Use the print working directory command to get a full path of your current location
cd
$ cd
c/users/jisajmb
You can create a new folder by using the make directory command. Same for Mac and Windows.
#list directory
$ cd
front-end-development-course-info\docs
$ mkdir my-work
$ cd
front-end-development-course-info\docs\my-work
touch
#list directory
$ ls
front-end-development-course-info/docs
$ touch index.html
$ ls
index.html
echo > index.html
#list directory
$ dir
front-end-development-course-info\docs
$ echo > index.html
$ dir
index.html
You can clear the console by simply typing clear
(Mac) or cls
(Windows) and hitting enter.
...not something you need to know for assessment 1
...but it is something you need to know as a member of the IT community