mirror of
https://github.com/bellingcat/ukraine-timemap.git
synced 2026-06-08 03:18:36 +03:00
Fix invalid <rect> width error
This commit is contained in:
@@ -73,7 +73,10 @@ class TimelineCategories extends React.Component {
|
||||
className="drag-grabber"
|
||||
x={dims.marginLeft}
|
||||
y={dims.marginTop}
|
||||
width={dims.width - dims.marginLeft - dims.width_controls}
|
||||
width={Math.max(
|
||||
0,
|
||||
dims.width - dims.marginLeft - dims.width_controls
|
||||
)}
|
||||
height={dims.contentHeight}
|
||||
/>
|
||||
</g>
|
||||
|
||||
@@ -5,7 +5,7 @@ const TimelineClip = ({ dims }) => (
|
||||
<rect
|
||||
x={dims.marginLeft}
|
||||
y="0"
|
||||
width={dims.width - dims.marginLeft - dims.width_controls}
|
||||
width={Math.max(0, dims.width - dims.marginLeft - dims.width_controls)}
|
||||
height={dims.contentHeight}
|
||||
/>
|
||||
</clipPath>
|
||||
|
||||
Reference in New Issue
Block a user