removed old shitz, added html src
This commit is contained in:
@@ -0,0 +1,68 @@
|
||||
|
||||
// Utilities for background tiling
|
||||
|
||||
// Use a tile as background (w, h - size of time)
|
||||
@mixin tile_xy($w, $h, $x, $y) {
|
||||
background-position: (-$x*$w) (-$y*$h);
|
||||
}
|
||||
|
||||
|
||||
// Use a square tile as background (size - w & h of time)
|
||||
@mixin tile($size, $x, $y) {
|
||||
@include tile_xy($size, $size, $x, $y);
|
||||
}
|
||||
|
||||
|
||||
// Button with sprite-sheet
|
||||
// A B
|
||||
// B:hover B:hover
|
||||
@mixin tile_btn_h($w, $h, $x) {
|
||||
@include tile_xy($w, $h, $x, 0);
|
||||
&:hover {
|
||||
@include tile_xy($w, $h, $x, 1);
|
||||
}
|
||||
}
|
||||
|
||||
// active the same as hover
|
||||
@mixin tile_btn_h_act($w, $h, $x) {
|
||||
@include tile_xy($w, $h, $x, 0);
|
||||
&:hover, &.active {
|
||||
@include tile_xy($w, $h, $x, 1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Button with sprite-sheet
|
||||
// A A:hover
|
||||
// B B:hover
|
||||
@mixin tile_btn_v($w, $h, $y) {
|
||||
@include tile_xy($w, $h, 0, $y);
|
||||
&:hover {
|
||||
@include tile_xy($w, $h, 1, $y);
|
||||
}
|
||||
}
|
||||
|
||||
// active the same as hover
|
||||
@mixin tile_btn_v_act($w, $h, $y) {
|
||||
@include tile_xy($w, $h, 0, $y);
|
||||
&:hover, &.active {
|
||||
@include tile_xy($w, $h, 1, $y);
|
||||
}
|
||||
}
|
||||
|
||||
@mixin inset-shadow-top($w, $c) {
|
||||
box-shadow: inset 0 $w ($w*2) (-$w) $c;
|
||||
}
|
||||
|
||||
@mixin inset-shadow-bottom($w, $c) {
|
||||
box-shadow: inset 0 (-$w) ($w*2) (-$w) $c;
|
||||
}
|
||||
|
||||
@mixin inset-shadow-left($w, $c) {
|
||||
box-shadow: inset $w 0 ($w*2) (-$w) $c;
|
||||
}
|
||||
|
||||
@mixin inset-shadow-right($w, $c) {
|
||||
box-shadow: inset (-$w) 0 ($w*2) (-$w) $c;
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
@import "background-tiling";
|
||||
@import "pointer";
|
||||
@import "misc";
|
||||
@@ -0,0 +1,34 @@
|
||||
// Add a highlight for debugging
|
||||
@mixin highlight($color) {
|
||||
outline: 1px solid $color;
|
||||
background: rgba($color, .05);
|
||||
box-shadow: 0 0 2px 2px rgba($color, .2), inset 0 0 2px 2px rgba($color, .2);
|
||||
}
|
||||
|
||||
// Ellipsis, but for block elements
|
||||
@mixin block-ellipsis($width: 100%) {
|
||||
display: block;
|
||||
max-width: $width;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
word-wrap: normal;
|
||||
}
|
||||
|
||||
// No margins, padding, borders
|
||||
@mixin naked() {
|
||||
border: 0 none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
@mixin translate($x, $y) {
|
||||
@include transform(translate($x, $y));
|
||||
}
|
||||
|
||||
// Disallow wrapping
|
||||
@mixin nowrap() {
|
||||
white-space: nowrap;
|
||||
word-wrap: normal;
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
|
||||
@mixin click-through() {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
|
||||
// Disallow text selection
|
||||
@mixin noselect() {
|
||||
-webkit-user-select: none;
|
||||
-khtml-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
|
||||
// Allow text selection
|
||||
@mixin can-select() {
|
||||
-webkit-user-select: text;
|
||||
-khtml-user-select: text;
|
||||
-moz-user-select: text;
|
||||
-ms-user-select: text;
|
||||
user-select: text;
|
||||
|
||||
cursor: text;
|
||||
}
|
||||
Reference in New Issue
Block a user