@tern-secure/nextjs 3.2.5 → 3.2.6
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/cjs/app-router/client/TernSecureProvider.js +2 -1
- package/dist/cjs/app-router/client/TernSecureProvider.js.map +1 -1
- package/dist/esm/app-router/client/TernSecureProvider.js +2 -1
- package/dist/esm/app-router/client/TernSecureProvider.js.map +1 -1
- package/dist/types/app-router/client/TernSecureProvider.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -33,6 +33,7 @@ __export(TernSecureProvider_exports, {
|
|
|
33
33
|
});
|
|
34
34
|
module.exports = __toCommonJS(TernSecureProvider_exports);
|
|
35
35
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
36
|
+
var import_react = require("react");
|
|
36
37
|
var import_dynamic = __toESM(require("next/dynamic"));
|
|
37
38
|
const TernSecureClientProvider = (0, import_dynamic.default)(
|
|
38
39
|
() => import("../../boundary/TernSecureClientProvider").then((mod) => mod.TernSecureClientProvider),
|
|
@@ -45,7 +46,7 @@ function TernSecureLoadingFallback() {
|
|
|
45
46
|
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "sr-only", children: "Loading authentication..." }) });
|
|
46
47
|
}
|
|
47
48
|
function TernSecureProvider({ children }) {
|
|
48
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TernSecureClientProvider, { children });
|
|
49
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react.Suspense, { fallback: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TernSecureLoadingFallback, {}), children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TernSecureClientProvider, { children }) });
|
|
49
50
|
}
|
|
50
51
|
// Annotate the CommonJS export names for ESM import in node:
|
|
51
52
|
0 && (module.exports = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/app-router/client/TernSecureProvider.tsx"],"sourcesContent":["'use client'\r\n\r\nimport React from \"react\"\r\nimport dynamic from \"next/dynamic\"\r\n\r\nconst TernSecureClientProvider = dynamic(\r\n () => import(\"../../boundary/TernSecureClientProvider\").then(mod => mod.TernSecureClientProvider),\r\n { \r\n ssr: false,\r\n loading: () => <TernSecureLoadingFallback />\r\n }\r\n)\r\n\r\n// Loading fallback component\r\nfunction TernSecureLoadingFallback() {\r\n return (\r\n <div>\r\n <span className=\"sr-only\">Loading authentication...</span>\r\n </div>\r\n )\r\n}\r\n/**\r\n * Root Provider for TernSecure\r\n * Use this in your Next.js App Router root layout\r\n * Automatically handles client/server boundary and authentication state\r\n * \r\n * @example\r\n * // app/layout.tsx\r\n * import { TernSecureProvider } from '@tern/secure'\r\n * \r\n * export default function RootLayout({ children }) {\r\n * return (\r\n * <html>\r\n * <body>\r\n * <TernSecureProvider>\r\n * {children}\r\n * </TernSecureProvider>\r\n * </body>\r\n * </html>\r\n * )\r\n * }\r\n */\r\nexport function TernSecureProvider({ children }: { children: React.ReactNode }) {\r\n return (\r\n <TernSecureClientProvider>\r\n {children}\r\n </TernSecureClientProvider>\r\n )\r\n}"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AASmB;
|
|
1
|
+
{"version":3,"sources":["../../../../src/app-router/client/TernSecureProvider.tsx"],"sourcesContent":["'use client'\r\n\r\nimport React, { Suspense } from \"react\"\r\nimport dynamic from \"next/dynamic\"\r\n\r\nconst TernSecureClientProvider = dynamic(\r\n () => import(\"../../boundary/TernSecureClientProvider\").then(mod => mod.TernSecureClientProvider),\r\n { \r\n ssr: false,\r\n loading: () => <TernSecureLoadingFallback />\r\n }\r\n)\r\n\r\n// Loading fallback component\r\nfunction TernSecureLoadingFallback() {\r\n return (\r\n <div>\r\n <span className=\"sr-only\">Loading authentication...</span>\r\n </div>\r\n )\r\n}\r\n/**\r\n * Root Provider for TernSecure\r\n * Use this in your Next.js App Router root layout\r\n * Automatically handles client/server boundary and authentication state\r\n * \r\n * @example\r\n * // app/layout.tsx\r\n * import { TernSecureProvider } from '@tern/secure'\r\n * \r\n * export default function RootLayout({ children }) {\r\n * return (\r\n * <html>\r\n * <body>\r\n * <TernSecureProvider>\r\n * {children}\r\n * </TernSecureProvider>\r\n * </body>\r\n * </html>\r\n * )\r\n * }\r\n */\r\nexport function TernSecureProvider({ children }: { children: React.ReactNode }) {\r\n return (\r\n <Suspense fallback={<TernSecureLoadingFallback />}>\r\n <TernSecureClientProvider>\r\n {children}\r\n </TernSecureClientProvider>\r\n </Suspense>\r\n )\r\n}"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AASmB;AAPnB,mBAAgC;AAChC,qBAAoB;AAEpB,MAAM,+BAA2B,eAAAA;AAAA,EAC/B,MAAM,OAAO,yCAAyC,EAAE,KAAK,SAAO,IAAI,wBAAwB;AAAA,EAChG;AAAA,IACE,KAAK;AAAA,IACL,SAAS,MAAM,4CAAC,6BAA0B;AAAA,EAC3C;AACH;AAGA,SAAS,4BAA4B;AACnC,SACE,4CAAC,SACC,sDAAC,UAAK,WAAU,WAAU,uCAAyB,GACrD;AAEJ;AAsBO,SAAS,mBAAmB,EAAE,SAAS,GAAkC;AAC9E,SACE,4CAAC,yBAAS,UAAU,4CAAC,6BAA0B,GAC7C,sDAAC,4BACI,UACL,GACA;AAEN;","names":["dynamic"]}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx } from "react/jsx-runtime";
|
|
3
|
+
import { Suspense } from "react";
|
|
3
4
|
import dynamic from "next/dynamic";
|
|
4
5
|
const TernSecureClientProvider = dynamic(
|
|
5
6
|
() => import("../../boundary/TernSecureClientProvider").then((mod) => mod.TernSecureClientProvider),
|
|
@@ -12,7 +13,7 @@ function TernSecureLoadingFallback() {
|
|
|
12
13
|
return /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Loading authentication..." }) });
|
|
13
14
|
}
|
|
14
15
|
function TernSecureProvider({ children }) {
|
|
15
|
-
return /* @__PURE__ */ jsx(TernSecureClientProvider, { children });
|
|
16
|
+
return /* @__PURE__ */ jsx(Suspense, { fallback: /* @__PURE__ */ jsx(TernSecureLoadingFallback, {}), children: /* @__PURE__ */ jsx(TernSecureClientProvider, { children }) });
|
|
16
17
|
}
|
|
17
18
|
export {
|
|
18
19
|
TernSecureProvider
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/app-router/client/TernSecureProvider.tsx"],"sourcesContent":["'use client'\r\n\r\nimport React from \"react\"\r\nimport dynamic from \"next/dynamic\"\r\n\r\nconst TernSecureClientProvider = dynamic(\r\n () => import(\"../../boundary/TernSecureClientProvider\").then(mod => mod.TernSecureClientProvider),\r\n { \r\n ssr: false,\r\n loading: () => <TernSecureLoadingFallback />\r\n }\r\n)\r\n\r\n// Loading fallback component\r\nfunction TernSecureLoadingFallback() {\r\n return (\r\n <div>\r\n <span className=\"sr-only\">Loading authentication...</span>\r\n </div>\r\n )\r\n}\r\n/**\r\n * Root Provider for TernSecure\r\n * Use this in your Next.js App Router root layout\r\n * Automatically handles client/server boundary and authentication state\r\n * \r\n * @example\r\n * // app/layout.tsx\r\n * import { TernSecureProvider } from '@tern/secure'\r\n * \r\n * export default function RootLayout({ children }) {\r\n * return (\r\n * <html>\r\n * <body>\r\n * <TernSecureProvider>\r\n * {children}\r\n * </TernSecureProvider>\r\n * </body>\r\n * </html>\r\n * )\r\n * }\r\n */\r\nexport function TernSecureProvider({ children }: { children: React.ReactNode }) {\r\n return (\r\n <TernSecureClientProvider>\r\n {children}\r\n </TernSecureClientProvider>\r\n )\r\n}"],"mappings":";AASmB;
|
|
1
|
+
{"version":3,"sources":["../../../../src/app-router/client/TernSecureProvider.tsx"],"sourcesContent":["'use client'\r\n\r\nimport React, { Suspense } from \"react\"\r\nimport dynamic from \"next/dynamic\"\r\n\r\nconst TernSecureClientProvider = dynamic(\r\n () => import(\"../../boundary/TernSecureClientProvider\").then(mod => mod.TernSecureClientProvider),\r\n { \r\n ssr: false,\r\n loading: () => <TernSecureLoadingFallback />\r\n }\r\n)\r\n\r\n// Loading fallback component\r\nfunction TernSecureLoadingFallback() {\r\n return (\r\n <div>\r\n <span className=\"sr-only\">Loading authentication...</span>\r\n </div>\r\n )\r\n}\r\n/**\r\n * Root Provider for TernSecure\r\n * Use this in your Next.js App Router root layout\r\n * Automatically handles client/server boundary and authentication state\r\n * \r\n * @example\r\n * // app/layout.tsx\r\n * import { TernSecureProvider } from '@tern/secure'\r\n * \r\n * export default function RootLayout({ children }) {\r\n * return (\r\n * <html>\r\n * <body>\r\n * <TernSecureProvider>\r\n * {children}\r\n * </TernSecureProvider>\r\n * </body>\r\n * </html>\r\n * )\r\n * }\r\n */\r\nexport function TernSecureProvider({ children }: { children: React.ReactNode }) {\r\n return (\r\n <Suspense fallback={<TernSecureLoadingFallback />}>\r\n <TernSecureClientProvider>\r\n {children}\r\n </TernSecureClientProvider>\r\n </Suspense>\r\n )\r\n}"],"mappings":";AASmB;AAPnB,SAAgB,gBAAgB;AAChC,OAAO,aAAa;AAEpB,MAAM,2BAA2B;AAAA,EAC/B,MAAM,OAAO,yCAAyC,EAAE,KAAK,SAAO,IAAI,wBAAwB;AAAA,EAChG;AAAA,IACE,KAAK;AAAA,IACL,SAAS,MAAM,oBAAC,6BAA0B;AAAA,EAC3C;AACH;AAGA,SAAS,4BAA4B;AACnC,SACE,oBAAC,SACC,8BAAC,UAAK,WAAU,WAAU,uCAAyB,GACrD;AAEJ;AAsBO,SAAS,mBAAmB,EAAE,SAAS,GAAkC;AAC9E,SACE,oBAAC,YAAS,UAAU,oBAAC,6BAA0B,GAC7C,8BAAC,4BACI,UACL,GACA;AAEN;","names":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TernSecureProvider.d.ts","sourceRoot":"","sources":["../../../../src/app-router/client/TernSecureProvider.tsx"],"names":[],"mappings":"AAEA,OAAO,
|
|
1
|
+
{"version":3,"file":"TernSecureProvider.d.ts","sourceRoot":"","sources":["../../../../src/app-router/client/TernSecureProvider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAmB,MAAM,OAAO,CAAA;AAmBvC;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,kBAAkB,CAAC,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;CAAE,2CAQ7E"}
|