1. #1
    Sencha User
    Join Date
    Aug 2011
    Posts
    62
    Vote Rating
    0
    slmd is on a distinguished road

      0  

    Default Override element CSS style

    Override element CSS style


    Hi all,

    My question is, how can i override an element CSS property so it fits my needs?

    Explanation :
    I have a list item in a tabpanel and and a toolbar that's docked at the top of the page with an absolute position by default. I've changed that position to initial so my list item will be able to scroll behind the toolbar. The reason why i want to do that is because i have an image as a toolbar that contains a transparent background.
    This said, after having changed my toolbar position from absolute to initial, my list scrolls well behind my toolbar but there is a space between my list item and my tabbar that i can't get ride of and which the height corresponds to my toolbar height.
    I've noticed that when i set the CSS top property of the corresponding panel to zero and set the height at 100% within the "element.style" area of the console panel everything is fine. But i can't override that property in my CSS.

    Thank you!

  2. #2
    Sencha User
    Join Date
    Nov 2010
    Posts
    118
    Vote Rating
    9
    Bunchofstring will become famous soon enough

      0  

    Default Important

    Important


    Try this: after the style, add "!important" without quotes as in...
    body{color:red !important}

    You can add the style directives within your JavaScript code most of the time, so I'd try that if you're just trying to make a one-off change.

  3. #3
    Sencha User
    Join Date
    Aug 2011
    Posts
    62
    Vote Rating
    0
    slmd is on a distinguished road

      0  

    Default


    Thank you! It worked out great

Thread Participants: 1

Tags for this Thread