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

              
                <div class="container">
<h1 id="title">San Diego Book Club Survey Form</h1>

<p id="description">The world belongs to those who read.</p>

<form id="survey-form">
  
  <label id="name-label">Name</label>
  <input id="name"
         required type="name-label"
         placeholder="Full Name">
  
  <label id="email-label">Email</label>
  <input id="email" 
         required type="email"
         placeholder="Your Email">
  
  <label id="number-label">Number</label>
  <input id="number" 
         required type="number" 
         min="0" 
         max="100" 
         placeholder="Your Number">

  <label for="books">Choose a Book:</label>
  
  <select name="books"
          id="dropdown">
    <option value="The Soulmate Equation">The Soulmate Equation</option>
    <option value="The Great Gatsby">The Great Gatsby</option>
    <option value="People We Meet on Vacation">People We Meet On Vacation</option>
    <option value="The Love Hypothesis">The Love Hypothesis</option>
  </select>
    
    <label for="radio">Choose a Day:</label>
  
  <label><input id="Monday"
                type="radio"
                name="Monday-Friday"
                class="input-radio"
                value="Monday">
    Monday
    </input>
  </label>
  
   <label><input id="Wednesday"
                type="radio"
                name="Monday-Friday"
                class="input-radio"
                value="Wednesday">
    Wednesday
    </input>
  </label>
  
  <label><input id="Friday"
                type="radio"
                name="Monday-Friday"
                class="input-radio"
                value="Friday">Friday</input>
  </label>
        
        <label for="times">
          Choose a Time:</label>
  
        <label for="Times">
          <input id="3pm" 
                 type="checkbox"
                 class="input-checkbox"
                 value="time">3:00pm-4:00pm</input>
  </label>
  
        <label for="Times">
          <input id="12pm"
                 class="input-checkbox"
                 type="checkbox"
                 value="time">12:00pm-1:00pm</input>
  </label>
        
    <label for="additional">Additional Info</label>
    <textarea id="additional"
              name="additional"
              rows="4"
              cols="50">Share with us any additional info for the book club!
    </textarea>
  
    <button id="submit" type="submit">Submit</button>
    </form>
  </div>
              
            
!

CSS

              
                .container {
  margin: auto;
  max-width: 980px;
}

h1 {
  text-align: center;
  font-family: copperplate;
  font-size: 45px;
  color: white;
}
p {
  text-align: center;
  font-size: 25px;
  font-family: courier new;
  color: white;
}

form {
  background: #915F6D;
}

label {
  display: flex;
  align-items: center;
  font-size: 30px;
  margin-bottom: 6rem;
  font-family: copperplate;
  margin: 8px 390px;
  color: #000035;
  white-space: nowrap;
}

input[type=text], select {
  width: 80%;
  padding: 12px 20px;
  margin: 8px 90px;
  display: inline-block;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-sizing: border-box;
  font-family: courier new;
}

input [type=text], input {
  width: 80%;
  padding: 12px 20px;
  margin: 8px 90px;
  display: inline-block;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-sizing: border-box;
  font-family: courier new;
}

input [type=radio] {
  width: 80%;
  padding: 12px 20px;
  margin: 8px 90px;
  display: inline-block;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-sizing: border-box;
  font-family: courier new;
  
}

textarea, input {
  width: 80%;
  padding: 12px 20px;
  margin: 8px 90px;
  display: inline-block;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-sizing: border-box;
  font-family: courier new;
}

button {
  width: 80%;
  padding: 12px 20px;
  margin: 8px 90px;
  display: inline-block;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-sizing: border-box;
  font-family: courier new;
  font-size: 30px;
}

div {
  background-image: url(https://www.pexels.com/photo/brown-wooden-shelf-with-books-3646172/);
}

body {
  background-image: url(https://hips.hearstapps.com/hmg-prod.s3.amazonaws.com/images/how-to-host-a-virtual-book-club2-1585775401.jpg);
}

textarea {
  font-family: courier new;
}

.input-radio,
.input-checkbox {
  display: inline-block;
  margin-right: 0.625rem;
  min-height: 1.25rem;
  min-width: 1.25rem;
}













              
            
!

JS

              
                // !! IMPORTANT README:

// You may add additional external JS and CSS as needed to complete the project, however the current external resource MUST remain in place for the tests to work. BABEL must also be left in place. 

/***********
INSTRUCTIONS:
  - Select the project you would 
    like to complete from the dropdown 
    menu.
  - Click the "RUN TESTS" button to
    run the tests against the blank 
    pen.
  - Click the "TESTS" button to see 
    the individual test cases. 
    (should all be failing at first)
  - Start coding! As you fulfill each
    test case, you will see them go   
    from red to green.
  - As you start to build out your 
    project, when tests are failing, 
    you should get helpful errors 
    along the way!
    ************/

// PLEASE NOTE: Adding global style rules using the * selector, or by adding rules to body {..} or html {..}, or to all elements within body or html, i.e. h1 {..}, has the potential to pollute the test suite's CSS. Try adding: * { color: red }, for a quick example!

// Once you have read the above messages, you can delete all comments. 

              
            
!
999px

Console