Problem/Motivation

In theme-options.yml file we only have access to built-in SASS functions. Currently, we are not able to load and use custom functions in theme yaml files.

Proposed resolution

If the theme is defining sass/_functions.scss file load it automatically on the start of the gulp sass and sass:dev tasks so it is available everywhere, including theme-options.yml.

Remaining tasks

- Update documentation with this new feature.

Comments

pivica created an issue. See original summary.

pivica’s picture

Issue summary: View changes
pivica’s picture

StatusFileSize
new10.11 KB

The first patch, adds two new packages through2 for injecting functions into the gulp stream and gulp-debug for some debug info.

More testing is needed.

pivica’s picture

Title: Support sass/_functions.scss which are available in theme-options.ym » Support sass/_functions.scss which are available in theme-options.yml
pivica’s picture

StatusFileSize
new10.18 KB

Forgot to add some stuff to the previous patch.

pivica’s picture

StatusFileSize
new17.6 KB

Updated bs_bootstrap, some small fixes in a generator.

pivica’s picture

And here is a composer friendly patch against alpha7 release.

pivica’s picture

Status: Active » Needs review
Issue tags: +next-release
pivica’s picture

StatusFileSize
new17.73 KB
new17.82 KB

We should also check the current theme for sass/_functions.scss.

pivica’s picture

StatusFileSize
new16.65 KB

An updated patch against latest dev version.

pivica’s picture

StatusFileSize
new16.71 KB

Messed up the previous patch a bit, here is a version that should work.

pivica’s picture

StatusFileSize
new16.69 KB

Actually i forgot to push one commit to 8.x-1.x branch when tagging alpha8...

Hopefully, now the patch is correct.

pivica’s picture

StatusFileSize
new17.17 KB
new2.36 KB

Cleaned the main gulp-tasks.js a bit.

  • pivica committed 410172b on 8.x-1.x
    Issue #3093783 by pivica: Support sass/_functions.scss which are...
pivica’s picture

Status: Needs review » Fixed
Issue tags: -next-release

Committed.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.