Stop the mobile focus zoom on text fields

This commit is contained in:
Fisto
2026-09-22 13:44:11 +02:00
parent 29df3c6870
commit 938fdafcaf
2 changed files with 33 additions and 0 deletions
+27
View File
@@ -2136,3 +2136,30 @@ a.vk-attachment:hover {
right: calc(50% - 26px);
}
}
/* ── Mobile form controls ─────────────────────────────────────────────────────
iOS Safari zooms the whole page when a focused text field renders below 16px,
and it does not always zoom back out when the field loses focus. Force 16px
on text-entry controls at the mobile breakpoint, stop the landscape text
inflation, and drop the double-tap zoom delay on controls. Sliders, check-
boxes, and radios keep their current sizing (they never trigger focus zoom,
and em-based slider thumbs must keep their own font size). */
html {
-webkit-text-size-adjust: 100%;
text-size-adjust: 100%;
}
input,
textarea,
select,
button {
touch-action: manipulation;
}
@media (max-width: 768px) {
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]),
textarea,
select {
font-size: 16px !important;
}
}