首页 \ 问答 \ 父元素显示时显示HTML子元素:无(Display HTML child element when parent element is display:none)

父元素显示时显示HTML子元素:无(Display HTML child element when parent element is display:none)

当它的父元素是display时,是否有任何显示子元素的机制:none?

这种情况是隐藏选项卡上的验证错误。 即使该字段已隐藏,我也想要显示错误消息。

一个真正简化的JSFiddle的情况是在这里http://jsfiddle.net/vLYnk/

标记:

<ul>
    <li>One</li>
    <li class="hide">
        Two
        <ul>
            <li class="reshow">Re Show Me</li>
            <li>Inner 2</li>
        </ul>
    </li>
    <li>Three</li>
</ul>

CSS:

.hide {display: none}
.reshow {display: block !important; position: fixed; top: 0; left: 0;}

我猜这是不可能的,因为孩子没有背景,但以防万一?


Is there any mechanism to display a child element when its parent element is display: none?

The situation is a validation error on a hidden tab. I want to surface the error message, even though the field is hidden.

A really simplified JSFiddle of the situation is here http://jsfiddle.net/vLYnk/

Markup:

<ul>
    <li>One</li>
    <li class="hide">
        Two
        <ul>
            <li class="reshow">Re Show Me</li>
            <li>Inner 2</li>
        </ul>
    </li>
    <li>Three</li>
</ul>

CSS:

.hide {display: none}
.reshow {display: block !important; position: fixed; top: 0; left: 0;}

I'm guessing this is impossible as the child would have no context, but just in case???


原文:https://stackoverflow.com/questions/12956937
更新时间:2022-03-28 16:03

最满意答案

警告:删除.kibana索引会让你失去所有的kibana设置(索引,图表,仪表板)

此行为有时是由现有的.kibana索引引起的。 请使用以下命令删除.kibana中的.kibana索引:

curl -XDELETE http://localhost:9200/.kibana

删除索引后,重新启动Kibana。

如果问题仍然存在, 并且您愿意丢失任何现有数据 ,则可以尝试使用以下命令删除所有索引:

curl -XDELETE http://localhost:9200/*

随后重新启动Kibana。

注意: localhost:9200是elasticsearch服务器的host:port ,在您的情况下可能会有所不同。


Warning: Removing .kibana index will make you lose all your kibana settings (indexes, graphs, dashboards)

This behavior is sometimes caused by an existing .kibana index. Kindly delete the .kibana index in elasticsearch using following command:

curl -XDELETE http://localhost:9200/.kibana

After deleting the index, restart Kibana.

If the problem still persists, and you are willing to lose any existing data, you can try deleting all indexes using following command:

curl -XDELETE http://localhost:9200/*

Followed by restarting Kibana.

Note: localhost:9200 is the elasticsearch server's host:port, which may be different in your case.

相关问答

更多
  • 警告:删除.kibana索引会让你失去所有的kibana设置(索引,图表,仪表板) 此行为有时是由现有的.kibana索引引起的。 请使用以下命令删除.kibana中的.kibana索引: curl -XDELETE http://localhost:9200/.kibana 删除索引后,重新启动Kibana。 如果问题仍然存在, 并且您愿意丢失任何现有数据 ,则可以尝试使用以下命令删除所有索引: curl -XDELETE http://localhost:9200/* 随后重新启动Kibana。 注 ...
  • 使用下一个查询:GET /.kibana/index-pattern/_search Use the next query: GET /.kibana/index-pattern/_search
  • 良好的附加信息,以及对这种行为的确认 ,你可以在这个github问题中找到,也可以在这个问题中找到。 作为总结 ... “ 部落节点”文档指出,您无法执行“创建索引”等主级写入操作,这是第一次使用Kibana 4时需要的。 仅仅创建索引是不够的,因为Put Mapping也是必需的,并且也是一个主级写操作。 作为解决方法,首先调出Kibana 4实例并将其配置为直接指向其中一个远程集群,以便它将初始化该集群中的.kibana索引 。 当Kibana 4连接到这个单一集群时,创建并保存将用于部落节点的索引设置 ...
  • 问题是两个logstash实例正在运行。 一个是在我不知道的背景中。 所以我杀了一个它现在正在工作。 The issue was that two logstash instances were running. One was in the background which I was not aware of. So I killed one and it's working now.
  • 默认情况下禁用此功能。 您可以通过在映射中添加"_index" : { "enabled" : true }来启用它。 来源: github上的问题 This is disabled by default. You can enable it by adding "_index" : { "enabled" : true } to your mapping. Source: Issue on github
  • 很明显,您将无法在logstash中找到使用logstash创建的索引,除非您在Kibana的Managemen部分内手动创建Kibana 。 确保您使用logstash创建的logstash名称相同。 看看文档 ,其中传达: 定义索引模式时,与Elasticsearch匹配的索引必须存在。 这些指数必须包含数据。 这几乎说明你应该在Kibana创建索引。 希望能帮助到你! I have actually succeeded to create index even without first creati ...
  • 您无法使用ElasticSearch DSL查询直接构建Kibana可视化。 您可能想尝试: 新的可视化 在查询栏中写: service:http 在X轴上添加一个存储桶,选择术语agreggation,为主机选择您的字段。 You can't directly build Kibana visualization using ElasticSearch DSL query. You might want to try : New Visualization Write in the query bar : ...
  • 这是与其他问题相同的问题以及它不起作用的原因与映射visit_mapping从未通过put_mapping安装的put_mapping 。 因此,ES根据visit文档中发送的内容创建了自己的映射。 要解决此问题,只需在索引第一个visit文档之前使用您的映射调用put_mapping 。 This is the same issue as this other issue and the reason it doesn't work has to do with the fact that the map ...
  • 当您尝试使用已存在的名称保存kibana对象(已保存的搜索,可视化或仪表板)时,通常会发生这种情况(因为kibana也为id使用了一个名称的slug)。 抛出此异常是因为kibana故意发送带有&op_type=create的REST请求,当对象id已经存在时抛出异常。 然后kibana通过询问您是否确定要覆盖正在保存的对象来处理此问题,如果单击“是”,则会进行相同的REST调用但不使用op_type=create 。 This usually happens when you try to save a ...
  • 下一个kibana插件允许您可视化多边形。 如果您使用kibana 5.3,插件安装不支持5.2以上的安装操作您可以选择以下选项之一: 1)在插件github中打开问题 2)克隆插件,将zip文件解压缩到插件目录vin kibana home,cd到你下载的插件并输入bower install,重启kibana The next kibana plugin allow you visualize polygons. If you using kibana 5.3, the plugin installati ...

