@koine/next 1.0.75 → 1.0.78

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.
@@ -6,7 +6,7 @@ import Head from "next/head";
6
6
  * @see https://github.com/vercel/next.js/discussions/13387#discussioncomment-101564
7
7
  */
8
8
  export var DisableErrorOverlay = function () {
9
- return (_jsx(Head, { children: process.env.NODE_ENV !== "production" && (_jsx("script", { dangerouslySetInnerHTML: {
9
+ return (_jsx(Head, { children: process.env["NODE_ENV"] !== "production" && (_jsx("script", { dangerouslySetInnerHTML: {
10
10
  __html: "window.addEventListener('error',event =>{event.stopImmediatePropagation()});window.addEventListener('unhandledrejection',event =>{event.stopImmediatePropagation()});",
11
11
  } })) }));
12
12
  };
package/T.d.ts CHANGED
@@ -12,3 +12,4 @@ export declare type TProps<TNamespace extends TranslateNamespace | undefined = u
12
12
  * in your `tsconfig.json` file.
13
13
  */
14
14
  export declare const T: (props: TProps) => JSX.Element;
15
+ export default T;
package/T.js CHANGED
@@ -7,3 +7,4 @@ import Trans from "next-translate/Trans";
7
7
  * in your `tsconfig.json` file.
8
8
  */
9
9
  export var T = function (props) { return _jsx(Trans, __assign({}, props)); };
10
+ export default T;
package/app/AppHead.d.ts CHANGED
@@ -1,2 +1,3 @@
1
1
  export declare type AppHeadProps = unknown;
2
2
  export declare const AppHead: () => JSX.Element;
3
+ export default AppHead;
package/app/AppHead.js CHANGED
@@ -3,3 +3,4 @@ import Head from "next/head";
3
3
  export var AppHead = function () {
4
4
  return (_jsx(Head, { children: _jsx("meta", { name: "viewport", content: "width=device-width" }) }));
5
5
  };
6
+ export default AppHead;
@@ -6,3 +6,4 @@ export declare type AppMainProps = Omit<AppMainBaseProps, "ProgressOverlay">;
6
6
  * It does not imply any specific styling or animation solution
7
7
  */
8
8
  export declare const AppMain: ({ Component, pageProps, Layout, seo, pre, post, }: AppMainProps) => JSX.Element;
9
+ export default AppMain;
@@ -11,3 +11,4 @@ export var AppMain = function (_a) {
11
11
  var Component = _a.Component, pageProps = _a.pageProps, Layout = _a.Layout, seo = _a.seo, pre = _a.pre, post = _a.post;
12
12
  return (_jsxs(React.Fragment, { children: [_jsx(SeoDefaults, __assign({}, seo)), pre, _jsx(Layout, { children: _jsx(Component, __assign({}, pageProps)) }), post] }));
13
13
  };
14
+ export default AppMain;
@@ -8,3 +8,4 @@ export declare type AppThemeProps = React.PropsWithChildren<NextAppProps & {
8
8
  * App theme with vanilla class based theme (good for `tailwindcss`)
9
9
  */
10
10
  export declare const AppTheme: ({ theme, children }: AppThemeProps) => JSX.Element;
11
+ export default AppTheme;
@@ -12,3 +12,4 @@ export var AppTheme = function (_a) {
12
12
  // );
13
13
  return (_jsx(ThemeProvider, __assign({ defaultTheme: theme, attribute: "class" }, { children: children })));
14
14
  };
15
+ export default AppTheme;
@@ -8,3 +8,4 @@ export declare type AppMainProps = AppMainBaseProps & AppMainFramerProps;
8
8
  * About the page transition [wallis' blog post](https://wallis.dev/blog/nextjs-page-transitions-with-framer-motion)
9
9
  */
10
10
  export declare const AppMain: ({ Component, pageProps, Layout, ProgressOverlay, seo, motion, transition, pre, post, }: AppMainProps) => JSX.Element;
11
+ export default AppMain;
package/app/em/AppMain.js CHANGED
@@ -22,3 +22,4 @@ export var AppMain = function (_a) {
22
22
  var pathname = useRouter().pathname;
23
23
  return (_jsxs(_Fragment, { children: [_jsx(SeoDefaults, __assign({}, seo)), pre, _jsxs(MotionProvider, __assign({ features: motion }, { children: [ProgressOverlay && _jsx(NextProgress, { Overlay: ProgressOverlay }), _jsx(Layout, { children: _jsx(AnimatePresence, __assign({ exitBeforeEnter: true, initial: false }, { children: _jsx(m.div, __assign({}, transition, { children: _createElement(Component, __assign({}, pageProps, { key: pathname })) }), pathname) })) })] })), post] }));
24
24
  };
25
+ export default AppMain;
@@ -13,3 +13,4 @@ export declare type AppThemeProps = React.PropsWithChildren<NextAppProps & {
13
13
  * App theme with `emotion` (good for `@mui`)s
14
14
  */
15
15
  export declare const AppTheme: ({ emotionCache, theme, children, }: AppThemeProps) => JSX.Element;
16
+ export default AppTheme;
@@ -15,4 +15,5 @@ export var AppTheme = function (_a) {
15
15
  var _b = _a.emotionCache, emotionCache = _b === void 0 ? clientSideEmotionCache : _b, theme = _a.theme, children = _a.children;
16
16
  return (_jsx(CacheProvider, __assign({ value: emotionCache }, { children: _jsxs(ThemeProvider, __assign({ theme: theme }, { children: [_jsx(CssBaseline, {}), _jsx(Global, { styles: css(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), stylesGlobal) }), children] })) })));
17
17
  };
18
+ export default AppTheme;
18
19
  var templateObject_1;
@@ -8,3 +8,4 @@ export declare type AppMainProps = AppMainBaseProps & AppMainFramerProps;
8
8
  * About the page transition [wallis' blog post](https://wallis.dev/blog/nextjs-page-transitions-with-framer-motion)
9
9
  */
10
10
  export declare const AppMain: ({ Component, pageProps, Layout, ProgressOverlay, seo, motion, transition, pre, post, }: AppMainProps) => JSX.Element;
11
+ export default AppMain;
package/app/sc/AppMain.js CHANGED
@@ -22,3 +22,4 @@ export var AppMain = function (_a) {
22
22
  var pathname = useRouter().pathname;
23
23
  return (_jsxs(_Fragment, { children: [_jsx(SeoDefaults, __assign({}, seo)), pre, _jsxs(MotionProvider, __assign({ features: motion }, { children: [ProgressOverlay && _jsx(NextProgress, { Overlay: ProgressOverlay }), _jsx(Layout, { children: _jsx(AnimatePresence, __assign({ exitBeforeEnter: true, initial: false }, { children: _jsx(m.div, __assign({}, transition, { children: _createElement(Component, __assign({}, pageProps, { key: pathname })) }), pathname) })) })] })), post] }));
24
24
  };
25
+ export default AppMain;
@@ -11,3 +11,4 @@ export declare type AppThemeProps = React.PropsWithChildren<NextAppProps & {
11
11
  * App theme with `styled-components`
12
12
  */
13
13
  export declare const AppTheme: ({ theme, children }: AppThemeProps) => JSX.Element;
14
+ export default AppTheme;
@@ -9,3 +9,4 @@ export var AppTheme = function (_a) {
9
9
  var theme = _a.theme, children = _a.children;
10
10
  return (_jsxs(ThemeProvider, __assign({ theme: theme }, { children: [_jsx(StylesGlobal, {}), children] })));
11
11
  };
12
+ export default AppTheme;
package/config/index.js CHANGED
@@ -165,7 +165,7 @@ export function getRedirects(defaultLocale, routes, permanent, debug) {
165
165
  }
166
166
  });
167
167
  if (debug)
168
- console.log("redirects", redirects);
168
+ console.info("[@koine/next/config:getRedirects]", redirects);
169
169
  return [2 /*return*/, redirects];
170
170
  });
171
171
  });
@@ -185,7 +185,7 @@ export function getRewrites(routes, debug) {
185
185
  }
186
186
  });
187
187
  if (debug)
188
- console.log("rewrites", rewrites);
188
+ console.info("[@koine/next/config:getRewrites]", rewrites);
189
189
  return [2 /*return*/, rewrites];
190
190
  });
191
191
  });
