HTML preprocessors can make writing HTML more powerful or convenient. For instance, Markdown is designed to be easier to write and read for text documents and you could write a loop in Pug.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. So you don't have access to higher-up elements like the <html>
tag. If you want to add classes there that can affect the whole document, this is the place to do it.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. If you need things in the <head>
of the document, put that code here.
The resource you are linking to is using the 'http' protocol, which may not work when the browser is using https.
CSS preprocessors help make authoring CSS easier. All of them offer things like variables and mixins to provide convenient abstractions.
It's a common practice to apply CSS to a page that styles elements such that they are consistent across all browsers. We offer two of the most popular choices: normalize.css and a reset. Or, choose Neither and nothing will be applied.
To get the best cross-browser support, it is a common practice to apply vendor prefixes to CSS properties and values that require them to work. For instance -webkit-
or -moz-
.
We offer two popular choices: Autoprefixer (which processes your CSS server-side) and -prefix-free (which applies prefixes via a script, client-side).
Any URLs 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 its URL and the proper URL extension.
You can apply CSS to your Pen from any stylesheet on the web. Just put a URL to it here and we'll apply it, in the order you have them, before the CSS in the Pen itself.
You can also link to another Pen here (use the .css
URL Extension) and we'll pull the CSS from that Pen and include it. If it's using a matching preprocessor, use the appropriate URL Extension and we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
JavaScript preprocessors can help make authoring JavaScript easier and more convenient.
Babel includes JSX processing.
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.
You can apply a script from anywhere on the web to your Pen. Just put a URL to it here and we'll add it, in the order you have them, before the JavaScript in the Pen itself.
If the script you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the JavaScript from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
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.
Using packages here is powered by esm.sh, which makes packages from npm not only available on a CDN, but prepares them for native JavaScript ESM usage.
All packages are different, so refer to their docs for how they work.
If you're using React / ReactDOM, make sure to turn on Babel for the JSX processing.
If active, Pens will autosave every 30 seconds after being saved once.
If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.
If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.
Visit your global Editor Settings.
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="Exquisite Corpses | A paper-and-pencil game for everyone, as explained by Pius Wong">
<meta name="author" content="Pius Wong | www.piuswong.com">
<meta property="og:site_name" content="Exquisite Corpses" />
<meta property="og:title" content="Exquisite Corpses | A paper-and-pencil game for everyone, as explained by Pius Wong" />
<meta property="og:url" content=# />
<meta property="og:type" content="website" />
<meta property="og:description" content="Exquisite Corpses | A paper-and-pencil game for everyone, as explained by Pius Wong" />
<meta property="og:image" content=# />
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:site" content="Inquire | A survcey template by Pius Wong" />
<meta name="twitter:creator" content="@PiusWong">
<meta name="twitter:title" content="Exquisite Corpses | A paper-and-pencil game for everyone, as explained by Pius Wong" />
<meta name="twitter:description" content="A template for a survey form" />
<meta name="twitter:image" content=# />
<link href="https://fonts.googleapis.com/css?family=Oxygen|Bad+Script|Give+You+Glory" rel="stylesheet">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.2.0/css/all.css" integrity="sha384-hWVjflwFxL6sNzntih27bfxkr27PmbbK/iSvJ+a4+0owXq79v+lsFkW54bOGbiDQ" crossorigin="anonymous">
<link href='main.css' rel='stylesheet'>
</head>
<body>
<header id="header">
<nav class="nav-primary" id="nav-bar">
<div class="branding">
<a href="#">Back to Top<img id="header-img" src></a>
</div>
<ul>
<li>
<a href="#about" class="nav-link">About</a>
</li>
<li>
<a href="#how-to-play" class="nav-link">How to Play</a>
</li>
<li>
<a href="#learn-more" class="nav-link">Learn More</a>
</li>
</ul>
</nav>
<h1 id="title">Exquisite Corpses</h1>
<h2>Play this paper-and-pencil game for everyone, as explained by <a href="http://www.piuswong.com" title="Browse some of Pius's projects.">Pius Wong</a>.</h2>
</header>
<main>
<section id="about">
<h3>What? Why...?</h3>
<div class="info-bullets">
<div class="info-bullet">
<div class="info-graphic">
<i class="fas fa-palette"></i>
</div>
<div class="info-text">
<h4>It unleashes creativity.</h4>
<p>Got drawing anxiety? No problem. Writer's block? Piece of cake. Build on other people's ideas, get over yourself, and make something amazing. Or just hilarious.</p>
</div>
</div>
</div>
<div class="info-bullets">
<div class="info-bullet">
<div class="info-graphic">
<i class="fas fa-people-carry"></i>
</div>
<div class="info-text">
<h4>It helps you practice teamwork.</h4>
<p>Ever want to have people reflect on their nonverbal communication abilities? Their unique points of view? Performance under pressure? But in a positive environment? Then this game is for you.</p>
</div>
</div>
</div>
<div class="info-bullets">
<div class="info-bullet">
<div class="info-graphic">
<i class="far fa-smile-wink"></i>
</div>
<div class="info-text">
<h4>It's fun.</h4>
<p>When you're with a group of friends or coworkers at your conference room or along the bar table writing nonsense and scribbling craziness, you can't help but laugh.</p>
</div>
</div>
</div>
</section>
<section id="how-to-play">
<h3>OK. How do we play?</h3>
<p>Grab paper and pencils, distribute to your players, and play around the table. Here's a video explaining the rules:</p>
<div class="video-container">
<iframe width="560" height="315" src="https://www.youtube.com/embed/ws2LlRNvoJY?rel=0&showinfo=0" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen id="video"></iframe>
</div>
<p>There are many variations to the game, as you can imagine. Play around, look up other tweaks to the rules, and see what you like.</p>
</section>
<section id="learn-more">
<h3>Show me more.</h3>
<p>Check out example game results, if you dare, along with other versions of the game. Click below for more resources.</p>
<div class="info-cards">
<a href="https://imgur.com/a/RMy77" title="See example game results on Imgur">
<div class="info-card">
<h5>Example Exquisite Corpses<h5>
<div class="info-icon">
<i class="far fa-grimace"></i>
</div>
<p>Craziness hosted on imgur</p>
</div>
</a>
<a href="https://en.wikipedia.org/wiki/Exquisite_corpse" title="Read more about the game's history on Wikipedia">
<div class="info-card">
<h5>Surrealist Artist Origins<h5>
<div class="info-icon">
<i class="fas fa-paint-brush"></i>
</div>
<p class="long-text">Artists played games like this decades ago.</p>
</div>
</a>
<a href="http://www.greatgroupgames.com/telephone-pictionary.htm" title="Another retelling of the game">
<div class="info-card">
<h5>Telephone Pictionary<h5>
<div class="info-icon">
<i class="fas fa-phone-volume"></i>
</div>
<p>The game has different names.</p>
</div>
</a>
<a href="https://www.thegamegal.com/2011/06/18/paper-telephone/" title="Another retelling of the game without trademark infringment">
<div class="info-card">
<h5>Paper Telephone<h5>
<div class="info-icon">
<i class="far fa-paper-plane"></i>
</div>
<p>Alternate game name without trademarks</p>
</div>
</a>
<a href="https://boardgamegeek.com/boardgame/30618/eat-poop-you-cat" title="Another version of the game">
<div class="info-card">
<h5>Eat Poop You Cat<h5>
<div class="info-icon">
<i class="fas fa-utensils"></i>
</div>
<p class="long-text">Alternate game names can be weird.</p>
</div>
</a>
<a href="https://drawception.com/" title="An example web version of the game">
<div class="info-card">
<h5>Drawception<h5>
<div class="info-icon">
<i class="fas fa-globe"></i>
</div>
<p>A web game version</p>
</div>
</a>
<a href="http://doodleordie.com/" title="An example web version of the game">
<div class="info-card">
<h5>Doodle or Die<h5>
<div class="info-icon">
<i class="fas fa-globe"></i>
</div>
<p>Another web game version</p>
</div>
</a>
<a href="https://boardgamegeek.com/boardgame/46213/telestrations" title="An example commercial version of the game">
<div class="info-card">
<h5>Telestrations<h5>
<div class="info-icon">
<i class="fas fa-dice"></i>
</div>
<p>A board game version</p>
</div>
</a>
<a href="http://www.lacma.org/artswipe" title="A digital form of the drawing game for iOS">
<div class="info-card">
<h5>Art Swipe<h5>
<div class="info-icon">
<i class="fab fa-apple"></i>
</div>
<p>An iOS app form of the drawing game</p>
</div>
</a>
<a href="https://play.google.com/store/apps/details?id=com.megan.exquisitecorpse.capstone&hl=en_US" title="A digital form of the drawing game for Android">
<div class="info-card">
<h5>Exquisite Corpse for Android<h5>
<div class="info-icon">
<i class="fab fa-android"></i>
</div>
<p>An app form of the drawing game</p>
</div>
</a>
<a href="https://readwrite.com/2011/02/21/exquisite_corpse_20_collaborative_story_writing_wi/" title="A digital form of the written-only game">
<div class="info-card">
<h5>FoldingStory<h5>
<div class="info-icon">
<i class="fas fa-font"></i>
</div>
<p>A writing-only form of the game</p>
</div>
</a>
</div>
<div>
<form id="form" action="https://www.freecodecamp.com/email-submit">
<p>Want to get news related to this game?</p>
<label for="email">Sign up for updates:</label>
<input type="email" id="email" name="email" required placeholder="your@emailaddress.com">
<input type="submit" id="submit">
</form>
</div>
</section>
</main>
<footer>
<div>
Powered by HTML/CSS/JS for <a target="_blank" href="https://learn.freecodecamp.org/responsive-web-design/responsive-web-design-projects/build-a-product-landing-page">freeCodeCamp</a>
</div>
<div>
Copyright 2018 <a target="_blank" href="http://www.piuswong.com" title="Browse some of Pius's projects.">Pius Wong</a>
</div>
</footer>
<script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>
<!--
Hello Camper!
For now, the test suite only works in Chrome! Please read the README below in the JS Editor before beginning. Feel free to delete this message once you have read it. Good luck and Happy Coding!
- The freeCodeCamp Team
-->
</body>
</html>
* {
-webkit-box-sizing: border-box;
-mox-box-sizing: border-box;
-ms-box-sizing: border-box;
box-sizing: border-box;
/* border: red solid 1px; */
}
body{
text-align: center;
color: black;
font-family: 'Oxygen', sans-serif;
background: white;
margin: 0;
-webkit-transition: all 1s;
transition: all 1s;
min-width: 300px;
}
a {
text-decoration: none;
color: hsl(239, 96%, 45%);
font-weight: bold;
-webkit-transition: 0.1s;
transition: 0.1s;
text-shadow: none;
}
a:hover, a:focus{
color: hsl(239, 96%, 70%);
}
a:active {
color: hsl(239, 96%, 65%);
}
header{
margin: 0;
padding: 0 0 10px 0;
}
header nav {
width: 100%;
position: fixed;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-orient: horizontal;
-webkit-box-direction: normal;
-ms-flex-direction: row;
flex-direction: row;
-webkit-box-align: start;
-ms-flex-align: start;
align-items: flex-start;
-webkit-box-pack: justify;
-ms-flex-pack: justify;
justify-content: space-between;
margin: 0;
padding: 0;
background: -webkit-gradient(linear,left top, left bottom,from(rgba(255,255,255,.9)),to(rgba(255,255,255,0)));
background: linear-gradient(rgba(255,255,255,.9),rgba(255,255,255,0));
}
header nav .branding {
margin: 10px;
padding: 0;
border-radius: 25px;
background-image: url(http://www.piuswong.com/img/projects/300x300_ec.jpg);
width: 160px;
height: 75px;
background-position: top;
background-size: cover;
background-repeat: none;
-webkit-box-shadow: rgba(0,0,0,0.2) -0px 0px 40px;
box-shadow: rgba(0,0,0,0.2) -0px 0px 40px;
overflow: hidden;
}
header nav .branding a {
opacity: 0;
-webkit-transition: all 0.2s;
transition: all 0.2s;
width: 100%;
height: 100%;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-pack: center;
-ms-flex-pack: center;
justify-content: center;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
font-size: 1.5em;
}
header nav .branding,
header nav .branding a {
-webkit-transition: all 0.3s;
transition: all 0.3s;
}
header nav .branding:hover {
-webkit-transform: scale(1.05);
transform: scale(1.05);
}
header nav .branding:hover a {
opacity: 1;
background: rgba(0,0,0,.4);
color: white;
}
header #header-img {
display: none;
}
header nav ul {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-orient: horizontal;
-webkit-box-direction: normal;
-ms-flex-direction: row;
flex-direction: row;
-ms-flex-wrap: none;
flex-wrap: none;
}
header nav ul li {
list-style-type: none;
padding: 0.25em 1.5em;
}
h1, h2, h3, h4{
font-family: 'Bad Script', cursive;
font-weight: normal;
}
header h1{
font-size: 70px;
margin: 0;
padding-top: 50px;
}
header h2{
font-family: 'Give You Glory', cursive;
font-size: 24px;
margin-top: -10px;
margin-bottom: 0;
max-width: 430px;
margin-left: auto;
margin-right: auto;
}
h3, h4 {
font-weight: bold;
}
main {
margin: 1em;
font-family: 'Bad Script', cursive;
font-family: 'Give You Glory', cursive;
font-size: 2em;
}
main p {
font-family: 'Give You Glory', cursive;
font-size: 24px;
margin: 0;
max-width: 800px;
}
main section {
padding: 25px 0;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-orient: vertical;
-webkit-box-direction: normal;
-ms-flex-direction: column;
flex-direction: column;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
}
main .info-bullets {
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-webkit-box-pack: center;
-ms-flex-pack: center;
justify-content: center;
margin: 25px 0;
}
main .info-bullet {
width: 100%;
max-width: 1200px;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-ms-flex-wrap: no-wrap;
flex-wrap: no-wrap;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
}
main .info-graphic {
min-width: 120px;
font-size: 2.5em;
}
main .info-text {
text-align: left;
padding: 10px;
}
main .info-text h4 {
margin: 0;
}
main .info-text p {
max-width: 1200px;
}
main .video-container {
margin: 24px 0px;
}
main .info-cards {
max-width: 1200px;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-ms-flex-wrap: wrap;
flex-wrap: wrap;
-webkit-box-pack: center;
-ms-flex-pack: center;
justify-content: center;
}
main .info-cards > a {
margin: 25px;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-ms-flex-wrap: wrap;
flex-wrap: wrap;
-webkit-box-pack: center;
-ms-flex-pack: center;
justify-content: center;
}
main .info-cards .info-card {
border: solid rgba(0,0,0,0.5) 2px;
-webkit-box-shadow: rgba(0,0,0,0.7) 1px 1px 30px;
box-shadow: rgba(0,0,0,0.7) 1px 1px 30px;
border-radius: 25px;
width: 250px;
height: 350px;
padding: 25px;
-webkit-transition: all 0.2s;
transition: all 0.2s;
display: -webkit-box;
display: -ms-flexbox;
display: flex;
-ms-flex-wrap: wrap;
flex-wrap: wrap;
-webkit-box-pack: center;
-ms-flex-pack: center;
justify-content: center;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
color: black;
}
main .info-cards .info-card h5 {
margin: 0;
-ms-flex-item-align: start;
align-self: flex-start;
}
main .info-cards .info-card .info-icon i {
font-size: 4em;
padding: 0 0 20px 0;
/* color: hsl(239, 96%, 45%); */
-webkit-transition: all 0.2s;
transition: all 0.2s;
}
main .info-cards .info-card:hover,
main .info-cards .info-card:hover .info-icon i,
main .info-cards > a:focus,
main .info-cards > a:focus .info-icon i {
color: hsl(239, 96%, 70%);
-webkit-transform: scale(1.05);
transform: scale(1.05);
}
.long-text {
font-size: 0.7em;
line-height: 1.5em;
}
footer {
margin: 1em;
}
/* Responsive design */
@media only screen and (max-width: 768px){
header nav {
-webkit-box-orient: vertical;
-webkit-box-direction: normal;
-ms-flex-direction: column;
flex-direction: column;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
}
header ul {
padding: 0;
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
margin: 3px;
}
header h1 {
padding-top: 180px;
}
main {
margin: 10px;
}
main .info-bullets .info-bullet {
-webkit-box-orient: vertical;
-webkit-box-direction: normal;
-ms-flex-direction: column;
flex-direction: column;
}
main .info-bullets .info-bullet .info-text h4 {
text-align: center;
}
main .video-container {
width: 100%;
max-width: unset;
}
main .video-container iframe {
width: 100%;
height:unset;
}
}
@media only screen and (max-width: 500px){
header nav {
background: white;
background: rgba(255,255,255,.8);
}
header h1 {
line-height: 1em;
padding-bottom: 50px;
}
}
// !! 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.
Also see: Tab Triggers