相关文章

更多

最新问答

更多
  • 您如何使用git diff文件,并将其应用于同一存储库的副本的本地分支?(How do you take a git diff file, and apply it to a local branch that is a copy of the same repository?)
  • 将长浮点值剪切为2个小数点并复制到字符数组(Cut Long Float Value to 2 decimal points and copy to Character Array)
  • OctoberCMS侧边栏不呈现(OctoberCMS Sidebar not rendering)
  • 页面加载后对象是否有资格进行垃圾回收?(Are objects eligible for garbage collection after the page loads?)
  • codeigniter中的语言不能按预期工作(language in codeigniter doesn' t work as expected)
  • 在计算机拍照在哪里进入
  • 使用cin.get()从c ++中的输入流中丢弃不需要的字符(Using cin.get() to discard unwanted characters from the input stream in c++)
  • No for循环将在for循环中运行。(No for loop will run inside for loop. Testing for primes)
  • 单页应用程序:页面重新加载(Single Page Application: page reload)
  • 在循环中选择具有相似模式的列名称(Selecting Column Name With Similar Pattern in a Loop)
  • System.StackOverflow错误(System.StackOverflow error)
  • KnockoutJS未在嵌套模板上应用beforeRemove和afterAdd(KnockoutJS not applying beforeRemove and afterAdd on nested templates)
  • 散列包括方法和/或嵌套属性(Hash include methods and/or nested attributes)
  • android - 如何避免使用Samsung RFS文件系统延迟/冻结?(android - how to avoid lag/freezes with Samsung RFS filesystem?)
  • TensorFlow:基于索引列表创建新张量(TensorFlow: Create a new tensor based on list of indices)
  • 企业安全培训的各项内容
  • 错误:RPC失败;(error: RPC failed; curl transfer closed with outstanding read data remaining)
  • C#类名中允许哪些字符?(What characters are allowed in C# class name?)
  • NumPy:将int64值存储在np.array中并使用dtype float64并将其转换回整数是否安全?(NumPy: Is it safe to store an int64 value in an np.array with dtype float64 and later convert it back to integer?)
  • 注销后如何隐藏导航portlet?(How to hide navigation portlet after logout?)
  • 将多个行和可变行移动到列(moving multiple and variable rows to columns)
  • 提交表单时忽略基础href,而不使用Javascript(ignore base href when submitting form, without using Javascript)
  • 对setOnInfoWindowClickListener的意图(Intent on setOnInfoWindowClickListener)
  • Angular $资源不会改变方法(Angular $resource doesn't change method)
  • 在Angular 5中不是一个函数(is not a function in Angular 5)
  • 如何配置Composite C1以将.m和桌面作为同一站点提供服务(How to configure Composite C1 to serve .m and desktop as the same site)
  • 不适用:悬停在悬停时:在元素之前[复制](Don't apply :hover when hovering on :before element [duplicate])
  • 常见的python rpc和cli接口(Common python rpc and cli interface)
  • Mysql DB单个字段匹配多个其他字段(Mysql DB single field matching to multiple other fields)
  • 产品页面上的Magento Up出售对齐问题(Magento Up sell alignment issue on the products page)