@@ -13,3 +13,4 @@ import NextDocument from "next/document";
13
13
  export declare class Document extends NextDocument {
14
14
  render(): JSX.Element;
15
15
  }
16
+ export default Document;
@@ -24,3 +24,4 @@ var Document = /** @class */ (function (_super) {
24
24
  return Document;
25
25
  }(NextDocument));
26
26
  export { Document };
27
+ export default Document;
@@ -10,7 +10,7 @@ var head_1 = tslib_1.__importDefault(require("next/head"));
10
10
  * @see https://github.com/vercel/next.js/discussions/13387#discussioncomment-101564
11
11
  */
12
12
  var DisableErrorOverlay = function () {
13
- return ((0, jsx_runtime_1.jsx)(head_1.default, { children: process.env.NODE_ENV !== "production" && ((0, jsx_runtime_1.jsx)("script", { dangerouslySetInnerHTML: {
13
+ return ((0, jsx_runtime_1.jsx)(head_1.default, { children: process.env["NODE_ENV"] !== "production" && ((0, jsx_runtime_1.jsx)("script", { dangerouslySetInnerHTML: {
14
14
  __html: "window.addEventListener('error',event =>{event.stopImmediatePropagation()});window.addEventListener('unhandledrejection',event =>{event.stopImmediatePropagation()});",
15
15
  } })) }));
16
16
  };
package/node/T.js CHANGED
@@ -11,3 +11,4 @@ var Trans_1 = tslib_1.__importDefault(require("next-translate/Trans"));
11
11
  */
12
12
  var T = function (props) { return (0, jsx_runtime_1.jsx)(Trans_1.default, tslib_1.__assign({}, props)); };
13
13
  exports.T = T;
14
+ exports.default = exports.T;
@@ -8,3 +8,4 @@ var AppHead = function () {
8
8
  return ((0, jsx_runtime_1.jsx)(head_1.default, { children: (0, jsx_runtime_1.jsx)("meta", { name: "viewport", content: "width=device-width" }) }));
9
9
  };
10
10
  exports.AppHead = AppHead;
11
+ exports.default = exports.AppHead;
@@ -15,3 +15,4 @@ var AppMain = function (_a) {
15
15
  return ((0, jsx_runtime_1.jsxs)(react_1.default.Fragment, { children: [(0, jsx_runtime_1.jsx)(SeoDefaults_1.SeoDefaults, tslib_1.__assign({}, seo)), pre, (0, jsx_runtime_1.jsx)(Layout, { children: (0, jsx_runtime_1.jsx)(Component, tslib_1.__assign({}, pageProps)) }), post] }));
16
16
  };
17
17
  exports.AppMain = AppMain;
18
+ exports.default = exports.AppMain;
@@ -16,3 +16,4 @@ var AppTheme = function (_a) {
16
16
  return ((0, jsx_runtime_1.jsx)(ThemeProvider_1.ThemeProvider, tslib_1.__assign({ defaultTheme: theme, attribute: "class" }, { children: children })));
17
17
  };
18
18
  exports.AppTheme = AppTheme;
19
+ exports.default = exports.AppTheme;
@@ -26,3 +26,4 @@ var AppMain = function (_a) {
26
26
  return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(SeoDefaults_1.SeoDefaults, tslib_1.__assign({}, seo)), pre, (0, jsx_runtime_1.jsxs)(m_1.MotionProvider, tslib_1.__assign({ features: motion }, { children: [ProgressOverlay && (0, jsx_runtime_1.jsx)(NextProgress_1.NextProgress, { Overlay: ProgressOverlay }), (0, jsx_runtime_1.jsx)(Layout, { children: (0, jsx_runtime_1.jsx)(framer_motion_1.AnimatePresence, tslib_1.__assign({ exitBeforeEnter: true, initial: false }, { children: (0, jsx_runtime_1.jsx)(framer_motion_1.m.div, tslib_1.__assign({}, transition, { children: (0, react_1.createElement)(Component, tslib_1.__assign({}, pageProps, { key: pathname })) }), pathname) })) })] })), post] }));
27
27
  };
28
28
  exports.AppMain = AppMain;
29
+ exports.default = exports.AppMain;
@@ -19,4 +19,5 @@ var AppTheme = function (_a) {
19
19
  return ((0, jsx_runtime_1.jsx)(react_1.CacheProvider, tslib_1.__assign({ value: emotionCache }, { children: (0, jsx_runtime_1.jsxs)(styles_1.ThemeProvider, tslib_1.__assign({ theme: theme }, { children: [(0, jsx_runtime_1.jsx)(CssBaseline_1.default, {}), (0, jsx_runtime_1.jsx)(react_2.Global, { styles: (0, react_2.css)(templateObject_1 || (templateObject_1 = tslib_1.__makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), sc_1.stylesGlobal) }), children] })) })));
20
20
  };
21
21
  exports.AppTheme = AppTheme;
22
+ exports.default = exports.AppTheme;
22
23
  var templateObject_1;
@@ -26,3 +26,4 @@ var AppMain = function (_a) {
26
26
  return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(SeoDefaults_1.SeoDefaults, tslib_1.__assign({}, seo)), pre, (0, jsx_runtime_1.jsxs)(m_1.MotionProvider, tslib_1.__assign({ features: motion }, { children: [ProgressOverlay && (0, jsx_runtime_1.jsx)(NextProgress_1.NextProgress, { Overlay: ProgressOverlay }), (0, jsx_runtime_1.jsx)(Layout, { children: (0, jsx_runtime_1.jsx)(framer_motion_1.AnimatePresence, tslib_1.__assign({ exitBeforeEnter: true, initial: false }, { children: (0, jsx_runtime_1.jsx)(framer_motion_1.m.div, tslib_1.__assign({}, transition, { children: (0, react_1.createElement)(Component, tslib_1.__assign({}, pageProps, { key: pathname })) }), pathname) })) })] })), post] }));
