Closed
Description
Example use case:
- There’s a table where each row links to a sub-state.
- For the user’s convenience the whole
<tr>
is made clickable by addingui-sref="A"
to it. - Some of the table columns contain
<a>
links to other states (implemented by usingui-sref="B"
on those link tags).
When you click on any of those links – because you want to visit state B
– the link to A
on the <tr>
elements takes precedence because ui-sref
’s click handler does not call e.stopPropagation()
when it handles the click event. So the transition to B
gets superseded by a transition to A
when the parent element processes the event. Therefore, you always end up in state A
– no matter where you click.
Adding e.stopPropagation()
somewhere in the click handler solves the problem.
Tested with [email protected]
and [email protected]