@twab/visualization 1.6.1 → 1.6.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.
@@ -1385,7 +1385,7 @@ FramesManager.prototype.orderFramesBlock = function (
1385
1385
 
1386
1386
  if (this.buffer.length > 0) {
1387
1387
  const uniqueTimes = new Set();
1388
- const result = [];
1388
+ let result = [];
1389
1389
 
1390
1390
  for (const item of this.buffer) {
1391
1391
  if (!uniqueTimes.has(item.time)) {
@@ -1403,16 +1403,11 @@ FramesManager.prototype.orderFramesBlock = function (
1403
1403
 
1404
1404
  result.sort((a, b) => a.time - b.time);
1405
1405
 
1406
- const sliceLimit =
1407
- ENUM.MinBlockSizesBack[this.currentStep] +
1408
- ENUM.MinBlockSizes[this.currentStep] +
1409
- 900;
1410
-
1411
- if (backwards) {
1412
- this.buffer = result.slice(0, sliceLimit);
1413
- } else {
1414
- this.buffer = result.slice(-sliceLimit);
1406
+ if (!backwards && !this.checkFramesBackward()) {
1407
+ result = result.slice(images.length);
1415
1408
  }
1409
+
1410
+ this.buffer = result;
1416
1411
  } else {
1417
1412
  this.buffer = images;
1418
1413
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twab/visualization",
3
- "version": "1.6.1",
3
+ "version": "1.6.2",
4
4
  "main": "dist/visualization.js",
5
5
  "files": [
6
6
  "dist"