mn-angular-lib 1.0.97 → 1.0.98
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -6783,13 +6783,6 @@ class MnModalShellComponent {
|
|
|
6783
6783
|
/** True while the user is actively dragging the grabber (disables snap transition). */
|
|
6784
6784
|
isDraggingSheet = false;
|
|
6785
6785
|
prevSample = null;
|
|
6786
|
-
/** True when this modal is currently presented as a bottom sheet (mobile config AND a
|
|
6787
|
-
* mobile-width viewport). Gates the swipe gesture and the open/drag haptics. */
|
|
6788
|
-
get isSheetViewport() {
|
|
6789
|
-
return this.isMobileSheet
|
|
6790
|
-
&& typeof window !== 'undefined'
|
|
6791
|
-
&& window.innerWidth <= MnModalShellComponent.SHEET_MAX_WIDTH;
|
|
6792
|
-
}
|
|
6793
6786
|
get hostClasses() {
|
|
6794
6787
|
const size = this.config.sizeWidth || ModalSize.MD;
|
|
6795
6788
|
const closing = this.isClosing ? ' closing' : '';
|
|
@@ -6817,10 +6810,6 @@ class MnModalShellComponent {
|
|
|
6817
6810
|
if (container) {
|
|
6818
6811
|
container.focus();
|
|
6819
6812
|
}
|
|
6820
|
-
// A light tick as the sheet slides up, matching native sheet presentation.
|
|
6821
|
-
if (this.isSheetViewport) {
|
|
6822
|
-
this.haptics?.impact('light');
|
|
6823
|
-
}
|
|
6824
6813
|
}
|
|
6825
6814
|
onSheetPointerDown(event) {
|
|
6826
6815
|
if (!this.isMobileSheet || !this.canClose)
|
|
@@ -6891,11 +6880,8 @@ class MnModalShellComponent {
|
|
|
6891
6880
|
return 0;
|
|
6892
6881
|
return (this.lastSample.y - this.prevSample.y) / dt;
|
|
6893
6882
|
}
|
|
6894
|
-
/** Springs the sheet back to
|
|
6883
|
+
/** Springs the sheet back to its resting position after a drag that didn't dismiss. */
|
|
6895
6884
|
snapBack() {
|
|
6896
|
-
if (this.sheetDragY > 0) {
|
|
6897
|
-
this.haptics?.impact('light');
|
|
6898
|
-
}
|
|
6899
6885
|
this.sheetDragY = 0;
|
|
6900
6886
|
}
|
|
6901
6887
|
/** Attempts to dismiss the modal. Resolves true if it was actually dismissed,
|