You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
_Note:_ angular-ui-scroll works with AngularJS v1.2.0 and above.
139
+
138
140
Currently we have 2 regular modules which can be added to the angular-app you are developing:
139
141
-__ui.scroll__ module which has
140
142
-[uiScroll directive](#uiscroll-directive)
@@ -274,9 +276,9 @@ Adapter object implements the following methods
274
276
275
277
reload(startIndex)
276
278
277
-
Calling this method reinitializes and reloads the scroller content. `startIndex` is an integer indicating what item index the scroller will use to start the load process. The value of the argument replaces the value provided with the start-index attribute. Calling `reload()` is equivalent to calling `reload` method with current value of the `start-index` attribute.
279
+
Calling this method re-initializes and reloads the scroller content. `startIndex` is an integer indicating what item index the scroller will use to start the load process. The value of the argument replaces the value provided with the start-index attribute. Calling `reload()` is equivalent to calling `reload` method with current value of the `start-index` attribute.
278
280
279
-
_Important!_`startIndex` should fall within underlying datset boundaries. The scroller will request two batches of items one starting from the `startIndex` and another one preceding the first one (starting from `startIndex - bufferSize`). If both requests come back empty, the scroller will consider the dataset to be empty and will place no further data requests.
281
+
_Important!_`startIndex` should fall within underlying dataset boundaries. The scroller will request two batches of items one starting from the `startIndex` and another one preceding the first one (starting from `startIndex - bufferSize`). If both requests come back empty, the scroller will consider the dataset to be empty and will place no further data requests.
280
282
281
283
* Method `applyUpdates`
282
284
@@ -296,7 +298,7 @@ Adapter object implements the following methods
296
298
***updater** is a function to be applied to every item currently in the buffer. The function will receive 3 parameters: `item`, `scope`, and `element`. Here `item` is the item to be affected, `scope` is the item $scope, and `element` is the html element for the item. The return value of the function should be an array of items. Similarly to the `newItem` parameter (see above), if the array is empty(`[]`), the item is deleted, otherwise the item is replaced by the items in the array. If the return value is not an array, the item remains unaffected, unless some updates were made to the item in the updater function. This can be thought of as in place update.
297
299
298
300
Options for both signatures, an object with following fields
299
-
***immutableTop** is a boolean flag with `false`defalt value. This option has an impact on removing/inserting items procedure. If it's `false`, deleting the topmost item will lead to incrementing min index, also inserting new item(s) before the topmost one will lead to decrementing min index. If it's `true`, min index will not be affected, max index will be shifted instead. If it's `true`, no matter which item is going to be removed/inserted, max index will be reduced/increased respectively.
301
+
***immutableTop** is a boolean flag with `false`default value. This option has an impact on removing/inserting items procedure. If it's `false`, deleting the topmost item will lead to incrementing min index, also inserting new item(s) before the topmost one will lead to decrementing min index. If it's `true`, min index will not be affected, max index will be shifted instead. If it's `true`, no matter which item is going to be removed/inserted, max index will be reduced/increased respectively.
300
302
301
303
Let's discuss a little sample. We have `{{$index}}: {{item}}` template and three rows: `1: item1`, `2: item2`, `3: item3`. Then we want to remove the first item. Without `immutableTop` we'll get `2: item2`, `3: item3`. With `immutableTop` we'll get `1: item2`, `2: item3`. The same for inserting, say, `item0` before `item1`. Without `immutableTop` we'll get `0: item0`, `1: item1`, `2: item2`, `3: item3`. With `immutableTop` we'll get `1: item0`, `2: item1`, `3: item2`, `4: item3`.
302
304
@@ -413,7 +415,7 @@ A reference to this object is injected as a property named `gridAdapter`in the s
413
415
`GridAdapter` object implements the following methods:
414
416
415
417
* Method `getLayout()` - returns an object describing current scrollable grid layout.
416
-
* Method `applyLayout(layout)` - restores scrollabel grid layout to the state as defined by the object passed as the parameter
418
+
* Method `applyLayout(layout)` - restores scrollable grid layout to the state as defined by the object passed as the parameter
417
419
* Method `columnFromPoint(x,y)` - if the coordinates belong to a scrollable grid column returns the appropriate ColumnAdapter object. Otherwise, returns `undefined`.
418
420
419
421
`ColumnAdapter` object implements the following methods:
@@ -469,17 +471,20 @@ npm run build
469
471
b) generate compressed and uncompressed versions of the ui-scroll distributive in the public [./dist](https://github.com/angular-ui/ui-scroll/tree/master/dist) folder,
470
472
c) run tests over minified distributive files.
471
473
472
-
Pull Rerquest should include source code (./scr) changes, may include tests (./test) changes and may not include public distributive (./dist) changes.
474
+
Pull Request should include source code (./scr) changes, may include tests (./test) changes and may not include public distributive (./dist) changes.
473
475
474
476
475
477
-------------------
476
478
477
479
478
480
## Change log
479
481
482
+
### v1.8.1
483
+
* Removed deprecated bind/unbind methods.
484
+
480
485
### v1.8.0
481
-
* Reconsidered scroll event handling
482
-
* Fixed inertia scrolling issues
486
+
* Reconsidered scroll event handling.
487
+
* Fixed inertia scrolling issues.
483
488
484
489
### v1.7.6
485
490
* Added immutableTop option for applyUpdates and prepend Adapter methods.
@@ -558,7 +563,7 @@ Pull Rerquest should include source code (./scr) changes, may include tests (./t
558
563
559
564
### v1.3.1
560
565
* Changed the logic of viewport scroll/padding recalculation.
561
-
*Splitted test specifications.
566
+
*Reorganized test specifications.
562
567
* Updated dev-dependencies (package.json).
563
568
* Implemented append/prepend methods on the adapter.
0 commit comments