1. 사파리에서 가로모드일 때, 사이트 양쪽에 여백이 생기는 이슈
이거 뭐람..? 사파리는 왜 자꾸 혼자 놀지..??
해결 방법은 생각보다 간단하다.
<meta name='viewport' content='viewport-fit=cover'>
위와 같이 뷰포트에 viewport-fit=cover 를 추가해주면 된다.
참고 : https://webkit.org/blog/7929/designing-websites-for-iphone-x/
Designing Websites for iPhone X
The section below about safe area insets was updated on Oct 31, 2017 to reflect changes in the iOS 11.2 beta.
webkit.org
2. 사파리에서 확대되는 이슈
ios 에서는 더이상 뷰포트 user-scalable=no 를 추가해도 사용자 휴대폰 설정에 확대 축소 가능으로 되어있다면 제한할 수 없게 되었다.
이 때 touch-action: pan-y 를 사용하면 확대 축소를 제한하고 세로로 스크롤은 유지할 수 있다.
참고 : https://developer.mozilla.org/en-US/docs/Web/CSS/touch-action
touch-action - CSS: Cascading Style Sheets | MDN
The touch-action CSS property sets how an element's region can be manipulated by a touchscreen user (for example, by zooming features built into the browser).
developer.mozilla.org
https://wit.nts-corp.com/2021/07/16/6397
CSS touch-action 한눈에 알아보기 | WIT블로그
touch-action CSS touch-action 속성이 무엇이며 어떻게 동작하는지 테스트 및 gif로 보기 쉽게 정리해보았습니다.
wit.nts-corp.com
'ETC > 이슈노트' 카테고리의 다른 글
[이슈노트] iOS 이슈 모음 #7 (구버전에서 swiper 터치 슬라이드 이슈) (0) | 2023.04.10 |
---|---|
[이슈노트] iOS 이슈 모음 #6 (letter-spacing, position: sticky, label 텍스트 줄바꿈) (0) | 2022.11.17 |
[이슈노트] iOS 이슈 모음 #4 (tel) (0) | 2021.03.12 |
[이슈노트] iOS 이슈 모음 #3 (overflow : scroll, border-radius) (0) | 2020.07.29 |
[이슈노트] aOS 이슈 모음 #2 (노트10 크롬브라우저 내 가상선택자 이슈) (0) | 2020.05.07 |