Pen Settings



CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

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.

+ add another resource


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


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.


Auto Save

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.


                <!DOCTYPE html>
<html lang="en">
<link rel="stylesheet" href="style.css">
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">


    <div class="shape-shift">
        <p id="text">Lorem ipsum dolor sit, <br>amet consectetur adipisicing elit.</p>

    <div class="shapes">
        <p>Choose your shape</p>
        <button id="triangle"><img src="" alt=""></button>
        <button id="circle"><img src="" alt=""></button>
        <button id="square"><img src="" alt=""></button>

    <footer>&copy; 2020 <a href="">StraleB</a></footer>
<script src="script.js"></script>


                @import url('');

    background-color: rgb(246, 248, 211);

    margin: 3em auto;
    text-align: center;
    font-family: 'Odibee Sans',
    font-size: 3em;
   border: 3px solid black;
   width: 7em;
  background-repeat: no-repeat;
  background-size:90% 100%;
  background-position-x:0.1em ;
position: relative;
  transition: all 0.2s;

    background-color: rgb(246, 248, 211);
   width: 10em;
   margin: 1.3em -1.5em;

    margin: 0 45%;
    width: 15em;

.shapes p{
    margin: 0 0.5em;
    padding-bottom: 2em;
    font-size: 1.2em;
    font-family:'Arial Narrow', Arial, sans-serif;
    font-weight: bold;

.shapes button{
border: 2px solid black;
background-color: transparent;

.shapes button:hover{
    background-color: rgb(197, 199, 173);
    cursor: pointer;

    margin: 10em 0;
    text-align: center;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-weight: bold;

footer a{
    text-decoration: none;
    color: royalblue;

@media screen and (max-width: 1280px) {
    .shapes {
        margin: 0 42%;

@media screen and (max-width: 960px) {
    .shapes {
        margin: 0 38%;

@media screen and (max-width: 960px) {
    .shapes {
        margin: 0 35%;


                const shapeShift = document.querySelector('.shape-shift')
const txt = document.querySelector('#text');
const triangle = document.querySelector('#triangle');

triangle.onclick = function(){ = "url('')" ="transparent"; = "no-repeat""90% 100%";

const circle = document.querySelector('#circle');
circle.onclick = function(){ = "140em"; = "5em" = " 1.3em 10em;" = "black"; ="rgb(246, 248, 211)";

const square = document.querySelector('#square');
square.onclick = function () { = "0" = "7em" = "black"; ="rgb(246, 248, 211)";