1

我想使用这样的 CSS 媒体查询来定位移动设备:

@media (min--moz-device-pixel-ratio: 1.5),
       (-o-min-device-pixel-ratio: 3/2),
       (-webkit-min-device-pixel-ratio: 1.5),
       (min-resolution: 1.5dppx) {

   /* your retina rules here */
}

手机的正确设置是什么。假设我想避免定位平板电脑和更大的屏幕,而只定位手机?

4

1 回答 1

3

引用这个答案

min-width: 320px  // smartphones, iPhone, portrait 480x320 phones
min-width: 481px  // portrait e-readers (Nook/Kindle), smaller tablets @ 600 or @ 640 wide.
min-width: 641px  // portrait tablets, portrait iPad, landscape e-readers, landscape 800x480 and 854x480 phones
min-width: 961px  // tablet, landscape iPad, lo-res laptops ands desktops
min-width: 1025px // big landscape tablets, laptops, and desktops
min-width: 1281px // hi-res laptops and desktops
于 2013-04-02T08:47:01.867 回答