mn-angular-lib 1.0.104 → 1.0.105
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.
package/package.json
CHANGED
|
@@ -10,7 +10,10 @@
|
|
|
10
10
|
display: flex;
|
|
11
11
|
align-items: center;
|
|
12
12
|
justify-content: center;
|
|
13
|
-
|
|
13
|
+
/* `padding-bottom` is transitioned too so a mobile bottom sheet rides up smoothly in sync
|
|
14
|
+
with the soft keyboard (see the `--keyboard-height` handling in the mobile-sheet block). */
|
|
15
|
+
transition: transform 0.3s ease-in-out, filter 0.3s ease-in-out, opacity 0.3s ease-in-out,
|
|
16
|
+
padding-bottom 0.25s ease-out;
|
|
14
17
|
}
|
|
15
18
|
|
|
16
19
|
:host(.is-stacked) {
|
|
@@ -117,12 +120,24 @@
|
|
|
117
120
|
@media (max-width: 639.98px) {
|
|
118
121
|
:host(.mobile-sheet) {
|
|
119
122
|
align-items: flex-end;
|
|
123
|
+
/* Lift the whole sheet above the on-screen keyboard so focused fields stay visible.
|
|
124
|
+
On iOS the WKWebView does NOT resize when the keyboard opens (Capacitor `resize: none`,
|
|
125
|
+
chosen to avoid a relayout black-flash), so a bottom-anchored sheet would sit behind the
|
|
126
|
+
keyboard and no amount of inner scrolling can raise a low/last field above it — the sheet
|
|
127
|
+
itself must move up. Insetting this flex container by `--keyboard-height` (which the host
|
|
128
|
+
app publishes on iOS; 0 on web/Android where the view resizes natively) pushes the
|
|
129
|
+
flex-end-aligned sheet up by exactly the keyboard height. It's read as a plain CSS var,
|
|
130
|
+
so the library keeps no dependency on Capacitor. */
|
|
131
|
+
padding-bottom: var(--keyboard-height, 0px);
|
|
120
132
|
}
|
|
121
133
|
|
|
122
134
|
:host(.mobile-sheet) .modal-container {
|
|
123
135
|
width: 100%;
|
|
124
136
|
max-width: 100%;
|
|
125
|
-
|
|
137
|
+
/* Cap the sheet to the space left above the keyboard so a tall form shrinks and scrolls
|
|
138
|
+
internally instead of running off the top of the screen. Falls back to 92vh when the
|
|
139
|
+
keyboard is closed (`--keyboard-height` is 0). */
|
|
140
|
+
max-height: calc(92vh - var(--keyboard-height, 0px));
|
|
126
141
|
/* Keep the footer / last content clear of the iOS home indicator. The sheet
|
|
127
142
|
background extends into the inset so it reads as one continuous surface.
|
|
128
143
|
The container is border-box (Tailwind preflight), so this padding sits inside
|
|
@@ -163,6 +178,7 @@
|
|
|
163
178
|
short-circuits its close wait when reduced motion is requested.
|
|
164
179
|
========================= */
|
|
165
180
|
@media (prefers-reduced-motion: reduce) {
|
|
181
|
+
:host,
|
|
166
182
|
:host .modal-backdrop,
|
|
167
183
|
:host .modal-container {
|
|
168
184
|
animation-duration: 0.01ms !important;
|