@@ -38,9 +38,9 @@ class MDCBottomSheetControllerDelegateImpl extends NSObject {
3838 //normalized = (value - min) / (max - min);
3939 let normalized = 0 ;
4040 if ( yOffset + bottomPadding > heightScreen - heightCollapsedSheet ) {
41- normalized = ( ( heightScreen - yOffset - bottomPadding ) - 0 ) / ( heightCollapsedSheet - 0 ) - 1 ;
41+ normalized = ( heightScreen - yOffset - bottomPadding - 0 ) / ( heightCollapsedSheet - 0 ) - 1 ;
4242 } else {
43- normalized = ( ( heightScreen - yOffset ) - heightCollapsedSheet ) / ( heightScreen - heightCollapsedSheet ) ;
43+ normalized = ( heightScreen - yOffset - heightCollapsedSheet ) / ( heightScreen - heightCollapsedSheet ) ;
4444 }
4545 owner . _onChangeStateBottomSheetCallback ( StateBottomSheet . DRAGGING , normalized ) ;
4646 } else {
@@ -71,7 +71,7 @@ class MDCBottomSheetControllerDelegateImpl extends NSObject {
7171 }
7272 } else {
7373 if ( owner && owner . _onChangeStateBottomSheetCallback ) {
74- owner . _onChangeStateBottomSheetCallback ( state === MDCSheetState . Extended ? StateBottomSheet . EXPANDED : StateBottomSheet . EXPANDED )
74+ owner . _onChangeStateBottomSheetCallback ( state === MDCSheetState . Extended ? StateBottomSheet . EXPANDED : StateBottomSheet . EXPANDED ) ;
7575 }
7676 }
7777 }
@@ -443,7 +443,7 @@ export class ViewWithBottomSheet extends ViewWithBottomSheetBase {
443443 if ( options . trackingScrollView ) {
444444 const scrollView = this . getViewById ( options . trackingScrollView ) ;
445445 if ( scrollView && scrollView . nativeViewProtected instanceof UIScrollView ) {
446- ( bottomSheet . presentationController as MDCBottomSheetPresentationController ) . trackingScrollView = scrollView . nativeViewProtected ;
446+ bottomSheet . trackingScrollView = scrollView . nativeViewProtected ;
447447 }
448448 }
449449 controller . nsAnimated = true ;
@@ -499,4 +499,4 @@ export function install() {
499499 mixinInstalled = true ;
500500 overrideBottomSheet ( ) ;
501501 }
502- }
502+ }
0 commit comments