【问题标题】:Cannot apply `omega/theme.css` in angular.json无法在 angular.json 中应用“omega/theme.css”
【发布时间】:2019-12-10 20:34:11
【问题描述】:
"styles": [
              "./node_modules/@angular/material/prebuilt-themes/indigo-pink.css",
              "node_modules/bootstrap/dist/css/bootstrap.min.css",
              "src/styles.css",
              "node_modules/primeicons/primeicons.css",  
              "./node_modules/primeng/resources/primeng.min.css",
              "./node_modules/primeng/resources/themes/omega/theme.css" //wont work
            ]

omega/theme.css 总是显示:-

多重错误 ./node_modules/@angular/material/prebuilt-themes/indigo-pink.css ./node_modules/bootstrap/dist/css/bootstrap.min.css ./src/styles.css ./node_modules/primeicons/primeicons.css ./node_modules/primeng/resources/primeng.min.css ./node_modules/primeng/resources/themes/omega/theme.css 模块不是 发现:错误:无法解析“路径”

我也尝试在 style.css 中导入它,但没有改变。其他任何事情都没有错误。 我还安装了:- npm install primeng font-awesome npm install @angular/animations --save

启动是否获得许可?

【问题讨论】:

  • 'Url' 问题你可以在这里找到帮助https://stackoverflow.com/questions/42012329/angular-2-primeng-style-not-working
  • 该主题不再是primeng包的一部分。他们几个月前将其删除。
  • 这能回答你的问题吗? Angular 2 - PrimeNg style not working

标签: css angular primeng


【解决方案1】:

Omega 主题不可用。因为在 PrimeNG 7.0 中弃用所有免费主题并删除它们

引入由 PrimeNG Theme Designer 生成的新 Nova 免费主题,为免费主题提供高级外观,Nova 有 3 种替代方案;

  • 新星光
  • 新星色
  • 新星黑暗

使用上述主题。

【讨论】:

  • ? 正确,但也有其他主题 lunu 和 rhea
猜你喜欢
  • 2015-12-02
  • 1970-01-01
  • 2020-01-21
  • 1970-01-01
  • 2021-09-19
  • 1970-01-01
  • 2013-08-22
  • 1970-01-01
  • 2022-12-03
相关资源
最近更新 更多