Bladeren bron

fix: row height size.

Ievgen Naida 5 jaren geleden
bovenliggende
commit
32b7734156
6 gewijzigde bestanden met toevoegingen van 3 en 6 verwijderingen
  1. 0 2
      index.html
  2. 1 1
      lib/animation-timeline.js
  3. 0 0
      lib/animation-timeline.min.js
  4. 1 2
      src/timeline.ts
  5. 1 1
      tests/js/styleTests.js
  6. 0 0
      tests/js/styleTests.js.map

+ 0 - 2
index.html

@@ -62,8 +62,6 @@
         ]
         ]
       },
       },
       {
       {
-        //keyframesShape: "rect",
-        //height: 40,
         selected: false,
         selected: false,
         hidden: false,
         hidden: false,
         keyframes: [
         keyframes: [

+ 1 - 1
lib/animation-timeline.js

@@ -2278,8 +2278,8 @@ var timeline_Timeline = /*#__PURE__*/function (_TimelineEventsEmitte) {
 
 
         var rowHeight = TimelineStyleUtils.getRowHeight(row, _this5._options);
         var rowHeight = TimelineStyleUtils.getRowHeight(row, _this5._options);
         var marginBottom = TimelineStyleUtils.getRowMarginBottom(row, _this5._options);
         var marginBottom = TimelineStyleUtils.getRowMarginBottom(row, _this5._options);
-        rowAbsoluteHeight += rowHeight + marginBottom;
         var currentRowY = rowAbsoluteHeight - _this5._scrollContainer.scrollTop;
         var currentRowY = rowAbsoluteHeight - _this5._scrollContainer.scrollTop;
+        rowAbsoluteHeight += rowHeight + marginBottom;
 
 
         if (index == 0) {
         if (index == 0) {
           toReturn.area.y = currentRowY;
           toReturn.area.y = currentRowY;

File diff suppressed because it is too large
+ 0 - 0
lib/animation-timeline.min.js


+ 1 - 2
src/timeline.ts

@@ -1102,9 +1102,8 @@ export class Timeline extends TimelineEventsEmitter {
         // draw with scroll virtualization:
         // draw with scroll virtualization:
         const rowHeight = TimelineStyleUtils.getRowHeight(row, this._options);
         const rowHeight = TimelineStyleUtils.getRowHeight(row, this._options);
         const marginBottom = TimelineStyleUtils.getRowMarginBottom(row, this._options);
         const marginBottom = TimelineStyleUtils.getRowMarginBottom(row, this._options);
-
-        rowAbsoluteHeight += rowHeight + marginBottom;
         const currentRowY = rowAbsoluteHeight - this._scrollContainer.scrollTop;
         const currentRowY = rowAbsoluteHeight - this._scrollContainer.scrollTop;
+        rowAbsoluteHeight += rowHeight + marginBottom;
         if (index == 0) {
         if (index == 0) {
           toReturn.area.y = currentRowY;
           toReturn.area.y = currentRowY;
         }
         }

+ 1 - 1
tests/js/styleTests.js

@@ -101,7 +101,7 @@ describe('TimelineStyleUtils', function () {
             asserts_1.assert.equal(animation_timeline_1.TimelineStyleUtils.stripeDraggable(rowStyle, globalStyle), false);
             asserts_1.assert.equal(animation_timeline_1.TimelineStyleUtils.stripeDraggable(rowStyle, globalStyle), false);
         });
         });
     });
     });
-    describe('Height', function () {
+    describe('Row size', function () {
         it('Height is taken from row', function () {
         it('Height is taken from row', function () {
             var globalStyle = {
             var globalStyle = {
                 rowsStyle: {
                 rowsStyle: {

File diff suppressed because it is too large
+ 0 - 0
tests/js/styleTests.js.map


Some files were not shown because too many files changed in this diff