What do two dots in a CSS declaration mean?

后端 未结 6 939
予麋鹿
予麋鹿 2020-12-31 00:56

This is a bit of code from Twitter Bootstrap

.navbar .nav.pull-right .dropdown-menu,
.navbar .nav .dropdown-menu.pull-right {
  left: auto;
  right: 0;
}
         


        
6条回答
  •  说谎
    说谎 (楼主)
    2020-12-31 01:09

    This is my answer on a duplicated question. I've put so much effort in it that I wanted to share it with the "original" post.

    It just selects elements with the classes "move" and "up". http://www.w3schools.com/cssref/css_selectors.asp

    div{
      width: 60px;
      height: 60px;
      background: beige;
      border: solid black;
      float:left;
      margin: 10px;
      text-align: center;
      line-height: 60px;
      font-family: arial;
      font-weight: bold;
    }
    .separator{
      width: 5px;
      height: 60px;
      border: solid black;
      background: grey;
      clear: both;
    }
    
    
    
    .move.up{
      background: green;
    }
    
    
    //Additional knowledge
    .class1 .class2{
      background: orange;
    }
    span div{
      background: purple;
    }
    
    .class3, .class4{
      background: brown;
    }
    1
    2
    3
    4
    5
    6
    7
    8
    8.1
    9
    10
    11
    12

提交回复
热议问题