Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

transition mixin breaks surrounding code #330

Open
enzy opened this issue Jun 22, 2016 · 0 comments
Open

transition mixin breaks surrounding code #330

enzy opened this issue Jun 22, 2016 · 0 comments

Comments

@enzy
Copy link

enzy commented Jun 22, 2016

Stylus: 0.54.5
Nib: 1.1.0

Source file:

@import 'nib'

$perRow = 5
$itemRatio = 0.625

.grid
    display block
    opacity 0
    transition opacity 1s ease

    &-item
        position relative
        display block
        width (100% / $perRow)
        height 0
        padding-top (100% * $itemRatio / $perRow)

Result:

.grid {
  display: block;
  opacity: 0;
  -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
  filter: alpha(opacity=0);
  .grid td,
  .grid th {
    padding: 0;
  }
  -webkit-transition: ;
  .grid td,
  .grid th {
    padding: 0;
  }
  -moz-transition: ;
  .grid td,
  .grid th {
    padding: 0;
  }
  -o-transition: ;
  .grid td,
  .grid th {
    padding: 0;
  }
  -ms-transition: ;
  .grid td,
  .grid th {
    padding: 0;
  }
  transition: ;
}
.grid-item {
  position: relative;
  display: block;
  width: 20%;
  height: 0;
  padding-top: 12.5%;
}

Correct result when nib is not imported:

.grid {
  display: block;
  opacity: 0;
  transition: opacity 1s ease;
}
.grid-item {
  position: relative;
  display: block;
  width: 20%;
  height: 0;
  padding-top: 12.5%;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant