aboutsummaryrefslogtreecommitdiff
path: root/third_party
diff options
context:
space:
mode:
authorKalle Raita <kalle.raita@drawelements.com>2015-01-20 17:54:30 -0800
committerKalle Raita <kraita@google.com>2015-02-23 13:50:02 +0200
commit4344737e710cd75461b1338105c98db8e3a73739 (patch)
treec6ccf2d130f8fc9b76d1ba7bb89d0aa3e63caa0f /third_party
parent393d899adcde79ec5d58efa789c5a5dc09e34771 (diff)
downloadcherry-4344737e710cd75461b1338105c98db8e3a73739.tar.gz
Add Cherry custom UI-router click handling preventer
Diffstat (limited to 'third_party')
-rw-r--r--third_party/ui-router/release/angular-ui-router.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/third_party/ui-router/release/angular-ui-router.js b/third_party/ui-router/release/angular-ui-router.js
index 3faa6bb..faefa4c 100644
--- a/third_party/ui-router/release/angular-ui-router.js
+++ b/third_party/ui-router/release/angular-ui-router.js
@@ -2938,7 +2938,7 @@ function $StateRefDirective($state, $timeout) {
element.bind("click", function(e) {
var button = e.which || e.button;
- if ( !(button > 1 || e.ctrlKey || e.metaKey || e.shiftKey || element.attr('target')) ) {
+ if ( !(button > 1 || e.ctrlKey || e.metaKey || e.shiftKey || element.attr('target') || element.attr('de-no-angular-ui-router-hack') !== undefined)) {
// HACK: This is to allow ng-clicks to be processed before the transition is initiated:
$timeout(function() {
$state.go(ref.state, params, options);
@@ -3220,4 +3220,4 @@ function $RouteProvider( $stateProvider, $urlRouterProvider) {
angular.module('ui.router.compat')
.provider('$route', $RouteProvider)
.directive('ngView', $ViewDirective);
-})(window, window.angular); \ No newline at end of file
+})(window, window.angular);