rails / sass-rails

Ruby on Rails stylesheet engine for Sass
MIT License
860 stars 333 forks source link

CSS-grid not supported. #395

Closed ycrepeau closed 7 years ago

ycrepeau commented 7 years ago

See: https://github.com/sass/sass/issues/2233

Summary: With the release of FF52 and GC57, CSS-grid layout is now supported. With this new feature, construct like grid-template-columns: repeat(5, 1fr) are present.

The CSS function 'repeat' is not really supported by SASS.

Solution: The last version of SASS (3.5) addresses the issue.

rafaelfranca commented 7 years ago

sass 3.5 is already supported by this gem https://github.com/rails/sass-rails/blob/v5.0.6/sass-rails.gemspec#L17, so why it is not supported?

ycrepeau commented 7 years ago

It works perfectly well in development mode.

It fails only in production environment with rake asset:precompile (aka heroku deploy).

rafaelfranca commented 7 years ago

If it works in development and not in production with the same set of gems I recommend you to report the issue to your production environment since it seems to be related with it.

sass-rails supports sass 3.5 and if it is fixed in sass 3.5 so you should be able to get it installed. If the issue is not fixed in sass 3.5, you should report the issue in the sass repository since sass-rails is just a wrapper around sass.

ycrepeau commented 7 years ago

I have the error locally when I run:

RAILS_ENV=production bundle exec rake assets:precompile

So, the problem starts here (locally) when I test my local environment in production mode.

rafaelfranca commented 7 years ago

Can you please provide a sample application that reproduces the error?

caiotarifa commented 7 years ago

@rafaelfranca, I'm having a similar error using @supports.

Just try:

.header {
  backdrop-filter: saturate(180%) blur(20px);
  background-color: rgba(#fff, 0.975);

  @supports (backdrop-filter: blur()) {
    background-color: rgba(#fff, 0.8);
  }
}

It works on development, but not in production.


The version of sass-rails is 5.0.6.

rafaelfranca commented 7 years ago

sass-rails doesn't defines the sass behavior, the gem responsible for this is sass, if it is working in development and not production either it is a problem in sass or the production envrionment.

jdolle commented 7 years ago

Sass added support https://github.com/sass/sass/issues/2233