gpt4 book ai didi

html - 灯箱的奇怪行为

转载 作者:行者123 更新时间:2023-11-27 23:05:35 28 4
gpt4 key购买 nike

我刚刚尝试了 CSS code由@ongtiffany 于 codepen.io 撰写关于灯箱。代码很棒,但如果我在独立测试中使用它(如下)

   <body>
<a class="lightbox" href="#first">
<img src="https://drive.google.com/uc?export=view&id=1cKXuGQzX3t65NoYEKfuI4wBHwxUM9wjH"/>
</a>
<div class="lightbox-target" id="first">
<img src="https://drive.google.com/uc?export=view&id=1cKXuGQzX3t65NoYEKfuI4wBHwxUM9wjH"/>
<a class="lightbox-close" href="#"></a>
</div>
<a class="lightbox" href="#second">
<img src="https://drive.google.com/uc?export=view&id=1kLe9YXiM2XdgwKkATwkhfk6kzdnKIefi"/>
</a>
<div class="lightbox-target" id="second">
<img src="https://drive.google.com/uc?export=view&id=1kLe9YXiM2XdgwKkATwkhfk6kzdnKIefi"/>
<a class="lightbox-close" href="#"></a>
</div>
</body>
</html>

它在两张图片之间给我留下了一个奇怪的“_”符号。

你看得到吗?有什么消除它的建议吗?

还有一个问题?有什么方法可以通过按“ESC”键关闭窗口?

最佳答案

试试这个

a.lightbox{
text-decoration:none;
}

输出

enter image description here

关于html - 灯箱的奇怪行为,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58757343/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com