Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/39.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/unit-testing/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Css 谷歌chrome开发工具don';我不能按照我的输入值工作_Css_Responsive Design_Google Chrome Devtools - Fatal编程技术网

Css 谷歌chrome开发工具don';我不能按照我的输入值工作

Css 谷歌chrome开发工具don';我不能按照我的输入值工作,css,responsive-design,google-chrome-devtools,Css,Responsive Design,Google Chrome Devtools,这是关于谷歌chrome开发工具和CSS的问题。正如下面的代码一样,虽然我在VSCODE的样式表中输入了“@media(max width:1000px)”,但这些工具会以750px(75%)的速度更改为响应性Web设计。我不缩放,在html上写“视口”。此外,比例为1.0。请告诉我解决办法 <!DOCTYPE html> <html lang="en"> <head> <meta charset="

这是关于谷歌chrome开发工具和CSS的问题。正如下面的代码一样,虽然我在VSCODE的样式表中输入了“@media(max width:1000px)”,但这些工具会以750px(75%)的速度更改为响应性Web设计。我不缩放,在html上写“视口”。此外,比例为1.0。请告诉我解决办法

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1.0" />
        <title>Document</title>
        <link rel="stylesheet" href="style.css" />
    </head>
    <body>
        <div></div>
    </body>
</html>

在我的评论中,原因是页面的缩放。通过恢复缩放,我可以解决这个问题。

您确定您正确地更改了视口而不是缩放吗?谢谢你的评论。在我得到那个之后,我再次确认了我的设置。然后,我找到了原因。原因是页面的缩放。我只是注意了触摸板的变焦。很抱歉问了这么一个基本的问题。在日语中,但我分享了我可以解决问题的链接。
div {
    width: max(400px, 50%);
    height: 400px;
    background-color: coral;
}
@media (max-width: 1000px){
    div {
        background-color: blue;
    }
}