הקוד הראשון זה קוד אם רוצים אנימציית ריחוף והקוד השני זה אנימציית סיבוב. המספרים 1 1 1 או 0 0 0
מייצגים את הצירים. ציר שנרצה שיסתובב סביבו נסמן ב 1
selector {
animation: float infinite alternate 3s ease-in-out;
}
@keyframes float {
100% {
translate: 0 5px;
}
}
Code language: CSS (css)
selector {
animation: floater infinite 3s ease-in-out;
}
@keyframes floater {
100% {
rotate: 0 1 0 360deg;
}
}
Code language: CSS (css)