Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

180
Visualizações
How can I remove this hideous hover effect on this button?

So me and my friend are making a chrome extension. To get into detail, it’s for the Roblox Devforum, and so far, so good! Yesterday we started, and already have our button on the header and stuff, similarly to Roblox+ or RoPro.

However there is a situation (not necessarily a bug, mainly a styling issue) with the button. Whenever you hover over the button, some white square appears on the icon of the button and it just looks hideous, and we didn’t know what was causing the issue, even after reviewing multiple articles on Google, which brings us here today. The code for the extension is as follows:

modifications.js:

function getFirstulWithClass(cssClass) {
    var elements = document.getElementsByTagName('ul');
    for (var i = 0; i < elements.length; i++) {
        if((' ' + elements[i].className + ' ').indexOf(' ' + cssClass + ' ') > -1) {
            return elements[i];
        }
    }
}

var ul = getFirstulWithClass('icons d-header-icons'); 
if (ul) {
    ul.innerHTML += `
        <li class="header-dropdown-toggle dpp-dropdown">
          <a title="DPPSettings" class="icon">
            <div>
              <img src="https://i.imgur.com/suZBJ8y.png" width="45" height="29" title="DSI" class="DSI">
            </div>
          </a>
        </li>
    `
}

To clarify this code, all it does is look for the header element, and injects that chunk of HTML code into the header without overriding the original Devforum header code.

Now I wanted to add a little animation to the button so that it looked very eye-appealing, so we added a new file called modifications.css, and looks as follows:


@keyframes settingsHover {
  0% {
    width: 45px;
    height: 29px;
  }
  100% {
    width: 48px;
    height: 31px;
  }
}

.DSI:hover {
  animation-name: settingsHover;
  animation-fill-mode: forwards;
  animation-duration: .01s;
}

All this does is add a small enlargement animation to the button.

Now we tie it together in our manifest.json file as so:


"content_scripts": [
    {
      "matches": ["https://*.devforum.roblox.com/*"], 
      "css": ["modifications.css"],
      "js": ["modifications.js"]
    }
  ],

And this ultimately creates this weird box that was not intended to be added in the programming of this, that looks as so:

enter image description here

How can I remove this? Any help is appreciated very much!

about 4 years ago · Juan Pablo Isaza
2 Respostas
Responde à pergunta

0

Let me preface this by saying I am by no means experienced enough to give a true answer on this, but I don't have enough reputation to give a comment.

Could the white square somehow be the keyframe(s)? It seems shaped like the dimensions you gave and could be some CSS visual error that could be fixed with a line of code or two. For me, it seems likely that it's either a Roblox thing or most likely a CSS thing, but again, I barely can understand what's going on here and have little experience. It could be that that is something like a HTML/CSS class in the Roblox site and you could be accidentally doing something with that as well.

Take this with a grain of salt though.

about 4 years ago · Juan Pablo Isaza Relatório

0

so basically, the answer this was just simply adding this to CSS:

.icon {
  --primary-low: transparent !important;
}
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda