如何关闭角度ui路由上的模式,使用ng-click
?角ui路径隐藏模式
我有UI航线角这个HTML文件:
<div ui-view="modalView"></div>
<div ui-sref="openModal">Open Modal</div>
这是我的配置:
$stateProvider.state('openModal', {
views: {
'modalView': {
templateUrl: "/partials/Modal.html"
}
}
然后在我的Modal.html我:
<div style ="position:fixed; width:100%; heigth:100%; background-color:black;">
//i want to click in this div and close the modal
<div style = "position:relative; float:right;"><i class="fa fa-times fa" aria-hidden="true"></i></div>
</div>
如何在不使用jQuery的情况下做到这一点?
好的,谢谢你。 – John