mirror of
https://github.com/actualbudget/actual.git
synced 2026-03-09 03:32:54 -05:00
28 lines
660 B
TypeScript
28 lines
660 B
TypeScript
import React from 'react';
|
|
import type { SVGProps } from 'react';
|
|
|
|
import { css, keyframes } from '@emotion/css';
|
|
|
|
import { SvgLoading } from './Loading';
|
|
|
|
const rotation = keyframes({
|
|
'0%': { transform: 'rotate(-90deg)' },
|
|
'100%': { transform: 'rotate(666deg)' },
|
|
});
|
|
|
|
export function AnimatedLoading(props: SVGProps<SVGSVGElement>) {
|
|
return (
|
|
<span
|
|
className={css({
|
|
animationName: rotation,
|
|
animationDuration: '1.6s',
|
|
animationTimingFunction: 'cubic-bezier(0.17, 0.67, 0.83, 0.67)',
|
|
animationIterationCount: 'infinite',
|
|
lineHeight: 0,
|
|
})}
|
|
>
|
|
<SvgLoading {...props} />
|
|
</span>
|
|
);
|
|
}
|