GithubHelp home page GithubHelp logo

Comments (4)

jelhan avatar jelhan commented on June 12, 2024

Did you double checked that you are using the same Bootstrap version before and afterwards? And the same version of Ember CLI SASS? Is the error getting away if you use Ember Bootstrap but continue to integrate Bootstrap SASS in the build manually?

from ember-bootstrap.

JackHowa avatar JackHowa commented on June 12, 2024

Thanks for responding @jelhan.

Did you double checked that you are using the same Bootstrap version before and afterwards?

I changed the variable overrides without upgrading or changing any dependencies. I'm not sure I follow but these are my dependency versions:

ember-ui % npm ls bootstrap
└── [email protected]
npm ls ember-bootstrap
─ [email protected]

And the same version of Ember CLI SASS?

I didn't change the dependency either. I only changed the override value to use a SassScript with a css variable inside.

ember-ui % npm ls ember-cli
├─┬ [email protected]
│ └── [email protected] deduped
└── [email protected] 

Is the error getting away if you use Ember Bootstrap but continue to integrate Bootstrap SASS in the build manually?

I'm not sure I follow. Can you explain how I would go about testing this? I'm updating the variable override in the bootstrap overrides file in one of the files that is manually updated in the app.scss.

<!-- index.html -->

<!-- toggle with media query -->
<style>
  --__color-text-primary: #00000;
</style>
// app.scss
// Define Bootstrap variables and override with css variables
@import 'variables';

// ember-bootstrap import
@import 'ember-bootstrap/bootstrap';
// _variables.scss
$black: #{var(--__color-text-primary)};

Investigating, this may be due to this instead https://stackoverflow.com/questions/61397995/css-variable-not-working-within-scss-when-i-use-var-and-rgba. No hex codes were used previously so I don't know why that would affect things rather than rgba


I also tried directly importing the css into the app.scss

// app.scss
// define css variables
@import 'definition-variables';

// Define Bootstrap variables and override with css variables
@import 'variables';

// ember-bootstrap import
@import 'ember-bootstrap/bootstrap';
// definition-variables.css
:root {
	--__color-text-primary: #00000;
}

from ember-bootstrap.

jelhan avatar jelhan commented on June 12, 2024

Got it. I thought it was an issue introduced by migrating to Ember Bootstrap.

The error tells you that it's not a valid color.

$black: #{var(--__color-text-primary)};

The # looks wrong to me. Could be caused by that. Or the Bootstrap utility does not support CSS custom properties. Support for those is still limited.

from ember-bootstrap.

jelhan avatar jelhan commented on June 12, 2024

Going to close this issue as it's not related to Ember Bootstrap. StackOverflow might a good place for this question.

from ember-bootstrap.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.