@chrryai/chrry 1.6.90 → 1.6.91

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
@@ -3156,7 +3156,7 @@ var init_utils = __esm({
3156
3156
  };
3157
3157
  isFirefox = typeof navigator !== "undefined" && navigator?.userAgent?.includes("Firefox");
3158
3158
  config = getSiteConfig(getClientHostname());
3159
- VERSION = config.version || "1.6.90";
3159
+ VERSION = config.version || "1.6.91";
3160
3160
  getSlugFromPathname = (path) => {
3161
3161
  return getAppAndStoreSlugs(path, {
3162
3162
  defaultAppSlug: config.slug,
@@ -6162,47 +6162,32 @@ var init_useWindowHistory = __esm({
6162
6162
 
6163
6163
  // platform/navigation.web.ts
6164
6164
  function useNavigation() {
6165
- const nextRouter = useNextRouter?.();
6166
- const pathname = useNextPathname?.() || usePathname();
6167
- const searchParams = useNextSearchParams?.() || useSearchParams();
6165
+ const pathname = usePathname();
6166
+ const searchParams = useSearchParams();
6168
6167
  const clientRouter2 = useRouter();
6169
6168
  const push = (0, import_react17.useCallback)(
6170
6169
  (path, options) => {
6171
- const useClientOnly = options?.clientOnly !== false;
6172
- if (useClientOnly) {
6173
- clientRouter2.push(path, { scroll: options?.scroll });
6174
- } else {
6175
- nextRouter?.push(path, { scroll: options?.scroll });
6176
- }
6170
+ clientRouter2.push(path, { scroll: options?.scroll });
6177
6171
  },
6178
- [nextRouter, clientRouter2]
6172
+ [clientRouter2]
6179
6173
  );
6180
6174
  const replace = (0, import_react17.useCallback)(
6181
6175
  (path, options) => {
6182
- const useClientOnly = options?.clientOnly !== false;
6183
- if (useClientOnly) {
6184
- clientRouter2.replace(path, { scroll: options?.scroll });
6185
- } else {
6186
- nextRouter?.replace(path, { scroll: options?.scroll });
6187
- }
6176
+ clientRouter2.replace(path, { scroll: options?.scroll });
6188
6177
  },
6189
- [nextRouter, clientRouter2]
6178
+ [clientRouter2]
6190
6179
  );
6191
6180
  const back = (0, import_react17.useCallback)(() => {
6192
- nextRouter?.back();
6193
- }, [nextRouter]);
6181
+ clientRouter2.back();
6182
+ }, [clientRouter2]);
6194
6183
  const forward = (0, import_react17.useCallback)(() => {
6195
- nextRouter?.forward();
6196
- }, [nextRouter]);
6184
+ clientRouter2.forward();
6185
+ }, [clientRouter2]);
6197
6186
  const refresh = (0, import_react17.useCallback)(() => {
6198
- nextRouter?.refresh();
6199
- }, [nextRouter]);
6200
- const prefetch = (0, import_react17.useCallback)(
6201
- (path) => {
6202
- nextRouter?.prefetch(path);
6203
- },
6204
- [nextRouter]
6205
- );
6187
+ window.location.reload();
6188
+ }, []);
6189
+ const prefetch = (0, import_react17.useCallback)((path) => {
6190
+ }, []);
6206
6191
  const addParams = (0, import_react17.useCallback)(
6207
6192
  (params) => {
6208
6193
  const newSearchParams = new URLSearchParams(searchParams?.toString());
@@ -6211,13 +6196,9 @@ function useNavigation() {
6211
6196
  });
6212
6197
  const queryString = newSearchParams.toString();
6213
6198
  const newUrl = queryString ? `${pathname}?${queryString}` : pathname;
6214
- if (nextRouter) {
6215
- nextRouter.push(newUrl);
6216
- } else {
6217
- clientRouter2.push(newUrl);
6218
- }
6199
+ clientRouter2.push(newUrl);
6219
6200
  },
6220
- [nextRouter, clientRouter2, pathname, searchParams]
6201
+ [clientRouter2, pathname, searchParams]
6221
6202
  );
6222
6203
  const removeParams = (0, import_react17.useCallback)(
6223
6204
  (keys) => {
@@ -6226,13 +6207,9 @@ function useNavigation() {
6226
6207
  keysArray.forEach((key) => newSearchParams.delete(key));
6227
6208
  const queryString = newSearchParams.toString();
6228
6209
  const newUrl = queryString ? `${pathname}?${queryString}` : pathname;
6229
- if (nextRouter) {
6230
- nextRouter.push(newUrl);
6231
- } else {
6232
- clientRouter2.push(newUrl);
6233
- }
6210
+ clientRouter2.push(newUrl);
6234
6211
  },
6235
- [nextRouter, clientRouter2, pathname, searchParams]
6212
+ [clientRouter2, pathname, searchParams]
6236
6213
  );
6237
6214
  const setParams = (0, import_react17.useCallback)(
6238
6215
  (params) => {
@@ -6242,13 +6219,9 @@ function useNavigation() {
6242
6219
  });
6243
6220
  const queryString = newSearchParams.toString();
6244
6221
  const newUrl = queryString ? `${pathname}?${queryString}` : pathname;
6245
- if (nextRouter) {
6246
- nextRouter.push(newUrl);
6247
- } else {
6248
- clientRouter2.push(newUrl);
6249
- }
6222
+ clientRouter2.push(newUrl);
6250
6223
  },
6251
- [nextRouter, clientRouter2, pathname]
6224
+ [clientRouter2, pathname]
6252
6225
  );
6253
6226
  return (0, import_react17.useMemo)(
6254
6227
  () => ({
@@ -6282,19 +6255,12 @@ function useNavigation() {
6282
6255
  function usePreviousPathname() {
6283
6256
  return null;
6284
6257
  }
6285
- var import_react17, useNextRouter, useNextPathname, useNextSearchParams;
6258
+ var import_react17;
6286
6259
  var init_navigation_web = __esm({
6287
6260
  "platform/navigation.web.ts"() {
6288
6261
  "use strict";
6289
6262
  import_react17 = __toESM(require("react"));
6290
6263
  init_useWindowHistory();
6291
- try {
6292
- const nextNavigation = require("next/navigation");
6293
- useNextRouter = nextNavigation.useRouter;
6294
- useNextPathname = nextNavigation.usePathname;
6295
- useNextSearchParams = nextNavigation.useSearchParams;
6296
- } catch {
6297
- }
6298
6264
  }
6299
6265
  });
6300
6266
 
@@ -24740,7 +24706,7 @@ function DataProvider({ children, ...rest }) {
24740
24706
  const [instructions, setInstructions] = (0, import_react21.useState)([]);
24741
24707
  const [affiliateStats, setAffiliateStats] = (0, import_react21.useState)(null);
24742
24708
  const [loadingAffiliateStats, setLoadingAffiliateStats] = (0, import_react21.useState)(false);
24743
- const VERSION4 = "1.6.90";
24709
+ const VERSION4 = "1.6.91";
24744
24710
  const [weather, setWeather] = useLocalStorage2("weather", user?.weather || guest?.weather || void 0);
24745
24711
  const {
24746
24712
  API_URL: API_URL2,