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>
<html>
<link href="https://fonts.googleapis.com/css2?family=PT+Sans&display=swap" rel="stylesheet">
  
<body>
  <h1 id="title">FreeCodeCamp survey form</h1>
      <p id="description">Thank you for taking the time to help us improve the platform</p>
<form id="survey-form">
<div>
  <label for="name" id="name-label">Name:</label>
</div>
  
  <div>
    <input type="text" id="name" name="name" required placeholder="Enter your Name">
  </div>
<div>
  <label for="email" id="email-label" class="labels">Email:</label>
  <div class="right">
          <input type="email" id="email" class="input" required placeholder="Enter your email here">
  </div>
          <div><label for="number" id="number-label" class="labels">Age:</label>
            <div><input type="number" id="number" name="age" min="10" max="99" placeholder="30">
            </div>
            
            </div>
          <!-- dropdown -->
          <div><label for="dropdown">Which option best describes your current role?</label>
  </div>
<div>
<select name="role" id="dropdown">
            <option value="">--Select current role--</option>
            <option value="student">Student</option>
            <option value="full-time-job">Full time job
  </option>
            <option value="full-time-learner">Full time learner</option>
            <option value="not-say">Prefer not to say</option>
            <option value="other">Other</option>
          </select>
          <!-- radio buttons -->
<div>
<label class="labels" for="radio">Would you recommend FreeCodeCamp to a friend?</label></div>
<div>
  <ul class="right" style="list-style: none;">
            <li class="radio"> <input name="radio-buttons" value="1" type="radio"><label>Defenitly</label></input> </li>
            <li class="radio"><input name="radio-buttons" value="2" type="radio"></input><label>Maybe</label></li>
            <li class="radio"> <input name="radio-buttons" value="3" type="radio"><label>Note sure</label></input> </li>
  </ul></div>
          <!-- dropdown 2 -->
<div>
  <label for="feature">What is your favorite feature of FreeCodeCamp?</label>
</div>
<div>
<select name="best-feature" id="feature"><option value="">--Select an option--</option>
 <option value="challenges">Challenges</option>
 <option value="projects">Projects</option>
 <option value="community">Community</option>
 <option value="Open-source">Open Source</option>
 <option value="other">Other</option>
 </select>
</div>
          <!--checkboxes-->
          <div>What would you like to see improved? (Check all that apply)</div>
<div> 
<ul id="improve" style="list-style: none" class="right">
    <li class="checkbox"><label><input type="checkbox" id="front" value="1">Front-end project</label></input></li>
    <li class="checkbox"><label><input type="checkbox" id="back" value="2">Back-end prject</label></input>
</li>
    <li class="checkbox"><label><input type="checkbox" id="data" value="3">Data Visualization</label></input></li>
    <li class="checkbox"><label><input type="checkbox" id="challenges" value="4">Challenges</label></input>
</li>
    <li class="checkbox"><label><input type="checkbox" id="opensource" value="5">Open Souce Community</label></input>
</li>
    <li class="checkbox"><label><input type="checkbox" id="gitter" value="6">Gitter help rooms</label></input></li>
    <li class="checkbox"><label><input type="checkbox" id="videos" value="7">videos</label></input>
</li>
    <li class="checkbox"><label><input type="checkbox" id="meetups" value="8">Meetups</label></input>
</li>
    <li class="checkbox"><label><input type="checkbox" id="wiki" value="9">Wiki</label></input>
</li>
    <li class="checkbox"><label><input type="checkbox" id="forum" value="10">Forum</label></input>
</li>
    <li class="checkbox"><label><input type="checkbox" id="courses" value="11">Additional courses</label></input>
</li>
</ul>
</div>
<div> 
<label for="comments-suggestions">Any comments or suggestions?</label>
</div>
          <textarea id="textarea" name="comments-suggestions" rows="5" cols="50" placeholder="Enter your comment here.."></textarea>
<div>
<button id="submit" type="submit">Submit</button>
</div>
</form>
</body>

</html>
              
            
!

CSS

              
                body {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100%;
  margin: 0;
  padding: 0;
  background-size: 100%;
  width: 100%;
  color: white;
  font-size: 100%;
}
@media only screen and (max-device-width: 980px) {
  body {
    font-size: 100%;
  }
}
body:before {
  content: "";
  position: fixed;
  height: 100%;
  width: 100%;
  background: url(https://images.unsplash.com/photo-1520509414578-d9cbf09933a1?ixlib=rb-1.2.1&q=85&fm=jpg&crop=entropy&cs=srgb&ixid=eyJhcHBfaWQiOjE0NTg5fQ);
  background-size: cover;
  z-index: -1; /* Keep the background behind the content */
  -webkit-filter: blur(5px);
  -webkit-background-size: cover; /* pour Chrome et Safari */
  -moz-background-size: cover; /* pour Firefox */
  -o-background-size: cover; /* pour Opera */
  background-size: cover; /* version standardisée */
}
#title {
  text-align: center;
  font-family: "PT Sans", sans-serif;
  color: white;
}
#description {
  text-align: center;
  font-size: 14px;
  font-family: "PT Sans", sans-serif;
  color: white;
}

#survey-form {
  position: absolute;
  width: 100%;
  display: inline flex;
  max-width: 100%;
  min-width: 10%;
  border-style: solid;
  border-color: #495867;
  border-width: 2px;
  border-radius: 2px;
  background-color: #495867;
  opacity: 0.85;
  padding: 2%;
  font-family: "PT Sans", sans-serif;
  font-size: medium;
  color: white;
  margin: 10px 50px 20px 0;
  vertical-align: middle;
  /*

  width: 75%;
  max-width: 100%;
  min-width: 10%;
  border-style: solid;
  border-color: #495867;
  border-width: 2px;
  border-radius: 2px;
  background-color: #495867;
  opacity: 0.85;
  text-align: center;
  margin-left: 150px;
}
  */

 
.right {
  display: inline-block;
  text-align: left;
  width: 100%;
  vertical-align: top;
}
#name {
  text-align: center;
  border-style: solid;
  border-radius: 2px;
}
#email {
  text-align: center;
  border-style: solid;
  border-radius: 2px;
}
#number {
  text-align: center;
  border-style: solid;
  border-radius: 2px;
}
select {
  display: inline-block;
  height: 45px;
  width: 85%;
  padding: 10px;
  margin: 10px;  
  border: .5px solid black;
  border-radius: 5px;
}
#submit {
  position: auto;
  background-color: #05668d;
  color: white;
  border-radius: 4px;
  height: 40px;
  width: 90px;
  border: 0px;
  margin: 10px;
}
div{
  font-family: "PT Sans", sans-serif;
  font-size: medium;
  color: white;
  text-align: justify;
  margin: 10px 50px 20px 0;
}
#textarea{
  position: auto;
  width: 50%;
  max-width: 100%;
  min-width: 10%;
}
              
            
!

JS

              
                
              
            
!
999px

Console