Skip to content

Instantly share code, notes, and snippets.

@ink-ru
Last active November 24, 2020 11:18
Show Gist options
  • Save ink-ru/73d14ed341f98f8359f0173973c01470 to your computer and use it in GitHub Desktop.
Save ink-ru/73d14ed341f98f8359f0173973c01470 to your computer and use it in GitHub Desktop.
Russian ruble symbol with CSS
<!DOCTYPE html>
<html>
<head>
<title>Russian ruble symbol with CSS</title>
<meta charset="UTF-8" />
<style type="text/css">
* { font-family: Verdana, Arial, sans-serif; }
body { background-color: #fff; cursor: default; }
h1 { font-size: 15pt; }
p { font-size: 10pt; }
.rubble { display: inline-block; max-width:1.3ex; overflow:hidden; font-size: 3em;
font-weight:bold; text-decoration:line-through;
text-decoration-style: double; }
.strike{
position: relative;
display: inline-block;
font-size: 3em;
font-weight:bold;
background: transparent;
}
.strike-0::before {
content: '';
border-bottom: 0.22ex solid;
width: 100%;
position: absolute;
left: 0;
top: 52%;
max-width:0.5em;
background: transparent;
}
.strike::before {
content: '';
border-bottom: 0.2ex solid;
width: 100%;
position: absolute;
left: 0;
top: 66%;
max-width:0.7em;
background: transparent;
}
</style>
</head>
<body>
<h1>Russian ruble symbol with CSS</h1>
<p>Your content. <span class="rubble">Р</span></p>
<p>Your content. <span class="strike"><span class="strike-0">Р</span></span></p>
</body>
</html>
@ink-ru
Copy link
Author

ink-ru commented Dec 15, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment