Skip to content

undefined variable compiling core.scss #278

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
jamesbirtles opened this issue Apr 8, 2016 · 4 comments
Closed

undefined variable compiling core.scss #278

jamesbirtles opened this issue Apr 8, 2016 · 4 comments

Comments

@jamesbirtles
Copy link

When compiling core.scss from the core package to use the elevation classes, it complains about an undefined variable $md-fast-out-slow-in-timing-function. It looks to me like core.scss or _elevation.scss should be importing _variables.scss but isn't.

@jelbourn
Copy link
Member

Fixed in #293

@shotleybuilder
Copy link

Is this error back or is it my compile ...?

Scss compiler error: Undefined variable: "$md-fast-out-slow-in-timing-function".

My main.scss

@import "../../node_modules/@angular2-material/core/style/core.scss";
@import "../../node_modules/@angular2-material/button/button.scss";
@import "../../node_modules/@angular2-material/input/input.scss";
@import "../../node_modules/@angular2-material/checkbox/checkbox.scss";

I've manually patched like this
example checkbox.scss

@import '../core/style/default-theme';
@import '../core/style/theme-functions';
@import '../core/style/variables';
@import '../core/style/mixins';

Because of #887

@shotleybuilder
Copy link

shotleybuilder commented Jul 30, 2016

Fixed by changing core.scss from

@import 'elevation';
@import 'variables';

to

@import 'variables.scss';
@import 'elevation.scss';

The order matters.

Then complained about the $md-light-theme-background' variable being undefined

Simply added .scss extension to the imports in _default-them.scss.

All now compiles.

andrewseguin pushed a commit to andrewseguin/components that referenced this issue Oct 15, 2018
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants