@koine/next 1.0.3 → 1.0.8
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/Analytics/AnalyticsGoogle.d.ts +5 -6
- package/Analytics/AnalyticsGoogle.js +37 -0
- package/Analytics/index.d.ts +1 -1
- package/Analytics/index.js +1 -0
- package/Auth/helpers.d.ts +17 -17
- package/Auth/helpers.js +21 -0
- package/Auth/index.d.ts +4 -4
- package/Auth/index.js +4 -0
- package/Auth/useLogin.d.ts +7 -7
- package/Auth/useLogin.js +47 -0
- package/Auth/useLoginUrl.d.ts +1 -1
- package/Auth/useLoginUrl.js +11 -0
- package/Auth/useLogout.d.ts +6 -6
- package/Auth/useLogout.js +52 -0
- package/Favicon/Favicon.d.ts +3 -4
- package/Favicon/Favicon.js +4 -0
- package/Favicon/index.d.ts +1 -1
- package/Favicon/index.js +1 -0
- package/Forms/index.d.ts +2 -2
- package/Forms/index.js +2 -0
- package/Forms/useForm.d.ts +32 -32
- package/Forms/useForm.js +33 -0
- package/Forms/useSubmit.d.ts +24 -24
- package/Forms/useSubmit.js +20 -0
- package/Head/Head.d.ts +1 -1
- package/Head/Head.js +1 -0
- package/Head/index.d.ts +1 -1
- package/Head/index.js +1 -0
- package/I18n/I18n.d.ts +48 -48
- package/I18n/I18n.js +86 -0
- package/I18n/index.d.ts +1 -1
- package/I18n/index.js +1 -0
- package/Img/Img.d.ts +21 -21
- package/Img/Img.js +30 -0
- package/Img/index.d.ts +1 -1
- package/Img/index.js +1 -0
- package/Link/Link.d.ts +8 -8
- package/Link/Link.js +12 -0
- package/Link/index.d.ts +1 -1
- package/Link/index.js +1 -0
- package/NextProgress/NextProgress.d.ts +13 -14
- package/NextProgress/NextProgress.js +38 -0
- package/NextProgress/index.d.ts +1 -1
- package/NextProgress/index.js +1 -0
- package/Seo/Seo.d.ts +3 -3
- package/Seo/Seo.js +8 -0
- package/Seo/SeoDefaults.d.ts +3 -3
- package/Seo/SeoDefaults.js +12 -0
- package/Seo/helpers.d.ts +48 -48
- package/Seo/helpers.js +113 -0
- package/Seo/index.d.ts +12 -12
- package/Seo/index.js +12 -0
- package/Theme/Theme.d.ts +46 -46
- package/Theme/Theme.js +235 -0
- package/Theme/index.d.ts +1 -1
- package/Theme/index.js +1 -0
- package/app/App--emotion.d.ts +10 -10
- package/app/App--emotion.js +11 -0
- package/app/App--sc.d.ts +10 -10
- package/app/App--sc.js +11 -0
- package/app/App--vanilla.d.ts +10 -10
- package/app/App--vanilla.js +11 -0
- package/app/AppAuth--emotion.d.ts +10 -10
- package/app/AppAuth--emotion.js +12 -0
- package/app/AppAuth--sc.d.ts +10 -10
- package/app/AppAuth--sc.js +12 -0
- package/app/AppHead.d.ts +3 -3
- package/app/AppHead.js +5 -0
- package/app/{AppMain.d.ts → AppMain--emotion.d.ts} +34 -34
- package/app/AppMain--emotion.js +27 -0
- package/app/AppMain--sc.d.ts +34 -0
- package/app/AppMain--sc.js +27 -0
- package/app/AppMain--vanilla.d.ts +27 -27
- package/app/AppMain--vanilla.js +11 -0
- package/app/AppTheme--emotion.d.ts +15 -15
- package/app/AppTheme--emotion.js +17 -0
- package/app/AppTheme--sc.d.ts +13 -13
- package/app/AppTheme--sc.js +9 -0
- package/app/AppTheme--vanilla.d.ts +10 -10
- package/app/AppTheme--vanilla.js +12 -0
- package/app/index.d.ts +11 -11
- package/app/index.js +11 -0
- package/app/motion-features.d.ts +2 -2
- package/app/motion-features.js +2 -0
- package/config/index.d.ts +58 -58
- package/config/index.js +144 -0
- package/document/Document--emotion.d.ts +5 -5
- package/document/Document--emotion.js +55 -0
- package/document/Document--sc.d.ts +11 -11
- package/document/Document--sc.js +33 -0
- package/document/Document--vanilla.d.ts +11 -11
- package/document/Document--vanilla.js +20 -0
- package/document/Document.d.ts +10 -10
- package/document/Document.js +14 -0
- package/document/index.d.ts +4 -4
- package/document/index.js +4 -0
- package/index.d.ts +15 -12
- package/index.js +15 -743
- package/index.umd.js +2061 -78
- package/package.json +27 -21
- package/{types.d.ts → typings.d.ts} +0 -0
- package/utils/api.d.ts +55 -55
- package/utils/api.js +33 -0
- package/{document/emotion.d.ts → utils/emotion-cache.d.ts} +5 -5
- package/utils/emotion-cache.js +8 -0
- package/utils/index.d.ts +20 -19
- package/utils/index.js +27 -0
- package/Theme.js +0 -1905
- package/_tslib.js +0 -41
- package/app.js +0 -250
- package/config.js +0 -183
- package/document.js +0 -207
- package/emotion.js +0 -1329
- package/es.object.assign.js +0 -1074
- package/es.string.replace.js +0 -785
- package/es.string.split.js +0 -201
- package/index.esm.js +0 -4600
- package/motion-features.js +0 -10
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import NextDocument, { DocumentContext, DocumentInitialProps } from "next/document";
|
|
3
|
-
import { ThemeVanillaValue } from "@koine/react";
|
|
4
|
-
/**
|
|
5
|
-
*/
|
|
6
|
-
export declare class DocumentVanilla extends NextDocument {
|
|
7
|
-
static getInitialProps(ctx: DocumentContext): Promise<DocumentInitialProps & {
|
|
8
|
-
theme: ThemeVanillaValue;
|
|
9
|
-
}>;
|
|
10
|
-
render(): JSX.Element;
|
|
11
|
-
}
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import NextDocument, { DocumentContext, DocumentInitialProps } from "next/document";
|
|
3
|
+
import { ThemeVanillaValue } from "@koine/react";
|
|
4
|
+
/**
|
|
5
|
+
*/
|
|
6
|
+
export declare class DocumentVanilla extends NextDocument {
|
|
7
|
+
static getInitialProps(ctx: DocumentContext): Promise<DocumentInitialProps & {
|
|
8
|
+
theme: ThemeVanillaValue;
|
|
9
|
+
}>;
|
|
10
|
+
render(): JSX.Element;
|
|
11
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { __awaiter } from "tslib";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
/* ? eslint-disable @next/next/no-document-import-in-page */
|
|
4
|
+
import NextDocument, { Html, Head, Main, NextScript, } from "next/document";
|
|
5
|
+
import { Meta, NoJs, getInitialThemeFromRequest, } from "@koine/react";
|
|
6
|
+
/**
|
|
7
|
+
*/
|
|
8
|
+
export class DocumentVanilla extends NextDocument {
|
|
9
|
+
static getInitialProps(ctx) {
|
|
10
|
+
var _a;
|
|
11
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
12
|
+
const initialProps = yield NextDocument.getInitialProps(ctx);
|
|
13
|
+
return Object.assign(Object.assign({}, initialProps), { theme: getInitialThemeFromRequest(((_a = ctx.req) === null || _a === void 0 ? void 0 : _a.headers.cookie /* || document?.cookie */) || "") });
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
render() {
|
|
17
|
+
const { locale, defaultLocale } = this.props.__NEXT_DATA__;
|
|
18
|
+
return (_jsxs(Html, Object.assign({ lang: locale || defaultLocale, className: "no-js" }, { children: [_jsxs(Head, { children: [_jsx(Meta, {}), _jsx(NoJs, {})] }), _jsxs("body", { children: [_jsx(Main, {}), _jsx(NextScript, {})] })] })));
|
|
19
|
+
}
|
|
20
|
+
}
|
package/document/Document.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import NextDocument from "next/document";
|
|
3
|
-
/**
|
|
4
|
-
* For typescript safety of this component
|
|
5
|
-
*
|
|
6
|
-
* @see https://bit.ly/3ceuF8m
|
|
7
|
-
*/
|
|
8
|
-
export declare class Document extends NextDocument {
|
|
9
|
-
render(): JSX.Element;
|
|
10
|
-
}
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import NextDocument from "next/document";
|
|
3
|
+
/**
|
|
4
|
+
* For typescript safety of this component
|
|
5
|
+
*
|
|
6
|
+
* @see https://bit.ly/3ceuF8m
|
|
7
|
+
*/
|
|
8
|
+
export declare class Document extends NextDocument {
|
|
9
|
+
render(): JSX.Element;
|
|
10
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import NextDocument, { Html, Head, Main, NextScript } from "next/document";
|
|
3
|
+
import { Meta, NoJs } from "@koine/react";
|
|
4
|
+
/**
|
|
5
|
+
* For typescript safety of this component
|
|
6
|
+
*
|
|
7
|
+
* @see https://bit.ly/3ceuF8m
|
|
8
|
+
*/
|
|
9
|
+
export class Document extends NextDocument {
|
|
10
|
+
render() {
|
|
11
|
+
const { locale, defaultLocale } = this.props.__NEXT_DATA__;
|
|
12
|
+
return (_jsxs(Html, Object.assign({ lang: locale || defaultLocale, className: "no-js" }, { children: [_jsxs(Head, { children: [_jsx(Meta, {}), _jsx(NoJs, {})] }), _jsxs("body", { children: [_jsx(Main, {}), _jsx(NextScript, {})] })] })));
|
|
13
|
+
}
|
|
14
|
+
}
|
package/document/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export * from "./Document";
|
|
2
|
-
export * from "./Document--emotion";
|
|
3
|
-
export * from "./Document--sc";
|
|
4
|
-
export * from "./Document--vanilla";
|
|
1
|
+
export * from "./Document";
|
|
2
|
+
export * from "./Document--emotion";
|
|
3
|
+
export * from "./Document--sc";
|
|
4
|
+
export * from "./Document--vanilla";
|
package/index.d.ts
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
|
-
export * from "./Analytics";
|
|
2
|
-
export * from "./Auth";
|
|
3
|
-
export * from "./Favicon";
|
|
4
|
-
export * from "./Forms";
|
|
5
|
-
export * from "./Head";
|
|
6
|
-
export * from "./I18n";
|
|
7
|
-
export * from "./Img";
|
|
8
|
-
export * from "./Link";
|
|
9
|
-
export * from "./NextProgress";
|
|
10
|
-
export * from "./Seo";
|
|
11
|
-
export * from "./Theme";
|
|
12
|
-
export * from "./utils";
|
|
1
|
+
export * from "./Analytics";
|
|
2
|
+
export * from "./Auth";
|
|
3
|
+
export * from "./Favicon";
|
|
4
|
+
export * from "./Forms";
|
|
5
|
+
export * from "./Head";
|
|
6
|
+
export * from "./I18n";
|
|
7
|
+
export * from "./Img";
|
|
8
|
+
export * from "./Link";
|
|
9
|
+
export * from "./NextProgress";
|
|
10
|
+
export * from "./Seo";
|
|
11
|
+
export * from "./Theme";
|
|
12
|
+
export * from "./utils";
|
|
13
|
+
export * from "./app";
|
|
14
|
+
export * from "./config";
|
|
15
|
+
export * from "./document";
|