Skip to content

Instantly share code, notes, and snippets.

@csssecrets
csssecrets / dabblet.css
Created January 13, 2015 07:57
Vertical stripes
/**
* Vertical stripes
*/
background: linear-gradient(to right, #fb3 50%, #58a 0);
background-size: 20px 100%;
@csssecrets
csssecrets / dabblet.css
Created January 6, 2016 14:42
Scrolling hints
/**
* Scrolling hints
*/
ul {
display: inline-block;
overflow: auto;
width: 7.2em;
height: 7em;
border: 1px solid silver;
@csssecrets
csssecrets / dabblet.css
Last active June 3, 2018 09:48
Interactive image comparison — range input version
/**
* Interactive image comparison — range input version
*/
.image-slider {
position:relative;
display: inline-block;
}
.image-slider > div {
@csssecrets
csssecrets / dabblet.css
Created February 22, 2015 04:16
Elastic color
/**
* Elastic color
*/
html {
background: rgb(100%, 0%, 40%);
transition: 1s cubic-bezier(.25,.1,.2,3);
}
@csssecrets
csssecrets / dabblet.css
Created March 4, 2016 23:34
box-shadow removes slider track in Chrome
/**
* box-shadow removes slider track in Chrome
*/
input {
box-shadow: 0 0 5px red;
}
@csssecrets
csssecrets / dabblet.css
Last active September 18, 2021 11:55
Diagonal stripes - repeating-linear-gradient() method
/**
* Diagonal stripes - repeating-linear-gradient() method
*/
background: repeating-linear-gradient(60deg,
#fb3, #fb3 15px,
#58a 0, #58a 30px);
height: 100%;
@csssecrets
csssecrets / dabblet.css
Last active September 18, 2021 12:06
Subtle stripes
/**
* Subtle stripes
*/
background: #58a;
background-image: repeating-linear-gradient(30deg,
hsla(0,0%,100%,.1), hsla(0,0%,100%,.1) 15px,
transparent 0, transparent 30px);
height: 100vh;
@csssecrets
csssecrets / dabblet.css
Last active September 18, 2021 12:52
Checkerboard with SVG
/**
* Checkerboard with SVG
*/
background: #eee url('data:image/svg+xml,\
<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" fill-opacity=".25" >\
<rect x="50" width="50" height="50" />\
<rect y="50" width="50" height="50" />\
</svg>');
background-size: 30px 30px;
@csssecrets
csssecrets / dabblet.css
Last active September 18, 2021 12:52
Checkerboard
/**
* Checkerboard
*/
background: #eee;
background-image:
linear-gradient(45deg, rgba(0,0,0,.25) 25%, transparent 0, transparent 75%, rgba(0,0,0,.25) 0),
linear-gradient(45deg, rgba(0,0,0,.25) 25%, transparent 0, transparent 75%, rgba(0,0,0,.25) 0);
background-position: 0 0, 15px 15px;
background-size: 30px 30px;
@csssecrets
csssecrets / dabblet.css
Created January 21, 2015 22:37
Conic gradients test
/**
* Conic gradients test
* PASS if green gradient, FAIL if red.
*/
background: red;
background: conic-gradient(limegreen, green, limegreen);
min-height: 100%;