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. 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

JavaScript

Babel is required to process package imports. If you need a different preprocessor remove all packages first.

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

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 id="page">
  <div class="actions">
    <div class="scale-wrapper"><button class="action-bubble green"><img class="icon" src="https://img.icons8.com/wired/64/000000/jake.png"></button></div>
    <div class="scale-wrapper"><button class="action-bubble cyan"><img class="icon" src="https://img.icons8.com/wired/64/000000/the-flash-sign.png"></button></div>
    <div class="scale-wrapper"><button class="action-bubble orange"><img class="icon" src="https://img.icons8.com/wired/64/000000/darth-vader.png"></button></div>
    <div class="scale-wrapper"><button class="action-bubble red"><img class="icon" src="https://img.icons8.com/wired/64/000000/anonymous-mask.png"></button></div>
    <div class="scale-wrapper"><button class="action-bubble purple"><img class="icon" src="https://img.icons8.com/wired/64/000000/superman.png"></button></div>
    <div class="scale-wrapper"><button class="action-bubble pink"><img class="icon" src="https://img.icons8.com/wired/64/000000/venom-head.png"></button></div>
    <div class="scale-wrapper"><button class="action-bubble yellow"><img class="icon" src="https://img.icons8.com/wired/64/000000/star-trek-symbol.png"></button></div>
    <div class="scale-wrapper"><button class="action-bubble black fold">
      <svg class="icon" width="24" height="24" viewBox="0 0 24 24">
    <path style="fill:white;"d="M20,11V13H8L13.5,18.5L12.08,19.92L4.16,12L12.08,4.08L13.5,5.5L8,11H20Z"></path>
</svg></button></div>
    <div class="suggestion">click Here ⬇</div>
  </div>
  <div class="gallery">
    <svg class="place" width="150" height="90" viewBox="0 0 270 150" style="fill:#ccc; color:#ccc;"><rect x="70" y="15" rx="4" ry="4" width="117" height="6.4" />
        <rect x="70" y="35" rx="3" ry="3" width="85" height="6.4" />
        <rect x="0" y="80" rx="3" ry="3" width="350" height="6.4" />
        <rect x="0" y="100" rx="3" ry="3" width="380" height="6.4" />
        <rect x="0" y="120" rx="3" ry="3" width="201" height="6.4" />
<circle cx="30" cy="30" r="30" /></svg>
    <svg class="place" width="150" height="90" viewBox="0 0 270 150" style="fill:#ccc; color:#ccc;"><rect x="70" y="15" rx="4" ry="4" width="117" height="6.4" />
        <rect x="70" y="35" rx="3" ry="3" width="85" height="6.4" />
        <rect x="0" y="80" rx="3" ry="3" width="350" height="6.4" />
        <rect x="0" y="100" rx="3" ry="3" width="380" height="6.4" />
        <rect x="0" y="120" rx="3" ry="3" width="201" height="6.4" />
<circle cx="30" cy="30" r="30" /></svg>
    <svg class="place" width="150" height="90" viewBox="0 0 270 150" style="fill:#ccc; color:#ccc;"><rect x="70" y="15" rx="4" ry="4" width="117" height="6.4" />
        <rect x="70" y="35" rx="3" ry="3" width="85" height="6.4" />
        <rect x="0" y="80" rx="3" ry="3" width="350" height="6.4" />
        <rect x="0" y="100" rx="3" ry="3" width="380" height="6.4" />
        <rect x="0" y="120" rx="3" ry="3" width="201" height="6.4" />
<circle cx="30" cy="30" r="30" /></svg>

    <svg class="place" width="150" height="90" viewBox="0 0 270 150" style="fill:#ccc; color:#ccc;"><rect x="70" y="15" rx="4" ry="4" width="117" height="6.4" />
        <rect x="70" y="35" rx="3" ry="3" width="85" height="6.4" />
        <rect x="0" y="80" rx="3" ry="3" width="350" height="6.4" />
        <rect x="0" y="100" rx="3" ry="3" width="380" height="6.4" />
        <rect x="0" y="120" rx="3" ry="3" width="201" height="6.4" />
