Skip to content

Can't use inherit value anymore since 0.8.0 #2741

@marcbelletre

Description

@marcbelletre

This is about Bulma.

Overview of the problem

This is about the Bulma CSS framework

I'm using Bulma version [0.8.0]

This is a Sass issue: I'm using version [0.8.0]

Description

Before version 0.8.0, we were able to use inherit values for colors. I used to override $text-strong variable so it takes an inherited color instead of a hardcoded one.

$text-strong: inherit

Since 0.8.0, using inherit value for this particular variable throws the following error when compiling with Sass:

ERROR in ./resources/sass/app.scss
Module build failed (from ./node_modules/css-loader/index.js):
ModuleBuildError: Module build failed (from ./node_modules/sass-loader/dist/cjs.js):

$input-placeholder-color: rgba($input-color, 0.3) !default
                         ^
      $color: inherit is not a color.
  ╷
6 │ $input-placeholder-color: rgba($input-color, 0.3) !default
  │                           ^^^^^^^^^^^^^^^^^^^^^^^
  ╵
  node_modules/bulma/sass/form/shared.sass 6:27  @import
  node_modules/bulma/sass/form/_all.sass 3:9     @import
  node_modules/bulma/bulma.sass 6:9              @import
  stdin 9:9                                      root stylesheet

I rolled back to Bulma 0.7.5 and Sass compiles without throwing any error.

An issue has been posted about this more than two years ago. @wrabit suggested to use inherit as a workaround but this is not working anymore. #821 (comment)

Steps to Reproduce

  1. Override $text-strong variable with the value inherit
  2. Compile with Sass

Expected behavior

We should be able to use inherit values without Sass throwing an error.

Actual behavior

Sass throws an error when compiling.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions