Questions tagged [ng-hide]

The ngHide directive shows or hides the given HTML element based on the expression provided to the ngHide attribute. The element is shown or hidden by removing or adding the ng-hide CSS class onto the element. The .ng-hide CSS class is predefined in AngularJS and sets the display style to none (using an !important flag).

The ngHide directive shows or hides the given HTML element based on the expression provided to the ngHide attribute. The element is shown or hidden by removing or adding the ng-hide CSS class onto the element. The .ng-hide CSS class is predefined in and sets the display style to none (using an !important flag).

See the AngularJS documentation for more information.

216 questions
0
votes
1 answer

AngularJS ng-hide not working with html binding to a div

I'm trying to render html content from a controller , but the angular directive ng-hide doesn't work , I've tried the following code, does it have a problem with binding as html this way? var htmlContent = "
user3248711
  • 47
  • 1
  • 1
  • 10
0
votes
1 answer

Hiding a Link on user input on a form field

I am building an SPA using AngularJS and Bootstrap. I have a form which has a "Back" link on the navigation bar and 2 buttons (Save and Cancel). When the form is launched I want to display only the "Back" link (Save and Cancel should be hidden).…
mithrandir
  • 1,323
  • 4
  • 18
  • 39
0
votes
3 answers

AngularJS ng-show / ng-hide

We are trying to incorporate this Stackoverflow example into our AngularJS script and can't seem to figure out why it isn't working correctly. We want to display a loading icon until the JSON data is rendered, once the JSON is ready we then want the…
user3999667
0
votes
2 answers

ngHide on model change

I have the following spinner,
Avraam Mavridis
  • 8,698
  • 19
  • 79
  • 133
0
votes
1 answer

AngularJS - hide/show div if date is within last 6 months

I have an ng-repeat that displays a list of dates, and information about purchases on that dates. HTML:

{{ data.purchasedOn.substring(6, data.purchasedOn.length - 2) | date:'dd/MM/yyyy' }}

Oam Psy
  • 8,555
  • 32
  • 93
  • 157
0
votes
1 answer

AngularJS - Show a div if date is within last six months

I have a simple ng-repeat that displays a list of names and icons:

Name: {{ data.Name }}

How can i modify this so that i display a list of all names, but…
Oam Psy
  • 8,555
  • 32
  • 93
  • 157
0
votes
1 answer

angular ng-hide with animate.css strange behavior

this example works fine until I click fast and multiple times on the check box. Then I can't hide the rectangle anymore. The animation completes fine, the rectangle fades out, then it becomes visible again when it should be hidden. Any idea…
Ashraf Fayad
  • 1,433
  • 4
  • 17
  • 31
0
votes
1 answer

accessing global scope outside custom directives environment angularjs

so here is my custom directives sample code myApp.directive('anchorLink', function () { return { restrict: 'EA', link: function (scope, elem, attr) { elem.on('click', function () { scope.show = true; …
Eka RudiAnto
  • 61
  • 3
  • 15
0
votes
1 answer

Cannot get angular ng-show or ng-hide to work inside directive template

A webservice returns values back... if the values returned are == 'N' I want to hide the html element. My problem is I cannot get ng-hide and ng-show to work inside the template. I looked at the other simular questions and the fixes didn't work…
silvster27
  • 1,916
  • 6
  • 30
  • 44
0
votes
1 answer

ng-hide not working with ng-model

I want to show/hide div on specific option selection from a dropdown. But the div stays hidden all the time.