Currently in grunt/config/copy.js menuAssets dest is set to dest: '<%= outputdir %>assets/' this should be brough into line with menuFonts, themeFonts and themeAssets that all point to Adapt/css/[respective-folder]for example themeAssets has dest: '<%= outputdir %>adapt/css/assets/'
i think all of the asset folders should go to adapt/css/assets not just menu and theme.
it seems silly to have two asset folder locations as we do at the moment. one at build/assets and one at build/adapt/css/assets.
this would mean we could stop having to write LESS which back references the root assets folder such as:
.mejs-overlay-button {
background-image: url(../../assets/bigplay.svg);
}
we could instead use:
.mejs-overlay-button {
background-image: url(assets/bigplay.svg);
}
there isn't a proposal where we could change the location of this folder without breaking any existing plugins. except by duplicating the assets over both folders and making the build/assets folder redundant at the next major version.
Another (breaking change) approach could be to move adapt.css to the root. Seems very superfluous to have a CSS directory with only ever one CSS file.
I had a little more of a think around this...
Assuming that:
We could probably:
../../assets/ in the LESS source files by path../../assets/ to assets/that way all the existing code would keep working, people would get warned about deprecated code and we'd get the result we want.
any thoughts on this @ciaranlp ?
I like the idea of having all assets in one place and the css file moved to root
cool. we'd have to move the font and assets folders to root, but that's quite doable.
it would be easier in the first instance to unify them into adapt/css/assets, as fewer things have to change, but i'll happily unify them at /assets instead if we can all agree
any objections? @moloko @brian-learningpool @lc-thomasberger @tomgreenfield @taylortom @dancgray @danielstorey
When moving root/adapt/css/adapt.min.css to root/adapt.min.css
@ciaranlp can you have a look at the above pr? see if that helps.
don't install spoor to test, i haven't done a pr for the link tag change in spoor yet.
i've added a backward compatibility function to scriptLoader.js to deal with old css urls but i need to pr to spoor to fix the old urls.
Yes @oliverfoster will do
Ta man. Let me know if it's not suitable as a solution to your specific issue. I'm trying to solve your problem along with the outstanding double assets folder issue at the same time.
@oliverfoster all seems to be working dandy! +1
Prompts:

1 LESS file from prompt

Paths fixed after compilation

Thanks @nilslp - I'll fix it so it only outputs one error per file. That should be enough.
@nilslp can you approve the pr? > https://github.com/adaptlearning/adapt_framework/pull/1932