Questions tagged [angularjs-ng-show]

The ngShow directive shows or hides the given HTML element based on the expression provided to the ngShow attribute.

From Angularjs documentation:

The ngShow directive shows or hides the given HTML element based on the expression provided to the ngShow 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). For CSP mode please add angular-csp.css to your html file (see ngCsp).

171 questions
0
votes
1 answer

How do debug ng-cloak AngularJS?

I have these icons. icon image icon font-awesome image `` font-awesome Notice I use class="ng-cloak" `
code-8
  • 54,650
  • 106
  • 352
  • 604
0
votes
1 answer

AngularJs 1.x not updating the visibility of element with ng-show or ng-if either

I am facing issue with the angular js 1.x not updating the visibility of the element even when variable values are detected. I am using custom angular open-close symbols but I don't see this as an issue. Here's the sample code:
  • 0
    votes
    1 answer

    How to hide show div by using dynamic id in AngularJS

    My code as below in html file:
    • // some another…
    0
    votes
    2 answers

    ng-show not working with nested ng-repeat

    This might seem like a repeated question but it isn't. I am stuck on this for a while. Well this is my code.
    Steve
    • 522
    • 3
    • 12
    • 28
    0
    votes
    0 answers

    Angular: When to put a variable inside curly braces?

    When I use a variable in the view (HTML), when should I put it inside curly braces {{}}? I saw an example like this where an img tag has two directives with the same value, but the first (ng-src) variable should be in curly braces and the second…
    0
    votes
    1 answer

    ANGULARJS :How to send radio button value from controller to another?

    I have two radio buttons redirecting to same application.jsp page but I just want to add/remove few fields on that application based on button that is clicked. For example- if btn 1 is clicked i want to see NAME and EMAIL fields on the application…
    0
    votes
    2 answers

    AngularJS ng-click only working on second click

    Attempting to collapse a dropdown menu (language selection), within a mobile bootstrap navbar. On first click, the dropdown menu with the languages opens fine, after changing languages the dropdown language menu closes, but when I attempt to change…
    0
    votes
    1 answer

    Hide parent block when child element is not present while searching in searchbox

    How do I hide the parent element when a child element is not present while searching in the search box. Here is my code:
    0
    votes
    1 answer

    ngShow expression is evaluated too early

    I have a angular component and controller that look like this: export class MyController{ static $inject = [MyService.serviceId]; public elements: Array; public errorReceived : boolean; private elementsService:…
    0
    votes
    2 answers

    ng-repeat checbox click not toggling div visibility

    I am using ng-repeat for a list of items. I also have a checkbox for each item. When I click on a checkbox, a div with a ng-show="IsVisible" should be shown and when I click it back(uncheck), it should hide. I am not able to make it work. Please…
    arunmmanoharan
    • 2,535
    • 2
    • 29
    • 60
    0
    votes
    1 answer

    ng-show not triggered on value=true

    I'm trying to display a div when Vimeo video reached the end using ng-show but I can get it to work. Related part of the controller responsible for ng-show looks like 'use strict'; myApp.controller('videoController', [ '$scope', …
    JackTheKnife
    • 3,795
    • 8
    • 57
    • 117
    0
    votes
    2 answers

    angularjs ng-show not working without http get

    I have a problem. In my html file I have a following content:
    quarandoo
    • 369
    • 4
    • 9
    0
    votes
    1 answer

    AngularJS ng-show not working with my function defined in a factory

    I am using the angular ng-show directive to check if a user is an admin user and if they are then I want certain html elements to be "shown". I firstly created the following function called checkIfUserIsAdmin in my mainController: …
    Sarah
    • 1,943
    • 2
    • 24
    • 39
    0
    votes
    1 answer

    ng-show Not Showing When input is invalid

    I am having trouble with form validation in AngularJS. I am trying to show a div based on whether an input is invalid. Angular is putting the correct classes on my inputs (ng-touched and ng-invalid) but it is still keeping the div with a ng-hide…
    0
    votes
    2 answers

    angularjs how to pass element properties to ng-show function

    There is one chart in my application like,
    usersam
    • 1,125
    • 4
    • 27
    • 54