@rokkit/core 1.0.0-next.13 → 1.0.0-next.14

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rokkit/core",
3
- "version": "1.0.0-next.13",
3
+ "version": "1.0.0-next.14",
4
4
  "description": "Core components, actions and stores for svelte apps.",
5
5
  "author": "Jerry Thomas <me@jerrythomas.name>",
6
6
  "license": "MIT",
@@ -135,6 +135,13 @@ export function movePrevious(path) {
135
135
  return path
136
136
  }
137
137
 
138
+ /**
139
+ *
140
+ * @param {Array<integer>} indices
141
+ * @param {Array<*>} items
142
+ * @param {import('../constants').FieldMapping} fields
143
+ * @returns
144
+ */
138
145
  export function pathFromIndices(indices, items, fields) {
139
146
  let path = []
140
147
  let fragment
@@ -171,19 +178,3 @@ export function findItem(items, indices, fields) {
171
178
  }
172
179
  return item
173
180
  }
174
-
175
- // export function getNodeFromIndices(indices, items, fields) {
176
- // let fragment
177
- // indices.map((index, level) => {
178
- // if (level === 0) {
179
- // fragment = { index, items, fields }
180
- // } else {
181
- // fragment = {
182
- // index,
183
- // items: fragment.items[fragment.index][fragment.fields.children],
184
- // fields: fragment.fields.fields ?? fragment.fields
185
- // }
186
- // }
187
- // })
188
- // return indices.length === 0 ? null : fragment.items[fragment.index]
189
- // }