Skip to content

Commit

Permalink
feat: upgrade draggable library
Browse files Browse the repository at this point in the history
  • Loading branch information
mattlewis92 committed Jun 22, 2018
1 parent bca145e commit d9e76d4
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 4 deletions.
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@
"@angular/core": ">=6.0.0 <8.0.0"
},
"dependencies": {
"angular-draggable-droppable": "^4.0.0-beta.5",
"angular-draggable-droppable": "^4.0.0-beta.6",
"angular-resizable-element": "^3.0.0",
"calendar-utils": "^0.2.0-alpha.7",
"positioning": "^1.3.1"
Expand Down
2 changes: 2 additions & 0 deletions src/modules/month/calendar-month-cell.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ import { trackByEventId } from '../common/util';
[tooltipTemplate]="tooltipTemplate"
[tooltipAppendToBody]="tooltipAppendToBody"
mwlDraggable
[class.cal-draggable]="event.draggable"
dragActiveClass="cal-drag-active"
[dropData]="{event: event}"
[dragAxis]="{x: event.draggable, y: event.draggable}"
(mwlClick)="eventClicked.emit({ event: event })">
Expand Down
4 changes: 4 additions & 0 deletions src/modules/month/calendar-month-view.scss
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,10 @@
}
}

.cal-draggable {
cursor: move;
}

.cal-drag-active * {
pointer-events: none;
}
Expand Down
1 change: 1 addition & 0 deletions src/modules/month/calendar-open-day-events.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import { trackByEventId } from '../common/util';
*ngFor="let event of events; trackBy:trackByEventId"
[ngClass]="event?.cssClass"
mwlDraggable
[class.cal-draggable]="event.draggable"
dragActiveClass="cal-drag-active"
[dropData]="{event: event}"
[dragAxis]="{x: event.draggable, y: event.draggable}">
Expand Down

0 comments on commit d9e76d4

Please sign in to comment.