Add chess (Oh my gosh big commit)
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
#chessBoard {
|
||||
margin: 2vw auto;
|
||||
width: 60vw;
|
||||
height: 60vw;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(8, 1fr);
|
||||
grid-template-rows: repeat(8, 1fr);
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
.chessSquare {
|
||||
background-color: inherit;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.chessSquare.light {
|
||||
background-color: #ccc;
|
||||
}
|
||||
|
||||
.chessSquare.dark {
|
||||
background-color: #656770;
|
||||
}
|
||||
|
||||
.chessPiece {
|
||||
width: 90%;
|
||||
height: 90%;
|
||||
display: block;
|
||||
margin: auto;
|
||||
}
|
||||
|
||||
.chessSquare.selected {
|
||||
border: 4px solid red;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.chessSquare.legal {
|
||||
border: 4px dashed red;
|
||||
box-sizing: border-box;
|
||||
cursor: pointer;
|
||||
}
|
||||
Reference in New Issue
Block a user