[英]Unable to ng-hide elements
In my mini-project here , I need to hide the Shop button and the Content div when the user clicks on the textbox. 在这里的迷你项目中 ,当用户单击文本框时,我需要隐藏“ 购物”按钮和“ 内容” div 。 I am attempting to do it using
ng-hide
. 我正在尝试使用
ng-hide
做到这一点。
For some reason there is an error with the module. 由于某些原因,模块出现错误。
Error: error:nomod
Module Unavailable
I was able to partly get it working here , but I need to hide the elements when someone clicks on the textbox, before they start typing. 我可以在这里部分使用它,但是当有人单击文本框时,我需要先隐藏它们,然后再开始输入。
I need to get this working in Firefox only. 我只需要在Firefox中使用它即可。
What am I missing? 我想念什么?
I've changed your code a bit. 我对您的代码做了一些更改。 You can try this out:
您可以尝试以下方法:
<input type="text" name="hideBasicInfo" ng-click="hideBasicInfo = true" />
<div ng-hide="hideBasicInfo">
When someone's press the textbox I'll set the property hideBasicInfo true. 当有人按下文本框时,我将把属性hideBasicInfo设置为true。 (via ng-click)
(通过ng-click)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.