@@ -3238,8 +3238,8 @@ describe('CdkDrag', () => {
3238
3238
`
3239
3239
} )
3240
3240
class StandaloneDraggable {
3241
- @ViewChild ( 'dragElement' ) dragElement : ElementRef < HTMLElement > ;
3242
- @ViewChild ( CdkDrag ) dragInstance : CdkDrag ;
3241
+ @ViewChild ( 'dragElement' , { static : false } ) dragElement : ElementRef < HTMLElement > ;
3242
+ @ViewChild ( CdkDrag , { static : false } ) dragInstance : CdkDrag ;
3243
3243
startedSpy = jasmine . createSpy ( 'started spy' ) ;
3244
3244
endedSpy = jasmine . createSpy ( 'ended spy' ) ;
3245
3245
releasedSpy = jasmine . createSpy ( 'released spy' ) ;
@@ -3256,8 +3256,8 @@ class StandaloneDraggable {
3256
3256
`
3257
3257
} )
3258
3258
class StandaloneDraggableWithOnPush {
3259
- @ViewChild ( 'dragElement' ) dragElement : ElementRef < HTMLElement > ;
3260
- @ViewChild ( CdkDrag ) dragInstance : CdkDrag ;
3259
+ @ViewChild ( 'dragElement' , { static : false } ) dragElement : ElementRef < HTMLElement > ;
3260
+ @ViewChild ( CdkDrag , { static : false } ) dragInstance : CdkDrag ;
3261
3261
}
3262
3262
3263
3263
@Component ( {
@@ -3270,7 +3270,7 @@ class StandaloneDraggableWithOnPush {
3270
3270
`
3271
3271
} )
3272
3272
class StandaloneDraggableSvg {
3273
- @ViewChild ( 'dragElement' ) dragElement : ElementRef < SVGElement > ;
3273
+ @ViewChild ( 'dragElement' , { static : false } ) dragElement : ElementRef < SVGElement > ;
3274
3274
}
3275
3275
3276
3276
@Component ( {
@@ -3282,10 +3282,10 @@ class StandaloneDraggableSvg {
3282
3282
`
3283
3283
} )
3284
3284
class StandaloneDraggableWithHandle {
3285
- @ViewChild ( 'dragElement' ) dragElement : ElementRef < HTMLElement > ;
3286
- @ViewChild ( 'handleElement' ) handleElement : ElementRef < HTMLElement > ;
3287
- @ViewChild ( CdkDrag ) dragInstance : CdkDrag ;
3288
- @ViewChild ( CdkDragHandle ) handleInstance : CdkDragHandle ;
3285
+ @ViewChild ( 'dragElement' , { static : false } ) dragElement : ElementRef < HTMLElement > ;
3286
+ @ViewChild ( 'handleElement' , { static : false } ) handleElement : ElementRef < HTMLElement > ;
3287
+ @ViewChild ( CdkDrag , { static : false } ) dragInstance : CdkDrag ;
3288
+ @ViewChild ( CdkDragHandle , { static : false } ) handleInstance : CdkDragHandle ;
3289
3289
}
3290
3290
3291
3291
@Component ( {
@@ -3300,8 +3300,8 @@ class StandaloneDraggableWithHandle {
3300
3300
`
3301
3301
} )
3302
3302
class StandaloneDraggableWithDelayedHandle {
3303
- @ViewChild ( 'dragElement' ) dragElement : ElementRef < HTMLElement > ;
3304
- @ViewChild ( 'handleElement' ) handleElement : ElementRef < HTMLElement > ;
3303
+ @ViewChild ( 'dragElement' , { static : false } ) dragElement : ElementRef < HTMLElement > ;
3304
+ @ViewChild ( 'handleElement' , { static : false } ) handleElement : ElementRef < HTMLElement > ;
3305
3305
showHandle = false ;
3306
3306
}
3307
3307
@@ -3320,8 +3320,8 @@ class StandaloneDraggableWithDelayedHandle {
3320
3320
`
3321
3321
} )
3322
3322
class StandaloneDraggableWithIndirectHandle {
3323
- @ViewChild ( 'dragElement' ) dragElement : ElementRef < HTMLElement > ;
3324
- @ViewChild ( 'handleElement' ) handleElement : ElementRef < HTMLElement > ;
3323
+ @ViewChild ( 'dragElement' , { static : false } ) dragElement : ElementRef < HTMLElement > ;
3324
+ @ViewChild ( 'handleElement' , { static : false } ) handleElement : ElementRef < HTMLElement > ;
3325
3325
}
3326
3326
3327
3327
@@ -3345,7 +3345,7 @@ class StandaloneDraggableWithIndirectHandle {
3345
3345
`
3346
3346
} )
3347
3347
class StandaloneDraggableWithMultipleHandles {
3348
- @ViewChild ( 'dragElement' ) dragElement : ElementRef < HTMLElement > ;
3348
+ @ViewChild ( 'dragElement' , { static : false } ) dragElement : ElementRef < HTMLElement > ;
3349
3349
@ViewChildren ( CdkDragHandle ) handles : QueryList < CdkDragHandle > ;
3350
3350
}
3351
3351
@@ -3371,7 +3371,7 @@ const DROP_ZONE_FIXTURE_TEMPLATE = `
3371
3371
@Component ( { template : DROP_ZONE_FIXTURE_TEMPLATE } )
3372
3372
class DraggableInDropZone {
3373
3373
@ViewChildren ( CdkDrag ) dragItems : QueryList < CdkDrag > ;
3374
- @ViewChild ( CdkDropList ) dropInstance : CdkDropList ;
3374
+ @ViewChild ( CdkDropList , { static : false } ) dropInstance : CdkDropList ;
3375
3375
items = [
3376
3376
{ value : 'Zero' , height : ITEM_HEIGHT , margin : 0 } ,
3377
3377
{ value : 'One' , height : ITEM_HEIGHT , margin : 0 } ,
@@ -3427,7 +3427,7 @@ class DraggableInOnPushDropZone extends DraggableInDropZone {}
3427
3427
} )
3428
3428
class DraggableInHorizontalDropZone {
3429
3429
@ViewChildren ( CdkDrag ) dragItems : QueryList < CdkDrag > ;
3430
- @ViewChild ( CdkDropList ) dropInstance : CdkDropList ;
3430
+ @ViewChild ( CdkDropList , { static : false } ) dropInstance : CdkDropList ;
3431
3431
items = [
3432
3432
{ value : 'Zero' , width : ITEM_WIDTH , margin : 0 } ,
3433
3433
{ value : 'One' , width : ITEM_WIDTH , margin : 0 } ,
@@ -3461,7 +3461,7 @@ class DraggableInHorizontalDropZone {
3461
3461
`
3462
3462
} )
3463
3463
class DraggableInDropZoneWithCustomPreview {
3464
- @ViewChild ( CdkDropList ) dropInstance : CdkDropList ;
3464
+ @ViewChild ( CdkDropList , { static : false } ) dropInstance : CdkDropList ;
3465
3465
@ViewChildren ( CdkDrag ) dragItems : QueryList < CdkDrag > ;
3466
3466
items = [ 'Zero' , 'One' , 'Two' , 'Three' ] ;
3467
3467
boundarySelector : string ;
@@ -3606,9 +3606,9 @@ class ConnectedDropZonesViaGroupDirective extends ConnectedDropZones {
3606
3606
`
3607
3607
} )
3608
3608
class DraggableWithAlternateRoot {
3609
- @ViewChild ( 'dragElement' ) dragElement : ElementRef < HTMLElement > ;
3610
- @ViewChild ( 'dragRoot' ) dragRoot : ElementRef < HTMLElement > ;
3611
- @ViewChild ( CdkDrag ) dragInstance : CdkDrag ;
3609
+ @ViewChild ( 'dragElement' , { static : false } ) dragElement : ElementRef < HTMLElement > ;
3610
+ @ViewChild ( 'dragRoot' , { static : false } ) dragRoot : ElementRef < HTMLElement > ;
3611
+ @ViewChild ( CdkDrag , { static : false } ) dragInstance : CdkDrag ;
3612
3612
rootElementSelector : string ;
3613
3613
}
3614
3614
@@ -3667,9 +3667,9 @@ class ConnectedDropZonesWithSingleItems {
3667
3667
`
3668
3668
} )
3669
3669
class NestedDropListGroups {
3670
- @ViewChild ( 'group' ) group : CdkDropListGroup < CdkDropList > ;
3671
- @ViewChild ( 'listOne' ) listOne : CdkDropList ;
3672
- @ViewChild ( 'listTwo' ) listTwo : CdkDropList ;
3670
+ @ViewChild ( 'group' , { static : false } ) group : CdkDropListGroup < CdkDropList > ;
3671
+ @ViewChild ( 'listOne' , { static : false } ) listOne : CdkDropList ;
3672
+ @ViewChild ( 'listTwo' , { static : false } ) listTwo : CdkDropList ;
3673
3673
}
3674
3674
3675
3675
@@ -3694,7 +3694,7 @@ class DraggableOnNgContainer {}
3694
3694
} )
3695
3695
class DraggableInDropZoneWithoutEvents {
3696
3696
@ViewChildren ( CdkDrag ) dragItems : QueryList < CdkDrag > ;
3697
- @ViewChild ( CdkDropList ) dropInstance : CdkDropList ;
3697
+ @ViewChild ( CdkDropList , { static : false } ) dropInstance : CdkDropList ;
3698
3698
items = [
3699
3699
{ value : 'Zero' , height : ITEM_HEIGHT } ,
3700
3700
{ value : 'One' , height : ITEM_HEIGHT } ,
0 commit comments