rqueensen/faludi-lca-app

View on GitHub
app/assets/stylesheets/model_mixins.scss

Summary

Maintainability
Test Coverage
@mixin descending-z-index($count: 30){
  // @include on UL class
  position: relative;
  li{
    position: relative;
    $target: 0;
    $index: $count;
    @while $index > 0 {
      &:nth-child(#{$target}){ z-index: #{$index}; }
      $target: $target + 1;
      $index: $index - 1;
      }
    }
}