BuddyDev

Search

[Resolved] Community theme – how to override default.css

  • Participant
    Level: Master
    Posts: 152
    Hugo Callens on #32720

    I created a child theme of the Community theme and would like to change the css, in order to keep the aspect ratio of the page header in all screen sizes.

    This works well when I replace the .page-header property

    background: fixed center center/cover no-repeat;

    with

    background: center/cover no-repeat;

    in /assets/css/default.css.

    I just don’t find a way to override this setting in my child theme; I’d rather not change the code of my parent theme. Adding a modified /assets/css/default.css to my child the folder doesn’t seem to work.

    Can you help?

  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #32723

    Hi Hugo,
    Are you using one of our child themes? If yes, Please put the code in your-child-theme/assets/css/custom.css

    If you are not using our child theme, Please check which css file it is loading, and add there.

    we do not allow override of default.css file as it contains the whole layout. All you need is to override a single selector/rule in your child theme and you can do it by adding the selector/rule to your child theme’s css file.

    Regards
    Brajesh

  • Participant
    Level: Master
    Posts: 152
    Hugo Callens on #32725

    Thank you for your reply.
    Which child themes are you referring to?
    I created a child theme of my own. Can i add a /assets/css/custom.css there?

  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #32735

    Hi Hugo,
    Community Builder does not load css files from child.

    If you have created a child theme, I assume, you are already loading some css file in the child theme? You can put the custom css there.

    PS:- I was referring to our ready to use child theme(community-builder-child) that comes with Community Builder Pro.

    Regards
    Brajesh

  • Participant
    Level: Master
    Posts: 152
    Hugo Callens on #32766
    This reply has been marked as private.
  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #32770
    This reply has been marked as private.
  • Participant
    Level: Master
    Posts: 152
    Hugo Callens on #32914
    This reply has been marked as private.
  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #33086
    This reply has been marked as private.

You must be logged in to reply to this topic.

This topic is: resolved