@arch-cadre/auth-google 1.0.8 → 1.0.10
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/actions/auth.cjs +1 -1
- package/dist/actions/auth.mjs +1 -1
- package/dist/index.cjs +3 -3
- package/dist/index.mjs +3 -3
- package/dist/routes.cjs +2 -2
- package/dist/routes.mjs +2 -2
- package/dist/ui/google-button.cjs +1 -1
- package/dist/ui/google-button.mjs +1 -1
- package/dist/ui/settings-page.cjs +1 -1
- package/dist/ui/settings-page.mjs +1 -1
- package/package.json +7 -7
- package/src/actions/auth.ts +1 -1
- package/src/index.ts +3 -3
- package/src/routes.ts +2 -2
- package/src/ui/google-button.tsx +1 -1
- package/src/ui/settings-page.tsx +1 -1
package/dist/actions/auth.cjs
CHANGED
|
@@ -8,7 +8,7 @@ exports.loginWithGoogle = loginWithGoogle;
|
|
|
8
8
|
var _arctic = require("arctic");
|
|
9
9
|
var _headers = require("next/headers");
|
|
10
10
|
var _navigation = require("next/navigation");
|
|
11
|
-
var _settings = require("./settings.
|
|
11
|
+
var _settings = require("./settings.cjs");
|
|
12
12
|
async function loginWithGoogle() {
|
|
13
13
|
const config = await (0, _settings.getGoogleConfig)();
|
|
14
14
|
if (!config.clientId || !config.clientSecret) {
|
package/dist/actions/auth.mjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { Google, generateCodeVerifier, generateState } from "arctic";
|
|
3
3
|
import { cookies } from "next/headers";
|
|
4
4
|
import { redirect } from "next/navigation";
|
|
5
|
-
import { getGoogleConfig } from "./settings.
|
|
5
|
+
import { getGoogleConfig } from "./settings.mjs";
|
|
6
6
|
export async function loginWithGoogle() {
|
|
7
7
|
const config = await getGoogleConfig();
|
|
8
8
|
if (!config.clientId || !config.clientSecret) {
|
package/dist/index.cjs
CHANGED
|
@@ -5,9 +5,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
|
|
7
7
|
var _manifest = _interopRequireDefault(require("../manifest.json"));
|
|
8
|
-
var _navigation = require("./navigation.
|
|
9
|
-
var _routes = require("./routes.
|
|
10
|
-
var _googleButton = require("./ui/google-button.
|
|
8
|
+
var _navigation = require("./navigation.cjs");
|
|
9
|
+
var _routes = require("./routes.cjs");
|
|
10
|
+
var _googleButton = require("./ui/google-button.cjs");
|
|
11
11
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
12
|
const googleAuthModule = {
|
|
13
13
|
manifest: _manifest.default,
|
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import manifest from "../manifest.json";
|
|
2
|
-
import { navigation } from "./navigation.
|
|
3
|
-
import { apiRoutes, privateRoutes } from "./routes.
|
|
4
|
-
import { GoogleLoginButton } from "./ui/google-button.
|
|
2
|
+
import { navigation } from "./navigation.mjs";
|
|
3
|
+
import { apiRoutes, privateRoutes } from "./routes.mjs";
|
|
4
|
+
import { GoogleLoginButton } from "./ui/google-button.mjs";
|
|
5
5
|
const googleAuthModule = {
|
|
6
6
|
manifest,
|
|
7
7
|
routes: {
|
package/dist/routes.cjs
CHANGED
|
@@ -9,9 +9,9 @@ var _server = require("@arch-cadre/core/server");
|
|
|
9
9
|
var _arctic = require("arctic");
|
|
10
10
|
var _dynamic = _interopRequireDefault(require("next/dynamic"));
|
|
11
11
|
var _headers = require("next/headers");
|
|
12
|
-
var _settings = require("./actions/settings.
|
|
12
|
+
var _settings = require("./actions/settings.cjs");
|
|
13
13
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
14
|
-
const GoogleAuthSettingsPage = (0, _dynamic.default)(() => Promise.resolve().then(() => require("./ui/settings-page.
|
|
14
|
+
const GoogleAuthSettingsPage = (0, _dynamic.default)(() => Promise.resolve().then(() => require("./ui/settings-page.cjs")));
|
|
15
15
|
async function getGoogleClient() {
|
|
16
16
|
const config = await (0, _settings.getGoogleConfig)();
|
|
17
17
|
return new _arctic.Google(config.clientId, config.clientSecret, config.redirectUri);
|
package/dist/routes.mjs
CHANGED
|
@@ -10,8 +10,8 @@ import {
|
|
|
10
10
|
import { decodeIdToken, Google } from "arctic";
|
|
11
11
|
import dynamic from "next/dynamic";
|
|
12
12
|
import { cookies } from "next/headers";
|
|
13
|
-
import { getGoogleConfig } from "./actions/settings.
|
|
14
|
-
const GoogleAuthSettingsPage = dynamic(() => import("./ui/settings-page.
|
|
13
|
+
import { getGoogleConfig } from "./actions/settings.mjs";
|
|
14
|
+
const GoogleAuthSettingsPage = dynamic(() => import("./ui/settings-page.mjs"));
|
|
15
15
|
async function getGoogleClient() {
|
|
16
16
|
const config = await getGoogleConfig();
|
|
17
17
|
return new Google(config.clientId, config.clientSecret, config.redirectUri);
|
|
@@ -8,7 +8,7 @@ exports.GoogleLoginButton = GoogleLoginButton;
|
|
|
8
8
|
var _intl = require("@arch-cadre/intl");
|
|
9
9
|
var _ui = require("@arch-cadre/ui");
|
|
10
10
|
var React = _interopRequireWildcard(require("react"));
|
|
11
|
-
var _auth = require("../actions/auth.
|
|
11
|
+
var _auth = require("../actions/auth.cjs");
|
|
12
12
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
13
13
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
14
14
|
function GoogleLoginButton() {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { useTranslation } from "@arch-cadre/intl";
|
|
3
3
|
import { Button } from "@arch-cadre/ui";
|
|
4
4
|
import * as React from "react";
|
|
5
|
-
import { loginWithGoogle } from "../actions/auth.
|
|
5
|
+
import { loginWithGoogle } from "../actions/auth.mjs";
|
|
6
6
|
export function GoogleLoginButton() {
|
|
7
7
|
const { t } = useTranslation();
|
|
8
8
|
return /* @__PURE__ */ React.createElement(
|
|
@@ -13,7 +13,7 @@ var _label = require("@arch-cadre/ui/components/label");
|
|
|
13
13
|
var _react = _interopRequireWildcard(require("react"));
|
|
14
14
|
var React = _react;
|
|
15
15
|
var _sonner = require("sonner");
|
|
16
|
-
var _settings = require("../actions/settings.
|
|
16
|
+
var _settings = require("../actions/settings.cjs");
|
|
17
17
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
18
18
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
19
19
|
function GoogleAuthSettingsPage() {
|
|
@@ -16,7 +16,7 @@ import { toast } from "sonner";
|
|
|
16
16
|
import {
|
|
17
17
|
getGoogleConfig,
|
|
18
18
|
updateGoogleConfig
|
|
19
|
-
} from "../actions/settings.
|
|
19
|
+
} from "../actions/settings.mjs";
|
|
20
20
|
export default function GoogleAuthSettingsPage() {
|
|
21
21
|
const { t } = useTranslation();
|
|
22
22
|
const [config, setConfig] = useState({
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@arch-cadre/auth-google",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.10",
|
|
4
4
|
"description": "Google Auth module for Kryo framework",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -26,9 +26,9 @@
|
|
|
26
26
|
"build": "unbuild"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@arch-cadre/modules": "^0.0.
|
|
29
|
+
"@arch-cadre/modules": "^0.0.80",
|
|
30
30
|
"@hookform/resolvers": "^3.10.0",
|
|
31
|
-
"@arch-cadre/ui": "^0.0.
|
|
31
|
+
"@arch-cadre/ui": "^0.0.54",
|
|
32
32
|
"arctic": "^3.7.0",
|
|
33
33
|
"lucide-react": "^0.475.0",
|
|
34
34
|
"react-hook-form": "^7.54.2",
|
|
@@ -36,8 +36,8 @@
|
|
|
36
36
|
"zod": "^3.24.1"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"@arch-cadre/core": "^0.0.
|
|
40
|
-
"@arch-cadre/intl": "^0.0.
|
|
39
|
+
"@arch-cadre/core": "^0.0.54",
|
|
40
|
+
"@arch-cadre/intl": "^0.0.54",
|
|
41
41
|
"@types/react": "^19",
|
|
42
42
|
"next": "16.1.1",
|
|
43
43
|
"react": "^19.0.0",
|
|
@@ -45,8 +45,8 @@
|
|
|
45
45
|
"unbuild": "^3.6.1"
|
|
46
46
|
},
|
|
47
47
|
"peerDependencies": {
|
|
48
|
-
"@arch-cadre/core": "^0.0.
|
|
49
|
-
"@arch-cadre/ui": "^0.0.
|
|
48
|
+
"@arch-cadre/core": "^0.0.54",
|
|
49
|
+
"@arch-cadre/ui": "^0.0.54",
|
|
50
50
|
"next": ">=15.0.0",
|
|
51
51
|
"react": "^19.0.0"
|
|
52
52
|
},
|
package/src/actions/auth.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
import { Google, generateCodeVerifier, generateState } from "arctic";
|
|
4
4
|
import { cookies } from "next/headers";
|
|
5
5
|
import { redirect } from "next/navigation";
|
|
6
|
-
import { getGoogleConfig } from "./settings
|
|
6
|
+
import { getGoogleConfig } from "./settings";
|
|
7
7
|
|
|
8
8
|
export async function loginWithGoogle() {
|
|
9
9
|
const config = await getGoogleConfig();
|
package/src/index.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { IModule } from "@arch-cadre/modules";
|
|
2
2
|
import manifest from "../manifest.json";
|
|
3
|
-
import { navigation } from "./navigation
|
|
4
|
-
import { apiRoutes, privateRoutes } from "./routes
|
|
5
|
-
import { GoogleLoginButton } from "./ui/google-button
|
|
3
|
+
import { navigation } from "./navigation";
|
|
4
|
+
import { apiRoutes, privateRoutes } from "./routes";
|
|
5
|
+
import { GoogleLoginButton } from "./ui/google-button";
|
|
6
6
|
|
|
7
7
|
const googleAuthModule: IModule = {
|
|
8
8
|
manifest,
|
package/src/routes.ts
CHANGED
|
@@ -14,9 +14,9 @@ import type {
|
|
|
14
14
|
import { decodeIdToken, Google } from "arctic";
|
|
15
15
|
import dynamic from "next/dynamic";
|
|
16
16
|
import { cookies } from "next/headers";
|
|
17
|
-
import { getGoogleConfig } from "./actions/settings
|
|
17
|
+
import { getGoogleConfig } from "./actions/settings";
|
|
18
18
|
|
|
19
|
-
const GoogleAuthSettingsPage = dynamic(() => import("./ui/settings-page
|
|
19
|
+
const GoogleAuthSettingsPage = dynamic(() => import("./ui/settings-page"));
|
|
20
20
|
|
|
21
21
|
async function getGoogleClient() {
|
|
22
22
|
const config = await getGoogleConfig();
|
package/src/ui/google-button.tsx
CHANGED
|
@@ -3,7 +3,7 @@ import { useTranslation } from "@arch-cadre/intl";
|
|
|
3
3
|
|
|
4
4
|
import { Button } from "@arch-cadre/ui";
|
|
5
5
|
import * as React from "react";
|
|
6
|
-
import { loginWithGoogle } from "../actions/auth
|
|
6
|
+
import { loginWithGoogle } from "../actions/auth";
|
|
7
7
|
|
|
8
8
|
export function GoogleLoginButton() {
|
|
9
9
|
const { t } = useTranslation();
|
package/src/ui/settings-page.tsx
CHANGED