Skip to content

Commit 9e800dd

Browse files
authored
Merge pull request #248 from avalonmediasystem/nested-dnd
Fix DnD drop-zone calculation for nested timespans
2 parents bcacceb + 218a5f5 commit 9e800dd

File tree

10 files changed

+522
-142
lines changed

10 files changed

+522
-142
lines changed

public/dev/manifest.json

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -391,6 +391,36 @@
391391
{
392392
"id": "http://localhost:3001/dev/lunchroom_manners/canvas/1#t=323,333",
393393
"type": "Canvas"
394+
},
395+
{
396+
"id": "http://localhost:3001/dev/lunchroom_manners/canvas/range/2-2-1-1",
397+
"type": "Range",
398+
"label": {
399+
"en": [
400+
"Not Talking Loudly"
401+
]
402+
},
403+
"items": [
404+
{
405+
"id": "http://localhost:3001/dev/lunchroom_manners/canvas/1#t=323,330",
406+
"type": "Canvas"
407+
},
408+
{
409+
"id": "http://localhost:3001/dev/lunchroom_manners/canvas/range/2-2-1-1-1",
410+
"type": "Range",
411+
"label": {
412+
"en": [
413+
"Waiting for Friends"
414+
]
415+
},
416+
"items": [
417+
{
418+
"id": "http://localhost:3001/dev/lunchroom_manners/canvas/1#t=324,329",
419+
"type": "Canvas"
420+
}
421+
]
422+
}
423+
]
394424
}
395425
]
396426
},

src/components/ListItem.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -90,13 +90,11 @@ const ListItem = ({ item, children }) => {
9090
}
9191
};
9292

93-
const { begin, end, items, label, type, active, valid } = item;
93+
const { begin, end, nestedSpan, items, label, type, active, valid } = item;
9494

9595
const itemProp = {
9696
childrenCount: items ? items.length : 0,
97-
label: label,
98-
type: type,
99-
active: active,
97+
label, type, active, nestedSpan
10098
};
10199

102100
/**

src/components/ListItemControls.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import PopoverBody from 'react-bootstrap/PopoverBody';
77
import PopoverHeader from 'react-bootstrap/PopoverHeader';
88
import PropTypes from 'prop-types';
99
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
10-
import { connect, useDispatch, useSelector } from 'react-redux';
10+
import { useDispatch, useSelector } from 'react-redux';
1111
import {
1212
handleEditingTimespans,
1313
updateStructureStatus,

0 commit comments

Comments
 (0)