1
0
mirror of https://github.com/phuoc-ng/csslayout.git synced 2025-10-24 19:26:26 +02:00

feat: Ribbon

This commit is contained in:
Phuoc Nguyen
2022-09-19 22:50:48 +07:00
parent 505b85fb7e
commit 61b40e8ab5
7 changed files with 173 additions and 246 deletions

View File

@@ -1,74 +0,0 @@
import * as React from 'react';
import Frame from '../../placeholders/Frame';
const Cover: React.FC<{}> = () => {
return (
<Frame>
<div
style={{
alignItems: 'center',
display: 'flex',
flexDirection: 'column',
height: '100%',
justifyContent: 'center',
padding: '8px',
}}
>
<div
style={{
backgroundColor: '#BBB',
height: '24px',
position: 'relative',
width: '48px',
}}
>
<div
style={{
border: '12px solid #CCC',
borderLeftColor: 'transparent',
bottom: '-6px',
left: '-18px',
position: 'absolute',
zIndex: -1,
}}
/>
<div
style={{
border: '6px solid transparent',
borderBottomWidth: 0,
borderRightWidth: 0,
borderTopColor: '#AAA',
left: 0,
position: 'absolute',
top: '100%',
}}
/>
<div
style={{
border: '6px solid transparent',
borderBottomWidth: 0,
borderLeftWidth: 0,
borderTopColor: '#AAA',
position: 'absolute',
right: 0,
top: '100%',
}}
/>
<div
style={{
border: '12px solid #CCC',
borderRightColor: 'transparent',
bottom: '-6px',
position: 'absolute',
right: '-18px',
zIndex: -1,
}}
/>
</div>
</div>
</Frame>
);
};
export default Cover;