do not render typing animation at all if not typing
parent
01ff290f85
commit
c58312e853
@ -1,40 +1,29 @@
|
|||||||
import React from 'react';
|
import React from 'react';
|
||||||
import classNames from 'classnames';
|
import classNames from 'classnames';
|
||||||
|
|
||||||
interface Props {
|
export const TypingAnimation = () => {
|
||||||
color?: string;
|
return (
|
||||||
}
|
<div className="module-typing-animation" title={window.i18n('typingAlt')}>
|
||||||
|
<div
|
||||||
export class TypingAnimation extends React.Component<Props> {
|
className={classNames(
|
||||||
public render() {
|
'module-typing-animation__dot',
|
||||||
const { color } = this.props;
|
'module-typing-animation__dot--first'
|
||||||
|
)}
|
||||||
return (
|
/>
|
||||||
<div className="module-typing-animation" title={window.i18n('typingAlt')}>
|
<div className="module-typing-animation__spacer" />
|
||||||
<div
|
<div
|
||||||
className={classNames(
|
className={classNames(
|
||||||
'module-typing-animation__dot',
|
'module-typing-animation__dot',
|
||||||
'module-typing-animation__dot--first',
|
'module-typing-animation__dot--second'
|
||||||
color ? `module-typing-animation__dot--${color}` : null
|
)}
|
||||||
)}
|
/>
|
||||||
/>
|
<div className="module-typing-animation__spacer" />
|
||||||
<div className="module-typing-animation__spacer" />
|
<div
|
||||||
<div
|
className={classNames(
|
||||||
className={classNames(
|
'module-typing-animation__dot',
|
||||||
'module-typing-animation__dot',
|
'module-typing-animation__dot--third'
|
||||||
'module-typing-animation__dot--second',
|
)}
|
||||||
color ? `module-typing-animation__dot--${color}` : null
|
/>
|
||||||
)}
|
</div>
|
||||||
/>
|
);
|
||||||
<div className="module-typing-animation__spacer" />
|
};
|
||||||
<div
|
|
||||||
className={classNames(
|
|
||||||
'module-typing-animation__dot',
|
|
||||||
'module-typing-animation__dot--third',
|
|
||||||
color ? `module-typing-animation__dot--${color}` : null
|
|
||||||
)}
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
Loading…
Reference in New Issue