6.1 KiB
defaults
Defaults & options
Returns object Typed defaults & options
strings
Properties
typeSpeed
Properties
typeSpeed
number type speed in milliseconds
startDelay
Properties
startDelay
number time before typing starts in milliseconds
backSpeed
Properties
backSpeed
number backspacing speed in milliseconds
smartBackspace
Properties
smartBackspace
boolean only backspace what doesn't match the previous string
shuffle
Properties
shuffle
boolean shuffle the strings
backDelay
Properties
backDelay
number time before backspacing in milliseconds
fadeOut
Properties
fadeOut
boolean Fade out instead of backspacefadeOutClass
string css class for fade animationfadeOutDelay
boolean Fade out delay in milliseconds
loop
Properties
showCursor
Properties
showCursor
boolean show cursorcursorChar
string character for cursorautoInsertCss
boolean insert CSS for cursor and fadeOut into HTML <head>
attr
Properties
attr
string attribute for typing Ex: input placeholder, value, or just HTML text
bindInputFocusEvents
Properties
bindInputFocusEvents
boolean bind to focus and blur if el is text input
contentType
Properties
contentType
string 'html' or 'null' for plaintext
onComplete
All typing is complete
Parameters
self
Typed
preStringTyped
Before each string is typed
Parameters
onStringTyped
After each string is typed
Parameters
onLastStringBackspaced
During looping, after last string is typed
Parameters
self
Typed
onTypingPaused
Typing has been stopped
Parameters
onTypingResumed
Typing has been started after being stopped
Parameters
onReset
After reset
Parameters
self
Typed
onStop
After stop
Parameters
onStart
After start
Parameters
onDestroy
After destroy
Parameters
self
Typed
HTMLParser
TODO: These methods can probably be combined somehow Parse HTML tags & HTML Characters
Initializer
Initialize the Typed object
Typed
Welcome to Typed.js!
Parameters
Returns object a new Typed object
toggle
Toggle start() and stop() of the Typed instance
stop
Stop typing / backspacing and enable cursor blinking
start
Start typing / backspacing after being stopped
destroy
Destroy this instance of Typed
reset
Reset Typed and optionally restarts
Parameters
restart
boolean?= nser