is there any inbuilt right click event in ng-grid using angularjs - angularjs

i am using angularjs to write right click event for selected row in ng-grid.but i want to know is any inbuilt right click event there in ng-grid.if it is there please suggest me.
Thanks

A directive may be used to bind required actions on a right click, by using contextmenu event.
You can also refer to answers to this question.

I think you need to define a celltemplate with the required conditions. Something like this by defining a directive
insert ng-click event into ng-grid

Related

adding event listeners to ng-tags-input

I want to add focus and blur events to the inputs in my form. I have Added it to my custom directives and inputs, but i am using ng-tags-input as well, how can i register event listeners to that? probably modifyingtagsInputConfig, but i am not able to implement it properly .. Or should i use a different approach to add event listener to the parent form and implement event bubbling in the child elements . But i guess event capturing is supported in IE9+ , Can anyone tell me an approach which can work on IE8 as well.
Thanks
ngTagsInput supports both ngFocus and ngBlur directives:
<tags-input ng-model="tags" ng-focus="focus()" ng-blur="blur()"></tags-input>
Working Plunker
That should be better documented, I must admit it. :|
Finally, ngTagsInput only works with IE10+. If you need to support older versions of that browser, perhaps you should check out this fork.

bind unbind dynamically $document click event in angular JS custom directive

I want to bind body click event to custom directive. I have created a custom directive for drop down. My functionality is I want closed the option list when the user clicks on the body. The html code for drop down is created by using <ul> and <li> tag. I have used the directive several times on the page. but the page now became slow as the no. of usage of directive increased on the page. So i want to know how to dynamically bind and unbind body click event inside the directive. i used $document.bind('click',function(){//function body}); syntax to bind click event. Please help. Thanks in advance
Instead of using JQuery, you can use the link method to manipulate DOM elements and add listeners
See : the AngularJS doc
I hope it may help

Kendo UI button swith angular

I have the following example.
Two kendo UI buttons and two regular buttons. Both should enable/disable the button on bottom. Only the regular buttons do and I don't understand why. Probably has something to do with the scope...
EDIT:
From another example I have, it seems like the scope is updated correctly but the ui is not updated. In my example i have another control that when I click it the ui is suddenly being updated.
Found the answer:
When clicking the kendo button the scope does change but it doesn't go through angular so angular doesn't know that the scope was changed so the digest cycle doesn't run.
So adding $scope.$apply(); at the end of the function triggers the digest.
Took the explanation from here.

Issue with drop down menu directive, ui-bootstrap, angular

I'm trying to make a dropdown menu. I'm usinig the Dropdown toggle directive form ui-bootstrap. I want to customize this a little. I want the drop down title to change to the option which I have chosen.
I've made my own directive for this. In this directive i add two data objects, the options and the selected option. I also have one function which changes the selected option.
Select category: <my-directive my-options="categories" my-selected-option="selectedCategory" set-my-selected-option="setCategory(selectedCategory)"></my-directive>
Js fiddle: http://jsfiddle.net/per_strom/QW634/2/
The problem is the setCategory function is not changing.
This is my first directive I'm writing so I may be totally of. Perhaps there's a much better way to do it.
Why can't I just use a normal select box? It's a GUI thing. In this case I prefer lists.
I appreciate any help I can get!
You should pass the function reference to the directive rather than a function call. Change the part of your code to
`set-my-selected-option="setCategory"`

Angular Bootstrap: How to show a popover based on a child elements' trigger?

Demo Fiddle
I'd like to show some help text using a popover for the entire group of fields, not for each individual input.
In the fiddle, I'm simply using a mouseenter trigger to show how it should look like, but what I really want is to trigger it on focus for any input, but have the popover be positioned based on the parent element.
In non-angular land, I'd trigger a custom event (say groupenter) when any one of the fields is in focus, and have the popover listen to that event. I'd also debounce the corresponding groupleave event so the popover won't flicker as I tab around the inputs.
What's an angular-y way to accomplish that here?
(I think this patch helps, but it just got committed days ago)
Got it working!
I had to fork tooltip.js to add 'groupenter': 'groupleave' to triggerMap since there's no public api to add to the map.

Resources