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
feat(alert): Add fade prop #1785
Conversation
Codecov Report
@@ Coverage Diff @@
## dev #1785 +/- ##
==========================================
+ Coverage 61.02% 61.04% +0.01%
==========================================
Files 154 154
Lines 2861 2862 +1
Branches 790 791 +1
==========================================
+ Hits 1746 1747 +1
Misses 800 800
Partials 315 315
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great! Would yu mind adding an example to the docs too?
src/components/alert/alert.js
Outdated
@@ -16,10 +18,15 @@ export default { | |||
[ this.$slots.dismiss ] | |||
) | |||
} | |||
return h( | |||
let alert = h( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd use const
here
@pi0 Sure, let me know if this is ok. |
} | ||
.fade-enter, .fade-leave-to { | ||
opacity: 0; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if we should target these classes to elements containing the class .alert
, so that it doesn't interfere with users who may have their own fade transition with different settings?
Maybe:
.alert.fade-enter-active,
.alert.fade-leave-active {
transition: opacity .15s linear;
}
.alert.fade-enter,
.alert.fade-leave-to {
opacity: 0;
}
Closes #1512