angular - 如何使角度识别星云主题
问题描述
我有一个新生成的 Angular 10 项目。我从 akveo 添加了角度星云主题,但 Angular 无法识别这些主题。
我从 akveos 页面复制了一张卡片的代码示例,但它只显示为文本。我没有收到任何错误或任何错误。
这是我在我的选项中的代码我在正确的地方添加了我需要的一切,但也许我弄错了。如果有人会看它会很好。
角.json:
],
"styles": [
"apps/moniesta-admin/src/styles.scss",
"node_modules/@nebular/theme/styles/prebuilt/default.css",
"node_modules/@nebular/theme/styles/prebuilt/dark.css",
"node_modules/@nebular/theme/styles/prebuilt/corporate.css",
"node_modules/@nebular/theme/styles/prebuilt/cosmic.css"
],
"scripts": []
},
LoginModule(自定义组件):
@NgModule({
imports: [CommonModule,
RouterModule,
NbCardModule,
NbThemeModule.forRoot(),
NbLayoutModule],
declarations: [LoginComponent],
exports: [LoginComponent],
})
登录组件-html
<nb-card status="success">
<nb-card-header>Nebula</nb-card-header>
<nb-card-body>
A nebula is an interstellar cloud of dust, hydrogen, helium and other ionized gases.
Originally, nebula was a name for any diffuse astronomical object,
including galaxies beyond the Milky Way.
</nb-card-body>
<nb-card-footer>By Wikipedia</nb-card-footer>
</nb-card>
解决方案
这是我登录使用的scss:
@import '~@nebular/theme/styles/theming';
@import '~@nebular/theme/styles/themes/default';
@import '~@nebular/theme/styles/themes/dark';
@import '~@nebular/theme/styles/themes/cosmic';
@import '~@nebular/theme/styles/themes/corporate';
推荐阅读
- python - 在熊猫中按列 dtype 进行 if-else
- java - 具有不同偏移量的 OffsetDateTime 与 UTC (Zulu) 的 OffsetDateTime
- command-line - .exe 的命令行静默安装
- ruby-on-rails - 使用关键字参数调用方法
- python - 如何避免 Pillow 在保存图像后稍微编辑我的图像?
- bit-manipulation - 无法理解一段代码。c中的按位运算
- python - 使用“pip install --platform”在windows上安装.so
- python - 尝试制作我自己的激活函数
- c# - PDFium 将 pdf 保存为图像指定颜色深度
- android - 在 Android 上设置包装组件的焦点顺序