27
27
  };
28
28
  exports.AppMain = AppMain;
29
+ exports.default = exports.AppMain;
@@ -13,3 +13,4 @@ var AppTheme = function (_a) {
13
13
  return ((0, jsx_runtime_1.jsxs)(styled_components_1.ThemeProvider, tslib_1.__assign({ theme: theme }, { children: [(0, jsx_runtime_1.jsx)(sc_1.StylesGlobal, {}), children] })));
14
14
  };
15
15
  exports.AppTheme = AppTheme;
16
+ exports.default = exports.AppTheme;
@@ -173,7 +173,7 @@ function getRedirects(defaultLocale, routes, permanent, debug) {
173
173
  }
174
174
  });
175
175
  if (debug)
176
- console.log("redirects", redirects);
176
+ console.info("[@koine/next/config:getRedirects]", redirects);
177
177
  return [2 /*return*/, redirects];
178
178
  });
179
179
  });
@@ -194,7 +194,7 @@ function getRewrites(routes, debug) {
194
194
  }
195
195
  });
196
196
  if (debug)
197
- console.log("rewrites", rewrites);
197
+ console.info("[@koine/next/config:getRewrites]", rewrites);
198
198
  return [2 /*return*/, rewrites];
199
199
  });
200
200
  });
@@ -27,3 +27,4 @@ var Document = /** @class */ (function (_super) {
27
27
  return Document;
28
28
  }(document_1.default));
