伪类对元素进行分类是基于特征(characteristics)而不是它们的名字、属性或者内容;原则上特征是不可以从文档树上推断得到的。
属性选择器(Attribute selectors):通过 属性 / 属性值 匹配一个或多个元素。 伪类(Pseudo-classes):匹配处于确定状态的一个或多个元素,比如被鼠标指针悬停的元素,或当前被选中或未选中的复选框,或元素是DOM树中一父节点的第一...
基于1820个网页-相关网页
你可以通过配置CSS中链接的active伪类来添加一个按下的按钮状态。
You can add a pressed button state with CSS by styling the active pseudo-class of the link in question.
伪类的表示方法是在名称前面加一个冒号。伪类与特定元素无关,而是根据文档中发生的情况应用样式。
Designated by a colon preceding the name, pseudo-classes are independent of particular elements and instead look at what's happening within the document.
一个简单选择符或者是一个类型选择符,或者是一个全局选择符,紧跟在后的是零个或多个属性选择符,ID选择符或伪类,次序任意。
A simple selector is either a type selector or universal selector followed immediately by zero or more attribute selectors, ID selectors, or pseudo-classes, in any order.
It's just some bogus language we made up that's kind of English-like, kind of look C-like now that you've seen this syntax, but it was just an arbitrary language.
并不是真正的编程语言,好比某种“伪英语“,或“类C语言“,你现在在语法中看到的就是所谓的伪代码,非常随意。
应用推荐