File tree Expand file tree Collapse file tree 7 files changed +16
-17
lines changed Expand file tree Collapse file tree 7 files changed +16
-17
lines changed Original file line number Diff line number Diff line change @@ -63,7 +63,7 @@ export default function RootLayout({
63
63
/>
64
64
< PosthogHeadSetup />
65
65
</ head >
66
- < PHProvider >
66
+ < PHProvider disable_session_recording = { true } >
67
67
< PostHogPageView />
68
68
< body
69
69
className = { cn (
Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ import { ThirdwebProvider } from "thirdweb/react";
5
5
import { PHProvider } from "../../../../lib/posthog/Posthog" ;
6
6
import { PostHogPageView } from "../../../../lib/posthog/PosthogPageView" ;
7
7
8
- export function Providers ( { children } : { children : React . ReactNode } ) {
8
+ export function BridgeProviders ( { children } : { children : React . ReactNode } ) {
9
9
return (
10
10
< ThirdwebProvider >
11
11
< ThemeProvider
@@ -14,7 +14,7 @@ export function Providers({ children }: { children: React.ReactNode }) {
14
14
enableSystem = { false }
15
15
defaultTheme = "dark"
16
16
>
17
- < PHProvider >
17
+ < PHProvider disable_session_recording = { true } >
18
18
< PostHogPageView />
19
19
{ children }
20
20
< Toaster richColors theme = "dark" />
Original file line number Diff line number Diff line change 1
1
import { cn } from "@/lib/utils" ;
2
2
import { Inter } from "next/font/google" ;
3
3
import "../../global.css" ;
4
- import { Providers } from "./components/client/Providers.client" ;
4
+ import { BridgeProviders } from "./components/client/Providers.client" ;
5
5
6
6
const fontSans = Inter ( {
7
7
subsets : [ "latin" ] ,
@@ -22,7 +22,7 @@ export default function BridgeLayout({
22
22
fontSans . variable ,
23
23
) }
24
24
>
25
- < Providers > { children } </ Providers >
25
+ < BridgeProviders > { children } </ BridgeProviders >
26
26
</ body >
27
27
</ html >
28
28
) ;
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ export default function Layout(props: {
39
39
< link rel = "icon" href = "/assets/nebula/favicon.ico" />
40
40
< PosthogHeadSetup />
41
41
</ head >
42
- < PHProvider >
42
+ < PHProvider disable_session_recording = { false } >
43
43
< PostHogPageView />
44
44
< body
45
45
className = { cn (
Original file line number Diff line number Diff line change @@ -4,10 +4,10 @@ import { ThirdwebProvider } from "thirdweb/react";
4
4
import { PHProvider } from "../../../../lib/posthog/Posthog" ;
5
5
import { PostHogPageView } from "../../../../lib/posthog/PosthogPageView" ;
6
6
7
- export function Providers ( { children } : { children : React . ReactNode } ) {
7
+ export function PayProviders ( { children } : { children : React . ReactNode } ) {
8
8
return (
9
9
< ThirdwebProvider >
10
- < PHProvider >
10
+ < PHProvider disable_session_recording = { true } >
11
11
< PostHogPageView />
12
12
{ children }
13
13
< Toaster richColors theme = "dark" />
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ import "../../global.css";
2
2
import { cn } from "@/lib/utils" ;
3
3
import { ThemeProvider } from "next-themes" ;
4
4
import { Inter } from "next/font/google" ;
5
- import { Providers } from "./components/client/Providers.client" ;
5
+ import { PayProviders } from "./components/client/Providers.client" ;
6
6
7
7
const fontSans = Inter ( {
8
8
subsets : [ "latin" ] ,
@@ -23,7 +23,7 @@ export default async function PayLayout({
23
23
fontSans . variable ,
24
24
) }
25
25
>
26
- < Providers >
26
+ < PayProviders >
27
27
< ThemeProvider
28
28
attribute = "class"
29
29
disableTransitionOnChange
@@ -43,7 +43,7 @@ export default async function PayLayout({
43
43
/>
44
44
</ div >
45
45
</ ThemeProvider >
46
- </ Providers >
46
+ </ PayProviders >
47
47
</ body >
48
48
</ html >
49
49
) ;
Original file line number Diff line number Diff line change @@ -7,10 +7,9 @@ import { useEffect } from "react";
7
7
8
8
const NEXT_PUBLIC_POSTHOG_API_KEY = process . env . NEXT_PUBLIC_POSTHOG_API_KEY ;
9
9
10
- export function PHProvider ( {
11
- children,
12
- } : {
10
+ export function PHProvider ( props : {
13
11
children : React . ReactNode ;
12
+ disable_session_recording : boolean ;
14
13
} ) {
15
14
// eslint-disable-next-line no-restricted-syntax
16
15
useEffect ( ( ) => {
@@ -19,10 +18,10 @@ export function PHProvider({
19
18
api_host : "https://a.thirdweb.com" ,
20
19
capture_pageview : false ,
21
20
debug : false ,
22
- disable_session_recording : true ,
21
+ disable_session_recording : props . disable_session_recording ,
23
22
} ) ;
24
23
}
25
- } , [ ] ) ;
24
+ } , [ props . disable_session_recording ] ) ;
26
25
27
- return < PostHogProvider client = { posthog } > { children } </ PostHogProvider > ;
26
+ return < PostHogProvider client = { posthog } > { props . children } </ PostHogProvider > ;
28
27
}
You can’t perform that action at this time.
0 commit comments