mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
* Added React Native Share Extension * Fixed Linting Issues Fixed linting issues, added tests. * Fixed other linting issues Data returns a promise. * Removed Public from state Removed public from state. * Added react-typing-animation Added react-typing-animation. * Updated react-typing-animation Updated the react-typing-animation definitions with the extra components such as delay, backspace.
43 lines
1.0 KiB
TypeScript
43 lines
1.0 KiB
TypeScript
import * as React from 'react';
|
|
|
|
import Typing from 'react-typing-animation';
|
|
|
|
const AnimatedTypingComponent = () => (
|
|
<Typing>
|
|
<span>This span will get typed.</span>
|
|
</Typing>
|
|
);
|
|
|
|
const AnimatedBackspaceComponent = () => (
|
|
<Typing>
|
|
<span>This span will get typed, then erased.</span>
|
|
<Typing.Backspace count={20} />
|
|
</Typing>
|
|
);
|
|
|
|
const AnimatedDelayComponent = () => (
|
|
<Typing>
|
|
<div>
|
|
There will be a 1000ms delay here,
|
|
<Typing.Delay ms={1000} />
|
|
then this will be typed.
|
|
</div>
|
|
</Typing>
|
|
);
|
|
|
|
const AnimatedSpeedComponent = () => (
|
|
<Typing speed={50}>
|
|
This line will be typed at 50ms/character,
|
|
<Typing.Speed ms={200} />
|
|
then this will be typed at 200ms/character.
|
|
</Typing>
|
|
);
|
|
|
|
const AnimatedResetComponent = () => (
|
|
<Typing>
|
|
<span>This line will stay.</span>
|
|
<span>This line will get instantly removed after a 500 ms delay</span>
|
|
<Typing.Reset count={1} delay={500} />
|
|
</Typing>
|
|
);
|