diff --git a/routes/_components/Timeline.html b/routes/_components/Timeline.html index bf59344..9e10466 100644 --- a/routes/_components/Timeline.html +++ b/routes/_components/Timeline.html @@ -2,7 +2,7 @@
(statusId) => database.getStatus($currentInstance, statusId), - items: (statusIds) => { - return statusIds.map(statusId => ({ - key: statusId - })) - }, lastStatusId: (statusIds) => statusIds.length && statusIds[statusIds.length - 1], label: (timeline, $currentInstance) => { if (timelines[timeline]) { diff --git a/routes/_components/VirtualList.html b/routes/_components/VirtualList.html index fcc694a..025fe33 100644 --- a/routes/_components/VirtualList.html +++ b/routes/_components/VirtualList.html @@ -1,11 +1,11 @@
- {{#each $visibleItems as item @key}} + {{#each $visibleItems as visibleItem @key}} {{/each}} {{#if $showFooter}} diff --git a/routes/_utils/virtualListStore.js b/routes/_utils/virtualListStore.js index 8d02c35..ef45cb3 100644 --- a/routes/_utils/virtualListStore.js +++ b/routes/_utils/virtualListStore.js @@ -56,7 +56,7 @@ virtualListStore.compute('visibleItems', let len = items.length let i = -1 while (++i < len) { - let { key } = items[i] + let key = items[i] let height = itemHeights[key] || 0 let currentOffset = totalOffset totalOffset += height @@ -87,7 +87,7 @@ virtualListStore.compute('heightWithoutFooter', let i = -1 let len = items.length while (++i < len) { - sum += itemHeights[items[i].key] || 0 + sum += itemHeights[items[i]] || 0 } return sum })