mixins.less 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. // Mixins
  2. .transition-all() {
  3. -webkit-transition: all 0.35s;
  4. -moz-transition: all 0.35s;
  5. transition: all 0.35s;
  6. }
  7. .background-cover() {
  8. -webkit-background-size: cover;
  9. -moz-background-size: cover;
  10. background-size: cover;
  11. -o-background-size: cover;
  12. }
  13. .button-variant(@color; @background; @border) {
  14. color: @color;
  15. background-color: @background;
  16. border-color: @border;
  17. .transition-all;
  18. &:hover,
  19. &:focus,
  20. &.focus,
  21. &:active,
  22. &.active,
  23. .open > .dropdown-toggle& {
  24. color: @color;
  25. background-color: darken(@background, 5%);
  26. border-color: darken(@border, 7%);
  27. }
  28. &:active,
  29. &.active,
  30. .open > .dropdown-toggle& {
  31. background-image: none;
  32. }
  33. &.disabled,
  34. &[disabled],
  35. fieldset[disabled] & {
  36. &,
  37. &:hover,
  38. &:focus,
  39. &.focus,
  40. &:active,
  41. &.active {
  42. background-color: @background;
  43. border-color: @border;
  44. }
  45. }
  46. .badge {
  47. color: @background;
  48. background-color: @color;
  49. }
  50. }
  51. .sans-serif-font() {
  52. font-family: 'Open Sans', 'Helvetica Neue', Arial, sans-serif;
  53. }
  54. .serif-font() {
  55. font-family: 'Merriweather', 'Helvetica Neue', Arial, sans-serif;
  56. }