Last active
November 30, 2018 13:49
-
-
Save tangorri/61e4bc80c31827e6e499 to your computer and use it in GitHub Desktop.
scope not injectable in controller ...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Created by ant on 16/04/2015. | |
*/ | |
'use strict'; | |
angular.module('project.widgets-grid').directive( | |
'gridScroll', function gridScrollDefinitionFn | |
($timeout, | |
DashboardGrid) | |
{ | |
function easeFn(t) { | |
return t < 0.5 ? 2 * t * t : -1 + (4 - 2 * t) * t; | |
} | |
return { | |
restrict: 'A', | |
scope: {}, | |
controller: function gridScrollDirectiveController(scope, element) { | |
function lockToRightBorder() { | |
//element[0].scrollLeft = element[0].scrollWidth; | |
} | |
this.lockToRightBorder = lockToRightBorder; | |
}, | |
//controllerAs: 'gridContainer', | |
link: function gridScrollPostLink(scope, element) { | |
... | |
} | |
}; | |
} | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment