funnel through just iframe for now for testing sake

This commit is contained in:
Gigiaj 2025-05-08 18:00:16 -05:00
parent 1bd593b530
commit 8b50ac150b

View file

@ -4,6 +4,7 @@ import classNames from 'classnames';
import { ContainerColor } from '../../styles/ContainerColor.css'; import { ContainerColor } from '../../styles/ContainerColor.css';
import * as css from './style.css'; import * as css from './style.css';
import { ScreenSize, useScreenSizeContext } from '../../hooks/useScreenSize'; import { ScreenSize, useScreenSizeContext } from '../../hooks/useScreenSize';
import { Outlet, useOutletContext } from 'react-router-dom';
type PageRootProps = { type PageRootProps = {
nav: ReactNode; nav: ReactNode;
@ -12,6 +13,7 @@ type PageRootProps = {
export function PageRoot({ nav, children }: PageRootProps) { export function PageRoot({ nav, children }: PageRootProps) {
const screenSize = useScreenSizeContext(); const screenSize = useScreenSizeContext();
const { iframeRef } = useOutletContext();
return ( return (
<Box grow="Yes" className={ContainerColor({ variant: 'Background' })}> <Box grow="Yes" className={ContainerColor({ variant: 'Background' })}>
@ -19,7 +21,7 @@ export function PageRoot({ nav, children }: PageRootProps) {
{screenSize !== ScreenSize.Mobile && ( {screenSize !== ScreenSize.Mobile && (
<Line variant="Background" size="300" direction="Vertical" /> <Line variant="Background" size="300" direction="Vertical" />
)} )}
{children} <Outlet context={{ iframeRef }} />
</Box> </Box>
); );
} }