Pen Settings

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. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

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

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation

     

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.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

            
              <DOCTYPE !html>
	<html language="en">

	<head>
		<meta charset="UTF-8" />
		<title>Survey Form</title>
		<!-- <link rel="stylesheet" href=""> -->
	</head>

	<body>
		<header>
			<h1 id="title">Survey Form</h1>
			<p id="description">This survey is to understand better your web development learning preferences and resources
				<p>
		</header>
		<main id="main">
			<div id="form">
				<form id="survey-form">
					<label for="name" id="name-label" class="left-side label-borders">* Name:</label>
					<input type="text" id="name" name="name" placeholder="John Doe" class="right-side user-entry-borders" required>

					<label for="email" id="email-label" class="left-side label-borders">* e-mail:</label>
					<input type="email" id="email" name="email" placeholder="john.doe@company.com" class="right-side user-entry-borders" required>

					<label for="number" id="number-label" class="left-side label-borders">* Age:</label>
					<input type="number" id="number" name="number" min="10" max="120" placeholder="enter your age in years" class="right-side user-entry-borders" required>

					<label for="dropdown" id="dropdown-label" class="left-side label-borders">Select your preferred training style:</label>
					<select id="dropdown" name="dropdown" class="right-side select">
						<option disabled value-"0" selected>Select an option</option>
						<option value="watch_me_how_to_code">Watch-me how to code</option>
						<option value="instructor_led">Instructor-led</option>
						<option value="code_camp">Code camp</option>
					</select>

					<label for="radio-buttons" id="radio-buttons-label" class="left-side label-borders">What is your preference on paying for learn:</label>
					<fieldset id="radio-buttons" class="right-side user-entry-borders fieldset-width">
						<legend>Choose one of these options:</legend>
						<input id="radio1" type="radio" name="radio-buttons" value="1">
						<label for="radio1">I prefer free resources</label><br>
						<input id="radio2" type="radio" name="radio-buttons" value="2">
						<label for="radio2">I am willing to donate</label><br>
						<input id="radio3" type="radio" name="radio-buttons" value="3">
						<label for="radio3">Pay for training is my thing</label>
					</fieldset>

					<label for="checkboxes" id="checkboxes-label" class="left-side label-borders">What training sites you use the most:</label>
					<fieldset id="checkboxes" class="right-side user-entry-borders fieldset-width">
						<legend>Select one or more options:</legend>
						<ul>
							<li>
								<input type="checkbox" id="checkbox1" name="checkboxes" value="1">
								<label for="checkbox1" id="checkbox1-label">FreeCodeCamp</label>
							</li>
							<li>
								<input type="checkbox" id="checkbox2" name="checkboxes" value="2">
								<label for="checkbox2" id="checkbox2-label">Codecademy</label>
							</li>
							<li>
								<input type="checkbox" id="checkbox3" name="checkboxes" value="3">
								<label for="checkbox3" id="checkbox3-label">Coursera</label>
							</li>
							<li>
								<input type="checkbox" id="checkbox4" name="checkboxes" value="4">
								<label for="checkbox4" id="checkbox4-label">EdX</label>
							</li>
							<li>
								<input type="checkbox" id="checkbox5" name="checkboxes" value="5">
								<label for="checkbox5" id="checkbox5-label">Lynda</label>
							</li>							
							<li>
								<input type="checkbox" id="checkbox6" name="checkboxes" value="6">
								<label for="checkbox6" id="checkbox6-label">Alison</label>
							</li>
						</ul>
					</fieldset>

					<label id="textarea-label" class="left-side label-borders">Please let us know what additional comments you might have:</label>
					<textarea id="textarea" name="textarea" rows="10" cols="30" class="right-side user-entry-borders"></textarea>

					<input type="reset" id="reset"value="Reset Form" class="right-side button reset-button">
					<input type="submit" id="submit" value="Submit" class="left-side button submit-button">
			</form>
			</div>
		</main>
		<footer>
			<p>Developed by Leo Vargas @ Magno Technologies</p>
		</footer>

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

	</html>
            
          
!
            
              :root {
	@import "https://fonts.googleapis.com/css?family=Lobster";	
	--std-width: 80%;
	--col-width: 45%;
	--fieldset-width: 79%;
	--text-email-password-number-width: 80%;
	--select-width: 86%;
	--border-rad: 15px;
	--color-base: hsl(150, 100%, 35%);
	--formatted-font-color: hsl(150, 100%, 90%);
	--button-preferred-bg-color: hsl(150, 100%, 20%);
	--button-regular-bg-color: hsl(150, 100%, 30%);
	--button-hover-bg-color: hsl(150, 100%, 40%);
	--anchor-color: hsl(150, 100%, 15%);
	--form-bg-color: white;
	--form-color: black;
	--form-border-format: 1px solid darkgray;
	--form-border-rad: 15px;
}

