Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>

<nav id="navbar">
  <ul>
    <li><a href="#welcome-section">Home</a></li>
    <li><a href="#projects">Projects</a></li>
    <li><a href="#contact">Contact</a></li>
</nav>
<section id="welcome-section">
  <h1>Welcome to the personal portfolio page of danh4648
    <h1>
</section>
<section id="projects">
  <h2> Some of my projects</h2>
  <div class="project-grid">
    <div class="project-tile">
    <a href="https://codepen.io/danh4648/pen/YozMPQ" target="_blank"><img src="https://raw.githubusercontent.com/danh4648/images/master/techdoc.png"><h2>Technical Documentation</h2></a>
    </div>
    <div class="project-tile">
    <a href="https://codepen.io/danh4648/pen/joLxBb" target="_blank"><img src="https://raw.githubusercontent.com/danh4648/images/master/landing.png"><h2>Landing Page</h2></a>
    </div>
    <div class="project-tile">
    <a href="https://danh4648.github.io/google-homepage" target="_blank"><img src="https://raw.githubusercontent.com/danh4648/images/master/google.png" target="_blank"><h2>Google Clone</h2></a>
    </div>
  </div>
</section>
<section id="contact">
  <a href="https://codepen.io/danh4648" target="_blank"><img src="https://blog.codepen.io/wp-content/uploads/2012/06/codepen-wordmark-display-inside-white@10x.png" height="20" alt="codepen logo"></a>
  <a href="https://github.com/danh4648" target="_blank"><img src="https://raw.githubusercontent.com/danh4648/images/master/GitHub_Logo_White.png" height="30" alt="github logo"></a>
  <a id="profile-link" href="https://www.freecodecamp.org/danh4648" target="_blank"><img src="https://raw.githubusercontent.com/danh4648/images/master/freeCodeCamp.png" height="20" alt="fcc logo"></a>
  <a href="https://3chelseastreetllc.blogspot.com" target="_blank">3chelseastreetllc.blogspot.com</a>
</section>
<footer>Page created by danh4648</footer>
              
            
!

CSS

              
                * {
  padding: 0px;
  margin: 0px;
}

#navbar {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  height: 50px;
  display: flex;
  align-items: center;
  flex-direction: row;
  z-index: 5;
}

nav * {
  display: inline-block;
}

nav ul {
  margin-left: auto;
}

nav li {
  margin: 20px;
}

nav li a {
  text-decoration: none;
  color: black;
  font-size: 20px;
  font-family: monospace;
}

nav li a:hover {
  color: #333333;
}

#welcome-section {
  height: 55vh;
  padding-top: 45vh;
  background-color: #baa480;
  color: #363636;
  font-family: monospace;
  font-size: 16px;
  text-align: center;
}

#projects {
  height: 100%;
  background-color: #eaaf77; 
}

#projects > h2 {
  font-family: monospace;
  font-size: 24px;
  color: #363636;
  text-align: center;
  padding-top: 40px;
}

.project-grid {
  display: flex;
  justify-content: space-evenly;
  flex-wrap: wrap;
  align-items: center;
  padding: 60px 0px 110px 0px;
}

.project-tile {
  justify-self: center;
  align-self: center;
  font-size: 14px;
  text-align: center;
  border: 1px solid gray;
  padding: 10px;
  border-radius: 20px;
  background-color: white;
  margin: 20px;
}

@media screen and(max-width: 600px) {
  .project-tile {
    font-size: 12px;
  }
}

.project-tile:hover {
  opacity: 0.95;
  border: 1px solid black;
}

.project-tile img {
  width: 100%;
  max-width: 600px;
  height: 20em;
  border-bottom: 1px solid gray;
  object-fit: cover;
}

.project-tile a {
  text-decoration: none;
  color: black;
  font-family: monospace;
}

#contact {
  background-color: #a0a0a0;
  padding: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  flex-wrap: wrap;
}

#contact a {
  text-decoration: none;
  color: white;
  font-size: 18px;
  font-family: monospace;
  padding: 0 40px;
}

#contact a:hover {
  opacity: 0.8;
}

footer {
  background-color: #363636;
  height: 6vh;
  color: grey;
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
}

              
            
!

JS

              
                
              
            
!
999px

Console