Floating Message – Whatsapp Icon – Close Button

<div class="ifso-pt-10">
  <a href="https://wa.me/number" target="_blank" class="ifso-pt-10-link">
    <img src="https://www.if-so.com/wp-content/uploads/2022/06/whatsapp-icon.png" alt="chat" class="ifso-pt-image">
  </a>
  <svg onclick="document.querySelector('.ifso-pt-10').style.display = 'none'" class="ifso-pt-close" viewBox="0 0 10 10">
    <path d="M0 0 L10 10 M0 10 L10 0" stroke="#3d3578" stroke-width="1.5"></path>
  </svg>
</div>

<style>
  .ifso-pt-10 {
    position: fixed;
    left: 8px;
    bottom: 8px;
    z-index: 100;
  }
  .ifso-pt-10-link {
    display: contents;
  }
  .ifso-pt-image {
    width: 50px;
    border-radius: 50%;
  }

  .ifso-pt-close {
    position: absolute;
    right: -12px;
    top: -12px;
    width: 20px;
    cursor: pointer;
    border-radius: 50%;
    padding: 5px;
    background-color: #e0e0e0;
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
  }
</style>
Use it on your site
PREVIEW

Categories

Content Type, Desktop, Device, Floating Messages, Mobile