This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.clase { | |
text-align: center; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.btn-3d { | |
padding: .6rem 1rem; | |
border: 1px solid #995309; | |
border-radius: 4px; | |
background-color: #d9750b; | |
color: #fff; | |
font-size: 1.5rem; | |
text-shadow: 0 -1px 0 rgba(0,0,0,.5); | |
box-shadow: 0 1px 0 rgba(255,255,255,.5) inset, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Alterna una clase de un elemento (la elimina si existe, la añade si no) | |
* @param {object}<Element> elemento - Elemento a manipular | |
* @param {object}<String> clase - Clase a alternar | |
* @returns {boolean} True si se añadió la clase, False si se eliminó | |
*/ | |
function alternarClase(elemento, clase) { | |
var clases, i; | |
clase = '' + clase; | |
if (!(elemento instanceof Element)) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Comprueba si el navegador es compatible con alguna de las propiedades CSS | |
* especificadas. | |
* @param {Array}<String> props - propiedades CSS a comprobar | |
* @returns {boolean} true si el navegador es compatible, false si no lo es | |
*/ | |
function obsoleto(props) { | |
if (!props) { | |
// Por defecto usamos border-image (no funciona en IE10, sí en IE11) | |
props = [ 'borderImage', 'WebkitBorderImage' ]; |