Closed bvarga closed 10 years ago
Call qtip each show:
cy.on('tap', 'node', function(){
this.qtip({ content: this.data('weight') });
});
Call qtip on each element directly:
cy.nodes().each(function(){
this.qtip({ content: this.data('weight') });
});
I've also added a change to master to override the reference to this
inside content()
:
cy.nodes().qtip({
content: function(){ return this.data('weight'); }
});
Oh, I see, thanks.
I would like to show node specific data in qtip. I couldn't figure out how to do this without modifying the code, so I made a little change, by adding a ref to the element object
see this commit
so this way if content is a function, here is how you can access to the element the event triggered on.
Is there other (better) way to do this?