css中的伪类有哪些


本文摘自PHP中文网,作者青灯夜游,侵删。

css伪类:“:active”、“:any-link”、“:blank”、“:checked”、“:current”、“:first”、“:first-child”、“:future”、“:focus”、“:has()”、“:host”等。

本教程操作环境:windows7系统、CSS3版、Dell G3电脑。

伪类选择器(简称:伪类)通过冒号来定义,它定义了元素的状态,如点击按下,点击完成等,通过伪类可以为元素的状态修改样式。CSS伪类是用来添加一些选择器的特殊效果。

css中的伪类列表

:active:any-link:blank:checked:current:default
:defined:dir():disabled:drop:empty:enabled
:first:first-child:first-of-type:fullscreen:future:focus
:focus-visible:focus-within:has():host:host():host-context()
:hover:indeterminate:in-range:invalid:is():lang():last-child
:last-of-type:left:link:local-link:not():nth-child()
:nth-col():nth-last-child():nth-last-col():nth-last-of-type():nth-of-type():only-child
:only-of-type:optional:out-of-range:past:placeholder-shown:read-only
:read-write:required:right:root:scope:target
:target-within:user-invalid:valid:visited:where()

常用的伪类及其分类

阅读剩余部分

相关阅读 >>

css 如何设置带有正方形项目的列表

css怎么设置最大宽度

css如何设置超出部分滚动条隐藏

css设置不了中文字体怎么办

css怎么设置字体发光效果

css如何利用:after清除浮动

hbuilderx写css代码没有提示怎么办

css中width什么意思

css如何使用rem布局实现自适应效果

css怎么设置变成小手

更多相关阅读请进入《css》频道 >>




打赏

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码打赏,您说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦

分享从这里开始,精彩与您同在

评论

管理员已关闭评论功能...