Skip to content

Instantly share code, notes, and snippets.

@2thecrow
Last active February 28, 2023 21:02
Show Gist options
  • Save 2thecrow/3e37e2b9cdb41800f373a03a097a37ce to your computer and use it in GitHub Desktop.
Save 2thecrow/3e37e2b9cdb41800f373a03a097a37ce to your computer and use it in GitHub Desktop.
Element decor with left/right horizontal line
<div class="mobile-login__or-decor">
<span>или</span>
</div>
.mobile-login__or-decor {
overflow: hidden;
white-space: nowrap;
text-align: center;
position: relative;
font-family: 'Montserrat';
font-style: normal;
font-weight: normal;
font-size: 18px;
line-height: 22px;
color: #C0C0C0;
margin-bottom: 13px;
}
.mobile-login__or-decor::before,
.mobile-login__or-decor::after
{
content: "";
position: relative;
display: inline-block;
width: 50%;
height: 1px;
vertical-align: middle;
background: #c0c0c0;
}
.mobile-login__or-decor::before {
left: -10px;
margin: 0 0 0 -50%;;
}
.mobile-login__or-decor::after {
left: 10px;
margin: 0 -50% 0 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment