angular - Infragistics 主题无法按 *I* 预期工作。未应用默认主题
问题描述
早上好,
我期望通过几行代码,我可以包含此处解释的 Infragitics 主题之一。(https://www.infragistics.com/products/ignite-ui-angular/angular/components/themes/examples.html)
我正在“默认主题”部分工作。我使用 Infragistics angular-cli 创建了一个新的 angular 项目。我像这样在 HTML(和支持模块导入)中添加了一个按钮。
<button igxButton="raised">Sign In</button>
现在我按照教程上的说明添加以下内容:
// import first the IgniteUI themes library
@import "~igniteui-angular/lib/core/styles/themes/index";
// Don't forget to include the igx-core first
@include igx-core();
// the default color palette is passed to the global theme
@include igx-theme($default-palette);
我仍然得到上面看到的“粉红色”按钮。但是教程声称并显示它是灰色的。所以我在 StackBlitz 中打开教程示例,我变得非常困惑。
他们已经手动添加到 scss 附加样式以获得灰色效果????
.addProdBtn.igx-button--raised{
margin-bottom: 5px;
background-color: lightgrey;
color: black;
&:hover {
background-color: rgba(0, 0, 0, 0.26)
}
}
如果我把上面的 scss 拿走,那么样品就会像我的一样变回粉红色???
所以我很困惑。我认为默认主题的想法是让您轻松获得一致的外观和感觉,而不必做一堆样式???
解决方案
我还在 Infragistics 论坛上交叉发布了这个问题,并得到了与上面的 Konstantin Diev 类似的回复。
该文档具有误导性,Infragistics 将进行更新。
推荐阅读
- java - 在创建具有盒装类型(例如整数)数组的张量与张量流中的基元数组时是否存在差异
- java - 在 java 中访问 JSONObject 中的键/值
- python-3.x - 如何忽略数据框中的空值并基于列构建新数据框
- python - 如何使用熊猫复制行(列)的元素并粘贴到csv中的第1行(另一列)?
- parsing - Terms for basic NLP/logical parsing example
- javascript - 检测父对象的窗口调整大小时排除子 jQuery 对象
- python - 使用 GradientTape 计算关于某些张量的预测梯度
- json - 通过在颤振中使用自定义 api 强制更新应用程序
- sql - SQL 案例查询没有给出正确的值
- .net-core - .NET Core 应用程序中的 System.DllNotFoundException