Pen Settings

HTML

CSS

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

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

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.

HTML

              
                
<div class="block"></div>
<ul class="utility-list">
                  <li class="utility__item">
                    <div class="utility-content">
                      <div class="utility-desc">
                        <h3 class="utility__subtitle subtitle">
                          Payout Split
                        </h3>
                        <p class="desc-txt">
                          10% of rewards earned by Midas platform community is used to <span>buyback MIDAS token</span> from the open market
                        </p>
                      </div>
                      <div class="utility__img">
                        <svg class="split" width="620" height="448" fill="none">
                          <g class="panel" width="87" height="258" x="28" y="133" stroke="#fff" stroke-opacity=".08" stroke-width="2" rx="23" >
                            <rect width="89" height="260" x="27" y="132" fill="#fff" fill-opacity=".08" rx="24" />
                          </g>
                          <g class="panel" width="87" height="258" x="28" y="133" stroke="#fff" stroke-opacity=".08" stroke-width="2" rx="23" >
                            <rect width="89" height="260" x="136" y="112" fill="#fff" fill-opacity=".08" rx="24" />
                          </g>
                          <g class="panel" width="87" height="258" x="28" y="133" stroke="#fff" stroke-opacity=".08" stroke-width="2" rx="23" >
                            <rect width="89" height="260" x="245" y="92" fill="#fff" fill-opacity=".08" rx="24" />
                          </g>
                          <g class="panel" width="87" height="258" x="28" y="133" stroke="#fff" stroke-opacity=".08" stroke-width="2" rx="23" >
                            <rect width="89" height="260" x="354" y="72" fill="#fff" fill-opacity=".08" rx="24" />
                          </g>
                          <g class="panel">
                            <rect width="89" height="260" x="463" y="52" fill="url(#b)" rx="24" />
                          </g>
                          <path fill="#fff"
                            d="M55.435 373v-14.545h9.318v2.208H58.07v3.949h6.044v2.209H58.07V373h-2.635Zm15.233.213c-1.093 0-2.038-.227-2.833-.682a4.617 4.617 0 0 1-1.826-1.946c-.426-.843-.639-1.835-.639-2.976 0-1.122.213-2.107.64-2.954.43-.852 1.032-1.515 1.803-1.989.772-.478 1.679-.717 2.72-.717.673 0 1.307.109 1.904.327a4.298 4.298 0 0 1 1.59.994c.465.45.83 1.023 1.095 1.719.265.691.397 1.515.397 2.471v.789h-8.941v-1.733h6.477a2.763 2.763 0 0 0-.32-1.314 2.314 2.314 0 0 0-.873-.916c-.37-.223-.8-.334-1.293-.334-.526 0-.987.128-1.385.383a2.644 2.644 0 0 0-.93.995c-.218.407-.33.854-.334 1.342v1.513c0 .634.116 1.179.348 1.633.232.45.556.796.973 1.037.417.237.904.355 1.463.355.374 0 .713-.052 1.016-.156a2.26 2.26 0 0 0 .788-.476c.223-.208.39-.466.504-.774l2.4.27a3.75 3.75 0 0 1-.866 1.662c-.421.469-.96.833-1.619 1.094-.658.255-1.41.383-2.259.383Zm6.74-.213v-14.545h2.571v5.44h.107c.132-.265.32-.547.56-.845a2.99 2.99 0 0 1 .98-.774c.413-.218.938-.327 1.578-.327a4.16 4.16 0 0 1 2.28.646c.681.426 1.221 1.058 1.619 1.896.402.834.603 1.857.603 3.069 0 1.198-.196 2.216-.59 3.054-.392.838-.927 1.477-1.604 1.917-.677.441-1.444.661-2.301.661-.625 0-1.144-.104-1.556-.313a3.153 3.153 0 0 1-.994-.753 4.867 4.867 0 0 1-.575-.845h-.15V373h-2.528Zm2.521-5.455c0 .706.1 1.324.299 1.854.203.53.495.945.873 1.243.384.294.848.44 1.392.44.569 0 1.044-.151 1.428-.454.383-.308.672-.727.866-1.257.2-.535.299-1.144.299-1.826 0-.677-.097-1.278-.291-1.804-.195-.525-.484-.937-.867-1.235-.383-.299-.862-.448-1.435-.448-.549 0-1.015.145-1.399.433-.383.289-.674.694-.873 1.215-.195.521-.292 1.134-.292 1.839Zm83.506-29.09h3.224l4.318 10.539h.171l4.318-10.539h3.224V353h-2.528v-9.993h-.135l-4.02 9.95h-1.889l-4.02-9.971h-.135V353h-2.528v-14.545Zm20.75 14.765c-.691 0-1.314-.123-1.868-.369a3.04 3.04 0 0 1-1.306-1.108c-.318-.488-.476-1.089-.476-1.804 0-.616.113-1.125.341-1.527.227-.403.537-.724.93-.966a4.708 4.708 0 0 1 1.328-.547c.497-.128 1.011-.22 1.541-.277a60.519 60.519 0 0 0 1.556-.177c.397-.057.686-.142.866-.256.185-.118.277-.301.277-.547v-.043c0-.535-.158-.949-.476-1.242-.317-.294-.774-.441-1.37-.441-.63 0-1.13.138-1.499.412-.365.275-.611.599-.739.973l-2.4-.341c.189-.663.502-1.217.937-1.662.436-.45.969-.786 1.598-1.008.63-.228 1.326-.341 2.088-.341.526 0 1.049.061 1.57.185.521.123.997.326 1.428.61.43.28.776.661 1.036 1.144.266.483.398 1.086.398 1.811V353h-2.471v-1.499h-.086a3.135 3.135 0 0 1-.66.853 3.19 3.19 0 0 1-1.058.632c-.422.156-.917.234-1.485.234Zm.668-1.889c.516 0 .963-.102 1.342-.305.379-.209.67-.483.874-.824.208-.341.312-.713.312-1.115v-1.286c-.08.066-.218.128-.412.185a5.84 5.84 0 0 1-.639.149c-.237.043-.471.08-.703.114l-.604.085a4.513 4.513 0 0 0-1.03.255 1.716 1.716 0 0 0-.717.498c-.175.208-.263.478-.263.809 0 .474.173.831.519 1.073.345.241.786.362 1.321.362ZM192.13 353v-10.909h2.493v1.818h.114c.199-.63.54-1.115 1.023-1.456a2.81 2.81 0 0 1 1.669-.518c.142 0 .3.007.476.021.179.009.329.026.447.05v2.365a2.74 2.74 0 0 0-.518-.1 4.79 4.79 0 0 0-.675-.049c-.469 0-.89.101-1.264.305-.37.199-.661.476-.874.831-.213.355-.32.765-.32 1.229V353h-2.571Zm83.173-20h-2.813l5.121-14.545h3.253L285.991 333h-2.812l-3.885-11.562h-.114L275.303 333Zm.092-5.703h7.67v2.116h-7.67v-2.116Zm11.999 9.794v-15h2.528v1.804h.149c.133-.265.32-.547.561-.845a2.98 2.98 0 0 1 .98-.774c.412-.218.938-.327 1.577-.327.843 0 1.603.215 2.28.646.682.426 1.222 1.058 1.619 1.896.403.834.604 1.857.604 3.069 0 1.198-.197 2.216-.59 3.054-.393.838-.928 1.477-1.605 1.917-.677.441-1.444.661-2.301.661-.625 0-1.143-.104-1.555-.313a3.14 3.14 0 0 1-.994-.753 4.87 4.87 0 0 1-.576-.845h-.106v5.81h-2.571Zm2.521-9.546c0 .706.099 1.324.298 1.854.204.53.495.945.874 1.243.383.294.847.44 1.392.44.568 0 1.044-.151 1.427-.454.384-.308.673-.727.867-1.257.199-.535.298-1.144.298-1.826 0-.677-.097-1.278-.291-1.804-.194-.525-.483-.937-.866-1.235-.384-.299-.862-.448-1.435-.448-.549 0-1.016.145-1.399.433-.384.289-.675.694-.874 1.215-.194.521-.291 1.134-.291 1.839Zm9.579 5.455v-10.909h2.493v1.818h.113c.199-.63.54-1.115 1.023-1.456a2.813 2.813 0 0 1 1.669-.518c.142 0 .301.007.476.021.18.009.329.026.447.05v2.365a2.722 2.722 0 0 0-.518-.1 4.79 4.79 0 0 0-.675-.049c-.469 0-.89.101-1.264.305a2.24 2.24 0 0 0-.874.831 2.343 2.343 0 0 0-.319 1.229V333h-2.571Zm88.679-34.545h2.614v10.227c-.005.937-.204 1.745-.597 2.422a3.985 3.985 0 0 1-1.647 1.555c-.701.36-1.518.54-2.451.54-.852 0-1.619-.152-2.301-.455a3.747 3.747 0 0 1-1.612-1.363c-.398-.602-.597-1.35-.597-2.245h2.621c.005.393.09.732.256 1.016.17.284.405.502.703.653.298.152.642.228 1.03.228.421 0 .779-.088 1.072-.263.294-.18.516-.445.668-.796.156-.35.237-.781.241-1.292v-10.227Zm11.912 9.957v-6.321h2.571V313h-2.493v-1.939h-.113a3.287 3.287 0 0 1-1.215 1.499c-.559.388-1.248.582-2.067.582-.715 0-1.347-.159-1.896-.476-.544-.322-.971-.788-1.278-1.399-.308-.615-.462-1.359-.462-2.23v-6.946h2.571v6.548c0 .691.189 1.241.568 1.648.379.407.876.611 1.492.611.378 0 .745-.093 1.1-.277a2.24 2.24 0 0 0 .874-.824c.232-.369.348-.831.348-1.385Zm7.386-1.804V313H404.9v-10.909h2.457v1.854h.128a3.114 3.114 0 0 1 1.2-1.456c.554-.36 1.239-.54 2.053-.54.753 0 1.409.161 1.967.483a3.25 3.25 0 0 1 1.307 1.399c.313.611.467 1.352.462 2.223V313h-2.571v-6.548c0-.729-.19-1.3-.568-1.712-.374-.412-.893-.618-1.556-.618-.45 0-.85.1-1.2.298a2.07 2.07 0 0 0-.817.846c-.194.369-.291.816-.291 1.342Zm93.702-28.153h2.614v10.227c-.005.937-.204 1.745-.597 2.422a3.985 3.985 0 0 1-1.647 1.555c-.701.36-1.518.54-2.451.54-.852 0-1.619-.152-2.301-.455a3.747 3.747 0 0 1-1.612-1.363c-.398-.602-.597-1.35-.597-2.245h2.621c.005.393.09.732.256 1.016.17.284.405.502.703.653.298.152.642.228 1.03.228.421 0 .779-.088 1.072-.263.294-.18.516-.445.668-.796.156-.35.237-.781.241-1.292v-10.227Zm11.912 9.957v-6.321h2.571V293h-2.493v-1.939h-.113a3.287 3.287 0 0 1-1.215 1.499c-.559.388-1.248.582-2.067.582-.715 0-1.347-.159-1.896-.476-.544-.322-.971-.788-1.278-1.399-.308-.615-.462-1.359-.462-2.23v-6.946h2.571v6.548c0 .691.189 1.241.568 1.648.379.407.876.611 1.492.611.378 0 .745-.093 1.1-.277a2.24 2.24 0 0 0 .874-.824c.232-.369.348-.831.348-1.385Zm7.386-9.957V293H517.9v-14.545h2.571Z" />
                          <defs>
                            <linearGradient id="b" x1="508" x2="590.611" y1="312" y2="282.376" gradientUnits="userSpaceOnUse">
                              <stop stop-color="#FFC657" />
                              <stop offset="1" stop-color="#FFD977" />
                            </linearGradient>
                            <filter id="a" width="225" height="396" x="395" y="0" color-interpolation-filters="sRGB"
                              filterUnits="userSpaceOnUse">
                              <feFlood flood-opacity="0" result="BackgroundImageFix" />
                              <feColorMatrix in="SourceAlpha" result="hardAlpha" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" />
                              <feMorphology in="SourceAlpha" radius="12" result="effect1_dropShadow_1_629" />
                              <feOffset dy="16" />
                              <feGaussianBlur stdDeviation="40" />
                              <feComposite in2="hardAlpha" operator="out" />
                              <feColorMatrix values="0 0 0 0 1 0 0 0 0 0.843137 0 0 0 0 0.45098 0 0 0 0.24 0" />
                              <feBlend in2="BackgroundImageFix" result="effect1_dropShadow_1_629" />
                              <feBlend in="SourceGraphic" in2="effect1_dropShadow_1_629" result="shape" />
                            </filter>
                          </defs>
                        </svg>
                      </div>
                    </div>
                  </li>
                </ul>
