Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8944935
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T12:08:03+00:00 2026-06-15T12:08:03+00:00

I am having a small problem with css transitions. I am trying to make

  • 0

I am having a small problem with css transitions.

I am trying to make the background width animate on hover, and it does work however it is a bit jumpy.

My css code is

ul {
    list-style:none;
    margin: 0;
    padding:0;
}
ul li {
    margin-bottom: 8px;
    color:#999;  
}
ul li:hover  {
    color: #FFF;
    background-color: #f6634c;
    width: 200px;
   -webkit-transition: all 0.3s ease-out;
   -moz-transition: all 0.3s ease-out;
   -o-transition: all 0.3s ease-out;
   transition: all 0.3s ease-out;
}

The demo can be seen here http://codepen.io/anon/pen/IFbds

The reason it is jumpy is because I have not specified a width on the li, but if I do, the animating background will not start from the left. I want the width to animate at the start of the text.

Also it only animates when you hover near the start of the link.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T12:08:04+00:00Added an answer on June 15, 2026 at 12:08 pm

    Like this?

    ul {
        list-style:none;
        margin: 0;
        padding:0;
        overflow:hidden; /*to clear the floats*/
    }
    ul li {
        margin-bottom: 8px;
        color:#999;  
        min-width:0px; /*the property we are going to animate, set to specific value*/
        float:left; /*prevent display block from filling up all available width*/
        clear:left; /*prevent float left from putting blocks in-line*/
        display:block;/*cause width to be interpreted my way*/
    }
    ul li:hover  {
        color: #FFF;
        background-color: #f6634c;
        min-width: 200px; /*BOOM*/
        -webkit-transition: all 0.3s ease-out;
        -moz-transition: all 0.3s ease-out;
        -o-transition: all 0.3s ease-out;
        transition: all 0.3s ease-out;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Im having a small problem with my code. I have been trying to read
Having a small problem with css, new on this website and wondering if someone
Im having a small problem, I'm trying to create an inline editing system with
Im having a small problem with storage of special characters like quotes, double quotes
I am having a small problem with the Magento quick search. When I search
i am having a small problem with my android application. I have some mp3
I am having a small problem. I am a beginner to iPhone programming so
I'm having a small problem. I have this grid with a column: <data:DataGrid ColumnHeaderStyle={StaticResource
Using Apache POI to generate a document and i'm having a small problem with
I have a question about a small problem I am having in Magento. When

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.