Picture of 360 elearning
Adapt.less compilataion
by 360 elearning - Tuesday, 24 February 2015, 12:50 PM
 

Hi everyone.

I am new to adapt elearning framework. When I make some chance to adapt.less file, and the run the command

$ grunt build, the change are not there in adapt.css  which resides in build version.

And after running the command $ grunt build, the adapt.less file come to its orignal state(my changes gone)

 

What is the problem? is there anyone to help me in this problem

Thanks in advance.

 

Regards

Picture of Matt Leathes
Re: Adapt.less compilataion
by Matt Leathes - Tuesday, 24 February 2015, 3:58 PM
 

the answer is simple: you shouldn't be changing the adapt.less file - this file is used by the grunt build process so any changes you make to it will be overwritten.

there's a guide to styling Adapt here: https://github.com/adaptlearning/adapt_framework/wiki/Styling-your-course

Picture of 360 elearning
Re: Adapt.less compilataion
by 360 elearning - Wednesday, 25 February 2015, 6:09 AM
 

Matt Leathes 

Thank you very much sir for you quick and effective response. will get more information about adapt framework in future

 

Regards

Picture of Kevin Lilienthal
Re: Adapt.less compilataion
by Kevin Lilienthal - Tuesday, 24 February 2015, 4:02 PM
 

Greetings and welcome to Adapt,

It sounds like you are trying to make changes to src/less/Adapt.less . This is an auto-generated file, which explains the missing changes. If you would like to make changes to the look/feel of your project, you will want to make these changes to your theme instead.

If you are using the vanilla theme, try going into src/theme/adapt-contrib-vanilla/less/  you can make changes to this as much as you like. If you're  concerned about making changes, I always save a backup, so I can see what the original looked like. Many of the colors can be updated in "variables.less" . If you don't want to rebuild every time, you can open a new terminal window, cd into your root directory, and type  "grunt watch". This will auto-compile for you every time you make a change.

Hope this helps

Picture of 360 elearning
Re: Adapt.less compilataion
by 360 elearning - Wednesday, 25 February 2015, 6:11 AM
 

Kevin Lilienthal

I am really thankful to you for details response, now I have cleared everything about less , and how make changes that will make affect on the build version.

Thank you so much

Regards:

Picture of 360 elearning
Re: Adapt.less compilataion
by 360 elearning - Monday, 2 March 2015, 4:37 AM
 

Respected Kevin Lilienthal 

As i am working with adapt framework to add make courses, I need to make some customization to its style.

 

Now what I need to add an new file called custom_style.less to themes less folder to override some specific styles. But I cannot under stand where to include its path?

 

Thanks in advance

 

Regards

Picture of Chuck Lorenz
Re: Adapt.less compilataion
by Chuck Lorenz - Monday, 2 March 2015, 3:26 PM
 

When you issue the grunt build command, Gruntfile.js processes various less files and outputs src/less/adapt.less. In turn, src/less/adapt.less is processed and becomes build/adapt/css/adapt.css. If you look through the tasks of Gruntfile.js, you may figure out ways to have a separate custom_style.less included during the build process. But until then, you may find it best to include your customizations in src/theme/adapt-contrib-vanilla/less/theme.less. You'll notice comments at the top that indicate this is the preferred place for bespoke/custom styles.