plyr/demo/src/less/lib/mixins.less

51 lines
1.3 KiB
Plaintext

// ==========================================================================
// Mixins
// ==========================================================================
// Convert a <button> into an <a>
// ---------------------------------------
.cancel-button-styles() {
position: relative;
margin: 0;
padding: 0;
width: auto;
border: 0;
background: transparent;
vertical-align: baseline;
text-align: inherit;
font: inherit;
line-height: @line-height-base;
cursor: pointer;
-moz-user-select: text;
text-shadow: inherit;
border-radius: 0;
}
// Nicer focus styles
// ---------------------------------------
.tab-focus(@color: @tab-focus-default-color) {
outline: 0;
box-shadow: 0 0 0 3px fade(@color, 35%);
}
// Use rems for font sizing
// Leave <body> at 100%/16px
// ---------------------------------------
.font-size(@font-size: 16) {
@rem: round((@font-size / 16), 3);
font-size: (@font-size * 1px);
font-size: ~'@{rem}rem';
}
// Font smoothing
// ---------------------------------------
.font-smoothing(@mode: on) when (@mode = on) {
-moz-osx-font-smoothing: grayscale;
-webkit-font-smoothing: antialiased;
}
.font-smoothing(@mode: on) when (@mode = off) {
-moz-osx-font-smoothing: auto;
-webkit-font-smoothing: subpixel-antialiased;
}