aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections/CollectionStackedTimeline.tsx
diff options
context:
space:
mode:
authormehekj <mehek.jethani@gmail.com>2021-11-11 16:57:49 -0500
committermehekj <mehek.jethani@gmail.com>2021-11-11 16:57:49 -0500
commit2a237ca29c11585ddf51be59be4a48c46c6d4b29 (patch)
treef9e2c500ceee8fd4f2a78ebbfad2769f8af69132 /src/client/views/collections/CollectionStackedTimeline.tsx
parent97a3a38c0fb07b52e70cba459d1b92273fb57b46 (diff)
prevent clips from becoming infinitely small
Diffstat (limited to 'src/client/views/collections/CollectionStackedTimeline.tsx')
-rw-r--r--src/client/views/collections/CollectionStackedTimeline.tsx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/views/collections/CollectionStackedTimeline.tsx b/src/client/views/collections/CollectionStackedTimeline.tsx
index 78883b577..c5fa126a3 100644
--- a/src/client/views/collections/CollectionStackedTimeline.tsx
+++ b/src/client/views/collections/CollectionStackedTimeline.tsx
@@ -94,7 +94,7 @@ export class CollectionStackedTimeline extends CollectionSubView<
@observable _scroll: number = 0;
- get minTrimLength() { return this._timeline?.getBoundingClientRect() ? 0.05 * this.clipDuration : 0; }
+ get minTrimLength() { return Math.max(this._timeline?.getBoundingClientRect() ? 0.05 * this.clipDuration : 0, 0.5) }
@computed get trimStart() { return this.IsTrimming !== TrimScope.None ? this._trimStart : this.clipStart; }
@computed get trimDuration() { return this.trimEnd - this.trimStart; }
@computed get trimEnd() { return this.IsTrimming !== TrimScope.None ? this._trimEnd : this.clipEnd; }