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

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 class="container">
<svg version="1.1" id="globe_1" xmlns="http://www.w3.org/2000/svg" x="0" y="0" viewBox="0 0 707.1 459.4" xml:space="preserve"><style>.st0{fill:none;stroke:#fff;stroke-miterlimit:10}.st1{fill:#fff}.st2{fill:none;stroke:#fff;stroke-width:6;stroke-linecap:round;stroke-miterlimit:10}</style><g id="container">
  <g id="left">
 <line id="line01" class="line" x1="20" y1="20" x2="190" y2="100"/>
     <text class="text" x="-255" y="25">Transaction Screening</text>
    <circle id="circle01" class="dot" cx="20" cy="20" r="24"/>
    <line id="line01-1" class="line line-red" x1="10" y1="150" x2="190" y2="100"/>
  <line id="line02" class="line" x1="10" y1="150" x2="160" y2="150"/>
      <circle id="circle02" class="dot" cx="10" cy="150" r="18"/>
    <text class="text" x="-355" y="155">Customer Management System</text>
    <line id="line02-1" class="line line-red" x1="10" y1="150" x2="10" y2="300"/>
  <line id="line03" class="line" x1="10" y1="300" x2="140" y2="280"/>
    <circle id="circle03" class="dot" cx="10" cy="300" r="20"/>
    <text class="text" x="-255" y="305">Contact Management</text>
   <line id="line04" class="line" x1="20" y1="500" x2="180" y2="380"/>
    <line id="line04-1" class="line line-red" x1="20" y1="500" x2="140" y2="280"/> 
   <circle id="circle04" class="dot" cx="20" cy="500" r="14"/>
   <text class="text" x="-245" y="510">Contact Management</text> 
  </g>
  <g id="right">
 <line id="line05" class="line" x1="620" y1="20" x2="520" y2="100"/>
    <text class="text" x="640" y="25">Risk Management</text> 
    <circle id="circle05" class="dot" cx="620" cy="20" r="14"/>
    <line id="line05-1" class="line line-red" x1="710" y1="150" x2="620" y2="20"/>
  <line id="line06" class="line" x1="710" y1="150" x2="560" y2="150"/>
    <circle id="circle06" class="dot" cx="710" cy="150" r="18"/>
    <text class="text" x="740" y="155">Audit Trail</text> 
  <line id="line07" class="line" x1="720" y1="300" x2="575" y2="280"/>
    <line id="line07-01" class="line line-red" x1="710" y1="150" x2="575" y2="280"/>
    <circle id="circle07" class="dot" cx="720" cy="300" r="24"/>
    <text class="text" x="760" y="305">Know your Client</text> 
   <line id="line08" class="line" x1="680" y1="500" x2="530" y2="380"/>
    <line id="line08-1" class="line line-red" x1="680" y1="500" x2="575" y2="280"/>
    <circle id="circle08" class="dot" cx="680" cy="500" r="14"/>
    <text class="text" x="710" y="505">Partner Screening</text> 
  </g>
 <g id="inner_1_"><path class="st1" d="M356.4 62.7c49 0 95.1 19.1 129.8 53.8 34.7 34.7 53.8 80.8 53.8 129.8s-19.1 95.1-53.8 129.8c-34.7 34.7-80.8 53.8-129.8 53.8s-95.1-19.1-129.8-53.8c-34.7-34.7-53.8-80.8-53.8-129.8s19.1-95.1 53.8-129.8 80.8-53.8 129.8-53.8m0-15c-109.7 0-198.6 88.9-198.6 198.6s88.9 198.6 198.6 198.6S555 355.9 555 246.2 466.1 47.7 356.4 47.7z" id="inner"/><path id="outer-right" class="st2" d="M446.2 448.9C523.9 414.4 578 336.7 578 246.2S523.9 78 446.2 43.6"/><path id="outer-left" class="st2" d="M266.5 43.6C188.9 78 134.7 155.8 134.7 246.2s54.2 168.2 131.8 202.7"/></g></g></svg>
</div>
              
            
!

CSS

              
                * {
  margin: 0;
}

.container {
  width: 100vw;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgb(79,56,84);
  background: linear-gradient(90deg, rgba(79,56,84,1) 0%, rgba(1,55,83,1) 100%);
}

#globe_1 {
  width: 30%;
  overflow:visible;
}

#globe_1 line {
  fill: none;
  stroke: white;
  stroke-width: 2;
}

#globe_1 .dot {
  fill: white;
}

#globe_1 text {
  font-family:sans-serif;
  font-size:24px;
  stroke: white;
  visibility:hidden;
  fill: white;
}

.line-red {
  stroke: red!important;
}
              
            
!

JS

              
                
const lines = gsap.utils.toArray(".line");
const allText = gsap.utils.toArray(".text");

gsap.utils.toArray(".dot").forEach(function(dot, i) {
  
var action = gsap.timeline({
    repeat:-1, yoyo:true, delay:i, //delay:i = not synchron
    defaults:{duration:(i+3)*0.3}
  }) 
  .to(lines[i], {attr:{x1:'+=10'}, ease:'none'})
  .to(allText[i], {attr:{x:'+=10'},  ease:'none'},0)
  .to(dot, {attr:{cx:'+=10'}, ease:'none'},0)
  .to(lines[i], {attr:{y1:'+=10'}, ease:'power2.out'},0)
  .to(allText[i], {attr:{y:'+=10'}, ease:'none'},0)
  .to(dot, {attr:{cy:'+=10'}, ease:'power2.out'},0)

  
  dot.addEventListener("mouseenter", function (){ 
    action.pause();
    gsap.to(dot, {scale:1.2, transformOrigin:'center'})
    gsap.to(allText[i], {autoAlpha:1})
  });

  dot.addEventListener("mouseleave", function (){ 
    action.play();
    gsap.to(dot, {scale:1})
    gsap.to(allText[i], {autoAlpha:0})
  })
})


              
            
!
999px

Console