I suggest that instead of trying to manupulate the DOM ourselves we can
probably give it to Angular using the *ng-class* directive and let it take
care of it.

*ng-class*

Conditionally applying classes to elements is another thing commonly done
manually using jQuery. Angular, of course, has a better way. You can give
ng-class a whitespace-separated set of class names, and then it's identical
to ordinary class. That's not very exciting, so there's a second syntax:

<div ng-class="{ errorClass: isError, warningClass: isWarning,
okClass: !isError && !isWarning }">...</div>



On Mon, Apr 1, 2013 at 9:51 AM, Bill Lazar <notifications@github.com> wrote:

> In app/views/shared/_hubModal.html.haml:
>
> >    .modal-header
> >      .pull-right= link_to raw('&times;'), '#', class: 'close', data: {dismiss: 'modal'}
> >      %h3 Create a new Group
> > +    .container(ng-class="alertclass")
>
> that's the answer then.
> … <#13dc6827a41ca667_>
> On Mon, Apr 1, 2013 at 9:50 AM, Kim Miller <notifications@github.com>
> wrote: In app/views/shared/_hubModal.html.haml: > .modal-header >
> .pull-right= link_to raw('&times;'), '#', class: 'close', data: {dismiss:
> 'modal'} > %h3 Create a new Group > + .container(ng-class="alertclass")
> Indeed, it appears to be gone, with just the one in the main page
> remaining. /k … <#13dc681a23ad139b_> On Apr 1, 2013, at 9:33 AM, Bill Lazar
> wrote: In app/views/shared/_hubModal.html.haml: > .modal-header >
> .pull-right= link_to raw('&times;'), '#', class: 'close', data: {dismiss:
> 'modal'} > %h3 Create a new Group > + .container(ng-class="alertclass") Not
> sure. After dismissing the first message, look at the DOM and see if the
> #alertContainer div is still there. … — Reply to this email directly or
> view it on GitHub. — Reply to this email directly or view it on GitHub<
> https://github.com/railsforcharity/spokenvote/pull/158/files#r3603594> .
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/railsforcharity/spokenvote/pull/158/files#r3603615>
> .
>