For the component's css file, we can improt two css files:

  • common.css
  • default-theme.css
@import "common.css";
@import "au-fa-input-default-theme.css";

In the default theme, it contains all the default theme related style.

:host {
border-color: lightgrey;
} :host(.input-focus) {
border-color: #4D90FE;
-webkit-box-shadow: 0 0 5px #4D90FE;
box-shadow: 0 0 5px #4D90FE;
}

In the common.css, it contains all the common style for different themes:

/*Common for all input fields*/
.icon {
width:20px;
text-align: center;
padding-left: 5px;
padding-right: 2px;
border:none;
vertical-align: middle;
} :host {
border-width:1px;
border-style: solid;
padding: 1px 0;
display: inline-block;
} :host(.input-focus) {
outline: none;
} :host /deep/ input {
border:none ;
outline: none;
height: 100%;
box-sizing: border-box;
}

[Angular] Separating Structural Styles From Theme Styles - Making Components Themeable的更多相关文章

  1. [Angular 2] ng-class and Encapsulated Component Styles

    import {Input, Component, View, NgClass} from "angular2/angular2"; @Component({ selector: ...

  2. [Angular] Use Angular style sanitization to mark dynamic styles as trusted values

    Angular has a very robust security model. Dynamically inserted html, style or url values into the DO ...

  3. Bootstrap Metronic 学习记录(二)菜单栏

    1.简介 1)  .环境配置 2)  .提取页面 2).动态生成菜单(无限级别树) 2.系统环境配置 项目需要程序数据支撑,这里选择MVC5.0+EF6.0[SQLSERVER](不对MVC架构和SQ ...

  4. Android 更改按钮样式 Button Styles

    extends:http://stackoverflow.com/questions/26346727/android-material-design-button-styles   I will a ...

  5. Styles and Themens(3)android所有主题表

    The Android platform provides a large collection of styles and themes that you can use in your appli ...

  6. [React] Radium: Updating Button Styles via Props

    In a CSS library like Bootstrap we can set a button's style to be "primary" or "secon ...

  7. GeoServer之styles定制

    GeoServer之styles定制 GeoServer中styles类似于css,将地图中的点线面画出一层皮肤,引用在图层上.不同的地方在于.GeoServer中的styles用的是sld语法,也就 ...

  8. LitElement(三)Styles样式

    1.为组件添加样式 import { LitElement, css, html } from 'lit-element'; class MyElement extends LitElement { ...

  9. angular项目中使用angular-material2

    Step 1: Install Angular Material and Angular CDK npm install --save @angular/material @angular/cdk n ...

随机推荐

  1. kali之EtterCap学习

    EtterCap是一个基于ARP地址欺骗方式的网络嗅探工具,主要适用于交换局域网络.借助于EtterCap嗅探软件,渗透测试人员可以检测网络内明文数据通讯的安全性,及时采取措施,避免敏感的用户名/密码 ...

  2. 洛谷 P1957 口算练习题

    洛谷 P1957 口算练习题 题目描述 王老师正在教简单算术运算.细心的王老师收集了i道学生经常做错的口算题,并且想整理编写成一份练习. 编排这些题目是一件繁琐的事情,为此他想用计算机程序来提高工作效 ...

  3. 【Codeforces Round #427 (Div. 2) C】Star sky

    [Link]:http://codeforces.com/contest/835/problem/C [Description] 给你n个星星的坐标(xi,yi); 第i个星星在第t秒,闪烁值变为(s ...

  4. 关于bat的变量赋值和解析机制

    以下的演示涉及几个知识点: 1. 怎样把命令输出内容保存到变量中? 2. 多次改变变量值,为什么在for或是if的()中的无效,怎样变通? 3. bat的function实现? 见代码,和代码凝视 : ...

  5. [Express] Upload Files with Express

    In this lesson we create a new Express web server app for handling file uploads and persisting them ...

  6. UITouch 的使用

    直接上代码: touch 的四大状态.: // // TouchView.m // UI_practice_04 // // Created by lanouhn on 15/4/22. // Cop ...

  7. 74LS153 选择器 【数字电路】

    74LS153 我用了八个不同频率的方波信号,用153当作信号选择器,控制环节的开关是4通道的选择器,00 01 10 11分别选择通道 0 1 2 3 以下是八选一的demo

  8. ReactNavtive框架教程(4)

    开头的响应码, 这些代码都很实用. 比如202 和 200表示返回一个推荐位置的列表.当完毕这个实例后.你能够尝试处理这些返回码.并将列表提供给用户选择. 保存,返回模拟器,按下Cmd+R ,然后搜索 ...

  9. 【2017 Multi-University Training Contest - Team 6】Kirinriki

    [链接]http://acm.hdu.edu.cn/showproblem.php?pid=6103 [题意] 给出一串字符串,从中选出两个不重叠的字符串,使得两个字符串的距离和 <= m 的最 ...

  10. Rdis-主从复制

    配置 配置一个从服务器非常简单, 只要在配置文件中增加以下的这一行就可以了: slaveof 192.168.1.1 6379 注:主:bind 192.168.10.1 (指定主机IP) 当然, 你 ...