@sheet-i18n/react-client 1.5.0-canary.3 → 1.5.0-canary.5

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.
package/dist/index.js CHANGED
@@ -162,6 +162,7 @@ function IntlProvider({
162
162
  children
163
163
  }) {
164
164
  const { locale } = useIntlLocale({ i18nStore, currentLocale });
165
+ console.log("\u2705 locale in IntlProvider", locale);
165
166
  const onIntlError = (err) => {
166
167
  const typeSafe = i18nStore.typeSafe;
167
168
  if (typeSafe) {
@@ -175,7 +176,7 @@ function IntlProvider({
175
176
  locale,
176
177
  messages: i18nStore == null ? void 0 : i18nStore.localeSet[locale],
177
178
  onError: onIntlError,
178
- children: !isLoading && children
179
+ children
179
180
  }
180
181
  );
181
182
  }
@@ -459,13 +460,11 @@ var LISTENER_ID = "LOCALE_STORAGE_LISTENER_ID";
459
460
  function useLocaleStorage(localeStorageManager) {
460
461
  var _a;
461
462
  const [locale, setLocale] = (0, import_react3.useState)((_a = localeStorageManager == null ? void 0 : localeStorageManager.getLocale) == null ? void 0 : _a.call(localeStorageManager));
462
- console.log("\u2705 locale in useLocaleStorage", locale);
463
463
  (0, import_react3.useEffect)(() => {
464
464
  var _a2;
465
465
  (_a2 = localeStorageManager == null ? void 0 : localeStorageManager.observerManager) == null ? void 0 : _a2.addListener({
466
466
  listenerId: LISTENER_ID,
467
467
  listener: (newLocale) => {
468
- console.log("\u2705 did you update the locale?", newLocale);
469
468
  setLocale(newLocale);
470
469
  }
471
470
  });
package/dist/index.mjs CHANGED
@@ -139,6 +139,7 @@ function IntlProvider({
139
139
  children
140
140
  }) {
141
141
  const { locale } = useIntlLocale({ i18nStore, currentLocale });
142
+ console.log("\u2705 locale in IntlProvider", locale);
142
143
  const onIntlError = (err) => {
143
144
  const typeSafe = i18nStore.typeSafe;
144
145
  if (typeSafe) {
@@ -152,7 +153,7 @@ function IntlProvider({
152
153
  locale,
153
154
  messages: i18nStore == null ? void 0 : i18nStore.localeSet[locale],
154
155
  onError: onIntlError,
155
- children: !isLoading && children
156
+ children
156
157
  }
157
158
  );
158
159
  }
@@ -436,13 +437,11 @@ var LISTENER_ID = "LOCALE_STORAGE_LISTENER_ID";
436
437
  function useLocaleStorage(localeStorageManager) {
437
438
  var _a;
438
439
  const [locale, setLocale] = useState2((_a = localeStorageManager == null ? void 0 : localeStorageManager.getLocale) == null ? void 0 : _a.call(localeStorageManager));
439
- console.log("\u2705 locale in useLocaleStorage", locale);
440
440
  useEffect2(() => {
441
441
  var _a2;
442
442
  (_a2 = localeStorageManager == null ? void 0 : localeStorageManager.observerManager) == null ? void 0 : _a2.addListener({
443
443
  listenerId: LISTENER_ID,
444
444
  listener: (newLocale) => {
445
- console.log("\u2705 did you update the locale?", newLocale);
446
445
  setLocale(newLocale);
447
446
  }
448
447
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sheet-i18n/react-client",
3
- "version": "1.5.0-canary.3",
3
+ "version": "1.5.0-canary.5",
4
4
  "description": "a client package for react modules used by sheet-i18n",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",