mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-09-11 06:30:03 +00:00
perf(studio): stabilize virtualized clip gestures (#2704)
This commit is contained in:
@@ -12,6 +12,7 @@ interface TimelineClipProps {
|
||||
isSelected: boolean;
|
||||
isHovered: boolean;
|
||||
isDragging?: boolean;
|
||||
isGestureActor?: boolean;
|
||||
isActive?: boolean;
|
||||
hasCustomContent: boolean;
|
||||
capabilities: TimelineEditCapabilities;
|
||||
@@ -36,6 +37,7 @@ export const TimelineClip = memo(function TimelineClip({
|
||||
isSelected,
|
||||
isHovered,
|
||||
isDragging = false,
|
||||
isGestureActor = false,
|
||||
isActive = false,
|
||||
hasCustomContent,
|
||||
capabilities,
|
||||
@@ -85,13 +87,14 @@ export const TimelineClip = memo(function TimelineClip({
|
||||
|
||||
return (
|
||||
<div
|
||||
data-clip="true"
|
||||
data-el-id={el.key ?? el.id}
|
||||
data-clip={isGestureActor ? undefined : "true"}
|
||||
data-el-id={isGestureActor ? undefined : (el.key ?? el.id)}
|
||||
data-clip-start={el.start}
|
||||
data-clip-end={el.start + el.duration}
|
||||
data-clip-hidden={el.hidden ? "true" : undefined}
|
||||
data-active={isActive ? "" : undefined}
|
||||
tabIndex={-1}
|
||||
aria-hidden={isGestureActor ? "true" : undefined}
|
||||
tabIndex={isGestureActor ? undefined : -1}
|
||||
className={clipClassName}
|
||||
style={style}
|
||||
title={
|
||||
|
||||
Reference in New Issue
Block a user