Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/35.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Css 自定义控件的引导4光标处于禁用状态_Css_Bootstrap 4_Twitter Bootstrap 4 - Fatal编程技术网

Css 自定义控件的引导4光标处于禁用状态

Css 自定义控件的引导4光标处于禁用状态,css,bootstrap-4,twitter-bootstrap-4,Css,Bootstrap 4,Twitter Bootstrap 4,我需要其他光标用于禁用的自定义控件元素(复选框,单选按钮) 这种风格行不通: .custom-control-input:disabled ~ .custom-control-label::before { cursor: not-allowed; } 对于引导4中禁用的自定义控件元素(复选框,单选按钮),您需要以下选择器css规则/选择器: .custom-control-input:disabled ~ .custom-control-label { cursor: not

我需要其他光标用于禁用的自定义控件元素(复选框,单选按钮)

这种风格行不通:

.custom-control-input:disabled ~ .custom-control-label::before {
    cursor: not-allowed;
}

对于引导4中禁用的自定义控件元素(复选框,单选按钮),您需要以下选择器css规则/选择器:

.custom-control-input:disabled ~ .custom-control-label {
    cursor: not-allowed;
}
如果您希望自定义光标样式仅用于实际的复选框/单选按钮,而不用于标签(在本例中不推荐),则需要以下规则:

.custom-control-input:disabled ~ .custom-control-label::after {
    cursor: not-allowed;
}
单击下面的“运行代码段”以查看其工作情况:


.自定义控件输入:禁用~.自定义控件标签{
光标:不允许;
}
这台定制收音机还可以
这个是残疾的
此自定义复选框是确定的
也可以
此自定义复选框已禁用

您应该显示正在选择的HTML。确保它实际上选择了正确的部件,诸如此类的东西