-
AuthorPosts
-
October 1, 2014 at 2:32 pm #201755
I have several custom animations that I want to add to the typography.less file.
It makes sense to me to keep them with the others rather than in my theme’s template.less file, but if I move typography.less to my theme folder, the front-end doesn’t seem to pick it up.
Would this be a case to put in the local folder? I don’t want the changes to get overwritten with any updates. What is the best approach?
jooservices Friendjooservices
- Join date:
- October 2014
- Posts:
- 8556
- Downloads:
- 0
- Uploads:
- 130
- Thanked:
- 1245 times in 1121 posts
October 1, 2014 at 3:09 pm #551367Hi there,
I would not prefer to modify less files.
Instead of that you can make your own custom.css and import it into template to use 🙂Thank you,
Viet Vujooservices Friendjooservices
- Join date:
- October 2014
- Posts:
- 8556
- Downloads:
- 0
- Uploads:
- 130
- Thanked:
- 1245 times in 1121 posts
October 1, 2014 at 3:11 pm #551368
<?php
// CUSTOM CSS
if (is_file(T3_TEMPLATE_PATH . '/css/custom.css')) {
$this->addStyleSheet(T3_TEMPLATE_URL . '/css/custom.css');
}
?>
custom.css will be automatic load if file is existed 🙂
Thank you,
Viet VuOctober 1, 2014 at 3:40 pm #551373I write all of my CSS in LESS, so have been using the template.less file in my theme folder. If need be, I can just add in a section there for the animations. Just looking for best practices.
TomC ModeratorTomC
- Join date:
- October 2014
- Posts:
- 14077
- Downloads:
- 58
- Uploads:
- 137
- Thanks:
- 948
- Thanked:
- 3155 times in 2495 posts
October 1, 2014 at 5:05 pm #551390<em>@vifadmin 448118 wrote:</em><blockquote>I write all of my CSS in LESS, so have been using the template.less file in my theme folder. If need be, I can just add in a section there for the animations. Just looking for best practices.</blockquote>
If you do all of yoru CSS modifications within the less files, there is a chance that your modifications could be overwritten upon updating/upgrading your core template files. This is the very reason why utilizing a custom.css file – or, for more recent templates, “local” file” is so advantageous.
By default, there should be one ‘custom.css’ file in /templates/purity_iii/css folder. However, if you want to customize one theme in this template and don’t want to loose these custom work when updating template, you can customize any theme via: /templates/purity_iii/local folder.
We’ve recently implemented a new feature in new version of T3 framework so that customer can add custom work in a folder which can’t be affected when updating template. You can check out this documentation for more information: http://t3-framework.org/documentation/new-features#isolate-template
jooservices Friendjooservices
- Join date:
- October 2014
- Posts:
- 8556
- Downloads:
- 0
- Uploads:
- 130
- Thanked:
- 1245 times in 1121 posts
October 2, 2014 at 7:54 am #551513Hi there,
Just wonder if you have managed your issue with TomC instruction ?
Please let me know, than we can help you .Thank you,
Viet VuOctober 2, 2014 at 1:46 pm #551548I believe so. I have started using the local directory according to the link TomC sent me. The priority of how folders are used was what cleared things up. I created a LESS folder in there and when I compile it, the CSS goes into the CSS folder inside local.
In prior versions of T3 I had setup a “vif” theme for our site and used Theme Magic to set the colors etc. But there is still some general confusion:
- Theme Magic makes a folder inside the <template name> less > themes > vif so I’m guessing Theme Magic would not be used if you intend to use the local folder.
- Still not sure about where images go. Any background images for my custom HTML modules go in the local/images folder? I managed to get one working by pathing up to the site’s root images folder but when inspecting the code in development mode, it indicates that the file is located in the local/images folder – which it is not.
- If I want to add my own js or other css, I typically add it in to the head.php file. However I am confused if I also need to add it to the assets.xml file. I did not know about that before and everything always worked.
Thanks for the assistance and for following up!
jooservices Friendjooservices
- Join date:
- October 2014
- Posts:
- 8556
- Downloads:
- 0
- Uploads:
- 130
- Thanked:
- 1245 times in 1121 posts
October 2, 2014 at 1:55 pm #551549Glad to hear that. For another issue please create another topic. It would help us easier to follow up with you.
Thank you,
Viet Vu -
AuthorPosts
This topic contains 8 replies, has 3 voices, and was last updated by jooservices 10 years, 3 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum