Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS hoverflow/jquery animation question

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #31751
    shavenraver
    Member

    I’m trying to get my sprite to animate a move left on hover, whilst text that overlays that image to go right

    So far, I can only target the “a” tag, and the child “p” moves with it

    My Markup

    My js function works to send both in the same direction

    $(function() {

    $("nav.mainNav a").hover(function(e) {

    $(this)
    .hoverFlow(e.type, { opacity: 1, left:'-2%'}, 500)
    .css('overflow', 'visible')

    }, function(e) {

    $(this)
    .hoverFlow(e.type, { opacity: 0.7, left: '0%'}, 500)
    .css('overflow', 'visible')

    });

    })

    Am I barking up the wrong tree in trying to get this

    tag to shift?

    #58685
    shavenraver
    Member

    ok – fixed it by adding ‘padding-left’

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘CSS’ is closed to new topics and replies.