<circle cx="30" cy="30" r="30" /></svg>

    <svg class="place" width="150" height="90" viewBox="0 0 270 150" style="fill:#ccc; color:#ccc;"><rect x="70" y="15" rx="4" ry="4" width="117" height="6.4" />
        <rect x="70" y="35" rx="3" ry="3" width="85" height="6.4" />
        <rect x="0" y="80" rx="3" ry="3" width="350" height="6.4" />
        <rect x="0" y="100" rx="3" ry="3" width="380" height="6.4" />
        <rect x="0" y="120" rx="3" ry="3" width="201" height="6.4" />
<circle cx="30" cy="30" r="30" /></svg>
  </div>
  <div class="title">
    <h2>Airtable onboarding animations
      <h3><a id="icons8-link" href="https://icons8.com">Icons by Icons8</a></h3>
    </h2>
  </div>
              
            
!

CSS

              
                @import url("https://fonts.googleapis.com/css?family=Lato:400,400i,700");

:root {
  --airtable-green: #20c933;
  --airtable-cyan: #18bfff;
  --airtable-red: #f82b60;
  --airtable-orange: #ff6f2c;
  --airtable-purple: #8b46ff;
  --airtable-pink: #ff08c2;
  --airtable-yellow: #fcb400;
  --airtable-black: hsl(0, 0%, 30%);
  --card-resize-screen-width-limit: 900px;
}

body {
  font-family: Lato, sans-serif;
  margin: 0;
  overflow: hidden;
}
#page {
  display: flex;
  flex-direction: column-reverse;
  justify-content: space-between;
  align-items: flex-end;
  background-image: url('data:image/svg+xml,%3Csvg width="52" height="26" viewBox="0 0 52 26" xmlns="http://www.w3.org/2000/svg"%3E%3Cg fill="none" fill-rule="evenodd"%3E%3Cg fill="%239C92AC" fill-opacity="0.4"%3E%3Cpath d="M10 10c0-2.21-1.79-4-4-4-3.314 0-6-2.686-6-6h2c0 2.21 1.79 4 4 4 3.314 0 6 2.686 6 6 0 2.21 1.79 4 4 4 3.314 0 6 2.686 6 6 0 2.21 1.79 4 4 4v2c-3.314 0-6-2.686-6-6 0-2.21-1.79-4-4-4-3.314 0-6-2.686-6-6zm25.464-1.95l8.486 8.486-1.414 1.414-8.486-8.486 1.414-1.414z" /%3E%3C/g%3E%3C/g%3E%3C/svg%3E');
  background-color: #fff59d;
  // background-size:15px;
  height: 100vh;
  width: 100vw;
}

.actions {
  display: flex;
  align-items: center;
  margin-right: 45px;
  margin-bottom: 45px;
  position: relative;
}

.actions .action-bubble {
  border-radius: 50%;
  opacity: 0.9;
  flex-grow: 0;
  cursor: pointer;
  padding: 7px;
  border: none;
  transition: all 0.6s 0.4s linear;
}

.scale-wrapper {
  margin-left: 12px;
  transition: all 1s cubic-bezier(0.63, -0.51, 0.57, 1.25);
}

.actions .action-bubble.green {
  background-color: var(--airtable-green);
}
.actions .action-bubble.cyan {
  background-color: var(--airtable-cyan);
}
.actions .action-bubble.orange {
  background-color: var(--airtable-orange);
}
.actions .action-bubble.red {
  background-color: var(--airtable-red);
}
.actions .action-bubble.purple {
  background-color: var(--airtable-purple);
}
.actions .action-bubble.pink {
  background-color: var(--airtable-pink);
}
.actions .action-bubble.yellow {
  background-color: var(--airtable-yellow);
}
.actions .action-bubble.black {
  background-color: var(--airtable-black);
}

.actions .action-bubble .icon {
  height: 32px;
  width: 32px;
}

.actions .action-bubble:last-child > svg {
  fill-color: white;
  width: 16px;
  height: 16px;
}

