Keyframes

1import React from 'react';
2import { styled, Global, keyframes } from '@filbert-js/core';
3
4// Create the keyframes
5const rotate = keyframes`
6 from {
7 transform: rotate(0deg);
8 }
9 to {
10 transform: rotate(360deg);
11 }
12`;
13/** Will rotate everything we pass in over one seconds */
14const Rotate = styled('span')`
15 display: flex;
16 justify-content: center;
17 font-size: 1.5rem;
18 animation: ${rotate} 1s linear infinite;
19`;
20
21render(
22 <Rotate role="img" aria-label="star">
23
24 </Rotate>,
25);