This repository was archived by the owner on Sep 5, 2024. It is now read-only.
Commit 96ec741
committed
fix(toast): improve position handling to better align with docs
- position of "" uses documented default positioning
- "bottom left"
- position of "left" or "right" uses default vertical positioning: "bottom"
- improve JSDoc
Closes #11843.
BREAKING CHANGE: `$mdToast.show()`'s position behavior has been updated to be consistent with the documentation. If you relied on the previously undocumented behavior where it defaulted to `top left` instead of `bottom left`, you will need to update your app.
Change your code from this:
```js
$mdToast.show(
$mdToast.simple()
.textContent('Simple Toast!'))
.then(...
```
To this:
```js
$mdToast.show(
$mdToast.simple()
.textContent('Simple Toast!')
.position('top left'))
.then(...
```1 parent e24d09c commit 96ec741
2 files changed
+28
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
459 | 459 | | |
460 | 460 | | |
461 | 461 | | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
462 | 468 | | |
463 | 469 | | |
464 | 470 | | |
| |||
504 | 510 | | |
505 | 511 | | |
506 | 512 | | |
507 | | - | |
508 | | - | |
509 | | - | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
510 | 531 | | |
511 | 532 | | |
512 | 533 | | |
| |||
551 | 572 | | |
552 | 573 | | |
553 | 574 | | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
554 | 578 | | |
555 | 579 | | |
556 | 580 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
673 | 673 | | |
674 | 674 | | |
675 | 675 | | |
676 | | - | |
| 676 | + | |
677 | 677 | | |
678 | 678 | | |
679 | 679 | | |
| |||
0 commit comments