Giter Club home page Giter Club logo

box-style-codealong-v-000's Introduction

CSS Box Style Code Along

Overview

In this code along exercise we will apply some CSS box styles such as background images, gradients, drop shadows, and borders. All the files you need to follow along are provided and opening this code along on the in-browser IDE will fork and clone down a copy for you, but if you would like to continue working from your personal exceptional-realty repository:

git clone https://github.com/<your_username_here>/exceptional-realty
cd exceptional-realty

We'll work on a new branch in this code along, so go ahead and create a branch called navbar-and-background-styles.

Note: If you are using the in-browser IDE, you won't be able to open images directly from the directory tree. However, you can still reference the images in your HTML and will be able to see them if you run httpserver in your IDE terminal to temporarily host your index.html.

The gradient code that is copied and pasted in the exercise is located at the bottom of this lesson.

<iframe width="640" height="480" src="//www.youtube.com/embed/Y4El1I-hagQ?rel=0&controls=1&showinfo=1" frameborder="0" allowfullscreen></iframe>

Don't forget to commit and push up your work!

Gradient Code Snippets

/* LIGHT-FADE */

background: #efefef; /* Old browsers */
background: -moz-linear-gradient(
  top,
  #efefef 0%,
  #ffffff 24%,
  #ffffff 68%,
  #dddddd 100%
); /* FF3.6+ */
background: -webkit-gradient(
  linear,
  left top,
  left bottom,
  color-stop(0%, #efefef),
  color-stop(24%, #ffffff),
  color-stop(68%, #ffffff),
  color-stop(100%, #dddddd)
); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(
  top,
  #efefef 0%,
  #ffffff 24%,
  #ffffff 68%,
  #dddddd 100%
); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(
  top,
  #efefef 0%,
  #ffffff 24%,
  #ffffff 68%,
  #dddddd 100%
); /* Opera 11.10+ */
background: -ms-linear-gradient(
  top,
  #efefef 0%,
  #ffffff 24%,
  #ffffff 68%,
  #dddddd 100%
); /* IE10+ */
background: linear-gradient(
  to bottom,
  #efefef 0%,
  #ffffff 24%,
  #ffffff 68%,
  #dddddd 100%
); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#efefef", endColorstr="#dddddd", GradientType=0); /* IE6-9 */
/* MEDIUM-FADE */

background: rgb(229, 229, 229); /* Old browsers */
background: -moz-linear-gradient(
  top,
  rgba(229, 229, 229, 1) 0%,
  rgba(255, 255, 255, 1) 99%
); /* FF3.6+ */
background: -webkit-gradient(
  linear,
  left top,
  left bottom,
  color-stop(0%, rgba(229, 229, 229, 1)),
  color-stop(99%, rgba(255, 255, 255, 1))
); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(
  top,
  rgba(229, 229, 229, 1) 0%,
  rgba(255, 255, 255, 1) 99%
); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(
  top,
  rgba(229, 229, 229, 1) 0%,
  rgba(255, 255, 255, 1) 99%
); /* Opera 11.10+ */
background: -ms-linear-gradient(
  top,
  rgba(229, 229, 229, 1) 0%,
  rgba(255, 255, 255, 1) 99%
); /* IE10+ */
background: linear-gradient(
  to bottom,
  rgba(229, 229, 229, 1) 0%,
  rgba(255, 255, 255, 1) 99%
); /* W3C */
/* NAVBAR-HOVER */

background: rgb(0, 0, 0); /* Old browsers */
background: -moz-linear-gradient(
  top,
  rgba(0, 0, 0, 1) 0%,
  rgba(71, 71, 71, 1) 28%,
  rgba(81, 81, 81, 1) 35%,
  rgba(71, 71, 71, 1) 72%,
  rgba(43, 43, 43, 1) 87%,
  rgba(28, 28, 28, 1) 91%,
  rgba(0, 0, 0, 1) 100%
); /* FF3.6+ */
background: -webkit-gradient(
  linear,
  left top,
  left bottom,
  color-stop(0%, rgba(0, 0, 0, 1)),
  color-stop(28%, rgba(71, 71, 71, 1)),
  color-stop(35%, rgba(81, 81, 81, 1)),
  color-stop(72%, rgba(71, 71, 71, 1)),
  color-stop(87%, rgba(43, 43, 43, 1)),
  color-stop(91%, rgba(28, 28, 28, 1)),
  color-stop(100%, rgba(0, 0, 0, 1))
); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(
  top,
  rgba(0, 0, 0, 1) 0%,
  rgba(71, 71, 71, 1) 28%,
  rgba(81, 81, 81, 1) 35%,
  rgba(71, 71, 71, 1) 72%,
  rgba(43, 43, 43, 1) 87%,
  rgba(28, 28, 28, 1) 91%,
  rgba(0, 0, 0, 1) 100%
); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(
  top,
  rgba(0, 0, 0, 1) 0%,
  rgba(71, 71, 71, 1) 28%,
  rgba(81, 81, 81, 1) 35%,
  rgba(71, 71, 71, 1) 72%,
  rgba(43, 43, 43, 1) 87%,
  rgba(28, 28, 28, 1) 91%,
  rgba(0, 0, 0, 1) 100%
); /* Opera 11.10+ */
background: -ms-linear-gradient(
  top,
  rgba(0, 0, 0, 1) 0%,
  rgba(71, 71, 71, 1) 28%,
  rgba(81, 81, 81, 1) 35%,
  rgba(71, 71, 71, 1) 72%,
  rgba(43, 43, 43, 1) 87%,
  rgba(28, 28, 28, 1) 91%,
  rgba(0, 0, 0, 1) 100%
); /* IE10+ */
background: linear-gradient(
  to bottom,
  rgba(0, 0, 0, 1) 0%,
  rgba(71, 71, 71, 1) 28%,
  rgba(81, 81, 81, 1) 35%,
  rgba(71, 71, 71, 1) 72%,
  rgba(43, 43, 43, 1) 87%,
  rgba(28, 28, 28, 1) 91%,
  rgba(0, 0, 0, 1) 100%
); /* W3C */

View Overview on Learn.co and start learning to code for free.

box-style-codealong-v-000's People

Contributors

annjohn avatar fislabstest avatar fs-lms-test-bot avatar gj avatar jmburges avatar jongrover avatar maxwellbenton avatar pletcher avatar sarogers avatar sgharms avatar wsaxe avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.