Skip to content

Instantly share code, notes, and snippets.

@a2sc
Created March 18, 2024 10:24
Show Gist options
  • Save a2sc/d28bded524e76c808e56f1e70cde19b5 to your computer and use it in GitHub Desktop.
Save a2sc/d28bded524e76c808e56f1e70cde19b5 to your computer and use it in GitHub Desktop.
CSS Pseudo Element ::marker
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
<style>
.test-1 li::marker {
color: red;
}
.test-2 li::marker {
content: "+ ";
color: green;
}
.test-3 li::marker {
font-weight: 900;
color: blue;
}
</style>
</head>
<body>
<ul>
<li>lorem</li>
<li>ipsum</li>
<li>dolor</li>
</ul>
<ul class="test-1">
<li>lorem</li>
<li>ipsum</li>
<li>dolor</li>
</ul>
<ul class="test-2">
<li>lorem</li>
<li>ipsum</li>
<li>dolor</li>
</ul>
<ol>
<li>lorem</li>
<li>ipsum</li>
<li>dolor</li>
</ol>
<ol class="test-3">
<li>lorem</li>
<li>ipsum</li>
<li>dolor</li>
</ol>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment