drop-list-ref.ts (material2-7.3.3) | : | drop-list-ref.ts (material2-7.3.4) | ||
---|---|---|---|---|
skipping to change at line 132 | skipping to change at line 132 | |||
*/ | */ | |||
private _activeDraggables: DragRef[]; | private _activeDraggables: DragRef[]; | |||
/** | /** | |||
* Keeps track of the item that was last swapped with the dragged item, as | * Keeps track of the item that was last swapped with the dragged item, as | |||
* well as what direction the pointer was moving in when the swap occured. | * well as what direction the pointer was moving in when the swap occured. | |||
*/ | */ | |||
private _previousSwap = {drag: null as DragRef | null, delta: 0}; | private _previousSwap = {drag: null as DragRef | null, delta: 0}; | |||
/** Draggable items in the container. */ | /** Draggable items in the container. */ | |||
private _draggables: DragRef[]; | private _draggables: ReadonlyArray<DragRef>; | |||
/** Drop lists that are connected to the current one. */ | /** Drop lists that are connected to the current one. */ | |||
private _siblings: DropListRef[] = []; | private _siblings: ReadonlyArray<DropListRef> = []; | |||
/** Direction in which the list is oriented. */ | /** Direction in which the list is oriented. */ | |||
private _orientation: 'horizontal' | 'vertical' = 'vertical'; | private _orientation: 'horizontal' | 'vertical' = 'vertical'; | |||
/** Connected siblings that currently have a dragged item. */ | /** Connected siblings that currently have a dragged item. */ | |||
private _activeSiblings = new Set<DropListRef>(); | private _activeSiblings = new Set<DropListRef>(); | |||
/** Layout direction of the drop list. */ | /** Layout direction of the drop list. */ | |||
private _direction: Direction = 'ltr'; | private _direction: Direction = 'ltr'; | |||
skipping to change at line 258 | skipping to change at line 258 | |||
previousContainer, | previousContainer, | |||
isPointerOverContainer | isPointerOverContainer | |||
}); | }); | |||
} | } | |||
/** | /** | |||
* Sets the draggable items that are a part of this list. | * Sets the draggable items that are a part of this list. | |||
* @param items Items that are a part of this list. | * @param items Items that are a part of this list. | |||
*/ | */ | |||
withItems(items: DragRef[]): this { | withItems(items: DragRef[]): this { | |||
this._draggables = items.slice(); | this._draggables = items; | |||
items.forEach(item => item._withDropContainer(this)); | items.forEach(item => item._withDropContainer(this)); | |||
return this; | return this; | |||
} | } | |||
/** Sets the layout direction of the drop list. */ | /** Sets the layout direction of the drop list. */ | |||
withDirection(direction: Direction): this { | withDirection(direction: Direction): this { | |||
this._direction = direction; | this._direction = direction; | |||
return this; | return this; | |||
} | } | |||
End of changes. 3 change blocks. | ||||
3 lines changed or deleted | 3 lines changed or added |