Html 是否可以将以下jquery转换为css?

Html 是否可以将以下jquery转换为css?,html,checkbox,Html,Checkbox,我有以下片段: $(.status”)。在(“单击”,函数(){ 如果($(this).prop(“选中”)){ $(this.next().show(); }否则{ $(this.next().hide(); } }); ……很多东西。。。。。。 ……很多东西。。。。。。 您应该能够通过以下代码实现这一点 .info>.infoCont { display:none; } .info>.status:checked + .infoCont { displ

我有以下片段:

$(.status”)。在(“单击”,函数(){
如果($(this).prop(“选中”)){
$(this.next().show();
}否则{
$(this.next().hide();
}
});

……很多东西。。。。。。
……很多东西。。。。。。

您应该能够通过以下代码实现这一点

    .info>.infoCont {
    display:none;
}
.info>.status:checked + .infoCont {
    display:block;
}
这应该行得通

.example+span{
能见度:可见;
}
.示例:选中+跨度{
可见性:隐藏;
}
你好

World
看一个例子。很抱歉,我的坏朋友忘记了谜题中的一个重要部分,现在就试试。非常感谢你的帮助,我会尽快接受你的答案。不幸的是,我不能投你一票,因为我没有足够的选票(没问题:)很高兴我能帮上忙