diff --git a/client/layouts/Centering.jsx b/client/layouts/Centering.jsx index 2ed71a4..958a723 100644 --- a/client/layouts/Centering.jsx +++ b/client/layouts/Centering.jsx @@ -6,11 +6,16 @@ import BrowserFrame from '../placeholders/BrowserFrame'; const Centering = () => { return ( - -
-
CENTER
-
-
+ +
CENTER
+ + } + source={ +
source
+ } + />
); }; diff --git a/client/placeholders/BrowserFrame.jsx b/client/placeholders/BrowserFrame.jsx index 2691ed6..5d3c753 100644 --- a/client/placeholders/BrowserFrame.jsx +++ b/client/placeholders/BrowserFrame.jsx @@ -1,15 +1,42 @@ -import React from 'react'; +import React, { useState } from 'react'; + +const BrowserFrame = ({ content, source }) => { + const [isContentActive, setContentActive] = useState(true); + const flip = () => setContentActive(isActive => !isActive); -const BrowserFrame = ({ children }) => { return (
+
+ + {isContentActive ? 'Source' : 'Demo'} + +
-
- {children} +
+
+ {content} +
+
+ {source} +
);