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

208
Views
Cómo agregar pausa en Typed.js representando las cadenas

Estoy trabajando en el siguiente código. ¿Cómo puedo agregar una pausa antes de comenzar a escribir cada elemento? Como puede ver en esta demostración, Typed.js está representando un nuevo elemento exactamente después de que finaliza la limpieza posterior, quiero hacer una pausa allí por unos minutos y luego comenzar a escribir nuevos elementos.

 document.addEventListener('DOMContentLoaded', function(){ Typed.new('.type', { strings: ["neighbor", "family", "team", "community"], stringsElement: null, // typing speed typeSpeed: 60, // time before typing starts startDelay: 600, // backspacing speed backSpeed: 20, // time before backspacing backDelay: 500, // loop loop: true, // false = infinite loopCount: false, // show cursor showCursor: false, // character for cursor cursorChar: "|", // attribute to type (null == text) attr: null, // either html or text contentType: 'html', }); });
 .center { height: 100px; width: 100%; display: flex; justify-content: center; align-items: center; background:#f7f7f7; } span { font-family: Arial; font-size: 25px; } span.type { margin: 0 auto; width: 200px; margin-top: 100px; } span.type::after { content: "|"; display: inline; animation: blink 0.7s infinite; } /*Removes cursor that comes with typed.js*/ .typed-cursor { opacity: 0; display: none; } /*Custom cursor animation*/ @keyframes blink { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } } @-webkit-keyframes blink { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } } @-moz-keyframes blink { 0% { opacity: 1; } 50% { opacity: 0; } 100% { opacity: 1; } }
 <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/typed.js/1.1.7/typed.min.js"></script> <div class="center"> <div class="text"> <span>Love your </span><span class="type"></span> </div> </div>

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

0

Intente aumentar el valor de 'backDelay' a la cantidad de milisegundos que desea que el texto escrito esté en la pantalla.

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!