0
Welcome Guest! Login
0 items Join Now

Adding custom less files

  • Adding custom less files

    Posted 9 years 9 months ago
    • Searched for this and couldn't find anything, sorry if this has already been answered.

      The very bottom of docs.gantry.org/gantry4/advanced/less-css seems to imply that I can create a file with a name like my-custom.less in the {theme name}/less directory, and it will automagically get picked up by the less compiler and included in the compiled .css files in the css-compiled directory. So I created a test .less file (rpr-custom.less), went into the Gantry Advanced menu from the dashboard and cleared the cache, and revisited the site. The timestamps on the files in the css-compiled director are updated, so I believe they were regenerated, but the styles from rpr-custom.less are nowhere to be found.

      Is this actually supposed to work? Am I missing a step somewhere? Or is this just a Joomla feature that isn't supposed to work in the WordPress version?

      I realize I can add custom css in the Style tab of my theme settings, but I'd prefer to do this in a file I can edit with a real editor.

      Thanks,

      -Rob

      Edit: apparently the filename has to be associated with one of the filenames already present. So template-custom.less gets found, but rpr-custom.less does not. Go figure.
    • Last Edit: 9 years 9 months ago by Robert Reichel.
    • Matt's Avatar
    • Matt
    • Preeminent Rocketeer
    • Posts: 22268
    • Thanks: 3224
    • messin' with stuff

    Re: Adding custom less files

    Posted 9 years 9 months ago
    • yup... there are a few different conventions that will get picked up

      template_name-custom.less
      master*.less

      per browser stuff:

      docs.gantry.org/gantry4/advanced/per-browser-control

      :)
    • SEARCH the forum first! These boards are rich in knowledge and vast in topics. This includes searching just the 'Solved' forums, using Google, and using ChatGPT :woohoo:

Time to create page: 0.075 seconds