mirror of
https://github.com/phuoc-ng/csslayout.git
synced 2025-08-06 22:26:33 +02:00
33 lines
879 B
TypeScript
33 lines
879 B
TypeScript
/**
|
|
* A collection of popular layouts and patterns made with CSS (https://csslayout.io)
|
|
* (c) 2019 - 2021 Nguyen Huu Phuoc <https://twitter.com/nghuuphuoc>
|
|
*/
|
|
|
|
import * as React from 'react';
|
|
|
|
import SampleCode from '../components/SampleCode';
|
|
import './browserFrame.css';
|
|
|
|
interface BrowserFrameProps {
|
|
css: string;
|
|
html: string;
|
|
}
|
|
|
|
const BrowserFrame: React.FC<BrowserFrameProps> = ({ children, css, html }) => {
|
|
return (
|
|
<div className="demo">
|
|
<div className="demo__html">
|
|
<SampleCode fullHeight={true} lang="html" code={html} />
|
|
</div>
|
|
<div className="demo__css">
|
|
<SampleCode fullHeight={true} lang="css" code={css} />
|
|
</div>
|
|
<div className="demo__live">
|
|
{children}
|
|
</div>
|
|
</div>
|
|
);
|
|
};
|
|
|
|
export default BrowserFrame;
|