@jupyterlab/translation
Advanced tools
Comparing version 3.3.0-alpha.4 to 3.3.0-alpha.5
@@ -354,2 +354,3 @@ /* ---------------------------------------------------------------------------- | ||
*/ | ||
// eslint-disable-next-line @typescript-eslint/ban-types | ||
getPluralFunc(pluralForm) { | ||
@@ -356,0 +357,0 @@ // Plural form string regexp |
@@ -20,6 +20,44 @@ import { DataConnector, IDataConnector } from '@jupyterlab/statedb'; | ||
} | ||
/** | ||
* Bundle of gettext-based translation functions. | ||
* | ||
* The calls to the functions in this bundle will be automatically | ||
* extracted by `jupyterlab-translate` package to generate translation | ||
* template files if the bundle is assigned to: | ||
* - variable named `trans`, | ||
* - public attribute named `trans` (`this.trans`), | ||
* - private attribute named `trans` (`this._trans`), | ||
* - `trans` attribute `props` variable (`props.trans`), | ||
* - `trans` attribute `props` attribute (`this.props.trans`) | ||
*/ | ||
export declare type TranslationBundle = { | ||
/** | ||
* Alias for `gettext` (translate strings without number inflection) | ||
* @param msgid message (text to translate) | ||
* @param args | ||
*/ | ||
__(msgid: string, ...args: any[]): string; | ||
/** | ||
* Alias for `ngettext` (translate accounting for plural forms) | ||
* @param msgid message for singular | ||
* @param msgid_plural message for plural | ||
* @param n determines which plural form to use | ||
* @param args | ||
*/ | ||
_n(msgid: string, msgid_plural: string, n: number, ...args: any[]): string; | ||
/** | ||
* Alias for `pgettext` (translate in given context) | ||
* @param msgctxt context | ||
* @param msgid message (text to translate) | ||
* @param args | ||
*/ | ||
_p(msgctxt: string, msgid: string, ...args: any[]): string; | ||
/** | ||
* Alias for `npgettext` (translate accounting for plural forms in given context) | ||
* @param msgctxt context | ||
* @param msgid message for singular | ||
* @param msgid_plural message for plural | ||
* @param n number used to determine which plural form to use | ||
* @param args | ||
*/ | ||
_np(msgctxt: string, msgid: string, msgid_plural: string, n: number, ...args: any[]): string; | ||
@@ -26,0 +64,0 @@ gettext(msgid: string, ...args: any[]): string; |
{ | ||
"name": "@jupyterlab/translation", | ||
"version": "3.3.0-alpha.4", | ||
"version": "3.3.0-alpha.5", | ||
"description": "JupyterLab - Translation services", | ||
@@ -35,3 +35,2 @@ "keywords": [ | ||
"eslint:check": "eslint . --ext .ts,.tsx", | ||
"prepublishOnly": "npm run build", | ||
"test": "jest", | ||
@@ -44,9 +43,9 @@ "test:cov": "jest --collect-coverage", | ||
"dependencies": { | ||
"@jupyterlab/coreutils": "^5.3.0-alpha.4", | ||
"@jupyterlab/services": "^6.3.0-alpha.4", | ||
"@jupyterlab/statedb": "^3.3.0-alpha.4", | ||
"@jupyterlab/coreutils": "^5.3.0-alpha.5", | ||
"@jupyterlab/services": "^6.3.0-alpha.5", | ||
"@jupyterlab/statedb": "^3.3.0-alpha.5", | ||
"@lumino/coreutils": "^1.5.3" | ||
}, | ||
"devDependencies": { | ||
"@jupyterlab/testutils": "^3.3.0-alpha.4", | ||
"@jupyterlab/testutils": "^3.3.0-alpha.5", | ||
"@types/jest": "^26.0.10", | ||
@@ -53,0 +52,0 @@ "jest": "^26.4.2", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
55346
1110