solid-ctrl-flow 2.1.1 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -166,8 +166,10 @@ export declare namespace Slot {
166
166
  * Restores the indexes of a slotted list.
167
167
  * This function is useful after a sort, filter, or any other operation that changes the order of the elements in the list without taking care of {@link Slot}s
168
168
  * @param list The list to restore
169
+ * @param start The index at which to start restoring the indexes
170
+ * @param end The index at which to stop restoring the indexes
169
171
  */
170
- export function restore(list: Slot[]): void;
172
+ export function restore(list: Slot[], start?: number, end?: number): void;
171
173
  }
172
174
 
173
175
  /**
package/dist/index.mjs CHANGED
@@ -65,8 +65,8 @@ var Slot;
65
65
  return out;
66
66
  }
67
67
  Slot2.removeAt = removeAt;
68
- function restore(list) {
69
- for (var i = 0; i < list.length; i++)
68
+ function restore(list, start = 0, end = list.length) {
69
+ for (var i = start; i < end; i++)
70
70
  list[i].slot = i;
71
71
  }
72
72
  Slot2.restore = restore;
package/dist/index.umd.js CHANGED
@@ -67,8 +67,8 @@
67
67
  return out;
68
68
  }
69
69
  Slot2.removeAt = removeAt;
70
- function restore(list) {
71
- for (var i = 0; i < list.length; i++)
70
+ function restore(list, start = 0, end = list.length) {
71
+ for (var i = start; i < end; i++)
72
72
  list[i].slot = i;
73
73
  }
74
74
  Slot2.restore = restore;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "solid-ctrl-flow",
3
- "version": "2.1.1",
3
+ "version": "2.1.2",
4
4
  "description": "Control flow components for solid-js",
5
5
  "author": "AFatNiBBa",
6
6
  "license": "ISC",