mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-10 00:27:41 +08:00
fix: safari no longer adjusts text in landscape (#27787)
Issue number: resolves #27782 --------- <!-- Please do not submit updates to dependencies unless it fixes an issue. --> <!-- Please try to limit your pull request to one type (bugfix, feature, etc). Submit multiple pull requests if needed. --> ## What is the current behavior? <!-- Please describe the current behavior that you are modifying. --> Ionic uses text-size-adjust to prevent browsers from resizing text in landscape mode in order to match native app behavior. However, WebKit only supports `-webkit-text-size-adjust`, so this fix never applied to iOS devices. https://caniuse.com/?search=text-size-adjust ## What is the new behavior? <!-- Please describe the behavior or changes that are being added by this PR. --> - Add `-webkit-text-size-adjust` where we use `text-size-adjust` ## Does this introduce a breaking change? - [ ] Yes - [x] No <!-- If this introduces a breaking change, please describe the impact and migration path for existing applications below. --> ## Other information <!-- Any other information that is important to this PR such as screenshots of how the component looks before and after the change. --> **Landscape** | main | branch | | - | - | |  |  | **Portrait** (Should be no changes) | main | branch | | - | - | |  |  |
This commit is contained in:
@ -17,6 +17,7 @@
|
||||
html {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
-webkit-text-size-adjust: 100%;
|
||||
|
||||
text-size-adjust: 100%;
|
||||
}
|
||||
@ -80,6 +81,7 @@ body {
|
||||
word-wrap: break-word;
|
||||
|
||||
overscroll-behavior-y: none;
|
||||
-webkit-text-size-adjust: none;
|
||||
|
||||
text-size-adjust: none;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user