29
29
  exports.Document = Document;
30
+ exports.default = Document;
@@ -39,3 +39,4 @@ var useDateFormat = function () {
39
39
  return formatter;
40
40
  };
41
41
  exports.useDateFormat = useDateFormat;
42
+ exports.default = exports.useDateFormat;
package/node/useForm.js CHANGED
@@ -17,7 +17,7 @@ schema, t, formProps, debug) {
17
17
  // const field = { control, register, setValue, t };
18
18
  // if (process.env["NODE_ENV"] !== "production") {
19
19
  // if (debug) {
20
- // console.log(
20
+ // console.info(
21
21
  // `Form ${i18nNamespace} data`,
22
22
  // form.watch(),
23
23
  // `errors: `,
@@ -35,3 +35,4 @@ schema, t, formProps, debug) {
35
35
  }, [t, form]);
36
36
  }
37
37
  exports.useForm = useForm;
38
+ exports.default = useForm;
package/node/useLocale.js CHANGED
@@ -7,3 +7,4 @@ function useLocale() {
7
7
  return (0, useTranslation_1.default)().lang;
8
8
  }
9
9
  exports.useLocale = useLocale;
10
+ exports.default = useLocale;
package/node/useT.js CHANGED
@@ -20,6 +20,7 @@ function useT(namespace) {
20
20
  return tMemoized;
21
21
  }
