diff --git a/types/angular-gettext/angular-gettext-tests.ts b/types/angular-gettext/angular-gettext-tests.ts index 766b16a963..1b1d5b6342 100644 --- a/types/angular-gettext/angular-gettext-tests.ts +++ b/types/angular-gettext/angular-gettext-tests.ts @@ -24,6 +24,8 @@ angular.module("myApp").controller("helloController", function (gettextCatalog: angular.module("myApp").controller("helloController", function (gettextCatalog: angular.gettext.gettextCatalog) { var myString2: string = gettextCatalog.getPlural(3, "Bird", "Birds"); + var myStringWithScope: string = gettextCatalog.getPlural(4, "{{color}} Bird", "{{color}} Birds", {color: 'Blue'}); + var myStringWithContext: string = gettextCatalog.getPlural(5, "pick", "picks", null, 'noun'); }); angular.module("myApp").controller("helloController", function (gettextCatalog: angular.gettext.gettextCatalog) { diff --git a/types/angular-gettext/index.d.ts b/types/angular-gettext/index.d.ts index 5b6eb1d90f..6b5fe29e73 100644 --- a/types/angular-gettext/index.d.ts +++ b/types/angular-gettext/index.d.ts @@ -1,4 +1,4 @@ -// Type definitions for angular-gettext v2.1.0 +// Type definitions for angular-gettext v2.1.1 // Project: https://angular-gettext.rocketeer.be/ // Definitions by: Ákos Lukács // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped @@ -66,7 +66,7 @@ declare module 'angular' { getString(string: string, scope?: any, context?: string): string; /** Translate a plural string with the given context. */ - getPlural(n: number, string: string, stringPlural: string, context?: any): string; + getPlural(n: number, string: string, stringPlural: string, scope?: any, context?: string): string; /** Load a set of translation strings from a given URL.This should be a JSON catalog generated with grunt-angular-gettext. More details https://angular-gettext.rocketeer.be/dev-guide/lazy-loading/ */ loadRemote(url: string): ng.IHttpPromise;