Skip to content

Commit

Permalink
fix for dragging while start not editable
Browse files Browse the repository at this point in the history
  • Loading branch information
arshaw committed Mar 18, 2019
1 parent c4b9bae commit 397fadd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
8 changes: 7 additions & 1 deletion src/core/structs/event-mutation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,13 @@ function applyMutationToEventInstance(
}
} else if (
mutation.endDelta &&
(eventConfig.durationEditable || !willDeltasAffectDuration(mutation.startDelta || null, mutation.endDelta))
(
eventConfig.durationEditable ||
!willDeltasAffectDuration( // TODO: nonDRY logic above
eventConfig.startEditable ? mutation.startDelta : null,
mutation.endDelta
)
)
) {
copy.range = {
start: copy.range.start,
Expand Down
2 changes: 1 addition & 1 deletion src/interaction/interactions/EventDragging.ts
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ export default class EventDragging extends Interaction { // TODO: rename to Even
mirror.revertDuration = component.opt('dragRevertDuration')

let isValid =
this.component.isValidSegDownEl(origTarget) &&
component.isValidSegDownEl(origTarget) &&
!elementClosest(origTarget, '.fc-resizer')

dragging.setIgnoreMove(!isValid)
Expand Down

0 comments on commit 397fadd

Please sign in to comment.