22
22
  exports.useT = useT;
23
+ exports.default = useT;
23
24
  // Instead of wrapping the `useTranslation` hook from [`next-translate`](https://github.com/vinissimus/next-translate/blob/master/src/useTranslation.tsx)
24
25
  // we might just rewrite it with our custom implementation but the `_context`
25
26
  // to use is not exposed by the library...
package/package.json CHANGED
@@ -14,34 +14,35 @@
14
14
  },
15
15
  "main": "./node/index.js",
16
16
  "typings": "./index.d.ts",
17
- "dependencies": {},
18
- "peerDependencies": {
19
- "react": "^16.8 || ^17 || ^18",
20
- "next": "^12.2.3",
21
- "@koine/utils": "1.0.75",
22
- "framer-motion": "^6.5.1",
23
- "@koine/react": "1.0.75",
17
+ "dependencies": {
18
+ "react": "^18.2.0",
19
+ "next": "^12.2.5",
20
+ "@koine/utils": "1.0.78",
21
+ "date-fns-tz": "^1.3.7",
22
+ "framer-motion": "^7.2.1",
23
+ "@koine/react": "1.0.78",
24
24
  "styled-components": "^5.3.5",
25
- "@mui/base": "^5.0.0-alpha.90",
25
+ "@mui/base": "^5.0.0-alpha.95",
26
26
  "react-icons": "^4.4.0",
27
- "date-fns": "^2.29.1",
27
+ "date-fns": "^2.29.2",
28
28
  "react-swipeable": "^7.0.0",
29
- "@tiptap/react": "^2.0.0-beta.114",
30
- "@tiptap/starter-kit": "^2.0.0-beta.191",
29
+ "@tiptap/react": "^2.0.0-beta.115",
30
+ "@tiptap/starter-kit": "^2.0.0-beta.192",
31
31
  "@kuus/yup": "^1.0.0-beta.4",
32
- "react-hook-form": "^7.33.1",
33
- "type-fest": "^2.17.0",
32
+ "react-hook-form": "^7.34.2",
33
+ "type-fest": "^2.19.0",
34
34
  "react-popper": "^2.3.0",
35
35
  "tslib": "^2.4.0",
36
- "next-auth": "^4.10.2",
37
- "@mui/material": "^5.9.1",
38
- "@emotion/react": "^11.9.3",
39
- "@emotion/server": "^11.4.0",
36
+ "next-auth": "^4.10.3",
37
+ "@mui/material": "^5.10.3",
38
+ "@emotion/react": "^11.10.4",
39
+ "@emotion/server": "^11.10.0",
40
40
  "next-translate": "^1.5.0",
41
41
  "next-seo": "^5.5.0",
42
- "@hookform/resolvers": "^2.9.6"
42
+ "@hookform/resolvers": "^2.9.7"
43
43
  },
44
- "version": "1.0.75",
44
+ "peerDependencies": {},
45
+ "version": "1.0.78",
45
46
  "module": "./index.js",
46
47
  "types": "./index.d.ts"
47
48
  }
package/seoBuildTags.d.ts CHANGED
@@ -17,5 +17,5 @@ declare type BuildTagsParams = SeoProps & SeoDefaultsProps;
17
17
  *
18
18
  * @returns
19
19
  */
