【发布时间】:2019-11-25 07:59:05
【问题描述】:
点击UI Element后添加类(打开)ti li,并打开折叠 但在 xxx.component.html 中没有 woking
截图
[]
【问题讨论】:
标签: javascript css angular typescript
点击UI Element后添加类(打开)ti li,并打开折叠 但在 xxx.component.html 中没有 woking
截图
[]
【问题讨论】:
标签: javascript css angular typescript
如果我必须猜测您的问题,很可能您的 css 已在 index 组件中声明。 Angular 的 css 被封装或作用域。
https://angular.io/guide/component-styles
将您的 css 移动到 styles.css 或使用阅读指南并使用 host-cotontext (https://angular.io/guide/component-styles#host-context) 或禁用封装 (https://angular.io/guide/component-styles#view-encapsulation)
【讨论】: