[x] ensure beforeSnap and afterSnap logic is maintained
[x] ensure snapping-after-manual-scroll behaviour snaps to the correct scrollTop when a child element has a bigger height
[x] ensure snap-from-current-scrolltop logic is maintained
[x] use a class Snapscroll to maintain state instead of polluting the scope. Will also make it easier to unit-test. won't do. I'd forgotten that angular only exposes what's in the scope binding. as for the tests, they are a mess but they do their job. will think about refactoring later.
[x] use an object to track changes to snapIndex and innerSnapIndex instead of two separate values turned out to be more messy than the current solution. snapIndex changes from outside would need to update the object, whereas innerSnapIndex and snapIndex changes from inside would need to also update snapIndex 19b1bcb.
Coverage decreased (-1.1%) to 96.83% when pulling 09d9539179eb156b97245be40193ed1b2eafa759 on feature/bigger-height-children into 89611b21a330b9a5cbddc4b1955f0ec9218e0fbd on master.
Coverage decreased (-3.5%) to 94.652% when pulling 7283ae1f39133c4a0b49c73f5627e811ec7f28cd on feature/bigger-height-children into 5bb914097ec7a3c44f9e0325511bfe74bfbf551b on master.
Coverage increased (+1.0%) to 99.15% when pulling 35d45701abab1ff188afb29da55591acb26c1af5 on feature/bigger-height-children into 5bb914097ec7a3c44f9e0325511bfe74bfbf551b on master.
Coverage increased (+1.0%) to 99.15% when pulling ea6b1e16d0981a50324c32fe7310bd5d80323167 on feature/bigger-height-children into 5bb914097ec7a3c44f9e0325511bfe74bfbf551b on master.
Coverage increased (+0.9%) to 99.135% when pulling 19b1bcb49051049e3d9a2a67b88c5a223db7393c on feature/bigger-height-children into 5bb914097ec7a3c44f9e0325511bfe74bfbf551b on master.
Coverage increased (+1.0%) to 99.162% when pulling 0c6aaf3909d4ad66e0a3a55e8232dbdbeb20b83f on feature/bigger-height-children into 5bb914097ec7a3c44f9e0325511bfe74bfbf551b on master.
Coverage increased (+1.0%) to 99.162% when pulling 0c6aaf3909d4ad66e0a3a55e8232dbdbeb20b83f on feature/bigger-height-children into 5bb914097ec7a3c44f9e0325511bfe74bfbf551b on master.
Coverage increased (+1.0%) to 99.162% when pulling 65e8ac8297f7c6ab72622e8fc40c15cf5be0327a on feature/bigger-height-children into 5bb914097ec7a3c44f9e0325511bfe74bfbf551b on master.
Fixes #26
scrollTop
when a child element has a bigger heightuse a classwon't do. I'd forgotten that angular only exposes what's in the scope binding. as for the tests, they are a mess but they do their job. will think about refactoring later.Snapscroll
to maintain state instead of polluting the scope. Will also make it easier to unit-test.snapIndex
andinnerSnapIndex
instead of two separate valuesturned out to be more messy than the current solution.19b1bcb.snapIndex
changes from outside would need to update the object, whereasinnerSnapIndex
andsnapIndex
changes from inside would need to also updatesnapIndex