<div class="block"></div>
              
            
!

CSS

              
                * {
  margin: 0;
  padding: 0;
  color: #fcfcfc;
  list-style: none;
  box-sizing: border-box;
  background-color: #0A0C0F;
}

.block {
  height: 100vh;
}

.utility {
  &__title {
    margin-bottom: 60px;
  }

  &-list {
    margin-bottom: 64px;
  }

  &-content {
    display: grid;
    grid-gap: 20px;
    align-items: center;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
  }

  &__subtitle {
    margin-bottom: 32px;
  }

  &__img {
    width: 100%;
    svg,
    img {
      width: 100%;
      height: 100%;
    }
  }
}
              
            
!

JS

              
                gsap.registerPlugin(ScrollTrigger);
const tl = gsap.timeline();

gsap.utils.toArray('.split rect').forEach(panel => {
      const axisY = panel.getAttribute('y');
      const string = parseInt(axisY);

      tl.fromTo(panel, {
        height: 52,
        stagger: {
          each: .3,
        },
        attr: {
          y: `${string + 208}`,
        },
      }, {
        height: 260,
        stagger: {
          each: .3,
        },
        attr: {
          y: `${axisY}`,
        },
        duration: .4,
        scrollTrigger: {
          trigger: panel,
          start: 'top 85%',
          end: 'bottom bottom',
          scrub: 3.5,
        }
      })
    })
              
            
!
999px

Console