html, body {
width: 100vw;
height: 100vh;
overflow: hidden;
}
.untitled {
position: absolute;
height: 100%;
width: 100%;
-webkit-animation: rotateHue infinite 20s linear;
animation: rotateHue infinite 20s linear;
-webkit-animation-delay: 0.625s;
animation-delay: 0.625s;
}
@-webkit-keyframes rotateHue {
0% {
-webkit-filter: hue-rotate(0deg);
filter: hue-rotate(0deg);
}
20% {
-webkit-filter: hue-rotate(0deg);
filter: hue-rotate(0deg);
}
25% {
-webkit-filter: hue-rotate(90deg);
filter: hue-rotate(90deg);
}
45% {
-webkit-filter: hue-rotate(90deg);
filter: hue-rotate(90deg);
}
50% {
-webkit-filter: hue-rotate(180deg);
filter: hue-rotate(180deg);
}
70% {
-webkit-filter: hue-rotate(180deg);
filter: hue-rotate(180deg);
}
75% {
-webkit-filter: hue-rotate(270deg);
filter: hue-rotate(270deg);
}
95% {
-webkit-filter: hue-rotate(270deg);
filter: hue-rotate(270deg);
}
100% {
-webkit-filter: hue-rotate(360deg);
filter: hue-rotate(360deg);
}
}
@keyframes rotateHue {
0% {
-webkit-filter: hue-rotate(0deg);
filter: hue-rotate(0deg);
}
20% {
-webkit-filter: hue-rotate(0deg);
filter: hue-rotate(0deg);
}
25% {
-webkit-filter: hue-rotate(90deg);
filter: hue-rotate(90deg);
}
45% {
-webkit-filter: hue-rotate(90deg);
filter: hue-rotate(90deg);
}
50% {
-webkit-filter: hue-rotate(180deg);
filter: hue-rotate(180deg);
}
70% {
-webkit-filter: hue-rotate(180deg);
filter: hue-rotate(180deg);
}
75% {
-webkit-filter: hue-rotate(270deg);
filter: hue-rotate(270deg);
}
95% {
-webkit-filter: hue-rotate(270deg);
filter: hue-rotate(270deg);
}
100% {
-webkit-filter: hue-rotate(360deg);
filter: hue-rotate(360deg);
}
}
const Untitled = styled.div`
position: absolute;
height: 100%;
width: 100%;
-webkit-animation: rotateHue infinite 20s linear;
animation: rotateHue infinite 20s linear;
-webkit-animation-delay: 0.625s;
animation-delay: 0.625s;`
;
<div className={className}>
<div className="sample-class">
</div>
</div>
const Untitled = styled.div`
position: absolute;
height: 100%;
width: 100%;
-webkit-animation: rotateHue infinite 20s linear;
animation: rotateHue infinite 20s linear;
-webkit-animation-delay: 0.625s;
animation-delay: 0.625s;
.sample-class {
color: red;
&:hover {
color: green;
}
}`
;
const { createGlobalStyle } from 'styled-components';
const GlobalStyle = createGlobalStyle`
html {
width: 100%;
}
`
export default GlobalStyle;
import GlobalStyle from '../path/global-style';
function App*() {
return (
<div>
<div>your app content</div>
<GlobalStyle />
</div>
)
}