Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Autoscroll down angularjs

Hi I'm creating a chat app with angularjs that autoscrolls down when a user messages another user. I'm not sure how to implement this as my chat window is a fixed ul element. I'm thinking I will need to implement a directive to do this (inboxmsg-scroll on the ul element)

Any help? thanks.

HTML

<ul class="chatting-window" inboxmsg-scroll>
    <li data-ng-repeat="messageinfo in messages">
        <div class="message-date">
            {{messageinfo[0]}}
        </div>
    </li>
</ul>
like image 939
user1424508 Avatar asked Nov 09 '13 01:11

user1424508


1 Answers

angularjs-scroll-glue

An AngularJs directive that automatically scrolls to the bottom of an element on changes in it's scope.

Link: https://github.com/Luegg/angularjs-scroll-glue

like image 178
Răzvan Flavius Panda Avatar answered Sep 28 '22 10:09

Răzvan Flavius Panda