Skip to content
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

Custom theme #459

Open
loo41 opened this issue May 12, 2021 · 1 comment
Open

Custom theme #459

loo41 opened this issue May 12, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@loo41
Copy link
Contributor

loo41 commented May 12, 2021

$cursor-url: url(get-file-as-data-uri("../assets/cursor.png")) !default;

Describe the bug

When I try to use a custom theme

To Reproduce

// xx.scss
$primary-colors: (
  normal: red,
  hover: red,
  shadow: red,
) !default;

@import "nes.css/scss/nes.scss";

截屏2021-05-12 下午11 19 12

Expected behavior

When I remove this

截屏2021-05-12 下午11 20 41

Environment:

Suggestion(s) for fixing this issue
In my opinion, should we not rely on the JS transformation Base64, but use the transformation directly?,Is it possible to provide the ability to customize the theme。

Additional context
In the component library I'm developing, I'm trying to provide a set of custom themes

@guastallaigor guastallaigor added the bug Something isn't working label May 14, 2021
@ZOUHEIRBN
Copy link

ZOUHEIRBN commented Jan 28, 2023

Same issue, I'm trying to alter the success color to a brighter green but to no avail. When I import variables like this:
@import "node_modules/nes.css/scss/base/variables";
it gives me this error in compilation:

HookWebpackError: Module build failed (from ./node_modules/sass-loader/dist/cjs.js):
SassError: Undefined variable.
  ╷
5 │ $base-color: $color-black !default;
  │              ^^^^^^^^^^^^
  ╵
  node_modules\nes.css\scss\base\variables.scss 5:14  @import
  src\styles.scss 3:9                                 root stylesheet



× Failed to compile.```

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants