Media Queries - CSS only for iPhone landscape

后端 未结 4 1987
抹茶落季
抹茶落季 2021-02-01 22:59

Are the same methods used to write CSS only for iPhone in landscape mode?

4条回答
  •  余生分开走
    2021-02-01 23:22

    If I understand you correctly, and you want to know the media queries to target a smartphone like the iPhone only when it is held horizontally, try something like this:

    @media only screen and (min-width: 480px) and (max-width: 767px) {
        /* styles go here */
        body {
    
        }
    }
    

提交回复
热议问题