CSS 不支持显示首字母

标签 css

我不知道如何让第二段显示在此示例代码中。我只在 Firefox 中试过。

<!DOCTYPE html>
<html>
<head>
<style>
body {
    display: none;
}
.show {
    display: initial;
}
</style>
</head>
<body>

<p>para 1</p>
<div class="show">
    <p>para 2</p>
</div>
</body>
</html>

最佳答案

body{
  visibility:hidden}
.show {
  visibility: visible;
  }
<p>para 1</p>
<div class="show">
    <p>para 2</p>
</div>

你可以试试这个

关于CSS 不支持显示首字母,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40382453/

相关文章:

css - 将 css 变量与 scss 变暗和变亮过滤器一起使用

css - 位置 :absolute breaks CSS dropdown

css - iPad 中的 jQuery 移动固定 header 问题

html - 强制图像不换行

html - 如何通过本地镜像的CSS使图像显示为背景

css - 在元素上添加图像

html - 在 css 中为自定义数据属性分配优先级

html - 如何排列 View 中的两个容器?

html - 用内容扩展 bootstrap div 宽度

css - 如何在没有 JavaScript 的情况下在 CSS 中制作 "title"(工具提示、弹出窗口、替代文本)以与 SVG 一起使用