JSFiddle - React, Tailwind, and code Playground

by neonDog

HTML

<div class="info-wrapper">
  <div class="info-title-box">
    <p>If link is blocked, just open menu here and "Open in browser" 😜</p>
    <img height="40" src="https://emokitten.com/emokitten/arrow2.gif">
  </div>
</div>

CSS

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600&display=swap');

* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}
body {
  min-height: 100vh;
  background-color: #4070f4;
}

.info-wrapper {
  position: fixed;
  right: -300px;
  top: 14px;
  max-width: 220px;
  width: 100%;
  background: blue;
  border-radius: 8px;
  padding: 10px;
  transition: all 0.3s ease;
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
}
.info-wrapper img {
  margin-top: -25px;
}
.info-wrapper.show {
  right: 10px;
}
.info-title-box {
  display: flex;
  align-items: top;
  column-gap: 5px;
  color: #4070f4;
}
.info-title-box p {
  font-size: 16px;
  font-weight: 400;
}

JavaScript

const infoBox = document.querySelector('.info-wrapper');
window.addEventListener('load', () => {
  infoBox.classList.add('show');
});