javascript - 我跟随文档自定义主题时使用弹性ui时遇到问题

标签 javascript reactjs elasticsearch sass elasticui

当我要自定义主题时,此失败显示。
有谁知道该如何解决?

我的项目Github链接是here

Failed to compile.

./src/themes/light/index.scss (./node_modules/css-loader/dist/cjs.js??ref--6-oneOf-5-1!./node_modules/postcss-loader/src??postcss!./node_modules/resolve-url-loader??ref--6-oneOf-5-3!./node_modules/sass-loader/dist/cjs.js??ref--6-oneOf-5-4!./src/themes/light/index.scss)
SassError: no mixin named euiScreenReaderOnly
        on line 3 of node_modules/@elastic/eui/src/components/accessibility/_screen_reader.scss
        from line 1 of node_modules/@elastic/eui/src/components/accessibility/_index.scss
        from line 4 of node_modules/@elastic/eui/src/components/index.scss
        from line 7 of /Users/austin/Documents/sideproject/eui-layout/src/themes/light/index.scss
>>   @include euiScreenReaderOnly;

   -----------^

最佳答案

订单需要正确且不起作用

@import错误'../../../node_modules/@elastic/eui/src/global_styling/ 函数 / index';

正确@import'../../../node_modules/@elastic/eui/src/global_styling/index.scss';

@import './color.scss';

$euiSize: 14px;
// Global styling
@import '../../../node_modules/@elastic/eui/src/global_styling/index.scss';

@import '../../../node_modules/@elastic/eui/src/components/index.scss'

关于javascript - 我跟随文档自定义主题时使用弹性ui时遇到问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/62339801/

相关文章:

javascript - Angular $scope 为什么不能改变?

javascript - 将多维数组传递给 Javascript

javascript - 如何在 react 导航中定位后退箭头按钮

nginx - Kibana->启用SSL Nginx代理的ElasticsSearch瓦特/基本身份验证启用

search - 多面搜索和汇总无法正常工作

javascript - 通过 css 居中 msform

javascript - 视频更改而无需重新加载页面时,HTML5视频元素缺少END事件

javascript - 将表单数据序列化为json react

javascript - 在 AJAX js 调用中动态分配值

python - 在Elasticsearch聚合器之间建立关系-嵌套分组