body {
	background-color: var(--color-base, hsl(150, 100%, 35%));
	color: var(--formatted-font-color, hsl(150, 100%, 90%));
	font-family: "Open sans", sans-serif;
}

header, body, footer {
	display: block;
	width: var(--std-width, 80%);
	margin: auto;
	/* border: 1px solid red; */
}

header, footer {
	text-align: center;
}

a {
	text-decoration: none;
	color: var(--anchor-color, hsl(150, 100%, 20%));
}

#title {
	font-size: 3em;
	letter-spacing: 1em;
}

#description {
	font-size: 2em;
}

#form {
	background-color: var(--form-bg-color, white);
	color: var(--form-color, black);
	width: var(--std-width, 80%);
	margin: auto;
	border-radius: var(--border-rad, 30px);
}

#survey-form {
	display: grid;
	padding: 20px;
  grid-template-columns: repeat(auto-fit, minmax(var(--col-width, 45%), 1fr));
	grid-template-rows: 1fr 1fr 1fr;
	grid-gap: 20px;
}

.left-side {
	align-self: center;
	justify-self: end;
	width: var(--std-width, 80%);
	text-align: right;
}

.right-side {
	align-self: center;
	justify-self: start;
	width: var(--std-width, 80%);
}

.user-entry-borders {
	border: var(--form-border-format, 5px solid darkgray);
	border-radius: var(--form-border-rad, 15px);
	padding: 10px;
	width: var(--text-email-password-number-width, 80%);
	outline: none;
}

.label-borders {
	border-bottom: var(--form-border-format, 5px solid darkgray);
	border-right: var(--form-border-format, 5px solid darkgray);
	border-radius: 0 0 var(--form-border-rad, 15px) 0;
	padding: 10px;
	width: var(--std-width, 45%);
}

.select {
	border: var(--form-border-format, 5px solid darkgray);
	background-color: white;
	border-radius: var(--form-border-rad, 15px);
	padding: 10px;
	width: var(--select-width, 86%);
	outline: none;
}

.fieldset-width {
	display: table-cell;
	width: var(--fieldset-width, 79%);
	min-width: 0;
}

li {
	list-style: none;
	margin-left: -40px;
}

input, select, textarea {
	transition: box-shadow 0.3s;
}

input:focus, select:focus, textarea:focus {
	box-shadow: 0 1px 10px #999;
}

input[type="radio"], input[type="checkbox"] {
	box-shadow: none;
}


.button {
	text-align: center;
	font-size: 1.5em;	
	border-radius: var(--border-rad, 30px);
	border: none;
	padding: 10px;
}

.button:hover {
	background-color: var(--button-hover-bg-color, hsl(150, 100%, 40%));
	cursor: pointer;
}

.submit-button {
	background-color: var(--button-preferred-bg-color, hsl(150, 100%, 20%));
	color: var(--formatted-font-color, hsl(150, 100%, 90%));
	justify-self: start;
}

.reset-button {
	background-color: var(--button-regular-bg-color, hsl(150, 100%, 30%));
	color: var(--formatted-font-color, hsl(150, 100%, 90%));
	justify-self: end;
}

@media (max-width: 865px) {
	:root {
		--std-width: 90%;
		--col-width: 100%;
		--form-border-format: 1px solid darkgray;
		--form-border-rad: 10px;
		--select-width: 90%;
	}
	
	#title {
		font-size: 1.5em;
		letter-spacing: 0;
	}

	#description {
		font-size: 1.3em;
	}

	#form {
		width: var(--std-width, 80%);
		margin: auto;
		padding: 10px 0 10px 0;
	}

	#survey-form {
		display: grid;
		padding: 0px;
		grid-template-columns: repeat(auto-fit, minmax(var(--col-width, 100%), 1fr));
		grid-template-rows: 1fr 1fr 1fr;
		grid-gap: 10px;
	}

	.left-side {
		justify-self: center;
		width: var(--std-width, 80%);
		text-align: left;
	}

	.right-side {
		justify-self: center;
		width: var(--std-width, 80%);
	}

	.label-borders {
		border: none;
		border-top: var(--form-border-format, 5px solid darkgray);
		border-left: var(--form-border-format, 5px solid darkgray);
		border-radius: var(--form-border-rad, 15px) 0 0 0;
		padding: 10px;
		width: var(--std-width, 80%);
	}

	.fieldset-width {
		display: table-cell;
		width: var(--std-width, 80%);
		min-width: 0;
	}	
	
	.select {
		width: var(--select-width, 86%);
	}

	.button {
		font-size: 5vmin;
		text-align: center;
	}
	
	.submit-button {

	}

}
            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.

Console