I hereby claim:
- I am joelcrocker on github.
- I am joelcrocker (https://keybase.io/joelcrocker) on keybase.
- I have a public key whose fingerprint is E4A4 B053 3145 D7F6 1CD4 CEE6 EF6C 2D68 DC73 6AE2
To claim this, I am signing this object:
angular.module("ui-utils-too", []). | |
directive("scrollfollow", ["$window", ($window) -> | |
restrict: "A" | |
link: (scope, el, attrs) -> | |
window = angular.element($window) | |
parent = angular.element(el.parent()) | |
currentOffsetTop = el[0].getBoundingClientRect().top | |
headerOffsetTop = scope.$eval(attrs.scrollfollow) or 5 | |
# assumes width/padding in px |
I hereby claim:
To claim this, I am signing this object:
from toolz.itertoolz.core import reduceby | |
from toolz.dicttoolz.core import valmap | |
def group_tuples(tuples): | |
if len(tuples[0]) < 2: | |
return [t[0] for t in tuples] | |
result = reduceby( | |
lambda t: t[0], | |
lambda a, b: a + [b[1:]], | |
tuples, |