material icon indicating copy to clipboard operation
material copied to clipboard

scss bower-material support

Open itajaja opened this issue 11 years ago • 18 comments

I am using bower-material, Is there a way to provide the sass files along with the compiled css?

itajaja avatar Jan 11 '15 23:01 itajaja

We would love that too! Looking forward to it, as we prefer scss over the already compiled css.

bogdandjukic avatar Jan 23 '15 09:01 bogdandjukic

Duplicate of #381

PaulMougel avatar Jan 23 '15 11:01 PaulMougel

#381 has been closed but I believe there are valid use cases for this request.

It is my understanding that the source repository is meant to be used by whoever wants to develop angular-material and the deployment repository is for developers that use angular-material in their own projects.

If that's the case, I would argue that there are valid uses cases for exposing the SCSS in the project builds repository. In these cases the developer doesn't want to mess with the original angular-material css but rather use the SCSS as a library to build his own classes. For instance I might want to access the SCSS variables, or use the handy mixins to build more *-sm *-gt classes.

I personally see the SCSS as being integral part of the library exposed to the developers rather than purely part of the library sources.

bonzanni avatar Feb 26 '15 09:02 bonzanni

an example of something similar is done in this repo for bootswatch. The use cases for this are several, of course the most important is building additional element that leverage existing mixins. Exposing just the core/style folder would be already a big improvement. Another use case would be to intercept and modify the variables before they are used in the material style sheets, or simply using the variables in your own style sheets.

itajaja avatar Feb 26 '15 09:02 itajaja

+1

paramburu avatar Mar 04 '15 20:03 paramburu

@rschmukler should chime in on this, but I believe the reason CSS is provided in a compiled format is due to theming support, where theme CSS is generated dynamically.

marcysutton avatar Mar 13 '15 00:03 marcysutton

+1

pzurowski avatar Mar 16 '15 09:03 pzurowski

+1

johannesjo avatar Apr 05 '15 18:04 johannesjo

For those interested I extracted the styles and put them into their own repository: https://github.com/johannesjo/angular-material-sass-files

johannesjo avatar Apr 05 '15 19:04 johannesjo

@johannesjo how will that be sustainable? It looks like there are specific filenames referenced in your shell script and not all of them are present (ex. typography.scss). Also, what about the themes scss?

marcysutton avatar Apr 05 '15 19:04 marcysutton

@marcysutton the colors would have to be replaced with sass-variables/functions. Still working on it. Thank you for reporting the issue, but maybe the repos page is a better place for this. I'm glad for help and suggestions.

johannesjo avatar Apr 05 '15 20:04 johannesjo

:+1: I am also lost on how to properly use the .scss files. There is the Gulp build process but that seems overkill for this use case. Looking forward to seeing how this one pans out :)

oste avatar Apr 05 '15 20:04 oste

+1

tkrotoff avatar Apr 14 '15 09:04 tkrotoff

this would be great

stryju avatar Jul 15 '15 12:07 stryju

Each build of Angular Material now [also] deploys angular-material.scss; with required mixins and variables.

  • This resource was deployed for developers wanting the SCSS master file.
  • The AM team will not document how to compile or use this file, etc.

ThomasBurleson avatar Jul 15 '15 14:07 ThomasBurleson

woohoo! :confetti_ball:


also, +1 point for using !default :ok_hand:

stryju avatar Jul 15 '15 14:07 stryju

This is great! Thanks.

breity avatar Jul 21 '15 18:07 breity

:tada: thanks!

itajaja avatar Jul 21 '15 18:07 itajaja