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

100
Visualizações
vue.js mode for css

I have this BaseComponent used and configures in another component as followed:

<BaseTitle
      v-slot="{ highlightClass }"
      :color="mode === 'faq' ? 'dark' : 'secondary'"
      v-bind="__titleProps"
      :text-uppercase="mode === 'incentive'"
      highlight-type="colorize-uppercase-bold"
      :class="{ 'font-weight-normal': mode === 'faq' }"
    >

On this element I have a css-hover class


    .InfoTile {
      &:hover {
        .answer {
          background-color: $transparent-primary;
          opacity: 1;
        }
    
        .question {
          opacity: 0;
        }
      }

When I use the „incentive" mode I need to use another hover background-color. Is there a way to use another hover depending on the mode I use?

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

0

So, is totally possible.

You just need to create 2 differentes css classes, between normal mode and incentive, that will have 2 differentes hover, etc.

you'll made a conditional term checking if mode === incentive.

But, the first thing you need to do is to set more than one classes in your component, you're using one already.

so, just do something like this.

:class="[{ 'font-weight-normal': mode === 'faq' }, mode === incentive ? 'cssClass1': 'cssClass2']"
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