@cristianchaparroa/simple-dyamond
v1.0.4
Published
A simple, customizable diamond-shaped React component
Downloads
12
Maintainers
Readme
Simple Dyamond
A simple, customizable diamond-shaped React component.
Installation
npm install @cristianchaparroa/simple-dyamondUsage
import React from 'react';
import SimpleDyamond from '@cristianchaparroa/simple-dyamond';
function App() {
return (
<div>
<SimpleDyamond
size={120}
color="#e74c3c"
borderColor="#c0392b"
content="💎"
/>
</div>
);
}
Props
| Prop | Type | Default | Description |
|------|------|---------|-------------|
| size | number | 100 | Size of the diamond (width and height in px) |
| color | string | "#3498db" | Background color of the diamond |
| borderColor | string | "#2980b9" | Border color of the diamond |
| borderWidth | number | 2 | Border width in pixels |
| content | string | "" | Content to display inside the diamond |
| contentColor | string | "#fff" | Color of the content text |
