1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Disable Styles Via Admin

Discussion in 'XenForo Questions and Support' started by Dan Allen, Aug 26, 2015.

  1. Dan Allen

    Dan Allen Active Member

    How can the generation styles through admin be disabled?

    Reason
    I don't like the relationships enforced among elements in the styles generated through admin. For instance, I need to change the forum names from red to black, and it is a big hassle. Another hassle is I don't want predefined color palette elements tied to screen elements. If there are three screen elements colored @primarylighter, I want to be able to change that without learning this system of styling. I already know a goo system for styling (css). This system has constraints I don't want.



    upload_2015-8-26_9-6-22.png

    upload_2015-8-26_9-8-24.png

    upload_2015-8-26_9-17-37.png
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    Edit the css templates directly if that's how you prefer to do it.

    You don't have to use the Style Properties.

    This set of guides should help: How To...
     
    Dan Allen likes this.
  3. pegasus

    pegasus Well-Known Member

    You can edit the CSS templates directly. Instead of "Style Properties", go to the "Templates" admin page, and search for the CSS file you need to change. Then modify it to remove those "constraints" that are giving you a headache.
     
    Dan Allen likes this.
  4. Dan Allen

    Dan Allen Active Member

    I thought changes to the style sheets would be overidden when templates are recalculated or upgrades installed. If that false?

    Yea the the relationships that I call constraining, is there something about them I an overlooking?
     
  5. Dan Allen

    Dan Allen Active Member

    Thank you Brogan, huge help
     
  6. Dan Allen

    Dan Allen Active Member

    I bet there is a better solution than what I was asking about earlier?

    Let's say there was a good reason to make the two items marked in this picture have different colors. What would be the best way to do that in XF?

    upload_2015-8-27_0-24-25.png
     
  7. Mike

    Mike XenForo Developer Staff Member

    In the end, it's just HTML and CSS so you would need to approach it in whatever your "standard" way is. You'd probably identify the link you want to change in the HTML, apply an extra class to it and then add CSS to change it the way you want.
     
  8. Arty

    Arty Well-Known Member

    You'll need to add individual rules for those links, like this:
    Code:
    .navTabs .navTab.selected .tabLinks a[href="watched/forums"] { color: white; }
    .navTabs .navTab.selected .tabLinks a[href="watched/threads"] { color: red; }
     
  9. Dan Allen

    Dan Allen Active Member

    Where do those rules get entered? I am looking at this:

    upload_2015-8-27_16-13-54.png
     
  10. Arty

    Arty Well-Known Member

    Click "Templates" link on left, find "EXTRA.css" and edit it. All custom CSS should go there.
     
    Dan Allen likes this.
  11. Dan Allen

    Dan Allen Active Member

    Brilliant! Thank you.
     
  12. Dan Allen

    Dan Allen Active Member

    Is the an easy way to find which template is the one that has the element I need to add a class to? Not for this example, but in general. That is my biggest problem with the templates: finding the one with the element I need edit.
     
  13. Brogan

    Brogan XenForo Moderator Staff Member

    This set of guides should help: How To...
     
    Dan Allen likes this.

Share This Page