mirror of
https://github.com/phuoc-ng/csslayout.git
synced 2025-10-23 18:56:29 +02:00
76 lines
2.1 KiB
JavaScript
76 lines
2.1 KiB
JavaScript
import React from 'react';
|
|
|
|
import DetailsLayout from '../../layouts/DetailsLayout';
|
|
import Block from '../../placeholders/Block';
|
|
import BrowserFrame from '../../placeholders/BrowserFrame';
|
|
import Circle from '../../placeholders/Circle';
|
|
import Rectangle from '../../placeholders/Rectangle';
|
|
|
|
import SampleCode from '../../SampleCode';
|
|
|
|
const Details = () => {
|
|
return (
|
|
<DetailsLayout title="Feature list">
|
|
<BrowserFrame
|
|
content={
|
|
<div className="flex h-100 items-center justify-center">
|
|
<div className="w-60">
|
|
<div className="flex flex-row mb4">
|
|
<div className="mh3"><Circle size={128} /></div>
|
|
<div style={{ flex: 1 }}>
|
|
<div className="mb4"><Rectangle height={8} /></div>
|
|
<Block numberOfBlocks={10} />
|
|
</div>
|
|
</div>
|
|
<div className="flex flex-row flex-row-reverse mb4">
|
|
<div className="mh3"><Circle size={128} /></div>
|
|
<div style={{ flex: 1 }}>
|
|
<div className="mb4"><Rectangle height={8} /></div>
|
|
<Block numberOfBlocks={15} />
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
}
|
|
source={
|
|
<SampleCode
|
|
lang="html"
|
|
code={`
|
|
<!-- Feature item -->
|
|
<div style="
|
|
display: flex;
|
|
|
|
/* OPTIONAL: Reverse the order of image and content */
|
|
flex-direction: row-reverse;
|
|
|
|
/* OPTIONAL: Spacing between items */
|
|
margin: 16px 0;
|
|
">
|
|
<!-- Image -->
|
|
<div style="
|
|
width: 128px;
|
|
">
|
|
...
|
|
</div>
|
|
|
|
<!-- Right side -->
|
|
<div style="
|
|
/* Take the remaining width */
|
|
flex: 1;
|
|
">
|
|
...
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Repeated items -->
|
|
...
|
|
`}
|
|
/>
|
|
}
|
|
/>
|
|
</DetailsLayout>
|
|
);
|
|
};
|
|
|
|
export default Details;
|