最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - How to hide the cursor permanently in Typed JS - Stack Overflow

programmeradmin7浏览0评论

I want to hide the cursor permanently in TypedJS i.e. I don't want it to blink/show as it types. I have found some tutorials on how to hide it on plete but not how to hide it since beginning. How to achieve it?

I want to hide the cursor permanently in TypedJS i.e. I don't want it to blink/show as it types. I have found some tutorials on how to hide it on plete but not how to hide it since beginning. How to achieve it?

Share Improve this question asked Nov 28, 2019 at 7:00 Sourav DasSourav Das 531 silver badge5 bronze badges
Add a ment  | 

2 Answers 2

Reset to default 6

Just use the showCursor option.

 var typedX = new Typed('#animatedText', {
  strings: 
    ['Hello Hello Hello',  'World World World', 'Goodbye Goodbye Goodbye'],
  showCursor: false
});
<script src="https://cdn.jsdelivr/npm/typed.js"></script>

<div id="animatedText"></div>

Deleting typed::after from css will help.

.typed::after {
    content: '|';
    display: inline;
    -webkit-animation: blink 0.7s infinite;
    -moz-animation: blink 0.7s infinite;
    animation: blink 0.7s infinite;
}

You can try it here.

发布评论

评论列表(0)

  1. 暂无评论