-
-
Notifications
You must be signed in to change notification settings - Fork 678
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #554 from fkhadra/next
## 💥 Breaking changes - dependency to react-transition-group has been removed #514 - the `duration` parameter has been removed from `cssTransition`. Css animations just works now out of the box. Check the codesanbox below - the border-radius has been increased a bit ## 🚀 Features - Css animation just works! [![View](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/react-toastify-animatecss-jxrx9?fontsize=14&hidenavigation=1&theme=dark&view=preview) - add a way to load the CSS without a CSS loader [![Edit react-toastify-inject-style](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/react-toastify-inject-style-qfg0l?fontsize=14&hidenavigation=1&theme=dark) - specify swipe direction, close #512 . Thanks to @denydavy [![Edit react-toastify-drag-y](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/react-toastify-drag-y-lh88i?fontsize=14&hidenavigation=1&theme=dark) - bundle size reduced from ~7k to ~5k! - remove the dependency on prop-types. ## 🐛 Bugfix - fix #541 apply pauseOnFocusLoss on first render - fix #538 react-dom should be a peer dep - fix #530 change id generation - fix #534 #483 toastId cannot be reused - fix #511 by removing react-transition-group - fix #550 Unable to select text inside inputs when a toast is open - fix #555 The toast timer starts after you click on the toast
- Loading branch information
Showing
34 changed files
with
1,659 additions
and
1,285 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,49 +1,54 @@ | ||
.#{$rt-namespace}__toast { | ||
position: relative; | ||
min-height: $rt-toast-min-height; | ||
box-sizing: border-box; | ||
margin-bottom: 1rem; | ||
padding: 8px; | ||
border-radius: 1px; | ||
box-shadow: 0 1px 10px 0 rgba(0, 0, 0, .1), 0 2px 15px 0 rgba(0, 0, 0, .05); | ||
display: flex; | ||
justify-content: space-between; | ||
max-height: $rt-toast-max-height; | ||
overflow: hidden; | ||
font-family: $rt-font-family; | ||
cursor: pointer; | ||
direction: ltr; | ||
&--rtl { | ||
direction: rtl; | ||
} | ||
&--dark { | ||
background: $rt-color-dark; | ||
color: $rt-text-color-dark; | ||
} | ||
&--default { | ||
background: $rt-color-default; | ||
color: $rt-text-color-default; | ||
} | ||
&--info { | ||
background: $rt-color-info; | ||
} | ||
&--success { | ||
background: $rt-color-success; | ||
} | ||
&--warning { | ||
background: $rt-color-warning; | ||
} | ||
&--error { | ||
background: $rt-color-error; | ||
} | ||
&-body { | ||
margin: auto 0; | ||
flex: 1 1 auto; | ||
} | ||
position: relative; | ||
min-height: $rt-toast-min-height; | ||
box-sizing: border-box; | ||
margin-bottom: 1rem; | ||
padding: 8px; | ||
border-radius: 4px; | ||
box-shadow: 0 1px 10px 0 rgba(0, 0, 0, 0.1), 0 2px 15px 0 rgba(0, 0, 0, 0.05); | ||
display: flex; | ||
justify-content: space-between; | ||
max-height: $rt-toast-max-height; | ||
overflow: hidden; | ||
font-family: $rt-font-family; | ||
cursor: pointer; | ||
direction: ltr; | ||
&--rtl { | ||
direction: rtl; | ||
} | ||
&--dark { | ||
background: $rt-color-dark; | ||
color: $rt-text-color-dark; | ||
} | ||
&--default { | ||
background: $rt-color-default; | ||
color: $rt-text-color-default; | ||
} | ||
&--info { | ||
background: $rt-color-info; | ||
} | ||
&--success { | ||
background: $rt-color-success; | ||
} | ||
&--warning { | ||
background: $rt-color-warning; | ||
} | ||
&--error { | ||
background: $rt-color-error; | ||
} | ||
&-body { | ||
margin: auto 0; | ||
padding: 6px; | ||
} | ||
} | ||
|
||
.#{$rt-namespace}--animate { | ||
animation-fill-mode: both; | ||
animation-duration: 0.7s; | ||
} | ||
|
||
@media #{$rt-mobile} { | ||
.#{$rt-namespace}__toast{ | ||
margin-bottom: 0; | ||
.#{$rt-namespace}__toast { | ||
margin-bottom: 0; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.