I came through this kind of animation while working on Asana, I am trying to implement it in my Angular 6 project, but still don't have an idea, how can I proceed in implementing this kind of animation?
Initially, step is to fill the div with different colors as shown in gif. This is what I have tried till so far.
@Component({
selector: '',
templateUrl: '',
styleUrls: [''],
animations: [
trigger('fadeInOut', [
transition(':enter', [
style({ opacity: 0 }),
animate(700, style({ opacity: 1, background: ' linear-gradient(to bottom left, rgb(123, 98, 221), rgb(37, 77, 180))' }))
]),
transition(':leave', [
animate(1000, style({ opacity: 0 }))
])
])
]
})
<div class="" [@fadeInOut] *ngIf = 'showFeedback'>
<p>Create</p>
</div>
Currently this is how it looks for me.