I've been searching for a way to create a smooth animation effect when a new element is added to a scrolling list.
For example, as a new element is added to the top of the list and older elements are pushed down, I want the transition to be visually pleasing. Specifically, I would like the "push" animation to be smooth and any overflowing elements should be blurred out below. How can this be accomplished?
CSS:
.transactions-list {
background-color: #eee;
padding-top:0rem;
width: 200px;
height: 100px;
border: 1px dotted black;
overflow: scroll; /* Add the ability to scroll */
-ms-overflow-style: none;
scrollbar-width: none;
border-radius: 1rem;
direction: ltr;
}
HTML:
<div class="transactions-list">
<p *ngFor="let element of transactions.slice().reverse()">{{element}}</p>
</div>