mirror of
https://github.com/maputnik/editor.git
synced 2026-11-27 04:23:45 +00:00
chore(deps): Bump i18next from 27.1.5 to 27.2.2 (#2356)
Bumps [i18next](https://github.com/i18next/i18next) from 27.1.5 to 27.2.2. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/i18next/i18next/releases">i18next's releases</a>.</em></p> <blockquote> <h2>v27.2.2</h2> <ul> <li>fix: <code>setDefaultNamespace()</code> works on a clone. A clone's translator keeps its own options object, so the call changed <code>i18n.options.defaultNS</code> while <code>t()</code> kept using the old default namespace. i18next-http-middleware hands every request a clone, so <code>req.i18n.setDefaultNamespace()</code> did nothing there. (<a href="https://github.com/i18next/i18next/discussions/2106">#2106</a>)</li> <li>fix: <code>supportedLngs</code> works in any casing. Every other language code is formatted (<code>pt-br</code> to <code>pt-BR</code>, <code>EN</code> to <code>en</code>, all lowercase with <code>lowerCaseLng</code>), but <code>supportedLngs</code> was compared as written, so <code>supportedLngs: ['pt-br']</code>, <code>['EN']</code>, or <code>['pt-BR']</code> with <code>lowerCaseLng: true</code> refused that language and fell back. They are now compared in that formatted form (also by <code>loadLanguages()</code>), while <code>options.supportedLngs</code> stays as written. (<a href="https://github.com/i18next/i18next/discussions/1791">#1791</a>)</li> <li>fix(types): resources typed with named <code>interface</code>s get their nested keys. The key types only walked into objects with an index signature, which a type alias has and an interface does not, so <code>t('nested.key')</code> failed with TS2345 while <code>t('nested')</code> compiled. Interfaces now give the same keys as type aliases, so <code>t('nested')</code> without <code>returnObjects</code> is rejected for them too. (<a href="https://github.com/i18next/i18next/discussions/2326">#2326</a>)</li> <li>fix(types): typed keys work with <code>strictNullChecks: false</code>. Without strict null checks <code>undefined</code> passes <code>extends string</code>, so the key prefix, namespace and context checks took a missing <code>keyPrefix</code>, <code>ns</code> or <code>context</code> for a value: <code>t('title')</code> was rejected (only <code>t('ns:title')</code> compiled), <code>t()</code> returned <code>string</code>, and react-i18next's <code>Trans</code> accepted no <code>i18nKey</code>. A new type test project compiles with <code>strictNullChecks: false</code>; with strict null checks the types resolve as before. (<a href="https://github.com/i18next/i18next/discussions/2085">#2085</a>)</li> </ul> <h2>v27.2.1</h2> <ul> <li>fix: a variable passed as <code>undefined</code> renders as an empty string when its placeholder has a format too (<code>{{amount, number}}</code>), as <code>{{amount}}</code> already did. The placeholder stayed in the result with the default <code>skipOnVariables: true</code>, and debug mode logged "missed to pass in variable" with either setting. Thanks <a href="https://github.com/Vineet829"><code>@Vineet829</code></a> (<a href="https://redirect.github.com/i18next/i18next/pull/2479">#2479</a>)</li> </ul> <h2>v27.2.0</h2> <ul> <li>fix: an error thrown by a load callback or a listener (the callback of <code>init</code>, <code>changeLanguage</code>, <code>loadNamespaces</code> or <code>loadLanguages</code>, or a <code>languageChanged</code> / <code>loaded</code> listener) is no longer handed back to the backend connector as if the read had failed. With a backend whose <code>read</code> returns a value or a promise, the connector got that error a second time: the namespace that had loaded was marked as failed, <code>failedLoading</code> was emitted with your error and the count of running reads dropped to -1. The error now reaches your app: it is thrown from the call that started the load for a <code>read</code> that returns a value, and it is an unhandled rejection for a <code>read</code> that returns a promise, which ends a Node.js process unless you handle <code>unhandledRejection</code>. Thanks <a href="https://github.com/SudeepGowda55"><code>@SudeepGowda55</code></a> (<a href="https://redirect.github.com/i18next/i18next/pull/2477">#2477</a>)</li> <li>fix: when a load callback throws, the other callbacks waiting for the same namespaces are still called and the <code>loaded</code> event is still emitted, and the error is thrown on after that. A second <code>loadNamespaces()</code> for the same namespace never called back before.</li> <li>fix: <code>addResourceBundle(lng, ns, resources, true, true)</code> overwrites numbers and booleans too. Only strings were replaced, so <code>{ n: 0 }</code> stayed 0 after adding <code>{ n: 5 }</code>, and adding an object where the bundle had a number, boolean or null threw <code>Cannot create property ... on number</code>, also without <code>overwrite</code>. With <code>overwrite</code>, a number, boolean or null now also replaces a nested object, as a string already did. Thanks <a href="https://github.com/SudeepGowda55"><code>@SudeepGowda55</code></a> (<a href="https://redirect.github.com/i18next/i18next/pull/2476">#2476</a>)</li> <li>fix: with <code>keySeparator: false</code>, a namespace separator inside the key after the namespace is kept. <code>t('common:errors:required')</code> looked up <code>'errorsfalserequired'</code> instead of the flat key <code>'errors:required'</code> that i18next-cli extracts (also for a selector like <code>$ => $.common['errors:required']</code>), and reported the missing key under that name. This dates back to 11.3. Thanks <a href="https://github.com/SudeepGowda55"><code>@SudeepGowda55</code></a> (<a href="https://redirect.github.com/i18next/i18next/pull/2478">#2478</a>)</li> </ul> </blockquote> </details> <details> <summary>Changelog</summary> <p><em>Sourced from <a href="https://github.com/i18next/i18next/blob/master/CHANGELOG.md">i18next's changelog</a>.</em></p> <blockquote> <h2>27.2.2</h2> <ul> <li>fix: <code>setDefaultNamespace()</code> works on a clone. A clone's translator keeps its own options object, so the call changed <code>i18n.options.defaultNS</code> while <code>t()</code> kept using the old default namespace. i18next-http-middleware hands every request a clone, so <code>req.i18n.setDefaultNamespace()</code> did nothing there. (<a href="https://github.com/i18next/i18next/discussions/2106">#2106</a>)</li> <li>fix: <code>supportedLngs</code> works in any casing. Every other language code is formatted (<code>pt-br</code> to <code>pt-BR</code>, <code>EN</code> to <code>en</code>, all lowercase with <code>lowerCaseLng</code>), but <code>supportedLngs</code> was compared as written, so <code>supportedLngs: ['pt-br']</code>, <code>['EN']</code>, or <code>['pt-BR']</code> with <code>lowerCaseLng: true</code> refused that language and fell back. They are now compared in that formatted form (also by <code>loadLanguages()</code>), while <code>options.supportedLngs</code> stays as written. (<a href="https://github.com/i18next/i18next/discussions/1791">#1791</a>)</li> <li>fix(types): resources typed with named <code>interface</code>s get their nested keys. The key types only walked into objects with an index signature, which a type alias has and an interface does not, so <code>t('nested.key')</code> failed with TS2345 while <code>t('nested')</code> compiled. Interfaces now give the same keys as type aliases, so <code>t('nested')</code> without <code>returnObjects</code> is rejected for them too. (<a href="https://github.com/i18next/i18next/discussions/2326">#2326</a>)</li> <li>fix(types): typed keys work with <code>strictNullChecks: false</code>. Without strict null checks <code>undefined</code> passes <code>extends string</code>, so the key prefix, namespace and context checks took a missing <code>keyPrefix</code>, <code>ns</code> or <code>context</code> for a value: <code>t('title')</code> was rejected (only <code>t('ns:title')</code> compiled), <code>t()</code> returned <code>string</code>, and react-i18next's <code>Trans</code> accepted no <code>i18nKey</code>. A new type test project compiles with <code>strictNullChecks: false</code>; with strict null checks the types resolve as before. (<a href="https://github.com/i18next/i18next/discussions/2085">#2085</a>)</li> </ul> <h2>27.2.1</h2> <ul> <li>fix: a variable passed as <code>undefined</code> renders as an empty string when its placeholder has a format too (<code>{{amount, number}}</code>), as <code>{{amount}}</code> already did. The placeholder stayed in the result with the default <code>skipOnVariables: true</code>, and debug mode logged "missed to pass in variable" with either setting. Thanks <a href="https://github.com/Vineet829"><code>@Vineet829</code></a> (<a href="https://redirect.github.com/i18next/i18next/pull/2479">#2479</a>)</li> </ul> <h2>27.2.0</h2> <ul> <li>fix: an error thrown by a load callback or a listener (the callback of <code>init</code>, <code>changeLanguage</code>, <code>loadNamespaces</code> or <code>loadLanguages</code>, or a <code>languageChanged</code> / <code>loaded</code> listener) is no longer handed back to the backend connector as if the read had failed. With a backend whose <code>read</code> returns a value or a promise, the connector got that error a second time: the namespace that had loaded was marked as failed, <code>failedLoading</code> was emitted with your error and the count of running reads dropped to -1. The error now reaches your app: it is thrown from the call that started the load for a <code>read</code> that returns a value, and it is an unhandled rejection for a <code>read</code> that returns a promise, which ends a Node.js process unless you handle <code>unhandledRejection</code>. Thanks <a href="https://github.com/SudeepGowda55"><code>@SudeepGowda55</code></a> (<a href="https://redirect.github.com/i18next/i18next/pull/2477">#2477</a>)</li> <li>fix: when a load callback throws, the other callbacks waiting for the same namespaces are still called and the <code>loaded</code> event is still emitted, and the error is thrown on after that. A second <code>loadNamespaces()</code> for the same namespace never called back before.</li> <li>fix: <code>addResourceBundle(lng, ns, resources, true, true)</code> overwrites numbers and booleans too. Only strings were replaced, so <code>{ n: 0 }</code> stayed 0 after adding <code>{ n: 5 }</code>, and adding an object where the bundle had a number, boolean or null threw <code>Cannot create property ... on number</code>, also without <code>overwrite</code>. With <code>overwrite</code>, a number, boolean or null now also replaces a nested object, as a string already did. Thanks <a href="https://github.com/SudeepGowda55"><code>@SudeepGowda55</code></a> (<a href="https://redirect.github.com/i18next/i18next/pull/2476">#2476</a>)</li> <li>fix: with <code>keySeparator: false</code>, a namespace separator inside the key after the namespace is kept. <code>t('common:errors:required')</code> looked up <code>'errorsfalserequired'</code> instead of the flat key <code>'errors:required'</code> that i18next-cli extracts (also for a selector like <code>$ => $.common['errors:required']</code>), and reported the missing key under that name. This dates back to 11.3. Thanks <a href="https://github.com/SudeepGowda55"><code>@SudeepGowda55</code></a> (<a href="https://redirect.github.com/i18next/i18next/pull/2478">#2478</a>)</li> </ul> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/i18next/i18next/commit/cb3add8ca73406cc1058af0dd358a35a37fd0985"><code>cb3add8</code></a> 27.2.2</li> <li><a href="https://github.com/i18next/i18next/commit/8bfb33bd33c0b54d4d527bd251114a81ee868f03"><code>8bfb33b</code></a> changelog for 27.2.2</li> <li><a href="https://github.com/i18next/i18next/commit/9afc4bfc18c4629f0d94de27926bef75065de1e8"><code>9afc4bf</code></a> fix(types): nested keys for resources typed with interfaces, and typed keys w...</li> <li><a href="https://github.com/i18next/i18next/commit/ef8c31a50c3cbd30debd94be9c6fa1b1f8d5f5ea"><code>ef8c31a</code></a> fix: supportedLngs works in any casing</li> <li><a href="https://github.com/i18next/i18next/commit/edfea35dd79ef36c448c400aa49d92b21c026a6a"><code>edfea35</code></a> fix: setDefaultNamespace() works on a clone</li> <li><a href="https://github.com/i18next/i18next/commit/5d8505d052deef6cd1cd7686170f29bf3bc85ea8"><code>5d8505d</code></a> 27.2.1</li> <li><a href="https://github.com/i18next/i18next/commit/ddbf81289dd53549827adcc817628ab233db7432"><code>ddbf812</code></a> changelog for 27.2.1</li> <li><a href="https://github.com/i18next/i18next/commit/6ba661c332af555c55d91a2ccf6270090f8edb9a"><code>6ba661c</code></a> fix: render a formatted variable passed as undefined as an empty string (<a href="https://redirect.github.com/i18next/i18next/issues/2479">#2479</a>)</li> <li><a href="https://github.com/i18next/i18next/commit/7c7a49ab4271c1cf67d0127799382098f001c72c"><code>7c7a49a</code></a> 27.2.0</li> <li><a href="https://github.com/i18next/i18next/commit/ad31df5fd444e6f219364748a173eecbe3dd2254"><code>ad31df5</code></a> changelog for 27.2.0</li> <li>Additional commits viewable in <a href="https://github.com/i18next/i18next/compare/v27.1.5...v27.2.2">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
Generated
+4
-4
@@ -29,7 +29,7 @@
|
||||
"downshift": "^9.5.0",
|
||||
"events": "^3.3.0",
|
||||
"file-saver": "^2.0.5",
|
||||
"i18next": "^27.1.5",
|
||||
"i18next": "^27.2.2",
|
||||
"i18next-browser-languagedetector": "^8.3.1",
|
||||
"i18next-resources-to-backend": "^1.3.0",
|
||||
"json-stringify-pretty-compact": "^4.0.0",
|
||||
@@ -5830,9 +5830,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/i18next": {
|
||||
"version": "27.1.5",
|
||||
"resolved": "https://registry.npmjs.org/i18next/-/i18next-27.1.5.tgz",
|
||||
"integrity": "sha512-KLrH2SWYWiI8Rx+ZbJ4+fdl5Ny2i8V9bJ6TkJ5YFrSyHgeUIGxoueQTZaafcHZcr1ENFqBicpu7ofr3SCSYDgA==",
|
||||
"version": "27.2.2",
|
||||
"resolved": "https://registry.npmjs.org/i18next/-/i18next-27.2.2.tgz",
|
||||
"integrity": "sha512-1/AJgz/bpE/YL6tqekQlZAzDhkmrUBbgU8+Xon/Lwv6c5WdYuyFZ9mb86OVfR2C2XujUDT7Rz23Ydaq4l981lA==",
|
||||
"funding": [
|
||||
{
|
||||
"type": "individual",
|
||||
|
||||
+1
-1
@@ -46,7 +46,7 @@
|
||||
"downshift": "^9.5.0",
|
||||
"events": "^3.3.0",
|
||||
"file-saver": "^2.0.5",
|
||||
"i18next": "^27.1.5",
|
||||
"i18next": "^27.2.2",
|
||||
"i18next-browser-languagedetector": "^8.3.1",
|
||||
"i18next-resources-to-backend": "^1.3.0",
|
||||
"json-stringify-pretty-compact": "^4.0.0",
|
||||
|
||||
Reference in New Issue
Block a user