Skip to content

Instantly share code, notes, and snippets.

@iliakan
Created September 21, 2020 13:30
Show Gist options
  • Save iliakan/faa7530457a926306fdda96a057bc72c to your computer and use it in GitHub Desktop.
Save iliakan/faa7530457a926306fdda96a057bc72c to your computer and use it in GitHub Desktop.
table.colortable {
& td {
text-align:center;
&.c { text-transform:uppercase }
&:first-child, &:first-child + td { border:1px solid black }
}
& th {
text-align:center;
background:blue;
color:white;
}
}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
</head>
<body>
<link rel="stylesheet" href="1.css">
<table class="colortable">
<tr>
<th>test</th>
</tr>
</table>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment