Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

125
Views
Cómo transformar 3 barras (&#9866) en una "-X" usando Transformar y Transición

 #menu{ transition-duration: 1s; transition-timing-function: ease-out; } #menu:hover div:nth-of-type(1){ transform-origin: top; transform: rotate(45deg); transition-duration: 1s; transition-timing-function: ease-out; } #menu:hover div:nth-of-type(3){ transform-origin: 1px bottom; transform: rotate(-45deg); transition-duration: 1s; transition-timing-function: ease-out; } #menu:hover div:nth-of-type(2){ transform: translateX(-10px); transition-duration: 1s; transition-timing-function: ease-out; }
 <html> <head></head> <body> <div id="menu" > <div class="bar" id="br1">&#9866</div> <div class="bar" id="br2">&#9866</div> <div class="bar" id="br3">&#9866</div> </div> </body>

Se supone que el código convierte las 3 barras (# 9866) en una "-X" cuando pasamos el cursor sobre el div (menú) usando el formulario de elemento de transformación CSS, pero de alguna manera no lo está haciendo

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

¿Puedes comprobar el siguiente código? Espero que te funcione

Consulte este enlace: https://jsfiddle.net/yudizsolutions/5x7kefwj/1/

Hicimos cambios en el archivo Html, en lugar de usar código hexadecimal, envolvimos las barras en una etiqueta de intervalo y también hicimos cambios en el archivo CSS aplicando ( tranfrom-origin: right ) ya que establecerá su posición a la derecha en lugar del centro , y al pasar el mouse, hemos aplicado ( transform: rotate( ) ) y ahora obtendrá el resultado deseado.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!