Change button:active in css

后端 未结 4 2047
面向向阳花
面向向阳花 2021-01-28 07:40

how i can change button to have border-radius: 6px; and to by active marked when i will select it. Here is my HTML code and i also have CSS. When i make

4条回答
  •  盖世英雄少女心
    2021-01-28 08:15

    The : indicates a pseudo-class (pr pseudo-element). It is not part of the class name.

    :active means "While being clicked on" (or otherwise activated).

    If you want to match a class in the document, then give it a regular class name (and preferably not one that could be confused with a pseudo-class):

    Then use a class selector in the CSS:

    .current { ... }
    

提交回复
热议问题