20
- export declare const seoBuildTags: ({ seo, hidden, keywords, title, titleTemplate, defaultTitle, noindex, nofollow, description, languageAlternates, twitter, facebook, openGraph, og: ogAlias, canonical, metaTags, linkTags, }?: BuildTagsParams) => React.ReactNode[];
20
+ export declare const seoBuildTags: ({ seo, hidden, keywords, title, titleTemplate, defaultTitle, noindex, nofollow, description, languageAlternates, twitter, facebook, openGraph, og, canonical, metaTags, linkTags, }?: BuildTagsParams) => React.ReactNode[];
21
21
  export default seoBuildTags;
@@ -4,3 +4,4 @@ import format from "date-fns/format";
4
4
  * passed as option (grabbed from next router value).
5
5
  */
6
6
  export declare const useDateFormat: () => typeof format;
7
+ export default useDateFormat;
package/useDateFormat.js CHANGED
@@ -35,3 +35,4 @@ export var useDateFormat = function () {
35
35
  }, [locale]);
36
36
  return formatter;
37
37
  };
38
+ export default useDateFormat;
package/useForm.d.ts CHANGED
@@ -14,13 +14,14 @@ export declare function useForm<T extends FieldValues>(schema: ObjectSchema<any>
14
14
  reset: import("react-hook-form").UseFormReset<T>;
15
15
  handleSubmit: import("react-hook-form").UseFormHandleSubmit<T>;
16
16
  unregister: import("react-hook-form").UseFormUnregister<T>;
17
- control: import("react-hook-form").Control<T, object>;
17
+ control: import("react-hook-form").Control<T, any>;
18
18
  register: import("react-hook-form").UseFormRegister<T>;
19
19
  setFocus: import("react-hook-form").UseFormSetFocus<T>;
20
20
  field: {
21
- control: import("react-hook-form").Control<T, object>;
21
+ control: import("react-hook-form").Control<T, any>;
22
22
  register: import("react-hook-form").UseFormRegister<T>;
23
23
  setValue: import("react-hook-form").UseFormSetValue<T>;
24
24
  t: TranslateLoose;
25
25
  };
26
26
  };
27
+ export default useForm;
package/useForm.js CHANGED
@@ -14,7 +14,7 @@ schema, t, formProps, debug) {
14
14
  // const field = { control, register, setValue, t };
15
15
  // if (process.env["NODE_ENV"] !== "production") {
16
16
  // if (debug) {
17
- // console.log(
17
+ // console.info(
18
18
  // `Form ${i18nNamespace} data`,
19
19
  // form.watch(),
20
20
  // `errors: `,
@@ -31,3 +31,4 @@ schema, t, formProps, debug) {
31
31
  return __assign({ field: field }, form);
32
32
  }, [t, form]);
33
33
  }
34
+ export default useForm;
package/useLocale.d.ts CHANGED
@@ -1 +1,2 @@
1
1
  export declare function useLocale(): string;
2
+ export default useLocale;
package/useLocale.js CHANGED
@@ -2,3 +2,4 @@ import useTranslation from "next-translate/useTranslation";
2
2
  export function useLocale() {
3
3
  return useTranslation().lang;
4
4
  }
5
+ export default useLocale;
package/useT.d.ts CHANGED
@@ -14,3 +14,4 @@ import type { TranslateNamespace, TranslateDefault, TranslateNamespaced } from "
14
14
  */
15
15
  export declare function useT(): TranslateDefault;
16
16
  export declare function useT<TNamespace extends TranslateNamespace>(namespace: TNamespace): TranslateNamespaced<TNamespace>;
17
+ export default useT;
package/useT.js CHANGED
@@ -15,6 +15,7 @@ export function useT(namespace) {
15
15
  }, [t, namespace]);
16
16
  return tMemoized;
17
17
  }
18
+ export default useT;
18
19
  // Instead of wrapping the `useTranslation` hook from [`next-translate`](https://github.com/vinissimus/next-translate/blob/master/src/useTranslation.tsx)
19
20
  // we might just rewrite it with our custom implementation but the `_context`
20
21
  // to use is not exposed by the library...