Skip to content

Commit

Permalink
fix: flicker when region starts at 0:00 (#11)
Browse files Browse the repository at this point in the history
  • Loading branch information
nikarh authored Mar 18, 2024
1 parent 4b634ab commit 90a9af5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Components/Control/Regions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,8 @@ function RegionList() {
const isPlaying = createSelector(
currentTime,
(r: Region, { seconds: t }) =>
t >= Math.floor(r.startTime) && t <= Math.ceil(r.endTime),
Math.max(t, 0) >= Math.floor(r.startTime) &&
Math.max(t, 0) <= Math.ceil(r.endTime),
);

const processedRegions = createMemo(() =>
Expand Down

0 comments on commit 90a9af5

Please sign in to comment.