【问题标题】:Transform and scale doesn't hides the overflowed images变换和缩放不会隐藏溢出的图像
【发布时间】:2019-10-23 11:20:19
【问题描述】:

我有一个包含图像的行列表。这些图像显示为小图像。但如果你将它们悬停,它们会被缩放。在缩放较小的图像时,它们会重叠。悬停图像下方的较小图像不会隐藏,而其上方较小的图像会隐藏。

我不确定我在哪里犯了错误。我用于缩放的类是,

        transition: all 0.6s;
        -ms-transform: scale(6.5, 6.5);
        -webkit-transform: scale(6.5, 6.5);
        transform: scale(6.5, 6.5);
        overflow: hidden;
        height: 100%;
        width: 100%;
        z-index: 2000 !important;
        border: 1px solid #e5e5e5;
        padding-top: 0px !important;
        padding-bottom: 0px !important;
    }
An example of how it is behaving is at,

https://jsfiddle.net/adnanj/1Lruex8f/

【问题讨论】:

    标签: html css twitter-bootstrap twitter-bootstrap-3


    【解决方案1】:

    这是由于图像上没有位置,没有position: ...z-index 将无法工作,在您的情况下,您可以使用position: relative

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2018-09-02
      • 2013-05-17
      • 2016-06-21
      • 1970-01-01
      • 2016-04-07
      • 1970-01-01
      • 2017-08-30
      • 2018-10-04
      相关资源
      最近更新 更多