37 lines
845 B
HTML
37 lines
845 B
HTML
<!DOCTYPE html>
|
|
<html lang="zh-CN">
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>13_伪类选择器_UI伪类</title>
|
|
<style>
|
|
/* 选择的是勾选的复选框或单选框按钮 */
|
|
input:checked {
|
|
height: 100px;
|
|
width: 100px;
|
|
}
|
|
|
|
/* 选择的是被禁用的input元素 */
|
|
input:disabled {
|
|
background-color: gray;
|
|
}
|
|
|
|
/* 选择的是可以的input元素 */
|
|
input:enabled {
|
|
background-color: green;
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<div>
|
|
<input type="checkbox">
|
|
<input type="radio" name="gender">
|
|
<input type="radio" name="gender">
|
|
<input type="text">
|
|
<input type="text" disabled>
|
|
</div>
|
|
</body>
|
|
|
|
</html> |