博客
关于我
Angular开发(二十五)-angular自带动画效果
阅读量:123 次
发布时间:2019-02-26

本文共 732 字,大约阅读时间需要 2 分钟。

angular2????????

????????????

import {Component, OnInit, style, trigger, state, transition, animate, keyframes} from '@angular/core';

@Component({selector: 'app-page1',templateUrl: './page1.component.html',styleUrls: ['./page1.component.css'],animations: [trigger('loginAnimation', [state('normal', style({transform: 'scale(1)'})),state('active', style({transform: 'scale(1.5)'})),transition('normal => active', animate('100ms ease-in')),transition('active => normal', animate('100ms ease-out'))])]})export class Page1Component implements OnInit {private loginBtnState: string = 'inactive';

constructor() {}ngOnInit() {}toggleLoginState(state: boolean) {  this.loginBtnState = state ? 'active' : 'inactive';}

}

???HTML???????

??????

转载地址:http://svvf.baihongyu.com/

你可能感兴趣的文章
MySQL集群解决方案(4):负载均衡
查看>>
mysql颠覆实战笔记(八)--mysql的自定义异常处理怎么破
查看>>
MySQL高级-MySQL并发参数调整
查看>>
MySQL高级-视图
查看>>
MySQL:判断逗号分隔的字符串中是否包含某个字符串
查看>>
Nacos在双击startup.cmd启动时提示:Unable to start embedded Tomcat
查看>>
Nacos安装教程(非常详细)从零基础入门到精通,看完这一篇就够了
查看>>
Nacos配置中心集群原理及源码分析
查看>>
nacos配置自动刷新源码解析
查看>>
Nacos集群搭建
查看>>
nacos集群搭建
查看>>
Navicat for MySQL 查看BLOB字段内容
查看>>
Neo4j电影关系图Cypher
查看>>
Neo4j的安装与使用
查看>>
Neo4j(2):环境搭建
查看>>
Neo私链
查看>>
nessus快速安装使用指南(非常详细)零基础入门到精通,收藏这一篇就够了
查看>>
Nessus漏洞扫描教程之配置Nessus
查看>>
Nest.js 6.0.0 正式版发布,基于 TypeScript 的 Node.js 框架
查看>>
NetApp凭借领先的混合云数据与服务把握数字化转型机遇
查看>>