AngularJS ng-mouseleave 指令

AngularJS 教程 · 2019-04-01 21:37:15

AngularJS 实例

在鼠标指针离开元素时执行表达式:

<div ng-mouseleave="count = count + 1" ng-init="count=0">鼠标从我这移开 me!</div>

<h1>{{count}}</h1>

定义和用法

ng-mouseleave 指令用于告诉 AngularJS 鼠标从 HTML 元素上移开时要执行的操作。

ng-mouseleave 指令不会覆盖元素的原生 onmouseleave 事件, 事件触发时,ng-mouseleave 表达式与原生的 onmouseleave 事件将都会执行。

语法

<element ng-mouseleave="expression"></element>

所有的 HTML 元素支持该指令。

参数值

描述
expression 鼠标在元素上移开时执行的表达式。

点击查看所有 AngularJS 教程 文章: https://codercto.com/courses/l/36.html

查看所有标签

Elements of Information Theory

Elements of Information Theory

Thomas M. Cover、Joy A. Thomas / Wiley-Blackwell / 2006-7 / GBP 76.50

The latest edition of this classic is updated with new problem sets and material The Second Edition of this fundamental textbook maintains the book's tradition of clear, thought-provoking instr......一起来看看 《Elements of Information Theory》 这本书的介绍吧!

JS 压缩/解压工具
JS 压缩/解压工具

在线压缩/解压 JS 代码

图片转BASE64编码
图片转BASE64编码

在线图片转Base64编码工具

XML、JSON 在线转换
XML、JSON 在线转换

在线XML、JSON转换工具