mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-16 23:10:29 +00:00
Correct the Angular Material IToastService updateContent typings (#11305)
This commit is contained in:
committed by
Masahiro Wakame
parent
4fd81af1e8
commit
1ce244c131
@@ -132,7 +132,10 @@ myApp.controller('SidenavController', ($scope: ng.IScope, $mdSidenav: ng.materia
|
||||
});
|
||||
|
||||
myApp.controller('ToastController', ($scope: ng.IScope, $mdToast: ng.material.IToastService) => {
|
||||
$scope['openToast'] = () => $mdToast.show($mdToast.simple().textContent('Hello!'));
|
||||
$scope['openToast'] = () => {
|
||||
$mdToast.show($mdToast.simple().textContent('Hello!'));
|
||||
$mdToast.updateTextContent('New Content');
|
||||
}
|
||||
|
||||
$scope['customToast'] = () => {
|
||||
var options = {
|
||||
|
||||
+2
-1
@@ -177,7 +177,8 @@ declare namespace angular.material {
|
||||
showSimple(content: string): angular.IPromise<any>;
|
||||
simple(): ISimpleToastPreset;
|
||||
build(): IToastPreset<any>;
|
||||
updateContent(): void;
|
||||
updateContent(newContent: string): void;
|
||||
updateTextContent(newContent: string): void
|
||||
hide(response?: any): void;
|
||||
cancel(response?: any): void;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user