tiles.sass 777 B

12345678910111213141516171819202122232425262728293031323334
  1. $tile-spacing: 0.75rem !default
  2. .tile
  3. align-items: stretch
  4. display: block
  5. flex-basis: 0
  6. flex-grow: 1
  7. flex-shrink: 1
  8. min-height: min-content
  9. // Modifiers
  10. &.is-ancestor
  11. margin-left: $tile-spacing * -1
  12. margin-right: $tile-spacing * -1
  13. margin-top: $tile-spacing * -1
  14. &:last-child
  15. margin-bottom: $tile-spacing * -1
  16. &:not(:last-child)
  17. margin-bottom: $tile-spacing
  18. &.is-child
  19. margin: 0 !important
  20. &.is-parent
  21. padding: $tile-spacing
  22. &.is-vertical
  23. flex-direction: column
  24. & > .tile.is-child:not(:last-child)
  25. margin-bottom: 1.5rem !important
  26. // Responsiveness
  27. +tablet
  28. &:not(.is-child)
  29. display: flex
  30. @for $i from 1 through 12
  31. &.is-#{$i}
  32. flex: none
  33. width: ($i / 12) * 100%