Lightweight CSS Framework for Building Apps and Websites https://crispy-css.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

65 lines
945 B

7 years ago
7 years ago
  1. /**
  2. * add font-size in px as fallback
  3. * and in rem
  4. *
  5. *
  6. * @param {px} $font-size
  7. *
  8. */
  9. @mixin font-size($font-size) {
  10. font-size: $font-size;
  11. font-size: pxToRem($font-size);
  12. }
  13. /**
  14. * add modificators for font-size from a map
  15. *
  16. *
  17. * @param {map} $font-sizes
  18. *
  19. */
  20. @mixin font-sizes($font-sizes) {
  21. @each $name, $font-size in $font-sizes {
  22. @if ($name == 'default') {
  23. @include font-size($font-size);
  24. } @else {
  25. &--#{$name} {
  26. @include font-size($font-size);
  27. }
  28. }
  29. }
  30. }
  31. /**
  32. * clearfix to end floating
  33. *
  34. *
  35. *
  36. */
  37. @mixin clearfix() {
  38. &::before,
  39. &::after {
  40. display: table;
  41. content: ' ';
  42. }
  43. &::after {
  44. clear: both;
  45. }
  46. }
  47. /**
  48. * clear default styles from list
  49. *
  50. *
  51. */
  52. @mixin crispy-boilerplate-list-clear() {
  53. list-style: none;
  54. margin: 0;
  55. padding: 0;
  56. li {
  57. margin: 0;
  58. padding: 0;
  59. }
  60. }