Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/35.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 背景图像图标尺寸不正确(较小)_Css - Fatal编程技术网

Css 背景图像图标尺寸不正确(较小)

Css 背景图像图标尺寸不正确(较小),css,Css,我有一个完整的黄色背景,在这个背景中有一些图标。例如,在大屏幕1920x1080中,我希望有17列图标水平占据整个屏幕的黄色背景,只有4行图标 问题是图标的尺寸不正确,更小,因此我得到的不是17列图标,而是30多列图标。我得到了8行图标,而不是4行 你知道怎么解决这个问题吗 html: 例如: 试试背景:url(https://preview.ibb.co/cxLLc5/img22.png)0/100%。把50%换成100%。这将获得4行图标。谢谢,现在只显示4行图标,但图标与图像的大小不同,图

我有一个完整的黄色背景,在这个背景中有一些图标。例如,在大屏幕1920x1080中,我希望有17列图标水平占据整个屏幕的黄色背景,只有4行图标

问题是图标的尺寸不正确,更小,因此我得到的不是17列图标,而是30多列图标。我得到了8行图标,而不是4行

你知道怎么解决这个问题吗

html:

例如:

试试
背景:url(https://preview.ibb.co/cxLLc5/img22.png)0/100%。把50%换成100%。这将获得4行图标。谢谢,现在只显示4行图标,但图标与图像的大小不同,图标仍然较小,因此有很多列带有图标。
background:url(https://preview.ibb.co/cxLLc5/img22.png) 0 0 / 50% 100%;。您可以将第一个
auto
更改为
50%
,并对其进行处理,但是形状可能与原始图像不成比例。谢谢您的回答。但是,50%和100%的图像不会出现在后面。
<section class="container content-search">
  <div class="div">
    <h1>Title</h1>

  </div>
  <section>
.content-search {
  height: 100%;
  width: 100%;
  position: relative;
  background: rgba(255, 255, 0, .54);
  min-height: 360px;
}

.content-search:after {
  content: '';
  position: absolute;
  z-index: -1;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: url(https://preview.ibb.co/cxLLc5/img22.png) 0 0 / auto 50%;
  opacity: .25;
}

.div {
  width: 60%;
  margin: 0 auto;
  padding: 20px 0;
}