Skip to content

Instantly share code, notes, and snippets.

View kovtunos's full-sized avatar

Andrey Kovtun kovtunos

View GitHub Profile
@kovtunos
kovtunos / _form-required.scss
Created January 12, 2017 08:53
Required form asterisk #sass #css
.form-group.required label::after {
content: '*';
color: #e3010b;
position: absolute;
margin-left: 4px;
top: 0;
}
@kovtunos
kovtunos / _owl-carousel.scss
Last active January 15, 2017 14:47
Owl carousel Prev/Next buttons #sass #css
@kovtunos
kovtunos / list-big-circles.scss
Last active January 12, 2017 20:09
Larger circles on bullet list #ul #sass
.list-circles {
li {
position: relative;
list-style: none;
font-size: 1rem;
line-height: 1rem;
&::before {
position: absolute;
top: 0;
@kovtunos
kovtunos / slug-class.js
Last active March 4, 2017 09:00
Add page class based on slug #js #jquery
var getSlug = window.location.href.substr(window.location.href.lastIndexOf("/") + 1);
$('body').addClass('page--' + getSlug);
@kovtunos
kovtunos / background-cover.scss
Created December 28, 2016 19:16
Emulate background-cover for inline html img #sass
.cover-image {
overflow: hidden;
position: relative;
top: 0;
right: 0;
bottom: 0;
left: 0;
height: 150px;
@kovtunos
kovtunos / radio-buttons.html
Created December 24, 2016 15:04
Radio buttons #css #sass
<div class="container">
<div class="radio">
<input id="radio-1" name="radio" type="radio" checked>
<label for="radio-1" class="radio-label">Checked</label>
</div>
<div class="radio">
<input id="radio-2" name="radio" type="radio">
<label for="radio-2" class="radio-label">Unchecked</label>
</div>
@kovtunos
kovtunos / bootstrap-fade-in-mobile-menu.scss
Last active September 29, 2017 14:15
Fade-in mobile menu #bootstrap #css
// Fade in mobile menu
.navbar-collapse {
opacity: 0;
width: auto;
height: auto !important;
max-height: none;
display: block !important;
}
.navbar-collapse.collapse.in {
@kovtunos
kovtunos / fix-bootstrap-footer.js
Last active September 29, 2017 14:17
Fix #bootstrap footer to bottom of the page #jquery
@kovtunos
kovtunos / retina.css
Last active May 9, 2017 11:35
Image for Retina display #css #sass
.image {
background-image: url('../images/image.png');
background-size: 400px 200px;
width: 400px;
height: 200px;
}
/* 2 dpr retina monitors */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
.image {
@kovtunos
kovtunos / .htaccess
Last active September 29, 2017 14:18 — forked from agragregra/.htaccess
htaccess wget disable #htaccess
RewriteCond %{HTTP_USER_AGENT} wget [NC]
RewriteRule .* - [F]