Forums

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

Home Forums CSS Firefox won't transition body background

  • This topic is empty.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #149441
    SilverSerpent
    Participant

    On my site I am working on I have the background set to transition when the page is scrolled more than 150px. In Chrome, the background nicely fades to the other. However, in Firefox (23), there is no smooth transition; the image jarringly changes. I know this can’t be a prefix problem because Firefox has used the unprefixed version of transition since version 16, and I’m using prefix-free so that shouldn’t matter anyways. Should this feature be supported in Firefox? And if so, does anybody know why this isn’t working?

    #149451
    SilverSerpent
    Participant

    Here is a reduced test case that works fine in Chrome but not in Firefox

    #149477
    Paulie_D
    Member

    Only think I can think of is that FF might require you to transition the longhand version…so

    transition: background-image 
    

    rather than

    transition:background
    
    #149534
    SilverSerpent
    Participant

    Thanks for the response, but that didn’t work. After doing a little more research, I’ve found this thread in which Paul Irish says Firefox can’t transition background-image. Seems like something they should implement.

    Edit: I have also tried using an element with fixed position set to cover the whole screen, then animating the opacity of that to achieve the fade effect, but what happens is it stays fixed until the page reaches the scrolling threshold where the fade happens, then during the fade it snaps to a different position. Then the body is in a different position as well, and after a moment it snaps to the correct place.

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