#icons8-link {
  margin-top: 15px;
  order: 1;
  align-self: flex-start;
  text-decoration: none;
}

.scale-wrapper {
  transform: translateX(-12px);
}

.scale-wrapper.test:nth-child(7) {
  transform-origin: 50% 50%;
  transform: translateX(12%) rotate(360deg);
  .action-bubble {
    transform: scale(0.3);
  }
}

.scale-wrapper.test:nth-child(6) {
  transform-origin: 150% 50%;
  transform: translateX(105%) rotateZ(51deg) translateX(30%);
  .action-bubble {
    transform: scale(0.3);
  }
}

.scale-wrapper.test:nth-child(5) {
  transform-origin: 150% 50%;
  transform: translateX(230%) rotateZ(103deg) translateX(30%);
  .action-bubble {
    transform: scale(0.3);
  }
}

.scale-wrapper.test:nth-child(4) {
  transform-origin: 150% 50%;
  transform: translateX(360%) rotateZ(154deg) translateX(30%);
  .action-bubble {
    transform: scale(0.3);
  }
}

.scale-wrapper.test:nth-child(3) {
  transform-origin: 150% 50%;
  transform: translateX(480%) rotateZ(205deg) translateX(30%);
  .action-bubble {
    transform: scale(0.3);
  }
}

.scale-wrapper.test:nth-child(2) {
  transform-origin: 150% 50%;
  transform: translateX(610%) rotateZ(257deg) translateX(30%);
  .action-bubble {
    transform: scale(0.3);
  }
}

.scale-wrapper.test:nth-child(1) {
  transform-origin: 150% 50%;
  transform: translateX(740%) rotateZ(308deg) translateX(30%);
  .action-bubble {
    transform: scale(0.3);
  }
}

.fold {
  transform: rotate(-180deg);
}

.test .action-bubble.fold {
  transform: rotate(0deg);
}

.gallery {
  margin: 15px;
  margin-top: 0;
  align-self: stretch;
  display: flex;
  justify-content: space-around;
  align-content: space-evenly;
  align-items: center;
  flex-grow: 1;
  padding-left: 65px;
  padding-right: 65px;
}

@media(min-width:1000px){
  .gallery svg{
height:200px;
    min-height:unset;
  }
}

@media(min-width:900px){
  .gallery svg{
    max-height:150px;
    flex-grow:1;
  }
}

@media(max-width:900px){
  .gallery{
    // flex-flow:wrap;
  }
  
  .gallery svg{
    flex-grow:0;
  }
}
.gallery svg {
  width: 220px;
  padding: 15px;
  margin-right: 30px;
  border: 1px solid #45b051;
  border-radius: 5px;
  flex-shrink: 1;
  flex-basis: 100px;
}
.suggestion {
  position: absolute;
  color:#555555;
  right: 5%;
  top: -55px;
  font-size: 20px;
  text-transform: uppercase;
}
.place {
  padding: 15px;
  border: 1px solid #555;
  background-color: #4ec25b;
  box-shadow: 3px 1px 10px #888;
}

.title {
  padding-left: 80px;
  align-self: flex-start;
  font-family: Lato;
  height: 30px;
  color: #666;
  h2 {
    margin-bottom: 0;
    text-decoration: underline;
  }
  h3 {
    margin-top: 0;
    color: #666;
    opacity: 0.5;
  }
  h3::visited {
    color: #666;
  }
}

              
            
!

JS

              
                const foldButton = document.querySelector(".fold");
const actionsWrapper = document.querySelector(".actions");
let open = true;
foldButton.addEventListener("click", () => {
  const icons = document.querySelectorAll(`.scale-wrapper`);
  if (open == true) {
    icons.forEach(icon => {
      icon.classList.add("test");
    });
    actionsWrapper.classList.add("rotating");
    open = false;
  } else {
    icons.forEach(icon => {
      icon.classList.remove("test");
      actionsWrapper.classList.remove("rotating");
      open = true;
    });
  }
});

              
            
!
999px

Console