Not exactly Steve, I wanted to ad a :hover effect ; when the mouse
gets over the unfolded element, the title would become red in your
example.

On 6 juin, 19:06, "Steve Onnis" <[email protected]> wrote:
> I think this is what you are trying to do
>
> http://mootools.net/shell/CB5hg/
>
> -----Original Message-----
> From: Simon Vart [mailto:[email protected]]
> Sent: Monday, 7 June 2010 2:30 AM
> To: MooTools Users
> Subject: [Moo] Re: Simple question about accordion
>
> I had find a way, using some script to tween the color of the element
> with mouseenter and mouseleave, but it make the onActive and
> onBackground useless.
>
> In fact, I coud use the CSS :hover pseudo-class, if i'm not applying
> it to the same tag and element than the accordion event. I tried to
> change the color of the text with the onActive and onBackground AND
> with the CSS : not working.
>
> So i just change the logic :
>
> In my case, I let the onActive and onBackground changing the color of
> the text (so i could mark visually the opened element of the
> accordion) ; and I'm changing the color of the border and the pointer
> of the mouse with the css class (makes people understand they could
> click there) ; works perfectly.
>
> But I wanted to know the logic of this behavior and thank you for
> responding.
>
> On 6 juin, 18:15, Oskar Krawczyk <[email protected]> wrote:
> > It's adding an inline-style to the element - there's no way to alter a
> pseudo-class inside an inline-stype attribute.
>
> > Create a test-case on jsfiddle.net, and we'll try to help out.
>
> > Oskar
>
> > On 6 Jun 2010, at 16:58, Simon Vart wrote:
>
> > > Hi,
>
> > > I have just a simple question about accordion, i didn't find the
> > > answer.
>
> > > When I use the onActive and onBackground events, which works
> > > absolutely fine. I just noticed that the pseudo-class :hover I'm using
> > > on the css doesn't work anymore ; I believe this is because I change
> > > the text color wit hthe onBackground event, so the color is now fixed
> > > in a javascript way, which takes precedence on css.
>
> > > Is this correct, is there a way to make css pseudo-class :hover
> > > working ?
>
> > > (anyway, i could use some javascript to create the hover effect, but
> > > it would save some lines of code)

Reply via email to