@internetarchive/collection-browser 4.8.1-webdev-9227.3 → 4.8.1-webdev-9227.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -13,6 +13,8 @@ import { msg } from '@lit/localize';
|
|
|
13
13
|
* code itself once a target locale's translation is in place.
|
|
14
14
|
*/
|
|
15
15
|
export function getLocale() {
|
|
16
|
-
return msg('en'
|
|
16
|
+
return msg('en', {
|
|
17
|
+
desc: 'Not shown to users. Reports the active locale: translators should translate this to the ISO code of the locale they are translating into.',
|
|
18
|
+
});
|
|
17
19
|
}
|
|
18
20
|
//# sourceMappingURL=get-locale.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-locale.js","sourceRoot":"","sources":["../../../src/utils/get-locale.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,eAAe,CAAC;AAEpC;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,SAAS;IACvB,OAAO,GAAG,CAAC,IAAI,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"get-locale.js","sourceRoot":"","sources":["../../../src/utils/get-locale.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,eAAe,CAAC;AAEpC;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,SAAS;IACvB,OAAO,GAAG,CAAC,IAAI,EAAE;QACf,IAAI,EAAE,2IAA2I;KAClJ,CAAC,CAAC;AACL,CAAC","sourcesContent":["import { msg } from '@lit/localize';\n\n/**\n * Returns the locale code currently active in the host app.\n *\n * This package never sets up `@lit/localize` itself (the host app owns that,\n * once), so `@lit/localize`'s own `getLocale()` isn't available here — it's\n * only returned from the host's one setup call. `msg()` always reflects the\n * host app's current locale, read fresh on every call, with no dependency on\n * when this package happened to load relative to the host setting its\n * locale. This probes a string whose only translation is the ISO code of\n * the locale it was translated into, and reads the locale off whichever\n * string comes back: the untranslated source for the source locale, or the\n * code itself once a target locale's translation is in place.\n */\nexport function getLocale(): string {\n return msg('en', {\n desc: 'Not shown to users. Reports the active locale: translators should translate this to the ISO code of the locale they are translating into.',\n });\n}\n"]}
|
package/package.json
CHANGED